NAME

Twilio::Rest::Proxy::V1::Service::Session::Participant::MessageInteraction - The MessageInteraction resource

SYNOPSIS

my $client = Twilio::Rest::Client->new($account_sid, $auth_token);

my $message_interaction = $client->proxy->v1->services($service_sid)->sessions($session_sid)->participants($participant_sid)->message_interactions->create(\%options);
for my $message_interaction ($client->proxy->v1->services($service_sid)->sessions($session_sid)->participants($participant_sid)->message_interactions->read({}, 20)) {
  ...
}
my $message_interaction = $client->proxy->v1->services($service_sid)->sessions($session_sid)->participants($participant_sid)->message_interactions($sid)->fetch;

DESCRIPTION

This file holds MessageInteractionList, MessageInteractionPage, MessageInteractionContext and MessageInteractionInstance. Methods that make a request throw Twilio::Exceptions::RestException on an error response.

MessageInteractionList

Returned by $client->proxy->v1->services($service_sid)->sessions($session_sid)->participants($participant_sid)->message_interactions. See also Twilio::ListResource.

create

my $message_interaction = $client->proxy->v1->services($service_sid)->sessions($session_sid)->participants($participant_sid)->message_interactions->create(\%options);

Create a new message Interaction to send directly from your system to one Participant. The inbound properties for the Interaction will always be empty. Returns a MessageInteractionInstance.

The options are:

body

The message to send to the participant

media_url

Reserved. Not currently supported. An array reference.

read

my @records = $client->proxy->v1->services($service_sid)->sessions($session_sid)->participants($participant_sid)->message_interactions->read(\%options, $limit, $page_size);

Returns the records as a list, fetching as many pages as it needs.

stream

my $stream = $client->proxy->v1->services($service_sid)->sessions($session_sid)->participants($participant_sid)->message_interactions->stream(\%options, $limit, $page_size);

Takes the same arguments as "read", and returns a Twilio::Stream.

page

my $page = $client->proxy->v1->services($service_sid)->sessions($session_sid)->participants($participant_sid)->message_interactions->page(\%options, $page_size, $page_token, $page_number);

Fetches one page, and returns a Twilio::Page.

get_page

my $page = $client->proxy->v1->services($service_sid)->sessions($session_sid)->participants($participant_sid)->message_interactions->get_page($url);

Fetches the page at a URL given by Twilio.

get_context

my $context = $client->proxy->v1->services($service_sid)->sessions($session_sid)->participants($participant_sid)->message_interactions->get_context($sid);

Returns a MessageInteractionContext, and makes no request.

MessageInteractionPage

A Twilio::Page of MessageInteractionInstance objects.

records_key

build_instance

Used by Twilio::Page.

MessageInteractionContext

Returned by $client->proxy->v1->services($service_sid)->sessions($session_sid)->participants($participant_sid)->message_interactions($sid). It makes no request until one of these methods is called.

fetch

my $message_interaction = $client->proxy->v1->services($service_sid)->sessions($session_sid)->participants($participant_sid)->message_interactions($sid)->fetch;

Returns a MessageInteractionInstance.

MessageInteractionInstance

See also Twilio::InstanceResource.

It has fetch, which work as they do on the context.

Its fields are:

account_sid

The SID of the Account that created the MessageInteraction resource.

data

A JSON string that includes the message body sent to the participant. (e.g. {"body": "hello"})

date_created

The ISO 8601 date and time in GMT when the resource was created. A Time::Piece object in UTC. See "date_time" in Twilio::Deserialize.

date_updated

The ISO 8601 date and time in GMT when the resource was last updated. A Time::Piece object in UTC. See "date_time" in Twilio::Deserialize.

inbound_participant_sid

Always empty for created Message Interactions.

inbound_resource_sid

Always empty for created Message Interactions.

inbound_resource_status

One of accepted, answered, busy, canceled, completed, deleted, delivered, delivery-unknown, failed, in-progress, initiated, no-answer, queued, received, receiving, ringing, scheduled, sending, sent, undelivered or unknown.

inbound_resource_type

Always empty for created Message Interactions.

inbound_resource_url

Always empty for created Message Interactions.

outbound_participant_sid

The SID of the outbound Participant resource.

outbound_resource_sid

The SID of the outbound Message resource.

outbound_resource_status

One of accepted, answered, busy, canceled, completed, deleted, delivered, delivery-unknown, failed, in-progress, initiated, no-answer, queued, received, receiving, ringing, scheduled, sending, sent, undelivered or unknown.

outbound_resource_type

The outbound resource type. This value is always Message.

outbound_resource_url

The URL of the Twilio message resource.

participant_sid

The SID of the Participant resource.

service_sid

The SID of the parent Service resource.

session_sid

The SID of the parent Session resource.

sid

The unique string that we created to identify the MessageInteraction resource.

type

One of message, voice or unknown.

url

The absolute URL of the MessageInteraction 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.