decentralised.art Chain Auth API (0.5.0)

Download OpenAPI specification:

License: MIT

Chain authentication endpoints.

auth

Operations related to authentication.

Get nonce

Issue a one-time EIP-4361 sign-in message for an address. Have the wallet sign message with personal_sign, then submit the nonce and the signature to /auth within five minutes. Each nonce can be redeemed once; requesting another one does not invalidate those already issued. Issuing a nonce stores nothing on the server: the nonce itself carries its issue time and origin under the server's signature.

The message names the site the user signs in through: the origin query parameter when given; otherwise the request's Origin header when it is one the server is configured with; otherwise the server's first configured origin. Wallets that support EIP-4361 reject or warn when the message names a different site from the one asking for the signature, so a page should pass its own origin.

path Parameters
address
required
string (Address) ^(0x)?[a-fA-F0-9]{40}$

Address to get nonce for

query Parameters
origin
string
Example: origin=https://decentralised.art

Origin of the page signing in, as window.location.origin gives it, percent-encoded or not. Browsers send no Origin header on a same-origin GET, so this is how a page served from a secondary configured origin gets a message naming it. A value that is not a configured origin is refused with 400.

header Parameters
Origin
string
Example: https://decentralised.art

Origin of the page signing in. Browsers send it on cross-origin requests; it is ignored when the origin query parameter is given or when it is not a configured origin.

Responses

Response samples

Content type
application/json
{
  • "nonce": "string",
  • "message": "https://decentralised.art wants you to sign in with your Ethereum account:\n0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266\n\nSign in to decentralised.art.\n\nURI: https://decentralised.art\nVersion: 1\nChain ID: 11155111\nNonce: 000000006ac23fc0003f9c1d27a84be6526b0d8e4c13f7a9e5d2b8c06f41e93a7d\nIssued At: 2026-10-04T12:00:00Z\nExpiration Time: 2026-10-04T12:05:00Z"
}

CORS preflight

CORS preflight

Responses

Authenticate

Authenticate using an address, the nonce /nonce issued to it, and the wallet's personal_sign signature of the message issued with that nonce. The server checks the signature against the message it issued.

Request Body schema: application/json
required
address
required
string (Address) ^(0x)?[a-fA-F0-9]{40}$

Ethereum-style address, with or without a 0x prefix.

nonce
required
string^[0-9a-f]{66}$

The nonce /nonce issued to address.

signature
required
string

The wallet's personal_sign (EIP-191) signature of the message issued with nonce, as 65-byte hex.

Responses

Request samples

Content type
application/json
{
  • "address": "string",
  • "nonce": "string",
  • "signature": "string"
}

Response samples

Content type
application/json
{
  • "access_token": "string"
}