Transaction documentation

A transaction request between source and target to move amount Gradecoin.

Requests

GET

A HTTP GET request to /transaction endpoint will return the current list of pending transactions.

POST

A HTTP POST request with Authorization using JWT to /transaction will allow you to propose your own transactions.

Fields

source: Fingerprint
target: Fingerprint
amount: unsigned 16 bit integer
timestamp: ISO 8601 <date>T<time>

Hash

tha field in jwt documentation in fact stands for "The Hash". In the context of a transaction proposal, you need the Md5 hash of the serialized JSON representation of transaction. Since there are many ways to convert an object to JSON, we enforce the following rules (alongside the regular rules of JSON syntax) for consistency:

Here's an example on how your JSON string should look like:

{"source":"bar","target":"baz","amount":2,"timestamp":"2021-04-18T21:49:00"}

Transaction Rules