Docs
SDK and MCP
A zero-dependency JavaScript module and an MCP endpoint, so your code or your agent can write and prepare strategies.
Get the SDK
One ES module, no dependencies, served by this site. It never holds keys: it builds transactions for your wallet to sign.
curl -O https://scriptcore.me/sdk/scriptcore.mjs
Use it
import { compile, buildRegister, listFires } from "./scriptcore.mjs";
const c = await compile("if HYPE.mark < 40 then buy 0.001 HYPE of KNTQ", { site: "https://scriptcore.me" });
if (!c.ok) throw new Error(`column ${c.error.col}: ${c.error.msg}`);
const tx = buildRegister({
code: c.code,
limits: {
expiry: BigInt(Math.floor(Date.now() / 1000) + 30 * 86400),
maxFires: 1,
cooldown: 0,
maxStaleness: 60,
keeperFee: 100000000000000n, // wei per fire
},
escrowWei: 2000000000000000n, // swap amount + fees, in wei
});
// tx = { to, data, value, chainId: 99901 }: sign it with any wallet
const fires = await listFires({}); // straight from the chainSDK reference
| Export | Does |
|---|---|
ADDRESSES | Every contract address on both chains. |
CHAINS | Chain ids, RPCs and explorers for Elysium and HyperEVM. |
compile(source, {site}) | The engine's compile result through the site: code, codeHash, bytes, venue, slots, actions, or an error with its column. |
buildRegister({code, limits, escrowWei}) | {to, data, value, chainId} for register(code, limits). limits: expiry, maxFires, cooldown, maxStaleness, keeperFee (wei). |
listStrategies({owner?, rpc?}) | Strategies from Registered events on Elysium. |
listFires({strategyId?, rpc?}) | Fires from Fired events, with values and transaction hashes. |
getStrategy(id, {rpc?}) | Live state and code of one strategy. |
decode(code), sourceOf(code) | Bytecode to its parts, and back to a readable line. |
MCP endpoint
A streamable HTTP MCP server (JSON-RPC 2.0 over POST) at https://scriptcore.me/api/mcp. It answers initialize, tools/list and tools/call.
claude mcp add --transport http scriptcore https://scriptcore.me/api/mcp
curl -s https://scriptcore.me/api/mcp -H 'content-type: application/json' \
-H 'accept: application/json, text/event-stream' \
-d '{"jsonrpc":"2.0","id":1,"method":"tools/call",
"params":{"name":"compile_strategy","arguments":{"source":"if HYPE.funding < 0 then close HYPE"}}}'Agentwrites a line from a goal
compile_strategybytes, slots, venue, or the exact column of an error
preview_strategylive values and the result right now
prepare_register{to, data, value, chainId}
Your walletyou read it, you sign it
MCP tools
| Tool | Arguments | Returns |
|---|---|---|
compile_strategy | source | The compile result, or the error and its column. |
preview_strategy | source | Connects to the live preview for about 3 seconds; the latest values and whether the condition is true. |
list_fires | limit?, strategyId? | Recent fires from the chain, with decoded source and values. |
get_strategy | id | State, limits, escrow and decoded source of one strategy. |
prepare_register | source, escrowHype, maxFires?, expiresInDays?, cooldown?, maxStaleness?, keeperFeeHype? | {to, data, value, chainId, summary} for your wallet to sign. |
prepare_register builds the Elysium registration. Strategies with HyperCore actions are enabled on your own executor instead; the steps are in the quickstart.
llms.txt
/llms.txt holds the grammar, the API, the MCP and SDK URLs and every address in one plain text file for models to read.