Skip to content

Commit

Permalink
[Librarian] Regenerated @ 5627c63bd23f159fdbe112bf727f87b79c3d4f74
Browse files Browse the repository at this point in the history
  • Loading branch information
twilio-dx committed Jul 13, 2023
1 parent 58f09a9 commit 0dea0be
Show file tree
Hide file tree
Showing 18 changed files with 1,608 additions and 39 deletions.
22 changes: 22 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,28 @@
twilio-php Changelog
====================

[2023-07-13] Version 7.7.0
--------------------------
**Flex**
- Adding `interaction_context_sid` as optional parameter in Interactions API

**Messaging**
- Making visiblity public for tollfree_verification API

**Numbers**
- Remove Sms capability property from HNO creation under version `/v2` of HNO API. **(breaking change)**
- Update required properties in LOA creation under version `/v2` of Authorization document API. **(breaking change)**

**Taskrouter**
- Add api to fetch task queue statistics for multiple TaskQueues

**Verify**
- Add `RiskCheck` optional parameter on Verification creation.

**Twiml**
- Add Google Voices and languages


[2023-06-28] Version 7.6.0
--------------------------
**Lookups**
Expand Down
2 changes: 2 additions & 0 deletions src/Twilio/Rest/FlexApi/V1/InteractionInstance.php
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@
* @property array|null $routing
* @property string|null $url
* @property array|null $links
* @property string|null $interactionContextSid
*/
class InteractionInstance extends InstanceResource
{
Expand All @@ -53,6 +54,7 @@ public function __construct(Version $version, array $payload, string $sid = null
'routing' => Values::array_get($payload, 'routing'),
'url' => Values::array_get($payload, 'url'),
'links' => Values::array_get($payload, 'links'),
'interactionContextSid' => Values::array_get($payload, 'interaction_context_sid'),
];

$this->solution = ['sid' => $sid ?: $this->properties['sid'], ];
Expand Down
8 changes: 7 additions & 1 deletion src/Twilio/Rest/FlexApi/V1/InteractionList.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@

use Twilio\Exceptions\TwilioException;
use Twilio\ListResource;
use Twilio\Options;
use Twilio\Values;
use Twilio\Version;
use Twilio\Serialize;
Expand Down Expand Up @@ -47,17 +48,22 @@ public function __construct(
*
* @param array $channel The Interaction's channel.
* @param array $routing The Interaction's routing logic.
* @param array|Options $options Optional Arguments
* @return InteractionInstance Created InteractionInstance
* @throws TwilioException When an HTTP error occurs.
*/
public function create(array $channel, array $routing): InteractionInstance
public function create(array $channel, array $routing, array $options = []): InteractionInstance
{

$options = new Values($options);

$data = Values::of([
'Channel' =>
Serialize::jsonObject($channel),
'Routing' =>
Serialize::jsonObject($routing),
'InteractionContextSid' =>
$options['interactionContextSid'],
]);

$payload = $this->version->create('POST', $this->uri, [], $data);
Expand Down
78 changes: 78 additions & 0 deletions src/Twilio/Rest/FlexApi/V1/InteractionOptions.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
<?php
/**
* This code was generated by
* ___ _ _ _ _ _ _ ____ ____ ____ _ ____ ____ _ _ ____ ____ ____ ___ __ __
* | | | | | | | | | __ | | |__| | __ | __ |___ |\ | |___ |__/ |__| | | | |__/
* | |_|_| | |___ | |__| |__| | | | |__] |___ | \| |___ | \ | | | |__| | \
*
* Twilio - Flex
* This is the public Twilio REST API.
*
* NOTE: This class is auto generated by OpenAPI Generator.
* https://openapi-generator.tech
* Do not edit the class manually.
*/

namespace Twilio\Rest\FlexApi\V1;

use Twilio\Options;
use Twilio\Values;

abstract class InteractionOptions
{
/**
* @param string $interactionContextSid The Interaction context sid is used for adding a context lookup sid
* @return CreateInteractionOptions Options builder
*/
public static function create(

string $interactionContextSid = Values::NONE

): CreateInteractionOptions
{
return new CreateInteractionOptions(
$interactionContextSid
);
}


}

class CreateInteractionOptions extends Options
{
/**
* @param string $interactionContextSid The Interaction context sid is used for adding a context lookup sid
*/
public function __construct(

string $interactionContextSid = Values::NONE

) {
$this->options['interactionContextSid'] = $interactionContextSid;
}

/**
* The Interaction context sid is used for adding a context lookup sid
*
* @param string $interactionContextSid The Interaction context sid is used for adding a context lookup sid
* @return $this Fluent Builder
*/
public function setInteractionContextSid(string $interactionContextSid): self
{
$this->options['interactionContextSid'] = $interactionContextSid;
return $this;
}

/**
* Provide a friendly representation
*
* @return string Machine friendly representation
*/
public function __toString(): string
{
$options = \http_build_query(Values::of($this->options), '', ' ');
return '[Twilio.FlexApi.V1.CreateInteractionOptions ' . $options . ']';
}
}


12 changes: 12 additions & 0 deletions src/Twilio/Rest/Messaging/V1.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
use Twilio\Rest\Messaging\V1\LinkshorteningMessagingServiceList;
use Twilio\Rest\Messaging\V1\LinkshorteningMessagingServiceDomainAssociationList;
use Twilio\Rest\Messaging\V1\ServiceList;
use Twilio\Rest\Messaging\V1\TollfreeVerificationList;
use Twilio\Rest\Messaging\V1\UsecaseList;
use Twilio\Version;

Expand All @@ -40,10 +41,12 @@
* @property LinkshorteningMessagingServiceList $linkshorteningMessagingService
* @property LinkshorteningMessagingServiceDomainAssociationList $linkshorteningMessagingServiceDomainAssociation
* @property ServiceList $services
* @property TollfreeVerificationList $tollfreeVerifications
* @property UsecaseList $usecases
* @method \Twilio\Rest\Messaging\V1\BrandRegistrationContext brandRegistrations(string $sid)
* @method \Twilio\Rest\Messaging\V1\LinkshorteningMessagingServiceContext linkshorteningMessagingService(string $domainSid, string $messagingServiceSid)
* @method \Twilio\Rest\Messaging\V1\ServiceContext services(string $sid)
* @method \Twilio\Rest\Messaging\V1\TollfreeVerificationContext tollfreeVerifications(string $sid)
*/
class V1 extends Version
{
Expand All @@ -56,6 +59,7 @@ class V1 extends Version
protected $_linkshorteningMessagingService;
protected $_linkshorteningMessagingServiceDomainAssociation;
protected $_services;
protected $_tollfreeVerifications;
protected $_usecases;

/**
Expand Down Expand Up @@ -141,6 +145,14 @@ protected function getServices(): ServiceList
return $this->_services;
}

protected function getTollfreeVerifications(): TollfreeVerificationList
{
if (!$this->_tollfreeVerifications) {
$this->_tollfreeVerifications = new TollfreeVerificationList($this);
}
return $this->_tollfreeVerifications;
}

protected function getUsecases(): UsecaseList
{
if (!$this->_usecases) {
Expand Down
38 changes: 19 additions & 19 deletions src/Twilio/Rest/Messaging/V1/ServiceContext.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,29 +26,29 @@
use Twilio\Serialize;
use Twilio\Rest\Messaging\V1\Service\AlphaSenderList;
use Twilio\Rest\Messaging\V1\Service\PhoneNumberList;
use Twilio\Rest\Messaging\V1\Service\UsAppToPersonUsecaseList;
use Twilio\Rest\Messaging\V1\Service\ShortCodeList;
use Twilio\Rest\Messaging\V1\Service\UsAppToPersonList;
use Twilio\Rest\Messaging\V1\Service\UsAppToPersonUsecaseList;


/**
* @property AlphaSenderList $alphaSenders
* @property PhoneNumberList $phoneNumbers
* @property UsAppToPersonUsecaseList $usAppToPersonUsecases
* @property ShortCodeList $shortCodes
* @property UsAppToPersonList $usAppToPerson
* @property UsAppToPersonUsecaseList $usAppToPersonUsecases
* @method \Twilio\Rest\Messaging\V1\Service\AlphaSenderContext alphaSenders(string $sid)
* @method \Twilio\Rest\Messaging\V1\Service\ShortCodeContext shortCodes(string $sid)
* @method \Twilio\Rest\Messaging\V1\Service\UsAppToPersonContext usAppToPerson(string $sid)
* @method \Twilio\Rest\Messaging\V1\Service\PhoneNumberContext phoneNumbers(string $sid)
* @method \Twilio\Rest\Messaging\V1\Service\AlphaSenderContext alphaSenders(string $sid)
*/
class ServiceContext extends InstanceContext
{
protected $_alphaSenders;
protected $_phoneNumbers;
protected $_usAppToPersonUsecases;
protected $_shortCodes;
protected $_usAppToPerson;
protected $_usAppToPersonUsecases;

/**
* Initialize the ServiceContext
Expand Down Expand Up @@ -192,48 +192,48 @@ protected function getPhoneNumbers(): PhoneNumberList
}

/**
* Access the shortCodes
* Access the usAppToPersonUsecases
*/
protected function getShortCodes(): ShortCodeList
protected function getUsAppToPersonUsecases(): UsAppToPersonUsecaseList
{
if (!$this->_shortCodes) {
$this->_shortCodes = new ShortCodeList(
if (!$this->_usAppToPersonUsecases) {
$this->_usAppToPersonUsecases = new UsAppToPersonUsecaseList(
$this->version,
$this->solution['sid']
);
}

return $this->_shortCodes;
return $this->_usAppToPersonUsecases;
}

/**
* Access the usAppToPerson
* Access the shortCodes
*/
protected function getUsAppToPerson(): UsAppToPersonList
protected function getShortCodes(): ShortCodeList
{
if (!$this->_usAppToPerson) {
$this->_usAppToPerson = new UsAppToPersonList(
if (!$this->_shortCodes) {
$this->_shortCodes = new ShortCodeList(
$this->version,
$this->solution['sid']
);
}

return $this->_usAppToPerson;
return $this->_shortCodes;
}

/**
* Access the usAppToPersonUsecases
* Access the usAppToPerson
*/
protected function getUsAppToPersonUsecases(): UsAppToPersonUsecaseList
protected function getUsAppToPerson(): UsAppToPersonList
{
if (!$this->_usAppToPersonUsecases) {
$this->_usAppToPersonUsecases = new UsAppToPersonUsecaseList(
if (!$this->_usAppToPerson) {
$this->_usAppToPerson = new UsAppToPersonList(
$this->version,
$this->solution['sid']
);
}

return $this->_usAppToPersonUsecases;
return $this->_usAppToPerson;
}

/**
Expand Down
20 changes: 10 additions & 10 deletions src/Twilio/Rest/Messaging/V1/ServiceInstance.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,9 @@
use Twilio\Deserialize;
use Twilio\Rest\Messaging\V1\Service\AlphaSenderList;
use Twilio\Rest\Messaging\V1\Service\PhoneNumberList;
use Twilio\Rest\Messaging\V1\Service\UsAppToPersonUsecaseList;
use Twilio\Rest\Messaging\V1\Service\ShortCodeList;
use Twilio\Rest\Messaging\V1\Service\UsAppToPersonList;
use Twilio\Rest\Messaging\V1\Service\UsAppToPersonUsecaseList;


/**
Expand Down Expand Up @@ -59,9 +59,9 @@ class ServiceInstance extends InstanceResource
{
protected $_alphaSenders;
protected $_phoneNumbers;
protected $_usAppToPersonUsecases;
protected $_shortCodes;
protected $_usAppToPerson;
protected $_usAppToPersonUsecases;

/**
* Initialize the ServiceInstance
Expand Down Expand Up @@ -175,6 +175,14 @@ protected function getPhoneNumbers(): PhoneNumberList
return $this->proxy()->phoneNumbers;
}

/**
* Access the usAppToPersonUsecases
*/
protected function getUsAppToPersonUsecases(): UsAppToPersonUsecaseList
{
return $this->proxy()->usAppToPersonUsecases;
}

/**
* Access the shortCodes
*/
Expand All @@ -191,14 +199,6 @@ protected function getUsAppToPerson(): UsAppToPersonList
return $this->proxy()->usAppToPerson;
}

/**
* Access the usAppToPersonUsecases
*/
protected function getUsAppToPersonUsecases(): UsAppToPersonUsecaseList
{
return $this->proxy()->usAppToPersonUsecases;
}

/**
* Magic getter to access properties
*
Expand Down
Loading

0 comments on commit 0dea0be

Please sign in to comment.