https://www.hl7.org/fhir/STU3/operations.html
https://www.hl7.org/fhir/STU3/operationdefinition.html
Status
In development. API spec subject to change.
Overview
This operation allows:
a Team Coordinator to deactivate an existing member of staff in their team.
a System user to deactivate an existing member of staff in a specified team.
a System user to deactivate an existing member of staff in a specified organisation...recursive deactivate within all teams within that organisation.
Endpoints
Interaction | HTTP | URL | Supported Parameters | Permitted User Types | Description |
POST | /Organization/<id>/$deactivate-team-member | mandatory:
optional:
Reference 'in' mappings below. |
| Deactivates an existing user. If <id> matches a [[Team]] then user is deactivated from that [[Team]] only. The user will remain in their current state in any other [[Team]]'s. If <id> matches an [[Organisation]] then user is deactivated from all [[Team]]'s in that [[Organisation]]. Only a system user can call the operation with an [[Organisation]]. If user-type is included then only deactivate a user matching that user-type. If user-type is excluded then all user types that match the email-address are deactivated - team coordinator and/or professional. |
Mappings
FHIR | PKB | Notes |
OperationDefinition.url | "http://fhir.patientsknowbest.com/operation/deactivate-team-member" |
|
"deactivate-team-member" |
| |
OperationDefinition.status | "active" |
|
OperationDefinition.kind | "operation" |
|
OperationDefinition.code | "deactivate-team-member" |
|
OperationDefinition.resource |
|
|
OperationDefinition.system | false |
|
OperationDefinition.type | false |
|
OperationDefinition.instance | true |
|
OperationDefinition.parameter |
| user-type options:
|
Examples
Deactivate team member from Team 'A'
As user-type is not specified in the example then the user is deactivated from all roles within Team A.
Request
/Organization/<Team A UUID>/$deactivate-team-member body: { "resourceType": "Parameters", "parameter": [{ "name": "deactivate-team-member", "email-address": "jock.jones@mydomain.com" }]
}
The response indicates that the team member has been deactivated.
Response
{ "resourceType": "Parameters", "parameter": [ { "message": "Deactivated from 1 team" } ] }
Deactivate the same team member from Team 'B'
As user-type is not specified in the example then the user is deactivated from all roles within Team B.
Request
/Organization/<Team B UUID>/$deactivate-team-member body: { "resourceType": "Parameters", "parameter": [{ "name": "deactivate-team-member", "email-address": "jock.jones@mydomain.com" }]
}
The response indicates that the team member has been deactivated.
Response
{ "resourceType": "Parameters", "parameter": [ { "message": "Deactivated from 1 team" } ] }
Deactivate a user from Org A (all teams that are partOf Org A). System User only.
As user-type is not specified in the example then the user is deactivated from all roles in all teams that are part of the org.
Request
/Organization/<Org A UUID>/$deactivate-team-member body: { "resourceType": "Parameters", "parameter": [{ "name": "deactivate-team-member", "email-address": "david.lawson@mydomain.com" }]}
The response indicates that the team member has been deactivated from multiple teams.
Response
{ "resourceType": "Parameters", "parameter": [ { "message": "Deactivated from 10 teams" } ] }
PKB customer sites: deploy | developer | information governance | procurement | manual
© Patients Know Best, Ltd. Registered in England and Wales Number: 6517382. VAT Number: GB 944 9739 67.
This API specification and design is licensed under a Creative Commons Attribution 4.0 International License.