Class: FusionAuth::FusionAuthClient
- Inherits:
-
Object
- Object
- FusionAuth::FusionAuthClient
- Defined in:
- lib/fusionauth/fusionauth_client.rb
Overview
This class is the the Ruby client library for the FusionAuth CIAM Platform https://fusionauth.io
Each method on this class calls one of the APIs for FusionAuth. In most cases, the methods will take either a Hash, an OpenStruct or any object that can be safely converted to JSON that conforms to the FusionAuth API interface. Likewise, most methods will return an OpenStruct that contains the response JSON from FusionAuth.
noinspection RubyInstanceMethodNamingConvention,RubyTooManyMethodsInspection,RubyParameterNamingConvention
Instance Attribute Summary collapse
-
#api_key ⇒ Object
Returns the value of attribute api_key.
-
#base_url ⇒ Object
Returns the value of attribute base_url.
-
#connect_timeout ⇒ Object
Returns the value of attribute connect_timeout.
-
#read_timeout ⇒ Object
Returns the value of attribute read_timeout.
-
#tenant_id ⇒ Object
Returns the value of attribute tenant_id.
Instance Method Summary collapse
-
#action_user(request) ⇒ FusionAuth::ClientResponse
Takes an action on a user.
-
#activate_reactor(request) ⇒ FusionAuth::ClientResponse
Activates the FusionAuth Reactor using a license Id and optionally a license text (for air-gapped deployments).
-
#add_user_to_family(family_id, request) ⇒ FusionAuth::ClientResponse
Adds a user to an existing family.
-
#approve_device(client_id, client_secret, token, user_code) ⇒ FusionAuth::ClientResponse
Approve a device grant.
-
#approve_device_with_request(request) ⇒ FusionAuth::ClientResponse
Approve a device grant.
-
#cancel_action(action_id, request) ⇒ FusionAuth::ClientResponse
Cancels the user action.
-
#change_password(change_password_id, request) ⇒ FusionAuth::ClientResponse
Changes a user’s password using the change password Id.
-
#change_password_by_identity(request) ⇒ FusionAuth::ClientResponse
Changes a user’s password using their identity (loginId and password).
-
#change_password_by_jwt(encoded_jwt, request) ⇒ FusionAuth::ClientResponse
deprecated
Deprecated.
This method has been renamed to change_password_using_jwt, use that method instead.
-
#change_password_using_jwt(encoded_jwt, request) ⇒ FusionAuth::ClientResponse
Changes a user’s password using their access token (JWT) instead of the changePasswordId A common use case for this method will be if you want to allow the user to change their own password.
-
#check_change_password_using_id(change_password_id) ⇒ FusionAuth::ClientResponse
Check to see if the user must obtain a Trust Token Id in order to complete a change password request.
-
#check_change_password_using_id_and_ip_address(change_password_id, ip_address) ⇒ FusionAuth::ClientResponse
Check to see if the user must obtain a Trust Token Id in order to complete a change password request.
-
#check_change_password_using_jwt(encoded_jwt) ⇒ FusionAuth::ClientResponse
Check to see if the user must obtain a Trust Token Id in order to complete a change password request.
-
#check_change_password_using_jwt_and_ip_address(encoded_jwt, ip_address) ⇒ FusionAuth::ClientResponse
Check to see if the user must obtain a Trust Token Id in order to complete a change password request.
-
#check_change_password_using_login_id(login_id) ⇒ FusionAuth::ClientResponse
Check to see if the user must obtain a Trust Request Id in order to complete a change password request.
-
#check_change_password_using_login_id_and_ip_address(login_id, ip_address) ⇒ FusionAuth::ClientResponse
Check to see if the user must obtain a Trust Request Id in order to complete a change password request.
-
#check_change_password_using_login_id_and_login_id_types(login_id, login_id_types) ⇒ FusionAuth::ClientResponse
Check to see if the user must obtain a Trust Request Id in order to complete a change password request.
-
#check_change_password_using_login_id_and_login_id_types_and_ip_address(login_id, login_id_types, ip_address) ⇒ FusionAuth::ClientResponse
Check to see if the user must obtain a Trust Request Id in order to complete a change password request.
-
#client_credentials_grant(client_id, client_secret, scope) ⇒ FusionAuth::ClientResponse
Make a Client Credentials grant request to obtain an access token.
-
#client_credentials_grant_with_request(request) ⇒ FusionAuth::ClientResponse
Make a Client Credentials grant request to obtain an access token.
-
#comment_on_user(request) ⇒ FusionAuth::ClientResponse
Adds a comment to the user’s account.
-
#complete_verify_identity(request) ⇒ FusionAuth::ClientResponse
Completes verification of an identity using verification codes from the Verify Start API.
-
#complete_web_authn_assertion(request) ⇒ FusionAuth::ClientResponse
Complete a WebAuthn authentication ceremony by validating the signature against the previously generated challenge without logging the user in.
-
#complete_web_authn_login(request) ⇒ FusionAuth::ClientResponse
Complete a WebAuthn authentication ceremony by validating the signature against the previously generated challenge and then login the user in.
-
#complete_web_authn_registration(request) ⇒ FusionAuth::ClientResponse
Complete a WebAuthn registration ceremony by validating the client request and saving the new credential.
-
#create_api_key(key_id, request) ⇒ FusionAuth::ClientResponse
Creates an API key.
-
#create_application(application_id, request) ⇒ FusionAuth::ClientResponse
Creates an application.
-
#create_application_role(application_id, role_id, request) ⇒ FusionAuth::ClientResponse
Creates a new role for an application.
-
#create_audit_log(request) ⇒ FusionAuth::ClientResponse
Creates an audit log with the message and user name (usually an email).
-
#create_connector(connector_id, request) ⇒ FusionAuth::ClientResponse
Creates a connector.
-
#create_consent(consent_id, request) ⇒ FusionAuth::ClientResponse
Creates a user consent type.
-
#create_email_template(email_template_id, request) ⇒ FusionAuth::ClientResponse
Creates an email template.
-
#create_entity(entity_id, request) ⇒ FusionAuth::ClientResponse
Creates an Entity.
-
#create_entity_type(entity_type_id, request) ⇒ FusionAuth::ClientResponse
Creates a Entity Type.
-
#create_entity_type_permission(entity_type_id, permission_id, request) ⇒ FusionAuth::ClientResponse
Creates a new permission for an entity type.
-
#create_family(family_id, request) ⇒ FusionAuth::ClientResponse
Creates a family with the user Id in the request as the owner and sole member of the family.
-
#create_form(form_id, request) ⇒ FusionAuth::ClientResponse
Creates a form.
-
#create_form_field(field_id, request) ⇒ FusionAuth::ClientResponse
Creates a form field.
-
#create_group(group_id, request) ⇒ FusionAuth::ClientResponse
Creates a group.
-
#create_group_members(request) ⇒ FusionAuth::ClientResponse
Creates a member in a group.
-
#create_identity_provider(identity_provider_id, request) ⇒ FusionAuth::ClientResponse
Creates an identity provider.
-
#create_ip_access_control_list(access_control_list_id, request) ⇒ FusionAuth::ClientResponse
Creates an IP Access Control List.
-
#create_lambda(lambda_id, request) ⇒ FusionAuth::ClientResponse
Creates a Lambda.
-
#create_message_template(message_template_id, request) ⇒ FusionAuth::ClientResponse
Creates an message template.
-
#create_messenger(messenger_id, request) ⇒ FusionAuth::ClientResponse
Creates a messenger.
-
#create_o_auth_scope(application_id, scope_id, request) ⇒ FusionAuth::ClientResponse
Creates a new custom OAuth scope for an application.
-
#create_tenant(tenant_id, request) ⇒ FusionAuth::ClientResponse
Creates a tenant.
-
#create_tenant_manager_identity_provider_type_configuration(type, request) ⇒ FusionAuth::ClientResponse
Creates a tenant manager identity provider type configuration for the given identity provider type.
-
#create_theme(theme_id, request) ⇒ FusionAuth::ClientResponse
Creates a Theme.
-
#create_user(user_id, request) ⇒ FusionAuth::ClientResponse
Creates a user.
-
#create_user_action(user_action_id, request) ⇒ FusionAuth::ClientResponse
Creates a user action.
-
#create_user_action_reason(user_action_reason_id, request) ⇒ FusionAuth::ClientResponse
Creates a user reason.
-
#create_user_consent(user_consent_id, request) ⇒ FusionAuth::ClientResponse
Creates a single User consent.
-
#create_user_link(request) ⇒ FusionAuth::ClientResponse
Link an external user from a 3rd party identity provider to a FusionAuth user.
-
#create_webhook(webhook_id, request) ⇒ FusionAuth::ClientResponse
Creates a webhook.
-
#deactivate_application(application_id) ⇒ FusionAuth::ClientResponse
Deactivates the application with the given Id.
-
#deactivate_reactor ⇒ FusionAuth::ClientResponse
Deactivates the FusionAuth Reactor.
-
#deactivate_user(user_id) ⇒ FusionAuth::ClientResponse
Deactivates the user with the given Id.
-
#deactivate_user_action(user_action_id) ⇒ FusionAuth::ClientResponse
Deactivates the user action with the given Id.
-
#deactivate_users(user_ids) ⇒ FusionAuth::ClientResponse
deprecated
Deprecated.
This method has been renamed to deactivate_users_by_ids, use that method instead.
-
#deactivate_users_by_ids(user_ids) ⇒ FusionAuth::ClientResponse
Deactivates the users with the given Ids.
-
#delete_api_key(key_id) ⇒ FusionAuth::ClientResponse
Deletes the API key for the given Id.
-
#delete_application(application_id) ⇒ FusionAuth::ClientResponse
Hard deletes an application.
-
#delete_application_role(application_id, role_id) ⇒ FusionAuth::ClientResponse
Hard deletes an application role.
-
#delete_connector(connector_id) ⇒ FusionAuth::ClientResponse
Deletes the connector for the given Id.
-
#delete_consent(consent_id) ⇒ FusionAuth::ClientResponse
Deletes the consent for the given Id.
-
#delete_email_template(email_template_id) ⇒ FusionAuth::ClientResponse
Deletes the email template for the given Id.
-
#delete_entity(entity_id) ⇒ FusionAuth::ClientResponse
Deletes the Entity for the given Id.
-
#delete_entity_grant(entity_id, recipient_entity_id, user_id) ⇒ FusionAuth::ClientResponse
Deletes an Entity Grant for the given User or Entity.
-
#delete_entity_type(entity_type_id) ⇒ FusionAuth::ClientResponse
Deletes the Entity Type for the given Id.
-
#delete_entity_type_permission(entity_type_id, permission_id) ⇒ FusionAuth::ClientResponse
Hard deletes a permission.
-
#delete_form(form_id) ⇒ FusionAuth::ClientResponse
Deletes the form for the given Id.
-
#delete_form_field(field_id) ⇒ FusionAuth::ClientResponse
Deletes the form field for the given Id.
-
#delete_group(group_id) ⇒ FusionAuth::ClientResponse
Deletes the group for the given Id.
-
#delete_group_members(request) ⇒ FusionAuth::ClientResponse
Removes users as members of a group.
-
#delete_identity_provider(identity_provider_id) ⇒ FusionAuth::ClientResponse
Deletes the identity provider for the given Id.
-
#delete_ip_access_control_list(ip_access_control_list_id) ⇒ FusionAuth::ClientResponse
Deletes the IP Access Control List for the given Id.
-
#delete_key(key_id) ⇒ FusionAuth::ClientResponse
Deletes the key for the given Id.
-
#delete_lambda(lambda_id) ⇒ FusionAuth::ClientResponse
Deletes the lambda for the given Id.
-
#delete_message_template(message_template_id) ⇒ FusionAuth::ClientResponse
Deletes the message template for the given Id.
-
#delete_messenger(messenger_id) ⇒ FusionAuth::ClientResponse
Deletes the messenger for the given Id.
-
#delete_o_auth_scope(application_id, scope_id) ⇒ FusionAuth::ClientResponse
Hard deletes a custom OAuth scope.
-
#delete_registration(user_id, application_id) ⇒ FusionAuth::ClientResponse
Deletes the user registration for the given user and application.
-
#delete_registration_with_request(user_id, application_id, request) ⇒ FusionAuth::ClientResponse
Deletes the user registration for the given user and application along with the given JSON body that contains the event information.
-
#delete_tenant(tenant_id) ⇒ FusionAuth::ClientResponse
Deletes the tenant based on the given Id on the URL.
-
#delete_tenant_async(tenant_id) ⇒ FusionAuth::ClientResponse
Deletes the tenant for the given Id asynchronously.
-
#delete_tenant_manager_identity_provider_type_configuration(type) ⇒ FusionAuth::ClientResponse
Deletes the tenant manager identity provider type configuration for the given identity provider type.
-
#delete_tenant_with_request(tenant_id, request) ⇒ FusionAuth::ClientResponse
Deletes the tenant based on the given request (sent to the API as JSON).
-
#delete_theme(theme_id) ⇒ FusionAuth::ClientResponse
Deletes the theme for the given Id.
-
#delete_user(user_id) ⇒ FusionAuth::ClientResponse
Deletes the user for the given Id.
-
#delete_user_action(user_action_id) ⇒ FusionAuth::ClientResponse
Deletes the user action for the given Id.
-
#delete_user_action_reason(user_action_reason_id) ⇒ FusionAuth::ClientResponse
Deletes the user action reason for the given Id.
-
#delete_user_link(identity_provider_id, identity_provider_user_id, user_id) ⇒ FusionAuth::ClientResponse
Remove an existing link that has been made from a 3rd party identity provider to a FusionAuth user.
-
#delete_user_with_request(user_id, request) ⇒ FusionAuth::ClientResponse
Deletes the user based on the given request (sent to the API as JSON).
-
#delete_users(request) ⇒ FusionAuth::ClientResponse
deprecated
Deprecated.
This method has been renamed to delete_users_by_query, use that method instead.
-
#delete_users_by_query(request) ⇒ FusionAuth::ClientResponse
Deletes the users with the given Ids, or users matching the provided JSON query or queryString.
-
#delete_web_authn_credential(id) ⇒ FusionAuth::ClientResponse
Deletes the WebAuthn credential for the given Id.
-
#delete_web_authn_credentials_for_user(user_id) ⇒ FusionAuth::ClientResponse
Deletes all of the WebAuthn credentials for the given User Id.
-
#delete_webhook(webhook_id) ⇒ FusionAuth::ClientResponse
Deletes the webhook for the given Id.
-
#device_authorize(client_id, client_secret, scope) ⇒ FusionAuth::ClientResponse
Start the Device Authorization flow using form-encoded parameters.
-
#device_authorize_with_request(request) ⇒ FusionAuth::ClientResponse
Start the Device Authorization flow using a request body.
-
#disable_two_factor(user_id, method_id, code) ⇒ FusionAuth::ClientResponse
Disable two-factor authentication for a user.
-
#disable_two_factor_with_request(user_id, request) ⇒ FusionAuth::ClientResponse
Disable two-factor authentication for a user using a JSON body rather than URL parameters.
-
#enable_two_factor(user_id, request) ⇒ FusionAuth::ClientResponse
Enable two-factor authentication for a user.
-
#exchange_o_auth_code_for_access_token(code, client_id, client_secret, redirect_uri) ⇒ FusionAuth::ClientResponse
Exchanges an OAuth authorization code for an access token.
-
#exchange_o_auth_code_for_access_token_using_pkce(code, client_id, client_secret, redirect_uri, code_verifier) ⇒ FusionAuth::ClientResponse
Exchanges an OAuth authorization code and code_verifier for an access token.
-
#exchange_o_auth_code_for_access_token_using_pkce_with_request(request) ⇒ FusionAuth::ClientResponse
Exchanges an OAuth authorization code and code_verifier for an access token.
-
#exchange_o_auth_code_for_access_token_with_request(request) ⇒ FusionAuth::ClientResponse
Exchanges an OAuth authorization code for an access token.
-
#exchange_refresh_token_for_access_token(refresh_token, client_id, client_secret, scope, user_code) ⇒ FusionAuth::ClientResponse
Exchange a Refresh Token for an Access Token.
-
#exchange_refresh_token_for_access_token_with_request(request) ⇒ FusionAuth::ClientResponse
Exchange a Refresh Token for an Access Token.
-
#exchange_refresh_token_for_jwt(request) ⇒ FusionAuth::ClientResponse
Exchange a refresh token for a new JWT.
-
#exchange_user_credentials_for_access_token(username, password, client_id, client_secret, scope, user_code) ⇒ FusionAuth::ClientResponse
Exchange User Credentials for a Token.
-
#exchange_user_credentials_for_access_token_with_request(request) ⇒ FusionAuth::ClientResponse
Exchange User Credentials for a Token.
-
#forgot_password(request) ⇒ FusionAuth::ClientResponse
Begins the forgot password sequence, which kicks off an email to the user so that they can reset their password.
-
#generate_email_verification_id(email) ⇒ FusionAuth::ClientResponse
Generate a new Email Verification Id to be used with the Verify Email API.
-
#generate_key(key_id, request) ⇒ FusionAuth::ClientResponse
Generate a new RSA or EC key pair or an HMAC secret.
-
#generate_registration_verification_id(email, application_id) ⇒ FusionAuth::ClientResponse
Generate a new Application Registration Verification Id to be used with the Verify Registration API.
-
#generate_two_factor_recovery_codes(user_id) ⇒ FusionAuth::ClientResponse
Generate two-factor recovery codes for a user.
-
#generate_two_factor_secret ⇒ FusionAuth::ClientResponse
Generate a Two Factor secret that can be used to enable Two Factor authentication for a User.
-
#generate_two_factor_secret_using_jwt(encoded_jwt) ⇒ FusionAuth::ClientResponse
Generate a Two Factor secret that can be used to enable Two Factor authentication for a User.
-
#identity_provider_login(request) ⇒ FusionAuth::ClientResponse
Handles login via third-parties including Social login, external OAuth and OpenID Connect, and other login systems.
-
#import_key(key_id, request) ⇒ FusionAuth::ClientResponse
Import an existing RSA or EC key pair or an HMAC secret.
-
#import_refresh_tokens(request) ⇒ FusionAuth::ClientResponse
Bulk imports refresh tokens.
-
#import_users(request) ⇒ FusionAuth::ClientResponse
Bulk imports users.
-
#import_web_authn_credential(request) ⇒ FusionAuth::ClientResponse
Import a WebAuthn credential.
-
#initialize(api_key, base_url) ⇒ FusionAuthClient
constructor
A new instance of FusionAuthClient.
-
#introspect_access_token(client_id, token) ⇒ FusionAuth::ClientResponse
Inspect an access token issued as the result of the User based grant such as the Authorization Code Grant, Implicit Grant, the User Credentials Grant or the Refresh Grant.
-
#introspect_access_token_with_request(request) ⇒ FusionAuth::ClientResponse
Inspect an access token issued as the result of the User based grant such as the Authorization Code Grant, Implicit Grant, the User Credentials Grant or the Refresh Grant.
-
#introspect_client_credentials_access_token(token) ⇒ FusionAuth::ClientResponse
Inspect an access token issued as the result of the Client Credentials Grant.
-
#introspect_client_credentials_access_token_with_request(request) ⇒ FusionAuth::ClientResponse
Inspect an access token issued as the result of the Client Credentials Grant.
-
#issue_jwt(application_id, encoded_jwt, refresh_token) ⇒ FusionAuth::ClientResponse
Issue a new access token (JWT) for the requested Application after ensuring the provided JWT is valid.
-
#login(request) ⇒ FusionAuth::ClientResponse
Authenticates a user to FusionAuth.
-
#login_ping(user_id, application_id, caller_ip_address) ⇒ FusionAuth::ClientResponse
Sends a ping to FusionAuth indicating that the user was automatically logged into an application.
-
#login_ping_with_request(request) ⇒ FusionAuth::ClientResponse
Sends a ping to FusionAuth indicating that the user was automatically logged into an application.
-
#logout(global, refresh_token) ⇒ FusionAuth::ClientResponse
The Logout API is intended to be used to remove the refresh token and access token cookies if they exist on the client and revoke the refresh token stored.
-
#logout_with_request(request) ⇒ FusionAuth::ClientResponse
The Logout API is intended to be used to remove the refresh token and access token cookies if they exist on the client and revoke the refresh token stored.
-
#lookup_identity_provider(domain) ⇒ FusionAuth::ClientResponse
Retrieves any global identity providers for the given domain.
-
#lookup_identity_provider_by_tenant_id(domain, tenant_id) ⇒ FusionAuth::ClientResponse
Retrieves the identity provider for the given domain and tenantId.
-
#modify_action(action_id, request) ⇒ FusionAuth::ClientResponse
Modifies a temporal user action by changing the expiration of the action and optionally adding a comment to the action.
-
#passwordless_login(request) ⇒ FusionAuth::ClientResponse
Complete a login request using a passwordless code.
-
#patch_api_key(key_id, request) ⇒ FusionAuth::ClientResponse
Updates an API key with the given Id.
-
#patch_application(application_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the application with the given Id.
-
#patch_application_role(application_id, role_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the application role with the given Id for the application.
-
#patch_connector(connector_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the connector with the given Id.
-
#patch_consent(consent_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the consent with the given Id.
-
#patch_email_template(email_template_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the email template with the given Id.
-
#patch_entity(entity_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the Entity with the given Id.
-
#patch_entity_type(entity_type_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the Entity Type with the given Id.
-
#patch_entity_type_permission(entity_type_id, permission_id, request) ⇒ FusionAuth::ClientResponse
Patches the permission with the given Id for the entity type.
-
#patch_form(form_id, request) ⇒ FusionAuth::ClientResponse
Patches the form with the given Id.
-
#patch_form_field(field_id, request) ⇒ FusionAuth::ClientResponse
Patches the form field with the given Id.
-
#patch_group(group_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the group with the given Id.
-
#patch_identity_provider(identity_provider_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the identity provider with the given Id.
-
#patch_integrations(request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the available integrations.
-
#patch_ip_access_control_list(access_control_list_id, request) ⇒ FusionAuth::ClientResponse
Update the IP Access Control List with the given Id.
-
#patch_lambda(lambda_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the lambda with the given Id.
-
#patch_message_template(message_template_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the message template with the given Id.
-
#patch_messenger(messenger_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the messenger with the given Id.
-
#patch_o_auth_scope(application_id, scope_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the custom OAuth scope with the given Id for the application.
-
#patch_registration(user_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the registration for the user with the given Id and the application defined in the request.
-
#patch_system_configuration(request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the system configuration.
-
#patch_tenant(tenant_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the tenant with the given Id.
-
#patch_tenant_manager_configuration(request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the Tenant Manager configuration.
-
#patch_tenant_manager_identity_provider_type_configuration(type, request) ⇒ FusionAuth::ClientResponse
Patches the tenant manager identity provider type configuration for the given identity provider type.
-
#patch_theme(theme_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the theme with the given Id.
-
#patch_user(user_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the user with the given Id.
-
#patch_user_action(user_action_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the user action with the given Id.
-
#patch_user_action_reason(user_action_reason_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the user action reason with the given Id.
-
#patch_user_consent(user_consent_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, a single User consent by Id.
-
#patch_webhook(webhook_id, request) ⇒ FusionAuth::ClientResponse
Patches the webhook with the given Id.
-
#reactivate_application(application_id) ⇒ FusionAuth::ClientResponse
Reactivates the application with the given Id.
-
#reactivate_user(user_id) ⇒ FusionAuth::ClientResponse
Reactivates the user with the given Id.
-
#reactivate_user_action(user_action_id) ⇒ FusionAuth::ClientResponse
Reactivates the user action with the given Id.
-
#reconcile_jwt(request) ⇒ FusionAuth::ClientResponse
Reconcile a User to FusionAuth using JWT issued from another Identity Provider.
-
#refresh_entity_search_index ⇒ FusionAuth::ClientResponse
Request a refresh of the Entity search index.
-
#refresh_user_search_index ⇒ FusionAuth::ClientResponse
Request a refresh of the User search index.
-
#regenerate_reactor_keys ⇒ FusionAuth::ClientResponse
Regenerates any keys that are used by the FusionAuth Reactor.
-
#register(user_id, request) ⇒ FusionAuth::ClientResponse
Registers a user for an application.
-
#reindex(request) ⇒ FusionAuth::ClientResponse
Requests Elasticsearch to delete and rebuild the index for FusionAuth users or entities.
-
#remove_user_from_family(family_id, user_id) ⇒ FusionAuth::ClientResponse
Removes a user from the family with the given Id.
-
#resend_email_verification(email) ⇒ FusionAuth::ClientResponse
Re-sends the verification email to the user.
-
#resend_email_verification_with_application_template(application_id, email) ⇒ FusionAuth::ClientResponse
Re-sends the verification email to the user.
-
#resend_registration_verification(email, application_id) ⇒ FusionAuth::ClientResponse
Re-sends the application registration verification email to the user.
-
#retrieve_action(action_id) ⇒ FusionAuth::ClientResponse
Retrieves a single action log (the log of a user action that was taken on a user previously) for the given Id.
-
#retrieve_actions(user_id) ⇒ FusionAuth::ClientResponse
Retrieves all the actions for the user with the given Id.
-
#retrieve_actions_preventing_login(user_id) ⇒ FusionAuth::ClientResponse
Retrieves all the actions for the user with the given Id that are currently preventing the User from logging in.
-
#retrieve_active_actions(user_id) ⇒ FusionAuth::ClientResponse
Retrieves all the actions for the user with the given Id that are currently active.
-
#retrieve_api_key(key_id) ⇒ FusionAuth::ClientResponse
Retrieves an authentication API key for the given Id.
-
#retrieve_application(application_id) ⇒ FusionAuth::ClientResponse
Retrieves the application for the given Id or all the applications if the Id is null.
-
#retrieve_applications ⇒ FusionAuth::ClientResponse
Retrieves all the applications.
-
#retrieve_audit_log(audit_log_id) ⇒ FusionAuth::ClientResponse
Retrieves a single audit log for the given Id.
-
#retrieve_connector(connector_id) ⇒ FusionAuth::ClientResponse
Retrieves the connector with the given Id.
-
#retrieve_connectors ⇒ FusionAuth::ClientResponse
Retrieves all the connectors.
-
#retrieve_consent(consent_id) ⇒ FusionAuth::ClientResponse
Retrieves the Consent for the given Id.
-
#retrieve_consents ⇒ FusionAuth::ClientResponse
Retrieves all the consent.
-
#retrieve_daily_active_report(application_id, start, _end) ⇒ FusionAuth::ClientResponse
Retrieves the daily active user report between the two instants.
-
#retrieve_email_template(email_template_id) ⇒ FusionAuth::ClientResponse
Retrieves the email template for the given Id.
-
#retrieve_email_template_preview(request) ⇒ FusionAuth::ClientResponse
Creates a preview of the email template provided in the request.
-
#retrieve_email_templates ⇒ FusionAuth::ClientResponse
Retrieves all the email templates.
-
#retrieve_entity(entity_id) ⇒ FusionAuth::ClientResponse
Retrieves the Entity for the given Id.
-
#retrieve_entity_grant(entity_id, recipient_entity_id, user_id) ⇒ FusionAuth::ClientResponse
Retrieves an Entity Grant for the given Entity and User/Entity.
-
#retrieve_entity_type(entity_type_id) ⇒ FusionAuth::ClientResponse
Retrieves the Entity Type for the given Id.
-
#retrieve_entity_types ⇒ FusionAuth::ClientResponse
Retrieves all the Entity Types.
-
#retrieve_event_log(event_log_id) ⇒ FusionAuth::ClientResponse
Retrieves a single event log for the given Id.
-
#retrieve_families(user_id) ⇒ FusionAuth::ClientResponse
Retrieves all the families that a user belongs to.
-
#retrieve_family_members_by_family_id(family_id) ⇒ FusionAuth::ClientResponse
Retrieves all the members of a family by the unique Family Id.
-
#retrieve_form(form_id) ⇒ FusionAuth::ClientResponse
Retrieves the form with the given Id.
-
#retrieve_form_field(field_id) ⇒ FusionAuth::ClientResponse
Retrieves the form field with the given Id.
-
#retrieve_form_fields ⇒ FusionAuth::ClientResponse
Retrieves all the forms fields.
-
#retrieve_forms ⇒ FusionAuth::ClientResponse
Retrieves all the forms.
-
#retrieve_group(group_id) ⇒ FusionAuth::ClientResponse
Retrieves the group for the given Id.
-
#retrieve_groups ⇒ FusionAuth::ClientResponse
Retrieves all the groups.
-
#retrieve_identity_provider(identity_provider_id) ⇒ FusionAuth::ClientResponse
Retrieves the identity provider for the given Id or all the identity providers if the Id is null.
-
#retrieve_identity_provider_by_type(type) ⇒ FusionAuth::ClientResponse
Retrieves one or more identity provider for the given type.
-
#retrieve_identity_provider_connection_test_results(connection_test_id) ⇒ FusionAuth::ClientResponse
Retrieves the results for an identity provider connection test.
-
#retrieve_identity_providers ⇒ FusionAuth::ClientResponse
Retrieves all the identity providers.
-
#retrieve_inactive_actions(user_id) ⇒ FusionAuth::ClientResponse
Retrieves all the actions for the user with the given Id that are currently inactive.
-
#retrieve_inactive_applications ⇒ FusionAuth::ClientResponse
Retrieves all the applications that are currently inactive.
-
#retrieve_inactive_user_actions ⇒ FusionAuth::ClientResponse
Retrieves all the user actions that are currently inactive.
-
#retrieve_integration ⇒ FusionAuth::ClientResponse
Retrieves the available integrations.
-
#retrieve_ip_access_control_list(ip_access_control_list_id) ⇒ FusionAuth::ClientResponse
Retrieves the IP Access Control List with the given Id.
-
#retrieve_json_web_key_set ⇒ FusionAuth::ClientResponse
Returns public keys used by FusionAuth to cryptographically verify JWTs using the JSON Web Key format.
-
#retrieve_jwt_public_key(key_id) ⇒ FusionAuth::ClientResponse
Retrieves the Public Key configured for verifying JSON Web Tokens (JWT) by the key Id (kid).
-
#retrieve_jwt_public_key_by_application_id(application_id) ⇒ FusionAuth::ClientResponse
Retrieves the Public Key configured for verifying the JSON Web Tokens (JWT) issued by the Login API by the Application Id.
-
#retrieve_jwt_public_keys ⇒ FusionAuth::ClientResponse
Retrieves all Public Keys configured for verifying JSON Web Tokens (JWT).
-
#retrieve_key(key_id) ⇒ FusionAuth::ClientResponse
Retrieves the key for the given Id.
-
#retrieve_keys ⇒ FusionAuth::ClientResponse
Retrieves all the keys.
-
#retrieve_lambda(lambda_id) ⇒ FusionAuth::ClientResponse
Retrieves the lambda for the given Id.
-
#retrieve_lambdas ⇒ FusionAuth::ClientResponse
Retrieves all the lambdas.
-
#retrieve_lambdas_by_type(type) ⇒ FusionAuth::ClientResponse
Retrieves all the lambdas for the provided type.
-
#retrieve_login_report(application_id, start, _end) ⇒ FusionAuth::ClientResponse
Retrieves the login report between the two instants.
-
#retrieve_message_template(message_template_id) ⇒ FusionAuth::ClientResponse
Retrieves the message template for the given Id.
-
#retrieve_message_template_preview(request) ⇒ FusionAuth::ClientResponse
Creates a preview of the message template provided in the request, normalized to a given locale.
-
#retrieve_message_templates ⇒ FusionAuth::ClientResponse
Retrieves all the message templates.
-
#retrieve_messenger(messenger_id) ⇒ FusionAuth::ClientResponse
Retrieves the messenger with the given Id.
-
#retrieve_messengers ⇒ FusionAuth::ClientResponse
Retrieves all the messengers.
-
#retrieve_monthly_active_report(application_id, start, _end) ⇒ FusionAuth::ClientResponse
Retrieves the monthly active user report between the two instants.
-
#retrieve_o_auth_scope(application_id, scope_id) ⇒ FusionAuth::ClientResponse
Retrieves a custom OAuth scope.
-
#retrieve_oauth_configuration(application_id) ⇒ FusionAuth::ClientResponse
Retrieves the Oauth2 configuration for the application for the given Application Id.
-
#retrieve_open_id_configuration ⇒ FusionAuth::ClientResponse
Returns the well known OpenID Configuration JSON document.
-
#retrieve_password_validation_rules ⇒ FusionAuth::ClientResponse
Retrieves the password validation rules for a specific tenant.
-
#retrieve_password_validation_rules_with_tenant_id(tenant_id) ⇒ FusionAuth::ClientResponse
Retrieves the password validation rules for a specific tenant.
-
#retrieve_pending_children(parent_email) ⇒ FusionAuth::ClientResponse
Retrieves all the children for the given parent email address.
-
#retrieve_pending_link(pending_link_id, user_id) ⇒ FusionAuth::ClientResponse
Retrieve a pending identity provider link.
-
#retrieve_reactor_metrics ⇒ FusionAuth::ClientResponse
Retrieves the FusionAuth Reactor metrics.
-
#retrieve_reactor_status ⇒ FusionAuth::ClientResponse
Retrieves the FusionAuth Reactor status.
-
#retrieve_recent_logins(offset, limit) ⇒ FusionAuth::ClientResponse
Retrieves the last number of login records.
-
#retrieve_refresh_token_by_id(token_id) ⇒ FusionAuth::ClientResponse
Retrieves a single refresh token by unique Id.
-
#retrieve_refresh_tokens(user_id) ⇒ FusionAuth::ClientResponse
Retrieves the refresh tokens that belong to the user with the given Id.
-
#retrieve_registration(user_id, application_id) ⇒ FusionAuth::ClientResponse
Retrieves the user registration for the user with the given Id and the given application Id.
-
#retrieve_registration_report(application_id, start, _end) ⇒ FusionAuth::ClientResponse
Retrieves the registration report between the two instants.
-
#retrieve_reindex_status ⇒ FusionAuth::ClientResponse
Retrieve the status of a re-index process.
-
#retrieve_system_configuration ⇒ FusionAuth::ClientResponse
Retrieves the system configuration.
-
#retrieve_system_health ⇒ FusionAuth::ClientResponse
Retrieves the FusionAuth system health.
-
#retrieve_system_status ⇒ FusionAuth::ClientResponse
Retrieves the FusionAuth system status.
-
#retrieve_system_status_using_api_key ⇒ FusionAuth::ClientResponse
Retrieves the FusionAuth system status using an API key.
-
#retrieve_tenant(tenant_id) ⇒ FusionAuth::ClientResponse
Retrieves the tenant for the given Id.
-
#retrieve_tenant_manager_configuration ⇒ FusionAuth::ClientResponse
Retrieves the Tenant Manager configuration.
-
#retrieve_tenants ⇒ FusionAuth::ClientResponse
Retrieves all the tenants.
-
#retrieve_theme(theme_id) ⇒ FusionAuth::ClientResponse
Retrieves the theme for the given Id.
-
#retrieve_themes ⇒ FusionAuth::ClientResponse
Retrieves all the themes.
-
#retrieve_total_report ⇒ FusionAuth::ClientResponse
Retrieves the totals report.
-
#retrieve_total_report_with_excludes(excludes) ⇒ FusionAuth::ClientResponse
Retrieves the totals report.
-
#retrieve_two_factor_recovery_codes(user_id) ⇒ FusionAuth::ClientResponse
Retrieve two-factor recovery codes for a user.
-
#retrieve_two_factor_status(user_id, application_id, two_factor_trust_id) ⇒ FusionAuth::ClientResponse
Retrieve a user’s two-factor status.
-
#retrieve_two_factor_status_with_request(request) ⇒ FusionAuth::ClientResponse
Retrieve a user’s two-factor status.
-
#retrieve_user(user_id) ⇒ FusionAuth::ClientResponse
Retrieves the user for the given Id.
-
#retrieve_user_action(user_action_id) ⇒ FusionAuth::ClientResponse
Retrieves the user action for the given Id.
-
#retrieve_user_action_reason(user_action_reason_id) ⇒ FusionAuth::ClientResponse
Retrieves the user action reason for the given Id.
-
#retrieve_user_action_reasons ⇒ FusionAuth::ClientResponse
Retrieves all the user action reasons.
-
#retrieve_user_actions ⇒ FusionAuth::ClientResponse
Retrieves all the user actions.
-
#retrieve_user_by_change_password_id(change_password_id) ⇒ FusionAuth::ClientResponse
Retrieves the user by a change password Id.
-
#retrieve_user_by_email(email) ⇒ FusionAuth::ClientResponse
Retrieves the user for the given email.
-
#retrieve_user_by_login_id(login_id) ⇒ FusionAuth::ClientResponse
Retrieves the user for the loginId.
-
#retrieve_user_by_login_id_with_login_id_types(login_id, login_id_types) ⇒ FusionAuth::ClientResponse
Retrieves the user for the loginId, using specific loginIdTypes.
-
#retrieve_user_by_username(username) ⇒ FusionAuth::ClientResponse
Retrieves the user for the given username.
-
#retrieve_user_by_verification_id(verification_id) ⇒ FusionAuth::ClientResponse
Retrieves the user by a verificationId.
-
#retrieve_user_code(client_id, client_secret, user_code) ⇒ FusionAuth::ClientResponse
Retrieve a user_code that is part of an in-progress Device Authorization Grant.
-
#retrieve_user_code_using_api_key(user_code) ⇒ FusionAuth::ClientResponse
Retrieve a user_code that is part of an in-progress Device Authorization Grant.
-
#retrieve_user_code_using_api_key_with_request(request) ⇒ FusionAuth::ClientResponse
Retrieve a user_code that is part of an in-progress Device Authorization Grant.
-
#retrieve_user_code_with_request(request) ⇒ FusionAuth::ClientResponse
Retrieve a user_code that is part of an in-progress Device Authorization Grant.
-
#retrieve_user_comments(user_id) ⇒ FusionAuth::ClientResponse
Retrieves all the comments for the user with the given Id.
-
#retrieve_user_consent(user_consent_id) ⇒ FusionAuth::ClientResponse
Retrieve a single User consent by Id.
-
#retrieve_user_consents(user_id) ⇒ FusionAuth::ClientResponse
Retrieves all the consents for a User.
-
#retrieve_user_info_from_access_token(encoded_jwt) ⇒ FusionAuth::ClientResponse
Call the UserInfo endpoint to retrieve User Claims from the access token issued by FusionAuth.
-
#retrieve_user_link(identity_provider_id, identity_provider_user_id, user_id) ⇒ FusionAuth::ClientResponse
Retrieve a single Identity Provider user (link).
-
#retrieve_user_links_by_user_id(identity_provider_id, user_id) ⇒ FusionAuth::ClientResponse
Retrieve all Identity Provider users (links) for the user.
-
#retrieve_user_login_report(application_id, user_id, start, _end) ⇒ FusionAuth::ClientResponse
Retrieves the login report between the two instants for a particular user by Id.
-
#retrieve_user_login_report_by_login_id(application_id, login_id, start, _end) ⇒ FusionAuth::ClientResponse
Retrieves the login report between the two instants for a particular user by login Id.
-
#retrieve_user_login_report_by_login_id_and_login_id_types(application_id, login_id, start, _end, login_id_types) ⇒ FusionAuth::ClientResponse
Retrieves the login report between the two instants for a particular user by login Id, using specific loginIdTypes.
-
#retrieve_user_recent_logins(user_id, offset, limit) ⇒ FusionAuth::ClientResponse
Retrieves the last number of login records for a user.
-
#retrieve_version ⇒ FusionAuth::ClientResponse
Retrieves the FusionAuth version string.
-
#retrieve_web_authn_credential(id) ⇒ FusionAuth::ClientResponse
Retrieves the WebAuthn credential for the given Id.
-
#retrieve_web_authn_credentials_for_user(user_id) ⇒ FusionAuth::ClientResponse
Retrieves all WebAuthn credentials for the given user.
-
#retrieve_webhook(webhook_id) ⇒ FusionAuth::ClientResponse
Retrieves the webhook for the given Id.
-
#retrieve_webhook_attempt_log(webhook_attempt_log_id) ⇒ FusionAuth::ClientResponse
Retrieves a single webhook attempt log for the given Id.
-
#retrieve_webhook_event_log(webhook_event_log_id) ⇒ FusionAuth::ClientResponse
Retrieves a single webhook event log for the given Id.
-
#retrieve_webhooks ⇒ FusionAuth::ClientResponse
Retrieves all the webhooks.
-
#revoke_refresh_token(token, user_id, application_id) ⇒ FusionAuth::ClientResponse
Revokes refresh tokens.
-
#revoke_refresh_token_by_id(token_id) ⇒ FusionAuth::ClientResponse
Revokes a single refresh token by the unique Id.
-
#revoke_refresh_token_by_token(token) ⇒ FusionAuth::ClientResponse
Revokes a single refresh token by using the actual refresh token value.
-
#revoke_refresh_tokens_by_application_id(application_id) ⇒ FusionAuth::ClientResponse
Revoke all refresh tokens that belong to an application by applicationId.
-
#revoke_refresh_tokens_by_user_id(user_id) ⇒ FusionAuth::ClientResponse
Revoke all refresh tokens that belong to a user by user Id.
-
#revoke_refresh_tokens_by_user_id_for_application(user_id, application_id) ⇒ FusionAuth::ClientResponse
Revoke all refresh tokens that belong to a user by user Id for a specific application by applicationId.
-
#revoke_refresh_tokens_with_request(request) ⇒ FusionAuth::ClientResponse
Revokes refresh tokens using the information in the JSON body.
-
#revoke_user_consent(user_consent_id) ⇒ FusionAuth::ClientResponse
Revokes a single User consent by Id.
-
#search_applications(request) ⇒ FusionAuth::ClientResponse
Searches applications with the specified criteria and pagination.
-
#search_audit_logs(request) ⇒ FusionAuth::ClientResponse
Searches the audit logs with the specified criteria and pagination.
-
#search_consents(request) ⇒ FusionAuth::ClientResponse
Searches consents with the specified criteria and pagination.
-
#search_email_templates(request) ⇒ FusionAuth::ClientResponse
Searches email templates with the specified criteria and pagination.
-
#search_entities(request) ⇒ FusionAuth::ClientResponse
Searches entities with the specified criteria and pagination.
-
#search_entities_by_ids(ids) ⇒ FusionAuth::ClientResponse
Retrieves the entities for the given Ids.
-
#search_entity_grants(request) ⇒ FusionAuth::ClientResponse
Searches Entity Grants with the specified criteria and pagination.
-
#search_entity_types(request) ⇒ FusionAuth::ClientResponse
Searches the entity types with the specified criteria and pagination.
-
#search_event_logs(request) ⇒ FusionAuth::ClientResponse
Searches the event logs with the specified criteria and pagination.
-
#search_group_members(request) ⇒ FusionAuth::ClientResponse
Searches group members with the specified criteria and pagination.
-
#search_groups(request) ⇒ FusionAuth::ClientResponse
Searches groups with the specified criteria and pagination.
-
#search_identity_providers(request) ⇒ FusionAuth::ClientResponse
Searches identity providers with the specified criteria and pagination.
-
#search_ip_access_control_lists(request) ⇒ FusionAuth::ClientResponse
Searches the IP Access Control Lists with the specified criteria and pagination.
-
#search_keys(request) ⇒ FusionAuth::ClientResponse
Searches keys with the specified criteria and pagination.
-
#search_lambdas(request) ⇒ FusionAuth::ClientResponse
Searches lambdas with the specified criteria and pagination.
-
#search_login_records(request) ⇒ FusionAuth::ClientResponse
Searches the login records with the specified criteria and pagination.
-
#search_tenants(request) ⇒ FusionAuth::ClientResponse
Searches tenants with the specified criteria and pagination.
-
#search_themes(request) ⇒ FusionAuth::ClientResponse
Searches themes with the specified criteria and pagination.
-
#search_user_comments(request) ⇒ FusionAuth::ClientResponse
Searches user comments with the specified criteria and pagination.
-
#search_users(ids) ⇒ FusionAuth::ClientResponse
deprecated
Deprecated.
This method has been renamed to search_users_by_ids, use that method instead.
-
#search_users_by_ids(ids) ⇒ FusionAuth::ClientResponse
Retrieves the users for the given Ids.
-
#search_users_by_query(request) ⇒ FusionAuth::ClientResponse
Retrieves the users for the given search criteria and pagination.
-
#search_users_by_query_string(request) ⇒ FusionAuth::ClientResponse
deprecated
Deprecated.
This method has been renamed to search_users_by_query, use that method instead.
-
#search_webhook_event_logs(request) ⇒ FusionAuth::ClientResponse
Searches the webhook event logs with the specified criteria and pagination.
-
#search_webhooks(request) ⇒ FusionAuth::ClientResponse
Searches webhooks with the specified criteria and pagination.
-
#send_email(email_template_id, request) ⇒ FusionAuth::ClientResponse
Send an email using an email template Id.
-
#send_family_request_email(request) ⇒ FusionAuth::ClientResponse
Sends out an email to a parent that they need to register and create a family or need to log in and add a child to their existing family.
-
#send_passwordless_code(request) ⇒ FusionAuth::ClientResponse
Send a passwordless authentication code in an email to complete login.
-
#send_two_factor_code(request) ⇒ FusionAuth::ClientResponse
deprecated
Deprecated.
This method has been renamed to send_two_factor_code_for_enable_disable, use that method instead.
-
#send_two_factor_code_for_enable_disable(request) ⇒ FusionAuth::ClientResponse
Send a Two Factor authentication code to assist in setting up Two Factor authentication or disabling.
-
#send_two_factor_code_for_login(two_factor_id) ⇒ FusionAuth::ClientResponse
deprecated
Deprecated.
This method has been renamed to send_two_factor_code_for_login_using_method, use that method instead.
-
#send_two_factor_code_for_login_using_method(two_factor_id, request) ⇒ FusionAuth::ClientResponse
Send a Two Factor authentication code to allow the completion of Two Factor authentication.
-
#send_verify_identity(request) ⇒ FusionAuth::ClientResponse
Send a verification code using the appropriate transport for the identity type being verified.
- #set_tenant_id(tenant_id) ⇒ Object
-
#start_identity_provider_connection_test(request) ⇒ FusionAuth::ClientResponse
Begins an identity provider connection test.
-
#start_identity_provider_login(request) ⇒ FusionAuth::ClientResponse
Begins a login request for a 3rd party login that requires user interaction such as HYPR.
-
#start_passwordless_login(request) ⇒ FusionAuth::ClientResponse
Start a passwordless login request by generating a passwordless code.
-
#start_two_factor_login(request) ⇒ FusionAuth::ClientResponse
Start a Two-Factor login request by generating a two-factor identifier.
-
#start_verify_identity(request) ⇒ FusionAuth::ClientResponse
Start a verification of an identity by generating a code.
-
#start_web_authn_login(request) ⇒ FusionAuth::ClientResponse
Start a WebAuthn authentication ceremony by generating a new challenge for the user.
-
#start_web_authn_registration(request) ⇒ FusionAuth::ClientResponse
Start a WebAuthn registration ceremony by generating a new challenge for the user.
-
#two_factor_login(request) ⇒ FusionAuth::ClientResponse
Complete login using a 2FA challenge.
-
#update_api_key(key_id, request) ⇒ FusionAuth::ClientResponse
Updates an API key with the given Id.
-
#update_application(application_id, request) ⇒ FusionAuth::ClientResponse
Updates the application with the given Id.
-
#update_application_role(application_id, role_id, request) ⇒ FusionAuth::ClientResponse
Updates the application role with the given Id for the application.
-
#update_connector(connector_id, request) ⇒ FusionAuth::ClientResponse
Updates the connector with the given Id.
-
#update_consent(consent_id, request) ⇒ FusionAuth::ClientResponse
Updates the consent with the given Id.
-
#update_email_template(email_template_id, request) ⇒ FusionAuth::ClientResponse
Updates the email template with the given Id.
-
#update_entity(entity_id, request) ⇒ FusionAuth::ClientResponse
Updates the Entity with the given Id.
-
#update_entity_type(entity_type_id, request) ⇒ FusionAuth::ClientResponse
Updates the Entity Type with the given Id.
-
#update_entity_type_permission(entity_type_id, permission_id, request) ⇒ FusionAuth::ClientResponse
Updates the permission with the given Id for the entity type.
-
#update_family(family_id, request) ⇒ FusionAuth::ClientResponse
Updates a family with a given Id.
-
#update_form(form_id, request) ⇒ FusionAuth::ClientResponse
Updates the form with the given Id.
-
#update_form_field(field_id, request) ⇒ FusionAuth::ClientResponse
Updates the form field with the given Id.
-
#update_group(group_id, request) ⇒ FusionAuth::ClientResponse
Updates the group with the given Id.
-
#update_group_members(request) ⇒ FusionAuth::ClientResponse
Creates a member in a group.
-
#update_identity_provider(identity_provider_id, request) ⇒ FusionAuth::ClientResponse
Updates the identity provider with the given Id.
-
#update_integrations(request) ⇒ FusionAuth::ClientResponse
Updates the available integrations.
-
#update_ip_access_control_list(access_control_list_id, request) ⇒ FusionAuth::ClientResponse
Updates the IP Access Control List with the given Id.
-
#update_key(key_id, request) ⇒ FusionAuth::ClientResponse
Updates the key with the given Id.
-
#update_lambda(lambda_id, request) ⇒ FusionAuth::ClientResponse
Updates the lambda with the given Id.
-
#update_message_template(message_template_id, request) ⇒ FusionAuth::ClientResponse
Updates the message template with the given Id.
-
#update_messenger(messenger_id, request) ⇒ FusionAuth::ClientResponse
Updates the messenger with the given Id.
-
#update_o_auth_scope(application_id, scope_id, request) ⇒ FusionAuth::ClientResponse
Updates the OAuth scope with the given Id for the application.
-
#update_registration(user_id, request) ⇒ FusionAuth::ClientResponse
Updates the registration for the user with the given Id and the application defined in the request.
-
#update_system_configuration(request) ⇒ FusionAuth::ClientResponse
Updates the system configuration.
-
#update_tenant(tenant_id, request) ⇒ FusionAuth::ClientResponse
Updates the tenant with the given Id.
-
#update_tenant_manager_configuration(request) ⇒ FusionAuth::ClientResponse
Updates the Tenant Manager configuration.
-
#update_tenant_manager_identity_provider_type_configuration(type, request) ⇒ FusionAuth::ClientResponse
Updates the tenant manager identity provider type configuration for the given identity provider type.
-
#update_theme(theme_id, request) ⇒ FusionAuth::ClientResponse
Updates the theme with the given Id.
-
#update_user(user_id, request) ⇒ FusionAuth::ClientResponse
Updates the user with the given Id.
-
#update_user_action(user_action_id, request) ⇒ FusionAuth::ClientResponse
Updates the user action with the given Id.
-
#update_user_action_reason(user_action_reason_id, request) ⇒ FusionAuth::ClientResponse
Updates the user action reason with the given Id.
-
#update_user_consent(user_consent_id, request) ⇒ FusionAuth::ClientResponse
Updates a single User consent by Id.
-
#update_webhook(webhook_id, request) ⇒ FusionAuth::ClientResponse
Updates the webhook with the given Id.
-
#upsert_entity_grant(entity_id, request) ⇒ FusionAuth::ClientResponse
Creates or updates an Entity Grant.
-
#validate_device(user_code, client_id) ⇒ FusionAuth::ClientResponse
Validates the end-user provided user_code from the user-interaction of the Device Authorization Grant.
-
#validate_device_with_request(request) ⇒ FusionAuth::ClientResponse
Validates the end-user provided user_code from the user-interaction of the Device Authorization Grant.
-
#validate_jwt(encoded_jwt) ⇒ FusionAuth::ClientResponse
Validates the provided JWT (encoded JWT string) to ensure the token is valid.
-
#vend_jwt(request) ⇒ FusionAuth::ClientResponse
It’s a JWT vending machine!.
-
#verify_email(verification_id) ⇒ FusionAuth::ClientResponse
deprecated
Deprecated.
This method has been renamed to verify_email_address and changed to take a JSON request body, use that method instead.
-
#verify_email_address(request) ⇒ FusionAuth::ClientResponse
Confirms a user’s email address.
-
#verify_email_address_by_user_id(request) ⇒ FusionAuth::ClientResponse
Administratively verify a user’s email address.
-
#verify_identity(request) ⇒ FusionAuth::ClientResponse
Administratively verify a user identity.
-
#verify_registration(verification_id) ⇒ FusionAuth::ClientResponse
deprecated
Deprecated.
This method has been renamed to verify_user_registration and changed to take a JSON request body, use that method instead.
-
#verify_user_registration(request) ⇒ FusionAuth::ClientResponse
Confirms a user’s registration.
Constructor Details
#initialize(api_key, base_url) ⇒ FusionAuthClient
Returns a new instance of FusionAuthClient.
32 33 34 35 36 37 38 |
# File 'lib/fusionauth/fusionauth_client.rb', line 32 def initialize(api_key, base_url) @api_key = api_key @base_url = base_url @connect_timeout = 1000 @read_timeout = 2000 @tenant_id = nil end |
Instance Attribute Details
#api_key ⇒ Object
Returns the value of attribute api_key.
30 31 32 |
# File 'lib/fusionauth/fusionauth_client.rb', line 30 def api_key @api_key end |
#base_url ⇒ Object
Returns the value of attribute base_url.
30 31 32 |
# File 'lib/fusionauth/fusionauth_client.rb', line 30 def base_url @base_url end |
#connect_timeout ⇒ Object
Returns the value of attribute connect_timeout.
30 31 32 |
# File 'lib/fusionauth/fusionauth_client.rb', line 30 def connect_timeout @connect_timeout end |
#read_timeout ⇒ Object
Returns the value of attribute read_timeout.
30 31 32 |
# File 'lib/fusionauth/fusionauth_client.rb', line 30 def read_timeout @read_timeout end |
#tenant_id ⇒ Object
Returns the value of attribute tenant_id.
30 31 32 |
# File 'lib/fusionauth/fusionauth_client.rb', line 30 def tenant_id @tenant_id end |
Instance Method Details
#action_user(request) ⇒ FusionAuth::ClientResponse
Takes an action on a user. The user being actioned is called the “actionee” and the user taking the action is called the “actioner”. Both user ids are required in the request object.
51 52 53 54 55 56 |
# File 'lib/fusionauth/fusionauth_client.rb', line 51 def action_user(request) start.uri('/api/user/action') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#activate_reactor(request) ⇒ FusionAuth::ClientResponse
Activates the FusionAuth Reactor using a license Id and optionally a license text (for air-gapped deployments)
63 64 65 66 67 68 |
# File 'lib/fusionauth/fusionauth_client.rb', line 63 def activate_reactor(request) start.uri('/api/reactor') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#add_user_to_family(family_id, request) ⇒ FusionAuth::ClientResponse
Adds a user to an existing family. The family Id must be specified.
76 77 78 79 80 81 82 |
# File 'lib/fusionauth/fusionauth_client.rb', line 76 def add_user_to_family(family_id, request) start.uri('/api/user/family') .url_segment(family_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .put .go end |
#approve_device(client_id, client_secret, token, user_code) ⇒ FusionAuth::ClientResponse
Approve a device grant.
92 93 94 95 96 97 98 99 100 101 102 103 |
# File 'lib/fusionauth/fusionauth_client.rb', line 92 def approve_device(client_id, client_secret, token, user_code) form_parameters = { "client_id" => client_id, "client_secret" => client_secret, "token" => token, "user_code" => user_code, } start.uri('/oauth2/device/approve') .body_handler(FusionAuth::FormDataBodyHandler.new(form_parameters)) .post .go end |
#approve_device_with_request(request) ⇒ FusionAuth::ClientResponse
Approve a device grant.
110 111 112 113 114 115 116 117 118 119 120 121 122 |
# File 'lib/fusionauth/fusionauth_client.rb', line 110 def approve_device_with_request(request) form_parameters = { "client_id" => request.client_id, "client_secret" => request.client_secret, "tenantId" => (request.tenantId.to_s unless request.tenantId.nil?), "token" => request.token, "user_code" => request.user_code, } start.uri('/oauth2/device/approve') .body_handler(FusionAuth::FormDataBodyHandler.new(form_parameters)) .post .go end |
#cancel_action(action_id, request) ⇒ FusionAuth::ClientResponse
Cancels the user action.
130 131 132 133 134 135 136 |
# File 'lib/fusionauth/fusionauth_client.rb', line 130 def cancel_action(action_id, request) start.uri('/api/user/action') .url_segment(action_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .delete .go end |
#change_password(change_password_id, request) ⇒ FusionAuth::ClientResponse
Changes a user’s password using the change password Id. This usually occurs after an email has been sent to the user and they clicked on a link to reset their password.
As of version 1.32.2, prefer sending the changePasswordId in the request body. To do this, omit the first parameter, and set the value in the request body.
148 149 150 151 152 153 154 |
# File 'lib/fusionauth/fusionauth_client.rb', line 148 def change_password(change_password_id, request) startAnonymous.uri('/api/user/change-password') .url_segment(change_password_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#change_password_by_identity(request) ⇒ FusionAuth::ClientResponse
Changes a user’s password using their identity (loginId and password). Using a loginId instead of the changePasswordId bypasses the email verification and allows a password to be changed directly without first calling the #forgotPassword method.
181 182 183 184 185 186 |
# File 'lib/fusionauth/fusionauth_client.rb', line 181 def change_password_by_identity(request) start.uri('/api/user/change-password') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#change_password_by_jwt(encoded_jwt, request) ⇒ FusionAuth::ClientResponse
This method has been renamed to change_password_using_jwt, use that method instead.
Changes a user’s password using their access token (JWT) instead of the changePasswordId A common use case for this method will be if you want to allow the user to change their own password.
Remember to send refreshToken in the request body if you want to get a new refresh token when login using the returned oneTimePassword.
166 167 168 169 170 171 172 |
# File 'lib/fusionauth/fusionauth_client.rb', line 166 def change_password_by_jwt(encoded_jwt, request) startAnonymous.uri('/api/user/change-password') .('Bearer ' + encoded_jwt) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#change_password_using_jwt(encoded_jwt, request) ⇒ FusionAuth::ClientResponse
Changes a user’s password using their access token (JWT) instead of the changePasswordId A common use case for this method will be if you want to allow the user to change their own password.
Remember to send refreshToken in the request body if you want to get a new refresh token when login using the returned oneTimePassword.
197 198 199 200 201 202 203 |
# File 'lib/fusionauth/fusionauth_client.rb', line 197 def change_password_using_jwt(encoded_jwt, request) startAnonymous.uri('/api/user/change-password') .('Bearer ' + encoded_jwt) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#check_change_password_using_id(change_password_id) ⇒ FusionAuth::ClientResponse
Check to see if the user must obtain a Trust Token Id in order to complete a change password request. When a user has enabled Two-Factor authentication, before you are allowed to use the Change Password API to change your password, you must obtain a Trust Token by completing a Two-Factor Step-Up authentication.
An HTTP status code of 400 with a general error code of [TrustTokenRequired] indicates that a Trust Token is required to make a POST request to this API.
214 215 216 217 218 219 |
# File 'lib/fusionauth/fusionauth_client.rb', line 214 def check_change_password_using_id(change_password_id) startAnonymous.uri('/api/user/change-password') .url_segment(change_password_id) .get .go end |
#check_change_password_using_id_and_ip_address(change_password_id, ip_address) ⇒ FusionAuth::ClientResponse
Check to see if the user must obtain a Trust Token Id in order to complete a change password request. When a user has enabled Two-Factor authentication, before you are allowed to use the Change Password API to change your password, you must obtain a Trust Token by completing a Two-Factor Step-Up authentication.
An HTTP status code of 400 with a general error code of [TrustTokenRequired] indicates that a Trust Token is required to make a POST request to this API.
231 232 233 234 235 236 237 |
# File 'lib/fusionauth/fusionauth_client.rb', line 231 def check_change_password_using_id_and_ip_address(change_password_id, ip_address) startAnonymous.uri('/api/user/change-password') .url_segment(change_password_id) .url_parameter('ipAddress', ip_address) .get .go end |
#check_change_password_using_jwt(encoded_jwt) ⇒ FusionAuth::ClientResponse
Check to see if the user must obtain a Trust Token Id in order to complete a change password request. When a user has enabled Two-Factor authentication, before you are allowed to use the Change Password API to change your password, you must obtain a Trust Token by completing a Two-Factor Step-Up authentication.
An HTTP status code of 400 with a general error code of [TrustTokenRequired] indicates that a Trust Token is required to make a POST request to this API.
248 249 250 251 252 253 |
# File 'lib/fusionauth/fusionauth_client.rb', line 248 def check_change_password_using_jwt(encoded_jwt) startAnonymous.uri('/api/user/change-password') .('Bearer ' + encoded_jwt) .get .go end |
#check_change_password_using_jwt_and_ip_address(encoded_jwt, ip_address) ⇒ FusionAuth::ClientResponse
Check to see if the user must obtain a Trust Token Id in order to complete a change password request. When a user has enabled Two-Factor authentication, before you are allowed to use the Change Password API to change your password, you must obtain a Trust Token by completing a Two-Factor Step-Up authentication.
An HTTP status code of 400 with a general error code of [TrustTokenRequired] indicates that a Trust Token is required to make a POST request to this API.
265 266 267 268 269 270 271 |
# File 'lib/fusionauth/fusionauth_client.rb', line 265 def check_change_password_using_jwt_and_ip_address(encoded_jwt, ip_address) startAnonymous.uri('/api/user/change-password') .('Bearer ' + encoded_jwt) .url_parameter('ipAddress', ip_address) .get .go end |
#check_change_password_using_login_id(login_id) ⇒ FusionAuth::ClientResponse
Check to see if the user must obtain a Trust Request Id in order to complete a change password request. When a user has enabled Two-Factor authentication, before you are allowed to use the Change Password API to change your password, you must obtain a Trust Request Id by completing a Two-Factor Step-Up authentication.
An HTTP status code of 400 with a general error code of [TrustTokenRequired] indicates that a Trust Token is required to make a POST request to this API.
282 283 284 285 286 287 |
# File 'lib/fusionauth/fusionauth_client.rb', line 282 def check_change_password_using_login_id(login_id) start.uri('/api/user/change-password') .url_parameter('loginId', login_id) .get .go end |
#check_change_password_using_login_id_and_ip_address(login_id, ip_address) ⇒ FusionAuth::ClientResponse
Check to see if the user must obtain a Trust Request Id in order to complete a change password request. When a user has enabled Two-Factor authentication, before you are allowed to use the Change Password API to change your password, you must obtain a Trust Request Id by completing a Two-Factor Step-Up authentication.
An HTTP status code of 400 with a general error code of [TrustTokenRequired] indicates that a Trust Token is required to make a POST request to this API.
299 300 301 302 303 304 305 |
# File 'lib/fusionauth/fusionauth_client.rb', line 299 def check_change_password_using_login_id_and_ip_address(login_id, ip_address) start.uri('/api/user/change-password') .url_parameter('loginId', login_id) .url_parameter('ipAddress', ip_address) .get .go end |
#check_change_password_using_login_id_and_login_id_types(login_id, login_id_types) ⇒ FusionAuth::ClientResponse
Check to see if the user must obtain a Trust Request Id in order to complete a change password request. When a user has enabled Two-Factor authentication, before you are allowed to use the Change Password API to change your password, you must obtain a Trust Request Id by completing a Two-Factor Step-Up authentication.
An HTTP status code of 400 with a general error code of [TrustTokenRequired] indicates that a Trust Token is required to make a POST request to this API.
317 318 319 320 321 322 323 |
# File 'lib/fusionauth/fusionauth_client.rb', line 317 def check_change_password_using_login_id_and_login_id_types(login_id, login_id_types) start.uri('/api/user/change-password') .url_parameter('loginId', login_id) .url_parameter('loginIdTypes', login_id_types) .get .go end |
#check_change_password_using_login_id_and_login_id_types_and_ip_address(login_id, login_id_types, ip_address) ⇒ FusionAuth::ClientResponse
Check to see if the user must obtain a Trust Request Id in order to complete a change password request. When a user has enabled Two-Factor authentication, before you are allowed to use the Change Password API to change your password, you must obtain a Trust Request Id by completing a Two-Factor Step-Up authentication.
An HTTP status code of 400 with a general error code of [TrustTokenRequired] indicates that a Trust Token is required to make a POST request to this API.
336 337 338 339 340 341 342 343 |
# File 'lib/fusionauth/fusionauth_client.rb', line 336 def check_change_password_using_login_id_and_login_id_types_and_ip_address(login_id, login_id_types, ip_address) start.uri('/api/user/change-password') .url_parameter('loginId', login_id) .url_parameter('loginIdTypes', login_id_types) .url_parameter('ipAddress', ip_address) .get .go end |
#client_credentials_grant(client_id, client_secret, scope) ⇒ FusionAuth::ClientResponse
Make a Client Credentials grant request to obtain an access token.
354 355 356 357 358 359 360 361 362 363 364 365 |
# File 'lib/fusionauth/fusionauth_client.rb', line 354 def client_credentials_grant(client_id, client_secret, scope) form_parameters = { "client_id" => client_id, "client_secret" => client_secret, "grant_type" => 'client_credentials', "scope" => scope, } startAnonymous.uri('/oauth2/token') .body_handler(FusionAuth::FormDataBodyHandler.new(form_parameters)) .post .go end |
#client_credentials_grant_with_request(request) ⇒ FusionAuth::ClientResponse
Make a Client Credentials grant request to obtain an access token.
372 373 374 375 376 377 378 379 380 381 382 383 384 |
# File 'lib/fusionauth/fusionauth_client.rb', line 372 def client_credentials_grant_with_request(request) form_parameters = { "client_id" => request.client_id, "client_secret" => request.client_secret, "grant_type" => request.grant_type, "scope" => request.scope, "tenantId" => request.tenantId, } startAnonymous.uri('/oauth2/token') .body_handler(FusionAuth::FormDataBodyHandler.new(form_parameters)) .post .go end |
#comment_on_user(request) ⇒ FusionAuth::ClientResponse
Adds a comment to the user’s account.
391 392 393 394 395 396 |
# File 'lib/fusionauth/fusionauth_client.rb', line 391 def comment_on_user(request) start.uri('/api/user/comment') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#complete_verify_identity(request) ⇒ FusionAuth::ClientResponse
Completes verification of an identity using verification codes from the Verify Start API.
403 404 405 406 407 408 |
# File 'lib/fusionauth/fusionauth_client.rb', line 403 def complete_verify_identity(request) start.uri('/api/identity/verify/complete') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#complete_web_authn_assertion(request) ⇒ FusionAuth::ClientResponse
Complete a WebAuthn authentication ceremony by validating the signature against the previously generated challenge without logging the user in
415 416 417 418 419 420 |
# File 'lib/fusionauth/fusionauth_client.rb', line 415 def complete_web_authn_assertion(request) startAnonymous.uri('/api/webauthn/assert') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#complete_web_authn_login(request) ⇒ FusionAuth::ClientResponse
Complete a WebAuthn authentication ceremony by validating the signature against the previously generated challenge and then login the user in
427 428 429 430 431 432 |
# File 'lib/fusionauth/fusionauth_client.rb', line 427 def complete_web_authn_login(request) startAnonymous.uri('/api/webauthn/login') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#complete_web_authn_registration(request) ⇒ FusionAuth::ClientResponse
Complete a WebAuthn registration ceremony by validating the client request and saving the new credential
439 440 441 442 443 444 |
# File 'lib/fusionauth/fusionauth_client.rb', line 439 def complete_web_authn_registration(request) start.uri('/api/webauthn/register/complete') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#create_api_key(key_id, request) ⇒ FusionAuth::ClientResponse
Creates an API key. You can optionally specify a unique Id for the key, if not provided one will be generated. an API key can only be created with equal or lesser authority. An API key cannot create another API key unless it is granted to that API key.
If an API key is locked to a tenant, it can only create API Keys for that same tenant.
456 457 458 459 460 461 462 |
# File 'lib/fusionauth/fusionauth_client.rb', line 456 def create_api_key(key_id, request) start.uri('/api/api-key') .url_segment(key_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#create_application(application_id, request) ⇒ FusionAuth::ClientResponse
Creates an application. You can optionally specify an Id for the application, if not provided one will be generated.
470 471 472 473 474 475 476 |
# File 'lib/fusionauth/fusionauth_client.rb', line 470 def create_application(application_id, request) start.uri('/api/application') .url_segment(application_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#create_application_role(application_id, role_id, request) ⇒ FusionAuth::ClientResponse
Creates a new role for an application. You must specify the Id of the application you are creating the role for. You can optionally specify an Id for the role inside the ApplicationRole object itself, if not provided one will be generated.
486 487 488 489 490 491 492 493 494 |
# File 'lib/fusionauth/fusionauth_client.rb', line 486 def create_application_role(application_id, role_id, request) start.uri('/api/application') .url_segment(application_id) .url_segment("role") .url_segment(role_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#create_audit_log(request) ⇒ FusionAuth::ClientResponse
Creates an audit log with the message and user name (usually an email). Audit logs should be written anytime you make changes to the FusionAuth database. When using the FusionAuth App web interface, any changes are automatically written to the audit log. However, if you are accessing the API, you must write the audit logs yourself.
503 504 505 506 507 508 |
# File 'lib/fusionauth/fusionauth_client.rb', line 503 def create_audit_log(request) start.uri('/api/system/audit-log') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#create_connector(connector_id, request) ⇒ FusionAuth::ClientResponse
Creates a connector. You can optionally specify an Id for the connector, if not provided one will be generated.
516 517 518 519 520 521 522 |
# File 'lib/fusionauth/fusionauth_client.rb', line 516 def create_connector(connector_id, request) start.uri('/api/connector') .url_segment(connector_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#create_consent(consent_id, request) ⇒ FusionAuth::ClientResponse
Creates a user consent type. You can optionally specify an Id for the consent type, if not provided one will be generated.
530 531 532 533 534 535 536 |
# File 'lib/fusionauth/fusionauth_client.rb', line 530 def (, request) start.uri('/api/consent') .url_segment() .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#create_email_template(email_template_id, request) ⇒ FusionAuth::ClientResponse
Creates an email template. You can optionally specify an Id for the template, if not provided one will be generated.
544 545 546 547 548 549 550 |
# File 'lib/fusionauth/fusionauth_client.rb', line 544 def create_email_template(email_template_id, request) start.uri('/api/email/template') .url_segment(email_template_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#create_entity(entity_id, request) ⇒ FusionAuth::ClientResponse
Creates an Entity. You can optionally specify an Id for the Entity. If not provided one will be generated.
558 559 560 561 562 563 564 |
# File 'lib/fusionauth/fusionauth_client.rb', line 558 def create_entity(entity_id, request) start.uri('/api/entity') .url_segment(entity_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#create_entity_type(entity_type_id, request) ⇒ FusionAuth::ClientResponse
Creates a Entity Type. You can optionally specify an Id for the Entity Type, if not provided one will be generated.
572 573 574 575 576 577 578 |
# File 'lib/fusionauth/fusionauth_client.rb', line 572 def create_entity_type(entity_type_id, request) start.uri('/api/entity/type') .url_segment(entity_type_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#create_entity_type_permission(entity_type_id, permission_id, request) ⇒ FusionAuth::ClientResponse
Creates a new permission for an entity type. You must specify the Id of the entity type you are creating the permission for. You can optionally specify an Id for the permission inside the EntityTypePermission object itself, if not provided one will be generated.
588 589 590 591 592 593 594 595 596 |
# File 'lib/fusionauth/fusionauth_client.rb', line 588 def (entity_type_id, , request) start.uri('/api/entity/type') .url_segment(entity_type_id) .url_segment("permission") .url_segment() .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#create_family(family_id, request) ⇒ FusionAuth::ClientResponse
Creates a family with the user Id in the request as the owner and sole member of the family. You can optionally specify an Id for the family, if not provided one will be generated.
605 606 607 608 609 610 611 |
# File 'lib/fusionauth/fusionauth_client.rb', line 605 def create_family(family_id, request) start.uri('/api/user/family') .url_segment(family_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#create_form(form_id, request) ⇒ FusionAuth::ClientResponse
Creates a form. You can optionally specify an Id for the form, if not provided one will be generated.
619 620 621 622 623 624 625 |
# File 'lib/fusionauth/fusionauth_client.rb', line 619 def create_form(form_id, request) start.uri('/api/form') .url_segment(form_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#create_form_field(field_id, request) ⇒ FusionAuth::ClientResponse
Creates a form field. You can optionally specify an Id for the form, if not provided one will be generated.
633 634 635 636 637 638 639 |
# File 'lib/fusionauth/fusionauth_client.rb', line 633 def create_form_field(field_id, request) start.uri('/api/form/field') .url_segment(field_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#create_group(group_id, request) ⇒ FusionAuth::ClientResponse
Creates a group. You can optionally specify an Id for the group, if not provided one will be generated.
647 648 649 650 651 652 653 |
# File 'lib/fusionauth/fusionauth_client.rb', line 647 def create_group(group_id, request) start.uri('/api/group') .url_segment(group_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#create_group_members(request) ⇒ FusionAuth::ClientResponse
Creates a member in a group.
660 661 662 663 664 665 |
# File 'lib/fusionauth/fusionauth_client.rb', line 660 def create_group_members(request) start.uri('/api/group/member') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#create_identity_provider(identity_provider_id, request) ⇒ FusionAuth::ClientResponse
Creates an identity provider. You can optionally specify an Id for the identity provider, if not provided one will be generated.
687 688 689 690 691 692 693 |
# File 'lib/fusionauth/fusionauth_client.rb', line 687 def create_identity_provider(identity_provider_id, request) start.uri('/api/identity-provider') .url_segment(identity_provider_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#create_ip_access_control_list(access_control_list_id, request) ⇒ FusionAuth::ClientResponse
Creates an IP Access Control List. You can optionally specify an Id on this create request, if one is not provided one will be generated.
673 674 675 676 677 678 679 |
# File 'lib/fusionauth/fusionauth_client.rb', line 673 def create_ip_access_control_list(access_control_list_id, request) start.uri('/api/ip-acl') .url_segment(access_control_list_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#create_lambda(lambda_id, request) ⇒ FusionAuth::ClientResponse
Creates a Lambda. You can optionally specify an Id for the lambda, if not provided one will be generated.
701 702 703 704 705 706 707 |
# File 'lib/fusionauth/fusionauth_client.rb', line 701 def create_lambda(lambda_id, request) start.uri('/api/lambda') .url_segment(lambda_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#create_message_template(message_template_id, request) ⇒ FusionAuth::ClientResponse
Creates an message template. You can optionally specify an Id for the template, if not provided one will be generated.
715 716 717 718 719 720 721 |
# File 'lib/fusionauth/fusionauth_client.rb', line 715 def (, request) start.uri('/api/message/template') .url_segment() .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#create_messenger(messenger_id, request) ⇒ FusionAuth::ClientResponse
Creates a messenger. You can optionally specify an Id for the messenger, if not provided one will be generated.
729 730 731 732 733 734 735 |
# File 'lib/fusionauth/fusionauth_client.rb', line 729 def create_messenger(messenger_id, request) start.uri('/api/messenger') .url_segment(messenger_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#create_o_auth_scope(application_id, scope_id, request) ⇒ FusionAuth::ClientResponse
Creates a new custom OAuth scope for an application. You must specify the Id of the application you are creating the scope for. You can optionally specify an Id for the OAuth scope on the URL, if not provided one will be generated.
745 746 747 748 749 750 751 752 753 |
# File 'lib/fusionauth/fusionauth_client.rb', line 745 def create_o_auth_scope(application_id, scope_id, request) start.uri('/api/application') .url_segment(application_id) .url_segment("scope") .url_segment(scope_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#create_tenant(tenant_id, request) ⇒ FusionAuth::ClientResponse
Creates a tenant. You can optionally specify an Id for the tenant, if not provided one will be generated.
761 762 763 764 765 766 767 |
# File 'lib/fusionauth/fusionauth_client.rb', line 761 def create_tenant(tenant_id, request) start.uri('/api/tenant') .url_segment(tenant_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#create_tenant_manager_identity_provider_type_configuration(type, request) ⇒ FusionAuth::ClientResponse
Creates a tenant manager identity provider type configuration for the given identity provider type.
775 776 777 778 779 780 781 |
# File 'lib/fusionauth/fusionauth_client.rb', line 775 def create_tenant_manager_identity_provider_type_configuration(type, request) start.uri('/api/tenant-manager/identity-provider') .url_segment(type) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#create_theme(theme_id, request) ⇒ FusionAuth::ClientResponse
Creates a Theme. You can optionally specify an Id for the theme, if not provided one will be generated.
789 790 791 792 793 794 795 |
# File 'lib/fusionauth/fusionauth_client.rb', line 789 def create_theme(theme_id, request) start.uri('/api/theme') .url_segment(theme_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#create_user(user_id, request) ⇒ FusionAuth::ClientResponse
Creates a user. You can optionally specify an Id for the user, if not provided one will be generated.
803 804 805 806 807 808 809 |
# File 'lib/fusionauth/fusionauth_client.rb', line 803 def create_user(user_id, request) start.uri('/api/user') .url_segment(user_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#create_user_action(user_action_id, request) ⇒ FusionAuth::ClientResponse
Creates a user action. This action cannot be taken on a user until this call successfully returns. Anytime after that the user action can be applied to any user.
818 819 820 821 822 823 824 |
# File 'lib/fusionauth/fusionauth_client.rb', line 818 def create_user_action(user_action_id, request) start.uri('/api/user-action') .url_segment(user_action_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#create_user_action_reason(user_action_reason_id, request) ⇒ FusionAuth::ClientResponse
Creates a user reason. This user action reason cannot be used when actioning a user until this call completes successfully. Anytime after that the user action reason can be used.
833 834 835 836 837 838 839 |
# File 'lib/fusionauth/fusionauth_client.rb', line 833 def create_user_action_reason(user_action_reason_id, request) start.uri('/api/user-action-reason') .url_segment(user_action_reason_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#create_user_consent(user_consent_id, request) ⇒ FusionAuth::ClientResponse
Creates a single User consent.
847 848 849 850 851 852 853 |
# File 'lib/fusionauth/fusionauth_client.rb', line 847 def (, request) start.uri('/api/user/consent') .url_segment() .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#create_user_link(request) ⇒ FusionAuth::ClientResponse
Link an external user from a 3rd party identity provider to a FusionAuth user.
860 861 862 863 864 865 |
# File 'lib/fusionauth/fusionauth_client.rb', line 860 def create_user_link(request) start.uri('/api/identity-provider/link') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#create_webhook(webhook_id, request) ⇒ FusionAuth::ClientResponse
Creates a webhook. You can optionally specify an Id for the webhook, if not provided one will be generated.
873 874 875 876 877 878 879 |
# File 'lib/fusionauth/fusionauth_client.rb', line 873 def create_webhook(webhook_id, request) start.uri('/api/webhook') .url_segment(webhook_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#deactivate_application(application_id) ⇒ FusionAuth::ClientResponse
Deactivates the application with the given Id.
886 887 888 889 890 891 |
# File 'lib/fusionauth/fusionauth_client.rb', line 886 def deactivate_application(application_id) start.uri('/api/application') .url_segment(application_id) .delete .go end |
#deactivate_reactor ⇒ FusionAuth::ClientResponse
Deactivates the FusionAuth Reactor.
897 898 899 900 901 |
# File 'lib/fusionauth/fusionauth_client.rb', line 897 def deactivate_reactor start.uri('/api/reactor') .delete .go end |
#deactivate_user(user_id) ⇒ FusionAuth::ClientResponse
Deactivates the user with the given Id.
908 909 910 911 912 913 |
# File 'lib/fusionauth/fusionauth_client.rb', line 908 def deactivate_user(user_id) start.uri('/api/user') .url_segment(user_id) .delete .go end |
#deactivate_user_action(user_action_id) ⇒ FusionAuth::ClientResponse
Deactivates the user action with the given Id.
920 921 922 923 924 925 |
# File 'lib/fusionauth/fusionauth_client.rb', line 920 def deactivate_user_action(user_action_id) start.uri('/api/user-action') .url_segment(user_action_id) .delete .go end |
#deactivate_users(user_ids) ⇒ FusionAuth::ClientResponse
This method has been renamed to deactivate_users_by_ids, use that method instead.
Deactivates the users with the given Ids.
933 934 935 936 937 938 939 940 |
# File 'lib/fusionauth/fusionauth_client.rb', line 933 def deactivate_users(user_ids) start.uri('/api/user/bulk') .url_parameter('userId', user_ids) .url_parameter('dryRun', false) .url_parameter('hardDelete', false) .delete .go end |
#deactivate_users_by_ids(user_ids) ⇒ FusionAuth::ClientResponse
Deactivates the users with the given Ids.
947 948 949 950 951 952 953 954 |
# File 'lib/fusionauth/fusionauth_client.rb', line 947 def deactivate_users_by_ids(user_ids) start.uri('/api/user/bulk') .url_parameter('userId', user_ids) .url_parameter('dryRun', false) .url_parameter('hardDelete', false) .delete .go end |
#delete_api_key(key_id) ⇒ FusionAuth::ClientResponse
Deletes the API key for the given Id.
961 962 963 964 965 966 |
# File 'lib/fusionauth/fusionauth_client.rb', line 961 def delete_api_key(key_id) start.uri('/api/api-key') .url_segment(key_id) .delete .go end |
#delete_application(application_id) ⇒ FusionAuth::ClientResponse
Hard deletes an application. This is a dangerous operation and should not be used in most circumstances. This will delete the application, any registrations for that application, metrics and reports for the application, all the roles for the application, and any other data associated with the application. This operation could take a very long time, depending on the amount of data in your database.
976 977 978 979 980 981 982 |
# File 'lib/fusionauth/fusionauth_client.rb', line 976 def delete_application(application_id) start.uri('/api/application') .url_segment(application_id) .url_parameter('hardDelete', true) .delete .go end |
#delete_application_role(application_id, role_id) ⇒ FusionAuth::ClientResponse
Hard deletes an application role. This is a dangerous operation and should not be used in most circumstances. This permanently removes the given role from all users that had it.
991 992 993 994 995 996 997 998 |
# File 'lib/fusionauth/fusionauth_client.rb', line 991 def delete_application_role(application_id, role_id) start.uri('/api/application') .url_segment(application_id) .url_segment("role") .url_segment(role_id) .delete .go end |
#delete_connector(connector_id) ⇒ FusionAuth::ClientResponse
Deletes the connector for the given Id.
1005 1006 1007 1008 1009 1010 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1005 def delete_connector(connector_id) start.uri('/api/connector') .url_segment(connector_id) .delete .go end |
#delete_consent(consent_id) ⇒ FusionAuth::ClientResponse
Deletes the consent for the given Id.
1017 1018 1019 1020 1021 1022 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1017 def () start.uri('/api/consent') .url_segment() .delete .go end |
#delete_email_template(email_template_id) ⇒ FusionAuth::ClientResponse
Deletes the email template for the given Id.
1029 1030 1031 1032 1033 1034 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1029 def delete_email_template(email_template_id) start.uri('/api/email/template') .url_segment(email_template_id) .delete .go end |
#delete_entity(entity_id) ⇒ FusionAuth::ClientResponse
Deletes the Entity for the given Id.
1041 1042 1043 1044 1045 1046 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1041 def delete_entity(entity_id) start.uri('/api/entity') .url_segment(entity_id) .delete .go end |
#delete_entity_grant(entity_id, recipient_entity_id, user_id) ⇒ FusionAuth::ClientResponse
Deletes an Entity Grant for the given User or Entity.
1055 1056 1057 1058 1059 1060 1061 1062 1063 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1055 def delete_entity_grant(entity_id, recipient_entity_id, user_id) start.uri('/api/entity') .url_segment(entity_id) .url_segment("grant") .url_parameter('recipientEntityId', recipient_entity_id) .url_parameter('userId', user_id) .delete .go end |
#delete_entity_type(entity_type_id) ⇒ FusionAuth::ClientResponse
Deletes the Entity Type for the given Id.
1070 1071 1072 1073 1074 1075 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1070 def delete_entity_type(entity_type_id) start.uri('/api/entity/type') .url_segment(entity_type_id) .delete .go end |
#delete_entity_type_permission(entity_type_id, permission_id) ⇒ FusionAuth::ClientResponse
Hard deletes a permission. This is a dangerous operation and should not be used in most circumstances. This permanently removes the given permission from all grants that had it.
1084 1085 1086 1087 1088 1089 1090 1091 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1084 def (entity_type_id, ) start.uri('/api/entity/type') .url_segment(entity_type_id) .url_segment("permission") .url_segment() .delete .go end |
#delete_form(form_id) ⇒ FusionAuth::ClientResponse
Deletes the form for the given Id.
1098 1099 1100 1101 1102 1103 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1098 def delete_form(form_id) start.uri('/api/form') .url_segment(form_id) .delete .go end |
#delete_form_field(field_id) ⇒ FusionAuth::ClientResponse
Deletes the form field for the given Id.
1110 1111 1112 1113 1114 1115 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1110 def delete_form_field(field_id) start.uri('/api/form/field') .url_segment(field_id) .delete .go end |
#delete_group(group_id) ⇒ FusionAuth::ClientResponse
Deletes the group for the given Id.
1122 1123 1124 1125 1126 1127 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1122 def delete_group(group_id) start.uri('/api/group') .url_segment(group_id) .delete .go end |
#delete_group_members(request) ⇒ FusionAuth::ClientResponse
Removes users as members of a group.
1134 1135 1136 1137 1138 1139 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1134 def delete_group_members(request) start.uri('/api/group/member') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .delete .go end |
#delete_identity_provider(identity_provider_id) ⇒ FusionAuth::ClientResponse
Deletes the identity provider for the given Id.
1158 1159 1160 1161 1162 1163 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1158 def delete_identity_provider(identity_provider_id) start.uri('/api/identity-provider') .url_segment(identity_provider_id) .delete .go end |
#delete_ip_access_control_list(ip_access_control_list_id) ⇒ FusionAuth::ClientResponse
Deletes the IP Access Control List for the given Id.
1146 1147 1148 1149 1150 1151 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1146 def delete_ip_access_control_list(ip_access_control_list_id) start.uri('/api/ip-acl') .url_segment(ip_access_control_list_id) .delete .go end |
#delete_key(key_id) ⇒ FusionAuth::ClientResponse
Deletes the key for the given Id.
1170 1171 1172 1173 1174 1175 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1170 def delete_key(key_id) start.uri('/api/key') .url_segment(key_id) .delete .go end |
#delete_lambda(lambda_id) ⇒ FusionAuth::ClientResponse
Deletes the lambda for the given Id.
1182 1183 1184 1185 1186 1187 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1182 def delete_lambda(lambda_id) start.uri('/api/lambda') .url_segment(lambda_id) .delete .go end |
#delete_message_template(message_template_id) ⇒ FusionAuth::ClientResponse
Deletes the message template for the given Id.
1194 1195 1196 1197 1198 1199 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1194 def () start.uri('/api/message/template') .url_segment() .delete .go end |
#delete_messenger(messenger_id) ⇒ FusionAuth::ClientResponse
Deletes the messenger for the given Id.
1206 1207 1208 1209 1210 1211 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1206 def delete_messenger(messenger_id) start.uri('/api/messenger') .url_segment(messenger_id) .delete .go end |
#delete_o_auth_scope(application_id, scope_id) ⇒ FusionAuth::ClientResponse
Hard deletes a custom OAuth scope. OAuth workflows that are still requesting the deleted OAuth scope may fail depending on the application’s unknown scope policy.
1220 1221 1222 1223 1224 1225 1226 1227 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1220 def delete_o_auth_scope(application_id, scope_id) start.uri('/api/application') .url_segment(application_id) .url_segment("scope") .url_segment(scope_id) .delete .go end |
#delete_registration(user_id, application_id) ⇒ FusionAuth::ClientResponse
Deletes the user registration for the given user and application.
1235 1236 1237 1238 1239 1240 1241 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1235 def delete_registration(user_id, application_id) start.uri('/api/user/registration') .url_segment(user_id) .url_segment(application_id) .delete .go end |
#delete_registration_with_request(user_id, application_id, request) ⇒ FusionAuth::ClientResponse
Deletes the user registration for the given user and application along with the given JSON body that contains the event information.
1250 1251 1252 1253 1254 1255 1256 1257 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1250 def delete_registration_with_request(user_id, application_id, request) start.uri('/api/user/registration') .url_segment(user_id) .url_segment(application_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .delete .go end |
#delete_tenant(tenant_id) ⇒ FusionAuth::ClientResponse
Deletes the tenant based on the given Id on the URL. This permanently deletes all information, metrics, reports and data associated with the tenant and everything under the tenant (applications, users, etc).
1265 1266 1267 1268 1269 1270 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1265 def delete_tenant(tenant_id) start.uri('/api/tenant') .url_segment(tenant_id) .delete .go end |
#delete_tenant_async(tenant_id) ⇒ FusionAuth::ClientResponse
Deletes the tenant for the given Id asynchronously. This method is helpful if you do not want to wait for the delete operation to complete.
1278 1279 1280 1281 1282 1283 1284 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1278 def delete_tenant_async(tenant_id) start.uri('/api/tenant') .url_segment(tenant_id) .url_parameter('async', true) .delete .go end |
#delete_tenant_manager_identity_provider_type_configuration(type) ⇒ FusionAuth::ClientResponse
Deletes the tenant manager identity provider type configuration for the given identity provider type.
1291 1292 1293 1294 1295 1296 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1291 def delete_tenant_manager_identity_provider_type_configuration(type) start.uri('/api/tenant-manager/identity-provider') .url_segment(type) .delete .go end |
#delete_tenant_with_request(tenant_id, request) ⇒ FusionAuth::ClientResponse
Deletes the tenant based on the given request (sent to the API as JSON). This permanently deletes all information, metrics, reports and data associated with the tenant and everything under the tenant (applications, users, etc).
1305 1306 1307 1308 1309 1310 1311 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1305 def delete_tenant_with_request(tenant_id, request) start.uri('/api/tenant') .url_segment(tenant_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .delete .go end |
#delete_theme(theme_id) ⇒ FusionAuth::ClientResponse
Deletes the theme for the given Id.
1318 1319 1320 1321 1322 1323 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1318 def delete_theme(theme_id) start.uri('/api/theme') .url_segment(theme_id) .delete .go end |
#delete_user(user_id) ⇒ FusionAuth::ClientResponse
Deletes the user for the given Id. This permanently deletes all information, metrics, reports and data associated with the user.
1331 1332 1333 1334 1335 1336 1337 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1331 def delete_user(user_id) start.uri('/api/user') .url_segment(user_id) .url_parameter('hardDelete', true) .delete .go end |
#delete_user_action(user_action_id) ⇒ FusionAuth::ClientResponse
Deletes the user action for the given Id. This permanently deletes the user action and also any history and logs of the action being applied to any users.
1345 1346 1347 1348 1349 1350 1351 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1345 def delete_user_action(user_action_id) start.uri('/api/user-action') .url_segment(user_action_id) .url_parameter('hardDelete', true) .delete .go end |
#delete_user_action_reason(user_action_reason_id) ⇒ FusionAuth::ClientResponse
Deletes the user action reason for the given Id.
1358 1359 1360 1361 1362 1363 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1358 def delete_user_action_reason(user_action_reason_id) start.uri('/api/user-action-reason') .url_segment(user_action_reason_id) .delete .go end |
#delete_user_link(identity_provider_id, identity_provider_user_id, user_id) ⇒ FusionAuth::ClientResponse
Remove an existing link that has been made from a 3rd party identity provider to a FusionAuth user.
1372 1373 1374 1375 1376 1377 1378 1379 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1372 def delete_user_link(identity_provider_id, identity_provider_user_id, user_id) start.uri('/api/identity-provider/link') .url_parameter('identityProviderId', identity_provider_id) .url_parameter('identityProviderUserId', identity_provider_user_id) .url_parameter('userId', user_id) .delete .go end |
#delete_user_with_request(user_id, request) ⇒ FusionAuth::ClientResponse
Deletes the user based on the given request (sent to the API as JSON). This permanently deletes all information, metrics, reports and data associated with the user.
1388 1389 1390 1391 1392 1393 1394 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1388 def delete_user_with_request(user_id, request) start.uri('/api/user') .url_segment(user_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .delete .go end |
#delete_users(request) ⇒ FusionAuth::ClientResponse
This method has been renamed to delete_users_by_query, use that method instead.
Deletes the users with the given Ids, or users matching the provided JSON query or queryString. The order of preference is Ids, query and then queryString, it is recommended to only provide one of the three for the request.
This method can be used to deactivate or permanently delete (hard-delete) users based upon the hardDelete boolean in the request body. Using the dryRun parameter you may also request the result of the action without actually deleting or deactivating any users.
1406 1407 1408 1409 1410 1411 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1406 def delete_users(request) start.uri('/api/user/bulk') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .delete .go end |
#delete_users_by_query(request) ⇒ FusionAuth::ClientResponse
Deletes the users with the given Ids, or users matching the provided JSON query or queryString. The order of preference is Ids, query and then queryString, it is recommended to only provide one of the three for the request.
This method can be used to deactivate or permanently delete (hard-delete) users based upon the hardDelete boolean in the request body. Using the dryRun parameter you may also request the result of the action without actually deleting or deactivating any users.
1422 1423 1424 1425 1426 1427 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1422 def delete_users_by_query(request) start.uri('/api/user/bulk') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .delete .go end |
#delete_web_authn_credential(id) ⇒ FusionAuth::ClientResponse
Deletes the WebAuthn credential for the given Id.
1434 1435 1436 1437 1438 1439 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1434 def delete_web_authn_credential(id) start.uri('/api/webauthn') .url_segment(id) .delete .go end |
#delete_web_authn_credentials_for_user(user_id) ⇒ FusionAuth::ClientResponse
Deletes all of the WebAuthn credentials for the given User Id.
1446 1447 1448 1449 1450 1451 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1446 def delete_web_authn_credentials_for_user(user_id) start.uri('/api/webauthn') .url_parameter('userId', user_id) .delete .go end |
#delete_webhook(webhook_id) ⇒ FusionAuth::ClientResponse
Deletes the webhook for the given Id.
1458 1459 1460 1461 1462 1463 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1458 def delete_webhook(webhook_id) start.uri('/api/webhook') .url_segment(webhook_id) .delete .go end |
#device_authorize(client_id, client_secret, scope) ⇒ FusionAuth::ClientResponse
Start the Device Authorization flow using form-encoded parameters
1472 1473 1474 1475 1476 1477 1478 1479 1480 1481 1482 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1472 def (client_id, client_secret, scope) form_parameters = { "client_id" => client_id, "client_secret" => client_secret, "scope" => scope, } startAnonymous.uri('/oauth2/device_authorize') .body_handler(FusionAuth::FormDataBodyHandler.new(form_parameters)) .post .go end |
#device_authorize_with_request(request) ⇒ FusionAuth::ClientResponse
Start the Device Authorization flow using a request body
1489 1490 1491 1492 1493 1494 1495 1496 1497 1498 1499 1500 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1489 def (request) form_parameters = { "client_id" => request.client_id, "client_secret" => request.client_secret, "scope" => request.scope, "tenantId" => (request.tenantId.to_s unless request.tenantId.nil?), } startAnonymous.uri('/oauth2/device_authorize') .body_handler(FusionAuth::FormDataBodyHandler.new(form_parameters)) .post .go end |
#disable_two_factor(user_id, method_id, code) ⇒ FusionAuth::ClientResponse
Disable two-factor authentication for a user.
1509 1510 1511 1512 1513 1514 1515 1516 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1509 def disable_two_factor(user_id, method_id, code) start.uri('/api/user/two-factor') .url_segment(user_id) .url_parameter('methodId', method_id) .url_parameter('code', code) .delete .go end |
#disable_two_factor_with_request(user_id, request) ⇒ FusionAuth::ClientResponse
Disable two-factor authentication for a user using a JSON body rather than URL parameters.
1524 1525 1526 1527 1528 1529 1530 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1524 def disable_two_factor_with_request(user_id, request) start.uri('/api/user/two-factor') .url_segment(user_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .delete .go end |
#enable_two_factor(user_id, request) ⇒ FusionAuth::ClientResponse
Enable two-factor authentication for a user.
1538 1539 1540 1541 1542 1543 1544 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1538 def enable_two_factor(user_id, request) start.uri('/api/user/two-factor') .url_segment(user_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#exchange_o_auth_code_for_access_token(code, client_id, client_secret, redirect_uri) ⇒ FusionAuth::ClientResponse
Exchanges an OAuth authorization code for an access token. Makes a request to the Token endpoint to exchange the authorization code returned from the Authorize endpoint for an access token.
1556 1557 1558 1559 1560 1561 1562 1563 1564 1565 1566 1567 1568 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1556 def exchange_o_auth_code_for_access_token(code, client_id, client_secret, redirect_uri) form_parameters = { "code" => code, "client_id" => client_id, "client_secret" => client_secret, "grant_type" => 'authorization_code', "redirect_uri" => redirect_uri, } startAnonymous.uri('/oauth2/token') .body_handler(FusionAuth::FormDataBodyHandler.new(form_parameters)) .post .go end |
#exchange_o_auth_code_for_access_token_using_pkce(code, client_id, client_secret, redirect_uri, code_verifier) ⇒ FusionAuth::ClientResponse
Exchanges an OAuth authorization code and code_verifier for an access token. Makes a request to the Token endpoint to exchange the authorization code returned from the Authorize endpoint and a code_verifier for an access token.
1581 1582 1583 1584 1585 1586 1587 1588 1589 1590 1591 1592 1593 1594 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1581 def exchange_o_auth_code_for_access_token_using_pkce(code, client_id, client_secret, redirect_uri, code_verifier) form_parameters = { "code" => code, "client_id" => client_id, "client_secret" => client_secret, "grant_type" => 'authorization_code', "redirect_uri" => redirect_uri, "code_verifier" => code_verifier, } startAnonymous.uri('/oauth2/token') .body_handler(FusionAuth::FormDataBodyHandler.new(form_parameters)) .post .go end |
#exchange_o_auth_code_for_access_token_using_pkce_with_request(request) ⇒ FusionAuth::ClientResponse
Exchanges an OAuth authorization code and code_verifier for an access token. Makes a request to the Token endpoint to exchange the authorization code returned from the Authorize endpoint and a code_verifier for an access token.
1602 1603 1604 1605 1606 1607 1608 1609 1610 1611 1612 1613 1614 1615 1616 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1602 def exchange_o_auth_code_for_access_token_using_pkce_with_request(request) form_parameters = { "client_id" => request.client_id, "client_secret" => request.client_secret, "code" => request.code, "code_verifier" => request.code_verifier, "grant_type" => request.grant_type, "redirect_uri" => request.redirect_uri, "tenantId" => (request.tenantId.to_s unless request.tenantId.nil?), } startAnonymous.uri('/oauth2/token') .body_handler(FusionAuth::FormDataBodyHandler.new(form_parameters)) .post .go end |
#exchange_o_auth_code_for_access_token_with_request(request) ⇒ FusionAuth::ClientResponse
Exchanges an OAuth authorization code for an access token. Makes a request to the Token endpoint to exchange the authorization code returned from the Authorize endpoint for an access token.
1624 1625 1626 1627 1628 1629 1630 1631 1632 1633 1634 1635 1636 1637 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1624 def exchange_o_auth_code_for_access_token_with_request(request) form_parameters = { "client_id" => request.client_id, "client_secret" => request.client_secret, "code" => request.code, "grant_type" => request.grant_type, "redirect_uri" => request.redirect_uri, "tenantId" => request.tenantId, } startAnonymous.uri('/oauth2/token') .body_handler(FusionAuth::FormDataBodyHandler.new(form_parameters)) .post .go end |
#exchange_refresh_token_for_access_token(refresh_token, client_id, client_secret, scope, user_code) ⇒ FusionAuth::ClientResponse
Exchange a Refresh Token for an Access Token. If you will be using the Refresh Token Grant, you will make a request to the Token endpoint to exchange the user’s refresh token for an access token.
1650 1651 1652 1653 1654 1655 1656 1657 1658 1659 1660 1661 1662 1663 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1650 def exchange_refresh_token_for_access_token(refresh_token, client_id, client_secret, scope, user_code) form_parameters = { "refresh_token" => refresh_token, "client_id" => client_id, "client_secret" => client_secret, "grant_type" => 'refresh_token', "scope" => scope, "user_code" => user_code, } startAnonymous.uri('/oauth2/token') .body_handler(FusionAuth::FormDataBodyHandler.new(form_parameters)) .post .go end |
#exchange_refresh_token_for_access_token_with_request(request) ⇒ FusionAuth::ClientResponse
Exchange a Refresh Token for an Access Token. If you will be using the Refresh Token Grant, you will make a request to the Token endpoint to exchange the user’s refresh token for an access token.
1671 1672 1673 1674 1675 1676 1677 1678 1679 1680 1681 1682 1683 1684 1685 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1671 def exchange_refresh_token_for_access_token_with_request(request) form_parameters = { "client_id" => request.client_id, "client_secret" => request.client_secret, "grant_type" => request.grant_type, "refresh_token" => request.refresh_token, "scope" => request.scope, "tenantId" => (request.tenantId.to_s unless request.tenantId.nil?), "user_code" => request.user_code, } startAnonymous.uri('/oauth2/token') .body_handler(FusionAuth::FormDataBodyHandler.new(form_parameters)) .post .go end |
#exchange_refresh_token_for_jwt(request) ⇒ FusionAuth::ClientResponse
Exchange a refresh token for a new JWT.
1692 1693 1694 1695 1696 1697 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1692 def exchange_refresh_token_for_jwt(request) startAnonymous.uri('/api/jwt/refresh') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#exchange_user_credentials_for_access_token(username, password, client_id, client_secret, scope, user_code) ⇒ FusionAuth::ClientResponse
Exchange User Credentials for a Token. If you will be using the Resource Owner Password Credential Grant, you will make a request to the Token endpoint to exchange the user’s email and password for an access token.
1711 1712 1713 1714 1715 1716 1717 1718 1719 1720 1721 1722 1723 1724 1725 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1711 def exchange_user_credentials_for_access_token(username, password, client_id, client_secret, scope, user_code) form_parameters = { "username" => username, "password" => password, "client_id" => client_id, "client_secret" => client_secret, "grant_type" => 'password', "scope" => scope, "user_code" => user_code, } startAnonymous.uri('/oauth2/token') .body_handler(FusionAuth::FormDataBodyHandler.new(form_parameters)) .post .go end |
#exchange_user_credentials_for_access_token_with_request(request) ⇒ FusionAuth::ClientResponse
Exchange User Credentials for a Token. If you will be using the Resource Owner Password Credential Grant, you will make a request to the Token endpoint to exchange the user’s email and password for an access token.
1733 1734 1735 1736 1737 1738 1739 1740 1741 1742 1743 1744 1745 1746 1747 1748 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1733 def exchange_user_credentials_for_access_token_with_request(request) form_parameters = { "client_id" => request.client_id, "client_secret" => request.client_secret, "grant_type" => request.grant_type, "password" => request.password, "scope" => request.scope, "tenantId" => request.tenantId, "user_code" => request.user_code, "username" => request.username, } startAnonymous.uri('/oauth2/token') .body_handler(FusionAuth::FormDataBodyHandler.new(form_parameters)) .post .go end |
#forgot_password(request) ⇒ FusionAuth::ClientResponse
Begins the forgot password sequence, which kicks off an email to the user so that they can reset their password.
1755 1756 1757 1758 1759 1760 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1755 def forgot_password(request) start.uri('/api/user/forgot-password') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#generate_email_verification_id(email) ⇒ FusionAuth::ClientResponse
Generate a new Email Verification Id to be used with the Verify Email API. This API will not attempt to send an email to the User. This API may be used to collect the verificationId for use with a third party system.
1768 1769 1770 1771 1772 1773 1774 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1768 def generate_email_verification_id(email) start.uri('/api/user/verify-email') .url_parameter('email', email) .url_parameter('sendVerifyEmail', false) .put .go end |
#generate_key(key_id, request) ⇒ FusionAuth::ClientResponse
Generate a new RSA or EC key pair or an HMAC secret.
1782 1783 1784 1785 1786 1787 1788 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1782 def generate_key(key_id, request) start.uri('/api/key/generate') .url_segment(key_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#generate_registration_verification_id(email, application_id) ⇒ FusionAuth::ClientResponse
Generate a new Application Registration Verification Id to be used with the Verify Registration API. This API will not attempt to send an email to the User. This API may be used to collect the verificationId for use with a third party system.
1797 1798 1799 1800 1801 1802 1803 1804 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1797 def generate_registration_verification_id(email, application_id) start.uri('/api/user/verify-registration') .url_parameter('email', email) .url_parameter('sendVerifyPasswordEmail', false) .url_parameter('applicationId', application_id) .put .go end |
#generate_two_factor_recovery_codes(user_id) ⇒ FusionAuth::ClientResponse
Generate two-factor recovery codes for a user. Generating two-factor recovery codes will invalidate any existing recovery codes.
1811 1812 1813 1814 1815 1816 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1811 def generate_two_factor_recovery_codes(user_id) start.uri('/api/user/two-factor/recovery-code') .url_segment(user_id) .post .go end |
#generate_two_factor_secret ⇒ FusionAuth::ClientResponse
Generate a Two Factor secret that can be used to enable Two Factor authentication for a User. The response will contain both the secret and a Base32 encoded form of the secret which can be shown to a User when using a 2 Step Authentication application such as Google Authenticator.
1824 1825 1826 1827 1828 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1824 def generate_two_factor_secret start.uri('/api/two-factor/secret') .get .go end |
#generate_two_factor_secret_using_jwt(encoded_jwt) ⇒ FusionAuth::ClientResponse
Generate a Two Factor secret that can be used to enable Two Factor authentication for a User. The response will contain both the secret and a Base32 encoded form of the secret which can be shown to a User when using a 2 Step Authentication application such as Google Authenticator.
1837 1838 1839 1840 1841 1842 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1837 def generate_two_factor_secret_using_jwt(encoded_jwt) startAnonymous.uri('/api/two-factor/secret') .('Bearer ' + encoded_jwt) .get .go end |
#identity_provider_login(request) ⇒ FusionAuth::ClientResponse
Handles login via third-parties including Social login, external OAuth and OpenID Connect, and other login systems.
1851 1852 1853 1854 1855 1856 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1851 def identity_provider_login(request) startAnonymous.uri('/api/identity-provider/login') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#import_key(key_id, request) ⇒ FusionAuth::ClientResponse
Import an existing RSA or EC key pair or an HMAC secret.
1864 1865 1866 1867 1868 1869 1870 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1864 def import_key(key_id, request) start.uri('/api/key/import') .url_segment(key_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#import_refresh_tokens(request) ⇒ FusionAuth::ClientResponse
Bulk imports refresh tokens. This request performs minimal validation and runs batch inserts of refresh tokens with the expectation that each token represents a user that already exists and is registered for the corresponding FusionAuth Application. This is done to increases the insert performance.
Therefore, if you encounter an error due to a database key violation, the response will likely offer a generic explanation. If you encounter an error, you may optionally enable additional validation to receive a JSON response body with specific validation errors. This will slow the request down but will allow you to identify the cause of the failure. See the validateDbConstraints request parameter.
1884 1885 1886 1887 1888 1889 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1884 def import_refresh_tokens(request) start.uri('/api/user/refresh-token/import') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#import_users(request) ⇒ FusionAuth::ClientResponse
Bulk imports users. This request performs minimal validation and runs batch inserts of users with the expectation that each user does not yet exist and each registration corresponds to an existing FusionAuth Application. This is done to increases the insert performance.
Therefore, if you encounter an error due to a database key violation, the response will likely offer a generic explanation. If you encounter an error, you may optionally enable additional validation to receive a JSON response body with specific validation errors. This will slow the request down but will allow you to identify the cause of the failure. See the validateDbConstraints request parameter.
1903 1904 1905 1906 1907 1908 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1903 def import_users(request) start.uri('/api/user/import') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#import_web_authn_credential(request) ⇒ FusionAuth::ClientResponse
Import a WebAuthn credential
1915 1916 1917 1918 1919 1920 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1915 def import_web_authn_credential(request) start.uri('/api/webauthn/import') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#introspect_access_token(client_id, token) ⇒ FusionAuth::ClientResponse
Inspect an access token issued as the result of the User based grant such as the Authorization Code Grant, Implicit Grant, the User Credentials Grant or the Refresh Grant.
1928 1929 1930 1931 1932 1933 1934 1935 1936 1937 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1928 def introspect_access_token(client_id, token) form_parameters = { "client_id" => client_id, "token" => token, } startAnonymous.uri('/oauth2/introspect') .body_handler(FusionAuth::FormDataBodyHandler.new(form_parameters)) .post .go end |
#introspect_access_token_with_request(request) ⇒ FusionAuth::ClientResponse
Inspect an access token issued as the result of the User based grant such as the Authorization Code Grant, Implicit Grant, the User Credentials Grant or the Refresh Grant.
1944 1945 1946 1947 1948 1949 1950 1951 1952 1953 1954 1955 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1944 def introspect_access_token_with_request(request) form_parameters = { "client_id" => request.client_id, "tenantId" => request.tenantId, "token" => request.token, "token_type_hint" => request.token_type_hint, } startAnonymous.uri('/oauth2/introspect') .body_handler(FusionAuth::FormDataBodyHandler.new(form_parameters)) .post .go end |
#introspect_client_credentials_access_token(token) ⇒ FusionAuth::ClientResponse
Inspect an access token issued as the result of the Client Credentials Grant.
1962 1963 1964 1965 1966 1967 1968 1969 1970 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1962 def introspect_client_credentials_access_token(token) form_parameters = { "token" => token, } startAnonymous.uri('/oauth2/introspect') .body_handler(FusionAuth::FormDataBodyHandler.new(form_parameters)) .post .go end |
#introspect_client_credentials_access_token_with_request(request) ⇒ FusionAuth::ClientResponse
Inspect an access token issued as the result of the Client Credentials Grant.
1977 1978 1979 1980 1981 1982 1983 1984 1985 1986 |
# File 'lib/fusionauth/fusionauth_client.rb', line 1977 def introspect_client_credentials_access_token_with_request(request) form_parameters = { "tenantId" => request.tenantId, "token" => request.token, } startAnonymous.uri('/oauth2/introspect') .body_handler(FusionAuth::FormDataBodyHandler.new(form_parameters)) .post .go end |
#issue_jwt(application_id, encoded_jwt, refresh_token) ⇒ FusionAuth::ClientResponse
Issue a new access token (JWT) for the requested Application after ensuring the provided JWT is valid. A valid access token is properly signed and not expired. <p> This API may be used in an SSO configuration to issue new tokens for another application after the user has obtained a valid token from authentication.
2001 2002 2003 2004 2005 2006 2007 2008 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2001 def issue_jwt(application_id, encoded_jwt, refresh_token) startAnonymous.uri('/api/jwt/issue') .('Bearer ' + encoded_jwt) .url_parameter('applicationId', application_id) .url_parameter('refreshToken', refresh_token) .get .go end |
#login(request) ⇒ FusionAuth::ClientResponse
Authenticates a user to FusionAuth.
This API optionally requires an API key. See Application.loginConfiguration.requireAuthentication.
2017 2018 2019 2020 2021 2022 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2017 def login(request) start.uri('/api/login') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#login_ping(user_id, application_id, caller_ip_address) ⇒ FusionAuth::ClientResponse
Sends a ping to FusionAuth indicating that the user was automatically logged into an application. When using FusionAuth’s SSO or your own, you should call this if the user is already logged in centrally, but accesses an application where they no longer have a session. This helps correctly track login counts, times and helps with reporting.
2035 2036 2037 2038 2039 2040 2041 2042 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2035 def login_ping(user_id, application_id, caller_ip_address) start.uri('/api/login') .url_segment(user_id) .url_segment(application_id) .url_parameter('ipAddress', caller_ip_address) .put .go end |
#login_ping_with_request(request) ⇒ FusionAuth::ClientResponse
Sends a ping to FusionAuth indicating that the user was automatically logged into an application. When using FusionAuth’s SSO or your own, you should call this if the user is already logged in centrally, but accesses an application where they no longer have a session. This helps correctly track login counts, times and helps with reporting.
2052 2053 2054 2055 2056 2057 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2052 def login_ping_with_request(request) start.uri('/api/login') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .put .go end |
#logout(global, refresh_token) ⇒ FusionAuth::ClientResponse
The Logout API is intended to be used to remove the refresh token and access token cookies if they exist on the client and revoke the refresh token stored. This API does nothing if the request does not contain an access token or refresh token cookies.
2069 2070 2071 2072 2073 2074 2075 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2069 def logout(global, refresh_token) startAnonymous.uri('/api/logout') .url_parameter('global', global) .url_parameter('refreshToken', refresh_token) .post .go end |
#logout_with_request(request) ⇒ FusionAuth::ClientResponse
The Logout API is intended to be used to remove the refresh token and access token cookies if they exist on the client and revoke the refresh token stored. This API takes the refresh token in the JSON body.
2083 2084 2085 2086 2087 2088 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2083 def logout_with_request(request) startAnonymous.uri('/api/logout') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#lookup_identity_provider(domain) ⇒ FusionAuth::ClientResponse
Retrieves any global identity providers for the given domain. A 200 response code indicates the domain is managed by a registered identity provider. A 404 indicates the domain is not managed.
2096 2097 2098 2099 2100 2101 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2096 def lookup_identity_provider(domain) start.uri('/api/identity-provider/lookup') .url_parameter('domain', domain) .get .go end |
#lookup_identity_provider_by_tenant_id(domain, tenant_id) ⇒ FusionAuth::ClientResponse
Retrieves the identity provider for the given domain and tenantId. A 200 response code indicates the domain is managed by a registered identity provider. A 404 indicates the domain is not managed.
2111 2112 2113 2114 2115 2116 2117 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2111 def lookup_identity_provider_by_tenant_id(domain, tenant_id) start.uri('/api/identity-provider/lookup') .url_parameter('domain', domain) .url_parameter('tenantId', tenant_id) .get .go end |
#modify_action(action_id, request) ⇒ FusionAuth::ClientResponse
Modifies a temporal user action by changing the expiration of the action and optionally adding a comment to the action.
2126 2127 2128 2129 2130 2131 2132 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2126 def modify_action(action_id, request) start.uri('/api/user/action') .url_segment(action_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .put .go end |
#passwordless_login(request) ⇒ FusionAuth::ClientResponse
Complete a login request using a passwordless code
2139 2140 2141 2142 2143 2144 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2139 def passwordless_login(request) startAnonymous.uri('/api/passwordless/login') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#patch_api_key(key_id, request) ⇒ FusionAuth::ClientResponse
Updates an API key with the given Id.
2152 2153 2154 2155 2156 2157 2158 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2152 def patch_api_key(key_id, request) start.uri('/api/api-key') .url_segment(key_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .patch .go end |
#patch_application(application_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the application with the given Id.
2166 2167 2168 2169 2170 2171 2172 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2166 def patch_application(application_id, request) start.uri('/api/application') .url_segment(application_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .patch .go end |
#patch_application_role(application_id, role_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the application role with the given Id for the application.
2181 2182 2183 2184 2185 2186 2187 2188 2189 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2181 def patch_application_role(application_id, role_id, request) start.uri('/api/application') .url_segment(application_id) .url_segment("role") .url_segment(role_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .patch .go end |
#patch_connector(connector_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the connector with the given Id.
2197 2198 2199 2200 2201 2202 2203 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2197 def patch_connector(connector_id, request) start.uri('/api/connector') .url_segment(connector_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .patch .go end |
#patch_consent(consent_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the consent with the given Id.
2211 2212 2213 2214 2215 2216 2217 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2211 def (, request) start.uri('/api/consent') .url_segment() .body_handler(FusionAuth::JSONBodyHandler.new(request)) .patch .go end |
#patch_email_template(email_template_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the email template with the given Id.
2225 2226 2227 2228 2229 2230 2231 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2225 def patch_email_template(email_template_id, request) start.uri('/api/email/template') .url_segment(email_template_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .patch .go end |
#patch_entity(entity_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the Entity with the given Id.
2239 2240 2241 2242 2243 2244 2245 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2239 def patch_entity(entity_id, request) start.uri('/api/entity') .url_segment(entity_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .patch .go end |
#patch_entity_type(entity_type_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the Entity Type with the given Id.
2253 2254 2255 2256 2257 2258 2259 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2253 def patch_entity_type(entity_type_id, request) start.uri('/api/entity/type') .url_segment(entity_type_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .patch .go end |
#patch_entity_type_permission(entity_type_id, permission_id, request) ⇒ FusionAuth::ClientResponse
Patches the permission with the given Id for the entity type.
2268 2269 2270 2271 2272 2273 2274 2275 2276 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2268 def (entity_type_id, , request) start.uri('/api/entity/type') .url_segment(entity_type_id) .url_segment("permission") .url_segment() .body_handler(FusionAuth::JSONBodyHandler.new(request)) .patch .go end |
#patch_form(form_id, request) ⇒ FusionAuth::ClientResponse
Patches the form with the given Id.
2284 2285 2286 2287 2288 2289 2290 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2284 def patch_form(form_id, request) start.uri('/api/form') .url_segment(form_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .patch .go end |
#patch_form_field(field_id, request) ⇒ FusionAuth::ClientResponse
Patches the form field with the given Id.
2298 2299 2300 2301 2302 2303 2304 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2298 def patch_form_field(field_id, request) start.uri('/api/form/field') .url_segment(field_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .patch .go end |
#patch_group(group_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the group with the given Id.
2312 2313 2314 2315 2316 2317 2318 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2312 def patch_group(group_id, request) start.uri('/api/group') .url_segment(group_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .patch .go end |
#patch_identity_provider(identity_provider_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the identity provider with the given Id.
2340 2341 2342 2343 2344 2345 2346 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2340 def patch_identity_provider(identity_provider_id, request) start.uri('/api/identity-provider') .url_segment(identity_provider_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .patch .go end |
#patch_integrations(request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the available integrations.
2353 2354 2355 2356 2357 2358 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2353 def patch_integrations(request) start.uri('/api/integration') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .patch .go end |
#patch_ip_access_control_list(access_control_list_id, request) ⇒ FusionAuth::ClientResponse
Update the IP Access Control List with the given Id.
2326 2327 2328 2329 2330 2331 2332 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2326 def patch_ip_access_control_list(access_control_list_id, request) start.uri('/api/ip-acl') .url_segment(access_control_list_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .patch .go end |
#patch_lambda(lambda_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the lambda with the given Id.
2366 2367 2368 2369 2370 2371 2372 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2366 def patch_lambda(lambda_id, request) start.uri('/api/lambda') .url_segment(lambda_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .patch .go end |
#patch_message_template(message_template_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the message template with the given Id.
2380 2381 2382 2383 2384 2385 2386 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2380 def (, request) start.uri('/api/message/template') .url_segment() .body_handler(FusionAuth::JSONBodyHandler.new(request)) .patch .go end |
#patch_messenger(messenger_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the messenger with the given Id.
2394 2395 2396 2397 2398 2399 2400 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2394 def patch_messenger(messenger_id, request) start.uri('/api/messenger') .url_segment(messenger_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .patch .go end |
#patch_o_auth_scope(application_id, scope_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the custom OAuth scope with the given Id for the application.
2409 2410 2411 2412 2413 2414 2415 2416 2417 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2409 def patch_o_auth_scope(application_id, scope_id, request) start.uri('/api/application') .url_segment(application_id) .url_segment("scope") .url_segment(scope_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .patch .go end |
#patch_registration(user_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the registration for the user with the given Id and the application defined in the request.
2425 2426 2427 2428 2429 2430 2431 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2425 def patch_registration(user_id, request) start.uri('/api/user/registration') .url_segment(user_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .patch .go end |
#patch_system_configuration(request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the system configuration.
2438 2439 2440 2441 2442 2443 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2438 def patch_system_configuration(request) start.uri('/api/system-configuration') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .patch .go end |
#patch_tenant(tenant_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the tenant with the given Id.
2451 2452 2453 2454 2455 2456 2457 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2451 def patch_tenant(tenant_id, request) start.uri('/api/tenant') .url_segment(tenant_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .patch .go end |
#patch_tenant_manager_configuration(request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the Tenant Manager configuration.
2464 2465 2466 2467 2468 2469 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2464 def patch_tenant_manager_configuration(request) start.uri('/api/tenant-manager') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .patch .go end |
#patch_tenant_manager_identity_provider_type_configuration(type, request) ⇒ FusionAuth::ClientResponse
Patches the tenant manager identity provider type configuration for the given identity provider type.
2477 2478 2479 2480 2481 2482 2483 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2477 def patch_tenant_manager_identity_provider_type_configuration(type, request) start.uri('/api/tenant-manager/identity-provider') .url_segment(type) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .patch .go end |
#patch_theme(theme_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the theme with the given Id.
2491 2492 2493 2494 2495 2496 2497 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2491 def patch_theme(theme_id, request) start.uri('/api/theme') .url_segment(theme_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .patch .go end |
#patch_user(user_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the user with the given Id.
2505 2506 2507 2508 2509 2510 2511 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2505 def patch_user(user_id, request) start.uri('/api/user') .url_segment(user_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .patch .go end |
#patch_user_action(user_action_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the user action with the given Id.
2519 2520 2521 2522 2523 2524 2525 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2519 def patch_user_action(user_action_id, request) start.uri('/api/user-action') .url_segment(user_action_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .patch .go end |
#patch_user_action_reason(user_action_reason_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, the user action reason with the given Id.
2533 2534 2535 2536 2537 2538 2539 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2533 def patch_user_action_reason(user_action_reason_id, request) start.uri('/api/user-action-reason') .url_segment(user_action_reason_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .patch .go end |
#patch_user_consent(user_consent_id, request) ⇒ FusionAuth::ClientResponse
Updates, via PATCH, a single User consent by Id.
2547 2548 2549 2550 2551 2552 2553 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2547 def (, request) start.uri('/api/user/consent') .url_segment() .body_handler(FusionAuth::JSONBodyHandler.new(request)) .patch .go end |
#patch_webhook(webhook_id, request) ⇒ FusionAuth::ClientResponse
Patches the webhook with the given Id.
2561 2562 2563 2564 2565 2566 2567 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2561 def patch_webhook(webhook_id, request) start.uri('/api/webhook') .url_segment(webhook_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .patch .go end |
#reactivate_application(application_id) ⇒ FusionAuth::ClientResponse
Reactivates the application with the given Id.
2574 2575 2576 2577 2578 2579 2580 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2574 def reactivate_application(application_id) start.uri('/api/application') .url_segment(application_id) .url_parameter('reactivate', true) .put .go end |
#reactivate_user(user_id) ⇒ FusionAuth::ClientResponse
Reactivates the user with the given Id.
2587 2588 2589 2590 2591 2592 2593 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2587 def reactivate_user(user_id) start.uri('/api/user') .url_segment(user_id) .url_parameter('reactivate', true) .put .go end |
#reactivate_user_action(user_action_id) ⇒ FusionAuth::ClientResponse
Reactivates the user action with the given Id.
2600 2601 2602 2603 2604 2605 2606 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2600 def reactivate_user_action(user_action_id) start.uri('/api/user-action') .url_segment(user_action_id) .url_parameter('reactivate', true) .put .go end |
#reconcile_jwt(request) ⇒ FusionAuth::ClientResponse
Reconcile a User to FusionAuth using JWT issued from another Identity Provider.
2613 2614 2615 2616 2617 2618 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2613 def reconcile_jwt(request) startAnonymous.uri('/api/jwt/reconcile') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#refresh_entity_search_index ⇒ FusionAuth::ClientResponse
Request a refresh of the Entity search index. This API is not generally necessary and the search index will become consistent in a reasonable amount of time. There may be scenarios where you may wish to manually request an index refresh. One example may be if you are using the Search API or Delete Tenant API immediately following a Entity Create etc, you may wish to request a refresh to
ensure the index immediately current before making a query request to the search index.
2627 2628 2629 2630 2631 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2627 def refresh_entity_search_index start.uri('/api/entity/search') .put .go end |
#refresh_user_search_index ⇒ FusionAuth::ClientResponse
Request a refresh of the User search index. This API is not generally necessary and the search index will become consistent in a reasonable amount of time. There may be scenarios where you may wish to manually request an index refresh. One example may be if you are using the Search API or Delete Tenant API immediately following a User Create etc, you may wish to request a refresh to
ensure the index immediately current before making a query request to the search index.
2640 2641 2642 2643 2644 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2640 def refresh_user_search_index start.uri('/api/user/search') .put .go end |
#regenerate_reactor_keys ⇒ FusionAuth::ClientResponse
Regenerates any keys that are used by the FusionAuth Reactor.
2650 2651 2652 2653 2654 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2650 def regenerate_reactor_keys start.uri('/api/reactor') .put .go end |
#register(user_id, request) ⇒ FusionAuth::ClientResponse
Registers a user for an application. If you provide the User and the UserRegistration object on this request, it will create the user as well as register them for the application. This is called a Full Registration. However, if you only provide the UserRegistration object, then the user must already exist and they will be registered for the application. The user Id can also be provided and it will either be used to look up an existing user or it will be used for the newly created User.
2666 2667 2668 2669 2670 2671 2672 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2666 def register(user_id, request) start.uri('/api/user/registration') .url_segment(user_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#reindex(request) ⇒ FusionAuth::ClientResponse
Requests Elasticsearch to delete and rebuild the index for FusionAuth users or entities. Be very careful when running this request as it will increase the CPU and I/O load on your database until the operation completes. Generally speaking you do not ever need to run this operation unless instructed by FusionAuth support, or if you are migrating a database another system and you are not brining along the Elasticsearch index.
You have been warned.
2683 2684 2685 2686 2687 2688 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2683 def reindex(request) start.uri('/api/system/reindex') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#remove_user_from_family(family_id, user_id) ⇒ FusionAuth::ClientResponse
Removes a user from the family with the given Id.
2696 2697 2698 2699 2700 2701 2702 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2696 def remove_user_from_family(family_id, user_id) start.uri('/api/user/family') .url_segment(family_id) .url_segment(user_id) .delete .go end |
#resend_email_verification(email) ⇒ FusionAuth::ClientResponse
Re-sends the verification email to the user.
2709 2710 2711 2712 2713 2714 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2709 def resend_email_verification(email) start.uri('/api/user/verify-email') .url_parameter('email', email) .put .go end |
#resend_email_verification_with_application_template(application_id, email) ⇒ FusionAuth::ClientResponse
Re-sends the verification email to the user. If the Application has configured a specific email template this will be used instead of the tenant configuration.
2723 2724 2725 2726 2727 2728 2729 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2723 def resend_email_verification_with_application_template(application_id, email) start.uri('/api/user/verify-email') .url_parameter('applicationId', application_id) .url_parameter('email', email) .put .go end |
#resend_registration_verification(email, application_id) ⇒ FusionAuth::ClientResponse
Re-sends the application registration verification email to the user.
2737 2738 2739 2740 2741 2742 2743 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2737 def resend_registration_verification(email, application_id) start.uri('/api/user/verify-registration') .url_parameter('email', email) .url_parameter('applicationId', application_id) .put .go end |
#retrieve_action(action_id) ⇒ FusionAuth::ClientResponse
Retrieves a single action log (the log of a user action that was taken on a user previously) for the given Id.
2762 2763 2764 2765 2766 2767 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2762 def retrieve_action(action_id) start.uri('/api/user/action') .url_segment(action_id) .get .go end |
#retrieve_actions(user_id) ⇒ FusionAuth::ClientResponse
Retrieves all the actions for the user with the given Id. This will return all time based actions that are active, and inactive as well as non-time based actions.
2775 2776 2777 2778 2779 2780 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2775 def retrieve_actions(user_id) start.uri('/api/user/action') .url_parameter('userId', user_id) .get .go end |
#retrieve_actions_preventing_login(user_id) ⇒ FusionAuth::ClientResponse
Retrieves all the actions for the user with the given Id that are currently preventing the User from logging in.
2787 2788 2789 2790 2791 2792 2793 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2787 def retrieve_actions_preventing_login(user_id) start.uri('/api/user/action') .url_parameter('userId', user_id) .url_parameter('preventingLogin', true) .get .go end |
#retrieve_active_actions(user_id) ⇒ FusionAuth::ClientResponse
Retrieves all the actions for the user with the given Id that are currently active. An active action means one that is time based and has not been canceled, and has not ended.
2801 2802 2803 2804 2805 2806 2807 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2801 def retrieve_active_actions(user_id) start.uri('/api/user/action') .url_parameter('userId', user_id) .url_parameter('active', true) .get .go end |
#retrieve_api_key(key_id) ⇒ FusionAuth::ClientResponse
Retrieves an authentication API key for the given Id.
2750 2751 2752 2753 2754 2755 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2750 def retrieve_api_key(key_id) start.uri('/api/api-key') .url_segment(key_id) .get .go end |
#retrieve_application(application_id) ⇒ FusionAuth::ClientResponse
Retrieves the application for the given Id or all the applications if the Id is null.
2814 2815 2816 2817 2818 2819 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2814 def retrieve_application(application_id) start.uri('/api/application') .url_segment(application_id) .get .go end |
#retrieve_applications ⇒ FusionAuth::ClientResponse
Retrieves all the applications.
2825 2826 2827 2828 2829 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2825 def retrieve_applications start.uri('/api/application') .get .go end |
#retrieve_audit_log(audit_log_id) ⇒ FusionAuth::ClientResponse
Retrieves a single audit log for the given Id.
2836 2837 2838 2839 2840 2841 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2836 def retrieve_audit_log(audit_log_id) start.uri('/api/system/audit-log') .url_segment(audit_log_id) .get .go end |
#retrieve_connector(connector_id) ⇒ FusionAuth::ClientResponse
Retrieves the connector with the given Id.
2848 2849 2850 2851 2852 2853 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2848 def retrieve_connector(connector_id) start.uri('/api/connector') .url_segment(connector_id) .get .go end |
#retrieve_connectors ⇒ FusionAuth::ClientResponse
Retrieves all the connectors.
2859 2860 2861 2862 2863 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2859 def retrieve_connectors start.uri('/api/connector') .get .go end |
#retrieve_consent(consent_id) ⇒ FusionAuth::ClientResponse
Retrieves the Consent for the given Id.
2870 2871 2872 2873 2874 2875 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2870 def () start.uri('/api/consent') .url_segment() .get .go end |
#retrieve_consents ⇒ FusionAuth::ClientResponse
Retrieves all the consent.
2881 2882 2883 2884 2885 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2881 def start.uri('/api/consent') .get .go end |
#retrieve_daily_active_report(application_id, start, _end) ⇒ FusionAuth::ClientResponse
Retrieves the daily active user report between the two instants. If you specify an application Id, it will only return the daily active counts for that application.
2895 2896 2897 2898 2899 2900 2901 2902 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2895 def retrieve_daily_active_report(application_id, start, _end) start.uri('/api/report/daily-active-user') .url_parameter('applicationId', application_id) .url_parameter('start', start) .url_parameter('end', _end) .get .go end |
#retrieve_email_template(email_template_id) ⇒ FusionAuth::ClientResponse
Retrieves the email template for the given Id. If you don’t specify the Id, this will return all the email templates.
2909 2910 2911 2912 2913 2914 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2909 def retrieve_email_template(email_template_id) start.uri('/api/email/template') .url_segment(email_template_id) .get .go end |
#retrieve_email_template_preview(request) ⇒ FusionAuth::ClientResponse
Creates a preview of the email template provided in the request. This allows you to preview an email template that hasn’t been saved to the database yet. The entire email template does not need to be provided on the request. This will create the preview based on whatever is given.
2923 2924 2925 2926 2927 2928 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2923 def retrieve_email_template_preview(request) start.uri('/api/email/template/preview') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#retrieve_email_templates ⇒ FusionAuth::ClientResponse
Retrieves all the email templates.
2934 2935 2936 2937 2938 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2934 def retrieve_email_templates start.uri('/api/email/template') .get .go end |
#retrieve_entity(entity_id) ⇒ FusionAuth::ClientResponse
Retrieves the Entity for the given Id.
2945 2946 2947 2948 2949 2950 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2945 def retrieve_entity(entity_id) start.uri('/api/entity') .url_segment(entity_id) .get .go end |
#retrieve_entity_grant(entity_id, recipient_entity_id, user_id) ⇒ FusionAuth::ClientResponse
Retrieves an Entity Grant for the given Entity and User/Entity.
2959 2960 2961 2962 2963 2964 2965 2966 2967 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2959 def retrieve_entity_grant(entity_id, recipient_entity_id, user_id) start.uri('/api/entity') .url_segment(entity_id) .url_segment("grant") .url_parameter('recipientEntityId', recipient_entity_id) .url_parameter('userId', user_id) .get .go end |
#retrieve_entity_type(entity_type_id) ⇒ FusionAuth::ClientResponse
Retrieves the Entity Type for the given Id.
2974 2975 2976 2977 2978 2979 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2974 def retrieve_entity_type(entity_type_id) start.uri('/api/entity/type') .url_segment(entity_type_id) .get .go end |
#retrieve_entity_types ⇒ FusionAuth::ClientResponse
Retrieves all the Entity Types.
2985 2986 2987 2988 2989 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2985 def retrieve_entity_types start.uri('/api/entity/type') .get .go end |
#retrieve_event_log(event_log_id) ⇒ FusionAuth::ClientResponse
Retrieves a single event log for the given Id.
2996 2997 2998 2999 3000 3001 |
# File 'lib/fusionauth/fusionauth_client.rb', line 2996 def retrieve_event_log(event_log_id) start.uri('/api/system/event-log') .url_segment(event_log_id) .get .go end |
#retrieve_families(user_id) ⇒ FusionAuth::ClientResponse
Retrieves all the families that a user belongs to.
3008 3009 3010 3011 3012 3013 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3008 def retrieve_families(user_id) start.uri('/api/user/family') .url_parameter('userId', user_id) .get .go end |
#retrieve_family_members_by_family_id(family_id) ⇒ FusionAuth::ClientResponse
Retrieves all the members of a family by the unique Family Id.
3020 3021 3022 3023 3024 3025 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3020 def retrieve_family_members_by_family_id(family_id) start.uri('/api/user/family') .url_segment(family_id) .get .go end |
#retrieve_form(form_id) ⇒ FusionAuth::ClientResponse
Retrieves the form with the given Id.
3032 3033 3034 3035 3036 3037 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3032 def retrieve_form(form_id) start.uri('/api/form') .url_segment(form_id) .get .go end |
#retrieve_form_field(field_id) ⇒ FusionAuth::ClientResponse
Retrieves the form field with the given Id.
3044 3045 3046 3047 3048 3049 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3044 def retrieve_form_field(field_id) start.uri('/api/form/field') .url_segment(field_id) .get .go end |
#retrieve_form_fields ⇒ FusionAuth::ClientResponse
Retrieves all the forms fields
3055 3056 3057 3058 3059 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3055 def retrieve_form_fields start.uri('/api/form/field') .get .go end |
#retrieve_forms ⇒ FusionAuth::ClientResponse
Retrieves all the forms.
3065 3066 3067 3068 3069 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3065 def retrieve_forms start.uri('/api/form') .get .go end |
#retrieve_group(group_id) ⇒ FusionAuth::ClientResponse
Retrieves the group for the given Id.
3076 3077 3078 3079 3080 3081 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3076 def retrieve_group(group_id) start.uri('/api/group') .url_segment(group_id) .get .go end |
#retrieve_groups ⇒ FusionAuth::ClientResponse
Retrieves all the groups.
3087 3088 3089 3090 3091 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3087 def retrieve_groups start.uri('/api/group') .get .go end |
#retrieve_identity_provider(identity_provider_id) ⇒ FusionAuth::ClientResponse
Retrieves the identity provider for the given Id or all the identity providers if the Id is null.
3110 3111 3112 3113 3114 3115 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3110 def retrieve_identity_provider(identity_provider_id) start.uri('/api/identity-provider') .url_segment(identity_provider_id) .get .go end |
#retrieve_identity_provider_by_type(type) ⇒ FusionAuth::ClientResponse
Retrieves one or more identity provider for the given type. For types such as Google, Facebook, Twitter and LinkedIn, only a single identity provider can exist. For types such as OpenID Connect and SAMLv2 more than one identity provider can be configured so this request may return multiple identity providers.
3124 3125 3126 3127 3128 3129 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3124 def retrieve_identity_provider_by_type(type) start.uri('/api/identity-provider') .url_parameter('type', type) .get .go end |
#retrieve_identity_provider_connection_test_results(connection_test_id) ⇒ FusionAuth::ClientResponse
Retrieves the results for an identity provider connection test.
3136 3137 3138 3139 3140 3141 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3136 def retrieve_identity_provider_connection_test_results(connection_test_id) start.uri('/api/identity-provider/test') .url_parameter('connectionTestId', connection_test_id) .get .go end |
#retrieve_identity_providers ⇒ FusionAuth::ClientResponse
Retrieves all the identity providers.
3147 3148 3149 3150 3151 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3147 def retrieve_identity_providers start.uri('/api/identity-provider') .get .go end |
#retrieve_inactive_actions(user_id) ⇒ FusionAuth::ClientResponse
Retrieves all the actions for the user with the given Id that are currently inactive. An inactive action means one that is time based and has been canceled or has expired, or is not time based.
3159 3160 3161 3162 3163 3164 3165 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3159 def retrieve_inactive_actions(user_id) start.uri('/api/user/action') .url_parameter('userId', user_id) .url_parameter('active', false) .get .go end |
#retrieve_inactive_applications ⇒ FusionAuth::ClientResponse
Retrieves all the applications that are currently inactive.
3171 3172 3173 3174 3175 3176 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3171 def retrieve_inactive_applications start.uri('/api/application') .url_parameter('inactive', true) .get .go end |
#retrieve_inactive_user_actions ⇒ FusionAuth::ClientResponse
Retrieves all the user actions that are currently inactive.
3182 3183 3184 3185 3186 3187 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3182 def retrieve_inactive_user_actions start.uri('/api/user-action') .url_parameter('inactive', true) .get .go end |
#retrieve_integration ⇒ FusionAuth::ClientResponse
Retrieves the available integrations.
3193 3194 3195 3196 3197 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3193 def retrieve_integration start.uri('/api/integration') .get .go end |
#retrieve_ip_access_control_list(ip_access_control_list_id) ⇒ FusionAuth::ClientResponse
Retrieves the IP Access Control List with the given Id.
3098 3099 3100 3101 3102 3103 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3098 def retrieve_ip_access_control_list(ip_access_control_list_id) start.uri('/api/ip-acl') .url_segment(ip_access_control_list_id) .get .go end |
#retrieve_json_web_key_set ⇒ FusionAuth::ClientResponse
Returns public keys used by FusionAuth to cryptographically verify JWTs using the JSON Web Key format.
3237 3238 3239 3240 3241 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3237 def retrieve_json_web_key_set startAnonymous.uri('/.well-known/jwks.json') .get .go end |
#retrieve_jwt_public_key(key_id) ⇒ FusionAuth::ClientResponse
Retrieves the Public Key configured for verifying JSON Web Tokens (JWT) by the key Id (kid).
3204 3205 3206 3207 3208 3209 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3204 def retrieve_jwt_public_key(key_id) startAnonymous.uri('/api/jwt/public-key') .url_parameter('kid', key_id) .get .go end |
#retrieve_jwt_public_key_by_application_id(application_id) ⇒ FusionAuth::ClientResponse
Retrieves the Public Key configured for verifying the JSON Web Tokens (JWT) issued by the Login API by the Application Id.
3216 3217 3218 3219 3220 3221 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3216 def retrieve_jwt_public_key_by_application_id(application_id) startAnonymous.uri('/api/jwt/public-key') .url_parameter('applicationId', application_id) .get .go end |
#retrieve_jwt_public_keys ⇒ FusionAuth::ClientResponse
Retrieves all Public Keys configured for verifying JSON Web Tokens (JWT).
3227 3228 3229 3230 3231 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3227 def retrieve_jwt_public_keys startAnonymous.uri('/api/jwt/public-key') .get .go end |
#retrieve_key(key_id) ⇒ FusionAuth::ClientResponse
Retrieves the key for the given Id.
3248 3249 3250 3251 3252 3253 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3248 def retrieve_key(key_id) start.uri('/api/key') .url_segment(key_id) .get .go end |
#retrieve_keys ⇒ FusionAuth::ClientResponse
Retrieves all the keys.
3259 3260 3261 3262 3263 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3259 def retrieve_keys start.uri('/api/key') .get .go end |
#retrieve_lambda(lambda_id) ⇒ FusionAuth::ClientResponse
Retrieves the lambda for the given Id.
3270 3271 3272 3273 3274 3275 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3270 def retrieve_lambda(lambda_id) start.uri('/api/lambda') .url_segment(lambda_id) .get .go end |
#retrieve_lambdas ⇒ FusionAuth::ClientResponse
Retrieves all the lambdas.
3281 3282 3283 3284 3285 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3281 def retrieve_lambdas start.uri('/api/lambda') .get .go end |
#retrieve_lambdas_by_type(type) ⇒ FusionAuth::ClientResponse
Retrieves all the lambdas for the provided type.
3292 3293 3294 3295 3296 3297 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3292 def retrieve_lambdas_by_type(type) start.uri('/api/lambda') .url_parameter('type', type) .get .go end |
#retrieve_login_report(application_id, start, _end) ⇒ FusionAuth::ClientResponse
Retrieves the login report between the two instants. If you specify an application Id, it will only return the login counts for that application.
3307 3308 3309 3310 3311 3312 3313 3314 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3307 def retrieve_login_report(application_id, start, _end) start.uri('/api/report/login') .url_parameter('applicationId', application_id) .url_parameter('start', start) .url_parameter('end', _end) .get .go end |
#retrieve_message_template(message_template_id) ⇒ FusionAuth::ClientResponse
Retrieves the message template for the given Id. If you don’t specify the Id, this will return all the message templates.
3321 3322 3323 3324 3325 3326 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3321 def () start.uri('/api/message/template') .url_segment() .get .go end |
#retrieve_message_template_preview(request) ⇒ FusionAuth::ClientResponse
Creates a preview of the message template provided in the request, normalized to a given locale.
3333 3334 3335 3336 3337 3338 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3333 def (request) start.uri('/api/message/template/preview') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#retrieve_message_templates ⇒ FusionAuth::ClientResponse
Retrieves all the message templates.
3344 3345 3346 3347 3348 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3344 def start.uri('/api/message/template') .get .go end |
#retrieve_messenger(messenger_id) ⇒ FusionAuth::ClientResponse
Retrieves the messenger with the given Id.
3355 3356 3357 3358 3359 3360 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3355 def retrieve_messenger(messenger_id) start.uri('/api/messenger') .url_segment(messenger_id) .get .go end |
#retrieve_messengers ⇒ FusionAuth::ClientResponse
Retrieves all the messengers.
3366 3367 3368 3369 3370 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3366 def retrieve_messengers start.uri('/api/messenger') .get .go end |
#retrieve_monthly_active_report(application_id, start, _end) ⇒ FusionAuth::ClientResponse
Retrieves the monthly active user report between the two instants. If you specify an application Id, it will only return the monthly active counts for that application.
3380 3381 3382 3383 3384 3385 3386 3387 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3380 def retrieve_monthly_active_report(application_id, start, _end) start.uri('/api/report/monthly-active-user') .url_parameter('applicationId', application_id) .url_parameter('start', start) .url_parameter('end', _end) .get .go end |
#retrieve_o_auth_scope(application_id, scope_id) ⇒ FusionAuth::ClientResponse
Retrieves a custom OAuth scope.
3395 3396 3397 3398 3399 3400 3401 3402 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3395 def retrieve_o_auth_scope(application_id, scope_id) start.uri('/api/application') .url_segment(application_id) .url_segment("scope") .url_segment(scope_id) .get .go end |
#retrieve_oauth_configuration(application_id) ⇒ FusionAuth::ClientResponse
Retrieves the Oauth2 configuration for the application for the given Application Id.
3409 3410 3411 3412 3413 3414 3415 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3409 def retrieve_oauth_configuration(application_id) start.uri('/api/application') .url_segment(application_id) .url_segment("oauth-configuration") .get .go end |
#retrieve_open_id_configuration ⇒ FusionAuth::ClientResponse
Returns the well known OpenID Configuration JSON document
3421 3422 3423 3424 3425 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3421 def retrieve_open_id_configuration startAnonymous.uri('/.well-known/openid-configuration') .get .go end |
#retrieve_password_validation_rules ⇒ FusionAuth::ClientResponse
Retrieves the password validation rules for a specific tenant. This method requires a tenantId to be provided through the use of a Tenant scoped API key or an HTTP header X-FusionAuth-TenantId to specify the Tenant Id.
This API does not require an API key.
3434 3435 3436 3437 3438 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3434 def retrieve_password_validation_rules startAnonymous.uri('/api/tenant/password-validation-rules') .get .go end |
#retrieve_password_validation_rules_with_tenant_id(tenant_id) ⇒ FusionAuth::ClientResponse
Retrieves the password validation rules for a specific tenant.
This API does not require an API key.
3447 3448 3449 3450 3451 3452 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3447 def retrieve_password_validation_rules_with_tenant_id(tenant_id) startAnonymous.uri('/api/tenant/password-validation-rules') .url_segment(tenant_id) .get .go end |
#retrieve_pending_children(parent_email) ⇒ FusionAuth::ClientResponse
Retrieves all the children for the given parent email address.
3459 3460 3461 3462 3463 3464 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3459 def retrieve_pending_children(parent_email) start.uri('/api/user/family/pending') .url_parameter('parentEmail', parent_email) .get .go end |
#retrieve_pending_link(pending_link_id, user_id) ⇒ FusionAuth::ClientResponse
Retrieve a pending identity provider link. This is useful to validate a pending link and retrieve meta-data about the identity provider link.
3472 3473 3474 3475 3476 3477 3478 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3472 def retrieve_pending_link(pending_link_id, user_id) start.uri('/api/identity-provider/link/pending') .url_segment(pending_link_id) .url_parameter('userId', user_id) .get .go end |
#retrieve_reactor_metrics ⇒ FusionAuth::ClientResponse
Retrieves the FusionAuth Reactor metrics.
3484 3485 3486 3487 3488 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3484 def retrieve_reactor_metrics start.uri('/api/reactor/metrics') .get .go end |
#retrieve_reactor_status ⇒ FusionAuth::ClientResponse
Retrieves the FusionAuth Reactor status.
3494 3495 3496 3497 3498 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3494 def retrieve_reactor_status start.uri('/api/reactor') .get .go end |
#retrieve_recent_logins(offset, limit) ⇒ FusionAuth::ClientResponse
Retrieves the last number of login records.
3506 3507 3508 3509 3510 3511 3512 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3506 def retrieve_recent_logins(offset, limit) start.uri('/api/user/recent-login') .url_parameter('offset', offset) .url_parameter('limit', limit) .get .go end |
#retrieve_refresh_token_by_id(token_id) ⇒ FusionAuth::ClientResponse
Retrieves a single refresh token by unique Id. This is not the same thing as the string value of the refresh token. If you have that, you already have what you need.
3519 3520 3521 3522 3523 3524 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3519 def retrieve_refresh_token_by_id(token_id) start.uri('/api/jwt/refresh') .url_segment(token_id) .get .go end |
#retrieve_refresh_tokens(user_id) ⇒ FusionAuth::ClientResponse
Retrieves the refresh tokens that belong to the user with the given Id.
3531 3532 3533 3534 3535 3536 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3531 def retrieve_refresh_tokens(user_id) start.uri('/api/jwt/refresh') .url_parameter('userId', user_id) .get .go end |
#retrieve_registration(user_id, application_id) ⇒ FusionAuth::ClientResponse
Retrieves the user registration for the user with the given Id and the given application Id.
3544 3545 3546 3547 3548 3549 3550 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3544 def retrieve_registration(user_id, application_id) start.uri('/api/user/registration') .url_segment(user_id) .url_segment(application_id) .get .go end |
#retrieve_registration_report(application_id, start, _end) ⇒ FusionAuth::ClientResponse
Retrieves the registration report between the two instants. If you specify an application Id, it will only return the registration counts for that application.
3560 3561 3562 3563 3564 3565 3566 3567 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3560 def retrieve_registration_report(application_id, start, _end) start.uri('/api/report/registration') .url_parameter('applicationId', application_id) .url_parameter('start', start) .url_parameter('end', _end) .get .go end |
#retrieve_reindex_status ⇒ FusionAuth::ClientResponse
Retrieve the status of a re-index process. A status code of 200 indicates the re-index is in progress, a status code of
404 indicates no re-index is in progress.
3574 3575 3576 3577 3578 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3574 def retrieve_reindex_status start.uri('/api/system/reindex') .get .go end |
#retrieve_system_configuration ⇒ FusionAuth::ClientResponse
Retrieves the system configuration.
3584 3585 3586 3587 3588 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3584 def retrieve_system_configuration start.uri('/api/system-configuration') .get .go end |
#retrieve_system_health ⇒ FusionAuth::ClientResponse
Retrieves the FusionAuth system health. This API will return 200 if the system is healthy, and 500 if the system is un-healthy.
3594 3595 3596 3597 3598 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3594 def retrieve_system_health startAnonymous.uri('/api/health') .get .go end |
#retrieve_system_status ⇒ FusionAuth::ClientResponse
Retrieves the FusionAuth system status. This request is anonymous and does not require an API key. When an API key is not provided the response will contain a single value in the JSON response indicating the current health check.
3604 3605 3606 3607 3608 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3604 def retrieve_system_status startAnonymous.uri('/api/status') .get .go end |
#retrieve_system_status_using_api_key ⇒ FusionAuth::ClientResponse
Retrieves the FusionAuth system status using an API key. Using an API key will cause the response to include the product version, health checks and various runtime metrics.
3614 3615 3616 3617 3618 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3614 def retrieve_system_status_using_api_key start.uri('/api/status') .get .go end |
#retrieve_tenant(tenant_id) ⇒ FusionAuth::ClientResponse
Retrieves the tenant for the given Id.
3625 3626 3627 3628 3629 3630 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3625 def retrieve_tenant(tenant_id) start.uri('/api/tenant') .url_segment(tenant_id) .get .go end |
#retrieve_tenant_manager_configuration ⇒ FusionAuth::ClientResponse
Retrieves the Tenant Manager configuration.
3636 3637 3638 3639 3640 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3636 def retrieve_tenant_manager_configuration start.uri('/api/tenant-manager') .get .go end |
#retrieve_tenants ⇒ FusionAuth::ClientResponse
Retrieves all the tenants.
3646 3647 3648 3649 3650 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3646 def retrieve_tenants start.uri('/api/tenant') .get .go end |
#retrieve_theme(theme_id) ⇒ FusionAuth::ClientResponse
Retrieves the theme for the given Id.
3657 3658 3659 3660 3661 3662 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3657 def retrieve_theme(theme_id) start.uri('/api/theme') .url_segment(theme_id) .get .go end |
#retrieve_themes ⇒ FusionAuth::ClientResponse
Retrieves all the themes.
3668 3669 3670 3671 3672 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3668 def retrieve_themes start.uri('/api/theme') .get .go end |
#retrieve_total_report ⇒ FusionAuth::ClientResponse
Retrieves the totals report. This contains all the total counts for each application and the global registration count.
3679 3680 3681 3682 3683 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3679 def retrieve_total_report start.uri('/api/report/totals') .get .go end |
#retrieve_total_report_with_excludes(excludes) ⇒ FusionAuth::ClientResponse
Retrieves the totals report. This allows excluding applicationTotals from the report. An empty list will include the applicationTotals.
3690 3691 3692 3693 3694 3695 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3690 def retrieve_total_report_with_excludes(excludes) start.uri('/api/report/totals') .url_parameter('excludes', excludes) .get .go end |
#retrieve_two_factor_recovery_codes(user_id) ⇒ FusionAuth::ClientResponse
Retrieve two-factor recovery codes for a user.
3702 3703 3704 3705 3706 3707 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3702 def retrieve_two_factor_recovery_codes(user_id) start.uri('/api/user/two-factor/recovery-code') .url_segment(user_id) .get .go end |
#retrieve_two_factor_status(user_id, application_id, two_factor_trust_id) ⇒ FusionAuth::ClientResponse
Retrieve a user’s two-factor status.
This can be used to see if a user will need to complete a two-factor challenge to complete a login, and optionally identify the state of the two-factor trust across various applications.
3719 3720 3721 3722 3723 3724 3725 3726 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3719 def retrieve_two_factor_status(user_id, application_id, two_factor_trust_id) start.uri('/api/two-factor/status') .url_parameter('userId', user_id) .url_parameter('applicationId', application_id) .url_segment(two_factor_trust_id) .get .go end |
#retrieve_two_factor_status_with_request(request) ⇒ FusionAuth::ClientResponse
Retrieve a user’s two-factor status.
This can be used to see if a user will need to complete a two-factor challenge to complete a login, and optionally identify the state of the two-factor trust across various applications. This operation provides more payload options than retrieveTwoFactorStatus.
3737 3738 3739 3740 3741 3742 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3737 def retrieve_two_factor_status_with_request(request) start.uri('/api/two-factor/status') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#retrieve_user(user_id) ⇒ FusionAuth::ClientResponse
Retrieves the user for the given Id.
3749 3750 3751 3752 3753 3754 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3749 def retrieve_user(user_id) start.uri('/api/user') .url_segment(user_id) .get .go end |
#retrieve_user_action(user_action_id) ⇒ FusionAuth::ClientResponse
Retrieves the user action for the given Id. If you pass in null for the Id, this will return all the user actions.
3762 3763 3764 3765 3766 3767 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3762 def retrieve_user_action(user_action_id) start.uri('/api/user-action') .url_segment(user_action_id) .get .go end |
#retrieve_user_action_reason(user_action_reason_id) ⇒ FusionAuth::ClientResponse
Retrieves the user action reason for the given Id. If you pass in null for the Id, this will return all the user action reasons.
3775 3776 3777 3778 3779 3780 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3775 def retrieve_user_action_reason(user_action_reason_id) start.uri('/api/user-action-reason') .url_segment(user_action_reason_id) .get .go end |
#retrieve_user_action_reasons ⇒ FusionAuth::ClientResponse
Retrieves all the user action reasons.
3786 3787 3788 3789 3790 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3786 def retrieve_user_action_reasons start.uri('/api/user-action-reason') .get .go end |
#retrieve_user_actions ⇒ FusionAuth::ClientResponse
Retrieves all the user actions.
3796 3797 3798 3799 3800 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3796 def retrieve_user_actions start.uri('/api/user-action') .get .go end |
#retrieve_user_by_change_password_id(change_password_id) ⇒ FusionAuth::ClientResponse
Retrieves the user by a change password Id. The intended use of this API is to retrieve a user after the forgot password workflow has been initiated and you may not know the user’s email or username.
3808 3809 3810 3811 3812 3813 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3808 def retrieve_user_by_change_password_id(change_password_id) start.uri('/api/user') .url_parameter('changePasswordId', change_password_id) .get .go end |
#retrieve_user_by_email(email) ⇒ FusionAuth::ClientResponse
Retrieves the user for the given email.
3820 3821 3822 3823 3824 3825 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3820 def retrieve_user_by_email(email) start.uri('/api/user') .url_parameter('email', email) .get .go end |
#retrieve_user_by_login_id(login_id) ⇒ FusionAuth::ClientResponse
Retrieves the user for the loginId. The loginId can be either the username or the email.
3832 3833 3834 3835 3836 3837 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3832 def retrieve_user_by_login_id(login_id) start.uri('/api/user') .url_parameter('loginId', login_id) .get .go end |
#retrieve_user_by_login_id_with_login_id_types(login_id, login_id_types) ⇒ FusionAuth::ClientResponse
Retrieves the user for the loginId, using specific loginIdTypes.
3845 3846 3847 3848 3849 3850 3851 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3845 def retrieve_user_by_login_id_with_login_id_types(login_id, login_id_types) start.uri('/api/user') .url_parameter('loginId', login_id) .url_parameter('loginIdTypes', login_id_types) .get .go end |
#retrieve_user_by_username(username) ⇒ FusionAuth::ClientResponse
Retrieves the user for the given username.
3858 3859 3860 3861 3862 3863 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3858 def retrieve_user_by_username(username) start.uri('/api/user') .url_parameter('username', username) .get .go end |
#retrieve_user_by_verification_id(verification_id) ⇒ FusionAuth::ClientResponse
Retrieves the user by a verificationId. The intended use of this API is to retrieve a user after the forgot password workflow has been initiated and you may not know the user’s email or username.
3871 3872 3873 3874 3875 3876 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3871 def retrieve_user_by_verification_id(verification_id) start.uri('/api/user') .url_parameter('verificationId', verification_id) .get .go end |
#retrieve_user_code(client_id, client_secret, user_code) ⇒ FusionAuth::ClientResponse
Retrieve a user_code that is part of an in-progress Device Authorization Grant.
This API is useful if you want to build your own login workflow to complete a device grant.
3887 3888 3889 3890 3891 3892 3893 3894 3895 3896 3897 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3887 def retrieve_user_code(client_id, client_secret, user_code) form_parameters = { "client_id" => client_id, "client_secret" => client_secret, "user_code" => user_code, } startAnonymous.uri('/oauth2/device/user-code') .body_handler(FusionAuth::FormDataBodyHandler.new(form_parameters)) .get .go end |
#retrieve_user_code_using_api_key(user_code) ⇒ FusionAuth::ClientResponse
Retrieve a user_code that is part of an in-progress Device Authorization Grant.
This API is useful if you want to build your own login workflow to complete a device grant.
This request will require an API key.
3908 3909 3910 3911 3912 3913 3914 3915 3916 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3908 def retrieve_user_code_using_api_key(user_code) form_parameters = { "user_code" => user_code, } startAnonymous.uri('/oauth2/device/user-code') .body_handler(FusionAuth::FormDataBodyHandler.new(form_parameters)) .get .go end |
#retrieve_user_code_using_api_key_with_request(request) ⇒ FusionAuth::ClientResponse
Retrieve a user_code that is part of an in-progress Device Authorization Grant.
This API is useful if you want to build your own login workflow to complete a device grant.
This request will require an API key.
3927 3928 3929 3930 3931 3932 3933 3934 3935 3936 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3927 def retrieve_user_code_using_api_key_with_request(request) form_parameters = { "tenantId" => (request.tenantId.to_s unless request.tenantId.nil?), "user_code" => request.user_code, } startAnonymous.uri('/oauth2/device/user-code') .body_handler(FusionAuth::FormDataBodyHandler.new(form_parameters)) .post .go end |
#retrieve_user_code_with_request(request) ⇒ FusionAuth::ClientResponse
Retrieve a user_code that is part of an in-progress Device Authorization Grant.
This API is useful if you want to build your own login workflow to complete a device grant.
3945 3946 3947 3948 3949 3950 3951 3952 3953 3954 3955 3956 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3945 def retrieve_user_code_with_request(request) form_parameters = { "client_id" => request.client_id, "client_secret" => request.client_secret, "tenantId" => (request.tenantId.to_s unless request.tenantId.nil?), "user_code" => request.user_code, } startAnonymous.uri('/oauth2/device/user-code') .body_handler(FusionAuth::FormDataBodyHandler.new(form_parameters)) .post .go end |
#retrieve_user_comments(user_id) ⇒ FusionAuth::ClientResponse
Retrieves all the comments for the user with the given Id.
3963 3964 3965 3966 3967 3968 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3963 def retrieve_user_comments(user_id) start.uri('/api/user/comment') .url_segment(user_id) .get .go end |
#retrieve_user_consent(user_consent_id) ⇒ FusionAuth::ClientResponse
Retrieve a single User consent by Id.
3975 3976 3977 3978 3979 3980 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3975 def () start.uri('/api/user/consent') .url_segment() .get .go end |
#retrieve_user_consents(user_id) ⇒ FusionAuth::ClientResponse
Retrieves all the consents for a User.
3987 3988 3989 3990 3991 3992 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3987 def (user_id) start.uri('/api/user/consent') .url_parameter('userId', user_id) .get .go end |
#retrieve_user_info_from_access_token(encoded_jwt) ⇒ FusionAuth::ClientResponse
Call the UserInfo endpoint to retrieve User Claims from the access token issued by FusionAuth.
3999 4000 4001 4002 4003 4004 |
# File 'lib/fusionauth/fusionauth_client.rb', line 3999 def retrieve_user_info_from_access_token(encoded_jwt) startAnonymous.uri('/oauth2/userinfo') .('Bearer ' + encoded_jwt) .get .go end |
#retrieve_user_link(identity_provider_id, identity_provider_user_id, user_id) ⇒ FusionAuth::ClientResponse
Retrieve a single Identity Provider user (link).
4013 4014 4015 4016 4017 4018 4019 4020 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4013 def retrieve_user_link(identity_provider_id, identity_provider_user_id, user_id) start.uri('/api/identity-provider/link') .url_parameter('identityProviderId', identity_provider_id) .url_parameter('identityProviderUserId', identity_provider_user_id) .url_parameter('userId', user_id) .get .go end |
#retrieve_user_links_by_user_id(identity_provider_id, user_id) ⇒ FusionAuth::ClientResponse
Retrieve all Identity Provider users (links) for the user. Specify the optional identityProviderId to retrieve links for a particular IdP.
4028 4029 4030 4031 4032 4033 4034 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4028 def retrieve_user_links_by_user_id(identity_provider_id, user_id) start.uri('/api/identity-provider/link') .url_parameter('identityProviderId', identity_provider_id) .url_parameter('userId', user_id) .get .go end |
#retrieve_user_login_report(application_id, user_id, start, _end) ⇒ FusionAuth::ClientResponse
Retrieves the login report between the two instants for a particular user by Id. If you specify an application Id, it will only return the login counts for that application.
4045 4046 4047 4048 4049 4050 4051 4052 4053 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4045 def retrieve_user_login_report(application_id, user_id, start, _end) start.uri('/api/report/login') .url_parameter('applicationId', application_id) .url_parameter('userId', user_id) .url_parameter('start', start) .url_parameter('end', _end) .get .go end |
#retrieve_user_login_report_by_login_id(application_id, login_id, start, _end) ⇒ FusionAuth::ClientResponse
Retrieves the login report between the two instants for a particular user by login Id. If you specify an application Id, it will only return the login counts for that application.
4064 4065 4066 4067 4068 4069 4070 4071 4072 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4064 def retrieve_user_login_report_by_login_id(application_id, login_id, start, _end) start.uri('/api/report/login') .url_parameter('applicationId', application_id) .url_parameter('loginId', login_id) .url_parameter('start', start) .url_parameter('end', _end) .get .go end |
#retrieve_user_login_report_by_login_id_and_login_id_types(application_id, login_id, start, _end, login_id_types) ⇒ FusionAuth::ClientResponse
Retrieves the login report between the two instants for a particular user by login Id, using specific loginIdTypes. If you specify an application id, it will only return the login counts for that application.
4084 4085 4086 4087 4088 4089 4090 4091 4092 4093 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4084 def retrieve_user_login_report_by_login_id_and_login_id_types(application_id, login_id, start, _end, login_id_types) start.uri('/api/report/login') .url_parameter('applicationId', application_id) .url_parameter('loginId', login_id) .url_parameter('start', start) .url_parameter('end', _end) .url_parameter('loginIdTypes', login_id_types) .get .go end |
#retrieve_user_recent_logins(user_id, offset, limit) ⇒ FusionAuth::ClientResponse
Retrieves the last number of login records for a user.
4102 4103 4104 4105 4106 4107 4108 4109 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4102 def retrieve_user_recent_logins(user_id, offset, limit) start.uri('/api/user/recent-login') .url_parameter('userId', user_id) .url_parameter('offset', offset) .url_parameter('limit', limit) .get .go end |
#retrieve_version ⇒ FusionAuth::ClientResponse
Retrieves the FusionAuth version string.
4115 4116 4117 4118 4119 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4115 def retrieve_version start.uri('/api/system/version') .get .go end |
#retrieve_web_authn_credential(id) ⇒ FusionAuth::ClientResponse
Retrieves the WebAuthn credential for the given Id.
4126 4127 4128 4129 4130 4131 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4126 def retrieve_web_authn_credential(id) start.uri('/api/webauthn') .url_segment(id) .get .go end |
#retrieve_web_authn_credentials_for_user(user_id) ⇒ FusionAuth::ClientResponse
Retrieves all WebAuthn credentials for the given user.
4138 4139 4140 4141 4142 4143 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4138 def retrieve_web_authn_credentials_for_user(user_id) start.uri('/api/webauthn') .url_parameter('userId', user_id) .get .go end |
#retrieve_webhook(webhook_id) ⇒ FusionAuth::ClientResponse
Retrieves the webhook for the given Id. If you pass in null for the Id, this will return all the webhooks.
4150 4151 4152 4153 4154 4155 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4150 def retrieve_webhook(webhook_id) start.uri('/api/webhook') .url_segment(webhook_id) .get .go end |
#retrieve_webhook_attempt_log(webhook_attempt_log_id) ⇒ FusionAuth::ClientResponse
Retrieves a single webhook attempt log for the given Id.
4162 4163 4164 4165 4166 4167 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4162 def retrieve_webhook_attempt_log(webhook_attempt_log_id) start.uri('/api/system/webhook-attempt-log') .url_segment(webhook_attempt_log_id) .get .go end |
#retrieve_webhook_event_log(webhook_event_log_id) ⇒ FusionAuth::ClientResponse
Retrieves a single webhook event log for the given Id.
4174 4175 4176 4177 4178 4179 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4174 def retrieve_webhook_event_log(webhook_event_log_id) start.uri('/api/system/webhook-event-log') .url_segment(webhook_event_log_id) .get .go end |
#retrieve_webhooks ⇒ FusionAuth::ClientResponse
Retrieves all the webhooks.
4185 4186 4187 4188 4189 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4185 def retrieve_webhooks start.uri('/api/webhook') .get .go end |
#revoke_refresh_token(token, user_id, application_id) ⇒ FusionAuth::ClientResponse
Revokes refresh tokens.
Usage examples:
- Delete a single refresh token, pass in only the token.
revokeRefreshToken(token)
- Delete all refresh tokens for a user, pass in only the userId.
revokeRefreshToken(null, userId)
- Delete all refresh tokens for a user for a specific application, pass in both the userId and the applicationId.
revokeRefreshToken(null, userId, applicationId)
- Delete all refresh tokens for an application
revokeRefreshToken(null, null, applicationId)
Note: null may be handled differently depending upon the programming language.
See also: (method names may vary by language… but you’ll figure it out)
- revokeRefreshTokenById
- revokeRefreshTokenByToken
- revokeRefreshTokensByUserId
- revokeRefreshTokensByApplicationId
- revokeRefreshTokensByUserIdForApplication
4221 4222 4223 4224 4225 4226 4227 4228 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4221 def revoke_refresh_token(token, user_id, application_id) start.uri('/api/jwt/refresh') .url_parameter('token', token) .url_parameter('userId', user_id) .url_parameter('applicationId', application_id) .delete .go end |
#revoke_refresh_token_by_id(token_id) ⇒ FusionAuth::ClientResponse
Revokes a single refresh token by the unique Id. The unique Id is not sensitive as it cannot be used to obtain another JWT.
4235 4236 4237 4238 4239 4240 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4235 def revoke_refresh_token_by_id(token_id) start.uri('/api/jwt/refresh') .url_segment(token_id) .delete .go end |
#revoke_refresh_token_by_token(token) ⇒ FusionAuth::ClientResponse
Revokes a single refresh token by using the actual refresh token value. This refresh token value is sensitive, so be careful with this API request.
4247 4248 4249 4250 4251 4252 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4247 def revoke_refresh_token_by_token(token) start.uri('/api/jwt/refresh') .url_parameter('token', token) .delete .go end |
#revoke_refresh_tokens_by_application_id(application_id) ⇒ FusionAuth::ClientResponse
Revoke all refresh tokens that belong to an application by applicationId.
4259 4260 4261 4262 4263 4264 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4259 def revoke_refresh_tokens_by_application_id(application_id) start.uri('/api/jwt/refresh') .url_parameter('applicationId', application_id) .delete .go end |
#revoke_refresh_tokens_by_user_id(user_id) ⇒ FusionAuth::ClientResponse
Revoke all refresh tokens that belong to a user by user Id.
4271 4272 4273 4274 4275 4276 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4271 def revoke_refresh_tokens_by_user_id(user_id) start.uri('/api/jwt/refresh') .url_parameter('userId', user_id) .delete .go end |
#revoke_refresh_tokens_by_user_id_for_application(user_id, application_id) ⇒ FusionAuth::ClientResponse
Revoke all refresh tokens that belong to a user by user Id for a specific application by applicationId.
4284 4285 4286 4287 4288 4289 4290 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4284 def revoke_refresh_tokens_by_user_id_for_application(user_id, application_id) start.uri('/api/jwt/refresh') .url_parameter('userId', user_id) .url_parameter('applicationId', application_id) .delete .go end |
#revoke_refresh_tokens_with_request(request) ⇒ FusionAuth::ClientResponse
Revokes refresh tokens using the information in the JSON body. The handling for this method is the same as the revokeRefreshToken method and is based on the information you provide in the RefreshDeleteRequest object. See that method for additional information.
4298 4299 4300 4301 4302 4303 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4298 def revoke_refresh_tokens_with_request(request) start.uri('/api/jwt/refresh') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .delete .go end |
#revoke_user_consent(user_consent_id) ⇒ FusionAuth::ClientResponse
Revokes a single User consent by Id.
4310 4311 4312 4313 4314 4315 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4310 def () start.uri('/api/user/consent') .url_segment() .delete .go end |
#search_applications(request) ⇒ FusionAuth::ClientResponse
Searches applications with the specified criteria and pagination.
4322 4323 4324 4325 4326 4327 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4322 def search_applications(request) start.uri('/api/application/search') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#search_audit_logs(request) ⇒ FusionAuth::ClientResponse
Searches the audit logs with the specified criteria and pagination.
4334 4335 4336 4337 4338 4339 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4334 def search_audit_logs(request) start.uri('/api/system/audit-log/search') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#search_consents(request) ⇒ FusionAuth::ClientResponse
Searches consents with the specified criteria and pagination.
4346 4347 4348 4349 4350 4351 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4346 def (request) start.uri('/api/consent/search') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#search_email_templates(request) ⇒ FusionAuth::ClientResponse
Searches email templates with the specified criteria and pagination.
4358 4359 4360 4361 4362 4363 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4358 def search_email_templates(request) start.uri('/api/email/template/search') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#search_entities(request) ⇒ FusionAuth::ClientResponse
Searches entities with the specified criteria and pagination.
4370 4371 4372 4373 4374 4375 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4370 def search_entities(request) start.uri('/api/entity/search') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#search_entities_by_ids(ids) ⇒ FusionAuth::ClientResponse
Retrieves the entities for the given Ids. If any Id is invalid, it is ignored.
4382 4383 4384 4385 4386 4387 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4382 def search_entities_by_ids(ids) start.uri('/api/entity/search') .url_parameter('ids', ids) .get .go end |
#search_entity_grants(request) ⇒ FusionAuth::ClientResponse
Searches Entity Grants with the specified criteria and pagination.
4394 4395 4396 4397 4398 4399 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4394 def search_entity_grants(request) start.uri('/api/entity/grant/search') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#search_entity_types(request) ⇒ FusionAuth::ClientResponse
Searches the entity types with the specified criteria and pagination.
4406 4407 4408 4409 4410 4411 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4406 def search_entity_types(request) start.uri('/api/entity/type/search') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#search_event_logs(request) ⇒ FusionAuth::ClientResponse
Searches the event logs with the specified criteria and pagination.
4418 4419 4420 4421 4422 4423 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4418 def search_event_logs(request) start.uri('/api/system/event-log/search') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#search_group_members(request) ⇒ FusionAuth::ClientResponse
Searches group members with the specified criteria and pagination.
4430 4431 4432 4433 4434 4435 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4430 def search_group_members(request) start.uri('/api/group/member/search') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#search_groups(request) ⇒ FusionAuth::ClientResponse
Searches groups with the specified criteria and pagination.
4442 4443 4444 4445 4446 4447 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4442 def search_groups(request) start.uri('/api/group/search') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#search_identity_providers(request) ⇒ FusionAuth::ClientResponse
Searches identity providers with the specified criteria and pagination.
4466 4467 4468 4469 4470 4471 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4466 def search_identity_providers(request) start.uri('/api/identity-provider/search') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#search_ip_access_control_lists(request) ⇒ FusionAuth::ClientResponse
Searches the IP Access Control Lists with the specified criteria and pagination.
4454 4455 4456 4457 4458 4459 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4454 def search_ip_access_control_lists(request) start.uri('/api/ip-acl/search') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#search_keys(request) ⇒ FusionAuth::ClientResponse
Searches keys with the specified criteria and pagination.
4478 4479 4480 4481 4482 4483 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4478 def search_keys(request) start.uri('/api/key/search') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#search_lambdas(request) ⇒ FusionAuth::ClientResponse
Searches lambdas with the specified criteria and pagination.
4490 4491 4492 4493 4494 4495 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4490 def search_lambdas(request) start.uri('/api/lambda/search') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#search_login_records(request) ⇒ FusionAuth::ClientResponse
Searches the login records with the specified criteria and pagination.
4502 4503 4504 4505 4506 4507 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4502 def search_login_records(request) start.uri('/api/system/login-record/search') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#search_tenants(request) ⇒ FusionAuth::ClientResponse
Searches tenants with the specified criteria and pagination.
4514 4515 4516 4517 4518 4519 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4514 def search_tenants(request) start.uri('/api/tenant/search') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#search_themes(request) ⇒ FusionAuth::ClientResponse
Searches themes with the specified criteria and pagination.
4526 4527 4528 4529 4530 4531 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4526 def search_themes(request) start.uri('/api/theme/search') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#search_user_comments(request) ⇒ FusionAuth::ClientResponse
Searches user comments with the specified criteria and pagination.
4538 4539 4540 4541 4542 4543 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4538 def search_user_comments(request) start.uri('/api/user/comment/search') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#search_users(ids) ⇒ FusionAuth::ClientResponse
This method has been renamed to search_users_by_ids, use that method instead.
Retrieves the users for the given Ids. If any Id is invalid, it is ignored.
4551 4552 4553 4554 4555 4556 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4551 def search_users(ids) start.uri('/api/user/search') .url_parameter('ids', ids) .get .go end |
#search_users_by_ids(ids) ⇒ FusionAuth::ClientResponse
Retrieves the users for the given Ids. If any Id is invalid, it is ignored.
4563 4564 4565 4566 4567 4568 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4563 def search_users_by_ids(ids) start.uri('/api/user/search') .url_parameter('ids', ids) .get .go end |
#search_users_by_query(request) ⇒ FusionAuth::ClientResponse
Retrieves the users for the given search criteria and pagination.
4576 4577 4578 4579 4580 4581 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4576 def search_users_by_query(request) start.uri('/api/user/search') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#search_users_by_query_string(request) ⇒ FusionAuth::ClientResponse
This method has been renamed to search_users_by_query, use that method instead.
Retrieves the users for the given search criteria and pagination.
4590 4591 4592 4593 4594 4595 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4590 def search_users_by_query_string(request) start.uri('/api/user/search') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#search_webhook_event_logs(request) ⇒ FusionAuth::ClientResponse
Searches the webhook event logs with the specified criteria and pagination.
4602 4603 4604 4605 4606 4607 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4602 def search_webhook_event_logs(request) start.uri('/api/system/webhook-event-log/search') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#search_webhooks(request) ⇒ FusionAuth::ClientResponse
Searches webhooks with the specified criteria and pagination.
4614 4615 4616 4617 4618 4619 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4614 def search_webhooks(request) start.uri('/api/webhook/search') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#send_email(email_template_id, request) ⇒ FusionAuth::ClientResponse
Send an email using an email template Id. You can optionally provide requestData to access key value pairs in the email template.
4628 4629 4630 4631 4632 4633 4634 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4628 def send_email(email_template_id, request) start.uri('/api/email/send') .url_segment(email_template_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#send_family_request_email(request) ⇒ FusionAuth::ClientResponse
Sends out an email to a parent that they need to register and create a family or need to log in and add a child to their existing family.
4641 4642 4643 4644 4645 4646 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4641 def send_family_request_email(request) start.uri('/api/user/family/request') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#send_passwordless_code(request) ⇒ FusionAuth::ClientResponse
Send a passwordless authentication code in an email to complete login.
4653 4654 4655 4656 4657 4658 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4653 def send_passwordless_code(request) startAnonymous.uri('/api/passwordless/send') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#send_two_factor_code(request) ⇒ FusionAuth::ClientResponse
This method has been renamed to send_two_factor_code_for_enable_disable, use that method instead.
Send a Two Factor authentication code to assist in setting up Two Factor authentication or disabling.
4666 4667 4668 4669 4670 4671 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4666 def send_two_factor_code(request) start.uri('/api/two-factor/send') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#send_two_factor_code_for_enable_disable(request) ⇒ FusionAuth::ClientResponse
Send a Two Factor authentication code to assist in setting up Two Factor authentication or disabling.
4678 4679 4680 4681 4682 4683 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4678 def send_two_factor_code_for_enable_disable(request) start.uri('/api/two-factor/send') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#send_two_factor_code_for_login(two_factor_id) ⇒ FusionAuth::ClientResponse
This method has been renamed to send_two_factor_code_for_login_using_method, use that method instead.
Send a Two Factor authentication code to allow the completion of Two Factor authentication.
4691 4692 4693 4694 4695 4696 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4691 def send_two_factor_code_for_login(two_factor_id) startAnonymous.uri('/api/two-factor/send') .url_segment(two_factor_id) .post .go end |
#send_two_factor_code_for_login_using_method(two_factor_id, request) ⇒ FusionAuth::ClientResponse
Send a Two Factor authentication code to allow the completion of Two Factor authentication.
4704 4705 4706 4707 4708 4709 4710 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4704 def send_two_factor_code_for_login_using_method(two_factor_id, request) startAnonymous.uri('/api/two-factor/send') .url_segment(two_factor_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#send_verify_identity(request) ⇒ FusionAuth::ClientResponse
Send a verification code using the appropriate transport for the identity type being verified.
4717 4718 4719 4720 4721 4722 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4717 def send_verify_identity(request) start.uri('/api/identity/verify/send') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#set_tenant_id(tenant_id) ⇒ Object
40 41 42 |
# File 'lib/fusionauth/fusionauth_client.rb', line 40 def set_tenant_id(tenant_id) @tenant_id = tenant_id end |
#start_identity_provider_connection_test(request) ⇒ FusionAuth::ClientResponse
Begins an identity provider connection test.
4729 4730 4731 4732 4733 4734 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4729 def start_identity_provider_connection_test(request) start.uri('/api/identity-provider/test') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#start_identity_provider_login(request) ⇒ FusionAuth::ClientResponse
Begins a login request for a 3rd party login that requires user interaction such as HYPR.
4742 4743 4744 4745 4746 4747 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4742 def start_identity_provider_login(request) start.uri('/api/identity-provider/start') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#start_passwordless_login(request) ⇒ FusionAuth::ClientResponse
Start a passwordless login request by generating a passwordless code. This code can be sent to the User using the Send Passwordless Code API or using a mechanism outside of FusionAuth. The passwordless login is completed by using the Passwordless Login API with this code.
4755 4756 4757 4758 4759 4760 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4755 def start_passwordless_login(request) start.uri('/api/passwordless/start') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#start_two_factor_login(request) ⇒ FusionAuth::ClientResponse
Start a Two-Factor login request by generating a two-factor identifier. This code can then be sent to the Two Factor Send API (/api/two-factor/send)in order to send a one-time use code to a user. You can also use one-time use code returned to send the code out-of-band. The Two-Factor login is completed by making a request to the Two-Factor Login API (/api/two-factor/login). with the two-factor identifier and the one-time use code.
This API is intended to allow you to begin a Two-Factor login outside a normal login that originated from the Login API (/api/login).
4772 4773 4774 4775 4776 4777 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4772 def start_two_factor_login(request) start.uri('/api/two-factor/start') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#start_verify_identity(request) ⇒ FusionAuth::ClientResponse
Start a verification of an identity by generating a code. This code can be sent to the User using the Verify Send API Verification Code API or using a mechanism outside of FusionAuth. The verification is completed by using the Verify Complete API with this code.
4785 4786 4787 4788 4789 4790 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4785 def start_verify_identity(request) start.uri('/api/identity/verify/start') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#start_web_authn_login(request) ⇒ FusionAuth::ClientResponse
Start a WebAuthn authentication ceremony by generating a new challenge for the user
4797 4798 4799 4800 4801 4802 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4797 def start_web_authn_login(request) start.uri('/api/webauthn/start') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#start_web_authn_registration(request) ⇒ FusionAuth::ClientResponse
Start a WebAuthn registration ceremony by generating a new challenge for the user
4809 4810 4811 4812 4813 4814 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4809 def start_web_authn_registration(request) start.uri('/api/webauthn/register/start') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#two_factor_login(request) ⇒ FusionAuth::ClientResponse
Complete login using a 2FA challenge
4821 4822 4823 4824 4825 4826 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4821 def two_factor_login(request) startAnonymous.uri('/api/two-factor/login') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#update_api_key(key_id, request) ⇒ FusionAuth::ClientResponse
Updates an API key with the given Id.
4834 4835 4836 4837 4838 4839 4840 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4834 def update_api_key(key_id, request) start.uri('/api/api-key') .url_segment(key_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .put .go end |
#update_application(application_id, request) ⇒ FusionAuth::ClientResponse
Updates the application with the given Id.
4848 4849 4850 4851 4852 4853 4854 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4848 def update_application(application_id, request) start.uri('/api/application') .url_segment(application_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .put .go end |
#update_application_role(application_id, role_id, request) ⇒ FusionAuth::ClientResponse
Updates the application role with the given Id for the application.
4863 4864 4865 4866 4867 4868 4869 4870 4871 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4863 def update_application_role(application_id, role_id, request) start.uri('/api/application') .url_segment(application_id) .url_segment("role") .url_segment(role_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .put .go end |
#update_connector(connector_id, request) ⇒ FusionAuth::ClientResponse
Updates the connector with the given Id.
4879 4880 4881 4882 4883 4884 4885 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4879 def update_connector(connector_id, request) start.uri('/api/connector') .url_segment(connector_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .put .go end |
#update_consent(consent_id, request) ⇒ FusionAuth::ClientResponse
Updates the consent with the given Id.
4893 4894 4895 4896 4897 4898 4899 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4893 def (, request) start.uri('/api/consent') .url_segment() .body_handler(FusionAuth::JSONBodyHandler.new(request)) .put .go end |
#update_email_template(email_template_id, request) ⇒ FusionAuth::ClientResponse
Updates the email template with the given Id.
4907 4908 4909 4910 4911 4912 4913 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4907 def update_email_template(email_template_id, request) start.uri('/api/email/template') .url_segment(email_template_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .put .go end |
#update_entity(entity_id, request) ⇒ FusionAuth::ClientResponse
Updates the Entity with the given Id.
4921 4922 4923 4924 4925 4926 4927 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4921 def update_entity(entity_id, request) start.uri('/api/entity') .url_segment(entity_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .put .go end |
#update_entity_type(entity_type_id, request) ⇒ FusionAuth::ClientResponse
Updates the Entity Type with the given Id.
4935 4936 4937 4938 4939 4940 4941 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4935 def update_entity_type(entity_type_id, request) start.uri('/api/entity/type') .url_segment(entity_type_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .put .go end |
#update_entity_type_permission(entity_type_id, permission_id, request) ⇒ FusionAuth::ClientResponse
Updates the permission with the given Id for the entity type.
4950 4951 4952 4953 4954 4955 4956 4957 4958 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4950 def (entity_type_id, , request) start.uri('/api/entity/type') .url_segment(entity_type_id) .url_segment("permission") .url_segment() .body_handler(FusionAuth::JSONBodyHandler.new(request)) .put .go end |
#update_family(family_id, request) ⇒ FusionAuth::ClientResponse
Updates a family with a given Id.
4966 4967 4968 4969 4970 4971 4972 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4966 def update_family(family_id, request) start.uri('/api/user/family') .url_segment(family_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .put .go end |
#update_form(form_id, request) ⇒ FusionAuth::ClientResponse
Updates the form with the given Id.
4980 4981 4982 4983 4984 4985 4986 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4980 def update_form(form_id, request) start.uri('/api/form') .url_segment(form_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .put .go end |
#update_form_field(field_id, request) ⇒ FusionAuth::ClientResponse
Updates the form field with the given Id.
4994 4995 4996 4997 4998 4999 5000 |
# File 'lib/fusionauth/fusionauth_client.rb', line 4994 def update_form_field(field_id, request) start.uri('/api/form/field') .url_segment(field_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .put .go end |
#update_group(group_id, request) ⇒ FusionAuth::ClientResponse
Updates the group with the given Id.
5008 5009 5010 5011 5012 5013 5014 |
# File 'lib/fusionauth/fusionauth_client.rb', line 5008 def update_group(group_id, request) start.uri('/api/group') .url_segment(group_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .put .go end |
#update_group_members(request) ⇒ FusionAuth::ClientResponse
Creates a member in a group.
5021 5022 5023 5024 5025 5026 |
# File 'lib/fusionauth/fusionauth_client.rb', line 5021 def update_group_members(request) start.uri('/api/group/member') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .put .go end |
#update_identity_provider(identity_provider_id, request) ⇒ FusionAuth::ClientResponse
Updates the identity provider with the given Id.
5048 5049 5050 5051 5052 5053 5054 |
# File 'lib/fusionauth/fusionauth_client.rb', line 5048 def update_identity_provider(identity_provider_id, request) start.uri('/api/identity-provider') .url_segment(identity_provider_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .put .go end |
#update_integrations(request) ⇒ FusionAuth::ClientResponse
Updates the available integrations.
5061 5062 5063 5064 5065 5066 |
# File 'lib/fusionauth/fusionauth_client.rb', line 5061 def update_integrations(request) start.uri('/api/integration') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .put .go end |
#update_ip_access_control_list(access_control_list_id, request) ⇒ FusionAuth::ClientResponse
Updates the IP Access Control List with the given Id.
5034 5035 5036 5037 5038 5039 5040 |
# File 'lib/fusionauth/fusionauth_client.rb', line 5034 def update_ip_access_control_list(access_control_list_id, request) start.uri('/api/ip-acl') .url_segment(access_control_list_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .put .go end |
#update_key(key_id, request) ⇒ FusionAuth::ClientResponse
Updates the key with the given Id.
5074 5075 5076 5077 5078 5079 5080 |
# File 'lib/fusionauth/fusionauth_client.rb', line 5074 def update_key(key_id, request) start.uri('/api/key') .url_segment(key_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .put .go end |
#update_lambda(lambda_id, request) ⇒ FusionAuth::ClientResponse
Updates the lambda with the given Id.
5088 5089 5090 5091 5092 5093 5094 |
# File 'lib/fusionauth/fusionauth_client.rb', line 5088 def update_lambda(lambda_id, request) start.uri('/api/lambda') .url_segment(lambda_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .put .go end |
#update_message_template(message_template_id, request) ⇒ FusionAuth::ClientResponse
Updates the message template with the given Id.
5102 5103 5104 5105 5106 5107 5108 |
# File 'lib/fusionauth/fusionauth_client.rb', line 5102 def (, request) start.uri('/api/message/template') .url_segment() .body_handler(FusionAuth::JSONBodyHandler.new(request)) .put .go end |
#update_messenger(messenger_id, request) ⇒ FusionAuth::ClientResponse
Updates the messenger with the given Id.
5116 5117 5118 5119 5120 5121 5122 |
# File 'lib/fusionauth/fusionauth_client.rb', line 5116 def update_messenger(messenger_id, request) start.uri('/api/messenger') .url_segment(messenger_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .put .go end |
#update_o_auth_scope(application_id, scope_id, request) ⇒ FusionAuth::ClientResponse
Updates the OAuth scope with the given Id for the application.
5131 5132 5133 5134 5135 5136 5137 5138 5139 |
# File 'lib/fusionauth/fusionauth_client.rb', line 5131 def update_o_auth_scope(application_id, scope_id, request) start.uri('/api/application') .url_segment(application_id) .url_segment("scope") .url_segment(scope_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .put .go end |
#update_registration(user_id, request) ⇒ FusionAuth::ClientResponse
Updates the registration for the user with the given Id and the application defined in the request.
5147 5148 5149 5150 5151 5152 5153 |
# File 'lib/fusionauth/fusionauth_client.rb', line 5147 def update_registration(user_id, request) start.uri('/api/user/registration') .url_segment(user_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .put .go end |
#update_system_configuration(request) ⇒ FusionAuth::ClientResponse
Updates the system configuration.
5160 5161 5162 5163 5164 5165 |
# File 'lib/fusionauth/fusionauth_client.rb', line 5160 def update_system_configuration(request) start.uri('/api/system-configuration') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .put .go end |
#update_tenant(tenant_id, request) ⇒ FusionAuth::ClientResponse
Updates the tenant with the given Id.
5173 5174 5175 5176 5177 5178 5179 |
# File 'lib/fusionauth/fusionauth_client.rb', line 5173 def update_tenant(tenant_id, request) start.uri('/api/tenant') .url_segment(tenant_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .put .go end |
#update_tenant_manager_configuration(request) ⇒ FusionAuth::ClientResponse
Updates the Tenant Manager configuration.
5186 5187 5188 5189 5190 5191 |
# File 'lib/fusionauth/fusionauth_client.rb', line 5186 def update_tenant_manager_configuration(request) start.uri('/api/tenant-manager') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .put .go end |
#update_tenant_manager_identity_provider_type_configuration(type, request) ⇒ FusionAuth::ClientResponse
Updates the tenant manager identity provider type configuration for the given identity provider type.
5199 5200 5201 5202 5203 5204 5205 |
# File 'lib/fusionauth/fusionauth_client.rb', line 5199 def update_tenant_manager_identity_provider_type_configuration(type, request) start.uri('/api/tenant-manager/identity-provider') .url_segment(type) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .put .go end |
#update_theme(theme_id, request) ⇒ FusionAuth::ClientResponse
Updates the theme with the given Id.
5213 5214 5215 5216 5217 5218 5219 |
# File 'lib/fusionauth/fusionauth_client.rb', line 5213 def update_theme(theme_id, request) start.uri('/api/theme') .url_segment(theme_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .put .go end |
#update_user(user_id, request) ⇒ FusionAuth::ClientResponse
Updates the user with the given Id.
5227 5228 5229 5230 5231 5232 5233 |
# File 'lib/fusionauth/fusionauth_client.rb', line 5227 def update_user(user_id, request) start.uri('/api/user') .url_segment(user_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .put .go end |
#update_user_action(user_action_id, request) ⇒ FusionAuth::ClientResponse
Updates the user action with the given Id.
5241 5242 5243 5244 5245 5246 5247 |
# File 'lib/fusionauth/fusionauth_client.rb', line 5241 def update_user_action(user_action_id, request) start.uri('/api/user-action') .url_segment(user_action_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .put .go end |
#update_user_action_reason(user_action_reason_id, request) ⇒ FusionAuth::ClientResponse
Updates the user action reason with the given Id.
5255 5256 5257 5258 5259 5260 5261 |
# File 'lib/fusionauth/fusionauth_client.rb', line 5255 def update_user_action_reason(user_action_reason_id, request) start.uri('/api/user-action-reason') .url_segment(user_action_reason_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .put .go end |
#update_user_consent(user_consent_id, request) ⇒ FusionAuth::ClientResponse
Updates a single User consent by Id.
5269 5270 5271 5272 5273 5274 5275 |
# File 'lib/fusionauth/fusionauth_client.rb', line 5269 def (, request) start.uri('/api/user/consent') .url_segment() .body_handler(FusionAuth::JSONBodyHandler.new(request)) .put .go end |
#update_webhook(webhook_id, request) ⇒ FusionAuth::ClientResponse
Updates the webhook with the given Id.
5283 5284 5285 5286 5287 5288 5289 |
# File 'lib/fusionauth/fusionauth_client.rb', line 5283 def update_webhook(webhook_id, request) start.uri('/api/webhook') .url_segment(webhook_id) .body_handler(FusionAuth::JSONBodyHandler.new(request)) .put .go end |
#upsert_entity_grant(entity_id, request) ⇒ FusionAuth::ClientResponse
Creates or updates an Entity Grant. This is when a User/Entity is granted permissions to an Entity.
5297 5298 5299 5300 5301 5302 5303 5304 |
# File 'lib/fusionauth/fusionauth_client.rb', line 5297 def upsert_entity_grant(entity_id, request) start.uri('/api/entity') .url_segment(entity_id) .url_segment("grant") .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#validate_device(user_code, client_id) ⇒ FusionAuth::ClientResponse
Validates the end-user provided user_code from the user-interaction of the Device Authorization Grant. If you build your own activation form you should validate the user provided code prior to beginning the Authorization grant.
5313 5314 5315 5316 5317 5318 5319 |
# File 'lib/fusionauth/fusionauth_client.rb', line 5313 def validate_device(user_code, client_id) startAnonymous.uri('/oauth2/device/validate') .url_parameter('user_code', user_code) .url_parameter('client_id', client_id) .get .go end |
#validate_device_with_request(request) ⇒ FusionAuth::ClientResponse
Validates the end-user provided user_code from the user-interaction of the Device Authorization Grant. If you build your own activation form you should validate the user provided code prior to beginning the Authorization grant.
5327 5328 5329 5330 5331 5332 5333 5334 |
# File 'lib/fusionauth/fusionauth_client.rb', line 5327 def validate_device_with_request(request) startAnonymous.uri('/oauth2/device/validate') .url_parameter('client_id', request.client_id) .url_parameter('tenantId', request.tenantId.nil? ? nil : request.tenantId.to_s) .url_parameter('user_code', request.user_code) .get .go end |
#validate_jwt(encoded_jwt) ⇒ FusionAuth::ClientResponse
Validates the provided JWT (encoded JWT string) to ensure the token is valid. A valid access token is properly signed and not expired. <p> This API may be used to verify the JWT as well as decode the encoded JWT into human readable identity claims.
5344 5345 5346 5347 5348 5349 |
# File 'lib/fusionauth/fusionauth_client.rb', line 5344 def validate_jwt(encoded_jwt) startAnonymous.uri('/api/jwt/validate') .('Bearer ' + encoded_jwt) .get .go end |
#vend_jwt(request) ⇒ FusionAuth::ClientResponse
It’s a JWT vending machine!
Issue a new access token (JWT) with the provided claims in the request. This JWT is not scoped to a tenant or user, it is a free form token that will contain what claims you provide. <p> The iat, exp and jti claims will be added by FusionAuth, all other claims must be provided by the caller.
If a TTL is not provided in the request, the TTL will be retrieved from the default Tenant or the Tenant specified on the request either by way of the X-FusionAuth-TenantId request header, or a tenant scoped API key.
5364 5365 5366 5367 5368 5369 |
# File 'lib/fusionauth/fusionauth_client.rb', line 5364 def vend_jwt(request) start.uri('/api/jwt/vend') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#verify_email(verification_id) ⇒ FusionAuth::ClientResponse
This method has been renamed to verify_email_address and changed to take a JSON request body, use that method instead.
Confirms a email verification. The Id given is usually from an email sent to the user.
5377 5378 5379 5380 5381 5382 |
# File 'lib/fusionauth/fusionauth_client.rb', line 5377 def verify_email(verification_id) startAnonymous.uri('/api/user/verify-email') .url_segment(verification_id) .post .go end |
#verify_email_address(request) ⇒ FusionAuth::ClientResponse
Confirms a user’s email address.
The request body will contain the verificationId. You may also be required to send a one-time use code based upon your configuration. When the tenant is configured to gate a user until their email address is verified, this procedures requires two values instead of one. The verificationId is a high entropy value and the one-time use code is a low entropy value that is easily entered in a user interactive form. The two values together are able to confirm a user’s email address and mark the user’s email address as verified.
5394 5395 5396 5397 5398 5399 |
# File 'lib/fusionauth/fusionauth_client.rb', line 5394 def verify_email_address(request) startAnonymous.uri('/api/user/verify-email') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#verify_email_address_by_user_id(request) ⇒ FusionAuth::ClientResponse
Administratively verify a user’s email address. Use this method to bypass email verification for the user.
The request body will contain the userId to be verified. An API key is required when sending the userId in the request body.
5408 5409 5410 5411 5412 5413 |
# File 'lib/fusionauth/fusionauth_client.rb', line 5408 def verify_email_address_by_user_id(request) start.uri('/api/user/verify-email') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#verify_identity(request) ⇒ FusionAuth::ClientResponse
Administratively verify a user identity.
5420 5421 5422 5423 5424 5425 |
# File 'lib/fusionauth/fusionauth_client.rb', line 5420 def verify_identity(request) start.uri('/api/identity/verify') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |
#verify_registration(verification_id) ⇒ FusionAuth::ClientResponse
This method has been renamed to verify_user_registration and changed to take a JSON request body, use that method instead.
Confirms an application registration. The Id given is usually from an email sent to the user.
5433 5434 5435 5436 5437 5438 |
# File 'lib/fusionauth/fusionauth_client.rb', line 5433 def verify_registration(verification_id) startAnonymous.uri('/api/user/verify-registration') .url_segment(verification_id) .post .go end |
#verify_user_registration(request) ⇒ FusionAuth::ClientResponse
Confirms a user’s registration.
The request body will contain the verificationId. You may also be required to send a one-time use code based upon your configuration. When the application is configured to gate a user until their registration is verified, this procedures requires two values instead of one. The verificationId is a high entropy value and the one-time use code is a low entropy value that is easily entered in a user interactive form. The two values together are able to confirm a user’s registration and mark the user’s registration as verified.
5450 5451 5452 5453 5454 5455 |
# File 'lib/fusionauth/fusionauth_client.rb', line 5450 def verify_user_registration(request) startAnonymous.uri('/api/user/verify-registration') .body_handler(FusionAuth::JSONBodyHandler.new(request)) .post .go end |