# Marketplace API Examples (v1) ## `GET /marketplace/offers` Success (`200`): ```json { "offers": [ { "offer_id": "edut.workspace.core", "issuer_id": "edut.firstparty", "title": "EDUT Workspace Core", "summary": "Org-bound deterministic governance runtime.", "status": "active", "pricing": { "currency": "USDC", "amount_atomic": "1000000000", "decimals": 6, "chain_id": 8453 }, "execution_profile": { "connector_surface": "hybrid", "pacing_tier": "governed_human_pace", "human_pace_floor_ms": 1200 }, "policies": { "member_only": true, "workspace_bound": true, "transferable": false, "internal_use_only": true, "multi_tenant": false } } ] } ``` ## `POST /marketplace/checkout/quote` Request: ```json { "wallet": "0x3ea6cbf98d23e2cf7b6f4f9bb1fb4f50b710f2d5", "payer_wallet": "0x2299547f6fA9A8f9b6d9aEA9F9D8A4B53C8A0e11", "offer_id": "edut.workspace.core", "org_root_id": "org.acme.root", "principal_id": "human.joshua", "principal_role": "org_root_owner", "workspace_id": "workspace.work.acme.exec", "ownership_proof": "0x9f20..." } ``` Success (`200`): ```json { "quote_id": "cq_01HZZXFQ27ZP6MP0V2R9M6V3KX", "wallet": "0x3ea6cbf98d23e2cf7b6f4f9bb1fb4f50b710f2d5", "payer_wallet": "0x2299547f6fA9A8f9b6d9aEA9F9D8A4B53C8A0e11", "offer_id": "edut.workspace.core", "org_root_id": "org.acme.root", "principal_id": "human.joshua", "principal_role": "org_root_owner", "currency": "USDC", "amount": "1000.00", "amount_atomic": "1000000000", "total_amount": "1100.00", "total_amount_atomic": "1100000000", "decimals": 6, "cost_envelope": { "version": "edut.quote_cost_envelope.v1", "checkout_currency": "USDC", "checkout_decimals": 6, "checkout_total_atomic": "1100000000", "checkout_total": "1100", "provider_fee_policy": "edut_absorbed", "provider_fee_included": true, "provider_fee_estimate_status": "absorbed_by_edut", "provider_fee_estimate_atomic": "0", "network_fee_policy": "payer_wallet_pays_chain_gas", "network_fee_currency": "ETH", "network_fee_estimate_status": "wallet_estimate_required", "network_fee_estimate_atomic": "0" }, "membership_activation_included": true, "line_items": [ { "kind": "license", "label": "EDUT Workspace Core", "amount": "1000.00", "amount_atomic": "1000000000", "decimals": 6, "currency": "USDC" }, { "kind": "membership", "label": "EDUT Membership Activation", "amount": "100.00", "amount_atomic": "100000000", "decimals": 6, "currency": "USDC" } ], "policy_hash": "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "access_class": "connected", "availability_state": "active", "expires_at": "2026-02-17T07:44:30Z", "tx": { "to": "0x2222222222222222222222222222222222222222", "data": "0xdeadbeef", "value": "0x0" } } ``` ### Notes 1. `amount`/`amount_atomic` represent the license component. 2. `total_amount`/`total_amount_atomic` represent the actual payable quote total. 3. First checkout can include membership activation as a separate line item. 4. `execution_profile.pacing_tier` distinguishes external human-governed cadence from native local-speed execution. Error (`403`): ```json { "error": "membership_required", "message": "Active membership is required for checkout." } ``` ## `POST /marketplace/checkout/confirm` Request: ```json { "quote_id": "cq_01HZZXFQ27ZP6MP0V2R9M6V3KX", "wallet": "0x3ea6cbf98d23e2cf7b6f4f9bb1fb4f50b710f2d5", "payer_wallet": "0x2299547f6fA9A8f9b6d9aEA9F9D8A4B53C8A0e11", "offer_id": "edut.workspace.core", "org_root_id": "org.acme.root", "principal_id": "human.joshua", "principal_role": "org_root_owner", "workspace_id": "workspace.work.acme.exec", "tx_hash": "0xbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb", "chain_id": 8453 } ``` Success (`200`): ```json { "status": "entitlement_active", "entitlement_id": "ent:8453:0x3ea6cbf98d23e2cf7b6f4f9bb1fb4f50b710f2d5:000001", "offer_id": "edut.workspace.core", "org_root_id": "org.acme.root", "principal_id": "human.joshua", "principal_role": "org_root_owner", "wallet": "0x3ea6cbf98d23e2cf7b6f4f9bb1fb4f50b710f2d5", "tx_hash": "0xbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb", "policy_hash": "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "access_class": "connected", "availability_state": "active", "activated_at": "2026-02-17T07:46:02Z" } ``` ## `GET /marketplace/entitlements?wallet=...` Success (`200`): ```json { "entitlements": [ { "entitlement_id": "ent:8453:0x3ea6cbf98d23e2cf7b6f4f9bb1fb4f50b710f2d5:000001", "offer_id": "edut.workspace.core", "wallet_address": "0x3ea6cbf98d23e2cf7b6f4f9bb1fb4f50b710f2d5", "workspace_id": "workspace.work.acme", "org_root_id": "org.acme.root", "state": "active", "access_class": "connected", "availability_state": "grace", "policy_hash": "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "issued_at": "2026-02-17T07:46:02Z" } ] } ```