Skip to content

Instantly share code, notes, and snippets.

@mstyne
Created May 14, 2015 13:13
Show Gist options
  • Save mstyne/8b983d20cb811b2932e4 to your computer and use it in GitHub Desktop.
Save mstyne/8b983d20cb811b2932e4 to your computer and use it in GitHub Desktop.
support.ticket_submit_outgoing Example
<?php
require_once dirname(__FILE__) .'/class.uber_api_client.php';
$client = new uber_api_client('http://your.ubersmith.com/','api','password');
try {
$result = $client->call('support.ticket_submit_outgoing',array(
'client_id' => 1,
'body' => 'Test',
'subject' => 'Test',
'recipient' => 'john.user@example.com',
'attach' => array(
'@/path/to/file/test.txt'
)
));
print_r($result);
} catch (Exception $e) {
print 'Error: '. $e->getMessage() .' ('. $e->getCode() .')';
}
// end of script
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment