# Customer support over X direct messages

> Read your X inbox and conversations, answer customers by DM, and catch public questions with mention search. Works with encrypted X Chat. $0.065 to $0.10 per 1,000 calls.

HTML page: https://www.twittrapi.com/use-cases/dm-support

Solutions · Customer support

Bring your X inbox into your helpdesk: read conversations, answer customers by DM, and pick up public questions from mentions. Each action is one call, the same price as a read: $0.065 to $0.10 per 1,000.

[Get an API key](https://www.twittrapi.com/start) [Direct message endpoints →](https://www.twittrapi.com/docs/account-actions#direct-messages)

Works with encrypted X Chat: send the account's X Chat passcode with the request. [X session guide](https://www.twittrapi.com/docs/x-session)

Direct messages

## Read and answer the inbox

Each line is one endpoint and one call.

- List conversations, with the latest messages

  /client/dm/inbox

  [Without the passcode: participants and settings only](https://www.twittrapi.com/docs/account-actions/client-dm-inbox)
- Read one conversation

  /client/dm/conversation

  [Newest first, with a cursor for older messages](https://www.twittrapi.com/docs/account-actions/client-dm-conversation)
- Reply to the customer

  /client/dm/send

  [Text up to 10,000 characters](https://www.twittrapi.com/docs/account-actions/client-dm-send)
- Check who can message you

  /client/dm/settings

  [Read receipts and call settings too; change them with the update call](https://www.twittrapi.com/docs/account-actions/client-dm-settings)

Public questions

## Catch questions asked in public

Many customers ask in a reply or a mention instead of a DM. Pick those up too and answer where they asked.

1. 01

  Find the mentions

  Search for your handle with [/search](https://www.twittrapi.com/docs/reference/search) on a schedule, or watch accounts with [account monitoring](https://www.twittrapi.com/docs/monitoring) and get new tweets by webhook.
2. 02

  Route them to your team

  Create a ticket per mention in your helpdesk, the same way as for DMs.
3. 03

  Answer in public or move to DMs

  Reply with [/client/reply](https://www.twittrapi.com/docs/account-actions/client-reply), or ask the customer to send you a DM when you need an order number or other private details.

How it works

## What each request carries

Every call is a POST with the support account's session cookie (`auth_token`, `ct0` and `twid`), a proxy and, to read or send messages, the X Chat passcode.

- Messages are decrypted and encrypted on our server while your request runs; the API does not store messages or the passcode.
- The same wrong passcode is never sent to X twice, and the API stops trying when only a few attempts are left.
- With `format=simple` messages come back as flat objects with sender, time, text and attachments.

[Direct message endpoints](https://www.twittrapi.com/docs/account-actions#direct-messages)

Use your own account or one you're authorised to manage, and follow [X's rules on automation](https://help.x.com/en/rules-and-policies/x-automation).

FAQ

## Support over DMs questions

**Why do I need the X Chat passcode?**

Direct messages on X are end-to-end encrypted (X Chat). The passcode unlocks the account's chat keys so messages can be decrypted and encrypted while your request runs. It is not stored. Listing conversations and reading settings work without it.

**Can I send images in a DM?**

No, sending is text only for now. Incoming attachments are listed in the message.

**Can I message people who never wrote to us?**

This page is about answering customers. The first message to someone starts an encrypted conversation and needs X Chat on their account, and X's rules apply: no unsolicited bulk messages.

**How do I catch new messages?**

Poll the inbox on a schedule that fits your response time, and keep the newest message ID per conversation so each message is handled once.

**Which account does this act on?**

The one whose X session (cookie) you send: your brand's support account, or a client's account you manage with their consent.

Related

## Read next

- [Direct messages → Inbox, conversations, send, settings /docs/account-actions#direct-messages](https://www.twittrapi.com/docs/account-actions#direct-messages)
- [X session guide → Cookie and proxy /docs/x-session](https://www.twittrapi.com/docs/x-session)
- [Account monitoring → New tweets by webhook /docs/monitoring](https://www.twittrapi.com/docs/monitoring)
- [Social listening → Mention searches /use-cases/social-listening](https://www.twittrapi.com/use-cases/social-listening)
- [AI agents that post → Draft answers with an agent, approve them /use-cases/agents-that-post](https://www.twittrapi.com/use-cases/agents-that-post)

## Answer your first customer by API

Get a key, copy your support account's X session, and read the inbox. New accounts start with $0.50 free credit.

[Get an API key](https://www.twittrapi.com/start) [Direct message endpoints →](https://www.twittrapi.com/docs/account-actions#direct-messages)
