logo
OpenapiAuth

Get EIP-712 types for a method

API Docs with browser client
GET
/eip712/types-for-method

Return legacy signing types and v4 method-specific payload types. For a complete v4 NamefiApiRequest envelope and domain, use the operation signing instructions.

Authorization

headerx-api-key<token>

Query Parameters

method*string

API operation ID (e.g. "createDnsRecord", "registerDomain").

Length1 <= length

Response Body

OK

application/json
  1. response

Result of looking up EIP-712 types for a specific API operation.

found*boolean

Whether the method was found in the EIP-712 registry.

acceptedPrimaryTypes?array<string>

Primary type names accepted by this method (sent via x-namefi-eip712-type header). Present when found is true.

types?

EIP-712 type map for this method. Present when found is true.

typedData?

V4 method payload types. NamefiApiRequest wraps the selected payload struct; request the operation without a signature for the complete envelope and domain.

availableMethods?array<string>

List of operation IDs that support EIP-712 authentication. Present when found is false.

Example Request
curl -X GET 'https://example.com/v4/eip712/types-for-method?method=string'
Example Response
{  "found": true,  "acceptedPrimaryTypes": [    "string"  ],  "types": {    "property1": [      {        "name": "string",        "type": "string"      }    ],    "property2": [      {        "name": "string",        "type": "string"      }    ]  },  "typedData": {    "acceptedPayloadTypes": [      "string"    ],    "types": {      "property1": [        {          "name": "string",          "type": "string"        }      ],      "property2": [        {          "name": "string",          "type": "string"        }      ]    }  },  "availableMethods": [    "string"  ]}