---
title: "Create assignments for multiple credentialing workflows"
method: POST
path: "/credentialing-workflows/assignments"
tags: ["CredentialingWorkflow"]
---

# Create assignments for multiple credentialing workflows

`POST /credentialing-workflows/assignments`

Creates assignments for multiple credentialing workflows in a single operation. Workflows are evenly distributed across the provided user IDs using round-robin distribution. Each workflow is processed independently, and results include both successful and failed assignments.

## Headers

- `tenant-id` string, required

## Request body

- BulkCreateAssignmentRequest — Request to create assignments for multiple credentialing workflows
  - `workflowIds` string[] — List of credentialing workflow IDs to assign. Required when isSelectAll is false. Ignored when isSelectAll is true (workflow IDs will be fetched using the filter).
  - `assignedTo` string[], required — List of user IDs to assign workflows to. Workflows will be evenly distributed across these users. If empty array, all workflows will be unassigned (assignedTo set to null).
  - `reason` string — Optional reason for the assignment
  - `filter` string — Filter criteria as JSON string (URL encoded). Used to fetch workflow IDs when isSelectAll is true. See GET /credentialing-workflows endpoint documentation for filter format.
  - `isSelectAll` boolean — If true, fetch all workflow IDs matching the filter criteria instead of using workflowIds. When true, filter parameter is required and workflowIds will be ignored.

## Response `200`

Bulk assignment operation completed. Check successful and failed arrays for individual results.

- BulkAssignmentResponse — Response containing results of bulk assignment operation
  - `successful` AssignmentResult[] — List of successful assignments
    - `workflowId` string — ID of the credentialing workflow
    - `assignment` AssignmentHistoryResponse — Response containing assignment history for a credentialing workflow
      - `workflowId` string — Unique identifier for the credentialing workflow
      - `tenantId` string — ID of the tenant
      - `tenantPractitionerId` string — ID of the tenant practitioner
      - `assignments` AssignmentEntry[] — Assignment history entries, with latest at index 0
        - `assignedFrom` string — User ID the assignment changed from
        - `assignedTo` string — User ID the assignment changed to
        - `assignedBy` string — User ID who made the assignment change
        - `assignedOn` string — Timestamp when the assignment was changed
        - `reason` string — Reason for the assignment change
    - `error` string — Error message if assignment failed
  - `failed` AssignmentResult[] — List of failed assignments with error details
    - `workflowId` string — ID of the credentialing workflow
    - `assignment` AssignmentHistoryResponse — Response containing assignment history for a credentialing workflow
      - `workflowId` string — Unique identifier for the credentialing workflow
      - `tenantId` string — ID of the tenant
      - `tenantPractitionerId` string — ID of the tenant practitioner
      - `assignments` AssignmentEntry[] — Assignment history entries, with latest at index 0
        - `assignedFrom` string — User ID the assignment changed from
        - `assignedTo` string — User ID the assignment changed to
        - `assignedBy` string — User ID who made the assignment change
        - `assignedOn` string — Timestamp when the assignment was changed
        - `reason` string — Reason for the assignment change
    - `error` string — Error message if assignment failed
  - `totalProcessed` integer — Total number of workflows processed
  - `successCount` integer — Number of successful assignments
  - `failureCount` integer — Number of failed assignments

## Other responses

- `400` — Invalid request data
- `401` — Unauthorized - Authentication required
- `403` — Forbidden - User does not have required permissions
- `500` — Internal Server Error - An unexpected error occurred

---

[API](https://skmtc.net/certifyos/apis/certify-api-layer.md) · [All operations](https://skmtc.net/certifyos/apis/certify-api-layer/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/certifyos/certify-api-layer/revisions/3d27e9019c7b/schema)
