We provide official SDKs for TypeScript, Go, and Python to make it easy to integrate with the OpenRegister API. These SDKs are published and maintained by our team.
Python
pip install openregister-sdk
import os
from openregister import Openregister
client = Openregister(
api_key=os.environ.get("OPENREGISTER_API_KEY"), # This is the default and can be omitted
)
response = client.search.find_companies()
print(response.results)
TypeScript/JavaScript
import Openregister from 'openregister';
const client = new Openregister({
apiKey: process.env['OPENREGISTER_API_KEY'], // This is the default and can be omitted
});
const response = await client.search.findCompanies();
console.log(response.results);
go get github.com/oregister/openregister-go
package main
import (
"context"
"fmt"
"github.com/oregister/openregister-go"
"github.com/oregister/openregister-go/option"
)
func main() {
client := openregister.NewClient(
option.WithAPIKey("My API Key"), // defaults to os.LookupEnv("OPENREGISTER_API_KEY")
)
response, err := client.Search.FindCompanies(context.TODO(), openregister.SearchFindCompaniesParams{})
if err != nil {
panic(err.Error())
}
fmt.Printf("%+v\n", response.Results)
}