Why the watermark is present when "sandbox" is set to false?
The watermark is present on two reasons :
When the sandbox parameter is set to True
When you are not authenticated
The watermark is only enforced in a unauthenticated account. Free users can have 50 conversions without watermark and without having to upgrade to a plaid plan.
This article explains how to be able to convert without the watermark
Now, PDFShift identifies you by using a specific header named "X-API-Key
" with your API Key as the value.
If that header is not present, your request will fallback to the unauthenticated mode, adding the watermark.
One way to be sure you are sending the proper authentication header is to try to load your credits. Only an authenticated user can retrieve their usage.
To do so, simply replace the call to the API with a GET
request to https://api.pdfshift.io/v3/credits/usage
.
If you are sending the appropriate X-API-Key
header, you will get a JSON response containing your usage and total of available credits.
Otherwise, you will get a 401 or 403 error depending on how you sent the API key.
Depending on your programming language, you can pass your API key when calling our servers by adding the specific header entry. For instance, in python:
response = requests.post(
'https://api.pdfshift.io/v3/convert/pdf',
headers={'X-API-Key': 'YOUR_API_KEY'},
json={'source': '...'}
)
Previously, PDFShift's API was using the "Basic Auth" mechanism to identify the API Key, but this was causing troubles to properly authenticate a request.
As of 2025-05-06, we moved to the "X-API-Key" header to simplify the mechanism and ensure no confusions on how to use our API.