API Documentation

Custom Tools: Overview

A version is one build of your tool. Build your source, test a completed version, and publish it when ready. Versions use simple names such as v1, v2, and v3 everywhere.

Download .md for agents

Tool format

1my-custom-tool/
2├── Dockerfile      # Runtime environment and dependencies
3├── run.sh          # Starts your tool
4├── config.json     # Inputs and resource settings
5└── main.py         # Your code; other languages are fine
  • SDK/API builds require Dockerfile, run.sh, and config.json at the source root. main.py is optional; run.sh can invoke any language.
  • The working directory is /app. Scalar inputs arrive as environment variables; file inputs arrive as paths under /app/inputs/.
  • Write results to /app/out/.
  • Jobs have no network access. Install dependencies during the Docker build, outside /app: uploaded source replaces /app at runtime.

Full tool format details · Starter template

Building your custom tool

The SDK packages and uploads your files and protects against overwriting concurrent edits. Start with a new tool name and a folder containing Dockerfile, run.sh, and config.json.

1from tamarind import Tamarind
2
3with Tamarind(api_key = "***************", api_base="https://app.tamarind.bio/api/") as client:
4    tool = client.custom_tools.create("my-custom-tool", display_name="My Custom Tool")
5    build = tool.build("./my-custom-tool")
6    version = build.version.monitor(timeout=3600)
7    # Optional: test version.version with /submit-job before publishing (see below).
8    published_tool = version.publish()
9    print(published_tool.name, published_tool.default_version)

View Python SDK reference

Using your custom tool

Once a build is Complete, you can run it with /submit-job before publishing. Use an API key with access to the tool.

1POST https://app.tamarind.bio/api/submit-job
2x-api-key: YOUR_API_KEY
3Content-Type: application/json
4
5{
6  "jobName": "my-custom-tool-test",
7  "type": "my-custom-tool",
8  "version": "v1",
9  "settings": {
10    "sequence": "MKTAYIAKQRQISFVKSHFSRQ"
11  }
12}

Set type to your tool's name and version to the completed build's version (for example, v1). Replace settings with the inputs declared in your config.json; this example assumes an input named sequence. Choose a unique jobName for each run.

Publishing selects the default version. After publishing, omit version to run that default, or keep it to run a specific completed version.