import { OpenAI } from "openai";
import { StackOneToolSet } from "@stackone/ai";
const toolset = new StackOneToolSet();
const openAITools = toolset.getTools("hris_*").toOpenAI();
await openai.chat.completions.create({
model: "gpt-4o",
messages: [
{
role: "system",
content: "You are a helpful assistant.",
},
{
role: "user",
content: "What is the name of the employee with id 123?",
},
],
tools: openAITools,
});
from openai import OpenAI
client = OpenAI()
tools = toolset.get_stackone_tools(["hris_*"], account_id=account_id)
openai_tools = tools.to_openai()
completion = await client.chat.completions.create(
model="gpt-4o",
messages=[{"role": "user", "content": "List all employees"}],
tools=openai_tools
)
if completion.choices[0].message.tool_calls:
tool_call = completion.choices[0].message.tool_calls[0]
result = await tools.execute(tool_call.function.arguments)
print('Function result:', result)
import { OpenAI } from "@ai-sdk/openai";
import { generateText } from "ai";
import { StackOneToolSet } from "@stackone/ai";
const toolset = new StackOneToolSet();
const aiSdkTools = toolset.getTools("hris_*").toAISDK();
await generateText({
model: openai("gpt-4o"),
tools: aiSdkTools,
maxSteps: 3,
});
import { StackOneToolSet } from "@stackone/ai";
const toolset = new StackOneToolSet();
const tools = toolset.getTools("hris_*", "your-account-id");
const employeeTool = toolset.getTool("hris_listemployees");
const employees = await employeeTool.execute();
from langchain_openai import ChatOpenAI
toolset = StackOneToolSet()
tools = toolset.get_tools(["hris_*"], account_id=account_id)
langchainTools = tools.to_langchain();
# Create model with tools
model = ChatOpenAI(model="gpt-4o-mini")
model_with_tools = model.bind_tools(langchain_tools)
result = model_with_tools.invoke(f"Find all employees in the engineering department")
StackOne provides everything you need to integrate, scale, and monitor every tool call - covering a wide range of tools with deep, customizable control
StackOne auto-detects and handles all authentication types via our embeddable Hub, clearing the path for your agents so they can focus on taking action without interruption while simplifying each tool call.
Pre‑written instructions for all integrations mean faster onboarding and fewer “How do I connect?” emails - plus the freedom to swap in your own guides anytime.
StackOne simplifies multi-tenant tool call authentication using account identifiers, improving accuracy and reducing credential errors. The dashboard lets you control AI actions per project or tenant for fine-grained access with minimal effort.
StackOne is built with open-source at its core, from our use of Instructor or Langchain to Zod, Vllm, SSTand more. That's why we're also commited to support and develop open-source projects to empower AI agent builders everywhere.