Skip to content
For the complete documentation index optimized for AI agents, see llms.txt or llms-full.txt. A markdown version of this page is available by appending .md to the URL or sending Accept: text/markdown.

Quickstart

For AI agents: the documentation index is at llms.txt (full corpus: llms-full.txt). A markdown source for this page is /using-stacks/quickstart.md.

This quickstart gets you streaming live Solana data in a few minutes using the ORE demo — a real, deployed Arete stack for the ORE mining program. It’s the fastest way to see Arete in action.


Choose how you want to run the CLI:

Install the native binary via Cargo:

Terminal window
cargo install a4-cli

Then use the a4 command:

Terminal window
a4 create my-app

This is the same CLI — Cargo installs it as a4, and so does npm.


Terminal window
a4 create my-app

You’ll be prompted to select a template:

TemplateDescriptionRun Command
react-oreReact + Vite dashboardnpm run dev → open localhost:5173
typescript-oreTypeScript CLI clientnpm start
rust-oreRust + Tokio clientcargo run
Terminal window
a4 create my-app --template rust-ore # or react-ore, typescript-ore

One final step is required for the browser template: configure hosted authentication.

The React template connects to the hosted ORE stack. Add a publishable key to my-app/.env.local:

Terminal window
VITE_ARETE_PUBLISHABLE_KEY=hspk_...

The template passes this value to AreteProvider as auth={{ publishableKey }}. Authentication is required for hosted read-only viewing; a wallet is not.


The scaffolded app connects to a deployed Arete Stack — a streaming data pipeline that:

  1. Watches Solana for ORE mining program activity
  2. Transforms raw transactions into structured round data (round ID, motherlode, deployment totals)
  3. Streams updates to your app via WebSocket as they happen on-chain
1

Solana

ORE program

2

Arete

ORE stack

3

Your App

Live feed

No RPC calls. No polling. No custom indexer. Just streaming data.

In the TypeScript SDK mental model, the generated ORE stack is a cartridge and the Arete session is the console. The cartridge keeps its existing generated stack object and types; inserting it as ore makes it available at session.stacks.ore. The same console provides session.programs.<name> for standalone programs, session.chain for generic Solana reads, and session.execute(...) for prepared semantic operations.


TemplateCommandWhat You Get
react-orenpx @usearete/a4 create my-appReact + Vite dashboard showing live ORE mining rounds
typescript-orenpx @usearete/a4 create my-appTypeScript CLI that streams ORE data to your terminal
rust-orenpx @usearete/a4 create my-appRust + Tokio client streaming ORE round updates

All templates connect to the hosted ORE stack at wss://ore.stack.arete.run. Hosted connections are authenticated even when the data is read-only.

You can also specify the template directly:

Terminal window
npx @usearete/a4 create my-app --template react-ore

The React template uses @usearete/react with a generated stack definition:

App.tsx
import { AreteProvider } from "@usearete/react";
import { OreDashboard } from "./components/OreDashboard";
import { ORE_STREAM_STACK } from "./generated/ore-stack";
const publishableKey = import.meta.env.VITE_ARETE_PUBLISHABLE_KEY;
if (!publishableKey) throw new Error("VITE_ARETE_PUBLISHABLE_KEY is required");
export default function App() {
return (
<AreteProvider stack={ORE_STREAM_STACK} auth={{ publishableKey }}>
<OreDashboard />
</AreteProvider>
);
}
components/OreDashboard.tsx
import { useArete } from "@usearete/react";
import { ORE_STREAM_STACK } from "../generated/ore-stack";
export function OreDashboard() {
const arete = useArete(ORE_STREAM_STACK);
const board = arete.views.OreBoard.state.use({
address: arete.addresses.board(),
});
const roundId = board.data?.state.roundId;
const round = arete.views.OreRound.state.use(
roundId == null ? undefined : { roundId },
);
return (
<div>
<p>{arete.status === "connected" ? "Live" : arete.status}</p>
{arete.socketIssue && <p>{arete.socketIssue.message}</p>}
<p>
Round #{round.data?.id.roundId?.toString() ?? "..."} - Motherlode:{" "}
{round.data?.state.motherlode?.toString() ?? "..."}
</p>
</div>
);
}

ORE’s Board account is the authority for the active round. OreRound.latest remains available for recent-round history, but the live board follows OreBoard/state to keyed OreRound/state during rollover.

autoConnect is omitted because it defaults to true and controls only this initial connection. autoReconnect also defaults to true, independently, and controls recovery only after an established connection is lost.


Install Arete agent skills so your AI can write correct code without you looking up docs:

Terminal window
npx skills add AreteA4/skills

Now try asking your agent: “Show me the ORE mining round data in a table with live updates.”

See Build with AI for the full guide and prompt cookbook.


Now that you’ve seen Arete in action, where you go next depends on what you’re building:

Using an existing on-chain program that has a Arete stack?

Have your own on-chain program and want to stream its data?

Want to understand what’s happening under the hood?

Using an AI coding tool?

  • Build with AI — Let your agent write Arete code with the right context