kanbanworkflowstimelinescrumrubyroadmapproject-planningproject-managementopenprojectangularissue-trackerifcgantt-chartganttbug-trackerboardsbcf
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
187 lines
5.6 KiB
187 lines
5.6 KiB
3 years ago
|
# /api/v3/users/{id}/lock
|
||
|
---
|
||
|
delete:
|
||
|
parameters:
|
||
|
- description: User id
|
||
|
example: '1'
|
||
|
in: path
|
||
|
name: id
|
||
|
required: true
|
||
|
schema:
|
||
|
type: integer
|
||
|
responses:
|
||
|
'200':
|
||
|
content:
|
||
|
application/hal+json:
|
||
|
examples:
|
||
|
response:
|
||
|
value:
|
||
|
_links:
|
||
|
delete:
|
||
|
href: "/api/v3/users/1"
|
||
|
method: DELETE
|
||
|
lock:
|
||
|
href: "/api/v3/users/1/lock"
|
||
|
method: POST
|
||
|
self:
|
||
|
href: "/api/v3/users/1"
|
||
|
title: j.sheppard
|
||
|
show:
|
||
|
href: "/users/1"
|
||
|
type: text/html
|
||
|
updateImmediately:
|
||
|
href: "/api/v3/users/1"
|
||
|
method: PATCH
|
||
|
_type: User
|
||
|
admin: true
|
||
|
avatar: https://example.org/users/1/avatar
|
||
|
createdAt: '2014-05-21T08:51:20Z'
|
||
|
email: shep@mail.com
|
||
|
firstName: John
|
||
|
id: 1
|
||
|
language: en
|
||
|
lastName: Sheppard
|
||
|
login: j.sheppard
|
||
|
status: active
|
||
|
updatedAt: '2014-05-21T08:51:20Z'
|
||
|
schema:
|
||
|
"$ref": "../components/schemas/view_user_model.yml"
|
||
|
description: OK
|
||
|
headers: {}
|
||
|
'400':
|
||
|
content:
|
||
|
application/hal+json:
|
||
|
examples:
|
||
|
response:
|
||
|
value:
|
||
|
_type: Error
|
||
|
errorIdentifier: urn:openproject-org:api:v3:errors:InvalidUserStatusTransition
|
||
|
message: The current user account status does not allow this operation.
|
||
|
description: |-
|
||
|
Returned if the client tries to unlock a user account whose current status does not allow this transition.
|
||
|
|
||
|
**Required permission:** Administrators only
|
||
|
headers: {}
|
||
|
'403':
|
||
|
content:
|
||
|
application/hal+json:
|
||
|
examples:
|
||
|
response:
|
||
|
value:
|
||
|
_type: Error
|
||
|
errorIdentifier: urn:openproject-org:api:v3:errors:MissingPermission
|
||
|
message: You are not allowed to unlock the account of this user.
|
||
|
description: |-
|
||
|
Returned if the client does not have sufficient permissions for unlocking a user.
|
||
|
|
||
|
**Required permission:** Administrators only
|
||
|
headers: {}
|
||
|
'404':
|
||
|
content:
|
||
|
application/hal+json:
|
||
|
examples:
|
||
|
response:
|
||
|
value:
|
||
|
_type: Error
|
||
|
errorIdentifier: urn:openproject-org:api:v3:errors:NotFound
|
||
|
message: The specified user does not exist.
|
||
|
description: Returned if the user does not exist.
|
||
|
headers: {}
|
||
|
tags:
|
||
|
- Users
|
||
|
description: ''
|
||
|
operationId: Unlock_user
|
||
|
summary: Unlock user
|
||
|
post:
|
||
|
parameters:
|
||
|
- description: User id
|
||
|
example: '1'
|
||
|
in: path
|
||
|
name: id
|
||
|
required: true
|
||
|
schema:
|
||
|
type: integer
|
||
|
responses:
|
||
|
'200':
|
||
|
content:
|
||
|
application/hal+json:
|
||
|
examples:
|
||
|
response:
|
||
|
value:
|
||
|
_links:
|
||
|
delete:
|
||
|
href: "/api/v3/users/1"
|
||
|
method: DELETE
|
||
|
lock:
|
||
|
href: "/api/v3/users/1/lock"
|
||
|
method: POST
|
||
|
self:
|
||
|
href: "/api/v3/users/1"
|
||
|
title: j.sheppard
|
||
|
show:
|
||
|
href: "/users/1"
|
||
|
type: text/html
|
||
|
updateImmediately:
|
||
|
href: "/api/v3/users/1"
|
||
|
method: PATCH
|
||
|
_type: User
|
||
|
admin: true
|
||
|
avatar: https://example.org/users/1/avatar
|
||
|
createdAt: '2014-05-21T08:51:20Z'
|
||
|
email: shep@mail.com
|
||
|
firstName: John
|
||
|
id: 1
|
||
|
language: en
|
||
|
lastName: Sheppard
|
||
|
login: j.sheppard
|
||
|
status: active
|
||
|
updatedAt: '2014-05-21T08:51:20Z'
|
||
|
schema:
|
||
|
"$ref": "../components/schemas/view_user_model.yml"
|
||
|
description: OK
|
||
|
headers: {}
|
||
|
'400':
|
||
|
content:
|
||
|
application/hal+json:
|
||
|
examples:
|
||
|
response:
|
||
|
value:
|
||
|
_type: Error
|
||
|
errorIdentifier: urn:openproject-org:api:v3:errors:InvalidUserStatusTransition
|
||
|
message: The current user account status does not allow this operation.
|
||
|
description: |-
|
||
|
Returned if the client tries to lock a user account whose current status does not allow this transition.
|
||
|
|
||
|
**Required permission:** Administrators only
|
||
|
headers: {}
|
||
|
'403':
|
||
|
content:
|
||
|
application/hal+json:
|
||
|
examples:
|
||
|
response:
|
||
|
value:
|
||
|
_type: Error
|
||
|
errorIdentifier: urn:openproject-org:api:v3:errors:MissingPermission
|
||
|
message: You are not allowed to lock the account of this user.
|
||
|
description: |-
|
||
|
Returned if the client does not have sufficient permissions for locking a user.
|
||
|
|
||
|
**Required permission:** Administrators only
|
||
|
headers: {}
|
||
|
'404':
|
||
|
content:
|
||
|
application/hal+json:
|
||
|
examples:
|
||
|
response:
|
||
|
value:
|
||
|
_type: Error
|
||
|
errorIdentifier: urn:openproject-org:api:v3:errors:NotFound
|
||
|
message: The specified user does not exist.
|
||
|
description: Returned if the user does not exist.
|
||
|
headers: {}
|
||
|
tags:
|
||
|
- Users
|
||
|
description: ''
|
||
|
operationId: Lock_user
|
||
|
summary: Lock user
|