{"openapi":"3.1.0","info":{"title":"AutoMining Company Evidence API","version":"0.6.2","description":"Resolve legal entities from official GLEIF records. Full evidence includes addresses, aliases, registration dates, ownership records or reporting exceptions, and a normalized entity digest."},"servers":[{"url":"https://ard-telegram-revenue.automining-engine.workers.dev"}],"paths":{"/v1/purchase/config":{"get":{"summary":"Read direct browser checkout terms; this does not request a payment.","responses":{"200":{"description":"Merchant, exact amount, asset, network and new-purchase state."},"503":{"description":"Purchases disabled."}}}},"/v1/monitors/create":{"post":{"summary":"Schedule one snapshot per 24 hours using an already settled USDT/TRC20 order.","description":"Private order_id acts as a bearer credential. Explicit consent to one prepaid credit per successful snapshot is mandatory. Unchanged evidence still uses one credit; failed or unresolved evidence does not. Creation does not debit a credit. Stop and balance exhaustion prevent new snapshots. No automatic top-up or owner spending.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["order_id","monitor_id","company","accept_daily_credit"],"properties":{"order_id":{"type":"string","format":"uuid","description":"A private random UUIDv4 generated by the buyer. Keep it confidential."},"monitor_id":{"type":"string","format":"uuid"},"company":{"type":"object","additionalProperties":false,"properties":{"lei":{"type":"string","description":"A checksum-valid 20-character LEI."},"legal_name":{"type":"string"},"jurisdiction":{"type":"string","description":"ISO jurisdiction code. Required with legal_name."},"registration_number":{"type":"string"}},"anyOf":[{"required":["lei"]},{"required":["legal_name","jurisdiction"]}]},"accept_daily_credit":{"const":true}}}}}},"responses":{"200":{"description":"Same monitor already exists."},"201":{"description":"Scheduled; poll the private status endpoint for the latest report."},"402":{"description":"Prepaid balance exhausted."},"422":{"description":"Invalid request or missing explicit daily credit consent."},"429":{"description":"Capacity limit reached."},"503":{"description":"New work paused or disabled."}}}},"/v1/monitors/status":{"post":{"summary":"Privately read scheduled monitors and latest reports for one settled order.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["order_id"],"properties":{"order_id":{"type":"string","format":"uuid","description":"A private random UUIDv4 generated by the buyer. Keep it confidential."},"monitor_id":{"type":"string","format":"uuid"}}}}}},"responses":{"200":{"description":"Monitor states, source failures, successful snapshot count and latest report."},"404":{"description":"No such settled order."}}}},"/v1/monitors/stop":{"post":{"summary":"Stop a monitor without authorizing any new credit use.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["order_id","monitor_id"],"properties":{"order_id":{"type":"string","format":"uuid","description":"A private random UUIDv4 generated by the buyer. Keep it confidential."},"monitor_id":{"type":"string","format":"uuid"}}}}}},"responses":{"200":{"description":"Monitor remains stopped on repeated requests."},"404":{"description":"No such settled order."}}}},"/v1/ai/status":{"get":{"summary":"Read the bounded model evaluation results; this is not a global accuracy ranking.","responses":{"200":{"description":"Binding state, fixed-case scores and daily reservation ceiling."}}}},"/v1/portfolio/sample":{"get":{"summary":"Inspect a free public-record example or a clearly labeled synthetic ambiguity case.","parameters":[{"name":"case","in":"query","required":true,"schema":{"enum":["exchange","bank","ambiguity"]}}],"responses":{"200":{"description":"Evidence with source URLs, retrieval times and explicit matching outcome."},"422":{"description":"Invalid or unresolved input. A paid credit is not consumed."},"502":{"description":"Source evidence could not be verified. A paid credit is not consumed."},"503":{"description":"Service or payment processing is unavailable."}}}},"/v1/inquiries":{"post":{"summary":"Request integration guidance without an email address or payment authorization.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["use_case","volume"],"properties":{"use_case":{"enum":["agent_integration","supplier_identity","bulk_data"]},"volume":{"enum":["1-100","101-1000","1000+"]}}}}}},"responses":{"200":{"description":"Fixed offer facts and optional, separately labeled AI tips."},"422":{"description":"Unsupported inquiry fields."},"429":{"description":"Daily inquiry limit reached."},"503":{"description":"Service stopped or unavailable."}}}},"/v1/agent/health":{"get":{"summary":"Read Base network and free-settlement readiness without paying.","responses":{"200":{"description":"Correct Base chain, finalized block and available free quota."},"503":{"description":"Service stopped, free quota exhausted or dependency unavailable."}}}},"/v1/agent/company-evidence":{"get":{"summary":"Buy one company evidence report for 0.02 USDC on Base.","description":"x402 v2. An unpaid request returns PAYMENT-REQUIRED. Retry with the signed PAYMENT-SIGNATURE. The same authorization is bound to one company and returns the cached report on retry. New purchases use PayAI free credits, then sponsored xpay settlement if those credits are exhausted or unavailable. No automatic top-ups. Pending payments retain their original facilitator. MCP clients can use company_evidence at /mcp with _meta[\"x402/payment\"].","parameters":[{"name":"lei","in":"query","schema":{"type":"string"}},{"name":"legal_name","in":"query","schema":{"type":"string"}},{"name":"jurisdiction","in":"query","schema":{"type":"string"}},{"name":"registration_number","in":"query","schema":{"type":"string"}}],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.020000"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Evidence with source URLs, retrieval times and explicit matching outcome."},"402":{"description":"Standard x402 v2 payment challenge, no money moved."},"409":{"description":"Payment pending. Retry with the identical signature and input."},"422":{"description":"Invalid or unresolved input. A paid credit is not consumed."},"502":{"description":"Source evidence could not be verified. A paid credit is not consumed."},"503":{"description":"Service or payment processing is unavailable."}}}},"/v1/company/example":{"get":{"summary":"Read a real full-evidence example without consuming credit.","responses":{"200":{"description":"Evidence with source URLs, retrieval times and explicit matching outcome."},"422":{"description":"Invalid or unresolved input. A paid credit is not consumed."},"502":{"description":"Source evidence could not be verified. A paid credit is not consumed."},"503":{"description":"Service or payment processing is unavailable."}}}},"/v1/company/preview":{"post":{"summary":"Resolve an LEI or an exact legal name and jurisdiction.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"lei":{"type":"string","description":"A checksum-valid 20-character LEI."},"legal_name":{"type":"string"},"jurisdiction":{"type":"string","description":"ISO jurisdiction code. Required with legal_name."},"registration_number":{"type":"string"}},"anyOf":[{"required":["lei"]},{"required":["legal_name","jurisdiction"]}]}}}},"responses":{"200":{"description":"Evidence with source URLs, retrieval times and explicit matching outcome."},"422":{"description":"Invalid or unresolved input. A paid credit is not consumed."},"502":{"description":"Source evidence could not be verified. A paid credit is not consumed."},"503":{"description":"Service or payment processing is unavailable."}}}},"/v1/company/evidence/quote":{"post":{"summary":"Request an invoice for prepaid evidence credits.","description":"Pay the exact quoted amount from payer_address using USDT on TRON. Each credit has a candidate price of 0.02 USDT, purchased in packs. Sender network fees are external to the quote.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["order_id","payer_address"],"properties":{"order_id":{"type":"string","format":"uuid","description":"A private random UUIDv4 generated by the buyer. Keep it confidential."},"payer_address":{"type":"string"},"credits":{"type":"integer","enum":[250,500,1000],"default":250}}}}}},"responses":{"200":{"description":"Previously settled invoice."},"402":{"description":"Invoice with exact amount, recipient, token contract, expiry and settlement route."},"503":{"description":"Payment processing is disabled or unavailable."}}}},"/v1/company/evidence/settle":{"post":{"summary":"Verify an already-broadcast buyer transfer and activate credits.","description":"This endpoint reads a solidified TRON receipt. Successful verification binds the transfer to one invoice.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["order_id","tx_id"],"properties":{"order_id":{"type":"string","format":"uuid","description":"A private random UUIDv4 generated by the buyer. Keep it confidential."},"tx_id":{"type":"string","pattern":"^[a-fA-F0-9]{64}$"}}}}}},"responses":{"200":{"description":"Verified settlement and remaining prepaid credits."},"409":{"description":"Transfer is not solidified, or settlement conflicts with an existing record."},"422":{"description":"Receipt does not match the invoice, payer, recipient, token, amount or time window."},"503":{"description":"Payment processing is disabled or unavailable."}}}},"/v1/company/evidence":{"post":{"summary":"Retrieve full evidence using a settled invoice.","description":"One resolved report consumes one credit. Repeating a successful request_id with the same input returns its stored report. Conflicting or unavailable evidence does not consume credit.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["order_id","request_id","company"],"properties":{"order_id":{"type":"string","format":"uuid","description":"A private random UUIDv4 generated by the buyer. Keep it confidential."},"request_id":{"type":"string","format":"uuid"},"company":{"type":"object","additionalProperties":false,"properties":{"lei":{"type":"string","description":"A checksum-valid 20-character LEI."},"legal_name":{"type":"string"},"jurisdiction":{"type":"string","description":"ISO jurisdiction code. Required with legal_name."},"registration_number":{"type":"string"}},"anyOf":[{"required":["lei"]},{"required":["legal_name","jurisdiction"]}]}}}}}},"responses":{"200":{"description":"Evidence with source URLs, retrieval times and explicit matching outcome."},"402":{"description":"A verified payment or additional prepaid credit is required."},"409":{"description":"The request_id was already used with different company criteria."},"422":{"description":"Invalid or unresolved input. A paid credit is not consumed."},"502":{"description":"Source evidence could not be verified. A paid credit is not consumed."},"503":{"description":"Service or payment processing is unavailable."}}}}}}