solution = array('resourceType' => $resourceType, ); $this->uri = '/Exports/' . rawurlencode($resourceType) . '/Configuration'; } /** * Fetch a ExportConfigurationInstance * * @return ExportConfigurationInstance Fetched ExportConfigurationInstance */ public function fetch() { $params = Values::of(array()); $payload = $this->version->fetch( 'GET', $this->uri, $params ); return new ExportConfigurationInstance($this->version, $payload, $this->solution['resourceType']); } /** * Update the ExportConfigurationInstance * * @param array|Options $options Optional Arguments * @return ExportConfigurationInstance Updated ExportConfigurationInstance */ public function update($options = array()) { $options = new Values($options); $data = Values::of(array( 'Enabled' => Serialize::booleanToString($options['enabled']), 'WebhookUrl' => $options['webhookUrl'], 'WebhookMethod' => $options['webhookMethod'], )); $payload = $this->version->update( 'POST', $this->uri, array(), $data ); return new ExportConfigurationInstance($this->version, $payload, $this->solution['resourceType']); } /** * Provide a friendly representation * * @return string Machine friendly representation */ public function __toString() { $context = array(); foreach ($this->solution as $key => $value) { $context[] = "$key=$value"; } return '[Twilio.Preview.BulkExports.ExportConfigurationContext ' . implode(' ', $context) . ']'; } }