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

Plugin Version Resource


A Plugin Version contains all the information about a particular version of a Plugin. Some notable fields include the URL to the plugin package, the version number and what plugin is it the version of.

Providing a URL to the built package in the plugin version provides you the flexibility of hosting your package in the software of your choice.


PluginVersion Properties

pluginversion-properties page anchor
Resource properties
sidtype: SID<FV>
Not PII

The unique string that we created to identify the Flex Plugin Version resource.

Pattern:
^FV[0-9a-fA-F]{32}$
Min length:
34
Max length:
34

plugin_sidtype: SID<FP>

The SID of the Flex Plugin resource this Flex Plugin Version belongs to.

Pattern:
^FP[0-9a-fA-F]{32}$
Min length:
34
Max length:
34

account_sidtype: SID<AC>

The SID of the Account(link takes you to an external page) that created the Flex Plugin Version resource and owns this resource.

Pattern:
^AC[0-9a-fA-F]{32}$
Min length:
34
Max length:
34

versiontype: string

The unique version of this Flex Plugin Version.


plugin_urltype: string<uri>

The URL of where the Flex Plugin Version JavaScript bundle is hosted on.


changelogtype: string

A changelog that describes the changes this Flex Plugin Version brings.


privatetype: boolean

Whether to inject credentials while accessing this Plugin Version. The default value is false.


archivedtype: boolean

Whether the Flex Plugin Version is archived. The default value is false.


date_createdtype: string<date-time>

The date and time in GMT when the Flex Plugin Version was created specified in ISO 8601(link takes you to an external page) format.


urltype: string<uri>

The absolute URL of the Flex Plugin Version resource.


Create a PluginVersion resource

create-a-pluginversion-resource page anchor
POST https://flex-api.twilio.com/v1/PluginService/Plugins/{PluginSid}/Versions

Parameters

create-parameters page anchor
Request headers
Flex-Metadatatype: string

The Flex-Metadata HTTP request header


URI parameters
PluginSidtype: string
Path ParameterNot PII

The SID of the Flex Plugin the resource to belongs to.


Request body parameters
Versiontype: stringRequired

The Flex Plugin Version's version.


PluginUrltype: string<uri>Required

The URL of the Flex Plugin Version bundle


Changelogtype: string

The changelog of the Flex Plugin Version.


Privatetype: boolean

Whether this Flex Plugin Version requires authorization.


CliVersiontype: string

The version of Flex Plugins CLI used to create this plugin


ValidateStatustype: string

The validation status of the plugin, indicating whether it has been validated

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

_14
// Download the helper library from https://www.twilio.com/docs/node/install
_14
// Find your Account SID and Auth Token at twilio.com/console
_14
// and set the environment variables. See http://twil.io/secure
_14
const accountSid = process.env.TWILIO_ACCOUNT_SID;
_14
const authToken = process.env.TWILIO_AUTH_TOKEN;
_14
const client = require('twilio')(accountSid, authToken);
_14
_14
client.flexApi.v1.plugins('FPXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX')
_14
.pluginVersions
_14
.create({
_14
version: 'version',
_14
pluginUrl: 'https://example.com'
_14
})
_14
.then(plugin_versions => console.log(plugin_versions.sid));

Output

_13
{
_13
"sid": "FVXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
_13
"account_sid": "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
_13
"plugin_sid": "FPXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
_13
"version": "1.0.0",
_13
"plugin_url": "https://sample.twil.io/plugin.js",
_13
"changelog": "the changelog",
_13
"private": true,
_13
"archived": false,
_13
"validated": false,
_13
"date_created": "2020-01-10T20:00:00Z",
_13
"url": "https://flex-api.twilio.com/v1/PluginService/Plugins/FPXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Versions/FVXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"
_13
}


Fetch a PluginVersion resource

fetch-a-pluginversion-resource page anchor
GET https://flex-api.twilio.com/v1/PluginService/Plugins/{PluginSid}/Versions/{Sid}

Request headers
Flex-Metadatatype: string

The Flex-Metadata HTTP request header


URI parameters
PluginSidtype: string
Path ParameterNot PII

The SID of the Flex Plugin the resource to belongs to.


Sidtype: string
Path ParameterNot PII

The SID of the Flex Plugin Version resource to fetch.

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.flexApi.v1.plugins('FPXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX')
_11
.pluginVersions('FVXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX')
_11
.fetch()
_11
.then(plugin_versions => console.log(plugin_versions.sid));

Output

_13
{
_13
"sid": "FVXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
_13
"account_sid": "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
_13
"plugin_sid": "FPXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
_13
"version": "1.0.0",
_13
"plugin_url": "https://sample.twil.io/plugin.js",
_13
"changelog": "the changelog",
_13
"private": false,
_13
"archived": false,
_13
"validated": false,
_13
"date_created": "2020-01-10T20:00:00Z",
_13
"url": "https://flex-api.twilio.com/v1/PluginService/Plugins/FPXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Versions/FVXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"
_13
}


Read multiple PluginVersion resources

read-multiple-pluginversion-resources page anchor
GET https://flex-api.twilio.com/v1/PluginService/Plugins/{PluginSid}/Versions

Request headers
Flex-Metadatatype: string

The Flex-Metadata HTTP request header


URI parameters
PluginSidtype: string
Path ParameterNot PII

The SID of the Flex Plugin the resource to belongs to.


PageSizetype: integer
Query ParameterNot PII

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

Minimum:
1

Pagetype: integer
Query ParameterNot PII

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

Minimum:
0

PageTokentype: string
Query ParameterNot PII

The page token. This is provided by the API.

List multiple PluginVersions

list-multiple-pluginversions page anchor
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.flexApi.v1.plugins('FPXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX')
_11
.pluginVersions
_11
.list({limit: 20})
_11
.then(pluginVersions => pluginVersions.forEach(p => console.log(p.sid)));

Output

_26
{
_26
"plugin_versions": [
_26
{
_26
"sid": "FVXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
_26
"account_sid": "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
_26
"plugin_sid": "FPXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
_26
"version": "1.0.0",
_26
"plugin_url": "https://sample.twil.io/plugin.js",
_26
"changelog": "the changelog",
_26
"private": false,
_26
"archived": false,
_26
"validated": false,
_26
"date_created": "2020-01-10T20:00:00Z",
_26
"url": "https://flex-api.twilio.com/v1/PluginService/Plugins/FPXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Versions/FVXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"
_26
}
_26
],
_26
"meta": {
_26
"page": 0,
_26
"page_size": 50,
_26
"first_page_url": "https://flex-api.twilio.com/v1/PluginService/Plugins/FPXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Versions?PageSize=50&Page=0",
_26
"previous_page_url": "https://flex-api.twilio.com/v1/PluginService/Plugins/FPXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Versions?PageSize=50&Page=0",
_26
"url": "https://flex-api.twilio.com/v1/PluginService/Plugins/FPXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Versions?PageSize=50&Page=0",
_26
"next_page_url": "https://flex-api.twilio.com/v1/PluginService/Plugins/FPXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Versions?PageSize=50&Page=1",
_26
"key": "plugin_versions"
_26
}
_26
}


Rate this page: