All Hashes
This endpoint return all hashes.
URL :
/hash/list
/hash/list?createdAt={createdAt}
/hash/list?blockchain={BTC|ETH}
/hash/list?customerId={customerId}
/hash/list?bin={bin}
/hash/list?from={from}&to={to}
Method : GET
X-HMAC required : YES
Request Query Parameters :
createdAtoptional
2024-02-10T10:00:00
blockchainoptional
BTC or ETH
customerIdoptional
any
binoptional
521739b1-5f51-4245-b80b-e45465925347
from-tooptional
from 2024-02-28T10:00:00
to 2024-02-30T08:00:00
You have to write both of the params together, otherwise the query will not work
You can chain all parameters as you like
Response
The response will be a JSON object containing all hashes.
interface Hash {
id: number
hashId: string
bin: string
customer: string
data: string
hash: string
createdAt: Date
publishId: number
publish: Publish
}
interface Response {
data: Hash[]
}
Status Codes
The endpoint will return the following status codes based on the operation outcome:
- 200
OK: The request was successful. - 400
Bad Request: No data are published. - 500
Internal Server Error: An error occurred on the server while processing the request.
Example Request
GET /hash/list HTTP/1.1
Content-Type: application/json
Host: localhost:3000
X-HMAC: 5d41402abc4b2a76b9719d911017c592
Example Response
{
"data": [
{
"id": 10,
"hashId": "521739b1-5f51-4245-b80b-e45465925347-2024-01-25T10:00:00Z",
"bin": "521739b1-5f51-4245-b80b-e45465925347",
"customer": "2",
"data": "{\"alerts\":[{\"code\":\"SE001001\",\"ts\":\"2024-01-25T10:00:00Z\"}],\"bin\":\"521739b1-5f51-4245-b80b-e45465925347\",\"data\":{\"amp\":2,\"tmp\":3,\"ts\":\"2024-01-25T10:00:00Z\",\"vlt\":1}}",
"hash": "d7da2a6fdcbf73dbace7b5de468fb37669593ce435d89322af65a291ac2679c9",
"createdAt": "2024-01-25T10:00:00.000Z",
"publishId": 11
}
]
}
Table of Contents
