mirror of
https://github.com/strapi/strapi.git
synced 2025-12-24 05:34:33 +00:00
Continue documenting
This commit is contained in:
parent
573d56bc30
commit
aa01d844e0
@ -43,7 +43,7 @@
|
||||
"redux": "^4.0.1",
|
||||
"reselect": "^4.0.0",
|
||||
"swagger-ui-dist": "3.47.1",
|
||||
"yaml": "2.1.1"
|
||||
"yaml": "1.10.2"
|
||||
},
|
||||
"peerDependencies": {
|
||||
"@strapi/strapi": "^4.0.0"
|
||||
|
||||
@ -143,38 +143,148 @@ paths:
|
||||
ok:
|
||||
type: enum
|
||||
enum: [true]
|
||||
default:
|
||||
description: Error
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: '#/components/schemas/Error'
|
||||
/auth/reset-password:
|
||||
post:
|
||||
tags:
|
||||
- Users-Permissions - Auth
|
||||
summary: Rest user password
|
||||
requestBody:
|
||||
required: true
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
type: object
|
||||
properties:
|
||||
password:
|
||||
type: string
|
||||
passwordConfirmation:
|
||||
type: string
|
||||
code:
|
||||
type: string
|
||||
example:
|
||||
password: Test1234
|
||||
passwordConfirmation: Test1234
|
||||
code: zertyoaizndoianzodianzdonaizdoinaozdnia
|
||||
responses:
|
||||
200:
|
||||
description: Returns a jwt token and user info
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: '#/components/schemas/Users-Permissions-UserRegistration'
|
||||
default:
|
||||
description: 'Success'
|
||||
description: Error
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: '#/components/schemas/Error'
|
||||
|
||||
/auth/email-confirmation:
|
||||
get:
|
||||
tags:
|
||||
- Users-Permissions - Auth
|
||||
summary: Confirm user email
|
||||
parameters:
|
||||
- in: query
|
||||
name: confirmation
|
||||
type: string
|
||||
description: confirmation token received by email
|
||||
responses:
|
||||
301:
|
||||
description: Redirects to the configure email confirmation redirect url
|
||||
default:
|
||||
description: 'Success'
|
||||
description: Error
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: '#/components/schemas/Error'
|
||||
|
||||
/auth/send-email-confirmation:
|
||||
post:
|
||||
tags:
|
||||
- Users-Permissions - Auth
|
||||
summary: Send confirmation email
|
||||
requestBody:
|
||||
required: true
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
type: object
|
||||
properties:
|
||||
email:
|
||||
type: string
|
||||
responses:
|
||||
200:
|
||||
description: Returns email and boolean to confirm email was sent
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
type: object
|
||||
properties:
|
||||
email:
|
||||
type: string
|
||||
sent:
|
||||
type: enum
|
||||
enum: [true]
|
||||
default:
|
||||
description: 'Success'
|
||||
description: Error
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: '#/components/schemas/Error'
|
||||
|
||||
/users-permissions/permissions:
|
||||
get:
|
||||
tags:
|
||||
- Users-Permissions - Users & Roles
|
||||
summary: Get default generated permissions
|
||||
responses:
|
||||
200:
|
||||
description: Returns the permissions tree
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
type: object
|
||||
properties:
|
||||
permissions:
|
||||
$ref: '#/components/schemas/Users-Permissions-PermissionsTree'
|
||||
example:
|
||||
permissions:
|
||||
api::content-type.content-type:
|
||||
controllers:
|
||||
controllerA:
|
||||
find:
|
||||
enabled: false
|
||||
policy: ''
|
||||
findOne:
|
||||
enabled: false
|
||||
policy: ''
|
||||
create:
|
||||
enabled: false
|
||||
policy: ''
|
||||
controllerB:
|
||||
find:
|
||||
enabled: false
|
||||
policy: ''
|
||||
findOne:
|
||||
enabled: false
|
||||
policy: ''
|
||||
create:
|
||||
enabled: false
|
||||
policy: ''
|
||||
default:
|
||||
description: 'Success'
|
||||
description: Error
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: '#/components/schemas/Error'
|
||||
|
||||
/users-permissions/roles:
|
||||
get:
|
||||
tags:
|
||||
@ -258,7 +368,6 @@ paths:
|
||||
|
||||
components:
|
||||
schemas:
|
||||
# TODO: generate dynamically from the CT at startup
|
||||
Users-Permissions-User:
|
||||
type: object
|
||||
properties:
|
||||
@ -296,5 +405,25 @@ components:
|
||||
user:
|
||||
$ref: '#/components/schemas/Users-Permissions-User'
|
||||
|
||||
Users-Permissions-PermissionsTree:
|
||||
type: object
|
||||
additionalProperties:
|
||||
type: object
|
||||
description: every api
|
||||
properties:
|
||||
controllers:
|
||||
description: every controller of the api
|
||||
type: object
|
||||
additionalProperties:
|
||||
type: object
|
||||
additionalProperties:
|
||||
description: every action of every controller
|
||||
type: object
|
||||
properties:
|
||||
enabled:
|
||||
type: boolean
|
||||
policy:
|
||||
type: string
|
||||
|
||||
parameters:
|
||||
responses:
|
||||
|
||||
@ -24075,12 +24075,7 @@ yallist@^3.0.0, yallist@^3.0.2, yallist@^3.1.1:
|
||||
resolved "https://registry.yarnpkg.com/yallist/-/yallist-3.1.1.tgz#dbb7daf9bfd8bac9ab45ebf602b8cbad0d5d08fd"
|
||||
integrity sha512-a4UGQaWPH59mOXUYnAG2ewncQS4i4F43Tv3JoAM+s2VDAmS9NsK8GpDMLrCHPksFT7h3K6TOoUNn2pb7RoXx4g==
|
||||
|
||||
yaml@2.1.1:
|
||||
version "2.1.1"
|
||||
resolved "https://registry.yarnpkg.com/yaml/-/yaml-2.1.1.tgz#1e06fb4ca46e60d9da07e4f786ea370ed3c3cfec"
|
||||
integrity sha512-o96x3OPo8GjWeSLF+wOAbrPfhFOGY0W00GNaxCDv+9hkcDJEnev1yh8S7pgHF0ik6zc8sQLuL8hjHjJULZp8bw==
|
||||
|
||||
yaml@^1.10.0, yaml@^1.7.2:
|
||||
yaml@1.10.2, yaml@^1.10.0, yaml@^1.7.2:
|
||||
version "1.10.2"
|
||||
resolved "https://registry.yarnpkg.com/yaml/-/yaml-1.10.2.tgz#2301c5ffbf12b467de8da2333a459e29e7920e4b"
|
||||
integrity sha512-r3vXyErRCYJ7wg28yvBY5VSoAF8ZvlcW9/BwUzEtUsjvX/DKs24dIkuwjtuprwJJHsbyUbLApepYTR1BN4uHrg==
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user