new DocumentPermissionList(version, serviceSid, documentSid)
Initialize the DocumentPermissionList
Parameters:
Name | Type | Description |
---|---|---|
version |
Twilio.Sync.V1 | Version of the resource |
serviceSid |
string | The SID of the Sync Service that the resource is associated with |
documentSid |
string | The Sync Document SID |
Methods
each(optsopt, callbackopt)
Streams DocumentPermissionInstance records from the API.
This operation lazily loads records as efficiently as possible until the limit
is reached.
The results are passed into the callback function, so this operation is memory
efficient.
If a function is passed as the first argument, it will be used as the callback
function.
Parameters:
Name | Type | Attributes | Description | ||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
opts |
object |
<optional> |
Options for request
Properties
|
||||||||||||||||||||
callback |
function |
<optional> |
Function to process each record |
get(identity) → {Twilio.Sync.V1.ServiceContext.DocumentContext.DocumentPermissionContext}
Constructs a document_permission
Parameters:
Name | Type | Description |
---|---|---|
identity |
string | The application-defined string that uniquely identifies the User's Document Permission resource to fetch |
Returns:
getPage(targetUrlopt, callbackopt) → {Promise}
Retrieve a single target page of DocumentPermissionInstance records from the
API.
The request is executed immediately.
If a function is passed as the first argument, it will be used as the callback
function.
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
targetUrl |
string |
<optional> |
API-generated URL for the requested results page |
callback |
function |
<optional> |
Callback to handle list of records |
Returns:
Resolves to a list of records
- Type
- Promise
list(optsopt, callbackopt) → {Promise}
Lists DocumentPermissionInstance records from the API as a list.
If a function is passed as the first argument, it will be used as the callback
function.
Parameters:
Name | Type | Attributes | Description | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
opts |
object |
<optional> |
Options for request
Properties
|
||||||||||||
callback |
function |
<optional> |
Callback to handle list of records |
Returns:
Resolves to a list of records
- Type
- Promise
page(optsopt, callbackopt) → {Promise}
Retrieve a single page of DocumentPermissionInstance records from the API.
The request is executed immediately.
If a function is passed as the first argument, it will be used as the callback
function.
Parameters:
Name | Type | Attributes | Description | ||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
opts |
object |
<optional> |
Options for request
Properties
|
||||||||||||||||
callback |
function |
<optional> |
Callback to handle list of records |
Returns:
Resolves to a list of records
- Type
- Promise
toJSON()
Provide a user-friendly representation
Returns:
Object