Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
W
WIE_202021_CSBillero11
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Bernard Roland (Student Com20)
WIE_202021_CSBillero11
Commits
f628d022
Commit
f628d022
authored
3 years ago
by
Bernard Roland (Student Com20)
Browse files
Options
Downloads
Patches
Plain Diff
Finished the API documentation
parent
9c888326
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
docs/api/work.md
+47
-0
47 additions, 0 deletions
docs/api/work.md
with
47 additions
and
0 deletions
docs/api/work.md
+
47
−
0
View file @
f628d022
## Work
### GET `/work` [requires authentication]
Get the information on the currently open work item of the authenticated user. If no item is open,
404 will be returned.
#### Response body
```
typescript
interface
Body
{
status
:
string
;
work
:
{
id
:
string
;
task
:
string
;
user
:
string
;
started
:
number
;
finished
?:
number
;
};
}
```
### POST `/work/start` [requires authentication]
Create a new work item with the given data. All open work items for the authenticated user will
also be closed in turn. On successful creation the id of the new work item will be returned.
#### Request body
```
typescript
interface
Body
{
task
:
string
;
}
```
#### Response body
```
typescript
interface
Body
{
status
:
string
;
id
:
string
;
}
```
### PUT `/work/finish` [requires authentication]
Finish the currently open work of the authenticated user. If no item is open, 404 will be returned.
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment