Individual skill
openrouter-function-calling
Implement function/tool calling with OpenRouter models. Use when building agents, structured output, or tool-augmented LLM workflows. Triggers: 'openrouter function calling', 'openrouter tools', 'openrouter agent tools', 'tool use openrouter'.
skills/.curated/openrouter-function-calling/SKILL.md
Source commit 0500b275e963c027f6b410e8c49c0446945c574e
What was checked
- Matches the observed repository HEAD
- Yes
- Scanner rules are current
- No
- Repository scan complete
- No
- Skill scan complete
- No
- Observed behavior
- Not checked yet
- Last checked
- Nov 12, 2026
These are observations at the recorded commit, not a guarantee of safety. Review the source before running it.
Install this skill
Choose an agent in your Stack or copy a command below. Commands fetch the pinned commit and copy only this skill directory. Existing destinations are refused. Copying a command does not install anything.
An install command is unavailable: current rules, complete repository and skill scans, an eligible behavior level and a permitted license are required.
Repository context
- Repository stars (not skill ratings)
- 2,916
- Repository last updated
- Nov 12, 2026
- License
- MIT
Observed agent integration: No specific integration evidence. Standard SKILL.md installation does not imply verified compatibility.
- ai Repository topic
- automation Repository topic
- claude-code Repository topic
- devops Repository topic
- mcp Repository topic
- ai-agents Repository topic
- anthropic Repository topic
- claude-code-plugins Repository topic
- developer-tools Repository topic
- llm Repository topic
- saas Declared skill tag
- openrouter Declared skill tag
- function-calling Declared skill tag
- agents Declared skill tag
- tools Declared skill tag
- engineering Derived category
Files and excerpt
File metadata and permitted, redacted excerpts come from the recorded scan. Source links are pinned to that commit.
Browse files
SKILL.mdcore · 10,619 bytesSKILL.mdcore · 10,619 bytesSKILL.mdcore · 10,619 bytesSKILL.mdcore · 10,619 bytesSKILL.mdcore · 10,619 bytesreferences/advanced-tool-definitions.mddoc · 3,046 bytesreferences/basic-function-calling.mddoc · 3,080 bytesreferences/errors.mddoc · 478 bytesreferences/examples.mddoc · 4,484 bytesreferences/forced-tool-use.mddoc · 823 bytesreferences/model-compatibility.mddoc · 981 bytesreferences/parallel-tool-calls.mddoc · 1,135 bytesreferences/streaming-with-tools.mddoc · 2,000 bytesreferences/tool-router.mddoc · 1,459 bytes
Read excerpt
# OpenRouter Function Calling
## Overview
OpenRouter supports OpenAI-compatible tool/function calling across multiple providers. Define tools as JSON Schema, send them with your request, and the model returns structured `tool_calls` instead of free text. This works with GPT-4o, Claude 3.5, Gemini, and other tool-capable models via the same API. The key difference from direct provider APIs: OpenRouter normalizes the tool calling interface, so the same code works across providers.
## Prerequisites
- An OpenRouter API key (`sk-or-v1-...`) exported as `OPENROUTER_API_KEY` — see the `openrouter-install-auth` skill for setup
- Python 3.8+ or Node.js 18+ with the OpenAI SDK (`pip install openai` / `npm install openai`)
- A tool-capable model — check the Model Compatibility table below or query `/api/v1/models` (e.g., `openai/gpt-4o`, `anthropic/claude-3.5-sonnet`)
- Real function implementations to dispatch tool calls to (the `execute_tool()` dispatcher below stubs `get_weather` and `search_database`)
## Instructions