Getting Started with Tickets

SoftLayer's ticket system is a primary communication medium for customers to interact with the SoftLayer support groups. The SoftLayer_Ticket service provides an interaction point for individual tickets, and all tickets on an account can be interfaced through SoftLayer_Account.


A list of all tickets can be gathered from the SoftLayer_Account service with SoftLayer_Account::getTickets. This method returns an array of SoftLayer_Ticket data type objects.

import SoftLayer
client = SoftLayer.Client()
tickets = client['Account'].getTickets()

Additionally, you can retrieve only open or closed tickets with SoftLayer_Account::getOpenTickets and SoftLayer_Account::getClosedTickets.


To get information about a specific ticket, such as its ID, last modified date, or status, we can use SoftLayer_Ticket::getObject that returns a SoftLayer_Ticket object. Object masks can be used to include SoftLayer_Ticket’s relational properties. Below is an example of using getObject on the SoftLayer_Ticket service with an object mask that provides the name of the assigned user and all the ticket updates.

mask = ('mask[id, title, assignedUser[firstName, lastName],'
return client[‘Ticket’].getObject(id=ticket_id, mask=mask)


Listing Subjects

When creating a ticket, a valid subject ID is needed. A list of all possible subjects is gathered with SoftLayer_Ticket_Subject::getAllObjects:

subjects = client['Ticket_Subject'].getAllObjects()
1001 'Accounting Request'
1002 'Sales Request'
1003 'Reboots and Console Access'
1041 'DNS Request'
1021 'Hardware Issue'
1022 'Public Network Question'
1061 'Private Network Question'
1201 'DOS/Abuse Issue'
1101 'Security Issue'
1121 'Hardware Firewall Question'
1122 'Hardware Load Balancer Question'
1004 'OS Reload Question'
1005 'Portal Information Question'
1081 'Licensing Question'
1141 'Mail Server Issue'
1161 'StorageLayer Question'
1181 'CDNLayer Question'
1221 'Transcoding Question'
1261 'Colocation Service Request'

Ticket Submission

Creating a new ticket is accomplished with the SoftLayer_Ticket::createStandardTicket method. First, a SoftLayer_Ticket template object is created that contains the details of the ticket. Every ticket template object will need, at minimum, the following properties defined:
• subjectId: the ID of the subject to be used as title for the ticket
• assignedUserId: An assigned user for the ticket, which is usually set to the ticket creator.
SoftLayer_Ticket::createStandardTicket can be called with the template object and the content for the first ticket message.

import SoftLayer
client = SoftLayer.Client()
currentUser = client[‘Account’].getCurrentUser()
new_ticket = {
       'subjectId': ID,
       'assignedUserId': currentUser['id']
created_ticket = client[‘Ticket’].createStandardTicket(new_ticket, “This is the content of the ticket xxxx”)


An update to a ticket can be made with SoftLayer_Ticket::addUpdate. A template object must be provided:

ticket_update = {
                 'entry': "This is a test update, please ignore",
tickets = client['Ticket'].addUpdate(ticket_update, id=8988302)