Explorez la documentation de notre API et des exemples pour intérergrer Png2Webp dans votre appliction ou flux de travail.
Our API is a simple HTTP interface with various options:
Direct uploads or URL reference
Image file or JSON-encoded data
up to 25 megapixels
Not a developer? There are plenty ready to use tools & Apps by png2webp and our community.
Our API is a simple HTTP interface with various options:
You’re going to receive 100 API calls for free.
After that your first 5 API calls per day are on us (see pricing)
Use the following code samples to get started quickly
Review the reference docs to adjust any parameters
Want to know more about subscription? see pricing
$ curl -H 'X-API-Key: INSERT_YOUR_API_KEY_HERE' \
-F 'image_file=@/path/to/file.jpg' \
-F 'size=auto' \
-f https://api.png2webp.com/v1.0/convert -o webp-file.webp
Get up and running faster with official and third-party libraries.
Not a developer?
There are plenty ready to use tools & Apps by png2webp and our community.
by Png2Webp
by Png2Webp
by Manuel Njiakim
by Manuel Njiakim
There are plenty ready to use tools & Apps by png2webp and our community.
We only accept images with the format bellow :
Formats | Limited size | Example |
---|---|---|
PNG | Up to 25 Megapixels | |
JPG | Up to 25 Megapixels | |
ZIP | Up to 50 Megapixels |
This feature is not yet available in stable version. If you need this feature, get in touch
If you want to authenticate users with the click of a button instead of having them enter an API Key, get in touch to try our OAuth 2.0 login.
Input image | Megapixels | Effective Rate Limit |
---|---|---|
625 x 400 | 1 MP | 500 images per minute |
1200 x 800 | 1 MP | 500 images per minute |
1600 x 1200 | 2 MP | 500 / 2 = 250 images per minute |
2500 x 1600 | 4 MP | 500 / 4 = 125 images per minute |
4000 x 2500 | 10 MP | 500 / 10 = 50 images per minute |
6250 x 4000 | 25 MP | 500 / 25 = 20 images per minute |
Le dépassement des limites tarifaires entraîne une réponse HTTP status 429 (aucun crédit facturé). Les clients peuvent utiliser les en-têtes de réponse suivants pour gérer gracieusement les limites de débit :
Response header | Sample value | Description |
---|---|---|
X-RateLimit-Limit | 500 MP | Total rate limit in megapixel images |
X-RateLimit-Remaining | 499 MP | Remaining rate limit for this minute |
X-RateLimit-Reset | 1662309450 MP | Unix timestamp when rate limit will reset |
Retry-After | 59 MP | Seconds until rate limit will reset (only present if rate limit exceeded) |
Higher Rate Limits are available upon request
Exponential backoff is an error handling strategy in which a client periodically retries a failed request.
Most recent API updates:
Nous utilisons des cookies pour améliorer votre expérience et à des fins d'analyse. Vous pouvez les désactiver à tout moment.