Skip to contentSkip to navigationSkip to topbar
Rate this page:
On this page

Schema Version Resource



SchemaVersion Properties

schemaversion-properties page anchor
Resource properties
idtype: stringNot PII

The unique identifier of the schema. Each schema can have multiple versions, that share the same id.


schema_versiontype: integerNot PII

The version of this schema.


date_createdtype: string<DATE TIME>Not PII

The date the schema version was created, given in ISO 8601 format.


urltype: string<URI>Not PII

The URL of this resource.


rawtype: string<URI>Not PII

Fetch a SchemaVersion resource

fetch-a-schemaversion-resource page anchor
GET https://events.twilio.com/v1/Schemas/{Id}/Versions/{SchemaVersion}

Parameters

fetch-parameters page anchor
URI parameters
Idtype: stringNot PII
Path Parameter

The unique identifier of the schema. Each schema can have multiple versions, that share the same id.


SchemaVersiontype: integerNot PII
Path Parameter

The version of the schema

Node.js
Python
C#
Java
Go
PHP
Ruby
twilio-cli
curl

_11
// Download the helper library from https://www.twilio.com/docs/node/install
_11
// Find your Account SID and Auth Token at twilio.com/console
_11
// and set the environment variables. See http://twil.io/secure
_11
const accountSid = process.env.TWILIO_ACCOUNT_SID;
_11
const authToken = process.env.TWILIO_AUTH_TOKEN;
_11
const client = require('twilio')(accountSid, authToken);
_11
_11
client.events.v1.schemas('Messaging.MessageStatus')
_11
.versions(1)
_11
.fetch()
_11
.then(schema_version => console.log(schema_version.id));

Output

_10
{
_10
"id": "Messaging.MessageStatus",
_10
"schema_version": 1,
_10
"date_created": "2015-07-30T20:00:00Z",
_10
"url": "https://events.twilio.com/v1/Schemas/Messaging.MessageStatus/Versions/1",
_10
"raw": "https://events-schemas.twilio.com/Messaging.MessageStatus/1"
_10
}


Read multiple SchemaVersion resources

read-multiple-schemaversion-resources page anchor
GET https://events.twilio.com/v1/Schemas/{Id}/Versions

URI parameters
Idtype: stringNot PII
Path Parameter

The unique identifier of the schema. Each schema can have multiple versions, that share the same id.


PageSizetype: integerNot PII
Query Parameter

How many resources to return in each list page. The default is 50, and the maximum is 1000.


Pagetype: integerNot PII
Query Parameter

The page index. This value is simply for client state.


PageTokentype: stringNot PII
Query Parameter

The page token. This is provided by the API.

Node.js
Python
C#
Java
Go
PHP
Ruby
twilio-cli
curl

_11
// Download the helper library from https://www.twilio.com/docs/node/install
_11
// Find your Account SID and Auth Token at twilio.com/console
_11
// and set the environment variables. See http://twil.io/secure
_11
const accountSid = process.env.TWILIO_ACCOUNT_SID;
_11
const authToken = process.env.TWILIO_AUTH_TOKEN;
_11
const client = require('twilio')(accountSid, authToken);
_11
_11
client.events.v1.schemas('id')
_11
.versions
_11
.list({limit: 20})
_11
.then(versions => versions.forEach(v => console.log(v.id)));

Output

_29
{
_29
"schema_versions": [
_29
{
_29
"id": "Messaging.MessageStatus",
_29
"schema_version": 1,
_29
"public": true,
_29
"date_created": "2015-07-30T20:00:00Z",
_29
"url": "https://events.twilio.com/v1/Schemas/Messaging.MessageStatus/Versions/1",
_29
"raw": "https://events-schemas.twilio.com/Messaging.MessageStatus/1"
_29
},
_29
{
_29
"id": "Messaging.MessageStatus",
_29
"schema_version": 2,
_29
"public": true,
_29
"date_created": "2015-07-30T20:00:00Z",
_29
"url": "https://events.twilio.com/v1/Schemas/Messaging.MessageStatus/Versions/2",
_29
"raw": "https://events-schemas.twilio.com/Messaging.MessageStatus/2"
_29
}
_29
],
_29
"meta": {
_29
"page": 0,
_29
"page_size": 50,
_29
"first_page_url": "https://events.twilio.com/v1/Schemas/Messaging.MessageStatus/Versions?PageSize=50&Page=0",
_29
"previous_page_url": "https://events.twilio.com/v1/Schemas/Messaging.MessageStatus/Versions?PageSize=50&Page=0",
_29
"url": "https://events.twilio.com/v1/Schemas/Messaging.MessageStatus/Versions?PageSize=50&Page=0",
_29
"next_page_url": "https://events.twilio.com/v1/Schemas/Messaging.MessageStatus/Versions?PageSize=50&Page=1",
_29
"key": "schema_versions"
_29
}
_29
}


Rate this page: