Moped Documentation
  • Welcome 👋
  • User Guides
    • Getting started
    • Map a project
  • Product Management
    • User communication
    • User management
    • User analytics
    • Local testing
    • Release process
    • Patch release process
    • MUI X Pro License
    • Integrations
      • Dataset documentation
      • ArcGIS Online
      • eCapris
      • Power BI
    • Features
  • Dev Guides
    • DB Docs & Data dictionary
    • Database backup policy
    • Moped Read Replica
    • How-to's
      • How do I start the Hasura cluster locally?
      • How do I launch the Hasura Console?
      • How do I get a JWT token?
      • How to ping the GraphQL API
      • How to ping the REST API
      • How do I connect a database with Postgres GUIs?
      • How do I connect to the RDS instance?
      • How to load production data into a local instance
      • How do I update seed data?
    • Hasura
      • Hasura Roles
      • Hasura Migrations
        • Getting Started
        • Installing the Hasura CLI
        • Configuration Files
        • Hasura Migration Principles
        • The Migration file format
        • Development
        • Hasura Seed Data
        • Running the Hasura Cluster Locally (video)
        • Create a migration: Exercise 1 (video)
        • Create a migration: Exercise 2 (video)
        • Latest hasura-cluster features
    • User Management
    • Authentication
      • Authentication Architecture
      • DynamoDB & Cognito
      • Secrets Manager & Cognito
      • Hasura & Cognito
      • React & Cognito
      • Flask API & Cognito
      • Single Sign-On with CTM
    • Code organization
    • API
      • Configuration Files
      • Testing
      • User Management API
    • Maps and geospatial data
      • Access tokens and API keys
      • Map libraries
      • Map data
      • Map styles
      • Map layers and basemaps
      • React patterns
      • V1 Archive
        • Map libraries
        • Map data
        • Map custom hooks
        • Map styles
        • Map layers and basemaps
    • UI access control
    • Design system
      • Branding
      • Component styles
      • Text content
    • Activity Log
      • Architecture
      • GitHub Actions and Deployment of Updates
      • Hasura Event Logs and Truncate Cron Job
      • Authentication
  • See also
  • Get Moped support, report a bug, or request an enhancement
  • Data & Technology Services
  • Github repository
Powered by GitBook
On this page
  • Three Initial Roles
  • How are these roles implemented?
  • How can these roles be changed?

Was this helpful?

  1. Dev Guides
  2. Hasura

Hasura Roles

PreviousHasuraNextHasura Migrations

Last updated 4 years ago

Was this helpful?

Three Initial Roles

A0s requested in , there are currently three roles implemented in production:

  • moped-admin This role can create a moped-editor as well as read-write access to any part of the database. No deletions are permitted, aggregations are not allowed either.

  • moped-editor This role has read-write access to any part of the database. No deletions are permitted, aggregations are not allowed either.

  • moped-viewer This role has read-only access to any part of the database.

How are these roles implemented?

The rules are implemented through a Hasura metadata migration. First, the local hasura cluster is started, then the console. While the console is open, the permissions are changed, then the console will make changes to the metadata file.

How can these roles be changed?

First, create a new branch in git. Then, start the cluster (locally), and open the hasura console. Once the console is open, go to any table you need to make changes to, then change the permission settings for the specific role you need to change.

Once you make changes, the console will directly make changes to the metadata file, which is tracked by git, meaning that git will show differences in the code which you can commit and push to your branch, those changes made to your PR can be tested by someone else without affecting staging and prod, and once approved the branch will be merged to staging (or production) and the migration will be applied automatically by GitHub actions.

this document