opencode-build-tool

Create custom tools and plugins for OpenCode using the SDK.

9|Updated Feb 21, 2026
One-click install
npx skills add https://github.com/pantheon-org/tekhne --skill opencode-build-tool
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: opencode-build-tool
Source: https://github.com/pantheon-org/tekhne/tree/main/skills/agentic-harness/opencode-toolkit/build-tool
Command: npx skills add https://github.com/pantheon-org/tekhne --skill opencode-build-tool

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) and assets (resource) components.

What problem does it solve?

This Skill simplifies the process of creating and integrating custom tools and plugins with the OpenCode development environment, enabling enhanced automation and custom functionality.

Core Features & Use Cases

  • Tool Creation: Define and implement custom tools using the OpenCode SDK and plugin system.
  • Plugin Development: Build custom plugins to extend OpenCode's capabilities with hooks and event handling.
  • SDK Integration: Automate OpenCode workflows from external scripts or CI/CD pipelines.
  • Use Case: You need to create a new tool that can interact with an external API. This Skill guides you through defining the tool's schema, implementing its execution logic, and ensuring it's discoverable by OpenCode.

Quick Start

Create a new tool by defining a tool() function in a .ts file within the .opencode/tool/ directory.

Frequently Asked Questions about opencode-build-tool

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I build a custom tool for OpenCode using TypeScript?

To build a custom OpenCode tool, define a `tool()` function in a `.ts` file within the `.opencode/tool/` directory. You define the tool schema using Zod, implement an execute handler, and manage sessions for deterministic task automation.

Can I integrate external APIs as first-class tools in OpenCode?

Yes, you can integrate external APIs as first-class tools in OpenCode. The Skill guides you through defining the tool schema, implementing its execution logic, and ensuring it is discoverable by the OpenCode environment.

What is the best way to automate OpenCode workflows from a CI/CD pipeline?

The best way to automate OpenCode workflows in CI is using the opencode-ai/sdk package. It supports automating external scripts, handling abort signals, and executing deterministic tasks without manual intervention.

Does OpenCode plugin development support event handling and hooks?

Yes, OpenCode plugin development supports event handling and hooks. You can build custom plugins using the opencode-ai/plugin package to extend OpenCode's capabilities with custom hooks and event-driven logic.

Do I need Zod to define tool schemas in the OpenCode environment?

Yes, Zod is used for defining tool schemas in the OpenCode environment. It allows you to validate inputs for your custom tools before executing the handler logic for deterministic automation tasks.