• This function setups a new Service Account with a given permission structure. Depending on the param enforceValidPermissionStructure, if any invalid permission(s) exists, the method will throw an error.

    Parameters

    • authEndpoint: string

      URL for id-service authEndpoint.

    • accessToken: string

      A valid token with permission for DEV_SETUP_SERVICE_ACCOUNT_WITH_PERMISSIONS granted.

    • serviceAccountName: string

      Name of the new service account.

    • permissions: PermissionStructure[]

      The list of permissions to be assigned to the new service account. This is an array of shape {serviceId: string, permissions: string[]}.

    • enforceValidPermissionStructure: boolean = true

      A boolean indicating if the permissions passed should be validated against existing permissions.

    Returns Promise<ServiceAccountResult>

    Client ID and Client Secret.

Generated using TypeDoc