> **Can't find what you're looking for?** Use `search_docs` on the docs MCP server at `https://docs.prividium.com/api/mcp` to find what you need.
>
> **Have feedback?** Use `submit_feedback` on the same MCP server.

# wallet

## GET /wallet/personal-rpc-token

`GET /wallet/personal-rpc-token`

Get the Per-User RPC token for the authenticated user

### Responses

#### `200`: Default Response

Body (`application/json`):

- `token` `string <base64url>` _(required)_

#### `401`: Default Response

Body (`application/json`):

- `error` `object` _(required)_
  - `code` `string` _(required)_
  - `message` `string` _(required)_
  - `issues` `unknown[]`

#### `403`: Default Response

Body (`application/json`):

- `error` `object` _(required)_
  - `code` `string` _(required)_
  - `message` `string` _(required)_
  - `issues` `unknown[]`

### Example request

```bash
curl /api/wallet/personal-rpc-token
```

```ts
fetch('/api/wallet/personal-rpc-token')
```

## POST /wallet/invalidate

`POST /wallet/invalidate`

Invalidate current RPC token and generate a new one

### Responses

#### `200`: Default Response

Body (`application/json`):

- `newWalletToken` `string <base64url>` _(required)_
- `message` `string` _(required)_

#### `400`: Default Response

Body (`application/json`):

- `error` `object` _(required)_
  - `code` `string` _(required)_
  - `message` `string` _(required)_
  - `issues` `unknown[]`

#### `401`: Default Response

Body (`application/json`):

- `error` `object` _(required)_
  - `code` `string` _(required)_
  - `message` `string` _(required)_
  - `issues` `unknown[]`

### Example request

```bash
curl /api/wallet/invalidate \
  --request POST
```

```ts
fetch('/api/wallet/invalidate', {
  method: 'POST'
})
```

## POST /wallet/enable

`POST /wallet/enable`

> **Deprecated**

Enable RPC for a specific transaction with calldata and nonce for 1 hour

### Request body (required) (`application/json`)

- `calldata` `string` _(required)_
- `nonce` `integer` _(required)_
- `walletAddress` `string` _(required)_
- `contractAddress` `string` _(required)_

### Responses

#### `200`: Default Response

Body (`application/json`):

- `message` `string` _(required)_
- `activeUntil` `string` _(required)_

#### `400`: Default Response

Body (`application/json`):

- `error` `object` _(required)_
  - `code` `string` _(required)_
  - `message` `string` _(required)_
  - `issues` `unknown[]`

#### `401`: Default Response

Body (`application/json`):

- `error` `object` _(required)_
  - `code` `string` _(required)_
  - `message` `string` _(required)_
  - `issues` `unknown[]`

#### `403`: Default Response

Body (`application/json`):

- `error` `object` _(required)_
  - `code` `string` _(required)_
  - `message` `string` _(required)_
  - `issues` `unknown[]`

### Example request

```bash
curl /api/wallet/enable \
  --request POST \
  --header 'Content-Type: application/json' \
  --data '{
  "calldata": "string",
  "nonce": 0,
  "walletAddress": "string",
  "contractAddress": "string"
}'
```

```ts
fetch('/api/wallet/enable', {
  method: 'POST',
  headers: {
    'Content-Type': 'application/json'
  },
  body: JSON.stringify({
    calldata: 'string',
    nonce: 0,
    walletAddress: 'string',
    contractAddress: 'string'
  })
})
```

## POST /wallet/transaction-authorization

`POST /wallet/transaction-authorization`

Enable RPC for a specific transaction for 1 hour

### Request body (required) (`application/json`)

- `walletAddress` `string` _(required)_
- `nonce` `integer` _(required)_
- `toAddress` `string` _(required)_
- `calldata` `string`
- `value` `string`

### Responses

#### `200`: Default Response

Body (`application/json`):

- `message` `string` _(required)_
- `activeUntil` `string` _(required)_

#### `400`: Default Response

Body (`application/json`):

- `error` `object` _(required)_
  - `code` `string` _(required)_
  - `message` `string` _(required)_
  - `issues` `unknown[]`

#### `401`: Default Response

Body (`application/json`):

- `error` `object` _(required)_
  - `code` `string` _(required)_
  - `message` `string` _(required)_
  - `issues` `unknown[]`

#### `403`: Default Response

Body (`application/json`):

- `error` `object` _(required)_
  - `code` `string` _(required)_
  - `message` `string` _(required)_
  - `issues` `unknown[]`

### Example request

```bash
curl /api/wallet/transaction-authorization \
  --request POST \
  --header 'Content-Type: application/json' \
  --data '{
  "walletAddress": "string",
  "nonce": 0,
  "toAddress": "string",
  "calldata": "string",
  "value": "string"
}'
```

```ts
fetch('/api/wallet/transaction-authorization', {
  method: 'POST',
  headers: {
    'Content-Type': 'application/json'
  },
  body: JSON.stringify({
    walletAddress: 'string',
    nonce: 0,
    toAddress: 'string',
    calldata: 'string',
    value: 'string'
  })
})
```

