Coudre Bros. Prerequisites API

## Prerequisites Two things to have ready before using this API end-to-end: a funded Cardano wallet (needed to register and to pay) and an IPFS CID for whatever you're minting. Both are covered below, along with how to verify a transaction before signing it, followed by `GET /info` -- the first live call you'll make. ### Part 1 -- preparing a Cardano mainnet wallet Before you can call `POST /register`, you need a Cardano **mainnet** wallet: a signing key, its address, and a small amount of real ADA at that address. This guide is based on a real, hands-on run-through (not just docs) -- `cardano-cli`, `pycardano`, MeshJS, and Lucid Evolution were all used end-to-end, against both Koios and Blockfrost, to mint on this API. #### 0. Pick your path - **Writing Python?** Use **PyCardano** -- pure Python, cross-platform, recommended for AI agents and server-side integrations. - **Writing JavaScript/TypeScript?** Use **MeshJS** (recommended) or **Lucid Evolution** -- see 1C below. Increasingly the default for agents built on Vercel AI SDK, Mastra, LangChain.js, or anything running on serverless/edge platforms where spawning `cardano-cli` as a subprocess isn't an option. - **Prefer a CLI, or on Linux?** Use **cardano-cli** -- the reference implementation. Platform note: `cardano-cli` is Linux-native. Support on macOS is weaker and on Windows it's not really usable directly -- use WSL there. `pycardano` is pure Python and works identically on any platform Python itself runs on. MeshJS and Lucid Evolution are pure JS/TS and work anywhere Node (or a compatible edge runtime) does. #### 1. Generate a signing key and address (offline, no network needed) **Base address vs. enterprise address -- pick base unless you have a reason not to.** A Cardano payment key alone gives you an **enterprise address** (`addr1v...`) -- valid for receiving on-chain payments from any wallet, but **rejected as a withdrawal destination by several centralized exchanges** (Coinbase, Binance among them; confirmed the hard way -- a real Coinbase withdrawal to an enterprise address was refused). Adding a **stake key** alongside the payment key gives you a **base address** (`addr1q...`) instead, which every exchange and wallet accepts, and which can also delegate stake. > **⚠️ If this address will ever receive a withdrawal from a centralized exchange > (funding it yourself, or telling a customer/operator to fund it that way), generate a > base address, not an enterprise one.** An address that only ever receives payments > from other on-chain wallets (e.g. a typical customer's `destination_address` for a > minted NFT) works fine either way -- the restriction is specifically about exchanges' > own withdrawal-destination validation, not the Cardano protocol. **1A. cardano-cli** ```bash cardano-cli conway address key-gen \ --verification-key-file payment.vkey \ --signing-key-file payment.skey cardano-cli conway stake-address key-gen \ --verification-key-file stake.vkey \ --signing-key-file stake.skey cardano-cli conway address build \ --payment-verification-key-file payment.vkey \ --stake-verification-key-file stake.vkey \ --mainnet \ --out-file payment.addr ``` Deliberately don't need exchange compatibility (e.g. a backend/operator address that's only ever funded peer-to-peer, never via an exchange withdrawal)? Drop `--stake-verification-key-file stake.vkey` from the `address build` call to get a simpler enterprise address instead -- one less key pair to manage, at the cost of the exchange-withdrawal restriction above. **1B. pycardano** Install into a virtualenv (a plain `pip install pycardano` outside a venv will fail on Ubuntu 22.04+ due to the system's externally-managed-environment policy): ```bash python3 -m venv venv venv/bin/pip install pycardano venv/bin/pip install "cbor2==5.6.5" ``` The `cbor2` pin is **not optional**: `pycardano` 0.19.2 pulls in `cbor2` 6.x by default, but internally still calls 5.x-era `cbor2` API -- without the pin you'll hit obscure `AttributeError`s deep inside transaction encoding. Tracked upstream as [Python-Cardano/pycardano#311](https://github.com/Python-Cardano/pycardano/issues/311). ```python from pycardano import ( PaymentSigningKey, PaymentVerificationKey, StakeSigningKey, StakeVerificationKey, Address, Network, ) payment_sk = PaymentSigningKey.generate() payment_vk = PaymentVerificationKey.from_signing_key(payment_sk) stake_sk = StakeSigningKey.generate() stake_vk = StakeVerificationKey.from_signing_key(stake_sk) # Base address (exchange-compatible) -- omit staking_part for a simpler # enterprise address if you deliberately don't need that (see note above). address = Address(payment_part=payment_vk.hash(), staking_part=stake_vk.hash(), network=Network.MAINNET) print(address) # addr1q... ``` Note: unlike `Network.TESTNET` (which covers both Preview and Preprod), `Network.MAINNET` is unambiguous -- there's only one mainnet. Just make sure every service URL you talk to (Koios, Blockfrost) is also the mainnet variant, not a testnet one left over from copy-pasted code. **1C. MeshJS / Lucid Evolution (JavaScript/TypeScript)** Two mature options, both with built-in Koios support (our recommended provider): - **[MeshJS](https://meshjs.dev/)** (recommended) -- address generation works fully **offline, no provider needed at all**. Good default unless you have a specific reason to prefer Lucid. - **[Lucid Evolution](https://no-witness-labs.github.io/lucid-evolution/)** -- a solid alternative, but its `Lucid()` entrypoint **requires a provider be supplied up front**, even just to derive an address from a key -- you can't go fully offline the way you can with MeshJS. ```bash npm install @meshsdk/core @meshsdk/core-csl # MeshJS npm install @lucid-evolution/lucid # Lucid Evolution (alternative) ``` MeshJS, fully offline -- generates a **base address** by default (payment + stake, no separate step needed, unlike the manual key-pair dance in 1A/1B above): ```javascript import { MeshWallet } from "@meshsdk/core"; const mnemonic = MeshWallet.brew(); // new key material, offline const wallet = new MeshWallet({ networkId: 1, // 0 = testnet, 1 = mainnet -- no fetcher/submitter needed just to get an address key: { type: "mnemonic", words: mnemonic }, }); const [address] = await wallet.getUsedAddresses(); // addr1q... -- note: returns an array ``` Lucid Evolution, for comparison -- notice the provider is required before you can derive anything: ```javascript import { Lucid, Koios, generateSeedPhrase } from "@lucid-evolution/lucid"; const provider = new Koios("https://api.koios.rest/api/v1"); const lucid = await Lucid(provider, "Mainnet"); // provider + network required up front const seed = generateSeedPhrase(); lucid.selectWallet.fromSeed(seed); const address = await lucid.wallet().address(); ``` Both have built-in Koios providers -- `new KoiosProvider("api")` (MeshJS) and `new Koios(url)` (Lucid, shown above) -- no custom wrapper needed, unlike pycardano. **Signing `partially_signed_tx`** (the atomic pay-and-mint flow's own signing step, see `POST /mint/prepare` below): ```javascript // MeshJS const signed = await wallet.signTx(partiallySignedCborHex, true); // Lucid Evolution const signed = await lucid.fromTx(partiallySignedCborHex).sign.withPrivateKey(key).complete(); ``` Gotchas specific to this path (confirmed hands-on, not just from docs): - **Lucid Evolution is published ESM-only.** `import` works cleanly; relying on `require()` in a strict CommonJS setup (older Node, some bundler configs, `"type"` left unset in `package.json`) can fail or behave inconsistently -- use `import`/ `.mjs`/`"type": "module"`, don't fight it with CJS interop. - **Lucid's numbers come back as `BigInt`, not `string`.** e.g. a transaction fee is `210733n`, not `"210733"` -- MeshJS's `.to_str()` calls return strings instead. Mixing the two up breaks naive `JSON.stringify()`/string concatenation. - **Lucid needs a network parameter even for offline-feeling operations** -- there's no way to sidestep supplying a provider, unlike MeshJS's `MeshWallet`. #### 2. ⚠️ Fund the wallet -- requires a human, and it's real money There is no mainnet faucet -- funding this address means sending **real ADA** you already hold, from an exchange withdrawal or another wallet you control. If you're an AI agent following this guide: this is not something to do on your own initiative. Hand the generated address to your human operator and let them decide the amount and send it deliberately. > **⚠️ Requires human intervention -- real funds.** Never ask an operator for > more than the small amount actually needed for fees/minting, and never > generate or reuse an address you can't clearly account for. Ask your > operator to fund `payment.addr` / `address` manually, then continue once > they confirm it's done and the transaction is confirmed on-chain. After funding, wait for the funding transaction to be **confirmed on-chain** (check via Koios/Blockfrost or a mainnet explorer) before your first balance query -- unlike a testnet faucet, there's no "instant" mainnet equivalent. #### 3. Query balance/UTxOs and submit transactions **cardano-cli + Koios (recommended default for the CLI path)** ```bash curl -s -X POST "https://api.koios.rest/api/v1/address_info" \ -H "Content-Type: application/json" \ -d '{"_addresses":["addr1q..."]}' curl -s -X POST "https://api.koios.rest/api/v1/address_utxos" \ -H "Content-Type: application/json" \ -d '{"_addresses":["addr1q..."]}' curl -s -X POST "https://api.koios.rest/api/v1/submittx" \ -H "Content-Type: application/cbor" \ --data-binary @signed.tx ``` Rate limit: 100 requests / 10s without authentication (an optional JWT token raises this, see Koios's own docs if you need it). **pycardano + Koios (recommended default for the Python path)** PyCardano does **not** ship a built-in `KoiosChainContext` -- only `BlockFrostChainContext`, which requires a Blockfrost API key. To use Koios from pycardano you have two options: (a) write a small custom `ChainContext` wrapper around Koios's REST API, or (b) call Koios directly via `requests` just for the query side, and let `TransactionBuilder` handle coin selection and fee calculation locally once you feed it the UTxOs. Raw query fallback (option b), the simpler starting point: ```python import requests resp = requests.post( "https://api.koios.rest/api/v1/address_utxos", json={"_addresses": ["addr1q..."]}, ) ``` Build, sign and submit: ```python builder = TransactionBuilder(ctx) builder.add_input_address(funded_address) builder.add_output(TransactionOutput.from_primitive([dest.to_primitive(), 2_000_000])) tx = builder.build_and_sign([signing_key], change_address=change_address) # Fee is calculated automatically resp = requests.post( "https://api.koios.rest/api/v1/submittx", data=tx.to_cbor(), headers={"Content-Type": "application/cbor"}, ) ``` The clear win here over `cardano-cli`: `TransactionBuilder` handles coin selection and fee calculation for you -- no manual fee math. **Blockfrost (alternative to Koios, for either path)** Better SDK ecosystem and SLA than Koios, but requires signing up (2-3 minutes, no credit card) for a free-tier API key (50,000 requests/day). ```bash curl "https://cardano-mainnet.blockfrost.io/api/v0/addresses/addr1q..." \ -H "project_id: mainnetXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX" ``` For pycardano, Blockfrost is the *easier* integration of the two: a ready `BlockFrostChainContext` exists out of the box, no wrapper needed. #### 4. Koios vs Blockfrost / PyCardano vs cardano-cli | | Koios | Blockfrost | |---|---|---| | Sign-up | None needed | Required (free, ~2-3 min) | | Auth header | None (optional JWT for higher limits) | `project_id: ` | | Rate limit (free) | 100 req/10s | 50,000 req/day | | Submit endpoint | `POST /submittx`, raw CBOR body | `POST /tx/submit`, raw CBOR body | | Reliability | Community-run, generally solid | Commercial SLA | | SDK ecosystem | Thin -- mostly raw REST | Broad -- official SDKs incl. pycardano's `BlockFrostChainContext` | | | PyCardano | cardano-cli | |---|---|---| | Cross-platform | Yes (pure Python) | Linux-native; weak macOS support, needs WSL on Windows | | Offline key generation | Yes | Yes | | Transaction building | `TransactionBuilder` -- automatic coin selection + fees | Manual (`transaction build` computes fees, but inputs/outputs are explicit) | | Chain context | Built-in for Blockfrost only; Koios needs a custom wrapper or raw `requests` | N/A -- talk to Koios/Blockfrost via `curl` directly | | Best fit for | AI agents / server-side automation | Scripts, ops tooling, Linux environments | | Documentation quality | Sparse in places (see gotchas below) | Comprehensive, but CLI-flag-heavy | #### 5. Common mistakes / things to watch for These are all things that actually tripped us up during testing, not theoretical concerns: - **Koios returns `[]` for an empty/unfunded address** -- that's a normal empty result, not an error. - **Koios requires `POST` with a JSON body, not `GET` with a query parameter** -- a `GET` request returns 404. - **Mainnet needs `--mainnet` on every cardano-cli call**, not `--testnet-magic ` -- mixing these up is the most common copy-paste error when adapting testnet code/examples to mainnet. - **Double-check every Koios/Blockfrost URL is the mainnet variant** (`api.koios.rest`, `cardano-mainnet.blockfrost.io`) -- a testnet URL left over from copy-pasted code will silently query the wrong chain instead of erroring. - **Blockfrost's auth header is exactly `project_id:`**, not `Authorization:` and not `X-Api-Key:`. - **Koios's submit endpoint expects raw binary CBOR**, `Content-Type: application/cbor` -- not JSON, not hex-encoded text. - **`cbor2` version conflict in PyCardano** -- run `pip install cbor2==5.6.5` right after installing `pycardano`, or you'll hit confusing encoding errors (see step 1B above). - **PyCardano has no `__version__` attribute** -- to check the installed version, use `importlib.metadata.version('pycardano')` instead of `pycardano.__version__`. - **PyCardano's `ProtocolParameters` fields are under-documented** -- e.g. the field is `collateral_percent`, not `collateral_percentage`, and `cost_models` is a required field, not optional. - **On Ubuntu 22.04+, a venv is mandatory** -- a bare `pip install pycardano` outside a virtualenv will fail with an externally-managed-environment error. #### Next step Once your address is funded, continue with **Part 2** below, or -- if you already have a CID ready too -- straight to **`POST /register`**. --- ### Part 2 -- getting an IPFS CID before you mint Both `POST /mint` and `POST /mint/prepare` take an `ipfs_hash` -- a CID that must already point to content pinned on IPFS *before* you call either endpoint. nft_api is a **blind backend**: it never receives, stores, or reviews your file. Pinning the asset is entirely your (the caller's) responsibility, against a separate IPFS pinning service, not this API. #### 0. The one step that needs a human > **⚠️ Requires human intervention.** Getting an API key/JWT from an IPFS pinning service > requires creating an account -- like the funding step in Part 1 above, this is a > one-time human step that can't be scripted or automated. If you're an AI agent following > this guide: ask your operator to sign up once and hand you the resulting key/JWT. > Everything after that -- uploading files, getting CIDs, minting -- you can do yourself, > for as many files as you need, without asking again. A concrete ask you can hand your > operator: *"Please sign up at pinata.cloud, then go to Developer -> API Keys, generate a > new key, and give me the JWT it shows you."* #### 1. Primary: Pinata Sign up for a free account at [pinata.cloud](https://www.pinata.cloud/). Once logged in, go to **Developer -> API Keys** in the left-hand menu, click **New Key**, grant it pinning access, and generate it -- the JWT shown at that point is what you (or your operator, on your behalf) need to hand back to the agent. ```bash curl -X POST https://api.pinata.cloud/pinning/pinFileToIPFS \ -H "Authorization: Bearer $PINATA_JWT" \ -F "file=@my_asset.png" ``` ```python import requests url = "https://api.pinata.cloud/pinning/pinFileToIPFS" headers = {"Authorization": f"Bearer {PINATA_JWT}"} with open("my_asset.png", "rb") as f: resp = requests.post(url, headers=headers, files={"file": f}) resp.raise_for_status() cid = resp.json()["IpfsHash"] ``` The response's `IpfsHash` field is your CID -- pass it as `ipfs_hash` to `/mint` or `/mint/prepare`. Files stay pinned by default on Pinata's free tier. #### 2. Fallback: NFT.Storage Useful as a backup if Pinata is unavailable, but be aware NFT.Storage's classic free tier has been winding down as the service migrates to a Storacha-backed, paid-plan model -- check current pricing/limits before relying on it for anything long-term. ```bash curl -X POST https://api.nft.storage/upload \ -H "Authorization: Bearer $NFT_STORAGE_TOKEN" \ --data-binary @my_asset.png ``` ```python import requests with open("my_asset.png", "rb") as f: resp = requests.post( "https://api.nft.storage/upload", headers={"Authorization": f"Bearer {NFT_STORAGE_TOKEN}"}, data=f, ) resp.raise_for_status() cid = resp.json()["value"]["cid"] ``` #### 3. What we don't recommend, and why - **Storacha** (formerly web3.storage) -- its current API is UCAN/DID-based, not a simple bearer-token REST upload; there's real setup overhead (`w3cli`, delegated capabilities) before you can pin a single file. Skip it unless you have a specific reason to use it. - **Infura IPFS** -- built primarily for its Ethereum product line; pinning requires a project ID **and** secret and carries needless complexity for a single-file CID lookup. #### Next step Once you have both a funded wallet (Part 1) and a CID (Part 2), continue with **Part 3** below -- how to check a transaction before you sign it -- then **`POST /register`** and **`POST /mint/prepare`** (or `POST /mint`, if you're paying separately). --- ### Part 3 -- verify the transaction before signing `POST /mint/prepare` (see below) returns `partially_signed_tx`: a transaction this API has built and already co-signed, along with a text description of what it does. Before adding your own signature, verify the actual CBOR contents yourself, rather than trusting that description -- this protects you just as much against a mistake on our side as against a compromised API or a tampered response in transit. Every tool below can inspect `partially_signed_tx` *before* you've added anything to it, so there's no reason to skip this and check only after the fact. #### What to check - **Outputs** -- does the expected amount land at the expected address? - **Mint** -- is only the expected token being minted, in the expected quantity? - **Inputs** -- do they match the UTxO(s) you expected to spend? - **Fee** -- is it a sane amount? #### How Use whatever tool you're already using to sign -- none of the four paths below is meaningfully worse than another for this, so there's no reason to add a new dependency just to verify. All four were run against a real `partially_signed_tx` from this API while writing this guide. **cardano-cli** ```bash cardano-cli debug transaction view --tx-file tx.tx ``` > **⚠️ This is `cardano-cli debug transaction view` -- not `conway transaction > view`.** The latter doesn't exist, even though every other command in this > guide is a `conway`-era subcommand -- an easy one to get wrong by analogy. > `tx.tx` here is `partially_signed_tx` wrapped in the same `{"type": "Tx > ConwayEra", "cborHex": "..."}` envelope used elsewhere in this guide. Returns a readable JSON document with era, fee, inputs, outputs, and any mint. **pycardano** ```python from pycardano import Transaction tx = Transaction.from_cbor(cbor_hex) # cbor_hex = partially_signed_tx, as-is body = tx.transaction_body print(f"Fee: {body.fee / 1_000_000:.6f} ADA") for inp in body.inputs: print(f"Input: {inp.transaction_id}#{inp.index}") for out in body.outputs: lovelace = out.amount if isinstance(out.amount, int) else out.amount.coin print(f"Output: {out.address}: {lovelace / 1_000_000:.2f} ADA") if body.mint: for policy, assets in body.mint.items(): for name, qty in assets.items(): print(f"Mint: {bytes(name).decode()} qty={qty}") ``` **MeshJS** -- the simplest of the four, one-liners against the raw CBOR hex: ```javascript import { getTransactionInputs, getTransactionOutputs, deserializeTx } from "@meshsdk/core-csl"; const cborHex = partiallySignedTx; // as returned by POST /mint/prepare const inputs = getTransactionInputs(cborHex); const outputs = getTransactionOutputs(cborHex); const fee = deserializeTx(cborHex).body().fee().to_str(); const mint = deserializeTx(cborHex).body().mint()?.to_js_value(); ``` > **These three functions live in `@meshsdk/core-csl`, not `@meshsdk/core`** > -- an easy import to get wrong, since everything else in the wallet guide > above comes from `@meshsdk/core`. **Lucid Evolution** ```javascript import { CML } from "@lucid-evolution/lucid"; const body = CML.Transaction.from_cbor_hex(cborHex).body(); const fee = body.fee(); // BigInt, e.g. 210733n -- not a string like MeshJS's .to_str() const outputs = body.outputs(); const mint = body.mint(); ``` All four paths above work identically on `partially_signed_tx` itself, before your own witness is added -- check first, sign second. #### Next step Continue with **`POST /register`** below to exchange a one-time registration payment for an API key, then **`POST /mint/prepare`** (or `POST /mint`, if you're paying separately). --- Public info needed to get started -- no API key required.

