API Reference
Vendor shipments
Auto-builds tracking_url from COURIER_OPTIONS template if not provided. Sets shipped_at = now(). Calls tryAdvanceParent. Email + Phase-17 e-invoice sync stay legacy — flag should be left off in prod until ported.
Authorization
better-auth.session_token better-auth.session_token<token>
In: cookie
Path Parameters
id*string
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
curl -X POST "https://example.com/api/v1/vendor/shipments/string/ship" \ -H "Content-Type: application/json" \ -d '{ "courier": "string", "trackingId": "string" }'Empty
409 if already delivered. Sets delivered_at = now(). Calls tryAdvanceParent. Email stays legacy.
Authorization
better-auth.session_token better-auth.session_token<token>
In: cookie
Path Parameters
id*string
Response Body
curl -X POST "https://example.com/api/v1/vendor/shipments/string/deliver"Empty
400 if status outside paid|processing. Releases stock per item, bumps payments.refunded_amount on parent, calls tryAdvanceParent. Email stays legacy.
Authorization
better-auth.session_token better-auth.session_token<token>
In: cookie
Path Parameters
id*string
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
curl -X POST "https://example.com/api/v1/vendor/shipments/string/cancel" \ -H "Content-Type: application/json" \ -d '{}'Empty