## GET /wallet-actions/allowance-tx-hash

`GET /wallet-actions/allowance-tx-hash`

Returns tx hash if it was already registered

### Responses

#### `200`: Default Response

Body (`application/json`):

- `txHash` `string` _(required)_

#### `401`: Default Response

Body (`application/json`):

- `error` `object` _(required)_
  - `code` `string` _(required)_
  - `message` `string` _(required)_
  - `issues` `unknown[]`

#### `403`: Default Response

Body (`application/json`):

- `error` `object` _(required)_
  - `code` `string` _(required)_
  - `message` `string` _(required)_
  - `issues` `unknown[]`

#### `404`: Default Response

Body (`application/json`):

- `error` `object` _(required)_
  - `code` `string` _(required)_
  - `message` `string` _(required)_
  - `issues` `unknown[]`

### Example request

```bash
curl /api/wallet-actions/allowance-tx-hash
```

```ts
fetch('/api/wallet-actions/allowance-tx-hash')
```

## POST /wallet-actions/verify-allowance

`POST /wallet-actions/verify-allowance`

Checks if the current token can perform a certain transaction

### Request body (required) (`application/json`)

- `nonce` `number` _(required)_
- `from` `string` _(required)_
- `to` `string` _(required)_
- `calldata` `string` _(required)_
- `value` `unknown` _(required)_

### Responses

#### `200`: Default Response

Body (`application/json`):

- `authorized` `boolean` _(required)_

#### `400`: Default Response

Body (`application/json`):

- `error` `object` _(required)_
  - `code` `string` _(required)_
  - `message` `string` _(required)_
  - `issues` `unknown[]`

#### `401`: Default Response

Body (`application/json`):

- `error` `object` _(required)_
  - `code` `string` _(required)_
  - `message` `string` _(required)_
  - `issues` `unknown[]`

#### `403`: Default Response

Body (`application/json`):

- `error` `object` _(required)_
  - `code` `string` _(required)_
  - `message` `string` _(required)_
  - `issues` `unknown[]`

### Example request

```bash
curl /api/wallet-actions/verify-allowance \
  --request POST \
  --header 'Content-Type: application/json' \
  --data '{
  "nonce": 0,
  "from": "string",
  "to": "string",
  "calldata": "string"
}'
```

```ts
fetch('/api/wallet-actions/verify-allowance', {
  method: 'POST',
  headers: {
    'Content-Type': 'application/json'
  },
  body: JSON.stringify({
    nonce: 0,
    from: 'string',
    to: 'string',
    calldata: 'string'
  })
})
```

## POST /wallet-actions/can-check-balance

`POST /wallet-actions/can-check-balance`

Verifies current given address is the sender in the allowance

### Request body (required) (`application/json`)

- `address` `string` _(required)_

### Responses

#### `200`: Default Response

Body (`application/json`):

- `authorized` `boolean` _(required)_

#### `400`: Default Response

Body (`application/json`):

- `error` `object` _(required)_
  - `code` `string` _(required)_
  - `message` `string` _(required)_
  - `issues` `unknown[]`

#### `401`: Default Response

Body (`application/json`):

- `error` `object` _(required)_
  - `code` `string` _(required)_
  - `message` `string` _(required)_
  - `issues` `unknown[]`

#### `403`: Default Response

Body (`application/json`):

- `error` `object` _(required)_
  - `code` `string` _(required)_
  - `message` `string` _(required)_
  - `issues` `unknown[]`

### Example request

```bash
curl /api/wallet-actions/can-check-balance \
  --request POST \
  --header 'Content-Type: application/json' \
  --data '{
  "address": "string"
}'
```

```ts
fetch('/api/wallet-actions/can-check-balance', {
  method: 'POST',
  headers: {
    'Content-Type': 'application/json'
  },
  body: JSON.stringify({
    address: 'string'
  })
})
```

## POST /wallet-actions/update-transaction-hash

`POST /wallet-actions/update-transaction-hash`

Update the transaction hash for an allowance (no JWT required)

### Request body (required) (`application/json`)

- `rawTx` `string` _(required)_

### Responses

#### `200`: Default Response

Body (`application/json`):

- `hash` `string` _(required)_

#### `400`: Default Response

Body (`application/json`):

- `error` `object` _(required)_
  - `code` `string` _(required)_
  - `message` `string` _(required)_
  - `issues` `unknown[]`

#### `401`: Default Response

Body (`application/json`):

- `error` `object` _(required)_
  - `code` `string` _(required)_
  - `message` `string` _(required)_
  - `issues` `unknown[]`

### Example request

```bash
curl /api/wallet-actions/update-transaction-hash \
  --request POST \
  --header 'Content-Type: application/json' \
  --data '{
  "rawTx": "string"
}'
```

```ts
fetch('/api/wallet-actions/update-transaction-hash', {
  method: 'POST',
  headers: {
    'Content-Type': 'application/json'
  },
  body: JSON.stringify({
    rawTx: 'string'
  })
})
```
