Account API handler for CRDL operations (#228)
This commit is contained in:
1 parent
2ca7e0b88e
commit
e5ec1f48b2
22 files changed
+3777
-91
No files matched your search
@@ -72,6 +72,171 @@
|
||||
]
|
||||
}
|
||||
},
|
||||
"/v1/scopes/*/auth-methods/{auth_method_id}/accounts": {
|
||||
"get": {
|
||||
"summary": "Lists all accounts in a specific auth method.",
|
||||
"operationId": "AccountService_ListAccounts",
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "A successful response.",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/controller.api.services.v1.ListAccountsResponse"
|
||||
}
|
||||
}
|
||||
},
|
||||
"parameters": [
|
||||
{
|
||||
"name": "auth_method_id",
|
||||
"in": "path",
|
||||
"required": true,
|
||||
"type": "string"
|
||||
},
|
||||
{
|
||||
"name": "view",
|
||||
"in": "query",
|
||||
"required": false,
|
||||
"type": "string"
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
"controller.api.services.v1.AccountService"
|
||||
]
|
||||
},
|
||||
"post": {
|
||||
"summary": "Creates a single account in the provided auth method.",
|
||||
"operationId": "AccountService_CreateAccount",
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/controller.api.resources.auth.v1.Account"
|
||||
}
|
||||
}
|
||||
},
|
||||
"parameters": [
|
||||
{
|
||||
"name": "auth_method_id",
|
||||
"in": "path",
|
||||
"required": true,
|
||||
"type": "string"
|
||||
},
|
||||
{
|
||||
"name": "body",
|
||||
"in": "body",
|
||||
"required": true,
|
||||
"schema": {
|
||||
"$ref": "#/definitions/controller.api.resources.auth.v1.Account"
|
||||
}
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
"controller.api.services.v1.AccountService"
|
||||
]
|
||||
}
|
||||
},
|
||||
"/v1/scopes/*/auth-methods/{auth_method_id}/accounts/{id}": {
|
||||
"get": {
|
||||
"summary": "Gets a single Account",
|
||||
"operationId": "AccountService_GetAccount",
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/controller.api.resources.auth.v1.Account"
|
||||
}
|
||||
}
|
||||
},
|
||||
"parameters": [
|
||||
{
|
||||
"name": "auth_method_id",
|
||||
"in": "path",
|
||||
"required": true,
|
||||
"type": "string"
|
||||
},
|
||||
{
|
||||
"name": "id",
|
||||
"in": "path",
|
||||
"required": true,
|
||||
"type": "string"
|
||||
},
|
||||
{
|
||||
"name": "view",
|
||||
"in": "query",
|
||||
"required": false,
|
||||
"type": "string"
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
"controller.api.services.v1.AccountService"
|
||||
]
|
||||
},
|
||||
"delete": {
|
||||
"summary": "Deletes an account.",
|
||||
"operationId": "AccountService_DeleteAccount",
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "A successful response.",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/controller.api.services.v1.DeleteAccountResponse"
|
||||
}
|
||||
}
|
||||
},
|
||||
"parameters": [
|
||||
{
|
||||
"name": "auth_method_id",
|
||||
"in": "path",
|
||||
"required": true,
|
||||
"type": "string"
|
||||
},
|
||||
{
|
||||
"name": "id",
|
||||
"in": "path",
|
||||
"required": true,
|
||||
"type": "string"
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
"controller.api.services.v1.AccountService"
|
||||
]
|
||||
},
|
||||
"patch": {
|
||||
"summary": "Updates an account.",
|
||||
"operationId": "AccountService_UpdateAccount",
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/controller.api.resources.auth.v1.Account"
|
||||
}
|
||||
}
|
||||
},
|
||||
"parameters": [
|
||||
{
|
||||
"name": "auth_method_id",
|
||||
"in": "path",
|
||||
"required": true,
|
||||
"type": "string"
|
||||
},
|
||||
{
|
||||
"name": "id",
|
||||
"in": "path",
|
||||
"required": true,
|
||||
"type": "string"
|
||||
},
|
||||
{
|
||||
"name": "body",
|
||||
"in": "body",
|
||||
"required": true,
|
||||
"schema": {
|
||||
"$ref": "#/definitions/controller.api.resources.auth.v1.Account"
|
||||
}
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
"controller.api.services.v1.AccountService"
|
||||
]
|
||||
}
|
||||
},
|
||||
"/v1/scopes/*/auth-methods/{auth_method_id}:authenticate": {
|
||||
"post": {
|
||||
"summary": "Authenticate a user to an scope and retrieve an authentication token.",
|
||||
@@ -1506,6 +1671,60 @@
|
||||
}
|
||||
},
|
||||
"definitions": {
|
||||
"controller.api.resources.auth.v1.Account": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"id": {
|
||||
"type": "string",
|
||||
"description": "The ID of the Account\nOutput only.",
|
||||
"readOnly": true
|
||||
},
|
||||
"scope": {
|
||||
"$ref": "#/definitions/controller.api.resources.scopes.v1.ScopeInfo",
|
||||
"description": "Scope information for this resource\nOutput only.",
|
||||
"readOnly": true
|
||||
},
|
||||
"auth_method_id": {
|
||||
"type": "string",
|
||||
"description": "The auth method this account is created for.\nOutput only.",
|
||||
"readOnly": true
|
||||
},
|
||||
"name": {
|
||||
"type": "string",
|
||||
"title": "Optional name for identification purposes"
|
||||
},
|
||||
"description": {
|
||||
"type": "string",
|
||||
"title": "Optional user-set descripton for identification purposes"
|
||||
},
|
||||
"created_time": {
|
||||
"type": "string",
|
||||
"format": "date-time",
|
||||
"description": "The time this resource was created\nOutput only.",
|
||||
"readOnly": true
|
||||
},
|
||||
"updated_time": {
|
||||
"type": "string",
|
||||
"format": "date-time",
|
||||
"description": "The time this resource was last updated.\nOutput only.",
|
||||
"readOnly": true
|
||||
},
|
||||
"disabled": {
|
||||
"type": "boolean",
|
||||
"format": "boolean",
|
||||
"title": "Whether the resource is disabled"
|
||||
},
|
||||
"type": {
|
||||
"type": "string",
|
||||
"description": "The type of this account. Possible values are: \"password\", \"oidc\"."
|
||||
},
|
||||
"attributes": {
|
||||
"type": "object",
|
||||
"description": "The attributes that are applicable for the specific Account type."
|
||||
}
|
||||
},
|
||||
"title": "Account contains all fields related to an auth Account resource"
|
||||
},
|
||||
"controller.api.resources.authtokens.v1.AuthToken": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
@@ -2168,6 +2387,17 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"controller.api.services.v1.CreateAccountResponse": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"uri": {
|
||||
"type": "string"
|
||||
},
|
||||
"item": {
|
||||
"$ref": "#/definitions/controller.api.resources.auth.v1.Account"
|
||||
}
|
||||
}
|
||||
},
|
||||
"controller.api.services.v1.CreateGroupResponse": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
@@ -2245,6 +2475,15 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"controller.api.services.v1.DeleteAccountResponse": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"existed": {
|
||||
"type": "boolean",
|
||||
"format": "boolean"
|
||||
}
|
||||
}
|
||||
},
|
||||
"controller.api.services.v1.DeleteAuthTokenResponse": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
@@ -2317,6 +2556,14 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"controller.api.services.v1.GetAccountResponse": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"item": {
|
||||
"$ref": "#/definitions/controller.api.resources.auth.v1.Account"
|
||||
}
|
||||
}
|
||||
},
|
||||
"controller.api.services.v1.GetAuthTokenResponse": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
@@ -2381,6 +2628,17 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"controller.api.services.v1.ListAccountsResponse": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"items": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/definitions/controller.api.resources.auth.v1.Account"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"controller.api.services.v1.ListAuthTokensResponse": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
@@ -2634,6 +2892,14 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"controller.api.services.v1.UpdateAccountResponse": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"item": {
|
||||
"$ref": "#/definitions/controller.api.resources.auth.v1.Account"
|
||||
}
|
||||
}
|
||||
},
|
||||
"controller.api.services.v1.UpdateGroupResponse": {
|
||||
"type": "object",
|
||||
"properties": {
|
||||
|
||||
Reference in new issue
Block a user