Authentication · Reads onchain state
Issues a one-time nonce to embed in a Sign-In with Ethereum message. The nonce binds the message the wallet is about to sign to this single authentication attempt, which is what makes a replayed signature worthless. It is step one of three: nonce, verify, refresh. Reach for it at the start of wallet authentication, put the value in the SIWE message, and send the signed result to the verify surface.
Send a request
Response
{data: {nonce: stringexpires_at: string}}
Code samples
Language
Prompt
Call the Plug API endpoint "Get nonce".## EndpointGET /auth/nonceBase URL: https://api.plug.to## DescriptionIssues a one-time nonce to embed in a Sign-In with Ethereum message.The nonce binds the message the wallet is about to sign to this single authentication attempt, which is what makes a replayed signature worthless. It is step one of three: nonce, verify, refresh.Reach for it at the start of wallet authentication, put the value in the SIWE message, and send the signed result to the verify surface.## Response Schema- data (object, required)- nonce (string, required) — One-time value to embed in the SIWE message before signing.- expires_at (string, required) — RFC 3339 timestamp after which the nonce is rejected.## Example RequestGET https://api.plug.to/auth/nonce