These developer pages document how to make use of Printenbind's RESTFUL API (from now on: "API").
With this API, you are able to create shopping orders, place articles from Printenbind in it, and actually order those articles under your name to your specified address. Naturally, you are able to retrieve the data of any order/article/delivery data you placed.
With these functionalities we hope to encourage developers to integrate their application with that of Printenbind!
For any request to any of the endpoints in this API, you are required to set the
Authorization HTTP header with as value your API token.
You are able to generate your API token at your profile page.
Failing to provide a valid API token will result in your request being denied by the API. If this would be the case, you would receive a
401 UNAUTHORIZED response error.
Example Authorization header
An example of what the
Authorization HTTP header should look like:
This API implements a method of limiting the amount of requests a client can make on the API.
Naturally, this is simply to prevent excessive spam on our servers. Clients that regularly hit and ignore the rate limit will have their API key temporarily revoked.
It's possible to execute requests on all endpoints combined up to 10 times per second. Should it happen that you hit the limit of the amount of requests you can make, then you would receive a
429 Too many requests response error.
Rate limit headersIn all responses of this API, the following rate limit headers are set:
|X-RateLimit-Limit||The amount of requests you are able to make per second.|
|X-RateLimit-Remaining||The amount of requests remaining you are able to make in the current second.|
Rate limit headers exampleAn example of the headers that a response (in this example, the response of a order creation) could have:
date: Fri, 15 Dec 2017 12:49:50 GMT server: Apache/2.4.27 (Win32) PHP/7.1.9 OpenSSL/1.0.2l x-ratelimit-remaining: 7 x-ratelimit-limit: 10 content-type: text/html location: api/orders/110 connection: Keep-Alive keep-alive: timeout=5, max=100 content-length: 0 status: 201 Created response-text: