> For the complete documentation index, see [llms.txt](https://docs.intents.aurora.dev/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.intents.aurora.dev/api-reference/confidential-swaps-api-reference/authenticate-user-with-signed-data.md).

# Authenticate user with signed data

## POST /api/auth/authenticate/{apiKey}

> Authenticate a user with signed data. Verifies the wallet signature and issues session tokens (access and refresh).

```json
{"openapi":"3.0.3","info":{"title":"@aurora-is-near/intents-fee-service","version":"1.0.0"},"servers":[{"url":"https://intents-api.aurora.dev"}],"security":[],"paths":{"/api/auth/authenticate/{apiKey}":{"post":{"tags":["auth"],"description":"Authenticate a user with signed data. Verifies the wallet signature and issues session tokens (access and refresh).","requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"signedData":{"anyOf":[{"type":"object","properties":{"standard":{"type":"string","enum":["nep413"],"description":"Message signing standard identifier."},"public_key":{"type":"string","description":"Base58-encoded Ed25519 public key (prefixed with `ed25519:`)."},"signature":{"type":"string","description":"Base58-encoded Ed25519 signature (prefixed with `ed25519:`)."},"payload":{"type":"object","properties":{"recipient":{"type":"string","description":"Intended recipient of the signed message."},"nonce":{"type":"string","description":"Base64-encoded nonce used for replay protection."},"message":{"type":"string","description":"Stringified JSON message that was signed, containing `deadline`, `signer_id`, and `intents`."},"callbackUrl":{"description":"Optional callback URL included in the signed payload.","nullable":true,"type":"string"}},"required":["recipient","nonce","message"],"description":"NEP-413 compliant payload that was signed."}},"required":["standard","public_key","signature","payload"]},{"type":"object","properties":{"standard":{"type":"string","enum":["erc191"],"description":"Message signing standard identifier."},"signature":{"type":"string","description":"Base58-encoded Secp256k1 signature (prefixed with `secp256k1:`). The public key is recovered from the signature via `ecrecover()`."},"payload":{"type":"string","description":"Stringified JSON ERC-191 message payload containing `signer_id`, `verifying_contract`, `nonce`, `deadline`, and `intents`."}},"required":["standard","signature","payload"]}],"description":"Signed message payload. Supports multiple signing standards (for example `nep413` and `erc191`), discriminated by the `standard` field."}},"required":["signedData"]}}},"required":true},"parameters":[{"schema":{"type":"string"},"in":"path","name":"apiKey","required":true,"description":"API key generated at [https://studio.aurora.dev](https://studio.aurora.dev)"}],"responses":{"200":{"description":"Signature verification succeeded; tokens issued","content":{"application/json":{"schema":{"type":"object","properties":{"accessToken":{"type":"string","description":"JWT access token for authenticated API calls."},"refreshToken":{"type":"string","description":"JWT refresh token used to obtain new access tokens."},"expiresIn":{"type":"number","description":"Access token lifetime in seconds."},"refreshExpiresIn":{"type":"number","description":"Refresh token lifetime in seconds."}},"required":["accessToken","refreshToken","expiresIn","refreshExpiresIn"],"additionalProperties":false,"description":"Signature verification succeeded; tokens issued"}}}},"400":{"description":"Default Response","content":{"application/json":{"schema":{"anyOf":[{"type":"object","properties":{"message":{"type":"string","description":"Error message returned by the upstream quote API."},"correlationId":{"type":"string","description":"Unique identifier for request tracing and debugging."},"timestamp":{"type":"string","description":"Timestamp in ISO format when the error response was generated."},"path":{"type":"string","description":"API path associated with the failed request."}},"required":["message","correlationId","timestamp","path"],"additionalProperties":false,"description":"Invalid signed data structure or encoding"},{"type":"object","properties":{"message":{"type":"string"},"error":{"type":"string"},"data":{"type":"object","additionalProperties":{}},"statusCode":{"type":"number"}},"required":["message","statusCode"],"additionalProperties":false}]}}}},"401":{"description":"Signature verification failed","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"error":{"type":"string"},"data":{"type":"object","additionalProperties":{}},"statusCode":{"type":"number","enum":[401]}},"required":["message","statusCode"],"additionalProperties":false,"description":"Signature verification failed"}}}},"500":{"description":"Internal Server Error - Failed to reach the auth service","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"},"error":{"type":"string"},"data":{"type":"object","additionalProperties":{}},"statusCode":{"type":"number","enum":[500]}},"required":["message","statusCode"],"additionalProperties":false,"description":"Internal Server Error - Failed to reach the auth service"}}}}}}}}}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.intents.aurora.dev/api-reference/confidential-swaps-api-reference/authenticate-user-with-signed-data.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
