> For the complete documentation index, see [llms.txt](https://help.botpenguin.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://help.botpenguin.com/api-documentation/contacts-and-chats-apis/put-update-user-status.md).

# PUT — Update User Status

### Overview

| Property          | Details                                                   |
| ----------------- | --------------------------------------------------------- |
| **Method**        | `PUT`                                                     |
| **Endpoint**      | `https://api.v7.botpenguin.com/inbox/users/status-update` |
| **Base URL**      | `https://api.v7.botpenguin.com`                           |
| **API Version**   | v7                                                        |
| **Auth Required** | Yes — Bearer Token                                        |
| **Content-Type**  | `application/json`                                        |

***

### Authentication

| Header          | Required | Value                   |
| --------------- | -------- | ----------------------- |
| `Authorization` | ✅ Yes    | `Bearer [MASKED_TOKEN]` |
| `authtype`      | ✅ Yes    | `Key`                   |

***

### How to Get a User ID

User IDs are found in the BotPenguin Inbox:

1. Go to Inbox in your BotPenguin dashboard.
2. Open the contact whose ID you need.
3. Click the three-dot menu (⋮) on the contact.
4. Select Copy User ID.

{% hint style="warning" icon="triangle-exclamation" %}
**Note:** `subscriberIds` is not supported by this endpoint. Pass User IDs only in the `ids` field.
{% endhint %}

***

### Request

#### Headers

| Header          | Required | Value                   |
| --------------- | -------- | ----------------------- |
| `Authorization` | ✅ Yes    | `Bearer [MASKED_TOKEN]` |
| `authtype`      | ✅ Yes    | `Key`                   |
| `Content-Type`  | ✅ Yes    | `application/json`      |

***

#### Request Body

```json
{
  "ids": ["640f472d173951357f08edee"],
  "status": "DELETED"
}
```

**Body Fields**

| Field    | Type     | Required | Description                                                                               |
| -------- | -------- | -------- | ----------------------------------------------------------------------------------------- |
| `ids`    | `array`  | ✅ Yes    | Array of User IDs to update. Obtain from Inbox → contact → three-dot menu → Copy User ID. |
| `status` | `string` | ✅ Yes    | New status to apply. Accepted value: `DELETED`.                                           |

***

#### Example Request

```bash
curl 'https://api.v7.botpenguin.com/inbox/users/status-update' \
  -X PUT \
  -H 'Authorization: Bearer [MASKED_TOKEN]' \
  -H 'authtype: Key' \
  -H 'Content-Type: application/json' \
  --data-raw '{
    "ids": ["640f472d173951357f08edee"],
    "status": "DELETED"
  }'
```

***

### Response

#### Success — `200 OK`

```json
{
  "success": true,
  "message": "",
  "code": 200
}
```

**Response Fields**

| Field     | Type      | Description                                           |
| --------- | --------- | ----------------------------------------------------- |
| `success` | `boolean` | `true` if the status update was applied successfully. |
| `message` | `string`  | Status message. Empty string on success.              |
| `code`    | `number`  | HTTP status code echo. `200` on success.              |

***

### HTTP Status Codes

| Code  | Status                | Meaning                                                |
| ----- | --------------------- | ------------------------------------------------------ |
| `200` | OK                    | Status updated successfully.                           |
| `400` | Bad Request           | Malformed request body or missing required fields.     |
| `401` | Unauthorized          | Bearer token is missing, invalid, or expired.          |
| `404` | Not Found             | One or more User IDs not found.                        |
| `429` | Too Many Requests     | Rate limit exceeded. Retry after the indicated window. |
| `500` | Internal Server Error | Server-side error. Contact support if it persists.     |

***

### Error Handling

All errors return a consistent structure:

```json
{
  "success": false,
  "error": {
    "code": "UNAUTHORIZED",
    "message": "Bearer token is invalid or has expired.",
    "statusCode": 401
  }
}
```

***

### Rate Limits

This endpoint is limited to **100 requests per minute** per token, across all plans. Exceeding this returns `429 Too Many Requests`. Use the `Retry-After` response header (in seconds) to schedule your retry.

***

*For questions or issues, contact* [*support@botpenguin.com*](mailto:support@botpenguin.com)


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://help.botpenguin.com/api-documentation/contacts-and-chats-apis/put-update-user-status.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
