ARCNM

API reference

Pay per call API

The Pay per call API prices a CAD file with no account or API key: get a binding offer, pay it, then read the result and receipt. The environment list is free.

The Pay per call API prices a CAD file with no account or API key: get a binding offer, pay it, then read the result and receipt. The environment list is free.

Auto-generated from the public OpenAPI spec — this page never drifts from the running API. Base URL https://api.arcnm.io. No account and no API key: the guide is Pay per call.

The environments and parameters an offer prices in

GET /api/v1/pay/environments

The environments POST /pay/price prices in — what each can make, its currency and its version, never what it costs — every optional parameter with its default, the limits and the price per calculation. Free; no account needed.

Request

curl -X GET https://api.arcnm.io/api/v1/pay/environments
import requests

resp = requests.get(
    "https://api.arcnm.io/api/v1/pay/environments",
)
resp.raise_for_status()
print(resp.json())
const resp = await fetch("https://api.arcnm.io/api/v1/pay/environments", {
  method: "GET",
})
const data = await resp.json()

Responses

Status Description
200 Successful Response
default Error — the error envelope; branch on error.code.

Response body 200

Field Type Description
default_environments string[] What environments is when it is not sent.
environments PayEnvironment[]
limits PayLimits
parameters PayParameter[]
unit_price PayUnitPrice

Example response

{
  "default_environments": [
    "string"
  ],
  "environments": [
    {
      "country": "string",
      "currency": "EUR",
      "id": "string",
      "kind": "string",
      "name": "string",
      "processes": [
        "milling"
      ],
      "region": "EU",
      "version": "string"
    }
  ],
  "limits": {
    "environments_per_item": 0,
    "faces": 0,
    "lot_sizes": 0,
    "units_per_payment": 0
  },
  "parameters": [
    {
      "default": "string",
      "description": "string",
      "name": "string"
    }
  ],
  "unit_price": {
    "currency": "EUR",
    "gross_cents": 0,
    "unit": "string",
    "usdc": "string"
  }
}

Price a CAD file without an account, and pay for its result

POST /api/v1/pay/price

Send a CAD file (STEP or DXF) and get its price before anything runs — no account, no key. The answer is HTTP 402 Payment Required carrying a signed, binding offer: the calculations the file is (as an account is billed for it, in each environment), the price of each including VAT (GET /pay/environments states the list price), and the amount to pay in USDC. The offer is in the PAYMENT-REQUIRED header (x402 version 2, with the standard offer-receipt signed offers) and, in full, in the JSON body; it stands for 24 hours, until its expires_at. A file whose structure is not read in time gets a ceiling (units_max), never a refusal. Every parameter is optional, may go in the query, a form field or the JSON body, and the offer states the values it was made for; a DXF flat pattern needs sheet_gauge_mm and material.

To pay, send the same request again with the payment (PAYMENT-SIGNATURE, x402 version 2) — or offer_id alone, without the file. The calculation runs, the payment settles once it is delivered, and the answer is 200 with the result and the receipt (PAYMENT-RESPONSE), or 202 with where to collect it (result_url, read with the result_token). A failed calculation is never charged; a payment is used once, and sending the same request again joins the run already paid for.

Parameters

Name In Type Required Description
environments query string no Up to 16 environments, comma separated (ids from GET /pay/environments, or id@version). Default: DE-BY.
lot_size query string no Pieces per lot the run is priced at.
lot_sizes query string no The lots the answer states, comma separated, at most 12. Default: 1,10,100,1000.
annual_volume query string no Pieces a year.
material query string no The material.
currency query string no ISO 4217: each environment states its prices in it. Default: each environment's own.
country query string no Your country, ISO 3166-1 alpha-2.
sheet_gauge_mm query string no Sheet thickness in millimetres, for a DXF flat pattern.
offer_id query string no An earlier offer: pay it without sending the file again.
vat_id query string no Your EU VAT ID, for an invoice that names it. The price is the same; the VAT inside it follows where you are (a VAT ID is not verified yet).
invoice_to query string no Who the invoice names: name and address. The price is the same.
filename query string no The file's name.
Prefer header string no wait=N: a paid request waits up to N seconds (at most 25; 4 without it) for its result before answering 202.

Request body (application/json)

