Class JobsEntity

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

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

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

    • get

      public Request<Job> get(String jobId)
      Request a Job. A token with scope create:users is needed. See https://auth0.com/docs/api/management/v2#!/Jobs/get_jobs_by_id.
      Parameters:
      jobId - the id of the job to retrieve.
      Returns:
      a Request to execute.
    • sendVerificationEmail

      public Request<Job> sendVerificationEmail(String userId, String clientId)
      Sends an Email Verification. A token with scope update:users is needed. See https://auth0.com/docs/api/management/v2#!/Jobs/post_verification_email.
      Parameters:
      userId - The user_id of the user to whom the email will be sent.
      clientId - The id of the client, if not provided the global one will be used.
      Returns:
      a Request to execute.
      See Also:
      sendVerificationEmail(String, String, EmailVerificationIdentity)
    • sendVerificationEmail

      public Request<Job> sendVerificationEmail(String userId, String clientId, EmailVerificationIdentity emailVerificationIdentity)
      Sends an Email Verification. A token with scope update:users is needed. See https://auth0.com/docs/api/management/v2#!/Jobs/post_verification_email.
      Parameters:
      userId - The user_id of the user to whom the email will be sent.
      clientId - The id of the client, if not provided the global one will be used.
      emailVerificationIdentity - The identity of the user. Required to verify primary identities when using social, enterprise, or passwordless connections. It is also required to verify secondary identities.
      Returns:
      a Request to execute.
      See Also:
      sendVerificationEmail(String, String)
    • sendVerificationEmail

      public Request<Job> sendVerificationEmail(String userId, String clientId, EmailVerificationIdentity emailVerificationIdentity, String orgId)
      Sends an Email Verification. A token with scope update:users is needed. See https://auth0.com/docs/api/management/v2#!/Jobs/post_verification_email.
      Parameters:
      userId - The user_id of the user to whom the email will be sent.
      clientId - The id of the client, if not provided the global one will be used.
      emailVerificationIdentity - The identity of the user. Required to verify primary identities when using social, enterprise, or passwordless connections. It is also required to verify secondary identities.
      orgId - The organization ID. If provided, the organization_id and organization_name will be included as query arguments in the link back to the application.
      Returns:
      a Request to execute.
      See Also:
      sendVerificationEmail(String, String)
    • exportUsers

      public Request<Job> exportUsers(String connectionId, UsersExportFilter filter)
      Requests a Users Exports job. A token with scope read:users is needed. See https://auth0.com/docs/api/management/v2#!/Jobs/post_users_exports. See https://auth0.com/docs/users/guides/bulk-user-exports.
      Parameters:
      connectionId - The id of the connection to export the users from.
      filter - the filter to use. Can be null.
      Returns:
      a Request to execute.
    • importUsers

      public Request<Job> importUsers(String connectionId, File users, UsersImportOptions options)
      Requests a Users Imports job. A token with scope write:users is needed. See https://auth0.com/docs/api/management/v2#!/Jobs/post_users_imports. See https://auth0.com/docs/users/guides/bulk-user-imports.
      Parameters:
      connectionId - The id of the connection to import the users to.
      users - The users file. Must have an array with the users' information in JSON format.
      options - Optional parameters to set. Can be null.
      Returns:
      a Request to execute.