Skip to main content

Developers

Build with the Domain.af API

Integrate .af domain availability, reseller pricing, and account management into your applications with a REST JSON API.

API access is available to reseller accounts with API enabled.

Supported today

What the API can do

These endpoints are implemented under /api/v1. Registration, renewal, and transfer mutations remain available through the reseller portal.

  • Domain Availability

    Check whether a domain is available and receive reseller-effective pricing in the same response.

    POST /api/v1/domains/check

  • Pricing

    Retrieve reseller-effective quotes for registration, renewal, transfer, or restore.

    POST /api/v1/pricing

  • Domain List

    List domains associated with your reseller account.

    GET /api/v1/domains

  • Domain Information

    Retrieve status, expiry, and nameservers for a domain you manage.

    GET /api/v1/domains/{domain}

  • Account Balance

    Retrieve your reseller credit balance, currency, and active domain count.

    GET /api/v1/account/balance

  • Pricing Tier

    See your current tier, next tier, and domains needed to advance.

    GET /api/v1/account/tier

API principles

Designed for server-side integrations

  • REST JSON API under /api/v1/
  • Header-based API key and secret authentication
  • Optional IP allowlists per credential
  • Per-credential rate limiting (default 60 requests/minute)
  • Structured error objects with machine-readable codes
curl -X POST https://domain.af/api/v1/domains/check \
  -H "X-DomainAf-Key: daf_…" \
  -H "X-DomainAf-Secret: …" \
  -H "Content-Type: application/json" \
  -H "Accept: application/json" \
  -d '{"domain":"example.af","years":1}'

Quick start

From zero to first API call

  1. 1

    Create a reseller account

    Sign up, verify email, and complete MFA.

  2. 2

    Enable API access

    API must be enabled on your reseller account, then generate credentials in the portal.

  3. 3

    Call availability

    POST /api/v1/domains/check from a secure server with your key and secret.

Credential security

Protect API secrets like production passwords

  • Shown once

    The API secret is displayed only when generated or rotated.

  • Rotate & revoke

    Rotate compromised secrets or revoke credentials immediately in the portal.

  • IP allowlist

    Optionally restrict each credential to known server IPs.

  • Server-side only

    Never embed credentials in browsers, mobile apps, or public repositories.

FAQ

Developer FAQ

Answers about access, credentials, and what the API supports today.

Who can use the Domain.af API?

API access is available to reseller accounts with API enabled. Create a reseller account, complete security setup, then enable API access and generate credentials in the portal.

Can I call the API from a browser app?

No. Never expose API credentials in client-side or browser applications. Call the API only from secure server-side systems.

Does Domain.af provide official SDKs?

Not at this time. Use the REST examples in the documentation with your preferred HTTP client.

Is there a sandbox environment?

A dedicated sandbox is not available yet. Use your reseller account carefully and prefer availability/pricing endpoints while integrating.

Ready to integrate?

Read the API reference or create a reseller account to request API access.