cgminer-rest

Crates.iocgminer-rest
lib.rscgminer-rest
version0.1.2
sourcesrc
created_at2018-12-17 01:13:46.964388
updated_at2018-12-17 01:13:46.964388
descriptionRESTful HTTP API wrapper for cgminer
homepage
repositoryhttps://github.com/brndnmtthws/cgminer-rest
max_upload_size
id102249
size9,461,114
Brenden Matthews (brndnmtthws)

documentation

README

Build Status Current Crates.io Version

cgminer-rest: a RESTful HTTP wrapper for the cgminer API

Demo

This package provides a RESTful HTTP wrapper around the cgminer API. Cgminer has a somewhat esoteric API, which isn't easy to use with standard HTTP-based tooling. Using this tool, it's easy to interact with cgminer programmatically or using a UI, such as through a web browser.

Installing

The package can be installed from crates.io using the cargo tool:

$ cargo install cgminer-rest
...
$ cgminer-rest

See Rocket.toml for configuration details.

Example

API

Endpoints

🛰  Mounting /:
    => GET /version (version)
    => GET /config (config)
    => GET /summary (summary)
    => GET /devs (devs)
    => GET /devdetails (devdetails)
    => GET /stats (stats)
    => GET /coin (coin)
    => GET /usbstats (usbstats)
    => GET /lcd (lcd)
    => GET /notify (notify)
    => GET /privileged (privileged)
    => PUT /restart (restart)
    => PUT /check/<command> (check)
    => PUT /debug (debug)
    => PUT /hotplug (hotplug)
    => GET /lockstats (lockstats)
    => PUT /zero (zero)
🛰  Mounting /pools:
    => GET /pools (pools)
    => PUT /pools/<id>/switchto (switchpool)
    => PUT /pools/<id>/enable (enablepool)
    => PUT /pools/<id>/disable (disablepool)
    => POST /pools (addpool)
    => DELETE /pools/<id> (removepool)
    => PUT /pools/<id>/quota (poolquota)
🛰  Mounting /pga:
    => GET /pga/<id> (pga)
    => GET /pga/count (pgacount)
    => PUT /pga/<id>/enable (pgaenable)
    => PUT /pga/<id>/disable (pgadisable)
    => GET /pga/<id>/identify (pgaidentify)
    => PUT /pga/<id> (pgaset)
🛰  Mounting /asc:
    => GET /asc/<id> (asc)
    => GET /asc/count (asccount)
    => PUT /asc/<id>/enable (ascenable)
    => PUT /asc/<id>/disable (ascdisable)
    => GET /asc/<id>/identify (ascidentify)
    => PUT /asc/<id> (ascset)
Commit count: 76

cargo fmt