clerk-http-client 0.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/Gemfile +9 -0
- data/Gemfile.lock +87 -0
- data/README.md +360 -0
- data/Rakefile +10 -0
- data/bin/fmt +5 -0
- data/bin/generate +8 -0
- data/bin/setup +7 -0
- data/clerk-http-client.gemspec +41 -0
- data/docs/ActorToken.md +34 -0
- data/docs/ActorTokensApi.md +147 -0
- data/docs/AddDomainRequest.md +22 -0
- data/docs/Admin.md +24 -0
- data/docs/AllowListBlockListApi.md +421 -0
- data/docs/AllowlistIdentifier.md +32 -0
- data/docs/BetaFeaturesApi.md +217 -0
- data/docs/BlocklistIdentifier.md +30 -0
- data/docs/BlocklistIdentifiers.md +20 -0
- data/docs/CNameTarget.md +22 -0
- data/docs/ChangeProductionInstanceDomainRequest.md +20 -0
- data/docs/ClerkError.md +26 -0
- data/docs/ClerkErrors.md +20 -0
- data/docs/Client.md +34 -0
- data/docs/ClientsApi.md +221 -0
- data/docs/CreateActorTokenRequest.md +24 -0
- data/docs/CreateAllowlistIdentifierRequest.md +20 -0
- data/docs/CreateBlocklistIdentifierRequest.md +18 -0
- data/docs/CreateEmailAddressRequest.md +24 -0
- data/docs/CreateInvitationRequest.md +28 -0
- data/docs/CreateJWTTemplateRequest.md +30 -0
- data/docs/CreateOAuthApplicationRequest.md +24 -0
- data/docs/CreateOrganizationDomainRequest.md +22 -0
- data/docs/CreateOrganizationInvitationBulkRequestInner.md +28 -0
- data/docs/CreateOrganizationInvitationRequest.md +28 -0
- data/docs/CreateOrganizationMembershipRequest.md +20 -0
- data/docs/CreateOrganizationRequest.md +30 -0
- data/docs/CreatePhoneNumberRequest.md +26 -0
- data/docs/CreateRedirectURLRequest.md +18 -0
- data/docs/CreateSAMLConnectionRequest.md +34 -0
- data/docs/CreateSAMLConnectionRequestAttributeMapping.md +24 -0
- data/docs/CreateSessionTokenFromTemplate200Response.md +20 -0
- data/docs/CreateSignInTokenRequest.md +20 -0
- data/docs/CreateUserRequest.md +62 -0
- data/docs/DeletedObject.md +24 -0
- data/docs/DisableMFA200Response.md +18 -0
- data/docs/Domain.md +34 -0
- data/docs/Domains.md +20 -0
- data/docs/DomainsApi.md +286 -0
- data/docs/EmailAddress.md +32 -0
- data/docs/EmailAddressVerification.md +51 -0
- data/docs/EmailAddressesApi.md +289 -0
- data/docs/EmailSMSTemplatesApi.md +449 -0
- data/docs/GetOAuthAccessToken200ResponseInner.md +34 -0
- data/docs/IdentificationLink.md +20 -0
- data/docs/InstanceRestrictions.md +26 -0
- data/docs/InstanceSettingsApi.md +216 -0
- data/docs/Invitation.md +36 -0
- data/docs/InvitationsApi.md +223 -0
- data/docs/JWKSApi.md +74 -0
- data/docs/JWTTemplate.md +36 -0
- data/docs/JWTTemplatesApi.md +354 -0
- data/docs/MergeOrganizationMetadataRequest.md +20 -0
- data/docs/MiscellaneousApi.md +75 -0
- data/docs/OAuthApplication.md +42 -0
- data/docs/OAuthApplicationWithSecret.md +44 -0
- data/docs/OAuthApplications.md +20 -0
- data/docs/OAuthApplicationsApi.md +433 -0
- data/docs/OTP.md +24 -0
- data/docs/Oauth.md +28 -0
- data/docs/OauthError.md +47 -0
- data/docs/Organization.md +40 -0
- data/docs/OrganizationDomain.md +38 -0
- data/docs/OrganizationDomainApi.md +81 -0
- data/docs/OrganizationDomainVerification.md +24 -0
- data/docs/OrganizationDomains.md +20 -0
- data/docs/OrganizationDomainsApi.md +231 -0
- data/docs/OrganizationInvitation.md +38 -0
- data/docs/OrganizationInvitationWithPublicOrganizationData.md +40 -0
- data/docs/OrganizationInvitationWithPublicOrganizationDataPublicOrganizationData.md +26 -0
- data/docs/OrganizationInvitations.md +20 -0
- data/docs/OrganizationInvitationsApi.md +533 -0
- data/docs/OrganizationInvitationsWithPublicOrganizationData.md +20 -0
- data/docs/OrganizationMembership.md +38 -0
- data/docs/OrganizationMembershipPublicUserData.md +30 -0
- data/docs/OrganizationMemberships.md +20 -0
- data/docs/OrganizationMembershipsApi.md +453 -0
- data/docs/OrganizationSettings.md +36 -0
- data/docs/OrganizationWithLogo.md +46 -0
- data/docs/Organizations.md +20 -0
- data/docs/OrganizationsApi.md +591 -0
- data/docs/Passkey.md +26 -0
- data/docs/PhoneNumber.md +38 -0
- data/docs/PhoneNumberVerification.md +49 -0
- data/docs/PhoneNumbersApi.md +289 -0
- data/docs/PreviewTemplateRequest.md +24 -0
- data/docs/ProxyCheck.md +32 -0
- data/docs/ProxyChecksApi.md +77 -0
- data/docs/RedirectURL.md +26 -0
- data/docs/RedirectURLsApi.md +284 -0
- data/docs/RevokeInvitation200Response.md +36 -0
- data/docs/RevokeOrganizationInvitationRequest.md +18 -0
- data/docs/SAML.md +28 -0
- data/docs/SAMLAccount.md +38 -0
- data/docs/SAMLAccountSamlConnection.md +47 -0
- data/docs/SAMLAccountVerification.md +49 -0
- data/docs/SAMLConnection.md +38 -0
- data/docs/SAMLConnections.md +20 -0
- data/docs/SAMLConnectionsApi.md +363 -0
- data/docs/SchemasPasskey.md +26 -0
- data/docs/SchemasPasskeyVerification.md +47 -0
- data/docs/SchemasSAMLConnection.md +60 -0
- data/docs/SchemasSAMLConnectionAttributeMapping.md +24 -0
- data/docs/Session.md +42 -0
- data/docs/SessionLatestActivity.md +34 -0
- data/docs/SessionsApi.md +373 -0
- data/docs/SignInToken.md +32 -0
- data/docs/SignInTokensApi.md +147 -0
- data/docs/SignUp.md +62 -0
- data/docs/SignUpsApi.md +79 -0
- data/docs/SvixURL.md +18 -0
- data/docs/TOTP.md +28 -0
- data/docs/Template.md +60 -0
- data/docs/TestingToken.md +22 -0
- data/docs/TestingTokensApi.md +74 -0
- data/docs/Ticket.md +24 -0
- data/docs/ToggleTemplateDeliveryRequest.md +18 -0
- data/docs/TotalCount.md +20 -0
- data/docs/UpdateDomainRequest.md +22 -0
- data/docs/UpdateEmailAddressRequest.md +20 -0
- data/docs/UpdateInstanceAuthConfig200Response.md +28 -0
- data/docs/UpdateInstanceAuthConfigRequest.md +28 -0
- data/docs/UpdateInstanceOrganizationSettingsRequest.md +30 -0
- data/docs/UpdateInstanceRequest.md +34 -0
- data/docs/UpdateInstanceRestrictionsRequest.md +26 -0
- data/docs/UpdateOAuthApplicationRequest.md +22 -0
- data/docs/UpdateOrganizationDomainRequest.md +20 -0
- data/docs/UpdateOrganizationMembershipMetadataRequest.md +20 -0
- data/docs/UpdateOrganizationMembershipRequest.md +18 -0
- data/docs/UpdateOrganizationRequest.md +30 -0
- data/docs/UpdatePhoneNumberRequest.md +22 -0
- data/docs/UpdateProductionInstanceDomainRequest.md +18 -0
- data/docs/UpdateSAMLConnectionRequest.md +42 -0
- data/docs/UpdateSAMLConnectionRequestAttributeMapping.md +24 -0
- data/docs/UpdateSignUpRequest.md +18 -0
- data/docs/UpdateUserMetadataRequest.md +22 -0
- data/docs/UpdateUserRequest.md +66 -0
- data/docs/UpsertTemplateRequest.md +30 -0
- data/docs/User.md +94 -0
- data/docs/UsersApi.md +1829 -0
- data/docs/VerifyClientRequest.md +18 -0
- data/docs/VerifyDomainProxyRequest.md +20 -0
- data/docs/VerifyPassword200Response.md +18 -0
- data/docs/VerifyPasswordRequest.md +18 -0
- data/docs/VerifySessionRequest.md +18 -0
- data/docs/VerifyTOTP200Response.md +20 -0
- data/docs/VerifyTOTPRequest.md +18 -0
- data/docs/Web3Signature.md +28 -0
- data/docs/Web3Wallet.md +28 -0
- data/docs/Web3WalletVerification.md +49 -0
- data/docs/WebhooksApi.md +207 -0
- data/docs/WellKnownJWKS.md +18 -0
- data/docs/WellKnownJWKSKeysInner.md +28 -0
- data/git_push.sh +57 -0
- data/lib/clerk-http-client/api/actor_tokens_api.rb +157 -0
- data/lib/clerk-http-client/api/allow_list_block_list_api.rb +410 -0
- data/lib/clerk-http-client/api/beta_features_api.rb +228 -0
- data/lib/clerk-http-client/api/clients_api.rb +234 -0
- data/lib/clerk-http-client/api/domains_api.rb +292 -0
- data/lib/clerk-http-client/api/email_addresses_api.rb +298 -0
- data/lib/clerk-http-client/api/email_sms_templates_api.rb +488 -0
- data/lib/clerk-http-client/api/instance_settings_api.rb +232 -0
- data/lib/clerk-http-client/api/invitations_api.rb +241 -0
- data/lib/clerk-http-client/api/jwks_api.rb +81 -0
- data/lib/clerk-http-client/api/jwt_templates_api.rb +355 -0
- data/lib/clerk-http-client/api/miscellaneous_api.rb +85 -0
- data/lib/clerk-http-client/api/o_auth_applications_api.rb +440 -0
- data/lib/clerk-http-client/api/organization_domain_api.rb +104 -0
- data/lib/clerk-http-client/api/organization_domains_api.rb +258 -0
- data/lib/clerk-http-client/api/organization_invitations_api.rb +586 -0
- data/lib/clerk-http-client/api/organization_memberships_api.rb +499 -0
- data/lib/clerk-http-client/api/organizations_api.rb +606 -0
- data/lib/clerk-http-client/api/phone_numbers_api.rb +298 -0
- data/lib/clerk-http-client/api/proxy_checks_api.rb +92 -0
- data/lib/clerk-http-client/api/redirect_urls_api.rb +281 -0
- data/lib/clerk-http-client/api/saml_connections_api.rb +375 -0
- data/lib/clerk-http-client/api/sessions_api.rb +385 -0
- data/lib/clerk-http-client/api/sign_in_tokens_api.rb +157 -0
- data/lib/clerk-http-client/api/sign_ups_api.rb +98 -0
- data/lib/clerk-http-client/api/testing_tokens_api.rb +81 -0
- data/lib/clerk-http-client/api/users_api.rb +1828 -0
- data/lib/clerk-http-client/api/webhooks_api.rb +199 -0
- data/lib/clerk-http-client/api_client.rb +437 -0
- data/lib/clerk-http-client/api_error.rb +58 -0
- data/lib/clerk-http-client/configuration.rb +393 -0
- data/lib/clerk-http-client/models/actor_token.rb +385 -0
- data/lib/clerk-http-client/models/add_domain_request.rb +249 -0
- data/lib/clerk-http-client/models/admin.rb +303 -0
- data/lib/clerk-http-client/models/allowlist_identifier.rb +327 -0
- data/lib/clerk-http-client/models/blocklist_identifier.rb +318 -0
- data/lib/clerk-http-client/models/blocklist_identifiers.rb +240 -0
- data/lib/clerk-http-client/models/c_name_target.rb +254 -0
- data/lib/clerk-http-client/models/change_production_instance_domain_request.rb +225 -0
- data/lib/clerk-http-client/models/clerk_error.rb +271 -0
- data/lib/clerk-http-client/models/clerk_errors.rb +232 -0
- data/lib/clerk-http-client/models/client.rb +380 -0
- data/lib/clerk-http-client/models/create_actor_token_request.rb +263 -0
- data/lib/clerk-http-client/models/create_allowlist_identifier_request.rb +234 -0
- data/lib/clerk-http-client/models/create_blocklist_identifier_request.rb +222 -0
- data/lib/clerk-http-client/models/create_email_address_request.rb +247 -0
- data/lib/clerk-http-client/models/create_invitation_request.rb +303 -0
- data/lib/clerk-http-client/models/create_jwt_template_request.rb +327 -0
- data/lib/clerk-http-client/models/create_o_auth_application_request.rb +261 -0
- data/lib/clerk-http-client/models/create_organization_domain_request.rb +236 -0
- data/lib/clerk-http-client/models/create_organization_invitation_bulk_request_inner.rb +280 -0
- data/lib/clerk-http-client/models/create_organization_invitation_request.rb +280 -0
- data/lib/clerk-http-client/models/create_organization_membership_request.rb +239 -0
- data/lib/clerk-http-client/models/create_organization_request.rb +289 -0
- data/lib/clerk-http-client/models/create_phone_number_request.rb +258 -0
- data/lib/clerk-http-client/models/create_redirect_url_request.rb +215 -0
- data/lib/clerk-http-client/models/create_saml_connection_request.rb +355 -0
- data/lib/clerk-http-client/models/create_saml_connection_request_attribute_mapping.rb +242 -0
- data/lib/clerk-http-client/models/create_session_token_from_template200_response.rb +257 -0
- data/lib/clerk-http-client/models/create_sign_in_token_request.rb +227 -0
- data/lib/clerk-http-client/models/create_user_request.rb +453 -0
- data/lib/clerk-http-client/models/deleted_object.rb +255 -0
- data/lib/clerk-http-client/models/disable_mfa200_response.rb +214 -0
- data/lib/clerk-http-client/models/domain.rb +368 -0
- data/lib/clerk-http-client/models/domains.rb +240 -0
- data/lib/clerk-http-client/models/email_address.rb +361 -0
- data/lib/clerk-http-client/models/email_address_verification.rb +106 -0
- data/lib/clerk-http-client/models/get_o_auth_access_token200_response_inner.rb +295 -0
- data/lib/clerk-http-client/models/identification_link.rb +271 -0
- data/lib/clerk-http-client/models/instance_restrictions.rb +285 -0
- data/lib/clerk-http-client/models/invitation.rb +388 -0
- data/lib/clerk-http-client/models/jwt_template.rb +387 -0
- data/lib/clerk-http-client/models/merge_organization_metadata_request.rb +225 -0
- data/lib/clerk-http-client/models/o_auth_application.rb +449 -0
- data/lib/clerk-http-client/models/o_auth_application_with_secret.rb +466 -0
- data/lib/clerk-http-client/models/o_auth_applications.rb +240 -0
- data/lib/clerk-http-client/models/oauth.rb +328 -0
- data/lib/clerk-http-client/models/oauth_error.rb +104 -0
- data/lib/clerk-http-client/models/organization.rb +413 -0
- data/lib/clerk-http-client/models/organization_domain.rb +364 -0
- data/lib/clerk-http-client/models/organization_domain_verification.rb +281 -0
- data/lib/clerk-http-client/models/organization_domains.rb +240 -0
- data/lib/clerk-http-client/models/organization_invitation.rb +342 -0
- data/lib/clerk-http-client/models/organization_invitation_with_public_organization_data.rb +351 -0
- data/lib/clerk-http-client/models/organization_invitation_with_public_organization_data_public_organization_data.rb +250 -0
- data/lib/clerk-http-client/models/organization_invitations.rb +240 -0
- data/lib/clerk-http-client/models/organization_invitations_with_public_organization_data.rb +240 -0
- data/lib/clerk-http-client/models/organization_membership.rb +346 -0
- data/lib/clerk-http-client/models/organization_membership_public_user_data.rb +272 -0
- data/lib/clerk-http-client/models/organization_memberships.rb +240 -0
- data/lib/clerk-http-client/models/organization_settings.rb +391 -0
- data/lib/clerk-http-client/models/organization_with_logo.rb +454 -0
- data/lib/clerk-http-client/models/organizations.rb +240 -0
- data/lib/clerk-http-client/models/otp.rb +315 -0
- data/lib/clerk-http-client/models/passkey.rb +324 -0
- data/lib/clerk-http-client/models/phone_number.rb +391 -0
- data/lib/clerk-http-client/models/phone_number_verification.rb +105 -0
- data/lib/clerk-http-client/models/preview_template_request.rb +246 -0
- data/lib/clerk-http-client/models/proxy_check.rb +367 -0
- data/lib/clerk-http-client/models/redirect_url.rb +321 -0
- data/lib/clerk-http-client/models/revoke_invitation200_response.rb +395 -0
- data/lib/clerk-http-client/models/revoke_organization_invitation_request.rb +216 -0
- data/lib/clerk-http-client/models/saml.rb +331 -0
- data/lib/clerk-http-client/models/saml_account.rb +381 -0
- data/lib/clerk-http-client/models/saml_account_saml_connection.rb +104 -0
- data/lib/clerk-http-client/models/saml_account_verification.rb +105 -0
- data/lib/clerk-http-client/models/saml_connection.rb +362 -0
- data/lib/clerk-http-client/models/saml_connections.rb +240 -0
- data/lib/clerk-http-client/models/schemas_passkey.rb +310 -0
- data/lib/clerk-http-client/models/schemas_passkey_verification.rb +104 -0
- data/lib/clerk-http-client/models/schemas_saml_connection.rb +541 -0
- data/lib/clerk-http-client/models/schemas_saml_connection_attribute_mapping.rb +241 -0
- data/lib/clerk-http-client/models/session.rb +444 -0
- data/lib/clerk-http-client/models/session_latest_activity.rb +300 -0
- data/lib/clerk-http-client/models/sign_in_token.rb +368 -0
- data/lib/clerk-http-client/models/sign_up.rb +517 -0
- data/lib/clerk-http-client/models/svix_url.rb +221 -0
- data/lib/clerk-http-client/models/template.rb +460 -0
- data/lib/clerk-http-client/models/testing_token.rb +289 -0
- data/lib/clerk-http-client/models/ticket.rb +303 -0
- data/lib/clerk-http-client/models/toggle_template_delivery_request.rb +216 -0
- data/lib/clerk-http-client/models/total_count.rb +272 -0
- data/lib/clerk-http-client/models/totp.rb +289 -0
- data/lib/clerk-http-client/models/update_domain_request.rb +238 -0
- data/lib/clerk-http-client/models/update_email_address_request.rb +227 -0
- data/lib/clerk-http-client/models/update_instance_auth_config200_response.rb +294 -0
- data/lib/clerk-http-client/models/update_instance_auth_config_request.rb +273 -0
- data/lib/clerk-http-client/models/update_instance_organization_settings_request.rb +277 -0
- data/lib/clerk-http-client/models/update_instance_request.rb +300 -0
- data/lib/clerk-http-client/models/update_instance_restrictions_request.rb +255 -0
- data/lib/clerk-http-client/models/update_o_auth_application_request.rb +237 -0
- data/lib/clerk-http-client/models/update_organization_domain_request.rb +227 -0
- data/lib/clerk-http-client/models/update_organization_membership_metadata_request.rb +225 -0
- data/lib/clerk-http-client/models/update_organization_membership_request.rb +222 -0
- data/lib/clerk-http-client/models/update_organization_request.rb +279 -0
- data/lib/clerk-http-client/models/update_phone_number_request.rb +238 -0
- data/lib/clerk-http-client/models/update_production_instance_domain_request.rb +215 -0
- data/lib/clerk-http-client/models/update_saml_connection_request.rb +347 -0
- data/lib/clerk-http-client/models/update_saml_connection_request_attribute_mapping.rb +242 -0
- data/lib/clerk-http-client/models/update_sign_up_request.rb +216 -0
- data/lib/clerk-http-client/models/update_user_metadata_request.rb +241 -0
- data/lib/clerk-http-client/models/update_user_request.rb +472 -0
- data/lib/clerk-http-client/models/upsert_template_request.rb +278 -0
- data/lib/clerk-http-client/models/user.rb +633 -0
- data/lib/clerk-http-client/models/verify_client_request.rb +215 -0
- data/lib/clerk-http-client/models/verify_domain_proxy_request.rb +225 -0
- data/lib/clerk-http-client/models/verify_password200_response.rb +214 -0
- data/lib/clerk-http-client/models/verify_password_request.rb +222 -0
- data/lib/clerk-http-client/models/verify_session_request.rb +215 -0
- data/lib/clerk-http-client/models/verify_totp200_response.rb +257 -0
- data/lib/clerk-http-client/models/verify_totp_request.rb +222 -0
- data/lib/clerk-http-client/models/web3_signature.rb +323 -0
- data/lib/clerk-http-client/models/web3_wallet.rb +327 -0
- data/lib/clerk-http-client/models/web3_wallet_verification.rb +105 -0
- data/lib/clerk-http-client/models/well_known_jwks.rb +216 -0
- data/lib/clerk-http-client/models/well_known_jwks_keys_inner.rb +259 -0
- data/lib/clerk-http-client/version.rb +15 -0
- data/lib/clerk-http-client.rb +321 -0
- data/openapitools.json +7 -0
- data/pkg/clerk-http-client-1.0.0.gem +0 -0
- data/resources/.DS_Store +0 -0
- data/resources/oas/bapi-2024-10-01.yml +7238 -0
- data/resources/templates/Gemfile.mustache +9 -0
- data/resources/templates/README.mustache +163 -0
- data/resources/templates/Rakefile.mustache +10 -0
- data/resources/templates/api.mustache +257 -0
- data/resources/templates/api_client.mustache +246 -0
- data/resources/templates/api_client_faraday_partial.mustache +200 -0
- data/resources/templates/api_client_httpx_partial.mustache +134 -0
- data/resources/templates/api_client_typhoeus_partial.mustache +161 -0
- data/resources/templates/api_doc.mustache +132 -0
- data/resources/templates/api_error.mustache +50 -0
- data/resources/templates/api_info.mustache +12 -0
- data/resources/templates/api_test.mustache +47 -0
- data/resources/templates/base_object.mustache +114 -0
- data/resources/templates/configuration.mustache +491 -0
- data/resources/templates/configuration_faraday_partial.mustache +40 -0
- data/resources/templates/configuration_httpx_partial.mustache +11 -0
- data/resources/templates/configuration_typhoeus_partial.mustache +41 -0
- data/resources/templates/gem.mustache +89 -0
- data/resources/templates/gemspec.mustache +41 -0
- data/resources/templates/git_push.sh.mustache +57 -0
- data/resources/templates/gitignore.mustache +39 -0
- data/resources/templates/gitlab-ci.mustache +26 -0
- data/resources/templates/model.mustache +33 -0
- data/resources/templates/model_doc.mustache +12 -0
- data/resources/templates/model_test.mustache +82 -0
- data/resources/templates/partial_anyof_module.mustache +94 -0
- data/resources/templates/partial_model_enum_class.mustache +23 -0
- data/resources/templates/partial_model_generic.mustache +377 -0
- data/resources/templates/partial_model_generic_doc.mustache +28 -0
- data/resources/templates/partial_oneof_module.mustache +137 -0
- data/resources/templates/partial_oneof_module_doc.mustache +93 -0
- data/resources/templates/rspec.mustache +2 -0
- data/resources/templates/rubocop.mustache +148 -0
- data/resources/templates/spec_helper.mustache +103 -0
- data/resources/templates/travis.mustache +11 -0
- data/resources/templates/version.mustache +7 -0
- data/sdk-generator-config.json +20 -0
- data/spec/api/actor_tokens_api_spec.rb +59 -0
- data/spec/api/allow_list_block_list_api_spec.rb +105 -0
- data/spec/api/beta_features_api_spec.rb +71 -0
- data/spec/api/clients_api_spec.rb +72 -0
- data/spec/api/domains_api_spec.rb +83 -0
- data/spec/api/email_addresses_api_spec.rb +84 -0
- data/spec/api/email_sms_templates_api_spec.rb +115 -0
- data/spec/api/instance_settings_api_spec.rb +71 -0
- data/spec/api/invitations_api_spec.rb +73 -0
- data/spec/api/jwks_api_spec.rb +46 -0
- data/spec/api/jwt_templates_api_spec.rb +94 -0
- data/spec/api/miscellaneous_api_spec.rb +48 -0
- data/spec/api/o_auth_applications_api_spec.rb +109 -0
- data/spec/api/organization_domain_api_spec.rb +49 -0
- data/spec/api/organization_domains_api_spec.rb +77 -0
- data/spec/api/organization_invitations_api_spec.rb +133 -0
- data/spec/api/organization_memberships_api_spec.rb +118 -0
- data/spec/api/organizations_api_spec.rb +139 -0
- data/spec/api/phone_numbers_api_spec.rb +84 -0
- data/spec/api/proxy_checks_api_spec.rb +47 -0
- data/spec/api/redirect_urls_api_spec.rb +82 -0
- data/spec/api/saml_connections_api_spec.rb +97 -0
- data/spec/api/sessions_api_spec.rb +101 -0
- data/spec/api/sign_in_tokens_api_spec.rb +59 -0
- data/spec/api/sign_ups_api_spec.rb +48 -0
- data/spec/api/testing_tokens_api_spec.rb +46 -0
- data/spec/api/users_api_spec.rb +366 -0
- data/spec/api/webhooks_api_spec.rb +68 -0
- data/spec/models/actor_token_spec.rb +92 -0
- data/spec/models/add_domain_request_spec.rb +48 -0
- data/spec/models/admin_spec.rb +62 -0
- data/spec/models/allowlist_identifier_spec.rb +86 -0
- data/spec/models/blocklist_identifier_spec.rb +80 -0
- data/spec/models/blocklist_identifiers_spec.rb +42 -0
- data/spec/models/c_name_target_spec.rb +48 -0
- data/spec/models/change_production_instance_domain_request_spec.rb +42 -0
- data/spec/models/clerk_error_spec.rb +60 -0
- data/spec/models/clerk_errors_spec.rb +42 -0
- data/spec/models/client_spec.rb +88 -0
- data/spec/models/create_actor_token_request_spec.rb +54 -0
- data/spec/models/create_allowlist_identifier_request_spec.rb +42 -0
- data/spec/models/create_blocklist_identifier_request_spec.rb +36 -0
- data/spec/models/create_email_address_request_spec.rb +54 -0
- data/spec/models/create_invitation_request_spec.rb +66 -0
- data/spec/models/create_jwt_template_request_spec.rb +72 -0
- data/spec/models/create_o_auth_application_request_spec.rb +54 -0
- data/spec/models/create_organization_domain_request_spec.rb +48 -0
- data/spec/models/create_organization_invitation_bulk_request_inner_spec.rb +66 -0
- data/spec/models/create_organization_invitation_request_spec.rb +66 -0
- data/spec/models/create_organization_membership_request_spec.rb +42 -0
- data/spec/models/create_organization_request_spec.rb +72 -0
- data/spec/models/create_phone_number_request_spec.rb +60 -0
- data/spec/models/create_redirect_url_request_spec.rb +36 -0
- data/spec/models/create_saml_connection_request_attribute_mapping_spec.rb +54 -0
- data/spec/models/create_saml_connection_request_spec.rb +88 -0
- data/spec/models/create_session_token_from_template200_response_spec.rb +46 -0
- data/spec/models/create_sign_in_token_request_spec.rb +42 -0
- data/spec/models/create_user_request_spec.rb +168 -0
- data/spec/models/deleted_object_spec.rb +54 -0
- data/spec/models/disable_mfa200_response_spec.rb +36 -0
- data/spec/models/domain_spec.rb +88 -0
- data/spec/models/domains_spec.rb +42 -0
- data/spec/models/email_address_spec.rb +82 -0
- data/spec/models/email_address_verification_spec.rb +32 -0
- data/spec/models/get_o_auth_access_token200_response_inner_spec.rb +84 -0
- data/spec/models/identification_link_spec.rb +46 -0
- data/spec/models/instance_restrictions_spec.rb +64 -0
- data/spec/models/invitation_spec.rb +98 -0
- data/spec/models/jwt_template_spec.rb +94 -0
- data/spec/models/merge_organization_metadata_request_spec.rb +42 -0
- data/spec/models/o_auth_application_spec.rb +112 -0
- data/spec/models/o_auth_application_with_secret_spec.rb +118 -0
- data/spec/models/o_auth_applications_spec.rb +42 -0
- data/spec/models/oauth_error_spec.rb +32 -0
- data/spec/models/oauth_spec.rb +74 -0
- data/spec/models/organization_domain_spec.rb +104 -0
- data/spec/models/organization_domain_verification_spec.rb +58 -0
- data/spec/models/organization_domains_spec.rb +42 -0
- data/spec/models/organization_invitation_spec.rb +100 -0
- data/spec/models/organization_invitation_with_public_organization_data_public_organization_data_spec.rb +60 -0
- data/spec/models/organization_invitation_with_public_organization_data_spec.rb +106 -0
- data/spec/models/organization_invitations_spec.rb +42 -0
- data/spec/models/organization_invitations_with_public_organization_data_spec.rb +42 -0
- data/spec/models/organization_membership_public_user_data_spec.rb +72 -0
- data/spec/models/organization_membership_spec.rb +100 -0
- data/spec/models/organization_memberships_spec.rb +42 -0
- data/spec/models/organization_settings_spec.rb +98 -0
- data/spec/models/organization_spec.rb +106 -0
- data/spec/models/organization_with_logo_spec.rb +124 -0
- data/spec/models/organizations_spec.rb +42 -0
- data/spec/models/otp_spec.rb +62 -0
- data/spec/models/passkey_spec.rb +72 -0
- data/spec/models/phone_number_spec.rb +100 -0
- data/spec/models/phone_number_verification_spec.rb +32 -0
- data/spec/models/preview_template_request_spec.rb +54 -0
- data/spec/models/proxy_check_spec.rb +82 -0
- data/spec/models/redirect_url_spec.rb +64 -0
- data/spec/models/revoke_invitation200_response_spec.rb +98 -0
- data/spec/models/revoke_organization_invitation_request_spec.rb +36 -0
- data/spec/models/saml_account_saml_connection_spec.rb +32 -0
- data/spec/models/saml_account_spec.rb +100 -0
- data/spec/models/saml_account_verification_spec.rb +32 -0
- data/spec/models/saml_connection_spec.rb +96 -0
- data/spec/models/saml_connections_spec.rb +42 -0
- data/spec/models/saml_spec.rb +74 -0
- data/spec/models/schemas_passkey_spec.rb +64 -0
- data/spec/models/schemas_passkey_verification_spec.rb +32 -0
- data/spec/models/schemas_saml_connection_attribute_mapping_spec.rb +54 -0
- data/spec/models/schemas_saml_connection_spec.rb +166 -0
- data/spec/models/session_latest_activity_spec.rb +84 -0
- data/spec/models/session_spec.rb +116 -0
- data/spec/models/sign_in_token_spec.rb +86 -0
- data/spec/models/sign_up_spec.rb +176 -0
- data/spec/models/svix_url_spec.rb +36 -0
- data/spec/models/template_spec.rb +166 -0
- data/spec/models/testing_token_spec.rb +52 -0
- data/spec/models/ticket_spec.rb +62 -0
- data/spec/models/toggle_template_delivery_request_spec.rb +36 -0
- data/spec/models/total_count_spec.rb +46 -0
- data/spec/models/totp_spec.rb +66 -0
- data/spec/models/update_domain_request_spec.rb +48 -0
- data/spec/models/update_email_address_request_spec.rb +42 -0
- data/spec/models/update_instance_auth_config200_response_spec.rb +70 -0
- data/spec/models/update_instance_auth_config_request_spec.rb +66 -0
- data/spec/models/update_instance_organization_settings_request_spec.rb +72 -0
- data/spec/models/update_instance_request_spec.rb +84 -0
- data/spec/models/update_instance_restrictions_request_spec.rb +60 -0
- data/spec/models/update_o_auth_application_request_spec.rb +48 -0
- data/spec/models/update_organization_domain_request_spec.rb +42 -0
- data/spec/models/update_organization_membership_metadata_request_spec.rb +42 -0
- data/spec/models/update_organization_membership_request_spec.rb +36 -0
- data/spec/models/update_organization_request_spec.rb +72 -0
- data/spec/models/update_phone_number_request_spec.rb +48 -0
- data/spec/models/update_production_instance_domain_request_spec.rb +36 -0
- data/spec/models/update_saml_connection_request_attribute_mapping_spec.rb +54 -0
- data/spec/models/update_saml_connection_request_spec.rb +108 -0
- data/spec/models/update_sign_up_request_spec.rb +36 -0
- data/spec/models/update_user_metadata_request_spec.rb +48 -0
- data/spec/models/update_user_request_spec.rb +180 -0
- data/spec/models/upsert_template_request_spec.rb +72 -0
- data/spec/models/user_spec.rb +268 -0
- data/spec/models/verify_client_request_spec.rb +36 -0
- data/spec/models/verify_domain_proxy_request_spec.rb +42 -0
- data/spec/models/verify_password200_response_spec.rb +36 -0
- data/spec/models/verify_password_request_spec.rb +36 -0
- data/spec/models/verify_session_request_spec.rb +36 -0
- data/spec/models/verify_totp200_response_spec.rb +46 -0
- data/spec/models/verify_totp_request_spec.rb +36 -0
- data/spec/models/web3_signature_spec.rb +74 -0
- data/spec/models/web3_wallet_spec.rb +70 -0
- data/spec/models/web3_wallet_verification_spec.rb +32 -0
- data/spec/models/well_known_jwks_keys_inner_spec.rb +66 -0
- data/spec/models/well_known_jwks_spec.rb +36 -0
- data/spec/spec_helper.rb +111 -0
- data/test.rb +2 -0
- metadata +782 -0
data/docs/UsersApi.md
ADDED
@@ -0,0 +1,1829 @@
|
|
1
|
+
# ClerkHttpClient::UsersApi
|
2
|
+
|
3
|
+
All URIs are relative to *https://api.clerk.com/v1*
|
4
|
+
|
5
|
+
| Method | HTTP request | Description |
|
6
|
+
| ------ | ------------ | ----------- |
|
7
|
+
| [**ban_user**](UsersApi.md#ban_user) | **POST** /users/{user_id}/ban | Ban a user |
|
8
|
+
| [**create_user**](UsersApi.md#create_user) | **POST** /users | Create a new user |
|
9
|
+
| [**create_user_totp**](UsersApi.md#create_user_totp) | **POST** /users/{user_id}/totp | Create a TOTP for a user |
|
10
|
+
| [**delete_backup_code**](UsersApi.md#delete_backup_code) | **DELETE** /users/{user_id}/backup_code | Disable all user's Backup codes |
|
11
|
+
| [**delete_external_account**](UsersApi.md#delete_external_account) | **DELETE** /users/{user_id}/external_accounts/{external_account_id} | Delete External Account |
|
12
|
+
| [**delete_totp**](UsersApi.md#delete_totp) | **DELETE** /users/{user_id}/totp | Delete all the user's TOTPs |
|
13
|
+
| [**delete_user**](UsersApi.md#delete_user) | **DELETE** /users/{user_id} | Delete a user |
|
14
|
+
| [**delete_user_profile_image**](UsersApi.md#delete_user_profile_image) | **DELETE** /users/{user_id}/profile_image | Delete user profile image |
|
15
|
+
| [**disable_mfa**](UsersApi.md#disable_mfa) | **DELETE** /users/{user_id}/mfa | Disable a user's MFA methods |
|
16
|
+
| [**get_o_auth_access_token**](UsersApi.md#get_o_auth_access_token) | **GET** /users/{user_id}/oauth_access_tokens/{provider} | Retrieve the OAuth access token of a user |
|
17
|
+
| [**get_user**](UsersApi.md#get_user) | **GET** /users/{user_id} | Retrieve a user |
|
18
|
+
| [**get_user_list**](UsersApi.md#get_user_list) | **GET** /users | List all users |
|
19
|
+
| [**get_users_count**](UsersApi.md#get_users_count) | **GET** /users/count | Count users |
|
20
|
+
| [**lock_user**](UsersApi.md#lock_user) | **POST** /users/{user_id}/lock | Lock a user |
|
21
|
+
| [**set_user_profile_image**](UsersApi.md#set_user_profile_image) | **POST** /users/{user_id}/profile_image | Set user profile image |
|
22
|
+
| [**unban_user**](UsersApi.md#unban_user) | **POST** /users/{user_id}/unban | Unban a user |
|
23
|
+
| [**unlock_user**](UsersApi.md#unlock_user) | **POST** /users/{user_id}/unlock | Unlock a user |
|
24
|
+
| [**update_user**](UsersApi.md#update_user) | **PATCH** /users/{user_id} | Update a user |
|
25
|
+
| [**update_user_metadata**](UsersApi.md#update_user_metadata) | **PATCH** /users/{user_id}/metadata | Merge and update a user's metadata |
|
26
|
+
| [**user_passkey_delete**](UsersApi.md#user_passkey_delete) | **DELETE** /users/{user_id}/passkeys/{passkey_identification_id} | Delete a user passkey |
|
27
|
+
| [**user_web3_wallet_delete**](UsersApi.md#user_web3_wallet_delete) | **DELETE** /users/{user_id}/web3_wallets/{web3_wallet_identification_id} | Delete a user web3 wallet |
|
28
|
+
| [**users_get_organization_invitations**](UsersApi.md#users_get_organization_invitations) | **GET** /users/{user_id}/organization_invitations | Retrieve all invitations for a user |
|
29
|
+
| [**users_get_organization_memberships**](UsersApi.md#users_get_organization_memberships) | **GET** /users/{user_id}/organization_memberships | Retrieve all memberships for a user |
|
30
|
+
| [**verify_password**](UsersApi.md#verify_password) | **POST** /users/{user_id}/verify_password | Verify the password of a user |
|
31
|
+
| [**verify_totp**](UsersApi.md#verify_totp) | **POST** /users/{user_id}/verify_totp | Verify a TOTP or backup code for a user |
|
32
|
+
|
33
|
+
|
34
|
+
## ban_user
|
35
|
+
|
36
|
+
> <User> ban_user(user_id)
|
37
|
+
|
38
|
+
Ban a user
|
39
|
+
|
40
|
+
Marks the given user as banned, which means that all their sessions are revoked and they are not allowed to sign in again.
|
41
|
+
|
42
|
+
### Examples
|
43
|
+
|
44
|
+
```ruby
|
45
|
+
require 'time'
|
46
|
+
require 'clerk-http-client'
|
47
|
+
# setup authorization
|
48
|
+
ClerkHttpClient.configure do |config|
|
49
|
+
# Configure Bearer authorization (sk_<environment>_<secret value>): bearerAuth
|
50
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
51
|
+
end
|
52
|
+
|
53
|
+
api_instance = ClerkHttpClient::UsersApi.new
|
54
|
+
user_id = 'user_id_example' # String | The ID of the user to ban
|
55
|
+
|
56
|
+
begin
|
57
|
+
# Ban a user
|
58
|
+
result = api_instance.ban_user(user_id)
|
59
|
+
p result
|
60
|
+
rescue ClerkHttpClient::ApiError => e
|
61
|
+
puts "Error when calling UsersApi->ban_user: #{e}"
|
62
|
+
end
|
63
|
+
```
|
64
|
+
|
65
|
+
#### Using the ban_user_with_http_info variant
|
66
|
+
|
67
|
+
This returns an Array which contains the response data, status code and headers.
|
68
|
+
|
69
|
+
> <Array(<User>, Integer, Hash)> ban_user_with_http_info(user_id)
|
70
|
+
|
71
|
+
```ruby
|
72
|
+
begin
|
73
|
+
# Ban a user
|
74
|
+
data, status_code, headers = api_instance.ban_user_with_http_info(user_id)
|
75
|
+
p status_code # => 2xx
|
76
|
+
p headers # => { ... }
|
77
|
+
p data # => <User>
|
78
|
+
rescue ClerkHttpClient::ApiError => e
|
79
|
+
puts "Error when calling UsersApi->ban_user_with_http_info: #{e}"
|
80
|
+
end
|
81
|
+
```
|
82
|
+
|
83
|
+
### Parameters
|
84
|
+
|
85
|
+
| Name | Type | Description | Notes |
|
86
|
+
| ---- | ---- | ----------- | ----- |
|
87
|
+
| **user_id** | **String** | The ID of the user to ban | |
|
88
|
+
|
89
|
+
### Return type
|
90
|
+
|
91
|
+
[**User**](User.md)
|
92
|
+
|
93
|
+
### Authorization
|
94
|
+
|
95
|
+
[bearerAuth](../README.md#bearerAuth)
|
96
|
+
|
97
|
+
### HTTP request headers
|
98
|
+
|
99
|
+
- **Content-Type**: Not defined
|
100
|
+
- **Accept**: application/json
|
101
|
+
|
102
|
+
|
103
|
+
## create_user
|
104
|
+
|
105
|
+
> <User> create_user(create_user_request)
|
106
|
+
|
107
|
+
Create a new user
|
108
|
+
|
109
|
+
Creates a new user. Your user management settings determine how you should setup your user model. Any email address and phone number created using this method will be marked as verified. Note: If you are performing a migration, check out our guide on [zero downtime migrations](https://clerk.com/docs/deployments/migrate-overview). A rate limit rule of 20 requests per 10 seconds is applied to this endpoint.
|
110
|
+
|
111
|
+
### Examples
|
112
|
+
|
113
|
+
```ruby
|
114
|
+
require 'time'
|
115
|
+
require 'clerk-http-client'
|
116
|
+
# setup authorization
|
117
|
+
ClerkHttpClient.configure do |config|
|
118
|
+
# Configure Bearer authorization (sk_<environment>_<secret value>): bearerAuth
|
119
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
120
|
+
end
|
121
|
+
|
122
|
+
api_instance = ClerkHttpClient::UsersApi.new
|
123
|
+
create_user_request = ClerkHttpClient::CreateUserRequest.new # CreateUserRequest |
|
124
|
+
|
125
|
+
begin
|
126
|
+
# Create a new user
|
127
|
+
result = api_instance.create_user(create_user_request)
|
128
|
+
p result
|
129
|
+
rescue ClerkHttpClient::ApiError => e
|
130
|
+
puts "Error when calling UsersApi->create_user: #{e}"
|
131
|
+
end
|
132
|
+
```
|
133
|
+
|
134
|
+
#### Using the create_user_with_http_info variant
|
135
|
+
|
136
|
+
This returns an Array which contains the response data, status code and headers.
|
137
|
+
|
138
|
+
> <Array(<User>, Integer, Hash)> create_user_with_http_info(create_user_request)
|
139
|
+
|
140
|
+
```ruby
|
141
|
+
begin
|
142
|
+
# Create a new user
|
143
|
+
data, status_code, headers = api_instance.create_user_with_http_info(create_user_request)
|
144
|
+
p status_code # => 2xx
|
145
|
+
p headers # => { ... }
|
146
|
+
p data # => <User>
|
147
|
+
rescue ClerkHttpClient::ApiError => e
|
148
|
+
puts "Error when calling UsersApi->create_user_with_http_info: #{e}"
|
149
|
+
end
|
150
|
+
```
|
151
|
+
|
152
|
+
### Parameters
|
153
|
+
|
154
|
+
| Name | Type | Description | Notes |
|
155
|
+
| ---- | ---- | ----------- | ----- |
|
156
|
+
| **create_user_request** | [**CreateUserRequest**](CreateUserRequest.md) | | |
|
157
|
+
|
158
|
+
### Return type
|
159
|
+
|
160
|
+
[**User**](User.md)
|
161
|
+
|
162
|
+
### Authorization
|
163
|
+
|
164
|
+
[bearerAuth](../README.md#bearerAuth)
|
165
|
+
|
166
|
+
### HTTP request headers
|
167
|
+
|
168
|
+
- **Content-Type**: application/json
|
169
|
+
- **Accept**: application/json
|
170
|
+
|
171
|
+
|
172
|
+
## create_user_totp
|
173
|
+
|
174
|
+
> <TOTP> create_user_totp(user_id)
|
175
|
+
|
176
|
+
Create a TOTP for a user
|
177
|
+
|
178
|
+
Creates a TOTP (Time-based One-Time Password) for a given user, returning both the TOTP secret and the URI.
|
179
|
+
|
180
|
+
### Examples
|
181
|
+
|
182
|
+
```ruby
|
183
|
+
require 'time'
|
184
|
+
require 'clerk-http-client'
|
185
|
+
# setup authorization
|
186
|
+
ClerkHttpClient.configure do |config|
|
187
|
+
# Configure Bearer authorization (sk_<environment>_<secret value>): bearerAuth
|
188
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
189
|
+
end
|
190
|
+
|
191
|
+
api_instance = ClerkHttpClient::UsersApi.new
|
192
|
+
user_id = 'user_id_example' # String | The ID of the user for whom the TOTP is being created.
|
193
|
+
|
194
|
+
begin
|
195
|
+
# Create a TOTP for a user
|
196
|
+
result = api_instance.create_user_totp(user_id)
|
197
|
+
p result
|
198
|
+
rescue ClerkHttpClient::ApiError => e
|
199
|
+
puts "Error when calling UsersApi->create_user_totp: #{e}"
|
200
|
+
end
|
201
|
+
```
|
202
|
+
|
203
|
+
#### Using the create_user_totp_with_http_info variant
|
204
|
+
|
205
|
+
This returns an Array which contains the response data, status code and headers.
|
206
|
+
|
207
|
+
> <Array(<TOTP>, Integer, Hash)> create_user_totp_with_http_info(user_id)
|
208
|
+
|
209
|
+
```ruby
|
210
|
+
begin
|
211
|
+
# Create a TOTP for a user
|
212
|
+
data, status_code, headers = api_instance.create_user_totp_with_http_info(user_id)
|
213
|
+
p status_code # => 2xx
|
214
|
+
p headers # => { ... }
|
215
|
+
p data # => <TOTP>
|
216
|
+
rescue ClerkHttpClient::ApiError => e
|
217
|
+
puts "Error when calling UsersApi->create_user_totp_with_http_info: #{e}"
|
218
|
+
end
|
219
|
+
```
|
220
|
+
|
221
|
+
### Parameters
|
222
|
+
|
223
|
+
| Name | Type | Description | Notes |
|
224
|
+
| ---- | ---- | ----------- | ----- |
|
225
|
+
| **user_id** | **String** | The ID of the user for whom the TOTP is being created. | |
|
226
|
+
|
227
|
+
### Return type
|
228
|
+
|
229
|
+
[**TOTP**](TOTP.md)
|
230
|
+
|
231
|
+
### Authorization
|
232
|
+
|
233
|
+
[bearerAuth](../README.md#bearerAuth)
|
234
|
+
|
235
|
+
### HTTP request headers
|
236
|
+
|
237
|
+
- **Content-Type**: Not defined
|
238
|
+
- **Accept**: application/json
|
239
|
+
|
240
|
+
|
241
|
+
## delete_backup_code
|
242
|
+
|
243
|
+
> <DisableMFA200Response> delete_backup_code(user_id)
|
244
|
+
|
245
|
+
Disable all user's Backup codes
|
246
|
+
|
247
|
+
Disable all of a user's backup codes.
|
248
|
+
|
249
|
+
### Examples
|
250
|
+
|
251
|
+
```ruby
|
252
|
+
require 'time'
|
253
|
+
require 'clerk-http-client'
|
254
|
+
# setup authorization
|
255
|
+
ClerkHttpClient.configure do |config|
|
256
|
+
# Configure Bearer authorization (sk_<environment>_<secret value>): bearerAuth
|
257
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
258
|
+
end
|
259
|
+
|
260
|
+
api_instance = ClerkHttpClient::UsersApi.new
|
261
|
+
user_id = 'user_id_example' # String | The ID of the user whose backup codes are to be deleted.
|
262
|
+
|
263
|
+
begin
|
264
|
+
# Disable all user's Backup codes
|
265
|
+
result = api_instance.delete_backup_code(user_id)
|
266
|
+
p result
|
267
|
+
rescue ClerkHttpClient::ApiError => e
|
268
|
+
puts "Error when calling UsersApi->delete_backup_code: #{e}"
|
269
|
+
end
|
270
|
+
```
|
271
|
+
|
272
|
+
#### Using the delete_backup_code_with_http_info variant
|
273
|
+
|
274
|
+
This returns an Array which contains the response data, status code and headers.
|
275
|
+
|
276
|
+
> <Array(<DisableMFA200Response>, Integer, Hash)> delete_backup_code_with_http_info(user_id)
|
277
|
+
|
278
|
+
```ruby
|
279
|
+
begin
|
280
|
+
# Disable all user's Backup codes
|
281
|
+
data, status_code, headers = api_instance.delete_backup_code_with_http_info(user_id)
|
282
|
+
p status_code # => 2xx
|
283
|
+
p headers # => { ... }
|
284
|
+
p data # => <DisableMFA200Response>
|
285
|
+
rescue ClerkHttpClient::ApiError => e
|
286
|
+
puts "Error when calling UsersApi->delete_backup_code_with_http_info: #{e}"
|
287
|
+
end
|
288
|
+
```
|
289
|
+
|
290
|
+
### Parameters
|
291
|
+
|
292
|
+
| Name | Type | Description | Notes |
|
293
|
+
| ---- | ---- | ----------- | ----- |
|
294
|
+
| **user_id** | **String** | The ID of the user whose backup codes are to be deleted. | |
|
295
|
+
|
296
|
+
### Return type
|
297
|
+
|
298
|
+
[**DisableMFA200Response**](DisableMFA200Response.md)
|
299
|
+
|
300
|
+
### Authorization
|
301
|
+
|
302
|
+
[bearerAuth](../README.md#bearerAuth)
|
303
|
+
|
304
|
+
### HTTP request headers
|
305
|
+
|
306
|
+
- **Content-Type**: Not defined
|
307
|
+
- **Accept**: application/json
|
308
|
+
|
309
|
+
|
310
|
+
## delete_external_account
|
311
|
+
|
312
|
+
> <DeletedObject> delete_external_account(user_id, external_account_id)
|
313
|
+
|
314
|
+
Delete External Account
|
315
|
+
|
316
|
+
Delete an external account by ID.
|
317
|
+
|
318
|
+
### Examples
|
319
|
+
|
320
|
+
```ruby
|
321
|
+
require 'time'
|
322
|
+
require 'clerk-http-client'
|
323
|
+
# setup authorization
|
324
|
+
ClerkHttpClient.configure do |config|
|
325
|
+
# Configure Bearer authorization (sk_<environment>_<secret value>): bearerAuth
|
326
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
327
|
+
end
|
328
|
+
|
329
|
+
api_instance = ClerkHttpClient::UsersApi.new
|
330
|
+
user_id = 'user_id_example' # String | The ID of the user's external account
|
331
|
+
external_account_id = 'external_account_id_example' # String | The ID of the external account to delete
|
332
|
+
|
333
|
+
begin
|
334
|
+
# Delete External Account
|
335
|
+
result = api_instance.delete_external_account(user_id, external_account_id)
|
336
|
+
p result
|
337
|
+
rescue ClerkHttpClient::ApiError => e
|
338
|
+
puts "Error when calling UsersApi->delete_external_account: #{e}"
|
339
|
+
end
|
340
|
+
```
|
341
|
+
|
342
|
+
#### Using the delete_external_account_with_http_info variant
|
343
|
+
|
344
|
+
This returns an Array which contains the response data, status code and headers.
|
345
|
+
|
346
|
+
> <Array(<DeletedObject>, Integer, Hash)> delete_external_account_with_http_info(user_id, external_account_id)
|
347
|
+
|
348
|
+
```ruby
|
349
|
+
begin
|
350
|
+
# Delete External Account
|
351
|
+
data, status_code, headers = api_instance.delete_external_account_with_http_info(user_id, external_account_id)
|
352
|
+
p status_code # => 2xx
|
353
|
+
p headers # => { ... }
|
354
|
+
p data # => <DeletedObject>
|
355
|
+
rescue ClerkHttpClient::ApiError => e
|
356
|
+
puts "Error when calling UsersApi->delete_external_account_with_http_info: #{e}"
|
357
|
+
end
|
358
|
+
```
|
359
|
+
|
360
|
+
### Parameters
|
361
|
+
|
362
|
+
| Name | Type | Description | Notes |
|
363
|
+
| ---- | ---- | ----------- | ----- |
|
364
|
+
| **user_id** | **String** | The ID of the user's external account | |
|
365
|
+
| **external_account_id** | **String** | The ID of the external account to delete | |
|
366
|
+
|
367
|
+
### Return type
|
368
|
+
|
369
|
+
[**DeletedObject**](DeletedObject.md)
|
370
|
+
|
371
|
+
### Authorization
|
372
|
+
|
373
|
+
[bearerAuth](../README.md#bearerAuth)
|
374
|
+
|
375
|
+
### HTTP request headers
|
376
|
+
|
377
|
+
- **Content-Type**: Not defined
|
378
|
+
- **Accept**: application/json
|
379
|
+
|
380
|
+
|
381
|
+
## delete_totp
|
382
|
+
|
383
|
+
> <DisableMFA200Response> delete_totp(user_id)
|
384
|
+
|
385
|
+
Delete all the user's TOTPs
|
386
|
+
|
387
|
+
Deletes all of the user's TOTPs.
|
388
|
+
|
389
|
+
### Examples
|
390
|
+
|
391
|
+
```ruby
|
392
|
+
require 'time'
|
393
|
+
require 'clerk-http-client'
|
394
|
+
# setup authorization
|
395
|
+
ClerkHttpClient.configure do |config|
|
396
|
+
# Configure Bearer authorization (sk_<environment>_<secret value>): bearerAuth
|
397
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
398
|
+
end
|
399
|
+
|
400
|
+
api_instance = ClerkHttpClient::UsersApi.new
|
401
|
+
user_id = 'user_id_example' # String | The ID of the user whose TOTPs are to be deleted
|
402
|
+
|
403
|
+
begin
|
404
|
+
# Delete all the user's TOTPs
|
405
|
+
result = api_instance.delete_totp(user_id)
|
406
|
+
p result
|
407
|
+
rescue ClerkHttpClient::ApiError => e
|
408
|
+
puts "Error when calling UsersApi->delete_totp: #{e}"
|
409
|
+
end
|
410
|
+
```
|
411
|
+
|
412
|
+
#### Using the delete_totp_with_http_info variant
|
413
|
+
|
414
|
+
This returns an Array which contains the response data, status code and headers.
|
415
|
+
|
416
|
+
> <Array(<DisableMFA200Response>, Integer, Hash)> delete_totp_with_http_info(user_id)
|
417
|
+
|
418
|
+
```ruby
|
419
|
+
begin
|
420
|
+
# Delete all the user's TOTPs
|
421
|
+
data, status_code, headers = api_instance.delete_totp_with_http_info(user_id)
|
422
|
+
p status_code # => 2xx
|
423
|
+
p headers # => { ... }
|
424
|
+
p data # => <DisableMFA200Response>
|
425
|
+
rescue ClerkHttpClient::ApiError => e
|
426
|
+
puts "Error when calling UsersApi->delete_totp_with_http_info: #{e}"
|
427
|
+
end
|
428
|
+
```
|
429
|
+
|
430
|
+
### Parameters
|
431
|
+
|
432
|
+
| Name | Type | Description | Notes |
|
433
|
+
| ---- | ---- | ----------- | ----- |
|
434
|
+
| **user_id** | **String** | The ID of the user whose TOTPs are to be deleted | |
|
435
|
+
|
436
|
+
### Return type
|
437
|
+
|
438
|
+
[**DisableMFA200Response**](DisableMFA200Response.md)
|
439
|
+
|
440
|
+
### Authorization
|
441
|
+
|
442
|
+
[bearerAuth](../README.md#bearerAuth)
|
443
|
+
|
444
|
+
### HTTP request headers
|
445
|
+
|
446
|
+
- **Content-Type**: Not defined
|
447
|
+
- **Accept**: application/json
|
448
|
+
|
449
|
+
|
450
|
+
## delete_user
|
451
|
+
|
452
|
+
> <DeletedObject> delete_user(user_id)
|
453
|
+
|
454
|
+
Delete a user
|
455
|
+
|
456
|
+
Delete the specified user
|
457
|
+
|
458
|
+
### Examples
|
459
|
+
|
460
|
+
```ruby
|
461
|
+
require 'time'
|
462
|
+
require 'clerk-http-client'
|
463
|
+
# setup authorization
|
464
|
+
ClerkHttpClient.configure do |config|
|
465
|
+
# Configure Bearer authorization (sk_<environment>_<secret value>): bearerAuth
|
466
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
467
|
+
end
|
468
|
+
|
469
|
+
api_instance = ClerkHttpClient::UsersApi.new
|
470
|
+
user_id = 'user_id_example' # String | The ID of the user to delete
|
471
|
+
|
472
|
+
begin
|
473
|
+
# Delete a user
|
474
|
+
result = api_instance.delete_user(user_id)
|
475
|
+
p result
|
476
|
+
rescue ClerkHttpClient::ApiError => e
|
477
|
+
puts "Error when calling UsersApi->delete_user: #{e}"
|
478
|
+
end
|
479
|
+
```
|
480
|
+
|
481
|
+
#### Using the delete_user_with_http_info variant
|
482
|
+
|
483
|
+
This returns an Array which contains the response data, status code and headers.
|
484
|
+
|
485
|
+
> <Array(<DeletedObject>, Integer, Hash)> delete_user_with_http_info(user_id)
|
486
|
+
|
487
|
+
```ruby
|
488
|
+
begin
|
489
|
+
# Delete a user
|
490
|
+
data, status_code, headers = api_instance.delete_user_with_http_info(user_id)
|
491
|
+
p status_code # => 2xx
|
492
|
+
p headers # => { ... }
|
493
|
+
p data # => <DeletedObject>
|
494
|
+
rescue ClerkHttpClient::ApiError => e
|
495
|
+
puts "Error when calling UsersApi->delete_user_with_http_info: #{e}"
|
496
|
+
end
|
497
|
+
```
|
498
|
+
|
499
|
+
### Parameters
|
500
|
+
|
501
|
+
| Name | Type | Description | Notes |
|
502
|
+
| ---- | ---- | ----------- | ----- |
|
503
|
+
| **user_id** | **String** | The ID of the user to delete | |
|
504
|
+
|
505
|
+
### Return type
|
506
|
+
|
507
|
+
[**DeletedObject**](DeletedObject.md)
|
508
|
+
|
509
|
+
### Authorization
|
510
|
+
|
511
|
+
[bearerAuth](../README.md#bearerAuth)
|
512
|
+
|
513
|
+
### HTTP request headers
|
514
|
+
|
515
|
+
- **Content-Type**: Not defined
|
516
|
+
- **Accept**: application/json
|
517
|
+
|
518
|
+
|
519
|
+
## delete_user_profile_image
|
520
|
+
|
521
|
+
> <User> delete_user_profile_image(user_id)
|
522
|
+
|
523
|
+
Delete user profile image
|
524
|
+
|
525
|
+
Delete a user's profile image
|
526
|
+
|
527
|
+
### Examples
|
528
|
+
|
529
|
+
```ruby
|
530
|
+
require 'time'
|
531
|
+
require 'clerk-http-client'
|
532
|
+
# setup authorization
|
533
|
+
ClerkHttpClient.configure do |config|
|
534
|
+
# Configure Bearer authorization (sk_<environment>_<secret value>): bearerAuth
|
535
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
536
|
+
end
|
537
|
+
|
538
|
+
api_instance = ClerkHttpClient::UsersApi.new
|
539
|
+
user_id = 'user_id_example' # String | The ID of the user to delete the profile image for
|
540
|
+
|
541
|
+
begin
|
542
|
+
# Delete user profile image
|
543
|
+
result = api_instance.delete_user_profile_image(user_id)
|
544
|
+
p result
|
545
|
+
rescue ClerkHttpClient::ApiError => e
|
546
|
+
puts "Error when calling UsersApi->delete_user_profile_image: #{e}"
|
547
|
+
end
|
548
|
+
```
|
549
|
+
|
550
|
+
#### Using the delete_user_profile_image_with_http_info variant
|
551
|
+
|
552
|
+
This returns an Array which contains the response data, status code and headers.
|
553
|
+
|
554
|
+
> <Array(<User>, Integer, Hash)> delete_user_profile_image_with_http_info(user_id)
|
555
|
+
|
556
|
+
```ruby
|
557
|
+
begin
|
558
|
+
# Delete user profile image
|
559
|
+
data, status_code, headers = api_instance.delete_user_profile_image_with_http_info(user_id)
|
560
|
+
p status_code # => 2xx
|
561
|
+
p headers # => { ... }
|
562
|
+
p data # => <User>
|
563
|
+
rescue ClerkHttpClient::ApiError => e
|
564
|
+
puts "Error when calling UsersApi->delete_user_profile_image_with_http_info: #{e}"
|
565
|
+
end
|
566
|
+
```
|
567
|
+
|
568
|
+
### Parameters
|
569
|
+
|
570
|
+
| Name | Type | Description | Notes |
|
571
|
+
| ---- | ---- | ----------- | ----- |
|
572
|
+
| **user_id** | **String** | The ID of the user to delete the profile image for | |
|
573
|
+
|
574
|
+
### Return type
|
575
|
+
|
576
|
+
[**User**](User.md)
|
577
|
+
|
578
|
+
### Authorization
|
579
|
+
|
580
|
+
[bearerAuth](../README.md#bearerAuth)
|
581
|
+
|
582
|
+
### HTTP request headers
|
583
|
+
|
584
|
+
- **Content-Type**: Not defined
|
585
|
+
- **Accept**: application/json
|
586
|
+
|
587
|
+
|
588
|
+
## disable_mfa
|
589
|
+
|
590
|
+
> <DisableMFA200Response> disable_mfa(user_id)
|
591
|
+
|
592
|
+
Disable a user's MFA methods
|
593
|
+
|
594
|
+
Disable all of a user's MFA methods (e.g. OTP sent via SMS, TOTP on their authenticator app) at once.
|
595
|
+
|
596
|
+
### Examples
|
597
|
+
|
598
|
+
```ruby
|
599
|
+
require 'time'
|
600
|
+
require 'clerk-http-client'
|
601
|
+
# setup authorization
|
602
|
+
ClerkHttpClient.configure do |config|
|
603
|
+
# Configure Bearer authorization (sk_<environment>_<secret value>): bearerAuth
|
604
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
605
|
+
end
|
606
|
+
|
607
|
+
api_instance = ClerkHttpClient::UsersApi.new
|
608
|
+
user_id = 'user_id_example' # String | The ID of the user whose MFA methods are to be disabled
|
609
|
+
|
610
|
+
begin
|
611
|
+
# Disable a user's MFA methods
|
612
|
+
result = api_instance.disable_mfa(user_id)
|
613
|
+
p result
|
614
|
+
rescue ClerkHttpClient::ApiError => e
|
615
|
+
puts "Error when calling UsersApi->disable_mfa: #{e}"
|
616
|
+
end
|
617
|
+
```
|
618
|
+
|
619
|
+
#### Using the disable_mfa_with_http_info variant
|
620
|
+
|
621
|
+
This returns an Array which contains the response data, status code and headers.
|
622
|
+
|
623
|
+
> <Array(<DisableMFA200Response>, Integer, Hash)> disable_mfa_with_http_info(user_id)
|
624
|
+
|
625
|
+
```ruby
|
626
|
+
begin
|
627
|
+
# Disable a user's MFA methods
|
628
|
+
data, status_code, headers = api_instance.disable_mfa_with_http_info(user_id)
|
629
|
+
p status_code # => 2xx
|
630
|
+
p headers # => { ... }
|
631
|
+
p data # => <DisableMFA200Response>
|
632
|
+
rescue ClerkHttpClient::ApiError => e
|
633
|
+
puts "Error when calling UsersApi->disable_mfa_with_http_info: #{e}"
|
634
|
+
end
|
635
|
+
```
|
636
|
+
|
637
|
+
### Parameters
|
638
|
+
|
639
|
+
| Name | Type | Description | Notes |
|
640
|
+
| ---- | ---- | ----------- | ----- |
|
641
|
+
| **user_id** | **String** | The ID of the user whose MFA methods are to be disabled | |
|
642
|
+
|
643
|
+
### Return type
|
644
|
+
|
645
|
+
[**DisableMFA200Response**](DisableMFA200Response.md)
|
646
|
+
|
647
|
+
### Authorization
|
648
|
+
|
649
|
+
[bearerAuth](../README.md#bearerAuth)
|
650
|
+
|
651
|
+
### HTTP request headers
|
652
|
+
|
653
|
+
- **Content-Type**: Not defined
|
654
|
+
- **Accept**: application/json
|
655
|
+
|
656
|
+
|
657
|
+
## get_o_auth_access_token
|
658
|
+
|
659
|
+
> <Array<GetOAuthAccessToken200ResponseInner>> get_o_auth_access_token(user_id, provider)
|
660
|
+
|
661
|
+
Retrieve the OAuth access token of a user
|
662
|
+
|
663
|
+
Fetch the corresponding OAuth access token for a user that has previously authenticated with a particular OAuth provider. For OAuth 2.0, if the access token has expired and we have a corresponding refresh token, the access token will be refreshed transparently the new one will be returned.
|
664
|
+
|
665
|
+
### Examples
|
666
|
+
|
667
|
+
```ruby
|
668
|
+
require 'time'
|
669
|
+
require 'clerk-http-client'
|
670
|
+
# setup authorization
|
671
|
+
ClerkHttpClient.configure do |config|
|
672
|
+
# Configure Bearer authorization (sk_<environment>_<secret value>): bearerAuth
|
673
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
674
|
+
end
|
675
|
+
|
676
|
+
api_instance = ClerkHttpClient::UsersApi.new
|
677
|
+
user_id = 'user_id_example' # String | The ID of the user for which to retrieve the OAuth access token
|
678
|
+
provider = 'provider_example' # String | The ID of the OAuth provider (e.g. `oauth_google`)
|
679
|
+
|
680
|
+
begin
|
681
|
+
# Retrieve the OAuth access token of a user
|
682
|
+
result = api_instance.get_o_auth_access_token(user_id, provider)
|
683
|
+
p result
|
684
|
+
rescue ClerkHttpClient::ApiError => e
|
685
|
+
puts "Error when calling UsersApi->get_o_auth_access_token: #{e}"
|
686
|
+
end
|
687
|
+
```
|
688
|
+
|
689
|
+
#### Using the get_o_auth_access_token_with_http_info variant
|
690
|
+
|
691
|
+
This returns an Array which contains the response data, status code and headers.
|
692
|
+
|
693
|
+
> <Array(<Array<GetOAuthAccessToken200ResponseInner>>, Integer, Hash)> get_o_auth_access_token_with_http_info(user_id, provider)
|
694
|
+
|
695
|
+
```ruby
|
696
|
+
begin
|
697
|
+
# Retrieve the OAuth access token of a user
|
698
|
+
data, status_code, headers = api_instance.get_o_auth_access_token_with_http_info(user_id, provider)
|
699
|
+
p status_code # => 2xx
|
700
|
+
p headers # => { ... }
|
701
|
+
p data # => <Array<GetOAuthAccessToken200ResponseInner>>
|
702
|
+
rescue ClerkHttpClient::ApiError => e
|
703
|
+
puts "Error when calling UsersApi->get_o_auth_access_token_with_http_info: #{e}"
|
704
|
+
end
|
705
|
+
```
|
706
|
+
|
707
|
+
### Parameters
|
708
|
+
|
709
|
+
| Name | Type | Description | Notes |
|
710
|
+
| ---- | ---- | ----------- | ----- |
|
711
|
+
| **user_id** | **String** | The ID of the user for which to retrieve the OAuth access token | |
|
712
|
+
| **provider** | **String** | The ID of the OAuth provider (e.g. `oauth_google`) | |
|
713
|
+
|
714
|
+
### Return type
|
715
|
+
|
716
|
+
[**Array<GetOAuthAccessToken200ResponseInner>**](GetOAuthAccessToken200ResponseInner.md)
|
717
|
+
|
718
|
+
### Authorization
|
719
|
+
|
720
|
+
[bearerAuth](../README.md#bearerAuth)
|
721
|
+
|
722
|
+
### HTTP request headers
|
723
|
+
|
724
|
+
- **Content-Type**: Not defined
|
725
|
+
- **Accept**: application/json
|
726
|
+
|
727
|
+
|
728
|
+
## get_user
|
729
|
+
|
730
|
+
> <User> get_user(user_id)
|
731
|
+
|
732
|
+
Retrieve a user
|
733
|
+
|
734
|
+
Retrieve the details of a user
|
735
|
+
|
736
|
+
### Examples
|
737
|
+
|
738
|
+
```ruby
|
739
|
+
require 'time'
|
740
|
+
require 'clerk-http-client'
|
741
|
+
# setup authorization
|
742
|
+
ClerkHttpClient.configure do |config|
|
743
|
+
# Configure Bearer authorization (sk_<environment>_<secret value>): bearerAuth
|
744
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
745
|
+
end
|
746
|
+
|
747
|
+
api_instance = ClerkHttpClient::UsersApi.new
|
748
|
+
user_id = 'user_id_example' # String | The ID of the user to retrieve
|
749
|
+
|
750
|
+
begin
|
751
|
+
# Retrieve a user
|
752
|
+
result = api_instance.get_user(user_id)
|
753
|
+
p result
|
754
|
+
rescue ClerkHttpClient::ApiError => e
|
755
|
+
puts "Error when calling UsersApi->get_user: #{e}"
|
756
|
+
end
|
757
|
+
```
|
758
|
+
|
759
|
+
#### Using the get_user_with_http_info variant
|
760
|
+
|
761
|
+
This returns an Array which contains the response data, status code and headers.
|
762
|
+
|
763
|
+
> <Array(<User>, Integer, Hash)> get_user_with_http_info(user_id)
|
764
|
+
|
765
|
+
```ruby
|
766
|
+
begin
|
767
|
+
# Retrieve a user
|
768
|
+
data, status_code, headers = api_instance.get_user_with_http_info(user_id)
|
769
|
+
p status_code # => 2xx
|
770
|
+
p headers # => { ... }
|
771
|
+
p data # => <User>
|
772
|
+
rescue ClerkHttpClient::ApiError => e
|
773
|
+
puts "Error when calling UsersApi->get_user_with_http_info: #{e}"
|
774
|
+
end
|
775
|
+
```
|
776
|
+
|
777
|
+
### Parameters
|
778
|
+
|
779
|
+
| Name | Type | Description | Notes |
|
780
|
+
| ---- | ---- | ----------- | ----- |
|
781
|
+
| **user_id** | **String** | The ID of the user to retrieve | |
|
782
|
+
|
783
|
+
### Return type
|
784
|
+
|
785
|
+
[**User**](User.md)
|
786
|
+
|
787
|
+
### Authorization
|
788
|
+
|
789
|
+
[bearerAuth](../README.md#bearerAuth)
|
790
|
+
|
791
|
+
### HTTP request headers
|
792
|
+
|
793
|
+
- **Content-Type**: Not defined
|
794
|
+
- **Accept**: application/json
|
795
|
+
|
796
|
+
|
797
|
+
## get_user_list
|
798
|
+
|
799
|
+
> <Array<User>> get_user_list(opts)
|
800
|
+
|
801
|
+
List all users
|
802
|
+
|
803
|
+
Returns a list of all users. The users are returned sorted by creation date, with the newest users appearing first.
|
804
|
+
|
805
|
+
### Examples
|
806
|
+
|
807
|
+
```ruby
|
808
|
+
require 'time'
|
809
|
+
require 'clerk-http-client'
|
810
|
+
# setup authorization
|
811
|
+
ClerkHttpClient.configure do |config|
|
812
|
+
# Configure Bearer authorization (sk_<environment>_<secret value>): bearerAuth
|
813
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
814
|
+
end
|
815
|
+
|
816
|
+
api_instance = ClerkHttpClient::UsersApi.new
|
817
|
+
opts = {
|
818
|
+
email_address: ['inner_example'], # Array<String> | Returns users with the specified email addresses. Accepts up to 100 email addresses. Any email addresses not found are ignored.
|
819
|
+
phone_number: ['inner_example'], # Array<String> | Returns users with the specified phone numbers. Accepts up to 100 phone numbers. Any phone numbers not found are ignored.
|
820
|
+
external_id: ['inner_example'], # Array<String> | Returns users with the specified external ids. For each external id, the `+` and `-` can be prepended to the id, which denote whether the respective external id should be included or excluded from the result set. Accepts up to 100 external ids. Any external ids not found are ignored.
|
821
|
+
username: ['inner_example'], # Array<String> | Returns users with the specified usernames. Accepts up to 100 usernames. Any usernames not found are ignored.
|
822
|
+
web3_wallet: ['inner_example'], # Array<String> | Returns users with the specified web3 wallet addresses. Accepts up to 100 web3 wallet addresses. Any web3 wallet addressed not found are ignored.
|
823
|
+
user_id: ['inner_example'], # Array<String> | Returns users with the user ids specified. For each user id, the `+` and `-` can be prepended to the id, which denote whether the respective user id should be included or excluded from the result set. Accepts up to 100 user ids. Any user ids not found are ignored.
|
824
|
+
organization_id: ['inner_example'], # Array<String> | Returns users that have memberships to the given organizations. For each organization id, the `+` and `-` can be prepended to the id, which denote whether the respective organization should be included or excluded from the result set. Accepts up to 100 organization ids.
|
825
|
+
query: 'query_example', # String | Returns users that match the given query. For possible matches, we check the email addresses, phone numbers, usernames, web3 wallets, user ids, first and last names. The query value doesn't need to match the exact value you are looking for, it is capable of partial matches as well.
|
826
|
+
last_active_at_since: 1700690400000, # Integer | Returns users that had session activity since the given date, with day precision. Providing a value with higher precision than day will result in an error. Example: use 1700690400000 to retrieve users that had session activity from 2023-11-23 until the current day.
|
827
|
+
limit: 8.14, # Float | Applies a limit to the number of results returned. Can be used for paginating the results together with `offset`.
|
828
|
+
offset: 8.14, # Float | Skip the first `offset` results when paginating. Needs to be an integer greater or equal to zero. To be used in conjunction with `limit`.
|
829
|
+
order_by: 'order_by_example' # String | Allows to return users in a particular order. At the moment, you can order the returned users by their `created_at`,`updated_at`,`email_address`,`web3wallet`,`first_name`,`last_name`,`phone_number`,`username`,`last_active_at`,`last_sign_in_at`. In order to specify the direction, you can use the `+/-` symbols prepended in the property to order by. For example, if you want users to be returned in descending order according to their `created_at` property, you can use `-created_at`. If you don't use `+` or `-`, then `+` is implied. We only support one `order_by` parameter, and if multiple `order_by` parameters are provided, we will only keep the first one. For example, if you pass `order_by=username&order_by=created_at`, we will consider only the first `order_by` parameter, which is `username`. The `created_at` parameter will be ignored in this case.
|
830
|
+
}
|
831
|
+
|
832
|
+
begin
|
833
|
+
# List all users
|
834
|
+
result = api_instance.get_user_list(opts)
|
835
|
+
p result
|
836
|
+
rescue ClerkHttpClient::ApiError => e
|
837
|
+
puts "Error when calling UsersApi->get_user_list: #{e}"
|
838
|
+
end
|
839
|
+
```
|
840
|
+
|
841
|
+
#### Using the get_user_list_with_http_info variant
|
842
|
+
|
843
|
+
This returns an Array which contains the response data, status code and headers.
|
844
|
+
|
845
|
+
> <Array(<Array<User>>, Integer, Hash)> get_user_list_with_http_info(opts)
|
846
|
+
|
847
|
+
```ruby
|
848
|
+
begin
|
849
|
+
# List all users
|
850
|
+
data, status_code, headers = api_instance.get_user_list_with_http_info(opts)
|
851
|
+
p status_code # => 2xx
|
852
|
+
p headers # => { ... }
|
853
|
+
p data # => <Array<User>>
|
854
|
+
rescue ClerkHttpClient::ApiError => e
|
855
|
+
puts "Error when calling UsersApi->get_user_list_with_http_info: #{e}"
|
856
|
+
end
|
857
|
+
```
|
858
|
+
|
859
|
+
### Parameters
|
860
|
+
|
861
|
+
| Name | Type | Description | Notes |
|
862
|
+
| ---- | ---- | ----------- | ----- |
|
863
|
+
| **email_address** | [**Array<String>**](String.md) | Returns users with the specified email addresses. Accepts up to 100 email addresses. Any email addresses not found are ignored. | [optional] |
|
864
|
+
| **phone_number** | [**Array<String>**](String.md) | Returns users with the specified phone numbers. Accepts up to 100 phone numbers. Any phone numbers not found are ignored. | [optional] |
|
865
|
+
| **external_id** | [**Array<String>**](String.md) | Returns users with the specified external ids. For each external id, the `+` and `-` can be prepended to the id, which denote whether the respective external id should be included or excluded from the result set. Accepts up to 100 external ids. Any external ids not found are ignored. | [optional] |
|
866
|
+
| **username** | [**Array<String>**](String.md) | Returns users with the specified usernames. Accepts up to 100 usernames. Any usernames not found are ignored. | [optional] |
|
867
|
+
| **web3_wallet** | [**Array<String>**](String.md) | Returns users with the specified web3 wallet addresses. Accepts up to 100 web3 wallet addresses. Any web3 wallet addressed not found are ignored. | [optional] |
|
868
|
+
| **user_id** | [**Array<String>**](String.md) | Returns users with the user ids specified. For each user id, the `+` and `-` can be prepended to the id, which denote whether the respective user id should be included or excluded from the result set. Accepts up to 100 user ids. Any user ids not found are ignored. | [optional] |
|
869
|
+
| **organization_id** | [**Array<String>**](String.md) | Returns users that have memberships to the given organizations. For each organization id, the `+` and `-` can be prepended to the id, which denote whether the respective organization should be included or excluded from the result set. Accepts up to 100 organization ids. | [optional] |
|
870
|
+
| **query** | **String** | Returns users that match the given query. For possible matches, we check the email addresses, phone numbers, usernames, web3 wallets, user ids, first and last names. The query value doesn't need to match the exact value you are looking for, it is capable of partial matches as well. | [optional] |
|
871
|
+
| **last_active_at_since** | **Integer** | Returns users that had session activity since the given date, with day precision. Providing a value with higher precision than day will result in an error. Example: use 1700690400000 to retrieve users that had session activity from 2023-11-23 until the current day. | [optional] |
|
872
|
+
| **limit** | **Float** | Applies a limit to the number of results returned. Can be used for paginating the results together with `offset`. | [optional][default to 10] |
|
873
|
+
| **offset** | **Float** | Skip the first `offset` results when paginating. Needs to be an integer greater or equal to zero. To be used in conjunction with `limit`. | [optional][default to 0] |
|
874
|
+
| **order_by** | **String** | Allows to return users in a particular order. At the moment, you can order the returned users by their `created_at`,`updated_at`,`email_address`,`web3wallet`,`first_name`,`last_name`,`phone_number`,`username`,`last_active_at`,`last_sign_in_at`. In order to specify the direction, you can use the `+/-` symbols prepended in the property to order by. For example, if you want users to be returned in descending order according to their `created_at` property, you can use `-created_at`. If you don't use `+` or `-`, then `+` is implied. We only support one `order_by` parameter, and if multiple `order_by` parameters are provided, we will only keep the first one. For example, if you pass `order_by=username&order_by=created_at`, we will consider only the first `order_by` parameter, which is `username`. The `created_at` parameter will be ignored in this case. | [optional][default to '-created_at'] |
|
875
|
+
|
876
|
+
### Return type
|
877
|
+
|
878
|
+
[**Array<User>**](User.md)
|
879
|
+
|
880
|
+
### Authorization
|
881
|
+
|
882
|
+
[bearerAuth](../README.md#bearerAuth)
|
883
|
+
|
884
|
+
### HTTP request headers
|
885
|
+
|
886
|
+
- **Content-Type**: Not defined
|
887
|
+
- **Accept**: application/json
|
888
|
+
|
889
|
+
|
890
|
+
## get_users_count
|
891
|
+
|
892
|
+
> <TotalCount> get_users_count(opts)
|
893
|
+
|
894
|
+
Count users
|
895
|
+
|
896
|
+
Returns a total count of all users that match the given filtering criteria.
|
897
|
+
|
898
|
+
### Examples
|
899
|
+
|
900
|
+
```ruby
|
901
|
+
require 'time'
|
902
|
+
require 'clerk-http-client'
|
903
|
+
# setup authorization
|
904
|
+
ClerkHttpClient.configure do |config|
|
905
|
+
# Configure Bearer authorization (sk_<environment>_<secret value>): bearerAuth
|
906
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
907
|
+
end
|
908
|
+
|
909
|
+
api_instance = ClerkHttpClient::UsersApi.new
|
910
|
+
opts = {
|
911
|
+
email_address: ['inner_example'], # Array<String> | Counts users with the specified email addresses. Accepts up to 100 email addresses. Any email addresses not found are ignored.
|
912
|
+
phone_number: ['inner_example'], # Array<String> | Counts users with the specified phone numbers. Accepts up to 100 phone numbers. Any phone numbers not found are ignored.
|
913
|
+
external_id: ['inner_example'], # Array<String> | Counts users with the specified external ids. Accepts up to 100 external ids. Any external ids not found are ignored.
|
914
|
+
username: ['inner_example'], # Array<String> | Counts users with the specified usernames. Accepts up to 100 usernames. Any usernames not found are ignored.
|
915
|
+
web3_wallet: ['inner_example'], # Array<String> | Counts users with the specified web3 wallet addresses. Accepts up to 100 web3 wallet addresses. Any web3 wallet addressed not found are ignored.
|
916
|
+
user_id: ['inner_example'], # Array<String> | Counts users with the user ids specified. Accepts up to 100 user ids. Any user ids not found are ignored.
|
917
|
+
query: 'query_example' # String | Counts users that match the given query. For possible matches, we check the email addresses, phone numbers, usernames, web3 wallets, user ids, first and last names. The query value doesn't need to match the exact value you are looking for, it is capable of partial matches as well.
|
918
|
+
}
|
919
|
+
|
920
|
+
begin
|
921
|
+
# Count users
|
922
|
+
result = api_instance.get_users_count(opts)
|
923
|
+
p result
|
924
|
+
rescue ClerkHttpClient::ApiError => e
|
925
|
+
puts "Error when calling UsersApi->get_users_count: #{e}"
|
926
|
+
end
|
927
|
+
```
|
928
|
+
|
929
|
+
#### Using the get_users_count_with_http_info variant
|
930
|
+
|
931
|
+
This returns an Array which contains the response data, status code and headers.
|
932
|
+
|
933
|
+
> <Array(<TotalCount>, Integer, Hash)> get_users_count_with_http_info(opts)
|
934
|
+
|
935
|
+
```ruby
|
936
|
+
begin
|
937
|
+
# Count users
|
938
|
+
data, status_code, headers = api_instance.get_users_count_with_http_info(opts)
|
939
|
+
p status_code # => 2xx
|
940
|
+
p headers # => { ... }
|
941
|
+
p data # => <TotalCount>
|
942
|
+
rescue ClerkHttpClient::ApiError => e
|
943
|
+
puts "Error when calling UsersApi->get_users_count_with_http_info: #{e}"
|
944
|
+
end
|
945
|
+
```
|
946
|
+
|
947
|
+
### Parameters
|
948
|
+
|
949
|
+
| Name | Type | Description | Notes |
|
950
|
+
| ---- | ---- | ----------- | ----- |
|
951
|
+
| **email_address** | [**Array<String>**](String.md) | Counts users with the specified email addresses. Accepts up to 100 email addresses. Any email addresses not found are ignored. | [optional] |
|
952
|
+
| **phone_number** | [**Array<String>**](String.md) | Counts users with the specified phone numbers. Accepts up to 100 phone numbers. Any phone numbers not found are ignored. | [optional] |
|
953
|
+
| **external_id** | [**Array<String>**](String.md) | Counts users with the specified external ids. Accepts up to 100 external ids. Any external ids not found are ignored. | [optional] |
|
954
|
+
| **username** | [**Array<String>**](String.md) | Counts users with the specified usernames. Accepts up to 100 usernames. Any usernames not found are ignored. | [optional] |
|
955
|
+
| **web3_wallet** | [**Array<String>**](String.md) | Counts users with the specified web3 wallet addresses. Accepts up to 100 web3 wallet addresses. Any web3 wallet addressed not found are ignored. | [optional] |
|
956
|
+
| **user_id** | [**Array<String>**](String.md) | Counts users with the user ids specified. Accepts up to 100 user ids. Any user ids not found are ignored. | [optional] |
|
957
|
+
| **query** | **String** | Counts users that match the given query. For possible matches, we check the email addresses, phone numbers, usernames, web3 wallets, user ids, first and last names. The query value doesn't need to match the exact value you are looking for, it is capable of partial matches as well. | [optional] |
|
958
|
+
|
959
|
+
### Return type
|
960
|
+
|
961
|
+
[**TotalCount**](TotalCount.md)
|
962
|
+
|
963
|
+
### Authorization
|
964
|
+
|
965
|
+
[bearerAuth](../README.md#bearerAuth)
|
966
|
+
|
967
|
+
### HTTP request headers
|
968
|
+
|
969
|
+
- **Content-Type**: Not defined
|
970
|
+
- **Accept**: application/json
|
971
|
+
|
972
|
+
|
973
|
+
## lock_user
|
974
|
+
|
975
|
+
> <User> lock_user(user_id)
|
976
|
+
|
977
|
+
Lock a user
|
978
|
+
|
979
|
+
Marks the given user as locked, which means they are not allowed to sign in again until the lock expires. Lock duration can be configured in the instance's restrictions settings.
|
980
|
+
|
981
|
+
### Examples
|
982
|
+
|
983
|
+
```ruby
|
984
|
+
require 'time'
|
985
|
+
require 'clerk-http-client'
|
986
|
+
# setup authorization
|
987
|
+
ClerkHttpClient.configure do |config|
|
988
|
+
# Configure Bearer authorization (sk_<environment>_<secret value>): bearerAuth
|
989
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
990
|
+
end
|
991
|
+
|
992
|
+
api_instance = ClerkHttpClient::UsersApi.new
|
993
|
+
user_id = 'user_id_example' # String | The ID of the user to lock
|
994
|
+
|
995
|
+
begin
|
996
|
+
# Lock a user
|
997
|
+
result = api_instance.lock_user(user_id)
|
998
|
+
p result
|
999
|
+
rescue ClerkHttpClient::ApiError => e
|
1000
|
+
puts "Error when calling UsersApi->lock_user: #{e}"
|
1001
|
+
end
|
1002
|
+
```
|
1003
|
+
|
1004
|
+
#### Using the lock_user_with_http_info variant
|
1005
|
+
|
1006
|
+
This returns an Array which contains the response data, status code and headers.
|
1007
|
+
|
1008
|
+
> <Array(<User>, Integer, Hash)> lock_user_with_http_info(user_id)
|
1009
|
+
|
1010
|
+
```ruby
|
1011
|
+
begin
|
1012
|
+
# Lock a user
|
1013
|
+
data, status_code, headers = api_instance.lock_user_with_http_info(user_id)
|
1014
|
+
p status_code # => 2xx
|
1015
|
+
p headers # => { ... }
|
1016
|
+
p data # => <User>
|
1017
|
+
rescue ClerkHttpClient::ApiError => e
|
1018
|
+
puts "Error when calling UsersApi->lock_user_with_http_info: #{e}"
|
1019
|
+
end
|
1020
|
+
```
|
1021
|
+
|
1022
|
+
### Parameters
|
1023
|
+
|
1024
|
+
| Name | Type | Description | Notes |
|
1025
|
+
| ---- | ---- | ----------- | ----- |
|
1026
|
+
| **user_id** | **String** | The ID of the user to lock | |
|
1027
|
+
|
1028
|
+
### Return type
|
1029
|
+
|
1030
|
+
[**User**](User.md)
|
1031
|
+
|
1032
|
+
### Authorization
|
1033
|
+
|
1034
|
+
[bearerAuth](../README.md#bearerAuth)
|
1035
|
+
|
1036
|
+
### HTTP request headers
|
1037
|
+
|
1038
|
+
- **Content-Type**: Not defined
|
1039
|
+
- **Accept**: application/json
|
1040
|
+
|
1041
|
+
|
1042
|
+
## set_user_profile_image
|
1043
|
+
|
1044
|
+
> <User> set_user_profile_image(user_id, opts)
|
1045
|
+
|
1046
|
+
Set user profile image
|
1047
|
+
|
1048
|
+
Update a user's profile image
|
1049
|
+
|
1050
|
+
### Examples
|
1051
|
+
|
1052
|
+
```ruby
|
1053
|
+
require 'time'
|
1054
|
+
require 'clerk-http-client'
|
1055
|
+
# setup authorization
|
1056
|
+
ClerkHttpClient.configure do |config|
|
1057
|
+
# Configure Bearer authorization (sk_<environment>_<secret value>): bearerAuth
|
1058
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
1059
|
+
end
|
1060
|
+
|
1061
|
+
api_instance = ClerkHttpClient::UsersApi.new
|
1062
|
+
user_id = 'user_id_example' # String | The ID of the user to update the profile image for
|
1063
|
+
opts = {
|
1064
|
+
file: File.new('/path/to/some/file') # File |
|
1065
|
+
}
|
1066
|
+
|
1067
|
+
begin
|
1068
|
+
# Set user profile image
|
1069
|
+
result = api_instance.set_user_profile_image(user_id, opts)
|
1070
|
+
p result
|
1071
|
+
rescue ClerkHttpClient::ApiError => e
|
1072
|
+
puts "Error when calling UsersApi->set_user_profile_image: #{e}"
|
1073
|
+
end
|
1074
|
+
```
|
1075
|
+
|
1076
|
+
#### Using the set_user_profile_image_with_http_info variant
|
1077
|
+
|
1078
|
+
This returns an Array which contains the response data, status code and headers.
|
1079
|
+
|
1080
|
+
> <Array(<User>, Integer, Hash)> set_user_profile_image_with_http_info(user_id, opts)
|
1081
|
+
|
1082
|
+
```ruby
|
1083
|
+
begin
|
1084
|
+
# Set user profile image
|
1085
|
+
data, status_code, headers = api_instance.set_user_profile_image_with_http_info(user_id, opts)
|
1086
|
+
p status_code # => 2xx
|
1087
|
+
p headers # => { ... }
|
1088
|
+
p data # => <User>
|
1089
|
+
rescue ClerkHttpClient::ApiError => e
|
1090
|
+
puts "Error when calling UsersApi->set_user_profile_image_with_http_info: #{e}"
|
1091
|
+
end
|
1092
|
+
```
|
1093
|
+
|
1094
|
+
### Parameters
|
1095
|
+
|
1096
|
+
| Name | Type | Description | Notes |
|
1097
|
+
| ---- | ---- | ----------- | ----- |
|
1098
|
+
| **user_id** | **String** | The ID of the user to update the profile image for | |
|
1099
|
+
| **file** | **File** | | [optional] |
|
1100
|
+
|
1101
|
+
### Return type
|
1102
|
+
|
1103
|
+
[**User**](User.md)
|
1104
|
+
|
1105
|
+
### Authorization
|
1106
|
+
|
1107
|
+
[bearerAuth](../README.md#bearerAuth)
|
1108
|
+
|
1109
|
+
### HTTP request headers
|
1110
|
+
|
1111
|
+
- **Content-Type**: multipart/form-data
|
1112
|
+
- **Accept**: application/json
|
1113
|
+
|
1114
|
+
|
1115
|
+
## unban_user
|
1116
|
+
|
1117
|
+
> <User> unban_user(user_id)
|
1118
|
+
|
1119
|
+
Unban a user
|
1120
|
+
|
1121
|
+
Removes the ban mark from the given user.
|
1122
|
+
|
1123
|
+
### Examples
|
1124
|
+
|
1125
|
+
```ruby
|
1126
|
+
require 'time'
|
1127
|
+
require 'clerk-http-client'
|
1128
|
+
# setup authorization
|
1129
|
+
ClerkHttpClient.configure do |config|
|
1130
|
+
# Configure Bearer authorization (sk_<environment>_<secret value>): bearerAuth
|
1131
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
1132
|
+
end
|
1133
|
+
|
1134
|
+
api_instance = ClerkHttpClient::UsersApi.new
|
1135
|
+
user_id = 'user_id_example' # String | The ID of the user to unban
|
1136
|
+
|
1137
|
+
begin
|
1138
|
+
# Unban a user
|
1139
|
+
result = api_instance.unban_user(user_id)
|
1140
|
+
p result
|
1141
|
+
rescue ClerkHttpClient::ApiError => e
|
1142
|
+
puts "Error when calling UsersApi->unban_user: #{e}"
|
1143
|
+
end
|
1144
|
+
```
|
1145
|
+
|
1146
|
+
#### Using the unban_user_with_http_info variant
|
1147
|
+
|
1148
|
+
This returns an Array which contains the response data, status code and headers.
|
1149
|
+
|
1150
|
+
> <Array(<User>, Integer, Hash)> unban_user_with_http_info(user_id)
|
1151
|
+
|
1152
|
+
```ruby
|
1153
|
+
begin
|
1154
|
+
# Unban a user
|
1155
|
+
data, status_code, headers = api_instance.unban_user_with_http_info(user_id)
|
1156
|
+
p status_code # => 2xx
|
1157
|
+
p headers # => { ... }
|
1158
|
+
p data # => <User>
|
1159
|
+
rescue ClerkHttpClient::ApiError => e
|
1160
|
+
puts "Error when calling UsersApi->unban_user_with_http_info: #{e}"
|
1161
|
+
end
|
1162
|
+
```
|
1163
|
+
|
1164
|
+
### Parameters
|
1165
|
+
|
1166
|
+
| Name | Type | Description | Notes |
|
1167
|
+
| ---- | ---- | ----------- | ----- |
|
1168
|
+
| **user_id** | **String** | The ID of the user to unban | |
|
1169
|
+
|
1170
|
+
### Return type
|
1171
|
+
|
1172
|
+
[**User**](User.md)
|
1173
|
+
|
1174
|
+
### Authorization
|
1175
|
+
|
1176
|
+
[bearerAuth](../README.md#bearerAuth)
|
1177
|
+
|
1178
|
+
### HTTP request headers
|
1179
|
+
|
1180
|
+
- **Content-Type**: Not defined
|
1181
|
+
- **Accept**: application/json
|
1182
|
+
|
1183
|
+
|
1184
|
+
## unlock_user
|
1185
|
+
|
1186
|
+
> <User> unlock_user(user_id)
|
1187
|
+
|
1188
|
+
Unlock a user
|
1189
|
+
|
1190
|
+
Removes the lock from the given user.
|
1191
|
+
|
1192
|
+
### Examples
|
1193
|
+
|
1194
|
+
```ruby
|
1195
|
+
require 'time'
|
1196
|
+
require 'clerk-http-client'
|
1197
|
+
# setup authorization
|
1198
|
+
ClerkHttpClient.configure do |config|
|
1199
|
+
# Configure Bearer authorization (sk_<environment>_<secret value>): bearerAuth
|
1200
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
1201
|
+
end
|
1202
|
+
|
1203
|
+
api_instance = ClerkHttpClient::UsersApi.new
|
1204
|
+
user_id = 'user_id_example' # String | The ID of the user to unlock
|
1205
|
+
|
1206
|
+
begin
|
1207
|
+
# Unlock a user
|
1208
|
+
result = api_instance.unlock_user(user_id)
|
1209
|
+
p result
|
1210
|
+
rescue ClerkHttpClient::ApiError => e
|
1211
|
+
puts "Error when calling UsersApi->unlock_user: #{e}"
|
1212
|
+
end
|
1213
|
+
```
|
1214
|
+
|
1215
|
+
#### Using the unlock_user_with_http_info variant
|
1216
|
+
|
1217
|
+
This returns an Array which contains the response data, status code and headers.
|
1218
|
+
|
1219
|
+
> <Array(<User>, Integer, Hash)> unlock_user_with_http_info(user_id)
|
1220
|
+
|
1221
|
+
```ruby
|
1222
|
+
begin
|
1223
|
+
# Unlock a user
|
1224
|
+
data, status_code, headers = api_instance.unlock_user_with_http_info(user_id)
|
1225
|
+
p status_code # => 2xx
|
1226
|
+
p headers # => { ... }
|
1227
|
+
p data # => <User>
|
1228
|
+
rescue ClerkHttpClient::ApiError => e
|
1229
|
+
puts "Error when calling UsersApi->unlock_user_with_http_info: #{e}"
|
1230
|
+
end
|
1231
|
+
```
|
1232
|
+
|
1233
|
+
### Parameters
|
1234
|
+
|
1235
|
+
| Name | Type | Description | Notes |
|
1236
|
+
| ---- | ---- | ----------- | ----- |
|
1237
|
+
| **user_id** | **String** | The ID of the user to unlock | |
|
1238
|
+
|
1239
|
+
### Return type
|
1240
|
+
|
1241
|
+
[**User**](User.md)
|
1242
|
+
|
1243
|
+
### Authorization
|
1244
|
+
|
1245
|
+
[bearerAuth](../README.md#bearerAuth)
|
1246
|
+
|
1247
|
+
### HTTP request headers
|
1248
|
+
|
1249
|
+
- **Content-Type**: Not defined
|
1250
|
+
- **Accept**: application/json
|
1251
|
+
|
1252
|
+
|
1253
|
+
## update_user
|
1254
|
+
|
1255
|
+
> <User> update_user(user_id, update_user_request)
|
1256
|
+
|
1257
|
+
Update a user
|
1258
|
+
|
1259
|
+
Update a user's attributes. You can set the user's primary contact identifiers (email address and phone numbers) by updating the `primary_email_address_id` and `primary_phone_number_id` attributes respectively. Both IDs should correspond to verified identifications that belong to the user. You can remove a user's username by setting the username attribute to null or the blank string \"\". This is a destructive action; the identification will be deleted forever. Usernames can be removed only if they are optional in your instance settings and there's at least one other identifier which can be used for authentication. This endpoint allows changing a user's password. When passing the `password` parameter directly you have two further options. You can ignore the password policy checks for your instance by setting the `skip_password_checks` parameter to `true`. You can also choose to sign the user out of all their active sessions on any device once the password is updated. Just set `sign_out_of_other_sessions` to `true`.
|
1260
|
+
|
1261
|
+
### Examples
|
1262
|
+
|
1263
|
+
```ruby
|
1264
|
+
require 'time'
|
1265
|
+
require 'clerk-http-client'
|
1266
|
+
# setup authorization
|
1267
|
+
ClerkHttpClient.configure do |config|
|
1268
|
+
# Configure Bearer authorization (sk_<environment>_<secret value>): bearerAuth
|
1269
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
1270
|
+
end
|
1271
|
+
|
1272
|
+
api_instance = ClerkHttpClient::UsersApi.new
|
1273
|
+
user_id = 'user_id_example' # String | The ID of the user to update
|
1274
|
+
update_user_request = ClerkHttpClient::UpdateUserRequest.new # UpdateUserRequest |
|
1275
|
+
|
1276
|
+
begin
|
1277
|
+
# Update a user
|
1278
|
+
result = api_instance.update_user(user_id, update_user_request)
|
1279
|
+
p result
|
1280
|
+
rescue ClerkHttpClient::ApiError => e
|
1281
|
+
puts "Error when calling UsersApi->update_user: #{e}"
|
1282
|
+
end
|
1283
|
+
```
|
1284
|
+
|
1285
|
+
#### Using the update_user_with_http_info variant
|
1286
|
+
|
1287
|
+
This returns an Array which contains the response data, status code and headers.
|
1288
|
+
|
1289
|
+
> <Array(<User>, Integer, Hash)> update_user_with_http_info(user_id, update_user_request)
|
1290
|
+
|
1291
|
+
```ruby
|
1292
|
+
begin
|
1293
|
+
# Update a user
|
1294
|
+
data, status_code, headers = api_instance.update_user_with_http_info(user_id, update_user_request)
|
1295
|
+
p status_code # => 2xx
|
1296
|
+
p headers # => { ... }
|
1297
|
+
p data # => <User>
|
1298
|
+
rescue ClerkHttpClient::ApiError => e
|
1299
|
+
puts "Error when calling UsersApi->update_user_with_http_info: #{e}"
|
1300
|
+
end
|
1301
|
+
```
|
1302
|
+
|
1303
|
+
### Parameters
|
1304
|
+
|
1305
|
+
| Name | Type | Description | Notes |
|
1306
|
+
| ---- | ---- | ----------- | ----- |
|
1307
|
+
| **user_id** | **String** | The ID of the user to update | |
|
1308
|
+
| **update_user_request** | [**UpdateUserRequest**](UpdateUserRequest.md) | | |
|
1309
|
+
|
1310
|
+
### Return type
|
1311
|
+
|
1312
|
+
[**User**](User.md)
|
1313
|
+
|
1314
|
+
### Authorization
|
1315
|
+
|
1316
|
+
[bearerAuth](../README.md#bearerAuth)
|
1317
|
+
|
1318
|
+
### HTTP request headers
|
1319
|
+
|
1320
|
+
- **Content-Type**: application/json
|
1321
|
+
- **Accept**: application/json
|
1322
|
+
|
1323
|
+
|
1324
|
+
## update_user_metadata
|
1325
|
+
|
1326
|
+
> <User> update_user_metadata(user_id, update_user_metadata_request)
|
1327
|
+
|
1328
|
+
Merge and update a user's metadata
|
1329
|
+
|
1330
|
+
Update a user's metadata attributes by merging existing values with the provided parameters. This endpoint behaves differently than the *Update a user* endpoint. Metadata values will not be replaced entirely. Instead, a deep merge will be performed. Deep means that any nested JSON objects will be merged as well. You can remove metadata keys at any level by setting their value to `null`.
|
1331
|
+
|
1332
|
+
### Examples
|
1333
|
+
|
1334
|
+
```ruby
|
1335
|
+
require 'time'
|
1336
|
+
require 'clerk-http-client'
|
1337
|
+
# setup authorization
|
1338
|
+
ClerkHttpClient.configure do |config|
|
1339
|
+
# Configure Bearer authorization (sk_<environment>_<secret value>): bearerAuth
|
1340
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
1341
|
+
end
|
1342
|
+
|
1343
|
+
api_instance = ClerkHttpClient::UsersApi.new
|
1344
|
+
user_id = 'user_id_example' # String | The ID of the user whose metadata will be updated and merged
|
1345
|
+
update_user_metadata_request = ClerkHttpClient::UpdateUserMetadataRequest.new # UpdateUserMetadataRequest |
|
1346
|
+
|
1347
|
+
begin
|
1348
|
+
# Merge and update a user's metadata
|
1349
|
+
result = api_instance.update_user_metadata(user_id, update_user_metadata_request)
|
1350
|
+
p result
|
1351
|
+
rescue ClerkHttpClient::ApiError => e
|
1352
|
+
puts "Error when calling UsersApi->update_user_metadata: #{e}"
|
1353
|
+
end
|
1354
|
+
```
|
1355
|
+
|
1356
|
+
#### Using the update_user_metadata_with_http_info variant
|
1357
|
+
|
1358
|
+
This returns an Array which contains the response data, status code and headers.
|
1359
|
+
|
1360
|
+
> <Array(<User>, Integer, Hash)> update_user_metadata_with_http_info(user_id, update_user_metadata_request)
|
1361
|
+
|
1362
|
+
```ruby
|
1363
|
+
begin
|
1364
|
+
# Merge and update a user's metadata
|
1365
|
+
data, status_code, headers = api_instance.update_user_metadata_with_http_info(user_id, update_user_metadata_request)
|
1366
|
+
p status_code # => 2xx
|
1367
|
+
p headers # => { ... }
|
1368
|
+
p data # => <User>
|
1369
|
+
rescue ClerkHttpClient::ApiError => e
|
1370
|
+
puts "Error when calling UsersApi->update_user_metadata_with_http_info: #{e}"
|
1371
|
+
end
|
1372
|
+
```
|
1373
|
+
|
1374
|
+
### Parameters
|
1375
|
+
|
1376
|
+
| Name | Type | Description | Notes |
|
1377
|
+
| ---- | ---- | ----------- | ----- |
|
1378
|
+
| **user_id** | **String** | The ID of the user whose metadata will be updated and merged | |
|
1379
|
+
| **update_user_metadata_request** | [**UpdateUserMetadataRequest**](UpdateUserMetadataRequest.md) | | |
|
1380
|
+
|
1381
|
+
### Return type
|
1382
|
+
|
1383
|
+
[**User**](User.md)
|
1384
|
+
|
1385
|
+
### Authorization
|
1386
|
+
|
1387
|
+
[bearerAuth](../README.md#bearerAuth)
|
1388
|
+
|
1389
|
+
### HTTP request headers
|
1390
|
+
|
1391
|
+
- **Content-Type**: application/json
|
1392
|
+
- **Accept**: application/json
|
1393
|
+
|
1394
|
+
|
1395
|
+
## user_passkey_delete
|
1396
|
+
|
1397
|
+
> <DeletedObject> user_passkey_delete(user_id, passkey_identification_id)
|
1398
|
+
|
1399
|
+
Delete a user passkey
|
1400
|
+
|
1401
|
+
Delete the passkey identification for a given user and notify them through email.
|
1402
|
+
|
1403
|
+
### Examples
|
1404
|
+
|
1405
|
+
```ruby
|
1406
|
+
require 'time'
|
1407
|
+
require 'clerk-http-client'
|
1408
|
+
# setup authorization
|
1409
|
+
ClerkHttpClient.configure do |config|
|
1410
|
+
# Configure Bearer authorization (sk_<environment>_<secret value>): bearerAuth
|
1411
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
1412
|
+
end
|
1413
|
+
|
1414
|
+
api_instance = ClerkHttpClient::UsersApi.new
|
1415
|
+
user_id = 'user_id_example' # String | The ID of the user that owns the passkey identity
|
1416
|
+
passkey_identification_id = 'passkey_identification_id_example' # String | The ID of the passkey identity to be deleted
|
1417
|
+
|
1418
|
+
begin
|
1419
|
+
# Delete a user passkey
|
1420
|
+
result = api_instance.user_passkey_delete(user_id, passkey_identification_id)
|
1421
|
+
p result
|
1422
|
+
rescue ClerkHttpClient::ApiError => e
|
1423
|
+
puts "Error when calling UsersApi->user_passkey_delete: #{e}"
|
1424
|
+
end
|
1425
|
+
```
|
1426
|
+
|
1427
|
+
#### Using the user_passkey_delete_with_http_info variant
|
1428
|
+
|
1429
|
+
This returns an Array which contains the response data, status code and headers.
|
1430
|
+
|
1431
|
+
> <Array(<DeletedObject>, Integer, Hash)> user_passkey_delete_with_http_info(user_id, passkey_identification_id)
|
1432
|
+
|
1433
|
+
```ruby
|
1434
|
+
begin
|
1435
|
+
# Delete a user passkey
|
1436
|
+
data, status_code, headers = api_instance.user_passkey_delete_with_http_info(user_id, passkey_identification_id)
|
1437
|
+
p status_code # => 2xx
|
1438
|
+
p headers # => { ... }
|
1439
|
+
p data # => <DeletedObject>
|
1440
|
+
rescue ClerkHttpClient::ApiError => e
|
1441
|
+
puts "Error when calling UsersApi->user_passkey_delete_with_http_info: #{e}"
|
1442
|
+
end
|
1443
|
+
```
|
1444
|
+
|
1445
|
+
### Parameters
|
1446
|
+
|
1447
|
+
| Name | Type | Description | Notes |
|
1448
|
+
| ---- | ---- | ----------- | ----- |
|
1449
|
+
| **user_id** | **String** | The ID of the user that owns the passkey identity | |
|
1450
|
+
| **passkey_identification_id** | **String** | The ID of the passkey identity to be deleted | |
|
1451
|
+
|
1452
|
+
### Return type
|
1453
|
+
|
1454
|
+
[**DeletedObject**](DeletedObject.md)
|
1455
|
+
|
1456
|
+
### Authorization
|
1457
|
+
|
1458
|
+
[bearerAuth](../README.md#bearerAuth)
|
1459
|
+
|
1460
|
+
### HTTP request headers
|
1461
|
+
|
1462
|
+
- **Content-Type**: Not defined
|
1463
|
+
- **Accept**: application/json
|
1464
|
+
|
1465
|
+
|
1466
|
+
## user_web3_wallet_delete
|
1467
|
+
|
1468
|
+
> <DeletedObject> user_web3_wallet_delete(user_id, web3_wallet_identification_id)
|
1469
|
+
|
1470
|
+
Delete a user web3 wallet
|
1471
|
+
|
1472
|
+
Delete the web3 wallet identification for a given user.
|
1473
|
+
|
1474
|
+
### Examples
|
1475
|
+
|
1476
|
+
```ruby
|
1477
|
+
require 'time'
|
1478
|
+
require 'clerk-http-client'
|
1479
|
+
# setup authorization
|
1480
|
+
ClerkHttpClient.configure do |config|
|
1481
|
+
# Configure Bearer authorization (sk_<environment>_<secret value>): bearerAuth
|
1482
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
1483
|
+
end
|
1484
|
+
|
1485
|
+
api_instance = ClerkHttpClient::UsersApi.new
|
1486
|
+
user_id = 'user_id_example' # String | The ID of the user that owns the web3 wallet
|
1487
|
+
web3_wallet_identification_id = 'web3_wallet_identification_id_example' # String | The ID of the web3 wallet identity to be deleted
|
1488
|
+
|
1489
|
+
begin
|
1490
|
+
# Delete a user web3 wallet
|
1491
|
+
result = api_instance.user_web3_wallet_delete(user_id, web3_wallet_identification_id)
|
1492
|
+
p result
|
1493
|
+
rescue ClerkHttpClient::ApiError => e
|
1494
|
+
puts "Error when calling UsersApi->user_web3_wallet_delete: #{e}"
|
1495
|
+
end
|
1496
|
+
```
|
1497
|
+
|
1498
|
+
#### Using the user_web3_wallet_delete_with_http_info variant
|
1499
|
+
|
1500
|
+
This returns an Array which contains the response data, status code and headers.
|
1501
|
+
|
1502
|
+
> <Array(<DeletedObject>, Integer, Hash)> user_web3_wallet_delete_with_http_info(user_id, web3_wallet_identification_id)
|
1503
|
+
|
1504
|
+
```ruby
|
1505
|
+
begin
|
1506
|
+
# Delete a user web3 wallet
|
1507
|
+
data, status_code, headers = api_instance.user_web3_wallet_delete_with_http_info(user_id, web3_wallet_identification_id)
|
1508
|
+
p status_code # => 2xx
|
1509
|
+
p headers # => { ... }
|
1510
|
+
p data # => <DeletedObject>
|
1511
|
+
rescue ClerkHttpClient::ApiError => e
|
1512
|
+
puts "Error when calling UsersApi->user_web3_wallet_delete_with_http_info: #{e}"
|
1513
|
+
end
|
1514
|
+
```
|
1515
|
+
|
1516
|
+
### Parameters
|
1517
|
+
|
1518
|
+
| Name | Type | Description | Notes |
|
1519
|
+
| ---- | ---- | ----------- | ----- |
|
1520
|
+
| **user_id** | **String** | The ID of the user that owns the web3 wallet | |
|
1521
|
+
| **web3_wallet_identification_id** | **String** | The ID of the web3 wallet identity to be deleted | |
|
1522
|
+
|
1523
|
+
### Return type
|
1524
|
+
|
1525
|
+
[**DeletedObject**](DeletedObject.md)
|
1526
|
+
|
1527
|
+
### Authorization
|
1528
|
+
|
1529
|
+
[bearerAuth](../README.md#bearerAuth)
|
1530
|
+
|
1531
|
+
### HTTP request headers
|
1532
|
+
|
1533
|
+
- **Content-Type**: Not defined
|
1534
|
+
- **Accept**: application/json
|
1535
|
+
|
1536
|
+
|
1537
|
+
## users_get_organization_invitations
|
1538
|
+
|
1539
|
+
> <OrganizationInvitationsWithPublicOrganizationData> users_get_organization_invitations(user_id, opts)
|
1540
|
+
|
1541
|
+
Retrieve all invitations for a user
|
1542
|
+
|
1543
|
+
Retrieve a paginated list of the user's organization invitations
|
1544
|
+
|
1545
|
+
### Examples
|
1546
|
+
|
1547
|
+
```ruby
|
1548
|
+
require 'time'
|
1549
|
+
require 'clerk-http-client'
|
1550
|
+
# setup authorization
|
1551
|
+
ClerkHttpClient.configure do |config|
|
1552
|
+
# Configure Bearer authorization (sk_<environment>_<secret value>): bearerAuth
|
1553
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
1554
|
+
end
|
1555
|
+
|
1556
|
+
api_instance = ClerkHttpClient::UsersApi.new
|
1557
|
+
user_id = 'user_id_example' # String | The ID of the user whose organization invitations we want to retrieve
|
1558
|
+
opts = {
|
1559
|
+
limit: 8.14, # Float | Applies a limit to the number of results returned. Can be used for paginating the results together with `offset`.
|
1560
|
+
offset: 8.14, # Float | Skip the first `offset` results when paginating. Needs to be an integer greater or equal to zero. To be used in conjunction with `limit`.
|
1561
|
+
status: 'pending' # String | Filter organization invitations based on their status
|
1562
|
+
}
|
1563
|
+
|
1564
|
+
begin
|
1565
|
+
# Retrieve all invitations for a user
|
1566
|
+
result = api_instance.users_get_organization_invitations(user_id, opts)
|
1567
|
+
p result
|
1568
|
+
rescue ClerkHttpClient::ApiError => e
|
1569
|
+
puts "Error when calling UsersApi->users_get_organization_invitations: #{e}"
|
1570
|
+
end
|
1571
|
+
```
|
1572
|
+
|
1573
|
+
#### Using the users_get_organization_invitations_with_http_info variant
|
1574
|
+
|
1575
|
+
This returns an Array which contains the response data, status code and headers.
|
1576
|
+
|
1577
|
+
> <Array(<OrganizationInvitationsWithPublicOrganizationData>, Integer, Hash)> users_get_organization_invitations_with_http_info(user_id, opts)
|
1578
|
+
|
1579
|
+
```ruby
|
1580
|
+
begin
|
1581
|
+
# Retrieve all invitations for a user
|
1582
|
+
data, status_code, headers = api_instance.users_get_organization_invitations_with_http_info(user_id, opts)
|
1583
|
+
p status_code # => 2xx
|
1584
|
+
p headers # => { ... }
|
1585
|
+
p data # => <OrganizationInvitationsWithPublicOrganizationData>
|
1586
|
+
rescue ClerkHttpClient::ApiError => e
|
1587
|
+
puts "Error when calling UsersApi->users_get_organization_invitations_with_http_info: #{e}"
|
1588
|
+
end
|
1589
|
+
```
|
1590
|
+
|
1591
|
+
### Parameters
|
1592
|
+
|
1593
|
+
| Name | Type | Description | Notes |
|
1594
|
+
| ---- | ---- | ----------- | ----- |
|
1595
|
+
| **user_id** | **String** | The ID of the user whose organization invitations we want to retrieve | |
|
1596
|
+
| **limit** | **Float** | Applies a limit to the number of results returned. Can be used for paginating the results together with `offset`. | [optional][default to 10] |
|
1597
|
+
| **offset** | **Float** | Skip the first `offset` results when paginating. Needs to be an integer greater or equal to zero. To be used in conjunction with `limit`. | [optional][default to 0] |
|
1598
|
+
| **status** | **String** | Filter organization invitations based on their status | [optional] |
|
1599
|
+
|
1600
|
+
### Return type
|
1601
|
+
|
1602
|
+
[**OrganizationInvitationsWithPublicOrganizationData**](OrganizationInvitationsWithPublicOrganizationData.md)
|
1603
|
+
|
1604
|
+
### Authorization
|
1605
|
+
|
1606
|
+
[bearerAuth](../README.md#bearerAuth)
|
1607
|
+
|
1608
|
+
### HTTP request headers
|
1609
|
+
|
1610
|
+
- **Content-Type**: Not defined
|
1611
|
+
- **Accept**: application/json
|
1612
|
+
|
1613
|
+
|
1614
|
+
## users_get_organization_memberships
|
1615
|
+
|
1616
|
+
> <OrganizationMemberships> users_get_organization_memberships(user_id, opts)
|
1617
|
+
|
1618
|
+
Retrieve all memberships for a user
|
1619
|
+
|
1620
|
+
Retrieve a paginated list of the user's organization memberships
|
1621
|
+
|
1622
|
+
### Examples
|
1623
|
+
|
1624
|
+
```ruby
|
1625
|
+
require 'time'
|
1626
|
+
require 'clerk-http-client'
|
1627
|
+
# setup authorization
|
1628
|
+
ClerkHttpClient.configure do |config|
|
1629
|
+
# Configure Bearer authorization (sk_<environment>_<secret value>): bearerAuth
|
1630
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
1631
|
+
end
|
1632
|
+
|
1633
|
+
api_instance = ClerkHttpClient::UsersApi.new
|
1634
|
+
user_id = 'user_id_example' # String | The ID of the user whose organization memberships we want to retrieve
|
1635
|
+
opts = {
|
1636
|
+
limit: 8.14, # Float | Applies a limit to the number of results returned. Can be used for paginating the results together with `offset`.
|
1637
|
+
offset: 8.14 # Float | Skip the first `offset` results when paginating. Needs to be an integer greater or equal to zero. To be used in conjunction with `limit`.
|
1638
|
+
}
|
1639
|
+
|
1640
|
+
begin
|
1641
|
+
# Retrieve all memberships for a user
|
1642
|
+
result = api_instance.users_get_organization_memberships(user_id, opts)
|
1643
|
+
p result
|
1644
|
+
rescue ClerkHttpClient::ApiError => e
|
1645
|
+
puts "Error when calling UsersApi->users_get_organization_memberships: #{e}"
|
1646
|
+
end
|
1647
|
+
```
|
1648
|
+
|
1649
|
+
#### Using the users_get_organization_memberships_with_http_info variant
|
1650
|
+
|
1651
|
+
This returns an Array which contains the response data, status code and headers.
|
1652
|
+
|
1653
|
+
> <Array(<OrganizationMemberships>, Integer, Hash)> users_get_organization_memberships_with_http_info(user_id, opts)
|
1654
|
+
|
1655
|
+
```ruby
|
1656
|
+
begin
|
1657
|
+
# Retrieve all memberships for a user
|
1658
|
+
data, status_code, headers = api_instance.users_get_organization_memberships_with_http_info(user_id, opts)
|
1659
|
+
p status_code # => 2xx
|
1660
|
+
p headers # => { ... }
|
1661
|
+
p data # => <OrganizationMemberships>
|
1662
|
+
rescue ClerkHttpClient::ApiError => e
|
1663
|
+
puts "Error when calling UsersApi->users_get_organization_memberships_with_http_info: #{e}"
|
1664
|
+
end
|
1665
|
+
```
|
1666
|
+
|
1667
|
+
### Parameters
|
1668
|
+
|
1669
|
+
| Name | Type | Description | Notes |
|
1670
|
+
| ---- | ---- | ----------- | ----- |
|
1671
|
+
| **user_id** | **String** | The ID of the user whose organization memberships we want to retrieve | |
|
1672
|
+
| **limit** | **Float** | Applies a limit to the number of results returned. Can be used for paginating the results together with `offset`. | [optional][default to 10] |
|
1673
|
+
| **offset** | **Float** | Skip the first `offset` results when paginating. Needs to be an integer greater or equal to zero. To be used in conjunction with `limit`. | [optional][default to 0] |
|
1674
|
+
|
1675
|
+
### Return type
|
1676
|
+
|
1677
|
+
[**OrganizationMemberships**](OrganizationMemberships.md)
|
1678
|
+
|
1679
|
+
### Authorization
|
1680
|
+
|
1681
|
+
[bearerAuth](../README.md#bearerAuth)
|
1682
|
+
|
1683
|
+
### HTTP request headers
|
1684
|
+
|
1685
|
+
- **Content-Type**: Not defined
|
1686
|
+
- **Accept**: application/json
|
1687
|
+
|
1688
|
+
|
1689
|
+
## verify_password
|
1690
|
+
|
1691
|
+
> <VerifyPassword200Response> verify_password(user_id, verify_password_request)
|
1692
|
+
|
1693
|
+
Verify the password of a user
|
1694
|
+
|
1695
|
+
Check that the user's password matches the supplied input. Useful for custom auth flows and re-verification.
|
1696
|
+
|
1697
|
+
### Examples
|
1698
|
+
|
1699
|
+
```ruby
|
1700
|
+
require 'time'
|
1701
|
+
require 'clerk-http-client'
|
1702
|
+
# setup authorization
|
1703
|
+
ClerkHttpClient.configure do |config|
|
1704
|
+
# Configure Bearer authorization (sk_<environment>_<secret value>): bearerAuth
|
1705
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
1706
|
+
end
|
1707
|
+
|
1708
|
+
api_instance = ClerkHttpClient::UsersApi.new
|
1709
|
+
user_id = 'user_id_example' # String | The ID of the user for whom to verify the password
|
1710
|
+
verify_password_request = ClerkHttpClient::VerifyPasswordRequest.new({password: 'password_example'}) # VerifyPasswordRequest |
|
1711
|
+
|
1712
|
+
begin
|
1713
|
+
# Verify the password of a user
|
1714
|
+
result = api_instance.verify_password(user_id, verify_password_request)
|
1715
|
+
p result
|
1716
|
+
rescue ClerkHttpClient::ApiError => e
|
1717
|
+
puts "Error when calling UsersApi->verify_password: #{e}"
|
1718
|
+
end
|
1719
|
+
```
|
1720
|
+
|
1721
|
+
#### Using the verify_password_with_http_info variant
|
1722
|
+
|
1723
|
+
This returns an Array which contains the response data, status code and headers.
|
1724
|
+
|
1725
|
+
> <Array(<VerifyPassword200Response>, Integer, Hash)> verify_password_with_http_info(user_id, verify_password_request)
|
1726
|
+
|
1727
|
+
```ruby
|
1728
|
+
begin
|
1729
|
+
# Verify the password of a user
|
1730
|
+
data, status_code, headers = api_instance.verify_password_with_http_info(user_id, verify_password_request)
|
1731
|
+
p status_code # => 2xx
|
1732
|
+
p headers # => { ... }
|
1733
|
+
p data # => <VerifyPassword200Response>
|
1734
|
+
rescue ClerkHttpClient::ApiError => e
|
1735
|
+
puts "Error when calling UsersApi->verify_password_with_http_info: #{e}"
|
1736
|
+
end
|
1737
|
+
```
|
1738
|
+
|
1739
|
+
### Parameters
|
1740
|
+
|
1741
|
+
| Name | Type | Description | Notes |
|
1742
|
+
| ---- | ---- | ----------- | ----- |
|
1743
|
+
| **user_id** | **String** | The ID of the user for whom to verify the password | |
|
1744
|
+
| **verify_password_request** | [**VerifyPasswordRequest**](VerifyPasswordRequest.md) | | |
|
1745
|
+
|
1746
|
+
### Return type
|
1747
|
+
|
1748
|
+
[**VerifyPassword200Response**](VerifyPassword200Response.md)
|
1749
|
+
|
1750
|
+
### Authorization
|
1751
|
+
|
1752
|
+
[bearerAuth](../README.md#bearerAuth)
|
1753
|
+
|
1754
|
+
### HTTP request headers
|
1755
|
+
|
1756
|
+
- **Content-Type**: application/json
|
1757
|
+
- **Accept**: application/json
|
1758
|
+
|
1759
|
+
|
1760
|
+
## verify_totp
|
1761
|
+
|
1762
|
+
> <VerifyTOTP200Response> verify_totp(user_id, verify_totp_request)
|
1763
|
+
|
1764
|
+
Verify a TOTP or backup code for a user
|
1765
|
+
|
1766
|
+
Verify that the provided TOTP or backup code is valid for the user. Verifying a backup code will result it in being consumed (i.e. it will become invalid). Useful for custom auth flows and re-verification.
|
1767
|
+
|
1768
|
+
### Examples
|
1769
|
+
|
1770
|
+
```ruby
|
1771
|
+
require 'time'
|
1772
|
+
require 'clerk-http-client'
|
1773
|
+
# setup authorization
|
1774
|
+
ClerkHttpClient.configure do |config|
|
1775
|
+
# Configure Bearer authorization (sk_<environment>_<secret value>): bearerAuth
|
1776
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
1777
|
+
end
|
1778
|
+
|
1779
|
+
api_instance = ClerkHttpClient::UsersApi.new
|
1780
|
+
user_id = 'user_id_example' # String | The ID of the user for whom to verify the TOTP
|
1781
|
+
verify_totp_request = ClerkHttpClient::VerifyTOTPRequest.new({code: 'code_example'}) # VerifyTOTPRequest |
|
1782
|
+
|
1783
|
+
begin
|
1784
|
+
# Verify a TOTP or backup code for a user
|
1785
|
+
result = api_instance.verify_totp(user_id, verify_totp_request)
|
1786
|
+
p result
|
1787
|
+
rescue ClerkHttpClient::ApiError => e
|
1788
|
+
puts "Error when calling UsersApi->verify_totp: #{e}"
|
1789
|
+
end
|
1790
|
+
```
|
1791
|
+
|
1792
|
+
#### Using the verify_totp_with_http_info variant
|
1793
|
+
|
1794
|
+
This returns an Array which contains the response data, status code and headers.
|
1795
|
+
|
1796
|
+
> <Array(<VerifyTOTP200Response>, Integer, Hash)> verify_totp_with_http_info(user_id, verify_totp_request)
|
1797
|
+
|
1798
|
+
```ruby
|
1799
|
+
begin
|
1800
|
+
# Verify a TOTP or backup code for a user
|
1801
|
+
data, status_code, headers = api_instance.verify_totp_with_http_info(user_id, verify_totp_request)
|
1802
|
+
p status_code # => 2xx
|
1803
|
+
p headers # => { ... }
|
1804
|
+
p data # => <VerifyTOTP200Response>
|
1805
|
+
rescue ClerkHttpClient::ApiError => e
|
1806
|
+
puts "Error when calling UsersApi->verify_totp_with_http_info: #{e}"
|
1807
|
+
end
|
1808
|
+
```
|
1809
|
+
|
1810
|
+
### Parameters
|
1811
|
+
|
1812
|
+
| Name | Type | Description | Notes |
|
1813
|
+
| ---- | ---- | ----------- | ----- |
|
1814
|
+
| **user_id** | **String** | The ID of the user for whom to verify the TOTP | |
|
1815
|
+
| **verify_totp_request** | [**VerifyTOTPRequest**](VerifyTOTPRequest.md) | | |
|
1816
|
+
|
1817
|
+
### Return type
|
1818
|
+
|
1819
|
+
[**VerifyTOTP200Response**](VerifyTOTP200Response.md)
|
1820
|
+
|
1821
|
+
### Authorization
|
1822
|
+
|
1823
|
+
[bearerAuth](../README.md#bearerAuth)
|
1824
|
+
|
1825
|
+
### HTTP request headers
|
1826
|
+
|
1827
|
+
- **Content-Type**: application/json
|
1828
|
+
- **Accept**: application/json
|
1829
|
+
|