Skip to main content

Effective 10 September 2024, API Documentation can be found on our Equinix Product Documentation site.
The content on this page will not be updated after 1 Oct 2024 and will be inaccessible after 31st Dec 2024.


Attachments (V1)

Attachments (V1) APIs allows a user to upload an attachment and to include this attachment in any order or request. These attachments may also be deleted.

POST Attachments File

 POST /attachments/file
MethodPOST
URL or End Point/v1/attachments/file
HeadersAuthorization, Content-Type
Query Parameterspurpose
Form Datafile
BodyNot applicable

This method creates an attachment to be uploaded. The returned attachment ID and attachment name will be used with other POST methods that require an attachment. For example, when you upload a Letter of Authorization (LOA) file or purchase order file using this method, the attachment IDs and names generated can be included in your request to create a cross connect.

 

The attachment size limit per file is 10 MB in the following formats: bmp, jpg, jpeg, gif, png, tif, tiff, txt, doc, docx, xls, xlsx, ppt, pps, ppsx, pdf, and vsd.

However, depending on the order or attachment type, the size of the file and the number of files that can be attached with a POST API may vary. Refer to the description of the attachment object in the request body parameter for the specific POST API.

Each attachment will only be stored for up to 40 days from the day of creation. The returned attachment ID number will no longer be valid after this time.

The attachment ID is exclusive to the original user who uploaded the attachment, and cannot be used by other users.

When using a GET call to retrieve order or ticket details, the attachment ID returned may appear different than the ID submitted. This is expected behaviour, so you may ignore this. However, the attachment name returned should match the original attachment name in this POST call. We recommend that you avoid having hard dependency on attachment ID from this method.

The authorization token and content-type are the only headers that are passed to this API and a response is received based on the values passed.

 

If you are unaware of how to obtain an authorization token, refer to Requesting Access and Refresh tokens under the Getting Access Token section.

The following screenshots show a sample curl request and JSON response for this API. The response indicates that a user can upload a file, 'letter_of_authorization294850.docx'.

curl -X
POST "https://api.equinix.com/v1/attachments/file?purpose=LOA"
-H "content-type: multipart/form-data; boundary=----WebKitFormBoundary7MA4YWxkTrZu0gW"
-H "content-type: application/x-www-form-urlencoded"
-H "authorization: Bearer qwErtY8zyW1abcdefGHI"
-F 'uploadFile=@/C:/Users/johndoe/Desktop/letter_of_authorization294850.docx'

The description of the request parameters is as follows:

 

When 'Conditional' is indicated for a request parameter, refer to Description for further details.

Form Parameter NameMandatoryTypeExampleDescription
uploadFileYesfileletter_of_authorization294850.docxThe name of the file to be uploaded.
 

This original name of the file will be saved as the attachment name in Equinix's system. Once uploaded, the attachment name cannot be changed.

Query Parameter NameMandatoryTypeExampleApplicable ValuesDescription
purposeConditionalstringLOALOA,
PO_DOCUMENT

Purpose of the file to be uploaded.

E.g. Letter of Authorization (LOA) for Cross Connect, Purchase Order (PO) document.

When an LOA or PO document is uploaded, this is a mandatory query parameter for background validation purposes.
{
"attachmentId": "abc1fd2e-345f-67g4-hi89-01jk234l5m6n",
"attachmentName": "letter_of_authorization294850.docx",
"attachmentType": "docx",
"attachmentSize": 35242,
"createdDate": "2019-07-02T02:46:27.105Z",
"createdBy": "johnDoe",
"lastUpdatedDate": "2019-07-02T02:46:27.105Z"
}

The description of the response payload is as follows:

Field nameTypeExampleDescription
attachmentIdstringabc1fd2e-345f-67g4-hi89-01jk234l5m6nID of the file uploaded (attachment). This is a fixed identifier unique to the attachment.
 

This is mandatory to include in other POST APIs with attachments.

This is mandatory to include when deleting or retrieving this attachment.

attachmentNamestringletter_of_authorization294850.docxName of the file uploaded (attachment).
 

This attachment name will remain unchanged in Equinix's system.

When including this attachment in other POST API request bodies, the attachment name may be changed by the user for their reference. However, this original attachment name will remain unchanged and linked to the attachment ID number in Equinix's system.

For example, the attachment name is registered in the system as 'letter_of_authorization294850.docx', but while including this in a cross connect order, it may be named as 'letter_of_authorization294850.docx' or be changed to '2019-LOAforAkamai1.docx', based on user's preference. However, when using a GET call to retrieve order or ticket details, the original attachment name 'letter_of_authorization294850.docx' will be the only name linked to this attachment.

attachmentTypestringdocxType of file uploaded.
attachmentSizestring35242Size of file uploaded in bytes.
createdDatestring2019-07-02T02:46:27.105ZDate and time (UTC time zone) that file was uploaded (following ISO 8601 Datetime format).
createdBystringjohnDoe

UserName of user who uploaded the file.

The file will only be stored for up to 40 days from this date before being deleted. After this, the file would have to be uploaded again and the new attachmentId and attachmentName would have to be used.
lastUpdatedDatestring2019-07-02T02:46:27.105ZDate and time (UTC time zone) that file was last accessed (following ISO 8601 Datetime format).
 

If you get “Insufficient permissions” error, contact your Master Administrator.

DELETE Attachments {attachmentId}

 DELETE /attachments/{attachmentId}
MethodDELETE
URL or End Point/v1/attachments/{attachmentId}
HeadersAuthorization, Content-Type
Query ParametersNot applicable
BodyNot applicable

This API deletes a specific attachment file. The authorization token and content-type are the only headers that are passed to this API and a response is received based on the values passed.

 

If you are unaware of how to obtain an authorization token, refer to Requesting Access and Refresh tokens under the Getting Access Token section.

The following screenshots show a sample curl request and JSON response to delete a connection with attachment ID, ce123d45-1f23-1ca2-1e23-12345f67890a.

curl -X
DEL "https://api.equinix.com/v1/attachments/abc1fd2e-345f-67g4-hi89-01jk234l5m6n"
-H "content-type: application/json"
-H "authorization: Bearer qwErtY8zyW1abcdefGHI"

The description of the URL parameter is as follows:

URL Parameter NameMandatoryTypeExample valuesDescription
attachmentIdYesstringabc1fd2e-345f-67g4-hi89-01jk234l5m6n

Attachment ID number.

This is an identifier unique to each attachment. This is exclusive to the original user who created the attachment, and can only be used by the original user.
{
"status": true
}

The description of the response payload is as follows:

Field nameTypeExample valuesDescription
statusstringtrue

Indicates the status of the Delete API call.

If 'true', attachment was successfully deleted.

If attachment was not succesfully deleted, error message will be returned.
 

If you get “Insufficient permissions” error, contact your Master Administrator.