View Source ActivityPubClient.Chat (ActivityPubClient v0.1.1)

Requests to the chat API in Pleroma.

Reference: https://docs-develop.pleroma.social/backend/development/API/chats/

Link to this section Summary

Functions

Creates or gets an existing Chat for a certain recipient (identified by Account ID).

Link to this section Functions

Link to this function

get_chat(client, account_id)

View Source

Creates or gets an existing Chat for a certain recipient (identified by Account ID).

Use ActivityPubClient.Search.search/3 to get a recipent ID.

Link to this function

post_message(client, chat_id, content, media_id \\ nil)

View Source

Posts a message to a chat.

Expects a client, a chat_id returned by get_chat/2, the message content, and an optional media ID.