Skip to main content
POST
/
v1
/
compliance
/
dsar
/
{jobId}
/
run
Run a DSAR job
const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};

fetch('https://sandbox.api.enfinitos.com/v1/compliance/dsar/{jobId}/run', options)
  .then(res => res.json())
  .then(res => console.log(res))
  .catch(err => console.error(err));
{
  "ok": true,
  "data": {
    "job": {
      "id": "<string>",
      "orgId": "<string>",
      "createdAt": "2023-11-07T05:31:56Z",
      "updatedAt": "2023-11-07T05:31:56Z",
      "scope": {
        "dataSubjectId": "<string>",
        "windowStart": "2023-11-07T05:31:56Z",
        "windowEnd": "2023-11-07T05:31:56Z",
        "campaignIds": [
          "<string>"
        ],
        "substrates": [
          "<string>"
        ]
      },
      "requestedBy": "<string>",
      "requestNotes": "<string>",
      "progress": {
        "rowsCollected": 123,
        "rowsExpected": 123,
        "bytesPackaged": 123,
        "lastHeartbeatAt": "2023-11-07T05:31:56Z",
        "workerId": "<string>"
      },
      "delivery": {
        "bundleR2Key": "<string>",
        "bundleSizeBytes": 123,
        "bundleSha256": "<string>",
        "bundleUrl": "<string>",
        "expiresAt": "2023-11-07T05:31:56Z",
        "downloadedAt": "2023-11-07T05:31:56Z",
        "downloadedBy": "<string>"
      },
      "failure": {
        "message": "<string>",
        "failedAt": "2023-11-07T05:31:56Z",
        "workerId": "<string>"
      },
      "timeline": [
        {
          "at": "2023-11-07T05:31:56Z",
          "actor": "<string>",
          "notes": "<string>"
        }
      ]
    },
    "auditReport": {
      "jobId": "<string>",
      "orgId": "<string>",
      "requestedBy": "<string>",
      "requestedAt": "2023-11-07T05:31:56Z",
      "generatedAt": "2023-11-07T05:31:56Z",
      "sectionCounts": {},
      "totalRecords": 123,
      "redactionNotes": [
        "<string>"
      ]
    }
  },
  "contractVersion": "<string>"
}

Authorizations

Authorization
string
header
required

API key sent as Authorization: Bearer <api-key>.

Path Parameters

jobId
string
required

DSAR job id (prefixed dsar:).

Response

The READY job and the materialised audit report.

ok
boolean
required
data
object
required

Route-specific payload. Operation responses refine this.

contractVersion
string
required
Allowed value: "v1.0"