Skip to content

Pay a robot

  1. Open the robot’s pay link. The owner finds it in the Income panel on the robot’s page. It looks like https://app.mova.build/pay/<robot id>.
  2. Connect a wallet that holds USDG and a little ETH on Robinhood Chain.
  3. Enter an amount, and optionally a note saying what it’s for.
  4. Click Pay and confirm in your wallet.

The money goes straight to the robot’s wallet. The payment shows on the robot’s page within about 20 seconds.

Send USDG on Robinhood Chain to the robot’s wallet address. The address is on the pay page and on the robot’s page.

A payment is a normal USDG transfer. Look up the robot’s wallet, then send to it.

import { createWalletClient, erc20Abi, http, parseUnits } from "viem";
import { privateKeyToAccount } from "viem/accounts";
const USDG = "0x5fc5360D0400a0Fd4f2af552ADD042D716F1d168";
const robotId = "7609796266404622865478520861685648070859553970607516824731969204689381529297";
// 1. Find the robot's wallet
const { robot } = await fetch(`https://app.mova.build/api/robots/${robotId}`).then((r) => r.json());
// 2. Pay it 4.20 USDG (6 decimals)
const account = privateKeyToAccount(process.env.PAYER_KEY);
const wallet = createWalletClient({
account,
transport: http("https://rpc.mainnet.chain.robinhood.com"),
chain: { id: 4663, name: "Robinhood Chain", nativeCurrency: { name: "Ether", symbol: "ETH", decimals: 18 }, rpcUrls: { default: { http: ["https://rpc.mainnet.chain.robinhood.com"] } } },
});
const hash = await wallet.writeContract({
address: USDG,
abi: erc20Abi,
functionName: "transfer",
args: [robot.wallet, parseUnits("4.20", 6)],
});
// 3. Optional: attach a note
await fetch("https://app.mova.build/api/payments/memo", {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify({ txHash: hash, machineId: robotId, memo: "Delivery, 1.8 km" }),
});

You can also read the wallet from peaq instead of the Mova API. It is the MovaWallet service endpoint in the robot’s identity.