AgSuranceNEAR TESTNET

From policy to payout

Open the public transaction receipts for two completed claims on NEAR testnet.

Verify both testnet claims

Clone the AgSurance repo and run this command from its root with Bun. Each successful check prints PASS.

bun run verify:receipts

0.25 NEAR CLI replay

Follow one policy on NEAR testnet, from enforcing a spending rule to paying a claim for a separate simulated loss.

Payment blocked
0.01 NEAR attempted
Approved supplier paid
0.05 NEAR sent
Claim reimbursed
0.25 NEAR paid

CLI transaction receipts

  1. Activate the policy

    The owner records the supplier and sets a 0.05 NEAR spending limit.

  2. Connect the agent

    The owner grants the agent permission to call the vault.

  3. Reject a payment outside the mandate

    The CLI requests 0.01 NEAR to the recovery account. The wallet rejects the request and sends no funds.

  4. Pay the approved supplier

    The same CLI agent pays 0.05 NEAR to the supplier in the mandate.

  5. Record a simulated loss

    The demo runner sends 0.30 NEAR to a separate test incident account.

  6. File and review the claim

    The agent files from the CLI. Two reviewers approve the same final loss receipt.

  7. Pay 0.25 NEAR

    The reserve pays the recovery account after a 0.05 NEAR deductible.

Policy and account IDs
Claim ID
vault.agsurance-7910a4d8.testnet/1
Approved supplier
supplier.agsurance-7910a4d8.testnet
Simulated loss recipient
incident.agsurance-7910a4d8.testnet
Recovery account
recovery.agsurance-7910a4d8.testnet

Why the second claim paid 0.18 NEAR

In this separate testnet run, the policy limit rose before the claim was filed. The payout used the limit in force at the block where the loss occurred.

  1. 0.18 NEAR limit at the simulated loss

    A simulated transfer of 0.30 NEAR executed in block 277,218,273.

  2. New limit of 0.42 NEAR

    The reserve booked the additional capacity. The vault confirmed the increase in block 277,218,292, effective from block 277,218,293.

  3. 0.18 NEAR paid after the increase

    The agent filed after the increase. Two reviewers approved the earlier receipt, and the reserve paid the limit that applied to that transfer.

Try AgSurance with your wallet

Connect a NEAR testnet wallet to set up an insured agent account or fund the capital pilot.

Get testnet NEAR from the faucet ยท View a completed demo

Connect an agent

  1. Buy a policy with the owner wallet.
  2. From the frontend repo in the agent runtime, install dependencies with Bun and create a key.
    bun install --frozen-lockfilebun scripts/agent.ts init .agsurance-agent.key
  3. Copy the public key the CLI prints. Paste it under Connect Agent in your policy dashboard and approve the wallet transaction. Keep the private key file in the agent runtime.
  4. Once the dashboard confirms the connection, use the vault ID to check the policy or file a claim after a recorded loss.
    bun scripts/agent.ts status YOUR_VAULT.testnetbun scripts/agent.ts submit-claim YOUR_VAULT.testnet .agsurance-agent.key
Open the CLI setup instructions

Replay the shared reserve claim

See a separate testnet scenario where a reserve shortfall held up reimbursement. No wallet or sign-in required.

Open the interactive replay
Duplicate invoice simulation (optional)

A scripted agent stands in for one affected by prompt injection. It requests two payments for one invoice. The simulation runs in your browser with a mock ledger.

Approved supplier
Demo supplier
Invoice INV-1042
0.05 NEAR due
Total spending limit
0.12 NEAR

See the separate testnet claim and payout receipts