# Schedule and track production

> Create jobs on a sales order, schedule them, move them through statuses, and manage their tasks. Read the production board and calendars.

Web page: https://developer.yoprint.com/guides/jobs-and-production/

**Read first:** [Production](https://developer.yoprint.com/how-yoprint-works/production.md), for jobs, tasks, task presets, the two kinds of status and the schedule.

A **job** is one piece of production work on a sales order or quote, and its **tasks** are the steps it takes. In the API, tasks are the job's **work pipeline**, and each comes from a **task preset** (the API calls it a pipeline).

## 1. List an order's jobs

`GET /v2/api/store/{team_slug}/v2/sales_order/{hash_id}/job` [List the jobs of a sales order or quote](https://developer.yoprint.com/reference/jobs/v2-job-index-for-order.md)

This list isn't paginated: you get every job on the order.

## 2. Create a job

`POST /v2/api/store/{team_slug}/v2/sales_order/{hash_id}/job` [Add a job to a sales order or quote](https://developer.yoprint.com/reference/jobs/v2-job-store.md)

```bash
curl https://secure.yoprint.com/v2/api/store/your-team/v2/sales_order/V4keXwwxMQyXw7/job \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Accept: application/json" \
  -H "X-Yoprint-Decimal-Format: exact-v1" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "Front logo tees",
    "is_rush": false,
    "pipeline": [
      {
        "action": "create",
        "pipeline_id": "PtawtCkfVsaZR7",
        "status_id": "uU6YdSxsWUfrbN",
        "start_date": "2026-11-04T05:00:00Z",
        "due_date": "2026-11-05T04:59:59Z",
        "position": 1
      }
    ]
  }'
```

The answer is the new job. Shortened:

```json
{
  "status": 200,
  "success": true,
  "data": {
    "id": "HuhbGhG57Z7Qyi",
    "scoped_id": "JOB-1003",
    "name": "Front logo tees",
    "order_id": "V4keXwwxMQyXw7",
    "is_rush": false
  }
}
```

Keep `data.id`, the job's id: lines and later job calls use it. `scoped_id` is the job number people see, not an id.

On some older orders, neither a draft nor published, the answer is `200` with `"success": false` and `action_not_allowed`, and no job is made. See [Errors](https://developer.yoprint.com/concepts/errors.md#known-exceptions).

- Every field is optional. `name` is the job's name, and `is_rush` marks it as rush.
- `pipeline` adds tasks at once. Each entry needs `"action": "create"`, a `pipeline_id` (the task preset), and one of that task preset's `status_id`s. Its dates are both set or both left out.
- `service` adds decoration services with their print locations (each entry also needs `"action": "create"`).
- The order can be a draft or published.

Get task preset (pipeline) ids, and each one's statuses, from the settings:

`GET /v1/api/store/{team_slug}/setting/pipeline` [List task presets](https://developer.yoprint.com/reference/task-presets/v1-pipeline-index.md)

`GET /v1/api/store/{team_slug}/setting/status/pipeline/{hash_id}` [List the task statuses of a task preset](https://developer.yoprint.com/reference/statuses/v1-status-list-pipeline.md)

Then put lines in the job with `"job": { "type": "linked", "id": "<job id>" }`. Every line on the job takes its decoration price. Line item prices, costs and quantities are decimal pairs (such as `{ "value": 1250, "dp": 2 }` for 12.50). See [Add line items](https://developer.yoprint.com/guides/line-items.md) and [Money and quantities](https://developer.yoprint.com/concepts/money-and-quantities.md).

To start from a job preset instead, use the operation below. The API calls a job preset a job template. The job copies the preset's name, note, services, tasks, files and teammates:

`POST /v2/api/store/{team_slug}/v2/sales_order/{hash_id}/job_template` [Add a job from a job template](https://developer.yoprint.com/reference/jobs/v2-job-create-with-template.md)

## 3. Schedule a job

Schedule in whole days in the person's timezone, as the web app does: from 00:00:00 on the first day to 23:59:59 on the last, sent as UTC. For Tuesday 3 to Thursday 5 November 2026 in America/New_York (UTC−5 once daylight saving ends on 1 November), that's `2026-11-03T05:00:00Z` to `2026-11-06T04:59:59Z`. See [Dates and times](https://developer.yoprint.com/concepts/dates-and-times.md).

`PUT /v2/api/store/{team_slug}/v2/job/{hash_id}/update_prod_date` [Schedule a job](https://developer.yoprint.com/reference/jobs/v2-job-update-prod-date.md)

```json
{ "start_date": "2026-11-03T05:00:00Z", "due_date": "2026-11-06T04:59:59Z" }
```

- Send both dates, or both as `null` to unschedule. One without the other is refused.
- `due_date` can't be before `start_date`.
- Scheduling a job moves its dated tasks with it.

## 4. Change a job's status

`PUT /v2/api/store/{team_slug}/v2/job/{hash_id}/status` [Change a job's status](https://developer.yoprint.com/reference/jobs/v2-job-change-status.md)

```json
{ "status_id": "kqXZfsLxjX2mpo" }
```

- The order must be published.
- `status_id` is one of the team's job statuses:

`GET /v1/api/store/{team_slug}/setting/status/job` [List job statuses](https://developer.yoprint.com/reference/statuses/v1-status-list-job.md)

A status change fires `job.status_changed`.

### Move a job to the next status

A job's stage in the shop is its status. Tasks have their own statuses, for the steps inside the job. Move those when your shop tracks each step.

1. Read the job, and note its `status_id`:

   `GET /v2/api/store/{team_slug}/v2/sales_order/{hash_id}/job/{job_id}` [Get one job of an order](https://developer.yoprint.com/reference/jobs/v2-job-show.md)

2. List the job statuses. They aren't sorted: sort them by `position` yourself, and find the one after the job's current status.

   `GET /v1/api/store/{team_slug}/setting/status/job` [List job statuses](https://developer.yoprint.com/reference/statuses/v1-status-list-job.md)

3. Change the job's status to it, then check that the answer has `"success": true`. On a draft order, the answer is `200` with `"success": false`.

## 5. Work with tasks

`GET /v2/api/store/{team_slug}/v2/job/{hash_id}/work_pipeline` [List the tasks of a job](https://developer.yoprint.com/reference/tasks/v2-job-work-pipeline-index-for-job.md)

`POST /v2/api/store/{team_slug}/v2/job/{hash_id}/work_pipeline` [Add a task to a job](https://developer.yoprint.com/reference/tasks/v2-job-work-pipeline-store.md)

Change a task's status, dates or assignee:

`PUT /v2/api/store/{team_slug}/v2/work_pipeline/{hash_id}/status` [Change a task's status](https://developer.yoprint.com/reference/tasks/v2-job-work-pipeline-change-status.md)

`PUT /v2/api/store/{team_slug}/v2/work_pipeline/{hash_id}` [Update a task](https://developer.yoprint.com/reference/tasks/v2-job-work-pipeline-update.md)

`PUT /v2/api/store/{team_slug}/v2/work_pipeline/{hash_id}/assign` [Assign or unassign a person on a task](https://developer.yoprint.com/reference/tasks/v2-job-work-pipeline-assign.md)

Dating a task resets its job's span to cover its tasks.

## 6. Read the board and calendars

Across all orders:

`POST /v1/api/store/{team_slug}/job/filter` [Filter jobs](https://developer.yoprint.com/reference/jobs/v1-job-filter.md)

`POST /v1/api/store/{team_slug}/work_pipeline/filter` [Filter tasks](https://developer.yoprint.com/reference/tasks/v1-work-pipeline-filter.md)

`POST /v1/api/store/{team_slug}/production_control/filter` [Read the production control calendar](https://developer.yoprint.com/reference/production-control/v1-production-control-filter.md)

For a calendar, by date range. The job calendar pages through the range with `page`, up to 1,000 rows a page, or returns up to 1,200 rows at once without it. The task calendar never pages: it returns up to 1,200 tasks.

`POST /v1/api/store/{team_slug}/job/calendar` [List jobs in a date range](https://developer.yoprint.com/reference/jobs/v1-job-calendar.md)

`POST /v1/api/store/{team_slug}/work_pipeline/calendar` [List tasks in a date range](https://developer.yoprint.com/reference/tasks/v1-work-pipeline-calendar.md)

## 7. Rush, clone and reorder

To mark one job as rush, update it with `"is_rush": true`:

`PUT /v2/api/store/{team_slug}/v2/job/{hash_id}` [Update a job](https://developer.yoprint.com/reference/jobs/v2-job-update.md)

`PUT /v2/api/store/{team_slug}/v2/job/{hash_id}/clone` [Copy a job](https://developer.yoprint.com/reference/jobs/v2-job-clone.md)

`PUT /v2/api/store/{team_slug}/v2/sales_order/{hash_id}/job/rearrange` [Reorder the jobs of a sales order or quote](https://developer.yoprint.com/reference/jobs/v2-job-rearrange.md)

To mark every job on an order as rush, run the order's `mark_all_job_as_rush` action (`mark_order_as_rush` marks the order too):

`PUT /v2/api/store/{team_slug}/v2/sales_order/{order_unique_key}/action/{action_name}` [Run an action on a sales order or quote](https://developer.yoprint.com/reference/sales-orders/v2-order-single-action.md)

## Printable documents

Job sheets, labels and lists for the shop floor:

`POST /v1/api/store/{team_slug}/job/export_job_detail` [Download job details (PDF)](https://developer.yoprint.com/reference/jobs/v1-job-export-job-detail.md)

`POST /v1/api/store/{team_slug}/job/export_job_label` [Download job labels (PDF)](https://developer.yoprint.com/reference/jobs/v1-job-export-job-label.md)

`POST /v1/api/store/{team_slug}/job/export_job_list` [Download a job list (PDF)](https://developer.yoprint.com/reference/jobs/v1-job-export-job-list.md)

## Pitfalls

- **Include `action: "create"` on nested job entries.** When creating a job, entries in `pipeline`, `service`, and `mockup` without `action: "create"` are skipped silently. A `production_file` entry without `action` is refused with `422`.
- **Use the v2 job operations.** The older v1 operations to show a job and change its status no longer work.
- **Both dates or neither.** Send both dates, or both as `null` to unschedule. One alone is refused.
- **Dates are UTC.** Convert the shop's day boundaries to UTC before you send them.
- **Statuses belong to a kind.** A job takes a job status, and a task takes a status of its own pipeline. A sales order status is refused.
- **Job status changes need a published order.** On a draft they answer `200` with `"success": false`. Task statuses can change on a draft.
