-
Notifications
You must be signed in to change notification settings - Fork 40
API
MaynardMiner edited this page Mar 28, 2019
·
29 revisions
SWARM API
Endpoints
Global security
if -APIPassword argument is set, then new endpoint becomes:
http://localhost:4099/[password]/
Remote Endpoint (if -Remote yes was set)
http://ip.address:4099/[password]/
GET /summary
Request
no extra variable.
Response
Array of ALL current pool and miner configurations.
Example:
[ { "Power": 0.0, "Pool_Estimate": 2.21445E-11, "Type": "NVIDIA2", "Miner": "TRex-2", "Name": "x22i", "Arguments": "-a x22i -o stratum+tcp://blockmasters.co:3223 --api-bind-telnet 0.0.0.0:4069 --api-bind-http 0.0.0.0:4072 -u 1DRxiWx6yuZfN9hrEJa3BDXWVJ9yyJU36i -p c=BTC,ID=MKVITO2 ", "HashRates": null, "Profits": null, "Algo": "x22i", "Fullname": "x22i", "MinerPool": "blockmasters" }, { "Power": 0.0, "Pool_Estimate": 1.135035E-10, "Type": "NVIDIA2", "Miner": "CryptoDredge-2", "Name": "neoscrypt", "Arguments": "-a neoscrypt -o stratum+tcp://neoscrypt.mine.ahashpool.com:4233 -b 0.0.0.0:4069 -u 1DRxiWx6yuZfN9hrEJa3BDXWVJ9yyJU36i -p c=BTC,ID=MKVITO2 ", "HashRates": null, "Profits": null, "Algo": "neoscrypt", "Fullname": "neoscrypt", "MinerPool": "ahashpool" } ]
GET /getstats
Request
no extra variable.
Response
Array of current GPU stats.
Example:
[{"GPU0":{"fans":"75","hashrate":"0.001","temperature":"69"}},{"GPU1":{"fans":"75","hashrate":"7114.77","temperature":"69"}},{"GPU2":{"fans":"75","hashrate":"0.001","temperature":"72"}},{"GPU3":{"fans":"75","hashrate":"7400.83","temperature":"63"}},{"GPU4":{"fans":"75","hashrate":"0.001","temperature":"66"}},{"GPU5":{"fans":"75","hashrate":"7317.26","temperature":"66"}},{"GPU6":{"fans":"75","hashrate":"7312.13","temperature":"70"}},{"GPU7":{"fans":"75","hashrate":"7391.74","temperature":"64"}},{"GPU8":{"fans":"75","hashrate":"7217.69","temperature":"66"}},{"GPU9":{"fans":"75","hashrate":"0.001","temperature":"73"}},{"GPU10":{"fans":"75","hashrate":"0.001","temperature":"71"}},{"GPU11":{"fans":"75","hashrate":"7255.27","temperature":"68"}},{"GPU12":{"fans":"75","hashrate":"0.001","temperature":"61"}},{"Algorithm":"x17"},{"Uptime":"297"},{"Hash_Units":"khs"},{"Accepted":"54"},{"Rejected":"0"}]
GET /getbest
Request
no extra variable.
Response
Array of current miners SWARM is using- The Miners Determined To Be Best.
Example:
[{"AMD1":[{"Delay":"1","Name":"fancyix-1","Type":"AMD1","Devices":"none","ArgDevices":null,"DeviceCall":"sgminer-gm","MinerName":"sgminer.exe","Path":".\\bin\\fancyix-1\\sgminer.exe","Arguments":"--gpu-platform 0 --api-listen --api-port 4028 -k allium -o stratum+tcp://allium.mine.zergpool.com:6433 -u 1DRxiWx6yuZfN9hrEJa3BDXWVJ9yyJU36i -p c=BTC,ID=AMD -T -w 256 -I 22","API":"sgminer-gm","Port":4028,"Coins":"allium","Active":{"Ticks":0,"Days":0,"Hours":0,"Milliseconds":0,"Minutes":0,"Seconds":0,"TotalDays":0,"TotalHours":0,"TotalMilliseconds":0,"TotalMinutes":0,"TotalSeconds":0},"Activated":0,"Status":"Idle","HashRate":0,"Benchmarked":0,"WasBenchmarked":false,"XProcess":null,"MinerPool":"zergpool","Algo":"allium","FullName":"allium","Instance":null,"InstanceName":null,"Username":null,"Connection":null,"Password":null,"BestMiner":true,"JsonFile":null,"LogGPUS":"none","FirstBad":null,"Prestart":["export LD_LIBRARY_PATH=C:\\Users\\Mayna\\Documents\\GitHub\\SWARM\\build\\export","export GPU_MAX_HEAP_SIZE=100","export GPU_USE_SYNC_OBJECTS=1","export GPU_SINGLE_ALLOC_PERCENT=100","export GPU_MAX_ALLOC_PERCENT=100"],"ocpl":null,"ocdpm":"","ocv":"","occore":"","ocmem":"","ocmdpm":"","ocpower":null,"ocfans":"","ethpill":null,"pilldelay":null,"Host":null,"User":null,"CommandFile":null,"Profit":"bench","Power":0,"Fiat_Day":"bench","Log":"C:\\Users\\Mayna\\Documents\\GitHub\\SWARM\\logs\\AMD1.log","Strike":false}]},{"NVIDIA2":[{"Delay":"1","Name":"bminer-2","Type":"NVIDIA2","Devices":"none","ArgDevices":null,"DeviceCall":"bminer","MinerName":"bminer","Path":".\\bin\\bminer-2\\bminer.exe","Arguments":"-uri equihash1445://1DRxiWx6yuZfN9hrEJa3BDXWVJ9yyJU36i.@equihash144.mine.zergpool.com:2146 -logfile \u0027C:\\Users\\Mayna\\Documents\\GitHub\\SWARM\\logs\\NVIDIA2.log\u0027 -api 127.0.0.1:44001","API":"bminer","Port":44001,"Coins":"equihash144","Active":{"Ticks":0,"Days":0,"Hours":0,"Milliseconds":0,"Minutes":0,"Seconds":0,"TotalDays":0,"TotalHours":0,"TotalMilliseconds":0,"TotalMinutes":0,"TotalSeconds":0},"Activated":0,"Status":"Idle","HashRate":0,"Benchmarked":0,"WasBenchmarked":false,"XProcess":null,"MinerPool":"zergpool","Algo":"equihash144","FullName":"equihash144","Instance":null,"InstanceName":null,"Username":null,"Connection":null,"Password":null,"BestMiner":true,"JsonFile":null,"LogGPUS":"none","FirstBad":null,"Prestart":"export LD_LIBRARY_PATH=C:\\Users\\Mayna\\Documents\\GitHub\\SWARM\\build\\export","ocpl":null,"ocdpm":null,"ocv":null,"occore":"","ocmem":"","ocmdpm":null,"ocpower":"","ocfans":"","ethpill":null,"pilldelay":null,"Host":null,"User":null,"CommandFile":null,"Profit":"bench","Power":0,"Fiat_Day":"bench","Log":"miner_generated","Strike":false}]}]