Skip to main content

Info API Methods

Info API returns basic info about the node

The API provides the following functions and endpoints:

Client lib APIs:

/info

Returns basic info about the node.

Parameters

None.

Examples

cURL

curl --location 'http://localhost:8080/info'

Client lib - Info

Information of a node can be retrieved via Info() (*jsonmodels.InfoResponse, error)

info, err := goshimAPI.Info()
if err != nil {
// return error
}

// will print the response
fmt.Println(string(info))

Response example

{
"version": "v0.6.2",
"networkVersion": 30,
"tangleTime": {
"blockID": "6ndfmfogpH9H8C9X9Fbb7Jmuf8RJHQgSjsHNPdKUUhoJ",
"time": 1621879864032595415,
"synced": true
},
"identityID": "D9SPFofAGhA5V9QRDngc1E8qG9bTrnATmpZMdoyRiBoW",
"identityIDShort": "XBgY5DsUPng",
"publicKey": "9DB3j9cWYSuEEtkvanrzqkzCQMdH1FGv3TawJdVbDxkd",
"solidBlockCount": 74088,
"totalBlockCount": 74088,
"enabledPlugins": [
"Activity",
"AnalysisClient",
"AutoPeering",
"Banner",
"CLI",
"Clock",
"Config",
"Consensus",
"DRNG",
"Dashboard",
"Database",
"Gossip",
"GracefulShutdown",
"Logger",
"Mana",
"ManaRefresher",
"ManualPeering",
"BlockLayer",
"Metrics",
"NetworkDelay",
"PoW",
"PortCheck",
"Profiling",
"Prometheus",
"RemoteLog",
"RemoteLogMetrics",
"WebAPI",
"WebAPIDRNGEndpoint",
"WebAPIManaEndpoint",
"WebAPIWeightProviderEndpoint",
"WebAPIAutoPeeringEndpoint",
"WebAPIDataEndpoint",
"WebAPIFaucetEndpoint",
"WebAPIHealthzEndpoint",
"WebAPIInfoEndpoint",
"WebAPILedgerstateEndpoint",
"WebAPIBlockEndpoint",
"WebAPIToolsEndpoint",
"snapshot"
],
"disabledPlugins": [
"AnalysisDashboard",
"AnalysisServer",
"Faucet",
"ManaEventLogger",
"Spammer",
"TXStream"
],
"mana": {
"access": 1,
"accessTimestamp": "2021-05-24T20:11:05.451224937+02:00",
"consensus": 10439991680906,
"consensusTimestamp": "2021-05-24T20:11:05.451228137+02:00"
},
"manaDelegationAddress": "1HMQic52dz3xLY2aeDXcDhX53LgbsHghdfD8eGXR1qVHy",
"mana_decay": 0.00003209,
"scheduler": {
"running": true,
"rate": "5ms",
"nodeQueueSizes": {}
},
"rateSetter": {
"rate": 20000,
"size": 0
}
}

Results

Return fieldTypeDescription
versionStringVersion of GoShimmer.
networkVersionuint32Network Version of the autopeering.
tangleTimeTangleTimeTangleTime sync status
identityIDstringIdentity ID of the node encoded in base58.
identityIDShortstringIdentity ID of the node encoded in base58 and truncated to its first 8 bytes.
publicKeystringPublic key of the node encoded in base58
blockRequestQueueSizeintThe number of blocks a node is trying to request from neighbors.
solidBlockCountintThe number of solid blocks in the node's database.
totalBlockCountintThe number of blocks in the node's database.
enabledPlugins[]stringList of enabled plugins.
disabledPlugins[]stringList if disabled plugins.
manaManaMana values.
manaDelegationAddressstringMana Delegation Address.
mana_decayfloat64The decay coefficient of bm2.
schedulerSchedulerScheduler is the scheduler used.
rateSetterRateSetterRateSetter is the rate setter used.
errorstringError block. Omitted if success.
  • Type TangleTime
fieldTypeDescription
blockIDstringID of the last confirmed block.
timeint64Issue timestamp of the last confirmed block.
syncedboolFlag indicating whether node is in sync.
  • Type Scheduler
fieldTypeDescription
runningboolFlag indicating whether Scheduler has started.
ratestringRate of the scheduler.
nodeQueueSizesmap[string]intThe size for each node queue.
  • Type RateSetter
fieldTypeDescription
ratefloat64The rate of the rate setter..
sizeintThe size of the issuing queue.
  • Type Mana
fieldTypeDescription
accessfloat64Access mana assigned to the node.
accessTimestamptime.TimeTime when the access mana was calculated.
consensusfloat64Consensus mana assigned to the node.
consensusTimestamptime.TimeTime when the consensus mana was calculated.

/healthz

Returns HTTP code 200 if everything is running correctly.

Parameters

None.

Examples

cURL

curl --location 'http://localhost:8080/healthz'

Client lib

This method is not available in client lib

Results

Empty response with HTTP 200 success code if everything is running correctly. Error block is returned if failed.