Write your tool

  1. In an editor, run the npx create-mosaia-tool command and answer the prompts. This will generate a tool codebase for you.

  2. Implement your tool call logic in ./src/index.ts and ./src/tool-call.ts

  3. Update the ./.mosaia manifest file.

    1. name is user-facing. It's the name of the tool that will be displayed in the tool registry.

    2. description is user-facing. It will also be displayed in the tool registry.

    3. schema is llm-facing. It tells the llm how to use your tool. It's identical to the tool call schema used by openai.

    4. envVars is an array of any environment variables that you want injected into the tool at call-time. The user adding this tool to their agent will be asked to supply these env vars. They are set on a per-agent basis.

  4. Push your code up to GitHub (has to be to the main branch)

  5. Our deployment pipeline will begin and deploy your tool to the Mosaia platform.

Last updated