Using the ExecuteCommand API
You can use the commands described here to access functionality for a variety of entities within Autotask including Tickets, Companies, Contacts, Opportunities, Assets, and Tasks.
IMPORTANT An Autotask login is required. The logged in user's security level access permissions apply.
Each command combines the following elements:
- The URL to the appropriate Autotask database
https://ww#.autotask.net/Autotask/
Replace # with the number of your Autotask zone.
- The command information which specifies the desired action and the target entity
For example, AutotaskExtend/ExecuteCommand.aspx?Code=NewTicket
- The parameter that identifies the item the command will act on
For example, &AccountID=[AccountID]
Together, these elements create a path to access the specified item.
NOTE The example above uses a New Ticket by Account ID command. When you use an ExecuteCommand, the command, entity, and parameter vary depending on what you want to do.
Important things to know
For all ExecuteCommands, the following considerations apply:
- When processing and comparing phone number input data, the ExecuteCommand strips all non-numeric characters from the data. For example, 413-444-4444 is processed as 4134444444.
- When processing and comparing phone number input data, the ExecuteCommand searches on the leading numeric characters, allowing partial searches, for example, by area code or area code and exchange.
NOTE When retrieving information by phone, if you have a large number of companies the response may take a few seconds.
- For best results, you must use your company's Autotask zone number in the URL in the ExecuteCommand; that is, in the code provided, replace the # in ww# with the zone number that appears in your Autotask URL.
If multiple items match the parameter you pass in with the ExecuteCommand, a list of all matching items opens in a separate window. For example, if you user OpenCompanyDetail by PhoneNumber, and you pass in only an area code, the list displays all companies in your database that have phone numbers with that area code.
Click the correct item in the list to open the requested Autotask page.
IMPORTANT Use your Autotask zone in the ExecuteCommand URLs.
For all URLs provided as examples in this topic, replace the "#" in "ww#" with the zone number that appears in your Autotask URL. For example, if you access Autotask at ww3.autotask.net, use ww3 in your ExecuteCommands.
The ExecuteCommands must utilize the entity and parameter names found in the Autotask database. Sometimes the database terms differ from the terms that appear in the user interface.
EXAMPLE For example, to access Company data, the commands use Account instead of Company, as in AccountID. Commands that access Asset data use the term InstalledProduct.
How to...
- Begin each ExecuteCommand with the following base URL information:
https://ww#.autotask.net/Autotask/AutotaskExtend/ExecuteCommand.aspx?Code=
NOTE Remember to replace "#" in "ww#" with your Autotask zone number.
- Append one of the command and parameter combinations described in this topic to the end of the base URL.
https://ww1.autotask.net/Autotask/AutotaskExtend/ExecuteCommand.aspx?Code=NewTicket&AccountName=[Company name]
- Replace the bracketed text with data from Autotask.
https://ww1.autotask.net/Autotask/AutotaskExtend/ExecuteCommand.aspx?Code=NewTicket&AccountName=Midco
IMPORTANT Do not leave any spaces. The ExecuteCommand must be a continuous string, regardless of whether or not a line break appears in the examples presented here.
Add this command and parameter to the base URL:
OpenAccount&Phone=[Phone Number]
To create this command:
https://ww3.autotask.net/Autotask/AutotaskExtend/ExecuteCommand.aspx?Code=OpenAccount&Phone=[PhoneNumber]
Replace the bracketed text with a company or contact phone number to open the Company Detail page for the company associated with the phone number.
https://ww3.autotask.net/Autotask/AutotaskExtend/ExecuteCommand.aspx?Code=OpenAccount&Phone=518-446-3333
NOTE Remember to replace "#" in "ww#" with your Autotask zone number.
- Log into the Autotask database that you want your command to access.
- Be sure to replace the # in the base URL of your execute command with the zone number for this database.
- In an external document, create a hyperlink using the execute command as the destination URL.
- Click the hyperlink to open the page specified in the ExecuteCommand.
If you activate an execute command without being logged into an Autotask database, the log in page will open.
The commands
Autotask currently provides the execute commands described below.
Ticket commands
Use the Ticket commands to create new tickets for a specific account or open the detail page for an existing ticket.
The NewTicket commands can open a New Ticket page in a new window in Autotask and populate the Company Name and related fields with data from the Company associated with the parameters you pass in.
Use this command with a company or contact phone number to open the New Ticket window and populate the Company Name field with the name of the company associated with the phone number.
NewTicket&Phone=[Phone Number]
NOTE You can use this command to integrate with a phone system that uses caller ID, using the number of an incoming call to populate the PhoneNumber parameter.
NOTE PhoneNumber = the number found in one of the following Autotask Company Detail fields: Phone, Alternate Phone 1, or Alternate Phone 2; or in one of the following Contact Detail fields: Phone, Alternate Phone, or Mobile Phone. For an exact match, the phone number must include 10 digits representing the area code, exchange, and number.
Use this command with a company's unique identifier (AccountID) to open the New Ticket window and populate the Company Name and related fields.
NewTicket&AccountID=[Company ID]
The automatically assigned Company ID is unique to each company in your database. It appears on the Company Detail page.
Use a company's name with this command to open the New Ticket window and populate the Company Name and related fields.
NewTicket& AccountName=[Company Name]
Company name is the name of the company for which you want to create a new ticket. For an exact match, the company name that you pass in must be identical to the name that appears in the Company Name field in Autotask.
Use a Global Task ID with this command to open the New Ticket window and populate the Company Name and related fields.
NewTicket&GlobalTaskId=[GlobalTaskId]
The Global Task Id is used with the Outsource module to identify tickets with a ticket number and insource number.
Use an Asset (that is, Configuration Item) ID to open the New Ticket window and populate the Asset Name field. If the asset is associated with an Account, the following fields will be populated when the data is available: Account, Contact, Serial Number, Reference Number, Reference Name, Contract, and Contract Service/Bundle.
NewTicket&InstalledProductID=[InstalledProductID]
You can use the NewTicket command with both the InstalledProductID and AccountID parameters at once. The order of the parameters does not matter.
NewTicket&InstalledProductID=[InstalledProductID]&AcountID=[Account ID]
IMPORTANT If you submit both the InstalledProductID and AccountID parameters in the same command, and the Asset ID is assigned to a Asset associated with an Account whose Account ID does not match the submitted Account ID, the command will return an error.
The OpenTicketDetail command opens the ticket Detail page for the ticket associated with the parameter you pass in, for example, the TicketID.
Use a ticket's ID number with this command to open the ticket's Detail page.
OpenTicketDetail&TicketID=[Ticket ID]
The ticket ID is not the same as the ticket number. The ticket ID does not display in the Autotask interface.
NOTE You can use this command to add a link to open a ticket detail from an email notification generated by an application that uses a Ticket ID.
Use a ticket number with this command to open the ticket detail page for that ticket.
OpenTicketDetail&TicketNumber=[Ticket Number]
NOTE You can use this command to add a link that will open a ticket detail from an email notification.
The command must contain a valid Autotask ticket number. The ticket number is the number that identifies a ticket in the Autotask interface.
Use a Global Task ID with this command to open the ticket detail for the associated ticket. The global task ID is used with tickets received from Outsource partners through the Outsource module.
OpenTicketDetail&GlobalTaskID=[Global Task ID]
Company commands
Use the Company commands to add a new company, or pass in parameters to access the company detail page or open the Edit Company window for the company associated with those parameters.
The NewAccount command opens an empty New Company window, allowing the user to complete the form and add a new Company.
NewAccount
No parameters are provided and no Company information is populated in the New Company window.
The OpenAccount command opens the company detail for the company associated with the parameters you pass in. The detail page opens in a new window.
Use the company's phone number with this command to open the company's detail page.
OpenAccount&Phone=[PhoneNumber]
NOTE You can integrate this command with a phone system with caller ID, using the number of an incoming call to populate the PhoneNumber parameter. All phone number considerations described above apply.
NOTE PhoneNumber = the number found in one of the following Autotask Company Detail fields: Phone, Alternate Phone 1, or Alternate Phone 2; or in one of the following Contact Detail fields: Phone, Alternate Phone, or Mobile Phone. For an exact match, the phone number must include 10 digits representing the area code, exchange, and number.
Use a company's ID number (AccountID) with this command to open the Detail page for that company.
OpenAccount&AccountID=[the Company ID]
NOTE The company ID appears on the company detail page, and can be selected from the column chooser to display in company search result grids.
Use a company's name with this command to open the Detail page for that company.
OpenAccount&AccountName=[the Company Name]
The URL command must contain a valid Autotask Company Name. For an exact match you must use the name that appears in the Company Name field in Autotask.
The EditAccount command opens the Edit Company page for the company associated with the parameters you pass in.
Use a company's phone number with this command to open the Edit Company page for that company.
NOTE You can integrate this command with a phone system with caller ID, using the number of an incoming call to populate the PhoneNumber parameter. All phone number considerations described above apply.
EditAccount&Phone=[Phone Number]
NOTE PhoneNumber = the number found in one of the following Autotask Company Detail fields: Phone, Alternate Phone 1, or Alternate Phone 2; or in one of the following Contact Detail fields: Phone, Alternate Phone, or Mobile Phone. For an exact match, the phone number must include 10 digits representing the area code, exchange, and number.
Use a company's ID number (AccountID) with this command to open the Edit Company page for that company.
EditAccount&AccountID=[Company ID]
The company ID appears on the company detail page, and can be selected from the column chooser to display in company search result grids.
Company Note command
Use the CompanyNote execute command to add a new CRM Note associated with a specific company.
Use an Account ID number to open a New Account Note for the specified company.
Use a company's ID number (AccountID) with this command to open a New Account Note page and populate the Company Name and Company Phone fields with information from the company associated with the ID. The" Assigned to" field is populated with the name of the logged in resource.
NewAccountNote&AccountID=[Company ID number]
The company ID appears on the company detail page, and can be selected from the column chooser to display in company search result grids.
Contact commands
Use the Contact execute commands to add new contacts to companies, and open the Contact Detail or Edit Contact pages for existing contacts.
The NewContact command opens a New Contact page in Autotask. The page is pre-populated with information from the company associated with the parameters you pass in.
Use a company or company contact's phone number with this command to open a New Contact window populated with the Company Name field populated with the name of the company associated with the phone number.
NOTE This command can be integrated with a phone system with caller ID, using the number of an incoming call to populate the PhoneNumber parameter. All phone number considerations described above apply.
NewContact&Phone=[PhoneNumber]
NOTE PhoneNumber = the number found in one of the following Autotask Company Detail fields: Phone, Alternate Phone 1, or Alternate Phone 2; or in one of the following Contact Detail fields: Phone, Alternate Phone, or Mobile Phone. For an exact match, the phone number must include 10 digits representing the area code, exchange, and number.
Use a company's ID number (AccountID) with this command to open a New Contact page and populate the Company Name field with the name of the company associated with the ID.
NewContact&AccountID=[Company ID number]
The company ID appears on the company detail page, and can be selected from the column chooser to display in company search result grids.
The EditContact command opens the Edit Contact page for the contact associated with the parameters you pass in.
Use a contact's ID number with this command to open an Edit Contact page for the Contact.
EditContact&ContactID=[ContactID]
The Contact ID must be a valid Autotask Contact ID.
With this command, use an email address associated with a company or contact to open the Edit Contact page for a contact associated with the email or with the company associated with the email.
EditContact&Email=[email]
Email must equal the email address listed for an Autotask contact or company. If multiple matches are found, a window opens containing a list of all matching contacts. Click the correct contact to open the contact's Detail page.
Use a contact's first or last name with this command to open an Edit page that contact.
Append one of the following to the base URL information:
EditContact&FirstName=[Contact's first name]
EditContact&LastName=[Contact's last name]
If multiple matches are found, a window opens containing a list of all matching contacts. Click the correct contact to open the contact's Detail page.
The OpenContact command opens the Contact Detail page for the contact associated with the parameters you pass in.
Use a contact's email address with this command to open the contact's Detail page.
OpenContact&Email=[email]
Email must equal the email address listed for an Autotask contact. If multiple matches are found, a window opens containing a list of all matching contacts. Click the correct contact to open the contact's Detail page.
Use a contact's ID with this command to open the contact's Detail page.
OpenContact&ContactID=[ContactID]
The Contact ID must be a valid Autotask Contact ID.
Asset (Configuration Item) commands
Use the following Company commands to add a new asset, or pass in parameters to access the Edit Asset page for the asset associated with the parameters you pass in.
Use the NewInstalledProduct command to add a Asset to the company associated with the parameters that you pass in.
Use a company or contact's phone number with this command to open a New Asset page and populate the Company Name field with the name of the Company associated with the phone number. If you use a contact phone number, the contact's company populates the field.
This command can be integrated with a phone system with caller ID, using the number of an incoming call to populate the PhoneNumber parameter.
NewInstalledProduct&Phone=[PhoneNumber]
NOTE PhoneNumber = the number found in one of the following Autotask Company Detail fields: Phone, Alternate Phone 1, or Alternate Phone 2; or in one of the following Contact Detail fields: Phone, Alternate Phone, or Mobile Phone. For an exact match, the phone number must include 10 digits representing the area code, exchange, and number.
Use a company's ID number with this command to open a New Asset window and populate the Company Name field with the associated company's name.
NewInstalledProduct&AccountID=[Company AccountID number]
The company ID appears on the company detail page, and can be selected from the column chooser to display in company search result grids.
Use the EditInstalledProduct command to open the Edit Asset window for the asset associated with the ID that you pass in.
Use an asset's ID number (InstalledProductID) with this command to open the asset's Edit page.
EditInstalledProduct&InstalledProductID=[Asset ID number]
The Asset ID number must be a valid ID number for an existing Asset in Autotask.
Time Entry commands
Use the following Time Entry or Work Entry commands to open a new ticket time entry window, or to edit an existing work entry.
The Edit Work Entry command respects all Autotask security level and proxy time entry permissions.
Use this command with a Ticket ID to open a New Ticket Time page with selected fields populated with data from the ticket.
OpenTicketTime&TicketID=[Ticket ID number]
Ticket ID is not the same as the Ticket number that appears on the Ticket detail and in Ticket search results.
Use this command to open a ticket or task time entry edit page. All security level and proxy time entry permissions are respected.
EditTimeEntry&WorkEntryID=[Work Entry ID number]
Additional Open commands
The following Open commands open detail information for the entity described by the specific command and parameters you pass in.
NOTE The Appointment ID is not exposed through the Autotask UI. This command is designed to be used by the Web services API or other code based application.
Use a calendar appointment's ID number with this command to open the appointment detail.
OpenAppointment&AppointmentID=[Appointment ID number]
Use a contract's ID number with this command to open the contract's Summary page.
OpenContract&ContractID=[Contract ID number]
Use the name of an Autotask Device Discovery Extension with this command to open the launch page for the Asset Discovery Wizard for the specified extension. Note that this command does not include Open before IPDW.
IPDW&wizard=[Extension name]
Use this command with a Knowledgebase article ID to open the article.
OpenKBArticle&ID=[Knowledgebase article ID number]
Use an Opportunity ID with this command to open the opportunity's Detail page.
OpenOpportunity&OpportunityID=[OpportunityID]
Use a Project ID with this command to open the project's summary page.
OpenProject&ProjectID=[Project ID number]
Use a Sales Order ID with this command to open the sales order's Detail page.
OpenSalesOrder&SalesOrderID=[Sales Order ID number]
Use a Service Call ID with this command to open the detail page for the service call.
OpenServiceCall&ServiceCallID=[ServiceCallID]
Use a Task ID with this command to open the task's detail page.
OpenTaskDetail&TaskID=[Task ID number]
Use both a ResourceID and ApproverID with this command to open the Time Off Request page for the request associated with both IDs. Optionally, you can add the Tier number to indicate which approver level tier to search.
NOTE Unless the optional Tier parameter is provided, the command will return only Tier 1 approvers.
If there are multiple time off requests with the same Resource ID and Approver ID (and optionally, tier), a list of all matching items is displayed. Click an item from the list to open the time off request.
Note that this command does not include Open before TimeOffRequest.
TimeOffRequest&ResourceID=[Resource ID number]&ApproverID=[Approver ID number]
Optionally, append the following parameter after the approver ID number: &Tier=[Approver Tier #]
Use a To-Do ID with this command to open the Edit page for the To-Do.
OpenToDo&ToDoID=[To-Do ID number]
Using the ExecuteCommand with third party applications
Many popular software packages, including Salesforce.com and Microsoft CRM, provide tools, similar to Autotask LiveLinks, that allow developers to add custom buttons and links that open external applications from within the software interface. You can use the Autotask ExecuteCommand API with these custom buttons and links to access functionality in Autotask.
For example, you could add custom buttons to the Company Management area of your customer resource management package. One button could use an " OpenCompany " ExecuteCommand to open the Company Detail for an Autotask Company. Another could use the "CreateNewTicket" ExecuteCommand to open a New Autotask Ticket form. Users can then compare company information or add a new ticket for a company without leaving the original application.
NOTE If the user is not already logged into Autotask, the Autotask login page opens. After the user logs in, the requested page opens.
The directions for adding these custom buttons and links will vary by application and by application version. Most applications will provide the application specific directions through a help system, manual, or an online developers' network or community. The degree of technical skills required will vary by application. For information on the customization options offered by your current third-party software packages, contact the software provider.