- FieldRelationContract/FieldRelationProvider bind every type: relation
field to a belongsTo foreign key or a belongsToMany pivot; activation
fails naming plugin, controller and field on a missing or broken contract
- GET /{vendor}/{plugin}/{controller}/fields/{field}/options serves
{value, label} pages scoped by pact.RelationExtendOptionsQuery, behind
the controller permission; read-only and non-relation fields are 404
- Saves apply present relation keys after the Before hook: ids are
revalidated through the same scoped query (422 and full rollback
otherwise), belongsTo sets the foreign key, belongsToMany replaces pivot
rows in submitted order with the order column set to the index
- Show, create and update return relation values in data and meta.labels
- A belongsTo on a protected fill key is read-only (D-26)
- One six-segment GET pattern dispatches relation lists and field options,
which ServeMux cannot register side by side
- Admin OpenAPI documents the options route and RecordEnvelope
2447 lines
85 KiB
JSON
2447 lines
85 KiB
JSON
{
|
|
"components": {
|
|
"schemas": {
|
|
"cabana.AdminLoginData": {
|
|
"properties": {
|
|
"access_token": {
|
|
"type": "string"
|
|
},
|
|
"expires_in": {
|
|
"type": "integer"
|
|
},
|
|
"token_type": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"required": [
|
|
"token_type"
|
|
],
|
|
"type": "object"
|
|
},
|
|
"cabana.AdminLoginRequest": {
|
|
"properties": {
|
|
"email": {
|
|
"type": "string"
|
|
},
|
|
"login": {
|
|
"type": "string"
|
|
},
|
|
"password": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"required": [
|
|
"password"
|
|
],
|
|
"type": "object"
|
|
},
|
|
"cabana.AdminProfile": {
|
|
"properties": {
|
|
"email": {
|
|
"type": "string"
|
|
},
|
|
"first_name": {
|
|
"type": "string"
|
|
},
|
|
"id": {
|
|
"type": "integer"
|
|
},
|
|
"is_superuser": {
|
|
"type": "boolean"
|
|
},
|
|
"last_name": {
|
|
"type": "string"
|
|
},
|
|
"login": {
|
|
"type": "string"
|
|
},
|
|
"role": {
|
|
"$ref": "#/components/schemas/cabana.AdminRoleSummary"
|
|
}
|
|
},
|
|
"required": [
|
|
"email",
|
|
"first_name",
|
|
"id",
|
|
"is_superuser",
|
|
"last_name",
|
|
"login"
|
|
],
|
|
"type": "object"
|
|
},
|
|
"cabana.AdminRecord": {
|
|
"additionalProperties": {},
|
|
"type": "object"
|
|
},
|
|
"cabana.AdminRoleSummary": {
|
|
"properties": {
|
|
"code": {
|
|
"type": "string"
|
|
},
|
|
"id": {
|
|
"type": "integer"
|
|
},
|
|
"name": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"required": [
|
|
"code",
|
|
"id",
|
|
"name"
|
|
],
|
|
"type": "object"
|
|
},
|
|
"cabana.BulkAction": {
|
|
"properties": {
|
|
"label": {
|
|
"type": "string"
|
|
},
|
|
"name": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"required": [
|
|
"name"
|
|
],
|
|
"type": "object"
|
|
},
|
|
"cabana.Envelope-array_cabana_NavigationEntry": {
|
|
"properties": {
|
|
"data": {
|
|
"items": {
|
|
"$ref": "#/components/schemas/cabana.NavigationEntry"
|
|
},
|
|
"type": "array"
|
|
},
|
|
"meta": {
|
|
"$ref": "#/components/schemas/cabana.SuccessMeta"
|
|
}
|
|
},
|
|
"required": [
|
|
"data",
|
|
"meta"
|
|
],
|
|
"type": "object"
|
|
},
|
|
"cabana.Envelope-cabana_AdminLoginData": {
|
|
"properties": {
|
|
"data": {
|
|
"$ref": "#/components/schemas/cabana.AdminLoginData"
|
|
},
|
|
"meta": {
|
|
"$ref": "#/components/schemas/cabana.SuccessMeta"
|
|
}
|
|
},
|
|
"required": [
|
|
"data",
|
|
"meta"
|
|
],
|
|
"type": "object"
|
|
},
|
|
"cabana.Envelope-cabana_AdminProfile": {
|
|
"properties": {
|
|
"data": {
|
|
"$ref": "#/components/schemas/cabana.AdminProfile"
|
|
},
|
|
"meta": {
|
|
"$ref": "#/components/schemas/cabana.SuccessMeta"
|
|
}
|
|
},
|
|
"required": [
|
|
"data",
|
|
"meta"
|
|
],
|
|
"type": "object"
|
|
},
|
|
"cabana.Envelope-cabana_ListSchema": {
|
|
"properties": {
|
|
"data": {
|
|
"$ref": "#/components/schemas/cabana.ListSchema"
|
|
},
|
|
"meta": {
|
|
"$ref": "#/components/schemas/cabana.SuccessMeta"
|
|
}
|
|
},
|
|
"required": [
|
|
"data",
|
|
"meta"
|
|
],
|
|
"type": "object"
|
|
},
|
|
"cabana.ErrorBody": {
|
|
"properties": {
|
|
"code": {
|
|
"type": "string"
|
|
},
|
|
"details": {
|
|
"additionalProperties": {},
|
|
"type": "object"
|
|
},
|
|
"message": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"required": [
|
|
"code",
|
|
"details",
|
|
"message"
|
|
],
|
|
"type": "object"
|
|
},
|
|
"cabana.ErrorEnvelope": {
|
|
"properties": {
|
|
"error": {
|
|
"$ref": "#/components/schemas/cabana.ErrorBody"
|
|
}
|
|
},
|
|
"required": [
|
|
"error"
|
|
],
|
|
"type": "object"
|
|
},
|
|
"cabana.FormMeta": {
|
|
"properties": {
|
|
"locale": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"required": [
|
|
"locale"
|
|
],
|
|
"type": "object"
|
|
},
|
|
"cabana.FormOption": {
|
|
"properties": {
|
|
"label": {
|
|
"type": "string"
|
|
},
|
|
"value": {
|
|
"$ref": "#/components/schemas/cabana.jsonScalar"
|
|
}
|
|
},
|
|
"required": [
|
|
"label",
|
|
"value"
|
|
],
|
|
"type": "object"
|
|
},
|
|
"cabana.ListColumn": {
|
|
"properties": {
|
|
"key": {
|
|
"type": "string"
|
|
},
|
|
"label": {
|
|
"type": "string"
|
|
},
|
|
"relation": {
|
|
"type": "string"
|
|
},
|
|
"searchable": {
|
|
"type": "boolean"
|
|
},
|
|
"select": {
|
|
"type": "string"
|
|
},
|
|
"sortable": {
|
|
"type": "boolean"
|
|
},
|
|
"type": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"required": [
|
|
"key",
|
|
"label",
|
|
"searchable",
|
|
"sortable"
|
|
],
|
|
"type": "object"
|
|
},
|
|
"cabana.ListEnvelope-array_cabana_AdminRecord": {
|
|
"properties": {
|
|
"data": {
|
|
"items": {
|
|
"additionalProperties": {},
|
|
"type": "object"
|
|
},
|
|
"type": "array"
|
|
},
|
|
"meta": {
|
|
"$ref": "#/components/schemas/cabana.ListMeta"
|
|
}
|
|
},
|
|
"required": [
|
|
"data",
|
|
"meta"
|
|
],
|
|
"type": "object"
|
|
},
|
|
"cabana.ListEnvelope-array_cabana_RelationOption": {
|
|
"properties": {
|
|
"data": {
|
|
"items": {
|
|
"$ref": "#/components/schemas/cabana.RelationOption"
|
|
},
|
|
"type": "array"
|
|
},
|
|
"meta": {
|
|
"$ref": "#/components/schemas/cabana.ListMeta"
|
|
}
|
|
},
|
|
"required": [
|
|
"data",
|
|
"meta"
|
|
],
|
|
"type": "object"
|
|
},
|
|
"cabana.ListFilter": {
|
|
"properties": {
|
|
"column": {
|
|
"type": "string"
|
|
},
|
|
"falseValue": {
|
|
"$ref": "#/components/schemas/cabana.jsonScalar"
|
|
},
|
|
"label": {
|
|
"type": "string"
|
|
},
|
|
"modelClass": {
|
|
"type": "string"
|
|
},
|
|
"name": {
|
|
"type": "string"
|
|
},
|
|
"nameFrom": {
|
|
"type": "string"
|
|
},
|
|
"options": {
|
|
"items": {
|
|
"$ref": "#/components/schemas/cabana.FormOption"
|
|
},
|
|
"type": "array"
|
|
},
|
|
"scope": {
|
|
"type": "string"
|
|
},
|
|
"trueValue": {
|
|
"$ref": "#/components/schemas/cabana.jsonScalar"
|
|
},
|
|
"type": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"required": [
|
|
"name",
|
|
"type"
|
|
],
|
|
"type": "object"
|
|
},
|
|
"cabana.ListMeta": {
|
|
"properties": {
|
|
"last_page": {
|
|
"type": "integer"
|
|
},
|
|
"page": {
|
|
"type": "integer"
|
|
},
|
|
"per_page": {
|
|
"type": "integer"
|
|
},
|
|
"total": {
|
|
"type": "integer"
|
|
}
|
|
},
|
|
"required": [
|
|
"last_page",
|
|
"page",
|
|
"per_page",
|
|
"total"
|
|
],
|
|
"type": "object"
|
|
},
|
|
"cabana.ListSchema": {
|
|
"properties": {
|
|
"bulkActions": {
|
|
"items": {
|
|
"$ref": "#/components/schemas/cabana.BulkAction"
|
|
},
|
|
"type": "array"
|
|
},
|
|
"columns": {
|
|
"items": {
|
|
"$ref": "#/components/schemas/cabana.ListColumn"
|
|
},
|
|
"type": "array"
|
|
},
|
|
"defaultSort": {
|
|
"$ref": "#/components/schemas/cabana.ListSort"
|
|
},
|
|
"filters": {
|
|
"items": {
|
|
"$ref": "#/components/schemas/cabana.ListFilter"
|
|
},
|
|
"type": "array"
|
|
},
|
|
"meta": {
|
|
"$ref": "#/components/schemas/cabana.FormMeta"
|
|
},
|
|
"modelClass": {
|
|
"type": "string"
|
|
},
|
|
"noRecordsMessage": {
|
|
"type": "string"
|
|
},
|
|
"perPageOptions": {
|
|
"items": {
|
|
"type": "integer"
|
|
},
|
|
"type": "array"
|
|
},
|
|
"recordUrl": {
|
|
"type": "string"
|
|
},
|
|
"recordsPerPage": {
|
|
"type": "integer"
|
|
},
|
|
"rowActions": {
|
|
"items": {
|
|
"$ref": "#/components/schemas/cabana.RowAction"
|
|
},
|
|
"type": "array"
|
|
},
|
|
"searchPrompt": {
|
|
"type": "string"
|
|
},
|
|
"searchTerm": {
|
|
"type": "string"
|
|
},
|
|
"showCheckboxes": {
|
|
"type": "boolean"
|
|
},
|
|
"showSearch": {
|
|
"type": "boolean"
|
|
},
|
|
"showSetup": {
|
|
"type": "boolean"
|
|
},
|
|
"showSorting": {
|
|
"type": "boolean"
|
|
},
|
|
"title": {
|
|
"type": "string"
|
|
},
|
|
"toolbarButtons": {
|
|
"items": {
|
|
"type": "string"
|
|
},
|
|
"type": "array"
|
|
}
|
|
},
|
|
"required": [
|
|
"bulkActions",
|
|
"columns",
|
|
"filters",
|
|
"perPageOptions",
|
|
"recordsPerPage",
|
|
"rowActions",
|
|
"searchTerm",
|
|
"showCheckboxes",
|
|
"showSearch",
|
|
"showSetup",
|
|
"showSorting",
|
|
"toolbarButtons"
|
|
],
|
|
"type": "object"
|
|
},
|
|
"cabana.ListSort": {
|
|
"properties": {
|
|
"column": {
|
|
"type": "string"
|
|
},
|
|
"direction": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"required": [
|
|
"column",
|
|
"direction"
|
|
],
|
|
"type": "object"
|
|
},
|
|
"cabana.NavigationEntry": {
|
|
"properties": {
|
|
"code": {
|
|
"type": "string"
|
|
},
|
|
"controller": {
|
|
"type": "string"
|
|
},
|
|
"icon": {
|
|
"type": "string"
|
|
},
|
|
"label": {
|
|
"type": "string"
|
|
},
|
|
"order": {
|
|
"type": "integer"
|
|
},
|
|
"sideMenu": {
|
|
"items": {
|
|
"$ref": "#/components/schemas/cabana.NavigationEntry"
|
|
},
|
|
"type": "array"
|
|
}
|
|
},
|
|
"required": [
|
|
"code",
|
|
"controller",
|
|
"icon",
|
|
"label",
|
|
"order",
|
|
"sideMenu"
|
|
],
|
|
"type": "object"
|
|
},
|
|
"cabana.RecordEnvelope": {
|
|
"properties": {
|
|
"data": {
|
|
"$ref": "#/components/schemas/cabana.AdminRecord"
|
|
},
|
|
"meta": {
|
|
"$ref": "#/components/schemas/cabana.RecordMeta"
|
|
}
|
|
},
|
|
"required": [
|
|
"data",
|
|
"meta"
|
|
],
|
|
"type": "object"
|
|
},
|
|
"cabana.RecordMeta": {
|
|
"properties": {
|
|
"labels": {
|
|
"additionalProperties": {
|
|
"items": {
|
|
"$ref": "#/components/schemas/cabana.RelationOption"
|
|
},
|
|
"type": "array"
|
|
},
|
|
"type": "object"
|
|
}
|
|
},
|
|
"required": [
|
|
"labels"
|
|
],
|
|
"type": "object"
|
|
},
|
|
"cabana.RelationOption": {
|
|
"properties": {
|
|
"label": {
|
|
"type": "string"
|
|
},
|
|
"value": {
|
|
"type": "integer"
|
|
}
|
|
},
|
|
"required": [
|
|
"label",
|
|
"value"
|
|
],
|
|
"type": "object"
|
|
},
|
|
"cabana.RowAction": {
|
|
"properties": {
|
|
"label": {
|
|
"type": "string"
|
|
},
|
|
"name": {
|
|
"type": "string"
|
|
},
|
|
"url": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
"required": [
|
|
"name"
|
|
],
|
|
"type": "object"
|
|
},
|
|
"cabana.SuccessEnvelope": {
|
|
"properties": {
|
|
"data": {},
|
|
"meta": {
|
|
"$ref": "#/components/schemas/cabana.SuccessMeta"
|
|
}
|
|
},
|
|
"required": [
|
|
"data",
|
|
"meta"
|
|
],
|
|
"type": "object"
|
|
},
|
|
"cabana.SuccessMeta": {
|
|
"properties": {
|
|
"last_page": {
|
|
"type": "integer"
|
|
},
|
|
"locale": {
|
|
"type": "string"
|
|
},
|
|
"page": {
|
|
"type": "integer"
|
|
},
|
|
"per_page": {
|
|
"type": "integer"
|
|
},
|
|
"total": {
|
|
"type": "integer"
|
|
}
|
|
},
|
|
"type": "object"
|
|
},
|
|
"cabana.jsonScalar": {
|
|
"nullable": true,
|
|
"oneOf": [
|
|
{
|
|
"type": "string"
|
|
},
|
|
{
|
|
"type": "number"
|
|
},
|
|
{
|
|
"type": "boolean"
|
|
}
|
|
]
|
|
}
|
|
},
|
|
"securitySchemes": {
|
|
"BackendBearer": {
|
|
"description": "Backend admin bearer token. Send \"Bearer {access_token}\".",
|
|
"in": "header",
|
|
"name": "Authorization",
|
|
"type": "apiKey"
|
|
}
|
|
}
|
|
},
|
|
"info": {
|
|
"contact": {},
|
|
"description": "Framework admin API consumed by the embedded admin SPA. Every path is relative to {backend.uri}/api/v1 (for example /backend/api/v1). The SPA authenticates with the HttpOnly summer_admin cookie set by a login that sends X-Requested-With: XMLHttpRequest, and sends that header on every request; CLI clients and tests send the BackendBearer Authorization header instead.",
|
|
"title": "SummerCMS Admin API",
|
|
"version": "1"
|
|
},
|
|
"openapi": "3.0.3",
|
|
"paths": {
|
|
"/auth/login": {
|
|
"post": {
|
|
"parameters": [
|
|
{
|
|
"description": "XMLHttpRequest selects cookie transport",
|
|
"in": "header",
|
|
"name": "X-Requested-With",
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"requestBody": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.AdminLoginRequest"
|
|
}
|
|
}
|
|
},
|
|
"description": "Credentials",
|
|
"required": true
|
|
},
|
|
"responses": {
|
|
"200": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.Envelope-cabana_AdminLoginData"
|
|
}
|
|
}
|
|
},
|
|
"description": "OK"
|
|
},
|
|
"401": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Unauthorized"
|
|
}
|
|
},
|
|
"summary": "Admin login",
|
|
"tags": [
|
|
"admin"
|
|
]
|
|
}
|
|
},
|
|
"/auth/logout": {
|
|
"post": {
|
|
"responses": {
|
|
"200": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.SuccessEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "OK"
|
|
},
|
|
"401": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Unauthorized"
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"BackendBearer": []
|
|
}
|
|
],
|
|
"summary": "Admin logout",
|
|
"tags": [
|
|
"admin"
|
|
]
|
|
}
|
|
},
|
|
"/auth/me": {
|
|
"get": {
|
|
"responses": {
|
|
"200": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.Envelope-cabana_AdminProfile"
|
|
}
|
|
}
|
|
},
|
|
"description": "OK"
|
|
},
|
|
"401": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Unauthorized"
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"BackendBearer": []
|
|
}
|
|
],
|
|
"summary": "Current admin",
|
|
"tags": [
|
|
"admin"
|
|
]
|
|
}
|
|
},
|
|
"/auth/refresh": {
|
|
"post": {
|
|
"parameters": [
|
|
{
|
|
"description": "XMLHttpRequest; required unless a Bearer token is sent",
|
|
"in": "header",
|
|
"name": "X-Requested-With",
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.Envelope-cabana_AdminLoginData"
|
|
}
|
|
}
|
|
},
|
|
"description": "OK"
|
|
},
|
|
"401": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Unauthorized"
|
|
},
|
|
"403": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Forbidden"
|
|
}
|
|
},
|
|
"summary": "Refresh an admin token",
|
|
"tags": [
|
|
"admin"
|
|
]
|
|
}
|
|
},
|
|
"/navigation": {
|
|
"get": {
|
|
"responses": {
|
|
"200": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.Envelope-array_cabana_NavigationEntry"
|
|
}
|
|
}
|
|
},
|
|
"description": "OK"
|
|
},
|
|
"401": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Unauthorized"
|
|
},
|
|
"403": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Forbidden"
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"BackendBearer": []
|
|
}
|
|
],
|
|
"summary": "Admin navigation",
|
|
"tags": [
|
|
"admin"
|
|
]
|
|
}
|
|
},
|
|
"/settings": {
|
|
"get": {
|
|
"responses": {
|
|
"200": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.SuccessEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "OK"
|
|
},
|
|
"401": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Unauthorized"
|
|
},
|
|
"403": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Forbidden"
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"BackendBearer": []
|
|
}
|
|
],
|
|
"summary": "List admin settings",
|
|
"tags": [
|
|
"admin"
|
|
]
|
|
}
|
|
},
|
|
"/settings/{code}": {
|
|
"get": {
|
|
"parameters": [
|
|
{
|
|
"description": "Settings code",
|
|
"in": "path",
|
|
"name": "code",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.SuccessEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "OK"
|
|
},
|
|
"401": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Unauthorized"
|
|
},
|
|
"403": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Forbidden"
|
|
},
|
|
"404": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Not Found"
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"BackendBearer": []
|
|
}
|
|
],
|
|
"summary": "Read admin settings",
|
|
"tags": [
|
|
"admin"
|
|
]
|
|
},
|
|
"put": {
|
|
"parameters": [
|
|
{
|
|
"description": "Settings code",
|
|
"in": "path",
|
|
"name": "code",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.SuccessEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "OK"
|
|
},
|
|
"401": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Unauthorized"
|
|
},
|
|
"403": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Forbidden"
|
|
},
|
|
"422": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Unprocessable Entity"
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"BackendBearer": []
|
|
}
|
|
],
|
|
"summary": "Update admin settings",
|
|
"tags": [
|
|
"admin"
|
|
]
|
|
}
|
|
},
|
|
"/settings/{code}/schema": {
|
|
"get": {
|
|
"parameters": [
|
|
{
|
|
"description": "Settings code",
|
|
"in": "path",
|
|
"name": "code",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.SuccessEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "OK"
|
|
},
|
|
"401": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Unauthorized"
|
|
},
|
|
"403": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Forbidden"
|
|
},
|
|
"404": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Not Found"
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"BackendBearer": []
|
|
}
|
|
],
|
|
"summary": "Admin settings schema",
|
|
"tags": [
|
|
"admin"
|
|
]
|
|
}
|
|
},
|
|
"/{vendor}/{plugin}/{controller}": {
|
|
"get": {
|
|
"parameters": [
|
|
{
|
|
"description": "Vendor",
|
|
"in": "path",
|
|
"name": "vendor",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Plugin",
|
|
"in": "path",
|
|
"name": "plugin",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Controller",
|
|
"in": "path",
|
|
"name": "controller",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Search term",
|
|
"in": "query",
|
|
"name": "search",
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Sort column",
|
|
"in": "query",
|
|
"name": "sort",
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Sort direction (asc or desc)",
|
|
"in": "query",
|
|
"name": "dir",
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Page",
|
|
"in": "query",
|
|
"name": "page",
|
|
"schema": {
|
|
"type": "integer"
|
|
}
|
|
},
|
|
{
|
|
"description": "Records per page",
|
|
"in": "query",
|
|
"name": "per_page",
|
|
"schema": {
|
|
"type": "integer"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ListEnvelope-array_cabana_AdminRecord"
|
|
}
|
|
}
|
|
},
|
|
"description": "OK"
|
|
},
|
|
"401": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Unauthorized"
|
|
},
|
|
"403": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Forbidden"
|
|
},
|
|
"422": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Unprocessable Entity"
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"BackendBearer": []
|
|
}
|
|
],
|
|
"summary": "List admin records",
|
|
"tags": [
|
|
"admin"
|
|
]
|
|
},
|
|
"post": {
|
|
"description": "Relation fields are sent by field name with ids ({\"genre\": 3, \"artists\": [4, 9]}); the response carries the same shape plus meta.labels.",
|
|
"parameters": [
|
|
{
|
|
"description": "Vendor",
|
|
"in": "path",
|
|
"name": "vendor",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Plugin",
|
|
"in": "path",
|
|
"name": "plugin",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Controller",
|
|
"in": "path",
|
|
"name": "controller",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"201": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.RecordEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Created"
|
|
},
|
|
"401": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Unauthorized"
|
|
},
|
|
"403": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Forbidden"
|
|
},
|
|
"422": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Unprocessable Entity"
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"BackendBearer": []
|
|
}
|
|
],
|
|
"summary": "Create an admin record",
|
|
"tags": [
|
|
"admin"
|
|
]
|
|
}
|
|
},
|
|
"/{vendor}/{plugin}/{controller}/bulk-delete": {
|
|
"post": {
|
|
"parameters": [
|
|
{
|
|
"description": "Vendor",
|
|
"in": "path",
|
|
"name": "vendor",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Plugin",
|
|
"in": "path",
|
|
"name": "plugin",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Controller",
|
|
"in": "path",
|
|
"name": "controller",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.SuccessEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "OK"
|
|
},
|
|
"401": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Unauthorized"
|
|
},
|
|
"403": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Forbidden"
|
|
},
|
|
"422": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Unprocessable Entity"
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"BackendBearer": []
|
|
}
|
|
],
|
|
"summary": "Bulk-delete admin records",
|
|
"tags": [
|
|
"admin"
|
|
]
|
|
}
|
|
},
|
|
"/{vendor}/{plugin}/{controller}/fields/{field}/options": {
|
|
"get": {
|
|
"description": "Choices for a writable `type: relation` field: value is the related id, label its nameFrom column. Read-only and non-relation fields answer 404.",
|
|
"parameters": [
|
|
{
|
|
"description": "Vendor",
|
|
"in": "path",
|
|
"name": "vendor",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Plugin",
|
|
"in": "path",
|
|
"name": "plugin",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Controller",
|
|
"in": "path",
|
|
"name": "controller",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Relation field name",
|
|
"in": "path",
|
|
"name": "field",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Case-insensitive label search",
|
|
"in": "query",
|
|
"name": "search",
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Page",
|
|
"in": "query",
|
|
"name": "page",
|
|
"schema": {
|
|
"type": "integer"
|
|
}
|
|
},
|
|
{
|
|
"description": "Options per page (1-100, default 20)",
|
|
"in": "query",
|
|
"name": "per_page",
|
|
"schema": {
|
|
"type": "integer"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ListEnvelope-array_cabana_RelationOption"
|
|
}
|
|
}
|
|
},
|
|
"description": "OK"
|
|
},
|
|
"401": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Unauthorized"
|
|
},
|
|
"403": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Forbidden"
|
|
},
|
|
"404": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Not Found"
|
|
},
|
|
"422": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Unprocessable Entity"
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"BackendBearer": []
|
|
}
|
|
],
|
|
"summary": "Relation field options",
|
|
"tags": [
|
|
"admin"
|
|
]
|
|
}
|
|
},
|
|
"/{vendor}/{plugin}/{controller}/schema/form": {
|
|
"get": {
|
|
"parameters": [
|
|
{
|
|
"description": "Vendor",
|
|
"in": "path",
|
|
"name": "vendor",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Plugin",
|
|
"in": "path",
|
|
"name": "plugin",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Controller",
|
|
"in": "path",
|
|
"name": "controller",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.SuccessEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "OK"
|
|
},
|
|
"401": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Unauthorized"
|
|
},
|
|
"403": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Forbidden"
|
|
},
|
|
"404": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Not Found"
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"BackendBearer": []
|
|
}
|
|
],
|
|
"summary": "Admin form schema",
|
|
"tags": [
|
|
"admin"
|
|
]
|
|
}
|
|
},
|
|
"/{vendor}/{plugin}/{controller}/schema/list": {
|
|
"get": {
|
|
"parameters": [
|
|
{
|
|
"description": "Vendor",
|
|
"in": "path",
|
|
"name": "vendor",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Plugin",
|
|
"in": "path",
|
|
"name": "plugin",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Controller",
|
|
"in": "path",
|
|
"name": "controller",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.Envelope-cabana_ListSchema"
|
|
}
|
|
}
|
|
},
|
|
"description": "OK"
|
|
},
|
|
"401": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Unauthorized"
|
|
},
|
|
"403": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Forbidden"
|
|
},
|
|
"404": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Not Found"
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"BackendBearer": []
|
|
}
|
|
],
|
|
"summary": "Admin list schema",
|
|
"tags": [
|
|
"admin"
|
|
]
|
|
}
|
|
},
|
|
"/{vendor}/{plugin}/{controller}/schema/relation/{name}": {
|
|
"get": {
|
|
"parameters": [
|
|
{
|
|
"description": "Vendor",
|
|
"in": "path",
|
|
"name": "vendor",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Plugin",
|
|
"in": "path",
|
|
"name": "plugin",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Controller",
|
|
"in": "path",
|
|
"name": "controller",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Relation name",
|
|
"in": "path",
|
|
"name": "name",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.SuccessEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "OK"
|
|
},
|
|
"401": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Unauthorized"
|
|
},
|
|
"403": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Forbidden"
|
|
},
|
|
"404": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Not Found"
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"BackendBearer": []
|
|
}
|
|
],
|
|
"summary": "Admin relation schema",
|
|
"tags": [
|
|
"admin"
|
|
]
|
|
}
|
|
},
|
|
"/{vendor}/{plugin}/{controller}/{id}": {
|
|
"delete": {
|
|
"parameters": [
|
|
{
|
|
"description": "Vendor",
|
|
"in": "path",
|
|
"name": "vendor",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Plugin",
|
|
"in": "path",
|
|
"name": "plugin",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Controller",
|
|
"in": "path",
|
|
"name": "controller",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Record id",
|
|
"in": "path",
|
|
"name": "id",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "integer"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.SuccessEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "OK"
|
|
},
|
|
"401": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Unauthorized"
|
|
},
|
|
"403": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Forbidden"
|
|
},
|
|
"404": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Not Found"
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"BackendBearer": []
|
|
}
|
|
],
|
|
"summary": "Delete an admin record",
|
|
"tags": [
|
|
"admin"
|
|
]
|
|
},
|
|
"get": {
|
|
"parameters": [
|
|
{
|
|
"description": "Vendor",
|
|
"in": "path",
|
|
"name": "vendor",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Plugin",
|
|
"in": "path",
|
|
"name": "plugin",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Controller",
|
|
"in": "path",
|
|
"name": "controller",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Record id",
|
|
"in": "path",
|
|
"name": "id",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "integer"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.RecordEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "OK"
|
|
},
|
|
"401": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Unauthorized"
|
|
},
|
|
"403": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Forbidden"
|
|
},
|
|
"404": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Not Found"
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"BackendBearer": []
|
|
}
|
|
],
|
|
"summary": "Show an admin record",
|
|
"tags": [
|
|
"admin"
|
|
]
|
|
},
|
|
"put": {
|
|
"parameters": [
|
|
{
|
|
"description": "Vendor",
|
|
"in": "path",
|
|
"name": "vendor",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Plugin",
|
|
"in": "path",
|
|
"name": "plugin",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Controller",
|
|
"in": "path",
|
|
"name": "controller",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Record id",
|
|
"in": "path",
|
|
"name": "id",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "integer"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.RecordEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "OK"
|
|
},
|
|
"401": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Unauthorized"
|
|
},
|
|
"403": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Forbidden"
|
|
},
|
|
"404": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Not Found"
|
|
},
|
|
"422": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Unprocessable Entity"
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"BackendBearer": []
|
|
}
|
|
],
|
|
"summary": "Update an admin record",
|
|
"tags": [
|
|
"admin"
|
|
]
|
|
}
|
|
},
|
|
"/{vendor}/{plugin}/{controller}/{id}/relations/{name}": {
|
|
"get": {
|
|
"parameters": [
|
|
{
|
|
"description": "Vendor",
|
|
"in": "path",
|
|
"name": "vendor",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Plugin",
|
|
"in": "path",
|
|
"name": "plugin",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Controller",
|
|
"in": "path",
|
|
"name": "controller",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Owner id",
|
|
"in": "path",
|
|
"name": "id",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "integer"
|
|
}
|
|
},
|
|
{
|
|
"description": "Relation name",
|
|
"in": "path",
|
|
"name": "name",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.SuccessEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "OK"
|
|
},
|
|
"401": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Unauthorized"
|
|
},
|
|
"403": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Forbidden"
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"BackendBearer": []
|
|
}
|
|
],
|
|
"summary": "List linked relation records",
|
|
"tags": [
|
|
"admin"
|
|
]
|
|
}
|
|
},
|
|
"/{vendor}/{plugin}/{controller}/{id}/relations/{name}/candidates": {
|
|
"get": {
|
|
"parameters": [
|
|
{
|
|
"description": "Vendor",
|
|
"in": "path",
|
|
"name": "vendor",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Plugin",
|
|
"in": "path",
|
|
"name": "plugin",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Controller",
|
|
"in": "path",
|
|
"name": "controller",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Owner id",
|
|
"in": "path",
|
|
"name": "id",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "integer"
|
|
}
|
|
},
|
|
{
|
|
"description": "Relation name",
|
|
"in": "path",
|
|
"name": "name",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.SuccessEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "OK"
|
|
},
|
|
"401": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Unauthorized"
|
|
},
|
|
"403": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Forbidden"
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"BackendBearer": []
|
|
}
|
|
],
|
|
"summary": "List relation candidates",
|
|
"tags": [
|
|
"admin"
|
|
]
|
|
}
|
|
},
|
|
"/{vendor}/{plugin}/{controller}/{id}/relations/{name}/link": {
|
|
"post": {
|
|
"parameters": [
|
|
{
|
|
"description": "Vendor",
|
|
"in": "path",
|
|
"name": "vendor",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Plugin",
|
|
"in": "path",
|
|
"name": "plugin",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Controller",
|
|
"in": "path",
|
|
"name": "controller",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Owner id",
|
|
"in": "path",
|
|
"name": "id",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "integer"
|
|
}
|
|
},
|
|
{
|
|
"description": "Relation name",
|
|
"in": "path",
|
|
"name": "name",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.SuccessEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "OK"
|
|
},
|
|
"401": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Unauthorized"
|
|
},
|
|
"403": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Forbidden"
|
|
},
|
|
"422": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Unprocessable Entity"
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"BackendBearer": []
|
|
}
|
|
],
|
|
"summary": "Link relation records",
|
|
"tags": [
|
|
"admin"
|
|
]
|
|
}
|
|
},
|
|
"/{vendor}/{plugin}/{controller}/{id}/relations/{name}/unlink": {
|
|
"post": {
|
|
"parameters": [
|
|
{
|
|
"description": "Vendor",
|
|
"in": "path",
|
|
"name": "vendor",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Plugin",
|
|
"in": "path",
|
|
"name": "plugin",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Controller",
|
|
"in": "path",
|
|
"name": "controller",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
},
|
|
{
|
|
"description": "Owner id",
|
|
"in": "path",
|
|
"name": "id",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "integer"
|
|
}
|
|
},
|
|
{
|
|
"description": "Relation name",
|
|
"in": "path",
|
|
"name": "name",
|
|
"required": true,
|
|
"schema": {
|
|
"type": "string"
|
|
}
|
|
}
|
|
],
|
|
"responses": {
|
|
"200": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.SuccessEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "OK"
|
|
},
|
|
"401": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Unauthorized"
|
|
},
|
|
"403": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Forbidden"
|
|
},
|
|
"422": {
|
|
"content": {
|
|
"application/json": {
|
|
"schema": {
|
|
"$ref": "#/components/schemas/cabana.ErrorEnvelope"
|
|
}
|
|
}
|
|
},
|
|
"description": "Unprocessable Entity"
|
|
}
|
|
},
|
|
"security": [
|
|
{
|
|
"BackendBearer": []
|
|
}
|
|
],
|
|
"summary": "Unlink relation records",
|
|
"tags": [
|
|
"admin"
|
|
]
|
|
}
|
|
}
|
|
}
|
|
}
|