# DHIS Connector Module - User Access Controlling

**URL:** <https://talk.openmrs.org/t/dhis-connector-module-user-access-controlling/34059>\
**Category:** GSoC\
**Tags:** module, dhis2, gsoc-2021\
**Created:** [July 13, 2021, 10:30am UTC](https://talk.openmrs.org/t/dhis-connector-module-user-access-controlling/34059 "2021-07-13T10:30:52Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![piumal1999](https://talk.openmrs.org/user_avatar/talk.openmrs.org/piumal1999/32/13557_2.png) [@piumal1999](https://talk.openmrs.org/u/piumal1999)\
**Post date:** [July 14, 2021, 8:27pm UTC](https://talk.openmrs.org/t/dhis-connector-module-user-access-controlling/34059/2 "2021-07-14T20:27:46Z")

</div>

Hi @akshika47 @k.joseph,

Basically my plan is to create the privileges first, so the roles can be created later according to the user requirements. We can secure the Different pages and options in Module UI with these privileges.

So these are the privileges I suggest for the DHIS Connector module.

1. View\_Data
2. Push\_Data
3. Manage\_Metadata

Previously I thought to create a new privilege for Import/export options. But in a previous meeting @k.joseph suggested to include that too in the manage\_metadata privilege

This is how the module will work for the users with/without these privileges.

### Users without any privilege

- Can’t access the module

### Users with View\_Data privilege

- Can access the module
- Have read access to these pages
  - Configure DHIS Server (Read only)
  - Location Mapping (Read only)
  - Automation (Read only)

### Users with Push\_Data privilege

- Can access the module
- Have access to these pages
  - Configure DHIS Server (Read only)
  - Location Mapping (Read only)
  - Automation
    - Can’t add/delete records
    - Can run/re-run automated mappings

  - Run Reports
    - Can push data or download ADX or JSON

  - Failed Data
    - Can push failed data

### Users with Manage\_Metadata privilege

- Can access the module
- Have access to these pages
  - Configure DHIS Server
    - Can update the connection

  - Location Mapping
    - Can edit/add mappings

  - Automation
    - Can add/delete records
    - Can’t push data

  - Create Mappings
  - Manage Mappings
  - Import/Export mappings
  - Import/Export DHIS2 API

After creating the privileges, we have to update the pages and options to display according to the user privileges. Also the backend endpoints will be updated to work according to the privileges. Then we can create roles with the combinations of these privileges.

This is the approach I thought to take. I would love to have your suggestions too. Is it ok to proceed with this or do I have to change anything?

cc: @akshika47 @k.joseph @jayasanka

---

_[View the full topic](https://talk.openmrs.org/t/dhis-connector-module-user-access-controlling/34059)._
