SDKs & Libraries
Official and community-maintained SDKs to integrate Cappers API into your favorite programming language.
Official SDKs Coming Soon
We're currently developing official SDKs for popular programming languages. In the meantime, you can use the REST API directly with any HTTP client library.
Planned Official SDKs
We're working on official SDKs for the following languages:
JavaScript / TypeScript
NPM package for Node.js and browser environments
Coming Q2 2026Python
PyPI package with full type hints
Coming Q2 2026Ruby
RubyGems package for Ruby applications
Coming Q3 2026PHP
Composer package for PHP applications
Coming Q3 2026Go
Go module with full concurrency support
Coming Q3 2026Rust
Crate with async/await support
Coming Q4 2026Want to contribute? We welcome community contributions! Contact us if you'd like to help build or maintain an SDK.
Using the REST API Directly
Until official SDKs are available, you can easily use the Cappers API with any HTTP client library in your language of choice:
JavaScript / Node.js
Using native fetch API:
const CAPPERS_API_KEY = 'cap_your_api_key_here';
const BASE_URL = 'https://api.cappersapi.com/v1';
async function getNBATeams() {
const response = await fetch(`${BASE_URL}/nba/teams`, {
headers: {
'Authorization': CAPPERS_API_KEY
}
});
if (!response.ok) {
throw new Error(`API error: ${response.status}`);
}
return await response.json();
}
const teams = await getNBATeams();
console.log(teams.data);Python
Using requests library:
import requests
CAPPERS_API_KEY = 'cap_your_api_key_here'
BASE_URL = 'https://api.cappersapi.com/v1'
def get_nba_teams():
response = requests.get(
f'{BASE_URL}/nba/teams',
headers={'Authorization': CAPPERS_API_KEY}
)
response.raise_for_status()
return response.json()
teams = get_nba_teams()
print(teams['data'])Install requests: pip install requests
PHP
Using cURL:
<?php
$apiKey = 'cap_your_api_key_here';
$baseUrl = 'https://api.cappersapi.com/v1';
function getNBATeams($apiKey, $baseUrl) {
$ch = curl_init("$baseUrl/nba/teams");
curl_setopt($ch, CURLOPT_HTTPHEADER, [
"Authorization: $apiKey"
]);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$response = curl_exec($ch);
$httpCode = curl_getinfo($ch, CURLINFO_HTTP_CODE);
curl_close($ch);
if ($httpCode !== 200) {
throw new Exception("API error: $httpCode");
}
return json_decode($response, true);
}
$teams = getNBATeams($apiKey, $baseUrl);
print_r($teams['data']);
?>Ruby
Using net/http:
require 'net/http'
require 'json'
CAPPERS_API_KEY = 'cap_your_api_key_here'
BASE_URL = 'https://api.cappersapi.com/v1'
def get_nba_teams
uri = URI("#{BASE_URL}/nba/teams")
request = Net::HTTP::Get.new(uri)
request['Authorization'] = CAPPERS_API_KEY
response = Net::HTTP.start(uri.hostname, uri.port, use_ssl: true) do |http|
http.request(request)
end
raise "API error: #{response.code}" unless response.code == '200'
JSON.parse(response.body)
end
teams = get_nba_teams
puts teams['data']Go
Using net/http package:
package main
import (
"encoding/json"
"fmt"
"io"
"net/http"
)
const (
apiKey = "cap_your_api_key_here"
baseURL = "https://api.cappersapi.com/v1"
)
type TeamsResponse struct {
Data []map[string]interface{} `json:"data"`
}
func getNBATeams() (*TeamsResponse, error) {
req, err := http.NewRequest("GET", baseURL+"/nba/teams", nil)
if err != nil {
return nil, err
}
req.Header.Set("Authorization", apiKey)
client := &http.Client{}
resp, err := client.Do(req)
if err != nil {
return nil, err
}
defer resp.Body.Close()
body, err := io.ReadAll(resp.Body)
if err != nil {
return nil, err
}
var teams TeamsResponse
if err := json.Unmarshal(body, &teams); err != nil {
return nil, err
}
return &teams, nil
}
func main() {
teams, err := getNBATeams()
if err != nil {
panic(err)
}
fmt.Printf("%+v\n", teams.Data)
}Community SDKs
Community-maintained SDKs and wrappers will be listed here as they become available.
No community SDKs yet. Be the first to create one!
Get Notified
Want to be notified when official SDKs are released? Follow our changelog or join our community.