Update the Attachment with predefined ID

Update the Attachment with predefined ID.

SecuritySecretApiKey or JWT
Request
path Parameters
id
required
string <= 50 characters ^[@~\-\.\w]+$

The resource identifier string.

Request Body schema: application/json

Attachment resource.

fileId
required
string

Linked File object id.

relatedId
required
string

Linked object Id.

relatedType
required
string

Linked object type.

Enum: "customer" "customer-timeline-comment" "customer-edd-timeline-comment" "dispute" "gateway-timeline-comment" "invoice" "invoice-timeline-comment" "order-timeline-comment" "organization" "payment" … 5 more
name
string

The Original Attachment name.

description
string

The Attachment description.

Responses
200

Attachment was updated.

Response Schema: application/json
fileId
required
string

Linked File object id.

relatedId
required
string

Linked object Id.

relatedType
required
string

Linked object type.

Enum: "customer" "customer-timeline-comment" "customer-edd-timeline-comment" "dispute" "gateway-timeline-comment" "invoice" "invoice-timeline-comment" "order-timeline-comment" "organization" "payment" … 5 more
id
string <= 50 characters

The resource ID. Defaults to UUID v4.

name
string

The Original Attachment name.

description
string

The Attachment description.

createdTime
string <date-time>

Creation date/time.

updatedTime
string <date-time> (UpdatedTime)

Read-only timestamp updates when the resource is updated.

Array of Self (object) or FileLink (object) or AttachmentResourceLink (object) >= 3 items

The links related to resource.

Array (>= 3 items)
Any of:
href
required
string

The link URL.

rel
required
string

The link type.

Value: "self"
Array of FileEmbed (object) non-empty

Any embedded objects available that are requested by the expand querystring parameter.

Array (non-empty)
Any of:

File object.

object (File)
201

Attachment was created.

Response Headers
Location
string <uri>

The location of the related resource.

Example: "https://api.rebilly.com/example"
Response Schema: application/json
fileId
required
string

Linked File object id.

relatedId
required
string

Linked object Id.

relatedType
required
string

Linked object type.

Enum: "customer" "customer-timeline-comment" "customer-edd-timeline-comment" "dispute" "gateway-timeline-comment" "invoice" "invoice-timeline-comment" "order-timeline-comment" "organization" "payment" … 5 more
id
string <= 50 characters

The resource ID. Defaults to UUID v4.

name
string

The Original Attachment name.

description
string

The Attachment description.

createdTime
string <date-time>

Creation date/time.

updatedTime
string <date-time> (UpdatedTime)

Read-only timestamp updates when the resource is updated.

Array of Self (object) or FileLink (object) or AttachmentResourceLink (object) >= 3 items

The links related to resource.

Array (>= 3 items)
Any of:
href
required
string

The link URL.

rel
required
string

The link type.

Value: "self"
Array of FileEmbed (object) non-empty

Any embedded objects available that are requested by the expand querystring parameter.

Array (non-empty)
Any of:

File object.

object (File)
401

Unauthorized access, invalid credentials were used.

403

Access forbidden.

404

Resource was not found.

409

Conflict.

422

Invalid data was sent.

put/attachments/{id}
Request samples
application/json
{
  • "fileId": "string",
  • "relatedType": "customer",
  • "relatedId": "string",
  • "name": "string",
  • "description": "string"
}
Response samples
application/json
{
  • "id": "4f6cf35x-2c4y-483z-a0a9-158621f77a21",
  • "fileId": "string",
  • "relatedType": "customer",
  • "relatedId": "string",
  • "name": "string",
  • "description": "string",
  • "createdTime": "2019-08-24T14:15:22Z",
  • "updatedTime": "2019-08-24T14:15:22Z",
  • "_links": [
    ],
  • "_embedded": [
    ]
}