SupportingDocument Resource
The unique string created by Twilio to identify the Supporting Document resource.
^RD[0-9a-fA-F]{32}$Min length: 34Max length: 34The SID of the Account that created the Document resource.
^AC[0-9a-fA-F]{32}$Min length: 34Max length: 34The verification status of the Supporting Document resource.
DRAFTPENDING_REVIEWREJECTEDAPPROVEDEXPIREDPROVISIONALLY_APPROVEDThe set of parameters that are the attributes of the Supporting Documents resource which are listed in the Supporting Document Types.
The date and time in GMT when the resource was created specified in ISO 8601 format.
The date and time in GMT when the resource was last updated specified in ISO 8601 format.
The absolute URL of the Supporting Document resource.
POST https://trusthub.twilio.com/v1/SupportingDocuments
application/x-www-form-urlencodedThe set of parameters that are the attributes of the Supporting Documents resource which are derived Supporting Document Types.
1// Download the helper library from https://www.twilio.com/docs/node/install2const twilio = require("twilio"); // Or, for ESM: import twilio from "twilio";34// Find your Account SID and Auth Token at twilio.com/console5// and set the environment variables. See http://twil.io/secure6const accountSid = process.env.TWILIO_ACCOUNT_SID;7const authToken = process.env.TWILIO_AUTH_TOKEN;8const client = twilio(accountSid, authToken);910async function createSupportingDocument() {11const supportingDocument =12await client.trusthub.v1.supportingDocuments.create({13friendlyName: "FriendlyName",14type: "Type",15});1617console.log(supportingDocument.sid);18}1920createSupportingDocument();
Response
1{2"status": "DRAFT",3"date_updated": "2021-02-11T17:23:00Z",4"friendly_name": "FriendlyName",5"account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",6"url": "https://trusthub.twilio.com/v1/SupportingDocuments/RDaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",7"date_created": "2021-02-11T17:23:00Z",8"sid": "RDaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",9"attributes": {10"address_sids": "ADaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"11},12"type": "Type",13"mime_type": null14}
GET https://trusthub.twilio.com/v1/SupportingDocuments/{Sid}
The unique string created by Twilio to identify the Supporting Document resource.
^RD[0-9a-fA-F]{32}$Min length: 34Max length: 341// Download the helper library from https://www.twilio.com/docs/node/install2const twilio = require("twilio"); // Or, for ESM: import twilio from "twilio";34// Find your Account SID and Auth Token at twilio.com/console5// and set the environment variables. See http://twil.io/secure6const accountSid = process.env.TWILIO_ACCOUNT_SID;7const authToken = process.env.TWILIO_AUTH_TOKEN;8const client = twilio(accountSid, authToken);910async function fetchSupportingDocument() {11const supportingDocument = await client.trusthub.v112.supportingDocuments("RDaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")13.fetch();1415console.log(supportingDocument.sid);16}1718fetchSupportingDocument();
Response
1{2"status": "DRAFT",3"date_updated": "2021-02-11T17:23:00Z",4"friendly_name": "Business-profile-physical-address",5"account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",6"url": "https://trusthub.twilio.com/v1/SupportingDocuments/RDaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",7"date_created": "2021-02-11T17:23:00Z",8"sid": "RDaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",9"attributes": {10"address_sids": "ADaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"11},12"type": "customer_profile_address",13"mime_type": null14}
GET https://trusthub.twilio.com/v1/SupportingDocuments
How many resources to return in each list page. The default is 50, and the maximum is 1000.
1Maximum: 1000The page token. This is provided by the API.
1// Download the helper library from https://www.twilio.com/docs/node/install2const twilio = require("twilio"); // Or, for ESM: import twilio from "twilio";34// Find your Account SID and Auth Token at twilio.com/console5// and set the environment variables. See http://twil.io/secure6const accountSid = process.env.TWILIO_ACCOUNT_SID;7const authToken = process.env.TWILIO_AUTH_TOKEN;8const client = twilio(accountSid, authToken);910async function listSupportingDocument() {11const supportingDocuments = await client.trusthub.v1.supportingDocuments.list(12{ limit: 20 }13);1415supportingDocuments.forEach((s) => console.log(s.sid));16}1718listSupportingDocument();
Response
1{2"results": [],3"meta": {4"page": 0,5"page_size": 50,6"first_page_url": "https://trusthub.twilio.com/v1/SupportingDocuments?PageSize=50&Page=0",7"previous_page_url": null,8"url": "https://trusthub.twilio.com/v1/SupportingDocuments?PageSize=50&Page=0",9"next_page_url": null,10"key": "results"11}12}
POST https://trusthub.twilio.com/v1/SupportingDocuments/{Sid}
The unique string created by Twilio to identify the Supporting Document resource.
^RD[0-9a-fA-F]{32}$Min length: 34Max length: 34application/x-www-form-urlencodedThe set of parameters that are the attributes of the Supporting Document resource which are derived Supporting Document Types.
1// Download the helper library from https://www.twilio.com/docs/node/install2const twilio = require("twilio"); // Or, for ESM: import twilio from "twilio";34// Find your Account SID and Auth Token at twilio.com/console5// and set the environment variables. See http://twil.io/secure6const accountSid = process.env.TWILIO_ACCOUNT_SID;7const authToken = process.env.TWILIO_AUTH_TOKEN;8const client = twilio(accountSid, authToken);910async function updateSupportingDocument() {11const supportingDocument = await client.trusthub.v112.supportingDocuments("RDaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")13.update({ friendlyName: "FriendlyName" });1415console.log(supportingDocument.sid);16}1718updateSupportingDocument();
Response
1{2"status": "DRAFT",3"date_updated": "2021-02-11T17:23:00Z",4"friendly_name": "FriendlyName",5"account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",6"url": "https://trusthub.twilio.com/v1/SupportingDocuments/RDaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",7"date_created": "2021-02-11T17:23:00Z",8"sid": "RDaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",9"attributes": {10"address_sids": "ADaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"11},12"type": "customer_profile_address",13"mime_type": null14}
DELETE https://trusthub.twilio.com/v1/SupportingDocuments/{Sid}
The unique string created by Twilio to identify the Supporting Document resource.
^RD[0-9a-fA-F]{32}$Min length: 34Max length: 341// Download the helper library from https://www.twilio.com/docs/node/install2const twilio = require("twilio"); // Or, for ESM: import twilio from "twilio";34// Find your Account SID and Auth Token at twilio.com/console5// and set the environment variables. See http://twil.io/secure6const accountSid = process.env.TWILIO_ACCOUNT_SID;7const authToken = process.env.TWILIO_AUTH_TOKEN;8const client = twilio(accountSid, authToken);910async function deleteSupportingDocument() {11await client.trusthub.v112.supportingDocuments("RDaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")13.remove();14}1516deleteSupportingDocument();