mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-08-21 07:03:49 +00:00
add route for scope on participation
This commit is contained in:
@@ -1,11 +1,41 @@
|
||||
components:
|
||||
schemas:
|
||||
# should go to main
|
||||
Date:
|
||||
type: object
|
||||
properties:
|
||||
datetime:
|
||||
type: string
|
||||
format: date-time
|
||||
Scope:
|
||||
type: object
|
||||
properties:
|
||||
id:
|
||||
type: integer
|
||||
type:
|
||||
type: string
|
||||
enum:
|
||||
- scope
|
||||
name:
|
||||
type: object
|
||||
additionalProperties:
|
||||
type: string
|
||||
example:
|
||||
fr: Social
|
||||
ScopeById:
|
||||
type: object
|
||||
properties:
|
||||
id:
|
||||
type: integer
|
||||
type:
|
||||
type: string
|
||||
enum:
|
||||
- scope
|
||||
required:
|
||||
- id
|
||||
- scope
|
||||
|
||||
# ok to stay here
|
||||
Person:
|
||||
type: object
|
||||
properties:
|
||||
@@ -413,7 +443,7 @@ paths:
|
||||
delete:
|
||||
tags:
|
||||
- person
|
||||
summary: "Remove the resource"
|
||||
summary: "Remove the comment"
|
||||
parameters:
|
||||
- name: id
|
||||
in: path
|
||||
@@ -424,7 +454,7 @@ paths:
|
||||
format: integer
|
||||
minimum: 1
|
||||
requestBody:
|
||||
description: "A resource"
|
||||
description: "A comment"
|
||||
required: true
|
||||
content:
|
||||
application/json:
|
||||
@@ -439,3 +469,68 @@ paths:
|
||||
description: "OK"
|
||||
422:
|
||||
description: "object with validation errors"
|
||||
|
||||
/1.0/person/accompanying-course/{id}/scope.json:
|
||||
post:
|
||||
tags:
|
||||
- person
|
||||
summary: "Add a scope to the accompanying course"
|
||||
parameters:
|
||||
- name: id
|
||||
in: path
|
||||
required: true
|
||||
description: The accompanying period's id
|
||||
schema:
|
||||
type: integer
|
||||
format: integer
|
||||
minimum: 1
|
||||
requestBody:
|
||||
description: "A comment"
|
||||
required: true
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: '#/components/schemas/Scope'
|
||||
examples:
|
||||
add a scope:
|
||||
value:
|
||||
type: scope
|
||||
id: 5
|
||||
responses:
|
||||
401:
|
||||
description: "Unauthorized"
|
||||
404:
|
||||
description: "Not found"
|
||||
200:
|
||||
description: "OK"
|
||||
422:
|
||||
description: "object with validation errors"
|
||||
delete:
|
||||
tags:
|
||||
- person
|
||||
summary: "Remove the scope"
|
||||
parameters:
|
||||
- name: id
|
||||
in: path
|
||||
required: true
|
||||
description: The accompanying period's id
|
||||
schema:
|
||||
type: integer
|
||||
format: integer
|
||||
minimum: 1
|
||||
requestBody:
|
||||
description: "A scope with his id"
|
||||
required: true
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: '#/components/schemas/ScopeById'
|
||||
responses:
|
||||
401:
|
||||
description: "Unauthorized"
|
||||
404:
|
||||
description: "Not found"
|
||||
200:
|
||||
description: "OK"
|
||||
422:
|
||||
description: "object with validation errors"
|
||||
|
Reference in New Issue
Block a user