initial cut at admin api operations (#537)

This commit is contained in:
Michael Quigley
2024-12-09 12:56:57 -05:00
parent 842f3e8c20
commit 38b32d15d0
49 changed files with 6649 additions and 0 deletions

View File

@ -831,6 +831,210 @@ func init() {
}
}
},
"/organization": {
"post": {
"security": [
{
"key": []
}
],
"tags": [
"admin"
],
"operationId": "createOrganization",
"parameters": [
{
"name": "body",
"in": "body",
"schema": {
"properties": {
"description": {
"type": "string"
}
}
}
}
],
"responses": {
"201": {
"description": "organization created",
"schema": {
"properties": {
"token": {
"type": "string"
}
}
}
},
"401": {
"description": "unauthorized"
},
"500": {
"description": "internal server error"
}
}
},
"delete": {
"security": [
{
"key": []
}
],
"tags": [
"admin"
],
"operationId": "deleteOrganization",
"parameters": [
{
"name": "body",
"in": "body",
"schema": {
"properties": {
"token": {
"type": "string"
}
}
}
}
],
"responses": {
"200": {
"description": "organization deleted"
},
"401": {
"description": "unauthorized"
},
"500": {
"description": "internal server error"
}
}
}
},
"/organization/add": {
"post": {
"security": [
{
"key": []
}
],
"tags": [
"admin"
],
"operationId": "addOrganizationMember",
"parameters": [
{
"name": "body",
"in": "body",
"schema": {
"properties": {
"email": {
"type": "string"
}
}
}
}
],
"responses": {
"201": {
"description": "member added"
},
"401": {
"description": "unauthorized"
},
"500": {
"description": "internal server error"
}
}
}
},
"/organization/members": {
"post": {
"security": [
{
"key": []
}
],
"tags": [
"admin"
],
"operationId": "listOrganizationMembers",
"parameters": [
{
"name": "body",
"in": "body",
"schema": {
"properties": {
"token": {
"type": "string"
}
}
}
}
],
"responses": {
"200": {
"description": "list organization members",
"schema": {
"properties": {
"members": {
"type": "array",
"items": {
"properties": {
"email": {
"type": "string"
}
}
}
}
}
}
},
"401": {
"description": "unauthorized"
},
"500": {
"description": "internal server error"
}
}
}
},
"/organization/remove": {
"post": {
"security": [
{
"key": []
}
],
"tags": [
"admin"
],
"operationId": "removeOrganizationMember",
"parameters": [
{
"name": "body",
"in": "body",
"schema": {
"properties": {
"email": {
"type": "string"
}
}
}
}
],
"responses": {
"200": {
"description": "member removed"
},
"401": {
"description": "unauthorized"
},
"500": {
"description": "internal server error"
}
}
}
},
"/overview": {
"get": {
"security": [
@ -2681,6 +2885,206 @@ func init() {
}
}
},
"/organization": {
"post": {
"security": [
{
"key": []
}
],
"tags": [
"admin"
],
"operationId": "createOrganization",
"parameters": [
{
"name": "body",
"in": "body",
"schema": {
"properties": {
"description": {
"type": "string"
}
}
}
}
],
"responses": {
"201": {
"description": "organization created",
"schema": {
"properties": {
"token": {
"type": "string"
}
}
}
},
"401": {
"description": "unauthorized"
},
"500": {
"description": "internal server error"
}
}
},
"delete": {
"security": [
{
"key": []
}
],
"tags": [
"admin"
],
"operationId": "deleteOrganization",
"parameters": [
{
"name": "body",
"in": "body",
"schema": {
"properties": {
"token": {
"type": "string"
}
}
}
}
],
"responses": {
"200": {
"description": "organization deleted"
},
"401": {
"description": "unauthorized"
},
"500": {
"description": "internal server error"
}
}
}
},
"/organization/add": {
"post": {
"security": [
{
"key": []
}
],
"tags": [
"admin"
],
"operationId": "addOrganizationMember",
"parameters": [
{
"name": "body",
"in": "body",
"schema": {
"properties": {
"email": {
"type": "string"
}
}
}
}
],
"responses": {
"201": {
"description": "member added"
},
"401": {
"description": "unauthorized"
},
"500": {
"description": "internal server error"
}
}
}
},
"/organization/members": {
"post": {
"security": [
{
"key": []
}
],
"tags": [
"admin"
],
"operationId": "listOrganizationMembers",
"parameters": [
{
"name": "body",
"in": "body",
"schema": {
"properties": {
"token": {
"type": "string"
}
}
}
}
],
"responses": {
"200": {
"description": "list organization members",
"schema": {
"properties": {
"members": {
"type": "array",
"items": {
"$ref": "#/definitions/MembersItems0"
}
}
}
}
},
"401": {
"description": "unauthorized"
},
"500": {
"description": "internal server error"
}
}
}
},
"/organization/remove": {
"post": {
"security": [
{
"key": []
}
],
"tags": [
"admin"
],
"operationId": "removeOrganizationMember",
"parameters": [
{
"name": "body",
"in": "body",
"schema": {
"properties": {
"email": {
"type": "string"
}
}
}
}
],
"responses": {
"200": {
"description": "member removed"
},
"401": {
"description": "unauthorized"
},
"500": {
"description": "internal server error"
}
}
}
},
"/overview": {
"get": {
"security": [
@ -3064,6 +3468,13 @@ func init() {
}
},
"definitions": {
"MembersItems0": {
"properties": {
"email": {
"type": "string"
}
}
},
"accessRequest": {
"type": "object",
"properties": {