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

# generateWalletJwt

```ts theme={null}
function generateWalletJwt(options: WalletJwtOptions): Promise<string>;
```

Defined in: [utils/jwt.ts:187](https://github.com/coinbase/cdp-sdk/blob/59b6f4f714b6e359fb2390fa1df724c8c5419568/typescript/packages/cdp-sdk/src/auth/utils/jwt.ts#L187)

Generates a wallet authentication JWT for the given API endpoint URL.
Used for authenticating with specific endpoints that require wallet authentication.

## Parameters

### options

[`WalletJwtOptions`](/sdks/cdp-sdks-v2/typescript/auth/JWT/index#walletjwtoptions)

The configuration options for generating the JWT

## Returns

`Promise`\<`string`>

The generated JWT (Bearer token) string

## Throws

If the Wallet Secret is not defined.

## Throws

If the private key is not in the correct format or signing fails.
