Roles & Permissions
Each action within the Spotflow IoT Platform requires certain permissions. The platform uses a role-based access control (RBAC) system to manage these permissions. This system determines which permissions a user has based on the roles assigned to them.
The roles are defined and assigned on the level of individual assets, such as Workspaces, Stream Groups, Streams, Egress Sinks, Service Accounts, and Fleet Configurations. Thanks to that, you can granularly control who can access each part of your system. See the Roles Reference for a list of available roles and the permissions they grant.
Assigning And Revoking Roles
To assign or revoke a user role, use the Assign Role and Revoke Role API endpoints.
The provided assetId
must be a fully qualified identificator of the asset:
- Workspace:
/workspaces/{workspaceId}
- Stream Group:
/workspaces/{workspaceId}/stream-groups/{streamGroupId}
- Stream:
/workspaces/{workspaceId}/stream-groups/{streamGroupId}/streams/{streamId}
- Egress Sinks:
/workspaces/{workspaceId}/egress-sinks/{egressSinkId}
- Service Accounts:
/workspaces/{workspaceId}/service-accounts/{serviceAccountId}
- Fleet Configuration:
/workspaces/{workspaceId}/fleet-configurations/{fleetConfigurationId}
Roles Reference
The following table lists all available roles and their permissions. The prefix of each role indicates the type of asset it can be assigned to.
/workspaces/owner
/workspaces/contributor
and the following:workspaces.egress-sinks.roles:assign
workspaces.fleet-configurations.roles:assign
workspaces.roles:assign
workspaces.service-accounts.api-keys:create
workspaces.service-accounts.api-keys:revoke
workspaces.service-accounts.api-keys:update
workspaces.service-accounts.roles:assign
workspaces.service-accounts:create
workspaces.service-accounts:delete
workspaces.service-accounts:update
workspaces.stream-groups.roles:assign
workspaces.stream-groups.streams.roles:assign
workspaces.stream-groups.streams.stream-partitioning:update
workspaces:delete
/workspaces/contributor
/workspaces/reader
and the following:workspaces.alert-notification-targets:create
workspaces.alert-notification-targets:delete
workspaces.alert-notification-targets:update
workspaces.alert-rules:create
workspaces.alert-rules:delete
workspaces.alert-rules:update
workspaces.alerts:acknowledge
workspaces.devices.c2d-messages:send
workspaces.devices.desired-properties:update
workspaces.devices.http-proxy:use
workspaces.devices.tags:update
workspaces.devices:delete
workspaces.egress-sinks.secrets:read
workspaces.egress-sinks:create
workspaces.egress-sinks:delete
workspaces.egress-sinks:update
workspaces.fleet-configurations:create
workspaces.fleet-configurations:delete
workspaces.fleet-configurations:update
workspaces.fleet-configurations:validate
workspaces.grafana:contribute
workspaces.provisioning-operations:resolve
workspaces.provisioning-tokens:create
workspaces.provisioning-tokens:regenerate
workspaces.registration-tokens:create
workspaces.registration-tokens:revoke
workspaces.stream-groups.stream-storage.secrets:read
workspaces.stream-groups.streams.egress-routes:create
workspaces.stream-groups.streams.egress-routes:delete
workspaces.stream-groups.streams.egress-routes:update
workspaces.stream-groups.streams:create
workspaces.stream-groups.streams:delete
workspaces.stream-groups.streams:update
workspaces.stream-groups:create
workspaces.stream-groups:delete
workspaces.stream-groups:update
workspaces.workspace-storage.secrets:read
workspaces.workspace-storage:use
workspaces:update
/workspaces/reader
workspaces.alert-notification-targets:read
workspaces.alert-rules:read
workspaces.alerts:list
workspaces.devices.desired-properties:read
workspaces.devices.reported-properties:read
workspaces.devices.tags:read
workspaces.devices:read
workspaces.egress-sinks:read
workspaces.fleet-configurations:read
workspaces.grafana:read
workspaces.provisioning-operations:read
workspaces.provisioning-tokens:read
workspaces.service-accounts:read
workspaces.stream-groups.streams:read
workspaces.stream-groups:read
workspaces:read
/workspaces/data-flows-contributor
workspaces.stream-groups.stream-storage.secrets:read
workspaces.stream-groups.streams.egress-routes:create
workspaces.stream-groups.streams.egress-routes:delete
workspaces.stream-groups.streams.egress-routes:update
workspaces.stream-groups.streams:create
workspaces.stream-groups.streams:delete
workspaces.stream-groups.streams:read
workspaces.stream-groups.streams:update
workspaces.stream-groups:create
workspaces.stream-groups:delete
workspaces.stream-groups:read
workspaces.stream-groups:update
workspaces.workspace-storage.secrets:read
workspaces.workspace-storage:use
workspaces:read
/workspaces/egress-sink-contributor
workspaces.egress-sinks.secrets:read
workspaces.egress-sinks:create
workspaces.egress-sinks:delete
workspaces.egress-sinks:read
workspaces.egress-sinks:update
workspaces:read
/workspaces/devices-operator
workspaces.devices.c2d-messages:send
workspaces.devices.desired-properties:read
workspaces.devices.desired-properties:update
workspaces.devices.http-proxy:use
workspaces.devices.reported-properties:read
workspaces.devices.tags:read
workspaces.devices.tags:update
workspaces.devices:delete
workspaces.devices:read
workspaces.provisioning-operations:read
workspaces.provisioning-operations:resolve
workspaces.provisioning-tokens:create
workspaces.provisioning-tokens:read
workspaces.provisioning-tokens:regenerate
workspaces.registration-tokens:create
workspaces.registration-tokens:revoke
workspaces:read
/workspaces/fleet-configurations-contributor
workspaces.fleet-configurations:create
workspaces.fleet-configurations:delete
workspaces.fleet-configurations:read
workspaces.fleet-configurations:update
workspaces.fleet-configurations:validate
workspaces:read
/workspaces/alerting-contributor
workspaces.alert-notification-targets:create
workspaces.alert-notification-targets:delete
workspaces.alert-notification-targets:read
workspaces.alert-notification-targets:update
workspaces.alert-rules:create
workspaces.alert-rules:delete
workspaces.alert-rules:read
workspaces.alert-rules:update
workspaces.alerts:acknowledge
workspaces.alerts:list
workspaces:read
/workspaces/grafana-reader
workspaces.grafana:read
/workspaces/grafana-contributor
/workspaces/grafana-reader
and the following:workspaces.grafana:contribute
/workspaces/stream-partitioning-contributor
workspaces.stream-groups.streams.stream-partitioning:update
workspaces:read
/stream-groups/owner
/stream-groups/contributor
and the following:workspaces.stream-groups.roles:assign
workspaces.stream-groups.streams.roles:assign
workspaces.stream-groups.streams.stream-partitioning:update
/stream-groups/contributor
/stream-groups/reader
and the following:workspaces.stream-groups.stream-storage.secrets:read
workspaces.stream-groups.streams.egress-routes:create
workspaces.stream-groups.streams.egress-routes:delete
workspaces.stream-groups.streams.egress-routes:update
workspaces.stream-groups.streams:create
workspaces.stream-groups.streams:delete
workspaces.stream-groups.streams:update
workspaces.stream-groups:delete
workspaces.stream-groups:update
/stream-groups/reader
workspaces.stream-groups.streams:read
workspaces.stream-groups:read
workspaces:read
/stream-groups/stream-partitioning-contributor
workspaces.stream-groups.streams.stream-partitioning:update
workspaces.stream-groups.streams:read
workspaces.stream-groups:read
workspaces:read
/streams/owner
/streams/contributor
and the following:workspaces.stream-groups.streams.roles:assign
workspaces.stream-groups.streams.stream-partitioning:update
/streams/contributor
/streams/reader
and the following:workspaces.stream-groups.streams.egress-routes:create
workspaces.stream-groups.streams.egress-routes:delete
workspaces.stream-groups.streams.egress-routes:update
workspaces.stream-groups.streams:delete
workspaces.stream-groups.streams:update
/streams/reader
workspaces.stream-groups.streams:read
workspaces.stream-groups:read
workspaces:read
/streams/stream-partitioning-contributor
workspaces.stream-groups.streams.stream-partitioning:update
workspaces.stream-groups.streams:read
workspaces.stream-groups:read
workspaces:read
/egress-sinks/owner
/egress-sinks/contributor
and the following:workspaces.egress-sinks.roles:assign
/egress-sinks/contributor
/egress-sinks/reader
and the following:workspaces.egress-sinks.secrets:read
workspaces.egress-sinks:delete
workspaces.egress-sinks:update
/egress-sinks/reader
workspaces.egress-sinks:read
workspaces:read
/service-accounts/owner
/service-accounts/contributor
and the following:workspaces.service-accounts.roles:assign
/service-accounts/contributor
/service-accounts/reader
and the following:workspaces.service-accounts.api-keys:create
workspaces.service-accounts.api-keys:revoke
workspaces.service-accounts.api-keys:update
workspaces.service-accounts:delete
workspaces.service-accounts:update
/service-accounts/reader
workspaces.service-accounts:read
workspaces:read
/fleet-configurations/owner
/fleet-configurations/contributor
and the following:workspaces.fleet-configurations.roles:assign
/fleet-configurations/contributor
/fleet-configurations/reader
and the following:workspaces.fleet-configurations:delete
workspaces.fleet-configurations:update
/fleet-configurations/reader
workspaces.fleet-configurations:read
workspaces:read