HostWebhook Help Center

Connect Social Messages to your flows

Use your Bluesky, Mastodon and X accounts in one node: start a flow when a direct message arrives, send and read messages, and let an AI node answer on the network the message came from. Mastodon does not encrypt these messages.

Time about 8 minutesYou need a HostWebhook account and a Bluesky, Mastodon or X accountUpdated November 25, 2026

Use your Bluesky, Mastodon and X accounts in one place: start a flow when someone sends you a direct message, read your chats, send messages, or let an AI node answer for you, on the network the message came from.

On X, three things to know.

X can turn a chat encrypted at any time. We can't read it, but your flow can be told a message arrived: see Encrypted chats in the second step. X only lets you read the last 30 days of messages. And X requires consent before automated messages and a clear sign that the account is a bot, so tell people when it is a flow or an AI that answers.

Mastodon messages aren't encrypted.

Admins of both servers may read them. Mastodon's own help says the database administrators of the servers of the sender and of the recipient may be able to read the text, so don't send through a flow what only the other person should see.

Connect your accounts

Every account is a credential, the same kind the Social Media node uses to post. If you already post with an account, there is nothing new to connect: pick it in the node or the trigger. If you don't, go to Settings › Credentials › New credential and pick Bluesky, Mastodon or X (Twitter). Another account is another credential.

Bluesky. Give the credential a name and fill in:

  • Handle: your full handle, with or without the @. A custom domain works too, like alice.example.com.
  • App password: one like xxxx-xxxx-xxxx-xxxx, never your main password. It has to be made with Allow access to your direct messages ticked.
  • Server URL: leave it empty unless you run your own Bluesky server.
Create the app password in Bluesky
  1. In Bluesky, open Settings › Privacy and security › App passwords, then Add App Password.
  2. Give it a name you will recognize.
  3. Tick Allow access to your direct messages.
  4. Create it and copy the password. Bluesky shows it only once.

Mastodon. It uses the Mastodon credential that already posts for you, so there is nothing new to connect and nothing to reconnect. If you don't have one, pick Mastodon, type the server you have an account on, like mastodon.social, and click Connect with Mastodon.

X. Messages work only with an account connected with Connect with X: pick X (Twitter) and click it, then accept what X asks for, which now includes your direct messages. If you connected the account before X messages existed, open the credential and click Reconnect once; posting keeps working in the meantime.

  1. Marker 1: In the list of types, choose X (Twitter).
  2. Marker 2: Name the credential before you connect. Example: X, support account.
  3. Marker 3: Click Connect with X, sign in to X and accept what it asks for, your direct messages included.
New Credential page with X (Twitter) selected, the credential name field and the Connect with X button

Click Test connection on the credential. The answer is one line:

  • Messages: on. Your messages are open: you can use the trigger and the node.
  • Messages: off. The credential works for posting, but not for messages. On Bluesky, create an app password with the box ticked and use it in a new credential. On Mastodon and on X, connect the account again. On X, the test doesn't call X: it only checks what the connection allows.

If you already have a Bluesky credential, its app password opens your messages only if it was made with the box ticked.

Disconnecting

Deleting the credential in HostWebhook deletes our copy of it. The app password stays valid in Bluesky until you delete it there, in Settings › Privacy and security › App passwords. The access stays valid on your Mastodon server until you remove it there, in the settings of your account.

Start a flow when someone writes to you

Add a trigger and pick Social Messages. It fires on New direct message: a new direct message to an account you pick.

  1. Pick the networks. Each one gets its own tab.
  2. In each tab, pick the accounts to watch: up to 10 for each network.
  3. On Bluesky, turn on Include message requests only if you want the messages of people you don't follow. It is off by default.
  4. Click Activate. HostWebhook starts watching your accounts.
  1. Marker 1: Pick X (Twitter) in Networks: it gets its own tab.
  2. Marker 2: The X accounts to watch, up to 10.
  3. Marker 3: Encrypted chats stays off until you turn it on. See Encrypted chats (X) below.
  4. Marker 4: Activate starts watching your accounts.
