components: securitySchemes: accountSid_authToken: scheme: basic type: http schemas: events.v1.event_type: type: object properties: type: type: string nullable: true description: A string that uniquely identifies this Event Type. schema_id: type: string nullable: true description: A string that uniquely identifies the Schema this Event Type adheres to. date_created: type: string format: date-time nullable: true description: The date that this Event Type was created, given in ISO 8601 format. date_updated: type: string format: date-time nullable: true description: The date that this Event Type was updated, given in ISO 8601 format. description: type: string nullable: true description: A human readable description for this Event Type. status: type: string nullable: true description: 'A string that describes how this Event Type can be used. For example: `available`, `deprecated`, `restricted`, `discontinued`. When the status is `available`, the Event Type can be used normally.' documentation_url: type: string nullable: true description: The URL to the documentation or to the most relevant Twilio Changelog entry of this Event Type. url: type: string format: uri nullable: true description: The URL of this resource. links: type: object format: uri-map nullable: true replay_enum_status: type: string enum: - submitted - starting - running - cancelling - cancelled - failed - completed replay_enum_patchstatus: type: string enum: - cancelling events.v1.schema: type: object properties: id: type: string nullable: true description: The unique identifier of the schema. Each schema can have multiple versions, that share the same id. url: type: string format: uri nullable: true description: The URL of this resource. links: type: object format: uri-map nullable: true description: Contains a dictionary of URL links to nested resources of this schema. latest_version_date_created: type: string format: date-time nullable: true description: The date that the latest schema version was created, given in ISO 8601 format. latest_version: type: integer default: 0 description: The latest version published of this schema. events.v1.schema.schema_version: type: object properties: id: type: string nullable: true description: The unique identifier of the schema. Each schema can have multiple versions, that share the same id. schema_version: type: integer default: 0 description: The version of this schema. date_created: type: string format: date-time nullable: true description: The date the schema version was created, given in ISO 8601 format. url: type: string format: uri nullable: true description: The URL of this resource. raw: type: string format: uri nullable: true events.v1.sink: type: object properties: date_created: type: string format: date-time nullable: true description: The date that this Sink was created, given in ISO 8601 format. date_updated: type: string format: date-time nullable: true description: The date that this Sink was updated, given in ISO 8601 format. description: type: string nullable: true description: A human readable description for the Sink sid: type: string minLength: 34 maxLength: 34 pattern: ^DG[0-9a-fA-F]{32}$ nullable: true description: A 34 character string that uniquely identifies this Sink. sink_configuration: nullable: true description: The information required for Twilio to connect to the provided Sink encoded as JSON. sink_type: $ref: '#/components/schemas/sink_enum_sink_type' status: $ref: '#/components/schemas/sink_enum_status' url: type: string format: uri nullable: true description: The URL of this resource. links: type: object format: uri-map nullable: true description: Contains a dictionary of URL links to nested resources of this Sink. sink_enum_status: type: string enum: - initialized - validating - active - failed description: The Status of this Sink. One of `initialized`, `validating`, `active` or `failed`. sink_enum_sink_type: type: string enum: - kinesis - webhook - segment - email description: The Sink type. Can only be "kinesis" or "webhook" currently. events.v1.sink.sink_test: type: object properties: result: type: string nullable: true description: Feedback indicating whether the test event was generated. events.v1.sink.sink_validate: type: object properties: result: type: string nullable: true description: Feedback indicating whether the given Sink was validated. events.v1.subscription.subscribed_event: type: object properties: account_sid: type: string minLength: 34 maxLength: 34 pattern: ^AC[0-9a-fA-F]{32}$ nullable: true description: The unique SID identifier of the Account. type: type: string nullable: true description: Type of event being subscribed to. schema_version: type: integer default: 0 description: The schema version that the Subscription should use. subscription_sid: type: string minLength: 34 maxLength: 34 pattern: ^DF[0-9a-fA-F]{32}$ nullable: true description: The unique SID identifier of the Subscription. url: type: string format: uri nullable: true description: The URL of this resource. events.v1.subscription: type: object properties: account_sid: type: string minLength: 34 maxLength: 34 pattern: ^AC[0-9a-fA-F]{32}$ nullable: true description: The unique SID identifier of the Account. sid: type: string minLength: 34 maxLength: 34 pattern: ^DF[0-9a-fA-F]{32}$ nullable: true description: A 34 character string that uniquely identifies this Subscription. date_created: type: string format: date-time nullable: true description: The date that this Subscription was created, given in ISO 8601 format. date_updated: type: string format: date-time nullable: true description: The date that this Subscription was updated, given in ISO 8601 format. description: type: string nullable: true description: A human readable description for the Subscription sink_sid: type: string minLength: 34 maxLength: 34 pattern: ^DG[0-9a-fA-F]{32}$ nullable: true description: The SID of the sink that events selected by this subscription should be sent to. Sink must be active for the subscription to be created. url: type: string format: uri nullable: true description: The URL of this resource. links: type: object format: uri-map nullable: true description: Contains a dictionary of URL links to nested resources of this Subscription. info: title: Twilio - Events description: This is the public Twilio REST API. termsOfService: https://www.twilio.com/legal/tos contact: name: Twilio Support url: https://support.twilio.com email: support@twilio.com license: name: Apache 2.0 url: https://www.apache.org/licenses/LICENSE-2.0.html version: 1.0.0 x-twilio: apiStandards: v0.1 openapi: 3.0.1 paths: /v1/Types: servers: - url: https://events.twilio.com description: Event Types available x-twilio: defaultOutputProperties: - type - schema_id - description mountName: event_types pathType: list get: description: Retrieve a paginated list of all the available Event Types. summary: Retrieve a paginated list of all the available Event Types. tags: - EventsV1EventType parameters: - name: SchemaId in: query description: A string parameter filtering the results to return only the Event Types using a given schema. schema: type: string examples: readResultsWithSchemaId: value: Messaging.MessageStatus - name: PageSize in: query description: How many resources to return in each list page. The default is 50, and the maximum is 1000. schema: type: integer format: int64 minimum: 1 maximum: 1000 - name: Page in: query description: The page index. This value is simply for client state. schema: type: integer minimum: 0 - name: PageToken in: query description: The page token. This is provided by the API. schema: type: string responses: '200': content: application/json: schema: type: object properties: types: type: array items: $ref: '#/components/schemas/events.v1.event_type' meta: properties: first_page_url: format: uri type: string key: type: string next_page_url: format: uri nullable: true type: string page: type: integer page_size: type: integer previous_page_url: format: uri nullable: true type: string url: format: uri type: string type: object title: ListEventTypeResponse examples: readEmpty: value: types: [] meta: page: 0 page_size: 10 first_page_url: https://events.twilio.com/v1/Types?PageSize=10&Page=0 previous_page_url: null url: https://events.twilio.com/v1/Types?PageSize=10&Page=0 next_page_url: null key: types readResults: value: types: - date_created: '2020-08-13T13:28:20Z' date_updated: '2020-08-13T13:28:20Z' type: com.twilio.messaging.message.delivered schema_id: Messaging.MessageStatus status: available documentation_url: null description: Messaging- delivered message url: https://events.twilio.com/v1/Types/com.twilio.messaging.message.delivered links: schema: https://events.twilio.com/v1/Schemas/Messaging.MessageStatus/Versions - date_created: '2020-08-13T13:28:19Z' date_updated: '2020-08-13T13:28:19Z' type: com.twilio.messaging.message.failed schema_id: Messaging.MessageStatus status: deprecated documentation_url: https://www.twilio.com/docs/voice/voice-insights/event-streams description: Messaging- failed message url: https://events.twilio.com/v1/Types/com.twilio.messaging.message.failed links: schema: https://events.twilio.com/v1/Schemas/Messaging.MessageStatus/Versions meta: page: 0 page_size: 20 first_page_url: https://events.twilio.com/v1/Types?PageSize=20&Page=0 previous_page_url: null url: https://events.twilio.com/v1/Types?PageSize=20&Page=0 next_page_url: null key: types readResultsRollbackStatusAndDocsFields: value: types: - date_created: '2020-08-13T13:28:20Z' date_updated: '2020-08-13T13:28:20Z' type: com.twilio.messaging.message.delivered schema_id: Messaging.MessageStatus status: available documentation_url: null description: Messaging- delivered message url: https://events.twilio.com/v1/Types/com.twilio.messaging.message.delivered links: schema: https://events.twilio.com/v1/Schemas/Messaging.MessageStatus/Versions - date_created: '2020-08-13T13:28:19Z' date_updated: '2020-08-13T13:28:19Z' type: com.twilio.messaging.message.failed schema_id: Messaging.MessageStatus status: available documentation_url: null description: Messaging- failed message url: https://events.twilio.com/v1/Types/com.twilio.messaging.message.failed links: schema: https://events.twilio.com/v1/Schemas/Messaging.MessageStatus/Versions meta: page: 0 page_size: 20 first_page_url: https://events.twilio.com/v1/Types?PageSize=20&Page=0 previous_page_url: null url: https://events.twilio.com/v1/Types?PageSize=20&Page=0 next_page_url: null key: types readResultsWithSchemaId: value: types: - date_created: '2020-08-13T13:28:20Z' date_updated: '2020-08-13T13:28:20Z' type: com.twilio.messaging.message.delivered schema_id: Messaging.MessageStatus status: available documentation_url: null description: Messaging- delivered message url: https://events.twilio.com/v1/Types/com.twilio.messaging.message.delivered links: schema: https://events.twilio.com/v1/Schemas/Messaging.MessageStatus/Versions - date_created: '2020-08-13T13:28:19Z' date_updated: '2020-08-13T13:28:19Z' type: com.twilio.messaging.message.failed schema_id: Messaging.MessageStatus status: deprecated documentation_url: https://www.twilio.com/docs/voice/voice-insights/event-streams description: Messaging- failed message url: https://events.twilio.com/v1/Types/com.twilio.messaging.message.failed links: schema: https://events.twilio.com/v1/Schemas/Messaging.MessageStatus/Versions meta: page: 0 page_size: 20 first_page_url: https://events.twilio.com/v1/Types?SchemaId=Messaging.MessageStatus&PageSize=20&Page=0 previous_page_url: null url: https://events.twilio.com/v1/Types?SchemaId=Messaging.MessageStatus&PageSize=20&Page=0 next_page_url: null key: types headers: Access-Control-Allow-Origin: description: Specify the origin(s) allowed to access the resource schema: type: string example: '*' Access-Control-Allow-Methods: description: Specify the HTTP methods allowed when accessing the resource schema: type: string example: POST, OPTIONS Access-Control-Allow-Headers: description: Specify the headers allowed when accessing the resource schema: type: string example: Content-Type, Authorization Access-Control-Allow-Credentials: description: Indicates whether the browser should include credentials schema: type: boolean Access-Control-Expose-Headers: description: Headers exposed to the client schema: type: string example: X-Custom-Header1, X-Custom-Header2 description: OK security: - accountSid_authToken: [] operationId: ListEventType /v1/Types/{Type}: servers: - url: https://events.twilio.com description: Event Types available x-twilio: defaultOutputProperties: - type - schema_id - description mountName: event_types pathType: instance get: description: Fetch a specific Event Type. summary: Fetch a specific Event Type. tags: - EventsV1EventType parameters: - name: Type in: path description: A string that uniquely identifies this Event Type. schema: type: string required: true responses: '200': content: application/json: schema: $ref: '#/components/schemas/events.v1.event_type' examples: fetchNoDocs: value: date_created: '2020-08-13T13:28:20Z' date_updated: '2020-08-13T13:28:20Z' type: com.twilio.messaging.message.delivered schema_id: Messaging.MessageStatus status: available documentation_url: null description: Messaging- delivered message url: https://events.twilio.com/v1/Types/com.twilio.messaging.message.delivered links: schema: https://events.twilio.com/v1/Schemas/Messaging.MessageStatus/Versions fetch: value: date_created: '2020-08-13T13:28:20Z' date_updated: '2020-08-13T13:28:20Z' type: com.twilio.messaging.message.delivered schema_id: Messaging.MessageStatus status: available documentation_url: https://www.twilio.com/docs/voice/voice-insights/event-streams description: Messaging- delivered message url: https://events.twilio.com/v1/Types/com.twilio.messaging.message.delivered links: schema: https://events.twilio.com/v1/Schemas/Messaging.MessageStatus/Versions fetchRollbackStatusAndDocsFields: value: date_created: '2020-08-13T13:28:20Z' date_updated: '2020-08-13T13:28:20Z' type: com.twilio.messaging.message.delivered schema_id: Messaging.MessageStatus status: available documentation_url: null description: Messaging- delivered message url: https://events.twilio.com/v1/Types/com.twilio.messaging.message.delivered links: schema: https://events.twilio.com/v1/Schemas/Messaging.MessageStatus/Versions headers: Access-Control-Allow-Origin: description: Specify the origin(s) allowed to access the resource schema: type: string example: '*' Access-Control-Allow-Methods: description: Specify the HTTP methods allowed when accessing the resource schema: type: string example: POST, OPTIONS Access-Control-Allow-Headers: description: Specify the headers allowed when accessing the resource schema: type: string example: Content-Type, Authorization Access-Control-Allow-Credentials: description: Indicates whether the browser should include credentials schema: type: boolean Access-Control-Expose-Headers: description: Headers exposed to the client schema: type: string example: X-Custom-Header1, X-Custom-Header2 description: OK security: - accountSid_authToken: [] operationId: FetchEventType /v1/Schemas/{Id}: servers: - url: https://events.twilio.com description: Versioned Schema definitions for Event Types x-twilio: defaultOutputProperties: - id dependentProperties: versions: mapping: id: id resource_url: /v1/Schemas/{id}/Versions pathType: instance get: description: Fetch a specific schema with its nested versions. summary: Fetch a specific schema with its nested versions. tags: - EventsV1Schema parameters: - name: Id in: path description: The unique identifier of the schema. Each schema can have multiple versions, that share the same id. schema: type: string required: true responses: '200': content: application/json: schema: $ref: '#/components/schemas/events.v1.schema' examples: fetch: value: id: Messaging.MessageStatus url: https://events.twilio.com/v1/Schemas/Messaging.MessageStatus latest_version_date_created: '2020-07-30T20:00:00Z' latest_version: 1 links: versions: https://events.twilio.com/v1/Schemas/Messaging.MessageStatus/Versions headers: Access-Control-Allow-Origin: description: Specify the origin(s) allowed to access the resource schema: type: string example: '*' Access-Control-Allow-Methods: description: Specify the HTTP methods allowed when accessing the resource schema: type: string example: POST, OPTIONS Access-Control-Allow-Headers: description: Specify the headers allowed when accessing the resource schema: type: string example: Content-Type, Authorization Access-Control-Allow-Credentials: description: Indicates whether the browser should include credentials schema: type: boolean Access-Control-Expose-Headers: description: Headers exposed to the client schema: type: string example: X-Custom-Header1, X-Custom-Header2 description: OK security: - accountSid_authToken: [] operationId: FetchSchema /v1/Schemas: servers: - url: https://events.twilio.com description: Versioned Schema definitions for Event Types x-twilio: defaultOutputProperties: - id dependentProperties: versions: mapping: id: id resource_url: /v1/Schemas/{id}/Versions pathType: list /v1/Schemas/{Id}/Versions: servers: - url: https://events.twilio.com description: Version of the Schema x-twilio: defaultOutputProperties: - id - schema_version - date_created parent: /Schemas/{Id} className: schema_version pathType: list get: description: Retrieve a paginated list of versions of the schema. summary: Retrieve a paginated list of versions of the schema. tags: - EventsV1SchemaVersion parameters: - name: Id in: path description: The unique identifier of the schema. Each schema can have multiple versions, that share the same id. schema: type: string required: true - name: PageSize in: query description: How many resources to return in each list page. The default is 50, and the maximum is 1000. schema: type: integer format: int64 minimum: 1 maximum: 1000 - name: Page in: query description: The page index. This value is simply for client state. schema: type: integer minimum: 0 - name: PageToken in: query description: The page token. This is provided by the API. schema: type: string responses: '200': content: application/json: schema: type: object properties: schema_versions: type: array items: $ref: '#/components/schemas/events.v1.schema.schema_version' meta: properties: first_page_url: format: uri type: string key: type: string next_page_url: format: uri nullable: true type: string page: type: integer page_size: type: integer previous_page_url: format: uri nullable: true type: string url: format: uri type: string type: object title: ListSchemaVersionResponse examples: readEmpty: value: schema_versions: [] meta: page: 0 page_size: 10 first_page_url: https://events.twilio.com/v1/Schemas/Messaging.MessageStatus/Versions?PageSize=10&Page=0 previous_page_url: null url: https://events.twilio.com/v1/Schemas/Messaging.MessageStatus/Versions?PageSize=10&Page=0 next_page_url: null key: schema_versions readResults: value: schema_versions: - id: Messaging.MessageStatus schema_version: 1 date_created: '2015-07-30T20:00:00Z' url: https://events.twilio.com/v1/Schemas/Messaging.MessageStatus/Versions/1 raw: https://events-schemas.twilio.com/Messaging.MessageStatus/1 - id: Messaging.MessageStatus schema_version: 2 date_created: '2015-07-30T20:00:00Z' url: https://events.twilio.com/v1/Schemas/Messaging.MessageStatus/Versions/2 raw: https://events-schemas.twilio.com/Messaging.MessageStatus/2 meta: page: 0 page_size: 50 first_page_url: https://events.twilio.com/v1/Schemas/Messaging.MessageStatus/Versions?PageSize=50&Page=0 previous_page_url: null url: https://events.twilio.com/v1/Schemas/Messaging.MessageStatus/Versions?PageSize=50&Page=0 next_page_url: null key: schema_versions headers: Access-Control-Allow-Origin: description: Specify the origin(s) allowed to access the resource schema: type: string example: '*' Access-Control-Allow-Methods: description: Specify the HTTP methods allowed when accessing the resource schema: type: string example: POST, OPTIONS Access-Control-Allow-Headers: description: Specify the headers allowed when accessing the resource schema: type: string example: Content-Type, Authorization Access-Control-Allow-Credentials: description: Indicates whether the browser should include credentials schema: type: boolean Access-Control-Expose-Headers: description: Headers exposed to the client schema: type: string example: X-Custom-Header1, X-Custom-Header2 description: OK security: - accountSid_authToken: [] operationId: ListSchemaVersion /v1/Schemas/{Id}/Versions/{SchemaVersion}: servers: - url: https://events.twilio.com description: Version of the Schema x-twilio: defaultOutputProperties: - id - schema_version - date_created parent: /Schemas/{Id} className: schema_version pathType: instance get: description: Fetch a specific schema and version. summary: Fetch a specific schema and version. tags: - EventsV1SchemaVersion parameters: - name: Id in: path description: The unique identifier of the schema. Each schema can have multiple versions, that share the same id. schema: type: string required: true - name: SchemaVersion in: path description: The version of the schema schema: type: integer required: true responses: '200': content: application/json: schema: $ref: '#/components/schemas/events.v1.schema.schema_version' examples: fetch: value: id: Messaging.MessageStatus schema_version: 1 date_created: '2015-07-30T20:00:00Z' url: https://events.twilio.com/v1/Schemas/Messaging.MessageStatus/Versions/1 raw: https://events-schemas.twilio.com/Messaging.MessageStatus/1 headers: Access-Control-Allow-Origin: description: Specify the origin(s) allowed to access the resource schema: type: string example: '*' Access-Control-Allow-Methods: description: Specify the HTTP methods allowed when accessing the resource schema: type: string example: POST, OPTIONS Access-Control-Allow-Headers: description: Specify the headers allowed when accessing the resource schema: type: string example: Content-Type, Authorization Access-Control-Allow-Credentials: description: Indicates whether the browser should include credentials schema: type: boolean Access-Control-Expose-Headers: description: Headers exposed to the client schema: type: string example: X-Custom-Header1, X-Custom-Header2 description: OK security: - accountSid_authToken: [] operationId: FetchSchemaVersion /v1/Sinks/{Sid}: servers: - url: https://events.twilio.com description: Sink destination to send events to x-twilio: defaultOutputProperties: - date_created - date_updated - description - sid - sink_configuration - sink_type - status dependentProperties: sink_test: mapping: sid: sid resource_url: /v1/Sinks/{sid}/Test sink_validate: mapping: sid: sid resource_url: /v1/Sinks/{sid}/Validate pathType: instance get: description: Fetch a specific Sink. summary: Fetch a specific Sink. tags: - EventsV1Sink parameters: - name: Sid in: path description: A 34 character string that uniquely identifies this Sink. schema: type: string minLength: 34 maxLength: 34 pattern: ^DG[0-9a-fA-F]{32}$ required: true responses: '200': content: application/json: schema: $ref: '#/components/schemas/events.v1.sink' examples: fetch: value: status: initialized sink_configuration: arn: arn:aws:kinesis:us-east-1:111111111:stream/test role_arn: arn:aws:iam::111111111:role/Role external_id: '1234567890' description: A Sink sid: DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa date_created: '2015-07-30T20:00:00Z' sink_type: kinesis date_updated: '2015-07-30T20:00:00Z' url: https://events.twilio.com/v1/Sinks/DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa links: sink_test: https://events.twilio.com/v1/Sinks/DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Test sink_validate: https://events.twilio.com/v1/Sinks/DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Validate headers: Access-Control-Allow-Origin: description: Specify the origin(s) allowed to access the resource schema: type: string example: '*' Access-Control-Allow-Methods: description: Specify the HTTP methods allowed when accessing the resource schema: type: string example: POST, OPTIONS Access-Control-Allow-Headers: description: Specify the headers allowed when accessing the resource schema: type: string example: Content-Type, Authorization Access-Control-Allow-Credentials: description: Indicates whether the browser should include credentials schema: type: boolean Access-Control-Expose-Headers: description: Headers exposed to the client schema: type: string example: X-Custom-Header1, X-Custom-Header2 description: OK security: - accountSid_authToken: [] operationId: FetchSink delete: description: Delete a specific Sink. summary: Delete a specific Sink. tags: - EventsV1Sink parameters: - name: Sid in: path description: A 34 character string that uniquely identifies this Sink. schema: type: string minLength: 34 maxLength: 34 pattern: ^DG[0-9a-fA-F]{32}$ required: true responses: '204': description: The resource was deleted successfully. security: - accountSid_authToken: [] operationId: DeleteSink post: description: Update a specific Sink summary: Update a specific Sink tags: - EventsV1Sink parameters: - name: Sid in: path description: A 34 character string that uniquely identifies this Sink. schema: type: string minLength: 34 maxLength: 34 pattern: ^DG[0-9a-fA-F]{32}$ required: true responses: '200': content: application/json: schema: $ref: '#/components/schemas/events.v1.sink' examples: update: value: status: initialized sink_configuration: arn: arn:aws:kinesis:us-east-1:111111111:stream/test role_arn: arn:aws:iam::111111111:role/Role external_id: '1234567890' description: My Kinesis Sink sid: DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa date_created: '2015-07-30T20:00:00Z' sink_type: kinesis date_updated: '2015-07-30T20:00:00Z' url: https://events.twilio.com/v1/Sinks/DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa links: sink_test: https://events.twilio.com/v1/Sinks/DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Test sink_validate: https://events.twilio.com/v1/Sinks/DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Validate headers: Access-Control-Allow-Origin: description: Specify the origin(s) allowed to access the resource schema: type: string example: '*' Access-Control-Allow-Methods: description: Specify the HTTP methods allowed when accessing the resource schema: type: string example: POST, OPTIONS Access-Control-Allow-Headers: description: Specify the headers allowed when accessing the resource schema: type: string example: Content-Type, Authorization Access-Control-Allow-Credentials: description: Indicates whether the browser should include credentials schema: type: boolean Access-Control-Expose-Headers: description: Headers exposed to the client schema: type: string example: X-Custom-Header1, X-Custom-Header2 description: OK security: - accountSid_authToken: [] operationId: UpdateSink requestBody: content: application/x-www-form-urlencoded: schema: type: object title: UpdateSinkRequest properties: Description: type: string description: A human readable description for the Sink **This value should not contain PII.** required: - Description examples: update: value: Description: My Kinesis Sink /v1/Sinks: servers: - url: https://events.twilio.com description: Sink destination to send events to x-twilio: defaultOutputProperties: - date_created - date_updated - description - sid - sink_configuration - sink_type - status dependentProperties: sink_test: mapping: sid: sid resource_url: /v1/Sinks/{sid}/Test sink_validate: mapping: sid: sid resource_url: /v1/Sinks/{sid}/Validate pathType: list post: description: Create a new Sink summary: Create a new Sink tags: - EventsV1Sink responses: '201': content: application/json: schema: $ref: '#/components/schemas/events.v1.sink' examples: create: value: status: initialized sink_configuration: arn: arn:aws:kinesis:us-east-1:111111111:stream/test role_arn: arn:aws:iam::111111111:role/Role external_id: '1234567890' description: My Kinesis Sink sid: DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa date_created: '2015-07-30T20:00:00Z' sink_type: kinesis date_updated: '2015-07-30T20:00:00Z' url: https://events.twilio.com/v1/Sinks/DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa links: sink_test: https://events.twilio.com/v1/Sinks/DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Test sink_validate: https://events.twilio.com/v1/Sinks/DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Validate createSegment: value: status: initialized sink_configuration: write_key: MY_WRITEKEY description: My segment Sink sid: DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa date_created: '2015-07-30T20:00:00Z' sink_type: segment date_updated: '2015-07-30T20:00:00Z' url: https://events.twilio.com/v1/Sinks/DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa links: sink_test: https://events.twilio.com/v1/Sinks/DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Test sink_validate: https://events.twilio.com/v1/Sinks/DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Validate headers: Access-Control-Allow-Origin: description: Specify the origin(s) allowed to access the resource schema: type: string example: '*' Access-Control-Allow-Methods: description: Specify the HTTP methods allowed when accessing the resource schema: type: string example: POST, OPTIONS Access-Control-Allow-Headers: description: Specify the headers allowed when accessing the resource schema: type: string example: Content-Type, Authorization Access-Control-Allow-Credentials: description: Indicates whether the browser should include credentials schema: type: boolean Access-Control-Expose-Headers: description: Headers exposed to the client schema: type: string example: X-Custom-Header1, X-Custom-Header2 description: Created security: - accountSid_authToken: [] operationId: CreateSink requestBody: content: application/x-www-form-urlencoded: schema: type: object title: CreateSinkRequest properties: Description: type: string description: A human readable description for the Sink **This value should not contain PII.** SinkConfiguration: description: The information required for Twilio to connect to the provided Sink encoded as JSON. SinkType: $ref: '#/components/schemas/sink_enum_sink_type' required: - Description - SinkConfiguration - SinkType examples: create: value: Description: My Kinesis Sink SinkType: kinesis SinkConfiguration: '{"arn": "arn:aws:kinesis:us-east-1:111111111:stream/test","role_arn": "arn:aws:iam::111111111:role/Role","external_id": "1234567890"}' createSegment: value: Description: My segment Sink SinkType: segment SinkConfiguration: '{"write_key": "MY_WRITEKEY"}' get: description: Retrieve a paginated list of Sinks belonging to the account used to make the request. summary: Retrieve a paginated list of Sinks belonging to the account used to make the request. tags: - EventsV1Sink parameters: - name: InUse in: query description: A boolean query parameter filtering the results to return sinks used/not used by a subscription. schema: type: boolean examples: readResultsInUse: value: true - name: Status in: query description: A String query parameter filtering the results by status `initialized`, `validating`, `active` or `failed`. schema: type: string examples: readResultsStatus: value: active - name: PageSize in: query description: How many resources to return in each list page. The default is 50, and the maximum is 1000. schema: type: integer format: int64 minimum: 1 maximum: 1000 - name: Page in: query description: The page index. This value is simply for client state. schema: type: integer minimum: 0 - name: PageToken in: query description: The page token. This is provided by the API. schema: type: string responses: '200': content: application/json: schema: type: object properties: sinks: type: array items: $ref: '#/components/schemas/events.v1.sink' meta: properties: first_page_url: format: uri type: string key: type: string next_page_url: format: uri nullable: true type: string page: type: integer page_size: type: integer previous_page_url: format: uri nullable: true type: string url: format: uri type: string type: object title: ListSinkResponse examples: readEmpty: value: sinks: [] meta: page: 0 page_size: 10 first_page_url: https://events.twilio.com/v1/Sinks?PageSize=10&Page=0 previous_page_url: null url: https://events.twilio.com/v1/Sinks?PageSize=10&Page=0 next_page_url: null key: sinks readResults: value: sinks: - status: initialized sink_configuration: arn: arn:aws:kinesis:us-east-1:111111111:stream/test role_arn: arn:aws:iam::111111111:role/Role external_id: '1234567890' description: A Sink sid: DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa date_created: '2015-07-30T19:00:00Z' sink_type: kinesis date_updated: '2015-07-30T19:00:00Z' url: https://events.twilio.com/v1/Sinks/DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa links: sink_test: https://events.twilio.com/v1/Sinks/DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Test sink_validate: https://events.twilio.com/v1/Sinks/DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Validate - status: initialized sink_configuration: arn: arn:aws:kinesis:us-east-1:222222222:stream/test role_arn: arn:aws:iam::111111111:role/Role external_id: '1234567890' description: ANOTHER Sink sid: DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaab date_created: '2015-07-30T20:00:00Z' sink_type: kinesis date_updated: '2015-07-30T20:00:00Z' url: https://events.twilio.com/v1/Sinks/DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaab links: sink_test: https://events.twilio.com/v1/Sinks/DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaab/Test sink_validate: https://events.twilio.com/v1/Sinks/DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaab/Validate - status: active sink_configuration: destination: http://example.org/webhook method: POST batch_events: true description: A webhook Sink sid: DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaac date_created: '2015-07-30T21:00:00Z' sink_type: webhook date_updated: '2015-07-30T21:00:00Z' url: https://events.twilio.com/v1/Sinks/DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaac links: sink_test: https://events.twilio.com/v1/Sinks/DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaac/Test sink_validate: https://events.twilio.com/v1/Sinks/DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaac/Validate meta: page: 0 page_size: 20 first_page_url: https://events.twilio.com/v1/Sinks?PageSize=20&Page=0 previous_page_url: null url: https://events.twilio.com/v1/Sinks?PageSize=20&Page=0 next_page_url: null key: sinks readResultsInUse: value: sinks: - status: initialized sink_configuration: arn: arn:aws:kinesis:us-east-1:111111111:stream/test role_arn: arn:aws:iam::111111111:role/Role external_id: '1234567890' description: A Sink sid: DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa date_created: '2015-07-30T19:00:00Z' sink_type: kinesis date_updated: '2015-07-30T19:00:00Z' url: https://events.twilio.com/v1/Sinks/DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa links: sink_test: https://events.twilio.com/v1/Sinks/DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Test sink_validate: https://events.twilio.com/v1/Sinks/DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Validate - status: initialized sink_configuration: arn: arn:aws:kinesis:us-east-1:222222222:stream/test role_arn: arn:aws:iam::111111111:role/Role external_id: '1234567890' description: ANOTHER Sink sid: DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaab date_created: '2015-07-30T20:00:00Z' sink_type: kinesis date_updated: '2015-07-30T20:00:00Z' url: https://events.twilio.com/v1/Sinks/DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaab links: sink_test: https://events.twilio.com/v1/Sinks/DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaab/Test sink_validate: https://events.twilio.com/v1/Sinks/DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaab/Validate - status: active sink_configuration: destination: http://example.org/webhook method: POST batch_events: true description: A webhook Sink sid: DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaac date_created: '2015-07-30T21:00:00Z' sink_type: webhook date_updated: '2015-07-30T21:00:00Z' url: https://events.twilio.com/v1/Sinks/DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaac links: sink_test: https://events.twilio.com/v1/Sinks/DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaac/Test sink_validate: https://events.twilio.com/v1/Sinks/DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaac/Validate meta: page: 0 page_size: 20 first_page_url: https://events.twilio.com/v1/Sinks?InUse=true&PageSize=20&Page=0 previous_page_url: null url: https://events.twilio.com/v1/Sinks?InUse=true&PageSize=20&Page=0 next_page_url: null key: sinks readResultsStatus: value: sinks: - status: active sink_configuration: destination: http://example.org/webhook method: POST batch_events: true description: A webhook Sink sid: DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaac date_created: '2015-07-30T21:00:00Z' sink_type: webhook date_updated: '2015-07-30T21:00:00Z' url: https://events.twilio.com/v1/Sinks/DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaac links: sink_test: https://events.twilio.com/v1/Sinks/DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaac/Test sink_validate: https://events.twilio.com/v1/Sinks/DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaac/Validate meta: page: 0 page_size: 20 first_page_url: https://events.twilio.com/v1/Sinks?Status=active&PageSize=20&Page=0 previous_page_url: null url: https://events.twilio.com/v1/Sinks?Status=active&PageSize=20&Page=0 next_page_url: null key: sinks headers: Access-Control-Allow-Origin: description: Specify the origin(s) allowed to access the resource schema: type: string example: '*' Access-Control-Allow-Methods: description: Specify the HTTP methods allowed when accessing the resource schema: type: string example: POST, OPTIONS Access-Control-Allow-Headers: description: Specify the headers allowed when accessing the resource schema: type: string example: Content-Type, Authorization Access-Control-Allow-Credentials: description: Indicates whether the browser should include credentials schema: type: boolean Access-Control-Expose-Headers: description: Headers exposed to the client schema: type: string example: X-Custom-Header1, X-Custom-Header2 description: OK security: - accountSid_authToken: [] operationId: ListSink /v1/Sinks/{Sid}/Test: servers: - url: https://events.twilio.com description: Test sink x-twilio: defaultOutputProperties: - result parent: /Sinks/{Sid} mountName: sink_test pathType: list post: description: Create a new Sink Test Event for the given Sink. summary: Create a new Sink Test Event for the given Sink. tags: - EventsV1SinkTest parameters: - name: Sid in: path description: A 34 character string that uniquely identifies the Sink to be Tested. schema: type: string minLength: 34 maxLength: 34 pattern: ^DG[0-9a-fA-F]{32}$ required: true responses: '201': content: application/json: schema: $ref: '#/components/schemas/events.v1.sink.sink_test' examples: create: value: result: submitted headers: Access-Control-Allow-Origin: description: Specify the origin(s) allowed to access the resource schema: type: string example: '*' Access-Control-Allow-Methods: description: Specify the HTTP methods allowed when accessing the resource schema: type: string example: POST, OPTIONS Access-Control-Allow-Headers: description: Specify the headers allowed when accessing the resource schema: type: string example: Content-Type, Authorization Access-Control-Allow-Credentials: description: Indicates whether the browser should include credentials schema: type: boolean Access-Control-Expose-Headers: description: Headers exposed to the client schema: type: string example: X-Custom-Header1, X-Custom-Header2 description: Created '200': content: application/json: schema: $ref: '#/components/schemas/events.v1.sink.sink_test' examples: create200: value: result: submitted headers: Access-Control-Allow-Origin: description: Specify the origin(s) allowed to access the resource schema: type: string example: '*' Access-Control-Allow-Methods: description: Specify the HTTP methods allowed when accessing the resource schema: type: string example: POST, OPTIONS Access-Control-Allow-Headers: description: Specify the headers allowed when accessing the resource schema: type: string example: Content-Type, Authorization Access-Control-Allow-Credentials: description: Indicates whether the browser should include credentials schema: type: boolean Access-Control-Expose-Headers: description: Headers exposed to the client schema: type: string example: X-Custom-Header1, X-Custom-Header2 description: OK security: - accountSid_authToken: [] operationId: CreateSinkTest /v1/Sinks/{Sid}/Validate: servers: - url: https://events.twilio.com description: Validate sink x-twilio: defaultOutputProperties: - result parent: /Sinks/{Sid} mountName: sink_validate pathType: list post: description: Validate that a test event for a Sink was received. summary: Validate that a test event for a Sink was received. tags: - EventsV1SinkValidate parameters: - name: Sid in: path description: A 34 character string that uniquely identifies the Sink being validated. schema: type: string minLength: 34 maxLength: 34 pattern: ^DG[0-9a-fA-F]{32}$ required: true responses: '201': content: application/json: schema: $ref: '#/components/schemas/events.v1.sink.sink_validate' examples: create: value: result: valid headers: Access-Control-Allow-Origin: description: Specify the origin(s) allowed to access the resource schema: type: string example: '*' Access-Control-Allow-Methods: description: Specify the HTTP methods allowed when accessing the resource schema: type: string example: POST, OPTIONS Access-Control-Allow-Headers: description: Specify the headers allowed when accessing the resource schema: type: string example: Content-Type, Authorization Access-Control-Allow-Credentials: description: Indicates whether the browser should include credentials schema: type: boolean Access-Control-Expose-Headers: description: Headers exposed to the client schema: type: string example: X-Custom-Header1, X-Custom-Header2 description: Created security: - accountSid_authToken: [] operationId: CreateSinkValidate requestBody: content: application/x-www-form-urlencoded: schema: type: object title: CreateSinkValidateRequest properties: TestId: type: string description: A 34 character string that uniquely identifies the test event for a Sink being validated. required: - TestId examples: create: value: TestId: TestID /v1/Subscriptions/{SubscriptionSid}/SubscribedEvents: servers: - url: https://events.twilio.com description: Event subscribed to in the parent Subscription x-twilio: defaultOutputProperties: - type - schema_version - account_sid - subscription_sid parent: /Subscriptions/{Sid} pathType: list get: description: Retrieve a list of all Subscribed Event types for a Subscription. summary: Retrieve a list of all Subscribed Event types for a Subscription. tags: - EventsV1SubscribedEvent parameters: - name: SubscriptionSid in: path description: The unique SID identifier of the Subscription. schema: type: string minLength: 34 maxLength: 34 pattern: ^DF[0-9a-fA-F]{32}$ required: true - name: PageSize in: query description: How many resources to return in each list page. The default is 50, and the maximum is 1000. schema: type: integer format: int64 minimum: 1 maximum: 1000 - name: Page in: query description: The page index. This value is simply for client state. schema: type: integer minimum: 0 - name: PageToken in: query description: The page token. This is provided by the API. schema: type: string responses: '200': content: application/json: schema: type: object properties: types: type: array items: $ref: '#/components/schemas/events.v1.subscription.subscribed_event' meta: properties: first_page_url: format: uri type: string key: type: string next_page_url: format: uri nullable: true type: string page: type: integer page_size: type: integer previous_page_url: format: uri nullable: true type: string url: format: uri type: string type: object title: ListSubscribedEventResponse examples: readEmpty: value: types: [] meta: page: 0 page_size: 10 first_page_url: https://events.twilio.com/v1/Subscriptions/DFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/SubscribedEvents?PageSize=10&Page=0 previous_page_url: null url: https://events.twilio.com/v1/Subscriptions/DFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/SubscribedEvents?PageSize=10&Page=0 next_page_url: null key: types readResults: value: types: - account_sid: ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa type: com.twilio.messaging.message.delivered schema_version: 2 subscription_sid: DFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa url: https://events.twilio.com/v1/Subscriptions/DFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/SubscribedEvents/com.twilio.messaging.message.delivered - account_sid: ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa type: com.twilio.messaging.message.failed schema_version: 15 subscription_sid: DFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa url: https://events.twilio.com/v1/Subscriptions/DFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/SubscribedEvents/com.twilio.messaging.message.failed meta: page: 0 page_size: 50 first_page_url: https://events.twilio.com/v1/Subscriptions/DFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/SubscribedEvents?PageSize=50&Page=0 previous_page_url: null url: https://events.twilio.com/v1/Subscriptions/DFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/SubscribedEvents?PageSize=50&Page=0 next_page_url: null key: types headers: Access-Control-Allow-Origin: description: Specify the origin(s) allowed to access the resource schema: type: string example: '*' Access-Control-Allow-Methods: description: Specify the HTTP methods allowed when accessing the resource schema: type: string example: POST, OPTIONS Access-Control-Allow-Headers: description: Specify the headers allowed when accessing the resource schema: type: string example: Content-Type, Authorization Access-Control-Allow-Credentials: description: Indicates whether the browser should include credentials schema: type: boolean Access-Control-Expose-Headers: description: Headers exposed to the client schema: type: string example: X-Custom-Header1, X-Custom-Header2 description: OK security: - accountSid_authToken: [] operationId: ListSubscribedEvent post: description: Add an event type to a Subscription. summary: Add an event type to a Subscription. tags: - EventsV1SubscribedEvent parameters: - name: SubscriptionSid in: path description: The unique SID identifier of the Subscription. schema: type: string minLength: 34 maxLength: 34 pattern: ^DF[0-9a-fA-F]{32}$ required: true responses: '201': content: application/json: schema: $ref: '#/components/schemas/events.v1.subscription.subscribed_event' examples: create: value: account_sid: ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa subscription_sid: DFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa type: com.twilio.messaging.message.delivered schema_version: 2 url: https://events.twilio.com/v1/Subscriptions/DFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/SubscribedEvents/com.twilio.messaging.message.delivered headers: Access-Control-Allow-Origin: description: Specify the origin(s) allowed to access the resource schema: type: string example: '*' Access-Control-Allow-Methods: description: Specify the HTTP methods allowed when accessing the resource schema: type: string example: POST, OPTIONS Access-Control-Allow-Headers: description: Specify the headers allowed when accessing the resource schema: type: string example: Content-Type, Authorization Access-Control-Allow-Credentials: description: Indicates whether the browser should include credentials schema: type: boolean Access-Control-Expose-Headers: description: Headers exposed to the client schema: type: string example: X-Custom-Header1, X-Custom-Header2 description: Created '200': content: application/json: schema: $ref: '#/components/schemas/events.v1.subscription.subscribed_event' examples: create200: value: account_sid: ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa subscription_sid: DFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa type: com.twilio.messaging.message.delivered schema_version: 2 url: https://events.twilio.com/v1/Subscriptions/DFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/SubscribedEvents/com.twilio.messaging.message.delivered headers: Access-Control-Allow-Origin: description: Specify the origin(s) allowed to access the resource schema: type: string example: '*' Access-Control-Allow-Methods: description: Specify the HTTP methods allowed when accessing the resource schema: type: string example: POST, OPTIONS Access-Control-Allow-Headers: description: Specify the headers allowed when accessing the resource schema: type: string example: Content-Type, Authorization Access-Control-Allow-Credentials: description: Indicates whether the browser should include credentials schema: type: boolean Access-Control-Expose-Headers: description: Headers exposed to the client schema: type: string example: X-Custom-Header1, X-Custom-Header2 description: OK security: - accountSid_authToken: [] operationId: CreateSubscribedEvent requestBody: content: application/x-www-form-urlencoded: schema: type: object title: CreateSubscribedEventRequest properties: Type: type: string description: Type of event being subscribed to. SchemaVersion: type: integer description: The schema version that the Subscription should use. required: - Type examples: create: value: Type: com.twilio.messaging.message.delivered SchemaVersion: 2 create200: value: Type: com.twilio.messaging.message.delivered SchemaVersion: 2 /v1/Subscriptions/{SubscriptionSid}/SubscribedEvents/{Type}: servers: - url: https://events.twilio.com description: Event subscribed to in the parent Subscription x-twilio: defaultOutputProperties: - type - schema_version - account_sid - subscription_sid parent: /Subscriptions/{Sid} pathType: instance get: description: Read an Event for a Subscription. summary: Read an Event for a Subscription. tags: - EventsV1SubscribedEvent parameters: - name: SubscriptionSid in: path description: The unique SID identifier of the Subscription. schema: type: string minLength: 34 maxLength: 34 pattern: ^DF[0-9a-fA-F]{32}$ required: true - name: Type in: path description: Type of event being subscribed to. schema: type: string required: true responses: '200': content: application/json: schema: $ref: '#/components/schemas/events.v1.subscription.subscribed_event' examples: fetch: value: account_sid: ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa subscription_sid: DFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa type: com.twilio.messaging.message.delivered schema_version: 2 url: https://events.twilio.com/v1/Subscriptions/DFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/SubscribedEvents/com.twilio.messaging.message.delivered headers: Access-Control-Allow-Origin: description: Specify the origin(s) allowed to access the resource schema: type: string example: '*' Access-Control-Allow-Methods: description: Specify the HTTP methods allowed when accessing the resource schema: type: string example: POST, OPTIONS Access-Control-Allow-Headers: description: Specify the headers allowed when accessing the resource schema: type: string example: Content-Type, Authorization Access-Control-Allow-Credentials: description: Indicates whether the browser should include credentials schema: type: boolean Access-Control-Expose-Headers: description: Headers exposed to the client schema: type: string example: X-Custom-Header1, X-Custom-Header2 description: OK security: - accountSid_authToken: [] operationId: FetchSubscribedEvent post: description: Update an Event for a Subscription. summary: Update an Event for a Subscription. tags: - EventsV1SubscribedEvent parameters: - name: SubscriptionSid in: path description: The unique SID identifier of the Subscription. schema: type: string minLength: 34 maxLength: 34 pattern: ^DF[0-9a-fA-F]{32}$ required: true - name: Type in: path description: Type of event being subscribed to. schema: type: string required: true responses: '200': content: application/json: schema: $ref: '#/components/schemas/events.v1.subscription.subscribed_event' examples: update: value: account_sid: ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa subscription_sid: DFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa type: com.twilio.messaging.message.delivered schema_version: 2 url: https://events.twilio.com/v1/Subscriptions/DFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/SubscribedEvents/com.twilio.messaging.message.delivered headers: Access-Control-Allow-Origin: description: Specify the origin(s) allowed to access the resource schema: type: string example: '*' Access-Control-Allow-Methods: description: Specify the HTTP methods allowed when accessing the resource schema: type: string example: POST, OPTIONS Access-Control-Allow-Headers: description: Specify the headers allowed when accessing the resource schema: type: string example: Content-Type, Authorization Access-Control-Allow-Credentials: description: Indicates whether the browser should include credentials schema: type: boolean Access-Control-Expose-Headers: description: Headers exposed to the client schema: type: string example: X-Custom-Header1, X-Custom-Header2 description: OK security: - accountSid_authToken: [] operationId: UpdateSubscribedEvent requestBody: content: application/x-www-form-urlencoded: schema: type: object title: UpdateSubscribedEventRequest properties: SchemaVersion: type: integer description: The schema version that the Subscription should use. examples: update: value: SchemaVersion: 2 delete: description: Remove an event type from a Subscription. summary: Remove an event type from a Subscription. tags: - EventsV1SubscribedEvent parameters: - name: SubscriptionSid in: path description: The unique SID identifier of the Subscription. schema: type: string minLength: 34 maxLength: 34 pattern: ^DF[0-9a-fA-F]{32}$ required: true - name: Type in: path description: Type of event being subscribed to. schema: type: string required: true responses: '204': description: The resource was deleted successfully. security: - accountSid_authToken: [] operationId: DeleteSubscribedEvent /v1/Subscriptions: servers: - url: https://events.twilio.com description: Subscription to send Event Types to a Sink x-twilio: defaultOutputProperties: - account_sid - sid - sink_sid - date_created - date_updated dependentProperties: subscribed_events: mapping: subscription_sid: sid resource_url: /v1/Subscriptions/{subscription_sid}/SubscribedEvents pathType: list get: description: Retrieve a paginated list of Subscriptions belonging to the account used to make the request. summary: Retrieve a paginated list of Subscriptions belonging to the account used to make the request. tags: - EventsV1Subscription parameters: - name: SinkSid in: query description: The SID of the sink that the list of Subscriptions should be filtered by. schema: type: string minLength: 34 maxLength: 34 pattern: ^DG[0-9a-fA-F]{32}$ examples: readResultsFilteredBySinkSid: value: DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa - name: PageSize in: query description: How many resources to return in each list page. The default is 50, and the maximum is 1000. schema: type: integer format: int64 minimum: 1 maximum: 1000 - name: Page in: query description: The page index. This value is simply for client state. schema: type: integer minimum: 0 - name: PageToken in: query description: The page token. This is provided by the API. schema: type: string responses: '200': content: application/json: schema: type: object properties: subscriptions: type: array items: $ref: '#/components/schemas/events.v1.subscription' meta: properties: first_page_url: format: uri type: string key: type: string next_page_url: format: uri nullable: true type: string page: type: integer page_size: type: integer previous_page_url: format: uri nullable: true type: string url: format: uri type: string type: object title: ListSubscriptionResponse examples: readEmpty: value: subscriptions: [] meta: page: 0 page_size: 10 first_page_url: https://events.twilio.com/v1/Subscriptions?PageSize=10&Page=0 previous_page_url: null url: https://events.twilio.com/v1/Subscriptions?PageSize=10&Page=0 next_page_url: null key: subscriptions readResults: value: subscriptions: - account_sid: ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa date_created: '2015-07-30T20:00:00Z' date_updated: '2015-07-30T20:01:33Z' sid: DFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa sink_sid: DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa description: A subscription url: https://events.twilio.com/v1/Subscriptions/DFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa links: subscribed_events: https://events.twilio.com/v1/Subscriptions/DFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/SubscribedEvents - account_sid: ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa date_created: '2015-07-30T20:00:00Z' date_updated: '2015-07-30T20:01:33Z' sid: DFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaab sink_sid: DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa description: Another subscription url: https://events.twilio.com/v1/Subscriptions/DFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaab links: subscribed_events: https://events.twilio.com/v1/Subscriptions/DFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaab/SubscribedEvents meta: page: 0 page_size: 20 first_page_url: https://events.twilio.com/v1/Subscriptions?PageSize=20&Page=0 previous_page_url: null url: https://events.twilio.com/v1/Subscriptions?PageSize=20&Page=0 next_page_url: null key: subscriptions readResultsFilteredBySinkSid: value: subscriptions: - account_sid: ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa date_created: '2015-07-30T20:00:00Z' date_updated: '2015-07-30T20:01:33Z' sid: DFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa sink_sid: DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa description: A subscription url: https://events.twilio.com/v1/Subscriptions/DFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa links: subscribed_events: https://events.twilio.com/v1/Subscriptions/DFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/SubscribedEvents - account_sid: ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa date_created: '2015-07-30T20:00:00Z' date_updated: '2015-07-30T20:01:33Z' sid: DFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaab sink_sid: DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa description: Another subscription url: https://events.twilio.com/v1/Subscriptions/DFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaab links: subscribed_events: https://events.twilio.com/v1/Subscriptions/DFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaab/SubscribedEvents meta: page: 0 page_size: 10 first_page_url: https://events.twilio.com/v1/Subscriptions?SinkSid=DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa&PageSize=10&Page=0 previous_page_url: null url: https://events.twilio.com/v1/Subscriptions?SinkSid=DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa&PageSize=10&Page=0 next_page_url: null key: subscriptions headers: Access-Control-Allow-Origin: description: Specify the origin(s) allowed to access the resource schema: type: string example: '*' Access-Control-Allow-Methods: description: Specify the HTTP methods allowed when accessing the resource schema: type: string example: POST, OPTIONS Access-Control-Allow-Headers: description: Specify the headers allowed when accessing the resource schema: type: string example: Content-Type, Authorization Access-Control-Allow-Credentials: description: Indicates whether the browser should include credentials schema: type: boolean Access-Control-Expose-Headers: description: Headers exposed to the client schema: type: string example: X-Custom-Header1, X-Custom-Header2 description: OK security: - accountSid_authToken: [] operationId: ListSubscription post: description: Create a new Subscription. summary: Create a new Subscription. tags: - EventsV1Subscription parameters: [] responses: '201': content: application/json: schema: $ref: '#/components/schemas/events.v1.subscription' examples: create: value: account_sid: ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa date_created: '2015-07-30T20:00:00Z' date_updated: '2015-07-30T20:01:33Z' sid: DFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa sink_sid: DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa description: A subscription url: https://events.twilio.com/v1/Subscriptions/DFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa links: subscribed_events: https://events.twilio.com/v1/Subscriptions/DFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/SubscribedEvents headers: Access-Control-Allow-Origin: description: Specify the origin(s) allowed to access the resource schema: type: string example: '*' Access-Control-Allow-Methods: description: Specify the HTTP methods allowed when accessing the resource schema: type: string example: POST, OPTIONS Access-Control-Allow-Headers: description: Specify the headers allowed when accessing the resource schema: type: string example: Content-Type, Authorization Access-Control-Allow-Credentials: description: Indicates whether the browser should include credentials schema: type: boolean Access-Control-Expose-Headers: description: Headers exposed to the client schema: type: string example: X-Custom-Header1, X-Custom-Header2 description: Created security: - accountSid_authToken: [] operationId: CreateSubscription requestBody: content: application/x-www-form-urlencoded: schema: type: object title: CreateSubscriptionRequest properties: Description: type: string description: A human readable description for the Subscription **This value should not contain PII.** SinkSid: type: string minLength: 34 maxLength: 34 pattern: ^DG[0-9a-fA-F]{32}$ description: The SID of the sink that events selected by this subscription should be sent to. Sink must be active for the subscription to be created. Types: type: array items: {} description: An array of objects containing the subscribed Event Types required: - Description - SinkSid - Types examples: create: value: SinkSid: DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa Description: A subscription Types: - '{"type": "com.twilio.messaging.message.delivered","schema_version": 1}' - '{"type": "com.twilio.messaging.message.failed","schema_version": 12}' Filter: messageStatus == 'FAILED' AND errorCode == 30004 /v1/Subscriptions/{Sid}: servers: - url: https://events.twilio.com description: Subscription to send Event Types to a Sink x-twilio: defaultOutputProperties: - account_sid - sid - sink_sid - date_created - date_updated dependentProperties: subscribed_events: mapping: subscription_sid: sid resource_url: /v1/Subscriptions/{subscription_sid}/SubscribedEvents pathType: instance get: description: Fetch a specific Subscription. summary: Fetch a specific Subscription. tags: - EventsV1Subscription parameters: - name: Sid in: path description: A 34 character string that uniquely identifies this Subscription. schema: type: string minLength: 34 maxLength: 34 pattern: ^DF[0-9a-fA-F]{32}$ required: true responses: '200': content: application/json: schema: $ref: '#/components/schemas/events.v1.subscription' examples: fetch: value: account_sid: ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa date_created: '2015-07-30T20:00:00Z' date_updated: '2015-07-30T20:01:33Z' sid: DFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa sink_sid: DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa description: A subscription url: https://events.twilio.com/v1/Subscriptions/DFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa links: subscribed_events: https://events.twilio.com/v1/Subscriptions/DFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/SubscribedEvents headers: Access-Control-Allow-Origin: description: Specify the origin(s) allowed to access the resource schema: type: string example: '*' Access-Control-Allow-Methods: description: Specify the HTTP methods allowed when accessing the resource schema: type: string example: POST, OPTIONS Access-Control-Allow-Headers: description: Specify the headers allowed when accessing the resource schema: type: string example: Content-Type, Authorization Access-Control-Allow-Credentials: description: Indicates whether the browser should include credentials schema: type: boolean Access-Control-Expose-Headers: description: Headers exposed to the client schema: type: string example: X-Custom-Header1, X-Custom-Header2 description: OK security: - accountSid_authToken: [] operationId: FetchSubscription post: description: Update a Subscription. summary: Update a Subscription. tags: - EventsV1Subscription parameters: - name: Sid in: path description: A 34 character string that uniquely identifies this Subscription. schema: type: string minLength: 34 maxLength: 34 pattern: ^DF[0-9a-fA-F]{32}$ required: true responses: '200': content: application/json: schema: $ref: '#/components/schemas/events.v1.subscription' examples: update: value: account_sid: ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa date_created: '2015-07-30T20:00:00Z' date_updated: '2020-07-30T20:01:33Z' sid: DFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa sink_sid: DGaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaab description: Updated description url: https://events.twilio.com/v1/Subscriptions/DFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa links: subscribed_events: https://events.twilio.com/v1/Subscriptions/DFaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/SubscribedEvents headers: Access-Control-Allow-Origin: description: Specify the origin(s) allowed to access the resource schema: type: string example: '*' Access-Control-Allow-Methods: description: Specify the HTTP methods allowed when accessing the resource schema: type: string example: POST, OPTIONS Access-Control-Allow-Headers: description: Specify the headers allowed when accessing the resource schema: type: string example: Content-Type, Authorization Access-Control-Allow-Credentials: description: Indicates whether the browser should include credentials schema: type: boolean Access-Control-Expose-Headers: description: Headers exposed to the client schema: type: string example: X-Custom-Header1, X-Custom-Header2 description: OK security: - accountSid_authToken: [] operationId: UpdateSubscription requestBody: content: application/x-www-form-urlencoded: schema: type: object title: UpdateSubscriptionRequest properties: Description: type: string description: A human readable description for the Subscription. examples: update: value: Description: Updated description Filter: messageStatus == 'FAILED' AND errorCode == 30004 delete: description: Delete a specific Subscription. summary: Delete a specific Subscription. tags: - EventsV1Subscription parameters: - name: Sid in: path description: A 34 character string that uniquely identifies this Subscription. schema: type: string minLength: 34 maxLength: 34 pattern: ^DF[0-9a-fA-F]{32}$ required: true responses: '204': description: The resource was deleted successfully. security: - accountSid_authToken: [] operationId: DeleteSubscription servers: - url: https://events.twilio.com tags: - name: EventsV1EventType - name: EventsV1Index - name: EventsV1Replay - name: EventsV1Schema - name: EventsV1SchemaVersion - name: EventsV1Sink - name: EventsV1SinkTest - name: EventsV1SinkValidate - name: EventsV1SubscribedEvent - name: EventsV1Subscription - name: EventsV1Version security: - accountSid_authToken: []