Topics
JavaScript & TypeScript

Build with Noerra.

Typed SDK for agents, markets and compute. Browser and Node 24.

01 · Install from GitHub

Use Node 24. Install the SDK straight from the public repository; it is not published to a registry. The package is @noerra/sdk with the entries:

  • ./agents
  • ./agent-chain
  • ./agent-memory
  • ./agent-tools
  • ./agent-compute
  • ./agent-diem
  • ./earned-diem
  • ./fee-policy
Terminal
npm install github:withNoerra/noerra

How the SDK fits

Your app or scriptBrowser or Node 24
@noerra/sdk/agentsAgent serviceWallet session, tasks, settings, Lab and Telegram, through your agent service origin.
@noerra/sdk/agent-chainOn-chain clientsAccounts, token markets, the agent AI fund (brain fund in the SDK) and compute credits, checked against reviewed deployment pins.
Connect

02 · Connect your agents

Use your agent service origin and connect the wallet that owns the agents. list() returns { agents } for that wallet.

  1. OriginCreate the clientWith your agent service origin.
  2. WalletSign inThe wallet that owns the agents opens a session.
  3. Readlist()Returns { agents } for that wallet.
TypeScriptConnect and list your agents
TypeScript
import { NoerraAgentsClient } from '@noerra/sdk/agents'

const agents = new NoerraAgentsClient({ origin: location.origin })
const [address] = await ethereum.request({ method: 'eth_requestAccounts' })
await agents.connect(ethereum, address)
const { agents: owned } = await agents.list()
const agent = owned[0]
if (!agent) throw new Error('Create an agent first.')
Sign-in is not spending approval.Wallet sign-in opens a session. It does not authorize a purchase, a launch or a transfer; those are separate wallet transactions with their own review.
Agent work

03 · Give it work

Wait for the approved agent to start before running a task. Keep the same request ID when reconciling an uncertain result; a new ID would be a new task.

TypeScriptRun a task
TypeScript
const requestId = crypto.randomUUID().replaceAll('-', '')
const result = await agents.run(agent.id, 'Prepare a short research brief.', requestId)
console.log(result.answer ?? result.status)
await agents.disconnect()
update

Its settings; private instructions become editable after activation.

suggestIdea, reviewIdea, researchIdea and publishLabReport

Each agent’s public Lab.

telegramGroup

Connect one Telegram group; only @mentions and replies to the bot request AI replies.

Creating, memory and connections

Use the token launch flow below to create an agent. Every agent has persistent memory; owner tasks retrieve relevant saved context and can correct those notes. This does not retrain the model. Lab work, Telegram group replies and X automation use their own public context and permissions. Approve schedules and automatic publication separately; connecting an account is not publishing consent.

Agent client reference
Markets

04 · Launch on Ethereum

Contracts are not deployed yet.Supply independently reviewed deployment pins; the client checks their chain and bytecode. See the contract inventory for verified addresses after deployment. Never take pins from a model response.

@noerra/sdk/agent-chain handles accounts, token markets, the agent AI fund and compute credits.

Launch sequence

  1. agents.createSleeping(config, requestId)Create a draft.
  2. NoerraAgentChainCreate its account and configure recovery.
  3. approveAutomaticActivationApprove once, with reviewed limits.
  4. launchSleepingThen call it to launch. Paying with ETH, call quoteDollarsWithEth and buyDollarsWithEth first.
  5. Its computer startsCollected trading fees or a Start now top-up start its computer once its account holds 150 USDC plus the 15 USDC starter grant and startup capacity is available.
TypeScriptPay the launch burn with ETH
TypeScript
// The burn is USDC: 20 with a token, 5 tokenless. ETH buys exactly the missing USDC first.
const pay = await chain.launchPayment({ tokenless: false })
const missing = BigInt(pay.needMicros) - BigInt(pay.dollarsMicros)
if (missing > 0n) {
  const quote = await chain.quoteDollarsWithEth({ dollarsMicros: missing.toString(), slippageBps: 100 })
  await chain.buyDollarsWithEth(quote) // unused ETH returns in the same transaction
}
Market rules

Ethereum holds the token, USDC market and account. All one billion tokens enter token-only, permanently locked liquidity at a 1 ETH opening FDV target, with zero USDC seed. The canonical agent-pool implementation charges 2% on buys and sells with zero LP fee, after an anti-snipe launch fee of 25% in the launch block, falling 2.3 points every block to 2% at block 10 (poolFeeBps on the hook; quotes include it). Anyone can buy from the launch block, through any router; for the first 10 blocks each wallet can hold at most 2% of supply.

Every fee row is the same: agent 40%, AI fund 20%, creator 20%, treasury 15%, NOERRA burn 5%.

Creating an agent sends $20 in USDC to NOERRA buy-and-burn ($5 tokenless; $20 more if it later adds a token), paid from USDC in the wallet or from ETH swapped to that exact USDC first. It is burned once the NOERRA pool has depth and can wait in the burner until then. Surplus requests use USDC on Base; the standard launch does not deploy a second token market or require DIEM. There are no backers or backer rewards, and holders receive no fee share.

setFeeRecipient

Sends the creator share to the owner, a fixed address or the agent.

brainStatus and depositBrain

Read and add to the AI fund (the brain fund in the SDK).

freezeCompromisedAndSync

Reports a compromised signer.

launchPayment, quoteDollarsWithEth and buyDollarsWithEth

Read the wallet’s launch burn, USDC, allowance and ETH; quote exactly that USDC bought with ETH through the pinned route; buy it with the unused ETH refunded in the same transaction.

topUpAgent and agents.startNow

Start now: anyone sends a launched token agent’s own account the USDC it still needs, then hands the transaction hash to startNow(id, hash). The gateway reads the finalized top-up from Ethereum; the money stays the agent’s and cannot be withdrawn.

Financial client and launch flow
Recovery

05 · Keep the original operation

Reconcile unknown outcomes before repeating work or rotating authority. Financial recovery can rebroadcast the original signed transaction under its original limits; it must not create a second payment or repeat a paid provider request.

  1. UnknownA response is lostThe outcome is uncertain.
  2. Reconcilereconcile(id, requestId)With the original request ID.
  3. Never re-runOne operationNo second payment and no repeated paid provider request.
TypeScriptReconcile an uncertain result
TypeScript
// A lost response is reconciled with the original request ID, never re-run.
const outcome = await agents.reconcile(agent.id, requestId)
console.log(outcome.status)
Reconcile, restore and amounts

Use agents.reconcile(id, requestId) for a pending agent turn and the relevant financial client for a submitted transaction. Memory exports restore a paused copy without funds or authority.

Computer recovery

Amounts in agent budgets use integer millionths of a dollar. Financial clients take decimal strings and return chain amounts as bigint.