Rental HashRateRental HashRateMinerCore Ecosystem

Developer

API Documentation

REST API for marketplace data, rigs, rentals, and account automation. Create keys under API Keys.

General

Base URL: https://dev.mcrental.minercore.online/api/v1

Responses use { "success": true, "data": … } on success and { "success": false, "error": "CODE" } on failure. Always check HTTP status codes as well.

This is the current API v1 for Rental HashRate. Auth headers follow the same HMAC pattern as common marketplace APIs (key + nonce + endpoint, SHA1 HMAC).

Authentication

  • x-api-key — your API key id
  • x-api-nonce — unique, increasing nonce (e.g. microtime-based string)
  • x-api-sign — HMAC-SHA1 of api_key + nonce + endpoint with your API secret

Endpoint for signing is the path after /api/v1, without a trailing slash and without query string. Example: GET /api/v1/rig/abc → sign /rig/abc.

const crypto = require("crypto");

const apiKey = "rh_…";
const apiSecret = "…";
const endpoint = "/whoami"; // no /api/v1, no trailing slash
const nonce = String(Date.now()) + String(process.hrtime()[1]).slice(0, 4);

const sign = crypto
  .createHmac("sha1", apiSecret)
  .update(apiKey + nonce + endpoint)
  .digest("hex");

const res = await fetch("https://dev.mcrental.minercore.online/api/v1" + endpoint, {
  headers: {
    "x-api-key": apiKey,
    "x-api-nonce": nonce,
    "x-api-sign": sign,
  },
});

Never put the API secret in frontend / browser code. Sign on a server you control.

Permissions

Each key has three modules, each set to write, read, or none:

  • permAccount — balances, transactions, pool profiles
  • permRental — marketplace browse + rentals
  • permRig — your rigs

