feat: Update swagger to openapi 3.0.4, update request payloads with examples (#11374)
This commit is contained in:
14
swagger/definitions/resource/account_user.yml
Normal file
14
swagger/definitions/resource/account_user.yml
Normal file
@@ -0,0 +1,14 @@
|
||||
type: array
|
||||
description: 'Array of account users'
|
||||
items:
|
||||
type: object
|
||||
properties:
|
||||
account_id:
|
||||
type: integer
|
||||
description: The ID of the account
|
||||
user_id:
|
||||
type: integer
|
||||
description: The ID of the user
|
||||
role:
|
||||
type: string
|
||||
description: whether user is an administrator or agent
|
||||
@@ -19,14 +19,13 @@ properties:
|
||||
enum: ['agent', 'administrator']
|
||||
confirmed:
|
||||
type: boolean
|
||||
availability_status:
|
||||
availability_status:
|
||||
type: string
|
||||
enum: ['available', 'busy', 'offline']
|
||||
description: The availability status of the agent computed by Chatwoot.
|
||||
auto_offline:
|
||||
type: boolean
|
||||
description: Whether the availability status of agent is configured to go offline automatically when away.
|
||||
custom_attributes:
|
||||
custom_attributes:
|
||||
type: object
|
||||
description: Available for users who are created through platform APIs and has custom attributes associated.
|
||||
|
||||
|
||||
@@ -24,8 +24,9 @@ properties:
|
||||
custom_attributes:
|
||||
type: object
|
||||
description: The object to save custom attributes for contact, accepts custom attributes key and value
|
||||
example: { attribute_key: attribute_value, signed_up_at: dd/mm/yyyy }
|
||||
example:
|
||||
{ attribute_key: attribute_value, signed_up_at: dd/mm/yyyy }
|
||||
contact_inboxes:
|
||||
type: array
|
||||
items:
|
||||
$ref: '#/definitions/contact_inboxes'
|
||||
$ref: '#/components/schemas/contact_inboxes'
|
||||
|
||||
@@ -5,4 +5,4 @@ properties:
|
||||
description: Contact Inbox Source Id
|
||||
inbox:
|
||||
type: object
|
||||
$ref: '#/definitions/inbox'
|
||||
$ref: '#/components/schemas/inbox'
|
||||
|
||||
@@ -5,4 +5,4 @@ properties:
|
||||
description: Contact Inbox Source Id
|
||||
inbox:
|
||||
type: object
|
||||
$ref: '#/definitions/inbox'
|
||||
$ref: '#/components/schemas/inbox'
|
||||
|
||||
@@ -6,7 +6,7 @@ properties:
|
||||
messages:
|
||||
type: array
|
||||
items:
|
||||
$ref: '#/definitions/message'
|
||||
$ref: '#/components/schemas/message'
|
||||
account_id:
|
||||
type: number
|
||||
description: Account Id
|
||||
|
||||
@@ -19,4 +19,4 @@ properties:
|
||||
type: string
|
||||
description: Channel Type
|
||||
assignee:
|
||||
$ref: '#/definitions/user'
|
||||
$ref: '#/components/schemas/user'
|
||||
|
||||
@@ -19,6 +19,6 @@ properties:
|
||||
description: 'array of conversations'
|
||||
items:
|
||||
allOf:
|
||||
- $ref: '#/definitions/generic_id'
|
||||
- $ref: '#/definitions/conversation'
|
||||
- $ref: '#/components/schemas/generic_id'
|
||||
- $ref: '#/components/schemas/conversation'
|
||||
- $ref: '../contact/conversation.yml'
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
type: object
|
||||
allOf:
|
||||
- $ref: '#/definitions/conversation'
|
||||
- $ref: '#/components/schemas/conversation'
|
||||
- $ref: '../contact/conversation.yml'
|
||||
|
||||
@@ -27,8 +27,8 @@ properties:
|
||||
categories:
|
||||
type: array
|
||||
items:
|
||||
$ref: '#/definitions/category'
|
||||
$ref: '#/components/schemas/category'
|
||||
articles:
|
||||
type: array
|
||||
items:
|
||||
$ref: '#/definitions/article'
|
||||
$ref: '#/components/schemas/article'
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
type: object
|
||||
properties:
|
||||
properties:
|
||||
id:
|
||||
type: integer
|
||||
description: Id of the contact
|
||||
@@ -14,4 +14,4 @@ properties:
|
||||
description: Email of the contact
|
||||
pubsub_token:
|
||||
type: string
|
||||
description: The token to be used to connect to chatwoot websocket
|
||||
description: The token to be used to connect to chatwoot websocket
|
||||
|
||||
@@ -9,7 +9,7 @@ properties:
|
||||
messages:
|
||||
type: array
|
||||
items:
|
||||
$ref: '#/definitions/message'
|
||||
$ref: '#/components/schemas/message'
|
||||
description: Messages in the conversation
|
||||
contact:
|
||||
type: object
|
||||
|
||||
@@ -19,10 +19,10 @@ properties:
|
||||
enum: ['agent', 'administrator']
|
||||
confirmed:
|
||||
type: boolean
|
||||
custom_attributes:
|
||||
custom_attributes:
|
||||
type: object
|
||||
description: Available for users who are created through platform APIs and has custom attributes associated.
|
||||
accounts:
|
||||
type: array
|
||||
items:
|
||||
$ref: '#/definitions/account'
|
||||
$ref: '#/components/schemas/account'
|
||||
|
||||
Reference in New Issue
Block a user