API Explorer

Sign-In With Ethereum

Sign-In With Ethereum (SIWE)

A User can log in by proving that they hold an Ethereum wallet, following EIP-4361. Only externally owned accounts are supported. The signature is checked locally, so no blockchain node is needed.

  1. The client asks for a challenge with POST /my/logins/siwe/challenge, without authentication. OBP returns a nonce and the message to sign.
  2. The wallet signs the message, and the client sends it to POST /my/logins/siwe. OBP checks the signature, the domain, the chain and the nonce, and returns a token.

It is off unless allow_siwe=true. siwe.domain is the domain the message must name, which protects against phishing. siwe.allowed_chain_ids lists the chains accepted, for example 1 for mainnet. siwe.nonce.ttl is how long a challenge lasts, 300 seconds by default.