NAME
Twilio::Rest::Chat::V2::Service::Channel::Invite - The Invite resource
SYNOPSIS
my $client = Twilio::Rest::Client->new($account_sid, $auth_token);
my $invite = $client->chat->v2->services($service_sid)->channels($channel_sid)->invites->create($identity, \%options);
for my $invite ($client->chat->v2->services($service_sid)->channels($channel_sid)->invites->read({}, 20)) {
...
}
my $invite = $client->chat->v2->services($service_sid)->channels($channel_sid)->invites($sid)->fetch;
$client->chat->v2->services($service_sid)->channels($channel_sid)->invites($sid)->delete;
DESCRIPTION
Pending invitations to users to become channel members
This file holds InviteList, InvitePage, InviteContext and InviteInstance. Methods that make a request throw Twilio::Exceptions::RestException on an error response.
InviteList
Returned by $client->chat->v2->services($service_sid)->channels($channel_sid)->invites. See also Twilio::ListResource.
create
my $invite = $client->chat->v2->services($service_sid)->channels($channel_sid)->invites->create($identity, \%options);
Returns a InviteInstance.
The required values are:
$identity-
The
identityvalue that uniquely identifies the new resource's User within the Service. See access tokens for more info.
The options are:
role_sid-
The SID of the Role assigned to the new member.
read
my @records = $client->chat->v2->services($service_sid)->channels($channel_sid)->invites->read(\%options, $limit, $page_size);
Returns the records as a list, fetching as many pages as it needs.
The options are:
identity-
The User's
identityvalue of the resources to read. See access tokens for more details. An array reference.
stream
my $stream = $client->chat->v2->services($service_sid)->channels($channel_sid)->invites->stream(\%options, $limit, $page_size);
Takes the same arguments as "read", and returns a Twilio::Stream.
page
my $page = $client->chat->v2->services($service_sid)->channels($channel_sid)->invites->page(\%options, $page_size, $page_token, $page_number);
Fetches one page, and returns a Twilio::Page.
get_page
my $page = $client->chat->v2->services($service_sid)->channels($channel_sid)->invites->get_page($url);
Fetches the page at a URL given by Twilio.
get_context
my $context = $client->chat->v2->services($service_sid)->channels($channel_sid)->invites->get_context($sid);
Returns a InviteContext, and makes no request.
InvitePage
A Twilio::Page of InviteInstance objects.
records_key
build_instance
Used by Twilio::Page.
InviteContext
Returned by $client->chat->v2->services($service_sid)->channels($channel_sid)->invites($sid). It makes no request until one of these methods is called.
fetch
my $invite = $client->chat->v2->services($service_sid)->channels($channel_sid)->invites($sid)->fetch;
Returns a InviteInstance.
delete
$client->chat->v2->services($service_sid)->channels($channel_sid)->invites($sid)->delete;
Returns true.
InviteInstance
See also Twilio::InstanceResource.
It has fetch and delete, which work as they do on the context.
Its fields are:
- account_sid
-
The SID of the Account that created the Invite resource.
- channel_sid
-
The SID of the Channel the Invite resource belongs to.
- created_by
-
The
identityof the User that created the invite. - date_created
-
The date and time in GMT when the resource was created specified in ISO 8601 format. A Time::Piece object in UTC. See "date_time" in Twilio::Deserialize.
- date_updated
-
The date and time in GMT when the resource was last updated specified in ISO 8601 format. A Time::Piece object in UTC. See "date_time" in Twilio::Deserialize.
- identity
-
The application-defined string that uniquely identifies the resource's User within the Service. See access tokens for more info.
- role_sid
-
The SID of the Role assigned to the resource.
- service_sid
-
The SID of the Service the Invite resource is associated with.
- sid
-
The unique string that we created to identify the Invite resource.
- url
-
The absolute URL of the Invite resource.
CONSTRUCTORS
new
Objects here come from the methods above, so there is no need to call new directly.
LICENSE
Copyright (c) 2026 Francisco Zarabozo. Released under the MIT License.