For a deeper look into our World Check One API, look into:

Overview |  Quickstart |  Documentation |  Downloads

question

Upvotes
Accepted
18 2 3 8

Bulk records execution Problem in WCO API

When we are sending bulk records(Ex:250) using API to WCO, we are able to create 135 records in WCO but after 135 records we are getting 401 - UnAuthorized error. Is there any time limit for the API connection or API Keys.

world-checkworld-check-onetime-out
icon clock
10 |1500

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

Upvotes
Accepted
4.2k 7 5 6

@manjusha.batchu

I assume you are sending each request concurrently because we do not have the functionality of sending bulk request.

No we do not have a time limit for the API connection or API key as each request establishes a new connection.

The reason you may be getting a 401 is because the date header value you are sending would be getting outdated after 135 requests. The dateheader value sent in the request should be exact as per the GMT clock, although we allow a leeway of 40 to 50 seconds on the timestamp but anything more than that we consider the date header value to be expired and send a 401 to avoid replay attack.

Kindly send a fresh date header value for each request instead of using the same timestamp for all your concurrent request. This can be done by defining a new date header value for each request instead of using the same dateheader value for every concurrent request.

icon clock
10 |1500

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

Upvotes
18 2 3 8

Hello @Irfan,

Thank you so much for your reply. Now i am able to send bulk request at a time with out hitting any unauthorised access after sending the date value header as GMT for each request .

icon clock
10 |1500

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

@manjusha.batchu

That's great news and I am glad to hear that the API calls are being sent concurrently.

Kindly accept the answer so that our other users can get benefitted by your question.

Click below to post an Idea Post Idea