SDKs & Libraries

Official SDKs

Get started quickly with official SERPII SDKs for your favorite programming language.

Quick Start

example.ts
import { Serpii } from 'serpii';

// Initialize the client
const serpii = new Serpii(process.env.SERPII_API_KEY);

// Search Google
const results = await serpii.search({
  q: 'best coffee shops in austin',
  location: 'Austin, TX',
  num: 10
});

// AI-enriched response
console.log(results.intent);        // 'commercial investigation'
console.log(results.clusters);      // ['coffee', 'Austin restaurants']
console.log(results.organic_results);

Available SDKs

🟢

Node.js

v2.1.0

Official Node.js SDK with TypeScript support

npm install serpii
View Documentation
🐍

Python

v2.0.3

Python SDK with async support

pip install serpii
View Documentation
🐘

PHP

v1.5.2

PHP SDK compatible with Laravel and Symfony

composer require serpii/serpii-php
View Documentation
💎

Ruby

v1.3.0

Ruby gem for Rails and Sinatra apps

gem install serpii
View Documentation
🔵

Go

v1.2.1

Go package with context and timeout support

go get github.com/serpii/serpii-go
View Documentation

REST API / cURL

Don't see your language? SERPII works with any HTTP client. Here's a simple cURL example:

curl -X GET "https://api.serpii.com/v1/search?q=coffee+shops+austin" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json"

SDK Features

Type Safety

Full TypeScript definitions for autocomplete and type checking

Async/Await

Modern async patterns for non-blocking requests

Error Handling

Typed errors with helpful messages and retry logic

Auto-Retry

Automatic retry with exponential backoff on failures