> ## Documentation Index
> Fetch the complete documentation index at: https://docs.fluz.app/llms.txt
> Use this file to discover all available pages before exploring further.

# generateUserAccessToken

> Generate a user token using 'Basic <API_KEY>'.

Generate a user token using 'Basic \<API\_KEY>'. The token will be associated with the user\_id and will have the specified scopes.

```graphql theme={null}
mutation {
  generateUserAccessToken(
    userId: UUID!
    accountId: UUID!
    scopes: [ScopeType!]!
    seatId: UUID
  ): GenerateUserAccessTokenResponse
}
```

## Arguments

<ParamField body="userId" type="UUID!" required>
  The userId that will be associated with the token.
</ParamField>

<ParamField body="accountId" type="UUID!" required>
  The accountId that will be associated with the token.
</ParamField>

<ParamField body="scopes" type="[ScopeType!]!" required>
  The scopes that the token will have access to.
</ParamField>

<ParamField body="seatId" type="UUID">
  The seatId will be used to make transactions, default to the most recently created if not provided.
</ParamField>

## Returns

[`GenerateUserAccessTokenResponse`](/api-reference/types/generate-user-access-token-response) — Represents the response returned from the generateUserAccessToken mutation.
