Vealth Sdg API
The sdg API from Vealth, for sdg.
The sdg API from Vealth, for sdg.
Every API here is available over the APIs.io API and to AI agents over MCP.
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
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.curl "https://apis.io/api/v1/apis/vealth-net:vealth-net-sdg-api"
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.
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: 3.2.0
info:
title: Vealth x402 Sdg API
version: 1.0.0
description: 'EcoWealth Engine API — agent-commerce surface for ecological decision artifacts.
## Payment flow (x402 on Base)
1. **Discover.** Call any paid endpoint without an Authorization header.
2. **402 Payment Required.** Server replies HTTP 402 with a JSON body carrying standard `accepts[]` (exact scheme) plus a base64 `PAYMENT-REQUIRED` response header. Sign an EIP-3009 `transferWithAuthorization` for the quoted amount to the named `payTo`, then retry with the base64 payload in the **`X-PAYMENT`** request header. Gasless, no prior approval, no API key.
3. **Pay.** Sign an EIP-3009 USDC `transferWithAuthorization` for the named price to the named recipient. The signature IS the credential; no separate transaction is required before retry.
4. **Retry.** Repeat the request with the base64 EIP-3009 payload in the `X-PAYMENT` header and the same JSON body. Bundle endpoints (`build-eco-food`, `build-eco-food-retire`) also accept an optional `Idempotency-Key` header to make replays safe.
5. **Receive.** HTTP 200 with a deterministic JSON artifact. Every paid response carries `artifact_id`, `artifact_url` (human receipt page), and a `quality` block (`endpoint_score` / `domain_score` / `evidence_score` / `proof_score` / `risk_score` plus `not_claimed[]` and `approval_gates[]`). Bundles additionally return `result.artifact_api`. Full per-endpoint response shape lives under /vealth/fixtures/*.response.json.
6. **Verify.** Settlement lands on Base at wallet `0x538aa4800ae2bd8e90556899514376ab96113a8e`. For `build-eco-food-retire` ($0.04), per-child tx hashes return only when both children land `on_chain`; otherwise honest `prepared` / `partial` / `failed` states are reported. The proof page reconciles every paid row: https://vealth.net/vealth/proof.html.
## Auth schemes
- `x402-exact` — single-product reads; one-shot payment for a fixed price.
- `x402-eip3009` — bundles; same EIP-3009 mechanic plus optional `Idempotency-Key` for safe retry. See per-operation `x-authentication`.
## No account system
No API key, no OAuth, no user record, no email. The EIP-3009 signature is the credential. An operator-issued `X-API-KEY` bypass exists for wiring tests against the real response shape; a bypass call does NOT flip `external_buyers_count`. Bypass doc: docs/ops/X402_API_KEY_FREE_TRIAL.md.
## Honest boundary
`external_buyers_count: 0`. The paid rows visible on the proof page are operator-funded plumbing, not customer revenue. No PMF, no measured ecological impact, no Carbonmark / Klima / LBC / Michelin Guide / UN / SDG endorsement is claimed.
Canonical human-readable contract: https://vealth.net/vealth/api.html. Machine-readable references in `info.x-x402`.'
contact:
url: https://vealth.net
email: brawlaphant@gmail.com
x-x402:
human_contract_page: https://vealth.net/vealth/api.html
agent_quickstart_html: https://vealth.net/vealth/agents.html#quickstart-h
agent_quickstart_json: https://vealth.net/vealth/agent-buyer-quickstart.json
discovery_manifest: https://vealth.net/.well-known/x402
fixtures_index: https://vealth.net/vealth/fixtures/index.json
quality_contract: https://vealth.net/vealth/endpoint-quality-contract.json
trust_engine_config: config/x402-trust-engine.json
trust_engine_doc: docs/ops/X402_TRUST_ENGINE.md
first_external_buyer_watch: https://vealth.net/vealth/first-external-buyer-watch.json
proof_page: https://vealth.net/vealth/proof.html
settlement:
chain: base
chain_id: 8453
currency: USDC
wallet: '0x538aa4800ae2bd8e90556899514376ab96113a8e'
payment_protocol: x402
signature_standard: EIP-3009/transferWithAuthorization
external_buyers_count: 0
external_buyers_count_source: https://vealth.net/vealth/first-external-buyer-watch.json
servers:
- url: https://vealth.net
description: Production
tags:
- name: sdg
paths:
/vealth/api/x402/sdg/assess:
post:
summary: SDG site assessment with methodology and PDF
operationId: post__vealth_api_x402_sdg_assess
tags:
- sdg
parameters:
- name: Idempotency-Key
in: header
required: false
schema:
type: string
description: Optional idempotency key for deduplication
requestBody:
required: true
content:
application/json:
schema:
type: object
responses:
'200':
description: Success
content:
application/json:
schema:
type: object
properties:
ok:
type: boolean
'402':
description: Payment required — x402 challenge. Body carries standard `accepts[]` (exact scheme). Sign EIP-3009 transferWithAuthorization for the quoted `maxAmountRequired` to the named `payTo` on the selected `network`, then retry with the base64 payload in the `X-PAYMENT` header.
headers:
PAYMENT-REQUIRED:
schema:
type: string
description: Base64-encoded x402 v2 PaymentRequired object (x402Version, resource, accepts[]). Decode it, or read the equivalent `accepts[]` from the JSON body.
example: eyJ4NDAyVmVyc2lvbiI6MiwicmVzb3VyY2UiOnsi...
content:
application/json:
schema:
$ref: '#/components/schemas/X402Challenge'
x-price: $0.02 USDC
x-payment-info:
protocols:
- x402: {}
price:
mode: fixed
currency: USD
amount: '0.02'
x-authentication: x402-eip3009
x-vealth-trust-engine: config/x402-trust-engine.json
x-vealth-trust-engine-doc: docs/ops/X402_TRUST_ENGINE.md
x-vealth-erc8004-status: registered
x-vealth-erc8004-agent-id: 45948
x-vealth-erc8004-registry: '0x8004A169FB4a3325136EB29fA0ceB6D2e539a432'
x-vealth-erc8004-mirror: /.well-known/agent-registration.json
x-vealth-erc8128-status: scaffolded-not-enforced
x-vealth-erc8128-readiness: docs/backlog/generated/erc8128-readiness/2026-04-28/summary.md
x-vealth-mpp-status: mpp-shape-on-x402-rail-not-integrated
x-vealth-mpp-plan: docs/backlog/generated/mpp-scale-plan/2026-04-28/summary.md
x-vealth-not-claimed-doc: docs/ops/AGENT_ENDPOINT_QUALITY_CONTRACT.md
x-vealth-quality-contract: /vealth/endpoint-quality-contract.json
x-vealth-status:
product_id: sdg-assess
status_label: Live (paid call lands an artifact)
quality_block_status: live emission
proof_boundary: local artifact (deterministic scorecard + payment tx; no on-chain side effect at this endpoint)
human_approval_boundary: the call itself is autonomous-allowed; irreversible follow-on actions require operator approval per docs/ops/OPERATOR_APPROVAL_POLICY.md
not_claimed_pointer: apps/web/public/vealth/agent-products.json (per-product not_claimed) + config/x402-trust-engine.json (per-product policy)
canonical_source_pointer: docs/canon/X402_TRUTH_BOARD.md + apps/web/public/llms.txt (per-row block)
components:
schemas:
X402Challenge:
type: object
description: 'Body returned with HTTP 402 Payment Required. Carries standard `accepts[]` (exact scheme) that the caller signs an EIP-3009 transferWithAuthorization against; the matching base64 `PAYMENT-REQUIRED` response header carries the same requirement in x402 v2 form. To retry: sign EIP-3009 for the quoted `maxAmountRequired` to the named `payTo` on the selected `network`, base64-encode the payload, and resend the original request with the **`X-PAYMENT`** header. `Authorization: x402` is the RETIRED door and is not accepted. Bundle endpoints additionally accept an optional `Idempotency-Key` header.'
required:
- status
- x402
properties:
status:
type: integer
example: 402
description: HTTP status echoed in the body.
error:
type: string
example: signature_expired
description: 'Short machine-readable error tag. Common values: `payment_required` (first call, no Authorization), `signature_expired`, `replay_nonce`, `recipient_mismatch`, `broadcast_failed`.'
message:
type: string
description: Human-readable explanation of the 402 cause. Optional.
x402:
type: object
description: The structured challenge. Sign EIP-3009 against `price` to `challenge.recipient` and retry.
required:
- version
- method
- price
- challenge
properties:
version:
type: string
example: '1'
description: x402 protocol version.
method:
type: string
example: eip3009
description: 'Settlement method. Today: `eip3009` (USDC `transferWithAuthorization` on Base).'
price:
type: object
description: What the caller must sign for.
required:
- amount
- currency
- chain
properties:
amount:
type: string
example: '0.040000'
description: USDC amount as a decimal string. Matches `priceUsd` for this endpoint in /.well-known/x402.
currency:
type: string
example: USDC
enum:
- USDC
chain:
type: string
example: base
enum:
- base
challenge:
type: object
description: Per-call signing parameters. Reuse exactly in the EIP-3009 message — `nonce` and `expiry` must round-trip.
required:
- priceUsdc
- recipient
- nonce
- expiry
properties:
priceUsdc:
type: number
example: 0.04
description: Numeric form of `price.amount` for convenience.
recipient:
type: string
pattern: ^0x[a-fA-F0-9]{40}$
example: '0x538aa4800ae2bd8e90556899514376ab96113a8e'
description: Address to sign the EIP-3009 transferWithAuthorization toward.
nonce:
type: string
description: 32-byte hex nonce; replay-protected by the server.
expiry:
type: integer
description: Unix seconds after which the signed authorization expires.
x-x402-flow-reference:
human_contract_page: https://vealth.net/vealth/api.html
agent_quickstart: https://vealth.net/vealth/agents.html#quickstart-h
bypass_doc: docs/ops/X402_API_KEY_FREE_TRIAL.md
retry_header_example: x402 <eip3009_signature_for_<amount>_USDC>
idempotency_header_example: 'Idempotency-Key: <uuid-v4> (bundle endpoints only)'
securitySchemes:
x402:
type: http
scheme: x402
description: 'x402 payment protocol. On an unauthenticated request, paid endpoints return HTTP 402 with standard `accepts[]` (exact scheme) and a base64 `PAYMENT-REQUIRED` response header. The caller signs an EIP-3009 `transferWithAuthorization` for the quoted amount to the named `payTo` (USDC on Base chainId 8453, or USDG on chainId 4663 where offered) and retries with the base64 payload in the **`X-PAYMENT`** request header. The EIP-3009 signature IS the credential — there is no separate API key. NOTE: `Authorization: x402` is the RETIRED bespoke door and is NOT accepted; `Authorization` is not in the CORS allow-list. Bundle endpoints additionally accept an optional `Idempotency-Key` header. Trust engine policy: docs/ops/X402_TRUST_ENGINE.md.'