<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://ohcnwiki.tellmey.fyi/index.php?action=history&amp;feed=atom&amp;title=Concepts%2FRoles_%26_Permissions</id>
	<title>Concepts/Roles &amp; Permissions - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://ohcnwiki.tellmey.fyi/index.php?action=history&amp;feed=atom&amp;title=Concepts%2FRoles_%26_Permissions"/>
	<link rel="alternate" type="text/html" href="https://ohcnwiki.tellmey.fyi/index.php?title=Concepts/Roles_%26_Permissions&amp;action=history"/>
	<updated>2026-07-06T05:42:45Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.45.4</generator>
	<entry>
		<id>https://ohcnwiki.tellmey.fyi/index.php?title=Concepts/Roles_%26_Permissions&amp;diff=404&amp;oldid=prev</id>
		<title>Admin: Automated edit (via update-page on MediaWiki MCP Server)</title>
		<link rel="alternate" type="text/html" href="https://ohcnwiki.tellmey.fyi/index.php?title=Concepts/Roles_%26_Permissions&amp;diff=404&amp;oldid=prev"/>
		<updated>2026-07-06T04:02:37Z</updated>

		<summary type="html">&lt;p&gt;Automated edit (via update-page on MediaWiki MCP Server)&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 09:32, 6 July 2026&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 166:&lt;/td&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 166:&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;| Admin, Doctor, Nurse, Administrator, Staff, Facility Admin, Volunteer, Pharmacist&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;| Admin, Doctor, Nurse, Administrator, Staff, Facility Admin, Volunteer, Pharmacist&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|}&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|}&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-empty diff-side-deleted&quot;&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br /&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-empty diff-side-deleted&quot;&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;{{Navbox access governance}}&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br /&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br /&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;{{Related}}&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;{{Related}}&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
	<entry>
		<id>https://ohcnwiki.tellmey.fyi/index.php?title=Concepts/Roles_%26_Permissions&amp;diff=83&amp;oldid=prev</id>
		<title>Admin: OHC identity seed</title>
		<link rel="alternate" type="text/html" href="https://ohcnwiki.tellmey.fyi/index.php?title=Concepts/Roles_%26_Permissions&amp;diff=83&amp;oldid=prev"/>
		<updated>2026-07-04T22:42:57Z</updated>

		<summary type="html">&lt;p&gt;OHC identity seed&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;{{Doc header&lt;br /&gt;
|type=concept&lt;br /&gt;
|domain=access-governance&lt;br /&gt;
|title=Roles &amp;amp; Permissions&lt;br /&gt;
|order=1&lt;br /&gt;
|introduced=3.0&lt;br /&gt;
|concept=Concepts/Patient&lt;br /&gt;
|reference=References/Permission Association&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
Roles and permissions are how Care decides &amp;#039;&amp;#039;&amp;#039;who can do what, and where&amp;#039;&amp;#039;&amp;#039;. A permission is a single action (&amp;amp;quot;Can Create Patient&amp;amp;quot;), a role bundles permissions into a job-shaped set (&amp;amp;quot;Doctor&amp;amp;quot;), and a grant gives a person that role inside one boundary — a facility, an organization, or a single patient.&lt;br /&gt;
&lt;br /&gt;
== What it represents ==&lt;br /&gt;
&lt;br /&gt;
There is no single FHIR resource for access control. Care builds it from three primitives that only mean something together:&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;Permission&amp;#039;&amp;#039;&amp;#039; — the smallest unit of access: one action, declared in code (for example &amp;lt;code&amp;gt;can_create_patient&amp;lt;/code&amp;gt;). Permissions are reference data; users never edit them.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;Role&amp;#039;&amp;#039;&amp;#039; — a flat, named bundle of permissions (Doctor, Nurse, Admin). A role is just a permission set — not a job title, not a person.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;Grant&amp;#039;&amp;#039;&amp;#039; — a role handed to a user &amp;#039;&amp;#039;within a context&amp;#039;&amp;#039;. The same person can be a Doctor at one facility, an Admin of a district, and have no access anywhere else.&lt;br /&gt;
&lt;br /&gt;
The key insight: a user has &amp;#039;&amp;#039;&amp;#039;no standing powers of their own&amp;#039;&amp;#039;&amp;#039;. Every ability comes from a role granted at a specific place. Move them to a new facility and their old access does not follow — it was scoped to the boundary where it was granted.&lt;br /&gt;
&lt;br /&gt;
== How a grant works ==&lt;br /&gt;
&lt;br /&gt;
A grant always answers three questions — &amp;#039;&amp;#039;who&amp;#039;&amp;#039;, &amp;#039;&amp;#039;what role&amp;#039;&amp;#039;, &amp;#039;&amp;#039;where&amp;#039;&amp;#039;:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;text&amp;quot;&amp;gt;User  ──granted──▶  Role  ──scoped to──▶  Context (facility / organization / patient)&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
The same role at a different context is a separate grant. A grant can also carry an &amp;#039;&amp;#039;&amp;#039;expiry&amp;#039;&amp;#039;&amp;#039;, after which it is meant to lapse — handy for locum cover or temporary staff. One user can hold many grants at once; their effective access on any record is the union of every role that reaches it.&lt;br /&gt;
&lt;br /&gt;
== How access cascades ==&lt;br /&gt;
&lt;br /&gt;
Two things make this manageable at scale rather than a grant-per-record chore.&lt;br /&gt;
&lt;br /&gt;
First, &amp;#039;&amp;#039;&amp;#039;permissions are context-aware&amp;#039;&amp;#039;&amp;#039;. Each permission is scoped to a kind of resource, and Care only considers permissions whose context matches what is being acted on. This is why a permission to view a patient does not also let someone administer a facility — they live in different contexts.&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Context&lt;br /&gt;
! Applies to&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;GENERIC&amp;lt;/code&amp;gt;&lt;br /&gt;
| Actions not tied to a specific resource&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;FACILITY&amp;lt;/code&amp;gt;&lt;br /&gt;
| A facility&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;PATIENT&amp;lt;/code&amp;gt;&lt;br /&gt;
| A patient record&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;ENCOUNTER&amp;lt;/code&amp;gt;&lt;br /&gt;
| A single encounter&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;ORGANIZATION&amp;lt;/code&amp;gt;&lt;br /&gt;
| A government or role (user-group) organization&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;FACILITY_ORGANIZATION&amp;lt;/code&amp;gt;&lt;br /&gt;
| A department or unit inside a facility&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;QUESTIONNAIRE&amp;lt;/code&amp;gt;&lt;br /&gt;
| A questionnaire&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Second, &amp;#039;&amp;#039;&amp;#039;grants flow down the organization tree&amp;#039;&amp;#039;&amp;#039;. Care&amp;#039;s [[Concepts/Organization|organizations]] nest — State → District → Local body → Facility — and a role granted at a node reaches everything beneath it. Grant an Administrator at the district level and they act across every facility in that district with no per-facility grant; grant a role on one facility and it reaches only that facility and its units. The same logic covers patients: a clinician&amp;#039;s role at a facility lets them work with the patients seen there, instead of a grant per patient.&lt;br /&gt;
&lt;br /&gt;
So you grant broadly at the top of the tree for oversight, and narrowly at a facility or department for day-to-day staff.&lt;br /&gt;
&lt;br /&gt;
== Standard roles ==&lt;br /&gt;
&lt;br /&gt;
Every Care deployment ships with these roles. They are platform-maintained — the API will not let anyone edit or delete them — and deployments can add custom roles alongside. A role&amp;#039;s &amp;#039;&amp;#039;boundaries&amp;#039;&amp;#039; are the kinds of context it can be granted in; note that a role name alone is not unique, since &amp;amp;quot;Admin&amp;amp;quot; exists both as a facility role and as a separate role-organization role, distinguished only by boundary.&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Role&lt;br /&gt;
! Description&lt;br /&gt;
! Boundaries it applies in&lt;br /&gt;
|-&lt;br /&gt;
| Doctor&lt;br /&gt;
| Clinician at a facility&lt;br /&gt;
| Facility, Government org&lt;br /&gt;
|-&lt;br /&gt;
| Nurse&lt;br /&gt;
| Nurse at a facility&lt;br /&gt;
| Facility, Government org&lt;br /&gt;
|-&lt;br /&gt;
| Staff&lt;br /&gt;
| General staff at a facility&lt;br /&gt;
| Facility, Government org&lt;br /&gt;
|-&lt;br /&gt;
| Volunteer&lt;br /&gt;
| Volunteer at a facility&lt;br /&gt;
| Facility, Government org&lt;br /&gt;
|-&lt;br /&gt;
| Pharmacist&lt;br /&gt;
| Pharmacist at a facility&lt;br /&gt;
| Facility&lt;br /&gt;
|-&lt;br /&gt;
| Administrator&lt;br /&gt;
| Administrator at a given boundary&lt;br /&gt;
| Facility, Government org&lt;br /&gt;
|-&lt;br /&gt;
| Facility Admin&lt;br /&gt;
| Facility administrator, assigned to whoever creates the facility&lt;br /&gt;
| Facility&lt;br /&gt;
|-&lt;br /&gt;
| Admin&lt;br /&gt;
| Top-level administrator&lt;br /&gt;
| Facility, Government org&lt;br /&gt;
|-&lt;br /&gt;
| Admin (role org)&lt;br /&gt;
| Administrator of a role (user-group) organization&lt;br /&gt;
| Role org&lt;br /&gt;
|-&lt;br /&gt;
| Manager (role org)&lt;br /&gt;
| Manager of a role organization&lt;br /&gt;
| Role org&lt;br /&gt;
|-&lt;br /&gt;
| Member (role org)&lt;br /&gt;
| Member of a role organization&lt;br /&gt;
| Role org&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Permissions ==&lt;br /&gt;
&lt;br /&gt;
Permissions are declared in code per resource area and assigned to standard roles by default. The slice below — the organization and user permissions — shows which roles hold each out of the box; custom roles can take any subset.&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Permission&lt;br /&gt;
! Description&lt;br /&gt;
! System Roles&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;can_create_organization&amp;lt;/code&amp;gt;&lt;br /&gt;
| Create a new organization under an accessible parent (checked by the organization create flow)&lt;br /&gt;
| Admin&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;can_view_organization&amp;lt;/code&amp;gt;&lt;br /&gt;
| View organizations; gates which organizations appear in list and retrieve&lt;br /&gt;
| Facility Admin, Admin, Staff, Doctor, Administrator, Nurse, Volunteer, Pharmacist, Admin (role org), Manager (role org), Member (role org)&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;can_list_organization_users&amp;lt;/code&amp;gt;&lt;br /&gt;
| List the users attached to an organization&lt;br /&gt;
| Facility Admin, Admin, Staff, Doctor, Administrator, Nurse, Volunteer, Pharmacist, Admin (role org), Manager (role org)&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;can_manage_organization&amp;lt;/code&amp;gt;&lt;br /&gt;
| Update an organization (name, description, metadata) and delete it — the update, delete, and managing-organization actions all check this&lt;br /&gt;
| Admin, Admin (role org)&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;can_manage_organization_users&amp;lt;/code&amp;gt;&lt;br /&gt;
| Add, remove, and assign roles to users in an organization&lt;br /&gt;
| Admin, Administrator, Facility Admin, Admin (role org)&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;can_manage_connected_role_organizations&amp;lt;/code&amp;gt;&lt;br /&gt;
| Manage users in connected role organizations&lt;br /&gt;
| Admin (role org), Manager (role org)&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;can_create_user&amp;lt;/code&amp;gt;&lt;br /&gt;
| Create a user in Care&lt;br /&gt;
| Admin, Facility Admin, Administrator&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;can_create_service_account&amp;lt;/code&amp;gt;&lt;br /&gt;
| Create a service-account user&lt;br /&gt;
| Admin, Facility Admin, Administrator&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;can_list_user&amp;lt;/code&amp;gt;&lt;br /&gt;
| List users in Care&lt;br /&gt;
| Admin, Doctor, Nurse, Administrator, Staff, Facility Admin, Volunteer, Pharmacist&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
{{Related}}&lt;/div&gt;</summary>
		<author><name>Admin</name></author>
	</entry>
</feed>