action x_send_dm { label: "Create DM message by participant ID" description: "Sends a new direct message to a specific participant by their ID." provider: x method: POST path: "/2/dm_conversations/with/{participant_id}/messages" encoding: json scopes: ["dm.write", "tweet.read", "users.read"] input: { type: "object" properties: { participant_id: { type: "string" description: "Unique identifier of this User. This is returned as a string in order to avoid complications with languages and tools that cannot handle large integers." } } required: ["participant_id"] additionalProperties: false } output: { type: "object" properties: { data: { type: "object" required: ["dm_conversation_id", "dm_event_id"] properties: { dm_conversation_id: { type: "string" description: "Unique identifier of a DM conversation. This can either be a numeric string, or a pair of numeric strings separated by a '-' character in the case of one-on-one DM Conversations." } dm_event_id: { type: "string" description: "Unique identifier of a DM Event." } } } errors: { type: "array" items: { type: "object" description: "An HTTP Problem Details object, as defined in IETF RFC 7807 (https://tools.ietf.org/html/rfc7807)." required: ["type", "title"] properties: { detail: { type: "string" } status: { type: "integer" } title: { type: "string" } type: { type: "string" } } } } } } }