GetForging
Retrieves forging status for a specific account (via secretPhrase/privateKey/publicKey) or all active generators on the network.
Request
GET /nxt?requestType=getForging
All endpoints use port 22024 by default.
Parameters
| Name | Type | Description | Required |
|---|---|---|---|
secretPhrase | string | Secret passphrase for account | No |
privateKey | string | Private key for account | No |
publicKey | string | Public key for account | No |
adminPassword | string | Admin password to get all generators | No |
Response
When querying specific account:
{
"generator": {
"account": "1234567890123456789",
"accountRS": "SHAMWARI-ABCD-EFGH-IJKL-MNOPQ",
"deadline": 120,
"hitTime": 45,
"targetDeadline": 120,
"effectiveBalanceFQT": "10000000000000000",
"blocksmithsCount": 1,
"hitTimeElapsd": 30
},
"errorCode": 0,
"errorDescription": ""
}
When querying all generators (adminPassword):
{
"generators": [
{
"account": "1234567890123456789",
"accountRS": "SHAMWARI-ABCD-EFGH-IJKL-MNOPQ",
"deadline": 120,
"hitTime": 45,
"targetDeadline": 120,
"effectiveBalanceFQT": "10000000000000000",
"blocksmithsCount": 1,
"hitTimeElapsd": 30
}
],
"errorCode": 0,
"errorDescription": ""
}
Example
# Get forging status for specific account
curl "http://localhost:22024/nxt?requestType=getForging&secretPhrase=your_secret_passphrase"
# Get all generators (requires admin password)
curl "http://localhost:22024/nxt?requestType=getForging&adminPassword=admin_password"