> ## Documentation Index
> Fetch the complete documentation index at: https://intunedhq.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Sink Body

## Introduction

When a sink is configured, Run results are delivered to the sink destination. The payload is a JSON object containing the API Run result along with additional metadata. The structure is mostly similar between Jobs and Runs with some minor differences.

## Format

**apiInfo** `object` *required*

Info about the API that was run. Includes the API name and result of run.

**name** `string` *required*

The API name.

**parameters** `object | array\<any\>`

The parameters to passed to the API for this run.

**result** `object`

> [tab] Completed
>
> **status** `enum\<string\>` *required*
>
> The status of the API run.
>
> Available options: `completed`
>
> **result** `any`
>
> The result of the API run.
>
> **statusCode** `number` *required*
>
> The status code of the API run.

> [tab] Failed
>
> **status** `enum\<string\>` *required*
>
> The status of the API run.
>
> Available options: `failed`
>
> **error** `string` *required*
>
> Error code.
>
> **message** `string` *required*
>
> Error message.
>
> **statusCode** `number` *required*
>
> The status code of the API run.

**runId** `string` *required*

The run ID for the API run.

**attributes** `object`

The run's [attributes](https://intunedhq.com/docs/main/02-features/run-attributes.md). Left out when the run reported none.

**metadata** `object`

Platform facts about the run. Fields that don't apply are `null`.

**workspaceId** `string` *required*

The workspace ID.

**projectId** `string` *required*

The project UUID.

**jobId** `string | null` *required*

The Job that started the run.

**jobRunId** `string | null` *required*

The JobRun the run belongs to.

**parentRunId** `string | null` *required*

The run whose `extendPayload` call created this run.

**authSessionId** `string | null` *required*

The AuthSession the run used.

**workspaceId** `string` *required*

The workspace ID of the project that the run belongs to.

**project** `object` *required*

Details of the project that the run belongs to.

**id** `string` *required*

The project UUID.

**name** `string` *required*

The project name.

**authSession** `object`

Details of the auth   used in this run.

**id** `string` *required*

The auth session ID.

**projectJob** `object`

Present when this Run is part of a Job. Contains information about the Job that triggered it.

**id** `string` *required*

Job ID.

**projectJobRun** `object`

Present when this Run is part of a Job. Contains information about the JobRun that triggered it.

**id** `string` *required*

JobRun ID.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.