GuardianManager

management. GuardianManager

Abstracts interaction with the Guardian endpoint.

Constructor

new GuardianManager(options)

Source:
Parameters:
Name Type Description
options Object

The client options.

Name Type Attributes Description
baseUrl String

The URL of the API.

headers Object <optional>

Headers to be included in all requests.

retry Object <optional>

Retry Policy Config

Members

(inner) guardianEnrollmentsAuth0RestClient :external:RestClient

Provides an abstraction layer for retrieving Guardian enrollments.

Source:
Type:

(inner) guardianFactorsAuth0RestClient :external:RestClient

Provides an abstraction layer for retrieving Guardian factors.

Source:
Type:

(inner) guardianFactorsProvidersAuth0RestClient :external:RestClient

Provides an abstraction layer for retrieving Guardian factor providers.

Source:
Type:

(inner) guardianFactorsTemplatesAuth0RestClient :external:RestClient

Provides an abstraction layer for retrieving Guardian factors.

Source:
Type:

(inner) guardianTicketsAuth0RestClient :external:RestClient

Provides an abstraction layer for retrieving Guardian tickets.

Source:
Type:

Methods

createEnrollmentTicket(cbopt) → {Promise|undefined}

Create a Guardian enrollment ticket.

Source:
Parameters:
Name Type Attributes Description
cb function <optional>

Callback function.

Returns:
Type:
Promise | undefined
Example
management.guardian.createEnrollmentTicket(function (err, ticket) {
  console.log(ticket);
});

deleteGuardianEnrollment(data, cbopt) → {Promise|undefined}

Delete a Guardian enrollment.

Source:
Parameters:
Name Type Attributes Description
data Object

The user data object.

Name Type Description
id String

The user id.

cb function <optional>

Callback function.

Returns:
Type:
Promise | undefined
Example
management.guardian.deleteGuardianEnrollment({ id: ENROLLMENT_ID }, function (err, enrollments) {
  console.log(enrollments);
});

getGuardianEnrollment(data, cbopt) → {Promise|undefined}

Get a single Guardian enrollment.

Source:
Parameters:
Name Type Attributes Description
data Object

The user data object.

Name Type Description
id String

The user id.

cb function <optional>

Callback function.

Returns:
Type:
Promise | undefined
Example
management.guardian.getGuardianEnrollment({ id: ENROLLMENT_ID }, function (err, enrollment) {
  console.log(enrollment);
});