auth

Redeem a PendingAccountClaim by proving ownership of an Ethereum wallet.

The caller must:

  1. Hold a valid, unexpired PendingAccountClaim (from a prior oauth_callback).
  2. Generate a nonce via GET /api/v1/wallet/nonce/<address>/.
  3. Sign get_nonce_message(address, nonce) with their private key.
  4. POST all four values here.

On success:

  • Finds or creates a User row keyed by ethereum_address.
  • Creates a SocialAccount linking the provider identity to that User.
  • Deletes the PendingAccountClaim (single-use).
  • Logs a UserLoginEvent.
  • Issues JWT access + refresh cookies.

Expected request body (JSON): { "claim_token": "<uuid>", "address": "<0x ethereum address>", "signature": "<hex signature>", "nonce": "<nonce obtained from /api/v1/wallet/nonce/<address>/>" }

Returns 200: {"status": "authenticated", "user": <profile>}

Returns 400: missing fields, unknown/expired claim token, invalid nonce.

Returns 401: wallet signature verification failed.

post/api/v1/auth/claim/

Request

  • Base URL: https://api.leviathannews.xyz (the document declares no server; this is the origin it was published from)
  • URL: https://api.leviathannews.xyz/api/v1/auth/claim/
  • Auth: one of:
    • HTTP bearer
    • none

Response

No response body

Changes

No recorded changes to this operation across all 1 revision of this API.