GitHub OpenAPI

Operations 1

1 of 1 operations are conformant: apis.io called them with no credentials and the responses matched this contract. Checked 2026-11-11. how this works · status file

GET /info Get the operator payment address and current fee amounts conformant #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/coudrebros-eu:coudrebros-eu-prerequisites-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

coudrebros-eu-prerequisites-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Coudrebros Eu Prerequisites API
  version: 1.1.0
  contact:
    name: CoudreBros
    url: https://www.coudrebros.eu/
  description: 'Operations tagged prerequisites across 2 of this provider''s published API definitions: coudrebros-eu-openapi.json, coudrebros-eu-openapi.yml. Each path carries the servers of the definition it was published in.'
servers:
- url: https://nftapi.coudrebros.eu
  description: Cardano mainnet (per https://nftapi.coudrebros.eu/llms.txt)
- url: https://testnet.nftapi.coudrebros.eu
  description: Testnet instance serving the same spec
tags:
- name: prerequisites
  description: '## Prerequisites


    Two things to have ready before using this API end-to-end: a funded Cardano wallet (needed to register and to pay) and an IPFS CID for whatever you''re minting. Both are covered below, along with how to verify a transaction before signing it, followed by `GET /info` -- the first live call you''ll make. ### Part 1 -- preparing a Cardano mainnet wallet


    Before you can call `POST /register`, you need a Cardano **mainnet**

    wallet: a signing key, its address, and a small amount of real ADA at

    that address. This guide is based on a real, hands-on run-through (not just

    docs) -- `cardano-cli`, `pycardano`, MeshJS, and Lucid Evolution were all

    used end-to-end, against both Koios and Blockfrost, to mint on this API. #### 0. Pick your path


    - **Writing Python?** Use **PyCardano** -- pure Python, cross-platform,

    recommended for AI agents and server-side integrations. - **Writing JavaScript/TypeScript?** Use **MeshJS** (recommended) or **Lucid

    Evolution** -- see 1C below. Increasingly the default for agents built on

    Vercel AI SDK, Mastra, LangChain.js, or anything running on serverless/edge

    platforms where spawning `cardano-cli` as a subprocess isn''t an option. - **Prefer a CLI, or on Linux?** Use **cardano-cli** -- the reference

    implementation. Platform note: `cardano-cli` is Linux-native. Support on macOS is weaker and

    on Windows it''s not really usable directly -- use WSL there. `pycardano` is

    pure Python and works identically on any platform Python itself runs on. MeshJS and Lucid Evolution are pure JS/TS and work anywhere Node (or a

    compatible edge runtime) does. #### 1. Generate a signing key and address (offline, no network needed)


    **Base address vs. enterprise address -- pick base unless you have a reason not to.**

    A Cardano payment key alone gives you an **enterprise address** (`addr1v...`)

    -- valid for receiving on-chain payments from any wallet, but **rejected as a withdrawal

    destination by several centralized exchanges** (Coinbase, Binance among them; confirmed the

    hard way -- a real Coinbase withdrawal to an enterprise address was refused). Adding a

    **stake key** alongside the payment key gives you a **base address** (`addr1q...`)

    instead, which every exchange and wallet accepts, and which can also delegate stake. > **⚠️ If this address will ever receive a withdrawal from a centralized exchange

    > (funding it yourself, or telling a customer/operator to fund it that way), generate a

    > base address, not an enterprise one.** An address that only ever receives payments

    > from other on-chain wallets (e.g. a typical customer''s `destination_address` for a

    > minted NFT) works fine either way -- the restriction is specifically about exchanges''

    > own withdrawal-destination validation, not the Cardano protocol. **1A. cardano-cli**


    ```bash

    cardano-cli conway address key-gen \

    --verification-key-file payment.vkey \

    --signing-key-file payment.skey


    cardano-cli conway stake-address key-gen \

    --verification-key-file stake.vkey \

    --signing-key-file stake.skey


    cardano-cli conway address build \

    --payment-verification-key-file payment.vkey \

    --stake-verification-key-file stake.vkey \

    --mainnet \

    --out-file payment.addr

    ```


    Deliberately don''t need exchange compatibility (e.g. a backend/operator address that''s

    only ever funded peer-to-peer, never via an exchange withdrawal)? Drop

    `--stake-verification-key-file stake.vkey` from the `address build` call to get a

    simpler enterprise address instead -- one less key pair to manage, at the cost of the

    exchange-withdrawal restriction above. **1B.'
paths:
  /info:
    get:
      tags:
      - prerequisites
      summary: Get the operator payment address and current fee amounts
      description: 'Everything a new client needs before its first call: where to send ADA, and how much. No API key required -- call this first, before `POST /register`.'
      operationId: info_info_get
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/InfoResponse'
components:
  schemas:
    InfoResponse:
      properties:
        payment_address:
          type: string
          title: Payment Address
          description: Operator's Cardano payment address -- send mint/registration fees here
        network:
          type: string
          enum:
          - mainnet
          - testnet
          title: Network
          description: Cardano network this API is currently operating on
        registration_fee_lovelace:
          type: integer
          title: Registration Fee Lovelace
          description: Exact amount required for POST /register
        mint_fee_lovelace:
          type: integer
          title: Mint Fee Lovelace
          description: Exact amount required for POST /mint
        nft_output_lovelace:
          type: integer
          title: Nft Output Lovelace
          description: Part of mint_fee_lovelace that is NOT operator revenue -- Cardano requires every UTxO holding a native token to carry a minimum ADA balance, so this amount is sent back out to destination_address bundled with the minted NFT itself, not kept by the operator. The rest of mint_fee_lovelace, minus the mint transaction's own network fee, is the operator's actual take.
      type: object
      required:
      - payment_address
      - network
      - registration_fee_lovelace
      - mint_fee_lovelace
      - nft_output_lovelace
      title: InfoResponse
x-refined-from:
- coudrebros-eu-openapi.json
- coudrebros-eu-openapi.yml