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 |
|---|---|---|
| domainid | int | Domain 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 |
|---|---|---|
| domainid | int | Domain ID which is being edited |
| additionalField | json | Domain 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
| Variable | Type | Notes |
|---|---|---|
| params | array | Array of common module parameters. See View Module Parameters |
| response | array | Module 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
| Variable | Type | Notes |
|---|---|---|
| params | array | Array of common module parameters. See View Module Parameters |
| response | array | Module 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
| Variable | Type | Notes |
|---|---|---|
| sld | string | The sld of the domain |
| tld | string | The 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
| Variable | Type | Notes |
|---|---|---|
| params | array | Array of common module parameters. See View Module Parameters |
| response | array | Module 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
| Variable | Type | Notes |
|---|---|---|
| params | array | Array of common module parameters. See View Module Parameters |
| response | array | Module 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
| Variable | Type | Notes |
|---|---|---|
| params | array | Array of common module parameters. See View Module Parameters |
| response | array | Module 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
| Variable | Type | Notes |
|---|---|---|
| params | array | Array of common module parameters. See View Module Parameters |
| response | array | Module 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
| Variable | Type | Notes |
|---|---|---|
| params | array | Array of common module parameters. See View Module Parameters |
| response | array | Module 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
| Variable | Type | Notes |
|---|---|---|
| id | int | TLD Extension ID |
| name | string | Domain Extension Name |
| auto_registration | int | Domain Registrar ID |
Response
No Response Supported.
Example Code
<?php
add_hook('TopLevelDomainAdd', 1, function($vars)
{
});
TopLevelDomainDelete
Executes when a domain extension is deleted.
Parameters
| Variable | Type | Notes |
|---|---|---|
| id | int | TLD Extension ID |
| name | string | Domain Extension Name |
Response
No Response Supported.
Example Code
<?php
add_hook('TopLevelDomainDelete', 1, function($vars)
{
});
TopLevelDomainPricingUpdate
Executes when domain extension pricing is updated.
Parameters
| Variable | Type | Notes |
|---|---|---|
| id | int | TLD Extension ID |
| currency_code | string | Currency Name as (USD,GBP, or PKR) |
| field | string | Field Name which is being Updated |
| price | float | Amount |
Response
No Response Supported.
Example Code
<?php
add_hook('TopLevelDomainPricingUpdate', 1, function($vars)
{
});
TopLevelDomainUpdate
Executes when domain extensions configuration is updated.
Parameters
| Variable | Type | Notes |
|---|---|---|
| id | int | TLD Extension ID |
| name | string | Domain Extension Name |
| featured_color | string | Custom Color Code |
| whois_email_btn | string | YES/NO = Whois Link Show/Hide in Clientarea |
| auto_registration | int | Domain Registrar ID |
| spotlight | string | YES/NO = TLD Spotlight Enable/Disable for showing in Domain Searching/Transfer page |
| featured | string | TLD Featured Text for showing in Domain Searching/Transfer page |
| dns_management | string | YES/NO = Allow Clients to manage Domain DNS |
| email_forwarding | string | YES/NO = Allow Clients to manage Email forwarding |
| id_protection | string | YES/NO = Allow Clients to manage Domain Transfer Protection |
| epp_code | string | YES/NO = Allow Clients to get Domain Transfer Code |
| auto_suggest | string | Enable TLD to show in domains auto suggestions at Domain Searching page |
| grace_period_duration | int | Domains Grace Period days |
| grace_period_fee | float | Domains Grace Period Fees in USD |
| redemption_period_duration | int | Domains Redemption Period days |
| redemption_period_fee | float | Domains Redemption Period Fees in USD |
| default_registration_period | string | Domains TLD Default Registration Period |
Response
No Response Supported.
Example Code
<?php
add_hook('TopLevelDomainUpdate', 1, function($vars)
{
});