From df1ebc6a3cfc97906ad7d088866c352c26dd4a27 Mon Sep 17 00:00:00 2001 From: Shwetha Radhakrishna Date: Tue, 1 Dec 2020 14:45:19 -0700 Subject: [PATCH] feat: Splitting up openAPI specs by version (#8) * Splitting up openAPI specs by version. Ref: https://code.hq.twilio.com/twilio/yps/pull/56 * Updated version * Ignoring preview * Updated version * Adding .gitignore * Removing .DS_Store * Adding in preview specs Co-authored-by: shwetharadhakrishna --- .gitignore | 1 + ..._accounts.json => twilio_accounts_v1.json} | 0 ...{twilio_api.json => twilio_api_v2010.json} | 0 ...utopilot.json => twilio_autopilot_v1.json} | 0 ...xports.json => twilio_bulkexports_v1.json} | 0 spec/json/twilio_chat_v1.json | 3875 +++++++++++++++ .../{twilio_chat.json => twilio_chat_v2.json} | 4275 +---------------- ...ions.json => twilio_conversations_v1.json} | 0 ...ilio_events.json => twilio_events_v1.json} | 0 .../{twilio_fax.json => twilio_fax_v1.json} | 0 .../{twilio_flex.json => twilio_flex_v1.json} | 0 ..._insights.json => twilio_insights_v1.json} | 0 ...tudio.json => twilio_ip_messaging_v1.json} | 3322 +++++++------ ...aging.json => twilio_ip_messaging_v2.json} | 4275 +---------------- ...io_lookups.json => twilio_lookups_v1.json} | 0 ...essaging.json => twilio_messaging_v1.json} | 0 ...io_monitor.json => twilio_monitor_v1.json} | 0 ...ilio_notify.json => twilio_notify_v1.json} | 0 ...io_numbers.json => twilio_numbers_v2.json} | 0 ...io_pricing.json => twilio_pricing_v1.json} | 341 -- spec/json/twilio_pricing_v2.json | 377 ++ ...twilio_proxy.json => twilio_proxy_v1.json} | 0 ...verless.json => twilio_serverless_v1.json} | 0 spec/json/twilio_studio_v1.json | 1880 ++++++++ spec/json/twilio_studio_v2.json | 1681 +++++++ ..._supersim.json => twilio_supersim_v1.json} | 0 .../{twilio_sync.json => twilio_sync_v1.json} | 0 ...krouter.json => twilio_taskrouter_v1.json} | 0 ..._trunking.json => twilio_trunking_v1.json} | 0 ...ilio_verify.json => twilio_verify_v2.json} | 0 ...twilio_video.json => twilio_video_v1.json} | 0 ...twilio_voice.json => twilio_voice_v1.json} | 0 ..._wireless.json => twilio_wireless_v1.json} | 0 ..._accounts.yaml => twilio_accounts_v1.yaml} | 0 ...{twilio_api.yaml => twilio_api_v2010.yaml} | 0 ...utopilot.yaml => twilio_autopilot_v1.yaml} | 0 ...xports.yaml => twilio_bulkexports_v1.yaml} | 0 spec/yaml/twilio_chat_v1.yaml | 2876 +++++++++++ .../{twilio_chat.yaml => twilio_chat_v2.yaml} | 3507 ++------------ ...ions.yaml => twilio_conversations_v1.yaml} | 0 ...ilio_events.yaml => twilio_events_v1.yaml} | 0 .../{twilio_fax.yaml => twilio_fax_v1.yaml} | 0 .../{twilio_flex.yaml => twilio_flex_v1.yaml} | 0 ..._insights.yaml => twilio_insights_v1.yaml} | 0 spec/yaml/twilio_ip_messaging_v1.yaml | 2656 ++++++++++ ...aging.yaml => twilio_ip_messaging_v2.yaml} | 3287 ++----------- ...io_lookups.yaml => twilio_lookups_v1.yaml} | 0 ...essaging.yaml => twilio_messaging_v1.yaml} | 0 ...io_monitor.yaml => twilio_monitor_v1.yaml} | 0 ...ilio_notify.yaml => twilio_notify_v1.yaml} | 0 ...io_numbers.yaml => twilio_numbers_v2.yaml} | 0 ...io_pricing.yaml => twilio_pricing_v1.yaml} | 222 - spec/yaml/twilio_pricing_v2.yaml | 245 + ...twilio_proxy.yaml => twilio_proxy_v1.yaml} | 0 ...verless.yaml => twilio_serverless_v1.yaml} | 0 ...ilio_studio.yaml => twilio_studio_v1.yaml} | 1099 ----- spec/yaml/twilio_studio_v2.yaml | 1120 +++++ ..._supersim.yaml => twilio_supersim_v1.yaml} | 0 .../{twilio_sync.yaml => twilio_sync_v1.yaml} | 0 ...krouter.yaml => twilio_taskrouter_v1.yaml} | 0 ..._trunking.yaml => twilio_trunking_v1.yaml} | 0 ...ilio_verify.yaml => twilio_verify_v2.yaml} | 0 ...twilio_video.yaml => twilio_video_v1.yaml} | 0 ...twilio_voice.yaml => twilio_voice_v1.yaml} | 0 ..._wireless.yaml => twilio_wireless_v1.yaml} | 0 65 files changed, 17635 insertions(+), 17404 deletions(-) create mode 100644 .gitignore rename spec/json/{twilio_accounts.json => twilio_accounts_v1.json} (100%) rename spec/json/{twilio_api.json => twilio_api_v2010.json} (100%) rename spec/json/{twilio_autopilot.json => twilio_autopilot_v1.json} (100%) rename spec/json/{twilio_bulkexports.json => twilio_bulkexports_v1.json} (100%) create mode 100644 spec/json/twilio_chat_v1.json rename spec/json/{twilio_chat.json => twilio_chat_v2.json} (57%) rename spec/json/{twilio_conversations.json => twilio_conversations_v1.json} (100%) rename spec/json/{twilio_events.json => twilio_events_v1.json} (100%) rename spec/json/{twilio_fax.json => twilio_fax_v1.json} (100%) rename spec/json/{twilio_flex.json => twilio_flex_v1.json} (100%) rename spec/json/{twilio_insights.json => twilio_insights_v1.json} (100%) rename spec/json/{twilio_studio.json => twilio_ip_messaging_v1.json} (59%) rename spec/json/{twilio_ip_messaging.json => twilio_ip_messaging_v2.json} (56%) rename spec/json/{twilio_lookups.json => twilio_lookups_v1.json} (100%) rename spec/json/{twilio_messaging.json => twilio_messaging_v1.json} (100%) rename spec/json/{twilio_monitor.json => twilio_monitor_v1.json} (100%) rename spec/json/{twilio_notify.json => twilio_notify_v1.json} (100%) rename spec/json/{twilio_numbers.json => twilio_numbers_v2.json} (100%) rename spec/json/{twilio_pricing.json => twilio_pricing_v1.json} (68%) create mode 100644 spec/json/twilio_pricing_v2.json rename spec/json/{twilio_proxy.json => twilio_proxy_v1.json} (100%) rename spec/json/{twilio_serverless.json => twilio_serverless_v1.json} (100%) create mode 100644 spec/json/twilio_studio_v1.json create mode 100644 spec/json/twilio_studio_v2.json rename spec/json/{twilio_supersim.json => twilio_supersim_v1.json} (100%) rename spec/json/{twilio_sync.json => twilio_sync_v1.json} (100%) rename spec/json/{twilio_taskrouter.json => twilio_taskrouter_v1.json} (100%) rename spec/json/{twilio_trunking.json => twilio_trunking_v1.json} (100%) rename spec/json/{twilio_verify.json => twilio_verify_v2.json} (100%) rename spec/json/{twilio_video.json => twilio_video_v1.json} (100%) rename spec/json/{twilio_voice.json => twilio_voice_v1.json} (100%) rename spec/json/{twilio_wireless.json => twilio_wireless_v1.json} (100%) rename spec/yaml/{twilio_accounts.yaml => twilio_accounts_v1.yaml} (100%) rename spec/yaml/{twilio_api.yaml => twilio_api_v2010.yaml} (100%) rename spec/yaml/{twilio_autopilot.yaml => twilio_autopilot_v1.yaml} (100%) rename spec/yaml/{twilio_bulkexports.yaml => twilio_bulkexports_v1.yaml} (100%) create mode 100644 spec/yaml/twilio_chat_v1.yaml rename spec/yaml/{twilio_chat.yaml => twilio_chat_v2.yaml} (57%) rename spec/yaml/{twilio_conversations.yaml => twilio_conversations_v1.yaml} (100%) rename spec/yaml/{twilio_events.yaml => twilio_events_v1.yaml} (100%) rename spec/yaml/{twilio_fax.yaml => twilio_fax_v1.yaml} (100%) rename spec/yaml/{twilio_flex.yaml => twilio_flex_v1.yaml} (100%) rename spec/yaml/{twilio_insights.yaml => twilio_insights_v1.yaml} (100%) create mode 100644 spec/yaml/twilio_ip_messaging_v1.yaml rename spec/yaml/{twilio_ip_messaging.yaml => twilio_ip_messaging_v2.yaml} (56%) rename spec/yaml/{twilio_lookups.yaml => twilio_lookups_v1.yaml} (100%) rename spec/yaml/{twilio_messaging.yaml => twilio_messaging_v1.yaml} (100%) rename spec/yaml/{twilio_monitor.yaml => twilio_monitor_v1.yaml} (100%) rename spec/yaml/{twilio_notify.yaml => twilio_notify_v1.yaml} (100%) rename spec/yaml/{twilio_numbers.yaml => twilio_numbers_v2.yaml} (100%) rename spec/yaml/{twilio_pricing.yaml => twilio_pricing_v1.yaml} (67%) create mode 100644 spec/yaml/twilio_pricing_v2.yaml rename spec/yaml/{twilio_proxy.yaml => twilio_proxy_v1.yaml} (100%) rename spec/yaml/{twilio_serverless.yaml => twilio_serverless_v1.yaml} (100%) rename spec/yaml/{twilio_studio.yaml => twilio_studio_v1.yaml} (54%) create mode 100644 spec/yaml/twilio_studio_v2.yaml rename spec/yaml/{twilio_supersim.yaml => twilio_supersim_v1.yaml} (100%) rename spec/yaml/{twilio_sync.yaml => twilio_sync_v1.yaml} (100%) rename spec/yaml/{twilio_taskrouter.yaml => twilio_taskrouter_v1.yaml} (100%) rename spec/yaml/{twilio_trunking.yaml => twilio_trunking_v1.yaml} (100%) rename spec/yaml/{twilio_verify.yaml => twilio_verify_v2.yaml} (100%) rename spec/yaml/{twilio_video.yaml => twilio_video_v1.yaml} (100%) rename spec/yaml/{twilio_voice.yaml => twilio_voice_v1.yaml} (100%) rename spec/yaml/{twilio_wireless.yaml => twilio_wireless_v1.yaml} (100%) diff --git a/.gitignore b/.gitignore new file mode 100644 index 00000000..e43b0f98 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +.DS_Store diff --git a/spec/json/twilio_accounts.json b/spec/json/twilio_accounts_v1.json similarity index 100% rename from spec/json/twilio_accounts.json rename to spec/json/twilio_accounts_v1.json diff --git a/spec/json/twilio_api.json b/spec/json/twilio_api_v2010.json similarity index 100% rename from spec/json/twilio_api.json rename to spec/json/twilio_api_v2010.json diff --git a/spec/json/twilio_autopilot.json b/spec/json/twilio_autopilot_v1.json similarity index 100% rename from spec/json/twilio_autopilot.json rename to spec/json/twilio_autopilot_v1.json diff --git a/spec/json/twilio_bulkexports.json b/spec/json/twilio_bulkexports_v1.json similarity index 100% rename from spec/json/twilio_bulkexports.json rename to spec/json/twilio_bulkexports_v1.json diff --git a/spec/json/twilio_chat_v1.json b/spec/json/twilio_chat_v1.json new file mode 100644 index 00000000..50f36a52 --- /dev/null +++ b/spec/json/twilio_chat_v1.json @@ -0,0 +1,3875 @@ +{ + "components": { + "schemas": { + "chat.v1.credential": { + "properties": { + "account_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^AC[0-9a-fA-F]{32}$", + "type": "string" + }, + "date_created": { + "format": "date-time", + "type": "string" + }, + "date_updated": { + "format": "date-time", + "type": "string" + }, + "friendly_name": { + "type": "string" + }, + "sandbox": { + "type": "string" + }, + "sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^CR[0-9a-fA-F]{32}$", + "type": "string" + }, + "type": { + "enum": [ + "gcm", + "apn", + "fcm" + ], + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + }, + "chat.v1.service": { + "properties": { + "account_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^AC[0-9a-fA-F]{32}$", + "type": "string" + }, + "consumption_report_interval": { + "type": "integer" + }, + "date_created": { + "format": "date-time", + "type": "string" + }, + "date_updated": { + "format": "date-time", + "type": "string" + }, + "default_channel_creator_role_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^RL[0-9a-fA-F]{32}$", + "type": "string" + }, + "default_channel_role_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^RL[0-9a-fA-F]{32}$", + "type": "string" + }, + "default_service_role_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^RL[0-9a-fA-F]{32}$", + "type": "string" + }, + "friendly_name": { + "type": "string" + }, + "limits": { + "type": "object" + }, + "links": { + "type": "object" + }, + "notifications": { + "type": "object" + }, + "post_webhook_url": { + "type": "string" + }, + "pre_webhook_url": { + "type": "string" + }, + "reachability_enabled": { + "type": "boolean" + }, + "read_status_enabled": { + "type": "boolean" + }, + "sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + }, + "typing_indicator_timeout": { + "type": "integer" + }, + "url": { + "format": "uri", + "type": "string" + }, + "webhook_filters": { + "items": { + "type": "string" + }, + "type": "array" + }, + "webhook_method": { + "type": "string" + }, + "webhooks": { + "type": "object" + } + }, + "type": "object" + }, + "chat.v1.service.channel": { + "properties": { + "account_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^AC[0-9a-fA-F]{32}$", + "type": "string" + }, + "attributes": { + "type": "string" + }, + "created_by": { + "type": "string" + }, + "date_created": { + "format": "date-time", + "type": "string" + }, + "date_updated": { + "format": "date-time", + "type": "string" + }, + "friendly_name": { + "type": "string" + }, + "links": { + "type": "object" + }, + "members_count": { + "type": "integer" + }, + "messages_count": { + "type": "integer" + }, + "service_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + }, + "sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^CH[0-9a-fA-F]{32}$", + "type": "string" + }, + "type": { + "enum": [ + "public", + "private" + ], + "type": "string" + }, + "unique_name": { + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + }, + "chat.v1.service.channel.invite": { + "properties": { + "account_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^AC[0-9a-fA-F]{32}$", + "type": "string" + }, + "channel_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^CH[0-9a-fA-F]{32}$", + "type": "string" + }, + "created_by": { + "type": "string" + }, + "date_created": { + "format": "date-time", + "type": "string" + }, + "date_updated": { + "format": "date-time", + "type": "string" + }, + "identity": { + "type": "string" + }, + "role_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^RL[0-9a-fA-F]{32}$", + "type": "string" + }, + "service_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + }, + "sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IN[0-9a-fA-F]{32}$", + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + }, + "chat.v1.service.channel.member": { + "properties": { + "account_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^AC[0-9a-fA-F]{32}$", + "type": "string" + }, + "channel_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^CH[0-9a-fA-F]{32}$", + "type": "string" + }, + "date_created": { + "format": "date-time", + "type": "string" + }, + "date_updated": { + "format": "date-time", + "type": "string" + }, + "identity": { + "type": "string" + }, + "last_consumed_message_index": { + "nullable": true, + "type": "integer" + }, + "last_consumption_timestamp": { + "format": "date-time", + "type": "string" + }, + "role_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^RL[0-9a-fA-F]{32}$", + "type": "string" + }, + "service_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + }, + "sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^MB[0-9a-fA-F]{32}$", + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + }, + "chat.v1.service.channel.message": { + "properties": { + "account_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^AC[0-9a-fA-F]{32}$", + "type": "string" + }, + "attributes": { + "type": "string" + }, + "body": { + "type": "string" + }, + "channel_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^CH[0-9a-fA-F]{32}$", + "type": "string" + }, + "date_created": { + "format": "date-time", + "type": "string" + }, + "date_updated": { + "format": "date-time", + "type": "string" + }, + "from": { + "type": "string" + }, + "index": { + "type": "integer" + }, + "service_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + }, + "sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IM[0-9a-fA-F]{32}$", + "type": "string" + }, + "to": { + "maxLength": 34, + "minLength": 34, + "pattern": "^CH[0-9a-fA-F]{32}$", + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + }, + "was_edited": { + "type": "boolean" + } + }, + "type": "object" + }, + "chat.v1.service.role": { + "properties": { + "account_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^AC[0-9a-fA-F]{32}$", + "type": "string" + }, + "date_created": { + "format": "date-time", + "type": "string" + }, + "date_updated": { + "format": "date-time", + "type": "string" + }, + "friendly_name": { + "type": "string" + }, + "permissions": { + "items": { + "type": "string" + }, + "type": "array" + }, + "service_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + }, + "sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^RL[0-9a-fA-F]{32}$", + "type": "string" + }, + "type": { + "enum": [ + "channel", + "deployment" + ], + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + }, + "chat.v1.service.user": { + "properties": { + "account_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^AC[0-9a-fA-F]{32}$", + "type": "string" + }, + "attributes": { + "type": "string" + }, + "date_created": { + "format": "date-time", + "type": "string" + }, + "date_updated": { + "format": "date-time", + "type": "string" + }, + "friendly_name": { + "type": "string" + }, + "identity": { + "type": "string" + }, + "is_notifiable": { + "type": "boolean" + }, + "is_online": { + "type": "boolean" + }, + "joined_channels_count": { + "type": "integer" + }, + "links": { + "type": "object" + }, + "role_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^RL[0-9a-fA-F]{32}$", + "type": "string" + }, + "service_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + }, + "sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^US[0-9a-fA-F]{32}$", + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + }, + "chat.v1.service.user.user_channel": { + "properties": { + "account_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^AC[0-9a-fA-F]{32}$", + "type": "string" + }, + "channel_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^CH[0-9a-fA-F]{32}$", + "type": "string" + }, + "last_consumed_message_index": { + "nullable": true, + "type": "integer" + }, + "links": { + "type": "object" + }, + "member_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^MB[0-9a-fA-F]{32}$", + "type": "string" + }, + "service_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + }, + "status": { + "enum": [ + "joined", + "invited", + "not_participating" + ], + "type": "string" + }, + "unread_messages_count": { + "nullable": true, + "type": "integer" + } + }, + "type": "object" + } + }, + "securitySchemes": { + "accountSid_authToken": { + "scheme": "basic", + "type": "http" + } + } + }, + "info": { + "contact": { + "email": "support@twilio.com", + "name": "Twilio Support", + "url": "https://support.twilio.com" + }, + "description": "This is the public Twilio REST API.", + "license": { + "name": "Apache 2.0", + "url": "https://www.apache.org/licenses/LICENSE-2.0.html" + }, + "termsOfService": "https://www.twilio.com/legal/tos", + "title": "Twilio - Chat", + "version": "1.3.0" + }, + "openapi": "3.0.1", + "paths": { + "/v1/Credentials": { + "description": "Credentials for push notifications channels", + "get": { + "description": "", + "parameters": [ + { + "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", + "in": "query", + "name": "PageSize", + "schema": { + "maximum": 1000, + "minimum": 1, + "type": "integer" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "properties": { + "credentials": { + "items": { + "$ref": "#/components/schemas/chat.v1.credential" + }, + "type": "array" + }, + "meta": { + "properties": { + "first_page_url": { + "format": "uri", + "type": "string" + }, + "key": { + "type": "string" + }, + "next_page_url": { + "format": "uri", + "type": "string" + }, + "page": { + "type": "integer" + }, + "page_size": { + "type": "integer" + }, + "previous_page_url": { + "format": "uri", + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + } + }, + "type": "object" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "post": { + "description": "", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "schema": { + "properties": { + "ApiKey": { + "description": "[GCM only] The API key for the project that was obtained from the Google Developer console for your GCM Service application credential.", + "type": "string" + }, + "Certificate": { + "description": "[APN only] The URL encoded representation of the certificate. For example, \n`-----BEGIN CERTIFICATE-----\nMIIFnTCCBIWgAwIBAgIIAjy9H849+E8wDQYJKoZIhvcNAQEFBQAwgZYxCzAJBgNV.....A==\n-----END CERTIFICATE-----`", + "type": "string" + }, + "FriendlyName": { + "description": "A descriptive string that you create to describe the new resource. It can be up to 64 characters long.", + "type": "string" + }, + "PrivateKey": { + "description": "[APN only] The URL encoded representation of the private key. For example,\n`-----BEGIN RSA PRIVATE KEY-----\nMIIEpQIBAAKCAQEAuyf/lNrH9ck8DmNyo3fGgvCI1l9s+cmBY3WIz+cUDqmxiieR.\n-----END RSA PRIVATE KEY-----`", + "type": "string" + }, + "Sandbox": { + "description": "[APN only] Whether to send the credential to sandbox APNs. Can be `true` to send to sandbox APNs or `false` to send to production.", + "type": "boolean" + }, + "Secret": { + "description": "[FCM only] The **Server key** of your project from the Firebase console, found under Settings / Cloud messaging.", + "type": "string" + }, + "Type": { + "description": "The type of push-notification service the credential is for. Can be: `gcm`, `fcm`, or `apn`.", + "enum": [ + "gcm", + "apn", + "fcm" + ], + "type": "string" + } + }, + "required": [ + "Type" + ], + "type": "object" + } + } + } + }, + "responses": { + "201": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/chat.v1.credential" + } + } + }, + "description": "Created" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "servers": [ + { + "url": "https://chat.twilio.com" + } + ], + "x-default-output-properties": [ + "sid", + "friendly_name", + "type" + ], + "x-path-type": "list" + }, + "/v1/Credentials/{Sid}": { + "delete": { + "description": "", + "parameters": [ + { + "description": "The Twilio-provided string that uniquely identifies the Credential resource to delete.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^CR[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "responses": { + "204": { + "description": "The resource was deleted successfully." + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "description": "Credentials for push notifications channels", + "get": { + "description": "", + "parameters": [ + { + "description": "The Twilio-provided string that uniquely identifies the Credential resource to fetch.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^CR[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/chat.v1.credential" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "post": { + "description": "", + "parameters": [ + { + "description": "The Twilio-provided string that uniquely identifies the Credential resource to update.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^CR[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "schema": { + "properties": { + "ApiKey": { + "description": "[GCM only] The API key for the project that was obtained from the Google Developer console for your GCM Service application credential.", + "type": "string" + }, + "Certificate": { + "description": "[APN only] The URL encoded representation of the certificate. For example, \n`-----BEGIN CERTIFICATE-----\nMIIFnTCCBIWgAwIBAgIIAjy9H849+E8wDQYJKoZIhvcNAQEFBQAwgZYxCzAJBgNV.....A==\n-----END CERTIFICATE-----`", + "type": "string" + }, + "FriendlyName": { + "description": "A descriptive string that you create to describe the resource. It can be up to 64 characters long.", + "type": "string" + }, + "PrivateKey": { + "description": "[APN only] The URL encoded representation of the private key. For example,\n`-----BEGIN RSA PRIVATE KEY-----\nMIIEpQIBAAKCAQEAuyf/lNrH9ck8DmNyo3fGgvCI1l9s+cmBY3WIz+cUDqmxiieR.\n-----END RSA PRIVATE KEY-----`", + "type": "string" + }, + "Sandbox": { + "description": "[APN only] Whether to send the credential to sandbox APNs. Can be `true` to send to sandbox APNs or `false` to send to production.", + "type": "boolean" + }, + "Secret": { + "description": "[FCM only] The **Server key** of your project from the Firebase console, found under Settings / Cloud messaging.", + "type": "string" + } + }, + "type": "object" + } + } + } + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/chat.v1.credential" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "servers": [ + { + "url": "https://chat.twilio.com" + } + ], + "x-default-output-properties": [ + "sid", + "friendly_name", + "type" + ], + "x-path-type": "instance" + }, + "/v1/Services": { + "description": "Top level scope for all chat resources", + "get": { + "description": "", + "parameters": [ + { + "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", + "in": "query", + "name": "PageSize", + "schema": { + "maximum": 1000, + "minimum": 1, + "type": "integer" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "properties": { + "meta": { + "properties": { + "first_page_url": { + "format": "uri", + "type": "string" + }, + "key": { + "type": "string" + }, + "next_page_url": { + "format": "uri", + "type": "string" + }, + "page": { + "type": "integer" + }, + "page_size": { + "type": "integer" + }, + "previous_page_url": { + "format": "uri", + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + }, + "services": { + "items": { + "$ref": "#/components/schemas/chat.v1.service" + }, + "type": "array" + } + }, + "type": "object" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "post": { + "description": "", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "schema": { + "properties": { + "FriendlyName": { + "description": "A descriptive string that you create to describe the resource. It can be up to 64 characters long.", + "type": "string" + } + }, + "required": [ + "FriendlyName" + ], + "type": "object" + } + } + } + }, + "responses": { + "201": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/chat.v1.service" + } + } + }, + "description": "Created" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "servers": [ + { + "url": "https://chat.twilio.com" + } + ], + "x-default-output-properties": [ + "sid", + "friendly_name", + "date_created" + ], + "x-path-type": "list" + }, + "/v1/Services/{ServiceSid}/Channels": { + "description": "Channels represent chat rooms", + "get": { + "description": "", + "parameters": [ + { + "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to read the resources from.", + "in": "path", + "name": "ServiceSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The visibility of the Channels to read. Can be: `public` or `private` and defaults to `public`.", + "in": "query", + "name": "Type", + "schema": { + "items": { + "enum": [ + "public", + "private" + ], + "type": "string" + }, + "type": "array" + } + }, + { + "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", + "in": "query", + "name": "PageSize", + "schema": { + "maximum": 1000, + "minimum": 1, + "type": "integer" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "properties": { + "channels": { + "items": { + "$ref": "#/components/schemas/chat.v1.service.channel" + }, + "type": "array" + }, + "meta": { + "properties": { + "first_page_url": { + "format": "uri", + "type": "string" + }, + "key": { + "type": "string" + }, + "next_page_url": { + "format": "uri", + "type": "string" + }, + "page": { + "type": "integer" + }, + "page_size": { + "type": "integer" + }, + "previous_page_url": { + "format": "uri", + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + } + }, + "type": "object" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "post": { + "description": "", + "parameters": [ + { + "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to create the resource under.", + "in": "path", + "name": "ServiceSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "schema": { + "properties": { + "Attributes": { + "description": "A valid JSON string that contains application-specific data.", + "type": "string" + }, + "FriendlyName": { + "description": "A descriptive string that you create to describe the new resource. It can be up to 64 characters long.", + "type": "string" + }, + "Type": { + "description": "The visibility of the channel. Can be: `public` or `private` and defaults to `public`.", + "enum": [ + "public", + "private" + ], + "type": "string" + }, + "UniqueName": { + "description": "An application-defined string that uniquely identifies the resource. It can be used to address the resource in place of the resource's `sid` in the URL. This value must be 64 characters or less in length and be unique within the Service.", + "type": "string" + } + }, + "type": "object" + } + } + } + }, + "responses": { + "201": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/chat.v1.service.channel" + } + } + }, + "description": "Created" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "servers": [ + { + "url": "https://chat.twilio.com" + } + ], + "x-default-output-properties": [ + "sid", + "unique_name", + "friendly_name" + ], + "x-path-type": "list" + }, + "/v1/Services/{ServiceSid}/Channels/{ChannelSid}/Invites": { + "description": "Pending invitations to users to become channel members", + "get": { + "description": "", + "parameters": [ + { + "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to read the resources from.", + "in": "path", + "name": "ServiceSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The SID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) the resources to read belong to.", + "in": "path", + "name": "ChannelSid", + "required": true, + "schema": { + "type": "string" + } + }, + { + "description": "The [User](https://www.twilio.com/docs/api/chat/rest/v1/user)'s `identity` value of the resources to read. See [access tokens](https://www.twilio.com/docs/api/chat/guides/create-tokens) for more details.", + "in": "query", + "name": "Identity", + "schema": { + "items": { + "type": "string" + }, + "type": "array" + } + }, + { + "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", + "in": "query", + "name": "PageSize", + "schema": { + "maximum": 1000, + "minimum": 1, + "type": "integer" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "properties": { + "invites": { + "items": { + "$ref": "#/components/schemas/chat.v1.service.channel.invite" + }, + "type": "array" + }, + "meta": { + "properties": { + "first_page_url": { + "format": "uri", + "type": "string" + }, + "key": { + "type": "string" + }, + "next_page_url": { + "format": "uri", + "type": "string" + }, + "page": { + "type": "integer" + }, + "page_size": { + "type": "integer" + }, + "previous_page_url": { + "format": "uri", + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + } + }, + "type": "object" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "post": { + "description": "", + "parameters": [ + { + "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to create the resource under.", + "in": "path", + "name": "ServiceSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The SID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) the new resource belongs to.", + "in": "path", + "name": "ChannelSid", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "schema": { + "properties": { + "Identity": { + "description": "The `identity` value that uniquely identifies the new resource's [User](https://www.twilio.com/docs/api/chat/rest/v1/user) within the [Service](https://www.twilio.com/docs/api/chat/rest/v1/service). See [access tokens](https://www.twilio.com/docs/api/chat/guides/create-tokens) for more info.", + "type": "string" + }, + "RoleSid": { + "description": "The SID of the [Role](https://www.twilio.com/docs/api/chat/rest/roles) assigned to the new member.", + "maxLength": 34, + "minLength": 34, + "pattern": "^RL[0-9a-fA-F]{32}$", + "type": "string" + } + }, + "required": [ + "Identity" + ], + "type": "object" + } + } + } + }, + "responses": { + "201": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/chat.v1.service.channel.invite" + } + } + }, + "description": "Created" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "servers": [ + { + "url": "https://chat.twilio.com" + } + ], + "x-default-output-properties": [ + "sid", + "identity", + "date_created" + ], + "x-path-type": "list" + }, + "/v1/Services/{ServiceSid}/Channels/{ChannelSid}/Invites/{Sid}": { + "delete": { + "description": "", + "parameters": [ + { + "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to delete the resource from.", + "in": "path", + "name": "ServiceSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The SID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) the resource to delete belongs to.", + "in": "path", + "name": "ChannelSid", + "required": true, + "schema": { + "type": "string" + } + }, + { + "description": "The Twilio-provided string that uniquely identifies the Invite resource to delete.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IN[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "responses": { + "204": { + "description": "The resource was deleted successfully." + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "description": "Pending invitations to users to become channel members", + "get": { + "description": "", + "parameters": [ + { + "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to fetch the resource from.", + "in": "path", + "name": "ServiceSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The SID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) the resource to fetch belongs to.", + "in": "path", + "name": "ChannelSid", + "required": true, + "schema": { + "type": "string" + } + }, + { + "description": "The Twilio-provided string that uniquely identifies the Invite resource to fetch.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IN[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/chat.v1.service.channel.invite" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "servers": [ + { + "url": "https://chat.twilio.com" + } + ], + "x-default-output-properties": [ + "sid", + "identity", + "date_created" + ], + "x-path-type": "instance" + }, + "/v1/Services/{ServiceSid}/Channels/{ChannelSid}/Members": { + "description": "Users joined to specific channels", + "get": { + "description": "", + "parameters": [ + { + "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to read the resources from.", + "in": "path", + "name": "ServiceSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) the members to read belong to. Can be the Channel resource's `sid` or `unique_name` value.", + "in": "path", + "name": "ChannelSid", + "required": true, + "schema": { + "type": "string" + } + }, + { + "description": "The [User](https://www.twilio.com/docs/api/chat/rest/v1/user)'s `identity` value of the resources to read. See [access tokens](https://www.twilio.com/docs/api/chat/guides/create-tokens) for more details.", + "in": "query", + "name": "Identity", + "schema": { + "items": { + "type": "string" + }, + "type": "array" + } + }, + { + "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", + "in": "query", + "name": "PageSize", + "schema": { + "maximum": 1000, + "minimum": 1, + "type": "integer" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "properties": { + "members": { + "items": { + "$ref": "#/components/schemas/chat.v1.service.channel.member" + }, + "type": "array" + }, + "meta": { + "properties": { + "first_page_url": { + "format": "uri", + "type": "string" + }, + "key": { + "type": "string" + }, + "next_page_url": { + "format": "uri", + "type": "string" + }, + "page": { + "type": "integer" + }, + "page_size": { + "type": "integer" + }, + "previous_page_url": { + "format": "uri", + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + } + }, + "type": "object" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "post": { + "description": "", + "parameters": [ + { + "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to create the resource under.", + "in": "path", + "name": "ServiceSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) the new member belongs to. Can be the Channel resource's `sid` or `unique_name`.", + "in": "path", + "name": "ChannelSid", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "schema": { + "properties": { + "Identity": { + "description": "The `identity` value that uniquely identifies the new resource's [User](https://www.twilio.com/docs/api/chat/rest/v1/user) within the [Service](https://www.twilio.com/docs/api/chat/rest/services). See [access tokens](https://www.twilio.com/docs/api/chat/guides/create-tokens) for more details.", + "type": "string" + }, + "RoleSid": { + "description": "The SID of the [Role](https://www.twilio.com/docs/api/chat/rest/roles) to assign to the member. The default roles are those specified on the [Service](https://www.twilio.com/docs/chat/api/services).", + "maxLength": 34, + "minLength": 34, + "pattern": "^RL[0-9a-fA-F]{32}$", + "type": "string" + } + }, + "required": [ + "Identity" + ], + "type": "object" + } + } + } + }, + "responses": { + "201": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/chat.v1.service.channel.member" + } + } + }, + "description": "Created" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "servers": [ + { + "url": "https://chat.twilio.com" + } + ], + "x-default-output-properties": [ + "sid", + "identity", + "date_created" + ], + "x-path-type": "list" + }, + "/v1/Services/{ServiceSid}/Channels/{ChannelSid}/Members/{Sid}": { + "delete": { + "description": "", + "parameters": [ + { + "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to delete the resource from.", + "in": "path", + "name": "ServiceSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) the message belongs to. Can be the Channel's `sid` or `unique_name`.", + "in": "path", + "name": "ChannelSid", + "required": true, + "schema": { + "type": "string" + } + }, + { + "description": "The Twilio-provided string that uniquely identifies the Member resource to delete.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^MB[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "responses": { + "204": { + "description": "The resource was deleted successfully." + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "description": "Users joined to specific channels", + "get": { + "description": "", + "parameters": [ + { + "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to fetch the resource from.", + "in": "path", + "name": "ServiceSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) the member to fetch belongs to. Can be the Channel resource's `sid` or `unique_name` value.", + "in": "path", + "name": "ChannelSid", + "required": true, + "schema": { + "type": "string" + } + }, + { + "description": "The Twilio-provided string that uniquely identifies the Member resource to fetch.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^MB[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/chat.v1.service.channel.member" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "post": { + "description": "", + "parameters": [ + { + "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to update the resource from.", + "in": "path", + "name": "ServiceSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) the member to update belongs to. Can be the Channel resource's `sid` or `unique_name`.", + "in": "path", + "name": "ChannelSid", + "required": true, + "schema": { + "type": "string" + } + }, + { + "description": "The Twilio-provided string that uniquely identifies the Member resource to update.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^MB[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "schema": { + "properties": { + "LastConsumedMessageIndex": { + "description": "The index of the last [Message](https://www.twilio.com/docs/api/chat/rest/messages) that the Member has read within the [Channel](https://www.twilio.com/docs/api/chat/rest/channels).", + "nullable": true, + "type": "integer" + }, + "RoleSid": { + "description": "The SID of the [Role](https://www.twilio.com/docs/api/chat/rest/roles) to assign to the member. The default roles are those specified on the [Service](https://www.twilio.com/docs/chat/api/services).", + "maxLength": 34, + "minLength": 34, + "pattern": "^RL[0-9a-fA-F]{32}$", + "type": "string" + } + }, + "type": "object" + } + } + } + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/chat.v1.service.channel.member" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "servers": [ + { + "url": "https://chat.twilio.com" + } + ], + "x-default-output-properties": [ + "sid", + "identity", + "date_created" + ], + "x-path-type": "instance" + }, + "/v1/Services/{ServiceSid}/Channels/{ChannelSid}/Messages": { + "description": "Individual chat messages", + "get": { + "description": "", + "parameters": [ + { + "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to read the resources from.", + "in": "path", + "name": "ServiceSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) the message to read belongs to. Can be the Channel's `sid` or `unique_name`.", + "in": "path", + "name": "ChannelSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^CH[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The sort order of the returned messages. Can be: `asc` (ascending) or `desc` (descending) with `asc` as the default.", + "in": "query", + "name": "Order", + "schema": { + "enum": [ + "asc", + "desc" + ], + "type": "string" + } + }, + { + "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", + "in": "query", + "name": "PageSize", + "schema": { + "maximum": 1000, + "minimum": 1, + "type": "integer" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "properties": { + "messages": { + "items": { + "$ref": "#/components/schemas/chat.v1.service.channel.message" + }, + "type": "array" + }, + "meta": { + "properties": { + "first_page_url": { + "format": "uri", + "type": "string" + }, + "key": { + "type": "string" + }, + "next_page_url": { + "format": "uri", + "type": "string" + }, + "page": { + "type": "integer" + }, + "page_size": { + "type": "integer" + }, + "previous_page_url": { + "format": "uri", + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + } + }, + "type": "object" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "post": { + "description": "", + "parameters": [ + { + "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to create the resource under.", + "in": "path", + "name": "ServiceSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) the new resource belongs to. Can be the Channel resource's `sid` or `unique_name`.", + "in": "path", + "name": "ChannelSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^CH[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "schema": { + "properties": { + "Attributes": { + "description": "A valid JSON string that contains application-specific data.", + "type": "string" + }, + "Body": { + "description": "The message to send to the channel. Can also be an empty string or `null`, which sets the value as an empty string. You can send structured data in the body by serializing it as a string.", + "type": "string" + }, + "From": { + "description": "The [identity](https://www.twilio.com/docs/api/chat/guides/identity) of the new message's author. The default value is `system`.", + "type": "string" + } + }, + "required": [ + "Body" + ], + "type": "object" + } + } + } + }, + "responses": { + "201": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/chat.v1.service.channel.message" + } + } + }, + "description": "Created" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "servers": [ + { + "url": "https://chat.twilio.com" + } + ], + "x-default-output-properties": [ + "sid", + "from", + "to", + "date_created" + ], + "x-path-type": "list" + }, + "/v1/Services/{ServiceSid}/Channels/{ChannelSid}/Messages/{Sid}": { + "delete": { + "description": "", + "parameters": [ + { + "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to delete the resource from.", + "in": "path", + "name": "ServiceSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) the message to delete belongs to. Can be the Channel resource's `sid` or `unique_name`.", + "in": "path", + "name": "ChannelSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^CH[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The Twilio-provided string that uniquely identifies the Message resource to delete.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IM[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "responses": { + "204": { + "description": "The resource was deleted successfully." + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "description": "Individual chat messages", + "get": { + "description": "", + "parameters": [ + { + "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to fetch the resource from.", + "in": "path", + "name": "ServiceSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) the message to fetch belongs to. Can be the Channel's `sid` or `unique_name`.", + "in": "path", + "name": "ChannelSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^CH[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The Twilio-provided string that uniquely identifies the Message resource to fetch.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IM[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/chat.v1.service.channel.message" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "post": { + "description": "", + "parameters": [ + { + "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to update the resource from.", + "in": "path", + "name": "ServiceSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) the message belongs to. Can be the Channel's `sid` or `unique_name`.", + "in": "path", + "name": "ChannelSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^CH[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The Twilio-provided string that uniquely identifies the Message resource to update.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IM[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "schema": { + "properties": { + "Attributes": { + "description": "A valid JSON string that contains application-specific data.", + "type": "string" + }, + "Body": { + "description": "The message to send to the channel. Can also be an empty string or `null`, which sets the value as an empty string. You can send structured data in the body by serializing it as a string.", + "type": "string" + } + }, + "type": "object" + } + } + } + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/chat.v1.service.channel.message" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "servers": [ + { + "url": "https://chat.twilio.com" + } + ], + "x-default-output-properties": [ + "sid", + "from", + "to", + "date_created" + ], + "x-path-type": "instance" + }, + "/v1/Services/{ServiceSid}/Channels/{Sid}": { + "delete": { + "description": "", + "parameters": [ + { + "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to delete the resource from.", + "in": "path", + "name": "ServiceSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The Twilio-provided string that uniquely identifies the Channel resource to delete.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "type": "string" + } + } + ], + "responses": { + "204": { + "description": "The resource was deleted successfully." + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "description": "Channels represent chat rooms", + "get": { + "description": "", + "parameters": [ + { + "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to fetch the resource from.", + "in": "path", + "name": "ServiceSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The Twilio-provided string that uniquely identifies the Channel resource to fetch.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "type": "string" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/chat.v1.service.channel" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "post": { + "description": "", + "parameters": [ + { + "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to update the resource from.", + "in": "path", + "name": "ServiceSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The Twilio-provided string that uniquely identifies the Channel resource to update.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "schema": { + "properties": { + "Attributes": { + "description": "A valid JSON string that contains application-specific data.", + "type": "string" + }, + "FriendlyName": { + "description": "A descriptive string that you create to describe the resource. It can be up to 64 characters long.", + "type": "string" + }, + "UniqueName": { + "description": "An application-defined string that uniquely identifies the resource. It can be used to address the resource in place of the resource's `sid` in the URL. This value must be 64 characters or less in length and be unique within the Service.", + "type": "string" + } + }, + "type": "object" + } + } + } + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/chat.v1.service.channel" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "servers": [ + { + "url": "https://chat.twilio.com" + } + ], + "x-default-output-properties": [ + "sid", + "unique_name", + "friendly_name" + ], + "x-path-type": "instance" + }, + "/v1/Services/{ServiceSid}/Roles": { + "description": "Roles determining user or member permissions", + "get": { + "description": "", + "parameters": [ + { + "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to read the resources from.", + "in": "path", + "name": "ServiceSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", + "in": "query", + "name": "PageSize", + "schema": { + "maximum": 1000, + "minimum": 1, + "type": "integer" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "properties": { + "meta": { + "properties": { + "first_page_url": { + "format": "uri", + "type": "string" + }, + "key": { + "type": "string" + }, + "next_page_url": { + "format": "uri", + "type": "string" + }, + "page": { + "type": "integer" + }, + "page_size": { + "type": "integer" + }, + "previous_page_url": { + "format": "uri", + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + }, + "roles": { + "items": { + "$ref": "#/components/schemas/chat.v1.service.role" + }, + "type": "array" + } + }, + "type": "object" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "post": { + "description": "", + "parameters": [ + { + "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to create the resource under.", + "in": "path", + "name": "ServiceSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "schema": { + "properties": { + "FriendlyName": { + "description": "A descriptive string that you create to describe the new resource. It can be up to 64 characters long.", + "type": "string" + }, + "Permission": { + "description": "A permission that you grant to the new role. Only one permission can be granted per parameter. To assign more than one permission, repeat this parameter for each permission value. The values for this parameter depend on the role's `type` and are described in the documentation.", + "items": { + "type": "string" + }, + "type": "array" + }, + "Type": { + "description": "The type of role. Can be: `channel` for [Channel](https://www.twilio.com/docs/chat/api/channels) roles or `deployment` for [Service](https://www.twilio.com/docs/chat/api/services) roles.", + "enum": [ + "channel", + "deployment" + ], + "type": "string" + } + }, + "required": [ + "FriendlyName", + "Type", + "Permission" + ], + "type": "object" + } + } + } + }, + "responses": { + "201": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/chat.v1.service.role" + } + } + }, + "description": "Created" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "servers": [ + { + "url": "https://chat.twilio.com" + } + ], + "x-default-output-properties": [ + "sid", + "friendly_name", + "type" + ], + "x-path-type": "list" + }, + "/v1/Services/{ServiceSid}/Roles/{Sid}": { + "delete": { + "description": "", + "parameters": [ + { + "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to delete the resource from.", + "in": "path", + "name": "ServiceSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The Twilio-provided string that uniquely identifies the Role resource to delete.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^RL[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "responses": { + "204": { + "description": "The resource was deleted successfully." + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "description": "Roles determining user or member permissions", + "get": { + "description": "", + "parameters": [ + { + "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to fetch the resource from.", + "in": "path", + "name": "ServiceSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The Twilio-provided string that uniquely identifies the Role resource to fetch.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^RL[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/chat.v1.service.role" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "post": { + "description": "", + "parameters": [ + { + "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to update the resource from.", + "in": "path", + "name": "ServiceSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The Twilio-provided string that uniquely identifies the Role resource to update.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^RL[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "schema": { + "properties": { + "Permission": { + "description": "A permission that you grant to the role. Only one permission can be granted per parameter. To assign more than one permission, repeat this parameter for each permission value. The values for this parameter depend on the role's `type` and are described in the documentation.", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "required": [ + "Permission" + ], + "type": "object" + } + } + } + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/chat.v1.service.role" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "servers": [ + { + "url": "https://chat.twilio.com" + } + ], + "x-default-output-properties": [ + "sid", + "friendly_name", + "type" + ], + "x-path-type": "instance" + }, + "/v1/Services/{ServiceSid}/Users": { + "description": "Unique chat users within a chat service", + "get": { + "description": "", + "parameters": [ + { + "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to read the resources from.", + "in": "path", + "name": "ServiceSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", + "in": "query", + "name": "PageSize", + "schema": { + "maximum": 1000, + "minimum": 1, + "type": "integer" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "properties": { + "meta": { + "properties": { + "first_page_url": { + "format": "uri", + "type": "string" + }, + "key": { + "type": "string" + }, + "next_page_url": { + "format": "uri", + "type": "string" + }, + "page": { + "type": "integer" + }, + "page_size": { + "type": "integer" + }, + "previous_page_url": { + "format": "uri", + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + }, + "users": { + "items": { + "$ref": "#/components/schemas/chat.v1.service.user" + }, + "type": "array" + } + }, + "type": "object" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "post": { + "description": "", + "parameters": [ + { + "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to create the resource under.", + "in": "path", + "name": "ServiceSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "schema": { + "properties": { + "Attributes": { + "description": "A valid JSON string that contains application-specific data.", + "type": "string" + }, + "FriendlyName": { + "description": "A descriptive string that you create to describe the new resource. This value is often used for display purposes.", + "type": "string" + }, + "Identity": { + "description": "The `identity` value that uniquely identifies the new resource's [User](https://www.twilio.com/docs/api/chat/rest/v1/user) within the [Service](https://www.twilio.com/docs/api/chat/rest/v1/service). This value is often a username or email address. See the Identity documentation for more details.", + "type": "string" + }, + "RoleSid": { + "description": "The SID of the [Role](https://www.twilio.com/docs/api/chat/rest/roles) assigned to the new User.", + "maxLength": 34, + "minLength": 34, + "pattern": "^RL[0-9a-fA-F]{32}$", + "type": "string" + } + }, + "required": [ + "Identity" + ], + "type": "object" + } + } + } + }, + "responses": { + "201": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/chat.v1.service.user" + } + } + }, + "description": "Created" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "servers": [ + { + "url": "https://chat.twilio.com" + } + ], + "x-default-output-properties": [ + "sid", + "friendly_name", + "date_created" + ], + "x-path-type": "list" + }, + "/v1/Services/{ServiceSid}/Users/{Sid}": { + "delete": { + "description": "", + "parameters": [ + { + "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to delete the resource from.", + "in": "path", + "name": "ServiceSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The Twilio-provided string that uniquely identifies the User resource to delete.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "type": "string" + } + } + ], + "responses": { + "204": { + "description": "The resource was deleted successfully." + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "description": "Unique chat users within a chat service", + "get": { + "description": "", + "parameters": [ + { + "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to fetch the resource from.", + "in": "path", + "name": "ServiceSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The Twilio-provided string that uniquely identifies the User resource to fetch.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "type": "string" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/chat.v1.service.user" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "post": { + "description": "", + "parameters": [ + { + "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to update the resource from.", + "in": "path", + "name": "ServiceSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The Twilio-provided string that uniquely identifies the User resource to update.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "schema": { + "properties": { + "Attributes": { + "description": "A valid JSON string that contains application-specific data.", + "type": "string" + }, + "FriendlyName": { + "description": "A descriptive string that you create to describe the resource. It is often used for display purposes.", + "type": "string" + }, + "RoleSid": { + "description": "The SID of the [Role](https://www.twilio.com/docs/api/chat/rest/roles) assigned to this user.", + "maxLength": 34, + "minLength": 34, + "pattern": "^RL[0-9a-fA-F]{32}$", + "type": "string" + } + }, + "type": "object" + } + } + } + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/chat.v1.service.user" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "servers": [ + { + "url": "https://chat.twilio.com" + } + ], + "x-default-output-properties": [ + "sid", + "friendly_name", + "date_created" + ], + "x-path-type": "instance" + }, + "/v1/Services/{ServiceSid}/Users/{UserSid}/Channels": { + "description": "TODO: Resource-level docs", + "get": { + "description": "List all Channels for a given User.", + "parameters": [ + { + "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to read the resources from.", + "in": "path", + "name": "ServiceSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The SID of the [User](https://www.twilio.com/docs/api/chat/rest/users) to read the User Channel resources from.", + "in": "path", + "name": "UserSid", + "required": true, + "schema": { + "type": "string" + } + }, + { + "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", + "in": "query", + "name": "PageSize", + "schema": { + "maximum": 1000, + "minimum": 1, + "type": "integer" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "properties": { + "channels": { + "items": { + "$ref": "#/components/schemas/chat.v1.service.user.user_channel" + }, + "type": "array" + }, + "meta": { + "properties": { + "first_page_url": { + "format": "uri", + "type": "string" + }, + "key": { + "type": "string" + }, + "next_page_url": { + "format": "uri", + "type": "string" + }, + "page": { + "type": "integer" + }, + "page_size": { + "type": "integer" + }, + "previous_page_url": { + "format": "uri", + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + } + }, + "type": "object" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "servers": [ + { + "url": "https://chat.twilio.com" + } + ], + "x-default-output-properties": [ + "channel_sid", + "status" + ], + "x-path-type": "list" + }, + "/v1/Services/{Sid}": { + "delete": { + "description": "", + "parameters": [ + { + "description": "The Twilio-provided string that uniquely identifies the Service resource to delete.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "responses": { + "204": { + "description": "The resource was deleted successfully." + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "description": "Top level scope for all chat resources", + "get": { + "description": "", + "parameters": [ + { + "description": "The Twilio-provided string that uniquely identifies the Service resource to fetch.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/chat.v1.service" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "post": { + "description": "", + "parameters": [ + { + "description": "The Twilio-provided string that uniquely identifies the Service resource to update.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "schema": { + "properties": { + "ConsumptionReportInterval": { + "description": "DEPRECATED. The interval in seconds between consumption reports submission batches from client endpoints.", + "type": "integer" + }, + "DefaultChannelCreatorRoleSid": { + "description": "The channel role assigned to a channel creator when they join a new channel. See the [Roles endpoint](https://www.twilio.com/docs/chat/api/roles) for more details.", + "maxLength": 34, + "minLength": 34, + "pattern": "^RL[0-9a-fA-F]{32}$", + "type": "string" + }, + "DefaultChannelRoleSid": { + "description": "The channel role assigned to users when they are added to a channel. See the [Roles endpoint](https://www.twilio.com/docs/chat/api/roles) for more details.", + "maxLength": 34, + "minLength": 34, + "pattern": "^RL[0-9a-fA-F]{32}$", + "type": "string" + }, + "DefaultServiceRoleSid": { + "description": "The service role assigned to users when they are added to the service. See the [Roles endpoint](https://www.twilio.com/docs/chat/api/roles) for more details.", + "maxLength": 34, + "minLength": 34, + "pattern": "^RL[0-9a-fA-F]{32}$", + "type": "string" + }, + "FriendlyName": { + "description": "A descriptive string that you create to describe the resource. It can be up to 64 characters long.", + "type": "string" + }, + "Limits.ChannelMembers": { + "description": "The maximum number of Members that can be added to Channels within this Service. Can be up to 1,000.", + "type": "integer" + }, + "Limits.UserChannels": { + "description": "The maximum number of Channels Users can be a Member of within this Service. Can be up to 1,000.", + "type": "integer" + }, + "Notifications.AddedToChannel.Enabled": { + "description": "Whether to send a notification when a member is added to a channel. Can be: `true` or `false` and the default is `false`.", + "type": "boolean" + }, + "Notifications.AddedToChannel.Template": { + "description": "The template to use to create the notification text displayed when a member is added to a channel and `notifications.added_to_channel.enabled` is `true`.", + "type": "string" + }, + "Notifications.InvitedToChannel.Enabled": { + "description": "Whether to send a notification when a user is invited to a channel. Can be: `true` or `false` and the default is `false`.", + "type": "boolean" + }, + "Notifications.InvitedToChannel.Template": { + "description": "The template to use to create the notification text displayed when a user is invited to a channel and `notifications.invited_to_channel.enabled` is `true`.", + "type": "string" + }, + "Notifications.NewMessage.Enabled": { + "description": "Whether to send a notification when a new message is added to a channel. Can be: `true` or `false` and the default is `false`.", + "type": "boolean" + }, + "Notifications.NewMessage.Template": { + "description": "The template to use to create the notification text displayed when a new message is added to a channel and `notifications.new_message.enabled` is `true`.", + "type": "string" + }, + "Notifications.RemovedFromChannel.Enabled": { + "description": "Whether to send a notification to a user when they are removed from a channel. Can be: `true` or `false` and the default is `false`.", + "type": "boolean" + }, + "Notifications.RemovedFromChannel.Template": { + "description": "The template to use to create the notification text displayed to a user when they are removed from a channel and `notifications.removed_from_channel.enabled` is `true`.", + "type": "string" + }, + "PostWebhookUrl": { + "description": "The URL for post-event webhooks, which are called by using the `webhook_method`. See [Webhook Events](https://www.twilio.com/docs/api/chat/webhooks) for more details.", + "format": "uri", + "type": "string" + }, + "PreWebhookUrl": { + "description": "The URL for pre-event webhooks, which are called by using the `webhook_method`. See [Webhook Events](https://www.twilio.com/docs/api/chat/webhooks) for more details.", + "format": "uri", + "type": "string" + }, + "ReachabilityEnabled": { + "description": "Whether to enable the [Reachability Indicator](https://www.twilio.com/docs/chat/reachability-indicator) for this Service instance. The default is `false`.", + "type": "boolean" + }, + "ReadStatusEnabled": { + "description": "Whether to enable the [Message Consumption Horizon](https://www.twilio.com/docs/chat/consumption-horizon) feature. The default is `true`.", + "type": "boolean" + }, + "TypingIndicatorTimeout": { + "description": "How long in seconds after a `started typing` event until clients should assume that user is no longer typing, even if no `ended typing` message was received. The default is 5 seconds.", + "type": "integer" + }, + "WebhookFilters": { + "description": "The list of WebHook events that are enabled for this Service instance. See [Webhook Events](https://www.twilio.com/docs/chat/webhook-events) for more details.", + "items": { + "type": "string" + }, + "type": "array" + }, + "WebhookMethod": { + "description": "The HTTP method to use for calls to the `pre_webhook_url` and `post_webhook_url` webhooks. Can be: `POST` or `GET` and the default is `POST`. See [Webhook Events](https://www.twilio.com/docs/chat/webhook-events) for more details.", + "enum": [ + "head", + "get", + "post", + "patch", + "put", + "delete", + "HEAD", + "GET", + "POST", + "PATCH", + "PUT", + "DELETE" + ], + "type": "string" + }, + "Webhooks.OnChannelAdd.Method": { + "description": "The HTTP method to use when calling the `webhooks.on_channel_add.url`.", + "enum": [ + "head", + "get", + "post", + "patch", + "put", + "delete", + "HEAD", + "GET", + "POST", + "PATCH", + "PUT", + "DELETE" + ], + "type": "string" + }, + "Webhooks.OnChannelAdd.Url": { + "description": "The URL of the webhook to call in response to the `on_channel_add` event using the `webhooks.on_channel_add.method` HTTP method.", + "format": "uri", + "type": "string" + }, + "Webhooks.OnChannelAdded.Method": { + "description": "The URL of the webhook to call in response to the `on_channel_added` event`.", + "enum": [ + "head", + "get", + "post", + "patch", + "put", + "delete", + "HEAD", + "GET", + "POST", + "PATCH", + "PUT", + "DELETE" + ], + "type": "string" + }, + "Webhooks.OnChannelAdded.Url": { + "description": "The URL of the webhook to call in response to the `on_channel_added` event using the `webhooks.on_channel_added.method` HTTP method.", + "format": "uri", + "type": "string" + }, + "Webhooks.OnChannelDestroy.Method": { + "description": "The HTTP method to use when calling the `webhooks.on_channel_destroy.url`.", + "enum": [ + "head", + "get", + "post", + "patch", + "put", + "delete", + "HEAD", + "GET", + "POST", + "PATCH", + "PUT", + "DELETE" + ], + "type": "string" + }, + "Webhooks.OnChannelDestroy.Url": { + "description": "The URL of the webhook to call in response to the `on_channel_destroy` event using the `webhooks.on_channel_destroy.method` HTTP method.", + "format": "uri", + "type": "string" + }, + "Webhooks.OnChannelDestroyed.Method": { + "description": "The HTTP method to use when calling the `webhooks.on_channel_destroyed.url`.", + "enum": [ + "head", + "get", + "post", + "patch", + "put", + "delete", + "HEAD", + "GET", + "POST", + "PATCH", + "PUT", + "DELETE" + ], + "type": "string" + }, + "Webhooks.OnChannelDestroyed.Url": { + "description": "The URL of the webhook to call in response to the `on_channel_added` event using the `webhooks.on_channel_destroyed.method` HTTP method.", + "format": "uri", + "type": "string" + }, + "Webhooks.OnChannelUpdate.Method": { + "description": "The HTTP method to use when calling the `webhooks.on_channel_update.url`.", + "enum": [ + "head", + "get", + "post", + "patch", + "put", + "delete", + "HEAD", + "GET", + "POST", + "PATCH", + "PUT", + "DELETE" + ], + "type": "string" + }, + "Webhooks.OnChannelUpdate.Url": { + "description": "The URL of the webhook to call in response to the `on_channel_update` event using the `webhooks.on_channel_update.method` HTTP method.", + "format": "uri", + "type": "string" + }, + "Webhooks.OnChannelUpdated.Method": { + "description": "The HTTP method to use when calling the `webhooks.on_channel_updated.url`.", + "enum": [ + "head", + "get", + "post", + "patch", + "put", + "delete", + "HEAD", + "GET", + "POST", + "PATCH", + "PUT", + "DELETE" + ], + "type": "string" + }, + "Webhooks.OnChannelUpdated.Url": { + "description": "The URL of the webhook to call in response to the `on_channel_updated` event using the `webhooks.on_channel_updated.method` HTTP method.", + "format": "uri", + "type": "string" + }, + "Webhooks.OnMemberAdd.Method": { + "description": "The HTTP method to use when calling the `webhooks.on_member_add.url`.", + "enum": [ + "head", + "get", + "post", + "patch", + "put", + "delete", + "HEAD", + "GET", + "POST", + "PATCH", + "PUT", + "DELETE" + ], + "type": "string" + }, + "Webhooks.OnMemberAdd.Url": { + "description": "The URL of the webhook to call in response to the `on_member_add` event using the `webhooks.on_member_add.method` HTTP method.", + "format": "uri", + "type": "string" + }, + "Webhooks.OnMemberAdded.Method": { + "description": "The HTTP method to use when calling the `webhooks.on_channel_updated.url`.", + "enum": [ + "head", + "get", + "post", + "patch", + "put", + "delete", + "HEAD", + "GET", + "POST", + "PATCH", + "PUT", + "DELETE" + ], + "type": "string" + }, + "Webhooks.OnMemberAdded.Url": { + "description": "The URL of the webhook to call in response to the `on_channel_updated` event using the `webhooks.on_channel_updated.method` HTTP method.", + "format": "uri", + "type": "string" + }, + "Webhooks.OnMemberRemove.Method": { + "description": "The HTTP method to use when calling the `webhooks.on_member_remove.url`.", + "enum": [ + "head", + "get", + "post", + "patch", + "put", + "delete", + "HEAD", + "GET", + "POST", + "PATCH", + "PUT", + "DELETE" + ], + "type": "string" + }, + "Webhooks.OnMemberRemove.Url": { + "description": "The URL of the webhook to call in response to the `on_member_remove` event using the `webhooks.on_member_remove.method` HTTP method.", + "format": "uri", + "type": "string" + }, + "Webhooks.OnMemberRemoved.Method": { + "description": "The HTTP method to use when calling the `webhooks.on_member_removed.url`.", + "enum": [ + "head", + "get", + "post", + "patch", + "put", + "delete", + "HEAD", + "GET", + "POST", + "PATCH", + "PUT", + "DELETE" + ], + "type": "string" + }, + "Webhooks.OnMemberRemoved.Url": { + "description": "The URL of the webhook to call in response to the `on_member_removed` event using the `webhooks.on_member_removed.method` HTTP method.", + "format": "uri", + "type": "string" + }, + "Webhooks.OnMessageRemove.Method": { + "description": "The HTTP method to use when calling the `webhooks.on_message_remove.url`.", + "enum": [ + "head", + "get", + "post", + "patch", + "put", + "delete", + "HEAD", + "GET", + "POST", + "PATCH", + "PUT", + "DELETE" + ], + "type": "string" + }, + "Webhooks.OnMessageRemove.Url": { + "description": "The URL of the webhook to call in response to the `on_message_remove` event using the `webhooks.on_message_remove.method` HTTP method.", + "format": "uri", + "type": "string" + }, + "Webhooks.OnMessageRemoved.Method": { + "description": "The HTTP method to use when calling the `webhooks.on_message_removed.url`.", + "enum": [ + "head", + "get", + "post", + "patch", + "put", + "delete", + "HEAD", + "GET", + "POST", + "PATCH", + "PUT", + "DELETE" + ], + "type": "string" + }, + "Webhooks.OnMessageRemoved.Url": { + "description": "The URL of the webhook to call in response to the `on_message_removed` event using the `webhooks.on_message_removed.method` HTTP method.", + "format": "uri", + "type": "string" + }, + "Webhooks.OnMessageSend.Method": { + "description": "The HTTP method to use when calling the `webhooks.on_message_send.url`.", + "enum": [ + "head", + "get", + "post", + "patch", + "put", + "delete", + "HEAD", + "GET", + "POST", + "PATCH", + "PUT", + "DELETE" + ], + "type": "string" + }, + "Webhooks.OnMessageSend.Url": { + "description": "The URL of the webhook to call in response to the `on_message_send` event using the `webhooks.on_message_send.method` HTTP method.", + "format": "uri", + "type": "string" + }, + "Webhooks.OnMessageSent.Method": { + "description": "The URL of the webhook to call in response to the `on_message_sent` event`.", + "enum": [ + "head", + "get", + "post", + "patch", + "put", + "delete", + "HEAD", + "GET", + "POST", + "PATCH", + "PUT", + "DELETE" + ], + "type": "string" + }, + "Webhooks.OnMessageSent.Url": { + "description": "The URL of the webhook to call in response to the `on_message_sent` event using the `webhooks.on_message_sent.method` HTTP method.", + "format": "uri", + "type": "string" + }, + "Webhooks.OnMessageUpdate.Method": { + "description": "The HTTP method to use when calling the `webhooks.on_message_update.url`.", + "enum": [ + "head", + "get", + "post", + "patch", + "put", + "delete", + "HEAD", + "GET", + "POST", + "PATCH", + "PUT", + "DELETE" + ], + "type": "string" + }, + "Webhooks.OnMessageUpdate.Url": { + "description": "The URL of the webhook to call in response to the `on_message_update` event using the `webhooks.on_message_update.method` HTTP method.", + "format": "uri", + "type": "string" + }, + "Webhooks.OnMessageUpdated.Method": { + "description": "The HTTP method to use when calling the `webhooks.on_message_updated.url`.", + "enum": [ + "head", + "get", + "post", + "patch", + "put", + "delete", + "HEAD", + "GET", + "POST", + "PATCH", + "PUT", + "DELETE" + ], + "type": "string" + }, + "Webhooks.OnMessageUpdated.Url": { + "description": "The URL of the webhook to call in response to the `on_message_updated` event using the `webhooks.on_message_updated.method` HTTP method.", + "format": "uri", + "type": "string" + } + }, + "type": "object" + } + } + } + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/chat.v1.service" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "servers": [ + { + "url": "https://chat.twilio.com" + } + ], + "x-default-output-properties": [ + "sid", + "friendly_name", + "date_created" + ], + "x-path-type": "instance" + } + }, + "tags": [ + { + "description": "This product is Generally Available.", + "name": "GA" + } + ] +} \ No newline at end of file diff --git a/spec/json/twilio_chat.json b/spec/json/twilio_chat_v2.json similarity index 57% rename from spec/json/twilio_chat.json rename to spec/json/twilio_chat_v2.json index a14b5977..b48df12a 100644 --- a/spec/json/twilio_chat.json +++ b/spec/json/twilio_chat_v2.json @@ -1,7 +1,7 @@ { "components": { "schemas": { - "chat.v1.credential": { + "chat.v2.credential": { "properties": { "account_sid": { "maxLength": 34, @@ -44,7 +44,7 @@ }, "type": "object" }, - "chat.v1.service": { + "chat.v2.service": { "properties": { "account_sid": { "maxLength": 34, @@ -90,12 +90,21 @@ "links": { "type": "object" }, + "media": { + "type": "object" + }, "notifications": { "type": "object" }, + "post_webhook_retry_count": { + "type": "integer" + }, "post_webhook_url": { "type": "string" }, + "pre_webhook_retry_count": { + "type": "integer" + }, "pre_webhook_url": { "type": "string" }, @@ -126,14 +135,75 @@ }, "webhook_method": { "type": "string" + } + }, + "type": "object" + }, + "chat.v2.service.binding": { + "properties": { + "account_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^AC[0-9a-fA-F]{32}$", + "type": "string" + }, + "binding_type": { + "enum": [ + "gcm", + "apn", + "fcm" + ], + "type": "string" + }, + "credential_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^CR[0-9a-fA-F]{32}$", + "type": "string" + }, + "date_created": { + "format": "date-time", + "type": "string" + }, + "date_updated": { + "format": "date-time", + "type": "string" + }, + "endpoint": { + "type": "string" + }, + "identity": { + "type": "string" }, - "webhooks": { + "links": { "type": "object" + }, + "message_types": { + "items": { + "type": "string" + }, + "type": "array" + }, + "service_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + }, + "sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^BS[0-9a-fA-F]{32}$", + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" } }, "type": "object" }, - "chat.v1.service.channel": { + "chat.v2.service.channel": { "properties": { "account_sid": { "maxLength": 34, @@ -196,7 +266,54 @@ }, "type": "object" }, - "chat.v1.service.channel.invite": { + "chat.v2.service.channel.channel_webhook": { + "properties": { + "account_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^AC[0-9a-fA-F]{32}$", + "type": "string" + }, + "channel_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^CH[0-9a-fA-F]{32}$", + "type": "string" + }, + "configuration": { + "type": "object" + }, + "date_created": { + "format": "date-time", + "type": "string" + }, + "date_updated": { + "format": "date-time", + "type": "string" + }, + "service_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + }, + "sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^WH[0-9a-fA-F]{32}$", + "type": "string" + }, + "type": { + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + }, + "chat.v2.service.channel.invite": { "properties": { "account_sid": { "maxLength": 34, @@ -249,7 +366,7 @@ }, "type": "object" }, - "chat.v1.service.channel.member": { + "chat.v2.service.channel.member": { "properties": { "account_sid": { "maxLength": 34, @@ -257,6 +374,9 @@ "pattern": "^AC[0-9a-fA-F]{32}$", "type": "string" }, + "attributes": { + "type": "string" + }, "channel_sid": { "maxLength": 34, "minLength": 34, @@ -307,7 +427,7 @@ }, "type": "object" }, - "chat.v1.service.channel.message": { + "chat.v2.service.channel.message": { "properties": { "account_sid": { "maxLength": 34, @@ -341,6 +461,12 @@ "index": { "type": "integer" }, + "last_updated_by": { + "type": "string" + }, + "media": { + "type": "object" + }, "service_sid": { "maxLength": 34, "minLength": 34, @@ -359,6 +485,9 @@ "pattern": "^CH[0-9a-fA-F]{32}$", "type": "string" }, + "type": { + "type": "string" + }, "url": { "format": "uri", "type": "string" @@ -369,7 +498,7 @@ }, "type": "object" }, - "chat.v1.service.role": { + "chat.v2.service.role": { "properties": { "account_sid": { "maxLength": 34, @@ -420,7 +549,7 @@ }, "type": "object" }, - "chat.v1.service.user": { + "chat.v2.service.user": { "properties": { "account_sid": { "maxLength": 34, @@ -482,7 +611,7 @@ }, "type": "object" }, - "chat.v1.service.user.user_channel": { + "chat.v2.service.user.user_binding": { "properties": { "account_sid": { "maxLength": 34, @@ -490,52 +619,18 @@ "pattern": "^AC[0-9a-fA-F]{32}$", "type": "string" }, - "channel_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^CH[0-9a-fA-F]{32}$", - "type": "string" - }, - "last_consumed_message_index": { - "nullable": true, - "type": "integer" - }, - "links": { - "type": "object" - }, - "member_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^MB[0-9a-fA-F]{32}$", - "type": "string" - }, - "service_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - }, - "status": { + "binding_type": { "enum": [ - "joined", - "invited", - "not_participating" + "gcm", + "apn", + "fcm" ], "type": "string" }, - "unread_messages_count": { - "nullable": true, - "type": "integer" - } - }, - "type": "object" - }, - "chat.v2.credential": { - "properties": { - "account_sid": { + "credential_sid": { "maxLength": 34, "minLength": 34, - "pattern": "^AC[0-9a-fA-F]{32}$", + "pattern": "^CR[0-9a-fA-F]{32}$", "type": "string" }, "date_created": { @@ -546,34 +641,44 @@ "format": "date-time", "type": "string" }, - "friendly_name": { + "endpoint": { "type": "string" }, - "sandbox": { + "identity": { "type": "string" }, - "sid": { + "message_types": { + "items": { + "type": "string" + }, + "type": "array" + }, + "service_sid": { "maxLength": 34, "minLength": 34, - "pattern": "^CR[0-9a-fA-F]{32}$", + "pattern": "^IS[0-9a-fA-F]{32}$", "type": "string" }, - "type": { - "enum": [ - "gcm", - "apn", - "fcm" - ], + "sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^BS[0-9a-fA-F]{32}$", "type": "string" }, "url": { "format": "uri", "type": "string" + }, + "user_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^US[0-9a-fA-F]{32}$", + "type": "string" } }, "type": "object" }, - "chat.v2.service": { + "chat.v2.service.user.user_channel": { "properties": { "account_sid": { "maxLength": 34, @@ -581,4032 +686,88 @@ "pattern": "^AC[0-9a-fA-F]{32}$", "type": "string" }, - "consumption_report_interval": { - "type": "integer" - }, - "date_created": { - "format": "date-time", + "channel_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^CH[0-9a-fA-F]{32}$", "type": "string" }, - "date_updated": { - "format": "date-time", - "type": "string" + "last_consumed_message_index": { + "nullable": true, + "type": "integer" }, - "default_channel_creator_role_sid": { + "links": { + "type": "object" + }, + "member_sid": { "maxLength": 34, "minLength": 34, - "pattern": "^RL[0-9a-fA-F]{32}$", + "pattern": "^MB[0-9a-fA-F]{32}$", "type": "string" }, - "default_channel_role_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^RL[0-9a-fA-F]{32}$", + "notification_level": { + "enum": [ + "default", + "muted" + ], "type": "string" }, - "default_service_role_sid": { + "service_sid": { "maxLength": 34, "minLength": 34, - "pattern": "^RL[0-9a-fA-F]{32}$", - "type": "string" - }, - "friendly_name": { + "pattern": "^IS[0-9a-fA-F]{32}$", "type": "string" }, - "limits": { - "type": "object" - }, - "links": { - "type": "object" - }, - "media": { - "type": "object" - }, - "notifications": { - "type": "object" - }, - "post_webhook_retry_count": { - "type": "integer" - }, - "post_webhook_url": { - "type": "string" - }, - "pre_webhook_retry_count": { - "type": "integer" - }, - "pre_webhook_url": { - "type": "string" - }, - "reachability_enabled": { - "type": "boolean" - }, - "read_status_enabled": { - "type": "boolean" - }, - "sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - }, - "typing_indicator_timeout": { - "type": "integer" - }, - "url": { - "format": "uri", - "type": "string" - }, - "webhook_filters": { - "items": { - "type": "string" - }, - "type": "array" - }, - "webhook_method": { - "type": "string" - } - }, - "type": "object" - }, - "chat.v2.service.binding": { - "properties": { - "account_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^AC[0-9a-fA-F]{32}$", - "type": "string" - }, - "binding_type": { + "status": { "enum": [ - "gcm", - "apn", - "fcm" + "joined", + "invited", + "not_participating" ], "type": "string" }, - "credential_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^CR[0-9a-fA-F]{32}$", - "type": "string" - }, - "date_created": { - "format": "date-time", - "type": "string" - }, - "date_updated": { - "format": "date-time", - "type": "string" - }, - "endpoint": { - "type": "string" - }, - "identity": { - "type": "string" - }, - "links": { - "type": "object" - }, - "message_types": { - "items": { - "type": "string" - }, - "type": "array" - }, - "service_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - }, - "sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^BS[0-9a-fA-F]{32}$", - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - }, - "chat.v2.service.channel": { - "properties": { - "account_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^AC[0-9a-fA-F]{32}$", - "type": "string" - }, - "attributes": { - "type": "string" - }, - "created_by": { - "type": "string" - }, - "date_created": { - "format": "date-time", - "type": "string" - }, - "date_updated": { - "format": "date-time", - "type": "string" - }, - "friendly_name": { - "type": "string" - }, - "links": { - "type": "object" - }, - "members_count": { - "type": "integer" - }, - "messages_count": { + "unread_messages_count": { + "nullable": true, "type": "integer" }, - "service_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - }, - "sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^CH[0-9a-fA-F]{32}$", - "type": "string" - }, - "type": { - "enum": [ - "public", - "private" - ], - "type": "string" - }, - "unique_name": { - "type": "string" - }, "url": { "format": "uri", "type": "string" - } - }, - "type": "object" - }, - "chat.v2.service.channel.channel_webhook": { - "properties": { - "account_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^AC[0-9a-fA-F]{32}$", - "type": "string" - }, - "channel_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^CH[0-9a-fA-F]{32}$", - "type": "string" - }, - "configuration": { - "type": "object" - }, - "date_created": { - "format": "date-time", - "type": "string" - }, - "date_updated": { - "format": "date-time", - "type": "string" - }, - "service_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" }, - "sid": { + "user_sid": { "maxLength": 34, "minLength": 34, - "pattern": "^WH[0-9a-fA-F]{32}$", - "type": "string" - }, - "type": { - "type": "string" - }, - "url": { - "format": "uri", + "pattern": "^US[0-9a-fA-F]{32}$", "type": "string" } }, "type": "object" - }, - "chat.v2.service.channel.invite": { - "properties": { - "account_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^AC[0-9a-fA-F]{32}$", - "type": "string" - }, - "channel_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^CH[0-9a-fA-F]{32}$", - "type": "string" - }, - "created_by": { - "type": "string" - }, - "date_created": { - "format": "date-time", - "type": "string" - }, - "date_updated": { - "format": "date-time", - "type": "string" - }, - "identity": { - "type": "string" - }, - "role_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^RL[0-9a-fA-F]{32}$", - "type": "string" - }, - "service_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - }, - "sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IN[0-9a-fA-F]{32}$", - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - }, - "chat.v2.service.channel.member": { - "properties": { - "account_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^AC[0-9a-fA-F]{32}$", - "type": "string" - }, - "attributes": { - "type": "string" - }, - "channel_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^CH[0-9a-fA-F]{32}$", - "type": "string" - }, - "date_created": { - "format": "date-time", - "type": "string" - }, - "date_updated": { - "format": "date-time", - "type": "string" - }, - "identity": { - "type": "string" - }, - "last_consumed_message_index": { - "nullable": true, - "type": "integer" - }, - "last_consumption_timestamp": { - "format": "date-time", - "type": "string" - }, - "role_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^RL[0-9a-fA-F]{32}$", - "type": "string" - }, - "service_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - }, - "sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^MB[0-9a-fA-F]{32}$", - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - }, - "chat.v2.service.channel.message": { - "properties": { - "account_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^AC[0-9a-fA-F]{32}$", - "type": "string" - }, - "attributes": { - "type": "string" - }, - "body": { - "type": "string" - }, - "channel_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^CH[0-9a-fA-F]{32}$", - "type": "string" - }, - "date_created": { - "format": "date-time", - "type": "string" - }, - "date_updated": { - "format": "date-time", - "type": "string" - }, - "from": { - "type": "string" - }, - "index": { - "type": "integer" - }, - "last_updated_by": { - "type": "string" - }, - "media": { - "type": "object" - }, - "service_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - }, - "sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IM[0-9a-fA-F]{32}$", - "type": "string" - }, - "to": { - "maxLength": 34, - "minLength": 34, - "pattern": "^CH[0-9a-fA-F]{32}$", - "type": "string" - }, - "type": { - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - }, - "was_edited": { - "type": "boolean" - } - }, - "type": "object" - }, - "chat.v2.service.role": { - "properties": { - "account_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^AC[0-9a-fA-F]{32}$", - "type": "string" - }, - "date_created": { - "format": "date-time", - "type": "string" - }, - "date_updated": { - "format": "date-time", - "type": "string" - }, - "friendly_name": { - "type": "string" - }, - "permissions": { - "items": { - "type": "string" - }, - "type": "array" - }, - "service_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - }, - "sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^RL[0-9a-fA-F]{32}$", - "type": "string" - }, - "type": { - "enum": [ - "channel", - "deployment" - ], - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - }, - "chat.v2.service.user": { - "properties": { - "account_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^AC[0-9a-fA-F]{32}$", - "type": "string" - }, - "attributes": { - "type": "string" - }, - "date_created": { - "format": "date-time", - "type": "string" - }, - "date_updated": { - "format": "date-time", - "type": "string" - }, - "friendly_name": { - "type": "string" - }, - "identity": { - "type": "string" - }, - "is_notifiable": { - "type": "boolean" - }, - "is_online": { - "type": "boolean" - }, - "joined_channels_count": { - "type": "integer" - }, - "links": { - "type": "object" - }, - "role_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^RL[0-9a-fA-F]{32}$", - "type": "string" - }, - "service_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - }, - "sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^US[0-9a-fA-F]{32}$", - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - }, - "chat.v2.service.user.user_binding": { - "properties": { - "account_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^AC[0-9a-fA-F]{32}$", - "type": "string" - }, - "binding_type": { - "enum": [ - "gcm", - "apn", - "fcm" - ], - "type": "string" - }, - "credential_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^CR[0-9a-fA-F]{32}$", - "type": "string" - }, - "date_created": { - "format": "date-time", - "type": "string" - }, - "date_updated": { - "format": "date-time", - "type": "string" - }, - "endpoint": { - "type": "string" - }, - "identity": { - "type": "string" - }, - "message_types": { - "items": { - "type": "string" - }, - "type": "array" - }, - "service_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - }, - "sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^BS[0-9a-fA-F]{32}$", - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - }, - "user_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^US[0-9a-fA-F]{32}$", - "type": "string" - } - }, - "type": "object" - }, - "chat.v2.service.user.user_channel": { - "properties": { - "account_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^AC[0-9a-fA-F]{32}$", - "type": "string" - }, - "channel_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^CH[0-9a-fA-F]{32}$", - "type": "string" - }, - "last_consumed_message_index": { - "nullable": true, - "type": "integer" - }, - "links": { - "type": "object" - }, - "member_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^MB[0-9a-fA-F]{32}$", - "type": "string" - }, - "notification_level": { - "enum": [ - "default", - "muted" - ], - "type": "string" - }, - "service_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - }, - "status": { - "enum": [ - "joined", - "invited", - "not_participating" - ], - "type": "string" - }, - "unread_messages_count": { - "nullable": true, - "type": "integer" - }, - "url": { - "format": "uri", - "type": "string" - }, - "user_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^US[0-9a-fA-F]{32}$", - "type": "string" - } - }, - "type": "object" - } - }, - "securitySchemes": { - "accountSid_authToken": { - "scheme": "basic", - "type": "http" - } - } - }, - "info": { - "contact": { - "email": "support@twilio.com", - "name": "Twilio Support", - "url": "https://support.twilio.com" - }, - "description": "This is the public Twilio REST API.", - "license": { - "name": "Apache 2.0", - "url": "https://www.apache.org/licenses/LICENSE-2.0.html" - }, - "termsOfService": "https://www.twilio.com/legal/tos", - "title": "Twilio - Chat", - "version": "1.3.0" - }, - "openapi": "3.0.1", - "paths": { - "/v1/Credentials": { - "description": "Credentials for push notifications channels", - "get": { - "description": "", - "parameters": [ - { - "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", - "in": "query", - "name": "PageSize", - "schema": { - "maximum": 1000, - "minimum": 1, - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "properties": { - "credentials": { - "items": { - "$ref": "#/components/schemas/chat.v1.credential" - }, - "type": "array" - }, - "meta": { - "properties": { - "first_page_url": { - "format": "uri", - "type": "string" - }, - "key": { - "type": "string" - }, - "next_page_url": { - "format": "uri", - "type": "string" - }, - "page": { - "type": "integer" - }, - "page_size": { - "type": "integer" - }, - "previous_page_url": { - "format": "uri", - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "post": { - "description": "", - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "schema": { - "properties": { - "ApiKey": { - "description": "[GCM only] The API key for the project that was obtained from the Google Developer console for your GCM Service application credential.", - "type": "string" - }, - "Certificate": { - "description": "[APN only] The URL encoded representation of the certificate. For example, \n`-----BEGIN CERTIFICATE-----\nMIIFnTCCBIWgAwIBAgIIAjy9H849+E8wDQYJKoZIhvcNAQEFBQAwgZYxCzAJBgNV.....A==\n-----END CERTIFICATE-----`", - "type": "string" - }, - "FriendlyName": { - "description": "A descriptive string that you create to describe the new resource. It can be up to 64 characters long.", - "type": "string" - }, - "PrivateKey": { - "description": "[APN only] The URL encoded representation of the private key. For example,\n`-----BEGIN RSA PRIVATE KEY-----\nMIIEpQIBAAKCAQEAuyf/lNrH9ck8DmNyo3fGgvCI1l9s+cmBY3WIz+cUDqmxiieR.\n-----END RSA PRIVATE KEY-----`", - "type": "string" - }, - "Sandbox": { - "description": "[APN only] Whether to send the credential to sandbox APNs. Can be `true` to send to sandbox APNs or `false` to send to production.", - "type": "boolean" - }, - "Secret": { - "description": "[FCM only] The **Server key** of your project from the Firebase console, found under Settings / Cloud messaging.", - "type": "string" - }, - "Type": { - "description": "The type of push-notification service the credential is for. Can be: `gcm`, `fcm`, or `apn`.", - "enum": [ - "gcm", - "apn", - "fcm" - ], - "type": "string" - } - }, - "required": [ - "Type" - ], - "type": "object" - } - } - } - }, - "responses": { - "201": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/chat.v1.credential" - } - } - }, - "description": "Created" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://chat.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "friendly_name", - "type" - ], - "x-path-type": "list" - }, - "/v1/Credentials/{Sid}": { - "delete": { - "description": "", - "parameters": [ - { - "description": "The Twilio-provided string that uniquely identifies the Credential resource to delete.", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^CR[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "responses": { - "204": { - "description": "The resource was deleted successfully." - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "description": "Credentials for push notifications channels", - "get": { - "description": "", - "parameters": [ - { - "description": "The Twilio-provided string that uniquely identifies the Credential resource to fetch.", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^CR[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/chat.v1.credential" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "post": { - "description": "", - "parameters": [ - { - "description": "The Twilio-provided string that uniquely identifies the Credential resource to update.", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^CR[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "schema": { - "properties": { - "ApiKey": { - "description": "[GCM only] The API key for the project that was obtained from the Google Developer console for your GCM Service application credential.", - "type": "string" - }, - "Certificate": { - "description": "[APN only] The URL encoded representation of the certificate. For example, \n`-----BEGIN CERTIFICATE-----\nMIIFnTCCBIWgAwIBAgIIAjy9H849+E8wDQYJKoZIhvcNAQEFBQAwgZYxCzAJBgNV.....A==\n-----END CERTIFICATE-----`", - "type": "string" - }, - "FriendlyName": { - "description": "A descriptive string that you create to describe the resource. It can be up to 64 characters long.", - "type": "string" - }, - "PrivateKey": { - "description": "[APN only] The URL encoded representation of the private key. For example,\n`-----BEGIN RSA PRIVATE KEY-----\nMIIEpQIBAAKCAQEAuyf/lNrH9ck8DmNyo3fGgvCI1l9s+cmBY3WIz+cUDqmxiieR.\n-----END RSA PRIVATE KEY-----`", - "type": "string" - }, - "Sandbox": { - "description": "[APN only] Whether to send the credential to sandbox APNs. Can be `true` to send to sandbox APNs or `false` to send to production.", - "type": "boolean" - }, - "Secret": { - "description": "[FCM only] The **Server key** of your project from the Firebase console, found under Settings / Cloud messaging.", - "type": "string" - } - }, - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/chat.v1.credential" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://chat.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "friendly_name", - "type" - ], - "x-path-type": "instance" - }, - "/v1/Services": { - "description": "Top level scope for all chat resources", - "get": { - "description": "", - "parameters": [ - { - "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", - "in": "query", - "name": "PageSize", - "schema": { - "maximum": 1000, - "minimum": 1, - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "properties": { - "meta": { - "properties": { - "first_page_url": { - "format": "uri", - "type": "string" - }, - "key": { - "type": "string" - }, - "next_page_url": { - "format": "uri", - "type": "string" - }, - "page": { - "type": "integer" - }, - "page_size": { - "type": "integer" - }, - "previous_page_url": { - "format": "uri", - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - }, - "services": { - "items": { - "$ref": "#/components/schemas/chat.v1.service" - }, - "type": "array" - } - }, - "type": "object" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "post": { - "description": "", - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "schema": { - "properties": { - "FriendlyName": { - "description": "A descriptive string that you create to describe the resource. It can be up to 64 characters long.", - "type": "string" - } - }, - "required": [ - "FriendlyName" - ], - "type": "object" - } - } - } - }, - "responses": { - "201": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/chat.v1.service" - } - } - }, - "description": "Created" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://chat.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "friendly_name", - "date_created" - ], - "x-path-type": "list" - }, - "/v1/Services/{ServiceSid}/Channels": { - "description": "Channels represent chat rooms", - "get": { - "description": "", - "parameters": [ - { - "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to read the resources from.", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "The visibility of the Channels to read. Can be: `public` or `private` and defaults to `public`.", - "in": "query", - "name": "Type", - "schema": { - "items": { - "enum": [ - "public", - "private" - ], - "type": "string" - }, - "type": "array" - } - }, - { - "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", - "in": "query", - "name": "PageSize", - "schema": { - "maximum": 1000, - "minimum": 1, - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "properties": { - "channels": { - "items": { - "$ref": "#/components/schemas/chat.v1.service.channel" - }, - "type": "array" - }, - "meta": { - "properties": { - "first_page_url": { - "format": "uri", - "type": "string" - }, - "key": { - "type": "string" - }, - "next_page_url": { - "format": "uri", - "type": "string" - }, - "page": { - "type": "integer" - }, - "page_size": { - "type": "integer" - }, - "previous_page_url": { - "format": "uri", - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "post": { - "description": "", - "parameters": [ - { - "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to create the resource under.", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "schema": { - "properties": { - "Attributes": { - "description": "A valid JSON string that contains application-specific data.", - "type": "string" - }, - "FriendlyName": { - "description": "A descriptive string that you create to describe the new resource. It can be up to 64 characters long.", - "type": "string" - }, - "Type": { - "description": "The visibility of the channel. Can be: `public` or `private` and defaults to `public`.", - "enum": [ - "public", - "private" - ], - "type": "string" - }, - "UniqueName": { - "description": "An application-defined string that uniquely identifies the resource. It can be used to address the resource in place of the resource's `sid` in the URL. This value must be 64 characters or less in length and be unique within the Service.", - "type": "string" - } - }, - "type": "object" - } - } - } - }, - "responses": { - "201": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/chat.v1.service.channel" - } - } - }, - "description": "Created" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://chat.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "unique_name", - "friendly_name" - ], - "x-path-type": "list" - }, - "/v1/Services/{ServiceSid}/Channels/{ChannelSid}/Invites": { - "description": "Pending invitations to users to become channel members", - "get": { - "description": "", - "parameters": [ - { - "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to read the resources from.", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "The SID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) the resources to read belong to.", - "in": "path", - "name": "ChannelSid", - "required": true, - "schema": { - "type": "string" - } - }, - { - "description": "The [User](https://www.twilio.com/docs/api/chat/rest/v1/user)'s `identity` value of the resources to read. See [access tokens](https://www.twilio.com/docs/api/chat/guides/create-tokens) for more details.", - "in": "query", - "name": "Identity", - "schema": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - { - "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", - "in": "query", - "name": "PageSize", - "schema": { - "maximum": 1000, - "minimum": 1, - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "properties": { - "invites": { - "items": { - "$ref": "#/components/schemas/chat.v1.service.channel.invite" - }, - "type": "array" - }, - "meta": { - "properties": { - "first_page_url": { - "format": "uri", - "type": "string" - }, - "key": { - "type": "string" - }, - "next_page_url": { - "format": "uri", - "type": "string" - }, - "page": { - "type": "integer" - }, - "page_size": { - "type": "integer" - }, - "previous_page_url": { - "format": "uri", - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "post": { - "description": "", - "parameters": [ - { - "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to create the resource under.", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "The SID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) the new resource belongs to.", - "in": "path", - "name": "ChannelSid", - "required": true, - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "schema": { - "properties": { - "Identity": { - "description": "The `identity` value that uniquely identifies the new resource's [User](https://www.twilio.com/docs/api/chat/rest/v1/user) within the [Service](https://www.twilio.com/docs/api/chat/rest/v1/service). See [access tokens](https://www.twilio.com/docs/api/chat/guides/create-tokens) for more info.", - "type": "string" - }, - "RoleSid": { - "description": "The SID of the [Role](https://www.twilio.com/docs/api/chat/rest/roles) assigned to the new member.", - "maxLength": 34, - "minLength": 34, - "pattern": "^RL[0-9a-fA-F]{32}$", - "type": "string" - } - }, - "required": [ - "Identity" - ], - "type": "object" - } - } - } - }, - "responses": { - "201": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/chat.v1.service.channel.invite" - } - } - }, - "description": "Created" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://chat.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "identity", - "date_created" - ], - "x-path-type": "list" - }, - "/v1/Services/{ServiceSid}/Channels/{ChannelSid}/Invites/{Sid}": { - "delete": { - "description": "", - "parameters": [ - { - "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to delete the resource from.", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "The SID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) the resource to delete belongs to.", - "in": "path", - "name": "ChannelSid", - "required": true, - "schema": { - "type": "string" - } - }, - { - "description": "The Twilio-provided string that uniquely identifies the Invite resource to delete.", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IN[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "responses": { - "204": { - "description": "The resource was deleted successfully." - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "description": "Pending invitations to users to become channel members", - "get": { - "description": "", - "parameters": [ - { - "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to fetch the resource from.", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "The SID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) the resource to fetch belongs to.", - "in": "path", - "name": "ChannelSid", - "required": true, - "schema": { - "type": "string" - } - }, - { - "description": "The Twilio-provided string that uniquely identifies the Invite resource to fetch.", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IN[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/chat.v1.service.channel.invite" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://chat.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "identity", - "date_created" - ], - "x-path-type": "instance" - }, - "/v1/Services/{ServiceSid}/Channels/{ChannelSid}/Members": { - "description": "Users joined to specific channels", - "get": { - "description": "", - "parameters": [ - { - "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to read the resources from.", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) the members to read belong to. Can be the Channel resource's `sid` or `unique_name` value.", - "in": "path", - "name": "ChannelSid", - "required": true, - "schema": { - "type": "string" - } - }, - { - "description": "The [User](https://www.twilio.com/docs/api/chat/rest/v1/user)'s `identity` value of the resources to read. See [access tokens](https://www.twilio.com/docs/api/chat/guides/create-tokens) for more details.", - "in": "query", - "name": "Identity", - "schema": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - { - "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", - "in": "query", - "name": "PageSize", - "schema": { - "maximum": 1000, - "minimum": 1, - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "properties": { - "members": { - "items": { - "$ref": "#/components/schemas/chat.v1.service.channel.member" - }, - "type": "array" - }, - "meta": { - "properties": { - "first_page_url": { - "format": "uri", - "type": "string" - }, - "key": { - "type": "string" - }, - "next_page_url": { - "format": "uri", - "type": "string" - }, - "page": { - "type": "integer" - }, - "page_size": { - "type": "integer" - }, - "previous_page_url": { - "format": "uri", - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "post": { - "description": "", - "parameters": [ - { - "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to create the resource under.", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) the new member belongs to. Can be the Channel resource's `sid` or `unique_name`.", - "in": "path", - "name": "ChannelSid", - "required": true, - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "schema": { - "properties": { - "Identity": { - "description": "The `identity` value that uniquely identifies the new resource's [User](https://www.twilio.com/docs/api/chat/rest/v1/user) within the [Service](https://www.twilio.com/docs/api/chat/rest/services). See [access tokens](https://www.twilio.com/docs/api/chat/guides/create-tokens) for more details.", - "type": "string" - }, - "RoleSid": { - "description": "The SID of the [Role](https://www.twilio.com/docs/api/chat/rest/roles) to assign to the member. The default roles are those specified on the [Service](https://www.twilio.com/docs/chat/api/services).", - "maxLength": 34, - "minLength": 34, - "pattern": "^RL[0-9a-fA-F]{32}$", - "type": "string" - } - }, - "required": [ - "Identity" - ], - "type": "object" - } - } - } - }, - "responses": { - "201": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/chat.v1.service.channel.member" - } - } - }, - "description": "Created" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://chat.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "identity", - "date_created" - ], - "x-path-type": "list" - }, - "/v1/Services/{ServiceSid}/Channels/{ChannelSid}/Members/{Sid}": { - "delete": { - "description": "", - "parameters": [ - { - "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to delete the resource from.", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) the message belongs to. Can be the Channel's `sid` or `unique_name`.", - "in": "path", - "name": "ChannelSid", - "required": true, - "schema": { - "type": "string" - } - }, - { - "description": "The Twilio-provided string that uniquely identifies the Member resource to delete.", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^MB[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "responses": { - "204": { - "description": "The resource was deleted successfully." - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "description": "Users joined to specific channels", - "get": { - "description": "", - "parameters": [ - { - "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to fetch the resource from.", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) the member to fetch belongs to. Can be the Channel resource's `sid` or `unique_name` value.", - "in": "path", - "name": "ChannelSid", - "required": true, - "schema": { - "type": "string" - } - }, - { - "description": "The Twilio-provided string that uniquely identifies the Member resource to fetch.", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^MB[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/chat.v1.service.channel.member" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "post": { - "description": "", - "parameters": [ - { - "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to update the resource from.", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) the member to update belongs to. Can be the Channel resource's `sid` or `unique_name`.", - "in": "path", - "name": "ChannelSid", - "required": true, - "schema": { - "type": "string" - } - }, - { - "description": "The Twilio-provided string that uniquely identifies the Member resource to update.", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^MB[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "schema": { - "properties": { - "LastConsumedMessageIndex": { - "description": "The index of the last [Message](https://www.twilio.com/docs/api/chat/rest/messages) that the Member has read within the [Channel](https://www.twilio.com/docs/api/chat/rest/channels).", - "nullable": true, - "type": "integer" - }, - "RoleSid": { - "description": "The SID of the [Role](https://www.twilio.com/docs/api/chat/rest/roles) to assign to the member. The default roles are those specified on the [Service](https://www.twilio.com/docs/chat/api/services).", - "maxLength": 34, - "minLength": 34, - "pattern": "^RL[0-9a-fA-F]{32}$", - "type": "string" - } - }, - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/chat.v1.service.channel.member" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://chat.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "identity", - "date_created" - ], - "x-path-type": "instance" - }, - "/v1/Services/{ServiceSid}/Channels/{ChannelSid}/Messages": { - "description": "Individual chat messages", - "get": { - "description": "", - "parameters": [ - { - "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to read the resources from.", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) the message to read belongs to. Can be the Channel's `sid` or `unique_name`.", - "in": "path", - "name": "ChannelSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^CH[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "The sort order of the returned messages. Can be: `asc` (ascending) or `desc` (descending) with `asc` as the default.", - "in": "query", - "name": "Order", - "schema": { - "enum": [ - "asc", - "desc" - ], - "type": "string" - } - }, - { - "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", - "in": "query", - "name": "PageSize", - "schema": { - "maximum": 1000, - "minimum": 1, - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "properties": { - "messages": { - "items": { - "$ref": "#/components/schemas/chat.v1.service.channel.message" - }, - "type": "array" - }, - "meta": { - "properties": { - "first_page_url": { - "format": "uri", - "type": "string" - }, - "key": { - "type": "string" - }, - "next_page_url": { - "format": "uri", - "type": "string" - }, - "page": { - "type": "integer" - }, - "page_size": { - "type": "integer" - }, - "previous_page_url": { - "format": "uri", - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "post": { - "description": "", - "parameters": [ - { - "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to create the resource under.", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) the new resource belongs to. Can be the Channel resource's `sid` or `unique_name`.", - "in": "path", - "name": "ChannelSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^CH[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "schema": { - "properties": { - "Attributes": { - "description": "A valid JSON string that contains application-specific data.", - "type": "string" - }, - "Body": { - "description": "The message to send to the channel. Can also be an empty string or `null`, which sets the value as an empty string. You can send structured data in the body by serializing it as a string.", - "type": "string" - }, - "From": { - "description": "The [identity](https://www.twilio.com/docs/api/chat/guides/identity) of the new message's author. The default value is `system`.", - "type": "string" - } - }, - "required": [ - "Body" - ], - "type": "object" - } - } - } - }, - "responses": { - "201": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/chat.v1.service.channel.message" - } - } - }, - "description": "Created" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://chat.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "from", - "to", - "date_created" - ], - "x-path-type": "list" - }, - "/v1/Services/{ServiceSid}/Channels/{ChannelSid}/Messages/{Sid}": { - "delete": { - "description": "", - "parameters": [ - { - "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to delete the resource from.", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) the message to delete belongs to. Can be the Channel resource's `sid` or `unique_name`.", - "in": "path", - "name": "ChannelSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^CH[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "The Twilio-provided string that uniquely identifies the Message resource to delete.", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IM[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "responses": { - "204": { - "description": "The resource was deleted successfully." - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "description": "Individual chat messages", - "get": { - "description": "", - "parameters": [ - { - "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to fetch the resource from.", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) the message to fetch belongs to. Can be the Channel's `sid` or `unique_name`.", - "in": "path", - "name": "ChannelSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^CH[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "The Twilio-provided string that uniquely identifies the Message resource to fetch.", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IM[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/chat.v1.service.channel.message" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "post": { - "description": "", - "parameters": [ - { - "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to update the resource from.", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) the message belongs to. Can be the Channel's `sid` or `unique_name`.", - "in": "path", - "name": "ChannelSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^CH[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "The Twilio-provided string that uniquely identifies the Message resource to update.", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IM[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "schema": { - "properties": { - "Attributes": { - "description": "A valid JSON string that contains application-specific data.", - "type": "string" - }, - "Body": { - "description": "The message to send to the channel. Can also be an empty string or `null`, which sets the value as an empty string. You can send structured data in the body by serializing it as a string.", - "type": "string" - } - }, - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/chat.v1.service.channel.message" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://chat.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "from", - "to", - "date_created" - ], - "x-path-type": "instance" - }, - "/v1/Services/{ServiceSid}/Channels/{Sid}": { - "delete": { - "description": "", - "parameters": [ - { - "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to delete the resource from.", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "The Twilio-provided string that uniquely identifies the Channel resource to delete.", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "204": { - "description": "The resource was deleted successfully." - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "description": "Channels represent chat rooms", - "get": { - "description": "", - "parameters": [ - { - "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to fetch the resource from.", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "The Twilio-provided string that uniquely identifies the Channel resource to fetch.", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/chat.v1.service.channel" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "post": { - "description": "", - "parameters": [ - { - "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to update the resource from.", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "The Twilio-provided string that uniquely identifies the Channel resource to update.", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "schema": { - "properties": { - "Attributes": { - "description": "A valid JSON string that contains application-specific data.", - "type": "string" - }, - "FriendlyName": { - "description": "A descriptive string that you create to describe the resource. It can be up to 64 characters long.", - "type": "string" - }, - "UniqueName": { - "description": "An application-defined string that uniquely identifies the resource. It can be used to address the resource in place of the resource's `sid` in the URL. This value must be 64 characters or less in length and be unique within the Service.", - "type": "string" - } - }, - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/chat.v1.service.channel" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://chat.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "unique_name", - "friendly_name" - ], - "x-path-type": "instance" - }, - "/v1/Services/{ServiceSid}/Roles": { - "description": "Roles determining user or member permissions", - "get": { - "description": "", - "parameters": [ - { - "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to read the resources from.", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", - "in": "query", - "name": "PageSize", - "schema": { - "maximum": 1000, - "minimum": 1, - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "properties": { - "meta": { - "properties": { - "first_page_url": { - "format": "uri", - "type": "string" - }, - "key": { - "type": "string" - }, - "next_page_url": { - "format": "uri", - "type": "string" - }, - "page": { - "type": "integer" - }, - "page_size": { - "type": "integer" - }, - "previous_page_url": { - "format": "uri", - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - }, - "roles": { - "items": { - "$ref": "#/components/schemas/chat.v1.service.role" - }, - "type": "array" - } - }, - "type": "object" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "post": { - "description": "", - "parameters": [ - { - "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to create the resource under.", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "schema": { - "properties": { - "FriendlyName": { - "description": "A descriptive string that you create to describe the new resource. It can be up to 64 characters long.", - "type": "string" - }, - "Permission": { - "description": "A permission that you grant to the new role. Only one permission can be granted per parameter. To assign more than one permission, repeat this parameter for each permission value. The values for this parameter depend on the role's `type` and are described in the documentation.", - "items": { - "type": "string" - }, - "type": "array" - }, - "Type": { - "description": "The type of role. Can be: `channel` for [Channel](https://www.twilio.com/docs/chat/api/channels) roles or `deployment` for [Service](https://www.twilio.com/docs/chat/api/services) roles.", - "enum": [ - "channel", - "deployment" - ], - "type": "string" - } - }, - "required": [ - "FriendlyName", - "Type", - "Permission" - ], - "type": "object" - } - } - } - }, - "responses": { - "201": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/chat.v1.service.role" - } - } - }, - "description": "Created" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://chat.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "friendly_name", - "type" - ], - "x-path-type": "list" - }, - "/v1/Services/{ServiceSid}/Roles/{Sid}": { - "delete": { - "description": "", - "parameters": [ - { - "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to delete the resource from.", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "The Twilio-provided string that uniquely identifies the Role resource to delete.", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^RL[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "responses": { - "204": { - "description": "The resource was deleted successfully." - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "description": "Roles determining user or member permissions", - "get": { - "description": "", - "parameters": [ - { - "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to fetch the resource from.", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "The Twilio-provided string that uniquely identifies the Role resource to fetch.", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^RL[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/chat.v1.service.role" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "post": { - "description": "", - "parameters": [ - { - "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to update the resource from.", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "The Twilio-provided string that uniquely identifies the Role resource to update.", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^RL[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "schema": { - "properties": { - "Permission": { - "description": "A permission that you grant to the role. Only one permission can be granted per parameter. To assign more than one permission, repeat this parameter for each permission value. The values for this parameter depend on the role's `type` and are described in the documentation.", - "items": { - "type": "string" - }, - "type": "array" - } - }, - "required": [ - "Permission" - ], - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/chat.v1.service.role" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://chat.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "friendly_name", - "type" - ], - "x-path-type": "instance" - }, - "/v1/Services/{ServiceSid}/Users": { - "description": "Unique chat users within a chat service", - "get": { - "description": "", - "parameters": [ - { - "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to read the resources from.", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", - "in": "query", - "name": "PageSize", - "schema": { - "maximum": 1000, - "minimum": 1, - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "properties": { - "meta": { - "properties": { - "first_page_url": { - "format": "uri", - "type": "string" - }, - "key": { - "type": "string" - }, - "next_page_url": { - "format": "uri", - "type": "string" - }, - "page": { - "type": "integer" - }, - "page_size": { - "type": "integer" - }, - "previous_page_url": { - "format": "uri", - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - }, - "users": { - "items": { - "$ref": "#/components/schemas/chat.v1.service.user" - }, - "type": "array" - } - }, - "type": "object" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "post": { - "description": "", - "parameters": [ - { - "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to create the resource under.", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "schema": { - "properties": { - "Attributes": { - "description": "A valid JSON string that contains application-specific data.", - "type": "string" - }, - "FriendlyName": { - "description": "A descriptive string that you create to describe the new resource. This value is often used for display purposes.", - "type": "string" - }, - "Identity": { - "description": "The `identity` value that uniquely identifies the new resource's [User](https://www.twilio.com/docs/api/chat/rest/v1/user) within the [Service](https://www.twilio.com/docs/api/chat/rest/v1/service). This value is often a username or email address. See the Identity documentation for more details.", - "type": "string" - }, - "RoleSid": { - "description": "The SID of the [Role](https://www.twilio.com/docs/api/chat/rest/roles) assigned to the new User.", - "maxLength": 34, - "minLength": 34, - "pattern": "^RL[0-9a-fA-F]{32}$", - "type": "string" - } - }, - "required": [ - "Identity" - ], - "type": "object" - } - } - } - }, - "responses": { - "201": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/chat.v1.service.user" - } - } - }, - "description": "Created" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://chat.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "friendly_name", - "date_created" - ], - "x-path-type": "list" - }, - "/v1/Services/{ServiceSid}/Users/{Sid}": { - "delete": { - "description": "", - "parameters": [ - { - "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to delete the resource from.", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "The Twilio-provided string that uniquely identifies the User resource to delete.", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "204": { - "description": "The resource was deleted successfully." - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "description": "Unique chat users within a chat service", - "get": { - "description": "", - "parameters": [ - { - "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to fetch the resource from.", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "The Twilio-provided string that uniquely identifies the User resource to fetch.", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/chat.v1.service.user" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "post": { - "description": "", - "parameters": [ - { - "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to update the resource from.", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "The Twilio-provided string that uniquely identifies the User resource to update.", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "schema": { - "properties": { - "Attributes": { - "description": "A valid JSON string that contains application-specific data.", - "type": "string" - }, - "FriendlyName": { - "description": "A descriptive string that you create to describe the resource. It is often used for display purposes.", - "type": "string" - }, - "RoleSid": { - "description": "The SID of the [Role](https://www.twilio.com/docs/api/chat/rest/roles) assigned to this user.", - "maxLength": 34, - "minLength": 34, - "pattern": "^RL[0-9a-fA-F]{32}$", - "type": "string" - } - }, - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/chat.v1.service.user" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://chat.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "friendly_name", - "date_created" - ], - "x-path-type": "instance" - }, - "/v1/Services/{ServiceSid}/Users/{UserSid}/Channels": { - "description": "TODO: Resource-level docs", - "get": { - "description": "List all Channels for a given User.", - "parameters": [ - { - "description": "The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) to read the resources from.", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "The SID of the [User](https://www.twilio.com/docs/api/chat/rest/users) to read the User Channel resources from.", - "in": "path", - "name": "UserSid", - "required": true, - "schema": { - "type": "string" - } - }, - { - "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", - "in": "query", - "name": "PageSize", - "schema": { - "maximum": 1000, - "minimum": 1, - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "properties": { - "channels": { - "items": { - "$ref": "#/components/schemas/chat.v1.service.user.user_channel" - }, - "type": "array" - }, - "meta": { - "properties": { - "first_page_url": { - "format": "uri", - "type": "string" - }, - "key": { - "type": "string" - }, - "next_page_url": { - "format": "uri", - "type": "string" - }, - "page": { - "type": "integer" - }, - "page_size": { - "type": "integer" - }, - "previous_page_url": { - "format": "uri", - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://chat.twilio.com" - } - ], - "x-default-output-properties": [ - "channel_sid", - "status" - ], - "x-path-type": "list" - }, - "/v1/Services/{Sid}": { - "delete": { - "description": "", - "parameters": [ - { - "description": "The Twilio-provided string that uniquely identifies the Service resource to delete.", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "responses": { - "204": { - "description": "The resource was deleted successfully." - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "description": "Top level scope for all chat resources", - "get": { - "description": "", - "parameters": [ - { - "description": "The Twilio-provided string that uniquely identifies the Service resource to fetch.", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/chat.v1.service" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "post": { - "description": "", - "parameters": [ - { - "description": "The Twilio-provided string that uniquely identifies the Service resource to update.", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "schema": { - "properties": { - "ConsumptionReportInterval": { - "description": "DEPRECATED. The interval in seconds between consumption reports submission batches from client endpoints.", - "type": "integer" - }, - "DefaultChannelCreatorRoleSid": { - "description": "The channel role assigned to a channel creator when they join a new channel. See the [Roles endpoint](https://www.twilio.com/docs/chat/api/roles) for more details.", - "maxLength": 34, - "minLength": 34, - "pattern": "^RL[0-9a-fA-F]{32}$", - "type": "string" - }, - "DefaultChannelRoleSid": { - "description": "The channel role assigned to users when they are added to a channel. See the [Roles endpoint](https://www.twilio.com/docs/chat/api/roles) for more details.", - "maxLength": 34, - "minLength": 34, - "pattern": "^RL[0-9a-fA-F]{32}$", - "type": "string" - }, - "DefaultServiceRoleSid": { - "description": "The service role assigned to users when they are added to the service. See the [Roles endpoint](https://www.twilio.com/docs/chat/api/roles) for more details.", - "maxLength": 34, - "minLength": 34, - "pattern": "^RL[0-9a-fA-F]{32}$", - "type": "string" - }, - "FriendlyName": { - "description": "A descriptive string that you create to describe the resource. It can be up to 64 characters long.", - "type": "string" - }, - "Limits.ChannelMembers": { - "description": "The maximum number of Members that can be added to Channels within this Service. Can be up to 1,000.", - "type": "integer" - }, - "Limits.UserChannels": { - "description": "The maximum number of Channels Users can be a Member of within this Service. Can be up to 1,000.", - "type": "integer" - }, - "Notifications.AddedToChannel.Enabled": { - "description": "Whether to send a notification when a member is added to a channel. Can be: `true` or `false` and the default is `false`.", - "type": "boolean" - }, - "Notifications.AddedToChannel.Template": { - "description": "The template to use to create the notification text displayed when a member is added to a channel and `notifications.added_to_channel.enabled` is `true`.", - "type": "string" - }, - "Notifications.InvitedToChannel.Enabled": { - "description": "Whether to send a notification when a user is invited to a channel. Can be: `true` or `false` and the default is `false`.", - "type": "boolean" - }, - "Notifications.InvitedToChannel.Template": { - "description": "The template to use to create the notification text displayed when a user is invited to a channel and `notifications.invited_to_channel.enabled` is `true`.", - "type": "string" - }, - "Notifications.NewMessage.Enabled": { - "description": "Whether to send a notification when a new message is added to a channel. Can be: `true` or `false` and the default is `false`.", - "type": "boolean" - }, - "Notifications.NewMessage.Template": { - "description": "The template to use to create the notification text displayed when a new message is added to a channel and `notifications.new_message.enabled` is `true`.", - "type": "string" - }, - "Notifications.RemovedFromChannel.Enabled": { - "description": "Whether to send a notification to a user when they are removed from a channel. Can be: `true` or `false` and the default is `false`.", - "type": "boolean" - }, - "Notifications.RemovedFromChannel.Template": { - "description": "The template to use to create the notification text displayed to a user when they are removed from a channel and `notifications.removed_from_channel.enabled` is `true`.", - "type": "string" - }, - "PostWebhookUrl": { - "description": "The URL for post-event webhooks, which are called by using the `webhook_method`. See [Webhook Events](https://www.twilio.com/docs/api/chat/webhooks) for more details.", - "format": "uri", - "type": "string" - }, - "PreWebhookUrl": { - "description": "The URL for pre-event webhooks, which are called by using the `webhook_method`. See [Webhook Events](https://www.twilio.com/docs/api/chat/webhooks) for more details.", - "format": "uri", - "type": "string" - }, - "ReachabilityEnabled": { - "description": "Whether to enable the [Reachability Indicator](https://www.twilio.com/docs/chat/reachability-indicator) for this Service instance. The default is `false`.", - "type": "boolean" - }, - "ReadStatusEnabled": { - "description": "Whether to enable the [Message Consumption Horizon](https://www.twilio.com/docs/chat/consumption-horizon) feature. The default is `true`.", - "type": "boolean" - }, - "TypingIndicatorTimeout": { - "description": "How long in seconds after a `started typing` event until clients should assume that user is no longer typing, even if no `ended typing` message was received. The default is 5 seconds.", - "type": "integer" - }, - "WebhookFilters": { - "description": "The list of WebHook events that are enabled for this Service instance. See [Webhook Events](https://www.twilio.com/docs/chat/webhook-events) for more details.", - "items": { - "type": "string" - }, - "type": "array" - }, - "WebhookMethod": { - "description": "The HTTP method to use for calls to the `pre_webhook_url` and `post_webhook_url` webhooks. Can be: `POST` or `GET` and the default is `POST`. See [Webhook Events](https://www.twilio.com/docs/chat/webhook-events) for more details.", - "enum": [ - "head", - "get", - "post", - "patch", - "put", - "delete", - "HEAD", - "GET", - "POST", - "PATCH", - "PUT", - "DELETE" - ], - "type": "string" - }, - "Webhooks.OnChannelAdd.Method": { - "description": "The HTTP method to use when calling the `webhooks.on_channel_add.url`.", - "enum": [ - "head", - "get", - "post", - "patch", - "put", - "delete", - "HEAD", - "GET", - "POST", - "PATCH", - "PUT", - "DELETE" - ], - "type": "string" - }, - "Webhooks.OnChannelAdd.Url": { - "description": "The URL of the webhook to call in response to the `on_channel_add` event using the `webhooks.on_channel_add.method` HTTP method.", - "format": "uri", - "type": "string" - }, - "Webhooks.OnChannelAdded.Method": { - "description": "The URL of the webhook to call in response to the `on_channel_added` event`.", - "enum": [ - "head", - "get", - "post", - "patch", - "put", - "delete", - "HEAD", - "GET", - "POST", - "PATCH", - "PUT", - "DELETE" - ], - "type": "string" - }, - "Webhooks.OnChannelAdded.Url": { - "description": "The URL of the webhook to call in response to the `on_channel_added` event using the `webhooks.on_channel_added.method` HTTP method.", - "format": "uri", - "type": "string" - }, - "Webhooks.OnChannelDestroy.Method": { - "description": "The HTTP method to use when calling the `webhooks.on_channel_destroy.url`.", - "enum": [ - "head", - "get", - "post", - "patch", - "put", - "delete", - "HEAD", - "GET", - "POST", - "PATCH", - "PUT", - "DELETE" - ], - "type": "string" - }, - "Webhooks.OnChannelDestroy.Url": { - "description": "The URL of the webhook to call in response to the `on_channel_destroy` event using the `webhooks.on_channel_destroy.method` HTTP method.", - "format": "uri", - "type": "string" - }, - "Webhooks.OnChannelDestroyed.Method": { - "description": "The HTTP method to use when calling the `webhooks.on_channel_destroyed.url`.", - "enum": [ - "head", - "get", - "post", - "patch", - "put", - "delete", - "HEAD", - "GET", - "POST", - "PATCH", - "PUT", - "DELETE" - ], - "type": "string" - }, - "Webhooks.OnChannelDestroyed.Url": { - "description": "The URL of the webhook to call in response to the `on_channel_added` event using the `webhooks.on_channel_destroyed.method` HTTP method.", - "format": "uri", - "type": "string" - }, - "Webhooks.OnChannelUpdate.Method": { - "description": "The HTTP method to use when calling the `webhooks.on_channel_update.url`.", - "enum": [ - "head", - "get", - "post", - "patch", - "put", - "delete", - "HEAD", - "GET", - "POST", - "PATCH", - "PUT", - "DELETE" - ], - "type": "string" - }, - "Webhooks.OnChannelUpdate.Url": { - "description": "The URL of the webhook to call in response to the `on_channel_update` event using the `webhooks.on_channel_update.method` HTTP method.", - "format": "uri", - "type": "string" - }, - "Webhooks.OnChannelUpdated.Method": { - "description": "The HTTP method to use when calling the `webhooks.on_channel_updated.url`.", - "enum": [ - "head", - "get", - "post", - "patch", - "put", - "delete", - "HEAD", - "GET", - "POST", - "PATCH", - "PUT", - "DELETE" - ], - "type": "string" - }, - "Webhooks.OnChannelUpdated.Url": { - "description": "The URL of the webhook to call in response to the `on_channel_updated` event using the `webhooks.on_channel_updated.method` HTTP method.", - "format": "uri", - "type": "string" - }, - "Webhooks.OnMemberAdd.Method": { - "description": "The HTTP method to use when calling the `webhooks.on_member_add.url`.", - "enum": [ - "head", - "get", - "post", - "patch", - "put", - "delete", - "HEAD", - "GET", - "POST", - "PATCH", - "PUT", - "DELETE" - ], - "type": "string" - }, - "Webhooks.OnMemberAdd.Url": { - "description": "The URL of the webhook to call in response to the `on_member_add` event using the `webhooks.on_member_add.method` HTTP method.", - "format": "uri", - "type": "string" - }, - "Webhooks.OnMemberAdded.Method": { - "description": "The HTTP method to use when calling the `webhooks.on_channel_updated.url`.", - "enum": [ - "head", - "get", - "post", - "patch", - "put", - "delete", - "HEAD", - "GET", - "POST", - "PATCH", - "PUT", - "DELETE" - ], - "type": "string" - }, - "Webhooks.OnMemberAdded.Url": { - "description": "The URL of the webhook to call in response to the `on_channel_updated` event using the `webhooks.on_channel_updated.method` HTTP method.", - "format": "uri", - "type": "string" - }, - "Webhooks.OnMemberRemove.Method": { - "description": "The HTTP method to use when calling the `webhooks.on_member_remove.url`.", - "enum": [ - "head", - "get", - "post", - "patch", - "put", - "delete", - "HEAD", - "GET", - "POST", - "PATCH", - "PUT", - "DELETE" - ], - "type": "string" - }, - "Webhooks.OnMemberRemove.Url": { - "description": "The URL of the webhook to call in response to the `on_member_remove` event using the `webhooks.on_member_remove.method` HTTP method.", - "format": "uri", - "type": "string" - }, - "Webhooks.OnMemberRemoved.Method": { - "description": "The HTTP method to use when calling the `webhooks.on_member_removed.url`.", - "enum": [ - "head", - "get", - "post", - "patch", - "put", - "delete", - "HEAD", - "GET", - "POST", - "PATCH", - "PUT", - "DELETE" - ], - "type": "string" - }, - "Webhooks.OnMemberRemoved.Url": { - "description": "The URL of the webhook to call in response to the `on_member_removed` event using the `webhooks.on_member_removed.method` HTTP method.", - "format": "uri", - "type": "string" - }, - "Webhooks.OnMessageRemove.Method": { - "description": "The HTTP method to use when calling the `webhooks.on_message_remove.url`.", - "enum": [ - "head", - "get", - "post", - "patch", - "put", - "delete", - "HEAD", - "GET", - "POST", - "PATCH", - "PUT", - "DELETE" - ], - "type": "string" - }, - "Webhooks.OnMessageRemove.Url": { - "description": "The URL of the webhook to call in response to the `on_message_remove` event using the `webhooks.on_message_remove.method` HTTP method.", - "format": "uri", - "type": "string" - }, - "Webhooks.OnMessageRemoved.Method": { - "description": "The HTTP method to use when calling the `webhooks.on_message_removed.url`.", - "enum": [ - "head", - "get", - "post", - "patch", - "put", - "delete", - "HEAD", - "GET", - "POST", - "PATCH", - "PUT", - "DELETE" - ], - "type": "string" - }, - "Webhooks.OnMessageRemoved.Url": { - "description": "The URL of the webhook to call in response to the `on_message_removed` event using the `webhooks.on_message_removed.method` HTTP method.", - "format": "uri", - "type": "string" - }, - "Webhooks.OnMessageSend.Method": { - "description": "The HTTP method to use when calling the `webhooks.on_message_send.url`.", - "enum": [ - "head", - "get", - "post", - "patch", - "put", - "delete", - "HEAD", - "GET", - "POST", - "PATCH", - "PUT", - "DELETE" - ], - "type": "string" - }, - "Webhooks.OnMessageSend.Url": { - "description": "The URL of the webhook to call in response to the `on_message_send` event using the `webhooks.on_message_send.method` HTTP method.", - "format": "uri", - "type": "string" - }, - "Webhooks.OnMessageSent.Method": { - "description": "The URL of the webhook to call in response to the `on_message_sent` event`.", - "enum": [ - "head", - "get", - "post", - "patch", - "put", - "delete", - "HEAD", - "GET", - "POST", - "PATCH", - "PUT", - "DELETE" - ], - "type": "string" - }, - "Webhooks.OnMessageSent.Url": { - "description": "The URL of the webhook to call in response to the `on_message_sent` event using the `webhooks.on_message_sent.method` HTTP method.", - "format": "uri", - "type": "string" - }, - "Webhooks.OnMessageUpdate.Method": { - "description": "The HTTP method to use when calling the `webhooks.on_message_update.url`.", - "enum": [ - "head", - "get", - "post", - "patch", - "put", - "delete", - "HEAD", - "GET", - "POST", - "PATCH", - "PUT", - "DELETE" - ], - "type": "string" - }, - "Webhooks.OnMessageUpdate.Url": { - "description": "The URL of the webhook to call in response to the `on_message_update` event using the `webhooks.on_message_update.method` HTTP method.", - "format": "uri", - "type": "string" - }, - "Webhooks.OnMessageUpdated.Method": { - "description": "The HTTP method to use when calling the `webhooks.on_message_updated.url`.", - "enum": [ - "head", - "get", - "post", - "patch", - "put", - "delete", - "HEAD", - "GET", - "POST", - "PATCH", - "PUT", - "DELETE" - ], - "type": "string" - }, - "Webhooks.OnMessageUpdated.Url": { - "description": "The URL of the webhook to call in response to the `on_message_updated` event using the `webhooks.on_message_updated.method` HTTP method.", - "format": "uri", - "type": "string" - } - }, - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/chat.v1.service" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://chat.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "friendly_name", - "date_created" - ], - "x-path-type": "instance" + } + }, + "securitySchemes": { + "accountSid_authToken": { + "scheme": "basic", + "type": "http" + } + } + }, + "info": { + "contact": { + "email": "support@twilio.com", + "name": "Twilio Support", + "url": "https://support.twilio.com" + }, + "description": "This is the public Twilio REST API.", + "license": { + "name": "Apache 2.0", + "url": "https://www.apache.org/licenses/LICENSE-2.0.html" }, + "termsOfService": "https://www.twilio.com/legal/tos", + "title": "Twilio - Chat", + "version": "1.3.0" + }, + "openapi": "3.0.1", + "paths": { "/v2/Credentials": { "description": "Credentials for push notifications channels", "get": { diff --git a/spec/json/twilio_conversations.json b/spec/json/twilio_conversations_v1.json similarity index 100% rename from spec/json/twilio_conversations.json rename to spec/json/twilio_conversations_v1.json diff --git a/spec/json/twilio_events.json b/spec/json/twilio_events_v1.json similarity index 100% rename from spec/json/twilio_events.json rename to spec/json/twilio_events_v1.json diff --git a/spec/json/twilio_fax.json b/spec/json/twilio_fax_v1.json similarity index 100% rename from spec/json/twilio_fax.json rename to spec/json/twilio_fax_v1.json diff --git a/spec/json/twilio_flex.json b/spec/json/twilio_flex_v1.json similarity index 100% rename from spec/json/twilio_flex.json rename to spec/json/twilio_flex_v1.json diff --git a/spec/json/twilio_insights.json b/spec/json/twilio_insights_v1.json similarity index 100% rename from spec/json/twilio_insights.json rename to spec/json/twilio_insights_v1.json diff --git a/spec/json/twilio_studio.json b/spec/json/twilio_ip_messaging_v1.json similarity index 59% rename from spec/json/twilio_studio.json rename to spec/json/twilio_ip_messaging_v1.json index f43f2f3a..ca8f3ae8 100644 --- a/spec/json/twilio_studio.json +++ b/spec/json/twilio_ip_messaging_v1.json @@ -1,7 +1,7 @@ { "components": { "schemas": { - "studio.v1.flow": { + "ip_messaging.v1.credential": { "properties": { "account_sid": { "maxLength": 34, @@ -20,33 +20,31 @@ "friendly_name": { "type": "string" }, - "links": { - "type": "object" + "sandbox": { + "type": "string" }, "sid": { "maxLength": 34, "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", + "pattern": "^CR[0-9a-fA-F]{32}$", "type": "string" }, - "status": { + "type": { "enum": [ - "draft", - "published" + "gcm", + "apn", + "fcm" ], "type": "string" }, "url": { "format": "uri", "type": "string" - }, - "version": { - "type": "integer" } }, "type": "object" }, - "studio.v1.flow.engagement": { + "ip_messaging.v1.service": { "properties": { "account_sid": { "maxLength": 34, @@ -54,17 +52,8 @@ "pattern": "^AC[0-9a-fA-F]{32}$", "type": "string" }, - "contact_channel_address": { - "type": "string" - }, - "contact_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FC[0-9a-fA-F]{32}$", - "type": "string" - }, - "context": { - "type": "object" + "consumption_report_interval": { + "type": "integer" }, "date_created": { "format": "date-time", @@ -74,66 +63,77 @@ "format": "date-time", "type": "string" }, - "flow_sid": { + "default_channel_creator_role_sid": { "maxLength": 34, "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", + "pattern": "^RL[0-9a-fA-F]{32}$", "type": "string" }, - "links": { - "type": "object" - }, - "sid": { + "default_channel_role_sid": { "maxLength": 34, "minLength": 34, - "pattern": "^FN[0-9a-fA-F]{32}$", - "type": "string" - }, - "status": { - "enum": [ - "active", - "ended" - ], + "pattern": "^RL[0-9a-fA-F]{32}$", "type": "string" }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - }, - "studio.v1.flow.engagement.engagement_context": { - "properties": { - "account_sid": { + "default_service_role_sid": { "maxLength": 34, "minLength": 34, - "pattern": "^AC[0-9a-fA-F]{32}$", + "pattern": "^RL[0-9a-fA-F]{32}$", + "type": "string" + }, + "friendly_name": { "type": "string" }, - "context": { + "limits": { "type": "object" }, - "engagement_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FN[0-9a-fA-F]{32}$", + "links": { + "type": "object" + }, + "notifications": { + "type": "object" + }, + "post_webhook_url": { + "type": "string" + }, + "pre_webhook_url": { "type": "string" }, - "flow_sid": { + "reachability_enabled": { + "type": "boolean" + }, + "read_status_enabled": { + "type": "boolean" + }, + "sid": { "maxLength": 34, "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", + "pattern": "^IS[0-9a-fA-F]{32}$", "type": "string" }, + "typing_indicator_timeout": { + "type": "integer" + }, "url": { "format": "uri", "type": "string" + }, + "webhook_filters": { + "items": { + "type": "string" + }, + "type": "array" + }, + "webhook_method": { + "type": "string" + }, + "webhooks": { + "type": "object" } }, "type": "object" }, - "studio.v1.flow.engagement.step": { + "ip_messaging.v1.service.channel": { "properties": { "account_sid": { "maxLength": 34, @@ -141,8 +141,11 @@ "pattern": "^AC[0-9a-fA-F]{32}$", "type": "string" }, - "context": { - "type": "object" + "attributes": { + "type": "string" + }, + "created_by": { + "type": "string" }, "date_created": { "format": "date-time", @@ -152,34 +155,38 @@ "format": "date-time", "type": "string" }, - "engagement_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FN[0-9a-fA-F]{32}$", - "type": "string" - }, - "flow_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", + "friendly_name": { "type": "string" }, "links": { "type": "object" }, - "name": { + "members_count": { + "type": "integer" + }, + "messages_count": { + "type": "integer" + }, + "service_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", "type": "string" }, "sid": { "maxLength": 34, "minLength": 34, - "pattern": "^FT[0-9a-fA-F]{32}$", + "pattern": "^CH[0-9a-fA-F]{32}$", "type": "string" }, - "transitioned_from": { + "type": { + "enum": [ + "public", + "private" + ], "type": "string" }, - "transitioned_to": { + "unique_name": { "type": "string" }, "url": { @@ -189,7 +196,7 @@ }, "type": "object" }, - "studio.v1.flow.engagement.step.step_context": { + "ip_messaging.v1.service.channel.invite": { "properties": { "account_sid": { "maxLength": 34, @@ -197,25 +204,42 @@ "pattern": "^AC[0-9a-fA-F]{32}$", "type": "string" }, - "context": { - "type": "object" + "channel_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^CH[0-9a-fA-F]{32}$", + "type": "string" + }, + "created_by": { + "type": "string" + }, + "date_created": { + "format": "date-time", + "type": "string" + }, + "date_updated": { + "format": "date-time", + "type": "string" + }, + "identity": { + "type": "string" }, - "engagement_sid": { + "role_sid": { "maxLength": 34, "minLength": 34, - "pattern": "^FN[0-9a-fA-F]{32}$", + "pattern": "^RL[0-9a-fA-F]{32}$", "type": "string" }, - "flow_sid": { + "service_sid": { "maxLength": 34, "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", + "pattern": "^IS[0-9a-fA-F]{32}$", "type": "string" }, - "step_sid": { + "sid": { "maxLength": 34, "minLength": 34, - "pattern": "^FT[0-9a-fA-F]{32}$", + "pattern": "^IN[0-9a-fA-F]{32}$", "type": "string" }, "url": { @@ -225,7 +249,7 @@ }, "type": "object" }, - "studio.v1.flow.execution": { + "ip_messaging.v1.service.channel.member": { "properties": { "account_sid": { "maxLength": 34, @@ -233,18 +257,12 @@ "pattern": "^AC[0-9a-fA-F]{32}$", "type": "string" }, - "contact_channel_address": { - "type": "string" - }, - "contact_sid": { + "channel_sid": { "maxLength": 34, "minLength": 34, - "pattern": "^FC[0-9a-fA-F]{32}$", + "pattern": "^CH[0-9a-fA-F]{32}$", "type": "string" }, - "context": { - "type": "object" - }, "date_created": { "format": "date-time", "type": "string" @@ -253,56 +271,33 @@ "format": "date-time", "type": "string" }, - "flow_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", + "identity": { "type": "string" }, - "links": { - "type": "object" - }, - "sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FN[0-9a-fA-F]{32}$", - "type": "string" + "last_consumed_message_index": { + "nullable": true, + "type": "integer" }, - "status": { - "enum": [ - "active", - "ended" - ], + "last_consumption_timestamp": { + "format": "date-time", "type": "string" }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - }, - "studio.v1.flow.execution.execution_context": { - "properties": { - "account_sid": { + "role_sid": { "maxLength": 34, "minLength": 34, - "pattern": "^AC[0-9a-fA-F]{32}$", + "pattern": "^RL[0-9a-fA-F]{32}$", "type": "string" }, - "context": { - "type": "object" - }, - "execution_sid": { + "service_sid": { "maxLength": 34, "minLength": 34, - "pattern": "^FN[0-9a-fA-F]{32}$", + "pattern": "^IS[0-9a-fA-F]{32}$", "type": "string" }, - "flow_sid": { + "sid": { "maxLength": 34, "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", + "pattern": "^MB[0-9a-fA-F]{32}$", "type": "string" }, "url": { @@ -312,7 +307,7 @@ }, "type": "object" }, - "studio.v1.flow.execution.execution_step": { + "ip_messaging.v1.service.channel.message": { "properties": { "account_sid": { "maxLength": 34, @@ -320,91 +315,61 @@ "pattern": "^AC[0-9a-fA-F]{32}$", "type": "string" }, - "context": { - "type": "object" - }, - "date_created": { - "format": "date-time", - "type": "string" - }, - "date_updated": { - "format": "date-time", - "type": "string" - }, - "execution_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FN[0-9a-fA-F]{32}$", - "type": "string" - }, - "flow_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", + "attributes": { "type": "string" }, - "links": { - "type": "object" - }, - "name": { + "body": { "type": "string" }, - "sid": { + "channel_sid": { "maxLength": 34, "minLength": 34, - "pattern": "^FT[0-9a-fA-F]{32}$", + "pattern": "^CH[0-9a-fA-F]{32}$", "type": "string" }, - "transitioned_from": { + "date_created": { + "format": "date-time", "type": "string" }, - "transitioned_to": { + "date_updated": { + "format": "date-time", "type": "string" }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - }, - "studio.v1.flow.execution.execution_step.execution_step_context": { - "properties": { - "account_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^AC[0-9a-fA-F]{32}$", + "from": { "type": "string" }, - "context": { - "type": "object" + "index": { + "type": "integer" }, - "execution_sid": { + "service_sid": { "maxLength": 34, "minLength": 34, - "pattern": "^FN[0-9a-fA-F]{32}$", + "pattern": "^IS[0-9a-fA-F]{32}$", "type": "string" }, - "flow_sid": { + "sid": { "maxLength": 34, "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", + "pattern": "^IM[0-9a-fA-F]{32}$", "type": "string" }, - "step_sid": { + "to": { "maxLength": 34, "minLength": 34, - "pattern": "^FT[0-9a-fA-F]{32}$", + "pattern": "^CH[0-9a-fA-F]{32}$", "type": "string" }, "url": { "format": "uri", "type": "string" + }, + "was_edited": { + "type": "boolean" } }, "type": "object" }, - "studio.v2.flow": { + "ip_messaging.v1.service.role": { "properties": { "account_sid": { "maxLength": 34, @@ -412,9 +377,6 @@ "pattern": "^AC[0-9a-fA-F]{32}$", "type": "string" }, - "commit_message": { - "type": "string" - }, "date_created": { "format": "date-time", "type": "string" @@ -423,58 +385,42 @@ "format": "date-time", "type": "string" }, - "definition": { - "type": "object" + "friendly_name": { + "type": "string" }, - "errors": { + "permissions": { "items": { - "type": "object" + "type": "string" }, "type": "array" }, - "friendly_name": { + "service_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", "type": "string" }, - "links": { - "type": "object" - }, - "revision": { - "type": "integer" - }, "sid": { "maxLength": 34, "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", + "pattern": "^RL[0-9a-fA-F]{32}$", "type": "string" }, - "status": { + "type": { "enum": [ - "draft", - "published" + "channel", + "deployment" ], "type": "string" }, "url": { "format": "uri", "type": "string" - }, - "valid": { - "type": "boolean" - }, - "warnings": { - "items": { - "type": "object" - }, - "type": "array" - }, - "webhook_url": { - "format": "uri", - "type": "string" } }, "type": "object" }, - "studio.v2.flow.execution": { + "ip_messaging.v1.service.user": { "properties": { "account_sid": { "maxLength": 34, @@ -482,12 +428,9 @@ "pattern": "^AC[0-9a-fA-F]{32}$", "type": "string" }, - "contact_channel_address": { + "attributes": { "type": "string" }, - "context": { - "type": "object" - }, "date_created": { "format": "date-time", "type": "string" @@ -496,56 +439,40 @@ "format": "date-time", "type": "string" }, - "flow_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", + "friendly_name": { "type": "string" }, - "links": { - "type": "object" - }, - "sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FN[0-9a-fA-F]{32}$", + "identity": { "type": "string" }, - "status": { - "enum": [ - "active", - "ended" - ], - "type": "string" + "is_notifiable": { + "type": "boolean" }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - }, - "studio.v2.flow.execution.execution_context": { - "properties": { - "account_sid": { + "is_online": { + "type": "boolean" + }, + "joined_channels_count": { + "type": "integer" + }, + "links": { + "type": "object" + }, + "role_sid": { "maxLength": 34, "minLength": 34, - "pattern": "^AC[0-9a-fA-F]{32}$", + "pattern": "^RL[0-9a-fA-F]{32}$", "type": "string" }, - "context": { - "type": "object" - }, - "execution_sid": { + "service_sid": { "maxLength": 34, "minLength": 34, - "pattern": "^FN[0-9a-fA-F]{32}$", + "pattern": "^IS[0-9a-fA-F]{32}$", "type": "string" }, - "flow_sid": { + "sid": { "maxLength": 34, "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", + "pattern": "^US[0-9a-fA-F]{32}$", "type": "string" }, "url": { @@ -555,7 +482,7 @@ }, "type": "object" }, - "studio.v2.flow.execution.execution_step": { + "ip_messaging.v1.service.user.user_channel": { "properties": { "account_sid": { "maxLength": 34, @@ -563,172 +490,42 @@ "pattern": "^AC[0-9a-fA-F]{32}$", "type": "string" }, - "context": { - "type": "object" - }, - "date_created": { - "format": "date-time", - "type": "string" - }, - "date_updated": { - "format": "date-time", - "type": "string" - }, - "execution_sid": { + "channel_sid": { "maxLength": 34, "minLength": 34, - "pattern": "^FN[0-9a-fA-F]{32}$", + "pattern": "^CH[0-9a-fA-F]{32}$", "type": "string" }, - "flow_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", - "type": "string" + "last_consumed_message_index": { + "nullable": true, + "type": "integer" }, "links": { "type": "object" }, - "name": { - "type": "string" - }, - "sid": { + "member_sid": { "maxLength": 34, "minLength": 34, - "pattern": "^FT[0-9a-fA-F]{32}$", + "pattern": "^MB[0-9a-fA-F]{32}$", "type": "string" }, - "transitioned_from": { + "service_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", "type": "string" }, - "transitioned_to": { + "status": { + "enum": [ + "joined", + "invited", + "not_participating" + ], "type": "string" }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - }, - "studio.v2.flow.execution.execution_step.execution_step_context": { - "properties": { - "account_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^AC[0-9a-fA-F]{32}$", - "type": "string" - }, - "context": { - "type": "object" - }, - "execution_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FN[0-9a-fA-F]{32}$", - "type": "string" - }, - "flow_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", - "type": "string" - }, - "step_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FT[0-9a-fA-F]{32}$", - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - }, - "studio.v2.flow.flow_revision": { - "properties": { - "account_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^AC[0-9a-fA-F]{32}$", - "type": "string" - }, - "commit_message": { - "type": "string" - }, - "date_created": { - "format": "date-time", - "type": "string" - }, - "date_updated": { - "format": "date-time", - "type": "string" - }, - "definition": { - "type": "object" - }, - "errors": { - "items": { - "type": "object" - }, - "type": "array" - }, - "friendly_name": { - "type": "string" - }, - "revision": { - "type": "integer" - }, - "sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", - "type": "string" - }, - "status": { - "enum": [ - "draft", - "published" - ], - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - }, - "valid": { - "type": "boolean" - } - }, - "type": "object" - }, - "studio.v2.flow.test_user": { - "properties": { - "sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", - "type": "string" - }, - "test_users": { - "items": { - "type": "string" - }, - "type": "array" - }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - }, - "studio.v2.flow_validate": { - "properties": { - "valid": { - "type": "boolean" + "unread_messages_count": { + "nullable": true, + "type": "integer" } }, "type": "object" @@ -753,116 +550,16 @@ "url": "https://www.apache.org/licenses/LICENSE-2.0.html" }, "termsOfService": "https://www.twilio.com/legal/tos", - "title": "Twilio - Studio", + "title": "Twilio - Ip_messaging", "version": "1.3.0" }, "openapi": "3.0.1", "paths": { - "/v1/Flows": { - "description": "Studio flows", - "get": { - "description": "Retrieve a list of all Flows.", - "parameters": [ - { - "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", - "in": "query", - "name": "PageSize", - "schema": { - "maximum": 1000, - "minimum": 1, - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "properties": { - "flows": { - "items": { - "$ref": "#/components/schemas/studio.v1.flow" - }, - "type": "array" - }, - "meta": { - "properties": { - "first_page_url": { - "format": "uri", - "type": "string" - }, - "key": { - "type": "string" - }, - "next_page_url": { - "format": "uri", - "type": "string" - }, - "page": { - "type": "integer" - }, - "page_size": { - "type": "integer" - }, - "previous_page_url": { - "format": "uri", - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://studio.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "friendly_name", - "status", - "version" - ], - "x-path-type": "list" - }, - "/v1/Flows/{FlowSid}/Engagements": { - "description": "[DEPRECATED] Excecutions of Studio flows", + "/v1/Credentials": { + "description": "TODO: Resource-level docs", "get": { - "description": "Retrieve a list of all Engagements for the Flow.", + "description": "", "parameters": [ - { - "description": "The SID of the Flow to read Engagements from.", - "in": "path", - "name": "FlowSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", - "type": "string" - } - }, { "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", "in": "query", @@ -880,9 +577,9 @@ "application/json": { "schema": { "properties": { - "engagements": { + "credentials": { "items": { - "$ref": "#/components/schemas/studio.v1.flow.engagement" + "$ref": "#/components/schemas/ip_messaging.v1.credential" }, "type": "array" }, @@ -934,42 +631,48 @@ ] }, "post": { - "description": "Triggers a new Engagement for the Flow", - "parameters": [ - { - "description": "The SID of the Flow.", - "in": "path", - "name": "FlowSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], + "description": "", "requestBody": { "content": { "application/x-www-form-urlencoded": { "schema": { "properties": { - "From": { - "description": "The Twilio phone number to send messages or initiate calls from during the Flow Engagement. Available as variable `{{flow.channel.address}}`", + "ApiKey": { + "description": "", + "type": "string" + }, + "Certificate": { + "description": "", + "type": "string" + }, + "FriendlyName": { + "description": "", + "type": "string" + }, + "PrivateKey": { + "description": "", "type": "string" }, - "Parameters": { - "description": "A JSON string we will add to your flow's context and that you can access as variables inside your flow. For example, if you pass in `Parameters={'name':'Zeke'}` then inside a widget you can reference the variable `{{flow.data.name}}` which will return the string 'Zeke'. Note: the JSON value must explicitly be passed as a string, not as a hash object. Depending on your particular HTTP library, you may need to add quotes or URL encode your JSON string.", - "type": "object" + "Sandbox": { + "description": "", + "type": "boolean" + }, + "Secret": { + "description": "", + "type": "string" }, - "To": { - "description": "The Contact phone number to start a Studio Flow Engagement, available as variable `{{contact.channel.address}}`.", + "Type": { + "description": "", + "enum": [ + "gcm", + "apn", + "fcm" + ], "type": "string" } }, "required": [ - "To", - "From" + "Type" ], "type": "object" } @@ -981,7 +684,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/studio.v1.flow.engagement" + "$ref": "#/components/schemas/ip_messaging.v1.credential" } } }, @@ -999,43 +702,60 @@ }, "servers": [ { - "url": "https://studio.twilio.com" + "url": "https://ip-messaging.twilio.com" } ], "x-default-output-properties": [ "sid", - "contact_sid", - "status", - "date_created" + "friendly_name", + "type" ], "x-path-type": "list" }, - "/v1/Flows/{FlowSid}/Engagements/{EngagementSid}/Context": { - "description": "[DEPRECATED] JSON context for engagements", - "get": { - "description": "Retrieve the most recent context for an Engagement.", + "/v1/Credentials/{Sid}": { + "delete": { + "description": "", "parameters": [ { - "description": "The SID of the Flow.", + "description": "", "in": "path", - "name": "FlowSid", + "name": "Sid", "required": true, "schema": { "maxLength": 34, "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", + "pattern": "^CR[0-9a-fA-F]{32}$", "type": "string" } - }, + } + ], + "responses": { + "204": { + "description": "The resource was deleted successfully." + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "description": "TODO: Resource-level docs", + "get": { + "description": "", + "parameters": [ { - "description": "The SID of the Engagement.", + "description": "", "in": "path", - "name": "EngagementSid", + "name": "Sid", "required": true, "schema": { "maxLength": 34, "minLength": 34, - "pattern": "^FN[0-9a-fA-F]{32}$", + "pattern": "^CR[0-9a-fA-F]{32}$", "type": "string" } } @@ -1045,7 +765,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/studio.v1.flow.engagement.engagement_context" + "$ref": "#/components/schemas/ip_messaging.v1.credential" } } }, @@ -1061,45 +781,95 @@ "GA" ] }, - "servers": [ - { - "url": "https://studio.twilio.com" - } - ], - "x-default-output-properties": [ - "context" - ], - "x-path-type": "instance" - }, - "/v1/Flows/{FlowSid}/Engagements/{EngagementSid}/Steps": { - "description": "Steps within a Studio flow", - "get": { - "description": "Retrieve a list of all Steps for an Engagement.", + "post": { + "description": "", "parameters": [ { - "description": "The SID of the Flow with the Step to read.", + "description": "", "in": "path", - "name": "FlowSid", + "name": "Sid", "required": true, "schema": { "maxLength": 34, "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", + "pattern": "^CR[0-9a-fA-F]{32}$", "type": "string" } - }, - { - "description": "The SID of the Engagement with the Step to read.", - "in": "path", - "name": "EngagementSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FN[0-9a-fA-F]{32}$", - "type": "string" + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "schema": { + "properties": { + "ApiKey": { + "description": "", + "type": "string" + }, + "Certificate": { + "description": "", + "type": "string" + }, + "FriendlyName": { + "description": "", + "type": "string" + }, + "PrivateKey": { + "description": "", + "type": "string" + }, + "Sandbox": { + "description": "", + "type": "boolean" + }, + "Secret": { + "description": "", + "type": "string" + } + }, + "type": "object" + } } - }, + } + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/ip_messaging.v1.credential" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "servers": [ + { + "url": "https://ip-messaging.twilio.com" + } + ], + "x-default-output-properties": [ + "sid", + "friendly_name", + "type" + ], + "x-path-type": "instance" + }, + "/v1/Services": { + "description": "TODO: Resource-level docs", + "get": { + "description": "", + "parameters": [ { "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", "in": "query", @@ -1147,9 +917,9 @@ }, "type": "object" }, - "steps": { + "services": { "items": { - "$ref": "#/components/schemas/studio.v1.flow.engagement.step" + "$ref": "#/components/schemas/ip_messaging.v1.service" }, "type": "array" } @@ -1170,71 +940,36 @@ "GA" ] }, - "servers": [ - { - "url": "https://studio.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "name", - "transitioned_from", - "transitioned_to" - ], - "x-path-type": "list" - }, - "/v1/Flows/{FlowSid}/Engagements/{EngagementSid}/Steps/{Sid}": { - "description": "Steps within a Studio flow", - "get": { - "description": "Retrieve a Step.", - "parameters": [ - { - "description": "The SID of the Flow with the Step to fetch.", - "in": "path", - "name": "FlowSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "The SID of the Engagement with the Step to fetch.", - "in": "path", - "name": "EngagementSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FN[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "The SID of the Step resource to fetch.", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FT[0-9a-fA-F]{32}$", - "type": "string" + "post": { + "description": "", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "schema": { + "properties": { + "FriendlyName": { + "description": "", + "type": "string" + } + }, + "required": [ + "FriendlyName" + ], + "type": "object" + } } } - ], + }, "responses": { - "200": { + "201": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/studio.v1.flow.engagement.step" + "$ref": "#/components/schemas/ip_messaging.v1.service" } } }, - "description": "OK" + "description": "Created" } }, "security": [ @@ -1248,56 +983,56 @@ }, "servers": [ { - "url": "https://studio.twilio.com" + "url": "https://ip-messaging.twilio.com" } ], "x-default-output-properties": [ "sid", - "name", - "transitioned_from", - "transitioned_to" + "friendly_name", + "date_created" ], - "x-path-type": "instance" + "x-path-type": "list" }, - "/v1/Flows/{FlowSid}/Engagements/{EngagementSid}/Steps/{StepSid}/Context": { - "description": "JSON context for individual steps", + "/v1/Services/{ServiceSid}/Channels": { + "description": "TODO: Resource-level docs", "get": { - "description": "Retrieve the context for an Engagement Step.", + "description": "", "parameters": [ { - "description": "The SID of the Flow with the Step to fetch.", + "description": "", "in": "path", - "name": "FlowSid", + "name": "ServiceSid", "required": true, "schema": { "maxLength": 34, "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", + "pattern": "^IS[0-9a-fA-F]{32}$", "type": "string" } }, { - "description": "The SID of the Engagement with the Step to fetch.", - "in": "path", - "name": "EngagementSid", - "required": true, + "description": "", + "in": "query", + "name": "Type", "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FN[0-9a-fA-F]{32}$", - "type": "string" + "items": { + "enum": [ + "public", + "private" + ], + "type": "string" + }, + "type": "array" } }, { - "description": "The SID of the Step to fetch", - "in": "path", - "name": "StepSid", - "required": true, + "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", + "in": "query", + "name": "PageSize", "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FT[0-9a-fA-F]{32}$", - "type": "string" + "maximum": 1000, + "minimum": 1, + "type": "integer" } } ], @@ -1306,7 +1041,45 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/studio.v1.flow.engagement.step.step_context" + "properties": { + "channels": { + "items": { + "$ref": "#/components/schemas/ip_messaging.v1.service.channel" + }, + "type": "array" + }, + "meta": { + "properties": { + "first_page_url": { + "format": "uri", + "type": "string" + }, + "key": { + "type": "string" + }, + "next_page_url": { + "format": "uri", + "type": "string" + }, + "page": { + "type": "integer" + }, + "page_size": { + "type": "integer" + }, + "previous_page_url": { + "format": "uri", + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + } + }, + "type": "object" } } }, @@ -1322,98 +1095,63 @@ "GA" ] }, - "servers": [ - { - "url": "https://studio.twilio.com" - } - ], - "x-default-output-properties": [ - "context" - ], - "x-path-type": "instance" - }, - "/v1/Flows/{FlowSid}/Engagements/{Sid}": { - "delete": { - "description": "Delete this Engagement and all Steps relating to it.", + "post": { + "description": "", "parameters": [ { - "description": "The SID of the Flow to delete Engagements from.", - "in": "path", - "name": "FlowSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "The SID of the Engagement resource to delete.", + "description": "", "in": "path", - "name": "Sid", + "name": "ServiceSid", "required": true, "schema": { "maxLength": 34, "minLength": 34, - "pattern": "^FN[0-9a-fA-F]{32}$", + "pattern": "^IS[0-9a-fA-F]{32}$", "type": "string" } } ], - "responses": { - "204": { - "description": "The resource was deleted successfully." - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "description": "[DEPRECATED] Excecutions of Studio flows", - "get": { - "description": "Retrieve an Engagement", - "parameters": [ - { - "description": "The SID of the Flow.", - "in": "path", - "name": "FlowSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "The SID of the Engagement resource to fetch.", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FN[0-9a-fA-F]{32}$", - "type": "string" + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "schema": { + "properties": { + "Attributes": { + "description": "", + "type": "string" + }, + "FriendlyName": { + "description": "", + "type": "string" + }, + "Type": { + "description": "", + "enum": [ + "public", + "private" + ], + "type": "string" + }, + "UniqueName": { + "description": "", + "type": "string" + } + }, + "type": "object" + } } } - ], + }, "responses": { - "200": { + "201": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/studio.v1.flow.engagement" + "$ref": "#/components/schemas/ip_messaging.v1.service.channel" } } }, - "description": "OK" + "description": "Created" } }, "security": [ @@ -1427,50 +1165,51 @@ }, "servers": [ { - "url": "https://studio.twilio.com" + "url": "https://ip-messaging.twilio.com" } ], "x-default-output-properties": [ "sid", - "contact_sid", - "status", - "date_created" + "unique_name", + "friendly_name" ], - "x-path-type": "instance" + "x-path-type": "list" }, - "/v1/Flows/{FlowSid}/Executions": { - "description": "Executions of Studio flows", + "/v1/Services/{ServiceSid}/Channels/{ChannelSid}/Invites": { + "description": "TODO: Resource-level docs", "get": { - "description": "Retrieve a list of all Executions for the Flow.", + "description": "", "parameters": [ { - "description": "The SID of the Flow with the Execution resources to read.", + "description": "", "in": "path", - "name": "FlowSid", + "name": "ServiceSid", "required": true, "schema": { "maxLength": 34, "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", + "pattern": "^IS[0-9a-fA-F]{32}$", "type": "string" } }, { - "description": "Only show Execution resources starting on or after this [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date-time, given as `YYYY-MM-DDThh:mm:ss-hh:mm`.", - "in": "query", - "name": "DateCreatedFrom", + "description": "", + "in": "path", + "name": "ChannelSid", + "required": true, "schema": { - "format": "date-time", "type": "string" } }, { - "description": "Only show Execution resources starting before this [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date-time, given as `YYYY-MM-DDThh:mm:ss-hh:mm`.", + "description": "", "in": "query", - "name": "DateCreatedTo", + "name": "Identity", "schema": { - "format": "date-time", - "type": "string" + "items": { + "type": "string" + }, + "type": "array" } }, { @@ -1490,9 +1229,9 @@ "application/json": { "schema": { "properties": { - "executions": { + "invites": { "items": { - "$ref": "#/components/schemas/studio.v1.flow.execution" + "$ref": "#/components/schemas/ip_messaging.v1.service.channel.invite" }, "type": "array" }, @@ -1544,17 +1283,26 @@ ] }, "post": { - "description": "Triggers a new Execution for the Flow", + "description": "", "parameters": [ { - "description": "The SID of the Excecution's Flow.", + "description": "", "in": "path", - "name": "FlowSid", + "name": "ServiceSid", "required": true, "schema": { "maxLength": 34, "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "", + "in": "path", + "name": "ChannelSid", + "required": true, + "schema": { "type": "string" } } @@ -1564,22 +1312,20 @@ "application/x-www-form-urlencoded": { "schema": { "properties": { - "From": { - "description": "The Twilio phone number to send messages or initiate calls from during the Flow's Execution. Available as variable `{{flow.channel.address}}`.", + "Identity": { + "description": "", "type": "string" }, - "Parameters": { - "description": "JSON data that will be added to the Flow's context and that can be accessed as variables inside your Flow. For example, if you pass in `Parameters={\"name\":\"Zeke\"}`, a widget in your Flow can reference the variable `{{flow.data.name}}`, which returns \"Zeke\". Note: the JSON value must explicitly be passed as a string, not as a hash object. Depending on your particular HTTP library, you may need to add quotes or URL encode the JSON string.", - "type": "object" - }, - "To": { - "description": "The Contact phone number to start a Studio Flow Execution, available as variable `{{contact.channel.address}}`.", + "RoleSid": { + "description": "", + "maxLength": 34, + "minLength": 34, + "pattern": "^RL[0-9a-fA-F]{32}$", "type": "string" } }, "required": [ - "To", - "From" + "Identity" ], "type": "object" } @@ -1591,7 +1337,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/studio.v1.flow.execution" + "$ref": "#/components/schemas/ip_messaging.v1.service.channel.invite" } } }, @@ -1609,43 +1355,102 @@ }, "servers": [ { - "url": "https://studio.twilio.com" + "url": "https://ip-messaging.twilio.com" } ], "x-default-output-properties": [ "sid", - "contact_sid", - "status", + "identity", "date_created" ], "x-path-type": "list" }, - "/v1/Flows/{FlowSid}/Executions/{ExecutionSid}/Context": { - "description": "JSON context for executions", + "/v1/Services/{ServiceSid}/Channels/{ChannelSid}/Invites/{Sid}": { + "delete": { + "description": "", + "parameters": [ + { + "description": "", + "in": "path", + "name": "ServiceSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "", + "in": "path", + "name": "ChannelSid", + "required": true, + "schema": { + "type": "string" + } + }, + { + "description": "", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IN[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "responses": { + "204": { + "description": "The resource was deleted successfully." + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "description": "TODO: Resource-level docs", "get": { - "description": "Retrieve the most recent context for an Execution.", + "description": "", "parameters": [ { - "description": "The SID of the Flow with the Execution context to fetch.", + "description": "", "in": "path", - "name": "FlowSid", + "name": "ServiceSid", "required": true, "schema": { "maxLength": 34, "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "", + "in": "path", + "name": "ChannelSid", + "required": true, + "schema": { "type": "string" } }, { - "description": "The SID of the Execution context to fetch.", + "description": "", "in": "path", - "name": "ExecutionSid", + "name": "Sid", "required": true, "schema": { "maxLength": 34, "minLength": 34, - "pattern": "^FN[0-9a-fA-F]{32}$", + "pattern": "^IN[0-9a-fA-F]{32}$", "type": "string" } } @@ -1655,7 +1460,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/studio.v1.flow.execution.execution_context" + "$ref": "#/components/schemas/ip_messaging.v1.service.channel.invite" } } }, @@ -1673,43 +1478,53 @@ }, "servers": [ { - "url": "https://studio.twilio.com" + "url": "https://ip-messaging.twilio.com" } ], "x-default-output-properties": [ - "context" + "sid", + "identity", + "date_created" ], "x-path-type": "instance" }, - "/v1/Flows/{FlowSid}/Executions/{ExecutionSid}/Steps": { - "description": "Individual steps within an execution", + "/v1/Services/{ServiceSid}/Channels/{ChannelSid}/Members": { + "description": "TODO: Resource-level docs", "get": { - "description": "Retrieve a list of all Steps for an Execution.", + "description": "", "parameters": [ { - "description": "The SID of the Flow with the Steps to read.", + "description": "", "in": "path", - "name": "FlowSid", + "name": "ServiceSid", "required": true, "schema": { "maxLength": 34, "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", + "pattern": "^IS[0-9a-fA-F]{32}$", "type": "string" } }, { - "description": "The SID of the Execution with the Steps to read.", + "description": "", "in": "path", - "name": "ExecutionSid", + "name": "ChannelSid", "required": true, "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FN[0-9a-fA-F]{32}$", "type": "string" } }, + { + "description": "", + "in": "query", + "name": "Identity", + "schema": { + "items": { + "type": "string" + }, + "type": "array" + } + }, { "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", "in": "query", @@ -1727,6 +1542,12 @@ "application/json": { "schema": { "properties": { + "members": { + "items": { + "$ref": "#/components/schemas/ip_messaging.v1.service.channel.member" + }, + "type": "array" + }, "meta": { "properties": { "first_page_url": { @@ -1756,12 +1577,6 @@ } }, "type": "object" - }, - "steps": { - "items": { - "$ref": "#/components/schemas/studio.v1.flow.execution.execution_step" - }, - "type": "array" } }, "type": "object" @@ -1780,70 +1595,66 @@ "GA" ] }, - "servers": [ - { - "url": "https://studio.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "name", - "date_created" - ], - "x-path-type": "list" - }, - "/v1/Flows/{FlowSid}/Executions/{ExecutionSid}/Steps/{Sid}": { - "description": "Individual steps within an execution", - "get": { - "description": "Retrieve a Step.", + "post": { + "description": "", "parameters": [ { - "description": "The SID of the Flow with the Step to fetch.", - "in": "path", - "name": "FlowSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "The SID of the Execution resource with the Step to fetch.", + "description": "", "in": "path", - "name": "ExecutionSid", + "name": "ServiceSid", "required": true, "schema": { "maxLength": 34, "minLength": 34, - "pattern": "^FN[0-9a-fA-F]{32}$", + "pattern": "^IS[0-9a-fA-F]{32}$", "type": "string" } }, { - "description": "The SID of the ExecutionStep resource to fetch.", + "description": "", "in": "path", - "name": "Sid", + "name": "ChannelSid", "required": true, "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FT[0-9a-fA-F]{32}$", "type": "string" } } ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "schema": { + "properties": { + "Identity": { + "description": "", + "type": "string" + }, + "RoleSid": { + "description": "", + "maxLength": 34, + "minLength": 34, + "pattern": "^RL[0-9a-fA-F]{32}$", + "type": "string" + } + }, + "required": [ + "Identity" + ], + "type": "object" + } + } + } + }, "responses": { - "200": { + "201": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/studio.v1.flow.execution.execution_step" + "$ref": "#/components/schemas/ip_messaging.v1.service.channel.member" } } }, - "description": "OK" + "description": "Created" } }, "security": [ @@ -1857,68 +1668,57 @@ }, "servers": [ { - "url": "https://studio.twilio.com" + "url": "https://ip-messaging.twilio.com" } ], "x-default-output-properties": [ "sid", - "name", + "identity", "date_created" ], - "x-path-type": "instance" + "x-path-type": "list" }, - "/v1/Flows/{FlowSid}/Executions/{ExecutionSid}/Steps/{StepSid}/Context": { - "description": "JSON context for an individual step within an execution", - "get": { - "description": "Retrieve the context for an Execution Step.", + "/v1/Services/{ServiceSid}/Channels/{ChannelSid}/Members/{Sid}": { + "delete": { + "description": "", "parameters": [ { - "description": "The SID of the Flow with the Step to fetch.", + "description": "", "in": "path", - "name": "FlowSid", + "name": "ServiceSid", "required": true, "schema": { "maxLength": 34, "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", + "pattern": "^IS[0-9a-fA-F]{32}$", "type": "string" } }, { - "description": "The SID of the Execution resource with the Step to fetch.", + "description": "", "in": "path", - "name": "ExecutionSid", + "name": "ChannelSid", "required": true, "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FN[0-9a-fA-F]{32}$", "type": "string" } }, { - "description": "The SID of the Step to fetch.", + "description": "", "in": "path", - "name": "StepSid", + "name": "Sid", "required": true, "schema": { "maxLength": 34, "minLength": 34, - "pattern": "^FT[0-9a-fA-F]{32}$", + "pattern": "^MB[0-9a-fA-F]{32}$", "type": "string" } } ], "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/studio.v1.flow.execution.execution_step.execution_step_context" - } - } - }, - "description": "OK" + "204": { + "description": "The resource was deleted successfully." } }, "security": [ @@ -1930,84 +1730,40 @@ "GA" ] }, - "servers": [ - { - "url": "https://studio.twilio.com" - } - ], - "x-default-output-properties": [ - "context" - ], - "x-path-type": "instance" - }, - "/v1/Flows/{FlowSid}/Executions/{Sid}": { - "delete": { - "description": "Delete the Execution and all Steps relating to it.", + "description": "TODO: Resource-level docs", + "get": { + "description": "", "parameters": [ { - "description": "The SID of the Flow with the Execution resources to delete.", + "description": "", "in": "path", - "name": "FlowSid", + "name": "ServiceSid", "required": true, "schema": { "maxLength": 34, "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", + "pattern": "^IS[0-9a-fA-F]{32}$", "type": "string" } }, { - "description": "The SID of the Execution resource to delete.", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FN[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "responses": { - "204": { - "description": "The resource was deleted successfully." - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "description": "Executions of Studio flows", - "get": { - "description": "Retrieve an Execution", - "parameters": [ - { - "description": "The SID of the Flow with the Execution resource to fetch", + "description": "", "in": "path", - "name": "FlowSid", + "name": "ChannelSid", "required": true, "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", "type": "string" } }, { - "description": "The SID of the Execution resource to fetch.", + "description": "", "in": "path", "name": "Sid", "required": true, "schema": { "maxLength": 34, "minLength": 34, - "pattern": "^FN[0-9a-fA-F]{32}$", + "pattern": "^MB[0-9a-fA-F]{32}$", "type": "string" } } @@ -2017,7 +1773,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/studio.v1.flow.execution" + "$ref": "#/components/schemas/ip_messaging.v1.service.channel.member" } } }, @@ -2034,29 +1790,38 @@ ] }, "post": { - "description": "Update the status of an Execution to `ended`.", + "description": "", "parameters": [ { - "description": "The SID of the Flow with the Execution resources to update.", + "description": "", "in": "path", - "name": "FlowSid", + "name": "ServiceSid", "required": true, "schema": { "maxLength": 34, "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", + "pattern": "^IS[0-9a-fA-F]{32}$", "type": "string" } }, { - "description": "The SID of the Execution resource to update.", + "description": "", + "in": "path", + "name": "ChannelSid", + "required": true, + "schema": { + "type": "string" + } + }, + { + "description": "", "in": "path", "name": "Sid", "required": true, "schema": { "maxLength": 34, "minLength": 34, - "pattern": "^FN[0-9a-fA-F]{32}$", + "pattern": "^MB[0-9a-fA-F]{32}$", "type": "string" } } @@ -2066,18 +1831,19 @@ "application/x-www-form-urlencoded": { "schema": { "properties": { - "Status": { - "description": "The status of the Execution. Can only be `ended`.", - "enum": [ - "active", - "ended" - ], + "LastConsumedMessageIndex": { + "description": "", + "nullable": true, + "type": "integer" + }, + "RoleSid": { + "description": "", + "maxLength": 34, + "minLength": 34, + "pattern": "^RL[0-9a-fA-F]{32}$", "type": "string" } }, - "required": [ - "Status" - ], "type": "object" } } @@ -2088,7 +1854,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/studio.v1.flow.execution" + "$ref": "#/components/schemas/ip_messaging.v1.service.channel.member" } } }, @@ -2106,104 +1872,57 @@ }, "servers": [ { - "url": "https://studio.twilio.com" + "url": "https://ip-messaging.twilio.com" } ], "x-default-output-properties": [ "sid", - "contact_sid", - "status", + "identity", "date_created" ], "x-path-type": "instance" }, - "/v1/Flows/{Sid}": { - "delete": { - "description": "Delete a specific Flow.", + "/v1/Services/{ServiceSid}/Channels/{ChannelSid}/Messages": { + "description": "TODO: Resource-level docs", + "get": { + "description": "", "parameters": [ { - "description": "The SID of the Flow resource to delete.", + "description": "", "in": "path", - "name": "Sid", + "name": "ServiceSid", "required": true, "schema": { "maxLength": 34, "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", + "pattern": "^IS[0-9a-fA-F]{32}$", "type": "string" } - } - ], - "responses": { - "204": { - "description": "The resource was deleted successfully." - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "description": "Studio flows", - "get": { - "description": "Retrieve a specific Flow.", - "parameters": [ + }, { - "description": "The SID of the Flow resource to fetch.", + "description": "", "in": "path", - "name": "Sid", + "name": "ChannelSid", "required": true, "schema": { "maxLength": 34, "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", + "pattern": "^CH[0-9a-fA-F]{32}$", "type": "string" } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/studio.v1.flow" - } - } - }, - "description": "OK" - } - }, - "security": [ + }, { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://studio.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "friendly_name", - "status", - "version" - ], - "x-path-type": "instance" - }, - "/v2/Flows": { - "description": "Studio flows", - "get": { - "description": "Retrieve a list of all Flows.", - "parameters": [ + "description": "", + "in": "query", + "name": "Order", + "schema": { + "enum": [ + "asc", + "desc" + ], + "type": "string" + } + }, { "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", "in": "query", @@ -2221,9 +1940,9 @@ "application/json": { "schema": { "properties": { - "flows": { + "messages": { "items": { - "$ref": "#/components/schemas/studio.v2.flow" + "$ref": "#/components/schemas/ip_messaging.v1.service.channel.message" }, "type": "array" }, @@ -2271,41 +1990,57 @@ } ], "tags": [ - "Beta" + "GA" ] }, "post": { - "description": "Create a Flow.", + "description": "", + "parameters": [ + { + "description": "", + "in": "path", + "name": "ServiceSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "", + "in": "path", + "name": "ChannelSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^CH[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], "requestBody": { "content": { "application/x-www-form-urlencoded": { "schema": { "properties": { - "CommitMessage": { - "description": "Description on change made in the revision.", + "Attributes": { + "description": "", "type": "string" }, - "Definition": { - "description": "JSON representation of flow definition.", - "type": "object" - }, - "FriendlyName": { - "description": "The string that you assigned to describe the Flow.", + "Body": { + "description": "", "type": "string" }, - "Status": { - "description": "The status of the Flow. Can be: `draft` or `published`.", - "enum": [ - "draft", - "published" - ], + "From": { + "description": "", "type": "string" } }, "required": [ - "FriendlyName", - "Status", - "Definition" + "Body" ], "type": "object" } @@ -2317,7 +2052,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/studio.v2.flow" + "$ref": "#/components/schemas/ip_messaging.v1.service.channel.message" } } }, @@ -2326,61 +2061,197 @@ }, "security": [ { - "accountSid_authToken": [] + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "servers": [ + { + "url": "https://ip-messaging.twilio.com" + } + ], + "x-default-output-properties": [ + "sid", + "from", + "to", + "date_created" + ], + "x-path-type": "list" + }, + "/v1/Services/{ServiceSid}/Channels/{ChannelSid}/Messages/{Sid}": { + "delete": { + "description": "", + "parameters": [ + { + "description": "", + "in": "path", + "name": "ServiceSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "", + "in": "path", + "name": "ChannelSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^CH[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IM[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "responses": { + "204": { + "description": "The resource was deleted successfully." + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "description": "TODO: Resource-level docs", + "get": { + "description": "", + "parameters": [ + { + "description": "", + "in": "path", + "name": "ServiceSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "", + "in": "path", + "name": "ChannelSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^CH[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IM[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/ip_messaging.v1.service.channel.message" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "post": { + "description": "", + "parameters": [ + { + "description": "", + "in": "path", + "name": "ServiceSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "", + "in": "path", + "name": "ChannelSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^CH[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IM[0-9a-fA-F]{32}$", + "type": "string" + } } ], - "tags": [ - "Beta" - ] - }, - "servers": [ - { - "url": "https://studio.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "friendly_name", - "status", - "revision" - ], - "x-path-type": "list" - }, - "/v2/Flows/Validate": { - "description": "TODO: Resource-level docs", - "post": { - "description": "", "requestBody": { "content": { "application/x-www-form-urlencoded": { "schema": { "properties": { - "CommitMessage": { + "Attributes": { "description": "", "type": "string" }, - "Definition": { + "Body": { "description": "", - "type": "object" - }, - "FriendlyName": { - "description": "", - "type": "string" - }, - "Status": { - "description": "", - "enum": [ - "draft", - "published" - ], "type": "string" } }, - "required": [ - "FriendlyName", - "Status", - "Definition" - ], "type": "object" } } @@ -2391,7 +2262,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/studio.v2.flow_validate" + "$ref": "#/components/schemas/ip_messaging.v1.service.channel.message" } } }, @@ -2404,113 +2275,51 @@ } ], "tags": [ - "Beta" + "GA" ] }, "servers": [ { - "url": "https://studio.twilio.com" + "url": "https://ip-messaging.twilio.com" } ], "x-default-output-properties": [ - "valid" + "sid", + "from", + "to", + "date_created" ], - "x-path-type": "list" + "x-path-type": "instance" }, - "/v2/Flows/{FlowSid}/Executions": { - "description": "Executions of Studio flows", - "get": { - "description": "Retrieve a list of all Executions for the Flow.", + "/v1/Services/{ServiceSid}/Channels/{Sid}": { + "delete": { + "description": "", "parameters": [ { - "description": "The SID of the Flow with the Execution resources to read.", + "description": "", "in": "path", - "name": "FlowSid", + "name": "ServiceSid", "required": true, "schema": { "maxLength": 34, "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "Only show Execution resources starting on or after this [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date-time, given as `YYYY-MM-DDThh:mm:ss-hh:mm`.", - "in": "query", - "name": "DateCreatedFrom", - "schema": { - "format": "date-time", + "pattern": "^IS[0-9a-fA-F]{32}$", "type": "string" } }, { - "description": "Only show Execution resources starting before this [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date-time, given as `YYYY-MM-DDThh:mm:ss-hh:mm`.", - "in": "query", - "name": "DateCreatedTo", + "description": "", + "in": "path", + "name": "Sid", + "required": true, "schema": { - "format": "date-time", "type": "string" } - }, - { - "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", - "in": "query", - "name": "PageSize", - "schema": { - "maximum": 1000, - "minimum": 1, - "type": "integer" - } } ], "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "properties": { - "executions": { - "items": { - "$ref": "#/components/schemas/studio.v2.flow.execution" - }, - "type": "array" - }, - "meta": { - "properties": { - "first_page_url": { - "format": "uri", - "type": "string" - }, - "key": { - "type": "string" - }, - "next_page_url": { - "format": "uri", - "type": "string" - }, - "page": { - "type": "integer" - }, - "page_size": { - "type": "integer" - }, - "previous_page_url": { - "format": "uri", - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - } - } - }, - "description": "OK" + "204": { + "description": "The resource was deleted successfully." } }, "security": [ @@ -2519,62 +2328,45 @@ } ], "tags": [ - "Beta" + "GA" ] }, - "post": { - "description": "Triggers a new Execution for the Flow", + "description": "TODO: Resource-level docs", + "get": { + "description": "", "parameters": [ { - "description": "The SID of the Excecution's Flow.", + "description": "", "in": "path", - "name": "FlowSid", + "name": "ServiceSid", "required": true, "schema": { "maxLength": 34, "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", + "pattern": "^IS[0-9a-fA-F]{32}$", "type": "string" } - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "schema": { - "properties": { - "From": { - "description": "The Twilio phone number to send messages or initiate calls from during the Flow's Execution. Available as variable `{{flow.channel.address}}`.", - "type": "string" - }, - "Parameters": { - "description": "JSON data that will be added to the Flow's context and that can be accessed as variables inside your Flow. For example, if you pass in `Parameters={\"name\":\"Zeke\"}`, a widget in your Flow can reference the variable `{{flow.data.name}}`, which returns \"Zeke\". Note: the JSON value must explicitly be passed as a string, not as a hash object. Depending on your particular HTTP library, you may need to add quotes or URL encode the JSON string.", - "type": "object" - }, - "To": { - "description": "The Contact phone number to start a Studio Flow Execution, available as variable `{{contact.channel.address}}`.", - "type": "string" - } - }, - "required": [ - "To", - "From" - ], - "type": "object" - } + }, + { + "description": "", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "type": "string" } } - }, + ], "responses": { - "201": { + "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/studio.v2.flow.execution" + "$ref": "#/components/schemas/ip_messaging.v1.service.channel" } } }, - "description": "Created" + "description": "OK" } }, "security": [ @@ -2583,57 +2375,63 @@ } ], "tags": [ - "Beta" + "GA" ] }, - "servers": [ - { - "url": "https://studio.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "status", - "date_created" - ], - "x-path-type": "list" - }, - "/v2/Flows/{FlowSid}/Executions/{ExecutionSid}/Context": { - "description": "JSON context for executions", - "get": { - "description": "Retrieve the most recent context for an Execution.", + "post": { + "description": "", "parameters": [ { - "description": "The SID of the Flow with the Execution context to fetch.", + "description": "", "in": "path", - "name": "FlowSid", + "name": "ServiceSid", "required": true, "schema": { "maxLength": 34, "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", + "pattern": "^IS[0-9a-fA-F]{32}$", "type": "string" } }, { - "description": "The SID of the Execution context to fetch.", + "description": "", "in": "path", - "name": "ExecutionSid", + "name": "Sid", "required": true, "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FN[0-9a-fA-F]{32}$", "type": "string" } } ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "schema": { + "properties": { + "Attributes": { + "description": "", + "type": "string" + }, + "FriendlyName": { + "description": "", + "type": "string" + }, + "UniqueName": { + "description": "", + "type": "string" + } + }, + "type": "object" + } + } + } + }, "responses": { "200": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/studio.v2.flow.execution.execution_context" + "$ref": "#/components/schemas/ip_messaging.v1.service.channel" } } }, @@ -2646,45 +2444,35 @@ } ], "tags": [ - "Beta" + "GA" ] }, "servers": [ { - "url": "https://studio.twilio.com" + "url": "https://ip-messaging.twilio.com" } ], "x-default-output-properties": [ - "context" + "sid", + "unique_name", + "friendly_name" ], "x-path-type": "instance" }, - "/v2/Flows/{FlowSid}/Executions/{ExecutionSid}/Steps": { - "description": "Individual steps within an execution", + "/v1/Services/{ServiceSid}/Roles": { + "description": "TODO: Resource-level docs", "get": { - "description": "Retrieve a list of all Steps for an Execution.", + "description": "", "parameters": [ { - "description": "The SID of the Flow with the Steps to read.", - "in": "path", - "name": "FlowSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "The SID of the Execution with the Steps to read.", + "description": "", "in": "path", - "name": "ExecutionSid", + "name": "ServiceSid", "required": true, "schema": { "maxLength": 34, "minLength": 34, - "pattern": "^FN[0-9a-fA-F]{32}$", + "pattern": "^IS[0-9a-fA-F]{32}$", "type": "string" } }, @@ -2735,18 +2523,90 @@ }, "type": "object" }, - "steps": { + "roles": { "items": { - "$ref": "#/components/schemas/studio.v2.flow.execution.execution_step" + "$ref": "#/components/schemas/ip_messaging.v1.service.role" }, "type": "array" } }, - "type": "object" + "type": "object" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "post": { + "description": "", + "parameters": [ + { + "description": "", + "in": "path", + "name": "ServiceSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "schema": { + "properties": { + "FriendlyName": { + "description": "", + "type": "string" + }, + "Permission": { + "description": "", + "items": { + "type": "string" + }, + "type": "array" + }, + "Type": { + "description": "", + "enum": [ + "channel", + "deployment" + ], + "type": "string" + } + }, + "required": [ + "FriendlyName", + "Type", + "Permission" + ], + "type": "object" + } + } + } + }, + "responses": { + "201": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/ip_messaging.v1.service.role" } } }, - "description": "OK" + "description": "Created" } }, "security": [ @@ -2755,73 +2615,53 @@ } ], "tags": [ - "Beta" + "GA" ] }, "servers": [ { - "url": "https://studio.twilio.com" + "url": "https://ip-messaging.twilio.com" } ], "x-default-output-properties": [ "sid", - "name", - "date_created" + "friendly_name", + "type" ], "x-path-type": "list" }, - "/v2/Flows/{FlowSid}/Executions/{ExecutionSid}/Steps/{Sid}": { - "description": "Individual steps within an execution", - "get": { - "description": "Retrieve a Step.", + "/v1/Services/{ServiceSid}/Roles/{Sid}": { + "delete": { + "description": "", "parameters": [ { - "description": "The SID of the Flow with the Step to fetch.", - "in": "path", - "name": "FlowSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "The SID of the Execution resource with the Step to fetch.", + "description": "", "in": "path", - "name": "ExecutionSid", + "name": "ServiceSid", "required": true, "schema": { "maxLength": 34, "minLength": 34, - "pattern": "^FN[0-9a-fA-F]{32}$", + "pattern": "^IS[0-9a-fA-F]{32}$", "type": "string" } }, { - "description": "The SID of the ExecutionStep resource to fetch.", + "description": "", "in": "path", "name": "Sid", "required": true, "schema": { "maxLength": 34, "minLength": 34, - "pattern": "^FT[0-9a-fA-F]{32}$", + "pattern": "^RL[0-9a-fA-F]{32}$", "type": "string" } } ], "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/studio.v2.flow.execution.execution_step" - } - } - }, - "description": "OK" + "204": { + "description": "The resource was deleted successfully." } }, "security": [ @@ -2830,59 +2670,34 @@ } ], "tags": [ - "Beta" + "GA" ] }, - "servers": [ - { - "url": "https://studio.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "name", - "date_created" - ], - "x-path-type": "instance" - }, - "/v2/Flows/{FlowSid}/Executions/{ExecutionSid}/Steps/{StepSid}/Context": { - "description": "JSON context for an individual step within an execution", + "description": "TODO: Resource-level docs", "get": { - "description": "Retrieve the context for an Execution Step.", + "description": "", "parameters": [ { - "description": "The SID of the Flow with the Step to fetch.", - "in": "path", - "name": "FlowSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "The SID of the Execution resource with the Step to fetch.", + "description": "", "in": "path", - "name": "ExecutionSid", + "name": "ServiceSid", "required": true, "schema": { "maxLength": 34, "minLength": 34, - "pattern": "^FN[0-9a-fA-F]{32}$", + "pattern": "^IS[0-9a-fA-F]{32}$", "type": "string" } }, { - "description": "The SID of the Step to fetch.", + "description": "", "in": "path", - "name": "StepSid", + "name": "Sid", "required": true, "schema": { "maxLength": 34, "minLength": 34, - "pattern": "^FT[0-9a-fA-F]{32}$", + "pattern": "^RL[0-9a-fA-F]{32}$", "type": "string" } } @@ -2892,7 +2707,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/studio.v2.flow.execution.execution_step.execution_step_context" + "$ref": "#/components/schemas/ip_messaging.v1.service.role" } } }, @@ -2905,51 +2720,68 @@ } ], "tags": [ - "Beta" + "GA" ] }, - "servers": [ - { - "url": "https://studio.twilio.com" - } - ], - "x-default-output-properties": [ - "context" - ], - "x-path-type": "instance" - }, - "/v2/Flows/{FlowSid}/Executions/{Sid}": { - "delete": { - "description": "Delete the Execution and all Steps relating to it.", + "post": { + "description": "", "parameters": [ { - "description": "The SID of the Flow with the Execution resources to delete.", + "description": "", "in": "path", - "name": "FlowSid", + "name": "ServiceSid", "required": true, "schema": { "maxLength": 34, "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", + "pattern": "^IS[0-9a-fA-F]{32}$", "type": "string" } }, { - "description": "The SID of the Execution resource to delete.", + "description": "", "in": "path", "name": "Sid", "required": true, "schema": { "maxLength": 34, "minLength": 34, - "pattern": "^FN[0-9a-fA-F]{32}$", + "pattern": "^RL[0-9a-fA-F]{32}$", "type": "string" } } ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "schema": { + "properties": { + "Permission": { + "description": "", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "required": [ + "Permission" + ], + "type": "object" + } + } + } + }, "responses": { - "204": { - "description": "The resource was deleted successfully." + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/ip_messaging.v1.service.role" + } + } + }, + "description": "OK" } }, "security": [ @@ -2958,35 +2790,46 @@ } ], "tags": [ - "Beta" + "GA" ] }, - "description": "Executions of Studio flows", + "servers": [ + { + "url": "https://ip-messaging.twilio.com" + } + ], + "x-default-output-properties": [ + "sid", + "friendly_name", + "type" + ], + "x-path-type": "instance" + }, + "/v1/Services/{ServiceSid}/Users": { + "description": "TODO: Resource-level docs", "get": { - "description": "Retrieve an Execution", + "description": "", "parameters": [ { - "description": "The SID of the Flow with the Execution resource to fetch", + "description": "", "in": "path", - "name": "FlowSid", + "name": "ServiceSid", "required": true, "schema": { "maxLength": 34, "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", + "pattern": "^IS[0-9a-fA-F]{32}$", "type": "string" } }, { - "description": "The SID of the Execution resource to fetch.", - "in": "path", - "name": "Sid", - "required": true, + "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", + "in": "query", + "name": "PageSize", "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FN[0-9a-fA-F]{32}$", - "type": "string" + "maximum": 1000, + "minimum": 1, + "type": "integer" } } ], @@ -2995,7 +2838,45 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/studio.v2.flow.execution" + "properties": { + "meta": { + "properties": { + "first_page_url": { + "format": "uri", + "type": "string" + }, + "key": { + "type": "string" + }, + "next_page_url": { + "format": "uri", + "type": "string" + }, + "page": { + "type": "integer" + }, + "page_size": { + "type": "integer" + }, + "previous_page_url": { + "format": "uri", + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + }, + "users": { + "items": { + "$ref": "#/components/schemas/ip_messaging.v1.service.user" + }, + "type": "array" + } + }, + "type": "object" } } }, @@ -3008,33 +2889,21 @@ } ], "tags": [ - "Beta" + "GA" ] }, "post": { - "description": "Update the status of an Execution to `ended`.", + "description": "", "parameters": [ { - "description": "The SID of the Flow with the Execution resources to update.", - "in": "path", - "name": "FlowSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "The SID of the Execution resource to update.", + "description": "", "in": "path", - "name": "Sid", + "name": "ServiceSid", "required": true, "schema": { "maxLength": 34, "minLength": 34, - "pattern": "^FN[0-9a-fA-F]{32}$", + "pattern": "^IS[0-9a-fA-F]{32}$", "type": "string" } } @@ -3044,17 +2913,28 @@ "application/x-www-form-urlencoded": { "schema": { "properties": { - "Status": { - "description": "The status of the Execution. Can only be `ended`.", - "enum": [ - "active", - "ended" - ], + "Attributes": { + "description": "", + "type": "string" + }, + "FriendlyName": { + "description": "", + "type": "string" + }, + "Identity": { + "description": "", + "type": "string" + }, + "RoleSid": { + "description": "", + "maxLength": 34, + "minLength": 34, + "pattern": "^RL[0-9a-fA-F]{32}$", "type": "string" } }, "required": [ - "Status" + "Identity" ], "type": "object" } @@ -3062,15 +2942,15 @@ } }, "responses": { - "200": { + "201": { "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/studio.v2.flow.execution" + "$ref": "#/components/schemas/ip_messaging.v1.service.user" } } }, - "description": "OK" + "description": "Created" } }, "security": [ @@ -3079,34 +2959,43 @@ } ], "tags": [ - "Beta" + "GA" ] }, "servers": [ { - "url": "https://studio.twilio.com" + "url": "https://ip-messaging.twilio.com" } ], "x-default-output-properties": [ "sid", - "status", + "friendly_name", "date_created" ], - "x-path-type": "instance" + "x-path-type": "list" }, - "/v2/Flows/{Sid}": { + "/v1/Services/{ServiceSid}/Users/{Sid}": { "delete": { - "description": "Delete a specific Flow.", + "description": "", "parameters": [ { - "description": "The SID of the Flow resource to delete.", + "description": "", "in": "path", - "name": "Sid", + "name": "ServiceSid", "required": true, "schema": { "maxLength": 34, "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "", + "in": "path", + "name": "Sid", + "required": true, + "schema": { "type": "string" } } @@ -3122,22 +3011,31 @@ } ], "tags": [ - "Beta" + "GA" ] }, - "description": "Studio flows", + "description": "TODO: Resource-level docs", "get": { - "description": "Retrieve a specific Flow.", + "description": "", "parameters": [ { - "description": "The SID of the Flow resource to fetch.", + "description": "", "in": "path", - "name": "Sid", + "name": "ServiceSid", "required": true, "schema": { "maxLength": 34, "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "", + "in": "path", + "name": "Sid", + "required": true, + "schema": { "type": "string" } } @@ -3147,7 +3045,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/studio.v2.flow" + "$ref": "#/components/schemas/ip_messaging.v1.service.user" } } }, @@ -3160,21 +3058,30 @@ } ], "tags": [ - "Beta" + "GA" ] }, "post": { - "description": "Update a Flow.", + "description": "", "parameters": [ { - "description": "The SID of the Flow resource to fetch.", + "description": "", "in": "path", - "name": "Sid", + "name": "ServiceSid", "required": true, "schema": { "maxLength": 34, "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "", + "in": "path", + "name": "Sid", + "required": true, + "schema": { "type": "string" } } @@ -3184,30 +3091,22 @@ "application/x-www-form-urlencoded": { "schema": { "properties": { - "CommitMessage": { - "description": "Description on change made in the revision.", + "Attributes": { + "description": "", "type": "string" }, - "Definition": { - "description": "JSON representation of flow definition.", - "type": "object" - }, "FriendlyName": { - "description": "The string that you assigned to describe the Flow.", + "description": "", "type": "string" }, - "Status": { - "description": "The status of the Flow. Can be: `draft` or `published`.", - "enum": [ - "draft", - "published" - ], + "RoleSid": { + "description": "", + "maxLength": 34, + "minLength": 34, + "pattern": "^RL[0-9a-fA-F]{32}$", "type": "string" } }, - "required": [ - "Status" - ], "type": "object" } } @@ -3218,7 +3117,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/studio.v2.flow" + "$ref": "#/components/schemas/ip_messaging.v1.service.user" } } }, @@ -3231,36 +3130,44 @@ } ], "tags": [ - "Beta" + "GA" ] }, "servers": [ { - "url": "https://studio.twilio.com" + "url": "https://ip-messaging.twilio.com" } ], "x-default-output-properties": [ "sid", "friendly_name", - "status", - "revision" + "date_created" ], "x-path-type": "instance" }, - "/v2/Flows/{Sid}/Revisions": { - "description": "Studio flows revisions", + "/v1/Services/{ServiceSid}/Users/{UserSid}/Channels": { + "description": "TODO: Resource-level docs", "get": { - "description": "Retrieve a list of all Flows revisions.", + "description": "", "parameters": [ { - "description": "The SID of the Flow resource to fetch.", + "description": "", "in": "path", - "name": "Sid", + "name": "ServiceSid", "required": true, "schema": { "maxLength": 34, "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "", + "in": "path", + "name": "UserSid", + "required": true, + "schema": { "type": "string" } }, @@ -3281,6 +3188,12 @@ "application/json": { "schema": { "properties": { + "channels": { + "items": { + "$ref": "#/components/schemas/ip_messaging.v1.service.user.user_channel" + }, + "type": "array" + }, "meta": { "properties": { "first_page_url": { @@ -3310,12 +3223,6 @@ } }, "type": "object" - }, - "revisions": { - "items": { - "$ref": "#/components/schemas/studio.v2.flow.flow_revision" - }, - "type": "array" } }, "type": "object" @@ -3331,59 +3238,40 @@ } ], "tags": [ - "Beta" + "GA" ] }, "servers": [ { - "url": "https://studio.twilio.com" + "url": "https://ip-messaging.twilio.com" } ], "x-default-output-properties": [ - "sid", - "friendly_name", - "status", - "revision" + "channel_sid", + "status" ], "x-path-type": "list" }, - "/v2/Flows/{Sid}/Revisions/{Revision}": { - "description": "Studio flows revisions", - "get": { - "description": "Retrieve a specific Flow revision.", + "/v1/Services/{Sid}": { + "delete": { + "description": "", "parameters": [ { - "description": "The SID of the Flow resource to fetch.", + "description": "", "in": "path", "name": "Sid", "required": true, "schema": { "maxLength": 34, "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "Specific Revision number or can be `LatestPublished` and `LatestRevision`.", - "in": "path", - "name": "Revision", - "required": true, - "schema": { + "pattern": "^IS[0-9a-fA-F]{32}$", "type": "string" } } ], "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/studio.v2.flow.flow_revision" - } - } - }, - "description": "OK" + "204": { + "description": "The resource was deleted successfully." } }, "security": [ @@ -3392,23 +3280,9 @@ } ], "tags": [ - "Beta" + "GA" ] }, - "servers": [ - { - "url": "https://studio.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "friendly_name", - "status", - "revision" - ], - "x-path-type": "instance" - }, - "/v2/Flows/{Sid}/TestUsers": { "description": "TODO: Resource-level docs", "get": { "description": "", @@ -3421,7 +3295,7 @@ "schema": { "maxLength": 34, "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", + "pattern": "^IS[0-9a-fA-F]{32}$", "type": "string" } } @@ -3431,7 +3305,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/studio.v2.flow.test_user" + "$ref": "#/components/schemas/ip_messaging.v1.service" } } }, @@ -3444,7 +3318,7 @@ } ], "tags": [ - "Beta" + "GA" ] }, "post": { @@ -3458,7 +3332,7 @@ "schema": { "maxLength": 34, "minLength": 34, - "pattern": "^FW[0-9a-fA-F]{32}$", + "pattern": "^IS[0-9a-fA-F]{32}$", "type": "string" } } @@ -3468,17 +3342,491 @@ "application/x-www-form-urlencoded": { "schema": { "properties": { - "TestUsers": { + "ConsumptionReportInterval": { + "description": "", + "type": "integer" + }, + "DefaultChannelCreatorRoleSid": { + "description": "", + "maxLength": 34, + "minLength": 34, + "pattern": "^RL[0-9a-fA-F]{32}$", + "type": "string" + }, + "DefaultChannelRoleSid": { + "description": "", + "maxLength": 34, + "minLength": 34, + "pattern": "^RL[0-9a-fA-F]{32}$", + "type": "string" + }, + "DefaultServiceRoleSid": { + "description": "", + "maxLength": 34, + "minLength": 34, + "pattern": "^RL[0-9a-fA-F]{32}$", + "type": "string" + }, + "FriendlyName": { + "description": "", + "type": "string" + }, + "Limits.ChannelMembers": { + "description": "", + "type": "integer" + }, + "Limits.UserChannels": { + "description": "", + "type": "integer" + }, + "Notifications.AddedToChannel.Enabled": { + "description": "", + "type": "boolean" + }, + "Notifications.AddedToChannel.Template": { + "description": "", + "type": "string" + }, + "Notifications.InvitedToChannel.Enabled": { + "description": "", + "type": "boolean" + }, + "Notifications.InvitedToChannel.Template": { + "description": "", + "type": "string" + }, + "Notifications.NewMessage.Enabled": { + "description": "", + "type": "boolean" + }, + "Notifications.NewMessage.Template": { + "description": "", + "type": "string" + }, + "Notifications.RemovedFromChannel.Enabled": { + "description": "", + "type": "boolean" + }, + "Notifications.RemovedFromChannel.Template": { + "description": "", + "type": "string" + }, + "PostWebhookUrl": { + "description": "", + "format": "uri", + "type": "string" + }, + "PreWebhookUrl": { + "description": "", + "format": "uri", + "type": "string" + }, + "ReachabilityEnabled": { + "description": "", + "type": "boolean" + }, + "ReadStatusEnabled": { + "description": "", + "type": "boolean" + }, + "TypingIndicatorTimeout": { + "description": "", + "type": "integer" + }, + "WebhookFilters": { "description": "", "items": { "type": "string" }, "type": "array" + }, + "WebhookMethod": { + "description": "", + "enum": [ + "head", + "get", + "post", + "patch", + "put", + "delete", + "HEAD", + "GET", + "POST", + "PATCH", + "PUT", + "DELETE" + ], + "type": "string" + }, + "Webhooks.OnChannelAdd.Method": { + "description": "", + "enum": [ + "head", + "get", + "post", + "patch", + "put", + "delete", + "HEAD", + "GET", + "POST", + "PATCH", + "PUT", + "DELETE" + ], + "type": "string" + }, + "Webhooks.OnChannelAdd.Url": { + "description": "", + "format": "uri", + "type": "string" + }, + "Webhooks.OnChannelAdded.Method": { + "description": "", + "enum": [ + "head", + "get", + "post", + "patch", + "put", + "delete", + "HEAD", + "GET", + "POST", + "PATCH", + "PUT", + "DELETE" + ], + "type": "string" + }, + "Webhooks.OnChannelAdded.Url": { + "description": "", + "format": "uri", + "type": "string" + }, + "Webhooks.OnChannelDestroy.Method": { + "description": "", + "enum": [ + "head", + "get", + "post", + "patch", + "put", + "delete", + "HEAD", + "GET", + "POST", + "PATCH", + "PUT", + "DELETE" + ], + "type": "string" + }, + "Webhooks.OnChannelDestroy.Url": { + "description": "", + "format": "uri", + "type": "string" + }, + "Webhooks.OnChannelDestroyed.Method": { + "description": "", + "enum": [ + "head", + "get", + "post", + "patch", + "put", + "delete", + "HEAD", + "GET", + "POST", + "PATCH", + "PUT", + "DELETE" + ], + "type": "string" + }, + "Webhooks.OnChannelDestroyed.Url": { + "description": "", + "format": "uri", + "type": "string" + }, + "Webhooks.OnChannelUpdate.Method": { + "description": "", + "enum": [ + "head", + "get", + "post", + "patch", + "put", + "delete", + "HEAD", + "GET", + "POST", + "PATCH", + "PUT", + "DELETE" + ], + "type": "string" + }, + "Webhooks.OnChannelUpdate.Url": { + "description": "", + "format": "uri", + "type": "string" + }, + "Webhooks.OnChannelUpdated.Method": { + "description": "", + "enum": [ + "head", + "get", + "post", + "patch", + "put", + "delete", + "HEAD", + "GET", + "POST", + "PATCH", + "PUT", + "DELETE" + ], + "type": "string" + }, + "Webhooks.OnChannelUpdated.Url": { + "description": "", + "format": "uri", + "type": "string" + }, + "Webhooks.OnMemberAdd.Method": { + "description": "", + "enum": [ + "head", + "get", + "post", + "patch", + "put", + "delete", + "HEAD", + "GET", + "POST", + "PATCH", + "PUT", + "DELETE" + ], + "type": "string" + }, + "Webhooks.OnMemberAdd.Url": { + "description": "", + "format": "uri", + "type": "string" + }, + "Webhooks.OnMemberAdded.Method": { + "description": "", + "enum": [ + "head", + "get", + "post", + "patch", + "put", + "delete", + "HEAD", + "GET", + "POST", + "PATCH", + "PUT", + "DELETE" + ], + "type": "string" + }, + "Webhooks.OnMemberAdded.Url": { + "description": "", + "format": "uri", + "type": "string" + }, + "Webhooks.OnMemberRemove.Method": { + "description": "", + "enum": [ + "head", + "get", + "post", + "patch", + "put", + "delete", + "HEAD", + "GET", + "POST", + "PATCH", + "PUT", + "DELETE" + ], + "type": "string" + }, + "Webhooks.OnMemberRemove.Url": { + "description": "", + "format": "uri", + "type": "string" + }, + "Webhooks.OnMemberRemoved.Method": { + "description": "", + "enum": [ + "head", + "get", + "post", + "patch", + "put", + "delete", + "HEAD", + "GET", + "POST", + "PATCH", + "PUT", + "DELETE" + ], + "type": "string" + }, + "Webhooks.OnMemberRemoved.Url": { + "description": "", + "format": "uri", + "type": "string" + }, + "Webhooks.OnMessageRemove.Method": { + "description": "", + "enum": [ + "head", + "get", + "post", + "patch", + "put", + "delete", + "HEAD", + "GET", + "POST", + "PATCH", + "PUT", + "DELETE" + ], + "type": "string" + }, + "Webhooks.OnMessageRemove.Url": { + "description": "", + "format": "uri", + "type": "string" + }, + "Webhooks.OnMessageRemoved.Method": { + "description": "", + "enum": [ + "head", + "get", + "post", + "patch", + "put", + "delete", + "HEAD", + "GET", + "POST", + "PATCH", + "PUT", + "DELETE" + ], + "type": "string" + }, + "Webhooks.OnMessageRemoved.Url": { + "description": "", + "format": "uri", + "type": "string" + }, + "Webhooks.OnMessageSend.Method": { + "description": "", + "enum": [ + "head", + "get", + "post", + "patch", + "put", + "delete", + "HEAD", + "GET", + "POST", + "PATCH", + "PUT", + "DELETE" + ], + "type": "string" + }, + "Webhooks.OnMessageSend.Url": { + "description": "", + "format": "uri", + "type": "string" + }, + "Webhooks.OnMessageSent.Method": { + "description": "", + "enum": [ + "head", + "get", + "post", + "patch", + "put", + "delete", + "HEAD", + "GET", + "POST", + "PATCH", + "PUT", + "DELETE" + ], + "type": "string" + }, + "Webhooks.OnMessageSent.Url": { + "description": "", + "format": "uri", + "type": "string" + }, + "Webhooks.OnMessageUpdate.Method": { + "description": "", + "enum": [ + "head", + "get", + "post", + "patch", + "put", + "delete", + "HEAD", + "GET", + "POST", + "PATCH", + "PUT", + "DELETE" + ], + "type": "string" + }, + "Webhooks.OnMessageUpdate.Url": { + "description": "", + "format": "uri", + "type": "string" + }, + "Webhooks.OnMessageUpdated.Method": { + "description": "", + "enum": [ + "head", + "get", + "post", + "patch", + "put", + "delete", + "HEAD", + "GET", + "POST", + "PATCH", + "PUT", + "DELETE" + ], + "type": "string" + }, + "Webhooks.OnMessageUpdated.Url": { + "description": "", + "format": "uri", + "type": "string" } }, - "required": [ - "TestUsers" - ], "type": "object" } } @@ -3489,7 +3837,7 @@ "content": { "application/json": { "schema": { - "$ref": "#/components/schemas/studio.v2.flow.test_user" + "$ref": "#/components/schemas/ip_messaging.v1.service" } } }, @@ -3502,16 +3850,18 @@ } ], "tags": [ - "Beta" + "GA" ] }, "servers": [ { - "url": "https://studio.twilio.com" + "url": "https://ip-messaging.twilio.com" } ], "x-default-output-properties": [ - "test_users" + "sid", + "friendly_name", + "date_created" ], "x-path-type": "instance" } @@ -3520,10 +3870,6 @@ { "description": "This product is Generally Available.", "name": "GA" - }, - { - "description": "PLEASE NOTE that this is a Beta product that is subject to change. Use it with caution.", - "name": "Beta" } ] } \ No newline at end of file diff --git a/spec/json/twilio_ip_messaging.json b/spec/json/twilio_ip_messaging_v2.json similarity index 56% rename from spec/json/twilio_ip_messaging.json rename to spec/json/twilio_ip_messaging_v2.json index 78264098..dda02371 100644 --- a/spec/json/twilio_ip_messaging.json +++ b/spec/json/twilio_ip_messaging_v2.json @@ -1,7 +1,7 @@ { "components": { "schemas": { - "ip_messaging.v1.credential": { + "ip_messaging.v2.credential": { "properties": { "account_sid": { "maxLength": 34, @@ -44,7 +44,7 @@ }, "type": "object" }, - "ip_messaging.v1.service": { + "ip_messaging.v2.service": { "properties": { "account_sid": { "maxLength": 34, @@ -90,12 +90,21 @@ "links": { "type": "object" }, + "media": { + "type": "object" + }, "notifications": { "type": "object" }, + "post_webhook_retry_count": { + "type": "integer" + }, "post_webhook_url": { "type": "string" }, + "pre_webhook_retry_count": { + "type": "integer" + }, "pre_webhook_url": { "type": "string" }, @@ -126,14 +135,75 @@ }, "webhook_method": { "type": "string" + } + }, + "type": "object" + }, + "ip_messaging.v2.service.binding": { + "properties": { + "account_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^AC[0-9a-fA-F]{32}$", + "type": "string" + }, + "binding_type": { + "enum": [ + "gcm", + "apn", + "fcm" + ], + "type": "string" + }, + "credential_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^CR[0-9a-fA-F]{32}$", + "type": "string" + }, + "date_created": { + "format": "date-time", + "type": "string" + }, + "date_updated": { + "format": "date-time", + "type": "string" + }, + "endpoint": { + "type": "string" + }, + "identity": { + "type": "string" }, - "webhooks": { + "links": { "type": "object" + }, + "message_types": { + "items": { + "type": "string" + }, + "type": "array" + }, + "service_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + }, + "sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^BS[0-9a-fA-F]{32}$", + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" } }, "type": "object" }, - "ip_messaging.v1.service.channel": { + "ip_messaging.v2.service.channel": { "properties": { "account_sid": { "maxLength": 34, @@ -196,7 +266,54 @@ }, "type": "object" }, - "ip_messaging.v1.service.channel.invite": { + "ip_messaging.v2.service.channel.channel_webhook": { + "properties": { + "account_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^AC[0-9a-fA-F]{32}$", + "type": "string" + }, + "channel_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^CH[0-9a-fA-F]{32}$", + "type": "string" + }, + "configuration": { + "type": "object" + }, + "date_created": { + "format": "date-time", + "type": "string" + }, + "date_updated": { + "format": "date-time", + "type": "string" + }, + "service_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^IS[0-9a-fA-F]{32}$", + "type": "string" + }, + "sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^WH[0-9a-fA-F]{32}$", + "type": "string" + }, + "type": { + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + }, + "ip_messaging.v2.service.channel.invite": { "properties": { "account_sid": { "maxLength": 34, @@ -249,7 +366,7 @@ }, "type": "object" }, - "ip_messaging.v1.service.channel.member": { + "ip_messaging.v2.service.channel.member": { "properties": { "account_sid": { "maxLength": 34, @@ -257,6 +374,9 @@ "pattern": "^AC[0-9a-fA-F]{32}$", "type": "string" }, + "attributes": { + "type": "string" + }, "channel_sid": { "maxLength": 34, "minLength": 34, @@ -307,7 +427,7 @@ }, "type": "object" }, - "ip_messaging.v1.service.channel.message": { + "ip_messaging.v2.service.channel.message": { "properties": { "account_sid": { "maxLength": 34, @@ -341,6 +461,12 @@ "index": { "type": "integer" }, + "last_updated_by": { + "type": "string" + }, + "media": { + "type": "object" + }, "service_sid": { "maxLength": 34, "minLength": 34, @@ -359,6 +485,9 @@ "pattern": "^CH[0-9a-fA-F]{32}$", "type": "string" }, + "type": { + "type": "string" + }, "url": { "format": "uri", "type": "string" @@ -369,7 +498,7 @@ }, "type": "object" }, - "ip_messaging.v1.service.role": { + "ip_messaging.v2.service.role": { "properties": { "account_sid": { "maxLength": 34, @@ -420,7 +549,7 @@ }, "type": "object" }, - "ip_messaging.v1.service.user": { + "ip_messaging.v2.service.user": { "properties": { "account_sid": { "maxLength": 34, @@ -482,7 +611,7 @@ }, "type": "object" }, - "ip_messaging.v1.service.user.user_channel": { + "ip_messaging.v2.service.user.user_binding": { "properties": { "account_sid": { "maxLength": 34, @@ -490,52 +619,18 @@ "pattern": "^AC[0-9a-fA-F]{32}$", "type": "string" }, - "channel_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^CH[0-9a-fA-F]{32}$", - "type": "string" - }, - "last_consumed_message_index": { - "nullable": true, - "type": "integer" - }, - "links": { - "type": "object" - }, - "member_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^MB[0-9a-fA-F]{32}$", - "type": "string" - }, - "service_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - }, - "status": { + "binding_type": { "enum": [ - "joined", - "invited", - "not_participating" + "gcm", + "apn", + "fcm" ], "type": "string" }, - "unread_messages_count": { - "nullable": true, - "type": "integer" - } - }, - "type": "object" - }, - "ip_messaging.v2.credential": { - "properties": { - "account_sid": { + "credential_sid": { "maxLength": 34, "minLength": 34, - "pattern": "^AC[0-9a-fA-F]{32}$", + "pattern": "^CR[0-9a-fA-F]{32}$", "type": "string" }, "date_created": { @@ -546,34 +641,44 @@ "format": "date-time", "type": "string" }, - "friendly_name": { + "endpoint": { "type": "string" }, - "sandbox": { + "identity": { "type": "string" }, - "sid": { + "message_types": { + "items": { + "type": "string" + }, + "type": "array" + }, + "service_sid": { "maxLength": 34, "minLength": 34, - "pattern": "^CR[0-9a-fA-F]{32}$", + "pattern": "^IS[0-9a-fA-F]{32}$", "type": "string" }, - "type": { - "enum": [ - "gcm", - "apn", - "fcm" - ], + "sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^BS[0-9a-fA-F]{32}$", "type": "string" }, "url": { "format": "uri", "type": "string" + }, + "user_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^US[0-9a-fA-F]{32}$", + "type": "string" } }, "type": "object" }, - "ip_messaging.v2.service": { + "ip_messaging.v2.service.user.user_channel": { "properties": { "account_sid": { "maxLength": 34, @@ -581,4032 +686,88 @@ "pattern": "^AC[0-9a-fA-F]{32}$", "type": "string" }, - "consumption_report_interval": { - "type": "integer" - }, - "date_created": { - "format": "date-time", + "channel_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^CH[0-9a-fA-F]{32}$", "type": "string" }, - "date_updated": { - "format": "date-time", - "type": "string" + "last_consumed_message_index": { + "nullable": true, + "type": "integer" }, - "default_channel_creator_role_sid": { + "links": { + "type": "object" + }, + "member_sid": { "maxLength": 34, "minLength": 34, - "pattern": "^RL[0-9a-fA-F]{32}$", + "pattern": "^MB[0-9a-fA-F]{32}$", "type": "string" }, - "default_channel_role_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^RL[0-9a-fA-F]{32}$", + "notification_level": { + "enum": [ + "default", + "muted" + ], "type": "string" }, - "default_service_role_sid": { + "service_sid": { "maxLength": 34, "minLength": 34, - "pattern": "^RL[0-9a-fA-F]{32}$", - "type": "string" - }, - "friendly_name": { + "pattern": "^IS[0-9a-fA-F]{32}$", "type": "string" }, - "limits": { - "type": "object" - }, - "links": { - "type": "object" - }, - "media": { - "type": "object" - }, - "notifications": { - "type": "object" - }, - "post_webhook_retry_count": { - "type": "integer" - }, - "post_webhook_url": { - "type": "string" - }, - "pre_webhook_retry_count": { - "type": "integer" - }, - "pre_webhook_url": { - "type": "string" - }, - "reachability_enabled": { - "type": "boolean" - }, - "read_status_enabled": { - "type": "boolean" - }, - "sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - }, - "typing_indicator_timeout": { - "type": "integer" - }, - "url": { - "format": "uri", - "type": "string" - }, - "webhook_filters": { - "items": { - "type": "string" - }, - "type": "array" - }, - "webhook_method": { - "type": "string" - } - }, - "type": "object" - }, - "ip_messaging.v2.service.binding": { - "properties": { - "account_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^AC[0-9a-fA-F]{32}$", - "type": "string" - }, - "binding_type": { + "status": { "enum": [ - "gcm", - "apn", - "fcm" + "joined", + "invited", + "not_participating" ], "type": "string" }, - "credential_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^CR[0-9a-fA-F]{32}$", - "type": "string" - }, - "date_created": { - "format": "date-time", - "type": "string" - }, - "date_updated": { - "format": "date-time", - "type": "string" - }, - "endpoint": { - "type": "string" - }, - "identity": { - "type": "string" - }, - "links": { - "type": "object" - }, - "message_types": { - "items": { - "type": "string" - }, - "type": "array" - }, - "service_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - }, - "sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^BS[0-9a-fA-F]{32}$", - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - }, - "ip_messaging.v2.service.channel": { - "properties": { - "account_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^AC[0-9a-fA-F]{32}$", - "type": "string" - }, - "attributes": { - "type": "string" - }, - "created_by": { - "type": "string" - }, - "date_created": { - "format": "date-time", - "type": "string" - }, - "date_updated": { - "format": "date-time", - "type": "string" - }, - "friendly_name": { - "type": "string" - }, - "links": { - "type": "object" - }, - "members_count": { - "type": "integer" - }, - "messages_count": { + "unread_messages_count": { + "nullable": true, "type": "integer" }, - "service_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - }, - "sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^CH[0-9a-fA-F]{32}$", - "type": "string" - }, - "type": { - "enum": [ - "public", - "private" - ], - "type": "string" - }, - "unique_name": { - "type": "string" - }, "url": { "format": "uri", "type": "string" - } - }, - "type": "object" - }, - "ip_messaging.v2.service.channel.channel_webhook": { - "properties": { - "account_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^AC[0-9a-fA-F]{32}$", - "type": "string" - }, - "channel_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^CH[0-9a-fA-F]{32}$", - "type": "string" - }, - "configuration": { - "type": "object" - }, - "date_created": { - "format": "date-time", - "type": "string" - }, - "date_updated": { - "format": "date-time", - "type": "string" - }, - "service_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" }, - "sid": { + "user_sid": { "maxLength": 34, "minLength": 34, - "pattern": "^WH[0-9a-fA-F]{32}$", - "type": "string" - }, - "type": { - "type": "string" - }, - "url": { - "format": "uri", + "pattern": "^US[0-9a-fA-F]{32}$", "type": "string" } }, "type": "object" - }, - "ip_messaging.v2.service.channel.invite": { - "properties": { - "account_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^AC[0-9a-fA-F]{32}$", - "type": "string" - }, - "channel_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^CH[0-9a-fA-F]{32}$", - "type": "string" - }, - "created_by": { - "type": "string" - }, - "date_created": { - "format": "date-time", - "type": "string" - }, - "date_updated": { - "format": "date-time", - "type": "string" - }, - "identity": { - "type": "string" - }, - "role_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^RL[0-9a-fA-F]{32}$", - "type": "string" - }, - "service_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - }, - "sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IN[0-9a-fA-F]{32}$", - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - }, - "ip_messaging.v2.service.channel.member": { - "properties": { - "account_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^AC[0-9a-fA-F]{32}$", - "type": "string" - }, - "attributes": { - "type": "string" - }, - "channel_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^CH[0-9a-fA-F]{32}$", - "type": "string" - }, - "date_created": { - "format": "date-time", - "type": "string" - }, - "date_updated": { - "format": "date-time", - "type": "string" - }, - "identity": { - "type": "string" - }, - "last_consumed_message_index": { - "nullable": true, - "type": "integer" - }, - "last_consumption_timestamp": { - "format": "date-time", - "type": "string" - }, - "role_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^RL[0-9a-fA-F]{32}$", - "type": "string" - }, - "service_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - }, - "sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^MB[0-9a-fA-F]{32}$", - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - }, - "ip_messaging.v2.service.channel.message": { - "properties": { - "account_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^AC[0-9a-fA-F]{32}$", - "type": "string" - }, - "attributes": { - "type": "string" - }, - "body": { - "type": "string" - }, - "channel_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^CH[0-9a-fA-F]{32}$", - "type": "string" - }, - "date_created": { - "format": "date-time", - "type": "string" - }, - "date_updated": { - "format": "date-time", - "type": "string" - }, - "from": { - "type": "string" - }, - "index": { - "type": "integer" - }, - "last_updated_by": { - "type": "string" - }, - "media": { - "type": "object" - }, - "service_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - }, - "sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IM[0-9a-fA-F]{32}$", - "type": "string" - }, - "to": { - "maxLength": 34, - "minLength": 34, - "pattern": "^CH[0-9a-fA-F]{32}$", - "type": "string" - }, - "type": { - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - }, - "was_edited": { - "type": "boolean" - } - }, - "type": "object" - }, - "ip_messaging.v2.service.role": { - "properties": { - "account_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^AC[0-9a-fA-F]{32}$", - "type": "string" - }, - "date_created": { - "format": "date-time", - "type": "string" - }, - "date_updated": { - "format": "date-time", - "type": "string" - }, - "friendly_name": { - "type": "string" - }, - "permissions": { - "items": { - "type": "string" - }, - "type": "array" - }, - "service_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - }, - "sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^RL[0-9a-fA-F]{32}$", - "type": "string" - }, - "type": { - "enum": [ - "channel", - "deployment" - ], - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - }, - "ip_messaging.v2.service.user": { - "properties": { - "account_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^AC[0-9a-fA-F]{32}$", - "type": "string" - }, - "attributes": { - "type": "string" - }, - "date_created": { - "format": "date-time", - "type": "string" - }, - "date_updated": { - "format": "date-time", - "type": "string" - }, - "friendly_name": { - "type": "string" - }, - "identity": { - "type": "string" - }, - "is_notifiable": { - "type": "boolean" - }, - "is_online": { - "type": "boolean" - }, - "joined_channels_count": { - "type": "integer" - }, - "links": { - "type": "object" - }, - "role_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^RL[0-9a-fA-F]{32}$", - "type": "string" - }, - "service_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - }, - "sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^US[0-9a-fA-F]{32}$", - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - }, - "ip_messaging.v2.service.user.user_binding": { - "properties": { - "account_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^AC[0-9a-fA-F]{32}$", - "type": "string" - }, - "binding_type": { - "enum": [ - "gcm", - "apn", - "fcm" - ], - "type": "string" - }, - "credential_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^CR[0-9a-fA-F]{32}$", - "type": "string" - }, - "date_created": { - "format": "date-time", - "type": "string" - }, - "date_updated": { - "format": "date-time", - "type": "string" - }, - "endpoint": { - "type": "string" - }, - "identity": { - "type": "string" - }, - "message_types": { - "items": { - "type": "string" - }, - "type": "array" - }, - "service_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - }, - "sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^BS[0-9a-fA-F]{32}$", - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - }, - "user_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^US[0-9a-fA-F]{32}$", - "type": "string" - } - }, - "type": "object" - }, - "ip_messaging.v2.service.user.user_channel": { - "properties": { - "account_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^AC[0-9a-fA-F]{32}$", - "type": "string" - }, - "channel_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^CH[0-9a-fA-F]{32}$", - "type": "string" - }, - "last_consumed_message_index": { - "nullable": true, - "type": "integer" - }, - "links": { - "type": "object" - }, - "member_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^MB[0-9a-fA-F]{32}$", - "type": "string" - }, - "notification_level": { - "enum": [ - "default", - "muted" - ], - "type": "string" - }, - "service_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - }, - "status": { - "enum": [ - "joined", - "invited", - "not_participating" - ], - "type": "string" - }, - "unread_messages_count": { - "nullable": true, - "type": "integer" - }, - "url": { - "format": "uri", - "type": "string" - }, - "user_sid": { - "maxLength": 34, - "minLength": 34, - "pattern": "^US[0-9a-fA-F]{32}$", - "type": "string" - } - }, - "type": "object" - } - }, - "securitySchemes": { - "accountSid_authToken": { - "scheme": "basic", - "type": "http" - } - } - }, - "info": { - "contact": { - "email": "support@twilio.com", - "name": "Twilio Support", - "url": "https://support.twilio.com" - }, - "description": "This is the public Twilio REST API.", - "license": { - "name": "Apache 2.0", - "url": "https://www.apache.org/licenses/LICENSE-2.0.html" - }, - "termsOfService": "https://www.twilio.com/legal/tos", - "title": "Twilio - Ip_messaging", - "version": "1.3.0" - }, - "openapi": "3.0.1", - "paths": { - "/v1/Credentials": { - "description": "TODO: Resource-level docs", - "get": { - "description": "", - "parameters": [ - { - "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", - "in": "query", - "name": "PageSize", - "schema": { - "maximum": 1000, - "minimum": 1, - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "properties": { - "credentials": { - "items": { - "$ref": "#/components/schemas/ip_messaging.v1.credential" - }, - "type": "array" - }, - "meta": { - "properties": { - "first_page_url": { - "format": "uri", - "type": "string" - }, - "key": { - "type": "string" - }, - "next_page_url": { - "format": "uri", - "type": "string" - }, - "page": { - "type": "integer" - }, - "page_size": { - "type": "integer" - }, - "previous_page_url": { - "format": "uri", - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "post": { - "description": "", - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "schema": { - "properties": { - "ApiKey": { - "description": "", - "type": "string" - }, - "Certificate": { - "description": "", - "type": "string" - }, - "FriendlyName": { - "description": "", - "type": "string" - }, - "PrivateKey": { - "description": "", - "type": "string" - }, - "Sandbox": { - "description": "", - "type": "boolean" - }, - "Secret": { - "description": "", - "type": "string" - }, - "Type": { - "description": "", - "enum": [ - "gcm", - "apn", - "fcm" - ], - "type": "string" - } - }, - "required": [ - "Type" - ], - "type": "object" - } - } - } - }, - "responses": { - "201": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ip_messaging.v1.credential" - } - } - }, - "description": "Created" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://ip-messaging.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "friendly_name", - "type" - ], - "x-path-type": "list" - }, - "/v1/Credentials/{Sid}": { - "delete": { - "description": "", - "parameters": [ - { - "description": "", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^CR[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "responses": { - "204": { - "description": "The resource was deleted successfully." - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "description": "TODO: Resource-level docs", - "get": { - "description": "", - "parameters": [ - { - "description": "", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^CR[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ip_messaging.v1.credential" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "post": { - "description": "", - "parameters": [ - { - "description": "", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^CR[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "schema": { - "properties": { - "ApiKey": { - "description": "", - "type": "string" - }, - "Certificate": { - "description": "", - "type": "string" - }, - "FriendlyName": { - "description": "", - "type": "string" - }, - "PrivateKey": { - "description": "", - "type": "string" - }, - "Sandbox": { - "description": "", - "type": "boolean" - }, - "Secret": { - "description": "", - "type": "string" - } - }, - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ip_messaging.v1.credential" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://ip-messaging.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "friendly_name", - "type" - ], - "x-path-type": "instance" - }, - "/v1/Services": { - "description": "TODO: Resource-level docs", - "get": { - "description": "", - "parameters": [ - { - "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", - "in": "query", - "name": "PageSize", - "schema": { - "maximum": 1000, - "minimum": 1, - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "properties": { - "meta": { - "properties": { - "first_page_url": { - "format": "uri", - "type": "string" - }, - "key": { - "type": "string" - }, - "next_page_url": { - "format": "uri", - "type": "string" - }, - "page": { - "type": "integer" - }, - "page_size": { - "type": "integer" - }, - "previous_page_url": { - "format": "uri", - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - }, - "services": { - "items": { - "$ref": "#/components/schemas/ip_messaging.v1.service" - }, - "type": "array" - } - }, - "type": "object" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "post": { - "description": "", - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "schema": { - "properties": { - "FriendlyName": { - "description": "", - "type": "string" - } - }, - "required": [ - "FriendlyName" - ], - "type": "object" - } - } - } - }, - "responses": { - "201": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ip_messaging.v1.service" - } - } - }, - "description": "Created" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://ip-messaging.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "friendly_name", - "date_created" - ], - "x-path-type": "list" - }, - "/v1/Services/{ServiceSid}/Channels": { - "description": "TODO: Resource-level docs", - "get": { - "description": "", - "parameters": [ - { - "description": "", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "", - "in": "query", - "name": "Type", - "schema": { - "items": { - "enum": [ - "public", - "private" - ], - "type": "string" - }, - "type": "array" - } - }, - { - "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", - "in": "query", - "name": "PageSize", - "schema": { - "maximum": 1000, - "minimum": 1, - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "properties": { - "channels": { - "items": { - "$ref": "#/components/schemas/ip_messaging.v1.service.channel" - }, - "type": "array" - }, - "meta": { - "properties": { - "first_page_url": { - "format": "uri", - "type": "string" - }, - "key": { - "type": "string" - }, - "next_page_url": { - "format": "uri", - "type": "string" - }, - "page": { - "type": "integer" - }, - "page_size": { - "type": "integer" - }, - "previous_page_url": { - "format": "uri", - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "post": { - "description": "", - "parameters": [ - { - "description": "", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "schema": { - "properties": { - "Attributes": { - "description": "", - "type": "string" - }, - "FriendlyName": { - "description": "", - "type": "string" - }, - "Type": { - "description": "", - "enum": [ - "public", - "private" - ], - "type": "string" - }, - "UniqueName": { - "description": "", - "type": "string" - } - }, - "type": "object" - } - } - } - }, - "responses": { - "201": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ip_messaging.v1.service.channel" - } - } - }, - "description": "Created" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://ip-messaging.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "unique_name", - "friendly_name" - ], - "x-path-type": "list" - }, - "/v1/Services/{ServiceSid}/Channels/{ChannelSid}/Invites": { - "description": "TODO: Resource-level docs", - "get": { - "description": "", - "parameters": [ - { - "description": "", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "", - "in": "path", - "name": "ChannelSid", - "required": true, - "schema": { - "type": "string" - } - }, - { - "description": "", - "in": "query", - "name": "Identity", - "schema": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - { - "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", - "in": "query", - "name": "PageSize", - "schema": { - "maximum": 1000, - "minimum": 1, - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "properties": { - "invites": { - "items": { - "$ref": "#/components/schemas/ip_messaging.v1.service.channel.invite" - }, - "type": "array" - }, - "meta": { - "properties": { - "first_page_url": { - "format": "uri", - "type": "string" - }, - "key": { - "type": "string" - }, - "next_page_url": { - "format": "uri", - "type": "string" - }, - "page": { - "type": "integer" - }, - "page_size": { - "type": "integer" - }, - "previous_page_url": { - "format": "uri", - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "post": { - "description": "", - "parameters": [ - { - "description": "", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "", - "in": "path", - "name": "ChannelSid", - "required": true, - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "schema": { - "properties": { - "Identity": { - "description": "", - "type": "string" - }, - "RoleSid": { - "description": "", - "maxLength": 34, - "minLength": 34, - "pattern": "^RL[0-9a-fA-F]{32}$", - "type": "string" - } - }, - "required": [ - "Identity" - ], - "type": "object" - } - } - } - }, - "responses": { - "201": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ip_messaging.v1.service.channel.invite" - } - } - }, - "description": "Created" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://ip-messaging.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "identity", - "date_created" - ], - "x-path-type": "list" - }, - "/v1/Services/{ServiceSid}/Channels/{ChannelSid}/Invites/{Sid}": { - "delete": { - "description": "", - "parameters": [ - { - "description": "", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "", - "in": "path", - "name": "ChannelSid", - "required": true, - "schema": { - "type": "string" - } - }, - { - "description": "", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IN[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "responses": { - "204": { - "description": "The resource was deleted successfully." - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "description": "TODO: Resource-level docs", - "get": { - "description": "", - "parameters": [ - { - "description": "", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "", - "in": "path", - "name": "ChannelSid", - "required": true, - "schema": { - "type": "string" - } - }, - { - "description": "", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IN[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ip_messaging.v1.service.channel.invite" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://ip-messaging.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "identity", - "date_created" - ], - "x-path-type": "instance" - }, - "/v1/Services/{ServiceSid}/Channels/{ChannelSid}/Members": { - "description": "TODO: Resource-level docs", - "get": { - "description": "", - "parameters": [ - { - "description": "", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "", - "in": "path", - "name": "ChannelSid", - "required": true, - "schema": { - "type": "string" - } - }, - { - "description": "", - "in": "query", - "name": "Identity", - "schema": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - { - "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", - "in": "query", - "name": "PageSize", - "schema": { - "maximum": 1000, - "minimum": 1, - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "properties": { - "members": { - "items": { - "$ref": "#/components/schemas/ip_messaging.v1.service.channel.member" - }, - "type": "array" - }, - "meta": { - "properties": { - "first_page_url": { - "format": "uri", - "type": "string" - }, - "key": { - "type": "string" - }, - "next_page_url": { - "format": "uri", - "type": "string" - }, - "page": { - "type": "integer" - }, - "page_size": { - "type": "integer" - }, - "previous_page_url": { - "format": "uri", - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "post": { - "description": "", - "parameters": [ - { - "description": "", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "", - "in": "path", - "name": "ChannelSid", - "required": true, - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "schema": { - "properties": { - "Identity": { - "description": "", - "type": "string" - }, - "RoleSid": { - "description": "", - "maxLength": 34, - "minLength": 34, - "pattern": "^RL[0-9a-fA-F]{32}$", - "type": "string" - } - }, - "required": [ - "Identity" - ], - "type": "object" - } - } - } - }, - "responses": { - "201": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ip_messaging.v1.service.channel.member" - } - } - }, - "description": "Created" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://ip-messaging.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "identity", - "date_created" - ], - "x-path-type": "list" - }, - "/v1/Services/{ServiceSid}/Channels/{ChannelSid}/Members/{Sid}": { - "delete": { - "description": "", - "parameters": [ - { - "description": "", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "", - "in": "path", - "name": "ChannelSid", - "required": true, - "schema": { - "type": "string" - } - }, - { - "description": "", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^MB[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "responses": { - "204": { - "description": "The resource was deleted successfully." - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "description": "TODO: Resource-level docs", - "get": { - "description": "", - "parameters": [ - { - "description": "", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "", - "in": "path", - "name": "ChannelSid", - "required": true, - "schema": { - "type": "string" - } - }, - { - "description": "", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^MB[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ip_messaging.v1.service.channel.member" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "post": { - "description": "", - "parameters": [ - { - "description": "", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "", - "in": "path", - "name": "ChannelSid", - "required": true, - "schema": { - "type": "string" - } - }, - { - "description": "", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^MB[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "schema": { - "properties": { - "LastConsumedMessageIndex": { - "description": "", - "nullable": true, - "type": "integer" - }, - "RoleSid": { - "description": "", - "maxLength": 34, - "minLength": 34, - "pattern": "^RL[0-9a-fA-F]{32}$", - "type": "string" - } - }, - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ip_messaging.v1.service.channel.member" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://ip-messaging.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "identity", - "date_created" - ], - "x-path-type": "instance" - }, - "/v1/Services/{ServiceSid}/Channels/{ChannelSid}/Messages": { - "description": "TODO: Resource-level docs", - "get": { - "description": "", - "parameters": [ - { - "description": "", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "", - "in": "path", - "name": "ChannelSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^CH[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "", - "in": "query", - "name": "Order", - "schema": { - "enum": [ - "asc", - "desc" - ], - "type": "string" - } - }, - { - "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", - "in": "query", - "name": "PageSize", - "schema": { - "maximum": 1000, - "minimum": 1, - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "properties": { - "messages": { - "items": { - "$ref": "#/components/schemas/ip_messaging.v1.service.channel.message" - }, - "type": "array" - }, - "meta": { - "properties": { - "first_page_url": { - "format": "uri", - "type": "string" - }, - "key": { - "type": "string" - }, - "next_page_url": { - "format": "uri", - "type": "string" - }, - "page": { - "type": "integer" - }, - "page_size": { - "type": "integer" - }, - "previous_page_url": { - "format": "uri", - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "post": { - "description": "", - "parameters": [ - { - "description": "", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "", - "in": "path", - "name": "ChannelSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^CH[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "schema": { - "properties": { - "Attributes": { - "description": "", - "type": "string" - }, - "Body": { - "description": "", - "type": "string" - }, - "From": { - "description": "", - "type": "string" - } - }, - "required": [ - "Body" - ], - "type": "object" - } - } - } - }, - "responses": { - "201": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ip_messaging.v1.service.channel.message" - } - } - }, - "description": "Created" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://ip-messaging.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "from", - "to", - "date_created" - ], - "x-path-type": "list" - }, - "/v1/Services/{ServiceSid}/Channels/{ChannelSid}/Messages/{Sid}": { - "delete": { - "description": "", - "parameters": [ - { - "description": "", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "", - "in": "path", - "name": "ChannelSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^CH[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IM[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "responses": { - "204": { - "description": "The resource was deleted successfully." - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "description": "TODO: Resource-level docs", - "get": { - "description": "", - "parameters": [ - { - "description": "", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "", - "in": "path", - "name": "ChannelSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^CH[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IM[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ip_messaging.v1.service.channel.message" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "post": { - "description": "", - "parameters": [ - { - "description": "", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "", - "in": "path", - "name": "ChannelSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^CH[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IM[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "schema": { - "properties": { - "Attributes": { - "description": "", - "type": "string" - }, - "Body": { - "description": "", - "type": "string" - } - }, - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ip_messaging.v1.service.channel.message" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://ip-messaging.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "from", - "to", - "date_created" - ], - "x-path-type": "instance" - }, - "/v1/Services/{ServiceSid}/Channels/{Sid}": { - "delete": { - "description": "", - "parameters": [ - { - "description": "", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "204": { - "description": "The resource was deleted successfully." - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "description": "TODO: Resource-level docs", - "get": { - "description": "", - "parameters": [ - { - "description": "", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ip_messaging.v1.service.channel" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "post": { - "description": "", - "parameters": [ - { - "description": "", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "schema": { - "properties": { - "Attributes": { - "description": "", - "type": "string" - }, - "FriendlyName": { - "description": "", - "type": "string" - }, - "UniqueName": { - "description": "", - "type": "string" - } - }, - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ip_messaging.v1.service.channel" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://ip-messaging.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "unique_name", - "friendly_name" - ], - "x-path-type": "instance" - }, - "/v1/Services/{ServiceSid}/Roles": { - "description": "TODO: Resource-level docs", - "get": { - "description": "", - "parameters": [ - { - "description": "", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", - "in": "query", - "name": "PageSize", - "schema": { - "maximum": 1000, - "minimum": 1, - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "properties": { - "meta": { - "properties": { - "first_page_url": { - "format": "uri", - "type": "string" - }, - "key": { - "type": "string" - }, - "next_page_url": { - "format": "uri", - "type": "string" - }, - "page": { - "type": "integer" - }, - "page_size": { - "type": "integer" - }, - "previous_page_url": { - "format": "uri", - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - }, - "roles": { - "items": { - "$ref": "#/components/schemas/ip_messaging.v1.service.role" - }, - "type": "array" - } - }, - "type": "object" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "post": { - "description": "", - "parameters": [ - { - "description": "", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "schema": { - "properties": { - "FriendlyName": { - "description": "", - "type": "string" - }, - "Permission": { - "description": "", - "items": { - "type": "string" - }, - "type": "array" - }, - "Type": { - "description": "", - "enum": [ - "channel", - "deployment" - ], - "type": "string" - } - }, - "required": [ - "FriendlyName", - "Type", - "Permission" - ], - "type": "object" - } - } - } - }, - "responses": { - "201": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ip_messaging.v1.service.role" - } - } - }, - "description": "Created" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://ip-messaging.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "friendly_name", - "type" - ], - "x-path-type": "list" - }, - "/v1/Services/{ServiceSid}/Roles/{Sid}": { - "delete": { - "description": "", - "parameters": [ - { - "description": "", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^RL[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "responses": { - "204": { - "description": "The resource was deleted successfully." - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "description": "TODO: Resource-level docs", - "get": { - "description": "", - "parameters": [ - { - "description": "", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^RL[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ip_messaging.v1.service.role" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "post": { - "description": "", - "parameters": [ - { - "description": "", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^RL[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "schema": { - "properties": { - "Permission": { - "description": "", - "items": { - "type": "string" - }, - "type": "array" - } - }, - "required": [ - "Permission" - ], - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ip_messaging.v1.service.role" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://ip-messaging.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "friendly_name", - "type" - ], - "x-path-type": "instance" - }, - "/v1/Services/{ServiceSid}/Users": { - "description": "TODO: Resource-level docs", - "get": { - "description": "", - "parameters": [ - { - "description": "", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", - "in": "query", - "name": "PageSize", - "schema": { - "maximum": 1000, - "minimum": 1, - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "properties": { - "meta": { - "properties": { - "first_page_url": { - "format": "uri", - "type": "string" - }, - "key": { - "type": "string" - }, - "next_page_url": { - "format": "uri", - "type": "string" - }, - "page": { - "type": "integer" - }, - "page_size": { - "type": "integer" - }, - "previous_page_url": { - "format": "uri", - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - }, - "users": { - "items": { - "$ref": "#/components/schemas/ip_messaging.v1.service.user" - }, - "type": "array" - } - }, - "type": "object" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "post": { - "description": "", - "parameters": [ - { - "description": "", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "schema": { - "properties": { - "Attributes": { - "description": "", - "type": "string" - }, - "FriendlyName": { - "description": "", - "type": "string" - }, - "Identity": { - "description": "", - "type": "string" - }, - "RoleSid": { - "description": "", - "maxLength": 34, - "minLength": 34, - "pattern": "^RL[0-9a-fA-F]{32}$", - "type": "string" - } - }, - "required": [ - "Identity" - ], - "type": "object" - } - } - } - }, - "responses": { - "201": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ip_messaging.v1.service.user" - } - } - }, - "description": "Created" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://ip-messaging.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "friendly_name", - "date_created" - ], - "x-path-type": "list" - }, - "/v1/Services/{ServiceSid}/Users/{Sid}": { - "delete": { - "description": "", - "parameters": [ - { - "description": "", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "204": { - "description": "The resource was deleted successfully." - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "description": "TODO: Resource-level docs", - "get": { - "description": "", - "parameters": [ - { - "description": "", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ip_messaging.v1.service.user" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "post": { - "description": "", - "parameters": [ - { - "description": "", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "schema": { - "properties": { - "Attributes": { - "description": "", - "type": "string" - }, - "FriendlyName": { - "description": "", - "type": "string" - }, - "RoleSid": { - "description": "", - "maxLength": 34, - "minLength": 34, - "pattern": "^RL[0-9a-fA-F]{32}$", - "type": "string" - } - }, - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ip_messaging.v1.service.user" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://ip-messaging.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "friendly_name", - "date_created" - ], - "x-path-type": "instance" - }, - "/v1/Services/{ServiceSid}/Users/{UserSid}/Channels": { - "description": "TODO: Resource-level docs", - "get": { - "description": "", - "parameters": [ - { - "description": "", - "in": "path", - "name": "ServiceSid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - }, - { - "description": "", - "in": "path", - "name": "UserSid", - "required": true, - "schema": { - "type": "string" - } - }, - { - "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", - "in": "query", - "name": "PageSize", - "schema": { - "maximum": 1000, - "minimum": 1, - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "properties": { - "channels": { - "items": { - "$ref": "#/components/schemas/ip_messaging.v1.service.user.user_channel" - }, - "type": "array" - }, - "meta": { - "properties": { - "first_page_url": { - "format": "uri", - "type": "string" - }, - "key": { - "type": "string" - }, - "next_page_url": { - "format": "uri", - "type": "string" - }, - "page": { - "type": "integer" - }, - "page_size": { - "type": "integer" - }, - "previous_page_url": { - "format": "uri", - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://ip-messaging.twilio.com" - } - ], - "x-default-output-properties": [ - "channel_sid", - "status" - ], - "x-path-type": "list" - }, - "/v1/Services/{Sid}": { - "delete": { - "description": "", - "parameters": [ - { - "description": "", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "responses": { - "204": { - "description": "The resource was deleted successfully." - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "description": "TODO: Resource-level docs", - "get": { - "description": "", - "parameters": [ - { - "description": "", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ip_messaging.v1.service" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "post": { - "description": "", - "parameters": [ - { - "description": "", - "in": "path", - "name": "Sid", - "required": true, - "schema": { - "maxLength": 34, - "minLength": 34, - "pattern": "^IS[0-9a-fA-F]{32}$", - "type": "string" - } - } - ], - "requestBody": { - "content": { - "application/x-www-form-urlencoded": { - "schema": { - "properties": { - "ConsumptionReportInterval": { - "description": "", - "type": "integer" - }, - "DefaultChannelCreatorRoleSid": { - "description": "", - "maxLength": 34, - "minLength": 34, - "pattern": "^RL[0-9a-fA-F]{32}$", - "type": "string" - }, - "DefaultChannelRoleSid": { - "description": "", - "maxLength": 34, - "minLength": 34, - "pattern": "^RL[0-9a-fA-F]{32}$", - "type": "string" - }, - "DefaultServiceRoleSid": { - "description": "", - "maxLength": 34, - "minLength": 34, - "pattern": "^RL[0-9a-fA-F]{32}$", - "type": "string" - }, - "FriendlyName": { - "description": "", - "type": "string" - }, - "Limits.ChannelMembers": { - "description": "", - "type": "integer" - }, - "Limits.UserChannels": { - "description": "", - "type": "integer" - }, - "Notifications.AddedToChannel.Enabled": { - "description": "", - "type": "boolean" - }, - "Notifications.AddedToChannel.Template": { - "description": "", - "type": "string" - }, - "Notifications.InvitedToChannel.Enabled": { - "description": "", - "type": "boolean" - }, - "Notifications.InvitedToChannel.Template": { - "description": "", - "type": "string" - }, - "Notifications.NewMessage.Enabled": { - "description": "", - "type": "boolean" - }, - "Notifications.NewMessage.Template": { - "description": "", - "type": "string" - }, - "Notifications.RemovedFromChannel.Enabled": { - "description": "", - "type": "boolean" - }, - "Notifications.RemovedFromChannel.Template": { - "description": "", - "type": "string" - }, - "PostWebhookUrl": { - "description": "", - "format": "uri", - "type": "string" - }, - "PreWebhookUrl": { - "description": "", - "format": "uri", - "type": "string" - }, - "ReachabilityEnabled": { - "description": "", - "type": "boolean" - }, - "ReadStatusEnabled": { - "description": "", - "type": "boolean" - }, - "TypingIndicatorTimeout": { - "description": "", - "type": "integer" - }, - "WebhookFilters": { - "description": "", - "items": { - "type": "string" - }, - "type": "array" - }, - "WebhookMethod": { - "description": "", - "enum": [ - "head", - "get", - "post", - "patch", - "put", - "delete", - "HEAD", - "GET", - "POST", - "PATCH", - "PUT", - "DELETE" - ], - "type": "string" - }, - "Webhooks.OnChannelAdd.Method": { - "description": "", - "enum": [ - "head", - "get", - "post", - "patch", - "put", - "delete", - "HEAD", - "GET", - "POST", - "PATCH", - "PUT", - "DELETE" - ], - "type": "string" - }, - "Webhooks.OnChannelAdd.Url": { - "description": "", - "format": "uri", - "type": "string" - }, - "Webhooks.OnChannelAdded.Method": { - "description": "", - "enum": [ - "head", - "get", - "post", - "patch", - "put", - "delete", - "HEAD", - "GET", - "POST", - "PATCH", - "PUT", - "DELETE" - ], - "type": "string" - }, - "Webhooks.OnChannelAdded.Url": { - "description": "", - "format": "uri", - "type": "string" - }, - "Webhooks.OnChannelDestroy.Method": { - "description": "", - "enum": [ - "head", - "get", - "post", - "patch", - "put", - "delete", - "HEAD", - "GET", - "POST", - "PATCH", - "PUT", - "DELETE" - ], - "type": "string" - }, - "Webhooks.OnChannelDestroy.Url": { - "description": "", - "format": "uri", - "type": "string" - }, - "Webhooks.OnChannelDestroyed.Method": { - "description": "", - "enum": [ - "head", - "get", - "post", - "patch", - "put", - "delete", - "HEAD", - "GET", - "POST", - "PATCH", - "PUT", - "DELETE" - ], - "type": "string" - }, - "Webhooks.OnChannelDestroyed.Url": { - "description": "", - "format": "uri", - "type": "string" - }, - "Webhooks.OnChannelUpdate.Method": { - "description": "", - "enum": [ - "head", - "get", - "post", - "patch", - "put", - "delete", - "HEAD", - "GET", - "POST", - "PATCH", - "PUT", - "DELETE" - ], - "type": "string" - }, - "Webhooks.OnChannelUpdate.Url": { - "description": "", - "format": "uri", - "type": "string" - }, - "Webhooks.OnChannelUpdated.Method": { - "description": "", - "enum": [ - "head", - "get", - "post", - "patch", - "put", - "delete", - "HEAD", - "GET", - "POST", - "PATCH", - "PUT", - "DELETE" - ], - "type": "string" - }, - "Webhooks.OnChannelUpdated.Url": { - "description": "", - "format": "uri", - "type": "string" - }, - "Webhooks.OnMemberAdd.Method": { - "description": "", - "enum": [ - "head", - "get", - "post", - "patch", - "put", - "delete", - "HEAD", - "GET", - "POST", - "PATCH", - "PUT", - "DELETE" - ], - "type": "string" - }, - "Webhooks.OnMemberAdd.Url": { - "description": "", - "format": "uri", - "type": "string" - }, - "Webhooks.OnMemberAdded.Method": { - "description": "", - "enum": [ - "head", - "get", - "post", - "patch", - "put", - "delete", - "HEAD", - "GET", - "POST", - "PATCH", - "PUT", - "DELETE" - ], - "type": "string" - }, - "Webhooks.OnMemberAdded.Url": { - "description": "", - "format": "uri", - "type": "string" - }, - "Webhooks.OnMemberRemove.Method": { - "description": "", - "enum": [ - "head", - "get", - "post", - "patch", - "put", - "delete", - "HEAD", - "GET", - "POST", - "PATCH", - "PUT", - "DELETE" - ], - "type": "string" - }, - "Webhooks.OnMemberRemove.Url": { - "description": "", - "format": "uri", - "type": "string" - }, - "Webhooks.OnMemberRemoved.Method": { - "description": "", - "enum": [ - "head", - "get", - "post", - "patch", - "put", - "delete", - "HEAD", - "GET", - "POST", - "PATCH", - "PUT", - "DELETE" - ], - "type": "string" - }, - "Webhooks.OnMemberRemoved.Url": { - "description": "", - "format": "uri", - "type": "string" - }, - "Webhooks.OnMessageRemove.Method": { - "description": "", - "enum": [ - "head", - "get", - "post", - "patch", - "put", - "delete", - "HEAD", - "GET", - "POST", - "PATCH", - "PUT", - "DELETE" - ], - "type": "string" - }, - "Webhooks.OnMessageRemove.Url": { - "description": "", - "format": "uri", - "type": "string" - }, - "Webhooks.OnMessageRemoved.Method": { - "description": "", - "enum": [ - "head", - "get", - "post", - "patch", - "put", - "delete", - "HEAD", - "GET", - "POST", - "PATCH", - "PUT", - "DELETE" - ], - "type": "string" - }, - "Webhooks.OnMessageRemoved.Url": { - "description": "", - "format": "uri", - "type": "string" - }, - "Webhooks.OnMessageSend.Method": { - "description": "", - "enum": [ - "head", - "get", - "post", - "patch", - "put", - "delete", - "HEAD", - "GET", - "POST", - "PATCH", - "PUT", - "DELETE" - ], - "type": "string" - }, - "Webhooks.OnMessageSend.Url": { - "description": "", - "format": "uri", - "type": "string" - }, - "Webhooks.OnMessageSent.Method": { - "description": "", - "enum": [ - "head", - "get", - "post", - "patch", - "put", - "delete", - "HEAD", - "GET", - "POST", - "PATCH", - "PUT", - "DELETE" - ], - "type": "string" - }, - "Webhooks.OnMessageSent.Url": { - "description": "", - "format": "uri", - "type": "string" - }, - "Webhooks.OnMessageUpdate.Method": { - "description": "", - "enum": [ - "head", - "get", - "post", - "patch", - "put", - "delete", - "HEAD", - "GET", - "POST", - "PATCH", - "PUT", - "DELETE" - ], - "type": "string" - }, - "Webhooks.OnMessageUpdate.Url": { - "description": "", - "format": "uri", - "type": "string" - }, - "Webhooks.OnMessageUpdated.Method": { - "description": "", - "enum": [ - "head", - "get", - "post", - "patch", - "put", - "delete", - "HEAD", - "GET", - "POST", - "PATCH", - "PUT", - "DELETE" - ], - "type": "string" - }, - "Webhooks.OnMessageUpdated.Url": { - "description": "", - "format": "uri", - "type": "string" - } - }, - "type": "object" - } - } - } - }, - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/ip_messaging.v1.service" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://ip-messaging.twilio.com" - } - ], - "x-default-output-properties": [ - "sid", - "friendly_name", - "date_created" - ], - "x-path-type": "instance" + } + }, + "securitySchemes": { + "accountSid_authToken": { + "scheme": "basic", + "type": "http" + } + } + }, + "info": { + "contact": { + "email": "support@twilio.com", + "name": "Twilio Support", + "url": "https://support.twilio.com" + }, + "description": "This is the public Twilio REST API.", + "license": { + "name": "Apache 2.0", + "url": "https://www.apache.org/licenses/LICENSE-2.0.html" }, + "termsOfService": "https://www.twilio.com/legal/tos", + "title": "Twilio - Ip_messaging", + "version": "1.3.0" + }, + "openapi": "3.0.1", + "paths": { "/v2/Credentials": { "description": "TODO: Resource-level docs", "get": { diff --git a/spec/json/twilio_lookups.json b/spec/json/twilio_lookups_v1.json similarity index 100% rename from spec/json/twilio_lookups.json rename to spec/json/twilio_lookups_v1.json diff --git a/spec/json/twilio_messaging.json b/spec/json/twilio_messaging_v1.json similarity index 100% rename from spec/json/twilio_messaging.json rename to spec/json/twilio_messaging_v1.json diff --git a/spec/json/twilio_monitor.json b/spec/json/twilio_monitor_v1.json similarity index 100% rename from spec/json/twilio_monitor.json rename to spec/json/twilio_monitor_v1.json diff --git a/spec/json/twilio_notify.json b/spec/json/twilio_notify_v1.json similarity index 100% rename from spec/json/twilio_notify.json rename to spec/json/twilio_notify_v1.json diff --git a/spec/json/twilio_numbers.json b/spec/json/twilio_numbers_v2.json similarity index 100% rename from spec/json/twilio_numbers.json rename to spec/json/twilio_numbers_v2.json diff --git a/spec/json/twilio_pricing.json b/spec/json/twilio_pricing_v1.json similarity index 68% rename from spec/json/twilio_pricing.json rename to spec/json/twilio_pricing_v1.json index e02c0656..d182c612 100644 --- a/spec/json/twilio_pricing.json +++ b/spec/json/twilio_pricing_v1.json @@ -298,158 +298,6 @@ } }, "type": "object" - }, - "pricing.v2.voice": { - "properties": { - "links": { - "type": "object" - }, - "name": { - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - }, - "pricing.v2.voice.voice_country": { - "properties": { - "country": { - "type": "string" - }, - "iso_country": { - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - }, - "pricing.v2.voice.voice_country|instance": { - "properties": { - "country": { - "type": "string" - }, - "inbound_call_prices": { - "items": { - "properties": { - "base_price": { - "type": "number" - }, - "current_price": { - "type": "number" - }, - "number_type": { - "type": "string" - } - }, - "type": "object" - }, - "type": "array" - }, - "iso_country": { - "type": "string" - }, - "outbound_prefix_prices": { - "items": { - "properties": { - "base_price": { - "type": "number" - }, - "current_price": { - "type": "number" - }, - "destination_prefixes": { - "items": { - "type": "string" - }, - "type": "array" - }, - "friendly_name": { - "type": "string" - }, - "origination_prefixes": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - }, - "type": "array" - }, - "price_unit": { - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - }, - "pricing.v2.voice.voice_number": { - "properties": { - "country": { - "type": "string" - }, - "destination_number": { - "type": "string" - }, - "inbound_call_price": { - "properties": { - "base_price": { - "type": "number" - }, - "current_price": { - "type": "number" - }, - "number_type": { - "type": "string" - } - }, - "type": "object" - }, - "iso_country": { - "type": "string" - }, - "origination_number": { - "type": "string" - }, - "outbound_call_prices": { - "items": { - "properties": { - "base_price": { - "type": "number" - }, - "current_price": { - "type": "number" - }, - "origination_prefixes": { - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - }, - "type": "array" - }, - "price_unit": { - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" } }, "securitySchemes": { @@ -927,195 +775,6 @@ "price_unit" ], "x-path-type": "instance" - }, - "/v2/Voice/Countries": { - "description": "Voice pricing by country", - "get": { - "description": "", - "parameters": [ - { - "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", - "in": "query", - "name": "PageSize", - "schema": { - "maximum": 1000, - "minimum": 1, - "type": "integer" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "properties": { - "countries": { - "items": { - "$ref": "#/components/schemas/pricing.v2.voice.voice_country" - }, - "type": "array" - }, - "meta": { - "properties": { - "first_page_url": { - "format": "uri", - "type": "string" - }, - "key": { - "type": "string" - }, - "next_page_url": { - "format": "uri", - "type": "string" - }, - "page": { - "type": "integer" - }, - "page_size": { - "type": "integer" - }, - "previous_page_url": { - "format": "uri", - "type": "string" - }, - "url": { - "format": "uri", - "type": "string" - } - }, - "type": "object" - } - }, - "type": "object" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://pricing.twilio.com" - } - ], - "x-default-output-properties": [ - "country", - "price_unit" - ], - "x-path-type": "list" - }, - "/v2/Voice/Countries/{IsoCountry}": { - "description": "Voice pricing by country", - "get": { - "description": "Fetch a specific Country.", - "parameters": [ - { - "description": "The [ISO country code](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2) of the origin-based voice pricing information to fetch.", - "in": "path", - "name": "IsoCountry", - "required": true, - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/pricing.v2.voice.voice_country|instance" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://pricing.twilio.com" - } - ], - "x-default-output-properties": [ - "country", - "price_unit" - ], - "x-path-type": "instance" - }, - "/v2/Voice/Numbers/{DestinationNumber}": { - "description": "Voice pricing for a specific phone number", - "get": { - "description": "Fetch pricing information for a specific destination and, optionally, origination phone number.", - "parameters": [ - { - "description": "The destination phone number, in [E.164](https://www.twilio.com/docs/glossary/what-e164) format, for which to fetch the origin-based voice pricing information. E.164 format consists of a + followed by the country code and subscriber number.", - "in": "path", - "name": "DestinationNumber", - "required": true, - "schema": { - "type": "string" - } - }, - { - "description": "The origination phone number, in [E.164](https://www.twilio.com/docs/glossary/what-e164) format, for which to fetch the origin-based voice pricing information. E.164 format consists of a + followed by the country code and subscriber number.", - "in": "query", - "name": "OriginationNumber", - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/pricing.v2.voice.voice_number" - } - } - }, - "description": "OK" - } - }, - "security": [ - { - "accountSid_authToken": [] - } - ], - "tags": [ - "GA" - ] - }, - "servers": [ - { - "url": "https://pricing.twilio.com" - } - ], - "x-default-output-properties": [ - "country", - "inbound_call_price", - "price_unit" - ], - "x-path-type": "instance" } }, "tags": [ diff --git a/spec/json/twilio_pricing_v2.json b/spec/json/twilio_pricing_v2.json new file mode 100644 index 00000000..ff7abe66 --- /dev/null +++ b/spec/json/twilio_pricing_v2.json @@ -0,0 +1,377 @@ +{ + "components": { + "schemas": { + "pricing.v2.voice": { + "properties": { + "links": { + "type": "object" + }, + "name": { + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + }, + "pricing.v2.voice.voice_country": { + "properties": { + "country": { + "type": "string" + }, + "iso_country": { + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + }, + "pricing.v2.voice.voice_country|instance": { + "properties": { + "country": { + "type": "string" + }, + "inbound_call_prices": { + "items": { + "properties": { + "base_price": { + "type": "number" + }, + "current_price": { + "type": "number" + }, + "number_type": { + "type": "string" + } + }, + "type": "object" + }, + "type": "array" + }, + "iso_country": { + "type": "string" + }, + "outbound_prefix_prices": { + "items": { + "properties": { + "base_price": { + "type": "number" + }, + "current_price": { + "type": "number" + }, + "destination_prefixes": { + "items": { + "type": "string" + }, + "type": "array" + }, + "friendly_name": { + "type": "string" + }, + "origination_prefixes": { + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, + "type": "array" + }, + "price_unit": { + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + }, + "pricing.v2.voice.voice_number": { + "properties": { + "country": { + "type": "string" + }, + "destination_number": { + "type": "string" + }, + "inbound_call_price": { + "properties": { + "base_price": { + "type": "number" + }, + "current_price": { + "type": "number" + }, + "number_type": { + "type": "string" + } + }, + "type": "object" + }, + "iso_country": { + "type": "string" + }, + "origination_number": { + "type": "string" + }, + "outbound_call_prices": { + "items": { + "properties": { + "base_price": { + "type": "number" + }, + "current_price": { + "type": "number" + }, + "origination_prefixes": { + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, + "type": "array" + }, + "price_unit": { + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + } + }, + "securitySchemes": { + "accountSid_authToken": { + "scheme": "basic", + "type": "http" + } + } + }, + "info": { + "contact": { + "email": "support@twilio.com", + "name": "Twilio Support", + "url": "https://support.twilio.com" + }, + "description": "This is the public Twilio REST API.", + "license": { + "name": "Apache 2.0", + "url": "https://www.apache.org/licenses/LICENSE-2.0.html" + }, + "termsOfService": "https://www.twilio.com/legal/tos", + "title": "Twilio - Pricing", + "version": "1.3.0" + }, + "openapi": "3.0.1", + "paths": { + "/v2/Voice/Countries": { + "description": "Voice pricing by country", + "get": { + "description": "", + "parameters": [ + { + "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", + "in": "query", + "name": "PageSize", + "schema": { + "maximum": 1000, + "minimum": 1, + "type": "integer" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "properties": { + "countries": { + "items": { + "$ref": "#/components/schemas/pricing.v2.voice.voice_country" + }, + "type": "array" + }, + "meta": { + "properties": { + "first_page_url": { + "format": "uri", + "type": "string" + }, + "key": { + "type": "string" + }, + "next_page_url": { + "format": "uri", + "type": "string" + }, + "page": { + "type": "integer" + }, + "page_size": { + "type": "integer" + }, + "previous_page_url": { + "format": "uri", + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + } + }, + "type": "object" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "servers": [ + { + "url": "https://pricing.twilio.com" + } + ], + "x-default-output-properties": [ + "country", + "price_unit" + ], + "x-path-type": "list" + }, + "/v2/Voice/Countries/{IsoCountry}": { + "description": "Voice pricing by country", + "get": { + "description": "Fetch a specific Country.", + "parameters": [ + { + "description": "The [ISO country code](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2) of the origin-based voice pricing information to fetch.", + "in": "path", + "name": "IsoCountry", + "required": true, + "schema": { + "type": "string" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/pricing.v2.voice.voice_country|instance" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "servers": [ + { + "url": "https://pricing.twilio.com" + } + ], + "x-default-output-properties": [ + "country", + "price_unit" + ], + "x-path-type": "instance" + }, + "/v2/Voice/Numbers/{DestinationNumber}": { + "description": "Voice pricing for a specific phone number", + "get": { + "description": "Fetch pricing information for a specific destination and, optionally, origination phone number.", + "parameters": [ + { + "description": "The destination phone number, in [E.164](https://www.twilio.com/docs/glossary/what-e164) format, for which to fetch the origin-based voice pricing information. E.164 format consists of a + followed by the country code and subscriber number.", + "in": "path", + "name": "DestinationNumber", + "required": true, + "schema": { + "type": "string" + } + }, + { + "description": "The origination phone number, in [E.164](https://www.twilio.com/docs/glossary/what-e164) format, for which to fetch the origin-based voice pricing information. E.164 format consists of a + followed by the country code and subscriber number.", + "in": "query", + "name": "OriginationNumber", + "schema": { + "type": "string" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/pricing.v2.voice.voice_number" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "servers": [ + { + "url": "https://pricing.twilio.com" + } + ], + "x-default-output-properties": [ + "country", + "inbound_call_price", + "price_unit" + ], + "x-path-type": "instance" + } + }, + "tags": [ + { + "description": "This product is Generally Available.", + "name": "GA" + } + ] +} \ No newline at end of file diff --git a/spec/json/twilio_proxy.json b/spec/json/twilio_proxy_v1.json similarity index 100% rename from spec/json/twilio_proxy.json rename to spec/json/twilio_proxy_v1.json diff --git a/spec/json/twilio_serverless.json b/spec/json/twilio_serverless_v1.json similarity index 100% rename from spec/json/twilio_serverless.json rename to spec/json/twilio_serverless_v1.json diff --git a/spec/json/twilio_studio_v1.json b/spec/json/twilio_studio_v1.json new file mode 100644 index 00000000..4eb30e00 --- /dev/null +++ b/spec/json/twilio_studio_v1.json @@ -0,0 +1,1880 @@ +{ + "components": { + "schemas": { + "studio.v1.flow": { + "properties": { + "account_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^AC[0-9a-fA-F]{32}$", + "type": "string" + }, + "date_created": { + "format": "date-time", + "type": "string" + }, + "date_updated": { + "format": "date-time", + "type": "string" + }, + "friendly_name": { + "type": "string" + }, + "links": { + "type": "object" + }, + "sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + }, + "status": { + "enum": [ + "draft", + "published" + ], + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + }, + "version": { + "type": "integer" + } + }, + "type": "object" + }, + "studio.v1.flow.engagement": { + "properties": { + "account_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^AC[0-9a-fA-F]{32}$", + "type": "string" + }, + "contact_channel_address": { + "type": "string" + }, + "contact_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FC[0-9a-fA-F]{32}$", + "type": "string" + }, + "context": { + "type": "object" + }, + "date_created": { + "format": "date-time", + "type": "string" + }, + "date_updated": { + "format": "date-time", + "type": "string" + }, + "flow_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + }, + "links": { + "type": "object" + }, + "sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FN[0-9a-fA-F]{32}$", + "type": "string" + }, + "status": { + "enum": [ + "active", + "ended" + ], + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + }, + "studio.v1.flow.engagement.engagement_context": { + "properties": { + "account_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^AC[0-9a-fA-F]{32}$", + "type": "string" + }, + "context": { + "type": "object" + }, + "engagement_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FN[0-9a-fA-F]{32}$", + "type": "string" + }, + "flow_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + }, + "studio.v1.flow.engagement.step": { + "properties": { + "account_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^AC[0-9a-fA-F]{32}$", + "type": "string" + }, + "context": { + "type": "object" + }, + "date_created": { + "format": "date-time", + "type": "string" + }, + "date_updated": { + "format": "date-time", + "type": "string" + }, + "engagement_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FN[0-9a-fA-F]{32}$", + "type": "string" + }, + "flow_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + }, + "links": { + "type": "object" + }, + "name": { + "type": "string" + }, + "sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FT[0-9a-fA-F]{32}$", + "type": "string" + }, + "transitioned_from": { + "type": "string" + }, + "transitioned_to": { + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + }, + "studio.v1.flow.engagement.step.step_context": { + "properties": { + "account_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^AC[0-9a-fA-F]{32}$", + "type": "string" + }, + "context": { + "type": "object" + }, + "engagement_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FN[0-9a-fA-F]{32}$", + "type": "string" + }, + "flow_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + }, + "step_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FT[0-9a-fA-F]{32}$", + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + }, + "studio.v1.flow.execution": { + "properties": { + "account_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^AC[0-9a-fA-F]{32}$", + "type": "string" + }, + "contact_channel_address": { + "type": "string" + }, + "contact_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FC[0-9a-fA-F]{32}$", + "type": "string" + }, + "context": { + "type": "object" + }, + "date_created": { + "format": "date-time", + "type": "string" + }, + "date_updated": { + "format": "date-time", + "type": "string" + }, + "flow_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + }, + "links": { + "type": "object" + }, + "sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FN[0-9a-fA-F]{32}$", + "type": "string" + }, + "status": { + "enum": [ + "active", + "ended" + ], + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + }, + "studio.v1.flow.execution.execution_context": { + "properties": { + "account_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^AC[0-9a-fA-F]{32}$", + "type": "string" + }, + "context": { + "type": "object" + }, + "execution_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FN[0-9a-fA-F]{32}$", + "type": "string" + }, + "flow_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + }, + "studio.v1.flow.execution.execution_step": { + "properties": { + "account_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^AC[0-9a-fA-F]{32}$", + "type": "string" + }, + "context": { + "type": "object" + }, + "date_created": { + "format": "date-time", + "type": "string" + }, + "date_updated": { + "format": "date-time", + "type": "string" + }, + "execution_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FN[0-9a-fA-F]{32}$", + "type": "string" + }, + "flow_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + }, + "links": { + "type": "object" + }, + "name": { + "type": "string" + }, + "sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FT[0-9a-fA-F]{32}$", + "type": "string" + }, + "transitioned_from": { + "type": "string" + }, + "transitioned_to": { + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + }, + "studio.v1.flow.execution.execution_step.execution_step_context": { + "properties": { + "account_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^AC[0-9a-fA-F]{32}$", + "type": "string" + }, + "context": { + "type": "object" + }, + "execution_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FN[0-9a-fA-F]{32}$", + "type": "string" + }, + "flow_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + }, + "step_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FT[0-9a-fA-F]{32}$", + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + } + }, + "securitySchemes": { + "accountSid_authToken": { + "scheme": "basic", + "type": "http" + } + } + }, + "info": { + "contact": { + "email": "support@twilio.com", + "name": "Twilio Support", + "url": "https://support.twilio.com" + }, + "description": "This is the public Twilio REST API.", + "license": { + "name": "Apache 2.0", + "url": "https://www.apache.org/licenses/LICENSE-2.0.html" + }, + "termsOfService": "https://www.twilio.com/legal/tos", + "title": "Twilio - Studio", + "version": "1.3.0" + }, + "openapi": "3.0.1", + "paths": { + "/v1/Flows": { + "description": "Studio flows", + "get": { + "description": "Retrieve a list of all Flows.", + "parameters": [ + { + "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", + "in": "query", + "name": "PageSize", + "schema": { + "maximum": 1000, + "minimum": 1, + "type": "integer" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "properties": { + "flows": { + "items": { + "$ref": "#/components/schemas/studio.v1.flow" + }, + "type": "array" + }, + "meta": { + "properties": { + "first_page_url": { + "format": "uri", + "type": "string" + }, + "key": { + "type": "string" + }, + "next_page_url": { + "format": "uri", + "type": "string" + }, + "page": { + "type": "integer" + }, + "page_size": { + "type": "integer" + }, + "previous_page_url": { + "format": "uri", + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + } + }, + "type": "object" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "servers": [ + { + "url": "https://studio.twilio.com" + } + ], + "x-default-output-properties": [ + "sid", + "friendly_name", + "status", + "version" + ], + "x-path-type": "list" + }, + "/v1/Flows/{FlowSid}/Engagements": { + "description": "[DEPRECATED] Excecutions of Studio flows", + "get": { + "description": "Retrieve a list of all Engagements for the Flow.", + "parameters": [ + { + "description": "The SID of the Flow to read Engagements from.", + "in": "path", + "name": "FlowSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", + "in": "query", + "name": "PageSize", + "schema": { + "maximum": 1000, + "minimum": 1, + "type": "integer" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "properties": { + "engagements": { + "items": { + "$ref": "#/components/schemas/studio.v1.flow.engagement" + }, + "type": "array" + }, + "meta": { + "properties": { + "first_page_url": { + "format": "uri", + "type": "string" + }, + "key": { + "type": "string" + }, + "next_page_url": { + "format": "uri", + "type": "string" + }, + "page": { + "type": "integer" + }, + "page_size": { + "type": "integer" + }, + "previous_page_url": { + "format": "uri", + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + } + }, + "type": "object" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "post": { + "description": "Triggers a new Engagement for the Flow", + "parameters": [ + { + "description": "The SID of the Flow.", + "in": "path", + "name": "FlowSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "schema": { + "properties": { + "From": { + "description": "The Twilio phone number to send messages or initiate calls from during the Flow Engagement. Available as variable `{{flow.channel.address}}`", + "type": "string" + }, + "Parameters": { + "description": "A JSON string we will add to your flow's context and that you can access as variables inside your flow. For example, if you pass in `Parameters={'name':'Zeke'}` then inside a widget you can reference the variable `{{flow.data.name}}` which will return the string 'Zeke'. Note: the JSON value must explicitly be passed as a string, not as a hash object. Depending on your particular HTTP library, you may need to add quotes or URL encode your JSON string.", + "type": "object" + }, + "To": { + "description": "The Contact phone number to start a Studio Flow Engagement, available as variable `{{contact.channel.address}}`.", + "type": "string" + } + }, + "required": [ + "To", + "From" + ], + "type": "object" + } + } + } + }, + "responses": { + "201": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/studio.v1.flow.engagement" + } + } + }, + "description": "Created" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "servers": [ + { + "url": "https://studio.twilio.com" + } + ], + "x-default-output-properties": [ + "sid", + "contact_sid", + "status", + "date_created" + ], + "x-path-type": "list" + }, + "/v1/Flows/{FlowSid}/Engagements/{EngagementSid}/Context": { + "description": "[DEPRECATED] JSON context for engagements", + "get": { + "description": "Retrieve the most recent context for an Engagement.", + "parameters": [ + { + "description": "The SID of the Flow.", + "in": "path", + "name": "FlowSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The SID of the Engagement.", + "in": "path", + "name": "EngagementSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FN[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/studio.v1.flow.engagement.engagement_context" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "servers": [ + { + "url": "https://studio.twilio.com" + } + ], + "x-default-output-properties": [ + "context" + ], + "x-path-type": "instance" + }, + "/v1/Flows/{FlowSid}/Engagements/{EngagementSid}/Steps": { + "description": "Steps within a Studio flow", + "get": { + "description": "Retrieve a list of all Steps for an Engagement.", + "parameters": [ + { + "description": "The SID of the Flow with the Step to read.", + "in": "path", + "name": "FlowSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The SID of the Engagement with the Step to read.", + "in": "path", + "name": "EngagementSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FN[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", + "in": "query", + "name": "PageSize", + "schema": { + "maximum": 1000, + "minimum": 1, + "type": "integer" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "properties": { + "meta": { + "properties": { + "first_page_url": { + "format": "uri", + "type": "string" + }, + "key": { + "type": "string" + }, + "next_page_url": { + "format": "uri", + "type": "string" + }, + "page": { + "type": "integer" + }, + "page_size": { + "type": "integer" + }, + "previous_page_url": { + "format": "uri", + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + }, + "steps": { + "items": { + "$ref": "#/components/schemas/studio.v1.flow.engagement.step" + }, + "type": "array" + } + }, + "type": "object" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "servers": [ + { + "url": "https://studio.twilio.com" + } + ], + "x-default-output-properties": [ + "sid", + "name", + "transitioned_from", + "transitioned_to" + ], + "x-path-type": "list" + }, + "/v1/Flows/{FlowSid}/Engagements/{EngagementSid}/Steps/{Sid}": { + "description": "Steps within a Studio flow", + "get": { + "description": "Retrieve a Step.", + "parameters": [ + { + "description": "The SID of the Flow with the Step to fetch.", + "in": "path", + "name": "FlowSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The SID of the Engagement with the Step to fetch.", + "in": "path", + "name": "EngagementSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FN[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The SID of the Step resource to fetch.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FT[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/studio.v1.flow.engagement.step" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "servers": [ + { + "url": "https://studio.twilio.com" + } + ], + "x-default-output-properties": [ + "sid", + "name", + "transitioned_from", + "transitioned_to" + ], + "x-path-type": "instance" + }, + "/v1/Flows/{FlowSid}/Engagements/{EngagementSid}/Steps/{StepSid}/Context": { + "description": "JSON context for individual steps", + "get": { + "description": "Retrieve the context for an Engagement Step.", + "parameters": [ + { + "description": "The SID of the Flow with the Step to fetch.", + "in": "path", + "name": "FlowSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The SID of the Engagement with the Step to fetch.", + "in": "path", + "name": "EngagementSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FN[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The SID of the Step to fetch", + "in": "path", + "name": "StepSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FT[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/studio.v1.flow.engagement.step.step_context" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "servers": [ + { + "url": "https://studio.twilio.com" + } + ], + "x-default-output-properties": [ + "context" + ], + "x-path-type": "instance" + }, + "/v1/Flows/{FlowSid}/Engagements/{Sid}": { + "delete": { + "description": "Delete this Engagement and all Steps relating to it.", + "parameters": [ + { + "description": "The SID of the Flow to delete Engagements from.", + "in": "path", + "name": "FlowSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The SID of the Engagement resource to delete.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FN[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "responses": { + "204": { + "description": "The resource was deleted successfully." + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "description": "[DEPRECATED] Excecutions of Studio flows", + "get": { + "description": "Retrieve an Engagement", + "parameters": [ + { + "description": "The SID of the Flow.", + "in": "path", + "name": "FlowSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The SID of the Engagement resource to fetch.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FN[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/studio.v1.flow.engagement" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "servers": [ + { + "url": "https://studio.twilio.com" + } + ], + "x-default-output-properties": [ + "sid", + "contact_sid", + "status", + "date_created" + ], + "x-path-type": "instance" + }, + "/v1/Flows/{FlowSid}/Executions": { + "description": "Executions of Studio flows", + "get": { + "description": "Retrieve a list of all Executions for the Flow.", + "parameters": [ + { + "description": "The SID of the Flow with the Execution resources to read.", + "in": "path", + "name": "FlowSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "Only show Execution resources starting on or after this [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date-time, given as `YYYY-MM-DDThh:mm:ss-hh:mm`.", + "in": "query", + "name": "DateCreatedFrom", + "schema": { + "format": "date-time", + "type": "string" + } + }, + { + "description": "Only show Execution resources starting before this [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date-time, given as `YYYY-MM-DDThh:mm:ss-hh:mm`.", + "in": "query", + "name": "DateCreatedTo", + "schema": { + "format": "date-time", + "type": "string" + } + }, + { + "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", + "in": "query", + "name": "PageSize", + "schema": { + "maximum": 1000, + "minimum": 1, + "type": "integer" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "properties": { + "executions": { + "items": { + "$ref": "#/components/schemas/studio.v1.flow.execution" + }, + "type": "array" + }, + "meta": { + "properties": { + "first_page_url": { + "format": "uri", + "type": "string" + }, + "key": { + "type": "string" + }, + "next_page_url": { + "format": "uri", + "type": "string" + }, + "page": { + "type": "integer" + }, + "page_size": { + "type": "integer" + }, + "previous_page_url": { + "format": "uri", + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + } + }, + "type": "object" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "post": { + "description": "Triggers a new Execution for the Flow", + "parameters": [ + { + "description": "The SID of the Excecution's Flow.", + "in": "path", + "name": "FlowSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "schema": { + "properties": { + "From": { + "description": "The Twilio phone number to send messages or initiate calls from during the Flow's Execution. Available as variable `{{flow.channel.address}}`.", + "type": "string" + }, + "Parameters": { + "description": "JSON data that will be added to the Flow's context and that can be accessed as variables inside your Flow. For example, if you pass in `Parameters={\"name\":\"Zeke\"}`, a widget in your Flow can reference the variable `{{flow.data.name}}`, which returns \"Zeke\". Note: the JSON value must explicitly be passed as a string, not as a hash object. Depending on your particular HTTP library, you may need to add quotes or URL encode the JSON string.", + "type": "object" + }, + "To": { + "description": "The Contact phone number to start a Studio Flow Execution, available as variable `{{contact.channel.address}}`.", + "type": "string" + } + }, + "required": [ + "To", + "From" + ], + "type": "object" + } + } + } + }, + "responses": { + "201": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/studio.v1.flow.execution" + } + } + }, + "description": "Created" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "servers": [ + { + "url": "https://studio.twilio.com" + } + ], + "x-default-output-properties": [ + "sid", + "contact_sid", + "status", + "date_created" + ], + "x-path-type": "list" + }, + "/v1/Flows/{FlowSid}/Executions/{ExecutionSid}/Context": { + "description": "JSON context for executions", + "get": { + "description": "Retrieve the most recent context for an Execution.", + "parameters": [ + { + "description": "The SID of the Flow with the Execution context to fetch.", + "in": "path", + "name": "FlowSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The SID of the Execution context to fetch.", + "in": "path", + "name": "ExecutionSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FN[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/studio.v1.flow.execution.execution_context" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "servers": [ + { + "url": "https://studio.twilio.com" + } + ], + "x-default-output-properties": [ + "context" + ], + "x-path-type": "instance" + }, + "/v1/Flows/{FlowSid}/Executions/{ExecutionSid}/Steps": { + "description": "Individual steps within an execution", + "get": { + "description": "Retrieve a list of all Steps for an Execution.", + "parameters": [ + { + "description": "The SID of the Flow with the Steps to read.", + "in": "path", + "name": "FlowSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The SID of the Execution with the Steps to read.", + "in": "path", + "name": "ExecutionSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FN[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", + "in": "query", + "name": "PageSize", + "schema": { + "maximum": 1000, + "minimum": 1, + "type": "integer" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "properties": { + "meta": { + "properties": { + "first_page_url": { + "format": "uri", + "type": "string" + }, + "key": { + "type": "string" + }, + "next_page_url": { + "format": "uri", + "type": "string" + }, + "page": { + "type": "integer" + }, + "page_size": { + "type": "integer" + }, + "previous_page_url": { + "format": "uri", + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + }, + "steps": { + "items": { + "$ref": "#/components/schemas/studio.v1.flow.execution.execution_step" + }, + "type": "array" + } + }, + "type": "object" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "servers": [ + { + "url": "https://studio.twilio.com" + } + ], + "x-default-output-properties": [ + "sid", + "name", + "date_created" + ], + "x-path-type": "list" + }, + "/v1/Flows/{FlowSid}/Executions/{ExecutionSid}/Steps/{Sid}": { + "description": "Individual steps within an execution", + "get": { + "description": "Retrieve a Step.", + "parameters": [ + { + "description": "The SID of the Flow with the Step to fetch.", + "in": "path", + "name": "FlowSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The SID of the Execution resource with the Step to fetch.", + "in": "path", + "name": "ExecutionSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FN[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The SID of the ExecutionStep resource to fetch.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FT[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/studio.v1.flow.execution.execution_step" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "servers": [ + { + "url": "https://studio.twilio.com" + } + ], + "x-default-output-properties": [ + "sid", + "name", + "date_created" + ], + "x-path-type": "instance" + }, + "/v1/Flows/{FlowSid}/Executions/{ExecutionSid}/Steps/{StepSid}/Context": { + "description": "JSON context for an individual step within an execution", + "get": { + "description": "Retrieve the context for an Execution Step.", + "parameters": [ + { + "description": "The SID of the Flow with the Step to fetch.", + "in": "path", + "name": "FlowSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The SID of the Execution resource with the Step to fetch.", + "in": "path", + "name": "ExecutionSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FN[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The SID of the Step to fetch.", + "in": "path", + "name": "StepSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FT[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/studio.v1.flow.execution.execution_step.execution_step_context" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "servers": [ + { + "url": "https://studio.twilio.com" + } + ], + "x-default-output-properties": [ + "context" + ], + "x-path-type": "instance" + }, + "/v1/Flows/{FlowSid}/Executions/{Sid}": { + "delete": { + "description": "Delete the Execution and all Steps relating to it.", + "parameters": [ + { + "description": "The SID of the Flow with the Execution resources to delete.", + "in": "path", + "name": "FlowSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The SID of the Execution resource to delete.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FN[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "responses": { + "204": { + "description": "The resource was deleted successfully." + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "description": "Executions of Studio flows", + "get": { + "description": "Retrieve an Execution", + "parameters": [ + { + "description": "The SID of the Flow with the Execution resource to fetch", + "in": "path", + "name": "FlowSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The SID of the Execution resource to fetch.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FN[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/studio.v1.flow.execution" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "post": { + "description": "Update the status of an Execution to `ended`.", + "parameters": [ + { + "description": "The SID of the Flow with the Execution resources to update.", + "in": "path", + "name": "FlowSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The SID of the Execution resource to update.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FN[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "schema": { + "properties": { + "Status": { + "description": "The status of the Execution. Can only be `ended`.", + "enum": [ + "active", + "ended" + ], + "type": "string" + } + }, + "required": [ + "Status" + ], + "type": "object" + } + } + } + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/studio.v1.flow.execution" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "servers": [ + { + "url": "https://studio.twilio.com" + } + ], + "x-default-output-properties": [ + "sid", + "contact_sid", + "status", + "date_created" + ], + "x-path-type": "instance" + }, + "/v1/Flows/{Sid}": { + "delete": { + "description": "Delete a specific Flow.", + "parameters": [ + { + "description": "The SID of the Flow resource to delete.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "responses": { + "204": { + "description": "The resource was deleted successfully." + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "description": "Studio flows", + "get": { + "description": "Retrieve a specific Flow.", + "parameters": [ + { + "description": "The SID of the Flow resource to fetch.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/studio.v1.flow" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "GA" + ] + }, + "servers": [ + { + "url": "https://studio.twilio.com" + } + ], + "x-default-output-properties": [ + "sid", + "friendly_name", + "status", + "version" + ], + "x-path-type": "instance" + } + }, + "tags": [ + { + "description": "This product is Generally Available.", + "name": "GA" + } + ] +} \ No newline at end of file diff --git a/spec/json/twilio_studio_v2.json b/spec/json/twilio_studio_v2.json new file mode 100644 index 00000000..d78744c4 --- /dev/null +++ b/spec/json/twilio_studio_v2.json @@ -0,0 +1,1681 @@ +{ + "components": { + "schemas": { + "studio.v2.flow": { + "properties": { + "account_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^AC[0-9a-fA-F]{32}$", + "type": "string" + }, + "commit_message": { + "type": "string" + }, + "date_created": { + "format": "date-time", + "type": "string" + }, + "date_updated": { + "format": "date-time", + "type": "string" + }, + "definition": { + "type": "object" + }, + "errors": { + "items": { + "type": "object" + }, + "type": "array" + }, + "friendly_name": { + "type": "string" + }, + "links": { + "type": "object" + }, + "revision": { + "type": "integer" + }, + "sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + }, + "status": { + "enum": [ + "draft", + "published" + ], + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + }, + "valid": { + "type": "boolean" + }, + "warnings": { + "items": { + "type": "object" + }, + "type": "array" + }, + "webhook_url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + }, + "studio.v2.flow.execution": { + "properties": { + "account_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^AC[0-9a-fA-F]{32}$", + "type": "string" + }, + "contact_channel_address": { + "type": "string" + }, + "context": { + "type": "object" + }, + "date_created": { + "format": "date-time", + "type": "string" + }, + "date_updated": { + "format": "date-time", + "type": "string" + }, + "flow_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + }, + "links": { + "type": "object" + }, + "sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FN[0-9a-fA-F]{32}$", + "type": "string" + }, + "status": { + "enum": [ + "active", + "ended" + ], + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + }, + "studio.v2.flow.execution.execution_context": { + "properties": { + "account_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^AC[0-9a-fA-F]{32}$", + "type": "string" + }, + "context": { + "type": "object" + }, + "execution_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FN[0-9a-fA-F]{32}$", + "type": "string" + }, + "flow_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + }, + "studio.v2.flow.execution.execution_step": { + "properties": { + "account_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^AC[0-9a-fA-F]{32}$", + "type": "string" + }, + "context": { + "type": "object" + }, + "date_created": { + "format": "date-time", + "type": "string" + }, + "date_updated": { + "format": "date-time", + "type": "string" + }, + "execution_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FN[0-9a-fA-F]{32}$", + "type": "string" + }, + "flow_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + }, + "links": { + "type": "object" + }, + "name": { + "type": "string" + }, + "sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FT[0-9a-fA-F]{32}$", + "type": "string" + }, + "transitioned_from": { + "type": "string" + }, + "transitioned_to": { + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + }, + "studio.v2.flow.execution.execution_step.execution_step_context": { + "properties": { + "account_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^AC[0-9a-fA-F]{32}$", + "type": "string" + }, + "context": { + "type": "object" + }, + "execution_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FN[0-9a-fA-F]{32}$", + "type": "string" + }, + "flow_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + }, + "step_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FT[0-9a-fA-F]{32}$", + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + }, + "studio.v2.flow.flow_revision": { + "properties": { + "account_sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^AC[0-9a-fA-F]{32}$", + "type": "string" + }, + "commit_message": { + "type": "string" + }, + "date_created": { + "format": "date-time", + "type": "string" + }, + "date_updated": { + "format": "date-time", + "type": "string" + }, + "definition": { + "type": "object" + }, + "errors": { + "items": { + "type": "object" + }, + "type": "array" + }, + "friendly_name": { + "type": "string" + }, + "revision": { + "type": "integer" + }, + "sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + }, + "status": { + "enum": [ + "draft", + "published" + ], + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + }, + "valid": { + "type": "boolean" + } + }, + "type": "object" + }, + "studio.v2.flow.test_user": { + "properties": { + "sid": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + }, + "test_users": { + "items": { + "type": "string" + }, + "type": "array" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + }, + "studio.v2.flow_validate": { + "properties": { + "valid": { + "type": "boolean" + } + }, + "type": "object" + } + }, + "securitySchemes": { + "accountSid_authToken": { + "scheme": "basic", + "type": "http" + } + } + }, + "info": { + "contact": { + "email": "support@twilio.com", + "name": "Twilio Support", + "url": "https://support.twilio.com" + }, + "description": "This is the public Twilio REST API.", + "license": { + "name": "Apache 2.0", + "url": "https://www.apache.org/licenses/LICENSE-2.0.html" + }, + "termsOfService": "https://www.twilio.com/legal/tos", + "title": "Twilio - Studio", + "version": "1.3.0" + }, + "openapi": "3.0.1", + "paths": { + "/v2/Flows": { + "description": "Studio flows", + "get": { + "description": "Retrieve a list of all Flows.", + "parameters": [ + { + "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", + "in": "query", + "name": "PageSize", + "schema": { + "maximum": 1000, + "minimum": 1, + "type": "integer" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "properties": { + "flows": { + "items": { + "$ref": "#/components/schemas/studio.v2.flow" + }, + "type": "array" + }, + "meta": { + "properties": { + "first_page_url": { + "format": "uri", + "type": "string" + }, + "key": { + "type": "string" + }, + "next_page_url": { + "format": "uri", + "type": "string" + }, + "page": { + "type": "integer" + }, + "page_size": { + "type": "integer" + }, + "previous_page_url": { + "format": "uri", + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + } + }, + "type": "object" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "Beta" + ] + }, + "post": { + "description": "Create a Flow.", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "schema": { + "properties": { + "CommitMessage": { + "description": "Description on change made in the revision.", + "type": "string" + }, + "Definition": { + "description": "JSON representation of flow definition.", + "type": "object" + }, + "FriendlyName": { + "description": "The string that you assigned to describe the Flow.", + "type": "string" + }, + "Status": { + "description": "The status of the Flow. Can be: `draft` or `published`.", + "enum": [ + "draft", + "published" + ], + "type": "string" + } + }, + "required": [ + "FriendlyName", + "Status", + "Definition" + ], + "type": "object" + } + } + } + }, + "responses": { + "201": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/studio.v2.flow" + } + } + }, + "description": "Created" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "Beta" + ] + }, + "servers": [ + { + "url": "https://studio.twilio.com" + } + ], + "x-default-output-properties": [ + "sid", + "friendly_name", + "status", + "revision" + ], + "x-path-type": "list" + }, + "/v2/Flows/Validate": { + "description": "TODO: Resource-level docs", + "post": { + "description": "", + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "schema": { + "properties": { + "CommitMessage": { + "description": "", + "type": "string" + }, + "Definition": { + "description": "", + "type": "object" + }, + "FriendlyName": { + "description": "", + "type": "string" + }, + "Status": { + "description": "", + "enum": [ + "draft", + "published" + ], + "type": "string" + } + }, + "required": [ + "FriendlyName", + "Status", + "Definition" + ], + "type": "object" + } + } + } + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/studio.v2.flow_validate" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "Beta" + ] + }, + "servers": [ + { + "url": "https://studio.twilio.com" + } + ], + "x-default-output-properties": [ + "valid" + ], + "x-path-type": "list" + }, + "/v2/Flows/{FlowSid}/Executions": { + "description": "Executions of Studio flows", + "get": { + "description": "Retrieve a list of all Executions for the Flow.", + "parameters": [ + { + "description": "The SID of the Flow with the Execution resources to read.", + "in": "path", + "name": "FlowSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "Only show Execution resources starting on or after this [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date-time, given as `YYYY-MM-DDThh:mm:ss-hh:mm`.", + "in": "query", + "name": "DateCreatedFrom", + "schema": { + "format": "date-time", + "type": "string" + } + }, + { + "description": "Only show Execution resources starting before this [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) date-time, given as `YYYY-MM-DDThh:mm:ss-hh:mm`.", + "in": "query", + "name": "DateCreatedTo", + "schema": { + "format": "date-time", + "type": "string" + } + }, + { + "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", + "in": "query", + "name": "PageSize", + "schema": { + "maximum": 1000, + "minimum": 1, + "type": "integer" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "properties": { + "executions": { + "items": { + "$ref": "#/components/schemas/studio.v2.flow.execution" + }, + "type": "array" + }, + "meta": { + "properties": { + "first_page_url": { + "format": "uri", + "type": "string" + }, + "key": { + "type": "string" + }, + "next_page_url": { + "format": "uri", + "type": "string" + }, + "page": { + "type": "integer" + }, + "page_size": { + "type": "integer" + }, + "previous_page_url": { + "format": "uri", + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + } + }, + "type": "object" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "Beta" + ] + }, + "post": { + "description": "Triggers a new Execution for the Flow", + "parameters": [ + { + "description": "The SID of the Excecution's Flow.", + "in": "path", + "name": "FlowSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "schema": { + "properties": { + "From": { + "description": "The Twilio phone number to send messages or initiate calls from during the Flow's Execution. Available as variable `{{flow.channel.address}}`.", + "type": "string" + }, + "Parameters": { + "description": "JSON data that will be added to the Flow's context and that can be accessed as variables inside your Flow. For example, if you pass in `Parameters={\"name\":\"Zeke\"}`, a widget in your Flow can reference the variable `{{flow.data.name}}`, which returns \"Zeke\". Note: the JSON value must explicitly be passed as a string, not as a hash object. Depending on your particular HTTP library, you may need to add quotes or URL encode the JSON string.", + "type": "object" + }, + "To": { + "description": "The Contact phone number to start a Studio Flow Execution, available as variable `{{contact.channel.address}}`.", + "type": "string" + } + }, + "required": [ + "To", + "From" + ], + "type": "object" + } + } + } + }, + "responses": { + "201": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/studio.v2.flow.execution" + } + } + }, + "description": "Created" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "Beta" + ] + }, + "servers": [ + { + "url": "https://studio.twilio.com" + } + ], + "x-default-output-properties": [ + "sid", + "status", + "date_created" + ], + "x-path-type": "list" + }, + "/v2/Flows/{FlowSid}/Executions/{ExecutionSid}/Context": { + "description": "JSON context for executions", + "get": { + "description": "Retrieve the most recent context for an Execution.", + "parameters": [ + { + "description": "The SID of the Flow with the Execution context to fetch.", + "in": "path", + "name": "FlowSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The SID of the Execution context to fetch.", + "in": "path", + "name": "ExecutionSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FN[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/studio.v2.flow.execution.execution_context" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "Beta" + ] + }, + "servers": [ + { + "url": "https://studio.twilio.com" + } + ], + "x-default-output-properties": [ + "context" + ], + "x-path-type": "instance" + }, + "/v2/Flows/{FlowSid}/Executions/{ExecutionSid}/Steps": { + "description": "Individual steps within an execution", + "get": { + "description": "Retrieve a list of all Steps for an Execution.", + "parameters": [ + { + "description": "The SID of the Flow with the Steps to read.", + "in": "path", + "name": "FlowSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The SID of the Execution with the Steps to read.", + "in": "path", + "name": "ExecutionSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FN[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", + "in": "query", + "name": "PageSize", + "schema": { + "maximum": 1000, + "minimum": 1, + "type": "integer" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "properties": { + "meta": { + "properties": { + "first_page_url": { + "format": "uri", + "type": "string" + }, + "key": { + "type": "string" + }, + "next_page_url": { + "format": "uri", + "type": "string" + }, + "page": { + "type": "integer" + }, + "page_size": { + "type": "integer" + }, + "previous_page_url": { + "format": "uri", + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + }, + "steps": { + "items": { + "$ref": "#/components/schemas/studio.v2.flow.execution.execution_step" + }, + "type": "array" + } + }, + "type": "object" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "Beta" + ] + }, + "servers": [ + { + "url": "https://studio.twilio.com" + } + ], + "x-default-output-properties": [ + "sid", + "name", + "date_created" + ], + "x-path-type": "list" + }, + "/v2/Flows/{FlowSid}/Executions/{ExecutionSid}/Steps/{Sid}": { + "description": "Individual steps within an execution", + "get": { + "description": "Retrieve a Step.", + "parameters": [ + { + "description": "The SID of the Flow with the Step to fetch.", + "in": "path", + "name": "FlowSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The SID of the Execution resource with the Step to fetch.", + "in": "path", + "name": "ExecutionSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FN[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The SID of the ExecutionStep resource to fetch.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FT[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/studio.v2.flow.execution.execution_step" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "Beta" + ] + }, + "servers": [ + { + "url": "https://studio.twilio.com" + } + ], + "x-default-output-properties": [ + "sid", + "name", + "date_created" + ], + "x-path-type": "instance" + }, + "/v2/Flows/{FlowSid}/Executions/{ExecutionSid}/Steps/{StepSid}/Context": { + "description": "JSON context for an individual step within an execution", + "get": { + "description": "Retrieve the context for an Execution Step.", + "parameters": [ + { + "description": "The SID of the Flow with the Step to fetch.", + "in": "path", + "name": "FlowSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The SID of the Execution resource with the Step to fetch.", + "in": "path", + "name": "ExecutionSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FN[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The SID of the Step to fetch.", + "in": "path", + "name": "StepSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FT[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/studio.v2.flow.execution.execution_step.execution_step_context" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "Beta" + ] + }, + "servers": [ + { + "url": "https://studio.twilio.com" + } + ], + "x-default-output-properties": [ + "context" + ], + "x-path-type": "instance" + }, + "/v2/Flows/{FlowSid}/Executions/{Sid}": { + "delete": { + "description": "Delete the Execution and all Steps relating to it.", + "parameters": [ + { + "description": "The SID of the Flow with the Execution resources to delete.", + "in": "path", + "name": "FlowSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The SID of the Execution resource to delete.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FN[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "responses": { + "204": { + "description": "The resource was deleted successfully." + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "Beta" + ] + }, + "description": "Executions of Studio flows", + "get": { + "description": "Retrieve an Execution", + "parameters": [ + { + "description": "The SID of the Flow with the Execution resource to fetch", + "in": "path", + "name": "FlowSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The SID of the Execution resource to fetch.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FN[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/studio.v2.flow.execution" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "Beta" + ] + }, + "post": { + "description": "Update the status of an Execution to `ended`.", + "parameters": [ + { + "description": "The SID of the Flow with the Execution resources to update.", + "in": "path", + "name": "FlowSid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "The SID of the Execution resource to update.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FN[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "schema": { + "properties": { + "Status": { + "description": "The status of the Execution. Can only be `ended`.", + "enum": [ + "active", + "ended" + ], + "type": "string" + } + }, + "required": [ + "Status" + ], + "type": "object" + } + } + } + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/studio.v2.flow.execution" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "Beta" + ] + }, + "servers": [ + { + "url": "https://studio.twilio.com" + } + ], + "x-default-output-properties": [ + "sid", + "status", + "date_created" + ], + "x-path-type": "instance" + }, + "/v2/Flows/{Sid}": { + "delete": { + "description": "Delete a specific Flow.", + "parameters": [ + { + "description": "The SID of the Flow resource to delete.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "responses": { + "204": { + "description": "The resource was deleted successfully." + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "Beta" + ] + }, + "description": "Studio flows", + "get": { + "description": "Retrieve a specific Flow.", + "parameters": [ + { + "description": "The SID of the Flow resource to fetch.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/studio.v2.flow" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "Beta" + ] + }, + "post": { + "description": "Update a Flow.", + "parameters": [ + { + "description": "The SID of the Flow resource to fetch.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "schema": { + "properties": { + "CommitMessage": { + "description": "Description on change made in the revision.", + "type": "string" + }, + "Definition": { + "description": "JSON representation of flow definition.", + "type": "object" + }, + "FriendlyName": { + "description": "The string that you assigned to describe the Flow.", + "type": "string" + }, + "Status": { + "description": "The status of the Flow. Can be: `draft` or `published`.", + "enum": [ + "draft", + "published" + ], + "type": "string" + } + }, + "required": [ + "Status" + ], + "type": "object" + } + } + } + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/studio.v2.flow" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "Beta" + ] + }, + "servers": [ + { + "url": "https://studio.twilio.com" + } + ], + "x-default-output-properties": [ + "sid", + "friendly_name", + "status", + "revision" + ], + "x-path-type": "instance" + }, + "/v2/Flows/{Sid}/Revisions": { + "description": "Studio flows revisions", + "get": { + "description": "Retrieve a list of all Flows revisions.", + "parameters": [ + { + "description": "The SID of the Flow resource to fetch.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "How many resources to return in each list page. The default is 50, and the maximum is 1000.", + "in": "query", + "name": "PageSize", + "schema": { + "maximum": 1000, + "minimum": 1, + "type": "integer" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "properties": { + "meta": { + "properties": { + "first_page_url": { + "format": "uri", + "type": "string" + }, + "key": { + "type": "string" + }, + "next_page_url": { + "format": "uri", + "type": "string" + }, + "page": { + "type": "integer" + }, + "page_size": { + "type": "integer" + }, + "previous_page_url": { + "format": "uri", + "type": "string" + }, + "url": { + "format": "uri", + "type": "string" + } + }, + "type": "object" + }, + "revisions": { + "items": { + "$ref": "#/components/schemas/studio.v2.flow.flow_revision" + }, + "type": "array" + } + }, + "type": "object" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "Beta" + ] + }, + "servers": [ + { + "url": "https://studio.twilio.com" + } + ], + "x-default-output-properties": [ + "sid", + "friendly_name", + "status", + "revision" + ], + "x-path-type": "list" + }, + "/v2/Flows/{Sid}/Revisions/{Revision}": { + "description": "Studio flows revisions", + "get": { + "description": "Retrieve a specific Flow revision.", + "parameters": [ + { + "description": "The SID of the Flow resource to fetch.", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + } + }, + { + "description": "Specific Revision number or can be `LatestPublished` and `LatestRevision`.", + "in": "path", + "name": "Revision", + "required": true, + "schema": { + "type": "string" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/studio.v2.flow.flow_revision" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "Beta" + ] + }, + "servers": [ + { + "url": "https://studio.twilio.com" + } + ], + "x-default-output-properties": [ + "sid", + "friendly_name", + "status", + "revision" + ], + "x-path-type": "instance" + }, + "/v2/Flows/{Sid}/TestUsers": { + "description": "TODO: Resource-level docs", + "get": { + "description": "", + "parameters": [ + { + "description": "", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/studio.v2.flow.test_user" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "Beta" + ] + }, + "post": { + "description": "", + "parameters": [ + { + "description": "", + "in": "path", + "name": "Sid", + "required": true, + "schema": { + "maxLength": 34, + "minLength": 34, + "pattern": "^FW[0-9a-fA-F]{32}$", + "type": "string" + } + } + ], + "requestBody": { + "content": { + "application/x-www-form-urlencoded": { + "schema": { + "properties": { + "TestUsers": { + "description": "", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "required": [ + "TestUsers" + ], + "type": "object" + } + } + } + }, + "responses": { + "200": { + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/studio.v2.flow.test_user" + } + } + }, + "description": "OK" + } + }, + "security": [ + { + "accountSid_authToken": [] + } + ], + "tags": [ + "Beta" + ] + }, + "servers": [ + { + "url": "https://studio.twilio.com" + } + ], + "x-default-output-properties": [ + "test_users" + ], + "x-path-type": "instance" + } + }, + "tags": [ + { + "description": "PLEASE NOTE that this is a Beta product that is subject to change. Use it with caution.", + "name": "Beta" + } + ] +} \ No newline at end of file diff --git a/spec/json/twilio_supersim.json b/spec/json/twilio_supersim_v1.json similarity index 100% rename from spec/json/twilio_supersim.json rename to spec/json/twilio_supersim_v1.json diff --git a/spec/json/twilio_sync.json b/spec/json/twilio_sync_v1.json similarity index 100% rename from spec/json/twilio_sync.json rename to spec/json/twilio_sync_v1.json diff --git a/spec/json/twilio_taskrouter.json b/spec/json/twilio_taskrouter_v1.json similarity index 100% rename from spec/json/twilio_taskrouter.json rename to spec/json/twilio_taskrouter_v1.json diff --git a/spec/json/twilio_trunking.json b/spec/json/twilio_trunking_v1.json similarity index 100% rename from spec/json/twilio_trunking.json rename to spec/json/twilio_trunking_v1.json diff --git a/spec/json/twilio_verify.json b/spec/json/twilio_verify_v2.json similarity index 100% rename from spec/json/twilio_verify.json rename to spec/json/twilio_verify_v2.json diff --git a/spec/json/twilio_video.json b/spec/json/twilio_video_v1.json similarity index 100% rename from spec/json/twilio_video.json rename to spec/json/twilio_video_v1.json diff --git a/spec/json/twilio_voice.json b/spec/json/twilio_voice_v1.json similarity index 100% rename from spec/json/twilio_voice.json rename to spec/json/twilio_voice_v1.json diff --git a/spec/json/twilio_wireless.json b/spec/json/twilio_wireless_v1.json similarity index 100% rename from spec/json/twilio_wireless.json rename to spec/json/twilio_wireless_v1.json diff --git a/spec/yaml/twilio_accounts.yaml b/spec/yaml/twilio_accounts_v1.yaml similarity index 100% rename from spec/yaml/twilio_accounts.yaml rename to spec/yaml/twilio_accounts_v1.yaml diff --git a/spec/yaml/twilio_api.yaml b/spec/yaml/twilio_api_v2010.yaml similarity index 100% rename from spec/yaml/twilio_api.yaml rename to spec/yaml/twilio_api_v2010.yaml diff --git a/spec/yaml/twilio_autopilot.yaml b/spec/yaml/twilio_autopilot_v1.yaml similarity index 100% rename from spec/yaml/twilio_autopilot.yaml rename to spec/yaml/twilio_autopilot_v1.yaml diff --git a/spec/yaml/twilio_bulkexports.yaml b/spec/yaml/twilio_bulkexports_v1.yaml similarity index 100% rename from spec/yaml/twilio_bulkexports.yaml rename to spec/yaml/twilio_bulkexports_v1.yaml diff --git a/spec/yaml/twilio_chat_v1.yaml b/spec/yaml/twilio_chat_v1.yaml new file mode 100644 index 00000000..25512aee --- /dev/null +++ b/spec/yaml/twilio_chat_v1.yaml @@ -0,0 +1,2876 @@ +components: + schemas: + chat.v1.credential: + properties: + account_sid: + maxLength: 34 + minLength: 34 + pattern: ^AC[0-9a-fA-F]{32}$ + type: string + date_created: + format: date-time + type: string + date_updated: + format: date-time + type: string + friendly_name: + type: string + sandbox: + type: string + sid: + maxLength: 34 + minLength: 34 + pattern: ^CR[0-9a-fA-F]{32}$ + type: string + type: + enum: + - gcm + - apn + - fcm + type: string + url: + format: uri + type: string + type: object + chat.v1.service: + properties: + account_sid: + maxLength: 34 + minLength: 34 + pattern: ^AC[0-9a-fA-F]{32}$ + type: string + consumption_report_interval: + type: integer + date_created: + format: date-time + type: string + date_updated: + format: date-time + type: string + default_channel_creator_role_sid: + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + default_channel_role_sid: + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + default_service_role_sid: + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + friendly_name: + type: string + limits: + type: object + links: + type: object + notifications: + type: object + post_webhook_url: + type: string + pre_webhook_url: + type: string + reachability_enabled: + type: boolean + read_status_enabled: + type: boolean + sid: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + typing_indicator_timeout: + type: integer + url: + format: uri + type: string + webhook_filters: + items: + type: string + type: array + webhook_method: + type: string + webhooks: + type: object + type: object + chat.v1.service.channel: + properties: + account_sid: + maxLength: 34 + minLength: 34 + pattern: ^AC[0-9a-fA-F]{32}$ + type: string + attributes: + type: string + created_by: + type: string + date_created: + format: date-time + type: string + date_updated: + format: date-time + type: string + friendly_name: + type: string + links: + type: object + members_count: + type: integer + messages_count: + type: integer + service_sid: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + sid: + maxLength: 34 + minLength: 34 + pattern: ^CH[0-9a-fA-F]{32}$ + type: string + type: + enum: + - public + - private + type: string + unique_name: + type: string + url: + format: uri + type: string + type: object + chat.v1.service.channel.invite: + properties: + account_sid: + maxLength: 34 + minLength: 34 + pattern: ^AC[0-9a-fA-F]{32}$ + type: string + channel_sid: + maxLength: 34 + minLength: 34 + pattern: ^CH[0-9a-fA-F]{32}$ + type: string + created_by: + type: string + date_created: + format: date-time + type: string + date_updated: + format: date-time + type: string + identity: + type: string + role_sid: + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + service_sid: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + sid: + maxLength: 34 + minLength: 34 + pattern: ^IN[0-9a-fA-F]{32}$ + type: string + url: + format: uri + type: string + type: object + chat.v1.service.channel.member: + properties: + account_sid: + maxLength: 34 + minLength: 34 + pattern: ^AC[0-9a-fA-F]{32}$ + type: string + channel_sid: + maxLength: 34 + minLength: 34 + pattern: ^CH[0-9a-fA-F]{32}$ + type: string + date_created: + format: date-time + type: string + date_updated: + format: date-time + type: string + identity: + type: string + last_consumed_message_index: + nullable: true + type: integer + last_consumption_timestamp: + format: date-time + type: string + role_sid: + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + service_sid: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + sid: + maxLength: 34 + minLength: 34 + pattern: ^MB[0-9a-fA-F]{32}$ + type: string + url: + format: uri + type: string + type: object + chat.v1.service.channel.message: + properties: + account_sid: + maxLength: 34 + minLength: 34 + pattern: ^AC[0-9a-fA-F]{32}$ + type: string + attributes: + type: string + body: + type: string + channel_sid: + maxLength: 34 + minLength: 34 + pattern: ^CH[0-9a-fA-F]{32}$ + type: string + date_created: + format: date-time + type: string + date_updated: + format: date-time + type: string + from: + type: string + index: + type: integer + service_sid: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + sid: + maxLength: 34 + minLength: 34 + pattern: ^IM[0-9a-fA-F]{32}$ + type: string + to: + maxLength: 34 + minLength: 34 + pattern: ^CH[0-9a-fA-F]{32}$ + type: string + url: + format: uri + type: string + was_edited: + type: boolean + type: object + chat.v1.service.role: + properties: + account_sid: + maxLength: 34 + minLength: 34 + pattern: ^AC[0-9a-fA-F]{32}$ + type: string + date_created: + format: date-time + type: string + date_updated: + format: date-time + type: string + friendly_name: + type: string + permissions: + items: + type: string + type: array + service_sid: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + sid: + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + type: + enum: + - channel + - deployment + type: string + url: + format: uri + type: string + type: object + chat.v1.service.user: + properties: + account_sid: + maxLength: 34 + minLength: 34 + pattern: ^AC[0-9a-fA-F]{32}$ + type: string + attributes: + type: string + date_created: + format: date-time + type: string + date_updated: + format: date-time + type: string + friendly_name: + type: string + identity: + type: string + is_notifiable: + type: boolean + is_online: + type: boolean + joined_channels_count: + type: integer + links: + type: object + role_sid: + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + service_sid: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + sid: + maxLength: 34 + minLength: 34 + pattern: ^US[0-9a-fA-F]{32}$ + type: string + url: + format: uri + type: string + type: object + chat.v1.service.user.user_channel: + properties: + account_sid: + maxLength: 34 + minLength: 34 + pattern: ^AC[0-9a-fA-F]{32}$ + type: string + channel_sid: + maxLength: 34 + minLength: 34 + pattern: ^CH[0-9a-fA-F]{32}$ + type: string + last_consumed_message_index: + nullable: true + type: integer + links: + type: object + member_sid: + maxLength: 34 + minLength: 34 + pattern: ^MB[0-9a-fA-F]{32}$ + type: string + service_sid: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + status: + enum: + - joined + - invited + - not_participating + type: string + unread_messages_count: + nullable: true + type: integer + type: object + securitySchemes: + accountSid_authToken: + scheme: basic + type: http +info: + contact: + email: support@twilio.com + name: Twilio Support + url: https://support.twilio.com + description: This is the public Twilio REST API. + license: + name: Apache 2.0 + url: https://www.apache.org/licenses/LICENSE-2.0.html + termsOfService: https://www.twilio.com/legal/tos + title: Twilio - Chat + version: 1.3.0 +openapi: 3.0.1 +paths: + /v1/Credentials: + description: Credentials for push notifications channels + get: + description: '' + parameters: + - description: How many resources to return in each list page. The default is + 50, and the maximum is 1000. + in: query + name: PageSize + schema: + maximum: 1000 + minimum: 1 + type: integer + responses: + 200: + content: + application/json: + schema: + properties: + credentials: + items: + $ref: '#/components/schemas/chat.v1.credential' + type: array + meta: + properties: + first_page_url: + format: uri + type: string + key: + type: string + next_page_url: + format: uri + type: string + page: + type: integer + page_size: + type: integer + previous_page_url: + format: uri + type: string + url: + format: uri + type: string + type: object + type: object + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + post: + description: '' + requestBody: + content: + application/x-www-form-urlencoded: + schema: + properties: + ApiKey: + description: '[GCM only] The API key for the project that was obtained + from the Google Developer console for your GCM Service application + credential.' + type: string + Certificate: + description: "[APN only] The URL encoded representation of the certificate.\ + \ For example, \n`-----BEGIN CERTIFICATE-----\nMIIFnTCCBIWgAwIBAgIIAjy9H849+E8wDQYJKoZIhvcNAQEFBQAwgZYxCzAJBgNV.....A==\n\ + -----END CERTIFICATE-----`" + type: string + FriendlyName: + description: A descriptive string that you create to describe the + new resource. It can be up to 64 characters long. + type: string + PrivateKey: + description: '[APN only] The URL encoded representation of the private + key. For example, + + `-----BEGIN RSA PRIVATE KEY----- + + MIIEpQIBAAKCAQEAuyf/lNrH9ck8DmNyo3fGgvCI1l9s+cmBY3WIz+cUDqmxiieR. + + -----END RSA PRIVATE KEY-----`' + type: string + Sandbox: + description: '[APN only] Whether to send the credential to sandbox + APNs. Can be `true` to send to sandbox APNs or `false` to send + to production.' + type: boolean + Secret: + description: '[FCM only] The **Server key** of your project from + the Firebase console, found under Settings / Cloud messaging.' + type: string + Type: + description: 'The type of push-notification service the credential + is for. Can be: `gcm`, `fcm`, or `apn`.' + enum: + - gcm + - apn + - fcm + type: string + required: + - Type + type: object + responses: + 201: + content: + application/json: + schema: + $ref: '#/components/schemas/chat.v1.credential' + description: Created + security: + - accountSid_authToken: [] + tags: + - GA + servers: + - url: https://chat.twilio.com + x-default-output-properties: &id001 + - sid + - friendly_name + - type + x-path-type: list + /v1/Credentials/{Sid}: + delete: + description: '' + parameters: + - description: The Twilio-provided string that uniquely identifies the Credential + resource to delete. + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^CR[0-9a-fA-F]{32}$ + type: string + responses: + 204: + description: The resource was deleted successfully. + security: + - accountSid_authToken: [] + tags: + - GA + description: Credentials for push notifications channels + get: + description: '' + parameters: + - description: The Twilio-provided string that uniquely identifies the Credential + resource to fetch. + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^CR[0-9a-fA-F]{32}$ + type: string + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/chat.v1.credential' + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + post: + description: '' + parameters: + - description: The Twilio-provided string that uniquely identifies the Credential + resource to update. + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^CR[0-9a-fA-F]{32}$ + type: string + requestBody: + content: + application/x-www-form-urlencoded: + schema: + properties: + ApiKey: + description: '[GCM only] The API key for the project that was obtained + from the Google Developer console for your GCM Service application + credential.' + type: string + Certificate: + description: "[APN only] The URL encoded representation of the certificate.\ + \ For example, \n`-----BEGIN CERTIFICATE-----\nMIIFnTCCBIWgAwIBAgIIAjy9H849+E8wDQYJKoZIhvcNAQEFBQAwgZYxCzAJBgNV.....A==\n\ + -----END CERTIFICATE-----`" + type: string + FriendlyName: + description: A descriptive string that you create to describe the + resource. It can be up to 64 characters long. + type: string + PrivateKey: + description: '[APN only] The URL encoded representation of the private + key. For example, + + `-----BEGIN RSA PRIVATE KEY----- + + MIIEpQIBAAKCAQEAuyf/lNrH9ck8DmNyo3fGgvCI1l9s+cmBY3WIz+cUDqmxiieR. + + -----END RSA PRIVATE KEY-----`' + type: string + Sandbox: + description: '[APN only] Whether to send the credential to sandbox + APNs. Can be `true` to send to sandbox APNs or `false` to send + to production.' + type: boolean + Secret: + description: '[FCM only] The **Server key** of your project from + the Firebase console, found under Settings / Cloud messaging.' + type: string + type: object + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/chat.v1.credential' + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + servers: + - url: https://chat.twilio.com + x-default-output-properties: *id001 + x-path-type: instance + /v1/Services: + description: Top level scope for all chat resources + get: + description: '' + parameters: + - description: How many resources to return in each list page. The default is + 50, and the maximum is 1000. + in: query + name: PageSize + schema: + maximum: 1000 + minimum: 1 + type: integer + responses: + 200: + content: + application/json: + schema: + properties: + meta: + properties: + first_page_url: + format: uri + type: string + key: + type: string + next_page_url: + format: uri + type: string + page: + type: integer + page_size: + type: integer + previous_page_url: + format: uri + type: string + url: + format: uri + type: string + type: object + services: + items: + $ref: '#/components/schemas/chat.v1.service' + type: array + type: object + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + post: + description: '' + requestBody: + content: + application/x-www-form-urlencoded: + schema: + properties: + FriendlyName: + description: A descriptive string that you create to describe the + resource. It can be up to 64 characters long. + type: string + required: + - FriendlyName + type: object + responses: + 201: + content: + application/json: + schema: + $ref: '#/components/schemas/chat.v1.service' + description: Created + security: + - accountSid_authToken: [] + tags: + - GA + servers: + - url: https://chat.twilio.com + x-default-output-properties: &id008 + - sid + - friendly_name + - date_created + x-path-type: list + /v1/Services/{ServiceSid}/Channels: + description: Channels represent chat rooms + get: + description: '' + parameters: + - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) + to read the resources from. + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: 'The visibility of the Channels to read. Can be: `public` or + `private` and defaults to `public`.' + in: query + name: Type + schema: + items: + enum: + - public + - private + type: string + type: array + - description: How many resources to return in each list page. The default is + 50, and the maximum is 1000. + in: query + name: PageSize + schema: + maximum: 1000 + minimum: 1 + type: integer + responses: + 200: + content: + application/json: + schema: + properties: + channels: + items: + $ref: '#/components/schemas/chat.v1.service.channel' + type: array + meta: + properties: + first_page_url: + format: uri + type: string + key: + type: string + next_page_url: + format: uri + type: string + page: + type: integer + page_size: + type: integer + previous_page_url: + format: uri + type: string + url: + format: uri + type: string + type: object + type: object + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + post: + description: '' + parameters: + - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) + to create the resource under. + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + requestBody: + content: + application/x-www-form-urlencoded: + schema: + properties: + Attributes: + description: A valid JSON string that contains application-specific + data. + type: string + FriendlyName: + description: A descriptive string that you create to describe the + new resource. It can be up to 64 characters long. + type: string + Type: + description: 'The visibility of the channel. Can be: `public` or + `private` and defaults to `public`.' + enum: + - public + - private + type: string + UniqueName: + description: An application-defined string that uniquely identifies + the resource. It can be used to address the resource in place + of the resource's `sid` in the URL. This value must be 64 characters + or less in length and be unique within the Service. + type: string + type: object + responses: + 201: + content: + application/json: + schema: + $ref: '#/components/schemas/chat.v1.service.channel' + description: Created + security: + - accountSid_authToken: [] + tags: + - GA + servers: + - url: https://chat.twilio.com + x-default-output-properties: &id005 + - sid + - unique_name + - friendly_name + x-path-type: list + /v1/Services/{ServiceSid}/Channels/{ChannelSid}/Invites: + description: Pending invitations to users to become channel members + get: + description: '' + parameters: + - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) + to read the resources from. + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: The SID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) + the resources to read belong to. + in: path + name: ChannelSid + required: true + schema: + type: string + - description: The [User](https://www.twilio.com/docs/api/chat/rest/v1/user)'s + `identity` value of the resources to read. See [access tokens](https://www.twilio.com/docs/api/chat/guides/create-tokens) + for more details. + in: query + name: Identity + schema: + items: + type: string + type: array + - description: How many resources to return in each list page. The default is + 50, and the maximum is 1000. + in: query + name: PageSize + schema: + maximum: 1000 + minimum: 1 + type: integer + responses: + 200: + content: + application/json: + schema: + properties: + invites: + items: + $ref: '#/components/schemas/chat.v1.service.channel.invite' + type: array + meta: + properties: + first_page_url: + format: uri + type: string + key: + type: string + next_page_url: + format: uri + type: string + page: + type: integer + page_size: + type: integer + previous_page_url: + format: uri + type: string + url: + format: uri + type: string + type: object + type: object + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + post: + description: '' + parameters: + - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) + to create the resource under. + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: The SID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) + the new resource belongs to. + in: path + name: ChannelSid + required: true + schema: + type: string + requestBody: + content: + application/x-www-form-urlencoded: + schema: + properties: + Identity: + description: The `identity` value that uniquely identifies the new + resource's [User](https://www.twilio.com/docs/api/chat/rest/v1/user) + within the [Service](https://www.twilio.com/docs/api/chat/rest/v1/service). + See [access tokens](https://www.twilio.com/docs/api/chat/guides/create-tokens) + for more info. + type: string + RoleSid: + description: The SID of the [Role](https://www.twilio.com/docs/api/chat/rest/roles) + assigned to the new member. + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + required: + - Identity + type: object + responses: + 201: + content: + application/json: + schema: + $ref: '#/components/schemas/chat.v1.service.channel.invite' + description: Created + security: + - accountSid_authToken: [] + tags: + - GA + servers: + - url: https://chat.twilio.com + x-default-output-properties: &id002 + - sid + - identity + - date_created + x-path-type: list + /v1/Services/{ServiceSid}/Channels/{ChannelSid}/Invites/{Sid}: + delete: + description: '' + parameters: + - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) + to delete the resource from. + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: The SID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) + the resource to delete belongs to. + in: path + name: ChannelSid + required: true + schema: + type: string + - description: The Twilio-provided string that uniquely identifies the Invite + resource to delete. + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IN[0-9a-fA-F]{32}$ + type: string + responses: + 204: + description: The resource was deleted successfully. + security: + - accountSid_authToken: [] + tags: + - GA + description: Pending invitations to users to become channel members + get: + description: '' + parameters: + - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) + to fetch the resource from. + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: The SID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) + the resource to fetch belongs to. + in: path + name: ChannelSid + required: true + schema: + type: string + - description: The Twilio-provided string that uniquely identifies the Invite + resource to fetch. + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IN[0-9a-fA-F]{32}$ + type: string + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/chat.v1.service.channel.invite' + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + servers: + - url: https://chat.twilio.com + x-default-output-properties: *id002 + x-path-type: instance + /v1/Services/{ServiceSid}/Channels/{ChannelSid}/Members: + description: Users joined to specific channels + get: + description: '' + parameters: + - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) + to read the resources from. + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) + the members to read belong to. Can be the Channel resource's `sid` or `unique_name` + value. + in: path + name: ChannelSid + required: true + schema: + type: string + - description: The [User](https://www.twilio.com/docs/api/chat/rest/v1/user)'s + `identity` value of the resources to read. See [access tokens](https://www.twilio.com/docs/api/chat/guides/create-tokens) + for more details. + in: query + name: Identity + schema: + items: + type: string + type: array + - description: How many resources to return in each list page. The default is + 50, and the maximum is 1000. + in: query + name: PageSize + schema: + maximum: 1000 + minimum: 1 + type: integer + responses: + 200: + content: + application/json: + schema: + properties: + members: + items: + $ref: '#/components/schemas/chat.v1.service.channel.member' + type: array + meta: + properties: + first_page_url: + format: uri + type: string + key: + type: string + next_page_url: + format: uri + type: string + page: + type: integer + page_size: + type: integer + previous_page_url: + format: uri + type: string + url: + format: uri + type: string + type: object + type: object + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + post: + description: '' + parameters: + - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) + to create the resource under. + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) + the new member belongs to. Can be the Channel resource's `sid` or `unique_name`. + in: path + name: ChannelSid + required: true + schema: + type: string + requestBody: + content: + application/x-www-form-urlencoded: + schema: + properties: + Identity: + description: The `identity` value that uniquely identifies the new + resource's [User](https://www.twilio.com/docs/api/chat/rest/v1/user) + within the [Service](https://www.twilio.com/docs/api/chat/rest/services). + See [access tokens](https://www.twilio.com/docs/api/chat/guides/create-tokens) + for more details. + type: string + RoleSid: + description: The SID of the [Role](https://www.twilio.com/docs/api/chat/rest/roles) + to assign to the member. The default roles are those specified + on the [Service](https://www.twilio.com/docs/chat/api/services). + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + required: + - Identity + type: object + responses: + 201: + content: + application/json: + schema: + $ref: '#/components/schemas/chat.v1.service.channel.member' + description: Created + security: + - accountSid_authToken: [] + tags: + - GA + servers: + - url: https://chat.twilio.com + x-default-output-properties: &id003 + - sid + - identity + - date_created + x-path-type: list + /v1/Services/{ServiceSid}/Channels/{ChannelSid}/Members/{Sid}: + delete: + description: '' + parameters: + - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) + to delete the resource from. + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) + the message belongs to. Can be the Channel's `sid` or `unique_name`. + in: path + name: ChannelSid + required: true + schema: + type: string + - description: The Twilio-provided string that uniquely identifies the Member + resource to delete. + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^MB[0-9a-fA-F]{32}$ + type: string + responses: + 204: + description: The resource was deleted successfully. + security: + - accountSid_authToken: [] + tags: + - GA + description: Users joined to specific channels + get: + description: '' + parameters: + - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) + to fetch the resource from. + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) + the member to fetch belongs to. Can be the Channel resource's `sid` or `unique_name` + value. + in: path + name: ChannelSid + required: true + schema: + type: string + - description: The Twilio-provided string that uniquely identifies the Member + resource to fetch. + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^MB[0-9a-fA-F]{32}$ + type: string + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/chat.v1.service.channel.member' + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + post: + description: '' + parameters: + - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) + to update the resource from. + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) + the member to update belongs to. Can be the Channel resource's `sid` or + `unique_name`. + in: path + name: ChannelSid + required: true + schema: + type: string + - description: The Twilio-provided string that uniquely identifies the Member + resource to update. + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^MB[0-9a-fA-F]{32}$ + type: string + requestBody: + content: + application/x-www-form-urlencoded: + schema: + properties: + LastConsumedMessageIndex: + description: The index of the last [Message](https://www.twilio.com/docs/api/chat/rest/messages) + that the Member has read within the [Channel](https://www.twilio.com/docs/api/chat/rest/channels). + nullable: true + type: integer + RoleSid: + description: The SID of the [Role](https://www.twilio.com/docs/api/chat/rest/roles) + to assign to the member. The default roles are those specified + on the [Service](https://www.twilio.com/docs/chat/api/services). + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + type: object + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/chat.v1.service.channel.member' + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + servers: + - url: https://chat.twilio.com + x-default-output-properties: *id003 + x-path-type: instance + /v1/Services/{ServiceSid}/Channels/{ChannelSid}/Messages: + description: Individual chat messages + get: + description: '' + parameters: + - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) + to read the resources from. + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) + the message to read belongs to. Can be the Channel's `sid` or `unique_name`. + in: path + name: ChannelSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^CH[0-9a-fA-F]{32}$ + type: string + - description: 'The sort order of the returned messages. Can be: `asc` (ascending) + or `desc` (descending) with `asc` as the default.' + in: query + name: Order + schema: + enum: + - asc + - desc + type: string + - description: How many resources to return in each list page. The default is + 50, and the maximum is 1000. + in: query + name: PageSize + schema: + maximum: 1000 + minimum: 1 + type: integer + responses: + 200: + content: + application/json: + schema: + properties: + messages: + items: + $ref: '#/components/schemas/chat.v1.service.channel.message' + type: array + meta: + properties: + first_page_url: + format: uri + type: string + key: + type: string + next_page_url: + format: uri + type: string + page: + type: integer + page_size: + type: integer + previous_page_url: + format: uri + type: string + url: + format: uri + type: string + type: object + type: object + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + post: + description: '' + parameters: + - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) + to create the resource under. + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) + the new resource belongs to. Can be the Channel resource's `sid` or `unique_name`. + in: path + name: ChannelSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^CH[0-9a-fA-F]{32}$ + type: string + requestBody: + content: + application/x-www-form-urlencoded: + schema: + properties: + Attributes: + description: A valid JSON string that contains application-specific + data. + type: string + Body: + description: The message to send to the channel. Can also be an + empty string or `null`, which sets the value as an empty string. + You can send structured data in the body by serializing it as + a string. + type: string + From: + description: The [identity](https://www.twilio.com/docs/api/chat/guides/identity) + of the new message's author. The default value is `system`. + type: string + required: + - Body + type: object + responses: + 201: + content: + application/json: + schema: + $ref: '#/components/schemas/chat.v1.service.channel.message' + description: Created + security: + - accountSid_authToken: [] + tags: + - GA + servers: + - url: https://chat.twilio.com + x-default-output-properties: &id004 + - sid + - from + - to + - date_created + x-path-type: list + /v1/Services/{ServiceSid}/Channels/{ChannelSid}/Messages/{Sid}: + delete: + description: '' + parameters: + - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) + to delete the resource from. + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) + the message to delete belongs to. Can be the Channel resource's `sid` or + `unique_name`. + in: path + name: ChannelSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^CH[0-9a-fA-F]{32}$ + type: string + - description: The Twilio-provided string that uniquely identifies the Message + resource to delete. + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IM[0-9a-fA-F]{32}$ + type: string + responses: + 204: + description: The resource was deleted successfully. + security: + - accountSid_authToken: [] + tags: + - GA + description: Individual chat messages + get: + description: '' + parameters: + - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) + to fetch the resource from. + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) + the message to fetch belongs to. Can be the Channel's `sid` or `unique_name`. + in: path + name: ChannelSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^CH[0-9a-fA-F]{32}$ + type: string + - description: The Twilio-provided string that uniquely identifies the Message + resource to fetch. + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IM[0-9a-fA-F]{32}$ + type: string + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/chat.v1.service.channel.message' + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + post: + description: '' + parameters: + - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) + to update the resource from. + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) + the message belongs to. Can be the Channel's `sid` or `unique_name`. + in: path + name: ChannelSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^CH[0-9a-fA-F]{32}$ + type: string + - description: The Twilio-provided string that uniquely identifies the Message + resource to update. + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IM[0-9a-fA-F]{32}$ + type: string + requestBody: + content: + application/x-www-form-urlencoded: + schema: + properties: + Attributes: + description: A valid JSON string that contains application-specific + data. + type: string + Body: + description: The message to send to the channel. Can also be an + empty string or `null`, which sets the value as an empty string. + You can send structured data in the body by serializing it as + a string. + type: string + type: object + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/chat.v1.service.channel.message' + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + servers: + - url: https://chat.twilio.com + x-default-output-properties: *id004 + x-path-type: instance + /v1/Services/{ServiceSid}/Channels/{Sid}: + delete: + description: '' + parameters: + - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) + to delete the resource from. + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: The Twilio-provided string that uniquely identifies the Channel + resource to delete. + in: path + name: Sid + required: true + schema: + type: string + responses: + 204: + description: The resource was deleted successfully. + security: + - accountSid_authToken: [] + tags: + - GA + description: Channels represent chat rooms + get: + description: '' + parameters: + - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) + to fetch the resource from. + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: The Twilio-provided string that uniquely identifies the Channel + resource to fetch. + in: path + name: Sid + required: true + schema: + type: string + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/chat.v1.service.channel' + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + post: + description: '' + parameters: + - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) + to update the resource from. + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: The Twilio-provided string that uniquely identifies the Channel + resource to update. + in: path + name: Sid + required: true + schema: + type: string + requestBody: + content: + application/x-www-form-urlencoded: + schema: + properties: + Attributes: + description: A valid JSON string that contains application-specific + data. + type: string + FriendlyName: + description: A descriptive string that you create to describe the + resource. It can be up to 64 characters long. + type: string + UniqueName: + description: An application-defined string that uniquely identifies + the resource. It can be used to address the resource in place + of the resource's `sid` in the URL. This value must be 64 characters + or less in length and be unique within the Service. + type: string + type: object + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/chat.v1.service.channel' + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + servers: + - url: https://chat.twilio.com + x-default-output-properties: *id005 + x-path-type: instance + /v1/Services/{ServiceSid}/Roles: + description: Roles determining user or member permissions + get: + description: '' + parameters: + - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) + to read the resources from. + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: How many resources to return in each list page. The default is + 50, and the maximum is 1000. + in: query + name: PageSize + schema: + maximum: 1000 + minimum: 1 + type: integer + responses: + 200: + content: + application/json: + schema: + properties: + meta: + properties: + first_page_url: + format: uri + type: string + key: + type: string + next_page_url: + format: uri + type: string + page: + type: integer + page_size: + type: integer + previous_page_url: + format: uri + type: string + url: + format: uri + type: string + type: object + roles: + items: + $ref: '#/components/schemas/chat.v1.service.role' + type: array + type: object + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + post: + description: '' + parameters: + - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) + to create the resource under. + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + requestBody: + content: + application/x-www-form-urlencoded: + schema: + properties: + FriendlyName: + description: A descriptive string that you create to describe the + new resource. It can be up to 64 characters long. + type: string + Permission: + description: A permission that you grant to the new role. Only one + permission can be granted per parameter. To assign more than one + permission, repeat this parameter for each permission value. The + values for this parameter depend on the role's `type` and are + described in the documentation. + items: + type: string + type: array + Type: + description: 'The type of role. Can be: `channel` for [Channel](https://www.twilio.com/docs/chat/api/channels) + roles or `deployment` for [Service](https://www.twilio.com/docs/chat/api/services) + roles.' + enum: + - channel + - deployment + type: string + required: + - FriendlyName + - Type + - Permission + type: object + responses: + 201: + content: + application/json: + schema: + $ref: '#/components/schemas/chat.v1.service.role' + description: Created + security: + - accountSid_authToken: [] + tags: + - GA + servers: + - url: https://chat.twilio.com + x-default-output-properties: &id006 + - sid + - friendly_name + - type + x-path-type: list + /v1/Services/{ServiceSid}/Roles/{Sid}: + delete: + description: '' + parameters: + - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) + to delete the resource from. + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: The Twilio-provided string that uniquely identifies the Role + resource to delete. + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + responses: + 204: + description: The resource was deleted successfully. + security: + - accountSid_authToken: [] + tags: + - GA + description: Roles determining user or member permissions + get: + description: '' + parameters: + - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) + to fetch the resource from. + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: The Twilio-provided string that uniquely identifies the Role + resource to fetch. + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/chat.v1.service.role' + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + post: + description: '' + parameters: + - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) + to update the resource from. + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: The Twilio-provided string that uniquely identifies the Role + resource to update. + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + requestBody: + content: + application/x-www-form-urlencoded: + schema: + properties: + Permission: + description: A permission that you grant to the role. Only one permission + can be granted per parameter. To assign more than one permission, + repeat this parameter for each permission value. The values for + this parameter depend on the role's `type` and are described in + the documentation. + items: + type: string + type: array + required: + - Permission + type: object + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/chat.v1.service.role' + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + servers: + - url: https://chat.twilio.com + x-default-output-properties: *id006 + x-path-type: instance + /v1/Services/{ServiceSid}/Users: + description: Unique chat users within a chat service + get: + description: '' + parameters: + - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) + to read the resources from. + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: How many resources to return in each list page. The default is + 50, and the maximum is 1000. + in: query + name: PageSize + schema: + maximum: 1000 + minimum: 1 + type: integer + responses: + 200: + content: + application/json: + schema: + properties: + meta: + properties: + first_page_url: + format: uri + type: string + key: + type: string + next_page_url: + format: uri + type: string + page: + type: integer + page_size: + type: integer + previous_page_url: + format: uri + type: string + url: + format: uri + type: string + type: object + users: + items: + $ref: '#/components/schemas/chat.v1.service.user' + type: array + type: object + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + post: + description: '' + parameters: + - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) + to create the resource under. + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + requestBody: + content: + application/x-www-form-urlencoded: + schema: + properties: + Attributes: + description: A valid JSON string that contains application-specific + data. + type: string + FriendlyName: + description: A descriptive string that you create to describe the + new resource. This value is often used for display purposes. + type: string + Identity: + description: The `identity` value that uniquely identifies the new + resource's [User](https://www.twilio.com/docs/api/chat/rest/v1/user) + within the [Service](https://www.twilio.com/docs/api/chat/rest/v1/service). + This value is often a username or email address. See the Identity + documentation for more details. + type: string + RoleSid: + description: The SID of the [Role](https://www.twilio.com/docs/api/chat/rest/roles) + assigned to the new User. + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + required: + - Identity + type: object + responses: + 201: + content: + application/json: + schema: + $ref: '#/components/schemas/chat.v1.service.user' + description: Created + security: + - accountSid_authToken: [] + tags: + - GA + servers: + - url: https://chat.twilio.com + x-default-output-properties: &id007 + - sid + - friendly_name + - date_created + x-path-type: list + /v1/Services/{ServiceSid}/Users/{Sid}: + delete: + description: '' + parameters: + - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) + to delete the resource from. + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: The Twilio-provided string that uniquely identifies the User + resource to delete. + in: path + name: Sid + required: true + schema: + type: string + responses: + 204: + description: The resource was deleted successfully. + security: + - accountSid_authToken: [] + tags: + - GA + description: Unique chat users within a chat service + get: + description: '' + parameters: + - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) + to fetch the resource from. + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: The Twilio-provided string that uniquely identifies the User + resource to fetch. + in: path + name: Sid + required: true + schema: + type: string + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/chat.v1.service.user' + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + post: + description: '' + parameters: + - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) + to update the resource from. + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: The Twilio-provided string that uniquely identifies the User + resource to update. + in: path + name: Sid + required: true + schema: + type: string + requestBody: + content: + application/x-www-form-urlencoded: + schema: + properties: + Attributes: + description: A valid JSON string that contains application-specific + data. + type: string + FriendlyName: + description: A descriptive string that you create to describe the + resource. It is often used for display purposes. + type: string + RoleSid: + description: The SID of the [Role](https://www.twilio.com/docs/api/chat/rest/roles) + assigned to this user. + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + type: object + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/chat.v1.service.user' + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + servers: + - url: https://chat.twilio.com + x-default-output-properties: *id007 + x-path-type: instance + /v1/Services/{ServiceSid}/Users/{UserSid}/Channels: + description: 'TODO: Resource-level docs' + get: + description: List all Channels for a given User. + parameters: + - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) + to read the resources from. + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: The SID of the [User](https://www.twilio.com/docs/api/chat/rest/users) + to read the User Channel resources from. + in: path + name: UserSid + required: true + schema: + type: string + - description: How many resources to return in each list page. The default is + 50, and the maximum is 1000. + in: query + name: PageSize + schema: + maximum: 1000 + minimum: 1 + type: integer + responses: + 200: + content: + application/json: + schema: + properties: + channels: + items: + $ref: '#/components/schemas/chat.v1.service.user.user_channel' + type: array + meta: + properties: + first_page_url: + format: uri + type: string + key: + type: string + next_page_url: + format: uri + type: string + page: + type: integer + page_size: + type: integer + previous_page_url: + format: uri + type: string + url: + format: uri + type: string + type: object + type: object + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + servers: + - url: https://chat.twilio.com + x-default-output-properties: + - channel_sid + - status + x-path-type: list + /v1/Services/{Sid}: + delete: + description: '' + parameters: + - description: The Twilio-provided string that uniquely identifies the Service + resource to delete. + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + responses: + 204: + description: The resource was deleted successfully. + security: + - accountSid_authToken: [] + tags: + - GA + description: Top level scope for all chat resources + get: + description: '' + parameters: + - description: The Twilio-provided string that uniquely identifies the Service + resource to fetch. + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/chat.v1.service' + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + post: + description: '' + parameters: + - description: The Twilio-provided string that uniquely identifies the Service + resource to update. + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + requestBody: + content: + application/x-www-form-urlencoded: + schema: + properties: + ConsumptionReportInterval: + description: DEPRECATED. The interval in seconds between consumption + reports submission batches from client endpoints. + type: integer + DefaultChannelCreatorRoleSid: + description: The channel role assigned to a channel creator when + they join a new channel. See the [Roles endpoint](https://www.twilio.com/docs/chat/api/roles) + for more details. + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + DefaultChannelRoleSid: + description: The channel role assigned to users when they are added + to a channel. See the [Roles endpoint](https://www.twilio.com/docs/chat/api/roles) + for more details. + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + DefaultServiceRoleSid: + description: The service role assigned to users when they are added + to the service. See the [Roles endpoint](https://www.twilio.com/docs/chat/api/roles) + for more details. + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + FriendlyName: + description: A descriptive string that you create to describe the + resource. It can be up to 64 characters long. + type: string + Limits.ChannelMembers: + description: The maximum number of Members that can be added to + Channels within this Service. Can be up to 1,000. + type: integer + Limits.UserChannels: + description: The maximum number of Channels Users can be a Member + of within this Service. Can be up to 1,000. + type: integer + Notifications.AddedToChannel.Enabled: + description: 'Whether to send a notification when a member is added + to a channel. Can be: `true` or `false` and the default is `false`.' + type: boolean + Notifications.AddedToChannel.Template: + description: The template to use to create the notification text + displayed when a member is added to a channel and `notifications.added_to_channel.enabled` + is `true`. + type: string + Notifications.InvitedToChannel.Enabled: + description: 'Whether to send a notification when a user is invited + to a channel. Can be: `true` or `false` and the default is `false`.' + type: boolean + Notifications.InvitedToChannel.Template: + description: The template to use to create the notification text + displayed when a user is invited to a channel and `notifications.invited_to_channel.enabled` + is `true`. + type: string + Notifications.NewMessage.Enabled: + description: 'Whether to send a notification when a new message + is added to a channel. Can be: `true` or `false` and the default + is `false`.' + type: boolean + Notifications.NewMessage.Template: + description: The template to use to create the notification text + displayed when a new message is added to a channel and `notifications.new_message.enabled` + is `true`. + type: string + Notifications.RemovedFromChannel.Enabled: + description: 'Whether to send a notification to a user when they + are removed from a channel. Can be: `true` or `false` and the + default is `false`.' + type: boolean + Notifications.RemovedFromChannel.Template: + description: The template to use to create the notification text + displayed to a user when they are removed from a channel and `notifications.removed_from_channel.enabled` + is `true`. + type: string + PostWebhookUrl: + description: The URL for post-event webhooks, which are called by + using the `webhook_method`. See [Webhook Events](https://www.twilio.com/docs/api/chat/webhooks) + for more details. + format: uri + type: string + PreWebhookUrl: + description: The URL for pre-event webhooks, which are called by + using the `webhook_method`. See [Webhook Events](https://www.twilio.com/docs/api/chat/webhooks) + for more details. + format: uri + type: string + ReachabilityEnabled: + description: Whether to enable the [Reachability Indicator](https://www.twilio.com/docs/chat/reachability-indicator) + for this Service instance. The default is `false`. + type: boolean + ReadStatusEnabled: + description: Whether to enable the [Message Consumption Horizon](https://www.twilio.com/docs/chat/consumption-horizon) + feature. The default is `true`. + type: boolean + TypingIndicatorTimeout: + description: How long in seconds after a `started typing` event + until clients should assume that user is no longer typing, even + if no `ended typing` message was received. The default is 5 seconds. + type: integer + WebhookFilters: + description: The list of WebHook events that are enabled for this + Service instance. See [Webhook Events](https://www.twilio.com/docs/chat/webhook-events) + for more details. + items: + type: string + type: array + WebhookMethod: + description: 'The HTTP method to use for calls to the `pre_webhook_url` + and `post_webhook_url` webhooks. Can be: `POST` or `GET` and + the default is `POST`. See [Webhook Events](https://www.twilio.com/docs/chat/webhook-events) + for more details.' + enum: + - head + - get + - post + - patch + - put + - delete + - HEAD + - GET + - POST + - PATCH + - PUT + - DELETE + type: string + Webhooks.OnChannelAdd.Method: + description: The HTTP method to use when calling the `webhooks.on_channel_add.url`. + enum: + - head + - get + - post + - patch + - put + - delete + - HEAD + - GET + - POST + - PATCH + - PUT + - DELETE + type: string + Webhooks.OnChannelAdd.Url: + description: The URL of the webhook to call in response to the `on_channel_add` + event using the `webhooks.on_channel_add.method` HTTP method. + format: uri + type: string + Webhooks.OnChannelAdded.Method: + description: The URL of the webhook to call in response to the `on_channel_added` + event`. + enum: + - head + - get + - post + - patch + - put + - delete + - HEAD + - GET + - POST + - PATCH + - PUT + - DELETE + type: string + Webhooks.OnChannelAdded.Url: + description: The URL of the webhook to call in response to the `on_channel_added` + event using the `webhooks.on_channel_added.method` HTTP method. + format: uri + type: string + Webhooks.OnChannelDestroy.Method: + description: The HTTP method to use when calling the `webhooks.on_channel_destroy.url`. + enum: + - head + - get + - post + - patch + - put + - delete + - HEAD + - GET + - POST + - PATCH + - PUT + - DELETE + type: string + Webhooks.OnChannelDestroy.Url: + description: The URL of the webhook to call in response to the `on_channel_destroy` + event using the `webhooks.on_channel_destroy.method` HTTP method. + format: uri + type: string + Webhooks.OnChannelDestroyed.Method: + description: The HTTP method to use when calling the `webhooks.on_channel_destroyed.url`. + enum: + - head + - get + - post + - patch + - put + - delete + - HEAD + - GET + - POST + - PATCH + - PUT + - DELETE + type: string + Webhooks.OnChannelDestroyed.Url: + description: The URL of the webhook to call in response to the `on_channel_added` + event using the `webhooks.on_channel_destroyed.method` HTTP method. + format: uri + type: string + Webhooks.OnChannelUpdate.Method: + description: The HTTP method to use when calling the `webhooks.on_channel_update.url`. + enum: + - head + - get + - post + - patch + - put + - delete + - HEAD + - GET + - POST + - PATCH + - PUT + - DELETE + type: string + Webhooks.OnChannelUpdate.Url: + description: The URL of the webhook to call in response to the `on_channel_update` + event using the `webhooks.on_channel_update.method` HTTP method. + format: uri + type: string + Webhooks.OnChannelUpdated.Method: + description: The HTTP method to use when calling the `webhooks.on_channel_updated.url`. + enum: + - head + - get + - post + - patch + - put + - delete + - HEAD + - GET + - POST + - PATCH + - PUT + - DELETE + type: string + Webhooks.OnChannelUpdated.Url: + description: The URL of the webhook to call in response to the `on_channel_updated` + event using the `webhooks.on_channel_updated.method` HTTP method. + format: uri + type: string + Webhooks.OnMemberAdd.Method: + description: The HTTP method to use when calling the `webhooks.on_member_add.url`. + enum: + - head + - get + - post + - patch + - put + - delete + - HEAD + - GET + - POST + - PATCH + - PUT + - DELETE + type: string + Webhooks.OnMemberAdd.Url: + description: The URL of the webhook to call in response to the `on_member_add` + event using the `webhooks.on_member_add.method` HTTP method. + format: uri + type: string + Webhooks.OnMemberAdded.Method: + description: The HTTP method to use when calling the `webhooks.on_channel_updated.url`. + enum: + - head + - get + - post + - patch + - put + - delete + - HEAD + - GET + - POST + - PATCH + - PUT + - DELETE + type: string + Webhooks.OnMemberAdded.Url: + description: The URL of the webhook to call in response to the `on_channel_updated` + event using the `webhooks.on_channel_updated.method` HTTP method. + format: uri + type: string + Webhooks.OnMemberRemove.Method: + description: The HTTP method to use when calling the `webhooks.on_member_remove.url`. + enum: + - head + - get + - post + - patch + - put + - delete + - HEAD + - GET + - POST + - PATCH + - PUT + - DELETE + type: string + Webhooks.OnMemberRemove.Url: + description: The URL of the webhook to call in response to the `on_member_remove` + event using the `webhooks.on_member_remove.method` HTTP method. + format: uri + type: string + Webhooks.OnMemberRemoved.Method: + description: The HTTP method to use when calling the `webhooks.on_member_removed.url`. + enum: + - head + - get + - post + - patch + - put + - delete + - HEAD + - GET + - POST + - PATCH + - PUT + - DELETE + type: string + Webhooks.OnMemberRemoved.Url: + description: The URL of the webhook to call in response to the `on_member_removed` + event using the `webhooks.on_member_removed.method` HTTP method. + format: uri + type: string + Webhooks.OnMessageRemove.Method: + description: The HTTP method to use when calling the `webhooks.on_message_remove.url`. + enum: + - head + - get + - post + - patch + - put + - delete + - HEAD + - GET + - POST + - PATCH + - PUT + - DELETE + type: string + Webhooks.OnMessageRemove.Url: + description: The URL of the webhook to call in response to the `on_message_remove` + event using the `webhooks.on_message_remove.method` HTTP method. + format: uri + type: string + Webhooks.OnMessageRemoved.Method: + description: The HTTP method to use when calling the `webhooks.on_message_removed.url`. + enum: + - head + - get + - post + - patch + - put + - delete + - HEAD + - GET + - POST + - PATCH + - PUT + - DELETE + type: string + Webhooks.OnMessageRemoved.Url: + description: The URL of the webhook to call in response to the `on_message_removed` + event using the `webhooks.on_message_removed.method` HTTP method. + format: uri + type: string + Webhooks.OnMessageSend.Method: + description: The HTTP method to use when calling the `webhooks.on_message_send.url`. + enum: + - head + - get + - post + - patch + - put + - delete + - HEAD + - GET + - POST + - PATCH + - PUT + - DELETE + type: string + Webhooks.OnMessageSend.Url: + description: The URL of the webhook to call in response to the `on_message_send` + event using the `webhooks.on_message_send.method` HTTP method. + format: uri + type: string + Webhooks.OnMessageSent.Method: + description: The URL of the webhook to call in response to the `on_message_sent` + event`. + enum: + - head + - get + - post + - patch + - put + - delete + - HEAD + - GET + - POST + - PATCH + - PUT + - DELETE + type: string + Webhooks.OnMessageSent.Url: + description: The URL of the webhook to call in response to the `on_message_sent` + event using the `webhooks.on_message_sent.method` HTTP method. + format: uri + type: string + Webhooks.OnMessageUpdate.Method: + description: The HTTP method to use when calling the `webhooks.on_message_update.url`. + enum: + - head + - get + - post + - patch + - put + - delete + - HEAD + - GET + - POST + - PATCH + - PUT + - DELETE + type: string + Webhooks.OnMessageUpdate.Url: + description: The URL of the webhook to call in response to the `on_message_update` + event using the `webhooks.on_message_update.method` HTTP method. + format: uri + type: string + Webhooks.OnMessageUpdated.Method: + description: The HTTP method to use when calling the `webhooks.on_message_updated.url`. + enum: + - head + - get + - post + - patch + - put + - delete + - HEAD + - GET + - POST + - PATCH + - PUT + - DELETE + type: string + Webhooks.OnMessageUpdated.Url: + description: The URL of the webhook to call in response to the `on_message_updated` + event using the `webhooks.on_message_updated.method` HTTP method. + format: uri + type: string + type: object + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/chat.v1.service' + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + servers: + - url: https://chat.twilio.com + x-default-output-properties: *id008 + x-path-type: instance +tags: +- description: This product is Generally Available. + name: GA diff --git a/spec/yaml/twilio_chat.yaml b/spec/yaml/twilio_chat_v2.yaml similarity index 57% rename from spec/yaml/twilio_chat.yaml rename to spec/yaml/twilio_chat_v2.yaml index f12bc5bf..580fa909 100644 --- a/spec/yaml/twilio_chat.yaml +++ b/spec/yaml/twilio_chat_v2.yaml @@ -1,6 +1,6 @@ components: schemas: - chat.v1.credential: + chat.v2.credential: properties: account_sid: maxLength: 34 @@ -32,7 +32,7 @@ components: format: uri type: string type: object - chat.v1.service: + chat.v2.service: properties: account_sid: maxLength: 34 @@ -68,10 +68,16 @@ components: type: object links: type: object + media: + type: object notifications: type: object + post_webhook_retry_count: + type: integer post_webhook_url: type: string + pre_webhook_retry_count: + type: integer pre_webhook_url: type: string reachability_enabled: @@ -94,19 +100,24 @@ components: type: array webhook_method: type: string - webhooks: - type: object type: object - chat.v1.service.channel: + chat.v2.service.binding: properties: account_sid: maxLength: 34 minLength: 34 pattern: ^AC[0-9a-fA-F]{32}$ type: string - attributes: + binding_type: + enum: + - gcm + - apn + - fcm type: string - created_by: + credential_sid: + maxLength: 34 + minLength: 34 + pattern: ^CR[0-9a-fA-F]{32}$ type: string date_created: format: date-time @@ -114,14 +125,16 @@ components: date_updated: format: date-time type: string - friendly_name: + endpoint: + type: string + identity: type: string links: type: object - members_count: - type: integer - messages_count: - type: integer + message_types: + items: + type: string + type: array service_sid: maxLength: 34 minLength: 34 @@ -130,30 +143,20 @@ components: sid: maxLength: 34 minLength: 34 - pattern: ^CH[0-9a-fA-F]{32}$ - type: string - type: - enum: - - public - - private - type: string - unique_name: + pattern: ^BS[0-9a-fA-F]{32}$ type: string url: format: uri type: string type: object - chat.v1.service.channel.invite: + chat.v2.service.channel: properties: account_sid: maxLength: 34 minLength: 34 pattern: ^AC[0-9a-fA-F]{32}$ type: string - channel_sid: - maxLength: 34 - minLength: 34 - pattern: ^CH[0-9a-fA-F]{32}$ + attributes: type: string created_by: type: string @@ -163,13 +166,14 @@ components: date_updated: format: date-time type: string - identity: - type: string - role_sid: - maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ + friendly_name: type: string + links: + type: object + members_count: + type: integer + messages_count: + type: integer service_sid: maxLength: 34 minLength: 34 @@ -178,13 +182,20 @@ components: sid: maxLength: 34 minLength: 34 - pattern: ^IN[0-9a-fA-F]{32}$ + pattern: ^CH[0-9a-fA-F]{32}$ + type: string + type: + enum: + - public + - private + type: string + unique_name: type: string url: format: uri type: string type: object - chat.v1.service.channel.member: + chat.v2.service.channel.channel_webhook: properties: account_sid: maxLength: 34 @@ -196,25 +207,14 @@ components: minLength: 34 pattern: ^CH[0-9a-fA-F]{32}$ type: string + configuration: + type: object date_created: format: date-time type: string date_updated: format: date-time type: string - identity: - type: string - last_consumed_message_index: - nullable: true - type: integer - last_consumption_timestamp: - format: date-time - type: string - role_sid: - maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ - type: string service_sid: maxLength: 34 minLength: 34 @@ -223,78 +223,41 @@ components: sid: maxLength: 34 minLength: 34 - pattern: ^MB[0-9a-fA-F]{32}$ + pattern: ^WH[0-9a-fA-F]{32}$ + type: string + type: type: string url: format: uri type: string type: object - chat.v1.service.channel.message: + chat.v2.service.channel.invite: properties: account_sid: maxLength: 34 minLength: 34 pattern: ^AC[0-9a-fA-F]{32}$ type: string - attributes: - type: string - body: - type: string channel_sid: maxLength: 34 minLength: 34 pattern: ^CH[0-9a-fA-F]{32}$ type: string + created_by: + type: string date_created: format: date-time type: string date_updated: format: date-time type: string - from: - type: string - index: - type: integer - service_sid: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - sid: - maxLength: 34 - minLength: 34 - pattern: ^IM[0-9a-fA-F]{32}$ - type: string - to: - maxLength: 34 - minLength: 34 - pattern: ^CH[0-9a-fA-F]{32}$ - type: string - url: - format: uri + identity: type: string - was_edited: - type: boolean - type: object - chat.v1.service.role: - properties: - account_sid: + role_sid: maxLength: 34 minLength: 34 - pattern: ^AC[0-9a-fA-F]{32}$ - type: string - date_created: - format: date-time - type: string - date_updated: - format: date-time - type: string - friendly_name: + pattern: ^RL[0-9a-fA-F]{32}$ type: string - permissions: - items: - type: string - type: array service_sid: maxLength: 34 minLength: 34 @@ -303,18 +266,13 @@ components: sid: maxLength: 34 minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ - type: string - type: - enum: - - channel - - deployment + pattern: ^IN[0-9a-fA-F]{32}$ type: string url: format: uri type: string type: object - chat.v1.service.user: + chat.v2.service.channel.member: properties: account_sid: maxLength: 34 @@ -323,24 +281,25 @@ components: type: string attributes: type: string + channel_sid: + maxLength: 34 + minLength: 34 + pattern: ^CH[0-9a-fA-F]{32}$ + type: string date_created: format: date-time type: string date_updated: format: date-time type: string - friendly_name: - type: string identity: type: string - is_notifiable: - type: boolean - is_online: - type: boolean - joined_channels_count: + last_consumed_message_index: + nullable: true type: integer - links: - type: object + last_consumption_timestamp: + format: date-time + type: string role_sid: maxLength: 34 minLength: 34 @@ -354,55 +313,27 @@ components: sid: maxLength: 34 minLength: 34 - pattern: ^US[0-9a-fA-F]{32}$ + pattern: ^MB[0-9a-fA-F]{32}$ type: string url: format: uri type: string type: object - chat.v1.service.user.user_channel: + chat.v2.service.channel.message: properties: account_sid: maxLength: 34 minLength: 34 pattern: ^AC[0-9a-fA-F]{32}$ type: string - channel_sid: - maxLength: 34 - minLength: 34 - pattern: ^CH[0-9a-fA-F]{32}$ - type: string - last_consumed_message_index: - nullable: true - type: integer - links: - type: object - member_sid: - maxLength: 34 - minLength: 34 - pattern: ^MB[0-9a-fA-F]{32}$ - type: string - service_sid: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ + attributes: type: string - status: - enum: - - joined - - invited - - not_participating + body: type: string - unread_messages_count: - nullable: true - type: integer - type: object - chat.v2.credential: - properties: - account_sid: + channel_sid: maxLength: 34 minLength: 34 - pattern: ^AC[0-9a-fA-F]{32}$ + pattern: ^CH[0-9a-fA-F]{32}$ type: string date_created: format: date-time @@ -410,3024 +341,240 @@ components: date_updated: format: date-time type: string - friendly_name: - type: string - sandbox: - type: string - sid: - maxLength: 34 - minLength: 34 - pattern: ^CR[0-9a-fA-F]{32}$ - type: string - type: - enum: - - gcm - - apn - - fcm - type: string - url: - format: uri - type: string - type: object - chat.v2.service: - properties: - account_sid: - maxLength: 34 - minLength: 34 - pattern: ^AC[0-9a-fA-F]{32}$ + from: type: string - consumption_report_interval: + index: type: integer - date_created: - format: date-time - type: string - date_updated: - format: date-time - type: string - default_channel_creator_role_sid: - maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ - type: string - default_channel_role_sid: - maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ + last_updated_by: type: string - default_service_role_sid: + media: + type: object + service_sid: maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ - type: string - friendly_name: - type: string - limits: - type: object - links: - type: object - media: - type: object - notifications: - type: object - post_webhook_retry_count: - type: integer - post_webhook_url: - type: string - pre_webhook_retry_count: - type: integer - pre_webhook_url: - type: string - reachability_enabled: - type: boolean - read_status_enabled: - type: boolean - sid: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - typing_indicator_timeout: - type: integer - url: - format: uri - type: string - webhook_filters: - items: - type: string - type: array - webhook_method: - type: string - type: object - chat.v2.service.binding: - properties: - account_sid: - maxLength: 34 - minLength: 34 - pattern: ^AC[0-9a-fA-F]{32}$ - type: string - binding_type: - enum: - - gcm - - apn - - fcm - type: string - credential_sid: - maxLength: 34 - minLength: 34 - pattern: ^CR[0-9a-fA-F]{32}$ - type: string - date_created: - format: date-time - type: string - date_updated: - format: date-time - type: string - endpoint: - type: string - identity: - type: string - links: - type: object - message_types: - items: - type: string - type: array - service_sid: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - sid: - maxLength: 34 - minLength: 34 - pattern: ^BS[0-9a-fA-F]{32}$ - type: string - url: - format: uri - type: string - type: object - chat.v2.service.channel: - properties: - account_sid: - maxLength: 34 - minLength: 34 - pattern: ^AC[0-9a-fA-F]{32}$ - type: string - attributes: - type: string - created_by: - type: string - date_created: - format: date-time - type: string - date_updated: - format: date-time - type: string - friendly_name: - type: string - links: - type: object - members_count: - type: integer - messages_count: - type: integer - service_sid: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - sid: - maxLength: 34 - minLength: 34 - pattern: ^CH[0-9a-fA-F]{32}$ - type: string - type: - enum: - - public - - private - type: string - unique_name: - type: string - url: - format: uri - type: string - type: object - chat.v2.service.channel.channel_webhook: - properties: - account_sid: - maxLength: 34 - minLength: 34 - pattern: ^AC[0-9a-fA-F]{32}$ - type: string - channel_sid: - maxLength: 34 - minLength: 34 - pattern: ^CH[0-9a-fA-F]{32}$ - type: string - configuration: - type: object - date_created: - format: date-time - type: string - date_updated: - format: date-time - type: string - service_sid: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - sid: - maxLength: 34 - minLength: 34 - pattern: ^WH[0-9a-fA-F]{32}$ - type: string - type: - type: string - url: - format: uri - type: string - type: object - chat.v2.service.channel.invite: - properties: - account_sid: - maxLength: 34 - minLength: 34 - pattern: ^AC[0-9a-fA-F]{32}$ - type: string - channel_sid: - maxLength: 34 - minLength: 34 - pattern: ^CH[0-9a-fA-F]{32}$ - type: string - created_by: - type: string - date_created: - format: date-time - type: string - date_updated: - format: date-time - type: string - identity: - type: string - role_sid: - maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ - type: string - service_sid: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - sid: - maxLength: 34 - minLength: 34 - pattern: ^IN[0-9a-fA-F]{32}$ - type: string - url: - format: uri - type: string - type: object - chat.v2.service.channel.member: - properties: - account_sid: - maxLength: 34 - minLength: 34 - pattern: ^AC[0-9a-fA-F]{32}$ - type: string - attributes: - type: string - channel_sid: - maxLength: 34 - minLength: 34 - pattern: ^CH[0-9a-fA-F]{32}$ - type: string - date_created: - format: date-time - type: string - date_updated: - format: date-time - type: string - identity: - type: string - last_consumed_message_index: - nullable: true - type: integer - last_consumption_timestamp: - format: date-time - type: string - role_sid: - maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ - type: string - service_sid: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - sid: - maxLength: 34 - minLength: 34 - pattern: ^MB[0-9a-fA-F]{32}$ - type: string - url: - format: uri - type: string - type: object - chat.v2.service.channel.message: - properties: - account_sid: - maxLength: 34 - minLength: 34 - pattern: ^AC[0-9a-fA-F]{32}$ - type: string - attributes: - type: string - body: - type: string - channel_sid: - maxLength: 34 - minLength: 34 - pattern: ^CH[0-9a-fA-F]{32}$ - type: string - date_created: - format: date-time - type: string - date_updated: - format: date-time - type: string - from: - type: string - index: - type: integer - last_updated_by: - type: string - media: - type: object - service_sid: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - sid: - maxLength: 34 - minLength: 34 - pattern: ^IM[0-9a-fA-F]{32}$ - type: string - to: - maxLength: 34 - minLength: 34 - pattern: ^CH[0-9a-fA-F]{32}$ - type: string - type: - type: string - url: - format: uri - type: string - was_edited: - type: boolean - type: object - chat.v2.service.role: - properties: - account_sid: - maxLength: 34 - minLength: 34 - pattern: ^AC[0-9a-fA-F]{32}$ - type: string - date_created: - format: date-time - type: string - date_updated: - format: date-time - type: string - friendly_name: - type: string - permissions: - items: - type: string - type: array - service_sid: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - sid: - maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ - type: string - type: - enum: - - channel - - deployment - type: string - url: - format: uri - type: string - type: object - chat.v2.service.user: - properties: - account_sid: - maxLength: 34 - minLength: 34 - pattern: ^AC[0-9a-fA-F]{32}$ - type: string - attributes: - type: string - date_created: - format: date-time - type: string - date_updated: - format: date-time - type: string - friendly_name: - type: string - identity: - type: string - is_notifiable: - type: boolean - is_online: - type: boolean - joined_channels_count: - type: integer - links: - type: object - role_sid: - maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ - type: string - service_sid: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - sid: - maxLength: 34 - minLength: 34 - pattern: ^US[0-9a-fA-F]{32}$ - type: string - url: - format: uri - type: string - type: object - chat.v2.service.user.user_binding: - properties: - account_sid: - maxLength: 34 - minLength: 34 - pattern: ^AC[0-9a-fA-F]{32}$ - type: string - binding_type: - enum: - - gcm - - apn - - fcm - type: string - credential_sid: - maxLength: 34 - minLength: 34 - pattern: ^CR[0-9a-fA-F]{32}$ - type: string - date_created: - format: date-time - type: string - date_updated: - format: date-time - type: string - endpoint: - type: string - identity: - type: string - message_types: - items: - type: string - type: array - service_sid: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - sid: - maxLength: 34 - minLength: 34 - pattern: ^BS[0-9a-fA-F]{32}$ - type: string - url: - format: uri - type: string - user_sid: - maxLength: 34 - minLength: 34 - pattern: ^US[0-9a-fA-F]{32}$ - type: string - type: object - chat.v2.service.user.user_channel: - properties: - account_sid: - maxLength: 34 - minLength: 34 - pattern: ^AC[0-9a-fA-F]{32}$ - type: string - channel_sid: - maxLength: 34 - minLength: 34 - pattern: ^CH[0-9a-fA-F]{32}$ - type: string - last_consumed_message_index: - nullable: true - type: integer - links: - type: object - member_sid: - maxLength: 34 - minLength: 34 - pattern: ^MB[0-9a-fA-F]{32}$ - type: string - notification_level: - enum: - - default - - muted - type: string - service_sid: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - status: - enum: - - joined - - invited - - not_participating - type: string - unread_messages_count: - nullable: true - type: integer - url: - format: uri - type: string - user_sid: - maxLength: 34 - minLength: 34 - pattern: ^US[0-9a-fA-F]{32}$ - type: string - type: object - securitySchemes: - accountSid_authToken: - scheme: basic - type: http -info: - contact: - email: support@twilio.com - name: Twilio Support - url: https://support.twilio.com - description: This is the public Twilio REST API. - license: - name: Apache 2.0 - url: https://www.apache.org/licenses/LICENSE-2.0.html - termsOfService: https://www.twilio.com/legal/tos - title: Twilio - Chat - version: 1.3.0 -openapi: 3.0.1 -paths: - /v1/Credentials: - description: Credentials for push notifications channels - get: - description: '' - parameters: - - description: How many resources to return in each list page. The default is - 50, and the maximum is 1000. - in: query - name: PageSize - schema: - maximum: 1000 - minimum: 1 - type: integer - responses: - 200: - content: - application/json: - schema: - properties: - credentials: - items: - $ref: '#/components/schemas/chat.v1.credential' - type: array - meta: - properties: - first_page_url: - format: uri - type: string - key: - type: string - next_page_url: - format: uri - type: string - page: - type: integer - page_size: - type: integer - previous_page_url: - format: uri - type: string - url: - format: uri - type: string - type: object - type: object - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - post: - description: '' - requestBody: - content: - application/x-www-form-urlencoded: - schema: - properties: - ApiKey: - description: '[GCM only] The API key for the project that was obtained - from the Google Developer console for your GCM Service application - credential.' - type: string - Certificate: - description: "[APN only] The URL encoded representation of the certificate.\ - \ For example, \n`-----BEGIN CERTIFICATE-----\nMIIFnTCCBIWgAwIBAgIIAjy9H849+E8wDQYJKoZIhvcNAQEFBQAwgZYxCzAJBgNV.....A==\n\ - -----END CERTIFICATE-----`" - type: string - FriendlyName: - description: A descriptive string that you create to describe the - new resource. It can be up to 64 characters long. - type: string - PrivateKey: - description: '[APN only] The URL encoded representation of the private - key. For example, - - `-----BEGIN RSA PRIVATE KEY----- - - MIIEpQIBAAKCAQEAuyf/lNrH9ck8DmNyo3fGgvCI1l9s+cmBY3WIz+cUDqmxiieR. - - -----END RSA PRIVATE KEY-----`' - type: string - Sandbox: - description: '[APN only] Whether to send the credential to sandbox - APNs. Can be `true` to send to sandbox APNs or `false` to send - to production.' - type: boolean - Secret: - description: '[FCM only] The **Server key** of your project from - the Firebase console, found under Settings / Cloud messaging.' - type: string - Type: - description: 'The type of push-notification service the credential - is for. Can be: `gcm`, `fcm`, or `apn`.' - enum: - - gcm - - apn - - fcm - type: string - required: - - Type - type: object - responses: - 201: - content: - application/json: - schema: - $ref: '#/components/schemas/chat.v1.credential' - description: Created - security: - - accountSid_authToken: [] - tags: - - GA - servers: - - url: https://chat.twilio.com - x-default-output-properties: &id001 - - sid - - friendly_name - - type - x-path-type: list - /v1/Credentials/{Sid}: - delete: - description: '' - parameters: - - description: The Twilio-provided string that uniquely identifies the Credential - resource to delete. - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^CR[0-9a-fA-F]{32}$ - type: string - responses: - 204: - description: The resource was deleted successfully. - security: - - accountSid_authToken: [] - tags: - - GA - description: Credentials for push notifications channels - get: - description: '' - parameters: - - description: The Twilio-provided string that uniquely identifies the Credential - resource to fetch. - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^CR[0-9a-fA-F]{32}$ - type: string - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/chat.v1.credential' - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - post: - description: '' - parameters: - - description: The Twilio-provided string that uniquely identifies the Credential - resource to update. - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^CR[0-9a-fA-F]{32}$ - type: string - requestBody: - content: - application/x-www-form-urlencoded: - schema: - properties: - ApiKey: - description: '[GCM only] The API key for the project that was obtained - from the Google Developer console for your GCM Service application - credential.' - type: string - Certificate: - description: "[APN only] The URL encoded representation of the certificate.\ - \ For example, \n`-----BEGIN CERTIFICATE-----\nMIIFnTCCBIWgAwIBAgIIAjy9H849+E8wDQYJKoZIhvcNAQEFBQAwgZYxCzAJBgNV.....A==\n\ - -----END CERTIFICATE-----`" - type: string - FriendlyName: - description: A descriptive string that you create to describe the - resource. It can be up to 64 characters long. - type: string - PrivateKey: - description: '[APN only] The URL encoded representation of the private - key. For example, - - `-----BEGIN RSA PRIVATE KEY----- - - MIIEpQIBAAKCAQEAuyf/lNrH9ck8DmNyo3fGgvCI1l9s+cmBY3WIz+cUDqmxiieR. - - -----END RSA PRIVATE KEY-----`' - type: string - Sandbox: - description: '[APN only] Whether to send the credential to sandbox - APNs. Can be `true` to send to sandbox APNs or `false` to send - to production.' - type: boolean - Secret: - description: '[FCM only] The **Server key** of your project from - the Firebase console, found under Settings / Cloud messaging.' - type: string - type: object - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/chat.v1.credential' - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - servers: - - url: https://chat.twilio.com - x-default-output-properties: *id001 - x-path-type: instance - /v1/Services: - description: Top level scope for all chat resources - get: - description: '' - parameters: - - description: How many resources to return in each list page. The default is - 50, and the maximum is 1000. - in: query - name: PageSize - schema: - maximum: 1000 - minimum: 1 - type: integer - responses: - 200: - content: - application/json: - schema: - properties: - meta: - properties: - first_page_url: - format: uri - type: string - key: - type: string - next_page_url: - format: uri - type: string - page: - type: integer - page_size: - type: integer - previous_page_url: - format: uri - type: string - url: - format: uri - type: string - type: object - services: - items: - $ref: '#/components/schemas/chat.v1.service' - type: array - type: object - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - post: - description: '' - requestBody: - content: - application/x-www-form-urlencoded: - schema: - properties: - FriendlyName: - description: A descriptive string that you create to describe the - resource. It can be up to 64 characters long. - type: string - required: - - FriendlyName - type: object - responses: - 201: - content: - application/json: - schema: - $ref: '#/components/schemas/chat.v1.service' - description: Created - security: - - accountSid_authToken: [] - tags: - - GA - servers: - - url: https://chat.twilio.com - x-default-output-properties: &id008 - - sid - - friendly_name - - date_created - x-path-type: list - /v1/Services/{ServiceSid}/Channels: - description: Channels represent chat rooms - get: - description: '' - parameters: - - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) - to read the resources from. - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: 'The visibility of the Channels to read. Can be: `public` or - `private` and defaults to `public`.' - in: query - name: Type - schema: - items: - enum: - - public - - private - type: string - type: array - - description: How many resources to return in each list page. The default is - 50, and the maximum is 1000. - in: query - name: PageSize - schema: - maximum: 1000 - minimum: 1 - type: integer - responses: - 200: - content: - application/json: - schema: - properties: - channels: - items: - $ref: '#/components/schemas/chat.v1.service.channel' - type: array - meta: - properties: - first_page_url: - format: uri - type: string - key: - type: string - next_page_url: - format: uri - type: string - page: - type: integer - page_size: - type: integer - previous_page_url: - format: uri - type: string - url: - format: uri - type: string - type: object - type: object - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - post: - description: '' - parameters: - - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) - to create the resource under. - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - requestBody: - content: - application/x-www-form-urlencoded: - schema: - properties: - Attributes: - description: A valid JSON string that contains application-specific - data. - type: string - FriendlyName: - description: A descriptive string that you create to describe the - new resource. It can be up to 64 characters long. - type: string - Type: - description: 'The visibility of the channel. Can be: `public` or - `private` and defaults to `public`.' - enum: - - public - - private - type: string - UniqueName: - description: An application-defined string that uniquely identifies - the resource. It can be used to address the resource in place - of the resource's `sid` in the URL. This value must be 64 characters - or less in length and be unique within the Service. - type: string - type: object - responses: - 201: - content: - application/json: - schema: - $ref: '#/components/schemas/chat.v1.service.channel' - description: Created - security: - - accountSid_authToken: [] - tags: - - GA - servers: - - url: https://chat.twilio.com - x-default-output-properties: &id005 - - sid - - unique_name - - friendly_name - x-path-type: list - /v1/Services/{ServiceSid}/Channels/{ChannelSid}/Invites: - description: Pending invitations to users to become channel members - get: - description: '' - parameters: - - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) - to read the resources from. - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: The SID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) - the resources to read belong to. - in: path - name: ChannelSid - required: true - schema: - type: string - - description: The [User](https://www.twilio.com/docs/api/chat/rest/v1/user)'s - `identity` value of the resources to read. See [access tokens](https://www.twilio.com/docs/api/chat/guides/create-tokens) - for more details. - in: query - name: Identity - schema: - items: - type: string - type: array - - description: How many resources to return in each list page. The default is - 50, and the maximum is 1000. - in: query - name: PageSize - schema: - maximum: 1000 - minimum: 1 - type: integer - responses: - 200: - content: - application/json: - schema: - properties: - invites: - items: - $ref: '#/components/schemas/chat.v1.service.channel.invite' - type: array - meta: - properties: - first_page_url: - format: uri - type: string - key: - type: string - next_page_url: - format: uri - type: string - page: - type: integer - page_size: - type: integer - previous_page_url: - format: uri - type: string - url: - format: uri - type: string - type: object - type: object - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - post: - description: '' - parameters: - - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) - to create the resource under. - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: The SID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) - the new resource belongs to. - in: path - name: ChannelSid - required: true - schema: - type: string - requestBody: - content: - application/x-www-form-urlencoded: - schema: - properties: - Identity: - description: The `identity` value that uniquely identifies the new - resource's [User](https://www.twilio.com/docs/api/chat/rest/v1/user) - within the [Service](https://www.twilio.com/docs/api/chat/rest/v1/service). - See [access tokens](https://www.twilio.com/docs/api/chat/guides/create-tokens) - for more info. - type: string - RoleSid: - description: The SID of the [Role](https://www.twilio.com/docs/api/chat/rest/roles) - assigned to the new member. - maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ - type: string - required: - - Identity - type: object - responses: - 201: - content: - application/json: - schema: - $ref: '#/components/schemas/chat.v1.service.channel.invite' - description: Created - security: - - accountSid_authToken: [] - tags: - - GA - servers: - - url: https://chat.twilio.com - x-default-output-properties: &id002 - - sid - - identity - - date_created - x-path-type: list - /v1/Services/{ServiceSid}/Channels/{ChannelSid}/Invites/{Sid}: - delete: - description: '' - parameters: - - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) - to delete the resource from. - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: The SID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) - the resource to delete belongs to. - in: path - name: ChannelSid - required: true - schema: - type: string - - description: The Twilio-provided string that uniquely identifies the Invite - resource to delete. - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IN[0-9a-fA-F]{32}$ - type: string - responses: - 204: - description: The resource was deleted successfully. - security: - - accountSid_authToken: [] - tags: - - GA - description: Pending invitations to users to become channel members - get: - description: '' - parameters: - - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) - to fetch the resource from. - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: The SID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) - the resource to fetch belongs to. - in: path - name: ChannelSid - required: true - schema: - type: string - - description: The Twilio-provided string that uniquely identifies the Invite - resource to fetch. - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IN[0-9a-fA-F]{32}$ - type: string - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/chat.v1.service.channel.invite' - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - servers: - - url: https://chat.twilio.com - x-default-output-properties: *id002 - x-path-type: instance - /v1/Services/{ServiceSid}/Channels/{ChannelSid}/Members: - description: Users joined to specific channels - get: - description: '' - parameters: - - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) - to read the resources from. - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) - the members to read belong to. Can be the Channel resource's `sid` or `unique_name` - value. - in: path - name: ChannelSid - required: true - schema: - type: string - - description: The [User](https://www.twilio.com/docs/api/chat/rest/v1/user)'s - `identity` value of the resources to read. See [access tokens](https://www.twilio.com/docs/api/chat/guides/create-tokens) - for more details. - in: query - name: Identity - schema: - items: - type: string - type: array - - description: How many resources to return in each list page. The default is - 50, and the maximum is 1000. - in: query - name: PageSize - schema: - maximum: 1000 - minimum: 1 - type: integer - responses: - 200: - content: - application/json: - schema: - properties: - members: - items: - $ref: '#/components/schemas/chat.v1.service.channel.member' - type: array - meta: - properties: - first_page_url: - format: uri - type: string - key: - type: string - next_page_url: - format: uri - type: string - page: - type: integer - page_size: - type: integer - previous_page_url: - format: uri - type: string - url: - format: uri - type: string - type: object - type: object - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - post: - description: '' - parameters: - - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) - to create the resource under. - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) - the new member belongs to. Can be the Channel resource's `sid` or `unique_name`. - in: path - name: ChannelSid - required: true - schema: - type: string - requestBody: - content: - application/x-www-form-urlencoded: - schema: - properties: - Identity: - description: The `identity` value that uniquely identifies the new - resource's [User](https://www.twilio.com/docs/api/chat/rest/v1/user) - within the [Service](https://www.twilio.com/docs/api/chat/rest/services). - See [access tokens](https://www.twilio.com/docs/api/chat/guides/create-tokens) - for more details. - type: string - RoleSid: - description: The SID of the [Role](https://www.twilio.com/docs/api/chat/rest/roles) - to assign to the member. The default roles are those specified - on the [Service](https://www.twilio.com/docs/chat/api/services). - maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ - type: string - required: - - Identity - type: object - responses: - 201: - content: - application/json: - schema: - $ref: '#/components/schemas/chat.v1.service.channel.member' - description: Created - security: - - accountSid_authToken: [] - tags: - - GA - servers: - - url: https://chat.twilio.com - x-default-output-properties: &id003 - - sid - - identity - - date_created - x-path-type: list - /v1/Services/{ServiceSid}/Channels/{ChannelSid}/Members/{Sid}: - delete: - description: '' - parameters: - - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) - to delete the resource from. - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) - the message belongs to. Can be the Channel's `sid` or `unique_name`. - in: path - name: ChannelSid - required: true - schema: - type: string - - description: The Twilio-provided string that uniquely identifies the Member - resource to delete. - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^MB[0-9a-fA-F]{32}$ - type: string - responses: - 204: - description: The resource was deleted successfully. - security: - - accountSid_authToken: [] - tags: - - GA - description: Users joined to specific channels - get: - description: '' - parameters: - - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) - to fetch the resource from. - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) - the member to fetch belongs to. Can be the Channel resource's `sid` or `unique_name` - value. - in: path - name: ChannelSid - required: true - schema: - type: string - - description: The Twilio-provided string that uniquely identifies the Member - resource to fetch. - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^MB[0-9a-fA-F]{32}$ - type: string - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/chat.v1.service.channel.member' - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - post: - description: '' - parameters: - - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) - to update the resource from. - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) - the member to update belongs to. Can be the Channel resource's `sid` or - `unique_name`. - in: path - name: ChannelSid - required: true - schema: - type: string - - description: The Twilio-provided string that uniquely identifies the Member - resource to update. - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^MB[0-9a-fA-F]{32}$ - type: string - requestBody: - content: - application/x-www-form-urlencoded: - schema: - properties: - LastConsumedMessageIndex: - description: The index of the last [Message](https://www.twilio.com/docs/api/chat/rest/messages) - that the Member has read within the [Channel](https://www.twilio.com/docs/api/chat/rest/channels). - nullable: true - type: integer - RoleSid: - description: The SID of the [Role](https://www.twilio.com/docs/api/chat/rest/roles) - to assign to the member. The default roles are those specified - on the [Service](https://www.twilio.com/docs/chat/api/services). - maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ - type: string - type: object - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/chat.v1.service.channel.member' - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - servers: - - url: https://chat.twilio.com - x-default-output-properties: *id003 - x-path-type: instance - /v1/Services/{ServiceSid}/Channels/{ChannelSid}/Messages: - description: Individual chat messages - get: - description: '' - parameters: - - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) - to read the resources from. - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) - the message to read belongs to. Can be the Channel's `sid` or `unique_name`. - in: path - name: ChannelSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^CH[0-9a-fA-F]{32}$ - type: string - - description: 'The sort order of the returned messages. Can be: `asc` (ascending) - or `desc` (descending) with `asc` as the default.' - in: query - name: Order - schema: - enum: - - asc - - desc - type: string - - description: How many resources to return in each list page. The default is - 50, and the maximum is 1000. - in: query - name: PageSize - schema: - maximum: 1000 - minimum: 1 - type: integer - responses: - 200: - content: - application/json: - schema: - properties: - messages: - items: - $ref: '#/components/schemas/chat.v1.service.channel.message' - type: array - meta: - properties: - first_page_url: - format: uri - type: string - key: - type: string - next_page_url: - format: uri - type: string - page: - type: integer - page_size: - type: integer - previous_page_url: - format: uri - type: string - url: - format: uri - type: string - type: object - type: object - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - post: - description: '' - parameters: - - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) - to create the resource under. - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) - the new resource belongs to. Can be the Channel resource's `sid` or `unique_name`. - in: path - name: ChannelSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^CH[0-9a-fA-F]{32}$ - type: string - requestBody: - content: - application/x-www-form-urlencoded: - schema: - properties: - Attributes: - description: A valid JSON string that contains application-specific - data. - type: string - Body: - description: The message to send to the channel. Can also be an - empty string or `null`, which sets the value as an empty string. - You can send structured data in the body by serializing it as - a string. - type: string - From: - description: The [identity](https://www.twilio.com/docs/api/chat/guides/identity) - of the new message's author. The default value is `system`. - type: string - required: - - Body - type: object - responses: - 201: - content: - application/json: - schema: - $ref: '#/components/schemas/chat.v1.service.channel.message' - description: Created - security: - - accountSid_authToken: [] - tags: - - GA - servers: - - url: https://chat.twilio.com - x-default-output-properties: &id004 - - sid - - from - - to - - date_created - x-path-type: list - /v1/Services/{ServiceSid}/Channels/{ChannelSid}/Messages/{Sid}: - delete: - description: '' - parameters: - - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) - to delete the resource from. - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) - the message to delete belongs to. Can be the Channel resource's `sid` or - `unique_name`. - in: path - name: ChannelSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^CH[0-9a-fA-F]{32}$ - type: string - - description: The Twilio-provided string that uniquely identifies the Message - resource to delete. - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IM[0-9a-fA-F]{32}$ - type: string - responses: - 204: - description: The resource was deleted successfully. - security: - - accountSid_authToken: [] - tags: - - GA - description: Individual chat messages - get: - description: '' - parameters: - - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) - to fetch the resource from. - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) - the message to fetch belongs to. Can be the Channel's `sid` or `unique_name`. - in: path - name: ChannelSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^CH[0-9a-fA-F]{32}$ - type: string - - description: The Twilio-provided string that uniquely identifies the Message - resource to fetch. - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IM[0-9a-fA-F]{32}$ - type: string - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/chat.v1.service.channel.message' - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - post: - description: '' - parameters: - - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) - to update the resource from. - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: The unique ID of the [Channel](https://www.twilio.com/docs/api/chat/rest/channels) - the message belongs to. Can be the Channel's `sid` or `unique_name`. - in: path - name: ChannelSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^CH[0-9a-fA-F]{32}$ - type: string - - description: The Twilio-provided string that uniquely identifies the Message - resource to update. - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IM[0-9a-fA-F]{32}$ - type: string - requestBody: - content: - application/x-www-form-urlencoded: - schema: - properties: - Attributes: - description: A valid JSON string that contains application-specific - data. - type: string - Body: - description: The message to send to the channel. Can also be an - empty string or `null`, which sets the value as an empty string. - You can send structured data in the body by serializing it as - a string. - type: string - type: object - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/chat.v1.service.channel.message' - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - servers: - - url: https://chat.twilio.com - x-default-output-properties: *id004 - x-path-type: instance - /v1/Services/{ServiceSid}/Channels/{Sid}: - delete: - description: '' - parameters: - - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) - to delete the resource from. - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: The Twilio-provided string that uniquely identifies the Channel - resource to delete. - in: path - name: Sid - required: true - schema: - type: string - responses: - 204: - description: The resource was deleted successfully. - security: - - accountSid_authToken: [] - tags: - - GA - description: Channels represent chat rooms - get: - description: '' - parameters: - - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) - to fetch the resource from. - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: The Twilio-provided string that uniquely identifies the Channel - resource to fetch. - in: path - name: Sid - required: true - schema: - type: string - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/chat.v1.service.channel' - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - post: - description: '' - parameters: - - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) - to update the resource from. - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: The Twilio-provided string that uniquely identifies the Channel - resource to update. - in: path - name: Sid - required: true - schema: - type: string - requestBody: - content: - application/x-www-form-urlencoded: - schema: - properties: - Attributes: - description: A valid JSON string that contains application-specific - data. - type: string - FriendlyName: - description: A descriptive string that you create to describe the - resource. It can be up to 64 characters long. - type: string - UniqueName: - description: An application-defined string that uniquely identifies - the resource. It can be used to address the resource in place - of the resource's `sid` in the URL. This value must be 64 characters - or less in length and be unique within the Service. - type: string - type: object - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/chat.v1.service.channel' - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - servers: - - url: https://chat.twilio.com - x-default-output-properties: *id005 - x-path-type: instance - /v1/Services/{ServiceSid}/Roles: - description: Roles determining user or member permissions - get: - description: '' - parameters: - - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) - to read the resources from. - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: How many resources to return in each list page. The default is - 50, and the maximum is 1000. - in: query - name: PageSize - schema: - maximum: 1000 - minimum: 1 - type: integer - responses: - 200: - content: - application/json: - schema: - properties: - meta: - properties: - first_page_url: - format: uri - type: string - key: - type: string - next_page_url: - format: uri - type: string - page: - type: integer - page_size: - type: integer - previous_page_url: - format: uri - type: string - url: - format: uri - type: string - type: object - roles: - items: - $ref: '#/components/schemas/chat.v1.service.role' - type: array - type: object - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - post: - description: '' - parameters: - - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) - to create the resource under. - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - requestBody: - content: - application/x-www-form-urlencoded: - schema: - properties: - FriendlyName: - description: A descriptive string that you create to describe the - new resource. It can be up to 64 characters long. - type: string - Permission: - description: A permission that you grant to the new role. Only one - permission can be granted per parameter. To assign more than one - permission, repeat this parameter for each permission value. The - values for this parameter depend on the role's `type` and are - described in the documentation. - items: - type: string - type: array - Type: - description: 'The type of role. Can be: `channel` for [Channel](https://www.twilio.com/docs/chat/api/channels) - roles or `deployment` for [Service](https://www.twilio.com/docs/chat/api/services) - roles.' - enum: - - channel - - deployment - type: string - required: - - FriendlyName - - Type - - Permission - type: object - responses: - 201: - content: - application/json: - schema: - $ref: '#/components/schemas/chat.v1.service.role' - description: Created - security: - - accountSid_authToken: [] - tags: - - GA - servers: - - url: https://chat.twilio.com - x-default-output-properties: &id006 - - sid - - friendly_name - - type - x-path-type: list - /v1/Services/{ServiceSid}/Roles/{Sid}: - delete: - description: '' - parameters: - - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) - to delete the resource from. - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: The Twilio-provided string that uniquely identifies the Role - resource to delete. - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ - type: string - responses: - 204: - description: The resource was deleted successfully. - security: - - accountSid_authToken: [] - tags: - - GA - description: Roles determining user or member permissions - get: - description: '' - parameters: - - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) - to fetch the resource from. - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: The Twilio-provided string that uniquely identifies the Role - resource to fetch. - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ - type: string - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/chat.v1.service.role' - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - post: - description: '' - parameters: - - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) - to update the resource from. - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: The Twilio-provided string that uniquely identifies the Role - resource to update. - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ - type: string - requestBody: - content: - application/x-www-form-urlencoded: - schema: - properties: - Permission: - description: A permission that you grant to the role. Only one permission - can be granted per parameter. To assign more than one permission, - repeat this parameter for each permission value. The values for - this parameter depend on the role's `type` and are described in - the documentation. - items: - type: string - type: array - required: - - Permission - type: object - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/chat.v1.service.role' - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - servers: - - url: https://chat.twilio.com - x-default-output-properties: *id006 - x-path-type: instance - /v1/Services/{ServiceSid}/Users: - description: Unique chat users within a chat service - get: - description: '' - parameters: - - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) - to read the resources from. - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: How many resources to return in each list page. The default is - 50, and the maximum is 1000. - in: query - name: PageSize - schema: - maximum: 1000 - minimum: 1 - type: integer - responses: - 200: - content: - application/json: - schema: - properties: - meta: - properties: - first_page_url: - format: uri - type: string - key: - type: string - next_page_url: - format: uri - type: string - page: - type: integer - page_size: - type: integer - previous_page_url: - format: uri - type: string - url: - format: uri - type: string - type: object - users: - items: - $ref: '#/components/schemas/chat.v1.service.user' - type: array - type: object - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - post: - description: '' - parameters: - - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) - to create the resource under. - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - requestBody: - content: - application/x-www-form-urlencoded: - schema: - properties: - Attributes: - description: A valid JSON string that contains application-specific - data. - type: string - FriendlyName: - description: A descriptive string that you create to describe the - new resource. This value is often used for display purposes. - type: string - Identity: - description: The `identity` value that uniquely identifies the new - resource's [User](https://www.twilio.com/docs/api/chat/rest/v1/user) - within the [Service](https://www.twilio.com/docs/api/chat/rest/v1/service). - This value is often a username or email address. See the Identity - documentation for more details. - type: string - RoleSid: - description: The SID of the [Role](https://www.twilio.com/docs/api/chat/rest/roles) - assigned to the new User. - maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ - type: string - required: - - Identity - type: object - responses: - 201: - content: - application/json: - schema: - $ref: '#/components/schemas/chat.v1.service.user' - description: Created - security: - - accountSid_authToken: [] - tags: - - GA - servers: - - url: https://chat.twilio.com - x-default-output-properties: &id007 - - sid - - friendly_name - - date_created - x-path-type: list - /v1/Services/{ServiceSid}/Users/{Sid}: - delete: - description: '' - parameters: - - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) - to delete the resource from. - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: The Twilio-provided string that uniquely identifies the User - resource to delete. - in: path - name: Sid - required: true - schema: - type: string - responses: - 204: - description: The resource was deleted successfully. - security: - - accountSid_authToken: [] - tags: - - GA - description: Unique chat users within a chat service - get: - description: '' - parameters: - - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) - to fetch the resource from. - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: The Twilio-provided string that uniquely identifies the User - resource to fetch. - in: path - name: Sid - required: true - schema: - type: string - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/chat.v1.service.user' - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - post: - description: '' - parameters: - - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) - to update the resource from. - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: The Twilio-provided string that uniquely identifies the User - resource to update. - in: path - name: Sid - required: true - schema: - type: string - requestBody: - content: - application/x-www-form-urlencoded: - schema: - properties: - Attributes: - description: A valid JSON string that contains application-specific - data. - type: string - FriendlyName: - description: A descriptive string that you create to describe the - resource. It is often used for display purposes. - type: string - RoleSid: - description: The SID of the [Role](https://www.twilio.com/docs/api/chat/rest/roles) - assigned to this user. - maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ - type: string - type: object - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/chat.v1.service.user' - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - servers: - - url: https://chat.twilio.com - x-default-output-properties: *id007 - x-path-type: instance - /v1/Services/{ServiceSid}/Users/{UserSid}/Channels: - description: 'TODO: Resource-level docs' - get: - description: List all Channels for a given User. - parameters: - - description: The SID of the [Service](https://www.twilio.com/docs/api/chat/rest/services) - to read the resources from. - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: The SID of the [User](https://www.twilio.com/docs/api/chat/rest/users) - to read the User Channel resources from. - in: path - name: UserSid - required: true - schema: - type: string - - description: How many resources to return in each list page. The default is - 50, and the maximum is 1000. - in: query - name: PageSize - schema: - maximum: 1000 - minimum: 1 - type: integer - responses: - 200: - content: - application/json: - schema: - properties: - channels: - items: - $ref: '#/components/schemas/chat.v1.service.user.user_channel' - type: array - meta: - properties: - first_page_url: - format: uri - type: string - key: - type: string - next_page_url: - format: uri - type: string - page: - type: integer - page_size: - type: integer - previous_page_url: - format: uri - type: string - url: - format: uri - type: string - type: object - type: object - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - servers: - - url: https://chat.twilio.com - x-default-output-properties: - - channel_sid - - status - x-path-type: list - /v1/Services/{Sid}: - delete: - description: '' - parameters: - - description: The Twilio-provided string that uniquely identifies the Service - resource to delete. - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - responses: - 204: - description: The resource was deleted successfully. - security: - - accountSid_authToken: [] - tags: - - GA - description: Top level scope for all chat resources - get: - description: '' - parameters: - - description: The Twilio-provided string that uniquely identifies the Service - resource to fetch. - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/chat.v1.service' - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - post: - description: '' - parameters: - - description: The Twilio-provided string that uniquely identifies the Service - resource to update. - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - requestBody: - content: - application/x-www-form-urlencoded: - schema: - properties: - ConsumptionReportInterval: - description: DEPRECATED. The interval in seconds between consumption - reports submission batches from client endpoints. - type: integer - DefaultChannelCreatorRoleSid: - description: The channel role assigned to a channel creator when - they join a new channel. See the [Roles endpoint](https://www.twilio.com/docs/chat/api/roles) - for more details. - maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ - type: string - DefaultChannelRoleSid: - description: The channel role assigned to users when they are added - to a channel. See the [Roles endpoint](https://www.twilio.com/docs/chat/api/roles) - for more details. - maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ - type: string - DefaultServiceRoleSid: - description: The service role assigned to users when they are added - to the service. See the [Roles endpoint](https://www.twilio.com/docs/chat/api/roles) - for more details. - maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ - type: string - FriendlyName: - description: A descriptive string that you create to describe the - resource. It can be up to 64 characters long. - type: string - Limits.ChannelMembers: - description: The maximum number of Members that can be added to - Channels within this Service. Can be up to 1,000. - type: integer - Limits.UserChannels: - description: The maximum number of Channels Users can be a Member - of within this Service. Can be up to 1,000. - type: integer - Notifications.AddedToChannel.Enabled: - description: 'Whether to send a notification when a member is added - to a channel. Can be: `true` or `false` and the default is `false`.' - type: boolean - Notifications.AddedToChannel.Template: - description: The template to use to create the notification text - displayed when a member is added to a channel and `notifications.added_to_channel.enabled` - is `true`. - type: string - Notifications.InvitedToChannel.Enabled: - description: 'Whether to send a notification when a user is invited - to a channel. Can be: `true` or `false` and the default is `false`.' - type: boolean - Notifications.InvitedToChannel.Template: - description: The template to use to create the notification text - displayed when a user is invited to a channel and `notifications.invited_to_channel.enabled` - is `true`. - type: string - Notifications.NewMessage.Enabled: - description: 'Whether to send a notification when a new message - is added to a channel. Can be: `true` or `false` and the default - is `false`.' - type: boolean - Notifications.NewMessage.Template: - description: The template to use to create the notification text - displayed when a new message is added to a channel and `notifications.new_message.enabled` - is `true`. - type: string - Notifications.RemovedFromChannel.Enabled: - description: 'Whether to send a notification to a user when they - are removed from a channel. Can be: `true` or `false` and the - default is `false`.' - type: boolean - Notifications.RemovedFromChannel.Template: - description: The template to use to create the notification text - displayed to a user when they are removed from a channel and `notifications.removed_from_channel.enabled` - is `true`. - type: string - PostWebhookUrl: - description: The URL for post-event webhooks, which are called by - using the `webhook_method`. See [Webhook Events](https://www.twilio.com/docs/api/chat/webhooks) - for more details. - format: uri - type: string - PreWebhookUrl: - description: The URL for pre-event webhooks, which are called by - using the `webhook_method`. See [Webhook Events](https://www.twilio.com/docs/api/chat/webhooks) - for more details. - format: uri - type: string - ReachabilityEnabled: - description: Whether to enable the [Reachability Indicator](https://www.twilio.com/docs/chat/reachability-indicator) - for this Service instance. The default is `false`. - type: boolean - ReadStatusEnabled: - description: Whether to enable the [Message Consumption Horizon](https://www.twilio.com/docs/chat/consumption-horizon) - feature. The default is `true`. - type: boolean - TypingIndicatorTimeout: - description: How long in seconds after a `started typing` event - until clients should assume that user is no longer typing, even - if no `ended typing` message was received. The default is 5 seconds. - type: integer - WebhookFilters: - description: The list of WebHook events that are enabled for this - Service instance. See [Webhook Events](https://www.twilio.com/docs/chat/webhook-events) - for more details. - items: - type: string - type: array - WebhookMethod: - description: 'The HTTP method to use for calls to the `pre_webhook_url` - and `post_webhook_url` webhooks. Can be: `POST` or `GET` and - the default is `POST`. See [Webhook Events](https://www.twilio.com/docs/chat/webhook-events) - for more details.' - enum: - - head - - get - - post - - patch - - put - - delete - - HEAD - - GET - - POST - - PATCH - - PUT - - DELETE - type: string - Webhooks.OnChannelAdd.Method: - description: The HTTP method to use when calling the `webhooks.on_channel_add.url`. - enum: - - head - - get - - post - - patch - - put - - delete - - HEAD - - GET - - POST - - PATCH - - PUT - - DELETE - type: string - Webhooks.OnChannelAdd.Url: - description: The URL of the webhook to call in response to the `on_channel_add` - event using the `webhooks.on_channel_add.method` HTTP method. - format: uri - type: string - Webhooks.OnChannelAdded.Method: - description: The URL of the webhook to call in response to the `on_channel_added` - event`. - enum: - - head - - get - - post - - patch - - put - - delete - - HEAD - - GET - - POST - - PATCH - - PUT - - DELETE - type: string - Webhooks.OnChannelAdded.Url: - description: The URL of the webhook to call in response to the `on_channel_added` - event using the `webhooks.on_channel_added.method` HTTP method. - format: uri - type: string - Webhooks.OnChannelDestroy.Method: - description: The HTTP method to use when calling the `webhooks.on_channel_destroy.url`. - enum: - - head - - get - - post - - patch - - put - - delete - - HEAD - - GET - - POST - - PATCH - - PUT - - DELETE - type: string - Webhooks.OnChannelDestroy.Url: - description: The URL of the webhook to call in response to the `on_channel_destroy` - event using the `webhooks.on_channel_destroy.method` HTTP method. - format: uri - type: string - Webhooks.OnChannelDestroyed.Method: - description: The HTTP method to use when calling the `webhooks.on_channel_destroyed.url`. - enum: - - head - - get - - post - - patch - - put - - delete - - HEAD - - GET - - POST - - PATCH - - PUT - - DELETE - type: string - Webhooks.OnChannelDestroyed.Url: - description: The URL of the webhook to call in response to the `on_channel_added` - event using the `webhooks.on_channel_destroyed.method` HTTP method. - format: uri - type: string - Webhooks.OnChannelUpdate.Method: - description: The HTTP method to use when calling the `webhooks.on_channel_update.url`. - enum: - - head - - get - - post - - patch - - put - - delete - - HEAD - - GET - - POST - - PATCH - - PUT - - DELETE - type: string - Webhooks.OnChannelUpdate.Url: - description: The URL of the webhook to call in response to the `on_channel_update` - event using the `webhooks.on_channel_update.method` HTTP method. - format: uri - type: string - Webhooks.OnChannelUpdated.Method: - description: The HTTP method to use when calling the `webhooks.on_channel_updated.url`. - enum: - - head - - get - - post - - patch - - put - - delete - - HEAD - - GET - - POST - - PATCH - - PUT - - DELETE - type: string - Webhooks.OnChannelUpdated.Url: - description: The URL of the webhook to call in response to the `on_channel_updated` - event using the `webhooks.on_channel_updated.method` HTTP method. - format: uri - type: string - Webhooks.OnMemberAdd.Method: - description: The HTTP method to use when calling the `webhooks.on_member_add.url`. - enum: - - head - - get - - post - - patch - - put - - delete - - HEAD - - GET - - POST - - PATCH - - PUT - - DELETE - type: string - Webhooks.OnMemberAdd.Url: - description: The URL of the webhook to call in response to the `on_member_add` - event using the `webhooks.on_member_add.method` HTTP method. - format: uri - type: string - Webhooks.OnMemberAdded.Method: - description: The HTTP method to use when calling the `webhooks.on_channel_updated.url`. - enum: - - head - - get - - post - - patch - - put - - delete - - HEAD - - GET - - POST - - PATCH - - PUT - - DELETE - type: string - Webhooks.OnMemberAdded.Url: - description: The URL of the webhook to call in response to the `on_channel_updated` - event using the `webhooks.on_channel_updated.method` HTTP method. - format: uri - type: string - Webhooks.OnMemberRemove.Method: - description: The HTTP method to use when calling the `webhooks.on_member_remove.url`. - enum: - - head - - get - - post - - patch - - put - - delete - - HEAD - - GET - - POST - - PATCH - - PUT - - DELETE - type: string - Webhooks.OnMemberRemove.Url: - description: The URL of the webhook to call in response to the `on_member_remove` - event using the `webhooks.on_member_remove.method` HTTP method. - format: uri - type: string - Webhooks.OnMemberRemoved.Method: - description: The HTTP method to use when calling the `webhooks.on_member_removed.url`. - enum: - - head - - get - - post - - patch - - put - - delete - - HEAD - - GET - - POST - - PATCH - - PUT - - DELETE - type: string - Webhooks.OnMemberRemoved.Url: - description: The URL of the webhook to call in response to the `on_member_removed` - event using the `webhooks.on_member_removed.method` HTTP method. - format: uri - type: string - Webhooks.OnMessageRemove.Method: - description: The HTTP method to use when calling the `webhooks.on_message_remove.url`. - enum: - - head - - get - - post - - patch - - put - - delete - - HEAD - - GET - - POST - - PATCH - - PUT - - DELETE - type: string - Webhooks.OnMessageRemove.Url: - description: The URL of the webhook to call in response to the `on_message_remove` - event using the `webhooks.on_message_remove.method` HTTP method. - format: uri - type: string - Webhooks.OnMessageRemoved.Method: - description: The HTTP method to use when calling the `webhooks.on_message_removed.url`. - enum: - - head - - get - - post - - patch - - put - - delete - - HEAD - - GET - - POST - - PATCH - - PUT - - DELETE - type: string - Webhooks.OnMessageRemoved.Url: - description: The URL of the webhook to call in response to the `on_message_removed` - event using the `webhooks.on_message_removed.method` HTTP method. - format: uri - type: string - Webhooks.OnMessageSend.Method: - description: The HTTP method to use when calling the `webhooks.on_message_send.url`. - enum: - - head - - get - - post - - patch - - put - - delete - - HEAD - - GET - - POST - - PATCH - - PUT - - DELETE - type: string - Webhooks.OnMessageSend.Url: - description: The URL of the webhook to call in response to the `on_message_send` - event using the `webhooks.on_message_send.method` HTTP method. - format: uri - type: string - Webhooks.OnMessageSent.Method: - description: The URL of the webhook to call in response to the `on_message_sent` - event`. - enum: - - head - - get - - post - - patch - - put - - delete - - HEAD - - GET - - POST - - PATCH - - PUT - - DELETE - type: string - Webhooks.OnMessageSent.Url: - description: The URL of the webhook to call in response to the `on_message_sent` - event using the `webhooks.on_message_sent.method` HTTP method. - format: uri - type: string - Webhooks.OnMessageUpdate.Method: - description: The HTTP method to use when calling the `webhooks.on_message_update.url`. - enum: - - head - - get - - post - - patch - - put - - delete - - HEAD - - GET - - POST - - PATCH - - PUT - - DELETE - type: string - Webhooks.OnMessageUpdate.Url: - description: The URL of the webhook to call in response to the `on_message_update` - event using the `webhooks.on_message_update.method` HTTP method. - format: uri - type: string - Webhooks.OnMessageUpdated.Method: - description: The HTTP method to use when calling the `webhooks.on_message_updated.url`. - enum: - - head - - get - - post - - patch - - put - - delete - - HEAD - - GET - - POST - - PATCH - - PUT - - DELETE - type: string - Webhooks.OnMessageUpdated.Url: - description: The URL of the webhook to call in response to the `on_message_updated` - event using the `webhooks.on_message_updated.method` HTTP method. - format: uri - type: string - type: object - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/chat.v1.service' - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - servers: - - url: https://chat.twilio.com - x-default-output-properties: *id008 - x-path-type: instance + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + sid: + maxLength: 34 + minLength: 34 + pattern: ^IM[0-9a-fA-F]{32}$ + type: string + to: + maxLength: 34 + minLength: 34 + pattern: ^CH[0-9a-fA-F]{32}$ + type: string + type: + type: string + url: + format: uri + type: string + was_edited: + type: boolean + type: object + chat.v2.service.role: + properties: + account_sid: + maxLength: 34 + minLength: 34 + pattern: ^AC[0-9a-fA-F]{32}$ + type: string + date_created: + format: date-time + type: string + date_updated: + format: date-time + type: string + friendly_name: + type: string + permissions: + items: + type: string + type: array + service_sid: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + sid: + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + type: + enum: + - channel + - deployment + type: string + url: + format: uri + type: string + type: object + chat.v2.service.user: + properties: + account_sid: + maxLength: 34 + minLength: 34 + pattern: ^AC[0-9a-fA-F]{32}$ + type: string + attributes: + type: string + date_created: + format: date-time + type: string + date_updated: + format: date-time + type: string + friendly_name: + type: string + identity: + type: string + is_notifiable: + type: boolean + is_online: + type: boolean + joined_channels_count: + type: integer + links: + type: object + role_sid: + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + service_sid: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + sid: + maxLength: 34 + minLength: 34 + pattern: ^US[0-9a-fA-F]{32}$ + type: string + url: + format: uri + type: string + type: object + chat.v2.service.user.user_binding: + properties: + account_sid: + maxLength: 34 + minLength: 34 + pattern: ^AC[0-9a-fA-F]{32}$ + type: string + binding_type: + enum: + - gcm + - apn + - fcm + type: string + credential_sid: + maxLength: 34 + minLength: 34 + pattern: ^CR[0-9a-fA-F]{32}$ + type: string + date_created: + format: date-time + type: string + date_updated: + format: date-time + type: string + endpoint: + type: string + identity: + type: string + message_types: + items: + type: string + type: array + service_sid: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + sid: + maxLength: 34 + minLength: 34 + pattern: ^BS[0-9a-fA-F]{32}$ + type: string + url: + format: uri + type: string + user_sid: + maxLength: 34 + minLength: 34 + pattern: ^US[0-9a-fA-F]{32}$ + type: string + type: object + chat.v2.service.user.user_channel: + properties: + account_sid: + maxLength: 34 + minLength: 34 + pattern: ^AC[0-9a-fA-F]{32}$ + type: string + channel_sid: + maxLength: 34 + minLength: 34 + pattern: ^CH[0-9a-fA-F]{32}$ + type: string + last_consumed_message_index: + nullable: true + type: integer + links: + type: object + member_sid: + maxLength: 34 + minLength: 34 + pattern: ^MB[0-9a-fA-F]{32}$ + type: string + notification_level: + enum: + - default + - muted + type: string + service_sid: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + status: + enum: + - joined + - invited + - not_participating + type: string + unread_messages_count: + nullable: true + type: integer + url: + format: uri + type: string + user_sid: + maxLength: 34 + minLength: 34 + pattern: ^US[0-9a-fA-F]{32}$ + type: string + type: object + securitySchemes: + accountSid_authToken: + scheme: basic + type: http +info: + contact: + email: support@twilio.com + name: Twilio Support + url: https://support.twilio.com + description: This is the public Twilio REST API. + license: + name: Apache 2.0 + url: https://www.apache.org/licenses/LICENSE-2.0.html + termsOfService: https://www.twilio.com/legal/tos + title: Twilio - Chat + version: 1.3.0 +openapi: 3.0.1 +paths: /v2/Credentials: description: Credentials for push notifications channels get: @@ -3542,7 +689,7 @@ paths: - GA servers: - url: https://chat.twilio.com - x-default-output-properties: &id009 + x-default-output-properties: &id001 - sid - friendly_name - type @@ -3655,7 +802,7 @@ paths: - GA servers: - url: https://chat.twilio.com - x-default-output-properties: *id009 + x-default-output-properties: *id001 x-path-type: instance /v2/Services: description: Top level scope for all chat resources @@ -3734,7 +881,7 @@ paths: - GA servers: - url: https://chat.twilio.com - x-default-output-properties: &id020 + x-default-output-properties: &id012 - sid - friendly_name - date_created @@ -3823,7 +970,7 @@ paths: - GA servers: - url: https://chat.twilio.com - x-default-output-properties: &id010 + x-default-output-properties: &id002 - sid - endpoint - identity @@ -3894,7 +1041,7 @@ paths: - GA servers: - url: https://chat.twilio.com - x-default-output-properties: *id010 + x-default-output-properties: *id002 x-path-type: instance /v2/Services/{ServiceSid}/Channels: description: Channels represent chat rooms @@ -4048,7 +1195,7 @@ paths: - GA servers: - url: https://chat.twilio.com - x-default-output-properties: &id015 + x-default-output-properties: &id007 - sid - unique_name - friendly_name @@ -4186,7 +1333,7 @@ paths: - GA servers: - url: https://chat.twilio.com - x-default-output-properties: &id011 + x-default-output-properties: &id003 - sid - identity - date_created @@ -4273,7 +1420,7 @@ paths: - GA servers: - url: https://chat.twilio.com - x-default-output-properties: *id011 + x-default-output-properties: *id003 x-path-type: instance /v2/Services/{ServiceSid}/Channels/{ChannelSid}/Members: description: Users joined to specific channels @@ -4450,7 +1597,7 @@ paths: - GA servers: - url: https://chat.twilio.com - x-default-output-properties: &id012 + x-default-output-properties: &id004 - sid - identity - date_created @@ -4630,7 +1777,7 @@ paths: - GA servers: - url: https://chat.twilio.com - x-default-output-properties: *id012 + x-default-output-properties: *id004 x-path-type: instance /v2/Services/{ServiceSid}/Channels/{ChannelSid}/Messages: description: Individual chat messages @@ -4794,7 +1941,7 @@ paths: - GA servers: - url: https://chat.twilio.com - x-default-output-properties: &id013 + x-default-output-properties: &id005 - sid - from - to @@ -4975,7 +2122,7 @@ paths: - GA servers: - url: https://chat.twilio.com - x-default-output-properties: *id013 + x-default-output-properties: *id005 x-path-type: instance /v2/Services/{ServiceSid}/Channels/{ChannelSid}/Webhooks: description: Webhooks for specific channels @@ -5135,7 +2282,7 @@ paths: - GA servers: - url: https://chat.twilio.com - x-default-output-properties: &id014 + x-default-output-properties: &id006 - sid - configuration x-path-type: list @@ -5308,7 +2455,7 @@ paths: - GA servers: - url: https://chat.twilio.com - x-default-output-properties: *id014 + x-default-output-properties: *id006 x-path-type: instance /v2/Services/{ServiceSid}/Channels/{Sid}: delete: @@ -5456,7 +2603,7 @@ paths: - GA servers: - url: https://chat.twilio.com - x-default-output-properties: *id015 + x-default-output-properties: *id007 x-path-type: instance /v2/Services/{ServiceSid}/Roles: description: Roles determining user or member permissions @@ -5574,7 +2721,7 @@ paths: - GA servers: - url: https://chat.twilio.com - x-default-output-properties: &id016 + x-default-output-properties: &id008 - sid - friendly_name - type @@ -5697,7 +2844,7 @@ paths: - GA servers: - url: https://chat.twilio.com - x-default-output-properties: *id016 + x-default-output-properties: *id008 x-path-type: instance /v2/Services/{ServiceSid}/Users: description: Unique chat users within a chat service @@ -5823,7 +2970,7 @@ paths: - GA servers: - url: https://chat.twilio.com - x-default-output-properties: &id017 + x-default-output-properties: &id009 - sid - friendly_name - identity @@ -5951,7 +3098,7 @@ paths: - GA servers: - url: https://chat.twilio.com - x-default-output-properties: *id017 + x-default-output-properties: *id009 x-path-type: instance /v2/Services/{ServiceSid}/Users/{UserSid}/Bindings: description: List of bindings for a given user @@ -6036,7 +3183,7 @@ paths: - GA servers: - url: https://chat.twilio.com - x-default-output-properties: &id018 + x-default-output-properties: &id010 - sid - endpoint - identity @@ -6124,7 +3271,7 @@ paths: - GA servers: - url: https://chat.twilio.com - x-default-output-properties: *id018 + x-default-output-properties: *id010 x-path-type: instance /v2/Services/{ServiceSid}/Users/{UserSid}/Channels: description: List of channels for a given user @@ -6196,7 +3343,7 @@ paths: - GA servers: - url: https://chat.twilio.com - x-default-output-properties: &id019 + x-default-output-properties: &id011 - channel_sid - status x-path-type: list @@ -6343,7 +3490,7 @@ paths: - GA servers: - url: https://chat.twilio.com - x-default-output-properties: *id019 + x-default-output-properties: *id011 x-path-type: instance /v2/Services/{Sid}: delete: @@ -6589,7 +3736,7 @@ paths: - GA servers: - url: https://chat.twilio.com - x-default-output-properties: *id020 + x-default-output-properties: *id012 x-path-type: instance tags: - description: This product is Generally Available. diff --git a/spec/yaml/twilio_conversations.yaml b/spec/yaml/twilio_conversations_v1.yaml similarity index 100% rename from spec/yaml/twilio_conversations.yaml rename to spec/yaml/twilio_conversations_v1.yaml diff --git a/spec/yaml/twilio_events.yaml b/spec/yaml/twilio_events_v1.yaml similarity index 100% rename from spec/yaml/twilio_events.yaml rename to spec/yaml/twilio_events_v1.yaml diff --git a/spec/yaml/twilio_fax.yaml b/spec/yaml/twilio_fax_v1.yaml similarity index 100% rename from spec/yaml/twilio_fax.yaml rename to spec/yaml/twilio_fax_v1.yaml diff --git a/spec/yaml/twilio_flex.yaml b/spec/yaml/twilio_flex_v1.yaml similarity index 100% rename from spec/yaml/twilio_flex.yaml rename to spec/yaml/twilio_flex_v1.yaml diff --git a/spec/yaml/twilio_insights.yaml b/spec/yaml/twilio_insights_v1.yaml similarity index 100% rename from spec/yaml/twilio_insights.yaml rename to spec/yaml/twilio_insights_v1.yaml diff --git a/spec/yaml/twilio_ip_messaging_v1.yaml b/spec/yaml/twilio_ip_messaging_v1.yaml new file mode 100644 index 00000000..4f7565d2 --- /dev/null +++ b/spec/yaml/twilio_ip_messaging_v1.yaml @@ -0,0 +1,2656 @@ +components: + schemas: + ip_messaging.v1.credential: + properties: + account_sid: + maxLength: 34 + minLength: 34 + pattern: ^AC[0-9a-fA-F]{32}$ + type: string + date_created: + format: date-time + type: string + date_updated: + format: date-time + type: string + friendly_name: + type: string + sandbox: + type: string + sid: + maxLength: 34 + minLength: 34 + pattern: ^CR[0-9a-fA-F]{32}$ + type: string + type: + enum: + - gcm + - apn + - fcm + type: string + url: + format: uri + type: string + type: object + ip_messaging.v1.service: + properties: + account_sid: + maxLength: 34 + minLength: 34 + pattern: ^AC[0-9a-fA-F]{32}$ + type: string + consumption_report_interval: + type: integer + date_created: + format: date-time + type: string + date_updated: + format: date-time + type: string + default_channel_creator_role_sid: + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + default_channel_role_sid: + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + default_service_role_sid: + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + friendly_name: + type: string + limits: + type: object + links: + type: object + notifications: + type: object + post_webhook_url: + type: string + pre_webhook_url: + type: string + reachability_enabled: + type: boolean + read_status_enabled: + type: boolean + sid: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + typing_indicator_timeout: + type: integer + url: + format: uri + type: string + webhook_filters: + items: + type: string + type: array + webhook_method: + type: string + webhooks: + type: object + type: object + ip_messaging.v1.service.channel: + properties: + account_sid: + maxLength: 34 + minLength: 34 + pattern: ^AC[0-9a-fA-F]{32}$ + type: string + attributes: + type: string + created_by: + type: string + date_created: + format: date-time + type: string + date_updated: + format: date-time + type: string + friendly_name: + type: string + links: + type: object + members_count: + type: integer + messages_count: + type: integer + service_sid: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + sid: + maxLength: 34 + minLength: 34 + pattern: ^CH[0-9a-fA-F]{32}$ + type: string + type: + enum: + - public + - private + type: string + unique_name: + type: string + url: + format: uri + type: string + type: object + ip_messaging.v1.service.channel.invite: + properties: + account_sid: + maxLength: 34 + minLength: 34 + pattern: ^AC[0-9a-fA-F]{32}$ + type: string + channel_sid: + maxLength: 34 + minLength: 34 + pattern: ^CH[0-9a-fA-F]{32}$ + type: string + created_by: + type: string + date_created: + format: date-time + type: string + date_updated: + format: date-time + type: string + identity: + type: string + role_sid: + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + service_sid: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + sid: + maxLength: 34 + minLength: 34 + pattern: ^IN[0-9a-fA-F]{32}$ + type: string + url: + format: uri + type: string + type: object + ip_messaging.v1.service.channel.member: + properties: + account_sid: + maxLength: 34 + minLength: 34 + pattern: ^AC[0-9a-fA-F]{32}$ + type: string + channel_sid: + maxLength: 34 + minLength: 34 + pattern: ^CH[0-9a-fA-F]{32}$ + type: string + date_created: + format: date-time + type: string + date_updated: + format: date-time + type: string + identity: + type: string + last_consumed_message_index: + nullable: true + type: integer + last_consumption_timestamp: + format: date-time + type: string + role_sid: + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + service_sid: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + sid: + maxLength: 34 + minLength: 34 + pattern: ^MB[0-9a-fA-F]{32}$ + type: string + url: + format: uri + type: string + type: object + ip_messaging.v1.service.channel.message: + properties: + account_sid: + maxLength: 34 + minLength: 34 + pattern: ^AC[0-9a-fA-F]{32}$ + type: string + attributes: + type: string + body: + type: string + channel_sid: + maxLength: 34 + minLength: 34 + pattern: ^CH[0-9a-fA-F]{32}$ + type: string + date_created: + format: date-time + type: string + date_updated: + format: date-time + type: string + from: + type: string + index: + type: integer + service_sid: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + sid: + maxLength: 34 + minLength: 34 + pattern: ^IM[0-9a-fA-F]{32}$ + type: string + to: + maxLength: 34 + minLength: 34 + pattern: ^CH[0-9a-fA-F]{32}$ + type: string + url: + format: uri + type: string + was_edited: + type: boolean + type: object + ip_messaging.v1.service.role: + properties: + account_sid: + maxLength: 34 + minLength: 34 + pattern: ^AC[0-9a-fA-F]{32}$ + type: string + date_created: + format: date-time + type: string + date_updated: + format: date-time + type: string + friendly_name: + type: string + permissions: + items: + type: string + type: array + service_sid: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + sid: + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + type: + enum: + - channel + - deployment + type: string + url: + format: uri + type: string + type: object + ip_messaging.v1.service.user: + properties: + account_sid: + maxLength: 34 + minLength: 34 + pattern: ^AC[0-9a-fA-F]{32}$ + type: string + attributes: + type: string + date_created: + format: date-time + type: string + date_updated: + format: date-time + type: string + friendly_name: + type: string + identity: + type: string + is_notifiable: + type: boolean + is_online: + type: boolean + joined_channels_count: + type: integer + links: + type: object + role_sid: + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + service_sid: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + sid: + maxLength: 34 + minLength: 34 + pattern: ^US[0-9a-fA-F]{32}$ + type: string + url: + format: uri + type: string + type: object + ip_messaging.v1.service.user.user_channel: + properties: + account_sid: + maxLength: 34 + minLength: 34 + pattern: ^AC[0-9a-fA-F]{32}$ + type: string + channel_sid: + maxLength: 34 + minLength: 34 + pattern: ^CH[0-9a-fA-F]{32}$ + type: string + last_consumed_message_index: + nullable: true + type: integer + links: + type: object + member_sid: + maxLength: 34 + minLength: 34 + pattern: ^MB[0-9a-fA-F]{32}$ + type: string + service_sid: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + status: + enum: + - joined + - invited + - not_participating + type: string + unread_messages_count: + nullable: true + type: integer + type: object + securitySchemes: + accountSid_authToken: + scheme: basic + type: http +info: + contact: + email: support@twilio.com + name: Twilio Support + url: https://support.twilio.com + description: This is the public Twilio REST API. + license: + name: Apache 2.0 + url: https://www.apache.org/licenses/LICENSE-2.0.html + termsOfService: https://www.twilio.com/legal/tos + title: Twilio - Ip_messaging + version: 1.3.0 +openapi: 3.0.1 +paths: + /v1/Credentials: + description: 'TODO: Resource-level docs' + get: + description: '' + parameters: + - description: How many resources to return in each list page. The default is + 50, and the maximum is 1000. + in: query + name: PageSize + schema: + maximum: 1000 + minimum: 1 + type: integer + responses: + 200: + content: + application/json: + schema: + properties: + credentials: + items: + $ref: '#/components/schemas/ip_messaging.v1.credential' + type: array + meta: + properties: + first_page_url: + format: uri + type: string + key: + type: string + next_page_url: + format: uri + type: string + page: + type: integer + page_size: + type: integer + previous_page_url: + format: uri + type: string + url: + format: uri + type: string + type: object + type: object + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + post: + description: '' + requestBody: + content: + application/x-www-form-urlencoded: + schema: + properties: + ApiKey: + description: '' + type: string + Certificate: + description: '' + type: string + FriendlyName: + description: '' + type: string + PrivateKey: + description: '' + type: string + Sandbox: + description: '' + type: boolean + Secret: + description: '' + type: string + Type: + description: '' + enum: + - gcm + - apn + - fcm + type: string + required: + - Type + type: object + responses: + 201: + content: + application/json: + schema: + $ref: '#/components/schemas/ip_messaging.v1.credential' + description: Created + security: + - accountSid_authToken: [] + tags: + - GA + servers: + - url: https://ip-messaging.twilio.com + x-default-output-properties: &id001 + - sid + - friendly_name + - type + x-path-type: list + /v1/Credentials/{Sid}: + delete: + description: '' + parameters: + - description: '' + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^CR[0-9a-fA-F]{32}$ + type: string + responses: + 204: + description: The resource was deleted successfully. + security: + - accountSid_authToken: [] + tags: + - GA + description: 'TODO: Resource-level docs' + get: + description: '' + parameters: + - description: '' + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^CR[0-9a-fA-F]{32}$ + type: string + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/ip_messaging.v1.credential' + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + post: + description: '' + parameters: + - description: '' + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^CR[0-9a-fA-F]{32}$ + type: string + requestBody: + content: + application/x-www-form-urlencoded: + schema: + properties: + ApiKey: + description: '' + type: string + Certificate: + description: '' + type: string + FriendlyName: + description: '' + type: string + PrivateKey: + description: '' + type: string + Sandbox: + description: '' + type: boolean + Secret: + description: '' + type: string + type: object + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/ip_messaging.v1.credential' + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + servers: + - url: https://ip-messaging.twilio.com + x-default-output-properties: *id001 + x-path-type: instance + /v1/Services: + description: 'TODO: Resource-level docs' + get: + description: '' + parameters: + - description: How many resources to return in each list page. The default is + 50, and the maximum is 1000. + in: query + name: PageSize + schema: + maximum: 1000 + minimum: 1 + type: integer + responses: + 200: + content: + application/json: + schema: + properties: + meta: + properties: + first_page_url: + format: uri + type: string + key: + type: string + next_page_url: + format: uri + type: string + page: + type: integer + page_size: + type: integer + previous_page_url: + format: uri + type: string + url: + format: uri + type: string + type: object + services: + items: + $ref: '#/components/schemas/ip_messaging.v1.service' + type: array + type: object + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + post: + description: '' + requestBody: + content: + application/x-www-form-urlencoded: + schema: + properties: + FriendlyName: + description: '' + type: string + required: + - FriendlyName + type: object + responses: + 201: + content: + application/json: + schema: + $ref: '#/components/schemas/ip_messaging.v1.service' + description: Created + security: + - accountSid_authToken: [] + tags: + - GA + servers: + - url: https://ip-messaging.twilio.com + x-default-output-properties: &id008 + - sid + - friendly_name + - date_created + x-path-type: list + /v1/Services/{ServiceSid}/Channels: + description: 'TODO: Resource-level docs' + get: + description: '' + parameters: + - description: '' + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: '' + in: query + name: Type + schema: + items: + enum: + - public + - private + type: string + type: array + - description: How many resources to return in each list page. The default is + 50, and the maximum is 1000. + in: query + name: PageSize + schema: + maximum: 1000 + minimum: 1 + type: integer + responses: + 200: + content: + application/json: + schema: + properties: + channels: + items: + $ref: '#/components/schemas/ip_messaging.v1.service.channel' + type: array + meta: + properties: + first_page_url: + format: uri + type: string + key: + type: string + next_page_url: + format: uri + type: string + page: + type: integer + page_size: + type: integer + previous_page_url: + format: uri + type: string + url: + format: uri + type: string + type: object + type: object + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + post: + description: '' + parameters: + - description: '' + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + requestBody: + content: + application/x-www-form-urlencoded: + schema: + properties: + Attributes: + description: '' + type: string + FriendlyName: + description: '' + type: string + Type: + description: '' + enum: + - public + - private + type: string + UniqueName: + description: '' + type: string + type: object + responses: + 201: + content: + application/json: + schema: + $ref: '#/components/schemas/ip_messaging.v1.service.channel' + description: Created + security: + - accountSid_authToken: [] + tags: + - GA + servers: + - url: https://ip-messaging.twilio.com + x-default-output-properties: &id005 + - sid + - unique_name + - friendly_name + x-path-type: list + /v1/Services/{ServiceSid}/Channels/{ChannelSid}/Invites: + description: 'TODO: Resource-level docs' + get: + description: '' + parameters: + - description: '' + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: '' + in: path + name: ChannelSid + required: true + schema: + type: string + - description: '' + in: query + name: Identity + schema: + items: + type: string + type: array + - description: How many resources to return in each list page. The default is + 50, and the maximum is 1000. + in: query + name: PageSize + schema: + maximum: 1000 + minimum: 1 + type: integer + responses: + 200: + content: + application/json: + schema: + properties: + invites: + items: + $ref: '#/components/schemas/ip_messaging.v1.service.channel.invite' + type: array + meta: + properties: + first_page_url: + format: uri + type: string + key: + type: string + next_page_url: + format: uri + type: string + page: + type: integer + page_size: + type: integer + previous_page_url: + format: uri + type: string + url: + format: uri + type: string + type: object + type: object + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + post: + description: '' + parameters: + - description: '' + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: '' + in: path + name: ChannelSid + required: true + schema: + type: string + requestBody: + content: + application/x-www-form-urlencoded: + schema: + properties: + Identity: + description: '' + type: string + RoleSid: + description: '' + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + required: + - Identity + type: object + responses: + 201: + content: + application/json: + schema: + $ref: '#/components/schemas/ip_messaging.v1.service.channel.invite' + description: Created + security: + - accountSid_authToken: [] + tags: + - GA + servers: + - url: https://ip-messaging.twilio.com + x-default-output-properties: &id002 + - sid + - identity + - date_created + x-path-type: list + /v1/Services/{ServiceSid}/Channels/{ChannelSid}/Invites/{Sid}: + delete: + description: '' + parameters: + - description: '' + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: '' + in: path + name: ChannelSid + required: true + schema: + type: string + - description: '' + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IN[0-9a-fA-F]{32}$ + type: string + responses: + 204: + description: The resource was deleted successfully. + security: + - accountSid_authToken: [] + tags: + - GA + description: 'TODO: Resource-level docs' + get: + description: '' + parameters: + - description: '' + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: '' + in: path + name: ChannelSid + required: true + schema: + type: string + - description: '' + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IN[0-9a-fA-F]{32}$ + type: string + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/ip_messaging.v1.service.channel.invite' + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + servers: + - url: https://ip-messaging.twilio.com + x-default-output-properties: *id002 + x-path-type: instance + /v1/Services/{ServiceSid}/Channels/{ChannelSid}/Members: + description: 'TODO: Resource-level docs' + get: + description: '' + parameters: + - description: '' + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: '' + in: path + name: ChannelSid + required: true + schema: + type: string + - description: '' + in: query + name: Identity + schema: + items: + type: string + type: array + - description: How many resources to return in each list page. The default is + 50, and the maximum is 1000. + in: query + name: PageSize + schema: + maximum: 1000 + minimum: 1 + type: integer + responses: + 200: + content: + application/json: + schema: + properties: + members: + items: + $ref: '#/components/schemas/ip_messaging.v1.service.channel.member' + type: array + meta: + properties: + first_page_url: + format: uri + type: string + key: + type: string + next_page_url: + format: uri + type: string + page: + type: integer + page_size: + type: integer + previous_page_url: + format: uri + type: string + url: + format: uri + type: string + type: object + type: object + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + post: + description: '' + parameters: + - description: '' + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: '' + in: path + name: ChannelSid + required: true + schema: + type: string + requestBody: + content: + application/x-www-form-urlencoded: + schema: + properties: + Identity: + description: '' + type: string + RoleSid: + description: '' + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + required: + - Identity + type: object + responses: + 201: + content: + application/json: + schema: + $ref: '#/components/schemas/ip_messaging.v1.service.channel.member' + description: Created + security: + - accountSid_authToken: [] + tags: + - GA + servers: + - url: https://ip-messaging.twilio.com + x-default-output-properties: &id003 + - sid + - identity + - date_created + x-path-type: list + /v1/Services/{ServiceSid}/Channels/{ChannelSid}/Members/{Sid}: + delete: + description: '' + parameters: + - description: '' + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: '' + in: path + name: ChannelSid + required: true + schema: + type: string + - description: '' + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^MB[0-9a-fA-F]{32}$ + type: string + responses: + 204: + description: The resource was deleted successfully. + security: + - accountSid_authToken: [] + tags: + - GA + description: 'TODO: Resource-level docs' + get: + description: '' + parameters: + - description: '' + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: '' + in: path + name: ChannelSid + required: true + schema: + type: string + - description: '' + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^MB[0-9a-fA-F]{32}$ + type: string + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/ip_messaging.v1.service.channel.member' + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + post: + description: '' + parameters: + - description: '' + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: '' + in: path + name: ChannelSid + required: true + schema: + type: string + - description: '' + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^MB[0-9a-fA-F]{32}$ + type: string + requestBody: + content: + application/x-www-form-urlencoded: + schema: + properties: + LastConsumedMessageIndex: + description: '' + nullable: true + type: integer + RoleSid: + description: '' + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + type: object + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/ip_messaging.v1.service.channel.member' + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + servers: + - url: https://ip-messaging.twilio.com + x-default-output-properties: *id003 + x-path-type: instance + /v1/Services/{ServiceSid}/Channels/{ChannelSid}/Messages: + description: 'TODO: Resource-level docs' + get: + description: '' + parameters: + - description: '' + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: '' + in: path + name: ChannelSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^CH[0-9a-fA-F]{32}$ + type: string + - description: '' + in: query + name: Order + schema: + enum: + - asc + - desc + type: string + - description: How many resources to return in each list page. The default is + 50, and the maximum is 1000. + in: query + name: PageSize + schema: + maximum: 1000 + minimum: 1 + type: integer + responses: + 200: + content: + application/json: + schema: + properties: + messages: + items: + $ref: '#/components/schemas/ip_messaging.v1.service.channel.message' + type: array + meta: + properties: + first_page_url: + format: uri + type: string + key: + type: string + next_page_url: + format: uri + type: string + page: + type: integer + page_size: + type: integer + previous_page_url: + format: uri + type: string + url: + format: uri + type: string + type: object + type: object + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + post: + description: '' + parameters: + - description: '' + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: '' + in: path + name: ChannelSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^CH[0-9a-fA-F]{32}$ + type: string + requestBody: + content: + application/x-www-form-urlencoded: + schema: + properties: + Attributes: + description: '' + type: string + Body: + description: '' + type: string + From: + description: '' + type: string + required: + - Body + type: object + responses: + 201: + content: + application/json: + schema: + $ref: '#/components/schemas/ip_messaging.v1.service.channel.message' + description: Created + security: + - accountSid_authToken: [] + tags: + - GA + servers: + - url: https://ip-messaging.twilio.com + x-default-output-properties: &id004 + - sid + - from + - to + - date_created + x-path-type: list + /v1/Services/{ServiceSid}/Channels/{ChannelSid}/Messages/{Sid}: + delete: + description: '' + parameters: + - description: '' + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: '' + in: path + name: ChannelSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^CH[0-9a-fA-F]{32}$ + type: string + - description: '' + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IM[0-9a-fA-F]{32}$ + type: string + responses: + 204: + description: The resource was deleted successfully. + security: + - accountSid_authToken: [] + tags: + - GA + description: 'TODO: Resource-level docs' + get: + description: '' + parameters: + - description: '' + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: '' + in: path + name: ChannelSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^CH[0-9a-fA-F]{32}$ + type: string + - description: '' + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IM[0-9a-fA-F]{32}$ + type: string + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/ip_messaging.v1.service.channel.message' + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + post: + description: '' + parameters: + - description: '' + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: '' + in: path + name: ChannelSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^CH[0-9a-fA-F]{32}$ + type: string + - description: '' + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IM[0-9a-fA-F]{32}$ + type: string + requestBody: + content: + application/x-www-form-urlencoded: + schema: + properties: + Attributes: + description: '' + type: string + Body: + description: '' + type: string + type: object + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/ip_messaging.v1.service.channel.message' + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + servers: + - url: https://ip-messaging.twilio.com + x-default-output-properties: *id004 + x-path-type: instance + /v1/Services/{ServiceSid}/Channels/{Sid}: + delete: + description: '' + parameters: + - description: '' + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: '' + in: path + name: Sid + required: true + schema: + type: string + responses: + 204: + description: The resource was deleted successfully. + security: + - accountSid_authToken: [] + tags: + - GA + description: 'TODO: Resource-level docs' + get: + description: '' + parameters: + - description: '' + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: '' + in: path + name: Sid + required: true + schema: + type: string + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/ip_messaging.v1.service.channel' + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + post: + description: '' + parameters: + - description: '' + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: '' + in: path + name: Sid + required: true + schema: + type: string + requestBody: + content: + application/x-www-form-urlencoded: + schema: + properties: + Attributes: + description: '' + type: string + FriendlyName: + description: '' + type: string + UniqueName: + description: '' + type: string + type: object + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/ip_messaging.v1.service.channel' + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + servers: + - url: https://ip-messaging.twilio.com + x-default-output-properties: *id005 + x-path-type: instance + /v1/Services/{ServiceSid}/Roles: + description: 'TODO: Resource-level docs' + get: + description: '' + parameters: + - description: '' + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: How many resources to return in each list page. The default is + 50, and the maximum is 1000. + in: query + name: PageSize + schema: + maximum: 1000 + minimum: 1 + type: integer + responses: + 200: + content: + application/json: + schema: + properties: + meta: + properties: + first_page_url: + format: uri + type: string + key: + type: string + next_page_url: + format: uri + type: string + page: + type: integer + page_size: + type: integer + previous_page_url: + format: uri + type: string + url: + format: uri + type: string + type: object + roles: + items: + $ref: '#/components/schemas/ip_messaging.v1.service.role' + type: array + type: object + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + post: + description: '' + parameters: + - description: '' + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + requestBody: + content: + application/x-www-form-urlencoded: + schema: + properties: + FriendlyName: + description: '' + type: string + Permission: + description: '' + items: + type: string + type: array + Type: + description: '' + enum: + - channel + - deployment + type: string + required: + - FriendlyName + - Type + - Permission + type: object + responses: + 201: + content: + application/json: + schema: + $ref: '#/components/schemas/ip_messaging.v1.service.role' + description: Created + security: + - accountSid_authToken: [] + tags: + - GA + servers: + - url: https://ip-messaging.twilio.com + x-default-output-properties: &id006 + - sid + - friendly_name + - type + x-path-type: list + /v1/Services/{ServiceSid}/Roles/{Sid}: + delete: + description: '' + parameters: + - description: '' + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: '' + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + responses: + 204: + description: The resource was deleted successfully. + security: + - accountSid_authToken: [] + tags: + - GA + description: 'TODO: Resource-level docs' + get: + description: '' + parameters: + - description: '' + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: '' + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/ip_messaging.v1.service.role' + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + post: + description: '' + parameters: + - description: '' + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: '' + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + requestBody: + content: + application/x-www-form-urlencoded: + schema: + properties: + Permission: + description: '' + items: + type: string + type: array + required: + - Permission + type: object + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/ip_messaging.v1.service.role' + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + servers: + - url: https://ip-messaging.twilio.com + x-default-output-properties: *id006 + x-path-type: instance + /v1/Services/{ServiceSid}/Users: + description: 'TODO: Resource-level docs' + get: + description: '' + parameters: + - description: '' + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: How many resources to return in each list page. The default is + 50, and the maximum is 1000. + in: query + name: PageSize + schema: + maximum: 1000 + minimum: 1 + type: integer + responses: + 200: + content: + application/json: + schema: + properties: + meta: + properties: + first_page_url: + format: uri + type: string + key: + type: string + next_page_url: + format: uri + type: string + page: + type: integer + page_size: + type: integer + previous_page_url: + format: uri + type: string + url: + format: uri + type: string + type: object + users: + items: + $ref: '#/components/schemas/ip_messaging.v1.service.user' + type: array + type: object + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + post: + description: '' + parameters: + - description: '' + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + requestBody: + content: + application/x-www-form-urlencoded: + schema: + properties: + Attributes: + description: '' + type: string + FriendlyName: + description: '' + type: string + Identity: + description: '' + type: string + RoleSid: + description: '' + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + required: + - Identity + type: object + responses: + 201: + content: + application/json: + schema: + $ref: '#/components/schemas/ip_messaging.v1.service.user' + description: Created + security: + - accountSid_authToken: [] + tags: + - GA + servers: + - url: https://ip-messaging.twilio.com + x-default-output-properties: &id007 + - sid + - friendly_name + - date_created + x-path-type: list + /v1/Services/{ServiceSid}/Users/{Sid}: + delete: + description: '' + parameters: + - description: '' + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: '' + in: path + name: Sid + required: true + schema: + type: string + responses: + 204: + description: The resource was deleted successfully. + security: + - accountSid_authToken: [] + tags: + - GA + description: 'TODO: Resource-level docs' + get: + description: '' + parameters: + - description: '' + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: '' + in: path + name: Sid + required: true + schema: + type: string + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/ip_messaging.v1.service.user' + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + post: + description: '' + parameters: + - description: '' + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: '' + in: path + name: Sid + required: true + schema: + type: string + requestBody: + content: + application/x-www-form-urlencoded: + schema: + properties: + Attributes: + description: '' + type: string + FriendlyName: + description: '' + type: string + RoleSid: + description: '' + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + type: object + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/ip_messaging.v1.service.user' + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + servers: + - url: https://ip-messaging.twilio.com + x-default-output-properties: *id007 + x-path-type: instance + /v1/Services/{ServiceSid}/Users/{UserSid}/Channels: + description: 'TODO: Resource-level docs' + get: + description: '' + parameters: + - description: '' + in: path + name: ServiceSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + - description: '' + in: path + name: UserSid + required: true + schema: + type: string + - description: How many resources to return in each list page. The default is + 50, and the maximum is 1000. + in: query + name: PageSize + schema: + maximum: 1000 + minimum: 1 + type: integer + responses: + 200: + content: + application/json: + schema: + properties: + channels: + items: + $ref: '#/components/schemas/ip_messaging.v1.service.user.user_channel' + type: array + meta: + properties: + first_page_url: + format: uri + type: string + key: + type: string + next_page_url: + format: uri + type: string + page: + type: integer + page_size: + type: integer + previous_page_url: + format: uri + type: string + url: + format: uri + type: string + type: object + type: object + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + servers: + - url: https://ip-messaging.twilio.com + x-default-output-properties: + - channel_sid + - status + x-path-type: list + /v1/Services/{Sid}: + delete: + description: '' + parameters: + - description: '' + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + responses: + 204: + description: The resource was deleted successfully. + security: + - accountSid_authToken: [] + tags: + - GA + description: 'TODO: Resource-level docs' + get: + description: '' + parameters: + - description: '' + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/ip_messaging.v1.service' + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + post: + description: '' + parameters: + - description: '' + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + requestBody: + content: + application/x-www-form-urlencoded: + schema: + properties: + ConsumptionReportInterval: + description: '' + type: integer + DefaultChannelCreatorRoleSid: + description: '' + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + DefaultChannelRoleSid: + description: '' + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + DefaultServiceRoleSid: + description: '' + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + FriendlyName: + description: '' + type: string + Limits.ChannelMembers: + description: '' + type: integer + Limits.UserChannels: + description: '' + type: integer + Notifications.AddedToChannel.Enabled: + description: '' + type: boolean + Notifications.AddedToChannel.Template: + description: '' + type: string + Notifications.InvitedToChannel.Enabled: + description: '' + type: boolean + Notifications.InvitedToChannel.Template: + description: '' + type: string + Notifications.NewMessage.Enabled: + description: '' + type: boolean + Notifications.NewMessage.Template: + description: '' + type: string + Notifications.RemovedFromChannel.Enabled: + description: '' + type: boolean + Notifications.RemovedFromChannel.Template: + description: '' + type: string + PostWebhookUrl: + description: '' + format: uri + type: string + PreWebhookUrl: + description: '' + format: uri + type: string + ReachabilityEnabled: + description: '' + type: boolean + ReadStatusEnabled: + description: '' + type: boolean + TypingIndicatorTimeout: + description: '' + type: integer + WebhookFilters: + description: '' + items: + type: string + type: array + WebhookMethod: + description: '' + enum: + - head + - get + - post + - patch + - put + - delete + - HEAD + - GET + - POST + - PATCH + - PUT + - DELETE + type: string + Webhooks.OnChannelAdd.Method: + description: '' + enum: + - head + - get + - post + - patch + - put + - delete + - HEAD + - GET + - POST + - PATCH + - PUT + - DELETE + type: string + Webhooks.OnChannelAdd.Url: + description: '' + format: uri + type: string + Webhooks.OnChannelAdded.Method: + description: '' + enum: + - head + - get + - post + - patch + - put + - delete + - HEAD + - GET + - POST + - PATCH + - PUT + - DELETE + type: string + Webhooks.OnChannelAdded.Url: + description: '' + format: uri + type: string + Webhooks.OnChannelDestroy.Method: + description: '' + enum: + - head + - get + - post + - patch + - put + - delete + - HEAD + - GET + - POST + - PATCH + - PUT + - DELETE + type: string + Webhooks.OnChannelDestroy.Url: + description: '' + format: uri + type: string + Webhooks.OnChannelDestroyed.Method: + description: '' + enum: + - head + - get + - post + - patch + - put + - delete + - HEAD + - GET + - POST + - PATCH + - PUT + - DELETE + type: string + Webhooks.OnChannelDestroyed.Url: + description: '' + format: uri + type: string + Webhooks.OnChannelUpdate.Method: + description: '' + enum: + - head + - get + - post + - patch + - put + - delete + - HEAD + - GET + - POST + - PATCH + - PUT + - DELETE + type: string + Webhooks.OnChannelUpdate.Url: + description: '' + format: uri + type: string + Webhooks.OnChannelUpdated.Method: + description: '' + enum: + - head + - get + - post + - patch + - put + - delete + - HEAD + - GET + - POST + - PATCH + - PUT + - DELETE + type: string + Webhooks.OnChannelUpdated.Url: + description: '' + format: uri + type: string + Webhooks.OnMemberAdd.Method: + description: '' + enum: + - head + - get + - post + - patch + - put + - delete + - HEAD + - GET + - POST + - PATCH + - PUT + - DELETE + type: string + Webhooks.OnMemberAdd.Url: + description: '' + format: uri + type: string + Webhooks.OnMemberAdded.Method: + description: '' + enum: + - head + - get + - post + - patch + - put + - delete + - HEAD + - GET + - POST + - PATCH + - PUT + - DELETE + type: string + Webhooks.OnMemberAdded.Url: + description: '' + format: uri + type: string + Webhooks.OnMemberRemove.Method: + description: '' + enum: + - head + - get + - post + - patch + - put + - delete + - HEAD + - GET + - POST + - PATCH + - PUT + - DELETE + type: string + Webhooks.OnMemberRemove.Url: + description: '' + format: uri + type: string + Webhooks.OnMemberRemoved.Method: + description: '' + enum: + - head + - get + - post + - patch + - put + - delete + - HEAD + - GET + - POST + - PATCH + - PUT + - DELETE + type: string + Webhooks.OnMemberRemoved.Url: + description: '' + format: uri + type: string + Webhooks.OnMessageRemove.Method: + description: '' + enum: + - head + - get + - post + - patch + - put + - delete + - HEAD + - GET + - POST + - PATCH + - PUT + - DELETE + type: string + Webhooks.OnMessageRemove.Url: + description: '' + format: uri + type: string + Webhooks.OnMessageRemoved.Method: + description: '' + enum: + - head + - get + - post + - patch + - put + - delete + - HEAD + - GET + - POST + - PATCH + - PUT + - DELETE + type: string + Webhooks.OnMessageRemoved.Url: + description: '' + format: uri + type: string + Webhooks.OnMessageSend.Method: + description: '' + enum: + - head + - get + - post + - patch + - put + - delete + - HEAD + - GET + - POST + - PATCH + - PUT + - DELETE + type: string + Webhooks.OnMessageSend.Url: + description: '' + format: uri + type: string + Webhooks.OnMessageSent.Method: + description: '' + enum: + - head + - get + - post + - patch + - put + - delete + - HEAD + - GET + - POST + - PATCH + - PUT + - DELETE + type: string + Webhooks.OnMessageSent.Url: + description: '' + format: uri + type: string + Webhooks.OnMessageUpdate.Method: + description: '' + enum: + - head + - get + - post + - patch + - put + - delete + - HEAD + - GET + - POST + - PATCH + - PUT + - DELETE + type: string + Webhooks.OnMessageUpdate.Url: + description: '' + format: uri + type: string + Webhooks.OnMessageUpdated.Method: + description: '' + enum: + - head + - get + - post + - patch + - put + - delete + - HEAD + - GET + - POST + - PATCH + - PUT + - DELETE + type: string + Webhooks.OnMessageUpdated.Url: + description: '' + format: uri + type: string + type: object + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/ip_messaging.v1.service' + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + servers: + - url: https://ip-messaging.twilio.com + x-default-output-properties: *id008 + x-path-type: instance +tags: +- description: This product is Generally Available. + name: GA diff --git a/spec/yaml/twilio_ip_messaging.yaml b/spec/yaml/twilio_ip_messaging_v2.yaml similarity index 56% rename from spec/yaml/twilio_ip_messaging.yaml rename to spec/yaml/twilio_ip_messaging_v2.yaml index c8a95c57..c589ba4d 100644 --- a/spec/yaml/twilio_ip_messaging.yaml +++ b/spec/yaml/twilio_ip_messaging_v2.yaml @@ -1,6 +1,6 @@ components: schemas: - ip_messaging.v1.credential: + ip_messaging.v2.credential: properties: account_sid: maxLength: 34 @@ -32,7 +32,7 @@ components: format: uri type: string type: object - ip_messaging.v1.service: + ip_messaging.v2.service: properties: account_sid: maxLength: 34 @@ -68,10 +68,16 @@ components: type: object links: type: object + media: + type: object notifications: type: object + post_webhook_retry_count: + type: integer post_webhook_url: type: string + pre_webhook_retry_count: + type: integer pre_webhook_url: type: string reachability_enabled: @@ -94,19 +100,24 @@ components: type: array webhook_method: type: string - webhooks: - type: object type: object - ip_messaging.v1.service.channel: + ip_messaging.v2.service.binding: properties: account_sid: maxLength: 34 minLength: 34 pattern: ^AC[0-9a-fA-F]{32}$ type: string - attributes: + binding_type: + enum: + - gcm + - apn + - fcm type: string - created_by: + credential_sid: + maxLength: 34 + minLength: 34 + pattern: ^CR[0-9a-fA-F]{32}$ type: string date_created: format: date-time @@ -114,14 +125,16 @@ components: date_updated: format: date-time type: string - friendly_name: + endpoint: + type: string + identity: type: string links: type: object - members_count: - type: integer - messages_count: - type: integer + message_types: + items: + type: string + type: array service_sid: maxLength: 34 minLength: 34 @@ -130,30 +143,20 @@ components: sid: maxLength: 34 minLength: 34 - pattern: ^CH[0-9a-fA-F]{32}$ - type: string - type: - enum: - - public - - private - type: string - unique_name: + pattern: ^BS[0-9a-fA-F]{32}$ type: string url: format: uri type: string type: object - ip_messaging.v1.service.channel.invite: + ip_messaging.v2.service.channel: properties: account_sid: maxLength: 34 minLength: 34 pattern: ^AC[0-9a-fA-F]{32}$ type: string - channel_sid: - maxLength: 34 - minLength: 34 - pattern: ^CH[0-9a-fA-F]{32}$ + attributes: type: string created_by: type: string @@ -163,13 +166,14 @@ components: date_updated: format: date-time type: string - identity: - type: string - role_sid: - maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ + friendly_name: type: string + links: + type: object + members_count: + type: integer + messages_count: + type: integer service_sid: maxLength: 34 minLength: 34 @@ -178,13 +182,20 @@ components: sid: maxLength: 34 minLength: 34 - pattern: ^IN[0-9a-fA-F]{32}$ + pattern: ^CH[0-9a-fA-F]{32}$ + type: string + type: + enum: + - public + - private + type: string + unique_name: type: string url: format: uri type: string type: object - ip_messaging.v1.service.channel.member: + ip_messaging.v2.service.channel.channel_webhook: properties: account_sid: maxLength: 34 @@ -196,25 +207,14 @@ components: minLength: 34 pattern: ^CH[0-9a-fA-F]{32}$ type: string + configuration: + type: object date_created: format: date-time type: string date_updated: format: date-time type: string - identity: - type: string - last_consumed_message_index: - nullable: true - type: integer - last_consumption_timestamp: - format: date-time - type: string - role_sid: - maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ - type: string service_sid: maxLength: 34 minLength: 34 @@ -223,78 +223,41 @@ components: sid: maxLength: 34 minLength: 34 - pattern: ^MB[0-9a-fA-F]{32}$ + pattern: ^WH[0-9a-fA-F]{32}$ + type: string + type: type: string url: format: uri type: string type: object - ip_messaging.v1.service.channel.message: + ip_messaging.v2.service.channel.invite: properties: account_sid: maxLength: 34 minLength: 34 pattern: ^AC[0-9a-fA-F]{32}$ type: string - attributes: - type: string - body: - type: string channel_sid: maxLength: 34 minLength: 34 pattern: ^CH[0-9a-fA-F]{32}$ type: string + created_by: + type: string date_created: format: date-time type: string date_updated: format: date-time type: string - from: - type: string - index: - type: integer - service_sid: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - sid: - maxLength: 34 - minLength: 34 - pattern: ^IM[0-9a-fA-F]{32}$ - type: string - to: - maxLength: 34 - minLength: 34 - pattern: ^CH[0-9a-fA-F]{32}$ - type: string - url: - format: uri + identity: type: string - was_edited: - type: boolean - type: object - ip_messaging.v1.service.role: - properties: - account_sid: + role_sid: maxLength: 34 minLength: 34 - pattern: ^AC[0-9a-fA-F]{32}$ - type: string - date_created: - format: date-time - type: string - date_updated: - format: date-time - type: string - friendly_name: + pattern: ^RL[0-9a-fA-F]{32}$ type: string - permissions: - items: - type: string - type: array service_sid: maxLength: 34 minLength: 34 @@ -303,18 +266,13 @@ components: sid: maxLength: 34 minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ - type: string - type: - enum: - - channel - - deployment + pattern: ^IN[0-9a-fA-F]{32}$ type: string url: format: uri type: string type: object - ip_messaging.v1.service.user: + ip_messaging.v2.service.channel.member: properties: account_sid: maxLength: 34 @@ -323,24 +281,25 @@ components: type: string attributes: type: string + channel_sid: + maxLength: 34 + minLength: 34 + pattern: ^CH[0-9a-fA-F]{32}$ + type: string date_created: format: date-time type: string date_updated: format: date-time type: string - friendly_name: - type: string identity: type: string - is_notifiable: - type: boolean - is_online: - type: boolean - joined_channels_count: + last_consumed_message_index: + nullable: true type: integer - links: - type: object + last_consumption_timestamp: + format: date-time + type: string role_sid: maxLength: 34 minLength: 34 @@ -354,55 +313,27 @@ components: sid: maxLength: 34 minLength: 34 - pattern: ^US[0-9a-fA-F]{32}$ + pattern: ^MB[0-9a-fA-F]{32}$ type: string url: format: uri type: string type: object - ip_messaging.v1.service.user.user_channel: + ip_messaging.v2.service.channel.message: properties: account_sid: maxLength: 34 minLength: 34 pattern: ^AC[0-9a-fA-F]{32}$ type: string - channel_sid: - maxLength: 34 - minLength: 34 - pattern: ^CH[0-9a-fA-F]{32}$ - type: string - last_consumed_message_index: - nullable: true - type: integer - links: - type: object - member_sid: - maxLength: 34 - minLength: 34 - pattern: ^MB[0-9a-fA-F]{32}$ - type: string - service_sid: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ + attributes: type: string - status: - enum: - - joined - - invited - - not_participating + body: type: string - unread_messages_count: - nullable: true - type: integer - type: object - ip_messaging.v2.credential: - properties: - account_sid: + channel_sid: maxLength: 34 minLength: 34 - pattern: ^AC[0-9a-fA-F]{32}$ + pattern: ^CH[0-9a-fA-F]{32}$ type: string date_created: format: date-time @@ -410,2804 +341,240 @@ components: date_updated: format: date-time type: string - friendly_name: - type: string - sandbox: - type: string - sid: - maxLength: 34 - minLength: 34 - pattern: ^CR[0-9a-fA-F]{32}$ - type: string - type: - enum: - - gcm - - apn - - fcm - type: string - url: - format: uri - type: string - type: object - ip_messaging.v2.service: - properties: - account_sid: - maxLength: 34 - minLength: 34 - pattern: ^AC[0-9a-fA-F]{32}$ + from: type: string - consumption_report_interval: + index: type: integer - date_created: - format: date-time - type: string - date_updated: - format: date-time - type: string - default_channel_creator_role_sid: - maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ - type: string - default_channel_role_sid: - maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ + last_updated_by: type: string - default_service_role_sid: + media: + type: object + service_sid: maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ - type: string - friendly_name: - type: string - limits: - type: object - links: - type: object - media: - type: object - notifications: - type: object - post_webhook_retry_count: - type: integer - post_webhook_url: - type: string - pre_webhook_retry_count: - type: integer - pre_webhook_url: - type: string - reachability_enabled: - type: boolean - read_status_enabled: - type: boolean - sid: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - typing_indicator_timeout: - type: integer - url: - format: uri - type: string - webhook_filters: - items: - type: string - type: array - webhook_method: - type: string - type: object - ip_messaging.v2.service.binding: - properties: - account_sid: - maxLength: 34 - minLength: 34 - pattern: ^AC[0-9a-fA-F]{32}$ - type: string - binding_type: - enum: - - gcm - - apn - - fcm - type: string - credential_sid: - maxLength: 34 - minLength: 34 - pattern: ^CR[0-9a-fA-F]{32}$ - type: string - date_created: - format: date-time - type: string - date_updated: - format: date-time - type: string - endpoint: - type: string - identity: - type: string - links: - type: object - message_types: - items: - type: string - type: array - service_sid: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - sid: - maxLength: 34 - minLength: 34 - pattern: ^BS[0-9a-fA-F]{32}$ - type: string - url: - format: uri - type: string - type: object - ip_messaging.v2.service.channel: - properties: - account_sid: - maxLength: 34 - minLength: 34 - pattern: ^AC[0-9a-fA-F]{32}$ - type: string - attributes: - type: string - created_by: - type: string - date_created: - format: date-time - type: string - date_updated: - format: date-time - type: string - friendly_name: - type: string - links: - type: object - members_count: - type: integer - messages_count: - type: integer - service_sid: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - sid: - maxLength: 34 - minLength: 34 - pattern: ^CH[0-9a-fA-F]{32}$ - type: string - type: - enum: - - public - - private - type: string - unique_name: - type: string - url: - format: uri - type: string - type: object - ip_messaging.v2.service.channel.channel_webhook: - properties: - account_sid: - maxLength: 34 - minLength: 34 - pattern: ^AC[0-9a-fA-F]{32}$ - type: string - channel_sid: - maxLength: 34 - minLength: 34 - pattern: ^CH[0-9a-fA-F]{32}$ - type: string - configuration: - type: object - date_created: - format: date-time - type: string - date_updated: - format: date-time - type: string - service_sid: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - sid: - maxLength: 34 - minLength: 34 - pattern: ^WH[0-9a-fA-F]{32}$ - type: string - type: - type: string - url: - format: uri - type: string - type: object - ip_messaging.v2.service.channel.invite: - properties: - account_sid: - maxLength: 34 - minLength: 34 - pattern: ^AC[0-9a-fA-F]{32}$ - type: string - channel_sid: - maxLength: 34 - minLength: 34 - pattern: ^CH[0-9a-fA-F]{32}$ - type: string - created_by: - type: string - date_created: - format: date-time - type: string - date_updated: - format: date-time - type: string - identity: - type: string - role_sid: - maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ - type: string - service_sid: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - sid: - maxLength: 34 - minLength: 34 - pattern: ^IN[0-9a-fA-F]{32}$ - type: string - url: - format: uri - type: string - type: object - ip_messaging.v2.service.channel.member: - properties: - account_sid: - maxLength: 34 - minLength: 34 - pattern: ^AC[0-9a-fA-F]{32}$ - type: string - attributes: - type: string - channel_sid: - maxLength: 34 - minLength: 34 - pattern: ^CH[0-9a-fA-F]{32}$ - type: string - date_created: - format: date-time - type: string - date_updated: - format: date-time - type: string - identity: - type: string - last_consumed_message_index: - nullable: true - type: integer - last_consumption_timestamp: - format: date-time - type: string - role_sid: - maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ - type: string - service_sid: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - sid: - maxLength: 34 - minLength: 34 - pattern: ^MB[0-9a-fA-F]{32}$ - type: string - url: - format: uri - type: string - type: object - ip_messaging.v2.service.channel.message: - properties: - account_sid: - maxLength: 34 - minLength: 34 - pattern: ^AC[0-9a-fA-F]{32}$ - type: string - attributes: - type: string - body: - type: string - channel_sid: - maxLength: 34 - minLength: 34 - pattern: ^CH[0-9a-fA-F]{32}$ - type: string - date_created: - format: date-time - type: string - date_updated: - format: date-time - type: string - from: - type: string - index: - type: integer - last_updated_by: - type: string - media: - type: object - service_sid: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - sid: - maxLength: 34 - minLength: 34 - pattern: ^IM[0-9a-fA-F]{32}$ - type: string - to: - maxLength: 34 - minLength: 34 - pattern: ^CH[0-9a-fA-F]{32}$ - type: string - type: - type: string - url: - format: uri - type: string - was_edited: - type: boolean - type: object - ip_messaging.v2.service.role: - properties: - account_sid: - maxLength: 34 - minLength: 34 - pattern: ^AC[0-9a-fA-F]{32}$ - type: string - date_created: - format: date-time - type: string - date_updated: - format: date-time - type: string - friendly_name: - type: string - permissions: - items: - type: string - type: array - service_sid: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - sid: - maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ - type: string - type: - enum: - - channel - - deployment - type: string - url: - format: uri - type: string - type: object - ip_messaging.v2.service.user: - properties: - account_sid: - maxLength: 34 - minLength: 34 - pattern: ^AC[0-9a-fA-F]{32}$ - type: string - attributes: - type: string - date_created: - format: date-time - type: string - date_updated: - format: date-time - type: string - friendly_name: - type: string - identity: - type: string - is_notifiable: - type: boolean - is_online: - type: boolean - joined_channels_count: - type: integer - links: - type: object - role_sid: - maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ - type: string - service_sid: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - sid: - maxLength: 34 - minLength: 34 - pattern: ^US[0-9a-fA-F]{32}$ - type: string - url: - format: uri - type: string - type: object - ip_messaging.v2.service.user.user_binding: - properties: - account_sid: - maxLength: 34 - minLength: 34 - pattern: ^AC[0-9a-fA-F]{32}$ - type: string - binding_type: - enum: - - gcm - - apn - - fcm - type: string - credential_sid: - maxLength: 34 - minLength: 34 - pattern: ^CR[0-9a-fA-F]{32}$ - type: string - date_created: - format: date-time - type: string - date_updated: - format: date-time - type: string - endpoint: - type: string - identity: - type: string - message_types: - items: - type: string - type: array - service_sid: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - sid: - maxLength: 34 - minLength: 34 - pattern: ^BS[0-9a-fA-F]{32}$ - type: string - url: - format: uri - type: string - user_sid: - maxLength: 34 - minLength: 34 - pattern: ^US[0-9a-fA-F]{32}$ - type: string - type: object - ip_messaging.v2.service.user.user_channel: - properties: - account_sid: - maxLength: 34 - minLength: 34 - pattern: ^AC[0-9a-fA-F]{32}$ - type: string - channel_sid: - maxLength: 34 - minLength: 34 - pattern: ^CH[0-9a-fA-F]{32}$ - type: string - last_consumed_message_index: - nullable: true - type: integer - links: - type: object - member_sid: - maxLength: 34 - minLength: 34 - pattern: ^MB[0-9a-fA-F]{32}$ - type: string - notification_level: - enum: - - default - - muted - type: string - service_sid: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - status: - enum: - - joined - - invited - - not_participating - type: string - unread_messages_count: - nullable: true - type: integer - url: - format: uri - type: string - user_sid: - maxLength: 34 - minLength: 34 - pattern: ^US[0-9a-fA-F]{32}$ - type: string - type: object - securitySchemes: - accountSid_authToken: - scheme: basic - type: http -info: - contact: - email: support@twilio.com - name: Twilio Support - url: https://support.twilio.com - description: This is the public Twilio REST API. - license: - name: Apache 2.0 - url: https://www.apache.org/licenses/LICENSE-2.0.html - termsOfService: https://www.twilio.com/legal/tos - title: Twilio - Ip_messaging - version: 1.3.0 -openapi: 3.0.1 -paths: - /v1/Credentials: - description: 'TODO: Resource-level docs' - get: - description: '' - parameters: - - description: How many resources to return in each list page. The default is - 50, and the maximum is 1000. - in: query - name: PageSize - schema: - maximum: 1000 - minimum: 1 - type: integer - responses: - 200: - content: - application/json: - schema: - properties: - credentials: - items: - $ref: '#/components/schemas/ip_messaging.v1.credential' - type: array - meta: - properties: - first_page_url: - format: uri - type: string - key: - type: string - next_page_url: - format: uri - type: string - page: - type: integer - page_size: - type: integer - previous_page_url: - format: uri - type: string - url: - format: uri - type: string - type: object - type: object - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - post: - description: '' - requestBody: - content: - application/x-www-form-urlencoded: - schema: - properties: - ApiKey: - description: '' - type: string - Certificate: - description: '' - type: string - FriendlyName: - description: '' - type: string - PrivateKey: - description: '' - type: string - Sandbox: - description: '' - type: boolean - Secret: - description: '' - type: string - Type: - description: '' - enum: - - gcm - - apn - - fcm - type: string - required: - - Type - type: object - responses: - 201: - content: - application/json: - schema: - $ref: '#/components/schemas/ip_messaging.v1.credential' - description: Created - security: - - accountSid_authToken: [] - tags: - - GA - servers: - - url: https://ip-messaging.twilio.com - x-default-output-properties: &id001 - - sid - - friendly_name - - type - x-path-type: list - /v1/Credentials/{Sid}: - delete: - description: '' - parameters: - - description: '' - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^CR[0-9a-fA-F]{32}$ - type: string - responses: - 204: - description: The resource was deleted successfully. - security: - - accountSid_authToken: [] - tags: - - GA - description: 'TODO: Resource-level docs' - get: - description: '' - parameters: - - description: '' - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^CR[0-9a-fA-F]{32}$ - type: string - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/ip_messaging.v1.credential' - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - post: - description: '' - parameters: - - description: '' - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^CR[0-9a-fA-F]{32}$ - type: string - requestBody: - content: - application/x-www-form-urlencoded: - schema: - properties: - ApiKey: - description: '' - type: string - Certificate: - description: '' - type: string - FriendlyName: - description: '' - type: string - PrivateKey: - description: '' - type: string - Sandbox: - description: '' - type: boolean - Secret: - description: '' - type: string - type: object - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/ip_messaging.v1.credential' - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - servers: - - url: https://ip-messaging.twilio.com - x-default-output-properties: *id001 - x-path-type: instance - /v1/Services: - description: 'TODO: Resource-level docs' - get: - description: '' - parameters: - - description: How many resources to return in each list page. The default is - 50, and the maximum is 1000. - in: query - name: PageSize - schema: - maximum: 1000 - minimum: 1 - type: integer - responses: - 200: - content: - application/json: - schema: - properties: - meta: - properties: - first_page_url: - format: uri - type: string - key: - type: string - next_page_url: - format: uri - type: string - page: - type: integer - page_size: - type: integer - previous_page_url: - format: uri - type: string - url: - format: uri - type: string - type: object - services: - items: - $ref: '#/components/schemas/ip_messaging.v1.service' - type: array - type: object - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - post: - description: '' - requestBody: - content: - application/x-www-form-urlencoded: - schema: - properties: - FriendlyName: - description: '' - type: string - required: - - FriendlyName - type: object - responses: - 201: - content: - application/json: - schema: - $ref: '#/components/schemas/ip_messaging.v1.service' - description: Created - security: - - accountSid_authToken: [] - tags: - - GA - servers: - - url: https://ip-messaging.twilio.com - x-default-output-properties: &id008 - - sid - - friendly_name - - date_created - x-path-type: list - /v1/Services/{ServiceSid}/Channels: - description: 'TODO: Resource-level docs' - get: - description: '' - parameters: - - description: '' - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: '' - in: query - name: Type - schema: - items: - enum: - - public - - private - type: string - type: array - - description: How many resources to return in each list page. The default is - 50, and the maximum is 1000. - in: query - name: PageSize - schema: - maximum: 1000 - minimum: 1 - type: integer - responses: - 200: - content: - application/json: - schema: - properties: - channels: - items: - $ref: '#/components/schemas/ip_messaging.v1.service.channel' - type: array - meta: - properties: - first_page_url: - format: uri - type: string - key: - type: string - next_page_url: - format: uri - type: string - page: - type: integer - page_size: - type: integer - previous_page_url: - format: uri - type: string - url: - format: uri - type: string - type: object - type: object - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - post: - description: '' - parameters: - - description: '' - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - requestBody: - content: - application/x-www-form-urlencoded: - schema: - properties: - Attributes: - description: '' - type: string - FriendlyName: - description: '' - type: string - Type: - description: '' - enum: - - public - - private - type: string - UniqueName: - description: '' - type: string - type: object - responses: - 201: - content: - application/json: - schema: - $ref: '#/components/schemas/ip_messaging.v1.service.channel' - description: Created - security: - - accountSid_authToken: [] - tags: - - GA - servers: - - url: https://ip-messaging.twilio.com - x-default-output-properties: &id005 - - sid - - unique_name - - friendly_name - x-path-type: list - /v1/Services/{ServiceSid}/Channels/{ChannelSid}/Invites: - description: 'TODO: Resource-level docs' - get: - description: '' - parameters: - - description: '' - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: '' - in: path - name: ChannelSid - required: true - schema: - type: string - - description: '' - in: query - name: Identity - schema: - items: - type: string - type: array - - description: How many resources to return in each list page. The default is - 50, and the maximum is 1000. - in: query - name: PageSize - schema: - maximum: 1000 - minimum: 1 - type: integer - responses: - 200: - content: - application/json: - schema: - properties: - invites: - items: - $ref: '#/components/schemas/ip_messaging.v1.service.channel.invite' - type: array - meta: - properties: - first_page_url: - format: uri - type: string - key: - type: string - next_page_url: - format: uri - type: string - page: - type: integer - page_size: - type: integer - previous_page_url: - format: uri - type: string - url: - format: uri - type: string - type: object - type: object - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - post: - description: '' - parameters: - - description: '' - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: '' - in: path - name: ChannelSid - required: true - schema: - type: string - requestBody: - content: - application/x-www-form-urlencoded: - schema: - properties: - Identity: - description: '' - type: string - RoleSid: - description: '' - maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ - type: string - required: - - Identity - type: object - responses: - 201: - content: - application/json: - schema: - $ref: '#/components/schemas/ip_messaging.v1.service.channel.invite' - description: Created - security: - - accountSid_authToken: [] - tags: - - GA - servers: - - url: https://ip-messaging.twilio.com - x-default-output-properties: &id002 - - sid - - identity - - date_created - x-path-type: list - /v1/Services/{ServiceSid}/Channels/{ChannelSid}/Invites/{Sid}: - delete: - description: '' - parameters: - - description: '' - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: '' - in: path - name: ChannelSid - required: true - schema: - type: string - - description: '' - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IN[0-9a-fA-F]{32}$ - type: string - responses: - 204: - description: The resource was deleted successfully. - security: - - accountSid_authToken: [] - tags: - - GA - description: 'TODO: Resource-level docs' - get: - description: '' - parameters: - - description: '' - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: '' - in: path - name: ChannelSid - required: true - schema: - type: string - - description: '' - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IN[0-9a-fA-F]{32}$ - type: string - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/ip_messaging.v1.service.channel.invite' - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - servers: - - url: https://ip-messaging.twilio.com - x-default-output-properties: *id002 - x-path-type: instance - /v1/Services/{ServiceSid}/Channels/{ChannelSid}/Members: - description: 'TODO: Resource-level docs' - get: - description: '' - parameters: - - description: '' - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: '' - in: path - name: ChannelSid - required: true - schema: - type: string - - description: '' - in: query - name: Identity - schema: - items: - type: string - type: array - - description: How many resources to return in each list page. The default is - 50, and the maximum is 1000. - in: query - name: PageSize - schema: - maximum: 1000 - minimum: 1 - type: integer - responses: - 200: - content: - application/json: - schema: - properties: - members: - items: - $ref: '#/components/schemas/ip_messaging.v1.service.channel.member' - type: array - meta: - properties: - first_page_url: - format: uri - type: string - key: - type: string - next_page_url: - format: uri - type: string - page: - type: integer - page_size: - type: integer - previous_page_url: - format: uri - type: string - url: - format: uri - type: string - type: object - type: object - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - post: - description: '' - parameters: - - description: '' - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: '' - in: path - name: ChannelSid - required: true - schema: - type: string - requestBody: - content: - application/x-www-form-urlencoded: - schema: - properties: - Identity: - description: '' - type: string - RoleSid: - description: '' - maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ - type: string - required: - - Identity - type: object - responses: - 201: - content: - application/json: - schema: - $ref: '#/components/schemas/ip_messaging.v1.service.channel.member' - description: Created - security: - - accountSid_authToken: [] - tags: - - GA - servers: - - url: https://ip-messaging.twilio.com - x-default-output-properties: &id003 - - sid - - identity - - date_created - x-path-type: list - /v1/Services/{ServiceSid}/Channels/{ChannelSid}/Members/{Sid}: - delete: - description: '' - parameters: - - description: '' - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: '' - in: path - name: ChannelSid - required: true - schema: - type: string - - description: '' - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^MB[0-9a-fA-F]{32}$ - type: string - responses: - 204: - description: The resource was deleted successfully. - security: - - accountSid_authToken: [] - tags: - - GA - description: 'TODO: Resource-level docs' - get: - description: '' - parameters: - - description: '' - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: '' - in: path - name: ChannelSid - required: true - schema: - type: string - - description: '' - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^MB[0-9a-fA-F]{32}$ - type: string - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/ip_messaging.v1.service.channel.member' - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - post: - description: '' - parameters: - - description: '' - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: '' - in: path - name: ChannelSid - required: true - schema: - type: string - - description: '' - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^MB[0-9a-fA-F]{32}$ - type: string - requestBody: - content: - application/x-www-form-urlencoded: - schema: - properties: - LastConsumedMessageIndex: - description: '' - nullable: true - type: integer - RoleSid: - description: '' - maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ - type: string - type: object - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/ip_messaging.v1.service.channel.member' - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - servers: - - url: https://ip-messaging.twilio.com - x-default-output-properties: *id003 - x-path-type: instance - /v1/Services/{ServiceSid}/Channels/{ChannelSid}/Messages: - description: 'TODO: Resource-level docs' - get: - description: '' - parameters: - - description: '' - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: '' - in: path - name: ChannelSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^CH[0-9a-fA-F]{32}$ - type: string - - description: '' - in: query - name: Order - schema: - enum: - - asc - - desc - type: string - - description: How many resources to return in each list page. The default is - 50, and the maximum is 1000. - in: query - name: PageSize - schema: - maximum: 1000 - minimum: 1 - type: integer - responses: - 200: - content: - application/json: - schema: - properties: - messages: - items: - $ref: '#/components/schemas/ip_messaging.v1.service.channel.message' - type: array - meta: - properties: - first_page_url: - format: uri - type: string - key: - type: string - next_page_url: - format: uri - type: string - page: - type: integer - page_size: - type: integer - previous_page_url: - format: uri - type: string - url: - format: uri - type: string - type: object - type: object - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - post: - description: '' - parameters: - - description: '' - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: '' - in: path - name: ChannelSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^CH[0-9a-fA-F]{32}$ - type: string - requestBody: - content: - application/x-www-form-urlencoded: - schema: - properties: - Attributes: - description: '' - type: string - Body: - description: '' - type: string - From: - description: '' - type: string - required: - - Body - type: object - responses: - 201: - content: - application/json: - schema: - $ref: '#/components/schemas/ip_messaging.v1.service.channel.message' - description: Created - security: - - accountSid_authToken: [] - tags: - - GA - servers: - - url: https://ip-messaging.twilio.com - x-default-output-properties: &id004 - - sid - - from - - to - - date_created - x-path-type: list - /v1/Services/{ServiceSid}/Channels/{ChannelSid}/Messages/{Sid}: - delete: - description: '' - parameters: - - description: '' - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: '' - in: path - name: ChannelSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^CH[0-9a-fA-F]{32}$ - type: string - - description: '' - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IM[0-9a-fA-F]{32}$ - type: string - responses: - 204: - description: The resource was deleted successfully. - security: - - accountSid_authToken: [] - tags: - - GA - description: 'TODO: Resource-level docs' - get: - description: '' - parameters: - - description: '' - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: '' - in: path - name: ChannelSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^CH[0-9a-fA-F]{32}$ - type: string - - description: '' - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IM[0-9a-fA-F]{32}$ - type: string - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/ip_messaging.v1.service.channel.message' - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - post: - description: '' - parameters: - - description: '' - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: '' - in: path - name: ChannelSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^CH[0-9a-fA-F]{32}$ - type: string - - description: '' - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IM[0-9a-fA-F]{32}$ - type: string - requestBody: - content: - application/x-www-form-urlencoded: - schema: - properties: - Attributes: - description: '' - type: string - Body: - description: '' - type: string - type: object - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/ip_messaging.v1.service.channel.message' - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - servers: - - url: https://ip-messaging.twilio.com - x-default-output-properties: *id004 - x-path-type: instance - /v1/Services/{ServiceSid}/Channels/{Sid}: - delete: - description: '' - parameters: - - description: '' - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: '' - in: path - name: Sid - required: true - schema: - type: string - responses: - 204: - description: The resource was deleted successfully. - security: - - accountSid_authToken: [] - tags: - - GA - description: 'TODO: Resource-level docs' - get: - description: '' - parameters: - - description: '' - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: '' - in: path - name: Sid - required: true - schema: - type: string - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/ip_messaging.v1.service.channel' - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - post: - description: '' - parameters: - - description: '' - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: '' - in: path - name: Sid - required: true - schema: - type: string - requestBody: - content: - application/x-www-form-urlencoded: - schema: - properties: - Attributes: - description: '' - type: string - FriendlyName: - description: '' - type: string - UniqueName: - description: '' - type: string - type: object - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/ip_messaging.v1.service.channel' - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - servers: - - url: https://ip-messaging.twilio.com - x-default-output-properties: *id005 - x-path-type: instance - /v1/Services/{ServiceSid}/Roles: - description: 'TODO: Resource-level docs' - get: - description: '' - parameters: - - description: '' - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: How many resources to return in each list page. The default is - 50, and the maximum is 1000. - in: query - name: PageSize - schema: - maximum: 1000 - minimum: 1 - type: integer - responses: - 200: - content: - application/json: - schema: - properties: - meta: - properties: - first_page_url: - format: uri - type: string - key: - type: string - next_page_url: - format: uri - type: string - page: - type: integer - page_size: - type: integer - previous_page_url: - format: uri - type: string - url: - format: uri - type: string - type: object - roles: - items: - $ref: '#/components/schemas/ip_messaging.v1.service.role' - type: array - type: object - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - post: - description: '' - parameters: - - description: '' - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - requestBody: - content: - application/x-www-form-urlencoded: - schema: - properties: - FriendlyName: - description: '' - type: string - Permission: - description: '' - items: - type: string - type: array - Type: - description: '' - enum: - - channel - - deployment - type: string - required: - - FriendlyName - - Type - - Permission - type: object - responses: - 201: - content: - application/json: - schema: - $ref: '#/components/schemas/ip_messaging.v1.service.role' - description: Created - security: - - accountSid_authToken: [] - tags: - - GA - servers: - - url: https://ip-messaging.twilio.com - x-default-output-properties: &id006 - - sid - - friendly_name - - type - x-path-type: list - /v1/Services/{ServiceSid}/Roles/{Sid}: - delete: - description: '' - parameters: - - description: '' - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: '' - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ - type: string - responses: - 204: - description: The resource was deleted successfully. - security: - - accountSid_authToken: [] - tags: - - GA - description: 'TODO: Resource-level docs' - get: - description: '' - parameters: - - description: '' - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: '' - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ - type: string - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/ip_messaging.v1.service.role' - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - post: - description: '' - parameters: - - description: '' - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: '' - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ - type: string - requestBody: - content: - application/x-www-form-urlencoded: - schema: - properties: - Permission: - description: '' - items: - type: string - type: array - required: - - Permission - type: object - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/ip_messaging.v1.service.role' - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - servers: - - url: https://ip-messaging.twilio.com - x-default-output-properties: *id006 - x-path-type: instance - /v1/Services/{ServiceSid}/Users: - description: 'TODO: Resource-level docs' - get: - description: '' - parameters: - - description: '' - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: How many resources to return in each list page. The default is - 50, and the maximum is 1000. - in: query - name: PageSize - schema: - maximum: 1000 - minimum: 1 - type: integer - responses: - 200: - content: - application/json: - schema: - properties: - meta: - properties: - first_page_url: - format: uri - type: string - key: - type: string - next_page_url: - format: uri - type: string - page: - type: integer - page_size: - type: integer - previous_page_url: - format: uri - type: string - url: - format: uri - type: string - type: object - users: - items: - $ref: '#/components/schemas/ip_messaging.v1.service.user' - type: array - type: object - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - post: - description: '' - parameters: - - description: '' - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - requestBody: - content: - application/x-www-form-urlencoded: - schema: - properties: - Attributes: - description: '' - type: string - FriendlyName: - description: '' - type: string - Identity: - description: '' - type: string - RoleSid: - description: '' - maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ - type: string - required: - - Identity - type: object - responses: - 201: - content: - application/json: - schema: - $ref: '#/components/schemas/ip_messaging.v1.service.user' - description: Created - security: - - accountSid_authToken: [] - tags: - - GA - servers: - - url: https://ip-messaging.twilio.com - x-default-output-properties: &id007 - - sid - - friendly_name - - date_created - x-path-type: list - /v1/Services/{ServiceSid}/Users/{Sid}: - delete: - description: '' - parameters: - - description: '' - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: '' - in: path - name: Sid - required: true - schema: - type: string - responses: - 204: - description: The resource was deleted successfully. - security: - - accountSid_authToken: [] - tags: - - GA - description: 'TODO: Resource-level docs' - get: - description: '' - parameters: - - description: '' - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: '' - in: path - name: Sid - required: true - schema: - type: string - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/ip_messaging.v1.service.user' - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - post: - description: '' - parameters: - - description: '' - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: '' - in: path - name: Sid - required: true - schema: - type: string - requestBody: - content: - application/x-www-form-urlencoded: - schema: - properties: - Attributes: - description: '' - type: string - FriendlyName: - description: '' - type: string - RoleSid: - description: '' - maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ - type: string - type: object - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/ip_messaging.v1.service.user' - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - servers: - - url: https://ip-messaging.twilio.com - x-default-output-properties: *id007 - x-path-type: instance - /v1/Services/{ServiceSid}/Users/{UserSid}/Channels: - description: 'TODO: Resource-level docs' - get: - description: '' - parameters: - - description: '' - in: path - name: ServiceSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - - description: '' - in: path - name: UserSid - required: true - schema: - type: string - - description: How many resources to return in each list page. The default is - 50, and the maximum is 1000. - in: query - name: PageSize - schema: - maximum: 1000 - minimum: 1 - type: integer - responses: - 200: - content: - application/json: - schema: - properties: - channels: - items: - $ref: '#/components/schemas/ip_messaging.v1.service.user.user_channel' - type: array - meta: - properties: - first_page_url: - format: uri - type: string - key: - type: string - next_page_url: - format: uri - type: string - page: - type: integer - page_size: - type: integer - previous_page_url: - format: uri - type: string - url: - format: uri - type: string - type: object - type: object - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - servers: - - url: https://ip-messaging.twilio.com - x-default-output-properties: - - channel_sid - - status - x-path-type: list - /v1/Services/{Sid}: - delete: - description: '' - parameters: - - description: '' - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - responses: - 204: - description: The resource was deleted successfully. - security: - - accountSid_authToken: [] - tags: - - GA - description: 'TODO: Resource-level docs' - get: - description: '' - parameters: - - description: '' - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/ip_messaging.v1.service' - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - post: - description: '' - parameters: - - description: '' - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^IS[0-9a-fA-F]{32}$ - type: string - requestBody: - content: - application/x-www-form-urlencoded: - schema: - properties: - ConsumptionReportInterval: - description: '' - type: integer - DefaultChannelCreatorRoleSid: - description: '' - maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ - type: string - DefaultChannelRoleSid: - description: '' - maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ - type: string - DefaultServiceRoleSid: - description: '' - maxLength: 34 - minLength: 34 - pattern: ^RL[0-9a-fA-F]{32}$ - type: string - FriendlyName: - description: '' - type: string - Limits.ChannelMembers: - description: '' - type: integer - Limits.UserChannels: - description: '' - type: integer - Notifications.AddedToChannel.Enabled: - description: '' - type: boolean - Notifications.AddedToChannel.Template: - description: '' - type: string - Notifications.InvitedToChannel.Enabled: - description: '' - type: boolean - Notifications.InvitedToChannel.Template: - description: '' - type: string - Notifications.NewMessage.Enabled: - description: '' - type: boolean - Notifications.NewMessage.Template: - description: '' - type: string - Notifications.RemovedFromChannel.Enabled: - description: '' - type: boolean - Notifications.RemovedFromChannel.Template: - description: '' - type: string - PostWebhookUrl: - description: '' - format: uri - type: string - PreWebhookUrl: - description: '' - format: uri - type: string - ReachabilityEnabled: - description: '' - type: boolean - ReadStatusEnabled: - description: '' - type: boolean - TypingIndicatorTimeout: - description: '' - type: integer - WebhookFilters: - description: '' - items: - type: string - type: array - WebhookMethod: - description: '' - enum: - - head - - get - - post - - patch - - put - - delete - - HEAD - - GET - - POST - - PATCH - - PUT - - DELETE - type: string - Webhooks.OnChannelAdd.Method: - description: '' - enum: - - head - - get - - post - - patch - - put - - delete - - HEAD - - GET - - POST - - PATCH - - PUT - - DELETE - type: string - Webhooks.OnChannelAdd.Url: - description: '' - format: uri - type: string - Webhooks.OnChannelAdded.Method: - description: '' - enum: - - head - - get - - post - - patch - - put - - delete - - HEAD - - GET - - POST - - PATCH - - PUT - - DELETE - type: string - Webhooks.OnChannelAdded.Url: - description: '' - format: uri - type: string - Webhooks.OnChannelDestroy.Method: - description: '' - enum: - - head - - get - - post - - patch - - put - - delete - - HEAD - - GET - - POST - - PATCH - - PUT - - DELETE - type: string - Webhooks.OnChannelDestroy.Url: - description: '' - format: uri - type: string - Webhooks.OnChannelDestroyed.Method: - description: '' - enum: - - head - - get - - post - - patch - - put - - delete - - HEAD - - GET - - POST - - PATCH - - PUT - - DELETE - type: string - Webhooks.OnChannelDestroyed.Url: - description: '' - format: uri - type: string - Webhooks.OnChannelUpdate.Method: - description: '' - enum: - - head - - get - - post - - patch - - put - - delete - - HEAD - - GET - - POST - - PATCH - - PUT - - DELETE - type: string - Webhooks.OnChannelUpdate.Url: - description: '' - format: uri - type: string - Webhooks.OnChannelUpdated.Method: - description: '' - enum: - - head - - get - - post - - patch - - put - - delete - - HEAD - - GET - - POST - - PATCH - - PUT - - DELETE - type: string - Webhooks.OnChannelUpdated.Url: - description: '' - format: uri - type: string - Webhooks.OnMemberAdd.Method: - description: '' - enum: - - head - - get - - post - - patch - - put - - delete - - HEAD - - GET - - POST - - PATCH - - PUT - - DELETE - type: string - Webhooks.OnMemberAdd.Url: - description: '' - format: uri - type: string - Webhooks.OnMemberAdded.Method: - description: '' - enum: - - head - - get - - post - - patch - - put - - delete - - HEAD - - GET - - POST - - PATCH - - PUT - - DELETE - type: string - Webhooks.OnMemberAdded.Url: - description: '' - format: uri - type: string - Webhooks.OnMemberRemove.Method: - description: '' - enum: - - head - - get - - post - - patch - - put - - delete - - HEAD - - GET - - POST - - PATCH - - PUT - - DELETE - type: string - Webhooks.OnMemberRemove.Url: - description: '' - format: uri - type: string - Webhooks.OnMemberRemoved.Method: - description: '' - enum: - - head - - get - - post - - patch - - put - - delete - - HEAD - - GET - - POST - - PATCH - - PUT - - DELETE - type: string - Webhooks.OnMemberRemoved.Url: - description: '' - format: uri - type: string - Webhooks.OnMessageRemove.Method: - description: '' - enum: - - head - - get - - post - - patch - - put - - delete - - HEAD - - GET - - POST - - PATCH - - PUT - - DELETE - type: string - Webhooks.OnMessageRemove.Url: - description: '' - format: uri - type: string - Webhooks.OnMessageRemoved.Method: - description: '' - enum: - - head - - get - - post - - patch - - put - - delete - - HEAD - - GET - - POST - - PATCH - - PUT - - DELETE - type: string - Webhooks.OnMessageRemoved.Url: - description: '' - format: uri - type: string - Webhooks.OnMessageSend.Method: - description: '' - enum: - - head - - get - - post - - patch - - put - - delete - - HEAD - - GET - - POST - - PATCH - - PUT - - DELETE - type: string - Webhooks.OnMessageSend.Url: - description: '' - format: uri - type: string - Webhooks.OnMessageSent.Method: - description: '' - enum: - - head - - get - - post - - patch - - put - - delete - - HEAD - - GET - - POST - - PATCH - - PUT - - DELETE - type: string - Webhooks.OnMessageSent.Url: - description: '' - format: uri - type: string - Webhooks.OnMessageUpdate.Method: - description: '' - enum: - - head - - get - - post - - patch - - put - - delete - - HEAD - - GET - - POST - - PATCH - - PUT - - DELETE - type: string - Webhooks.OnMessageUpdate.Url: - description: '' - format: uri - type: string - Webhooks.OnMessageUpdated.Method: - description: '' - enum: - - head - - get - - post - - patch - - put - - delete - - HEAD - - GET - - POST - - PATCH - - PUT - - DELETE - type: string - Webhooks.OnMessageUpdated.Url: - description: '' - format: uri - type: string - type: object - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/ip_messaging.v1.service' - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - servers: - - url: https://ip-messaging.twilio.com - x-default-output-properties: *id008 - x-path-type: instance + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + sid: + maxLength: 34 + minLength: 34 + pattern: ^IM[0-9a-fA-F]{32}$ + type: string + to: + maxLength: 34 + minLength: 34 + pattern: ^CH[0-9a-fA-F]{32}$ + type: string + type: + type: string + url: + format: uri + type: string + was_edited: + type: boolean + type: object + ip_messaging.v2.service.role: + properties: + account_sid: + maxLength: 34 + minLength: 34 + pattern: ^AC[0-9a-fA-F]{32}$ + type: string + date_created: + format: date-time + type: string + date_updated: + format: date-time + type: string + friendly_name: + type: string + permissions: + items: + type: string + type: array + service_sid: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + sid: + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + type: + enum: + - channel + - deployment + type: string + url: + format: uri + type: string + type: object + ip_messaging.v2.service.user: + properties: + account_sid: + maxLength: 34 + minLength: 34 + pattern: ^AC[0-9a-fA-F]{32}$ + type: string + attributes: + type: string + date_created: + format: date-time + type: string + date_updated: + format: date-time + type: string + friendly_name: + type: string + identity: + type: string + is_notifiable: + type: boolean + is_online: + type: boolean + joined_channels_count: + type: integer + links: + type: object + role_sid: + maxLength: 34 + minLength: 34 + pattern: ^RL[0-9a-fA-F]{32}$ + type: string + service_sid: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + sid: + maxLength: 34 + minLength: 34 + pattern: ^US[0-9a-fA-F]{32}$ + type: string + url: + format: uri + type: string + type: object + ip_messaging.v2.service.user.user_binding: + properties: + account_sid: + maxLength: 34 + minLength: 34 + pattern: ^AC[0-9a-fA-F]{32}$ + type: string + binding_type: + enum: + - gcm + - apn + - fcm + type: string + credential_sid: + maxLength: 34 + minLength: 34 + pattern: ^CR[0-9a-fA-F]{32}$ + type: string + date_created: + format: date-time + type: string + date_updated: + format: date-time + type: string + endpoint: + type: string + identity: + type: string + message_types: + items: + type: string + type: array + service_sid: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + sid: + maxLength: 34 + minLength: 34 + pattern: ^BS[0-9a-fA-F]{32}$ + type: string + url: + format: uri + type: string + user_sid: + maxLength: 34 + minLength: 34 + pattern: ^US[0-9a-fA-F]{32}$ + type: string + type: object + ip_messaging.v2.service.user.user_channel: + properties: + account_sid: + maxLength: 34 + minLength: 34 + pattern: ^AC[0-9a-fA-F]{32}$ + type: string + channel_sid: + maxLength: 34 + minLength: 34 + pattern: ^CH[0-9a-fA-F]{32}$ + type: string + last_consumed_message_index: + nullable: true + type: integer + links: + type: object + member_sid: + maxLength: 34 + minLength: 34 + pattern: ^MB[0-9a-fA-F]{32}$ + type: string + notification_level: + enum: + - default + - muted + type: string + service_sid: + maxLength: 34 + minLength: 34 + pattern: ^IS[0-9a-fA-F]{32}$ + type: string + status: + enum: + - joined + - invited + - not_participating + type: string + unread_messages_count: + nullable: true + type: integer + url: + format: uri + type: string + user_sid: + maxLength: 34 + minLength: 34 + pattern: ^US[0-9a-fA-F]{32}$ + type: string + type: object + securitySchemes: + accountSid_authToken: + scheme: basic + type: http +info: + contact: + email: support@twilio.com + name: Twilio Support + url: https://support.twilio.com + description: This is the public Twilio REST API. + license: + name: Apache 2.0 + url: https://www.apache.org/licenses/LICENSE-2.0.html + termsOfService: https://www.twilio.com/legal/tos + title: Twilio - Ip_messaging + version: 1.3.0 +openapi: 3.0.1 +paths: /v2/Credentials: description: 'TODO: Resource-level docs' get: @@ -3306,7 +673,7 @@ paths: - GA servers: - url: https://ip-messaging.twilio.com - x-default-output-properties: &id009 + x-default-output-properties: &id001 - sid - friendly_name - type @@ -3404,7 +771,7 @@ paths: - GA servers: - url: https://ip-messaging.twilio.com - x-default-output-properties: *id009 + x-default-output-properties: *id001 x-path-type: instance /v2/Services: description: 'TODO: Resource-level docs' @@ -3482,7 +849,7 @@ paths: - GA servers: - url: https://ip-messaging.twilio.com - x-default-output-properties: &id020 + x-default-output-properties: &id012 - sid - friendly_name - date_created @@ -3566,7 +933,7 @@ paths: - GA servers: - url: https://ip-messaging.twilio.com - x-default-output-properties: &id010 + x-default-output-properties: &id002 - sid - endpoint - identity @@ -3635,7 +1002,7 @@ paths: - GA servers: - url: https://ip-messaging.twilio.com - x-default-output-properties: *id010 + x-default-output-properties: *id002 x-path-type: instance /v2/Services/{ServiceSid}/Channels: description: 'TODO: Resource-level docs' @@ -3771,7 +1138,7 @@ paths: - GA servers: - url: https://ip-messaging.twilio.com - x-default-output-properties: &id015 + x-default-output-properties: &id007 - sid - unique_name - friendly_name @@ -3896,7 +1263,7 @@ paths: - GA servers: - url: https://ip-messaging.twilio.com - x-default-output-properties: &id011 + x-default-output-properties: &id003 - sid - identity - date_created @@ -3977,7 +1344,7 @@ paths: - GA servers: - url: https://ip-messaging.twilio.com - x-default-output-properties: *id011 + x-default-output-properties: *id003 x-path-type: instance /v2/Services/{ServiceSid}/Channels/{ChannelSid}/Members: description: 'TODO: Resource-level docs' @@ -4126,7 +1493,7 @@ paths: - GA servers: - url: https://ip-messaging.twilio.com - x-default-output-properties: &id012 + x-default-output-properties: &id004 - sid - identity - date_created @@ -4283,7 +1650,7 @@ paths: - GA servers: - url: https://ip-messaging.twilio.com - x-default-output-properties: *id012 + x-default-output-properties: *id004 x-path-type: instance /v2/Services/{ServiceSid}/Channels/{ChannelSid}/Messages: description: 'TODO: Resource-level docs' @@ -4429,7 +1796,7 @@ paths: - GA servers: - url: https://ip-messaging.twilio.com - x-default-output-properties: &id013 + x-default-output-properties: &id005 - sid - from - to @@ -4591,7 +1958,7 @@ paths: - GA servers: - url: https://ip-messaging.twilio.com - x-default-output-properties: *id013 + x-default-output-properties: *id005 x-path-type: instance /v2/Services/{ServiceSid}/Channels/{ChannelSid}/Webhooks: description: 'TODO: Resource-level docs' @@ -4732,7 +2099,7 @@ paths: - GA servers: - url: https://ip-messaging.twilio.com - x-default-output-properties: &id014 + x-default-output-properties: &id006 - sid - configuration x-path-type: list @@ -4884,7 +2251,7 @@ paths: - GA servers: - url: https://ip-messaging.twilio.com - x-default-output-properties: *id014 + x-default-output-properties: *id006 x-path-type: instance /v2/Services/{ServiceSid}/Channels/{Sid}: delete: @@ -5015,7 +2382,7 @@ paths: - GA servers: - url: https://ip-messaging.twilio.com - x-default-output-properties: *id015 + x-default-output-properties: *id007 x-path-type: instance /v2/Services/{ServiceSid}/Roles: description: 'TODO: Resource-level docs' @@ -5125,7 +2492,7 @@ paths: - GA servers: - url: https://ip-messaging.twilio.com - x-default-output-properties: &id016 + x-default-output-properties: &id008 - sid - friendly_name - type @@ -5239,7 +2606,7 @@ paths: - GA servers: - url: https://ip-messaging.twilio.com - x-default-output-properties: *id016 + x-default-output-properties: *id008 x-path-type: instance /v2/Services/{ServiceSid}/Users: description: 'TODO: Resource-level docs' @@ -5356,7 +2723,7 @@ paths: - GA servers: - url: https://ip-messaging.twilio.com - x-default-output-properties: &id017 + x-default-output-properties: &id009 - sid - friendly_name - identity @@ -5475,7 +2842,7 @@ paths: - GA servers: - url: https://ip-messaging.twilio.com - x-default-output-properties: *id017 + x-default-output-properties: *id009 x-path-type: instance /v2/Services/{ServiceSid}/Users/{UserSid}/Bindings: description: 'TODO: Resource-level docs' @@ -5555,7 +2922,7 @@ paths: - GA servers: - url: https://ip-messaging.twilio.com - x-default-output-properties: &id018 + x-default-output-properties: &id010 - sid - endpoint - identity @@ -5637,7 +3004,7 @@ paths: - GA servers: - url: https://ip-messaging.twilio.com - x-default-output-properties: *id018 + x-default-output-properties: *id010 x-path-type: instance /v2/Services/{ServiceSid}/Users/{UserSid}/Channels: description: 'TODO: Resource-level docs' @@ -5706,7 +3073,7 @@ paths: - GA servers: - url: https://ip-messaging.twilio.com - x-default-output-properties: &id019 + x-default-output-properties: &id011 - channel_sid - status x-path-type: list @@ -5835,7 +3202,7 @@ paths: - GA servers: - url: https://ip-messaging.twilio.com - x-default-output-properties: *id019 + x-default-output-properties: *id011 x-path-type: instance /v2/Services/{Sid}: delete: @@ -6031,7 +3398,7 @@ paths: - GA servers: - url: https://ip-messaging.twilio.com - x-default-output-properties: *id020 + x-default-output-properties: *id012 x-path-type: instance tags: - description: This product is Generally Available. diff --git a/spec/yaml/twilio_lookups.yaml b/spec/yaml/twilio_lookups_v1.yaml similarity index 100% rename from spec/yaml/twilio_lookups.yaml rename to spec/yaml/twilio_lookups_v1.yaml diff --git a/spec/yaml/twilio_messaging.yaml b/spec/yaml/twilio_messaging_v1.yaml similarity index 100% rename from spec/yaml/twilio_messaging.yaml rename to spec/yaml/twilio_messaging_v1.yaml diff --git a/spec/yaml/twilio_monitor.yaml b/spec/yaml/twilio_monitor_v1.yaml similarity index 100% rename from spec/yaml/twilio_monitor.yaml rename to spec/yaml/twilio_monitor_v1.yaml diff --git a/spec/yaml/twilio_notify.yaml b/spec/yaml/twilio_notify_v1.yaml similarity index 100% rename from spec/yaml/twilio_notify.yaml rename to spec/yaml/twilio_notify_v1.yaml diff --git a/spec/yaml/twilio_numbers.yaml b/spec/yaml/twilio_numbers_v2.yaml similarity index 100% rename from spec/yaml/twilio_numbers.yaml rename to spec/yaml/twilio_numbers_v2.yaml diff --git a/spec/yaml/twilio_pricing.yaml b/spec/yaml/twilio_pricing_v1.yaml similarity index 67% rename from spec/yaml/twilio_pricing.yaml rename to spec/yaml/twilio_pricing_v1.yaml index 948ade6e..088a8d8e 100644 --- a/spec/yaml/twilio_pricing.yaml +++ b/spec/yaml/twilio_pricing_v1.yaml @@ -196,106 +196,6 @@ components: format: uri type: string type: object - pricing.v2.voice: - properties: - links: - type: object - name: - type: string - url: - format: uri - type: string - type: object - pricing.v2.voice.voice_country: - properties: - country: - type: string - iso_country: - type: string - url: - format: uri - type: string - type: object - pricing.v2.voice.voice_country|instance: - properties: - country: - type: string - inbound_call_prices: - items: - properties: - base_price: - type: number - current_price: - type: number - number_type: - type: string - type: object - type: array - iso_country: - type: string - outbound_prefix_prices: - items: - properties: - base_price: - type: number - current_price: - type: number - destination_prefixes: - items: - type: string - type: array - friendly_name: - type: string - origination_prefixes: - items: - type: string - type: array - type: object - type: array - price_unit: - type: string - url: - format: uri - type: string - type: object - pricing.v2.voice.voice_number: - properties: - country: - type: string - destination_number: - type: string - inbound_call_price: - properties: - base_price: - type: number - current_price: - type: number - number_type: - type: string - type: object - iso_country: - type: string - origination_number: - type: string - outbound_call_prices: - items: - properties: - base_price: - type: number - current_price: - type: number - origination_prefixes: - items: - type: string - type: array - type: object - type: array - price_unit: - type: string - url: - format: uri - type: string - type: object securitySchemes: accountSid_authToken: scheme: basic @@ -595,128 +495,6 @@ paths: - inbound_call_price - price_unit x-path-type: instance - /v2/Voice/Countries: - description: Voice pricing by country - get: - description: '' - parameters: - - description: How many resources to return in each list page. The default is - 50, and the maximum is 1000. - in: query - name: PageSize - schema: - maximum: 1000 - minimum: 1 - type: integer - responses: - 200: - content: - application/json: - schema: - properties: - countries: - items: - $ref: '#/components/schemas/pricing.v2.voice.voice_country' - type: array - meta: - properties: - first_page_url: - format: uri - type: string - key: - type: string - next_page_url: - format: uri - type: string - page: - type: integer - page_size: - type: integer - previous_page_url: - format: uri - type: string - url: - format: uri - type: string - type: object - type: object - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - servers: - - url: https://pricing.twilio.com - x-default-output-properties: &id004 - - country - - price_unit - x-path-type: list - /v2/Voice/Countries/{IsoCountry}: - description: Voice pricing by country - get: - description: Fetch a specific Country. - parameters: - - description: The [ISO country code](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2) - of the origin-based voice pricing information to fetch. - in: path - name: IsoCountry - required: true - schema: - type: string - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/pricing.v2.voice.voice_country|instance' - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - servers: - - url: https://pricing.twilio.com - x-default-output-properties: *id004 - x-path-type: instance - /v2/Voice/Numbers/{DestinationNumber}: - description: Voice pricing for a specific phone number - get: - description: Fetch pricing information for a specific destination and, optionally, - origination phone number. - parameters: - - description: The destination phone number, in [E.164](https://www.twilio.com/docs/glossary/what-e164) - format, for which to fetch the origin-based voice pricing information. E.164 - format consists of a + followed by the country code and subscriber number. - in: path - name: DestinationNumber - required: true - schema: - type: string - - description: The origination phone number, in [E.164](https://www.twilio.com/docs/glossary/what-e164) - format, for which to fetch the origin-based voice pricing information. E.164 - format consists of a + followed by the country code and subscriber number. - in: query - name: OriginationNumber - schema: - type: string - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/pricing.v2.voice.voice_number' - description: OK - security: - - accountSid_authToken: [] - tags: - - GA - servers: - - url: https://pricing.twilio.com - x-default-output-properties: - - country - - inbound_call_price - - price_unit - x-path-type: instance tags: - description: This product is Generally Available. name: GA diff --git a/spec/yaml/twilio_pricing_v2.yaml b/spec/yaml/twilio_pricing_v2.yaml new file mode 100644 index 00000000..e33f4289 --- /dev/null +++ b/spec/yaml/twilio_pricing_v2.yaml @@ -0,0 +1,245 @@ +components: + schemas: + pricing.v2.voice: + properties: + links: + type: object + name: + type: string + url: + format: uri + type: string + type: object + pricing.v2.voice.voice_country: + properties: + country: + type: string + iso_country: + type: string + url: + format: uri + type: string + type: object + pricing.v2.voice.voice_country|instance: + properties: + country: + type: string + inbound_call_prices: + items: + properties: + base_price: + type: number + current_price: + type: number + number_type: + type: string + type: object + type: array + iso_country: + type: string + outbound_prefix_prices: + items: + properties: + base_price: + type: number + current_price: + type: number + destination_prefixes: + items: + type: string + type: array + friendly_name: + type: string + origination_prefixes: + items: + type: string + type: array + type: object + type: array + price_unit: + type: string + url: + format: uri + type: string + type: object + pricing.v2.voice.voice_number: + properties: + country: + type: string + destination_number: + type: string + inbound_call_price: + properties: + base_price: + type: number + current_price: + type: number + number_type: + type: string + type: object + iso_country: + type: string + origination_number: + type: string + outbound_call_prices: + items: + properties: + base_price: + type: number + current_price: + type: number + origination_prefixes: + items: + type: string + type: array + type: object + type: array + price_unit: + type: string + url: + format: uri + type: string + type: object + securitySchemes: + accountSid_authToken: + scheme: basic + type: http +info: + contact: + email: support@twilio.com + name: Twilio Support + url: https://support.twilio.com + description: This is the public Twilio REST API. + license: + name: Apache 2.0 + url: https://www.apache.org/licenses/LICENSE-2.0.html + termsOfService: https://www.twilio.com/legal/tos + title: Twilio - Pricing + version: 1.3.0 +openapi: 3.0.1 +paths: + /v2/Voice/Countries: + description: Voice pricing by country + get: + description: '' + parameters: + - description: How many resources to return in each list page. The default is + 50, and the maximum is 1000. + in: query + name: PageSize + schema: + maximum: 1000 + minimum: 1 + type: integer + responses: + 200: + content: + application/json: + schema: + properties: + countries: + items: + $ref: '#/components/schemas/pricing.v2.voice.voice_country' + type: array + meta: + properties: + first_page_url: + format: uri + type: string + key: + type: string + next_page_url: + format: uri + type: string + page: + type: integer + page_size: + type: integer + previous_page_url: + format: uri + type: string + url: + format: uri + type: string + type: object + type: object + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + servers: + - url: https://pricing.twilio.com + x-default-output-properties: &id001 + - country + - price_unit + x-path-type: list + /v2/Voice/Countries/{IsoCountry}: + description: Voice pricing by country + get: + description: Fetch a specific Country. + parameters: + - description: The [ISO country code](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2) + of the origin-based voice pricing information to fetch. + in: path + name: IsoCountry + required: true + schema: + type: string + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/pricing.v2.voice.voice_country|instance' + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + servers: + - url: https://pricing.twilio.com + x-default-output-properties: *id001 + x-path-type: instance + /v2/Voice/Numbers/{DestinationNumber}: + description: Voice pricing for a specific phone number + get: + description: Fetch pricing information for a specific destination and, optionally, + origination phone number. + parameters: + - description: The destination phone number, in [E.164](https://www.twilio.com/docs/glossary/what-e164) + format, for which to fetch the origin-based voice pricing information. E.164 + format consists of a + followed by the country code and subscriber number. + in: path + name: DestinationNumber + required: true + schema: + type: string + - description: The origination phone number, in [E.164](https://www.twilio.com/docs/glossary/what-e164) + format, for which to fetch the origin-based voice pricing information. E.164 + format consists of a + followed by the country code and subscriber number. + in: query + name: OriginationNumber + schema: + type: string + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/pricing.v2.voice.voice_number' + description: OK + security: + - accountSid_authToken: [] + tags: + - GA + servers: + - url: https://pricing.twilio.com + x-default-output-properties: + - country + - inbound_call_price + - price_unit + x-path-type: instance +tags: +- description: This product is Generally Available. + name: GA diff --git a/spec/yaml/twilio_proxy.yaml b/spec/yaml/twilio_proxy_v1.yaml similarity index 100% rename from spec/yaml/twilio_proxy.yaml rename to spec/yaml/twilio_proxy_v1.yaml diff --git a/spec/yaml/twilio_serverless.yaml b/spec/yaml/twilio_serverless_v1.yaml similarity index 100% rename from spec/yaml/twilio_serverless.yaml rename to spec/yaml/twilio_serverless_v1.yaml diff --git a/spec/yaml/twilio_studio.yaml b/spec/yaml/twilio_studio_v1.yaml similarity index 54% rename from spec/yaml/twilio_studio.yaml rename to spec/yaml/twilio_studio_v1.yaml index 0e93beaf..6c7338e1 100644 --- a/spec/yaml/twilio_studio.yaml +++ b/spec/yaml/twilio_studio_v1.yaml @@ -305,248 +305,6 @@ components: format: uri type: string type: object - studio.v2.flow: - properties: - account_sid: - maxLength: 34 - minLength: 34 - pattern: ^AC[0-9a-fA-F]{32}$ - type: string - commit_message: - type: string - date_created: - format: date-time - type: string - date_updated: - format: date-time - type: string - definition: - type: object - errors: - items: - type: object - type: array - friendly_name: - type: string - links: - type: object - revision: - type: integer - sid: - maxLength: 34 - minLength: 34 - pattern: ^FW[0-9a-fA-F]{32}$ - type: string - status: - enum: - - draft - - published - type: string - url: - format: uri - type: string - valid: - type: boolean - warnings: - items: - type: object - type: array - webhook_url: - format: uri - type: string - type: object - studio.v2.flow.execution: - properties: - account_sid: - maxLength: 34 - minLength: 34 - pattern: ^AC[0-9a-fA-F]{32}$ - type: string - contact_channel_address: - type: string - context: - type: object - date_created: - format: date-time - type: string - date_updated: - format: date-time - type: string - flow_sid: - maxLength: 34 - minLength: 34 - pattern: ^FW[0-9a-fA-F]{32}$ - type: string - links: - type: object - sid: - maxLength: 34 - minLength: 34 - pattern: ^FN[0-9a-fA-F]{32}$ - type: string - status: - enum: - - active - - ended - type: string - url: - format: uri - type: string - type: object - studio.v2.flow.execution.execution_context: - properties: - account_sid: - maxLength: 34 - minLength: 34 - pattern: ^AC[0-9a-fA-F]{32}$ - type: string - context: - type: object - execution_sid: - maxLength: 34 - minLength: 34 - pattern: ^FN[0-9a-fA-F]{32}$ - type: string - flow_sid: - maxLength: 34 - minLength: 34 - pattern: ^FW[0-9a-fA-F]{32}$ - type: string - url: - format: uri - type: string - type: object - studio.v2.flow.execution.execution_step: - properties: - account_sid: - maxLength: 34 - minLength: 34 - pattern: ^AC[0-9a-fA-F]{32}$ - type: string - context: - type: object - date_created: - format: date-time - type: string - date_updated: - format: date-time - type: string - execution_sid: - maxLength: 34 - minLength: 34 - pattern: ^FN[0-9a-fA-F]{32}$ - type: string - flow_sid: - maxLength: 34 - minLength: 34 - pattern: ^FW[0-9a-fA-F]{32}$ - type: string - links: - type: object - name: - type: string - sid: - maxLength: 34 - minLength: 34 - pattern: ^FT[0-9a-fA-F]{32}$ - type: string - transitioned_from: - type: string - transitioned_to: - type: string - url: - format: uri - type: string - type: object - studio.v2.flow.execution.execution_step.execution_step_context: - properties: - account_sid: - maxLength: 34 - minLength: 34 - pattern: ^AC[0-9a-fA-F]{32}$ - type: string - context: - type: object - execution_sid: - maxLength: 34 - minLength: 34 - pattern: ^FN[0-9a-fA-F]{32}$ - type: string - flow_sid: - maxLength: 34 - minLength: 34 - pattern: ^FW[0-9a-fA-F]{32}$ - type: string - step_sid: - maxLength: 34 - minLength: 34 - pattern: ^FT[0-9a-fA-F]{32}$ - type: string - url: - format: uri - type: string - type: object - studio.v2.flow.flow_revision: - properties: - account_sid: - maxLength: 34 - minLength: 34 - pattern: ^AC[0-9a-fA-F]{32}$ - type: string - commit_message: - type: string - date_created: - format: date-time - type: string - date_updated: - format: date-time - type: string - definition: - type: object - errors: - items: - type: object - type: array - friendly_name: - type: string - revision: - type: integer - sid: - maxLength: 34 - minLength: 34 - pattern: ^FW[0-9a-fA-F]{32}$ - type: string - status: - enum: - - draft - - published - type: string - url: - format: uri - type: string - valid: - type: boolean - type: object - studio.v2.flow.test_user: - properties: - sid: - maxLength: 34 - minLength: 34 - pattern: ^FW[0-9a-fA-F]{32}$ - type: string - test_users: - items: - type: string - type: array - url: - format: uri - type: string - type: object - studio.v2.flow_validate: - properties: - valid: - type: boolean - type: object securitySchemes: accountSid_authToken: scheme: basic @@ -1516,863 +1274,6 @@ paths: - url: https://studio.twilio.com x-default-output-properties: *id005 x-path-type: instance - /v2/Flows: - description: Studio flows - get: - description: Retrieve a list of all Flows. - parameters: - - description: How many resources to return in each list page. The default is - 50, and the maximum is 1000. - in: query - name: PageSize - schema: - maximum: 1000 - minimum: 1 - type: integer - responses: - 200: - content: - application/json: - schema: - properties: - flows: - items: - $ref: '#/components/schemas/studio.v2.flow' - type: array - meta: - properties: - first_page_url: - format: uri - type: string - key: - type: string - next_page_url: - format: uri - type: string - page: - type: integer - page_size: - type: integer - previous_page_url: - format: uri - type: string - url: - format: uri - type: string - type: object - type: object - description: OK - security: - - accountSid_authToken: [] - tags: - - Beta - post: - description: Create a Flow. - requestBody: - content: - application/x-www-form-urlencoded: - schema: - properties: - CommitMessage: - description: Description on change made in the revision. - type: string - Definition: - description: JSON representation of flow definition. - type: object - FriendlyName: - description: The string that you assigned to describe the Flow. - type: string - Status: - description: 'The status of the Flow. Can be: `draft` or `published`.' - enum: - - draft - - published - type: string - required: - - FriendlyName - - Status - - Definition - type: object - responses: - 201: - content: - application/json: - schema: - $ref: '#/components/schemas/studio.v2.flow' - description: Created - security: - - accountSid_authToken: [] - tags: - - Beta - servers: - - url: https://studio.twilio.com - x-default-output-properties: &id008 - - sid - - friendly_name - - status - - revision - x-path-type: list - /v2/Flows/Validate: - description: 'TODO: Resource-level docs' - post: - description: '' - requestBody: - content: - application/x-www-form-urlencoded: - schema: - properties: - CommitMessage: - description: '' - type: string - Definition: - description: '' - type: object - FriendlyName: - description: '' - type: string - Status: - description: '' - enum: - - draft - - published - type: string - required: - - FriendlyName - - Status - - Definition - type: object - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/studio.v2.flow_validate' - description: OK - security: - - accountSid_authToken: [] - tags: - - Beta - servers: - - url: https://studio.twilio.com - x-default-output-properties: - - valid - x-path-type: list - /v2/Flows/{FlowSid}/Executions: - description: Executions of Studio flows - get: - description: Retrieve a list of all Executions for the Flow. - parameters: - - description: The SID of the Flow with the Execution resources to read. - in: path - name: FlowSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^FW[0-9a-fA-F]{32}$ - type: string - - description: Only show Execution resources starting on or after this [ISO - 8601](https://en.wikipedia.org/wiki/ISO_8601) date-time, given as `YYYY-MM-DDThh:mm:ss-hh:mm`. - in: query - name: DateCreatedFrom - schema: - format: date-time - type: string - - description: Only show Execution resources starting before this [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) - date-time, given as `YYYY-MM-DDThh:mm:ss-hh:mm`. - in: query - name: DateCreatedTo - schema: - format: date-time - type: string - - description: How many resources to return in each list page. The default is - 50, and the maximum is 1000. - in: query - name: PageSize - schema: - maximum: 1000 - minimum: 1 - type: integer - responses: - 200: - content: - application/json: - schema: - properties: - executions: - items: - $ref: '#/components/schemas/studio.v2.flow.execution' - type: array - meta: - properties: - first_page_url: - format: uri - type: string - key: - type: string - next_page_url: - format: uri - type: string - page: - type: integer - page_size: - type: integer - previous_page_url: - format: uri - type: string - url: - format: uri - type: string - type: object - type: object - description: OK - security: - - accountSid_authToken: [] - tags: - - Beta - post: - description: Triggers a new Execution for the Flow - parameters: - - description: The SID of the Excecution's Flow. - in: path - name: FlowSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^FW[0-9a-fA-F]{32}$ - type: string - requestBody: - content: - application/x-www-form-urlencoded: - schema: - properties: - From: - description: The Twilio phone number to send messages or initiate - calls from during the Flow's Execution. Available as variable - `{{flow.channel.address}}`. - type: string - Parameters: - description: 'JSON data that will be added to the Flow''s context - and that can be accessed as variables inside your Flow. For example, - if you pass in `Parameters={"name":"Zeke"}`, a widget in your - Flow can reference the variable `{{flow.data.name}}`, which returns - "Zeke". Note: the JSON value must explicitly be passed as a string, - not as a hash object. Depending on your particular HTTP library, - you may need to add quotes or URL encode the JSON string.' - type: object - To: - description: The Contact phone number to start a Studio Flow Execution, - available as variable `{{contact.channel.address}}`. - type: string - required: - - To - - From - type: object - responses: - 201: - content: - application/json: - schema: - $ref: '#/components/schemas/studio.v2.flow.execution' - description: Created - security: - - accountSid_authToken: [] - tags: - - Beta - servers: - - url: https://studio.twilio.com - x-default-output-properties: &id007 - - sid - - status - - date_created - x-path-type: list - /v2/Flows/{FlowSid}/Executions/{ExecutionSid}/Context: - description: JSON context for executions - get: - description: Retrieve the most recent context for an Execution. - parameters: - - description: The SID of the Flow with the Execution context to fetch. - in: path - name: FlowSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^FW[0-9a-fA-F]{32}$ - type: string - - description: The SID of the Execution context to fetch. - in: path - name: ExecutionSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^FN[0-9a-fA-F]{32}$ - type: string - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/studio.v2.flow.execution.execution_context' - description: OK - security: - - accountSid_authToken: [] - tags: - - Beta - servers: - - url: https://studio.twilio.com - x-default-output-properties: - - context - x-path-type: instance - /v2/Flows/{FlowSid}/Executions/{ExecutionSid}/Steps: - description: Individual steps within an execution - get: - description: Retrieve a list of all Steps for an Execution. - parameters: - - description: The SID of the Flow with the Steps to read. - in: path - name: FlowSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^FW[0-9a-fA-F]{32}$ - type: string - - description: The SID of the Execution with the Steps to read. - in: path - name: ExecutionSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^FN[0-9a-fA-F]{32}$ - type: string - - description: How many resources to return in each list page. The default is - 50, and the maximum is 1000. - in: query - name: PageSize - schema: - maximum: 1000 - minimum: 1 - type: integer - responses: - 200: - content: - application/json: - schema: - properties: - meta: - properties: - first_page_url: - format: uri - type: string - key: - type: string - next_page_url: - format: uri - type: string - page: - type: integer - page_size: - type: integer - previous_page_url: - format: uri - type: string - url: - format: uri - type: string - type: object - steps: - items: - $ref: '#/components/schemas/studio.v2.flow.execution.execution_step' - type: array - type: object - description: OK - security: - - accountSid_authToken: [] - tags: - - Beta - servers: - - url: https://studio.twilio.com - x-default-output-properties: &id006 - - sid - - name - - date_created - x-path-type: list - /v2/Flows/{FlowSid}/Executions/{ExecutionSid}/Steps/{Sid}: - description: Individual steps within an execution - get: - description: Retrieve a Step. - parameters: - - description: The SID of the Flow with the Step to fetch. - in: path - name: FlowSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^FW[0-9a-fA-F]{32}$ - type: string - - description: The SID of the Execution resource with the Step to fetch. - in: path - name: ExecutionSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^FN[0-9a-fA-F]{32}$ - type: string - - description: The SID of the ExecutionStep resource to fetch. - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^FT[0-9a-fA-F]{32}$ - type: string - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/studio.v2.flow.execution.execution_step' - description: OK - security: - - accountSid_authToken: [] - tags: - - Beta - servers: - - url: https://studio.twilio.com - x-default-output-properties: *id006 - x-path-type: instance - /v2/Flows/{FlowSid}/Executions/{ExecutionSid}/Steps/{StepSid}/Context: - description: JSON context for an individual step within an execution - get: - description: Retrieve the context for an Execution Step. - parameters: - - description: The SID of the Flow with the Step to fetch. - in: path - name: FlowSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^FW[0-9a-fA-F]{32}$ - type: string - - description: The SID of the Execution resource with the Step to fetch. - in: path - name: ExecutionSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^FN[0-9a-fA-F]{32}$ - type: string - - description: The SID of the Step to fetch. - in: path - name: StepSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^FT[0-9a-fA-F]{32}$ - type: string - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/studio.v2.flow.execution.execution_step.execution_step_context' - description: OK - security: - - accountSid_authToken: [] - tags: - - Beta - servers: - - url: https://studio.twilio.com - x-default-output-properties: - - context - x-path-type: instance - /v2/Flows/{FlowSid}/Executions/{Sid}: - delete: - description: Delete the Execution and all Steps relating to it. - parameters: - - description: The SID of the Flow with the Execution resources to delete. - in: path - name: FlowSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^FW[0-9a-fA-F]{32}$ - type: string - - description: The SID of the Execution resource to delete. - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^FN[0-9a-fA-F]{32}$ - type: string - responses: - 204: - description: The resource was deleted successfully. - security: - - accountSid_authToken: [] - tags: - - Beta - description: Executions of Studio flows - get: - description: Retrieve an Execution - parameters: - - description: The SID of the Flow with the Execution resource to fetch - in: path - name: FlowSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^FW[0-9a-fA-F]{32}$ - type: string - - description: The SID of the Execution resource to fetch. - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^FN[0-9a-fA-F]{32}$ - type: string - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/studio.v2.flow.execution' - description: OK - security: - - accountSid_authToken: [] - tags: - - Beta - post: - description: Update the status of an Execution to `ended`. - parameters: - - description: The SID of the Flow with the Execution resources to update. - in: path - name: FlowSid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^FW[0-9a-fA-F]{32}$ - type: string - - description: The SID of the Execution resource to update. - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^FN[0-9a-fA-F]{32}$ - type: string - requestBody: - content: - application/x-www-form-urlencoded: - schema: - properties: - Status: - description: The status of the Execution. Can only be `ended`. - enum: - - active - - ended - type: string - required: - - Status - type: object - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/studio.v2.flow.execution' - description: OK - security: - - accountSid_authToken: [] - tags: - - Beta - servers: - - url: https://studio.twilio.com - x-default-output-properties: *id007 - x-path-type: instance - /v2/Flows/{Sid}: - delete: - description: Delete a specific Flow. - parameters: - - description: The SID of the Flow resource to delete. - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^FW[0-9a-fA-F]{32}$ - type: string - responses: - 204: - description: The resource was deleted successfully. - security: - - accountSid_authToken: [] - tags: - - Beta - description: Studio flows - get: - description: Retrieve a specific Flow. - parameters: - - description: The SID of the Flow resource to fetch. - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^FW[0-9a-fA-F]{32}$ - type: string - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/studio.v2.flow' - description: OK - security: - - accountSid_authToken: [] - tags: - - Beta - post: - description: Update a Flow. - parameters: - - description: The SID of the Flow resource to fetch. - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^FW[0-9a-fA-F]{32}$ - type: string - requestBody: - content: - application/x-www-form-urlencoded: - schema: - properties: - CommitMessage: - description: Description on change made in the revision. - type: string - Definition: - description: JSON representation of flow definition. - type: object - FriendlyName: - description: The string that you assigned to describe the Flow. - type: string - Status: - description: 'The status of the Flow. Can be: `draft` or `published`.' - enum: - - draft - - published - type: string - required: - - Status - type: object - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/studio.v2.flow' - description: OK - security: - - accountSid_authToken: [] - tags: - - Beta - servers: - - url: https://studio.twilio.com - x-default-output-properties: *id008 - x-path-type: instance - /v2/Flows/{Sid}/Revisions: - description: Studio flows revisions - get: - description: Retrieve a list of all Flows revisions. - parameters: - - description: The SID of the Flow resource to fetch. - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^FW[0-9a-fA-F]{32}$ - type: string - - description: How many resources to return in each list page. The default is - 50, and the maximum is 1000. - in: query - name: PageSize - schema: - maximum: 1000 - minimum: 1 - type: integer - responses: - 200: - content: - application/json: - schema: - properties: - meta: - properties: - first_page_url: - format: uri - type: string - key: - type: string - next_page_url: - format: uri - type: string - page: - type: integer - page_size: - type: integer - previous_page_url: - format: uri - type: string - url: - format: uri - type: string - type: object - revisions: - items: - $ref: '#/components/schemas/studio.v2.flow.flow_revision' - type: array - type: object - description: OK - security: - - accountSid_authToken: [] - tags: - - Beta - servers: - - url: https://studio.twilio.com - x-default-output-properties: &id009 - - sid - - friendly_name - - status - - revision - x-path-type: list - /v2/Flows/{Sid}/Revisions/{Revision}: - description: Studio flows revisions - get: - description: Retrieve a specific Flow revision. - parameters: - - description: The SID of the Flow resource to fetch. - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^FW[0-9a-fA-F]{32}$ - type: string - - description: Specific Revision number or can be `LatestPublished` and `LatestRevision`. - in: path - name: Revision - required: true - schema: - type: string - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/studio.v2.flow.flow_revision' - description: OK - security: - - accountSid_authToken: [] - tags: - - Beta - servers: - - url: https://studio.twilio.com - x-default-output-properties: *id009 - x-path-type: instance - /v2/Flows/{Sid}/TestUsers: - description: 'TODO: Resource-level docs' - get: - description: '' - parameters: - - description: '' - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^FW[0-9a-fA-F]{32}$ - type: string - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/studio.v2.flow.test_user' - description: OK - security: - - accountSid_authToken: [] - tags: - - Beta - post: - description: '' - parameters: - - description: '' - in: path - name: Sid - required: true - schema: - maxLength: 34 - minLength: 34 - pattern: ^FW[0-9a-fA-F]{32}$ - type: string - requestBody: - content: - application/x-www-form-urlencoded: - schema: - properties: - TestUsers: - description: '' - items: - type: string - type: array - required: - - TestUsers - type: object - responses: - 200: - content: - application/json: - schema: - $ref: '#/components/schemas/studio.v2.flow.test_user' - description: OK - security: - - accountSid_authToken: [] - tags: - - Beta - servers: - - url: https://studio.twilio.com - x-default-output-properties: - - test_users - x-path-type: instance tags: - description: This product is Generally Available. name: GA -- description: PLEASE NOTE that this is a Beta product that is subject to change. - Use it with caution. - name: Beta diff --git a/spec/yaml/twilio_studio_v2.yaml b/spec/yaml/twilio_studio_v2.yaml new file mode 100644 index 00000000..4db8b7a4 --- /dev/null +++ b/spec/yaml/twilio_studio_v2.yaml @@ -0,0 +1,1120 @@ +components: + schemas: + studio.v2.flow: + properties: + account_sid: + maxLength: 34 + minLength: 34 + pattern: ^AC[0-9a-fA-F]{32}$ + type: string + commit_message: + type: string + date_created: + format: date-time + type: string + date_updated: + format: date-time + type: string + definition: + type: object + errors: + items: + type: object + type: array + friendly_name: + type: string + links: + type: object + revision: + type: integer + sid: + maxLength: 34 + minLength: 34 + pattern: ^FW[0-9a-fA-F]{32}$ + type: string + status: + enum: + - draft + - published + type: string + url: + format: uri + type: string + valid: + type: boolean + warnings: + items: + type: object + type: array + webhook_url: + format: uri + type: string + type: object + studio.v2.flow.execution: + properties: + account_sid: + maxLength: 34 + minLength: 34 + pattern: ^AC[0-9a-fA-F]{32}$ + type: string + contact_channel_address: + type: string + context: + type: object + date_created: + format: date-time + type: string + date_updated: + format: date-time + type: string + flow_sid: + maxLength: 34 + minLength: 34 + pattern: ^FW[0-9a-fA-F]{32}$ + type: string + links: + type: object + sid: + maxLength: 34 + minLength: 34 + pattern: ^FN[0-9a-fA-F]{32}$ + type: string + status: + enum: + - active + - ended + type: string + url: + format: uri + type: string + type: object + studio.v2.flow.execution.execution_context: + properties: + account_sid: + maxLength: 34 + minLength: 34 + pattern: ^AC[0-9a-fA-F]{32}$ + type: string + context: + type: object + execution_sid: + maxLength: 34 + minLength: 34 + pattern: ^FN[0-9a-fA-F]{32}$ + type: string + flow_sid: + maxLength: 34 + minLength: 34 + pattern: ^FW[0-9a-fA-F]{32}$ + type: string + url: + format: uri + type: string + type: object + studio.v2.flow.execution.execution_step: + properties: + account_sid: + maxLength: 34 + minLength: 34 + pattern: ^AC[0-9a-fA-F]{32}$ + type: string + context: + type: object + date_created: + format: date-time + type: string + date_updated: + format: date-time + type: string + execution_sid: + maxLength: 34 + minLength: 34 + pattern: ^FN[0-9a-fA-F]{32}$ + type: string + flow_sid: + maxLength: 34 + minLength: 34 + pattern: ^FW[0-9a-fA-F]{32}$ + type: string + links: + type: object + name: + type: string + sid: + maxLength: 34 + minLength: 34 + pattern: ^FT[0-9a-fA-F]{32}$ + type: string + transitioned_from: + type: string + transitioned_to: + type: string + url: + format: uri + type: string + type: object + studio.v2.flow.execution.execution_step.execution_step_context: + properties: + account_sid: + maxLength: 34 + minLength: 34 + pattern: ^AC[0-9a-fA-F]{32}$ + type: string + context: + type: object + execution_sid: + maxLength: 34 + minLength: 34 + pattern: ^FN[0-9a-fA-F]{32}$ + type: string + flow_sid: + maxLength: 34 + minLength: 34 + pattern: ^FW[0-9a-fA-F]{32}$ + type: string + step_sid: + maxLength: 34 + minLength: 34 + pattern: ^FT[0-9a-fA-F]{32}$ + type: string + url: + format: uri + type: string + type: object + studio.v2.flow.flow_revision: + properties: + account_sid: + maxLength: 34 + minLength: 34 + pattern: ^AC[0-9a-fA-F]{32}$ + type: string + commit_message: + type: string + date_created: + format: date-time + type: string + date_updated: + format: date-time + type: string + definition: + type: object + errors: + items: + type: object + type: array + friendly_name: + type: string + revision: + type: integer + sid: + maxLength: 34 + minLength: 34 + pattern: ^FW[0-9a-fA-F]{32}$ + type: string + status: + enum: + - draft + - published + type: string + url: + format: uri + type: string + valid: + type: boolean + type: object + studio.v2.flow.test_user: + properties: + sid: + maxLength: 34 + minLength: 34 + pattern: ^FW[0-9a-fA-F]{32}$ + type: string + test_users: + items: + type: string + type: array + url: + format: uri + type: string + type: object + studio.v2.flow_validate: + properties: + valid: + type: boolean + type: object + securitySchemes: + accountSid_authToken: + scheme: basic + type: http +info: + contact: + email: support@twilio.com + name: Twilio Support + url: https://support.twilio.com + description: This is the public Twilio REST API. + license: + name: Apache 2.0 + url: https://www.apache.org/licenses/LICENSE-2.0.html + termsOfService: https://www.twilio.com/legal/tos + title: Twilio - Studio + version: 1.3.0 +openapi: 3.0.1 +paths: + /v2/Flows: + description: Studio flows + get: + description: Retrieve a list of all Flows. + parameters: + - description: How many resources to return in each list page. The default is + 50, and the maximum is 1000. + in: query + name: PageSize + schema: + maximum: 1000 + minimum: 1 + type: integer + responses: + 200: + content: + application/json: + schema: + properties: + flows: + items: + $ref: '#/components/schemas/studio.v2.flow' + type: array + meta: + properties: + first_page_url: + format: uri + type: string + key: + type: string + next_page_url: + format: uri + type: string + page: + type: integer + page_size: + type: integer + previous_page_url: + format: uri + type: string + url: + format: uri + type: string + type: object + type: object + description: OK + security: + - accountSid_authToken: [] + tags: + - Beta + post: + description: Create a Flow. + requestBody: + content: + application/x-www-form-urlencoded: + schema: + properties: + CommitMessage: + description: Description on change made in the revision. + type: string + Definition: + description: JSON representation of flow definition. + type: object + FriendlyName: + description: The string that you assigned to describe the Flow. + type: string + Status: + description: 'The status of the Flow. Can be: `draft` or `published`.' + enum: + - draft + - published + type: string + required: + - FriendlyName + - Status + - Definition + type: object + responses: + 201: + content: + application/json: + schema: + $ref: '#/components/schemas/studio.v2.flow' + description: Created + security: + - accountSid_authToken: [] + tags: + - Beta + servers: + - url: https://studio.twilio.com + x-default-output-properties: &id003 + - sid + - friendly_name + - status + - revision + x-path-type: list + /v2/Flows/Validate: + description: 'TODO: Resource-level docs' + post: + description: '' + requestBody: + content: + application/x-www-form-urlencoded: + schema: + properties: + CommitMessage: + description: '' + type: string + Definition: + description: '' + type: object + FriendlyName: + description: '' + type: string + Status: + description: '' + enum: + - draft + - published + type: string + required: + - FriendlyName + - Status + - Definition + type: object + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/studio.v2.flow_validate' + description: OK + security: + - accountSid_authToken: [] + tags: + - Beta + servers: + - url: https://studio.twilio.com + x-default-output-properties: + - valid + x-path-type: list + /v2/Flows/{FlowSid}/Executions: + description: Executions of Studio flows + get: + description: Retrieve a list of all Executions for the Flow. + parameters: + - description: The SID of the Flow with the Execution resources to read. + in: path + name: FlowSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^FW[0-9a-fA-F]{32}$ + type: string + - description: Only show Execution resources starting on or after this [ISO + 8601](https://en.wikipedia.org/wiki/ISO_8601) date-time, given as `YYYY-MM-DDThh:mm:ss-hh:mm`. + in: query + name: DateCreatedFrom + schema: + format: date-time + type: string + - description: Only show Execution resources starting before this [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) + date-time, given as `YYYY-MM-DDThh:mm:ss-hh:mm`. + in: query + name: DateCreatedTo + schema: + format: date-time + type: string + - description: How many resources to return in each list page. The default is + 50, and the maximum is 1000. + in: query + name: PageSize + schema: + maximum: 1000 + minimum: 1 + type: integer + responses: + 200: + content: + application/json: + schema: + properties: + executions: + items: + $ref: '#/components/schemas/studio.v2.flow.execution' + type: array + meta: + properties: + first_page_url: + format: uri + type: string + key: + type: string + next_page_url: + format: uri + type: string + page: + type: integer + page_size: + type: integer + previous_page_url: + format: uri + type: string + url: + format: uri + type: string + type: object + type: object + description: OK + security: + - accountSid_authToken: [] + tags: + - Beta + post: + description: Triggers a new Execution for the Flow + parameters: + - description: The SID of the Excecution's Flow. + in: path + name: FlowSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^FW[0-9a-fA-F]{32}$ + type: string + requestBody: + content: + application/x-www-form-urlencoded: + schema: + properties: + From: + description: The Twilio phone number to send messages or initiate + calls from during the Flow's Execution. Available as variable + `{{flow.channel.address}}`. + type: string + Parameters: + description: 'JSON data that will be added to the Flow''s context + and that can be accessed as variables inside your Flow. For example, + if you pass in `Parameters={"name":"Zeke"}`, a widget in your + Flow can reference the variable `{{flow.data.name}}`, which returns + "Zeke". Note: the JSON value must explicitly be passed as a string, + not as a hash object. Depending on your particular HTTP library, + you may need to add quotes or URL encode the JSON string.' + type: object + To: + description: The Contact phone number to start a Studio Flow Execution, + available as variable `{{contact.channel.address}}`. + type: string + required: + - To + - From + type: object + responses: + 201: + content: + application/json: + schema: + $ref: '#/components/schemas/studio.v2.flow.execution' + description: Created + security: + - accountSid_authToken: [] + tags: + - Beta + servers: + - url: https://studio.twilio.com + x-default-output-properties: &id002 + - sid + - status + - date_created + x-path-type: list + /v2/Flows/{FlowSid}/Executions/{ExecutionSid}/Context: + description: JSON context for executions + get: + description: Retrieve the most recent context for an Execution. + parameters: + - description: The SID of the Flow with the Execution context to fetch. + in: path + name: FlowSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^FW[0-9a-fA-F]{32}$ + type: string + - description: The SID of the Execution context to fetch. + in: path + name: ExecutionSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^FN[0-9a-fA-F]{32}$ + type: string + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/studio.v2.flow.execution.execution_context' + description: OK + security: + - accountSid_authToken: [] + tags: + - Beta + servers: + - url: https://studio.twilio.com + x-default-output-properties: + - context + x-path-type: instance + /v2/Flows/{FlowSid}/Executions/{ExecutionSid}/Steps: + description: Individual steps within an execution + get: + description: Retrieve a list of all Steps for an Execution. + parameters: + - description: The SID of the Flow with the Steps to read. + in: path + name: FlowSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^FW[0-9a-fA-F]{32}$ + type: string + - description: The SID of the Execution with the Steps to read. + in: path + name: ExecutionSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^FN[0-9a-fA-F]{32}$ + type: string + - description: How many resources to return in each list page. The default is + 50, and the maximum is 1000. + in: query + name: PageSize + schema: + maximum: 1000 + minimum: 1 + type: integer + responses: + 200: + content: + application/json: + schema: + properties: + meta: + properties: + first_page_url: + format: uri + type: string + key: + type: string + next_page_url: + format: uri + type: string + page: + type: integer + page_size: + type: integer + previous_page_url: + format: uri + type: string + url: + format: uri + type: string + type: object + steps: + items: + $ref: '#/components/schemas/studio.v2.flow.execution.execution_step' + type: array + type: object + description: OK + security: + - accountSid_authToken: [] + tags: + - Beta + servers: + - url: https://studio.twilio.com + x-default-output-properties: &id001 + - sid + - name + - date_created + x-path-type: list + /v2/Flows/{FlowSid}/Executions/{ExecutionSid}/Steps/{Sid}: + description: Individual steps within an execution + get: + description: Retrieve a Step. + parameters: + - description: The SID of the Flow with the Step to fetch. + in: path + name: FlowSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^FW[0-9a-fA-F]{32}$ + type: string + - description: The SID of the Execution resource with the Step to fetch. + in: path + name: ExecutionSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^FN[0-9a-fA-F]{32}$ + type: string + - description: The SID of the ExecutionStep resource to fetch. + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^FT[0-9a-fA-F]{32}$ + type: string + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/studio.v2.flow.execution.execution_step' + description: OK + security: + - accountSid_authToken: [] + tags: + - Beta + servers: + - url: https://studio.twilio.com + x-default-output-properties: *id001 + x-path-type: instance + /v2/Flows/{FlowSid}/Executions/{ExecutionSid}/Steps/{StepSid}/Context: + description: JSON context for an individual step within an execution + get: + description: Retrieve the context for an Execution Step. + parameters: + - description: The SID of the Flow with the Step to fetch. + in: path + name: FlowSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^FW[0-9a-fA-F]{32}$ + type: string + - description: The SID of the Execution resource with the Step to fetch. + in: path + name: ExecutionSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^FN[0-9a-fA-F]{32}$ + type: string + - description: The SID of the Step to fetch. + in: path + name: StepSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^FT[0-9a-fA-F]{32}$ + type: string + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/studio.v2.flow.execution.execution_step.execution_step_context' + description: OK + security: + - accountSid_authToken: [] + tags: + - Beta + servers: + - url: https://studio.twilio.com + x-default-output-properties: + - context + x-path-type: instance + /v2/Flows/{FlowSid}/Executions/{Sid}: + delete: + description: Delete the Execution and all Steps relating to it. + parameters: + - description: The SID of the Flow with the Execution resources to delete. + in: path + name: FlowSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^FW[0-9a-fA-F]{32}$ + type: string + - description: The SID of the Execution resource to delete. + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^FN[0-9a-fA-F]{32}$ + type: string + responses: + 204: + description: The resource was deleted successfully. + security: + - accountSid_authToken: [] + tags: + - Beta + description: Executions of Studio flows + get: + description: Retrieve an Execution + parameters: + - description: The SID of the Flow with the Execution resource to fetch + in: path + name: FlowSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^FW[0-9a-fA-F]{32}$ + type: string + - description: The SID of the Execution resource to fetch. + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^FN[0-9a-fA-F]{32}$ + type: string + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/studio.v2.flow.execution' + description: OK + security: + - accountSid_authToken: [] + tags: + - Beta + post: + description: Update the status of an Execution to `ended`. + parameters: + - description: The SID of the Flow with the Execution resources to update. + in: path + name: FlowSid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^FW[0-9a-fA-F]{32}$ + type: string + - description: The SID of the Execution resource to update. + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^FN[0-9a-fA-F]{32}$ + type: string + requestBody: + content: + application/x-www-form-urlencoded: + schema: + properties: + Status: + description: The status of the Execution. Can only be `ended`. + enum: + - active + - ended + type: string + required: + - Status + type: object + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/studio.v2.flow.execution' + description: OK + security: + - accountSid_authToken: [] + tags: + - Beta + servers: + - url: https://studio.twilio.com + x-default-output-properties: *id002 + x-path-type: instance + /v2/Flows/{Sid}: + delete: + description: Delete a specific Flow. + parameters: + - description: The SID of the Flow resource to delete. + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^FW[0-9a-fA-F]{32}$ + type: string + responses: + 204: + description: The resource was deleted successfully. + security: + - accountSid_authToken: [] + tags: + - Beta + description: Studio flows + get: + description: Retrieve a specific Flow. + parameters: + - description: The SID of the Flow resource to fetch. + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^FW[0-9a-fA-F]{32}$ + type: string + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/studio.v2.flow' + description: OK + security: + - accountSid_authToken: [] + tags: + - Beta + post: + description: Update a Flow. + parameters: + - description: The SID of the Flow resource to fetch. + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^FW[0-9a-fA-F]{32}$ + type: string + requestBody: + content: + application/x-www-form-urlencoded: + schema: + properties: + CommitMessage: + description: Description on change made in the revision. + type: string + Definition: + description: JSON representation of flow definition. + type: object + FriendlyName: + description: The string that you assigned to describe the Flow. + type: string + Status: + description: 'The status of the Flow. Can be: `draft` or `published`.' + enum: + - draft + - published + type: string + required: + - Status + type: object + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/studio.v2.flow' + description: OK + security: + - accountSid_authToken: [] + tags: + - Beta + servers: + - url: https://studio.twilio.com + x-default-output-properties: *id003 + x-path-type: instance + /v2/Flows/{Sid}/Revisions: + description: Studio flows revisions + get: + description: Retrieve a list of all Flows revisions. + parameters: + - description: The SID of the Flow resource to fetch. + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^FW[0-9a-fA-F]{32}$ + type: string + - description: How many resources to return in each list page. The default is + 50, and the maximum is 1000. + in: query + name: PageSize + schema: + maximum: 1000 + minimum: 1 + type: integer + responses: + 200: + content: + application/json: + schema: + properties: + meta: + properties: + first_page_url: + format: uri + type: string + key: + type: string + next_page_url: + format: uri + type: string + page: + type: integer + page_size: + type: integer + previous_page_url: + format: uri + type: string + url: + format: uri + type: string + type: object + revisions: + items: + $ref: '#/components/schemas/studio.v2.flow.flow_revision' + type: array + type: object + description: OK + security: + - accountSid_authToken: [] + tags: + - Beta + servers: + - url: https://studio.twilio.com + x-default-output-properties: &id004 + - sid + - friendly_name + - status + - revision + x-path-type: list + /v2/Flows/{Sid}/Revisions/{Revision}: + description: Studio flows revisions + get: + description: Retrieve a specific Flow revision. + parameters: + - description: The SID of the Flow resource to fetch. + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^FW[0-9a-fA-F]{32}$ + type: string + - description: Specific Revision number or can be `LatestPublished` and `LatestRevision`. + in: path + name: Revision + required: true + schema: + type: string + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/studio.v2.flow.flow_revision' + description: OK + security: + - accountSid_authToken: [] + tags: + - Beta + servers: + - url: https://studio.twilio.com + x-default-output-properties: *id004 + x-path-type: instance + /v2/Flows/{Sid}/TestUsers: + description: 'TODO: Resource-level docs' + get: + description: '' + parameters: + - description: '' + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^FW[0-9a-fA-F]{32}$ + type: string + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/studio.v2.flow.test_user' + description: OK + security: + - accountSid_authToken: [] + tags: + - Beta + post: + description: '' + parameters: + - description: '' + in: path + name: Sid + required: true + schema: + maxLength: 34 + minLength: 34 + pattern: ^FW[0-9a-fA-F]{32}$ + type: string + requestBody: + content: + application/x-www-form-urlencoded: + schema: + properties: + TestUsers: + description: '' + items: + type: string + type: array + required: + - TestUsers + type: object + responses: + 200: + content: + application/json: + schema: + $ref: '#/components/schemas/studio.v2.flow.test_user' + description: OK + security: + - accountSid_authToken: [] + tags: + - Beta + servers: + - url: https://studio.twilio.com + x-default-output-properties: + - test_users + x-path-type: instance +tags: +- description: PLEASE NOTE that this is a Beta product that is subject to change. + Use it with caution. + name: Beta diff --git a/spec/yaml/twilio_supersim.yaml b/spec/yaml/twilio_supersim_v1.yaml similarity index 100% rename from spec/yaml/twilio_supersim.yaml rename to spec/yaml/twilio_supersim_v1.yaml diff --git a/spec/yaml/twilio_sync.yaml b/spec/yaml/twilio_sync_v1.yaml similarity index 100% rename from spec/yaml/twilio_sync.yaml rename to spec/yaml/twilio_sync_v1.yaml diff --git a/spec/yaml/twilio_taskrouter.yaml b/spec/yaml/twilio_taskrouter_v1.yaml similarity index 100% rename from spec/yaml/twilio_taskrouter.yaml rename to spec/yaml/twilio_taskrouter_v1.yaml diff --git a/spec/yaml/twilio_trunking.yaml b/spec/yaml/twilio_trunking_v1.yaml similarity index 100% rename from spec/yaml/twilio_trunking.yaml rename to spec/yaml/twilio_trunking_v1.yaml diff --git a/spec/yaml/twilio_verify.yaml b/spec/yaml/twilio_verify_v2.yaml similarity index 100% rename from spec/yaml/twilio_verify.yaml rename to spec/yaml/twilio_verify_v2.yaml diff --git a/spec/yaml/twilio_video.yaml b/spec/yaml/twilio_video_v1.yaml similarity index 100% rename from spec/yaml/twilio_video.yaml rename to spec/yaml/twilio_video_v1.yaml diff --git a/spec/yaml/twilio_voice.yaml b/spec/yaml/twilio_voice_v1.yaml similarity index 100% rename from spec/yaml/twilio_voice.yaml rename to spec/yaml/twilio_voice_v1.yaml diff --git a/spec/yaml/twilio_wireless.yaml b/spec/yaml/twilio_wireless_v1.yaml similarity index 100% rename from spec/yaml/twilio_wireless.yaml rename to spec/yaml/twilio_wireless_v1.yaml