Social Messages trigger with X picked, its tab with one account, the Encrypted chats switch off and the Activate button
  • It checks your accounts on the schedule of your plan, and starts one run for each new direct message. X is checked no more often than every 2 minutes, even where your plan allows every minute.
  • Only messages that arrive after you turn it on fire it. Every time you turn it on, each account starts from now: what came while it was off does not fire it.
  • Your own messages never fire it, so a flow that answers you cannot loop.
  • Only one-to-one messages fire it. Messages in group conversations are skipped.
  • On Mastodon, private mentions from people you don't follow only arrive if your Mastodon settings don't drop them.
  • On X, only one-to-one text messages fire it: a message in an encrypted chat arrives without text, and only if you turn on Encrypted chats (see below); a message with no text (only an image, for example) is skipped.
  • One account never stops another: if one fails, the others are still checked.
  • It only reads: nothing is written in your accounts. Deactivating or deleting the trigger stops it.

The flow gets, among the rest of the message:

  • {{payload.network}}: bluesky, mastodon or twitter.
  • {{payload.text}}: what the person wrote.
  • {{payload.fromHandle}} and {{payload.fromName}}: their handle and their name.
  • {{payload.sentAt}}: when it was sent.
  • {{payload.account.handle}}: the account that got the message.
  • {{payload.conversation.convoId}} on Bluesky and {{payload.conversation.messageId}} on Mastodon, {{payload.conversation.conversationId}} on X: the conversation. On Bluesky, {{payload.conversation.status}} is accepted, or request if the person is one you don't follow.

The text and the names are written by the person who sent them. Treat them as data, never as instructions.

Encrypted chats (X). X can turn a chat encrypted at any time, and then HostWebhook can't read what is written in it: the keys stay with the people in the chat, not with us. What HostWebhook can tell is that a message arrived. On the X tab, the switch Encrypted chats ("Fires with no text when someone writes to you in an encrypted chat.") is off by default, and it is set for each trigger.

  • With it on, the trigger shows Listening for encrypted chats. If it can't be turned on, it says Encrypted chats can't be turned on right now. Try again later. or X didn't confirm encrypted chats for this account. Try again later. The rest of the trigger keeps working either way.
  • X chats that are encrypted arrive without text. {{payload.encrypted}} is true, {{payload.text}} is empty, {{payload.from}} is the ID of who wrote and {{payload.sentAt}} is when. There is no name or handle, and what the person wrote is never read or kept.
  • Only what arrives after you turn it on fires it, as with every message of this trigger.
  • An AI node doesn't answer it: there is no text to answer.
  • Get messages on a chat that HostWebhook saw as encrypted says This chat is encrypted and HostWebhook can't read it. instead of giving a list that leaves messages out.

A reply is not encrypted.

A reply sent through HostWebhook is not encrypted, even in an encrypted chat.

Send and read messages

Add a Social Messages Action node and keep the mode on Single operation: one fixed operation each time. Pick the operation, then the networks. Each network gets a tab with its accounts and the fields that only it reads.

