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

REST API: Connect Apps


The ConnectApps list resource shows all of the Connect Apps that you have created within your Twilio account. The instance resource shows information about the ConnectApp as well as the permissions the ConnectApp will request from authorized users.


ConnectApp Instance Resource

instance page anchor

Resource URI

instance-uri page anchor

_10
/2010-04-01/Accounts/{AccountSid}/ConnectApps/{ConnectAppSid}

Resource properties
account_sidtype: SID<AC>
Not PII

The SID of the Account(link takes you to an external page) that created the ConnectApp resource.

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

authorize_redirect_urltype: string<uri>

The URL we redirect the user to after we authenticate the user and obtain authorization to access the Connect App.


company_nametype: string

The company name set for the Connect App.


deauthorize_callback_methodtype: enum<http-method>

The HTTP method we use to call deauthorize_callback_url.

Possible values:
GETPOST

deauthorize_callback_urltype: string<uri>

The URL we call using the deauthorize_callback_method to de-authorize the Connect App.


descriptiontype: string

The description of the Connect App.


friendly_nametype: string

The string that you assigned to describe the resource.


homepage_urltype: string<uri>

The public URL where users can obtain more information about this Connect App.


permissionstype: array[string]

The set of permissions that your ConnectApp requests.

Possible values:
get-allpost-all

sidtype: SID<CN>

The unique string that that we created to identify the ConnectApp resource.

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

uritype: string

The URI of the resource, relative to https://api.twilio.com.

Get the properties of a Connect App.

Example

instance-get-example-1 page anchor
Node.js
Python
C#
Java
Go
PHP
Ruby
twilio-cli
curl

_10
// Download the helper library from https://www.twilio.com/docs/node/install
_10
// Find your Account SID and Auth Token at twilio.com/console
_10
// and set the environment variables. See http://twil.io/secure
_10
const accountSid = process.env.TWILIO_ACCOUNT_SID;
_10
const authToken = process.env.TWILIO_AUTH_TOKEN;
_10
const client = require('twilio')(accountSid, authToken);
_10
_10
client.connectApps('CNb989fdd207b04d16aee578018ef5fd93')
_10
.fetch()
_10
.then(connect_app => console.log(connect_app.companyName));

Output

_13
{
_13
"account_sid": "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
_13
"authorize_redirect_url": "http://example.com/redirect",
_13
"company_name": "Twilio",
_13
"deauthorize_callback_method": "GET",
_13
"deauthorize_callback_url": "http://example.com/deauth",
_13
"description": null,
_13
"friendly_name": "Connect app for deletion",
_13
"homepage_url": "http://example.com/home",
_13
"permissions": [],
_13
"sid": "CNb989fdd207b04d16aee578018ef5fd93",
_13
"uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/ConnectApps/CNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX.json"
_13
}

Tries to update the Connect App's properties, and returns the updated resource representation if successful. The returned response is identical to that returned above when making a GET request.

You may specify one or more of the following parameters to update this Connect App's respective properties:

URI parameters
AccountSidtype: SID<AC>
Path ParameterNot PII

The SID of the Account(link takes you to an external page) that created the ConnectApp resources to update.

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

Sidtype: SID<CN>
Path ParameterNot PII

The Twilio-provided string that uniquely identifies the ConnectApp resource to update.

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

Request body parameters
AuthorizeRedirectUrltype: string<uri>

The URL to redirect the user to after we authenticate the user and obtain authorization to access the Connect App.


CompanyNametype: string

The company name to set for the Connect App.


DeauthorizeCallbackMethodtype: enum<http-method>

The HTTP method to use when calling deauthorize_callback_url.

Possible values:
GETPOST

DeauthorizeCallbackUrltype: string<uri>

The URL to call using the deauthorize_callback_method to de-authorize the Connect App.


Descriptiontype: string

A description of the Connect App.


FriendlyNametype: string

A descriptive string that you create to describe the resource. It can be up to 64 characters long.


HomepageUrltype: string<uri>

A public URL where users can obtain more information about this Connect App.


Permissionstype: array[string]

A comma-separated list of the permissions you will request from the users of this ConnectApp. Can include: get-all and post-all.

Possible values:
get-allpost-all

Not supported.

Not supported.


ConnectApp List Resource

list page anchor

_10
/2010-04-01/Accounts/{AccountSid}/ConnectApps

Returns a list of Connect App resource representations, each representing a Connect App in your account. The list includes paging information.

Retrieve all Connect Apps

retrieve-all-connect-apps page anchor
Node.js
Python
C#
Java
Go
PHP
Ruby
twilio-cli
curl

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

Output

_25
{
_25
"connect_apps": [
_25
{
_25
"account_sid": "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
_25
"authorize_redirect_url": "http://example.com/redirect",
_25
"company_name": "Twilio",
_25
"deauthorize_callback_method": "GET",
_25
"deauthorize_callback_url": "http://example.com/deauth",
_25
"description": null,
_25
"friendly_name": "Connect app for deletion",
_25
"homepage_url": "http://example.com/home",
_25
"permissions": [],
_25
"sid": "CNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
_25
"uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/ConnectApps/CNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX.json"
_25
}
_25
],
_25
"end": 0,
_25
"first_page_uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/ConnectApps.json?Page=0&PageSize=50",
_25
"next_page_uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/ConnectApps.json?Page=2&PageSize=50",
_25
"page": 0,
_25
"page_size": 50,
_25
"previous_page_uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/ConnectApps.json?Page=1&PageSize=50",
_25
"start": 0,
_25
"uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/ConnectApps.json"
_25
}

Not Supported.

Not Supported.

Not Supported.


Rate this page: