apyhub
DEVELOPER TOOLS · FILE CONVERSION

Convert JSON to XML API

Hosted on ApyHub

What it does

JSON to XML Converter turns JSON into XML from three input styles: raw JSON in the request body, a JSON file upload, or a publicly accessible JSON URL. You can receive the result as a raw XML string, a downloadable .xml file, or a pre-signed S3 URL to the converted file.

Use the raw endpoints when you want XML inline in the response. Use the file endpoints when your workflow starts with an uploaded JSON document and you need a binary .xml file back. Use the URL endpoints when the source JSON already lives at a public URL and you want the converter to fetch it for you.

For raw JSON requests, send any non-empty JSON object in the body. For URL-based requests, send a url pointing to a publicly accessible JSON resource. For file-based requests, upload a file with MIME type application/json. Some file and URL endpoints also accept an optional output query value that is used to name the generated .xml file or S3 object.

JSON to XML Converter fits backend jobs, integrations, and document pipelines where a system stores JSON but downstream consumers expect XML. It gives you a simple way to transform data without adding conversion logic to your app.

▣ ENDPOINT 01 / 09
POST
Convert uploaded JSON file to raw XML string
http://localhost:8080/apyhub/convert-json-to-xml/json-file-xml-raw
QUICKSTARTGUIDE

Quickstart

Upload a JSON file to convert it into XML.

curl -X POST "http://localhost:8080/apyhub/convert-json-to-xml/json-file-xml-raw" \
  -H "apy-token: $APY_TOKEN" \
  -F "file=@/path/to/file.json"

What you'll get back

Returns a plain XML string, not a JSON object. The response body is the XML output directly, such as:

<root><id>1</id><name>Alice</name></root>
TRY ITLIVE · 50 ATOMS
Loading your default key…
The full key is used to call the gateway and stays in this tab — never sent to orbit or saved.
Max 100MB total per request (all files combined). Larger? Use this API's URL-based endpoint instead, if it has one.
body*
JSON file to convert (MIME type must be `application/json`).

About this endpoint

What it does

Converts an uploaded JSON file into a raw XML string. The request uploads a JSON file, and the response is plain XML text rather than a JSON object.

Request Body

ParameterTypeMandatoryDescription
fileStringYesJSON file to convert. The file MIME type must be application/json.

Response

Returns a plain XML string, not a JSON wrapper. The output schema is a top-level string, so the success response body is the XML text itself.

ParameterTypeMandatoryDescription
string bodyStringYesPlain XML string. Not wrapped in JSON. No value field exists.

Body

Name
Type
Description
bodyREQUIRED
object

Max 100MB total per request (all files combined). Larger? Use this API's URL-based endpoint instead, if it has one.

▣ ENDPOINT 02 / 09
POST
Convert uploaded JSON file to pre-signed S3 URL for .xml file
http://localhost:8080/apyhub/convert-json-to-xml/json-file-xml-url
QUICKSTARTGUIDE

Quickstart

Upload a JSON file and get back a pre-signed URL to the converted XML file.

curl -X POST "http://localhost:8080/apyhub/convert-json-to-xml/json-file-xml-url?output=my-output" \
  -H "apy-token: $APY_TOKEN" \
  -F "file=@/path/to/file.json"

What you'll get back

Returns a JSON object with a data string field containing a pre-signed S3 URL for the converted .xml file.

{
  "data": "https://s3.amazonaws.com/bucket/uuid_sample-output.xml?..."
}
TRY ITLIVE · 50 ATOMS
Loading your default key…
The full key is used to call the gateway and stays in this tab — never sent to orbit or saved.
Max 100MB total per request (all files combined). Larger? Use this API's URL-based endpoint instead, if it has one.
body*
JSON file to convert (MIME type must be `application/json`).

About this endpoint

What it does

Converts an uploaded JSON file into an XML file and returns a pre-signed S3 URL for the generated .xml file. The request uploads the source file, and the response contains the URL in the data field.

Query Parameter(s)

AttributeTypeMandatoryDescription
outputStringNoOutput filename base used to build the generated XML object name. Default: sample-output.

Request Body

ParameterTypeMandatoryDescription
fileStringYesJSON file to convert. The file must have MIME type application/json.

Response

Returns a JSON object with a single data string field containing a pre-signed S3 URL to the converted .xml file. Success response shape: object with data as a URI string.

