@cpod/sdk - v0.2.7
    Preparing search index...

    Class PermissionsModule

    Permissions Module

    Role-based access control and permission checking.

    This module is pending backend implementation. All methods will throw NotImplementedError until the backend endpoints are available.

    Index

    Constructors

    Methods

    • Check if current user has a specific permission

      Parameters

      • permission: string

        Permission name to check

      Returns Promise<boolean>

      True if user has the permission

      NotImplementedError - Backend endpoint pending

    • Check if current user has multiple permissions

      Parameters

      • permissions: string[]

        Array of permission names to check

      • requireAll: boolean = true

        If true, user must have all permissions. If false, any permission is sufficient.

      Returns Promise<HasPermissionsResponse>

      Permission check results

      NotImplementedError - Backend endpoint pending

    • Check if current user can access a specific resource

      Parameters

      • resourceType: string

        Type of resource (e.g., "project", "file")

      • resourceId: string

        ID of the resource

      • action: PermissionAction

        Action to check (e.g., "read", "update")

      Returns Promise<boolean>

      True if user can access the resource

      NotImplementedError - Backend endpoint pending