Skip to content

M11 - List all threads

Request

Description

You may want to retrieve the threads linked to a specific entity, using both entity_type and entity_id.
For example, to retrieve threads for an order, use entity_type=MMP_ORDER&entity_id=my-order-1.
Available values for entity_type are:

  • MMP_ORDER: for threads on product orders
  • MMP_OFFER: for threads on offers
  • MPS_ORDER: for threads on service orders
  • MPS_SERVICE: for threads on services
  • SELLER_OPERATOR: for threads between sellers and operator

This resource uses seek pagination. The default value for parameter limit is 50.

Call Frequency
Maximum usage: Synchronous only - At each page that includes an inbox display
Pagination

This resource supports seek pagination (see documentation)

Security
Shop-API-Key(Required scopes: ROLE_SHOP_ADMINROLE_PARTNER_OFFER_MESSAGE_READROLE_PARTNER_MESSAGE_READ)
Query
entity_typestring

Entity type to include in result (default: include all).
Available values: MMP_ORDER, MMP_OFFER, MPS_ORDER, MPS_SERVICE, SELLER_OPERATOR

entity_idArray of strings

Comma separated list of Entity id to include in result (default: include all).
The entity_type must be specified to use this filter, otherwise an error 400 will be returned.
Example of an entity_id query: entity_id=order1-A,order20-A,order13-A&entity_type=MMP_ORDER

updated_sincestring, (date-time)

Retrieve threads modified at or after this date.

with_messagesboolean

True to include message details. Limited to the last 100 messages received on each thread.

Default:false
channel_codesArray of strings, unique

List of the channel codes to filter with, using a comma (,) as a separator.
If specified, only order messages linked to the given channels will be returned (Whatever the value of entity_type).
Otherwise, messages will be returned regardless of their channels.

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.

curl -i -X GET \
  'https://your-instance.mirakl.net/api/inbox/threads?entity_type=string&entity_id=string&updated_since=2019-08-24T14%3A15%3A22Z&with_messages=false&channel_codes=string&shop_id=0' \
  -H 'Authorization: YOUR_API_KEY_HERE'

Responses

OK

Bodyapplication/json
dataArray of objectsrequired

Page of data

next_page_tokenstring

Token to access the next page. Absent if the current page is the last one.

previous_page_tokenstring

Token to access the previous page. Absent if the current page is the first one.

Response
{ "data": [ { … } ], "next_page_token": "bGltaXQ9NTAmYWZ0ZXI9MjA3NjYwNTAtZDc5Yy00YzUyLWEwODctZWI5YjY1MjFkNzA5JnNvcnQ9ZGF0ZSxERVND.jFoPX_GjfbaRV88hhNxWWEzeRSqPt1WNExsrcBTkuSY=" }