ParameterTypeMandatoryDescription
dataStringYesPre-signed S3 URL to the converted .xml file.

Query parameters

Name
Type
Description
outputOPTIONAL
string
DEFAULT sample-output

Body

Name
Type
Description
bodyREQUIRED
object

Max 100MB total per request (all files combined). Larger? Use this API's URL-based endpoint instead, if it has one.

▣ ENDPOINT 03 / 09
POST
Convert raw JSON body to raw XML string
http://localhost:8080/apyhub/convert-json-to-xml/json-raw-xml-raw
QUICKSTARTGUIDE

Quickstart

Send any non-empty JSON object to convert it into raw XML.

curl -X POST "http://localhost:8080/apyhub/convert-json-to-xml/json-raw-xml-raw" \
  -H "apy-token: $APY_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"id":1,"name":"Alice"}'

What you'll get back

Returns a plain XML string, not a JSON object. The response body is the XML output directly.

<root><id>1</id><name>Alice</name></root>
TRY ITLIVE · 50 ATOMS
Loading your default key…
The full key is used to call the gateway and stays in this tab — never sent to orbit or saved.
body*
Any non-empty JSON object. The entire request body is used as-is as the conversion input — there are no fixed or required properties. Do not treat any example property names as required fields; they are illustrative only. Any valid JSON object with at least one key is accepted.

About this endpoint

What it does

Converts the raw JSON request body into a raw XML string. The endpoint accepts any non-empty JSON object as input and returns XML as a plain string response.

Request Body

ParameterTypeMandatoryDescription
bodyObjectYesAny non-empty JSON object. The entire request body is used as-is as the conversion input. There are no fixed or required properties; all properties are treated as input data.

Response

Returns a plain XML string, not a JSON object. The success response body is the XML output itself.

ParameterTypeMandatoryDescription
response bodyStringYesPlain XML string produced from the input JSON. Not wrapped in JSON.

Body

Name
Type
Description
bodyREQUIRED
object
Any non-empty JSON object. The entire request body is used as-is as the conversion input — there are no fixed or required properties. Do not treat any example property names as required fields; they are illustrative only. Any valid JSON object with at least one key is accepted.
▣ ENDPOINT 04 / 09
POST
Convert uploaded JSON file to downloadable .xml file
http://localhost:8080/apyhub/convert-json-to-xml/json-file-xml-file
QUICKSTARTGUIDE

Quickstart

Convert a JSON file to an XML file by uploading the JSON file and naming the output.

curl -X POST "http://localhost:8080/apyhub/convert-json-to-xml/json-file-xml-file?output=my-output" \
  -H "apy-token: $APY_TOKEN" \
  -F "file=@/path/to/file.json"

What you'll get back

Returns the raw XML file content as a binary .xml response body, not a JSON object. There is no value field in the response.

<...XML file content...>
TRY ITLIVE · 50 ATOMS
Loading your default key…
The full key is used to call the gateway and stays in this tab — never sent to orbit or saved.
Max 100MB total per request (all files combined). Larger? Use this API's URL-based endpoint instead, if it has one.
body*
JSON file to convert (MIME type must be `application/json`).

About this endpoint

What it does

Converts an uploaded JSON file into a downloadable XML file. The request uploads the JSON as binary file content, and the response returns the generated XML file as raw binary data.

Query Parameter(s)

AttributeTypeMandatoryDescription
outputStringNoOutput file name prefix or name. Default: sample-output.

Request Body

ParameterTypeMandatoryDescription
fileStringYesJSON file to convert. MIME type must be application/json.

Response

Returns a binary .xml file as the raw response body, not a JSON object. The output schema is a single binary string; no response fields are defined.

Query parameters

Name
Type
Description
outputOPTIONAL
string
DEFAULT sample-output

Body

Name
Type
Description
bodyREQUIRED
object

Max 100MB total per request (all files combined). Larger? Use this API's URL-based endpoint instead, if it has one.

▣ ENDPOINT 05 / 09
POST
Convert raw JSON body to downloadable .xml file
http://localhost:8080/apyhub/convert-json-to-xml/json-raw-xml-file
QUICKSTARTGUIDE

Quickstart

Convert a JSON object to an XML file with one POST request. The output query parameter is optional, so this minimal example sends just the JSON body.

curl -X POST "http://localhost:8080/apyhub/convert-json-to-xml/json-raw-xml-file" \
  -H "apy-token: $APY_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"key1":"value1","key2":123}'

