daodm/streamcardano/1.0.0

StreamCardano.Api

Helpers for sending Http requests to the StreamCardano endpoints.

StreamCardano API credentials

credentials : { r | host : String, key : String } -> Credentials

Init credentials

Get Requests

getStatus : (Result Error Status -> msg) -> Credentials -> Cmd msg

SEND a basic request to check if the Service is online. No authentication is required.

getLastBlock : (Result Error LastBlock -> msg) -> Credentials -> Cmd msg

Checking StreamCardano is up-to-date with the Cardano network.

Post Requests

postQuery : (Result Error Query -> msg) -> Credentials -> String -> Cmd msg

Selecting data with a custom SQL query.

postQueryDebug : (Result Error Query -> msg) -> Credentials -> String -> Cmd msg

Selecting data with a custom SQL query. Use Debug endpoint