Skip to content

M12 - Reply to a thread

Request

Description

Maximum of 1000 messages on a thread

Call Frequency
Maximum usage: Synchronous only - At each thread answer
Security
Shop-API-Key(Required scopes: ROLE_SHOP_ADMINROLE_PARTNER_OFFER_MESSAGE_WRITEROLE_PARTNER_MESSAGE_WRITE)
Path
thread_idstringrequired

The ID of the thread to reply to.

Query
shop_idinteger, (int64)

Use this parameter when your user has access to several shops. If not specified, the shop_id from your default shop will be used.

Bodymultipart/form-data
filesArray of strings, (binary)

List of attachments for the message
Maximum 50 across all threads of the same entity.
For example, for a given order, you can not have more than 50 attachments across all its threads.

message_inputobjectrequired

The message data

curl -i -X POST \
  https://your-instance.mirakl.net/api/inbox/threads/{thread_id}/message \
  -H 'Content-Type: multipart/form-data' \
  -F 'files=@path/to/file' \
  -F 'message_input="{\"body\":\"string\",\"to\":[{\"id\":\"string\",\"type\":\"OPERATOR\"}],\"topic\":{\"type\":\"FREE_TEXT\",\"value\":\"string\"}}";type=application/json'

Responses

Created

Bodyapplication/json
message_idstring

Id of the message

thread_idstring

Id of the thread

Response
{ "message_id": "873f1cb5-a7a2-4e07-8e0e-12eb64e93ece", "thread_id": "702c3e56-dcca-41e2-b6bd-72ba3fa809be" }