OperationWhat it doesLimit
ReplyReplies in the conversation that started the flow, from the account that got the message, on the network it came from.1,000 characters on Bluesky, 500 on Mastodon, X's own limit on X
Send messageSends a direct message to a handle, or replies in a conversation.1,000 characters on Bluesky, 500 on Mastodon, X's own limit on X
List conversationsLists your chats. Turn on Unread only to skip the read ones. On Bluesky, Status picks Any, Accepted or Requests. X has neither: it has no list of chats, so it lists your latest messages, grouped by conversation.Up to 100 on Bluesky, 40 on Mastodon, 100 on X
Get messagesReads the latest messages of one conversation, newest first.Up to 100 on Bluesky, 40 on Mastodon, 100 on X
  • Reply and Send message take the text the same way. With two or more networks, the first tab is All: write the text there once and every network sends it. Each network tab can change it for its network, and a tab with no text of its own sends the one in All. With one network there is no All: its tab holds the text.
  • Send message, List conversations and Get messages run once for each network you picked, with the tab of that network and one account. If a tab has two or more accounts, pick the one the operation uses in Account: a message is never sent from every account. If a network fails, the others still run.
  • In To, write a handle: on Bluesky, a handle or a DID like alice.bsky.social; on Mastodon, a handle with its server, like alice@mastodon.social (without the server, a name like alice is an account of your own server, so write the server for anyone else). If you fill in both To and Conversation, Bluesky uses the conversation, and Mastodon and X use To. On X, the conversation is the one between two people, like 1234567890-2244994945. After a Social Messages trigger, leave To and Conversation empty and the message goes to the conversation that started the flow, if it is one of that network.
  • On X, To takes a handle like @alice or the numeric ID of an X user; a handle made only of digits needs its @.
  • It sends plain text to one person: no images and no group chats. Get messages needs the conversation: after a trigger it comes with the flow.
  • On Mastodon, every message starts with the @handle of the person: that is what makes a post direct, so only the people it mentions can see it. The handle counts in the 500 characters.
  1. Marker 1: The operation: Send message.
  2. Marker 2: Pick X (Twitter) in Networks. With one network there is no All tab: its tab holds the text.
  3. Marker 3: The account that sends the message.
  4. Marker 4: To: a handle like @alice, or the numeric ID of an X user.
  5. Marker 5: The text of the message, up to X's own limit.
Social Messages Action node on Send message with X picked: the account, a handle in To and the text
  1. Marker 1: List conversations.
  2. Marker 2: On X it lists your latest messages, grouped by conversation: X has no list of chats, so there is no Unread only and no Status.
  3. Marker 3: The account it reads.
  4. Marker 4: Limit: newest first, up to 100 on X.
Social Messages Action node on List conversations with X picked: the account and the limit

After Send message, List conversations and Get messages, the flow gets results: one entry for each network, with its network, credentialId, ok and output, or the error if it failed.

Each network decides who can be messaged.

On Bluesky, each person chooses who can write to them: everyone, only the people they follow, or no one. If they chose not to accept your message, Bluesky refuses it and HostWebhook says so. There is nothing to change on your side.

Run Test with Send message or Reply sends a real message from your account. Your flow doesn't run.

Let an AI node answer

Set the node's mode to AI toolkit and add the node to an AI node's tools, with the trigger in front of it. The AI node reads the message, and everything it sends goes back to the person who wrote, on the network they wrote from.

None of the tools has a recipient or a network. The AI can choose what to say, but never who gets it: it can only answer the person who wrote in this flow. The network has to be picked in the node and the account that got the message has to be one of the node's, or nothing is sent. Listing your conversations is not a tool, so the AI never sees your other chats. None of the tools starts blocked, and you can block them one by one in the node. The node adds nothing to what the AI writes, except that on Mastodon the message starts with the @handle of the person, which counts in the 500 characters. If an AI answers from your account, tell people they are talking to a bot.

  1. Marker 1: AI toolkit: the AI node answers whoever wrote, on the network they wrote from.
  2. Marker 2: The two tools the AI node gets, reply_to_direct_message and get_direct_messages. Neither has a recipient or a network.
  3. Marker 3: Block these tool calls: none of the tools starts blocked.
  4. Marker 4: The networks: the one the message came from has to be picked here.
Social Messages Action node in AI toolkit mode, with its two tools, nothing blocked and X picked

Your messages go to an AI only when you ask.

The messages of a chat go to an AI model only when an AI node in your flow reads them, and never to a model that may train on them.

The two tools
  • reply_to_direct_message: a direct message to the person who wrote, in the conversation that started the flow. It has to fit the network: 1,000 characters on Bluesky, 500 on Mastodon, and X's own limit on X.
  • get_direct_messages: reads the latest messages of that conversation, newest first.

