Class LicenseSubUserOperations

java.lang.Object
dev.demeng.sentinel.client.license.LicenseSubUserOperations

public final class LicenseSubUserOperations extends Object
Operations for managing license sub-users.

Obtain an instance via LicenseService.subUsers().

  • Method Details

    • add

      public License add(String key, List<SubUser> subUsers) throws SentinelException
      Adds sub-users to a license.
      Parameters:
      key - the license key
      subUsers - the sub-users to add
      Returns:
      the updated license
      Throws:
      SentinelException - if a network or API error occurs
    • remove

      public License remove(String key, List<SubUser> subUsers) throws SentinelException
      Removes sub-users from a license.

      Uses POST instead of DELETE because the request body is structured.

      Parameters:
      key - the license key
      subUsers - the sub-users to remove
      Returns:
      the updated license
      Throws:
      SentinelException - if a network or API error occurs