From 78b03a16515bed0dbc90406c1c0de5bc5074126f Mon Sep 17 00:00:00 2001 From: Tanmay Deep Sharma Date: Tue, 20 May 2025 17:00:52 +0700 Subject: [PATCH] validate swagger api specification --- swagger/definitions/index.yml | 4 ++ .../definitions/resource/contact_inboxes.yml | 1 - swagger/definitions/resource/conversation.yml | 3 ++ .../definitions/resource/portal_single.yml | 1 - swagger/swagger.json | 43 ++++++++++++++++++- swagger/tag_groups/application_swagger.json | 43 ++++++++++++++++++- swagger/tag_groups/client_swagger.json | 43 ++++++++++++++++++- swagger/tag_groups/other_swagger.json | 43 ++++++++++++++++++- swagger/tag_groups/platform_swagger.json | 43 ++++++++++++++++++- 9 files changed, 217 insertions(+), 7 deletions(-) diff --git a/swagger/definitions/index.yml b/swagger/definitions/index.yml index b59f0292a..57e10e2dd 100644 --- a/swagger/definitions/index.yml +++ b/swagger/definitions/index.yml @@ -20,6 +20,8 @@ automation_rule_item: $ref: ./resource/automation_rule_item.yml portal: $ref: ./resource/portal.yml +portal_single: + $ref: ./resource/portal_single.yml portal_config: $ref: ./resource/portal_config.yml portal_logo: @@ -44,6 +46,8 @@ agent: $ref: ./resource/agent.yml inbox: $ref: ./resource/inbox.yml +inbox_contact: + $ref: ./resource/inbox_contact.yml agent_bot: $ref: ./resource/agent_bot.yml contact_inboxes: diff --git a/swagger/definitions/resource/contact_inboxes.yml b/swagger/definitions/resource/contact_inboxes.yml index 09d4086db..5eabeff13 100644 --- a/swagger/definitions/resource/contact_inboxes.yml +++ b/swagger/definitions/resource/contact_inboxes.yml @@ -4,5 +4,4 @@ properties: type: string description: Contact Inbox Source Id inbox: - type: object $ref: '#/components/schemas/inbox_contact' diff --git a/swagger/definitions/resource/conversation.yml b/swagger/definitions/resource/conversation.yml index ffd1eaac2..c1577e693 100644 --- a/swagger/definitions/resource/conversation.yml +++ b/swagger/definitions/resource/conversation.yml @@ -85,4 +85,7 @@ properties: description: The applied SLA sla_events: type: array + items: + type: object + description: SLA event objects diff --git a/swagger/definitions/resource/portal_single.yml b/swagger/definitions/resource/portal_single.yml index 233b69f72..2ca8c6e15 100644 --- a/swagger/definitions/resource/portal_single.yml +++ b/swagger/definitions/resource/portal_single.yml @@ -1,6 +1,5 @@ type: object properties: payload: - type: object description: A single portal object (for show/update endpoints) $ref: '#/components/schemas/portal_item' \ No newline at end of file diff --git a/swagger/swagger.json b/swagger/swagger.json index 80c493c01..0416ab92a 100644 --- a/swagger/swagger.json +++ b/swagger/swagger.json @@ -7936,6 +7936,14 @@ } } }, + "portal_single": { + "type": "object", + "properties": { + "payload": { + "$ref": "#/components/schemas/portal_item" + } + } + }, "portal_config": { "type": "object", "description": "Configuration settings for the portal", @@ -8365,7 +8373,11 @@ "description": "The applied SLA" }, "sla_events": { - "type": "array" + "type": "array", + "items": { + "type": "object", + "description": "SLA event objects" + } } } }, @@ -8831,6 +8843,35 @@ } } }, + "inbox_contact": { + "type": "object", + "properties": { + "id": { + "type": "number", + "description": "ID of the inbox" + }, + "avatar_url": { + "type": "string", + "description": "The avatar image of the inbox" + }, + "channel_id": { + "type": "number", + "description": "The ID of the channel" + }, + "name": { + "type": "string", + "description": "The name of the inbox" + }, + "channel_type": { + "type": "string", + "description": "The type of the inbox" + }, + "provider": { + "type": "string", + "description": "The provider of the inbox" + } + } + }, "agent_bot": { "type": "object", "properties": { diff --git a/swagger/tag_groups/application_swagger.json b/swagger/tag_groups/application_swagger.json index 3f496e143..90a1f5f1c 100644 --- a/swagger/tag_groups/application_swagger.json +++ b/swagger/tag_groups/application_swagger.json @@ -6231,6 +6231,14 @@ } } }, + "portal_single": { + "type": "object", + "properties": { + "payload": { + "$ref": "#/components/schemas/portal_item" + } + } + }, "portal_config": { "type": "object", "description": "Configuration settings for the portal", @@ -6660,7 +6668,11 @@ "description": "The applied SLA" }, "sla_events": { - "type": "array" + "type": "array", + "items": { + "type": "object", + "description": "SLA event objects" + } } } }, @@ -7126,6 +7138,35 @@ } } }, + "inbox_contact": { + "type": "object", + "properties": { + "id": { + "type": "number", + "description": "ID of the inbox" + }, + "avatar_url": { + "type": "string", + "description": "The avatar image of the inbox" + }, + "channel_id": { + "type": "number", + "description": "The ID of the channel" + }, + "name": { + "type": "string", + "description": "The name of the inbox" + }, + "channel_type": { + "type": "string", + "description": "The type of the inbox" + }, + "provider": { + "type": "string", + "description": "The provider of the inbox" + } + } + }, "agent_bot": { "type": "object", "properties": { diff --git a/swagger/tag_groups/client_swagger.json b/swagger/tag_groups/client_swagger.json index 3c59a7f4f..2a111025c 100644 --- a/swagger/tag_groups/client_swagger.json +++ b/swagger/tag_groups/client_swagger.json @@ -906,6 +906,14 @@ } } }, + "portal_single": { + "type": "object", + "properties": { + "payload": { + "$ref": "#/components/schemas/portal_item" + } + } + }, "portal_config": { "type": "object", "description": "Configuration settings for the portal", @@ -1335,7 +1343,11 @@ "description": "The applied SLA" }, "sla_events": { - "type": "array" + "type": "array", + "items": { + "type": "object", + "description": "SLA event objects" + } } } }, @@ -1801,6 +1813,35 @@ } } }, + "inbox_contact": { + "type": "object", + "properties": { + "id": { + "type": "number", + "description": "ID of the inbox" + }, + "avatar_url": { + "type": "string", + "description": "The avatar image of the inbox" + }, + "channel_id": { + "type": "number", + "description": "The ID of the channel" + }, + "name": { + "type": "string", + "description": "The name of the inbox" + }, + "channel_type": { + "type": "string", + "description": "The type of the inbox" + }, + "provider": { + "type": "string", + "description": "The provider of the inbox" + } + } + }, "agent_bot": { "type": "object", "properties": { diff --git a/swagger/tag_groups/other_swagger.json b/swagger/tag_groups/other_swagger.json index c0f65e20d..0f55bde64 100644 --- a/swagger/tag_groups/other_swagger.json +++ b/swagger/tag_groups/other_swagger.json @@ -299,6 +299,14 @@ } } }, + "portal_single": { + "type": "object", + "properties": { + "payload": { + "$ref": "#/components/schemas/portal_item" + } + } + }, "portal_config": { "type": "object", "description": "Configuration settings for the portal", @@ -728,7 +736,11 @@ "description": "The applied SLA" }, "sla_events": { - "type": "array" + "type": "array", + "items": { + "type": "object", + "description": "SLA event objects" + } } } }, @@ -1194,6 +1206,35 @@ } } }, + "inbox_contact": { + "type": "object", + "properties": { + "id": { + "type": "number", + "description": "ID of the inbox" + }, + "avatar_url": { + "type": "string", + "description": "The avatar image of the inbox" + }, + "channel_id": { + "type": "number", + "description": "The ID of the channel" + }, + "name": { + "type": "string", + "description": "The name of the inbox" + }, + "channel_type": { + "type": "string", + "description": "The type of the inbox" + }, + "provider": { + "type": "string", + "description": "The provider of the inbox" + } + } + }, "agent_bot": { "type": "object", "properties": { diff --git a/swagger/tag_groups/platform_swagger.json b/swagger/tag_groups/platform_swagger.json index 330bd8142..396798bc6 100644 --- a/swagger/tag_groups/platform_swagger.json +++ b/swagger/tag_groups/platform_swagger.json @@ -1092,6 +1092,14 @@ } } }, + "portal_single": { + "type": "object", + "properties": { + "payload": { + "$ref": "#/components/schemas/portal_item" + } + } + }, "portal_config": { "type": "object", "description": "Configuration settings for the portal", @@ -1521,7 +1529,11 @@ "description": "The applied SLA" }, "sla_events": { - "type": "array" + "type": "array", + "items": { + "type": "object", + "description": "SLA event objects" + } } } }, @@ -1987,6 +1999,35 @@ } } }, + "inbox_contact": { + "type": "object", + "properties": { + "id": { + "type": "number", + "description": "ID of the inbox" + }, + "avatar_url": { + "type": "string", + "description": "The avatar image of the inbox" + }, + "channel_id": { + "type": "number", + "description": "The ID of the channel" + }, + "name": { + "type": "string", + "description": "The name of the inbox" + }, + "channel_type": { + "type": "string", + "description": "The type of the inbox" + }, + "provider": { + "type": "string", + "description": "The provider of the inbox" + } + } + }, "agent_bot": { "type": "object", "properties": {