{"service":"wever-pay-invoicing","version":"1.0.0","primitive":"invoice","network":"eip155:8453","chain_id":8453,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","max_invoice_atomic":"300000000","statuses":["open","paid","expired","cancelled"],"schemas":{"create_invoice":{"type":"object","additionalProperties":false,"properties":{"issuer_wallet":{"type":"string","pattern":"^0x[a-fA-F0-9]{40}(?![\\s\\S])"},"payer_wallet":{"type":"string","pattern":"^0x[a-fA-F0-9]{40}(?![\\s\\S])"},"payer_agent_id":{"type":"string","minLength":1,"maxLength":160},"amount_usdc":{"type":"string","pattern":"^(0|[1-9][0-9]{0,8})(\\.[0-9]{1,6})?(?![\\s\\S])"},"memo":{"type":"string","minLength":1,"maxLength":1000},"due_date":{"type":"string","pattern":"^20[0-9]{2}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}:[0-9]{2}Z(?![\\s\\S])"},"idempotency_key":{"type":"string","pattern":"^[A-Za-z0-9._:-]{1,128}(?![\\s\\S])"},"usage":{"enum":["synthetic","operational","unspecified"]}},"required":["issuer_wallet","amount_usdc","memo","idempotency_key"]},"get_invoice":{"type":"object","additionalProperties":false,"properties":{"invoice_id":{"type":"string","pattern":"^inv_[a-f0-9]{64}(?![\\s\\S])"}},"required":["invoice_id"]},"list_invoices":{"type":"object","additionalProperties":false,"properties":{"role":{"enum":["issued","received"]},"status":{"enum":["open","paid","expired","cancelled"]},"limit":{"type":"integer","minimum":1,"maximum":100},"cursor":{"type":"string","pattern":"^inv_[a-f0-9]{64}(?![\\s\\S])"}},"required":[]},"pay_invoice":{"type":"object","additionalProperties":false,"properties":{"invoice_id":{"type":"string","pattern":"^inv_[a-f0-9]{64}(?![\\s\\S])"},"idempotency_key":{"type":"string","pattern":"^[A-Za-z0-9._:-]{1,128}(?![\\s\\S])"},"payment_signature":{"type":"string","minLength":1,"maxLength":12000}},"required":["invoice_id","idempotency_key"]},"cancel_invoice":{"type":"object","additionalProperties":false,"properties":{"invoice_id":{"type":"string","pattern":"^inv_[a-f0-9]{64}(?![\\s\\S])"},"idempotency_key":{"type":"string","pattern":"^[A-Za-z0-9._:-]{1,128}(?![\\s\\S])"}},"required":["invoice_id","idempotency_key"]}},"pricing":{"pricesAtomic":{"/api/create_invoice":"100000","/api/get_invoice":"100000","/api/list_invoices":"100000","/api/pay_invoice":"100000","/api/cancel_invoice":"100000"},"freeTier":{"calls":10,"windowDays":30,"scope":"all_paid_endpoints","walletProofMaxAgeSeconds":300},"network":"eip155:8453","asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","scheme":"exact","x402Version":2,"principal_is_api_fee":false,"note":"0.10 USDC per tool call under the shared 10 free calls per signed wallet per rolling 30 days. Invoice principal is separate from the tool fee."},"wallet_proof":{"header":"X-Wever-Wallet-Proof","every_tool_call":true,"body_and_api_path_bound":true},"machine_endpoint":"https://weverlabs.com/mcp-invoices","human_page":"https://weverlabs.com/invoices/","settlement":"Existing x402 exact USDC on Base, paid directly by the designated payer to the issuer. A new paid result requires matching finalized settlement proof from two independent RPC providers, each using the existing observer. No new transfer contract or custody wallet.","settlement_verification":{"version":1,"providers":["base","tenderly"],"required_agreements":2,"finalized":true,"single_provider_fallback":false,"timeout_ms":7000,"observation_only":true},"direct_recovery":{"retained_source":"successful_facilitator_response","field":"submitted_transaction","persisted_before_confirmation":true,"bound_to_selected_operation":true,"immutable_hint":true,"proof_required":"both_finalized_rpc_providers","log_discovery_required_with_hint":false,"no_resubmission":true,"legacy_without_hint":"existing_bounded_discovery","note":"A retained hash is only a lookup hint. Direct verification failure stays pending. A crash or lost facilitator response before persistence can still require log discovery or operator proof."},"payment_signature":"Pass the principal x402 Payment-Signature encoding in the pay_invoice payment_signature argument. The HTTP Payment-Signature header remains reserved for the 0.10 USDC tool fee.","idempotency":"Keep the exact pay_invoice body, idempotency_key, payment_signature and wallet proof nonce on every retry. Refresh only the proof timestamp and signature. A paid invoice cannot be paid or cancelled again. A selected authorization stays locked until confirmed paid, proven expired and unused at a finalized Base block, or explicitly retired by the authorized operator after expiry. Retired operation keys can never select a payment again. Every approval retains the same invoice-bound USDC nonce.","payment_pending":"A settlement awaiting matching finalized proof from both RPC providers keeps status open with payment_pending true. It does not mean payment failed. Automatic recovery checks a retained facilitator transaction directly through both providers when available, without log discovery or submitting payments. Wait for payment_pending false before a fresh approval; its new operation key must retain the same invoice-bound authorization nonce.","challenge":"An unsigned pay_invoice call returns payment requirements and uses one tool call. Use a new idempotency key for the subsequent signed request. The human payment link exposes the same principal requirements without a billable tool call.","payer_identity":"Use a wallet address or the wallet-bound agent ID did:pkh:eip155:8453:<wallet>. Opaque IDs without a verified wallet binding are rejected.","sharing":"create_invoice returns a human payment link. Sharing that link permits viewing the amount, issuer, memo, due date and status; only authenticated parties can use private lookup and list tools. Tools do not email or message a recipient.","conditional_payments":{"human_page":"https://weverlabs.com/conditional-payments/","contract":"https://weverlabs.com/api/conditional-contract","note":"Use conditional payments for escrow terms. An invoice is a direct payment request and does not create escrow."},"capacity":{"max_retained_invoices":512,"max_business_operations":4096,"max_storage_bytes":4194304,"history_eviction":false,"note":"Admission stops at the first capacity bound; storage also reserves space for settlement completion. These are storage limits, not a concurrency or throughput guarantee."},"recovery":{"schedule":"*/2 * * * *","observation_only":true,"maximum_records_per_run":4,"concurrency":2,"maximum_scan_blocks_per_record":1000,"paid_evidence":"Finalized canonical receipt with matching USDC AuthorizationUsed and Transfer events, independently validated through both RPC providers and their existing observers.","release_evidence":"Finalized Base timestamp at or after authorization expiry and strict unused USDC authorizationState at that block, with canonical block rechecks.","after_release":"Open invoices can receive a fresh payer approval with a new operation key and the same immutable invoice nonce. Overdue invoices expire. Old payment operations remain permanently retired.","fees":"Automatic recovery makes no billable tool call and submits no payment. Normal tool pricing applies to a fresh payer approval."},"recovery_boundary":"A retained facilitator hash uses direct two-provider receipt checks. Without a retained hash, bounded scheduled observation advances a durable scan cursor beyond the old 2000-block window. RPC failure, reorg, malformed evidence, a cancelled nonce, or a used nonce without matching transfer keeps payment pending. Paid conclusions require agreement from both configured RPC providers. Scanning and unused-state conclusions retain the Base RPC check. Recovery never signs, resubmits or changes the invoice nonce.","operator_review":{"human_page":"https://weverlabs.com/invoices/operator/","api":"https://weverlabs.com/api/invoice-operator","authentication":"Owner-only email sign-in, separate secure session and CSRF protection. Wallet proof and tool fee payment do not grant operator authority.","actions":["unlock","expire","mark_paid"],"observation_only":true,"tool_fee_usdc":"0","queue_filters":{"path":"/api/invoice-operator/invoices","method":"GET","private":true,"read_only":true,"hold_age":["any","under_1h","1h_to_24h","over_24h","no_hold","unknown"],"verification":["unverified","confirmed","recorded","any"],"defaults":{"hold_age":"any","verification":"unverified"},"evidence_source":"retained_records","fresh_rpc_reads":false,"filter_before_pagination":true,"max_page_size":50,"max_records":512,"cursor_bound_to_filters":true,"age_clock_pinned":true,"snapshot_lifetime_seconds":900,"refresh_on_record_change":true,"confirmed_requires":"recorded_matching_two_provider_finalized_settlement","paid_records_require_explicit_filter":true},"facilitator_transactions":{"private":true,"response_field":"facilitator_transaction","source":"retained_facilitator_response","unverified_by_default":true,"confirmation_requires":"matching_two_provider_finalized_settlement","review_confirmation_changes_invoice":false,"history_verification_at_decision":true,"automatic_decision_or_prefill":false,"note":"A retained transaction is a lookup hint. A matching two-provider preview is labeled separately from recorded settlement. Earlier decisions retain their original verification label."},"unlock":"After the selected approval expires plus 30 seconds, an operator can retire it with a recorded reason. This is an administrative decision, not proof of nonpayment. A fresh payer approval must retain the same invoice nonce.","expire":"After the selected approval expires plus 30 seconds, an operator can close the request with a recorded reason. A previously settled transfer may still be recorded paid if later proven.","mark_paid":"Requires a finalized canonical Base native-USDC receipt with the exact invoice nonce, payer, issuer and amount, matching a current or retained approval interval and independently confirmed by both RPC providers with the existing observer. A transaction hash alone is not proof.","audit":"Every successful resolution is persisted atomically with actor, reason, revision, prior state and evidence. Retired operations never select again. Every retained decision can be inspected through newest-first, snapshot-stable pages of up to 50 entries.","history":{"path":"/api/invoice-operator/history","method":"POST","read_only":true,"max_page_size":50,"snapshot_stable":true,"cursor_bound_to_invoice":true,"refresh_to_include_newer":true},"bounds":"Paid invoices are terminal. Stale reviews and conflicting idempotency keys reject. Decisions do not sign, submit, resubmit, refund or charge. Capacity can reject a nonpaid decision before mutation; paid-proof completion space is preserved."},"evidence":{"real_money_acceptance":false,"synthetic_tests":true,"concurrent_payment_requests_tested":8}}