workflows

HTTP 202 in an automation: check completion before the next step

An API accepted a request, but the job may still be running. Track the operation and confirm its final result before downstream work.

An API response of 202 Accepted means the request was accepted for processing. It does not prove that the job is finished. When a later action depends on the outcome, keep the operation reference, follow the provider’s documented status path, and wait for a confirmed final result.

Short answer

For some Microsoft Graph long-running actions, a 202 response includes a Location header for a status monitor. That monitor may still report work in progress; the result comes later. An Azure Automation webhook can accept a request and return the ID of a queued job. Those are provider-specific contracts. Your endpoint may use a different monitor, event or set of status values.

Downstream release card

Observed state Evidence to retain Downstream decision
Accepted, no final state Operation ID and documented status route Wait; do not mark complete or resubmit automatically
Running Status and time of last check; provider’s suggested cadence Keep waiting without excessive polling
Succeeded Terminal state and, where supplied, result location or resource read Check the required result, then release the dependent action
Failed Terminal state and safe error details Stop the dependency; fix the cause before another request
Unknown Last response, operation ID and an operational review deadline Hold the sequence for investigation; do not assume success or repeat a possible side effect

This is a Pulse editorial decision card, not a Microsoft feature. Keep only the details needed to trace the job. In the Graph copy example, the monitor URL is short-lived and can be accessed without authentication: store it in a restricted location and show only a safe reference on a shared dashboard. Avoid storing tokens, personal records or entire request bodies there.

Follow the job without running it twice

  1. Read the endpoint contract. Confirm what 202 means for this operation, where the job ID and monitor appear, and whether the same endpoint can also complete synchronously.
  2. Correlate the original request. Store the operation reference beside the workflow item. A pending status is not a reason to create a second job.
  3. Use the documented completion signal. Poll a monitor, wait for a final event, or read the resource as the provider directs. Follow its polling guidance. An expired or unavailable monitor means the outcome is unknown until checked elsewhere.
  4. Separate technical completion from the needed business result. In the Graph copy example, the monitor moves from inProgress to completed and provides the copy’s resource ID. The application can then read the copied item. Other endpoints have their own states, including failure; follow that endpoint’s contract.
  5. Release or stop. Only continue after the state and result your workflow requires have been confirmed. Failure and uncertainty need correction or human review.

Illustrative example for a small team

A team in the US, Canada or the UK starts an asynchronous file copy through an API and plans to tell a colleague when the copy is available. A 202 response alone cannot trigger the message. The workflow stores the job reference, checks the documented monitor, confirms success and the copied file, then sends the message. If the monitor fails, the message stays pending. This is an example, not an integration Pulse has run.

When to stop automation

If the API offers no reliable way to determine the outcome and retrying may create a duplicate, hold the request for a manual check. If the response is a batch with per-item results, use the batch result card. For Make webhook receipt, see the Make queue guide. For repeated incoming events, see duplicate webhook controls.

Sources