mirror of
https://github.com/grocy/grocy.git
synced 2025-08-20 04:12:59 +00:00
Start working on API documentation and token auth (references #5)
This commit is contained in:
47
helpers/grocy.openapi.json
Normal file
47
helpers/grocy.openapi.json
Normal file
@@ -0,0 +1,47 @@
|
||||
{
|
||||
"openapi": "3.0.0",
|
||||
"info": {
|
||||
"title": "grocy REST API",
|
||||
"description": "xxx",
|
||||
"version": "xxx"
|
||||
},
|
||||
"servers": [
|
||||
{
|
||||
"url": "xxx"
|
||||
}
|
||||
],
|
||||
"paths": {
|
||||
"/get-objects/{entity}": {
|
||||
"get": {
|
||||
"description": "Returns all objects of the given entity",
|
||||
"parameters": [
|
||||
{
|
||||
"in": "path",
|
||||
"name": "entity",
|
||||
"required": true,
|
||||
"description": "A valid entity name",
|
||||
"schema": {
|
||||
"$ref": "#/components/schemas/Entity"
|
||||
}
|
||||
}
|
||||
],
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "OK"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"components": {
|
||||
"schemas": {
|
||||
"Entity": {
|
||||
"type": "string",
|
||||
"enum": [
|
||||
"product",
|
||||
"habit"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user