---
title: "Closes a completed job."
method: POST
path: "/routing/jobs/{jobId}/assignments/{assignmentId}:close"
---

# Closes a completed job.

`POST /routing/jobs/{jobId}/assignments/{assignmentId}:close`

## Request

- Base URL: `{endpoint}`
- URL: `{endpoint}/routing/jobs/{jobId}/assignments/{assignmentId}:close`
- Auth: OAuth 2
  - Authorization code: `https://login.microsoftonline.com/common/oauth2/authorize`
  - Token URL: `https://login.microsoftonline.com/common/oauth2/token` scopes: `https://communication.azure.com/.default`

Closes a completed job.

## Path parameters

- `jobId` string, required
- `assignmentId` string, required

## Query parameters

- `api-version` string, required

## Request body

- CloseJobOptions: Request payload for closing jobs
  - `dispositionCode` string: Indicates the outcome of a job, populate this field with your own custom values.
  - `closeAt` string, date-time: If not provided, worker capacity is released immediately along with a JobClosedEvent notification. If provided, worker capacity is released along with a JobClosedEvent notification at a future time in UTC.
  - `note` string: A note that will be appended to a job's Notes collection with the current timestamp.

## Response `200`

The request has succeeded.

- CloseJobResult: Response payload from closing a job.

## Other responses

- `default`: An unexpected error response.

## Changes

- **2026-07-13** `fe2019dcc5b0`: 1 info
  - endpoint added
- **2022-05-05** `8cbeaf5a7ce3`: 1 breaking
  - api path removed without deprecation

[Operation history](https://skmtc.dev/azure/apis/communication-jobrouter/changes/routing/jobs/:jobId/assignments/:assignmentId:close/post.md)

---

[API](https://skmtc.dev/azure/apis/communication-jobrouter.md) - [All operations](https://skmtc.dev/azure/apis/communication-jobrouter/llms.txt) - [OpenAPI document](https://skmtc.dev/azure/apis/communication-jobrouter/revisions/c06e8f55d8b7?raw)
