---
name: json-toml-converter
description: "JSON ↔ TOML (JSON to TOML Converter) via devops.majbase.com's free public API, no key required. Keywords: json to toml, toml converter."
---

# JSON ↔ TOML

JSON to TOML Converter. Calls devops.majbase.com's free public API — no API key or authentication required.

## Endpoint

```
GET/POST https://devops.majbase.com/json-toml-converter/api
```

## Request / Response

```
API: GET or POST /json-toml-converter/api
  text=<string>                          (required)
  direction=toml-to-json|json-to-toml     (required)
  sort_keys=true|false                    (optional, default false)
  indent=<int>                            (optional, default 2 — toml-to-json only)
Returns {"result": "..."}, or {"error": "..."} on malformed input.
JSON must be an object at the top level for json-to-toml (TOML
documents are always a table).
```

## Example

```bash
curl -sS "https://devops.majbase.com/json-toml-converter/api" \
    --data-urlencode 'direction=json-to-toml' \
    --data-urlencode 'text={"name": "my-app", "port": 8080}'
```

## Notes

- No API key or authentication required.
- Full interactive tool: https://devops.majbase.com/json-toml-converter/
