clerk-sdk-ruby 7.0.0 → 8.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 +4 -4
- data/lib/clerk/actortokens.rb +11 -11
- data/lib/clerk/admin_portal_link_tokens.rb +10 -10
- data/lib/clerk/agenttasks.rb +10 -10
- data/lib/clerk/allowlistidentifiers.rb +15 -15
- data/lib/clerk/api_keys.rb +40 -40
- data/lib/clerk/betafeatures.rb +10 -10
- data/lib/clerk/billing.rb +388 -52
- data/lib/clerk/blocklistidentifiers.rb +15 -15
- data/lib/clerk/clients.rb +15 -15
- data/lib/clerk/directories.rb +1534 -0
- data/lib/clerk/domains.rb +27 -24
- data/lib/clerk/emailaddresses.rb +43 -36
- data/lib/clerk/emailandsmstemplates.rb +6 -6
- data/lib/clerk/emailsmstemplates.rb +21 -21
- data/lib/clerk/enterpriseconnections.rb +35 -35
- data/lib/clerk/instancesettings.rb +60 -60
- data/lib/clerk/invitations.rb +20 -20
- data/lib/clerk/jwks.rb +5 -5
- data/lib/clerk/jwttemplates.rb +25 -25
- data/lib/clerk/m2m.rb +20 -20
- data/lib/clerk/machines.rb +45 -45
- data/lib/clerk/miscellaneous.rb +5 -5
- data/lib/clerk/models/components/amount_off.rb +44 -0
- data/lib/clerk/models/components/{schemas_commerceplan_fee.rbi → amount_off.rbi} +2 -2
- data/lib/clerk/models/components/applycommercediscountrequest.rb +32 -0
- data/lib/clerk/models/components/applycommercediscountrequest.rbi +13 -0
- data/lib/clerk/models/components/automation_disposition.rb +21 -0
- data/lib/clerk/models/components/automation_disposition.rbi +11 -0
- data/lib/clerk/models/components/billingpaymentattempt_totals.rb +1 -1
- data/lib/clerk/models/components/billingstatement.rb +1 -1
- data/lib/clerk/models/components/{group.rb → billingstatement_group.rb} +1 -1
- data/lib/clerk/models/components/{group.rbi → billingstatement_group.rbi} +2 -2
- data/lib/clerk/models/components/biometriccredential.rb +72 -0
- data/lib/clerk/models/components/biometriccredential.rbi +33 -0
- data/lib/clerk/models/components/biometriccredential_algorithm.rb +19 -0
- data/lib/clerk/models/components/biometriccredential_algorithm.rbi +11 -0
- data/lib/clerk/models/components/biometriccredential_list.rb +36 -0
- data/lib/clerk/models/components/biometriccredential_list.rbi +15 -0
- data/lib/clerk/models/components/biometriccredential_object.rb +19 -0
- data/lib/clerk/models/components/biometriccredential_object.rbi +11 -0
- data/lib/clerk/models/components/biometriccredential_platform.rb +20 -0
- data/lib/clerk/models/components/biometriccredential_platform.rbi +11 -0
- data/lib/clerk/models/components/biometriccredential_status.rb +20 -0
- data/lib/clerk/models/components/biometriccredential_status.rbi +11 -0
- data/lib/clerk/models/components/clerkerror.rb +1 -1
- data/lib/clerk/models/components/commercecreditledgerresponse.rb +3 -7
- data/lib/clerk/models/components/commercecreditledgerresponse.rbi +0 -2
- data/lib/clerk/models/components/commercediscountredemptionresponse.rb +93 -0
- data/lib/clerk/models/components/commercediscountredemptionresponse.rbi +43 -0
- data/lib/clerk/models/components/commercediscountredemptionresponse_amount.rb +45 -0
- data/lib/clerk/models/components/{schemas_commercesubscriptionitem_amount.rbi → commercediscountredemptionresponse_amount.rbi} +2 -2
- data/lib/clerk/models/components/commercediscountredemptionresponse_object.rb +19 -0
- data/lib/clerk/models/components/commercediscountredemptionresponse_object.rbi +11 -0
- data/lib/clerk/models/components/commercediscountredemptionresponse_status.rb +21 -0
- data/lib/clerk/models/components/commercediscountredemptionresponse_status.rbi +11 -0
- data/lib/clerk/models/components/{schemas_commerceperunittotal.rb → commerceperunittotal_2.rb} +2 -2
- data/lib/clerk/models/components/{schemas_commerceperunittotal.rbi → commerceperunittotal_2.rbi} +2 -2
- data/lib/clerk/models/components/{schemas_commerceperunittotaltier.rb → commerceperunittotaltier_2.rb} +1 -1
- data/lib/clerk/models/components/{schemas_commerceperunittotaltier.rbi → commerceperunittotaltier_2.rbi} +2 -2
- data/lib/clerk/models/components/{schemas_commerceplan.rb → commerceplan_2.rb} +6 -6
- data/lib/clerk/models/components/{schemas_commerceplan.rbi → commerceplan_2.rbi} +2 -2
- data/lib/clerk/models/components/{schemas_commerceplan_fee.rb → commerceplan_2_annual_fee.rb} +1 -1
- data/lib/clerk/models/components/{schemas_commerceplan_annual_fee.rbi → commerceplan_2_annual_fee.rbi} +2 -2
- data/lib/clerk/models/components/{schemas_commercesubscriptionitem_fee.rb → commerceplan_2_annual_monthly_fee.rb} +1 -1
- data/lib/clerk/models/components/{schemas_commerceplan_annual_monthly_fee.rbi → commerceplan_2_annual_monthly_fee.rbi} +2 -2
- data/lib/clerk/models/components/{schemas_commerceplan_annual_fee.rb → commerceplan_2_fee.rb} +1 -1
- data/lib/clerk/models/components/commerceplan_2_fee.rbi +19 -0
- data/lib/clerk/models/components/{schemas_commerceplan_object.rb → commerceplan_2_object.rb} +2 -2
- data/lib/clerk/models/components/commerceplan_2_object.rbi +11 -0
- data/lib/clerk/models/components/commercepricetransitiondetails.rb +1 -1
- data/lib/clerk/models/components/commercepricetransitionresponse.rb +1 -1
- data/lib/clerk/models/components/{schemas_commercesubscriptionitem.rb → commercesubscriptionitem_2.rb} +7 -7
- data/lib/clerk/models/components/{schemas_commercesubscriptionitem.rbi → commercesubscriptionitem_2.rbi} +2 -2
- data/lib/clerk/models/components/{schemas_commercesubscriptionitem_amount.rb → commercesubscriptionitem_2_amount.rb} +1 -1
- data/lib/clerk/models/components/commercesubscriptionitem_2_amount.rbi +19 -0
- data/lib/clerk/models/components/{schemas_commerceplan_annual_monthly_fee.rb → commercesubscriptionitem_2_annual_fee.rb} +1 -1
- data/lib/clerk/models/components/{schemas_commercesubscriptionitem_fee.rbi → commercesubscriptionitem_2_annual_fee.rbi} +2 -2
- data/lib/clerk/models/components/{schemas_commercesubscriptionitem_annual_fee.rb → commercesubscriptionitem_2_annual_monthly_fee.rb} +1 -1
- data/lib/clerk/models/components/commercesubscriptionitem_2_annual_monthly_fee.rbi +19 -0
- data/lib/clerk/models/components/commercesubscriptionitem_2_fee.rb +44 -0
- data/lib/clerk/models/components/commercesubscriptionitem_2_fee.rbi +19 -0
- data/lib/clerk/models/components/{schemas_commercesubscriptionitem_next_payment.rb → commercesubscriptionitem_2_next_payment.rb} +3 -3
- data/lib/clerk/models/components/{schemas_commercesubscriptionitem_next_payment.rbi → commercesubscriptionitem_2_next_payment.rbi} +2 -2
- data/lib/clerk/models/components/{schemas_commercesubscriptionitem_next_payment_amount.rb → commercesubscriptionitem_2_next_payment_amount.rb} +1 -1
- data/lib/clerk/models/components/commercesubscriptionitem_2_next_payment_amount.rbi +19 -0
- data/lib/clerk/models/components/{schemas_commercesubscriptionitem_next_payment_credits.rb → commercesubscriptionitem_2_next_payment_credits.rb} +3 -3
- data/lib/clerk/models/components/{schemas_commercesubscriptionitem_next_payment_credits.rbi → commercesubscriptionitem_2_next_payment_credits.rbi} +2 -2
- data/lib/clerk/models/components/{schemas_commercesubscriptionitem_next_payment_credits_proration.rb → commercesubscriptionitem_2_next_payment_credits_proration.rb} +1 -1
- data/lib/clerk/models/components/{schemas_commercesubscriptionitem_next_payment_credits_proration.rbi → commercesubscriptionitem_2_next_payment_credits_proration.rbi} +2 -2
- data/lib/clerk/models/components/{schemas_commercesubscriptionitem_next_payment_discounts.rb → commercesubscriptionitem_2_next_payment_discounts.rb} +2 -2
- data/lib/clerk/models/components/{schemas_commercesubscriptionitem_next_payment_discounts.rbi → commercesubscriptionitem_2_next_payment_discounts.rbi} +2 -2
- data/lib/clerk/models/components/{schemas_commercesubscriptionitem_next_payment_discounts_proration.rb → commercesubscriptionitem_2_next_payment_discounts_proration.rb} +1 -1
- data/lib/clerk/models/components/{schemas_commercesubscriptionitem_next_payment_discounts_proration.rbi → commercesubscriptionitem_2_next_payment_discounts_proration.rbi} +2 -2
- data/lib/clerk/models/components/{schemas_commercesubscriptionitem_next_payment_payer.rb → commercesubscriptionitem_2_next_payment_payer.rb} +1 -1
- data/lib/clerk/models/components/{schemas_commercesubscriptionitem_next_payment_payer.rbi → commercesubscriptionitem_2_next_payment_payer.rbi} +2 -2
- data/lib/clerk/models/components/{schemas_commercesubscriptionitem_next_payment_totals.rb → commercesubscriptionitem_2_next_payment_totals.rb} +3 -3
- data/lib/clerk/models/components/{schemas_commercesubscriptionitem_next_payment_totals.rbi → commercesubscriptionitem_2_next_payment_totals.rbi} +2 -2
- data/lib/clerk/models/components/{schemas_commercesubscriptionitem_object_commercepayer.rb → commercesubscriptionitem_2_object_commercepayer.rb} +2 -2
- data/lib/clerk/models/components/commercesubscriptionitem_2_object_commercepayer.rbi +11 -0
- data/lib/clerk/models/components/{schemas_commercesubscriptionitem_object_commerceplan.rb → commercesubscriptionitem_2_object_commerceplan.rb} +2 -2
- data/lib/clerk/models/components/commercesubscriptionitem_2_object_commerceplan.rbi +11 -0
- data/lib/clerk/models/components/{schemas_commercesubscriptionitem_object_commercesubscriptionitem.rb → commercesubscriptionitem_2_object_commercesubscriptionitem.rb} +2 -2
- data/lib/clerk/models/components/commercesubscriptionitem_2_object_commercesubscriptionitem.rbi +11 -0
- data/lib/clerk/models/components/{schemas_commercesubscriptionitem_plan.rb → commercesubscriptionitem_2_plan.rb} +6 -6
- data/lib/clerk/models/components/{schemas_commercesubscriptionitem_plan.rbi → commercesubscriptionitem_2_plan.rbi} +2 -2
- data/lib/clerk/models/components/{schemas_commercesubscriptionitem_plan_period.rb → commercesubscriptionitem_2_plan_period.rb} +2 -2
- data/lib/clerk/models/components/commercesubscriptionitem_2_plan_period.rbi +11 -0
- data/lib/clerk/models/components/{schemas_commercesubscriptionitem_status.rb → commercesubscriptionitem_2_status.rb} +2 -2
- data/lib/clerk/models/components/commercesubscriptionitem_2_status.rbi +11 -0
- data/lib/clerk/models/components/commercesubscriptionitem_totals.rb +1 -1
- data/lib/clerk/models/components/commercesubscriptionnextpayment.rb +1 -1
- data/lib/clerk/models/components/commercesubscriptionnextpayment_totals.rb +1 -1
- data/lib/clerk/models/components/createbillingpricerequest.rb +2 -2
- data/lib/clerk/models/components/directory.rb +80 -0
- data/lib/clerk/models/components/directory.rbi +37 -0
- data/lib/clerk/models/components/directory_custom_attribute.rb +52 -0
- data/lib/clerk/models/components/{custom_attribute.rbi → directory_custom_attribute.rbi} +4 -2
- data/lib/clerk/models/components/directory_group.rb +36 -0
- data/lib/clerk/models/components/directory_group.rbi +15 -0
- data/lib/clerk/models/components/directory_list.rb +36 -0
- data/lib/clerk/models/components/directory_list.rbi +15 -0
- data/lib/clerk/models/components/directory_object.rb +19 -0
- data/lib/clerk/models/components/{samlaccount_meta.rbi → directory_object.rbi} +2 -2
- data/lib/clerk/models/components/directorygrouprolemapping.rb +76 -0
- data/lib/clerk/models/components/directorygrouprolemapping.rbi +35 -0
- data/lib/clerk/models/components/directorygrouprolemapping_deleted.rb +43 -0
- data/lib/clerk/models/components/directorygrouprolemapping_deleted.rbi +17 -0
- data/lib/clerk/models/components/directorygrouprolemapping_deleted_object.rb +19 -0
- data/lib/clerk/models/components/directorygrouprolemapping_deleted_object.rbi +11 -0
- data/lib/clerk/models/components/directorygrouprolemapping_list.rb +36 -0
- data/lib/clerk/models/components/directorygrouprolemapping_list.rbi +15 -0
- data/lib/clerk/models/components/directorygrouprolemapping_object.rb +19 -0
- data/lib/clerk/models/components/directorygrouprolemapping_object.rbi +11 -0
- data/lib/clerk/models/components/dnstarget.rb +49 -0
- data/lib/clerk/models/components/dnstarget.rbi +21 -0
- data/lib/clerk/models/components/domain.rb +7 -2
- data/lib/clerk/models/components/domain.rbi +2 -0
- data/lib/clerk/models/components/effect.rb +20 -0
- data/lib/clerk/models/components/{clerkerror_meta.rbi → effect.rbi} +2 -2
- data/lib/clerk/models/components/emailaddress_verification_saml_clerkerror.rb +1 -1
- data/lib/clerk/models/components/enrollment_mode.rb +1 -0
- data/lib/clerk/models/components/enterpriseaccount_verification_oauth_clerkerror.rb +1 -1
- data/lib/clerk/models/components/enterpriseaccount_verification_saml_clerkerror.rb +1 -1
- data/lib/clerk/models/components/enterpriseconnection.rb +6 -2
- data/lib/clerk/models/components/enterpriseconnection.rbi +2 -0
- data/lib/clerk/models/components/{custom_attribute.rb → enterpriseconnection_custom_attribute.rb} +6 -2
- data/lib/clerk/models/components/enterpriseconnection_custom_attribute.rbi +23 -0
- data/lib/clerk/models/components/enterpriseconnection_mode.rb +21 -0
- data/lib/clerk/models/components/enterpriseconnection_mode.rbi +11 -0
- data/lib/clerk/models/components/enterpriseconnection_object.rb +19 -0
- data/lib/clerk/models/components/enterpriseconnection_object.rbi +11 -0
- data/lib/clerk/models/components/enterpriseconnection_saml_connection.rb +5 -1
- data/lib/clerk/models/components/enterpriseconnection_saml_connection.rbi +2 -0
- data/lib/clerk/models/components/externalaccountwithverification_verification_oauth_clerkerror.rb +1 -1
- data/lib/clerk/models/components/{schemas_featureresponse.rb → featureresponse_2.rb} +2 -2
- data/lib/clerk/models/components/{schemas_featureresponse.rbi → featureresponse_2.rbi} +2 -2
- data/lib/clerk/models/components/{schemas_featureresponse_object.rb → featureresponse_2_object.rb} +2 -2
- data/lib/clerk/models/components/featureresponse_2_object.rbi +11 -0
- data/lib/clerk/models/components/instance.rb +13 -1
- data/lib/clerk/models/components/instance.rbi +6 -0
- data/lib/clerk/models/components/instanceprotect.rb +14 -2
- data/lib/clerk/models/components/instanceprotect.rbi +6 -0
- data/lib/clerk/models/components/instancesettings.rb +4 -1
- data/lib/clerk/models/components/level.rb +21 -0
- data/lib/clerk/models/components/{clerkerrors_meta.rbi → level.rbi} +2 -2
- data/lib/clerk/models/components/login_hint.rb +36 -0
- data/lib/clerk/models/components/login_hint.rbi +15 -0
- data/lib/clerk/models/components/oauthapplication.rb +7 -2
- data/lib/clerk/models/components/oauthapplication.rbi +2 -0
- data/lib/clerk/models/components/oauthapplicationsettings.rb +26 -1
- data/lib/clerk/models/components/oauthapplicationsettings.rbi +12 -0
- data/lib/clerk/models/components/oauthapplicationwithsecret.rb +7 -2
- data/lib/clerk/models/components/oauthapplicationwithsecret.rbi +2 -0
- data/lib/clerk/models/components/organization.rb +6 -1
- data/lib/clerk/models/components/organization.rbi +2 -0
- data/lib/clerk/models/components/organizationmembership_organization.rb +6 -1
- data/lib/clerk/models/components/organizationmembership_organization.rbi +2 -0
- data/lib/clerk/models/components/organizationmembershippublicuserdata.rb +5 -1
- data/lib/clerk/models/components/organizationmembershippublicuserdata.rbi +2 -0
- data/lib/clerk/models/components/organizationwithlogo.rb +6 -1
- data/lib/clerk/models/components/organizationwithlogo.rbi +2 -0
- data/lib/clerk/models/components/payer_commercepayer.rb +1 -1
- data/lib/clerk/models/components/payment_type.rb +1 -0
- data/lib/clerk/models/components/record_type.rb +20 -0
- data/lib/clerk/models/components/record_type.rbi +11 -0
- data/lib/clerk/models/components/reverification.rb +74 -0
- data/lib/clerk/models/components/reverification.rbi +31 -0
- data/lib/clerk/models/components/reverification_object.rb +20 -0
- data/lib/clerk/models/components/reverification_object.rbi +11 -0
- data/lib/clerk/models/components/reverification_status.rb +21 -0
- data/lib/clerk/models/components/reverification_status.rbi +11 -0
- data/lib/clerk/models/components/samlaccount_clerkerror.rb +1 -1
- data/lib/clerk/models/components/samlconnection_1.rb +15 -1
- data/lib/clerk/models/components/samlconnection_1.rbi +6 -0
- data/lib/clerk/models/components/samlconnection_2.rb +15 -1
- data/lib/clerk/models/components/samlconnection_2.rbi +6 -0
- data/lib/clerk/models/components/samlconnectionloginhint.rb +36 -0
- data/lib/clerk/models/components/samlconnectionloginhint.rbi +15 -0
- data/lib/clerk/models/components/samlconnectionloginhint_mode.rb +21 -0
- data/lib/clerk/models/components/samlconnectionloginhint_mode.rbi +11 -0
- data/lib/clerk/models/components/scim_group.rb +36 -0
- data/lib/clerk/models/components/scim_group.rbi +15 -0
- data/lib/clerk/models/components/scimdirectory.rb +80 -0
- data/lib/clerk/models/components/scimdirectory.rbi +37 -0
- data/lib/clerk/models/components/scimdirectory_custom_attribute.rb +52 -0
- data/lib/clerk/models/components/scimdirectory_custom_attribute.rbi +23 -0
- data/lib/clerk/models/components/scimdirectory_list.rb +36 -0
- data/lib/clerk/models/components/scimdirectory_list.rbi +15 -0
- data/lib/clerk/models/components/scimdirectory_object.rb +19 -0
- data/lib/clerk/models/components/scimdirectory_object.rbi +11 -0
- data/lib/clerk/models/components/scimgrouprolemapping.rb +76 -0
- data/lib/clerk/models/components/scimgrouprolemapping.rbi +35 -0
- data/lib/clerk/models/components/scimgrouprolemapping_deleted.rb +43 -0
- data/lib/clerk/models/components/scimgrouprolemapping_deleted.rbi +17 -0
- data/lib/clerk/models/components/scimgrouprolemapping_deleted_object.rb +19 -0
- data/lib/clerk/models/components/scimgrouprolemapping_deleted_object.rbi +11 -0
- data/lib/clerk/models/components/scimgrouprolemapping_list.rb +36 -0
- data/lib/clerk/models/components/scimgrouprolemapping_list.rbi +15 -0
- data/lib/clerk/models/components/scimgrouprolemapping_object.rb +19 -0
- data/lib/clerk/models/components/scimgrouprolemapping_object.rbi +11 -0
- data/lib/clerk/models/components/scimusermetadata.rb +64 -0
- data/lib/clerk/models/components/scimusermetadata.rbi +27 -0
- data/lib/clerk/models/components/scimusermetadata_group.rb +36 -0
- data/lib/clerk/models/components/scimusermetadata_group.rbi +15 -0
- data/lib/clerk/models/components/seats.rb +1 -1
- data/lib/clerk/models/components/source.rb +21 -0
- data/lib/clerk/models/components/source.rbi +11 -0
- data/lib/clerk/models/components/trusteddevice.rb +72 -0
- data/lib/clerk/models/components/trusteddevice.rbi +33 -0
- data/lib/clerk/models/components/trusteddevice_algorithm.rb +19 -0
- data/lib/clerk/models/components/trusteddevice_algorithm.rbi +11 -0
- data/lib/clerk/models/components/trusteddevice_list.rb +36 -0
- data/lib/clerk/models/components/trusteddevice_list.rbi +15 -0
- data/lib/clerk/models/components/trusteddevice_object.rb +19 -0
- data/lib/clerk/models/components/trusteddevice_object.rbi +11 -0
- data/lib/clerk/models/components/trusteddevice_platform.rb +20 -0
- data/lib/clerk/models/components/trusteddevice_platform.rbi +11 -0
- data/lib/clerk/models/components/trusteddevice_status.rb +20 -0
- data/lib/clerk/models/components/trusteddevice_status.rbi +11 -0
- data/lib/clerk/models/components/user.rb +16 -3
- data/lib/clerk/models/components/user.rbi +4 -0
- data/lib/clerk/models/components/user_directory.rb +65 -0
- data/lib/clerk/models/components/user_directory.rbi +27 -0
- data/lib/clerk/models/components/user_scim.rb +27 -6
- data/lib/clerk/models/components/user_scim.rbi +10 -0
- data/lib/clerk/models/components/verification_from_oauth_clerkerror.rb +1 -1
- data/lib/clerk/models/components/verification_google_one_tap_clerkerror.rb +1 -1
- data/lib/clerk/models/components.rb +85 -39
- data/lib/clerk/models/errors/clerkerrors.rb +1 -1
- data/lib/clerk/models/operations/adddomain_request.rb +3 -6
- data/lib/clerk/models/operations/applybillingsubscriptionitemdiscount_request.rb +36 -0
- data/lib/clerk/models/operations/applybillingsubscriptionitemdiscount_request.rbi +15 -0
- data/lib/clerk/models/operations/applybillingsubscriptionitemdiscount_response.rb +44 -0
- data/lib/clerk/models/operations/applybillingsubscriptionitemdiscount_response.rbi +19 -0
- data/lib/clerk/models/operations/clerkidpoauthaccesstoken.rb +5 -1
- data/lib/clerk/models/operations/clerkidpoauthaccesstoken.rbi +2 -0
- data/lib/clerk/models/operations/createdirectory_group_role_mapping.rb +52 -0
- data/lib/clerk/models/operations/createdirectory_group_role_mapping.rbi +23 -0
- data/lib/clerk/models/operations/createdirectory_request.rb +44 -0
- data/lib/clerk/models/operations/createdirectory_request.rbi +19 -0
- data/lib/clerk/models/operations/createdirectory_response.rb +44 -0
- data/lib/clerk/models/operations/createdirectory_response.rbi +19 -0
- data/lib/clerk/models/operations/createdirectorygrouprolemapping_request.rb +36 -0
- data/lib/clerk/models/operations/createdirectorygrouprolemapping_request.rbi +15 -0
- data/lib/clerk/models/operations/createdirectorygrouprolemapping_requestbody.rb +46 -0
- data/lib/clerk/models/operations/createdirectorygrouprolemapping_requestbody.rbi +19 -0
- data/lib/clerk/models/operations/createdirectorygrouprolemapping_response.rb +44 -0
- data/lib/clerk/models/operations/createdirectorygrouprolemapping_response.rbi +19 -0
- data/lib/clerk/models/operations/createemailaddress_request.rb +7 -1
- data/lib/clerk/models/operations/createemailaddress_request.rbi +2 -0
- data/lib/clerk/models/operations/createenterpriseconnection_custom_attribute.rb +5 -1
- data/lib/clerk/models/operations/createenterpriseconnection_custom_attribute.rbi +2 -0
- data/lib/clerk/models/operations/createenterpriseconnection_login_hint.rb +36 -0
- data/lib/clerk/models/operations/createenterpriseconnection_login_hint.rbi +15 -0
- data/lib/clerk/models/operations/createenterpriseconnection_mode.rb +21 -0
- data/lib/clerk/models/operations/createenterpriseconnection_mode.rbi +11 -0
- data/lib/clerk/models/operations/createenterpriseconnection_saml.rb +5 -1
- data/lib/clerk/models/operations/createenterpriseconnection_saml.rbi +2 -0
- data/lib/clerk/models/operations/createoauthapplication_request.rb +6 -2
- data/lib/clerk/models/operations/createoauthapplication_request.rbi +2 -0
- data/lib/clerk/models/operations/createorganizationdomain_requestbody.rb +1 -1
- data/lib/clerk/models/operations/createsamlconnection_login_hint_1.rb +36 -0
- data/lib/clerk/models/operations/createsamlconnection_login_hint_1.rbi +15 -0
- data/lib/clerk/models/operations/createsamlconnection_login_hint_2.rb +36 -0
- data/lib/clerk/models/operations/createsamlconnection_login_hint_2.rbi +15 -0
- data/lib/clerk/models/operations/createsamlconnection_mode_1.rb +21 -0
- data/lib/clerk/models/operations/createsamlconnection_mode_1.rbi +11 -0
- data/lib/clerk/models/operations/createsamlconnection_mode_2.rb +21 -0
- data/lib/clerk/models/operations/createsamlconnection_mode_2.rbi +11 -0
- data/lib/clerk/models/operations/createsamlconnection_requestbody_1.rb +5 -1
- data/lib/clerk/models/operations/createsamlconnection_requestbody_1.rbi +2 -0
- data/lib/clerk/models/operations/createsamlconnection_requestbody_2.rb +5 -1
- data/lib/clerk/models/operations/createsamlconnection_requestbody_2.rbi +2 -0
- data/lib/clerk/models/operations/createscimdirectory_group_role_mapping.rb +44 -0
- data/lib/clerk/models/operations/createscimdirectory_group_role_mapping.rbi +19 -0
- data/lib/clerk/models/operations/createscimdirectory_request.rb +44 -0
- data/lib/clerk/models/operations/createscimdirectory_request.rbi +19 -0
- data/lib/clerk/models/operations/createscimdirectory_response.rb +44 -0
- data/lib/clerk/models/operations/createscimdirectory_response.rbi +19 -0
- data/lib/clerk/models/operations/createscimgrouprolemapping_request.rb +36 -0
- data/lib/clerk/models/operations/createscimgrouprolemapping_request.rbi +15 -0
- data/lib/clerk/models/operations/createscimgrouprolemapping_requestbody.rb +42 -0
- data/lib/clerk/models/operations/createscimgrouprolemapping_requestbody.rbi +17 -0
- data/lib/clerk/models/operations/createscimgrouprolemapping_response.rb +44 -0
- data/lib/clerk/models/operations/createscimgrouprolemapping_response.rbi +19 -0
- data/lib/clerk/models/operations/createsignintoken_request.rb +6 -1
- data/lib/clerk/models/operations/createsignintoken_request.rbi +2 -0
- data/lib/clerk/models/operations/createuser_request.rb +8 -2
- data/lib/clerk/models/operations/createuser_request.rbi +2 -0
- data/lib/clerk/models/operations/deletedirectory_request.rb +32 -0
- data/lib/clerk/models/operations/deletedirectory_request.rbi +13 -0
- data/lib/clerk/models/operations/deletedirectory_response.rb +44 -0
- data/lib/clerk/models/operations/deletedirectory_response.rbi +19 -0
- data/lib/clerk/models/operations/deletedirectorygrouprolemapping_request.rb +36 -0
- data/lib/clerk/models/operations/deletedirectorygrouprolemapping_request.rbi +15 -0
- data/lib/clerk/models/operations/deletedirectorygrouprolemapping_response.rb +44 -0
- data/lib/clerk/models/operations/deletedirectorygrouprolemapping_response.rbi +19 -0
- data/lib/clerk/models/operations/deletedomain_request.rb +1 -1
- data/lib/clerk/models/operations/deletescimdirectory_request.rb +32 -0
- data/lib/clerk/models/operations/deletescimdirectory_request.rbi +13 -0
- data/lib/clerk/models/operations/deletescimdirectory_response.rb +44 -0
- data/lib/clerk/models/operations/deletescimdirectory_response.rbi +19 -0
- data/lib/clerk/models/operations/deletescimgrouprolemapping_request.rb +36 -0
- data/lib/clerk/models/operations/deletescimgrouprolemapping_request.rbi +15 -0
- data/lib/clerk/models/operations/deletescimgrouprolemapping_response.rb +44 -0
- data/lib/clerk/models/operations/deletescimgrouprolemapping_response.rbi +19 -0
- data/lib/clerk/models/operations/enrollment_mode.rb +5 -0
- data/lib/clerk/models/operations/extendbillingsubscriptionitemfreetrial_response.rb +4 -4
- data/lib/clerk/models/operations/extendbillingsubscriptionitemfreetrial_response.rbi +2 -2
- data/lib/clerk/models/operations/getdirectory_request.rb +32 -0
- data/lib/clerk/models/operations/getdirectory_request.rbi +13 -0
- data/lib/clerk/models/operations/getdirectory_response.rb +44 -0
- data/lib/clerk/models/operations/getdirectory_response.rbi +19 -0
- data/lib/clerk/models/operations/getreverification_request.rb +36 -0
- data/lib/clerk/models/operations/getreverification_request.rbi +15 -0
- data/lib/clerk/models/operations/getreverification_response.rb +44 -0
- data/lib/clerk/models/operations/getreverification_response.rbi +19 -0
- data/lib/clerk/models/operations/getscimdirectory_request.rb +32 -0
- data/lib/clerk/models/operations/getscimdirectory_request.rbi +13 -0
- data/lib/clerk/models/operations/getscimdirectory_response.rb +44 -0
- data/lib/clerk/models/operations/getscimdirectory_response.rbi +19 -0
- data/lib/clerk/models/operations/getuserlist_request.rb +13 -1
- data/lib/clerk/models/operations/getuserlist_request.rbi +2 -0
- data/lib/clerk/models/operations/listallorganizationdomains_request.rb +2 -1
- data/lib/clerk/models/operations/listdirectories_request.rb +39 -0
- data/lib/clerk/models/operations/listdirectories_request.rbi +15 -0
- data/lib/clerk/models/operations/listdirectories_response.rb +44 -0
- data/lib/clerk/models/operations/listdirectories_response.rbi +19 -0
- data/lib/clerk/models/operations/listdirectorygrouprolemappings_request.rb +32 -0
- data/lib/clerk/models/operations/listdirectorygrouprolemappings_request.rbi +13 -0
- data/lib/clerk/models/operations/listdirectorygrouprolemappings_response.rb +44 -0
- data/lib/clerk/models/operations/listdirectorygrouprolemappings_response.rbi +19 -0
- data/lib/clerk/models/operations/listoauthapplications_request.rb +2 -0
- data/lib/clerk/models/operations/listorganizationdomains_request.rb +2 -1
- data/lib/clerk/models/operations/listscimdirectories_request.rb +39 -0
- data/lib/clerk/models/operations/listscimdirectories_request.rbi +15 -0
- data/lib/clerk/models/operations/listscimdirectories_response.rb +44 -0
- data/lib/clerk/models/operations/listscimdirectories_response.rbi +19 -0
- data/lib/clerk/models/operations/listscimgrouprolemappings_request.rb +32 -0
- data/lib/clerk/models/operations/listscimgrouprolemappings_request.rbi +13 -0
- data/lib/clerk/models/operations/listscimgrouprolemappings_response.rb +44 -0
- data/lib/clerk/models/operations/listscimgrouprolemappings_response.rbi +19 -0
- data/lib/clerk/models/operations/listuserbiometriccredentials_request.rb +32 -0
- data/lib/clerk/models/operations/listuserbiometriccredentials_request.rbi +13 -0
- data/lib/clerk/models/operations/listuserbiometriccredentials_response.rb +44 -0
- data/lib/clerk/models/operations/listuserbiometriccredentials_response.rbi +19 -0
- data/lib/clerk/models/operations/listusertrusteddevices_request.rb +32 -0
- data/lib/clerk/models/operations/listusertrusteddevices_request.rbi +13 -0
- data/lib/clerk/models/operations/listusertrusteddevices_response.rb +44 -0
- data/lib/clerk/models/operations/listusertrusteddevices_response.rbi +19 -0
- data/lib/clerk/models/operations/removebillingsubscriptionitemdiscount_request.rb +36 -0
- data/lib/clerk/models/operations/removebillingsubscriptionitemdiscount_request.rbi +15 -0
- data/lib/clerk/models/operations/removebillingsubscriptionitemdiscount_response.rb +44 -0
- data/lib/clerk/models/operations/removebillingsubscriptionitemdiscount_response.rbi +19 -0
- data/lib/clerk/models/operations/removeuserpassword_request.rb +36 -0
- data/lib/clerk/models/operations/removeuserpassword_request.rbi +15 -0
- data/lib/clerk/models/operations/removeuserpassword_requestbody.rb +32 -0
- data/lib/clerk/models/operations/removeuserpassword_requestbody.rbi +13 -0
- data/lib/clerk/models/operations/removeuserpassword_response.rb +44 -0
- data/lib/clerk/models/operations/removeuserpassword_response.rbi +19 -0
- data/lib/clerk/models/operations/replacedirectorygrouprolemappings_mapping.rb +40 -0
- data/lib/clerk/models/operations/replacedirectorygrouprolemappings_mapping.rbi +17 -0
- data/lib/clerk/models/operations/replacedirectorygrouprolemappings_request.rb +36 -0
- data/lib/clerk/models/operations/replacedirectorygrouprolemappings_request.rbi +15 -0
- data/lib/clerk/models/operations/replacedirectorygrouprolemappings_requestbody.rb +32 -0
- data/lib/clerk/models/operations/replacedirectorygrouprolemappings_requestbody.rbi +13 -0
- data/lib/clerk/models/operations/replacedirectorygrouprolemappings_response.rb +44 -0
- data/lib/clerk/models/operations/replacedirectorygrouprolemappings_response.rbi +19 -0
- data/lib/clerk/models/operations/replacescimgrouprolemappings_mapping.rb +36 -0
- data/lib/clerk/models/operations/replacescimgrouprolemappings_mapping.rbi +15 -0
- data/lib/clerk/models/operations/replacescimgrouprolemappings_request.rb +36 -0
- data/lib/clerk/models/operations/replacescimgrouprolemappings_request.rbi +15 -0
- data/lib/clerk/models/operations/replacescimgrouprolemappings_requestbody.rb +32 -0
- data/lib/clerk/models/operations/replacescimgrouprolemappings_requestbody.rbi +13 -0
- data/lib/clerk/models/operations/replacescimgrouprolemappings_response.rb +44 -0
- data/lib/clerk/models/operations/replacescimgrouprolemappings_response.rbi +19 -0
- data/lib/clerk/models/operations/replaceuseremailaddress_identification_status.rb +10 -2
- data/lib/clerk/models/operations/replaceuseremailaddress_requestbody.rb +16 -3
- data/lib/clerk/models/operations/replaceuseremailaddress_requestbody.rbi +2 -0
- data/lib/clerk/models/operations/replaceuserphonenumber_identification_status.rb +10 -2
- data/lib/clerk/models/operations/replaceuserphonenumber_requestbody.rb +9 -2
- data/lib/clerk/models/operations/revokeoauthapplicationtoken_request.rb +36 -0
- data/lib/clerk/models/operations/revokeoauthapplicationtoken_request.rbi +15 -0
- data/lib/clerk/models/operations/revokeoauthapplicationtoken_requestbody.rb +32 -0
- data/lib/clerk/models/operations/revokeoauthapplicationtoken_requestbody.rbi +13 -0
- data/lib/clerk/models/operations/revokeoauthapplicationtoken_response.rb +40 -0
- data/lib/clerk/models/operations/revokeoauthapplicationtoken_response.rbi +17 -0
- data/lib/clerk/models/operations/revokeuserbiometriccredential_request.rb +36 -0
- data/lib/clerk/models/operations/revokeuserbiometriccredential_request.rbi +15 -0
- data/lib/clerk/models/operations/revokeuserbiometriccredential_response.rb +44 -0
- data/lib/clerk/models/operations/revokeuserbiometriccredential_response.rbi +19 -0
- data/lib/clerk/models/operations/revokeusertrusteddevice_request.rb +36 -0
- data/lib/clerk/models/operations/revokeusertrusteddevice_request.rbi +15 -0
- data/lib/clerk/models/operations/revokeusertrusteddevice_response.rb +44 -0
- data/lib/clerk/models/operations/revokeusertrusteddevice_response.rbi +19 -0
- data/lib/clerk/models/operations/rotatedirectoryapikey_request.rb +32 -0
- data/lib/clerk/models/operations/rotatedirectoryapikey_request.rbi +13 -0
- data/lib/clerk/models/operations/rotatedirectoryapikey_response.rb +44 -0
- data/lib/clerk/models/operations/rotatedirectoryapikey_response.rbi +19 -0
- data/lib/clerk/models/operations/rotatescimdirectoryapikey_request.rb +32 -0
- data/lib/clerk/models/operations/rotatescimdirectoryapikey_request.rbi +13 -0
- data/lib/clerk/models/operations/rotatescimdirectoryapikey_response.rb +44 -0
- data/lib/clerk/models/operations/rotatescimdirectoryapikey_response.rbi +19 -0
- data/lib/clerk/models/operations/updatedirectory_request.rb +36 -0
- data/lib/clerk/models/operations/updatedirectory_request.rbi +15 -0
- data/lib/clerk/models/operations/updatedirectory_requestbody.rb +49 -0
- data/lib/clerk/models/operations/updatedirectory_requestbody.rbi +21 -0
- data/lib/clerk/models/operations/updatedirectory_response.rb +44 -0
- data/lib/clerk/models/operations/updatedirectory_response.rbi +19 -0
- data/lib/clerk/models/operations/updateemailaddress_requestbody.rb +7 -1
- data/lib/clerk/models/operations/updateemailaddress_requestbody.rbi +2 -0
- data/lib/clerk/models/operations/updateenterpriseconnection_custom_attribute.rb +5 -1
- data/lib/clerk/models/operations/updateenterpriseconnection_custom_attribute.rbi +2 -0
- data/lib/clerk/models/operations/updateenterpriseconnection_login_hint.rb +36 -0
- data/lib/clerk/models/operations/updateenterpriseconnection_login_hint.rbi +15 -0
- data/lib/clerk/models/operations/updateenterpriseconnection_mode.rb +21 -0
- data/lib/clerk/models/operations/updateenterpriseconnection_mode.rbi +11 -0
- data/lib/clerk/models/operations/updateenterpriseconnection_saml.rb +5 -1
- data/lib/clerk/models/operations/updateenterpriseconnection_saml.rbi +2 -0
- data/lib/clerk/models/operations/updateinstance_request.rb +15 -5
- data/lib/clerk/models/operations/updateinstance_request.rbi +6 -2
- data/lib/clerk/models/operations/updateinstanceoauthapplicationsettings_request.rb +26 -1
- data/lib/clerk/models/operations/updateinstanceoauthapplicationsettings_request.rbi +12 -0
- data/lib/clerk/models/operations/updateinstanceprotect_request.rb +1 -1
- data/lib/clerk/models/operations/updateoauthapplication_requestbody.rb +9 -5
- data/lib/clerk/models/operations/updateoauthapplication_requestbody.rbi +4 -2
- data/lib/clerk/models/operations/updateorganization_requestbody.rb +6 -1
- data/lib/clerk/models/operations/updateorganization_requestbody.rbi +2 -0
- data/lib/clerk/models/operations/updateorganizationdomain_requestbody.rb +1 -1
- data/lib/clerk/models/operations/updatesamlconnection_login_hint.rb +36 -0
- data/lib/clerk/models/operations/updatesamlconnection_login_hint.rbi +15 -0
- data/lib/clerk/models/operations/updatesamlconnection_mode.rb +21 -0
- data/lib/clerk/models/operations/updatesamlconnection_mode.rbi +11 -0
- data/lib/clerk/models/operations/updatesamlconnection_requestbody.rb +5 -1
- data/lib/clerk/models/operations/updatesamlconnection_requestbody.rbi +2 -0
- data/lib/clerk/models/operations/updatescimdirectory_request.rb +36 -0
- data/lib/clerk/models/operations/updatescimdirectory_request.rbi +15 -0
- data/lib/clerk/models/operations/updatescimdirectory_requestbody.rb +49 -0
- data/lib/clerk/models/operations/updatescimdirectory_requestbody.rbi +21 -0
- data/lib/clerk/models/operations/updatescimdirectory_response.rb +44 -0
- data/lib/clerk/models/operations/updatescimdirectory_response.rbi +19 -0
- data/lib/clerk/models/operations/updateuser_requestbody.rb +1 -1
- data/lib/clerk/models/operations.rb +80 -0
- data/lib/clerk/oauthaccesstokens.rb +5 -5
- data/lib/clerk/oauthapplications.rb +185 -35
- data/lib/clerk/openapiclient.rb +3 -1
- data/lib/clerk/organizationdomains.rb +32 -32
- data/lib/clerk/organizationinvitations.rb +35 -35
- data/lib/clerk/organizationmemberships.rb +25 -25
- data/lib/clerk/organizationpermissions.rb +25 -25
- data/lib/clerk/organizationroles.rb +35 -35
- data/lib/clerk/organizations.rb +60 -60
- data/lib/clerk/phonenumbers.rb +53 -38
- data/lib/clerk/proxy.rb +3 -3
- data/lib/clerk/proxychecks.rb +5 -5
- data/lib/clerk/redirecturls.rb +20 -20
- data/lib/clerk/rolesets.rb +35 -35
- data/lib/clerk/samlconnections.rb +25 -25
- data/lib/clerk/scimdirectories.rb +1534 -0
- data/lib/clerk/sdk.rb +44 -6
- data/lib/clerk/sdkconfiguration.rb +3 -3
- data/lib/clerk/sessions.rb +181 -35
- data/lib/clerk/signintokens.rb +11 -11
- data/lib/clerk/signups.rb +10 -10
- data/lib/clerk/templates.rb +5 -5
- data/lib/clerk/testingtokens.rb +5 -5
- data/lib/clerk/users.rb +1045 -223
- data/lib/clerk/utils/retries.rb +43 -1
- data/lib/clerk/utils/utils.rb +6 -2
- data/lib/clerk/waitlistentries.rb +30 -30
- data/lib/clerk/webhooks.rb +15 -15
- data/lib/clerk_sdk_ruby.rb +2 -0
- data/test/clerk/jwks_cache_scoping_test.rb +83 -0
- data/test/clerk/org_permissions_v2_test.rb +130 -0
- data/test/clerk/proxy_test.rb +108 -0
- metadata +339 -82
- data/lib/clerk/models/components/clerkerror_meta.rb +0 -27
- data/lib/clerk/models/components/clerkerrors_meta.rb +0 -27
- data/lib/clerk/models/components/emailaddress_verification_saml_meta.rb +0 -27
- data/lib/clerk/models/components/emailaddress_verification_saml_meta.rbi +0 -11
- data/lib/clerk/models/components/enterpriseaccount_verification_oauth_meta.rb +0 -27
- data/lib/clerk/models/components/enterpriseaccount_verification_oauth_meta.rbi +0 -11
- data/lib/clerk/models/components/enterpriseaccount_verification_saml_meta.rb +0 -27
- data/lib/clerk/models/components/enterpriseaccount_verification_saml_meta.rbi +0 -11
- data/lib/clerk/models/components/externalaccountwithverification_verification_oauth_meta.rb +0 -27
- data/lib/clerk/models/components/externalaccountwithverification_verification_oauth_meta.rbi +0 -11
- data/lib/clerk/models/components/samlaccount_meta.rb +0 -27
- data/lib/clerk/models/components/schemas_commerceplan_object.rbi +0 -11
- data/lib/clerk/models/components/schemas_commercesubscriptionitem_annual_fee.rbi +0 -19
- data/lib/clerk/models/components/schemas_commercesubscriptionitem_annual_monthly_fee.rb +0 -44
- data/lib/clerk/models/components/schemas_commercesubscriptionitem_annual_monthly_fee.rbi +0 -19
- data/lib/clerk/models/components/schemas_commercesubscriptionitem_next_payment_amount.rbi +0 -19
- data/lib/clerk/models/components/schemas_commercesubscriptionitem_object_commercepayer.rbi +0 -11
- data/lib/clerk/models/components/schemas_commercesubscriptionitem_object_commerceplan.rbi +0 -11
- data/lib/clerk/models/components/schemas_commercesubscriptionitem_object_commercesubscriptionitem.rbi +0 -11
- data/lib/clerk/models/components/schemas_commercesubscriptionitem_plan_period.rbi +0 -11
- data/lib/clerk/models/components/schemas_commercesubscriptionitem_status.rbi +0 -11
- data/lib/clerk/models/components/schemas_featureresponse_object.rbi +0 -11
- data/lib/clerk/models/components/verification_from_oauth_meta.rb +0 -27
- data/lib/clerk/models/components/verification_from_oauth_meta.rbi +0 -11
- data/lib/clerk/models/components/verification_google_one_tap_meta.rb +0 -27
- data/lib/clerk/models/components/verification_google_one_tap_meta.rbi +0 -11
data/lib/clerk/domains.rb
CHANGED
|
@@ -70,10 +70,10 @@ module Clerk
|
|
|
70
70
|
|
|
71
71
|
timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil?
|
|
72
72
|
timeout ||= @sdk_configuration.timeout
|
|
73
|
-
|
|
73
|
+
|
|
74
74
|
|
|
75
75
|
connection = @sdk_configuration.client.dup
|
|
76
|
-
connection.
|
|
76
|
+
connection.use Utils::RetryMiddleware, retry_options
|
|
77
77
|
|
|
78
78
|
hook_ctx = SDKHooks::HookContext.new(
|
|
79
79
|
config: @sdk_configuration,
|
|
@@ -86,7 +86,7 @@ module Clerk
|
|
|
86
86
|
error = nil
|
|
87
87
|
http_response = nil
|
|
88
88
|
|
|
89
|
-
|
|
89
|
+
|
|
90
90
|
begin
|
|
91
91
|
http_response = connection.get(url) do |req|
|
|
92
92
|
req.headers.merge!(headers)
|
|
@@ -122,13 +122,13 @@ module Clerk
|
|
|
122
122
|
response: http_response
|
|
123
123
|
)
|
|
124
124
|
end
|
|
125
|
-
|
|
125
|
+
|
|
126
126
|
if http_response.nil?
|
|
127
127
|
raise error if !error.nil?
|
|
128
128
|
raise 'no response'
|
|
129
129
|
end
|
|
130
130
|
end
|
|
131
|
-
|
|
131
|
+
|
|
132
132
|
content_type = http_response.headers.fetch('Content-Type', 'application/octet-stream')
|
|
133
133
|
if Utils.match_status_code(http_response.status, ['200'])
|
|
134
134
|
if Utils.match_content_type(content_type, 'application/json')
|
|
@@ -168,7 +168,10 @@ module Clerk
|
|
|
168
168
|
# Add a new domain for your instance.
|
|
169
169
|
# Useful in the case of multi-domain instances, allows adding satellite domains to an instance.
|
|
170
170
|
# The new domain must have a `name`. The domain name can contain the port for development instances, like `localhost:3000`.
|
|
171
|
-
#
|
|
171
|
+
# Set `is_satellite` to `true` to add a satellite domain.
|
|
172
|
+
# To migrate a production instance from an active provider domain to its first custom primary domain,
|
|
173
|
+
# set `is_satellite` to `false`. The custom domain becomes active and the provider domain stays attached.
|
|
174
|
+
# Additional custom primary domains are not supported.
|
|
172
175
|
# If you're planning to configure the new satellite domain to run behind a proxy, pass the `proxy_url` parameter accordingly.
|
|
173
176
|
url, params = @sdk_configuration.get_server_details
|
|
174
177
|
base_url = Utils.template_url(url, params)
|
|
@@ -205,10 +208,10 @@ module Clerk
|
|
|
205
208
|
|
|
206
209
|
timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil?
|
|
207
210
|
timeout ||= @sdk_configuration.timeout
|
|
208
|
-
|
|
211
|
+
|
|
209
212
|
|
|
210
213
|
connection = @sdk_configuration.client.dup
|
|
211
|
-
connection.
|
|
214
|
+
connection.use Utils::RetryMiddleware, retry_options
|
|
212
215
|
|
|
213
216
|
hook_ctx = SDKHooks::HookContext.new(
|
|
214
217
|
config: @sdk_configuration,
|
|
@@ -221,7 +224,7 @@ module Clerk
|
|
|
221
224
|
error = nil
|
|
222
225
|
http_response = nil
|
|
223
226
|
|
|
224
|
-
|
|
227
|
+
|
|
225
228
|
begin
|
|
226
229
|
http_response = connection.post(url) do |req|
|
|
227
230
|
req.body = body
|
|
@@ -258,13 +261,13 @@ module Clerk
|
|
|
258
261
|
response: http_response
|
|
259
262
|
)
|
|
260
263
|
end
|
|
261
|
-
|
|
264
|
+
|
|
262
265
|
if http_response.nil?
|
|
263
266
|
raise error if !error.nil?
|
|
264
267
|
raise 'no response'
|
|
265
268
|
end
|
|
266
269
|
end
|
|
267
|
-
|
|
270
|
+
|
|
268
271
|
content_type = http_response.headers.fetch('Content-Type', 'application/octet-stream')
|
|
269
272
|
if Utils.match_status_code(http_response.status, ['200'])
|
|
270
273
|
if Utils.match_content_type(content_type, 'application/json')
|
|
@@ -315,9 +318,9 @@ module Clerk
|
|
|
315
318
|
|
|
316
319
|
|
|
317
320
|
def delete(domain_id:, retries: nil, timeout_ms: nil, http_headers: nil)
|
|
318
|
-
# delete - Delete a
|
|
319
|
-
# Deletes a
|
|
320
|
-
#
|
|
321
|
+
# delete - Delete a domain
|
|
322
|
+
# Deletes a domain for the instance.
|
|
323
|
+
# The instance's active domain cannot be deleted.
|
|
321
324
|
request = Models::Operations::DeleteDomainRequest.new(
|
|
322
325
|
domain_id: domain_id
|
|
323
326
|
)
|
|
@@ -351,10 +354,10 @@ module Clerk
|
|
|
351
354
|
|
|
352
355
|
timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil?
|
|
353
356
|
timeout ||= @sdk_configuration.timeout
|
|
354
|
-
|
|
357
|
+
|
|
355
358
|
|
|
356
359
|
connection = @sdk_configuration.client.dup
|
|
357
|
-
connection.
|
|
360
|
+
connection.use Utils::RetryMiddleware, retry_options
|
|
358
361
|
|
|
359
362
|
hook_ctx = SDKHooks::HookContext.new(
|
|
360
363
|
config: @sdk_configuration,
|
|
@@ -367,7 +370,7 @@ module Clerk
|
|
|
367
370
|
error = nil
|
|
368
371
|
http_response = nil
|
|
369
372
|
|
|
370
|
-
|
|
373
|
+
|
|
371
374
|
begin
|
|
372
375
|
http_response = connection.delete(url) do |req|
|
|
373
376
|
req.headers.merge!(headers)
|
|
@@ -403,13 +406,13 @@ module Clerk
|
|
|
403
406
|
response: http_response
|
|
404
407
|
)
|
|
405
408
|
end
|
|
406
|
-
|
|
409
|
+
|
|
407
410
|
if http_response.nil?
|
|
408
411
|
raise error if !error.nil?
|
|
409
412
|
raise 'no response'
|
|
410
413
|
end
|
|
411
414
|
end
|
|
412
|
-
|
|
415
|
+
|
|
413
416
|
content_type = http_response.headers.fetch('Content-Type', 'application/octet-stream')
|
|
414
417
|
if Utils.match_status_code(http_response.status, ['200'])
|
|
415
418
|
if Utils.match_content_type(content_type, 'application/json')
|
|
@@ -514,10 +517,10 @@ module Clerk
|
|
|
514
517
|
|
|
515
518
|
timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil?
|
|
516
519
|
timeout ||= @sdk_configuration.timeout
|
|
517
|
-
|
|
520
|
+
|
|
518
521
|
|
|
519
522
|
connection = @sdk_configuration.client.dup
|
|
520
|
-
connection.
|
|
523
|
+
connection.use Utils::RetryMiddleware, retry_options
|
|
521
524
|
|
|
522
525
|
hook_ctx = SDKHooks::HookContext.new(
|
|
523
526
|
config: @sdk_configuration,
|
|
@@ -530,7 +533,7 @@ module Clerk
|
|
|
530
533
|
error = nil
|
|
531
534
|
http_response = nil
|
|
532
535
|
|
|
533
|
-
|
|
536
|
+
|
|
534
537
|
begin
|
|
535
538
|
http_response = connection.patch(url) do |req|
|
|
536
539
|
req.body = body
|
|
@@ -567,13 +570,13 @@ module Clerk
|
|
|
567
570
|
response: http_response
|
|
568
571
|
)
|
|
569
572
|
end
|
|
570
|
-
|
|
573
|
+
|
|
571
574
|
if http_response.nil?
|
|
572
575
|
raise error if !error.nil?
|
|
573
576
|
raise 'no response'
|
|
574
577
|
end
|
|
575
578
|
end
|
|
576
|
-
|
|
579
|
+
|
|
577
580
|
content_type = http_response.headers.fetch('Content-Type', 'application/octet-stream')
|
|
578
581
|
if Utils.match_status_code(http_response.status, ['200'])
|
|
579
582
|
if Utils.match_content_type(content_type, 'application/json')
|
data/lib/clerk/emailaddresses.rb
CHANGED
|
@@ -79,10 +79,10 @@ module Clerk
|
|
|
79
79
|
|
|
80
80
|
timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil?
|
|
81
81
|
timeout ||= @sdk_configuration.timeout
|
|
82
|
-
|
|
82
|
+
|
|
83
83
|
|
|
84
84
|
connection = @sdk_configuration.client.dup
|
|
85
|
-
connection.
|
|
85
|
+
connection.use Utils::RetryMiddleware, retry_options
|
|
86
86
|
|
|
87
87
|
hook_ctx = SDKHooks::HookContext.new(
|
|
88
88
|
config: @sdk_configuration,
|
|
@@ -95,7 +95,7 @@ module Clerk
|
|
|
95
95
|
error = nil
|
|
96
96
|
http_response = nil
|
|
97
97
|
|
|
98
|
-
|
|
98
|
+
|
|
99
99
|
begin
|
|
100
100
|
http_response = connection.post(url) do |req|
|
|
101
101
|
req.body = body
|
|
@@ -132,13 +132,13 @@ module Clerk
|
|
|
132
132
|
response: http_response
|
|
133
133
|
)
|
|
134
134
|
end
|
|
135
|
-
|
|
135
|
+
|
|
136
136
|
if http_response.nil?
|
|
137
137
|
raise error if !error.nil?
|
|
138
138
|
raise 'no response'
|
|
139
139
|
end
|
|
140
140
|
end
|
|
141
|
-
|
|
141
|
+
|
|
142
142
|
content_type = http_response.headers.fetch('Content-Type', 'application/octet-stream')
|
|
143
143
|
if Utils.match_status_code(http_response.status, ['200'])
|
|
144
144
|
if Utils.match_content_type(content_type, 'application/json')
|
|
@@ -224,10 +224,10 @@ module Clerk
|
|
|
224
224
|
|
|
225
225
|
timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil?
|
|
226
226
|
timeout ||= @sdk_configuration.timeout
|
|
227
|
-
|
|
227
|
+
|
|
228
228
|
|
|
229
229
|
connection = @sdk_configuration.client.dup
|
|
230
|
-
connection.
|
|
230
|
+
connection.use Utils::RetryMiddleware, retry_options
|
|
231
231
|
|
|
232
232
|
hook_ctx = SDKHooks::HookContext.new(
|
|
233
233
|
config: @sdk_configuration,
|
|
@@ -240,7 +240,7 @@ module Clerk
|
|
|
240
240
|
error = nil
|
|
241
241
|
http_response = nil
|
|
242
242
|
|
|
243
|
-
|
|
243
|
+
|
|
244
244
|
begin
|
|
245
245
|
http_response = connection.get(url) do |req|
|
|
246
246
|
req.headers.merge!(headers)
|
|
@@ -276,13 +276,13 @@ module Clerk
|
|
|
276
276
|
response: http_response
|
|
277
277
|
)
|
|
278
278
|
end
|
|
279
|
-
|
|
279
|
+
|
|
280
280
|
if http_response.nil?
|
|
281
281
|
raise error if !error.nil?
|
|
282
282
|
raise 'no response'
|
|
283
283
|
end
|
|
284
284
|
end
|
|
285
|
-
|
|
285
|
+
|
|
286
286
|
content_type = http_response.headers.fetch('Content-Type', 'application/octet-stream')
|
|
287
287
|
if Utils.match_status_code(http_response.status, ['200'])
|
|
288
288
|
if Utils.match_content_type(content_type, 'application/json')
|
|
@@ -368,10 +368,10 @@ module Clerk
|
|
|
368
368
|
|
|
369
369
|
timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil?
|
|
370
370
|
timeout ||= @sdk_configuration.timeout
|
|
371
|
-
|
|
371
|
+
|
|
372
372
|
|
|
373
373
|
connection = @sdk_configuration.client.dup
|
|
374
|
-
connection.
|
|
374
|
+
connection.use Utils::RetryMiddleware, retry_options
|
|
375
375
|
|
|
376
376
|
hook_ctx = SDKHooks::HookContext.new(
|
|
377
377
|
config: @sdk_configuration,
|
|
@@ -384,7 +384,7 @@ module Clerk
|
|
|
384
384
|
error = nil
|
|
385
385
|
http_response = nil
|
|
386
386
|
|
|
387
|
-
|
|
387
|
+
|
|
388
388
|
begin
|
|
389
389
|
http_response = connection.delete(url) do |req|
|
|
390
390
|
req.headers.merge!(headers)
|
|
@@ -420,13 +420,13 @@ module Clerk
|
|
|
420
420
|
response: http_response
|
|
421
421
|
)
|
|
422
422
|
end
|
|
423
|
-
|
|
423
|
+
|
|
424
424
|
if http_response.nil?
|
|
425
425
|
raise error if !error.nil?
|
|
426
426
|
raise 'no response'
|
|
427
427
|
end
|
|
428
428
|
end
|
|
429
|
-
|
|
429
|
+
|
|
430
430
|
content_type = http_response.headers.fetch('Content-Type', 'application/octet-stream')
|
|
431
431
|
if Utils.match_status_code(http_response.status, ['200'])
|
|
432
432
|
if Utils.match_content_type(content_type, 'application/json')
|
|
@@ -523,10 +523,10 @@ module Clerk
|
|
|
523
523
|
|
|
524
524
|
timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil?
|
|
525
525
|
timeout ||= @sdk_configuration.timeout
|
|
526
|
-
|
|
526
|
+
|
|
527
527
|
|
|
528
528
|
connection = @sdk_configuration.client.dup
|
|
529
|
-
connection.
|
|
529
|
+
connection.use Utils::RetryMiddleware, retry_options
|
|
530
530
|
|
|
531
531
|
hook_ctx = SDKHooks::HookContext.new(
|
|
532
532
|
config: @sdk_configuration,
|
|
@@ -539,7 +539,7 @@ module Clerk
|
|
|
539
539
|
error = nil
|
|
540
540
|
http_response = nil
|
|
541
541
|
|
|
542
|
-
|
|
542
|
+
|
|
543
543
|
begin
|
|
544
544
|
http_response = connection.patch(url) do |req|
|
|
545
545
|
req.body = body
|
|
@@ -576,13 +576,13 @@ module Clerk
|
|
|
576
576
|
response: http_response
|
|
577
577
|
)
|
|
578
578
|
end
|
|
579
|
-
|
|
579
|
+
|
|
580
580
|
if http_response.nil?
|
|
581
581
|
raise error if !error.nil?
|
|
582
582
|
raise 'no response'
|
|
583
583
|
end
|
|
584
584
|
end
|
|
585
|
-
|
|
585
|
+
|
|
586
586
|
content_type = http_response.headers.fetch('Content-Type', 'application/octet-stream')
|
|
587
587
|
if Utils.match_status_code(http_response.status, ['200'])
|
|
588
588
|
if Utils.match_content_type(content_type, 'application/json')
|
|
@@ -671,10 +671,10 @@ module Clerk
|
|
|
671
671
|
|
|
672
672
|
timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil?
|
|
673
673
|
timeout ||= @sdk_configuration.timeout
|
|
674
|
-
|
|
674
|
+
|
|
675
675
|
|
|
676
676
|
connection = @sdk_configuration.client.dup
|
|
677
|
-
connection.
|
|
677
|
+
connection.use Utils::RetryMiddleware, retry_options
|
|
678
678
|
|
|
679
679
|
hook_ctx = SDKHooks::HookContext.new(
|
|
680
680
|
config: @sdk_configuration,
|
|
@@ -687,7 +687,7 @@ module Clerk
|
|
|
687
687
|
error = nil
|
|
688
688
|
http_response = nil
|
|
689
689
|
|
|
690
|
-
|
|
690
|
+
|
|
691
691
|
begin
|
|
692
692
|
http_response = connection.post(url) do |req|
|
|
693
693
|
req.headers.merge!(headers)
|
|
@@ -723,13 +723,13 @@ module Clerk
|
|
|
723
723
|
response: http_response
|
|
724
724
|
)
|
|
725
725
|
end
|
|
726
|
-
|
|
726
|
+
|
|
727
727
|
if http_response.nil?
|
|
728
728
|
raise error if !error.nil?
|
|
729
729
|
raise 'no response'
|
|
730
730
|
end
|
|
731
731
|
end
|
|
732
|
-
|
|
732
|
+
|
|
733
733
|
content_type = http_response.headers.fetch('Content-Type', 'application/octet-stream')
|
|
734
734
|
if Utils.match_status_code(http_response.status, ['200'])
|
|
735
735
|
if Utils.match_content_type(content_type, 'application/json')
|
|
@@ -852,10 +852,10 @@ module Clerk
|
|
|
852
852
|
|
|
853
853
|
timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil?
|
|
854
854
|
timeout ||= @sdk_configuration.timeout
|
|
855
|
-
|
|
855
|
+
|
|
856
856
|
|
|
857
857
|
connection = @sdk_configuration.client.dup
|
|
858
|
-
connection.
|
|
858
|
+
connection.use Utils::RetryMiddleware, retry_options
|
|
859
859
|
|
|
860
860
|
hook_ctx = SDKHooks::HookContext.new(
|
|
861
861
|
config: @sdk_configuration,
|
|
@@ -868,7 +868,7 @@ module Clerk
|
|
|
868
868
|
error = nil
|
|
869
869
|
http_response = nil
|
|
870
870
|
|
|
871
|
-
|
|
871
|
+
|
|
872
872
|
begin
|
|
873
873
|
http_response = connection.post(url) do |req|
|
|
874
874
|
req.body = body
|
|
@@ -905,13 +905,13 @@ module Clerk
|
|
|
905
905
|
response: http_response
|
|
906
906
|
)
|
|
907
907
|
end
|
|
908
|
-
|
|
908
|
+
|
|
909
909
|
if http_response.nil?
|
|
910
910
|
raise error if !error.nil?
|
|
911
911
|
raise 'no response'
|
|
912
912
|
end
|
|
913
913
|
end
|
|
914
|
-
|
|
914
|
+
|
|
915
915
|
content_type = http_response.headers.fetch('Content-Type', 'application/octet-stream')
|
|
916
916
|
if Utils.match_status_code(http_response.status, ['200'])
|
|
917
917
|
if Utils.match_content_type(content_type, 'application/json')
|
|
@@ -981,9 +981,16 @@ module Clerk
|
|
|
981
981
|
# Replaces all of the user's email addresses with a single primary email address.
|
|
982
982
|
# By default the new email address is created verified, with the admin verification strategy.
|
|
983
983
|
# When `identification_status` is `reserved` it is created reserved instead: unverified but usable
|
|
984
|
-
# for sign-in and locked so no other user can claim it.
|
|
984
|
+
# for sign-in and locked so no other user can claim it. When it is `unverified` the address is
|
|
985
|
+
# neither usable for sign-in nor locked. Any existing email addresses are deleted.
|
|
985
986
|
# If an existing email address is linked to a connected account, the request is rejected; remove
|
|
986
987
|
# the connected account first.
|
|
988
|
+
#
|
|
989
|
+
# **Warning:** `identification_status: unverified` can lock the user out of their account. An
|
|
990
|
+
# unverified email address cannot be used to sign in, so if the user has no other verified or
|
|
991
|
+
# reserved identifier, deleting their existing email addresses leaves them unable to
|
|
992
|
+
# authenticate — and unable to verify the new address, since that requires signing in. Recovery
|
|
993
|
+
# then requires another admin API call.
|
|
987
994
|
request = Models::Operations::ReplaceUserEmailAddressRequest.new(
|
|
988
995
|
user_id: user_id,
|
|
989
996
|
body: body
|
|
@@ -1029,10 +1036,10 @@ module Clerk
|
|
|
1029
1036
|
|
|
1030
1037
|
timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil?
|
|
1031
1038
|
timeout ||= @sdk_configuration.timeout
|
|
1032
|
-
|
|
1039
|
+
|
|
1033
1040
|
|
|
1034
1041
|
connection = @sdk_configuration.client.dup
|
|
1035
|
-
connection.
|
|
1042
|
+
connection.use Utils::RetryMiddleware, retry_options
|
|
1036
1043
|
|
|
1037
1044
|
hook_ctx = SDKHooks::HookContext.new(
|
|
1038
1045
|
config: @sdk_configuration,
|
|
@@ -1045,7 +1052,7 @@ module Clerk
|
|
|
1045
1052
|
error = nil
|
|
1046
1053
|
http_response = nil
|
|
1047
1054
|
|
|
1048
|
-
|
|
1055
|
+
|
|
1049
1056
|
begin
|
|
1050
1057
|
http_response = connection.put(url) do |req|
|
|
1051
1058
|
req.body = body
|
|
@@ -1082,13 +1089,13 @@ module Clerk
|
|
|
1082
1089
|
response: http_response
|
|
1083
1090
|
)
|
|
1084
1091
|
end
|
|
1085
|
-
|
|
1092
|
+
|
|
1086
1093
|
if http_response.nil?
|
|
1087
1094
|
raise error if !error.nil?
|
|
1088
1095
|
raise 'no response'
|
|
1089
1096
|
end
|
|
1090
1097
|
end
|
|
1091
|
-
|
|
1098
|
+
|
|
1092
1099
|
content_type = http_response.headers.fetch('Content-Type', 'application/octet-stream')
|
|
1093
1100
|
if Utils.match_status_code(http_response.status, ['200'])
|
|
1094
1101
|
if Utils.match_content_type(content_type, 'application/json')
|
|
@@ -91,10 +91,10 @@ module Clerk
|
|
|
91
91
|
|
|
92
92
|
timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil?
|
|
93
93
|
timeout ||= @sdk_configuration.timeout
|
|
94
|
-
|
|
94
|
+
|
|
95
95
|
|
|
96
96
|
connection = @sdk_configuration.client.dup
|
|
97
|
-
connection.
|
|
97
|
+
connection.use Utils::RetryMiddleware, retry_options
|
|
98
98
|
|
|
99
99
|
hook_ctx = SDKHooks::HookContext.new(
|
|
100
100
|
config: @sdk_configuration,
|
|
@@ -107,7 +107,7 @@ module Clerk
|
|
|
107
107
|
error = nil
|
|
108
108
|
http_response = nil
|
|
109
109
|
|
|
110
|
-
|
|
110
|
+
|
|
111
111
|
begin
|
|
112
112
|
http_response = connection.put(url) do |req|
|
|
113
113
|
req.body = body
|
|
@@ -144,13 +144,13 @@ module Clerk
|
|
|
144
144
|
response: http_response
|
|
145
145
|
)
|
|
146
146
|
end
|
|
147
|
-
|
|
147
|
+
|
|
148
148
|
if http_response.nil?
|
|
149
149
|
raise error if !error.nil?
|
|
150
150
|
raise 'no response'
|
|
151
151
|
end
|
|
152
152
|
end
|
|
153
|
-
|
|
153
|
+
|
|
154
154
|
content_type = http_response.headers.fetch('Content-Type', 'application/octet-stream')
|
|
155
155
|
if Utils.match_status_code(http_response.status, ['200'])
|
|
156
156
|
if Utils.match_content_type(content_type, 'application/json')
|
|
@@ -173,7 +173,7 @@ module Clerk
|
|
|
173
173
|
else
|
|
174
174
|
raise ::Clerk::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received'
|
|
175
175
|
end
|
|
176
|
-
elsif Utils.match_status_code(http_response.status, ['400', '401', '402', '403', '404', '422'])
|
|
176
|
+
elsif Utils.match_status_code(http_response.status, ['400', '401', '402', '403', '404', '422', '423', '429'])
|
|
177
177
|
if Utils.match_content_type(content_type, 'application/json')
|
|
178
178
|
http_response = @sdk_configuration.hooks.after_success(
|
|
179
179
|
hook_ctx: SDKHooks::AfterSuccessHookContext.new(
|
|
@@ -84,10 +84,10 @@ module Clerk
|
|
|
84
84
|
|
|
85
85
|
timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil?
|
|
86
86
|
timeout ||= @sdk_configuration.timeout
|
|
87
|
-
|
|
87
|
+
|
|
88
88
|
|
|
89
89
|
connection = @sdk_configuration.client.dup
|
|
90
|
-
connection.
|
|
90
|
+
connection.use Utils::RetryMiddleware, retry_options
|
|
91
91
|
|
|
92
92
|
hook_ctx = SDKHooks::HookContext.new(
|
|
93
93
|
config: @sdk_configuration,
|
|
@@ -100,7 +100,7 @@ module Clerk
|
|
|
100
100
|
error = nil
|
|
101
101
|
http_response = nil
|
|
102
102
|
|
|
103
|
-
|
|
103
|
+
|
|
104
104
|
begin
|
|
105
105
|
http_response = connection.get(url) do |req|
|
|
106
106
|
req.headers.merge!(headers)
|
|
@@ -137,13 +137,13 @@ module Clerk
|
|
|
137
137
|
response: http_response
|
|
138
138
|
)
|
|
139
139
|
end
|
|
140
|
-
|
|
140
|
+
|
|
141
141
|
if http_response.nil?
|
|
142
142
|
raise error if !error.nil?
|
|
143
143
|
raise 'no response'
|
|
144
144
|
end
|
|
145
145
|
end
|
|
146
|
-
|
|
146
|
+
|
|
147
147
|
content_type = http_response.headers.fetch('Content-Type', 'application/octet-stream')
|
|
148
148
|
if Utils.match_status_code(http_response.status, ['200'])
|
|
149
149
|
if Utils.match_content_type(content_type, 'application/json')
|
|
@@ -232,10 +232,10 @@ module Clerk
|
|
|
232
232
|
|
|
233
233
|
timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil?
|
|
234
234
|
timeout ||= @sdk_configuration.timeout
|
|
235
|
-
|
|
235
|
+
|
|
236
236
|
|
|
237
237
|
connection = @sdk_configuration.client.dup
|
|
238
|
-
connection.
|
|
238
|
+
connection.use Utils::RetryMiddleware, retry_options
|
|
239
239
|
|
|
240
240
|
hook_ctx = SDKHooks::HookContext.new(
|
|
241
241
|
config: @sdk_configuration,
|
|
@@ -248,7 +248,7 @@ module Clerk
|
|
|
248
248
|
error = nil
|
|
249
249
|
http_response = nil
|
|
250
250
|
|
|
251
|
-
|
|
251
|
+
|
|
252
252
|
begin
|
|
253
253
|
http_response = connection.get(url) do |req|
|
|
254
254
|
req.headers.merge!(headers)
|
|
@@ -284,13 +284,13 @@ module Clerk
|
|
|
284
284
|
response: http_response
|
|
285
285
|
)
|
|
286
286
|
end
|
|
287
|
-
|
|
287
|
+
|
|
288
288
|
if http_response.nil?
|
|
289
289
|
raise error if !error.nil?
|
|
290
290
|
raise 'no response'
|
|
291
291
|
end
|
|
292
292
|
end
|
|
293
|
-
|
|
293
|
+
|
|
294
294
|
content_type = http_response.headers.fetch('Content-Type', 'application/octet-stream')
|
|
295
295
|
if Utils.match_status_code(http_response.status, ['200'])
|
|
296
296
|
if Utils.match_content_type(content_type, 'application/json')
|
|
@@ -379,10 +379,10 @@ module Clerk
|
|
|
379
379
|
|
|
380
380
|
timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil?
|
|
381
381
|
timeout ||= @sdk_configuration.timeout
|
|
382
|
-
|
|
382
|
+
|
|
383
383
|
|
|
384
384
|
connection = @sdk_configuration.client.dup
|
|
385
|
-
connection.
|
|
385
|
+
connection.use Utils::RetryMiddleware, retry_options
|
|
386
386
|
|
|
387
387
|
hook_ctx = SDKHooks::HookContext.new(
|
|
388
388
|
config: @sdk_configuration,
|
|
@@ -395,7 +395,7 @@ module Clerk
|
|
|
395
395
|
error = nil
|
|
396
396
|
http_response = nil
|
|
397
397
|
|
|
398
|
-
|
|
398
|
+
|
|
399
399
|
begin
|
|
400
400
|
http_response = connection.post(url) do |req|
|
|
401
401
|
req.headers.merge!(headers)
|
|
@@ -431,13 +431,13 @@ module Clerk
|
|
|
431
431
|
response: http_response
|
|
432
432
|
)
|
|
433
433
|
end
|
|
434
|
-
|
|
434
|
+
|
|
435
435
|
if http_response.nil?
|
|
436
436
|
raise error if !error.nil?
|
|
437
437
|
raise 'no response'
|
|
438
438
|
end
|
|
439
439
|
end
|
|
440
|
-
|
|
440
|
+
|
|
441
441
|
content_type = http_response.headers.fetch('Content-Type', 'application/octet-stream')
|
|
442
442
|
if Utils.match_status_code(http_response.status, ['200'])
|
|
443
443
|
if Utils.match_content_type(content_type, 'application/json')
|
|
@@ -539,10 +539,10 @@ module Clerk
|
|
|
539
539
|
|
|
540
540
|
timeout = (timeout_ms.to_f / 1000) unless timeout_ms.nil?
|
|
541
541
|
timeout ||= @sdk_configuration.timeout
|
|
542
|
-
|
|
542
|
+
|
|
543
543
|
|
|
544
544
|
connection = @sdk_configuration.client.dup
|
|
545
|
-
connection.
|
|
545
|
+
connection.use Utils::RetryMiddleware, retry_options
|
|
546
546
|
|
|
547
547
|
hook_ctx = SDKHooks::HookContext.new(
|
|
548
548
|
config: @sdk_configuration,
|
|
@@ -555,7 +555,7 @@ module Clerk
|
|
|
555
555
|
error = nil
|
|
556
556
|
http_response = nil
|
|
557
557
|
|
|
558
|
-
|
|
558
|
+
|
|
559
559
|
begin
|
|
560
560
|
http_response = connection.post(url) do |req|
|
|
561
561
|
req.body = body
|
|
@@ -592,13 +592,13 @@ module Clerk
|
|
|
592
592
|
response: http_response
|
|
593
593
|
)
|
|
594
594
|
end
|
|
595
|
-
|
|
595
|
+
|
|
596
596
|
if http_response.nil?
|
|
597
597
|
raise error if !error.nil?
|
|
598
598
|
raise 'no response'
|
|
599
599
|
end
|
|
600
600
|
end
|
|
601
|
-
|
|
601
|
+
|
|
602
602
|
content_type = http_response.headers.fetch('Content-Type', 'application/octet-stream')
|
|
603
603
|
if Utils.match_status_code(http_response.status, ['200'])
|
|
604
604
|
if Utils.match_content_type(content_type, 'application/json')
|
|
@@ -621,7 +621,7 @@ module Clerk
|
|
|
621
621
|
else
|
|
622
622
|
raise ::Clerk::Models::Errors::APIError.new(status_code: http_response.status, body: http_response.env.response_body, raw_response: http_response), 'Unknown content type received'
|
|
623
623
|
end
|
|
624
|
-
elsif Utils.match_status_code(http_response.status, ['400', '401', '404'])
|
|
624
|
+
elsif Utils.match_status_code(http_response.status, ['400', '401', '404', '423', '429'])
|
|
625
625
|
if Utils.match_content_type(content_type, 'application/json')
|
|
626
626
|
http_response = @sdk_configuration.hooks.after_success(
|
|
627
627
|
hook_ctx: SDKHooks::AfterSuccessHookContext.new(
|