Skip to main content
Capabilities give an agent something beyond its instructions and model. Choose the narrowest capability that fits the job. useModel() selects the model for a render, but it does not add an executable capability.

Tool or MCP server?

Use a code-defined tool when you own the operation, want a small schema, or need application-specific validation. Use an MCP server when another service already hosts the tools. Both ultimately give the model callable tools. A code-defined tool exposes the single operation you register; an MCP server exposes the tools it advertises.

Tool or skill?

A tool performs an operation and returns structured data. A skill teaches the agent how to approach a category of work. Many agents use both: the skill describes the workflow while tools perform the individual actions.

Session data or memory?

Session data describes the current session and is set by your application. Document memory keeps notes across sessions that agents can save and owners can edit. A tool that writes to your own database is a third option when the data belongs to your application rather than to the agent’s continuing work.

HTTP connections are not managed accounts

defineConnection() declares a secret-backed HTTP destination. It is not an OAuth account selector and does not itself give the model a tool. Call it from a code-defined tool or attach it to an MCP definition that accepts the declared authorization headers. The proposed HTTP memory provider contract uses the same connection mechanism. A managed GitHub App connection is the exception: the user installs OpenComputer’s App, chooses repositories in GitHub, and the eligible agent receives a short-lived installation token for direct Git and API calls. See Secrets and outbound requests for the complete security model.