Update order
PATCH
/v2/checkout/orders/{order_id}
CREATED
or APPROVED
status. You cannot update an order with the COMPLETED
status.To make an update, you must provide a
reference_id
. If you omit this value with an order that contains only one purchase unit, PayPal sets the value to default
which enables you to use the path: "/purchase_units/@reference_id=='default'/{attribute-or-object}"
.Note: For error handling and troubleshooting, see Orders v2 errors.Patchable attributes or objects:
Attribute | Op | Notes |
---|---|---|
intent | replace | |
payer | replace, add | Using replace op for payer will replace the whole payer object with the value sent in request. |
purchase_units | replace, add | |
purchase_units[].custom_id | replace, add, remove | |
purchase_units[].description | replace, add, remove | |
purchase_units[].payee.email | replace | |
purchase_units[].shipping.name | replace, add | |
purchase_units[].shipping.address | replace, add | |
purchase_units[].shipping.type | replace, add | |
purchase_units[].soft_descriptor | replace, remove | |
purchase_units[].amount | replace | |
purchase_units[].invoice_id | replace, add, remove | |
purchase_units[].payment_instruction | replace | |
purchase_units[].payment_instruction.disbursement_mode | replace | By default, disbursement_mode is INSTANT . |
purchase_units[].payment_instruction.platform_fees | replace, add, remove |
请求参数
Path 参数
order_id
string
必需
示例值:
{{order_id}}
Header 参数
Content-Type
string
必需
示例值:
application/json
PayPal-Request-Id
string
必需
示例值:
{{$guid}}
Body 参数application/json