1 /**
2 * Copyright 2016-2024 IBM Corp.
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with
5 * the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0
6 *
7 * Unless required by applicable law or agreed to in writing, software distributed under the License is distributed
8 * on an "AS IS" BASIS,WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
9 * See the License for the specific language governing permissions and limitations under the License.
10 */
11 12 // AUTOMATICALLY GENERATED CODE - DO NOT MODIFY
13 14 package services
15 16 import (
17 "fmt"
18 "strings"
19 20 "github.com/softlayer/softlayer-go/datatypes"
21 "github.com/softlayer/softlayer-go/session"
22 "github.com/softlayer/softlayer-go/sl"
23 )
24 25 // The SoftLayer_Ticket data type models a single SoftLayer customer support or notification ticket. Each ticket object contains references to it's updates, the user it's assigned to, the SoftLayer department and employee that it's assigned to, and any hardware objects or attached files associated with the ticket. Tickets are described in further detail on the [[SoftLayer_Ticket]] service page.
26 //
27 // To create a support ticket execute the [[SoftLayer_Ticket::createStandardTicket|createStandardTicket]] or [[SoftLayer_Ticket::createAdministrativeTicket|createAdministrativeTicket]] methods in the SoftLayer_Ticket service. To create an upgrade ticket for the SoftLayer sales group execute the [[SoftLayer_Ticket::createUpgradeTicket|createUpgradeTicket]].
28 type Ticket struct {
29 Session session.SLSession
30 Options sl.Options
31 }
32 33 // GetTicketService returns an instance of the Ticket SoftLayer service
34 func GetTicketService(sess session.SLSession) Ticket {
35 return Ticket{Session: sess}
36 }
37 38 func (r Ticket) Id(id int) Ticket {
39 r.Options.Id = &id
40 return r
41 }
42 43 func (r Ticket) Mask(mask string) Ticket {
44 if !strings.HasPrefix(mask, "mask[") && (strings.Contains(mask, "[") || strings.Contains(mask, ",")) {
45 mask = fmt.Sprintf("mask[%s]", mask)
46 }
47 48 r.Options.Mask = mask
49 return r
50 }
51 52 func (r Ticket) Filter(filter string) Ticket {
53 r.Options.Filter = filter
54 return r
55 }
56 57 func (r Ticket) Limit(limit int) Ticket {
58 r.Options.Limit = &limit
59 return r
60 }
61 62 func (r Ticket) Offset(offset int) Ticket {
63 r.Options.Offset = &offset
64 return r
65 }
66 67 func (r Ticket) AddAssignedAgent(agentId *int) (err error) {
68 var resp datatypes.Void
69 params := []interface{}{
70 agentId,
71 }
72 err = r.Session.DoRequest("SoftLayer_Ticket", "addAssignedAgent", params, &r.Options, &resp)
73 return
74 }
75 76 // Creates new additional emails for assigned user if new emails are provided. Attaches any newly created additional emails to ticket.
77 func (r Ticket) AddAttachedAdditionalEmails(emails []string) (resp bool, err error) {
78 params := []interface{}{
79 emails,
80 }
81 err = r.Session.DoRequest("SoftLayer_Ticket", "addAttachedAdditionalEmails", params, &r.Options, &resp)
82 return
83 }
84 85 // Attach the given Dedicated Host to a SoftLayer ticket. An attachment provides an easy way for SoftLayer's employees to quickly look up your records in the case of specific issues.
86 func (r Ticket) AddAttachedDedicatedHost(dedicatedHostId *int) (resp datatypes.Ticket_Attachment_Dedicated_Host, err error) {
87 params := []interface{}{
88 dedicatedHostId,
89 }
90 err = r.Session.DoRequest("SoftLayer_Ticket", "addAttachedDedicatedHost", params, &r.Options, &resp)
91 return
92 }
93 94 // Attach the given file to a SoftLayer ticket. A file attachment is a convenient way to submit non-textual error reports to SoftLayer employees in a ticket. File attachments to tickets must have a unique name.
95 func (r Ticket) AddAttachedFile(fileAttachment *datatypes.Container_Utility_File_Attachment) (resp datatypes.Ticket_Attachment_File, err error) {
96 params := []interface{}{
97 fileAttachment,
98 }
99 err = r.Session.DoRequest("SoftLayer_Ticket", "addAttachedFile", params, &r.Options, &resp)
100 return
101 }
102 103 // Attach the given hardware to a SoftLayer ticket. A hardware attachment provides an easy way for SoftLayer's employees to quickly look up your hardware records in the case of hardware-specific issues.
104 func (r Ticket) AddAttachedHardware(hardwareId *int) (resp datatypes.Ticket_Attachment_Hardware, err error) {
105 params := []interface{}{
106 hardwareId,
107 }
108 err = r.Session.DoRequest("SoftLayer_Ticket", "addAttachedHardware", params, &r.Options, &resp)
109 return
110 }
111 112 // Attach the given CloudLayer Computing Instance to a SoftLayer ticket. An attachment provides an easy way for SoftLayer's employees to quickly look up your records in the case of specific issues.
113 func (r Ticket) AddAttachedVirtualGuest(guestId *int, callCommit *bool) (resp datatypes.Ticket_Attachment_Virtual_Guest, err error) {
114 params := []interface{}{
115 guestId,
116 callCommit,
117 }
118 err = r.Session.DoRequest("SoftLayer_Ticket", "addAttachedVirtualGuest", params, &r.Options, &resp)
119 return
120 }
121 122 // As part of the customer service process SoftLayer has provided a quick feedback mechanism for its customers to rate their overall experience with SoftLayer after a ticket is closed. addFinalComments() sets these comments for a ticket update made by a SoftLayer employee. Final comments may only be set on closed tickets, can only be set once, and may not exceed 4000 characters in length. Once the comments are set ”addFinalComments()” returns a boolean true.
123 func (r Ticket) AddFinalComments(finalComments *string) (resp bool, err error) {
124 params := []interface{}{
125 finalComments,
126 }
127 err = r.Session.DoRequest("SoftLayer_Ticket", "addFinalComments", params, &r.Options, &resp)
128 return
129 }
130 131 // no documentation yet
132 func (r Ticket) AddScheduledAlert(activationTime *string) (err error) {
133 var resp datatypes.Void
134 params := []interface{}{
135 activationTime,
136 }
137 err = r.Session.DoRequest("SoftLayer_Ticket", "addScheduledAlert", params, &r.Options, &resp)
138 return
139 }
140 141 // no documentation yet
142 func (r Ticket) AddScheduledAutoClose(activationTime *string) (err error) {
143 var resp datatypes.Void
144 params := []interface{}{
145 activationTime,
146 }
147 err = r.Session.DoRequest("SoftLayer_Ticket", "addScheduledAutoClose", params, &r.Options, &resp)
148 return
149 }
150 151 // Add an update to a ticket. A ticket update's entry has a maximum length of 4000 characters, so ”addUpdate()” splits the ”entry” property in the ”templateObject” parameter into 3900 character blocks and creates one entry per 3900 character block. Once complete ”addUpdate()” emails the ticket's owner and additional email addresses with an update message if the ticket's ”notifyUserOnUpdateFlag” is set. If the ticket is a Legal or Abuse ticket, then the account's abuse emails are also notified when the updates are processed. Finally, ”addUpdate()” returns an array of the newly created ticket updates.
152 func (r Ticket) AddUpdate(templateObject *datatypes.Ticket_Update, attachedFiles []datatypes.Container_Utility_File_Attachment) (resp []datatypes.Ticket_Update, err error) {
153 params := []interface{}{
154 templateObject,
155 attachedFiles,
156 }
157 err = r.Session.DoRequest("SoftLayer_Ticket", "addUpdate", params, &r.Options, &resp)
158 return
159 }
160 161 // Create an administrative support ticket. Use an administrative ticket if you require SoftLayer's assistance managing your server or content. If you are experiencing an issue with SoftLayer's hardware, network, or services then please open a standard support ticket.
162 //
163 // Support tickets may only be created in the open state. The SoftLayer API defaults new ticket properties ”userEditableFlag” to true, ”accountId” to the id of the account that your API user belongs to, and ”statusId” to 1001 (or "open"). You may not assign your new to ticket to users that your API user does not have access to.
164 //
165 // Once your ticket is created it is placed in a queue for SoftLayer employees to work. As they update the ticket new [[SoftLayer_Ticket_Update]] entries are added to the ticket object.
166 //
167 // Administrative support tickets add a one-time $3USD charge to your account.
168 func (r Ticket) CreateAdministrativeTicket(templateObject *datatypes.Ticket, contents *string, attachmentId *int, rootPassword *string, controlPanelPassword *string, accessPort *string, attachedFiles []datatypes.Container_Utility_File_Attachment, attachmentType *string) (resp datatypes.Ticket, err error) {
169 params := []interface{}{
170 templateObject,
171 contents,
172 attachmentId,
173 rootPassword,
174 controlPanelPassword,
175 accessPort,
176 attachedFiles,
177 attachmentType,
178 }
179 err = r.Session.DoRequest("SoftLayer_Ticket", "createAdministrativeTicket", params, &r.Options, &resp)
180 return
181 }
182 183 // A cancel server request creates a ticket to cancel the resource on next bill date. The hardware ID parameter is required to determine which server is to be cancelled. NOTE: Hourly bare metal servers will be cancelled on next bill date.
184 //
185 // The reason parameter could be from the list below:
186 // * "No longer needed"
187 // * "Business closing down"
188 // * "Server / Upgrade Costs"
189 // * "Migrating to larger server"
190 // * "Migrating to smaller server"
191 // * "Migrating to a different SoftLayer datacenter"
192 // * "Network performance / latency"
193 // * "Support response / timing"
194 // * "Sales process / upgrades"
195 // * "Moving to competitor"
196 //
197 // The content parameter describes further the reason for cancelling the server.
198 func (r Ticket) CreateCancelServerTicket(attachmentId *int, reason *string, content *string, cancelAssociatedItems *bool, attachmentType *string) (resp datatypes.Ticket, err error) {
199 params := []interface{}{
200 attachmentId,
201 reason,
202 content,
203 cancelAssociatedItems,
204 attachmentType,
205 }
206 err = r.Session.DoRequest("SoftLayer_Ticket", "createCancelServerTicket", params, &r.Options, &resp)
207 return
208 }
209 210 // A cancel service request creates a sales ticket. The hardware ID parameter is required to determine which server is to be cancelled.
211 //
212 // The reason parameter could be from the list below:
213 // * "No longer needed"
214 // * "Business closing down"
215 // * "Server / Upgrade Costs"
216 // * "Migrating to larger server"
217 // * "Migrating to smaller server"
218 // * "Migrating to a different SoftLayer datacenter"
219 // * "Network performance / latency"
220 // * "Support response / timing"
221 // * "Sales process / upgrades"
222 // * "Moving to competitor"
223 //
224 // The content parameter describes further the reason for cancelling service.
225 func (r Ticket) CreateCancelServiceTicket(attachmentId *int, reason *string, content *string, attachmentType *string) (resp datatypes.Ticket, err error) {
226 params := []interface{}{
227 attachmentId,
228 reason,
229 content,
230 attachmentType,
231 }
232 err = r.Session.DoRequest("SoftLayer_Ticket", "createCancelServiceTicket", params, &r.Options, &resp)
233 return
234 }
235 236 // Create a standard support ticket. Use a standard support ticket if you need to work out a problem related to SoftLayer's hardware, network, or services. If you require SoftLayer's assistance managing your server or content then please open an administrative ticket.
237 //
238 // Support tickets may only be created in the open state. The SoftLayer API defaults new ticket properties ”userEditableFlag” to true, ”accountId” to the id of the account that your API user belongs to, and ”statusId” to 1001 (or "open"). You may not assign your new to ticket to users that your API user does not have access to.
239 //
240 // Once your ticket is created it is placed in a queue for SoftLayer employees to work. As they update the ticket new [[SoftLayer_Ticket_Update]] entries are added to the ticket object.
241 func (r Ticket) CreateStandardTicket(templateObject *datatypes.Ticket, contents *string, attachmentId *int, rootPassword *string, controlPanelPassword *string, accessPort *string, attachedFiles []datatypes.Container_Utility_File_Attachment, attachmentType *string) (resp datatypes.Ticket, err error) {
242 params := []interface{}{
243 templateObject,
244 contents,
245 attachmentId,
246 rootPassword,
247 controlPanelPassword,
248 accessPort,
249 attachedFiles,
250 attachmentType,
251 }
252 err = r.Session.DoRequest("SoftLayer_Ticket", "createStandardTicket", params, &r.Options, &resp)
253 return
254 }
255 256 // Create a ticket for the SoftLayer sales team to perform a hardware or service upgrade. Our sales team will work with you on upgrade feasibility and pricing and then send the upgrade ticket to the proper department to perform the actual upgrade. Service affecting upgrades, such as server hardware or CloudLayer Computing Instance upgrades that require the server powered down must have a two hour maintenance specified for our datacenter engineers to perform your upgrade. Account level upgrades, such as adding PPTP VPN users, CDNLayer accounts, and monitoring services are processed much faster and do not require a maintenance window.
257 func (r Ticket) CreateUpgradeTicket(attachmentId *int, genericUpgrade *string, upgradeMaintenanceWindow *string, details *string, attachmentType *string, title *string) (resp datatypes.Ticket, err error) {
258 params := []interface{}{
259 attachmentId,
260 genericUpgrade,
261 upgradeMaintenanceWindow,
262 details,
263 attachmentType,
264 title,
265 }
266 err = r.Session.DoRequest("SoftLayer_Ticket", "createUpgradeTicket", params, &r.Options, &resp)
267 return
268 }
269 270 // Edit a SoftLayer ticket. The edit method is two-fold. You may either edit a ticket itself, add an update to a ticket, attach up to two files to a ticket, or perform all of these tasks. The SoftLayer API ignores changes made to the ”userEditableFlag” and ”accountId” properties. You may not assign a ticket to a user that your API account does not have access to. You may not enter a custom title for standard support tickets, buy may do so when editing an administrative ticket. Finally, you may not close a ticket using this method. Please contact SoftLayer if you need a ticket closed.
271 //
272 // If you need to only add an update to a ticket then please use the [[SoftLayer_Ticket::addUpdate|addUpdate]] method in this service. Likewise if you need to only attach a file to a ticket then use the [[SoftLayer_Ticket::addAttachedFile|addAttachedFile]] method. The edit method exists as a convenience if you need to perform all these tasks at once.
273 func (r Ticket) Edit(templateObject *datatypes.Ticket, contents *string, attachedFiles []datatypes.Container_Utility_File_Attachment) (resp datatypes.Ticket, err error) {
274 params := []interface{}{
275 templateObject,
276 contents,
277 attachedFiles,
278 }
279 err = r.Session.DoRequest("SoftLayer_Ticket", "edit", params, &r.Options, &resp)
280 return
281 }
282 283 // Retrieve The SoftLayer customer account associated with a ticket.
284 func (r Ticket) GetAccount() (resp datatypes.Account, err error) {
285 err = r.Session.DoRequest("SoftLayer_Ticket", "getAccount", nil, &r.Options, &resp)
286 return
287 }
288 289 // getAllTicketGroups() retrieves a list of all groups that a ticket may be assigned to. Ticket groups represent the internal department at SoftLayer who a ticket is assigned to.
290 //
291 // Every SoftLayer ticket has groupId and ticketGroup properties that correspond to one of the groups returned by getAllTicketGroups().
292 func (r Ticket) GetAllTicketGroups() (resp []datatypes.Ticket_Group, err error) {
293 err = r.Session.DoRequest("SoftLayer_Ticket", "getAllTicketGroups", nil, &r.Options, &resp)
294 return
295 }
296 297 // getAllTicketStatuses() retrieves a list of all statuses that a ticket may exist in. Ticket status represent the current state of a ticket, usually "open", "assigned", and "closed".
298 //
299 // Every SoftLayer ticket has statusId and status properties that correspond to one of the statuses returned by getAllTicketStatuses().
300 func (r Ticket) GetAllTicketStatuses() (resp []datatypes.Ticket_Status, err error) {
301 err = r.Session.DoRequest("SoftLayer_Ticket", "getAllTicketStatuses", nil, &r.Options, &resp)
302 return
303 }
304 305 // Retrieve
306 func (r Ticket) GetAssignedAgents() (resp []datatypes.User_Customer, err error) {
307 err = r.Session.DoRequest("SoftLayer_Ticket", "getAssignedAgents", nil, &r.Options, &resp)
308 return
309 }
310 311 // Retrieve The portal user that a ticket is assigned to.
312 func (r Ticket) GetAssignedUser() (resp datatypes.User_Customer, err error) {
313 err = r.Session.DoRequest("SoftLayer_Ticket", "getAssignedUser", nil, &r.Options, &resp)
314 return
315 }
316 317 // Retrieve The list of additional emails to notify when a ticket update is made.
318 func (r Ticket) GetAttachedAdditionalEmails() (resp []datatypes.User_Customer_AdditionalEmail, err error) {
319 err = r.Session.DoRequest("SoftLayer_Ticket", "getAttachedAdditionalEmails", nil, &r.Options, &resp)
320 return
321 }
322 323 // Retrieve The Dedicated Hosts associated with a ticket. This is used in cases where a ticket is directly associated with one or more Dedicated Hosts.
324 func (r Ticket) GetAttachedDedicatedHosts() (resp []datatypes.Virtual_DedicatedHost, err error) {
325 err = r.Session.DoRequest("SoftLayer_Ticket", "getAttachedDedicatedHosts", nil, &r.Options, &resp)
326 return
327 }
328 329 // Retrieve the file attached to a SoftLayer ticket by it's given identifier. To retrieve a list of files attached to a ticket either call the SoftLayer_Ticket::getAttachedFiles method or call SoftLayer_Ticket::getObject with ”attachedFiles” defined in an object mask.
330 func (r Ticket) GetAttachedFile(attachmentId *int) (resp []byte, err error) {
331 params := []interface{}{
332 attachmentId,
333 }
334 err = r.Session.DoRequest("SoftLayer_Ticket", "getAttachedFile", params, &r.Options, &resp)
335 return
336 }
337 338 // Retrieve The files attached to a ticket.
339 func (r Ticket) GetAttachedFiles() (resp []datatypes.Ticket_Attachment_File, err error) {
340 err = r.Session.DoRequest("SoftLayer_Ticket", "getAttachedFiles", nil, &r.Options, &resp)
341 return
342 }
343 344 // Retrieve The hardware associated with a ticket. This is used in cases where a ticket is directly associated with one or more pieces of hardware.
345 func (r Ticket) GetAttachedHardware() (resp []datatypes.Hardware, err error) {
346 err = r.Session.DoRequest("SoftLayer_Ticket", "getAttachedHardware", nil, &r.Options, &resp)
347 return
348 }
349 350 // Retrieve
351 func (r Ticket) GetAttachedHardwareCount() (resp uint, err error) {
352 err = r.Session.DoRequest("SoftLayer_Ticket", "getAttachedHardwareCount", nil, &r.Options, &resp)
353 return
354 }
355 356 // Retrieve
357 func (r Ticket) GetAttachedResources() (resp []datatypes.Ticket_Attachment, err error) {
358 err = r.Session.DoRequest("SoftLayer_Ticket", "getAttachedResources", nil, &r.Options, &resp)
359 return
360 }
361 362 // Retrieve The virtual guests associated with a ticket. This is used in cases where a ticket is directly associated with one or more virtualized guests installations or Virtual Servers.
363 func (r Ticket) GetAttachedVirtualGuests() (resp []datatypes.Virtual_Guest, err error) {
364 err = r.Session.DoRequest("SoftLayer_Ticket", "getAttachedVirtualGuests", nil, &r.Options, &resp)
365 return
366 }
367 368 // Retrieve Ticket is waiting on a response from a customer flag.
369 func (r Ticket) GetAwaitingUserResponseFlag() (resp bool, err error) {
370 err = r.Session.DoRequest("SoftLayer_Ticket", "getAwaitingUserResponseFlag", nil, &r.Options, &resp)
371 return
372 }
373 374 // Retrieve A ticket's associated BNPP compliant record
375 func (r Ticket) GetBnppSupportedFlag() (resp bool, err error) {
376 err = r.Session.DoRequest("SoftLayer_Ticket", "getBnppSupportedFlag", nil, &r.Options, &resp)
377 return
378 }
379 380 // Retrieve A service cancellation request.
381 func (r Ticket) GetCancellationRequest() (resp datatypes.Billing_Item_Cancellation_Request, err error) {
382 err = r.Session.DoRequest("SoftLayer_Ticket", "getCancellationRequest", nil, &r.Options, &resp)
383 return
384 }
385 386 // Retrieve
387 func (r Ticket) GetEmployeeAttachments() (resp []datatypes.User_Employee, err error) {
388 err = r.Session.DoRequest("SoftLayer_Ticket", "getEmployeeAttachments", nil, &r.Options, &resp)
389 return
390 }
391 392 // Retrieve A ticket's associated EU compliant record
393 func (r Ticket) GetEuSupportedFlag() (resp bool, err error) {
394 err = r.Session.DoRequest("SoftLayer_Ticket", "getEuSupportedFlag", nil, &r.Options, &resp)
395 return
396 }
397 398 // Retrieve The first physical or virtual server attached to a ticket.
399 func (r Ticket) GetFirstAttachedResource() (resp datatypes.Ticket_Attachment, err error) {
400 err = r.Session.DoRequest("SoftLayer_Ticket", "getFirstAttachedResource", nil, &r.Options, &resp)
401 return
402 }
403 404 // Retrieve The first update made to a ticket. This is typically the contents of a ticket when it's created.
405 func (r Ticket) GetFirstUpdate() (resp datatypes.Ticket_Update, err error) {
406 err = r.Session.DoRequest("SoftLayer_Ticket", "getFirstUpdate", nil, &r.Options, &resp)
407 return
408 }
409 410 // Retrieve A ticket's associated FSBOA compliant record
411 func (r Ticket) GetFsboaSupportedFlag() (resp bool, err error) {
412 err = r.Session.DoRequest("SoftLayer_Ticket", "getFsboaSupportedFlag", nil, &r.Options, &resp)
413 return
414 }
415 416 // Retrieve The SoftLayer department that a ticket is assigned to.
417 func (r Ticket) GetGroup() (resp datatypes.Ticket_Group, err error) {
418 err = r.Session.DoRequest("SoftLayer_Ticket", "getGroup", nil, &r.Options, &resp)
419 return
420 }
421 422 // Retrieve The invoice items associated with a ticket. Ticket based invoice items only exist when a ticket incurs a fee that has been invoiced.
423 func (r Ticket) GetInvoiceItems() (resp []datatypes.Billing_Invoice_Item, err error) {
424 err = r.Session.DoRequest("SoftLayer_Ticket", "getInvoiceItems", nil, &r.Options, &resp)
425 return
426 }
427 428 // Retrieve
429 func (r Ticket) GetLastActivity() (resp datatypes.Ticket_Activity, err error) {
430 err = r.Session.DoRequest("SoftLayer_Ticket", "getLastActivity", nil, &r.Options, &resp)
431 return
432 }
433 434 // Retrieve
435 func (r Ticket) GetLastEditor() (resp datatypes.User_Interface, err error) {
436 err = r.Session.DoRequest("SoftLayer_Ticket", "getLastEditor", nil, &r.Options, &resp)
437 return
438 }
439 440 // Retrieve The last update made to a ticket.
441 func (r Ticket) GetLastUpdate() (resp datatypes.Ticket_Update, err error) {
442 err = r.Session.DoRequest("SoftLayer_Ticket", "getLastUpdate", nil, &r.Options, &resp)
443 return
444 }
445 446 // Retrieve A ticket's associated location within the SoftLayer location hierarchy.
447 func (r Ticket) GetLocation() (resp datatypes.Location, err error) {
448 err = r.Session.DoRequest("SoftLayer_Ticket", "getLocation", nil, &r.Options, &resp)
449 return
450 }
451 452 // Retrieve True if there are new, unread updates to this ticket for the current user, False otherwise.
453 func (r Ticket) GetNewUpdatesFlag() (resp bool, err error) {
454 err = r.Session.DoRequest("SoftLayer_Ticket", "getNewUpdatesFlag", nil, &r.Options, &resp)
455 return
456 }
457 458 // getObject retrieves the SoftLayer_Ticket object whose ID number corresponds to the ID number of the init parameter passed to the SoftLayer_Ticket service. You can only retrieve tickets that are associated with your SoftLayer customer account.
459 func (r Ticket) GetObject() (resp datatypes.Ticket, err error) {
460 err = r.Session.DoRequest("SoftLayer_Ticket", "getObject", nil, &r.Options, &resp)
461 return
462 }
463 464 // Retrieve
465 func (r Ticket) GetScheduledActions() (resp []datatypes.Provisioning_Version1_Transaction, err error) {
466 err = r.Session.DoRequest("SoftLayer_Ticket", "getScheduledActions", nil, &r.Options, &resp)
467 return
468 }
469 470 // Retrieve The invoice associated with a ticket. Only tickets with an associated administrative charge have an invoice.
471 func (r Ticket) GetServerAdministrationBillingInvoice() (resp datatypes.Billing_Invoice, err error) {
472 err = r.Session.DoRequest("SoftLayer_Ticket", "getServerAdministrationBillingInvoice", nil, &r.Options, &resp)
473 return
474 }
475 476 // Retrieve The refund invoice associated with a ticket. Only tickets with a refund applied in them have an associated refund invoice.
477 func (r Ticket) GetServerAdministrationRefundInvoice() (resp datatypes.Billing_Invoice, err error) {
478 err = r.Session.DoRequest("SoftLayer_Ticket", "getServerAdministrationRefundInvoice", nil, &r.Options, &resp)
479 return
480 }
481 482 // Retrieve
483 func (r Ticket) GetServiceProvider() (resp datatypes.Service_Provider, err error) {
484 err = r.Session.DoRequest("SoftLayer_Ticket", "getServiceProvider", nil, &r.Options, &resp)
485 return
486 }
487 488 // Retrieve
489 func (r Ticket) GetState() (resp []datatypes.Ticket_State, err error) {
490 err = r.Session.DoRequest("SoftLayer_Ticket", "getState", nil, &r.Options, &resp)
491 return
492 }
493 494 // Retrieve A ticket's status.
495 func (r Ticket) GetStatus() (resp datatypes.Ticket_Status, err error) {
496 err = r.Session.DoRequest("SoftLayer_Ticket", "getStatus", nil, &r.Options, &resp)
497 return
498 }
499 500 // Retrieve A ticket's subject. Only standard support tickets have an associated subject. A standard support ticket's title corresponds with it's subject's name.
501 func (r Ticket) GetSubject() (resp datatypes.Ticket_Subject, err error) {
502 err = r.Session.DoRequest("SoftLayer_Ticket", "getSubject", nil, &r.Options, &resp)
503 return
504 }
505 506 // Retrieve
507 func (r Ticket) GetTagReferences() (resp []datatypes.Tag_Reference, err error) {
508 err = r.Session.DoRequest("SoftLayer_Ticket", "getTagReferences", nil, &r.Options, &resp)
509 return
510 }
511 512 // Retrieve all tickets closed since a given date.
513 func (r Ticket) GetTicketsClosedSinceDate(closeDate *datatypes.Time) (resp []datatypes.Ticket, err error) {
514 params := []interface{}{
515 closeDate,
516 }
517 err = r.Session.DoRequest("SoftLayer_Ticket", "getTicketsClosedSinceDate", params, &r.Options, &resp)
518 return
519 }
520 521 // Retrieve Whether employees' updates of this ticket could be rated by customer
522 func (r Ticket) GetUpdateRatingFlag() (resp bool, err error) {
523 err = r.Session.DoRequest("SoftLayer_Ticket", "getUpdateRatingFlag", nil, &r.Options, &resp)
524 return
525 }
526 527 // Retrieve A ticket's updates.
528 func (r Ticket) GetUpdates() (resp []datatypes.Ticket_Update, err error) {
529 err = r.Session.DoRequest("SoftLayer_Ticket", "getUpdates", nil, &r.Options, &resp)
530 return
531 }
532 533 // Mark a ticket as viewed. All currently posted updates will be marked as viewed. The lastViewedDate property will be updated to the current time.
534 func (r Ticket) MarkAsViewed() (err error) {
535 var resp datatypes.Void
536 err = r.Session.DoRequest("SoftLayer_Ticket", "markAsViewed", nil, &r.Options, &resp)
537 return
538 }
539 540 func (r Ticket) RemoveAssignedAgent(agentId *int) (err error) {
541 var resp datatypes.Void
542 params := []interface{}{
543 agentId,
544 }
545 err = r.Session.DoRequest("SoftLayer_Ticket", "removeAssignedAgent", params, &r.Options, &resp)
546 return
547 }
548 549 // removeAttachedAdditionalEmails() removes the specified email addresses from a ticket's notification list. If one of the provided email addresses is not attached to the ticket then ”removeAttachedAdditiaonalEmails()” ignores it and continues to the next one. Once the email addresses are removed ”removeAttachedAdditiaonalEmails()” returns a boolean true.
550 func (r Ticket) RemoveAttachedAdditionalEmails(emails []string) (resp bool, err error) {
551 params := []interface{}{
552 emails,
553 }
554 err = r.Session.DoRequest("SoftLayer_Ticket", "removeAttachedAdditionalEmails", params, &r.Options, &resp)
555 return
556 }
557 558 // detach the given hardware from a SoftLayer ticket. Removing a hardware attachment may delay ticket processing time if the hardware removed is relevant to the ticket's issue. Return a boolean true upon successful hardware detachment.
559 func (r Ticket) RemoveAttachedHardware(hardwareId *int) (resp bool, err error) {
560 params := []interface{}{
561 hardwareId,
562 }
563 err = r.Session.DoRequest("SoftLayer_Ticket", "removeAttachedHardware", params, &r.Options, &resp)
564 return
565 }
566 567 // Detach the given CloudLayer Computing Instance from a SoftLayer ticket. Removing an attachment may delay ticket processing time if the instance removed is relevant to the ticket's issue. Return a boolean true upon successful detachment.
568 func (r Ticket) RemoveAttachedVirtualGuest(guestId *int) (resp bool, err error) {
569 params := []interface{}{
570 guestId,
571 }
572 err = r.Session.DoRequest("SoftLayer_Ticket", "removeAttachedVirtualGuest", params, &r.Options, &resp)
573 return
574 }
575 576 // no documentation yet
577 func (r Ticket) RemoveScheduledAlert() (err error) {
578 var resp datatypes.Void
579 err = r.Session.DoRequest("SoftLayer_Ticket", "removeScheduledAlert", nil, &r.Options, &resp)
580 return
581 }
582 583 // no documentation yet
584 func (r Ticket) RemoveScheduledAutoClose() (err error) {
585 var resp datatypes.Void
586 err = r.Session.DoRequest("SoftLayer_Ticket", "removeScheduledAutoClose", nil, &r.Options, &resp)
587 return
588 }
589 590 // no documentation yet
591 func (r Ticket) SetTags(tags *string) (resp bool, err error) {
592 params := []interface{}{
593 tags,
594 }
595 err = r.Session.DoRequest("SoftLayer_Ticket", "setTags", params, &r.Options, &resp)
596 return
597 }
598 599 // (DEPRECATED) Use [[SoftLayer_Ticket_Survey::getPreference]] method.
600 // Deprecated: This function has been marked as deprecated.
601 func (r Ticket) SurveyEligible() (resp bool, err error) {
602 err = r.Session.DoRequest("SoftLayer_Ticket", "surveyEligible", nil, &r.Options, &resp)
603 return
604 }
605 606 // Creates new additional emails for assigned user if new emails are provided. Attaches any newly created additional emails to ticket. Remove any additional emails from a ticket that are not provided as part of $emails
607 func (r Ticket) UpdateAttachedAdditionalEmails(emails []string) (resp bool, err error) {
608 params := []interface{}{
609 emails,
610 }
611 err = r.Session.DoRequest("SoftLayer_Ticket", "updateAttachedAdditionalEmails", params, &r.Options, &resp)
612 return
613 }
614 615 // SoftLayer tickets can have have files attached to them. Attaching a file to a ticket is a good way to report issues, provide documentation, and give examples of an issue. Both SoftLayer customers and employees have the ability to attach files to a ticket. The SoftLayer_Ticket_Attachment_File data type models a single file attached to a ticket.
616 type Ticket_Attachment_File struct {
617 Session session.SLSession
618 Options sl.Options
619 }
620 621 // GetTicketAttachmentFileService returns an instance of the Ticket_Attachment_File SoftLayer service
622 func GetTicketAttachmentFileService(sess session.SLSession) Ticket_Attachment_File {
623 return Ticket_Attachment_File{Session: sess}
624 }
625 626 func (r Ticket_Attachment_File) Id(id int) Ticket_Attachment_File {
627 r.Options.Id = &id
628 return r
629 }
630 631 func (r Ticket_Attachment_File) Mask(mask string) Ticket_Attachment_File {
632 if !strings.HasPrefix(mask, "mask[") && (strings.Contains(mask, "[") || strings.Contains(mask, ",")) {
633 mask = fmt.Sprintf("mask[%s]", mask)
634 }
635 636 r.Options.Mask = mask
637 return r
638 }
639 640 func (r Ticket_Attachment_File) Filter(filter string) Ticket_Attachment_File {
641 r.Options.Filter = filter
642 return r
643 }
644 645 func (r Ticket_Attachment_File) Limit(limit int) Ticket_Attachment_File {
646 r.Options.Limit = &limit
647 return r
648 }
649 650 func (r Ticket_Attachment_File) Offset(offset int) Ticket_Attachment_File {
651 r.Options.Offset = &offset
652 return r
653 }
654 655 // no documentation yet
656 func (r Ticket_Attachment_File) GetExtensionWhitelist() (resp []string, err error) {
657 err = r.Session.DoRequest("SoftLayer_Ticket_Attachment_File", "getExtensionWhitelist", nil, &r.Options, &resp)
658 return
659 }
660 661 // no documentation yet
662 func (r Ticket_Attachment_File) GetObject() (resp datatypes.Ticket_Attachment_File, err error) {
663 err = r.Session.DoRequest("SoftLayer_Ticket_Attachment_File", "getObject", nil, &r.Options, &resp)
664 return
665 }
666 667 // Retrieve
668 func (r Ticket_Attachment_File) GetTicket() (resp datatypes.Ticket, err error) {
669 err = r.Session.DoRequest("SoftLayer_Ticket_Attachment_File", "getTicket", nil, &r.Options, &resp)
670 return
671 }
672 673 // Retrieve The ticket that a file is attached to.
674 func (r Ticket_Attachment_File) GetUpdate() (resp datatypes.Ticket_Update, err error) {
675 err = r.Session.DoRequest("SoftLayer_Ticket_Attachment_File", "getUpdate", nil, &r.Options, &resp)
676 return
677 }
678 679 // no documentation yet
680 type Ticket_Attachment_File_ServiceNow struct {
681 Session session.SLSession
682 Options sl.Options
683 }
684 685 // GetTicketAttachmentFileServiceNowService returns an instance of the Ticket_Attachment_File_ServiceNow SoftLayer service
686 func GetTicketAttachmentFileServiceNowService(sess session.SLSession) Ticket_Attachment_File_ServiceNow {
687 return Ticket_Attachment_File_ServiceNow{Session: sess}
688 }
689 690 func (r Ticket_Attachment_File_ServiceNow) Id(id int) Ticket_Attachment_File_ServiceNow {
691 r.Options.Id = &id
692 return r
693 }
694 695 func (r Ticket_Attachment_File_ServiceNow) Mask(mask string) Ticket_Attachment_File_ServiceNow {
696 if !strings.HasPrefix(mask, "mask[") && (strings.Contains(mask, "[") || strings.Contains(mask, ",")) {
697 mask = fmt.Sprintf("mask[%s]", mask)
698 }
699 700 r.Options.Mask = mask
701 return r
702 }
703 704 func (r Ticket_Attachment_File_ServiceNow) Filter(filter string) Ticket_Attachment_File_ServiceNow {
705 r.Options.Filter = filter
706 return r
707 }
708 709 func (r Ticket_Attachment_File_ServiceNow) Limit(limit int) Ticket_Attachment_File_ServiceNow {
710 r.Options.Limit = &limit
711 return r
712 }
713 714 func (r Ticket_Attachment_File_ServiceNow) Offset(offset int) Ticket_Attachment_File_ServiceNow {
715 r.Options.Offset = &offset
716 return r
717 }
718 719 // no documentation yet
720 func (r Ticket_Attachment_File_ServiceNow) GetExtensionWhitelist() (resp []string, err error) {
721 err = r.Session.DoRequest("SoftLayer_Ticket_Attachment_File_ServiceNow", "getExtensionWhitelist", nil, &r.Options, &resp)
722 return
723 }
724 725 // no documentation yet
726 func (r Ticket_Attachment_File_ServiceNow) GetObject() (resp datatypes.Ticket_Attachment_File_ServiceNow, err error) {
727 err = r.Session.DoRequest("SoftLayer_Ticket_Attachment_File_ServiceNow", "getObject", nil, &r.Options, &resp)
728 return
729 }
730 731 // Retrieve
732 func (r Ticket_Attachment_File_ServiceNow) GetTicket() (resp datatypes.Ticket, err error) {
733 err = r.Session.DoRequest("SoftLayer_Ticket_Attachment_File_ServiceNow", "getTicket", nil, &r.Options, &resp)
734 return
735 }
736 737 // Retrieve The ticket that a file is attached to.
738 func (r Ticket_Attachment_File_ServiceNow) GetUpdate() (resp datatypes.Ticket_Update, err error) {
739 err = r.Session.DoRequest("SoftLayer_Ticket_Attachment_File_ServiceNow", "getUpdate", nil, &r.Options, &resp)
740 return
741 }
742 743 // no documentation yet
744 type Ticket_Priority struct {
745 Session session.SLSession
746 Options sl.Options
747 }
748 749 // GetTicketPriorityService returns an instance of the Ticket_Priority SoftLayer service
750 func GetTicketPriorityService(sess session.SLSession) Ticket_Priority {
751 return Ticket_Priority{Session: sess}
752 }
753 754 func (r Ticket_Priority) Id(id int) Ticket_Priority {
755 r.Options.Id = &id
756 return r
757 }
758 759 func (r Ticket_Priority) Mask(mask string) Ticket_Priority {
760 if !strings.HasPrefix(mask, "mask[") && (strings.Contains(mask, "[") || strings.Contains(mask, ",")) {
761 mask = fmt.Sprintf("mask[%s]", mask)
762 }
763 764 r.Options.Mask = mask
765 return r
766 }
767 768 func (r Ticket_Priority) Filter(filter string) Ticket_Priority {
769 r.Options.Filter = filter
770 return r
771 }
772 773 func (r Ticket_Priority) Limit(limit int) Ticket_Priority {
774 r.Options.Limit = &limit
775 return r
776 }
777 778 func (r Ticket_Priority) Offset(offset int) Ticket_Priority {
779 r.Options.Offset = &offset
780 return r
781 }
782 783 // no documentation yet
784 func (r Ticket_Priority) GetPriorities() (resp []datatypes.Container_Ticket_Priority, err error) {
785 err = r.Session.DoRequest("SoftLayer_Ticket_Priority", "getPriorities", nil, &r.Options, &resp)
786 return
787 }
788 789 // The SoftLayer_Ticket_Subject data type models one of the possible subjects that a standard support ticket may belong to. A basic support ticket's title matches it's corresponding subject's name.
790 type Ticket_Subject struct {
791 Session session.SLSession
792 Options sl.Options
793 }
794 795 // GetTicketSubjectService returns an instance of the Ticket_Subject SoftLayer service
796 func GetTicketSubjectService(sess session.SLSession) Ticket_Subject {
797 return Ticket_Subject{Session: sess}
798 }
799 800 func (r Ticket_Subject) Id(id int) Ticket_Subject {
801 r.Options.Id = &id
802 return r
803 }
804 805 func (r Ticket_Subject) Mask(mask string) Ticket_Subject {
806 if !strings.HasPrefix(mask, "mask[") && (strings.Contains(mask, "[") || strings.Contains(mask, ",")) {
807 mask = fmt.Sprintf("mask[%s]", mask)
808 }
809 810 r.Options.Mask = mask
811 return r
812 }
813 814 func (r Ticket_Subject) Filter(filter string) Ticket_Subject {
815 r.Options.Filter = filter
816 return r
817 }
818 819 func (r Ticket_Subject) Limit(limit int) Ticket_Subject {
820 r.Options.Limit = &limit
821 return r
822 }
823 824 func (r Ticket_Subject) Offset(offset int) Ticket_Subject {
825 r.Options.Offset = &offset
826 return r
827 }
828 829 // Retrieve all possible ticket subjects. The SoftLayer customer portal uses this method in the add standard support ticket form.
830 func (r Ticket_Subject) GetAllObjects() (resp []datatypes.Ticket_Subject, err error) {
831 err = r.Session.DoRequest("SoftLayer_Ticket_Subject", "getAllObjects", nil, &r.Options, &resp)
832 return
833 }
834 835 // Retrieve
836 func (r Ticket_Subject) GetCategory() (resp datatypes.Ticket_Subject_Category, err error) {
837 err = r.Session.DoRequest("SoftLayer_Ticket_Subject", "getCategory", nil, &r.Options, &resp)
838 return
839 }
840 841 // Retrieve A child subject
842 func (r Ticket_Subject) GetChildren() (resp []datatypes.Ticket_Subject, err error) {
843 err = r.Session.DoRequest("SoftLayer_Ticket_Subject", "getChildren", nil, &r.Options, &resp)
844 return
845 }
846 847 // Retrieve
848 func (r Ticket_Subject) GetGroup() (resp datatypes.Ticket_Group, err error) {
849 err = r.Session.DoRequest("SoftLayer_Ticket_Subject", "getGroup", nil, &r.Options, &resp)
850 return
851 }
852 853 // getObject retrieves the SoftLayer_Ticket_Subject object whose ID number corresponds to the ID number of the init parameter passed to the SoftLayer_Ticket_Subject service.
854 func (r Ticket_Subject) GetObject() (resp datatypes.Ticket_Subject, err error) {
855 err = r.Session.DoRequest("SoftLayer_Ticket_Subject", "getObject", nil, &r.Options, &resp)
856 return
857 }
858 859 // Retrieve A parent subject
860 func (r Ticket_Subject) GetParent() (resp datatypes.Ticket_Subject, err error) {
861 err = r.Session.DoRequest("SoftLayer_Ticket_Subject", "getParent", nil, &r.Options, &resp)
862 return
863 }
864 865 // SoftLayer maintains relationships between the generic subjects for standard administration and the top five commonly asked questions about these subjects. getTopFileKnowledgeLayerQuestions() retrieves the top five questions and answers from the SoftLayer KnowledgeLayer related to the given ticket subject.
866 func (r Ticket_Subject) GetTopFiveKnowledgeLayerQuestions() (resp []datatypes.Container_KnowledgeLayer_QuestionAnswer, err error) {
867 err = r.Session.DoRequest("SoftLayer_Ticket_Subject", "getTopFiveKnowledgeLayerQuestions", nil, &r.Options, &resp)
868 return
869 }
870 871 // SoftLayer_Ticket_Subject_Category groups ticket subjects into logical group.
872 type Ticket_Subject_Category struct {
873 Session session.SLSession
874 Options sl.Options
875 }
876 877 // GetTicketSubjectCategoryService returns an instance of the Ticket_Subject_Category SoftLayer service
878 func GetTicketSubjectCategoryService(sess session.SLSession) Ticket_Subject_Category {
879 return Ticket_Subject_Category{Session: sess}
880 }
881 882 func (r Ticket_Subject_Category) Id(id int) Ticket_Subject_Category {
883 r.Options.Id = &id
884 return r
885 }
886 887 func (r Ticket_Subject_Category) Mask(mask string) Ticket_Subject_Category {
888 if !strings.HasPrefix(mask, "mask[") && (strings.Contains(mask, "[") || strings.Contains(mask, ",")) {
889 mask = fmt.Sprintf("mask[%s]", mask)
890 }
891 892 r.Options.Mask = mask
893 return r
894 }
895 896 func (r Ticket_Subject_Category) Filter(filter string) Ticket_Subject_Category {
897 r.Options.Filter = filter
898 return r
899 }
900 901 func (r Ticket_Subject_Category) Limit(limit int) Ticket_Subject_Category {
902 r.Options.Limit = &limit
903 return r
904 }
905 906 func (r Ticket_Subject_Category) Offset(offset int) Ticket_Subject_Category {
907 r.Options.Offset = &offset
908 return r
909 }
910 911 // Retrieve all ticket subject categories.
912 func (r Ticket_Subject_Category) GetAllObjects() (resp []datatypes.Ticket_Subject_Category, err error) {
913 err = r.Session.DoRequest("SoftLayer_Ticket_Subject_Category", "getAllObjects", nil, &r.Options, &resp)
914 return
915 }
916 917 // no documentation yet
918 func (r Ticket_Subject_Category) GetObject() (resp datatypes.Ticket_Subject_Category, err error) {
919 err = r.Session.DoRequest("SoftLayer_Ticket_Subject_Category", "getObject", nil, &r.Options, &resp)
920 return
921 }
922 923 // Retrieve
924 func (r Ticket_Subject_Category) GetSubjects() (resp []datatypes.Ticket_Subject, err error) {
925 err = r.Session.DoRequest("SoftLayer_Ticket_Subject_Category", "getSubjects", nil, &r.Options, &resp)
926 return
927 }
928 929 // no documentation yet
930 // Deprecated: This function has been marked as deprecated.
931 type Ticket_Survey struct {
932 Session session.SLSession
933 Options sl.Options
934 }
935 936 // GetTicketSurveyService returns an instance of the Ticket_Survey SoftLayer service
937 func GetTicketSurveyService(sess session.SLSession) Ticket_Survey {
938 return Ticket_Survey{Session: sess}
939 }
940 941 func (r Ticket_Survey) Id(id int) Ticket_Survey {
942 r.Options.Id = &id
943 return r
944 }
945 946 func (r Ticket_Survey) Mask(mask string) Ticket_Survey {
947 if !strings.HasPrefix(mask, "mask[") && (strings.Contains(mask, "[") || strings.Contains(mask, ",")) {
948 mask = fmt.Sprintf("mask[%s]", mask)
949 }
950 951 r.Options.Mask = mask
952 return r
953 }
954 955 func (r Ticket_Survey) Filter(filter string) Ticket_Survey {
956 r.Options.Filter = filter
957 return r
958 }
959 960 func (r Ticket_Survey) Limit(limit int) Ticket_Survey {
961 r.Options.Limit = &limit
962 return r
963 }
964 965 func (r Ticket_Survey) Offset(offset int) Ticket_Survey {
966 r.Options.Offset = &offset
967 return r
968 }
969 970 // (DEPRECATED) To opt in or out of future surveys, please follow the link found in the email survey.
971 // Deprecated: This function has been marked as deprecated.
972 func (r Ticket_Survey) GetPreference() (err error) {
973 var resp datatypes.Void
974 err = r.Session.DoRequest("SoftLayer_Ticket_Survey", "getPreference", nil, &r.Options, &resp)
975 return
976 }
977 978 // (DEPRECATED) To opt in of future surveys, please follow the link found in the email survey.
979 // Deprecated: This function has been marked as deprecated.
980 func (r Ticket_Survey) OptIn() (err error) {
981 var resp datatypes.Void
982 err = r.Session.DoRequest("SoftLayer_Ticket_Survey", "optIn", nil, &r.Options, &resp)
983 return
984 }
985 986 // (DEPRECATED) To opt out of future surveys, please follow the link found in the email survey.
987 // Deprecated: This function has been marked as deprecated.
988 func (r Ticket_Survey) OptOut() (err error) {
989 var resp datatypes.Void
990 err = r.Session.DoRequest("SoftLayer_Ticket_Survey", "optOut", nil, &r.Options, &resp)
991 return
992 }
993 994 // The SoftLayer_Ticket_Update_Employee data type models an update to a ticket made by a SoftLayer employee.
995 type Ticket_Update_Employee struct {
996 Session session.SLSession
997 Options sl.Options
998 }
999 1000 // GetTicketUpdateEmployeeService returns an instance of the Ticket_Update_Employee SoftLayer service
1001 func GetTicketUpdateEmployeeService(sess session.SLSession) Ticket_Update_Employee {
1002 return Ticket_Update_Employee{Session: sess}
1003 }
1004 1005 func (r Ticket_Update_Employee) Id(id int) Ticket_Update_Employee {
1006 r.Options.Id = &id
1007 return r
1008 }
1009 1010 func (r Ticket_Update_Employee) Mask(mask string) Ticket_Update_Employee {
1011 if !strings.HasPrefix(mask, "mask[") && (strings.Contains(mask, "[") || strings.Contains(mask, ",")) {
1012 mask = fmt.Sprintf("mask[%s]", mask)
1013 }
1014 1015 r.Options.Mask = mask
1016 return r
1017 }
1018 1019 func (r Ticket_Update_Employee) Filter(filter string) Ticket_Update_Employee {
1020 r.Options.Filter = filter
1021 return r
1022 }
1023 1024 func (r Ticket_Update_Employee) Limit(limit int) Ticket_Update_Employee {
1025 r.Options.Limit = &limit
1026 return r
1027 }
1028 1029 func (r Ticket_Update_Employee) Offset(offset int) Ticket_Update_Employee {
1030 r.Options.Offset = &offset
1031 return r
1032 }
1033 1034 // As part of the customer service process SoftLayer has provided a quick feedback mechanism for its customers to rate the responses that its employees give on tickets. addResponseRating() sets the rating for a single ticket update made by a SoftLayer employee. Ticket ratings have the integer values 1 through 5, with 1 being the worst and 5 being the best. Once the rating is set ”addResponseRating()” returns a boolean true.
1035 func (r Ticket_Update_Employee) AddResponseRating(responseRating *int, responseIndex *int) (resp bool, err error) {
1036 params := []interface{}{
1037 responseRating,
1038 responseIndex,
1039 }
1040 err = r.Session.DoRequest("SoftLayer_Ticket_Update_Employee", "addResponseRating", params, &r.Options, &resp)
1041 return
1042 }
1043 1044 // getObject retrieves the SoftLayer_Ticket_Update_Employee object whose ID number corresponds to the ID number of the init parameter passed to the SoftLayer_Ticket_Update_Employee service. You can only retrieve employee updates to tickets that your API account has access to.
1045 func (r Ticket_Update_Employee) GetObject() (resp datatypes.Ticket_Update_Employee, err error) {
1046 err = r.Session.DoRequest("SoftLayer_Ticket_Update_Employee", "getObject", nil, &r.Options, &resp)
1047 return
1048 }
1049