Field Type Required Description
annual_volume integer no Pieces a year.
costing_date string no Not used yet: an offer is priced as of the day it runs.
country string no Your country, ISO 3166-1 alpha-2.
currency string no ISO 4217: each environment states its prices in it with its own rates. Default: each environment's own.
drawing_base64 string no A drawing of the part: not read and not kept, the price is the geometry's (the offer's item says so in drawing).
environments string | object[] no Up to 16 environments to price in, in order (the first is the baseline): ids from GET /pay/environments, id@version, or {id, version}. Default: DE-BY.
file_base64 string yes The CAD file (STEP or DXF) as base64, or a data: URI; gzip-compressed is accepted.
filename string no Its name, e.g. bracket.step.
invoice_to string no Who the invoice names: name and address. The price is the same.
lot_size integer no Pieces per lot the run is priced at. Default: 1.
lot_sizes integer[] no The lots the answer states, at most 12. Default: 1, 10, 100 and 1000.
material string no The material.
offer_id string no An earlier offer.
sheet_gauge_mm number no Sheet thickness in millimetres: with material, required for a DXF flat pattern.
vat_id string no Your EU VAT ID, for an invoice that names it. The price is the same; the VAT inside it follows where you are (a VAT ID is not verified yet).

Request

curl -X POST https://api.arcnm.io/api/v1/pay/price \
  -H "Content-Type: application/json" \
  -d '{
    "file_base64": "string"
  }'
import requests

resp = requests.post(
    "https://api.arcnm.io/api/v1/pay/price",
    json={
        "file_base64": "string"
    },
)
if resp.status_code != 402:  # a 402 carries the offer to pay
    resp.raise_for_status()
print(resp.json())
const resp = await fetch("https://api.arcnm.io/api/v1/pay/price", {
  method: "POST",
  headers: {
    "Content-Type": "application/json",
  },
  body: JSON.stringify({
    "file_base64": "string"
  }),
})
const data = await resp.json()

Responses

