---
title: "Assign"
method: POST
path: "/workspaces/{wid}/batches/{bid}/orders/assignments"
tags: ["orders"]
---

# Assign

`POST /workspaces/{wid}/batches/{bid}/orders/assignments`

## Request

- Base URL: `https://app.linerecon.com` (the document declares no server; this is the origin it was published from)
- URL: `https://app.linerecon.com/workspaces/{wid}/batches/{bid}/orders/assignments`
- Auth: none declared

Pair a Needs pairing document with an order, or keep it as its own order. Writes the
next comparison version and starts matching the order's lines (`rematch_run_id`).

## Path parameters

- `wid` string, uuid, required
- `bid` string, uuid, required

## Request body

- AssignDocument
  - `request_id` string, uuid, required
  - `base_version` integer, required
  - `document_id` string, uuid, required
  - `order_id` union, required
    - string, uuid
    - 'own'

## Response `202`

Successful Response

- OrderAssignmentView
  - `comparison_version_id` string, uuid, required
  - `version` integer, required
  - `rematch_run_id` string, uuid, nullable, required
  - `match_limit` boolean, required
  - `noop` boolean, required

## Other responses

- `400`: Bad Request
- `401`: Unauthorized
- `403`: Forbidden
- `404`: Not Found
- `409`: Conflict
- `413`: Content Too Large
- `422`: Unprocessable Content
- `429`: Too Many Requests
- `503`: Service Unavailable

---

[API](https://skmtc.dev/linerecon/apis/linerecon-api.md) · [All operations](https://skmtc.dev/linerecon/apis/linerecon-api/llms.txt) · [OpenAPI document](https://skmtc.dev/linerecon/apis/linerecon-api/revisions/0650f53a4249?raw)
