question

cowboysaif avatar image
cowboysaif asked

Error 429 on a simple hosted checkout request

Hello,

We have a simple webpage that redirects to hosted checkout url. To isolate the problem, i have run it via postman: https://www.postman.com/cowboysaif/workspace/demo/request/11944295-fa8c1a68-e18f-4e4c-8b3f-ccc8375bdc34

its retuning 429 although its a simple request. Same code in sandbox working fine. Please help

Here is the code in js :

var myHeaders = new Headers();
myHeaders.append("X-Clover-Merchant-Id", "TK2KTFVHQEQA1");
myHeaders.append("Authorization", "Bearer 2a22188c-e770-4aac-5a41-c0a37513b3ef");
myHeaders.append("Content-Type", "application/json");

var raw = JSON.stringify({
  "customer": {
    "firstName": "Boyd",
    "lastName": "Glover",
    "email": "shane@tellus.business"
  },
  "shoppingCart": {
    "lineItems": [
      {
        "price": "100",
        "name": "Payment for Order 37",
        "unitQty": 1
      }
    ],
    "total": "100"
  }
});

var requestOptions = {
  method: 'POST',
  headers: myHeaders,
  body: raw,
  redirect: 'follow'
};

fetch("https://www.clover.com/invoicingcheckoutservice/v1/checkouts", requestOptions)
  .then(response => response.text())
  .then(result => console.log(result))
  .catch(error => console.log('error', error));


REST API
10 |2000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

0 Answers

·

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Welcome to the
Clover Developer Community