> For the complete documentation index, see [llms.txt](https://requestmechanic.gitbook.io/request-mechanic-api-documentation/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://requestmechanic.gitbook.io/request-mechanic-api-documentation/client/create-notification.md).

# Create Notification

Use the `POST /client/notifications/` endpoint to create a new notification by specifying the required details such as a header, body, and optionally an image. Notifications can be used to share important updates or messages with clients.

***

#### Parameters

| Name     | Type   | In   | Description                                                 | Required |
| -------- | ------ | ---- | ----------------------------------------------------------- | -------- |
| `header` | string | body | The title or header of the notification (1–255 characters). | Yes      |
| `body`   | string | body | The main content of the notification.                       | Yes      |
| `image`  | string | body | URL of the image to include in the notification (optional). | No       |

**Request Body Example:**

```json
{
  "header": "Maintenance Reminder",
  "body": "Your scheduled maintenance is due tomorrow. Please confirm.",
  "image": "https://example.com/notification-image.jpg"
}
```

***

#### Responses

**201 Created**

**Description:** The notification was successfully created.

**Example Response:**

```json
{
  "id": 101,
  "header": "Maintenance Reminder",
  "body": "Your scheduled maintenance is due tomorrow. Please confirm.",
  "image": "https://example.com/notification-image.jpg",
  "created_at": "2024-11-17T10:30:00Z",
  "created_by": "admin"
}
```
