API::Zendesk
Manage Zendesk connection, get tickets etc. This is a work-in-progress - we have only written the access methods we have used so far, but as you can see, it is a good template to extend for all remaining API endpoints. I'm totally open for any pull requests! :)
This module uses MooseX::Log::Log4perl for logging - be sure to initialize!
Optional.
Provided by MooseX::WithX - optionally pass a Cache::FileCache object to cache and avoid unnecessary requests
Required.
Optional. Default: 10
Time in seconds to back off before retrying request if a http 429 (Too Many Requests) response is received.
Optional. Default: https://elasticsearch.zendesk.com/api/v2
Optional. A new LWP::UserAgent will be created for you if you don't already have one you'd like to reuse.
Create the user agent and credentials. As these are built lazily, initialising manually can avoid errors thrown when building them later being silently swallowed in try/catch blocks.
Access the Incremental Ticket Export interface
!! Broken !!
Access the Search interface
Parameters
Required. Query string
Optional. Default: "updated_at"
Optional. Default: "desc"
Optional. Integer indicating the number of entries to return. The number returned may be slightly larger (paginating will stop when this number is exceeded).
Returns array of results.
Access the List Comments interface
Required. The ticket id to query on.
Returns an array of comments
Download an attachment.
Required. An attachment HashRef as returned as part of a comment.
Directory to download to
Force overwrite if item already exists
Returns path to the downloaded file
Shortcut to Updating Tickets specifically for adding a response.
Required. Ticket to add response to
Optional. Default: 0 (not public). Set to "1" for public response
Required. The text to be addded to the ticket as response.
Returns response HashRef
Access Updating Tickets interface.
Required. HashRef of valid parameters - see link above for details.
Access Getting Tickets interface.
Required. Ticket to get
Disable cache get/set for this operation
Returns ticket HashRef
Get a single organization by accessing Getting Organizations interface with a single organization_id. The get_many_organizations interface detailed below is more efficient for getting many organizations at once.
Required. Organization id to get
Returns organization HashRef
Required. ArrayRef of organization ids to get
Returns an array of organization HashRefs
Use the Update Organization interface.
Required. HashRef of the details to be updated.
Disable cache set for this operation
returns the
Use the List Users interface.
Required. Organization id to get users from
Disable cache set/get for this operation
Returns array of users
Copyright 2015, Robin Clarke
Robin Clarke <robin@robinclarke.net>
Jeremy Falling
To install API::Zendesk, copy and paste the appropriate command in to your terminal.
cpanm
cpanm API::Zendesk
CPAN shell
perl -MCPAN -e shell install API::Zendesk
For more information on module installation, please visit the detailed CPAN module installation guide.