B2B feature. Learn more
placeOrderForPurchaseOrder mutation
The placeOrderForPurchaseOrder
mutation converts an approved purchase order to an order. If the request is successful, the status of the purchase order is ORDER_PLACED
.
If you want to place a purchase order using the cart ID instead of the purchase order UID, use the placePurchaseOrder
mutation.
Syntax
Copied to your clipboardmutation {placeOrderForPurchaseOrder(input: PlaceOrderForPurchaseOrderInput!) {PlaceOrderForPurchaseOrderOutput}}
Reference
The placeOrderForPurchaseOrder
reference provides detailed information about the types and fields defined in this mutation.
Example usage
The following example places an order based on the approved purchase order.
Request:
Copied to your clipboardmutation {placeOrderForPurchaseOrder(input: {purchase_order_uid: "MQ=="}) {order {number}}}
Response:
Copied to your clipboard{"data": {"placeOrderForPurchaseOrder": {"order": {"number": "000000001"}}}}