Public /info/* and authenticated /whoami do not require module permissions.

Rate limits

Default documented limit: 100 requests per minute per IP. Cache when possible, avoid burst polling, and use backoff on errors. Need more? Open a Support ticket with your use case — do not send your API secret.

Errors

{ "success": false, "error": "INVALID_SIGNATURE" }

Common codes: INVALID_KEY, INVALID_SIGNATURE, PERMISSION_DENIED, INVALID_BODY, plus domain errors from each method.

Whoami

GETGET /api/v1/whoami

Test authentication and list key permissions.

Auth: Required (HMAC)
Sign path: /whoami
Full URL: https://dev.mcrental.minercore.online/api/v1/whoami

Example response

{
  "success": true,
  "data": {
    "authed": true,
    "userid": "…",
    "username": "alice",
    "api_key": "rh_…",
    "api_nonce": "1710000000123456",
    "permissions": { "withdraw": "yes", "rent": "yes", "rigs": "yes" },
    "permission_levels": {
      "permAccount": "write",
      "permRental": "write",
      "permRig": "write"
    }
  }
}

Info (public)

GETGET /api/v1/info/assets

List payment assets available on the platform.

Auth: Public (no signature)
Full URL: https://dev.mcrental.minercore.online/api/v1/info/assets
GETGET /api/v1/info/algorithms

List marketplace algorithms (Phase 1 active markets).

Auth: Public (no signature)
Full URL: https://dev.mcrental.minercore.online/api/v1/info/algorithms

Account

GETGET /api/v1/account/balance

Wallet balances by asset.

Auth: Required (HMAC)
Permission: permAccount read+
Sign path: /account/balance
Full URL: https://dev.mcrental.minercore.online/api/v1/account/balance
GETGET /api/v1/account/transactions

Ledger / transaction history.

Auth: Required (HMAC)
Permission: permAccount read+
Sign path: /account/transactions
Full URL: https://dev.mcrental.minercore.online/api/v1/account/transactions

Query params

  • limitPage size (default depends on server).
  • startOffset for pagination.
GETGET /api/v1/account/profile

List pool profiles.

Auth: Required (HMAC)
Permission: permAccount read+
Sign path: /account/profile
Full URL: https://dev.mcrental.minercore.online/api/v1/account/profile

Query params

  • algoFilter by algorithm slug (e.g. scrypt, sha256ab).
PUTPUT /api/v1/account/profile

Create a pool profile.

Auth: Required (HMAC)
Permission: permAccount write
Sign path: /account/profile
Full URL: https://dev.mcrental.minercore.online/api/v1/account/profile

Body (JSON)

{
  "name": "My scrypt profile",
  "algo": "scrypt"
}
GETGET /api/v1/account/profile/{id}

Pool profile detail including pool slots.

Auth: Required (HMAC)
Permission: permAccount read+
Sign path: /account/profile/{id}
Full URL: https://dev.mcrental.minercore.online/api/v1/account/profile/:id
  • Sign the concrete path, e.g. /account/profile/abc123 — not the {id} placeholder.
PUTPUT /api/v1/account/profile/{id}/{priority}

Set a pool slot on a profile (priority 0–4).

Auth: Required (HMAC)
Permission: permAccount write
Sign path: /account/profile/{id}/{priority}
Full URL: https://dev.mcrental.minercore.online/api/v1/account/profile/:id/:id

Body (JSON)

{
  "host": "stratum+tcp://pool.example:3333",
  "user": "wallet.worker",
  "pass": "x"
}
GETGET /api/v1/account/pool

List saved pools.

Auth: Required (HMAC)
Permission: permAccount read+
Sign path: /account/pool
Full URL: https://dev.mcrental.minercore.online/api/v1/account/pool
PUTPUT /api/v1/account/pool

Create a saved pool.

Auth: Required (HMAC)
Permission: permAccount write
Sign path: /account/pool
Full URL: https://dev.mcrental.minercore.online/api/v1/account/pool

Body (JSON)

{
  "name": "Home pool",
  "host": "stratum+tcp://pool.example:3333",
  "user": "wallet.worker",
  "pass": "x",
  "algo": "scrypt"
}
GETGET /api/v1/account/pool/{id}

Saved pool detail.

Auth: Required (HMAC)
Permission: permAccount read+
Sign path: /account/pool/{id}
Full URL: https://dev.mcrental.minercore.online/api/v1/account/pool/:id

Rigs

GETGET /api/v1/rig

Search marketplace rigs.

Auth: Required (HMAC)
Permission: permRental read+ (marketplace browse)
Sign path: /rig
Full URL: https://dev.mcrental.minercore.online/api/v1/rig

Query params

  • typeAlgorithm slug filter.
  • limitPage size.
  • startOffset.
GETGET /api/v1/rig/mine

List your owned rigs.

Auth: Required (HMAC)
Permission: permRig read+
Sign path: /rig/mine
Full URL: https://dev.mcrental.minercore.online/api/v1/rig/mine
GETGET /api/v1/rig/{id}

Rig detail.

Auth: Required (HMAC)
Permission: permRental or permRig read+
Sign path: /rig/{id}
Full URL: https://dev.mcrental.minercore.online/api/v1/rig/:id
GETGET /api/v1/rig/{id}/graph

Hashrate chart / telemetry points for a rig.

Auth: Required (HMAC)
Permission: permRental or permRig read+
Sign path: /rig/{id}/graph
Full URL: https://dev.mcrental.minercore.online/api/v1/rig/:id/graph
PUTPUT /api/v1/rig

Create a rig listing.

Auth: Required (HMAC)
Permission: permRig write
Sign path: /rig
Full URL: https://dev.mcrental.minercore.online/api/v1/rig

Body (JSON)

{
  "name": "My rig",
  "type": "scrypt",
  "hash": { "hash": 50, "type": "gh" },
  "price": { "btc": { "price": "0.0001" } },
  "minhours": 3,
  "maxhours": 48,
  "pool_url": "stratum+tcp://pool:3333",
  "pool_user": "worker",
  "pool_password": "x"
}
PUTPUT /api/v1/rig/{id}

Update an owned rig.

Auth: Required (HMAC)
Permission: permRig write
Sign path: /rig/{id}
Full URL: https://dev.mcrental.minercore.online/api/v1/rig/:id

Rentals

GETGET /api/v1/rental

List rentals for your account.

Auth: Required (HMAC)
Permission: permRental read+
Sign path: /rental
Full URL: https://dev.mcrental.minercore.online/api/v1/rental

Query params

  • typerenter (default) or owner.
  • historytrue to include finished rentals.
  • algoAlgorithm filter.
  • rigFilter by rig id.
  • currencyPay asset filter.
  • limitPage size (default 25).
  • startOffset.
GETGET /api/v1/rental/{id}

Rental detail.

Auth: Required (HMAC)
Permission: permRental read+
Sign path: /rental/{id}
Full URL: https://dev.mcrental.minercore.online/api/v1/rental/:id
PUTPUT /api/v1/rental

Create a rental. Use a pool profile id or explicit pool fields.

Auth: Required (HMAC)
Permission: permRental write
Sign path: /rental
Full URL: https://dev.mcrental.minercore.online/api/v1/rental

Body (JSON)

{
  "rig": "<rigId>",
  "length": 3,
  "currency": "BTC",
  "profile": "<poolProfileId>"
}

// or explicit pool:
{
  "rig": "<rigId>",
  "length": 3,
  "currency": "BTC",
  "pool_url": "stratum+tcp://pool:3333",
  "pool_user": "wallet.worker",
  "pool_password": "x"
}
PUTPUT /api/v1/rental/{id}/extend

Extend an active rental. Pass getcost=true to simulate cost only.

Auth: Required (HMAC)
Permission: permRental write
Sign path: /rental/{id}/extend
Full URL: https://dev.mcrental.minercore.online/api/v1/rental/:id/extend

Body (JSON)

{
  "length": 2,
  "getcost": false
}