2021-11-17 13:25:15 +00:00
parameters :
- $ref : '#/parameters/account_id'
2020-09-23 09:57:41 +00:00
get :
tags :
2022-04-05 10:35:49 +00:00
- Conversations
2021-11-17 13:25:15 +00:00
operationId : conversationList
description : List all the conversations with pagination
summary : Conversations List
2020-09-23 09:57:41 +00:00
parameters :
- name : assignee_type
in : query
type : string
2021-07-14 17:21:27 +00:00
enum : [ 'me' , 'unassigned' , 'all' , 'assigned' ]
2022-04-11 11:13:09 +00:00
default : 'all'
description : Filter conversations by assignee type.
2020-09-23 09:57:41 +00:00
- name : status
in : query
type : string
2022-04-11 11:13:09 +00:00
enum : [ 'open' , 'resolved' , 'pending' , 'snoozed' ]
default : 'open'
description : Filter by conversation status.
- name : q
2020-09-23 09:57:41 +00:00
in : query
2022-04-11 11:13:09 +00:00
type : string
description : Filters conversations with messages containing the search term
2020-09-23 09:57:41 +00:00
- name : inbox_id
in : query
type : integer
2022-04-11 11:13:09 +00:00
- name : team_id
in : query
type : integer
2020-09-23 09:57:41 +00:00
- name : labels
in : query
type : array
items :
type : string
2022-04-11 11:13:09 +00:00
- name : page
in : query
type : integer
default : 1
description : paginate through conversations
2022-06-14 05:05:56 +00:00
2020-09-23 09:57:41 +00:00
responses :
200 :
description : Success
schema :
$ref : '#/definitions/conversation_list'
400 :
description : Bad Request Error
schema :
$ref : '#/definitions/bad_request_error'
2020-04-10 11:12:37 +00:00
post :
tags :
2022-04-05 10:35:49 +00:00
- Conversations
2020-04-10 11:12:37 +00:00
operationId : newConversation
summary : Create New Conversation
2021-05-11 17:08:46 +00:00
description : "Creating a conversation in chatwoot requires a source id. \n\n Learn more about source_id: https://github.com/chatwoot/chatwoot/wiki/Building-on-Top-of-Chatwoot:-Importing-Existing-Contacts-and-Creating-Conversations"
2020-06-25 18:05:16 +00:00
security :
- userApiKey : [ ]
- agentBotApiKey : [ ]
2020-04-10 11:12:37 +00:00
parameters :
- name : data
in : body
required : true
schema :
type : object
properties :
2021-06-07 14:34:31 +00:00
source_id :
2021-11-17 13:25:15 +00:00
type : string
description : Conversation source id
2021-05-11 17:08:46 +00:00
inbox_id :
type : string
description : "Id of inbox in which the conversation is created <br/> Allowed Inbox Types: Website, Phone, Api, Email "
contact_id :
2020-04-10 11:12:37 +00:00
type : string
2021-05-11 17:08:46 +00:00
description : Contact Id for which conversation is created
2021-01-07 08:17:38 +00:00
additional_attributes :
type : object
description : Lets you specify attributes like browser information
2022-06-14 05:05:56 +00:00
custom_attributes :
type : object
description : The object to save custom attributes for conversation, accepts custom attributes key and value
example : { attribute_key: attribute_value, priority_conversation_number : 3 }
2021-06-07 14:34:31 +00:00
status :
type : string
2021-07-21 16:32:43 +00:00
enum : [ 'open' , 'resolved' , 'pending' ]
description : Specify the conversation whether it's pending, open, closed
2021-10-11 09:47:30 +00:00
assignee_id :
type : string
description : Agent Id for assigning a conversation to an agent
team_id :
type : string
description : Team Id for assigning a conversation to a team
2020-04-10 11:12:37 +00:00
responses :
200 :
description : Success
schema :
type : object
properties :
id :
type : number
description : ID of the conversation
account_id :
type : number
description : Account Id
inbox_id :
type : number
description : ID of the inbox
403 :
description : Access denied