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

# Send Test Notification

> This endpoint allows users to send a test notification on the account's enabled channels.

```http theme={null}
POST /api/v1/account/notifications/test
```

This endpoint sends a test notification to your account. Use it to check that a device or browser receives pushes.

The test notification uses only the master preference. Pacifica sends it on every channel that is on in [Set notification master preference](https://docs.pacifica.fi/api-documentation/api/rest-api/notifications/set-notification-master-preference.md). Type preferences don't apply.

| Field | Value |
| - | - |
| `"notification_type"` | `"test"` |
| `"title"` | `"Pacifica"` |
| `"body"` | `"Notifications are enabled."` |

Pacifica sends a `mobile_push` test to every active Expo token and a `web_push` test to every active Web Push subscription on the account. If `in_app` is on, the test also appears in [Get notification history](https://docs.pacifica.fi/api-documentation/api/rest-api/notifications/get-notification-history.md).

#### Operation Type (for Signing)

| Header Field | Type | Content |
| - | - | - |
| `"type"` | string | `"send_test_notification"` |

#### Request Body

<table><thead><tr><th width="176">Field</th><th width="98">Type</th><th width="95">Need</th><th>Description</th><th>Example</th></tr></thead><tbody><tr><td>`"account"`</td><td>string</td><td>required</td><td>User's wallet address</td><td>`42trU9A5...`</td></tr><tr><td>`"signature"`</td><td>string</td><td>required</td><td>Cryptographic signature</td><td>`5j1Vy9Uq...`</td></tr><tr><td>`"timestamp"`</td><td>integer</td><td>required</td><td>Current timestamp in milliseconds</td><td>`1716200000000`</td></tr><tr><td>`"expiry_window"`</td><td>integer</td><td>optional</td><td>Signature expiry in milliseconds</td><td>`30000`</td></tr><tr><td>`"agent_wallet"`</td><td>string</td><td>optional</td><td>Agent wallet address</td><td>`69trU9A5...`</td></tr></tbody></table>

```json theme={null}
{
  "account": "42trU9A5...",
  "signature": "5j1Vy9Uq...",
  "timestamp": 1716200000000,
  "expiry_window": 30000
}
```

You can sign this request with the account key or with an [agent wallet](https://docs.pacifica.fi/api-documentation/api/signing/api-agent-keys.md).

#### Signing

This request has no fields of its own. Sign an empty `data` object:

```json theme={null}
{"data":{},"expiry_window":30000,"timestamp":1716200000000,"type":"send_test_notification"}
```

#### Response

* Status 200: Test notification created

```json theme={null}
{
  "success": true,
  "data": {
    "outbox_id": 81235
  },
  "error": null,
  "code": null
}
```

<table><thead><tr><th width="208">Field</th><th width="186">Type</th><th>Description</th></tr></thead><tbody><tr><td>`"outbox_id"`</td><td>integer</td><td>ID of the test notification. It is the `id` in [Get notification history](https://docs.pacifica.fi/api-documentation/api/rest-api/notifications/get-notification-history.md) and the `notification_id` in a Web Push payload</td></tr></tbody></table>

A 200 response means that Pacifica created the notification. Delivery to each device happens after the response.

* Status 400: Invalid request parameters or signature
* Status 403: The account doesn't exist. An account exists after its first deposit
* Status 409: No channel is on in the master preference

```json theme={null}
{
  "success": false,
  "data": null,
  "error": "Notifications are disabled",
  "code": 409,
  "error_id": "notifications_disabled"
}
```

* Status 429: Rate limit exceeded
* Status 500: Internal server error

#### Code Example (Python)

```python theme={null}
import requests

payload = {
    "account": "42trU9A5...",
    "signature": "5j1Vy9Uq...",
    "timestamp": 1716200000000
}

response = requests.post(
    "/api/v1/account/notifications/test",
    json=payload,
    headers={"Content-Type": "application/json"}
)

data = response.json()
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.