Operations
Use the blockchain as your trusted database.
Saves data to selected blockchain network you can later retrieve using select operation.
POST
https://api.bws.ninja/v1/call
Request Body
Name
Type
Value
solution*
string
BWS.Blockchain.Hash
version*
number
1
operation*
string
insert
Parameter
Type
Max. Size
Desciption
key
string
network limits
The key for your data. You can use this key to select the data using select operation.
value
string
network limits
The value to save to the selected blockchain
Curl Example
curl --location 'https://api.bws.ninja/v1/call' \
--header 'X-Api-Key: API-KEY' \
--header 'Content-Type: application/json' \
--data '{
"solution": "BWS.Blockchain.Hash",
"version": 1,
"network": "matchain",
"operation": "insert",
"parameters": {
"key": "my patient id",
"value": "my patient data"
}
}'
Retrieve previously saved data using insert operation.
POST
https://api.bws.ninja/v1/call
Request Body
Name
Type
Description
solution*
string
BWS.Blockchain.Hash
version*
number
1
operation*
string
select
Method Parameters
Parameter
Type
Max. Size
Desciption
Curl Example
curl --location 'https://api.bws.ninja/v1/call' \
--header 'X-Api-Key: API-KEY' \
--header 'Content-Type: application/json' \
--data '{
"contract": "Ethereum.Database.Mutable",
"version": 1,
"network": "matchain",
"operation": "select",
"parameters": {
"key": "my patient id"
}
}'
Last updated
Was this helpful?