Every conversion request call must be authenticated with secret
or token
and submited as query parameter
. More detailed authentication methods covered in Authentication section. All supported file format conversions are provided here.
When files or web pages are accessible from the Internet it is enough to open a link to convert them.
[GET/POST]
https://v2.convertapi.com/convert/web/to/pdf?download=inline&secret=XXX&url=http%3A%2F%2Fexample.com
[response]
PDF file contents displayed in a browser
URL passed as a query parameter must be percentage encoded (from http://example.com to http%3A%2F%2Fexample.com).
[GET/POST]
https://v2.convertapi.com/convert/docx/to/pdf?download=inline&secret=XXX&file=http%3A%2F%2www.baltsoft.com/files/doc-demo.docx
[response]
PDF file contents displayed in a browser
More about GET method request conversions please read in Virtual File Server section.
[POST]
https://v2.convertapi.com/convert/doc/to/pdf?Secret=XXX
{
"Parameters": [
{
"Name": "File",
"FileValue": {
"Name": "my_file.doc",
"Data": "--Base64 encoded file content--"
}
}
]
}
[response]
{
"ConversionTime": 2,
"Files": [
{
"FileName": "my_file.pdf",
"FileSize": 523672,
"FileData": "--Base64 encoded file content--"
}
]
}