Use the public APILink to this section
TL;DRLink to this section
- Public GET routes need no API key, wallet connection or private SDK.
- Check the response version, availability and source before using its values.
- This API snapshot supports Mining4 integration, not Mining5.
Before you startLink to this section
Obtain the API base URL for your approved environment from its deployment configuration. This source reference does not designate a current public service endpoint.
The examples use curl; set API_BASE_URL to that endpoint. Do not send device, indexer or administrator credentials to public routes.
StepsLink to this section
-
Read the configured public installation's telemetry:
: "${API_BASE_URL:?Set API_BASE_URL to the approved API endpoint}" curl --include --fail-with-body --silent --show-error \ "$API_BASE_URL/v1/public/telemetry"A complete illustrative HTTP 200 response, for a fictitious installation with no received measurement, is:
{ "schemaVersion": 1, "installationId": "example-installation", "revision": null, "status": "offline", "observedAt": null, "receivedAt": null, "softwareVersion": null, "measurement": null } -
Inspect the body, not just HTTP status. Here
offlineandmeasurement: nullmean no measurement is available; they do not report zero work. Use the telemetry response contract and preserve timestamps and provenance when a measurement is present. - Choose your next public API resource. Keep large decimal-string counters and amounts as strings or
BigInt, and handle that resource's unavailable variant before displaying values. -
For an owner portfolio, request a bounded page and retain the owner while following
nextCursor:curl --get --fail-with-body --silent --show-error \ "$API_BASE_URL/v2/public/squeeks/portfolio" \ --data-urlencode "owner=${OWNER:?Set OWNER to the intended lowercase address}" \ --data-urlencode "limit=25"On later requests, add
--data-urlencode "cursor=$NEXT_CURSOR"with the returned non-null cursor. Stop when it is null; never decode it or reuse it with another owner. See portfolio parameters and responses. -
Keep settlement history's response headers alongside its body:
curl --include --fail-with-body --silent --show-error \ "$API_BASE_URL/v4/public/settlements?range=now&queue=1"Preserve
X-Squeek-Settlement-Source, any fallback reason,generatedAtand the last safe block. The settlement reference distinguishes cached history, pending queue work and confirmed issuance. -
For NFT display, request token metadata with the intended release when you need its card image URL. The metadata response is not immutable; follow its cache headers, and use metadata verification for independent onchain checks.
Expected resultLink to this section
Your application distinguishes available values, stale measurements, unavailable data and HTTP failures. It retains source identity and age instead of silently substituting another deployment or displaying unavailable rewards as zero.
Common failuresLink to this section
- HTTP 400: correct the request before retrying; HTTP 403: use an approved browser origin.
- HTTP 503: preserve the error state, respect
Retry-Afterand bound retries. - Invalid JSON, schema mismatches and timeouts: report an error, not empty data.
See HTTP errors and conditional responses for exact codes, response bodies and retry-header guarantees. Availability reasons and caching belong to each endpoint's reference.
Verify the resultLink to this section
Check the response against the endpoint's linked JSON Schema and its semantic rules. Do not use a telemetry or process projection as evidence of settlement.
For chain-backed views, check the intended chain, release, contract identities and confirmation-safe block. API display data does not authorize a transaction: read current chain state and simulate before signing.
SourceLink to this section
System/API source snapshot 9e38b931. The example is illustrative, not a live service read; first-party source is private; see source and release scope.