-
Notifications
You must be signed in to change notification settings - Fork 0
feat(mcp): bulk_update_order_status returns per-order outcomes #34
Copy link
Copy link
Open
Labels
area/clientTouches statuspro_public_api_client/Touches statuspro_public_api_client/area/mcpTouches statuspro_mcp_server/ onlyTouches statuspro_mcp_server/ onlyarea/specTouches docs/statuspro-openapi.yamlTouches docs/statuspro-openapi.yamlpriority/p0Blocks reconciliation workflow todayBlocks reconciliation workflow todaytheme/tool-surface-redesignMCP tool surface redesign initiativeMCP tool surface redesign initiativetype/breakingBreaking change for an MCP/client consumerBreaking change for an MCP/client consumer
Metadata
Metadata
Assignees
Labels
area/clientTouches statuspro_public_api_client/Touches statuspro_public_api_client/area/mcpTouches statuspro_mcp_server/ onlyTouches statuspro_mcp_server/ onlyarea/specTouches docs/statuspro-openapi.yamlTouches docs/statuspro-openapi.yamlpriority/p0Blocks reconciliation workflow todayBlocks reconciliation workflow todaytheme/tool-surface-redesignMCP tool surface redesign initiativeMCP tool surface redesign initiativetype/breakingBreaking change for an MCP/client consumerBreaking change for an MCP/client consumer
Problem
Today
bulk_update_order_statusreturns:```python
{
"confirmed": True,
"success": is_success(response), # 202 Accepted = True
"status_code": 202,
"note": "Bulk updates are queued and processed asynchronously.",
}
```
A reconciliation run that bulk-updates 50 orders has no way to know which 47 actually moved to the new status vs which 3 hit a viable-status check or rate-limit and silently failed. This makes the tool useless for any real "fire 50 updates and report results" workflow — the agent has to follow up with 50 individual
get_ordercalls to verify each, defeating the bulk path.Two implementation paths (choice depends on #30 / F3)
Path A — server returns a job_id
If the server's 202 response includes a
job_idand there's aGET /jobs/{id}or similar endpoint:job_idin the bulk return typeget_bulk_status_job(job_id)that polls the job and returns per-order outcomesbulk_update_order_statuscould synchronously poll until the job completes (with a timeout) and return the per-order outcomes inline — agent ergonomics > async ceremonyPath B — per-order results inline
If the server returns per-order results in the 202 response body:
BulkStatusUpdateResponseschema to include the arrayBulkUpdateOutcomeper orderAcceptance
Breaking change
The current return shape changes. Callers reading
result["success"]will see a different semantic — "request was accepted" no longer implies "all 50 moved." Callable asfeat(mcp)!.Depends on
Tracking
Part of epic #31, Tier 1.