Skip to content

eq_callback.php

Module for processing asynchronous responses from workers to manage hardware (EQ) and virtual machines. It processes task statuses (deploy, reinstall, backup, network), updates billing, and sends notifications to customers.

API Methods

Method Action Description
check check async job status Checks the current status of an asynchronous job using a 32-character hex key. Returns job scope, context, and debug information.
reinstall reinstall callback receiver Processes the completion of a server reinstallation job, updates billing status via WHMCS, notifies customers, and cleans up deployment tags.

eq_callback/check

Checks the current status of an asynchronous job using a 32-character hex key. Returns job scope, context, and debug information.

HTTP Method: POST

Parameters:

Parameter Required Type Description
action string The action to perform (e.g., check)
?key string 32-character alphanumeric async job key

Example Request

curl -s "https://invapi.hostkey.com/eq_callback.php" -X POST \
--data "action=check" \
--data "?key=a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6"
Example of a successful response
{
"result": "OK",
"scope": {
"id": 123,
"location": "NL"
},
"context": {
"action": "start_job",
"id": 123,
"ip": "1.2.3.4"
},
"debug": "Job processed successfully",
"key": "a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6"
}
Failure response
{
"code": -1,
"message": "AsyncKey a1b2c3d4e5f6g7h8i9j0k1l2m3n4o5p6 not found"
}

eq_callback/reinstall

Processes the completion of a server reinstallation job, updates billing status via WHMCS, notifies customers, and cleans up deployment tags.

HTTP Method: POST

Parameters:

Parameter Required Type Description
action string The action being performed (must be 'reinstall' for this handler)
key string 32-character alphanumeric async job key
status string The status/result received from the worker (e.g., 'deploy_done', 'Error')

Example Request

curl -s "https://invapi.hostkey.com/eq_callback" -X POST \
--data "action=reinstall" \
--data "key=VALUE" \
--data "status=deploy_done"
Example of a successful response
{
"result": "OK",
"action": "reinstall",
"callback": "7bc29eb23b1b879b21fce509597f07c"
}
Failure response
{
"code": -1,
"message": "Key not found"
}
question_mark
Is there anything I can help you with?
question_mark
AI Assistant ×