convertapi API Reference

Convert API lets you effortlessly convert file formats and types.

Swagger OpenAPI Specification | .NET Framework Client | .NET Core Client | Java Client
API Endpoint
https://api.cloudmersive.com
Schemes: https
Version: v1

Authentication

Apikey

description

API Key Authentication

name
Apikey
in
header

ConvertData

CSV to JSON conversion

POST /convert/csv/to/json

Convert a CSV file to a JSON object array

inputFile

Input file to perform the operation on.

type
file
in
formData
200 OK

OK

Response Content-Types: application/json, text/json, application/xml, text/xml
Response Example (200 OK)
"object"

XML to JSON conversion

POST /convert/xml/to/json

Convert an XML string or file into JSON

200 OK

OK

Response Content-Types: application/json, text/json, application/xml, text/xml
Response Example (200 OK)
"object"

ConvertDocument

Word DOCX to PDF

POST /convert/docx/to/pdf

Convert Office Word Documents (docx) to standard PDF

inputFile

Input file to perform the operation on.

type
file
in
formData
200 OK

OK

Response Content-Types: application/pdf
Response Example (200 OK)
"file"

PowerPoint PPTX to PDF

POST /convert/pptx/to/pdf

Convert Office PowerPoint Documents (pptx) to standard PDF

inputFile

Input file to perform the operation on.

type
file
in
formData
200 OK

OK

Response Content-Types: application/pdf
Response Example (200 OK)
"file"

Excel XLSX to PDF

POST /convert/xlsx/to/pdf

Convert Office Excel Workbooks (xlsx) to standard PDF. Converts all worksheets in the workbook to PDF.

inputFile

Input file to perform the operation on.

type
file
in
formData
200 OK

OK

Response Content-Types: application/pdf
Response Example (200 OK)
"file"

Excel XLSX to CSV

POST /convert/xlsx/to/csv

Convert Office Excel Workbooks (xlsx) to standard Comma-Separated Values (CSV) format.

inputFile

Input file to perform the operation on.

type
file
in
formData
200 OK

OK

Response Content-Types: application/csv
Response Example (200 OK)
"file"

Convert Document to PDF

POST /convert/autodetect/to/pdf

Automatically detect file type and convert it to PDF.

inputFile

Input file to perform the operation on.

type
file
in
formData
200 OK

OK

Response Content-Types: application/pdf
Response Example (200 OK)
"file"

ConvertImage

Image format conversion

POST /convert/image/{format1}/to/{format2}

Convert between over 100 file formats, including key formats such as Photoshop (PSD), PNG, JPG, GIF, NEF, and BMP.

format1

Input file format as a 3+ letter file extension. Supported formats include AAI, ART, ARW, AVS, BPG, BMP, BMP2, BMP3, BRF, CALS, CGM, CIN, CMYK, CMYKA, CR2, CRW, CUR, CUT, DCM, DCR, DCX, DDS, DIB, DJVU, DNG, DOT, DPX, EMF, EPDF, EPI, EPS, EPS2, EPS3, EPSF, EPSI, EPT, EXR, FAX, FIG, FITS, FPX, GIF, GPLT, GRAY, HDR, HEIC, HPGL, HRZ, ICO, ISOBRL, ISBRL6, JBIG, JNG, JP2, JPT, J2C, J2K, JPEG/JPG, JXR, MAT, MONO, MNG, M2V, MRW, MTV, NEF, ORF, OTB, P7, PALM, PAM, PBM, PCD, PCDS, PCL, PCX, PEF, PES, PFA, PFB, PFM, PGM, PICON, PICT, PIX, PNG, PNG8, PNG00, PNG24, PNG32, PNG48, PNG64, PNM, PPM, PSB, PSD, PTIF, PWB, RAD, RAF, RGB, RGBA, RGF, RLA, RLE, SCT, SFW, SGI, SID, SUN, SVG, TGA, TIFF, TIM, UIL, VIFF, VICAR, VBMP, WDP, WEBP, WPG, X, XBM, XCF, XPM, XWD, X3F, YCbCr, YCbCrA, YUV

type
string
in
path
format2

