Skip to main content

GET /reverse-key/:domain

Derive an SNS reverse-record public key without making an RPC request.

Request

GET /reverse-key/:domain

Path parameters

domain

Required. A TLD-less top-level domain such as bonfida, or a one-level subdomain such as team.bonfida. The route trims whitespace, converts the value to lowercase, and selects subdomain derivation when two labels are present.

Response

A successful request returns 200 OK with the derived base58 reverse-record public key:

type ReverseKeyResponse = {
s: "ok";
result: string;
};

Example

curl "https://sdk-proxy-v2.sns.id/reverse-key/bonfida"
{
"s": "ok",
"result": "<REVERSE_RECORD_PUBLIC_KEY>"
}

Errors

StatusresultWhen
400Invalid inputThe domain has empty labels or more than two labels.
500Internal errorDerivation fails for another unmapped reason.