PR

prompt_to_production

A guided workshop for developers learning the Gemini Interactions API for agent development.

Install

mkdir -p .claude/skills/prompt-to-production && curl -L -o skill.zip "https://agentskills.codes/api/skills/download/13828" && unzip -o skill.zip -d .claude/skills/prompt-to-production && rm skill.zip

Installs to .claude/skills/prompt-to-production

Activation

This is the description your AI agent reads to decide when to run this skill — the better it matches your request, the more reliably it fires.

A complete workshop curriculum for building an agentic application using the Gemini Interactions API. Guides the user from basic API calls to a full production coding agent.
173 charsno explicit “when” trigger
Intermediate

Key capabilities

  • Instantiate the client and make basic `interactions.create` calls.
  • Apply configurations like `thinking_level` to the model.
  • Provide the model with a JSON schema for a tool.
  • Refactor stateless methods to use server-side state with `previous_interaction_id`.
  • Wrap `interactions.create` calls in a `while (status === "requires_action")` loop.
  • Integrate built-in tools like Google Search.

How it works

The skill guides users through a workshop curriculum, demonstrating how to build agentic applications using the Gemini Interactions API. It covers API calls, tool integration, state management, and agent looping.

Inputs & outputs

You give it
User prompts or tool call results for an agentic application
You get back
An array of `steps` including `user_input`, `thought`, `function_call`, or `function_call_result`

When to use prompt_to_production

  • Learning Gemini API
  • Building coding agents
  • Implementing agentic workflows

About this skill

Prompt to Production: Workshop Guide

Welcome to the Prompt to Production workshop skill. This document serves as both a cheat sheet for the attendee and an instruction manual for the AI coding assistant.

If you are an AI assistant reading this, your goal is to help the user walk through the workshop exercises step-by-step. The reference implementations for every step are located in the solutions/ directory next to this file.

⚠️ API Reference: The Interactions API

Do NOT use the old generateContent API shape. This workshop exclusively uses the new client.interactions.create() API.

Response Shape (steps array)

An interaction returns a flat array of steps, not outputs.

{
  status: "requires_action", // or "completed"
  steps: [
    { type: "user_input", content: ... },
    { type: "thought", signature: ... },
    { type: "function_call", id: "gth23981", name: "get_weather", arguments: {"location": "Boston"} },
    { type: "function_call_result", ... }
  ]
}

Passing State

Never manually append history arrays. Use previous_interaction_id:

const response2 = await client.interactions.create({
    model: "gemini-3.1-pro-preview",
    previous_interaction_id: response1.id,
    input: [
        { type: "function_call_result", name: "get_weather", call_id: "gth23981", result: "Sunny" }
    ]
});

🛠️ Workshop Walkthrough

This section outlines the progression of the workshop. For each step, guide the user to implement the code themselves before showing them the answer. Reference the solutions/ directory if they get stuck.

Step 1: The Basic API Call (solutions/01-basic-api-call.ts)

Goal: Understand how to instantiate the client and make a basic interactions.create call. Takeaway: The response object is flat. We access the final text via response.steps.at(-1).text.

Step 2: Generation Config (solutions/02-generate-config.ts)

Goal: Learn how to apply configurations like thinking_level to the model. Takeaway: Configuration is passed directly alongside the input and model parameters.

Step 3: Tool Calling (solutions/03-tool-call.ts)

Goal: Provide the model with a JSON schema for a tool and see how it responds. Takeaway: When tools are provided, the model's status becomes requires_action and it generates a function_call step instead of text.

Step 4: The Stateless Method (solutions/04-stateless-method.ts)

Goal: Manually handle a tool call using the old, expensive stateless method (re-sending history). Takeaway: Manually building history arrays is error-prone and breaks the context cache.

Step 5: Interaction IDs (solutions/05-interaction-id.ts)

