Invite Resource
The Twilio Conversations API is now Generally Available! We recommend using Conversations to build your chat application to get access to additional channels and even more functionality.
Invite properties
Each Invite resource contains these properties.
Resource Properties in REST API format | |
---|---|
sid
|
The unique string that we created to identify the Invite resource. |
account_sid
|
The SID of the Account that created the Invite resource. |
channel_sid
|
The SID of the Channel the Invite resource belongs to. |
service_sid
|
The SID of the Service the Invite resource is associated with. |
identity
|
The application-defined string that uniquely identifies the resource's User within the Service. See access tokens for more info. |
date_created
|
The date and time in GMT when the resource was created specified in ISO 8601 format. |
date_updated
|
The date and time in GMT when the resource was last updated specified in ISO 8601 format. |
role_sid
|
The SID of the Role assigned to the resource. |
created_by
|
The |
url
|
The absolute URL of the Invite resource. |
Create an Invite resource
https://chat.twilio.com/v2/Services/{ServiceSid}/Channels/{ChannelSid}/Invites
The {ChannelSid}
value can be the Channel's sid
or its unique_name
.
Parameters
Parameters in REST API format | |
---|---|
service_sid
Path
|
The SID of the Service to create the Invite resource under. |
channel_sid
Path
|
The SID of the Channel the new Invite resource belongs to. This value can be the Channel resource's |
identity
Required
|
The |
role_sid
Optional
|
The SID of the Role assigned to the new member. |
Example 1
Fetch an Invite resource
https://chat.twilio.com/v2/Services/{ServiceSid}/Channels/{ChannelSid}/Invites/{Sid}
The {ChannelSid}
value can be the Channel's sid
or its unique_name
.
Parameters
Parameters in REST API format | |
---|---|
service_sid
Path
|
The SID of the Service to fetch the Invite resource from. |
channel_sid
Path
|
The SID of the Channel the Invite resource to fetch belongs to. This value can be the Channel resource's |
sid
Path
|
The SID of the Invite resource to fetch. |
Example 1
Read multiple Invite resources
https://chat.twilio.com/v2/Services/{ServiceSid}/Channels/{ChannelSid}/Invites
The {ChannelSid}
value can be the Channel's sid
or its unique_name
.
Parameters
Parameters in REST API format | |
---|---|
service_sid
Path
|
The SID of the Service to read the Invite resources from. |
channel_sid
Path
|
The SID of the Channel the Invite resources to read belong to. This value can be the Channel resource's |
identity
Optional
|
The User's |
Example 1
Delete an Invite resource
https://chat.twilio.com/v2/Services/{ServiceSid}/Channels/{ChannelSid}/Invites/{Sid}
The {ChannelSid}
value can be the Channel's sid
or its unique_name
.
Parameters
Parameters in REST API format | |
---|---|
service_sid
Path
|
The SID of the Service to delete the Invite resource from. |
channel_sid
Path
|
The SID of the Channel the Invite resource to delete belongs to. This value can be the Channel resource's |
sid
Path
|
The SID of the Invite resource to delete. |
Example 1
Need some help?
We all do sometimes; code is hard. Get help now from our support team, or lean on the wisdom of the crowd browsing the Twilio tag on Stack Overflow.