How to Automate Image Conversions with an API
The free tools on conver.tr are perfect for manually converting a few files. But what if you need to process hundreds, or even thousands, of images every day? What if you want to automatically convert every user-uploaded photo on your website into an optimized WEBP file?
For this, you need an API (Application Programming Interface). This guide explains what our API is, who it's for, and how to get started.
Why Use an Image API?
An API allows your application (your website, your mobile app, your backend server) to "talk" to our application and request conversions automatically. This is ideal for:
- Web Developers: Automatically resize and compress all user-generated content to save bandwidth and improve site speed.
- Businesses: Batch-process entire folders of images into a standard format (like PDF or JPG) for reports.
- SaaS Companies: Integrate image conversion as a feature directly into your own product.
- Automation: Set up scripts to watch a folder and automatically convert any new images.
Getting Started with the conver.tr API
Our API is built to be simple, fast, and scalable. It's a standard REST API that accepts image files and returns your converted files.
Step-by-Step Guide
-
Explore Plans & Documentation
First, head over to our API & Pricing page. Here you can see the different plans, from "Personal" for small projects to "Business" and "Enterprise" for high-volume needs. This page also links to our full API documentation.
View API & Pricing -
Get Your API Key
Once you sign up for a plan, you will receive a unique API key. This key is secret and authenticates your application, allowing it to make requests.
-
Make Your First API Call
You can make requests from any programming language (like JavaScript, Python, PHP, or cURL). Here's a conceptual example (in JavaScript) of what a request to convert an image to a 800px-wide JPG might look like:
// This is a conceptual example. // See our API docs for full code. const imageFile = get_my_image_file(); // Your file const apiKey = 'YOUR_SECRET_API_KEY'; const formData = new FormData(); formData.append('image', imageFile); formData.append('to', 'jpg'); formData.append('width', 800); formData.append('quality', 90); fetch('https://api.conver.tr/v1/convert', { method: 'POST', headers: { 'Authorization': `Bearer ${apiKey}` }, body: formData }) .then(response => response.blob()) .then(blob => { // success! 'blob' is your new JPG file. save_my_new_file(blob); }); -
Integrate and Scale
Once you've made a successful test call, you can integrate this logic directly into your application. Our API is built on high-performance infrastructure, so you can scale from 10 requests a month to 10 million.
Ready to Build?
Stop wasting time with manual conversions. Automate your entire image workflow with a powerful and reliable API. Explore our plans to get started.
Explore API Plans