API Docs

REST API · v1.0

ResellPlan API

Complete reference for building custom control panels and automating domain workflows.

JSON Responses HMAC-SHA256 Auth 26 Endpoints

Overview

The ResellPlan API provides programmatic access to domain registration, renewal, transfer, and management operations. It is designed for resellers who want to build their own control panels or automate domain workflows.

All requests are made to a single endpoint with action-specific paths or parameters. Responses are returned in JSON format.

Note: This documentation is based on the standard ResellPlan module structure. The nameserver endpoints have been verified against the live secure.resellplan.com endpoint. Other actions follow the same authentication and request pattern.

Authentication

Every API request requires two HTTP headers:

HeaderDescription
username Your ResellPlan account email address.
token A Base64-encoded HMAC-SHA256 hash generated from your API key, email, and current UTC time.

Token Generation (PHP)

The token is valid for the current UTC hour and must be regenerated for each hour boundary. The published PHP expression is:

<?php
$token = base64_encode(
    hash_hmac(
        "sha256",
        "<your-api-key>",
        "<your-email>:" . gmdate("y-m-d H")
    )
);
?>
Important: The API key must never be exposed in client-side JavaScript or public repositories. Always generate the token on your server.

Example: Generate Headers

<?php
$apiKey   = "your_api_key_here";
$username = "[email protected]";

$token = base64_encode(
    hash_hmac("sha256", $apiKey, $username . ":" . gmdate("y-m-d H"))
);

$headers = [
    "username: " . $username,
    "token: "    . $token,
];
?>

Base URL

URL https://secure.resellplan.com/modules/addons/DomainsReseller/api/index.php

All actions are appended to this base URL as path segments or sent as action parameters in the request body.

Register Domain

POST /order/domains/register

Registers a new domain name with the registrar.

Parameters

ParameterTypeRequiredDescription
domain string Yes Domain name to register (e.g., example.com)
regperiod integer Yes Registration period in years
nameservers array No Array of nameservers (ns1–ns5)
addons array No Addon services (dnsmanagement, emailforwarding, idprotection)

Example Request

<?php
$action = "/order/domains/register";
$params = [
    "domain"    => "example.com",
    "regperiod" => 1,
    "nameservers" => [
        "ns1" => "ns1.yourprovider.com",
        "ns2" => "ns2.yourprovider.com",
    ],
];

$url = $endpoint . $action;
// ... cURL with headers ...
?>

Success Response

{
    "result": "success",
    "msg": "Domain has been registered"
}

Renew Domain

POST /order/domains/renew

Renews an existing domain registration.

Parameters

ParameterTypeRequiredDescription
domain string Yes Domain to renew
regperiod integer Yes Renewal period in years

Example Request

$params = [
    "domain"    => "example.com",
    "regperiod" => 1,
];

Transfer Domain

POST /order/domains/transfer

Initiates a domain transfer from another registrar. Requires an EPP code.

Parameters

ParameterTypeRequiredDescription
domain string Yes Domain to transfer
eppcode string Yes EPP authorization code from current registrar
regperiod integer Yes Transfer period in years

Get Domain Information

GET /domains/{domain}

Retrieves detailed information about a specific domain.

Example

GET /domains/example.com

Response (abbreviated)

{
    "domain": "example.com",
    "status": "active",
    "expirydate": "2026-10-23",
    "nameservers": {
        "ns1": "ns1.provider.com",
        "ns2": "ns2.provider.com"
    },
    "registrarlock": "locked"
}

Get Nameservers

GET /domains/{domain}/nameservers

Retrieves the current nameservers for a domain.

Example

GET /domains/webfusionris.com/nameservers

Success Response

{
    "ns1": "ns1.example.com",
    "ns2": "ns2.example.com",
    "ns3": "",
    "ns4": "",
    "ns5": "",
    "status": "success"
}

Save Nameservers

POST /domains/{domain}/nameservers

Updates the nameservers for a domain. This is the endpoint verified with webfusionris.com.

Parameters

ParameterTypeRequiredDescription
ns1 string Yes Primary nameserver hostname
ns2 string Yes Secondary nameserver hostname
ns3 – ns5 string No Additional nameservers (optional)

Example Request

<?php
$domain = "webfusionris.com";
$url    = $endpoint . "/domains/" . $domain . "/nameservers";

$params = [
    "ns1" => "ns1.yourprovider.com",
    "ns2" => "ns2.yourprovider.com",
];

// cURL with headers ...
?>
Verified: This exact request pattern works with secure.resellplan.com for the domain webfusionris.com.

Get Contact Details

GET /domains/{domain}/contacts

Retrieves the registrant, admin, tech, and billing contact information.

Response (abbreviated)

{
    "registrant": {
        "firstname": "John",
        "lastname": "Doe",
        "email": "[email protected]",
        "country": "US"
    },
    "admin": { ... },
    "tech": { ... },
    "billing": { ... }
}

Get EPP Code

GET /domains/{domain}/eppcode

Retrieves the EPP authorization code required for domain transfers.

Response

{
    "eppcode": "ABC123XYZ",
    "status": "success"
}

Registrar Lock

GET /domains/{domain}/registrarlock

Check the current registrar lock status.

POST /domains/{domain}/registrarlock

Update the registrar lock status.

Parameters (POST)

ParameterTypeDescription
lockstatus integer 1 = locked, 0 = unlocked

Check Availability

POST /domains/check

Checks whether a domain name is available for registration.

Parameters

ParameterTypeRequiredDescription
domain string Yes Domain to check (e.g., example.com)

Response

{
    "domain": "example.com",
    "available": true,
    "status": "success"
}

Get Credits

GET /credits

Returns the available account balance for domain purchases.

Response

{
    "credits": "150.00",
    "currency": "USD",
    "status": "success"
}

Get Version

GET /version

Returns the API module version. Useful for connectivity testing.

Response

{
    "version": "1.0.0",
    "status": "success"
}

All Supported Actions

The following actions are available in the standard ResellPlan module. Action names may also be sent as the action parameter in the request body for legacy compatibility.

Domain Lifecycle 4
RegisterDomainRegister a new domain
TransferDomainTransfer a domain in
RenewDomainRenew an existing domain
GetDomainInformationGet full domain details
Nameservers 5
GetNameserversRetrieve current nameservers
SaveNameserversUpdate nameservers
RegisterNameserverCreate a child nameserver
ModifyNameserverUpdate a child nameserver
DeleteNameserverDelete a child nameserver
Contacts & Security 5
GetContactDetailsGet contact information
SaveContactDetailsUpdate contact information
GetEPPCodeRetrieve transfer authorization code
GetRegistrarLockCheck lock status
SaveRegistrarLockUpdate lock status
DNS & Extras 5
GetDNSRetrieve DNS records
SaveDNSUpdate DNS records
GetEmailForwardingRetrieve email forwarders
SaveEmailForwardingUpdate email forwarders
IDProtectToggleToggle ID protection
Utility & Sync 7
CheckAvailabilityCheck domain availability
GetCreditsCheck account balance
GetVersionGet API version
GetTLDsList available TLDs
GetTldPricingGet TLD pricing information
SyncDomainSynchronize domain status
TransferSyncSynchronize transfer status
Tip: Not all actions may be enabled for every reseller account. If an action returns an error, check with your provider or use the GetVersion endpoint to confirm API access.