Attachments
Manage action attachments (files, reports, data to include in action output).
GET /api/jobs/{id}/actions/{jobActionId}/attachments
List all attachments for an action.
Authentication: Required
Response:
{
"_links": {
"self": { "href": "/api/jobs/{id}/actions/{jobActionId}/attachments" }
},
"_embedded": {
"inf:job-attachment": [
{
"id": "attachment-abc-123",
"jobActionId": "action-abc-123",
"type": "report",
"name": "Sales Report",
"data": {
"reportId": "sales-summary-2024"
}
}
]
},
"start": 0,
"count": 1,
"total": 1
}
POST /api/jobs/{id}/actions/{jobActionId}/attachments
Create a new attachment for an action.
Authentication: Required
Permissions: Requires job:edit permission
Request Body:
| Field | Type | Required | Description |
|---|---|---|---|
type | string | Yes | Attachment driver type |
name | string | Yes | Attachment name |
data | object | No | Attachment-specific configuration |
Example:
{
"type": "report",
"name": "Sales Report",
"data": {
"reportId": "sales-summary-2024",
"format": "pdf"
}
}
Response:
201 Created
GET /api/jobs/{id}/actions/{jobActionId}/attachments/{jobActionAttachmentId}
Get a specific attachment.
Authentication: Required
Response:
{
"id": "attachment-abc-123",
"type": "report",
"name": "Sales Report",
"data": { "reportId": "sales-summary-2024" }
}
PUT /api/jobs/{id}/actions/{jobActionId}/attachments/{jobActionAttachmentId}
Update an attachment.
Authentication: Required
Permissions: Requires job:edit permission
Request Body:
{
"name": "Updated Sales Report",
"data": { "format": "excel" }
}
Response:
200 OK
DELETE /api/jobs/{id}/actions/{jobActionId}/attachments/{jobActionAttachmentId}
Delete an attachment.
Authentication: Required
Permissions: Requires job:edit permission
Response:
204 No Content
GET /api/jobs/{id}/actions/{jobActionId}/attachments/{jobActionAttachmentId}/action-attachment-file-contents
Get uploaded file contents for an attachment.
Authentication: Required
Response:
Binary stream with file contents
PUT /api/jobs/{id}/actions/{jobActionId}/attachments/{jobActionAttachmentId}/action-attachment-file-contents
Upload a file for an attachment.
Authentication: Required
Permissions: Requires job:edit permission
Response:
200 OK
GET /api/job-attachment-drivers
List available attachment drivers.
Authentication: Required
Response:
{
"_links": {
"self": { "href": "/api/job-attachment-drivers" }
},
"_embedded": {
"inf:job-attachment-driver": [
{
"id": "report",
"name": "Report",
"description": "Attach a report export"
},
{
"id": "file",
"name": "File",
"description": "Attach a file upload"
},
{
"id": "dataset",
"name": "Dataset",
"description": "Attach dataset export"
}
]
},
"start": 0,
"count": 3,
"total": 3
}
GET /api/job-attachment-drivers/{id}
Get details for a specific attachment driver.
Authentication: Required
Path Parameters:
| Parameter | Type | Description |
|---|---|---|
id | string | Driver ID |
Response:
{
"id": "report",
"name": "Report",
"description": "Attach a report export"
}
GET /api/jobs/{id}/actions/{jobActionId}/attachment-templates
List attachment templates for an action.
Authentication: Required
Response:
{
"_links": {
"self": { "href": "/api/jobs/{id}/actions/{jobActionId}/attachment-templates" }
},
"_embedded": {
"inf:job-attachment-template": [
{
"id": "pdf-report",
"name": "PDF Report",
"type": "report",
"data": { "format": "pdf" }
}
]
},
"start": 0,
"count": 1,
"total": 1
}