For general information on the Trust Hub API, go to the Trust Hub API Docs.
This page walks Direct Customers using subaccounts through creating a SHAKEN/STIR Trust Product with the Trust Hub REST API.
Not a Direct Customer using subaccounts? Find the appropriate onboarding instructions below:
ChannelEndpointType
. It needs to be
phone-number
to add a phone number to your Business Profile.
_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_14const accountSid = process.env.TWILIO_ACCOUNT_SID;_14const authToken = process.env.TWILIO_AUTH_TOKEN;_14const client = require('twilio')(accountSid, authToken);_14_14client.trusthub.v1.customerProfiles('YOUR_BUSINESS_PROFILE_SID')_14 .customerProfilesChannelEndpointAssignment_14 .create({_14 channelEndpointType: 'phone-number',_14 channelEndpointSid: 'YOUR_PHONE_NUMBER_SID'_14 })_14 .then(customer_profiles_channel_endpoint_assignment => console.log(customer_profiles_channel_endpoint_assignment.sid));
_10{_10 "sid": "RAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_10 "customer_profile_sid": "BUXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_10 "account_sid": "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_10 "channel_endpoint_sid": "PNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_10 "channel_endpoint_type": "phone-number",_10 "date_created": "2019-07-31T02:34:41Z",_10 "url": "https://trusthub.twilio.com/v1/CustomerProfiles/BUXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/ChannelEndpointAssignments/RAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"_10}
_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_14const accountSid = process.env.TWILIO_ACCOUNT_SID;_14const authToken = process.env.TWILIO_AUTH_TOKEN;_14const client = require('twilio')(accountSid, authToken);_14_14client.trusthub.v1.trustProducts_14 .create({_14 friendlyName: 'FRIENDLY_NAME_FOR_YOUR_TRUST_PRODUCT',_14 email: 'EMAIL@EMAIL.COM',_14 policySid: 'RN7a97559effdf62d00f4298208492a5ea'_14 })_14 .then(trust_products => console.log(trust_products.sid));
_19{_19 "sid": "BUXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_19 "account_sid": "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_19 "policy_sid": "RN7a97559effdf62d00f4298208492a5ea",_19 "friendly_name": "FRIENDLY_NAME_FOR_YOUR_TRUST_PRODUCT",_19 "status": "draft",_19 "email": "EMAIL@EMAIL.COM",_19 "status_callback": "http://www.example.com",_19 "valid_until": null,_19 "date_created": "2019-07-30T22:29:24Z",_19 "date_updated": "2019-07-31T01:09:00Z",_19 "url": "https://trusthub.twilio.com/v1/TrustProducts/BUXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_19 "links": {_19 "trust_products_entity_assignments": "https://trusthub.twilio.com/v1/TrustProducts/BUXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/EntityAssignments",_19 "trust_products_evaluations": "https://trusthub.twilio.com/v1/TrustProducts/BUXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Evaluations",_19 "trust_products_channel_endpoint_assignment": "https://trusthub.twilio.com/v1/TrustProducts/BUXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/ChannelEndpointAssignments"_19 },_19 "errors": null_19}
_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_11const accountSid = process.env.TWILIO_ACCOUNT_SID;_11const authToken = process.env.TWILIO_AUTH_TOKEN;_11const client = require('twilio')(accountSid, authToken);_11_11client.trusthub.v1.trustProducts('YOUR_TRUST_PRODUCT_SID')_11 .trustProductsEntityAssignments_11 .create({objectSid: 'YOUR_BUSINESS_PROFILE_SID'})_11 .then(trust_products_entity_assignments => console.log(trust_products_entity_assignments.sid));
_10{_10 "sid": "BVXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_10 "trust_product_sid": "BUXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_10 "account_sid": "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_10 "object_sid": "RDXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_10 "date_created": "2019-07-31T02:34:41Z",_10 "url": "https://trusthub.twilio.com/v1/TrustProducts/BUXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/EntityAssignments/BVXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"_10}
ChannelEndpointType
_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_14const accountSid = process.env.TWILIO_ACCOUNT_SID;_14const authToken = process.env.TWILIO_AUTH_TOKEN;_14const client = require('twilio')(accountSid, authToken);_14_14client.trusthub.v1.trustProducts('YOUR_TRUST_PRODUCT_SID')_14 .trustProductsChannelEndpointAssignment_14 .create({_14 channelEndpointType: 'phone-number',_14 channelEndpointSid: 'YOUR_PHONE_NUMBER_SID'_14 })_14 .then(trust_products_channel_endpoint_assignment => console.log(trust_products_channel_endpoint_assignment.sid));
_10{_10 "sid": "RAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_10 "trust_product_sid": "BUXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_10 "account_sid": "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_10 "channel_endpoint_sid": "PNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_10 "channel_endpoint_type": "phone-number",_10 "date_created": "2019-07-31T02:34:41Z",_10 "url": "https://trusthub.twilio.com/v1/TrustProducts/BUXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/ChannelEndpointAssignments/RAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"_10}
_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_10const accountSid = process.env.TWILIO_ACCOUNT_SID;_10const authToken = process.env.TWILIO_AUTH_TOKEN;_10const client = require('twilio')(accountSid, authToken);_10_10client.trusthub.v1.trustProducts('YOUR_TRUST_PRODUCT_SID')_10 .update({status: 'pending-review'})_10 .then(trust_products => console.log(trust_products.friendlyName));
_19{_19 "sid": "BUXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_19 "account_sid": "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_19 "policy_sid": "RNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_19 "friendly_name": "friendly_name",_19 "status": "pending-review",_19 "email": "email",_19 "status_callback": "http://www.example.com",_19 "valid_until": null,_19 "date_created": "2019-07-30T22:29:24Z",_19 "date_updated": "2019-07-31T01:09:00Z",_19 "url": "https://trusthub.twilio.com/v1/TrustProducts/BUXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_19 "links": {_19 "trust_products_entity_assignments": "https://trusthub.twilio.com/v1/TrustProducts/BUXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/EntityAssignments",_19 "trust_products_evaluations": "https://trusthub.twilio.com/v1/TrustProducts/BUXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Evaluations",_19 "trust_products_channel_endpoint_assignment": "https://trusthub.twilio.com/v1/TrustProducts/BUXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/ChannelEndpointAssignments"_19 },_19 "errors": null_19}
_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_10const accountSid = process.env.TWILIO_ACCOUNT_SID;_10const authToken = process.env.TWILIO_AUTH_TOKEN;_10const client = require('twilio')(accountSid, authToken);_10_10client.api.v2010.accounts_10 .list({limit: 20})_10 .then(accounts => accounts.forEach(a => console.log(a.sid)));
_45{_45 "first_page_uri": "/2010-04-01/Accounts.json?FriendlyName=friendly_name&Status=active&PageSize=50&Page=0",_45 "end": 0,_45 "previous_page_uri": "/2010-04-01/Accounts.json?FriendlyName=friendly_name&Status=active&PageSize=50&Page=0",_45 "accounts": [_45 {_45 "auth_token": "auth_token",_45 "date_created": "Thu, 30 Jul 2015 20:00:00 +0000",_45 "date_updated": "Thu, 30 Jul 2015 20:00:00 +0000",_45 "friendly_name": "friendly_name",_45 "owner_account_sid": "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_45 "sid": "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_45 "status": "active",_45 "subresource_uris": {_45 "available_phone_numbers": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/AvailablePhoneNumbers.json",_45 "calls": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Calls.json",_45 "conferences": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Conferences.json",_45 "incoming_phone_numbers": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/IncomingPhoneNumbers.json",_45 "notifications": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Notifications.json",_45 "outgoing_caller_ids": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/OutgoingCallerIds.json",_45 "recordings": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Recordings.json",_45 "transcriptions": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Transcriptions.json",_45 "addresses": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Addresses.json",_45 "signing_keys": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/SigningKeys.json",_45 "connect_apps": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/ConnectApps.json",_45 "sip": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/SIP.json",_45 "authorized_connect_apps": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/AuthorizedConnectApps.json",_45 "usage": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Usage.json",_45 "keys": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Keys.json",_45 "applications": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Applications.json",_45 "short_codes": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/SMS/ShortCodes.json",_45 "queues": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Queues.json",_45 "messages": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Messages.json",_45 "balance": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Balance.json"_45 },_45 "type": "Full",_45 "uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX.json"_45 }_45 ],_45 "uri": "/2010-04-01/Accounts.json?FriendlyName=friendly_name&Status=active&PageSize=50&Page=0",_45 "page_size": 50,_45 "start": 0,_45 "next_page_uri": "/2010-04-01/Accounts.json?FriendlyName=friendly_name&Status=active&PageSize=50&Page=50",_45 "page": 0_45}
_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_10const accountSid = process.env.TWILIO_ACCOUNT_SID;_10const authToken = process.env.TWILIO_AUTH_TOKEN;_10const client = require('twilio')(accountSid, authToken);_10_10client.trusthub.v1.customerProfiles_10 .list({limit: 20})_10 .then(customerProfiles => customerProfiles.forEach(c => console.log(c.sid)));
_36{_36 "results": [_36 {_36 "sid": "BUXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_36 "account_sid": "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_36 "policy_sid": "RNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_36 "friendly_name": "friendly_name",_36 "status": "twilio-approved",_36 "email": "email",_36 "status_callback": "http://www.example.com",_36 "valid_until": "2020-07-31T01:00:00Z",_36 "date_created": "2019-07-30T22:29:24Z",_36 "date_updated": "2019-07-31T01:09:00Z",_36 "url": "https://trusthub.twilio.com/v1/CustomerProfiles/BUXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_36 "links": {_36 "customer_profiles_entity_assignments": "https://trusthub.twilio.com/v1/CustomerProfiles/BUXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/EntityAssignments",_36 "customer_profiles_evaluations": "https://trusthub.twilio.com/v1/CustomerProfiles/BUXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Evaluations",_36 "customer_profiles_channel_endpoint_assignment": "https://trusthub.twilio.com/v1/CustomerProfiles/BUXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/ChannelEndpointAssignments"_36 },_36 "errors": [_36 {_36 "code": 18601_36 }_36 ]_36 }_36 ],_36 "meta": {_36 "page": 0,_36 "page_size": 50,_36 "first_page_url": "https://trusthub.twilio.com/v1/CustomerProfiles?Status=draft&FriendlyName=friendly_name&PolicySid=RNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX&PageSize=50&Page=0",_36 "previous_page_url": "https://trusthub.twilio.com/v1/CustomerProfiles?Status=draft&FriendlyName=friendly_name&PolicySid=RNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX&PageSize=50&Page=0",_36 "url": "https://trusthub.twilio.com/v1/CustomerProfiles?Status=draft&FriendlyName=friendly_name&PolicySid=RNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX&PageSize=50&Page=0",_36 "next_page_url": "https://trusthub.twilio.com/v1/CustomerProfiles?Status=draft&FriendlyName=friendly_name&PolicySid=RNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX&PageSize=50&Page=1",_36 "key": "results"_36 }_36}
Replace $TWILIO_ACCOUNT_SID in the URL with your Subaccount SID
_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_10const accountSid = process.env.TWILIO_ACCOUNT_SID;_10const authToken = process.env.TWILIO_AUTH_TOKEN;_10const client = require('twilio')(accountSid, authToken);_10_10client.incomingPhoneNumbers_10 .list({limit: 20})_10 .then(incomingPhoneNumbers => incomingPhoneNumbers.forEach(i => console.log(i.sid)));
_56{_56 "end": 0,_56 "first_page_uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/IncomingPhoneNumbers.json?FriendlyName=friendly_name&Beta=true&PhoneNumber=%2B19876543210&PageSize=50&Page=0",_56 "incoming_phone_numbers": [_56 {_56 "account_sid": "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_56 "address_requirements": "none",_56 "address_sid": "ADXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_56 "api_version": "2010-04-01",_56 "beta": null,_56 "capabilities": {_56 "voice": true,_56 "sms": false,_56 "mms": true,_56 "fax": false_56 },_56 "date_created": "Thu, 30 Jul 2015 23:19:04 +0000",_56 "date_updated": "Thu, 30 Jul 2015 23:19:04 +0000",_56 "emergency_status": "Active",_56 "emergency_address_sid": "ADXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_56 "emergency_address_status": "registered",_56 "friendly_name": "(808) 925-5327",_56 "identity_sid": "RIXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_56 "origin": "origin",_56 "phone_number": "+18089255327",_56 "sid": "PNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_56 "sms_application_sid": "",_56 "sms_fallback_method": "POST",_56 "sms_fallback_url": "",_56 "sms_method": "POST",_56 "sms_url": "",_56 "status_callback": "",_56 "status_callback_method": "POST",_56 "trunk_sid": null,_56 "uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/IncomingPhoneNumbers/PNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX.json",_56 "voice_application_sid": "",_56 "voice_caller_id_lookup": false,_56 "voice_fallback_method": "POST",_56 "voice_fallback_url": null,_56 "voice_method": "POST",_56 "voice_url": null,_56 "bundle_sid": "BUXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_56 "voice_receive_mode": "voice",_56 "status": "in-use",_56 "subresource_uris": {_56 "assigned_add_ons": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/IncomingPhoneNumbers/PNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/AssignedAddOns.json"_56 }_56 }_56 ],_56 "next_page_uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/IncomingPhoneNumbers.json?FriendlyName=friendly_name&Beta=true&PhoneNumber=%2B19876543210&PageSize=50&Page=50",_56 "page": 0,_56 "page_size": 50,_56 "previous_page_uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/IncomingPhoneNumbers.json?FriendlyName=friendly_name&Beta=true&PhoneNumber=%2B19876543210&PageSize=50&Page=0",_56 "start": 0,_56 "uri": "/2010-04-01/Accounts/ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/IncomingPhoneNumbers.json?FriendlyName=friendly_name&Beta=true&PhoneNumber=%2B19876543210&PageSize=50&Page=0"_56}
_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_10const accountSid = process.env.TWILIO_ACCOUNT_SID;_10const authToken = process.env.TWILIO_AUTH_TOKEN;_10const client = require('twilio')(accountSid, authToken);_10_10client.trusthub.v1.trustProducts_10 .list({limit: 20})_10 .then(trustProducts => trustProducts.forEach(t => console.log(t.sid)));
_32{_32 "results": [_32 {_32 "sid": "BUXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_32 "account_sid": "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_32 "policy_sid": "RNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_32 "friendly_name": "friendly_name",_32 "status": "twilio-approved",_32 "email": "email",_32 "status_callback": "http://www.example.com",_32 "valid_until": "2020-07-31T01:00:00Z",_32 "date_created": "2019-07-30T22:29:24Z",_32 "date_updated": "2019-07-31T01:09:00Z",_32 "url": "https://trusthub.twilio.com/v1/TrustProducts/BUXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_32 "links": {_32 "trust_products_entity_assignments": "https://trusthub.twilio.com/v1/TrustProducts/BUXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/EntityAssignments",_32 "trust_products_evaluations": "https://trusthub.twilio.com/v1/TrustProducts/BUXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/Evaluations",_32 "trust_products_channel_endpoint_assignment": "https://trusthub.twilio.com/v1/TrustProducts/BUXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/ChannelEndpointAssignments"_32 },_32 "errors": null_32 }_32 ],_32 "meta": {_32 "page": 0,_32 "page_size": 50,_32 "first_page_url": "https://trusthub.twilio.com/v1/TrustProducts?Status=draft&FriendlyName=friendly_name&PolicySid=RNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX&PageSize=50&Page=0",_32 "previous_page_url": "https://trusthub.twilio.com/v1/TrustProducts?Status=draft&FriendlyName=friendly_name&PolicySid=RNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX&PageSize=50&Page=0",_32 "url": "https://trusthub.twilio.com/v1/TrustProducts?Status=draft&FriendlyName=friendly_name&PolicySid=RNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX&PageSize=50&Page=0",_32 "next_page_url": "https://trusthub.twilio.com/v1/TrustProducts?Status=draft&FriendlyName=friendly_name&PolicySid=RNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX&PageSize=50&Page=1",_32 "key": "results"_32 }_32}
_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_11const accountSid = process.env.TWILIO_ACCOUNT_SID;_11const authToken = process.env.TWILIO_AUTH_TOKEN;_11const client = require('twilio')(accountSid, authToken);_11_11client.trusthub.v1.customerProfiles('YOUR_BUSINESS_PROFILE_SID')_11 .customerProfilesChannelEndpointAssignment_11 .list({limit: 20})_11 .then(customerProfilesChannelEndpointAssignment => customerProfilesChannelEndpointAssignment.forEach(c => console.log(c.sid)));
_22{_22 "results": [_22 {_22 "sid": "RAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_22 "customer_profile_sid": "BUXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_22 "account_sid": "ACXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_22 "channel_endpoint_sid": "PNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",_22 "channel_endpoint_type": "phone-number",_22 "date_created": "2019-07-31T02:34:41Z",_22 "url": "https://trusthub.twilio.com/v1/CustomerProfiles/BUXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/ChannelEndpointAssignments/RAXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"_22 }_22 ],_22 "meta": {_22 "page": 0,_22 "page_size": 50,_22 "first_page_url": "https://trusthub.twilio.com/v1/CustomerProfiles/BUXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/ChannelEndpointAssignments?ChannelEndpointSid=PNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX&PageSize=50&Page=0",_22 "previous_page_url": "https://trusthub.twilio.com/v1/CustomerProfiles/BUXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/ChannelEndpointAssignments?ChannelEndpointSid=PNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX&PageSize=50&Page=0",_22 "url": "https://trusthub.twilio.com/v1/CustomerProfiles/BUXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/ChannelEndpointAssignments?ChannelEndpointSid=PNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX&PageSize=50&Page=0",_22 "next_page_url": "https://trusthub.twilio.com/v1/CustomerProfiles/BUXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX/ChannelEndpointAssignments?ChannelEndpointSid=PNXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX&PageSize=50&Page=1",_22 "key": "results"_22 }_22}