load-official-blueprint
Load predefined blueprints on Flux MCP server by specifying blueprintName and processId, enabling AI-powered creation, running, and testing of code and handlers in Arweave OS.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| blueprintName | Yes | ||
| processId | Yes |
Input Schema (JSON Schema)
{
"$schema": "http://json-schema.org/draft-07/schema#",
"additionalProperties": false,
"properties": {
"blueprintName": {
"type": "string"
},
"processId": {
"type": "string"
}
},
"required": [
"blueprintName",
"processId"
],
"type": "object"
}
Implementation Reference
- src/mcp.ts:217-231 (registration)Registration of the 'load-official-blueprint' tool including name, description, Zod input schema, and inline handler function.this.server.tool( "load-official-blueprint", "load an official blueprint in an existing AO process", { blueprintName: z.string(), processId: z.string() }, async ({ blueprintName, processId }) => { const result = await addBlueprint( blueprintName, processId, this.signer ); return { content: [{ type: "text", text: cleanOutput(result) }], }; } );
- src/mcp.ts:221-230 (handler)The handler function that implements the tool logic by invoking addBlueprint and formatting the response.async ({ blueprintName, processId }) => { const result = await addBlueprint( blueprintName, processId, this.signer ); return { content: [{ type: "text", text: cleanOutput(result) }], }; }
- src/mcp.ts:220-220 (schema)Input schema using Zod for blueprintName and processId parameters.{ blueprintName: z.string(), processId: z.string() },
- src/helpers/blueprint.ts:9-18 (helper)Core helper function that fetches the official blueprint Lua code from GitHub and loads it into the specified AO process.export async function addBlueprint( blueprintName: string, processId: string, signer: any ) { const url = `https://raw.githubusercontent.com/permaweb/aos/refs/heads/main/blueprints/${blueprintName}.lua`; const code = await fetchBlueprintCode(url); const result = await runLuaCode(code, processId, signer); return result; }