Lists all attachments for the resource
OptionalinlineDoc: booleanIf true, includes inline document content in the response
A promise resolving to an array of DocLink objects
Downloads the content of an attachment
The ID of the attachment (from DocLink href)
A promise resolving to the attachment data (ArrayBuffer)
Fetches metadata for a specific attachment (document description, mimetype, etc.) Uses the /doclinks/meta/{id} endpoint per IBM Maximo REST API docs
The ID of the attachment (from DocLink href)
A promise resolving to the attachment metadata
Deletes an attachment using POST with x-method-override: DELETE Per IBM Maximo REST API docs, attachment deletion requires POST with method override
The ID of the attachment to delete
Uploads a file as an attachment via binary POST to the doclinks endpoint
Supports two modes:
The name of the file
The file data (Buffer, ArrayBuffer, or string). If customEncoding='base64', this should be the base64 string.
Additional options like description, doctype, content-location, and custom headers
Optionalproperties: string | string[]Optional properties to return in the response (string or string array)
Creates an attachment from Base64 encoded data using the custom-encoding header.
Per IBM Maximo REST API docs, the doclinks endpoint accepts base64-encoded content when the 'custom-encoding: base64' header is set. The base64 string is sent as the body.
The name of the file
The Base64 encoded file content
Additional options like description and doctype
Optionalproperties: string | string[]Optional properties to return in the response (string or string array)
Creates a new AttachmentService
The HTTP client for making requests
The Maximo object structure name (e.g., 'mxapiasset')
The unique ID of the resource (e.g., '123')
The API home path (e.g., '/maximo/oslc/os')
Optionallogger: ILoggerOptional logger
Service for managing attachments (DocLinks) for a specific Maximo resource