mirror of
https://github.com/casdoor/casdoor.git
synced 2025-07-03 12:30:19 +08:00
feat: add basic enforcer manager (#2130)
* feat: add basic enforcer manager * chore: generate swagger
This commit is contained in:
@ -155,6 +155,34 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"/api/add-enforcer": {
|
||||
"post": {
|
||||
"tags": [
|
||||
"Enforcer API"
|
||||
],
|
||||
"description": "add enforcer",
|
||||
"operationId": "ApiController.AddEnforcer",
|
||||
"parameters": [
|
||||
{
|
||||
"in": "body",
|
||||
"name": "enforcer",
|
||||
"description": "The enforcer object",
|
||||
"required": true,
|
||||
"schema": {
|
||||
"$ref": "#/definitions/object"
|
||||
}
|
||||
}
|
||||
],
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/object"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"/api/add-group": {
|
||||
"post": {
|
||||
"tags": [
|
||||
@ -1073,6 +1101,34 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"/api/delete-enforcer": {
|
||||
"post": {
|
||||
"tags": [
|
||||
"Enforcer API"
|
||||
],
|
||||
"description": "delete enforcer",
|
||||
"operationId": "ApiController.DeleteEnforcer",
|
||||
"parameters": [
|
||||
{
|
||||
"in": "body",
|
||||
"name": "body",
|
||||
"description": "The enforcer object",
|
||||
"required": true,
|
||||
"schema": {
|
||||
"$ref": "#/definitions/object.Enforce"
|
||||
}
|
||||
}
|
||||
],
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/object"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"/api/delete-group": {
|
||||
"post": {
|
||||
"tags": [
|
||||
@ -2018,6 +2074,61 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"/api/get-enforcer": {
|
||||
"get": {
|
||||
"tags": [
|
||||
"Enforcer API"
|
||||
],
|
||||
"description": "get enforcer",
|
||||
"operationId": "ApiController.GetEnforcer",
|
||||
"parameters": [
|
||||
{
|
||||
"in": "query",
|
||||
"name": "id",
|
||||
"description": "The id ( owner/name ) of enforcer",
|
||||
"required": true,
|
||||
"type": "string"
|
||||
}
|
||||
],
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/object"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"/api/get-enforcers": {
|
||||
"get": {
|
||||
"tags": [
|
||||
"Enforcer API"
|
||||
],
|
||||
"description": "get enforcers",
|
||||
"operationId": "ApiController.GetEnforcers",
|
||||
"parameters": [
|
||||
{
|
||||
"in": "query",
|
||||
"name": "owner",
|
||||
"description": "The owner of enforcers",
|
||||
"required": true,
|
||||
"type": "string"
|
||||
}
|
||||
],
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "",
|
||||
"schema": {
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/definitions/object.Enforcer"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"/api/get-global-providers": {
|
||||
"get": {
|
||||
"tags": [
|
||||
@ -4394,6 +4505,41 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"/api/update-enforcer": {
|
||||
"post": {
|
||||
"tags": [
|
||||
"Enforcer API"
|
||||
],
|
||||
"description": "update enforcer",
|
||||
"operationId": "ApiController.UpdateEnforcer",
|
||||
"parameters": [
|
||||
{
|
||||
"in": "query",
|
||||
"name": "id",
|
||||
"description": "The id ( owner/name ) of enforcer",
|
||||
"required": true,
|
||||
"type": "string"
|
||||
},
|
||||
{
|
||||
"in": "body",
|
||||
"name": "enforcer",
|
||||
"description": "The enforcer object",
|
||||
"required": true,
|
||||
"schema": {
|
||||
"$ref": "#/definitions/object"
|
||||
}
|
||||
}
|
||||
],
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/object"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"/api/update-group": {
|
||||
"post": {
|
||||
"tags": [
|
||||
@ -5273,6 +5419,14 @@
|
||||
}
|
||||
},
|
||||
"definitions": {
|
||||
"1225.0xc000333110.false": {
|
||||
"title": "false",
|
||||
"type": "object"
|
||||
},
|
||||
"1260.0xc000333140.false": {
|
||||
"title": "false",
|
||||
"type": "object"
|
||||
},
|
||||
"LaravelResponse": {
|
||||
"title": "LaravelResponse",
|
||||
"type": "object"
|
||||
@ -5289,6 +5443,10 @@
|
||||
"title": "Response",
|
||||
"type": "object"
|
||||
},
|
||||
"casbin.Enforcer": {
|
||||
"title": "Enforcer",
|
||||
"type": "object"
|
||||
},
|
||||
"controllers.AuthForm": {
|
||||
"title": "AuthForm",
|
||||
"type": "object"
|
||||
@ -5322,16 +5480,10 @@
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"data": {
|
||||
"additionalProperties": {
|
||||
"description": "support string, struct or []struct",
|
||||
"type": "string"
|
||||
}
|
||||
"$ref": "#/definitions/1225.0xc000333110.false"
|
||||
},
|
||||
"data2": {
|
||||
"additionalProperties": {
|
||||
"description": "support string, struct or []struct",
|
||||
"type": "string"
|
||||
}
|
||||
"$ref": "#/definitions/1260.0xc000333140.false"
|
||||
},
|
||||
"msg": {
|
||||
"type": "string"
|
||||
@ -5373,6 +5525,10 @@
|
||||
"title": "object",
|
||||
"type": "object"
|
||||
},
|
||||
"object.\u0026{197582 0xc000ace360 false}": {
|
||||
"title": "\u0026{197582 0xc000ace360 false}",
|
||||
"type": "object"
|
||||
},
|
||||
"object.AccountItem": {
|
||||
"title": "AccountItem",
|
||||
"type": "object",
|
||||
@ -5566,7 +5722,7 @@
|
||||
"title": "CasbinRequest",
|
||||
"type": "array",
|
||||
"items": {
|
||||
"$ref": "#/definitions/object.CasbinRequest"
|
||||
"$ref": "#/definitions/object.\u0026{197582 0xc000ace360 false}"
|
||||
}
|
||||
},
|
||||
"object.Cert": {
|
||||
@ -5662,6 +5818,43 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"object.Enforce": {
|
||||
"title": "Enforce",
|
||||
"type": "object"
|
||||
},
|
||||
"object.Enforcer": {
|
||||
"title": "Enforcer",
|
||||
"type": "object",
|
||||
"properties": {
|
||||
"adapter": {
|
||||
"type": "string"
|
||||
},
|
||||
"createdTime": {
|
||||
"type": "string"
|
||||
},
|
||||
"description": {
|
||||
"type": "string"
|
||||
},
|
||||
"displayName": {
|
||||
"type": "string"
|
||||
},
|
||||
"isEnabled": {
|
||||
"type": "boolean"
|
||||
},
|
||||
"model": {
|
||||
"type": "string"
|
||||
},
|
||||
"name": {
|
||||
"type": "string"
|
||||
},
|
||||
"owner": {
|
||||
"type": "string"
|
||||
},
|
||||
"updatedTime": {
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
},
|
||||
"object.GaugeVecInfo": {
|
||||
"title": "GaugeVecInfo",
|
||||
"type": "object",
|
||||
@ -7323,6 +7516,9 @@
|
||||
"meetup": {
|
||||
"type": "string"
|
||||
},
|
||||
"metamask": {
|
||||
"type": "string"
|
||||
},
|
||||
"mfaEmailEnabled": {
|
||||
"type": "boolean"
|
||||
},
|
||||
|
Reference in New Issue
Block a user