Hire and Pay
hire_and_payOne-call shortcut to register an escrow vault AND get the ready-to-sign transaction.
This combines create_escrow_vault() + prepare_escrow() into a single call. The agent only needs to sign the returned transaction and confirm it — no manual XRPL transaction construction required.
Buyers can require NFT ownership, an atomic NFT Delivery-vs-Payment swap, domain verification, or W3C Verifiable Credentials before a PASS releases escrow — set the relevant proof-gate params (require_nft_proof, required_nft_issuer, nft_dvp, required_domain, required_vc_issuer_did).
White-label / headless integration:
Pass callback_url to receive webhook POSTs on all state changes.
Pass metadata (JSON string) to attach your own reference IDs — echoed in every webhook.
Typical flow:
hire_and_pay() — register vault, get ready-to-sign EscrowCreate tx
Sign transaction with your wallet and submit to XRPL
confirm_escrow_transaction(escrow_id, tx_hash) — activate the vault
Worker submits work, agent calls evaluate_escrow_work() to release payment
Returns: escrow_id, transaction (ready-to-sign), condition, cancel_after_human, next_step instructions.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| task | Yes | Detailed description of what the worker must deliver. The AI referee evaluates against this — be precise. | |
| nft_dvp | No | Atomic NFT swap: worker must transfer a specific NFT to the buyer before payment releases. On PASS the vault enters PASS_AWAITING_NFT; worker registers their NFTokenCreateOffer and payment auto-releases when buyer accepts. | |
| fee_hash | No | 64-char hex hash of your $0.10 payment (XRP/RLUSD/USDC) to rmcSrkpZ2i2kuvtCPeTVetee9SixP4djR. Omit to use free tier (if eligible). | |
| metadata | No | Optional JSON string of key/value pairs to attach to this escrow and echo back in every webhook payload. Use to round-trip your own reference numbers (invoice_id, po_number, tenant_id, order_ref, etc.). Example: '{"invoice_id": "INV-2026-0042"}'. | |
| escrow_id | Yes | Unique receipt code for this escrow, e.g. AT-7X9K-2MQ4. Must be unique. | |
| amount_xrp | Yes | Amount of XRP to lock in escrow as the bounty. | |
| buyer_name | No | Your name or agent identifier. | |
| callback_url | No | HTTPS endpoint on your server to receive webhook POST notifications on escrow state changes (funded, PASS, FAIL, expired). Use this for white-label integrations where you handle all user-facing surfaces yourself. Payload: {escrow_id, event, verdict, timestamp, metadata}. | |
| proof_policy | No | When multiple proof gates are set: 'ALL' (default) requires every gate to pass; 'ANY' requires at least one. | ALL |
| buyer_address | Yes | Your XRPL wallet address (r...) — you are the buyer. | |
| worker_address | Yes | XRPL address (r...) of the worker to hire directly. Get this from direct_hire() or award_job(). | |
| required_domain | No | Worker must have their XRPL wallet domain field pointing to this domain. Pass 'ANY' to require any verified domain. | |
| cancel_after_hrs | No | Hours until escrow auto-cancels if worker doesn't deliver. Default 168 = 7 days. | |
| require_consensus | No | Require consensus between Gemini Flash AND Gemini Pro. Both must agree on PASS; split verdict returns conservative FAIL. Fee: $0.25 (vs $0.10 standard). | |
| require_nft_proof | No | Worker must own an NFT from any trusted issuer (or from required_nft_issuer if set) to receive payment. | |
| required_nft_issuer | No | Restrict NFT proof to NFTs minted by this XRPL wallet address. | |
| required_vc_issuer_did | No | Worker must present a W3C Verifiable Credential JWT issued by this DID. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||