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

# List inbox conversations

> List conversations for one owned number and channel. Read-only listing does not mark messages as read.

**FIXED · account** Inbox number discovery is account-wide. Filter threads by channel and number, and call history by number. `DELETE /v1/calls` purges calls and related recordings account-wide and reports sms\_deleted=0. For one customer verify each call ID, then use `DELETE /v1/calls/{id}`.

**NOT OFFERED → do this instead · number** A business\_number filter on campaign and opt-out reads does not establish tenant identity. Authorise the tenant and its number on your server. Keep that filter through SMS pagination. Bulk call deletion stays account-wide.

**YOU CAN CHANGE · account** Choose direction, source, outcome and period when supported. The number narrows a history read only. `direction` `all`, `inbound`, `outbound`, `web` · `source` `all`, `campaign`, `web`, `test`, `other` · `outcome` `all`, `successful`, `unsuccessful`, `unknown`, `failed` · `period` `all`, `today`, `week`, `month`.

**SCOPE · account** Keep the same filters with each server-issued cursor.

[Read the compact AI rules](https://docs.nixflex.com/ai-rules.md#inbox-history)

List conversations for one owned number and channel. Read-only listing does not mark messages as read.

Method: **GET** · Success: **200** · Scope: **Owning account**

**The important part**

* Keep the channel and number fixed while paging.
* A conversation summary is not the full message thread.

[Business guide](https://docs.nixflex.com/guides/business/agent-inbox.md) · [Developer guide](https://docs.nixflex.com/guides/developer/agent-inbox.md) · [Glossary](https://docs.nixflex.com/guides/glossary.md)

## Authentication

Send `Authorization: Bearer KEY_ID:KEY_SECRET` using the owning account’s server-side credential.

## Request fields

| Field | Type | Required | Default | Limits and meaning |
| - | - | - | - | - |
| `channel` (path) | string | Yes | None | Conversation channel. Allowed: `"sms"`, `"web"`. |
| `number` (path) | string | Yes | None | International number with + and digits; no spaces. Pattern: `^\+[1-9][0-9]{6,14}$`. |
| `archived` (query) | boolean | No | `false` | false selects unarchived conversations; true selects archived only. |
| `unread` (query) | boolean | No | `false` | true selects unread conversations; false includes both read and unread. |
| `search` (query) | string | No | `""` | Literal case-insensitive search across message text, thread key and visitor name/phone. Maximum 160 characters. |
| `since` (query) | string | No | Omitted | Only conversations whose last message is at or after this timestamp. Do not combine with period. Format: date-time. |
| `period` (query) | string | No | `"all"` | UTC calendar range: today, or the last N calendar dates including today; all has no time floor. Allowed: `"all"`, `"today"`, `"7"`, `"30"`, `"90"`. |
| `limit` (query) | integer | No | `30` | Conversation page size. Minimum 1. Maximum 100. |
| `offset` (query) | integer | No | `0` | Offset in the filtered list. Minimum 0. Maximum 10000. |

Do not send a request body.

Unknown query fields are refused. Boolean query values must be the literal strings true or false. period and since are mutually exclusive. Sort order is last\_at descending then thread\_key ascending. There is no cursor; continue by offset while needed, recognising that incoming messages can move rows between pages. archived\_new and unread\_total count conversations, not messages. Requests return Cache-Control: no-store.

## Response fields

`200 OK` returns the shape below. Nullable fields can be unknown or unset; do not turn null into zero or false.

| Field | Type | Meaning |
| - | - | - |
| `conversations` | array of object | Saved value. |
| `conversations[].thread_key` | string | Opaque thread key. |
| `conversations[].last_at` | string or null | Saved timestamp, or null. Format: date-time. |
| `conversations[].msg_count` | integer | Conversation message count. |
| `conversations[].unread_count` | integer | Unread incoming message count. |
| `conversations[].archived` | boolean | Archived state. |
| `conversations[].visits` | integer | Distinct visits, minimum one. |
| `conversations[].visitor_name` | string or null | Latest visitor name when present. |
| `conversations[].visitor_phone` | string or null | Latest visitor phone when present. |
| `conversations[].matched` | boolean | Whether this conversation matches the search. |
| `conversations[].last_message` | string or null | Latest message content. |
| `total` | integer | Filtered conversations across all pages. |
| `archived_new` | integer | Archived conversations with unread messages, regardless of the current filters. |
| `unread_total` | integer | Unarchived conversations with unread messages, regardless of current filters. |

## Example request

These examples require Node/CLI 0.11.0 or later, Python 0.4.0 or later and MCP 0.5.0 or later. Keep `NIXFLEX_API_KEY` private. cURL uses Bash; CLI uses PowerShell and reads the key through `NIXFLEX_API_KEY`. Replace fixture identifiers and reserved example numbers with approved account-owned values. Configure the existing MCP installation for the same account at `https://api.nixflex.com` before using the shown tool arguments. Python shows the synchronous client; `AsyncNixflex` uses the same method with `async with` and `await`.

```bash cURL theme={"dark"}
curl --request GET \
  --url "https://api.nixflex.com/v1/agent-inbox/web/%2B12025550123?archived=false&unread=true&search=one%20%2B%20two&period=7&limit=2&offset=0" \
  --header "Authorization: Bearer $NIXFLEX_API_KEY"
```

```javascript Node theme={"dark"}
import Nixflex from 'nixflex';

const c = new Nixflex({
  apiKey: process.env.NIXFLEX_API_KEY,
  baseUrl: 'https://api.nixflex.com',
  maxRetries: 0,
});
const result = await c.inbox.list("web", "+12025550123", {"archived": false, "unread": true, "search": "one + two", "period": "7", "limit": 2, "offset": 0});
```

```python Python theme={"dark"}
import os
from nixflex import Nixflex

with Nixflex(
    api_key=os.environ["NIXFLEX_API_KEY"],
    base_url="https://api.nixflex.com",
    max_retries=0,
) as c:
    result = c.inbox.list('web', '+12025550123', archived=False, unread=True, search='one + two', period='7', limit=2, offset=0)
```

```powershell CLI (PowerShell) theme={"dark"}
nixflex inbox list web '+12025550123' --archived false --unread true --search 'one + two' --period 7 --limit 2 --offset 0 --json --base-url "https://api.nixflex.com"
```

```json MCP theme={"dark"}
{
  "name": "list_inbox_conversations",
  "arguments": {
    "channel": "web",
    "number": "+12025550123",
    "archived": false,
    "unread": true,
    "search": "one + two",
    "period": "7",
    "limit": 2,
    "offset": 0
  }
}
```

## Example response

Illustrative `200` response. Identifiers and values are examples; some optional or compatibility fields are omitted.

```json Response theme={"dark"}
{
  "conversations": [],
  "total": 0,
  "archived_new": 0,
  "unread_total": 0
}
```

## Errors

Failures return an `error` object with `code`, `message`, `doc_url` and optional details. Each code links to the shared error catalog. Read the message and details before deciding whether to resend.

| Status | Code | Meaning | What to do |
| - | - | - | - |
| 400 | [`invalid_inbox_request`](https://docs.nixflex.com/api-reference/errors#invalid_inbox_request) | A path, query, body or settings value is invalid. | Correct the documented shape and limits. |
| 404 | [`inbox_not_found`](https://docs.nixflex.com/api-reference/errors#inbox_not_found) | The number or thread is unavailable to this account. | Check the number, thread and account state. |
| 503 | [`agent_inbox_disabled`](https://docs.nixflex.com/api-reference/errors#agent_inbox_disabled) | The inbox feature is disabled. | Wait for feature availability. |
| 503 | [`inbox_unavailable`](https://docs.nixflex.com/api-reference/errors#inbox_unavailable) | The inbox read or write could not be confirmed. | Retry reads with bounded backoff; reconcile writes first. |
| 401 | [`unauthorized`](https://docs.nixflex.com/api-reference/errors#unauthorized) | The credential is missing or invalid. | Check the full account credential. |
| 429 | [`rate_limit_exceeded`](https://docs.nixflex.com/api-reference/errors#rate_limit_exceeded) | The account request limit was reached. | Wait for Retry-After. Reconcile uncertain writes before resending. |

## Retry and idempotency

This is a read-only request. Retry transient connection or server failures with bounded backoff; respect Retry-After for 429. Do not retry validation or ownership errors unchanged. A later read can return newer state.

## Related endpoints

* [Check inbox availability](https://docs.nixflex.com/api-reference/agent-inbox/get-agent-inbox-features.md)
* [List inbox numbers](https://docs.nixflex.com/api-reference/agent-inbox/get-agent-inbox-numbers.md)
* [Errors and recovery](https://docs.nixflex.com/api-reference/errors.md#error-envelope)


## OpenAPI

````yaml api-reference/public.openapi.json GET /agent-inbox/{channel}/{number}
openapi: 3.1.0
info:
  title: Nixflex public API
  version: 1.0.0
  description: >-
    Nixflex API reference for agents, calls, messaging, knowledge, organisations
    and integrations. Authenticate with the owning account and follow each
    operation’s permissions, response and retry contract.
servers:
  - url: https://api.nixflex.com/v1
security:
  - bearerAuth: []
paths:
  /agent-inbox/{channel}/{number}:
    get:
      tags:
        - Agent inbox
      summary: List inbox conversations
      description: >-
        List conversations for one owned number and channel. Read-only listing
        does not mark messages as read. Unknown query fields are refused.
        Boolean query values must be the literal strings true or false. period
        and since are mutually exclusive. Sort order is last_at descending then
        thread_key ascending. There is no cursor; continue by offset while
        needed, recognising that incoming messages can move rows between pages.
        archived_new and unread_total count conversations, not messages.
        Requests return Cache-Control: no-store.
      operationId: get_agent_inbox_channel_number_
      parameters:
        - name: channel
          in: path
          required: true
          schema:
            type: string
            description: Conversation channel.
            enum:
              - sms
              - web
        - name: number
          in: path
          required: true
          schema:
            type: string
            description: International number with + and digits; no spaces.
            pattern: ^\+[1-9][0-9]{6,14}$
        - name: archived
          in: query
          required: false
          schema:
            type: boolean
            description: >-
              false selects unarchived conversations; true selects archived
              only.
            default: false
        - name: unread
          in: query
          required: false
          schema:
            type: boolean
            description: >-
              true selects unread conversations; false includes both read and
              unread.
            default: false
        - name: search
          in: query
          required: false
          schema:
            type: string
            description: >-
              Literal case-insensitive search across message text, thread key
              and visitor name/phone.
            default: ''
            maxLength: 160
        - name: since
          in: query
          required: false
          schema:
            type: string
            description: >-
              Only conversations whose last message is at or after this
              timestamp. Do not combine with period.
            format: date-time
        - name: period
          in: query
          required: false
          schema:
            type: string
            description: >-
              UTC calendar range: today, or the last N calendar dates including
              today; all has no time floor.
            enum:
              - all
              - today
              - '7'
              - '30'
              - '90'
            default: all
        - name: limit
          in: query
          required: false
          schema:
            type: integer
            description: Conversation page size.
            minimum: 1
            maximum: 100
            default: 30
        - name: offset
          in: query
          required: false
          schema:
            type: integer
            description: Offset in the filtered list.
            minimum: 0
            maximum: 10000
            default: 0
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                type: object
                properties:
                  conversations:
                    type: array
                    items:
                      type: object
                      properties:
                        thread_key:
                          type: string
                          description: Opaque thread key.
                        last_at:
                          type:
                            - string
                            - 'null'
                          description: Saved timestamp, or null.
                          format: date-time
                        msg_count:
                          type: integer
                          description: Conversation message count.
                        unread_count:
                          type: integer
                          description: Unread incoming message count.
                        archived:
                          type: boolean
                          description: Archived state.
                        visits:
                          type: integer
                          description: Distinct visits, minimum one.
                        visitor_name:
                          type:
                            - string
                            - 'null'
                          description: Latest visitor name when present.
                        visitor_phone:
                          type:
                            - string
                            - 'null'
                          description: Latest visitor phone when present.
                        matched:
                          type: boolean
                          description: Whether this conversation matches the search.
                        last_message:
                          type:
                            - string
                            - 'null'
                          description: Latest message content.
                      required:
                        - thread_key
                        - last_at
                        - msg_count
                        - unread_count
                        - archived
                        - visits
                        - visitor_name
                        - visitor_phone
                        - matched
                        - last_message
                      description: ''
                      additionalProperties: false
                    description: ''
                  total:
                    type: integer
                    description: Filtered conversations across all pages.
                  archived_new:
                    type: integer
                    description: >-
                      Archived conversations with unread messages, regardless of
                      the current filters.
                  unread_total:
                    type: integer
                    description: >-
                      Unarchived conversations with unread messages, regardless
                      of current filters.
                required:
                  - conversations
                  - total
                  - archived_new
                  - unread_total
                description: ''
                additionalProperties: false
              example:
                conversations: []
                total: 0
                archived_new: 0
                unread_total: 0
        '400':
          description: >-
            invalid_inbox_request: A path, query, body or settings value is
            invalid.
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                        description: Machine-readable error code.
                      message:
                        type: string
                        description: Explanation.
                      doc_url:
                        type: string
                        description: Error reference link.
                      details:
                        type: object
                        properties: {}
                        description: >-
                          Optional context; inspect campaign_id, status, outcome
                          and safe_to_retry for uncertain writes.
                        additionalProperties: true
                    required:
                      - code
                      - message
                      - doc_url
                      - type
                    description: ''
                    additionalProperties: false
                required:
                  - error
                description: ''
                additionalProperties: false
        '401':
          description: 'unauthorized: The credential is missing or invalid.'
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                        description: Machine-readable error code.
                      message:
                        type: string
                        description: Explanation.
                      doc_url:
                        type: string
                        description: Error reference link.
                      details:
                        type: object
                        properties: {}
                        description: >-
                          Optional context; inspect campaign_id, status, outcome
                          and safe_to_retry for uncertain writes.
                        additionalProperties: true
                    required:
                      - code
                      - message
                      - doc_url
                      - type
                    description: ''
                    additionalProperties: false
                required:
                  - error
                description: ''
                additionalProperties: false
        '404':
          description: >-
            inbox_not_found: The number or thread is unavailable to this
            account.
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                        description: Machine-readable error code.
                      message:
                        type: string
                        description: Explanation.
                      doc_url:
                        type: string
                        description: Error reference link.
                      details:
                        type: object
                        properties: {}
                        description: >-
                          Optional context; inspect campaign_id, status, outcome
                          and safe_to_retry for uncertain writes.
                        additionalProperties: true
                    required:
                      - code
                      - message
                      - doc_url
                      - type
                    description: ''
                    additionalProperties: false
                required:
                  - error
                description: ''
                additionalProperties: false
        '429':
          description: 'rate_limit_exceeded: The account request limit was reached.'
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                        description: Machine-readable error code.
                      message:
                        type: string
                        description: Explanation.
                      doc_url:
                        type: string
                        description: Error reference link.
                      details:
                        type: object
                        properties: {}
                        description: >-
                          Optional context; inspect campaign_id, status, outcome
                          and safe_to_retry for uncertain writes.
                        additionalProperties: true
                    required:
                      - code
                      - message
                      - doc_url
                      - type
                    description: ''
                    additionalProperties: false
                required:
                  - error
                description: ''
                additionalProperties: false
        '503':
          description: >-
            agent_inbox_disabled: The inbox feature is disabled.
            inbox_unavailable: The inbox read or write could not be confirmed.
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      code:
                        type: string
                        description: Machine-readable error code.
                      message:
                        type: string
                        description: Explanation.
                      doc_url:
                        type: string
                        description: Error reference link.
                      details:
                        type: object
                        properties: {}
                        description: >-
                          Optional context; inspect campaign_id, status, outcome
                          and safe_to_retry for uncertain writes.
                        additionalProperties: true
                    required:
                      - code
                      - message
                      - doc_url
                      - type
                    description: ''
                    additionalProperties: false
                required:
                  - error
                description: ''
                additionalProperties: false
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        KEY_ID:KEY_SECRET from the owning account. Keep it server-side. A
        verified personal dashboard Bearer session may be used where the
        operation documents role-based access.

````

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