Home / Domain Registrar Modules / Creating Registrar Modules

Creating Registrar Modules

Custom registrar integration

What it is

Registrar modules integrate with domain registrars (Domainbox, eNom, OpenSRS, NameSilo, Namecheap, ResellerClub, etc.). They handle domain availability checks, registration, renewal, transfer, and management.

Directory structure

modules/registrars/yourregistrar/
├── module.json
├── YourRegistrarRegistrar.php
└── YourRegistrarApiClient.php (optional, for API calls)

Required class methods

Implement ModuleInterface. Your class must define:

  • getName(), getType() (return "registrar")
  • getConfigFields() – reseller ID, username, password, test mode, etc.
  • initialize(array $config) – store config, create API client
  • execute($action, $params) – handle actions (see below)
  • isEnabled()

execute() actions

ActionPurpose
check_availabilityCheck if domain is available. Params: domain. Return: success, available, price
registerRegister domain. Params: domain, years, contacts
renewRenew domain. Params: domain, years
transferTransfer domain. Params: domain, auth_code
get_infoGet domain info (status, expiry, nameservers)
update_nameserversUpdate nameservers
update_contactsUpdate registrant/admin/tech contacts
get_auth_codeGet EPP/auth code for transfer
validate_credentialsTest API connection

Return format

Always return an array: ["success" => true, "available" => true, "price" => 9.99] or ["success" => false, "error" => "message"].

Reference

See modules/registrars/domainbox/ for a full Domainbox SOAP API implementation.

Was this helpful?

Tags: Developer