Docs
SDKs and tools

Other languages

The planned PHP library and Python and Go clients, and how to generate a client in any language from the OpenAPI contract today.

Planned· P9For developers

This is designed and scheduled but not built yet. We document it now so you can plan your integration.

The Agoo API is plain JSON over HTTPS, so any language with an HTTP client can use it. Official libraries beyond TypeScript are planned, and until they ship you can generate a client from the same OpenAPI document that powers the API reference.

LanguagePackageHow it's madeStatus
PHPardent-africa/agoo-php, via ComposerHand-finished, on a generated corePlanned, P9
PythonTo be announcedGenerated from the OpenAPI contractPlanned
GoTo be announcedGenerated from the OpenAPI contractPlanned

Package names for Python and Go will be announced in the changelog when they're published.

PHP

ardent-africa/agoo-php is the official PHP library. It also powers the WordPress plugin. It needs PHP 8.1 or later and works with any PSR-18 HTTP client, using Guzzle if none is given.

The install command will work once the package is published on Packagist.

Terminal
composer require ardent-africa/agoo-php

It mirrors the TypeScript SDK: the same resources and methods, snake_case fields as in the API, cursor pagination, automatic idempotency keys and retries, and webhook verification.

example.php
<?php
require __DIR__ . '/vendor/autoload.php';

use Agoo\AgooException;
use Agoo\Client;
use Agoo\Webhook;

$agoo = new Client( [ 'api_key' => getenv( 'AGOO_API_KEY' ) ] );

// Create an expected visit (an Idempotency-Key is added automatically)
$visit = $agoo->visits->create( [
	'site_id'     => 'site_01kjpt3yw0fz0v414608h9x65s',
	'host_id'     => 'person_01kjsesxm0e4zbyvkr7bcfxbfg',
	'expected_at' => '2026-10-14T09:30:00Z',
	'visitor'     => [ 'name' => 'Ama Owusu', 'phone' => '+233241234567' ],
] );

// Every checked-in visit, across all pages
foreach ( $agoo->visits->list( [ 'status' => 'checked_in' ] )->autoPaginate() as $visit ) {
	echo $visit->visitor->name, PHP_EOL;
}

// Typed errors
try {
	$agoo->visits->checkIn( 'visit_01m4k5z4j0fxbte6sn6e8tpgza' );
} catch ( AgooException $e ) {
	error_log( "{$e->errorCode} ({$e->status}), request {$e->requestId}" );
}

// Verify a webhook: returns the event, or throws Agoo\WebhookVerificationException
$event = Webhook::verify( file_get_contents( 'php://input' ), getallheaders(), getenv( 'AGOO_WEBHOOK_SECRET' ) );

Until it's published, verify webhooks with the plain PHP function in WordPress: verifying signatures yourself, which works in any PHP application.

Python and Go

Official Python and Go clients will be generated from the OpenAPI contract, with idiomatic naming, pagination helpers and typed errors added on top. If you need one of them sooner, generate your own as below, or tell us through developer support so we can prioritise.

Generate a client today

The contract is an OpenAPI 3.1 document, agoo.v1.yaml. It's the single source for the API reference and the official SDKs.

Download it from docs.agoo.ardent.africa/openapi.yaml:

Terminal
curl -o agoo.v1.yaml https://docs.agoo.ardent.africa/openapi.yaml

The contract uses OpenAPI 3.1 features, such as type: [string, "null"] for nullable fields. Use a recent version of your generator, and check that it supports 3.1.

Prefer the official TypeScript SDK. To generate a lightweight fetch client of your own instead:

Terminal
npx @hey-api/openapi-ts -i agoo.v1.yaml -o src/agoo-client

What a generated client won't do for you

Generated clients cover requests and types. Add these yourself, following the concept pages:

ConcernWhat to addSee
AuthenticationSend Authorization: Bearer <key> on every requestAuthentication
IdempotencyAn Idempotency-Key header with a fresh UUID on every POST, reused on retriesIdempotency
RetriesRetry 429, 500 and 503 with backoff, honouring Retry-AfterRate limits
PaginationFollow next_cursor while has_more is truePagination
ErrorsRead code and request_id from the problem details bodyErrors
Forward compatibilityIgnore unknown fields and enum values; don't fail on themVersioning
WebhooksVerify signatures before parsingVerify signatures

Some generators produce strict enums that reject values they don't know. Agoo adds enum values (new statuses, new event types) without a new API version, so configure your generator to allow unknown enum values, or treat them as strings. Visit types aren't an enum at all: each organisation adds its own, so type and visit_type are plain strings.

On this page