# Subscribe to Query Job Platform Events (Beta)

Use the standard platform event BulkApi2JobEvent to get query job status updates and begin downloading results before the query job completes.

:::note
Bulk API V2 query standard platform events is a pilot or beta service that is subject to the Beta Services Terms at [Agreements - Salesforce.com](https://www.salesforce.com/company/legal/agreements/) or a written Unified Pilot Agreement if executed by Customer, and applicable terms in the [Product Terms Diretctory](https://ptd.salesforce.com/?\_ga=2.247987783.1372150065.1709219475-629000709.1639001992). Use of this pilot or beta service is at the Customer's sole discretion.
:::

To enable this beta, follow these steps. You must have either the Modify All Data or the Customize Application permission.

1. From Setup, in the Quick Find box, enter `User Interface`, and then select **User Interface**.

2. On the User Interface page, select **Enable Salesforce Platform Bulk API 2.0 Query Partial Download and Job Completion Events (Beta)**.

   :::note
   Selecting this item asserts that you accept the Beta Services Terms provided at the [Agreements and Terms](https://www.salesforce.com/company/legal/agreements).
   :::

3. Choose a supported subscriber.

   Use the `/event/BulkApi2JobEvent` channel to subscribe to Bulk API 2 query job platform events when configuring a subscription. See [Subscribing to Platform Events](https://developer.salesforce.com/docs/atlas.en-us.platform_events.meta/platform_events/platform_events_subscribe.htm).

4. Start a Bulk API 2 query job.

   Your code can process events associated with the job ID in the response body. See [Create a Query Job](/docs/platform/api-asynch/guide/query-create-job.md).

This event indicates job status. The unique ID in `JobIdentifier` is the same ID that you get from the query job response body.

```json
{
  "Type": "JOB_STATE",
  "JobIdentifier": "750xx000004UeCCB",
  "JobState": "InProgress",
  "ResultType": null,
  "ResultUrl": null
}
```

This event indicates that a set of results is available. Your client uses the unique URL in `ResultUrl` to get the results.

```json
{
  "Type": "RESULT",
  "JobIdentifier": "750xx000004UeCCB",
  "JobState": "InProgress",
  "ResultType": "PARTIAL",
  "ResultUrl": "https://mydomain.salesforce.com/services/data/v63.0/jobs/query/750xx000004UeCCB/results?locator:AOTUALft490873ALSH353w4oithw404FKJ"
}
```

This event indicates that only one set of results remains. Your client uses the `ResultUrl` URL to get the last set of results.

```json
{
  "Type": "RESULT",
  "JobIdentifier": "750xx000004UeCCB",
  "JobState": "JobComplete",
  "ResultType": "FINAL",
  "ResultUrl": "https://mydomain.salesforce.com/services/data/v63.0/jobs/query/750xx000004UeCCB/results?locator:aSdEft490873ALSH353w4oithw404jKlM"
}
```

**See Also**

- [*Platform Events Developer Guide*: BulkApi2JobEvent](https://developer.salesforce.com/docs/atlas.en-us.platform_events.meta/platform_events/sforce_api_objects_bulkapi2jobevent.htm)
- [*Salesforce Developers Blog*: Introducing Events and Partial Downloads in Bulk API 2.0](https://developer.salesforce.com/blogs/2025/01/introducing-events-and-partial-downloads-in-bulk-api-2-0)
