API referenceDiscord
POST /discord/dms
A 1:1 DM from the bot to a user it shares a server with (by snowflake id; Discord answers 403 when the user accepts no DMs). Sent now, not stored; replies never arrive
POST
BearerAuthheader
AuthorizationBearer <token>API key sk_...
application/json- body
accountId*stringuserId*string15-21 digits
content?stringLength
length <= 2000embeds?array<>Items
items <= 10attachments?array<>Items
items <= 10tts?booleanDM sent
application/json- response
messageId?stringchannelId?stringDM channel id
url?stringtimestamp?stringFormat
date-timerecipient?account?curl -X POST 'https://example.com/api/v1/discord/dms' \ -H 'Content-Type: application/json' \ -d '{ "accountId": "string", "userId": "string"}'Example Response
{ "messageId": "string", "channelId": "string", "url": "string", "timestamp": "2019-08-24T14:15:22Z", "recipient": { "userId": "string", "platform": "string" }, "account": { "id": "string", "username": "string", "displayName": "string" }}