Class ClientsEntity

java.lang.Object
com.auth0.client.mgmt.ClientsEntity

public class ClientsEntity extends Object
Class that provides an implementation of the Application methods of the Management API as defined in https://auth0.com/docs/api/management/v2#!/Clients

This class is not thread-safe.

See Also:
ManagementAPI
  • Field Details

    • client

      protected final okhttp3.OkHttpClient client
    • baseUrl

      protected final okhttp3.HttpUrl baseUrl
    • apiToken

      protected final String apiToken
  • Method Details

    • list

      @Deprecated public Request<List<Client>> list()
      Deprecated.
      Calling this method will soon stop returning the complete list of clients and instead, limit to the first page of results. Please use list(ClientFilter) instead as it provides pagination support.
      Request all the Applications. A token with scope read:clients is needed. If you also need the client_secret and encryption_key attributes the token must have read:client_keys scope. See https://auth0.com/docs/api/management/v2#!/Clients/get_clients
      Returns:
      a Request to execute.
    • list

      public Request<ClientsPage> list(ClientFilter filter)
      Request all the Applications. A token with scope read:clients is needed. If you also need the client_secret and encryption_key attributes the token must have read:client_keys scope. See https://auth0.com/docs/api/management/v2#!/Clients/get_clients
      Parameters:
      filter - the filter to use. Can be null.
      Returns:
      a Request to execute.
    • get

      public Request<Client> get(String clientId)
      Request an Application. A token with scope read:clients is needed. If you also need the client_secret and encryption_key attributes the token must have read:client_keys scope. See https://auth0.com/docs/api/management/v2#!/Clients/get_clients_by_id
      Parameters:
      clientId - the application's client id.
      Returns:
      a Request to execute.
    • create

      public Request<Client> create(Client client)
      Create a new Application. A token with scope create:clients is needed. See https://auth0.com/docs/api/management/v2#!/Clients/post_clients
      Parameters:
      client - the application data to set.
      Returns:
      a Request to execute.
    • delete

      public Request delete(String clientId)
      Delete an existing Application. A token with scope delete:clients is needed. See https://auth0.com/docs/api/management/v2#!/Clients/delete_clients_by_id
      Parameters:
      clientId - the application's client id.
      Returns:
      a Request to execute.
    • update

      public Request<Client> update(String clientId, Client client)
      Update an existing Application. A token with scope update:clients is needed. If you also need to update the client_secret and encryption_key attributes the token must have update:client_keys scope. See https://auth0.com/docs/api/management/v2#!/Clients/patch_clients_by_id
      Parameters:
      clientId - the application's client id.
      client - the application data to set.
      Returns:
      a Request to execute.
    • rotateSecret

      public Request<Client> rotateSecret(String clientId)
      Rotates an Application's client secret. A token with scope update:client_keys is needed. Note that the generated secret is NOT base64 encoded. See https://auth0.com/docs/api/management/v2#!/Clients/post_rotate_secret
      Parameters:
      clientId - the application's client id.
      Returns:
      a Request to execute.