feat: Finish adding all request payload examples

This commit is contained in:
Daniel Jimenez
2025-05-13 14:29:02 +12:00
parent c3f741bdda
commit 2c3a3bbbd2
31 changed files with 865 additions and 496 deletions
@@ -16,9 +16,11 @@ requestBody:
assignee_id:
type: number
description: Id of the assignee user
example: 1
team_id:
type: number
description: Id of the team. If the assignee_id is present, this param would be ignored
example: 1
responses:
'200':
description: Success
@@ -69,7 +69,7 @@ post:
- Conversations
operationId: newConversation
summary: Create New Conversation
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"
description: "Creating a conversation in chatwoot requires a source id. \n\n Learn more about source_id: https://www.chatwoot.com/hc/user-guide/articles/1677839703-how-to-create-an-api-channel-inbox#send-messages-to-the-api-channel"
security:
- userApiKey: []
- agentBotApiKey: []
@@ -78,70 +78,7 @@ post:
content:
application/json:
schema:
type: object
required:
- source_id
- inbox_id
properties:
source_id:
type: string
description: Conversation source id
inbox_id:
type: string
description: 'Id of inbox in which the conversation is created <br/> Allowed Inbox Types: Website, Phone, Api, Email '
contact_id:
type: string
description: Contact Id for which conversation is created
additional_attributes:
type: object
description: Lets you specify attributes like browser information
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,
}
status:
type: string
enum: ['open', 'resolved', 'pending']
description: Specify the conversation whether it's pending, open, closed
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
message:
type: object
description: The initial message to be sent to the conversation
required: ['content']
properties:
content:
type: string
description: The content of the message
template_params:
type: object
description: The template params for the message in case of whatsapp Channel
properties:
name:
type: string
description: Name of the template
example: 'sample_issue_resolution'
category:
type: string
description: Category of the template
example: UTILITY
language:
type: string
description: Language of the template
example: en_US
processed_params:
type: object
description: The processed param values for template variables in template
example:
1: 'Chatwoot'
$ref: '#/components/schemas/conversation_create_payload'
responses:
'200':
description: Success
@@ -19,6 +19,7 @@ requestBody:
type: string
enum: ['urgent', 'high', 'medium', 'low', 'none']
description: 'The priority of the conversation'
example: 'high'
responses:
'200':
description: Success
@@ -19,6 +19,7 @@ requestBody:
type: string
enum: ['open', 'resolved', 'pending']
description: The status of the conversation
example: open
responses:
'200':
description: Success
@@ -17,9 +17,11 @@ requestBody:
type: string
enum: ['urgent', 'high', 'medium', 'low', 'none']
description: 'The priority of the conversation'
example: 'high'
sla_policy_id:
type: number
description: 'The ID of the SLA policy (Available only in Enterprise edition)'
example: 1
responses:
'200':
description: Success
+1 -30
View File
@@ -13,36 +13,7 @@ post:
content:
application/json:
schema:
type: object
properties:
name:
type: string
description: The name of the inbox
avatar:
type: string
format: binary
description: File for avatar image
channel:
type: object
properties:
type:
type: string
enum: ['web_widget']
website_url:
type: string
description: URL at which the widget will be loaded
welcome_title:
type: string
description: Welcome title to be displayed on the widget
welcome_tagline:
type: string
description: Welcome tagline to be displayed on the widget
agent_away_message:
type: string
description: A message which will be sent if there is not agent available. This is not available if agentbot is connected
widget_color:
type: string
description: A Hex-color string used to customize the widget
$ref: '#/components/schemas/inbox_create_update_payload'
responses:
'200':
description: Success
@@ -16,13 +16,15 @@ requestBody:
- user_ids
properties:
inbox_id:
type: string
type: integer
description: The ID of the inbox
example: 1
user_ids:
type: array
items:
type: integer
description: IDs of users to be added to the inbox
example: [1, 2, 3]
responses:
'200':
description: Success
@@ -18,11 +18,13 @@ requestBody:
inbox_id:
type: string
description: The ID of the inbox
example: 1
user_ids:
type: array
items:
type: integer
description: IDs of users to be added to the inbox
example: [1, 2, 3]
responses:
'200':
description: Success
@@ -26,6 +26,7 @@ post:
agent_bot:
type: number
description: 'Agent bot ID'
example: 1
responses:
'204':
description: Success
+1 -32
View File
@@ -19,38 +19,7 @@ patch:
content:
application/json:
schema:
type: object
required:
- enable_auto_assignment
properties:
name:
type: string
description: The name of the inbox
enable_auto_assignment:
type: boolean
description: 'Enable Auto Assignment'
avatar:
type: string
format: binary
description: 'Image file for avatar'
channel:
type: object
properties:
website_url:
type: string
description: URL at which the widget will be loaded
welcome_title:
type: string
description: Welcome title to be displayed on the widget
welcome_tagline:
type: string
description: Welcome tagline to be displayed on the widget
agent_away_message:
type: string
description: A message which will be sent if there is not agent available. This is not available if agentbot is connected
widget_color:
type: string
description: A Hex-color string used to customize the widget
$ref: '#/components/schemas/inbox_create_update_payload'
responses:
'200':
description: Success
+3 -3
View File
@@ -1,8 +1,8 @@
tags:
- Help Center
operationId: update-new-portal-to-account
summary: update a new portal
description: update a new portal to account
operationId: update-portal-to-account
summary: Update a portal
description: Update a portal to account
security:
- userApiKey: []
requestBody:
@@ -19,6 +19,7 @@ requestBody:
items:
type: integer
description: IDs of users to be added to the team
example: [1, 2, 3]
responses:
'200':
description: Success
@@ -19,6 +19,7 @@ requestBody:
items:
type: integer
description: IDs of users to be added to the team
example: [1, 2, 3]
responses:
'200':
description: Success
@@ -11,6 +11,18 @@ parameters:
schema:
type: string
description: Typing status, either 'on' or 'off'
requestBody:
required: true
content:
application/json:
schema:
type: object
properties:
typing_status:
type: string
enum: ['on', 'off']
description: The typing status to set
example: 'on'
responses:
'200':
description: Typing status toggled successfully