Goal: Refactor the stateless method to use server-side state. Takeaway: Passing previous_interaction_id replaces the need to manage history, guaranteeing perfect cache hits.

Step 6: The Agent Loop (solutions/06-agent.ts)

Goal: Wrap the interactions.create call in a while (status === "requires_action") loop. Takeaway: An agent is just a model inside a loop that continuously executes tools and passes back function_call_result steps.

Step 7: The Coding Agent (solutions/07-coding-agent.ts)

Goal: Give the agent loop real tools (readFile, writeFile, runBash). Takeaway: With local tools, the agent can interact with the file system. But running this locally is dangerous.

Step 8: Adding Google Tools (solutions/08-google-tools.ts)

Goal: Integrate built-in tools like Google Search. Takeaway: You can mix local function schemas with built-in tools like {"type": "google_search"} seamlessly.

Step 9: Daytona Sandboxing (solutions/09-daytona-sdk.ts)

Goal: Move the local bash execution into an ephemeral cloud sandbox. Takeaway: Production agents need secure execution environments. We replace child_process.exec with daytona.process.executeCommand.

Step 10 & 11: Observability (solutions/10-adding-otel.ts & 11-tuning-responses.ts)

Goal: Add OpenTelemetry tracing to see inside the black box. Takeaway: Tracing allows for Time Travel Debugging—we can grab a failed interaction_id and replay from that exact state without re-running the tools.

When not to use it

  • When using the old `generateContent` API shape.
  • When manually appending history arrays instead of using `previous_interaction_id`.
  • When the task does not involve building an agentic application with the Gemini Interactions API.

Limitations

  • The skill exclusively uses the new `client.interactions.create()` API.
  • The skill focuses on building agentic applications.
  • The skill's examples are in TypeScript.

How it compares

This skill provides a structured, step-by-step curriculum for building agentic applications using a specific API, unlike general API documentation.

Compared to similar skills

prompt_to_production side by side with the closest alternatives in the catalog.

SkillInstallsUpdatedSafetyDifficulty
prompt_to_production (this skill)03moReviewIntermediate
llm-service-integration07moNo flagsIntermediate
mcp-builder03moNo flagsAdvanced
copilot-sdk06moNo flagsIntermediate

Try saying

Example prompts that trigger this skill in your AI assistant.

You might also like

llm-service-integration

codename-co

Guide for integrating with LLM providers in the DEVS platform. Use this when asked to add LLM functionality, create AI-powered features, or work with the LLM service.

00

mcp-builder

UnderUndreGH

MCP (Model Context Protocol) server building principles. Tool design, resource patterns, best practices.

00

copilot-sdk

vivi3172

This skill provides guidance for creating agents and applications with the GitHub Copilot SDK. IMPORTANT - When using the SDK with TypeScript/Node.js, the project MUST use ESM (ECMAScript Modules). CommonJS (require/module.exports) is NOT supported. It should be used when the user wants to create, m

00

langsmith-evaluator

dhar174

INVOKE THIS SKILL when building evaluation pipelines for LangSmith. Covers three core components: (1) Creating Evaluators - LLM-as-Judge, custom code; (2) Defining Run Functions - how to capture outputs and trajectories from your agent; (3) Running Evaluations - locally with evaluate() or auto-run v

00

mcp-builder

anthropics

Guide for creating high-quality MCP (Model Context Protocol) servers that enable LLMs to interact with external services through well-designed tools. Use when building MCP servers to integrate external APIs or services, whether in Python (FastMCP) or Node/TypeScript (MCP SDK).

136215

langchain

zechenzhangAGI

Framework for building LLM-powered applications with agents, chains, and RAG. Supports multiple providers (OpenAI, Anthropic, Google), 500+ integrations, ReAct agents, tool calling, memory management, and vector store retrieval. Use for building chatbots, question-answering systems, autonomous agents, or RAG applications. Best for rapid prototyping and production deployments.

26138

Search skills

Search the agent skills registry