Integrations/Google ADK
AI Agent

Create spreadsheets & documents with Google ADK

In the Google Agent Development Kit (ADK), wrap the OpenOfficeAI API as a FunctionTool so your agent can create shareable spreadsheets. ADK builds the tool schema from your typed function and docstring, and the agent calls it when the task calls for a document.

Google ADK (Python)
import requests
from google.adk.agents import Agent
from google.adk.tools import FunctionTool

def create_spreadsheet(title: str, rows: list) -> str:
    """Create a shareable spreadsheet (first row = header). Returns a URL."""
    r = requests.post(
        "https://openofficeai.com/api/v1/sheets",
        headers={"Authorization": "Bearer YOUR_API_KEY"},
        json={"title": title, "sheets": [{"rows": rows}]},
    )
    return r.json()["url"]

agent = Agent(
    model="gemini-2.0-flash",
    tools=[FunctionTool(func=create_spreadsheet)],
)

How to create a spreadsheet with Google ADK

  1. 1Write a typed create_spreadsheet function with a docstring.
  2. 2Wrap it with FunctionTool(func=...).
  3. 3Add it to your ADK Agent's tools list.
  4. 4Run the agent; it calls the tool and returns the shareable link.

Why use OpenOfficeAI with Google ADK

Frequently asked questions

Do I need to define a schema manually?

No. ADK's FunctionTool infers the parameter schema from your type hints and docstring, so a clear function signature is all you need.

Can I use it with the ADK web UI?

Yes. Once the tool is on the agent, you can exercise it from "adk web" during development and watch the tool call and returned URL.

Does it deploy to Vertex AI?

Yes. Agents built with ADK (including their tools) can be deployed to Vertex AI Agent Engine; the tool runs your HTTP call server-side.

Start creating documents with Google ADK

Free tier includes 500 API calls per month — no card required.