The SID of the Account that created the Policy resource.
^AC[0-9a-fA-F]{32}$
Min length: 34
Max length: 34
The SID of the User that created the Policy resource.
^US[0-9a-fA-F]{32}$
Min length: 34
Max length: 34
The date and time in GMT when the Policy was created specified in ISO 8601 format.
GET https://assistants.twilio.com/v1/Policies
How many resources to return in each list page. The default is 50, and the maximum is 1000.
1
Maximum: 1000
The 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 listPolicies() {11const policies = await client.assistants.v1.policies.list({ limit: 20 });1213policies.forEach((p) => console.log(p.id));14}1516listPolicies();
1{2"meta": {3"first_page_url": "https://www.example.com",4"key": "key",5"next_page_url": "https://www.example.com",6"page": 42,7"page_size": 42,8"previous_page_url": "https://www.example.com",9"url": "https://www.example.com"10},11"policies": [12{13"id": "aia_plcy",14"name": "name",15"description": "description",16"account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",17"user_sid": "USaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",18"type": "type",19"policy_details": {},20"date_created": "2009-07-06T20:30:00Z",21"date_updated": "2009-07-06T20:30:00Z"22}23]24}