Guides

Virtual orchestration

Value-add: send as a dispatchable group member (off by default; apply for access).

When to use

On an authorized bot, list dispatchable members with listChatVirtualMembers, then send text / photo / document / audio / video / location as that member via simulateSendMessage. Every call is audited.

Access

  • Admin must enable allow_virtual_user_operation on the bot.
  • The bot must be an active group member; the virtual member must be active and in the group.
  • Otherwise APIs return 403.

Steps

  1. GET /api/v1/bots/listChatVirtualMembers?chat_id=…virtual_user_id.
  2. For media, obtain file_id via the files guide.
  3. POST /api/v1/bots/simulateSendMessage with chat_id, virtual_user_id, and type-specific fields.

Example

curl -X POST "$API/bots/simulateSendMessage" \
  -H "Authorization: Bearer $SOCHAT_BOT_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
  "chat_id": "<chat_id>",
  "virtual_user_id": "<virtual_user_id>",
  "type": "text",
  "text": "Sent as a dispatchable member"
}'

Limits

  • Default type is text; media types need a valid file_id.
  • Both Node and Java SDKs wrap these methods.

Next

Orchestration API · Files · Chat read (getMyChats).