update contact payload for developer docs

This commit is contained in:
Tanmay Deep Sharma
2025-05-20 00:34:42 +07:00
parent ac94e34c72
commit 2b043e5460
7 changed files with 126 additions and 48 deletions
+1 -1
View File
@@ -16,7 +16,7 @@
"tabs": [
{
"tab": "API Documentation",
"openapi": "https://raw.githubusercontent.com/chatwoot/chatwoot/bde4833e4f866b1fc9dcdbcc14267351406069a3/swagger/swagger.json"
"openapi": "https://raw.githubusercontent.com/chatwoot/chatwoot/ac94e34c723731ef7f9caf839c2616bd96ef89c1/swagger/swagger.json"
}
]
},
@@ -11,12 +11,32 @@ responses:
content:
application/json:
schema:
type: array
description: Array of messages
items:
allOf:
- $ref: '#/components/schemas/generic_id'
- $ref: '#/components/schemas/message'
type: object
properties:
meta:
type: object
properties:
labels:
type: array
items:
type: string
additional_attributes:
type: object
contact:
$ref: '#/components/schemas/contact'
assignee:
$ref: '#/components/schemas/agent'
agent_last_seen_at:
type: string
format: date-time
assignee_last_seen_at:
type: string
format: date-time
payload:
type: array
description: Array of messages
items:
$ref: '#/components/schemas/message'
'404':
description: Conversation not found
content:
@@ -31,10 +31,13 @@ responses:
content:
application/json:
schema:
type: array
description: 'Array of all active agents'
items:
$ref: '#/components/schemas/agent'
type: object
properties:
payload:
type: array
description: 'Array of all active agents'
items:
$ref: '#/components/schemas/agent'
'404':
description: Inbox not found
content:
@@ -13,10 +13,13 @@ responses:
content:
application/json:
schema:
type: array
description: 'Array of all active agents'
items:
$ref: '#/components/schemas/agent'
type: object
properties:
payload:
type: array
description: 'Array of all active agents'
items:
$ref: '#/components/schemas/agent'
'404':
description: Inbox not found
content:
@@ -31,10 +31,13 @@ responses:
content:
application/json:
schema:
type: array
description: 'Array of all active agents'
items:
$ref: '#/components/schemas/agent'
type: object
properties:
payload:
type: array
description: 'Array of all active agents'
items:
$ref: '#/components/schemas/agent'
'404':
description: Inbox not found
content:
+7 -4
View File
@@ -14,10 +14,13 @@ get:
content:
application/json:
schema:
type: array
description: 'Array of inboxes'
items:
$ref: '#/components/schemas/inbox'
type: object
properties:
payload:
type: array
description: 'Array of inboxes'
items:
$ref: '#/components/schemas/inbox'
'404':
description: Inbox not found
content:
+71 -25
View File
@@ -5091,10 +5091,15 @@
"content": {
"application/json": {
"schema": {
"type": "array",
"description": "Array of inboxes",
"items": {
"$ref": "#/components/schemas/inbox"
"type": "object",
"properties": {
"payload": {
"type": "array",
"description": "Array of inboxes",
"items": {
"$ref": "#/components/schemas/inbox"
}
}
}
}
}
@@ -5496,10 +5501,15 @@
"content": {
"application/json": {
"schema": {
"type": "array",
"description": "Array of all active agents",
"items": {
"$ref": "#/components/schemas/agent"
"type": "object",
"properties": {
"payload": {
"type": "array",
"description": "Array of all active agents",
"items": {
"$ref": "#/components/schemas/agent"
}
}
}
}
}
@@ -5585,10 +5595,15 @@
"content": {
"application/json": {
"schema": {
"type": "array",
"description": "Array of all active agents",
"items": {
"$ref": "#/components/schemas/agent"
"type": "object",
"properties": {
"payload": {
"type": "array",
"description": "Array of all active agents",
"items": {
"$ref": "#/components/schemas/agent"
}
}
}
}
}
@@ -5677,10 +5692,15 @@
"content": {
"application/json": {
"schema": {
"type": "array",
"description": "Array of all active agents",
"items": {
"$ref": "#/components/schemas/agent"
"type": "object",
"properties": {
"payload": {
"type": "array",
"description": "Array of all active agents",
"items": {
"$ref": "#/components/schemas/agent"
}
}
}
}
}
@@ -5825,17 +5845,43 @@
"content": {
"application/json": {
"schema": {
"type": "array",
"description": "Array of messages",
"items": {
"allOf": [
{
"$ref": "#/components/schemas/generic_id"
},
{
"type": "object",
"properties": {
"meta": {
"type": "object",
"properties": {
"labels": {
"type": "array",
"items": {
"type": "string"
}
},
"additional_attributes": {
"type": "object"
},
"contact": {
"$ref": "#/components/schemas/contact"
},
"assignee": {
"$ref": "#/components/schemas/agent"
},
"agent_last_seen_at": {
"type": "string",
"format": "date-time"
},
"assignee_last_seen_at": {
"type": "string",
"format": "date-time"
}
}
},
"payload": {
"type": "array",
"description": "Array of messages",
"items": {
"$ref": "#/components/schemas/message"
}
]
}
}
}
}