---
title: "Code Convert (x402)"
method: POST
path: "/x402/v2/code-convert"
tags: ["x402"]
---

# Code Convert (x402)

`POST /x402/v2/code-convert`

## Request

- Base URL: `https://api.strale.io`
- URL: `https://api.strale.io/x402/v2/code-convert`
- Auth: none required

Convert code between programming languages. Uses idiomatic patterns for the target language. Supports all major languages.

## Request body

- object
  - `code` string, required
  - `to_language` string, required
  - `from_language` string

## Response `200`

Success

- object
  - `confidence` string
  - `converted_code` string
  - `source_language` string
  - `target_language` string
  - `dependencies_needed` unknown[]
    - unknown

## Other responses

- `402`: Payment required (x402 — pay with USDC on Base)

---

[API](https://skmtc.dev/strale/apis/strale-api-2.md) · [All operations](https://skmtc.dev/strale/apis/strale-api-2/llms.txt) · [OpenAPI document](https://skmtc.dev/strale/apis/strale-api-2/revisions/a5293878cfc6?raw)