Status Description
200 Paid: the result and the receipt. The PAYMENT-RESPONSE header carries the settlement (x402 version 2).
202 Paid and still running or settling, or decided with the result not put together yet: collect the result at result_url with the result_token. Or, unpaid, pricing: the file is still being read for its count — the offer so far, nothing to sign yet; send the same request again after Retry-After.
402 The offer, in full. The PAYMENT-REQUIRED header carries it as x402 version 2 (base64 JSON: accepts, and under extensions the standard offer-receipt signed offers, the offer's summary with its signature, and the terms). Also the answer to a payment that cannot be taken (its error says why: an expired offer, a used signature, a balance that does not cover it), and, with file_required, to a payment by offer_id whose file is no longer kept. Sent with nothing at all (no file, no offer_id, no payment): what one calculation costs — no offer: PAYMENT-REQUIRED and the body are the x402 requirement of one calculation at the list price, with the request's shape under extensions.bazaar; send a file for its offer. A paid request whose purchase owes a payment: what it owes, as its result URL answers it (status: payment_required).
403 payer_blocked: this payer may not pay here.
404 offer_not_found: an offer_id sent without a file names no open offer here (unknown, or bought already): send the file for a new offer. Nothing is charged.
409 offer_taken: another payment bought this offer. Nothing is charged for this one: ask for a new price.
413 file_too_large: the file is over the size a CAD file may be (details.limit_bytes). request_too_large: more than details.limit_files files or details.limit_bytes in one request: send the rest as another request. Nothing is charged.
422 file_unreadable: no STEP or DXF file that opens, or one with no solid (details.reason). part_too_complex: more faces than this endpoint prices (details.max_faces). dxf_gauge_required: a DXF flat pattern without sheet_gauge_mm and material. export_controlled: the file's header carries an export-control marking (details.marking); nothing of it is kept. nothing_to_price: only catalogue parts in the file. invalid_text: text that is no valid Unicode. calculation_failed: paid, and the calculation could not be completed. Nothing is charged.
429 rate_limited: more requests than this address may send.
451 sanctioned: a sanctioned origin or payer address (sanctions law). Nothing is charged.
503 payment_unavailable or default_environment_unavailable: no offer can be made here now. payment_provider_unavailable: the payment could not be checked now (Retry-After). Nothing is charged.
default Error — the error envelope; branch on error.code.

Response body 200

Field Type Description
by_environment ResultColumn[]
comparable boolean True when every cell states one currency (send currency to compare across currencies).
environments ResultEnvironment[]
guidance string What to do next, in one sentence.
has_more boolean
ignored object Parameters of this read not used, each with the reason.
items ResultItem[]
next_cursor string
purchase_id string The purchase's id.
receipt PaidReceipt The receipt; none when nothing was charged.
result_token string The bearer token that reads this purchase for 30 days (Authorization: Bearer). Only on the paid request's answer.
result_url string Where the result is read again (GET, with the result token).
status string paid: the payment settled and the result is released.
units ResultUnits

Example response

{
  "by_environment": [
    {
      "basket": {},
      "basket_note": "string",
      "cells": 0,
      "environment": "string",
      "failed": 0,
      "succeeded": 0,
      "wins": 0
    }
  ],
  "comparable": true,
  "environments": [
    {
      "currency": "EUR",
      "id": "string",
      "name": "string",
      "priced_at": "2026-06-01T12:00:00Z",
      "version": "string"
    }
  ],
  "guidance": "string",
  "has_more": true,
  "ignored": {},
  "items": [
    {
      "cells": [
        {}
      ],
      "cheapest": {},
      "components": [
        {}
      ],
      "components_cursor": "string",
      "drawing": "string",
      "filename": "bracket.step",
      "item": 0,
      "kind": "part",
      "parts": {
        "bought": 0,
        "capped": 0,
        "made": 0,
        "pieces": 0
      },
      "sha256": "9f86d081884c7d659a2feaa0c55ad015…",
      "units": {
        "paid": 0
      }
    }
  ],
  "next_cursor": "string",
  "purchase_id": "string",
  "receipt": {
    "amount": "string",
    "asset": "string",
    "currency": "EUR",
    "document": {
      "buyer": {},
      "corrects": "string",
      "currency": "EUR",
      "description": "string",
      "gross_cents": 0,
      "issued_at": "string",
      "kind": "receipt",
      "net_cents": 0,
      "note": "string",
      "number": "string",
      "seller": {},
      "small_amount": true,
      "supply_date": "string",
      "units": 0,
      "vat_cents": 0,
      "vat_country": "string",
      "vat_rate": "string",
      "vat_rule": "string"
    },
    "network": "string",
    "offer_id": "string",
    "pay_to": "string",
    "payer": "string",
    "price_gross_cents": 0,
    "purchase_id": "string",
    "receipt_id": "string",
    "refunds": [
      {
        "amount": "string",
        "created_at": "string",
        "document": {},
        "status": "pending",
        "units": 0
      }
    ],
    "settled_at": "string",
    "signature": "string",
    "transaction": "string",
    "units": 0,
    "units_refunded": 0
  },
  "result_token": "string",
  "result_url": "string",
  "status": "string",
  "units": {
    "paid": 0
  }
}

A paid purchase: its status, then its result and receipt

GET /api/v1/pay/price/{purchase_id}

Read a paid purchase with its result token: 202 while it runs or settles (with its progress, as counts); then the summary — every item in every environment at every lot asked, the cheapest environment per lot, each environment's basket — and the receipt, never before its payment has settled. Detail on demand: a cell or a component in full, a cost sheet at any lot, the whole purchase as JSON lines or CSV. When no live payment of it covers what was delivered, the answer is a 402 for exactly that amount: pay it here (PAYMENT-SIGNATURE) to release the result. Free. A value a read cannot use is set aside (ignored).

Paginated. Pass cursor (from the previous response) to fetch the next page; limit caps the page size.

Parameters

Name In Type Required Description
purchase_id path string yes The purchase's id (a UUID).
view query string no summary (default): items, cells and lots. full: a cell (or with component, a component) as GET /calculations/{id} states it. cost_sheet: the itemised sheet of a part or a component at lot_size.
format query string no json (default, paged), or the whole purchase as jsonl (a line per cell and per component and cell) or csv (a row per item, environment and lot, and per component and environment).
item query string no One item, from 1.
environment query string no One environment, by id.
component query string no One component, by its key in components.
lot_sizes query string no Lots to state, comma separated: a part is restated at any lot, free; an assembly states the lots it was priced at.
lot_size query string no The lot of view=cost_sheet.
cursor query string no The next page.
limit query string no Cells of view=full a page: 1 by default, at most 5.
authorization header string no Bearer <result_token>: the token the paid request answered with.

Request

curl -X GET https://api.arcnm.io/api/v1/pay/price/{purchase_id}
import requests

resp = requests.get(
    "https://api.arcnm.io/api/v1/pay/price/{purchase_id}",
)
if resp.status_code != 402:  # a 402 carries the offer to pay
    resp.raise_for_status()
print(resp.json())
const resp = await fetch("https://api.arcnm.io/api/v1/pay/price/{purchase_id}", {
  method: "GET",
})
const data = await resp.json()

Responses

Status Description
200 Paid: the summary (default), a cell or component in full (view=full), or a cost sheet (view=cost_sheet) — or the whole purchase as JSON lines (format=jsonl) or long-form CSV (format=csv).
202 Paid and still running or settling, or decided with the result not put together yet: collect the result at result_url with the result_token.
402 The purchase owes a payment (payment_required): no live payment of it covers what was delivered (reason: not_covered — another amount than was signed — or expired). The offer for exactly what was delivered, and where each cell stands (cells: its status, and why one has no price — never a figure); pay it here to release the result. A payment sent here that cannot be taken: that offer alone, the PAYMENT-REQUIRED header's error saying why.
404 not_found: no purchase for this id and token, or no such item, environment or component in it.
409 assembly_parent: an assembly states no cost sheet of its own — ask one of its components (component=).
410 result_purged: past its 30 days, or its payer's organization deleted — the result is gone (a receipt stays). refunded: an operator refunded it; the receipt, with the refund, is in details.
422 calculation_failed, file_unreadable, nothing_to_price: nothing was delivered and nothing is charged.
451 sanctioned: a sanctioned origin or payer address (sanctions law). Nothing is charged.
503 payment_unavailable or default_environment_unavailable: no offer can be made here now. payment_provider_unavailable: the payment could not be checked now (Retry-After). Nothing is charged.
default Error — the error envelope; branch on error.code.

Response body 200

Field Type Description
by_environment ResultColumn[]
comparable boolean True when every cell states one currency (send currency to compare across currencies).
environments ResultEnvironment[]
guidance string What to do next, in one sentence.
has_more boolean
ignored object Parameters of this read not used, each with the reason.
items ResultItem[]
next_cursor string
purchase_id string The purchase's id.
receipt PaidReceipt The receipt; none when nothing was charged.
result_token string The bearer token that reads this purchase for 30 days (Authorization: Bearer). Only on the paid request's answer.
result_url string Where the result is read again (GET, with the result token).
status string paid: the payment settled and the result is released.
units ResultUnits

Example response

{
  "by_environment": [
    {
      "basket": {},
      "basket_note": "string",
      "cells": 0,
      "environment": "string",
      "failed": 0,
      "succeeded": 0,
      "wins": 0
    }
  ],
  "comparable": true,
  "environments": [
    {
      "currency": "EUR",
      "id": "string",
      "name": "string",
      "priced_at": "2026-06-01T12:00:00Z",
      "version": "string"
    }
  ],
  "guidance": "string",
  "has_more": true,
  "ignored": {},
  "items": [
    {
      "cells": [
        {}
      ],
      "cheapest": {},
      "components": [
        {}
      ],
      "components_cursor": "string",
      "drawing": "string",
      "filename": "bracket.step",
      "item": 0,
      "kind": "part",
      "parts": {
        "bought": 0,
        "capped": 0,
        "made": 0,
        "pieces": 0
      },
      "sha256": "9f86d081884c7d659a2feaa0c55ad015…",
      "units": {
        "paid": 0
      }
    }
  ],
  "next_cursor": "string",
  "purchase_id": "string",
  "receipt": {
    "amount": "string",
    "asset": "string",
    "currency": "EUR",
    "document": {
      "buyer": {},
      "corrects": "string",
      "currency": "EUR",
      "description": "string",
      "gross_cents": 0,
      "issued_at": "string",
      "kind": "receipt",
      "net_cents": 0,
      "note": "string",
      "number": "string",
      "seller": {},
      "small_amount": true,
      "supply_date": "string",
      "units": 0,
      "vat_cents": 0,
      "vat_country": "string",
      "vat_rate": "string",
      "vat_rule": "string"
    },
    "network": "string",
    "offer_id": "string",
    "pay_to": "string",
    "payer": "string",
    "price_gross_cents": 0,
    "purchase_id": "string",
    "receipt_id": "string",
    "refunds": [
      {
        "amount": "string",
        "created_at": "string",
        "document": {},
        "status": "pending",
        "units": 0
      }
    ],
    "settled_at": "string",
    "signature": "string",
    "transaction": "string",
    "units": 0,
    "units_refunded": 0
  },
  "result_token": "string",
  "result_url": "string",
  "status": "string",
  "units": {
    "paid": 0
  }
}

The receipt of a paid purchase

GET /api/v1/pay/receipts/{purchase_id}

The receipt of the payment that settled the purchase: the offer, the calculations paid for, the amount, the network, the transaction and the time, its tax document — the VAT inside the price — and the refunds an operator made of it, each with its correction. Free.

Parameters

Name In Type Required Description
purchase_id path string yes The purchase's id (a UUID).
authorization header string no Bearer <result_token>: the token the paid request answered with.

Request

curl -X GET https://api.arcnm.io/api/v1/pay/receipts/{purchase_id}
import requests

resp = requests.get(
    "https://api.arcnm.io/api/v1/pay/receipts/{purchase_id}",
)
resp.raise_for_status()
print(resp.json())
const resp = await fetch("https://api.arcnm.io/api/v1/pay/receipts/{purchase_id}", {
  method: "GET",
})
const data = await resp.json()

Responses

Status Description
200 Successful Response
404 not_found: no settled payment for it yet.
422 Validation Error
default Error — the error envelope; branch on error.code.

Response body 200

Field Type Description
amount string The amount paid, in the token's smallest unit (EUR cents for the card).
asset string The token's contract address (eur: the card).
currency string EUR.
document TaxDocument Its tax document.
network string CAIP-2 network id (stripe: the card).
offer_id string The offer paid.
pay_to string The address paid (the Stripe profile).
payer string The paying address (the card's fingerprint).
price_gross_cents integer EUR cents, VAT included: what the units cost.
purchase_id string The purchase it pays: the id its result is read with.
receipt_id string The payment's id.
refunds ReceiptRefund[] The refunds of this payment.
settled_at string When it settled (UTC, ISO 8601).
signature string The x402 offer-receipt receipt: a compact JWS (EdDSA) over the network, the resource paid, the payer, the time and the transaction. Its key is in the DID document at /.well-known/did.json.
transaction string The transaction that paid it (the card's PaymentIntent).
units integer The calculations paid for.
units_refunded integer Of the units paid for, those an operator refunded or is refunding: their results are no longer served.

Example response

{
  "amount": "string",
  "asset": "string",
  "currency": "EUR",
  "document": {
    "buyer": {},
    "corrects": "string",
    "currency": "EUR",
    "description": "string",
    "gross_cents": 0,
    "issued_at": "string",
    "kind": "receipt",
    "net_cents": 0,
    "note": "string",
    "number": "string",
    "seller": {},
    "small_amount": true,
    "supply_date": "string",
    "units": 0,
    "vat_cents": 0,
    "vat_country": "string",
    "vat_rate": "string",
    "vat_rule": "string"
  },
  "network": "string",
  "offer_id": "string",
  "pay_to": "string",
  "payer": "string",
  "price_gross_cents": 0,
  "purchase_id": "string",
  "receipt_id": "string",
  "refunds": [
    {
      "amount": "string",
      "created_at": "string",
      "document": {
        "buyer": {},
        "corrects": "string",
        "currency": "EUR",
        "description": "string",
        "gross_cents": 0,
        "issued_at": "string",
        "kind": "receipt",
        "net_cents": 0,
        "note": "string",
        "number": "string",
        "seller": {},
        "small_amount": true,
        "supply_date": "string",
        "units": 0,
        "vat_cents": 0,
        "vat_country": "string",
        "vat_rate": "string",
        "vat_rule": "string"
      },
      "status": "pending",
      "units": 0
    }
  ],
  "settled_at": "string",
  "signature": "string",
  "transaction": "string",
  "units": 0,
  "units_refunded": 0
}

Name the buyer on the receipt of a paid purchase

POST /api/v1/pay/receipts/{purchase_id}

Give the invoice details — vat_id, invoice_to — in the body: the receipt's document becomes an invoice that names the buyer. Each detail is taken once, the first well-formed value; the price and the VAT inside it never change. The answer is the receipt. Free.

Parameters

Name In Type Required Description
purchase_id path string yes The purchase's id (a UUID).
authorization header string no Bearer <result_token>: the token the paid request answered with.

Request body (application/json)

Field Type Required Description
invoice_to string no Who the invoice names: name and address. The price is the same.
vat_id string no Your EU VAT ID, for an invoice that names it. The price is the same; the VAT inside it follows where you are (a VAT ID is not verified yet).

Request

curl -X POST https://api.arcnm.io/api/v1/pay/receipts/{purchase_id} \
  -H "Content-Type: application/json" \
  -d '{
    "invoice_to": "string",
    "vat_id": "string"
  }'
import requests

resp = requests.post(
    "https://api.arcnm.io/api/v1/pay/receipts/{purchase_id}",
    json={
        "invoice_to": "string",
        "vat_id": "string"
    },
)
resp.raise_for_status()
print(resp.json())
const resp = await fetch("https://api.arcnm.io/api/v1/pay/receipts/{purchase_id}", {
  method: "POST",
  headers: {
    "Content-Type": "application/json",
  },
  body: JSON.stringify({
    "invoice_to": "string",
    "vat_id": "string"
  }),
})
const data = await resp.json()

Responses

Status Description
200 Successful Response
404 not_found: no settled payment for it yet.
422 invalid_text: a detail the document cannot carry.
default Error — the error envelope; branch on error.code.

Response body 200

Field Type Description
amount string The amount paid, in the token's smallest unit (EUR cents for the card).
asset string The token's contract address (eur: the card).
currency string EUR.
document TaxDocument Its tax document.
network string CAIP-2 network id (stripe: the card).
offer_id string The offer paid.
pay_to string The address paid (the Stripe profile).
payer string The paying address (the card's fingerprint).
price_gross_cents integer EUR cents, VAT included: what the units cost.
purchase_id string The purchase it pays: the id its result is read with.
receipt_id string The payment's id.
refunds ReceiptRefund[] The refunds of this payment.
settled_at string When it settled (UTC, ISO 8601).
signature string The x402 offer-receipt receipt: a compact JWS (EdDSA) over the network, the resource paid, the payer, the time and the transaction. Its key is in the DID document at /.well-known/did.json.
transaction string The transaction that paid it (the card's PaymentIntent).
units integer The calculations paid for.
units_refunded integer Of the units paid for, those an operator refunded or is refunding: their results are no longer served.

Example response

{
  "amount": "string",
  "asset": "string",
  "currency": "EUR",
  "document": {
    "buyer": {},
    "corrects": "string",
    "currency": "EUR",
    "description": "string",
    "gross_cents": 0,
    "issued_at": "string",
    "kind": "receipt",
    "net_cents": 0,
    "note": "string",
    "number": "string",
    "seller": {},
    "small_amount": true,
    "supply_date": "string",
    "units": 0,
    "vat_cents": 0,
    "vat_country": "string",
    "vat_rate": "string",
    "vat_rule": "string"
  },
  "network": "string",
  "offer_id": "string",
  "pay_to": "string",
  "payer": "string",
  "price_gross_cents": 0,
  "purchase_id": "string",
  "receipt_id": "string",
  "refunds": [
    {
      "amount": "string",
      "created_at": "string",
      "document": {
        "buyer": {},
        "corrects": "string",
        "currency": "EUR",
        "description": "string",
        "gross_cents": 0,
        "issued_at": "string",
        "kind": "receipt",
        "net_cents": 0,
        "note": "string",
        "number": "string",
        "seller": {},
        "small_amount": true,
        "supply_date": "string",
        "units": 0,
        "vat_cents": 0,
        "vat_country": "string",
        "vat_rate": "string",
        "vat_rule": "string"
      },
      "status": "pending",
      "units": 0
    }
  ],
  "settled_at": "string",
  "signature": "string",
  "transaction": "string",
  "units": 0,
  "units_refunded": 0
}