What you'll get back

Returns the raw XML file content as a binary .xml response body, not a JSON object. The schema does not declare any JSON fields.

TRY ITLIVE · 50 ATOMS
Loading your default key…
The full key is used to call the gateway and stays in this tab — never sent to orbit or saved.
body*
Any non-empty JSON object. The entire request body is used as-is as the conversion input — there are no fixed or required properties. Do not treat any example property names as required fields; they are illustrative only. Any valid JSON object with at least one key is accepted.

About this endpoint

What it does

Converts the raw JSON object sent in the request body into an XML file and returns the file content directly in the response. The endpoint accepts any non-empty JSON object as input and can use the output query parameter to name the generated file output.

Query Parameter(s)

AttributeTypeMandatoryDescription
outputStringNoOutput file name. Default: sample-output.

Request Body

ParameterTypeMandatoryDescription
key/value pairsObjectYesAny non-empty JSON object. The entire request body is used as-is as the conversion input. Additional properties are allowed; there are no fixed or required fields.

Response

Returns a binary .xml file as the raw response body, not a JSON object. The output is declared as a string with binary format, and no value field exists.

ParameterTypeMandatoryDescription
response bodyString (binary)YesRaw XML file content returned directly in the response.

Query parameters

Name
Type
Description
outputOPTIONAL
string
DEFAULT sample-output

Body

Name
Type
Description
bodyREQUIRED
object
Any non-empty JSON object. The entire request body is used as-is as the conversion input — there are no fixed or required properties. Do not treat any example property names as required fields; they are illustrative only. Any valid JSON object with at least one key is accepted.
▣ ENDPOINT 06 / 09
POST
Convert raw JSON body to pre-signed S3 URL for .xml file
http://localhost:8080/apyhub/convert-json-to-xml/json-raw-xml-url
QUICKSTARTGUIDE

Quickstart

Convert a JSON object to XML and get back a pre-signed download URL for the .xml file.

curl -X POST "http://localhost:8080/apyhub/convert-json-to-xml/json-raw-xml-url" \
  -H "apy-token: $APY_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"key1":"value1","key2":123}'

What you'll get back

Returns a JSON object with a single data string field containing a pre-signed S3 URI for the converted .xml file.

{
  "data": "https://s3.amazonaws.com/bucket/uuid_sample-output.xml?..."
}
TRY ITLIVE · 50 ATOMS
Loading your default key…
The full key is used to call the gateway and stays in this tab — never sent to orbit or saved.
body*
Any non-empty JSON object. The entire request body is used as-is as the conversion input — there are no fixed or required properties. Do not treat any example property names as required fields; they are illustrative only. Any valid JSON object with at least one key is accepted.

About this endpoint

What it does

Converts the raw JSON request body into an XML file and returns a pre-signed S3 URL where the generated .xml file can be downloaded. You can optionally control the output name via a query parameter.

Query Parameter(s)

AttributeTypeMandatoryDescription
outputStringNoOutput file name stem. Default: sample-output.

Request Body

ParameterTypeMandatoryDescription
Raw JSONStringYesAny JSON object key is accepted; the request body is used as-is as the conversion input.

Response

Returns a JSON object with a single data string field containing a pre-signed S3 URL for the converted .xml file.

ParameterTypeMandatoryDescription
dataStringYesPre-signed S3 URL to the converted .xml file. It is a URI string.

Query parameters

Name
Type
Description
outputOPTIONAL
string
DEFAULT sample-output

Body

Name
Type
Description
bodyREQUIRED
object
Any non-empty JSON object. The entire request body is used as-is as the conversion input — there are no fixed or required properties. Do not treat any example property names as required fields; they are illustrative only. Any valid JSON object with at least one key is accepted.
▣ ENDPOINT 07 / 09
POST
Convert JSON at URL to downloadable .xml file
http://localhost:8080/apyhub/convert-json-to-xml/json-url-xml-file
QUICKSTARTGUIDE

Quickstart

Convert a JSON file from a public URL into an XML file by sending the source URL in the request body.

curl -X POST "http://localhost:8080/apyhub/convert-json-to-xml/json-url-xml-file" \
  -H "apy-token: $APY_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"url":"https://assets.apyhub.com/samples/sample.json"}'

What you'll get back