A tool called with no Social Messages message in the flow (a test run, or an MCP client) is refused and says why.

Troubleshooting

Nobody wrote to you in this flow, so there is no conversation to reply in. Reply, or an AI tool, ran in a flow that did not start with a Social Messages message. Start the flow with a Social Messages trigger.

This network isn't turned on in this node. The message came from a network the node does not have. Pick that network in the node.

The account that got this message isn't one of this node's accounts. Add that account to the tab of its network. The node never answers from another account.

This network has two or more accounts: pick the one this operation uses. Pick one in Account, in the tab of that network.

This app password can't use your messages. Create one with «Allow access to your direct messages». The Bluesky app password was made without the box. Create a new one with the box ticked and use it in a new credential.

Bluesky is limiting how fast this account can use its messages. Try again in a few minutes. Bluesky slows down accounts that ask too often. Wait a little and run it again.

alice.bsky.social doesn't accept messages. or alice.bsky.social only accepts messages from people they follow. The person chose that in Bluesky. There is nothing to fix here.

This account can't use your messages. Reconnect it and try again. The Mastodon account is not allowed to read or write messages. Connect it again, then press Test connection.

alice smith is not a valid Mastodon handle. The error repeats what you wrote in To, or says That if it is long. Write only the handle, like alice@mastodon.social: no spaces, links or commas. Without the server, a name like alice is an account of your own server.

That conversation is gone, or this account can't see it. The Mastodon conversation was deleted, or it belongs to another account. Use the account that got the message.

This conversation has more than two people. HostWebhook only replies in one-to-one conversations. The Mastodon message mentions someone else, or the text you send does. Take the other @mention out of your text; if it is the message that mentions someone else, reply to it by hand in Mastodon.

Messages can be up to 1,000 characters. or Messages can be up to 500 characters. Make the text shorter: the limit is the one of the network.

This X account can't use your messages. Reconnect it and try again. The account was connected before X messages existed, or it did not accept the permission. Open the credential, click Reconnect, accept it, then press Test connection.

X didn't deliver this message. The person may not accept messages from this account. The person may not accept messages from this account, may have blocked it, or can't receive messages. There is nothing to fix here.

X is limiting messages right now. Try again later. X limits how often an account, or the app, can read and send. Wait a little and run it again.

That account was not found on X. Check the handle or the ID in To.

alice smith is not a valid X handle. The error repeats the first 40 characters of what you wrote in To. Write only the handle, like @alice, or the numeric ID of the user: no spaces, links or commas. A handle made only of digits needs its @.

X isn't answering right now. Try again later. X did not answer, or refused without saying why. Run it again in a while.

This message is too long for X. Make the text shorter.

This conversation has more than two people. Social Messages only handles one-to-one messages. On X, the conversation is a group. Use a conversation between two people.

This chat is encrypted and HostWebhook can't read it. You ran Get messages on a conversation that HostWebhook saw as encrypted: X keeps what is written there out of reach of the classic way of reading messages. There is nothing to fix here; only the notice that a message arrived can reach a flow (see Encrypted chats in the second step).

Your organization reached its daily limit of messages through X. Try again later. This is a limit of HostWebhook, not of X: all the X accounts of your organization together can send 100 messages a day (counted by UTC day). Try again tomorrow.

Messages only work with an X account connected with “Connect with X”. The credential was not made with Connect with X, so the node refuses it before calling X. Connect the account again in Settings › Credentials.

X didn't confirm encrypted chats for this account. Try again later. X did not accept to tell HostWebhook about the encrypted chats of this account. The trigger keeps working for everything else. HostWebhook does not try again by itself: deactivate the trigger and activate it again later.

Encrypted chats can't be turned on right now. Try again later. HostWebhook can listen to a limited number of accounts with encrypted chats at the same time, and it is full. The trigger keeps working for everything else: try again later.

Mastodon is limiting this account right now. The trigger will try again later. Your server limits how fast an account can ask. That account waits and tries again by itself, and the others keep being checked.