Domain

The following hooks are provided for Domain related events.

DomainDelete

Executes when a domain is being deleted from the client account.

Parameters

Variable Type Notes
domainidintDomain ID which is being deleted

Response

No Response Supported.

Example Code

<?php
add_hook('DomainDelete', 1, function($vars)
{
});

DomainEdit

Executes when the domain is being edited via the Client Profile Summary and Domains tabs in the Admin Area.

Parameters

Variable Type Notes
domainidintDomain ID which is being edited
additionalFieldjsonDomain Additional fields information

Response

No Response Supported.

Example Code

<?php
add_hook('DomainEdit', 1, function($vars)
{
});

DomainTransferCompleted

Executes when a domain transfer is set to completed by the domain sync cron.

Parameters

VariableTypeNotes
paramsarrayArray of common module parameters. See View Module Parameters
responsearrayModule action response have status and message

Response

No Response Supported.

Example Code

<?php
add_hook('DomainTransferCompleted', 1, function($vars)
{
});

DomainTransferFailed

Executes when a domain transfer is set to failed by the domain sync cron.

Parameters

VariableTypeNotes
paramsarrayArray of common module parameters. See View Module Parameters
responsearrayModule action response have status and message

Response

No Response Supported.

Example Code

<?php
add_hook('DomainTransferFailed', 1, function($vars)
{
});

DomainValidation

Executes as domain validation is being run

Parameters

VariableTypeNotes
sldstringThe sld of the domain
tldstringThe tld of the domain

Response

No Response Supported.

Example Code

<?php
add_hook('DomainValidation', 1, function($vars)
{
});

PreDomainRegister

Executes before a domain register Cron Command

Parameters

VariableTypeNotes
paramsarrayArray of common module parameters. See View Module Parameters
responsearrayModule action response have status and message

Response

Accepts a return of key/value pairs to override the parameters to be used in action aborting. Use the same names as the input parameters. Return abort=true to abort the action.

Example Code

<?php
add_hook('PreDomainRegister', 1, function($vars)
{
    return ['abort'=>true,'message'=>'About action reason'];
});

PreDomainTransfer

Executes before a domain transfer Cron Command

Parameters

VariableTypeNotes
paramsarrayArray of common module parameters. See View Module Parameters
responsearrayModule action response have status and message

Response

Accepts a return of key/value pairs to override the parameters to be used in action aborting. Use the same names as the input parameters. Return abort=true to abort the action.

Example Code

<?php
add_hook('PreDomainTransfer', 1, function($vars)
{
    return ['abort'=>true,'message'=>'About action reason'];
});

PreRegistrarRegisterDomain

Executes prior to the registrar function being executed for a domain. Allows the action to be aborted.

Parameters

VariableTypeNotes
paramsarrayArray of common module parameters. See View Module Parameters
responsearrayModule action response have status and message

Response

Accepts a return of key/value pairs to override the parameters to be used in action aborting. Use the same names as the input parameters. Return abort=true to abort the action.

Example Code

<?php
add_hook('PreRegistrarRegisterDomain', 1, function($vars)
{
    return ['abort'=>true,'message'=>'About action reason'];
});

PreRegistrarRenewDomain

Executes prior to the registrar function being executed for a domain. Allows the action to be aborted.

Parameters

VariableTypeNotes
paramsarrayArray of common module parameters. See View Module Parameters
responsearrayModule action response have status and message

Response

Accepts a return of key/value pairs to override the parameters to be used in action aborting. Use the same names as the input parameters. Return abort=true to abort the action.

Example Code

<?php
add_hook('PreRegistrarRenewDomain', 1, function($vars)
{
    return ['abort'=>true,'message'=>'About action reason'];
});

PreRegistrarTransferDomain

Executes prior to the registrar function being executed for a domain. Allows the action to be aborted.

Parameters

VariableTypeNotes
paramsarrayArray of common module parameters. See View Module Parameters
responsearrayModule action response have status and message

Response

Accepts a return of key/value pairs to override the parameters to be used in action aborting. Use the same names as the input parameters. Return abort=true to abort the action.

Example Code

<?php
add_hook('PreRegistrarTransferDomain', 1, function($vars)
{
    return ['abort'=>true,'message'=>'About action reason'];
});

TopLevelDomainAdd

Executes when a new domain extension is added.

Parameters

VariableTypeNotes
idintTLD Extension ID
namestringDomain Extension Name
auto_registrationintDomain Registrar ID

Response

No Response Supported.

Example Code

<?php
add_hook('TopLevelDomainAdd', 1, function($vars)
{
});

TopLevelDomainDelete

Executes when a domain extension is deleted.

Parameters

VariableTypeNotes
idintTLD Extension ID
namestringDomain Extension Name

Response

No Response Supported.

Example Code

<?php
add_hook('TopLevelDomainDelete', 1, function($vars)
{
});

TopLevelDomainPricingUpdate

Executes when domain extension pricing is updated.

Parameters

VariableTypeNotes
idintTLD Extension ID
currency_codestringCurrency Name as (USD,GBP, or PKR)
fieldstringField Name which is being Updated
pricefloatAmount

Response

No Response Supported.

Example Code

<?php
add_hook('TopLevelDomainPricingUpdate', 1, function($vars)
{
});

TopLevelDomainUpdate

Executes when domain extensions configuration is updated.

Parameters

VariableTypeNotes
idintTLD Extension ID
namestringDomain Extension Name
featured_colorstringCustom Color Code
whois_email_btnstringYES/NO = Whois Link Show/Hide in Clientarea
auto_registrationintDomain Registrar ID
spotlightstringYES/NO = TLD Spotlight Enable/Disable for showing in Domain Searching/Transfer page
featuredstringTLD Featured Text for showing in Domain Searching/Transfer page
dns_managementstringYES/NO = Allow Clients to manage Domain DNS
email_forwardingstringYES/NO = Allow Clients to manage Email forwarding
id_protectionstringYES/NO = Allow Clients to manage Domain Transfer Protection
epp_codestringYES/NO = Allow Clients to get Domain Transfer Code
auto_suggeststringEnable TLD to show in domains auto suggestions at Domain Searching page
grace_period_durationintDomains Grace Period days
grace_period_feefloatDomains Grace Period Fees in USD
redemption_period_durationintDomains Redemption Period days
redemption_period_feefloatDomains Redemption Period Fees in USD
default_registration_periodstringDomains TLD Default Registration Period

Response

No Response Supported.

Example Code

<?php
add_hook('TopLevelDomainUpdate', 1, function($vars)
{
});