Reassign a Counted Annotation
PATCH/v1/api/quality/inspection/shipment-issue/annotation/reassign
Manually reassigns an already-detected, already-counted annotation straight to a different, existing line item — no issue is involved. This backs the "flag an already-counted instance" flow off the product-count popup (the pipeline originally matched the annotation correctly, so it never raised an issue for it): when the operator types a sku that matches a real line item on the manifest, there's nothing to review, just a direct correction.
Decrements the annotation's current line item and increments the target in a single
internal post-id event — quality's own counting logic decrements whatever the unit
previously counted toward before incrementing the new one, so a same-call
real-to-real transition is safe.
annotation_id alone identifies the exact annotation (a single monotonic counter per
shipment, never reused across images/units) — shipment_id only says which shipment to
look it up in; the unit and unit session it belongs to are resolved server-side from the
annotation's own image, not required from the caller.
If the entered sku does not match any line item, use
POST /shipment-issue/annotation/flag-wrong-product instead — that's a genuine
off-manifest case and creates a real wrong_product issue for review.
Auth Required
Required Permissions:
quality.inspection.shipment:execute("Quality Inspection Shipment Execute")
Request
Responses
- 200
- 400
- 401
- 403
- 500
Product reassigned successfully
Bad Request. The request was invalid or cannot be otherwise served.
Unauthorized. User is not authenticated or session is invalid.
Forbidden. User does not have the required permissions.
Internal Server Error