Output (convert to this format) file format as a 3+ letter file extension. Supported formats include AAI, ART, ARW, AVS, BPG, BMP, BMP2, BMP3, BRF, CALS, CGM, CIN, CMYK, CMYKA, CR2, CRW, CUR, CUT, DCM, DCR, DCX, DDS, DIB, DJVU, DNG, DOT, DPX, EMF, EPDF, EPI, EPS, EPS2, EPS3, EPSF, EPSI, EPT, EXR, FAX, FIG, FITS, FPX, GIF, GPLT, GRAY, HDR, HEIC, HPGL, HRZ, ICO, ISOBRL, ISBRL6, JBIG, JNG, JP2, JPT, J2C, J2K, JPEG/JPG, JXR, MAT, MONO, MNG, M2V, MRW, MTV, NEF, ORF, OTB, P7, PALM, PAM, PBM, PCD, PCDS, PCL, PCX, PEF, PES, PFA, PFB, PFM, PGM, PICON, PICT, PIX, PNG, PNG8, PNG00, PNG24, PNG32, PNG48, PNG64, PNM, PPM, PSB, PSD, PTIF, PWB, RAD, RAF, RGB, RGBA, RGF, RLA, RLE, SCT, SFW, SGI, SID, SUN, SVG, TGA, TIFF, TIM, UIL, VIFF, VICAR, VBMP, WDP, WEBP, WPG, X, XBM, XCF, XPM, XWD, X3F, YCbCr, YCbCrA, YUV

type
string
in
path
inputFile

Input file to perform the operation on.

type
file
in
formData
200 OK

OK

Response Content-Types: application/json, text/json, application/xml, text/xml
Response Example (200 OK)
"file"

ConvertTemplate

Apply HTML template

POST /convert/template/html/apply

Apply operations to fill in an HTML template, generating a final HTML result

Operations to apply to template

Request Content-Types: application/json, text/json, application/xml, text/xml, application/x-www-form-urlencoded
Request Example
{
  "HtmlTemplate": "string",
  "HtmlTemplateUrl": "string",
  "Operations": [
    {
      "Action": "integer (int32)",
      "MatchAgsint": "string",
      "ReplaceWith": "string"
    }
  ]
}
Response Content-Types: application/json, text/json, application/xml, text/xml
Response Example (200 OK)
{
  "Successful": "boolean",
  "FinalHtml": "string"
}

ConvertWeb

Take screenshot of URL

POST /convert/web/url/to/screenshot

Fully renders a website and returns a PNG screenshot of the full page image. Javascript, HTML5, CSS and other advanced features are all supported.

Screenshot request parameters

Request Content-Types: application/json, text/json, application/xml, text/xml, application/x-www-form-urlencoded
Request Example
{
  "Url": "string",
  "ExtraLoadingWait": "integer (int32)"
}
200 OK

OK

Response Content-Types: image/png
Response Example (200 OK)
"file"

Convert a URL to PDF

POST /convert/web/url/to/pdf

Fully renders a website and returns a PDF of the full page. Javascript, HTML5, CSS and other advanced features are all supported.

URL to PDF request parameters

Request Content-Types: application/json, text/json, application/xml, text/xml, application/x-www-form-urlencoded
Request Example
{
  "Url": "string",
  "ExtraLoadingWait": "integer (int32)"
}
200 OK

OK

Response Content-Types: application/pdf
Response Example (200 OK)
"file"

Convert HTML string to PDF

POST /convert/web/html/to/pdf

Fully renders a website and returns a PDF of the HTML. Javascript, HTML5, CSS and other advanced features are all supported.

HTML to PDF request parameters

Request Content-Types: application/json, text/json, application/xml, text/xml, application/x-www-form-urlencoded
Request Example
{
  "Html": "string",
  "ExtraLoadingWait": "integer (int32)"
}
200 OK

OK

Response Content-Types: application/pdf
Response Example (200 OK)
"object"

Schema Definitions

HtmlTemplateApplicationRequest: object

HTML template application request

HtmlTemplate: string
HtmlTemplateUrl: string
Operations: HtmlTemplateOperation
Example
{
  "HtmlTemplate": "string",
  "HtmlTemplateUrl": "string",
  "Operations": [
    {
      "Action": "integer (int32)",
      "MatchAgsint": "string",
      "ReplaceWith": "string"
    }
  ]
}

HtmlTemplateOperation: object

Action: integer (int32) 1
MatchAgsint: string
ReplaceWith: string
Example
{
  "Action": "integer (int32)",
  "MatchAgsint": "string",
  "ReplaceWith": "string"
}

HtmlTemplateApplicationResponse: object

Response from an HTML template application

Successful: boolean
FinalHtml: string
Example
{
  "Successful": "boolean",
  "FinalHtml": "string"
}

ScreenshotRequest: object

Details of the screenshot request

Url: string
ExtraLoadingWait: integer (int32)
Example
{
  "Url": "string",
  "ExtraLoadingWait": "integer (int32)"
}

HtmlToPdfRequest: object

Details of the HTML to PDF request

Html: string
ExtraLoadingWait: integer (int32)
Example
{
  "Html": "string",
  "ExtraLoadingWait": "integer (int32)"
}