ToolYourToolYourAPI Docs

Convertors

Image and CSV conversion APIs — REST and TypeScript SDK.

TypeScript SDK

Namespace: ty.convertors. Pass file as image (or route-specific field). Full table: SDK Tool Map → Convertors.

import { ToolYour } from "@toolyour/sdk";
const ty = ToolYour({ apiKey: process.env.TOOLYOUR_API_KEY! });

await ty.convertors.convertToJpg({ image: fileBlob });
await ty.convertors.compressImage({ image: fileBlob });
await ty.convertors.csvToJson({ csvFile: fileBlob });

Base path: /api/v1/convertors

All endpoints are POST with multipart/form-data and require X-Api-Key.

Image uploads

Most routes accept an image file field:

curl -X POST "https://api.toolyour.com/api/v1/convertors/to-jpg" \
  -H "X-Api-Key: $API_KEY" \
  -F "[email protected]"

Default response is JSON with result.downloadUrl (presigned link, 1 hour). See Calling Tools for the full envelope and download step.

Common routes:

PathDescription
/to-jpgConvert to JPG
/to-pngConvert to PNG
/to-webpConvert to WebP
/to-svgConvert to SVG
/compress-imageCompress image
/to-grayscaleGrayscale
/image-to-pdfImage to PDF
/image-metadataRead metadata (JSON, not a file URL)

CSV / JSON

PathFile fieldResponse
/csv-2-jsoncsvFileJSON in body
/json-2-csvjsonFileToolFileResponse + downloadUrl

Query parameter

NameValuesDefault
deliveryurl, binaryurl

See the Convertors tag in the API reference for the full list and schemas.

On this page