58 lines
1.2 KiB
HTTP
58 lines
1.2 KiB
HTTP
### create row
|
|
POST http://localhost:9001/api/vehicle
|
|
Content-Type: application/json
|
|
|
|
{
|
|
"data": {
|
|
"number": "KA03HD6064"
|
|
},
|
|
"uniqueIdentifier": "KA03HD6064"
|
|
}
|
|
|
|
### create row, with autogenerated identifier
|
|
POST http://localhost:9001/api/log
|
|
Content-Type: application/json
|
|
|
|
{
|
|
"data": {
|
|
"user": "gowthaman",
|
|
"action": "logout"
|
|
}
|
|
}
|
|
|
|
### get row
|
|
GET http://localhost:9001/api/vehicle/KA03HD6064
|
|
|
|
### query row
|
|
POST http://localhost:9001/api/vehicle/query
|
|
Content-Type: application/json
|
|
|
|
{
|
|
"sql": "select sys_pk, tenant_id, deleted_on, deleted_by, deleted, version, created_at, modified_at, created_by, modified_by, data, tags, comments, unique_identifier, entity_name from data_model where data ->> 'number' = :number",
|
|
"params": {
|
|
"number": "KA03HD6064"
|
|
}
|
|
}
|
|
|
|
### update field
|
|
PATCH http://localhost:9001/api/vehicle/KA03HD6064
|
|
Content-Type: application/json
|
|
|
|
{
|
|
"key": "ownerName",
|
|
"value": "Gowthaman Basuvaraj"
|
|
}
|
|
|
|
|
|
### upate a row
|
|
PUT http://localhost:9001/api/vehicle/KA03HD6064
|
|
Content-Type: application/json
|
|
|
|
{
|
|
"number": "KA03HD6064",
|
|
"ownerName": "Gowthaman Basuvaraj",
|
|
"address": "Sathyamangalam"
|
|
}
|
|
|
|
### delete a row
|
|
DELETE http://localhost:9001/api/vehicle/KA03HD6064 |