SoftLayer Ticket::addAttachedFile

From SoftLayer Development Network Wiki

Jump to: navigation, search

addAttachedFile is a member of the SoftLayer_Ticket service.

Contents

Overview

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.

User Access

Users wishing to execute addAttachedFile service must have the Add / Edit Tickets and View Tickets permissions assigned to their account.

Return Type

addAttachedFile returns the SoftLayer_Ticket_Attachment_File data type.

Headers

Required Headers

addAttachedFile requires the following headers:

Parameters

addAttachedFile takes the following parameters:

fileAttachment

The file to attach

Error Handling

addAttachedFile throws the following exceptions:

  • SoftLayer_Exception
Throw the exception "Unable to attach a null file to this ticket." if an empty SoftLayer_Container_File_Attachment is provided.
  • SoftLayer_Exception
Throw the exception "Unable to attach a file with no file name to this ticket." if the given file attachment has no file name.
  • SoftLayer_Exception
Throw the exception "Unable to attach a file with no contents to this ticket." if the given file attachment has no contents.
  • SoftLayer_Exception
Throw the exception "A file named {filename} is already attached to this ticket." if the a file with the same name is already attached to this ticket.
  • SoftLayer_Exception
Throw the exception "Unable to attach file to this ticket." if the API is unable to attach the given file to this ticket.

Associated Methods

Personal tools