Request is not well-formed, syntactically incorrect, or violates schema.

liufengsheng
New Community Member
Client error: `POST https://api-m.sandbox.paypal.com/v2/checkout/orders` resulted in a `400 Bad Request` response:\n{\"name\":\"INVALID_REQUEST\",\"message\":\"Request is not well-formed, syntactically incorrect, or violates schema.

 

{
"intent": "CAPTURE",
"purchase_units": [
{
"reference_id": "2cd892c0-73f9-4156-85bd-4a1420f8fbe4",
"amount": {
"currency_code": "USD",
"value": 9.90,
"breakdown": {
"item_total": 9.90
}
},
"items": [
{
"name": "Video Converter(Mac)",
"unit_amount": {
"currency_code": "USD",
"value": 9.90
},
"quantity": 1
}
]
}
]
}

Login to Me Too
1 REPLY 1

Kavyar
Moderator
Moderator

Good day @liufengsheng 

 

Thank you for posting to the PayPal community.

 

I understand that you are currently encountering an error with your API request. This type of error usually arises when there are problems with the formatting of the API request, as it may not adhere to the necessary standards.

 

To resolve this issue, I kindly suggest to review your "Create Order" API request payload and make sure your passing valid request to PayPal system. Please refer the guide link below for further assistance:

 

https://developer.paypal.com/docs/api/orders/v2/#orders_create 

 

If your still facing issues, please create an MTS ticket via - https://www.paypal-support.com/s/?language=en_US  with the detailed information and error details.

 

Sincerely,

Kavya

PayPal MTS

 

If this post or any other was helpful, please enrich the community by giving kudos or accepting it as a solution.

 

Login to Me Too

Haven't Found your Answer?

It happens. Hit the "Login to Ask the community" button to create a question for the PayPal community.