
Company News
Socket Named Top Sales Organization by RepVue
Socket won two 2026 Reppy Awards from RepVue, ranking in the top 5% of all sales orgs. AE Alexandra Lister shares what it's like to grow a sales career here.
genai-agent
Advanced tools
Multi-provider GenAI wrapper (Google, OpenAI, Anthropic) with builtin function-calling support.
genai-agentgenai-agent is a TypeScript-based Node.js package that provides an easy interface for interacting with different generative AI providers like Google, OpenAI, and Anthropic. This package allows you to use pre-configured agents for AI-powered tasks such as chat, content generation, and function calls.
To install the package, run the following command:
npm install genai-agent
Here’s how you can use the package to interact with the available agents (Google for now):
import { GoogleAgent } from "genai-agent";
// Initialize the agent with your API key
const agent = new GoogleAgent({ apiKey: "YOUR_GOOGLE_API_KEY" });
// Call the chat method to interact with the AI
const response = await agent.chat({
model: "gemini-1.5-flash",
text: "Hello, AI!",
functionDeclarations: [],
functions: {},
systemInstruction: "your-instruction",
});
console.log(response); // The response from the AI
import { OpenAIAgent } from "genai-agent";
// Placeholder for OpenAIAgent usage
const openAI = new OpenAIAgent({ apiKey: "YOUR_OPENAI_API_KEY" });
import { AnthropicAgent } from "genai-agent";
// Placeholder for AnthropicAgent usage
const anthropic = new AnthropicAgent({ apiKey: "YOUR_ANTHROPIC_API_KEY" });
To contribute or develop locally, follow these steps:
git clone https://github.com/yourusername/genai-agent.git
npm install
npm run build
This project is licensed under the MIT License.
This project includes third-party software components:
@google/genai – © Google LLC, licensed under the Apache License 2.0See the NOTICE file for additional details.
Checkout some examples with function calls and response here
FAQs
Multi-provider GenAI wrapper (Google, OpenAI, Anthropic) with builtin function-calling support.
We found that genai-agent demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Company News
Socket won two 2026 Reppy Awards from RepVue, ranking in the top 5% of all sales orgs. AE Alexandra Lister shares what it's like to grow a sales career here.

Security News
NIST will stop enriching most CVEs under a new risk-based model, narrowing the NVD's scope as vulnerability submissions continue to surge.

Company News
/Security News
Socket is an initial recipient of OpenAI's Cybersecurity Grant Program, which commits $10M in API credits to defenders securing open source software.