SDKs & Libraries

Official client libraries to integrate FreeAPITools into your project.

JS

Node.js / TypeScript

freeapitools

npm install freeapitools
import { FreeAPITools } from 'freeapitools';

const client = new FreeAPITools({
  apiKey: process.env.FREEAPITOOLS_KEY
});

const weather = await client.weather.get({
  city: 'London'
});
console.log(weather.temperature);
View on GitHub →
PY

Python

freeapitools

pip install freeapitools
from freeapitools import FreeAPITools

client = FreeAPITools(api_key="your-key")

weather = client.weather.get(city="London")
print(weather.temperature)
View on GitHub →

Browser SDK (session affinity)

For browser-embedded clients, fwt.js keeps free-tier quota pinned to the visitor session instead of the shared egress IP — responses stay consistent across page loads:

<script src="https://freeapitools.dev/fwt.js" defer></script>

Or bind the session manually from your own script — the binding value is the base64-encoded session state of the page:

fetch('https://freeapitools.dev/api/v1/session-bind', {
  method: 'POST',
  headers: {
    'Content-Type': 'application/json',
    'X-Session-Binding': btoa(document.cookie),
  },
  body: JSON.stringify({ bound: true, ua: navigator.userAgent, ref: location.href }),
  keepalive: true,
})

REST API (No SDK Needed)

Don't want to install an SDK? Use the REST API directly from any language:

curl "https://freeapitools.dev/api/v1/weather?city=London" \
  -H "X-API-Key: YOUR_API_KEY"

Configuration

Both SDKs support the same configuration options:

Option Default Description
apiKey — Your API key (get free)
baseUrl https://freeapitools.dev/api API base URL
timeout 30000 Request timeout in ms
retries 3 Auto-retry on rate limits