Calls a common FT view method against the active contract.
await near.view({ contractId: app.contractId, methodName: "ft_total_supply", args: {} })
FastNear JS gives agents and developers a fast path from a NEAR data question to a working answer. Start with copyable snippets; open the docs only when you need the full reference.
Open DevTools and paste any of these. They reference app.contractId,
so they follow whatever target contract is set via the ⚙ gear in the navbar —
change it once, and these snippets retarget.
Calls a common FT view method against the active contract.
await near.view({ contractId: app.contractId, methodName: "ft_total_supply", args: {} })
Reads get_account for the signed-in account — swap the argument for any account id.
await near.view({
contractId: app.contractId,
methodName: "get_account",
args: { account_id: nearWallet.accountId() },
})
Template for any signed transaction — replace methodName and args.
await nearWallet.sendTransaction({
receiverId: app.contractId,
actions: [{
type: "FunctionCall",
params: {
methodName: "your_method",
gas: near.utils.convertUnit("100 Tgas"),
deposit: "0",
args: {},
},
}],
})
Use these lower-level FastNear families when the question is about direct RPC, indexed transactions, transfers, recent blocks, or contract storage history.
These links connect the JS quickstart to the full FastNear docs for RPC, indexed APIs, auth, and agent workflows.
These task helpers are layered on top of the lower-level APIs and come from the same
machine-readable catalog behind recipes.json, llms.txt, and
the terminal wrapper.
The same FastNear JS runtime driving a live app — a berry.fast board crop and wallet-backed Berry Club actions (or a testnet counter on testnet).
Loading live berry.fast crop…
Connect any wallet to try draw or buy_tokens on
berryclub.ek.near — all from the browser.
The same library you used in the terminal — now driving a browser app.
—
Target contract —. Use the browser DevTools console
with near.view({ contractId: app.contractId, … }) for reads and
nearWallet.sendTransaction({ receiverId: app.contractId, … }) for writes.