/* generated using openapi-typescript-codegen -- do not edit */ /* istanbul ignore file */ /* tslint:disable */ /* eslint-disable */ import type { RbacBaseRole } from './RbacBaseRole'; import type { RbacPlatform } from './RbacPlatform'; import type { RbacPolicyGroup } from './RbacPolicyGroup'; import type { RbacUser } from './RbacUser'; /** * Serializer for policies. */ export type RbacPolicy = { readonly id: number; /** * Policy name. If not supplied, defaults to a UUID4 */ name?: string; /** * Role information (read-only) */ readonly role: RbacBaseRole; /** * Platform information (read-only) */ readonly platform: RbacPlatform; /** * Target platform key. Service-account callers must supply this. Non-SA callers' value is overwritten by the view with the platform from the auth token. */ platform_key: string; /** * List of resource paths this policy grants access to, relative to your platform (e.g., ['/mentors/', '/usergroups/5/']). The '/platforms/{pk}/' prefix is added server-side. */ resources: Array; readonly users: Array; readonly groups: Array; /** * ID of the role this policy applies to */ role_id: number; /** * List of user IDs to add to this Policy */ users_to_add?: Array; /** * List of user IDs to remove from this Policy */ users_to_remove?: Array; /** * List of group IDs to add to this Policy */ groups_to_add?: Array; /** * List of group IDs to remove from this Policy */ groups_to_remove?: Array; /** * When True, this policy is internal to the system and cannot be modified by tenants via API endpoints. */ readonly is_internal: boolean; };