Returns the raw XML file content as a binary .xml response body, not a JSON object. No value field exists.

TRY ITLIVE · 50 ATOMS
Loading your default key…
The full key is used to call the gateway and stays in this tab — never sent to orbit or saved.
body*
Publicly accessible URL pointing to a JSON resource.

About this endpoint

What it does

Converts a JSON resource available at a public URL into a downloadable .xml file. The request supplies the source URL, and the response returns the raw XML file content as binary data.

Query Parameter(s)

AttributeTypeMandatoryDescription
outputStringNoOutput file name prefix. Default: sample-output.

Request Body

ParameterTypeMandatoryDescription
urlStringYesPublicly accessible URL pointing to a JSON resource. Format: URI.

Response

Returns a binary .xml file as the raw response body, not a JSON object. The output schema is a single binary string, so there are no response fields to document.

Query parameters

Name
Type
Description
outputOPTIONAL
string
DEFAULT sample-output

Body

Name
Type
Description
bodyREQUIRED
object
▣ ENDPOINT 08 / 09
POST
Convert JSON at URL to raw XML string
http://localhost:8080/apyhub/convert-json-to-xml/json-url-xml-raw
QUICKSTARTGUIDE

Quickstart

Convert a JSON resource at a public URL into raw XML.

curl -X POST "http://localhost:8080/apyhub/convert-json-to-xml/json-url-xml-raw" \
  -H "apy-token: $APY_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"url":"https://assets.apyhub.com/samples/sample.json"}'

What you'll get back

Returns a plain XML string, not a JSON object. The response body is the XML output directly, for example:

<root><id>1</id><name>Alice</name></root>
TRY ITLIVE · 50 ATOMS
Loading your default key…
The full key is used to call the gateway and stays in this tab — never sent to orbit or saved.
body*
Publicly accessible URL pointing to a JSON resource.

About this endpoint

What it does

Converts the JSON resource located at the provided URL into a raw XML string. The request sends a JSON URL in the body and the response returns plain XML text, not a JSON wrapper.

Request Body

ParameterTypeMandatoryDescription
urlStringYesPublicly accessible URL pointing to a JSON resource. Format: URI.

Response

Returns a plain XML string in the response body. The output schema is a string, so there is no JSON object wrapper or response field structure to map.

Body

Name
Type
Description
bodyREQUIRED
object
▣ ENDPOINT 09 / 09
POST
Convert JSON at URL to pre-signed S3 URL for .xml file
http://localhost:8080/apyhub/convert-json-to-xml/json-url-xml-url
QUICKSTARTGUIDE

Quickstart

Convert a JSON file from a public URL into XML by sending the source URL in the request body.

curl -X POST "http://localhost:8080/apyhub/convert-json-to-xml/json-url-xml-url" \
  -H "apy-token: $APY_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"url":"https://assets.apyhub.com/samples/sample.json"}'

What you'll get back

Returns a JSON object with a data string field containing a pre-signed S3 URL to the converted .xml file.

{
  "data": "https://s3.amazonaws.com/bucket/uuid_sample-output.xml?..."
}
TRY ITLIVE · 50 ATOMS
Loading your default key…
The full key is used to call the gateway and stays in this tab — never sent to orbit or saved.
body*
Publicly accessible URL pointing to a JSON resource.

About this endpoint

What it does

Converts the JSON document available at a publicly accessible URL into an XML file and returns a pre-signed S3 URL for the generated .xml file.

Query Parameter(s)

AttributeTypeMandatoryDescription
outputStringNoOutput filename base. Default: sample-output.

Request Body

ParameterTypeMandatoryDescription
urlStringYesPublicly accessible URL pointing to a JSON resource. Must be a URI.

Response

Returns a JSON object with a single data string field containing a pre-signed S3 URL to the converted .xml file.

ParameterTypeMandatoryDescription
dataStringYesPre-signed S3 URL to the converted .xml file. Must be a URI.

Query parameters

Name
Type
Description
outputOPTIONAL
string
DEFAULT sample-output

Body

Name
Type
Description
bodyREQUIRED
object
▣ COMMON ERRORS

Errors any endpoint can return

400bad_request

Required parameter missing or malformed body.

401unauthorized

API key missing, revoked, or not authorized for this service.

429rate_limited

Your plan's per-second rate exceeded. Retry with exponential backoff.

503upstream_busy

Backend temporarily unavailable. Try again in a few seconds.