ibm_cloud_iam 1.0.2 → 2.0.0
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/README.md +548 -36
- data/docs/APIKeysApi.md +714 -0
- data/docs/AccessGroupCount.md +20 -0
- data/docs/AccountBasedMfaEnrollment.md +24 -0
- data/docs/AccountIdpSettings.md +32 -0
- data/docs/AccountLimitsApi.md +173 -0
- data/docs/AccountLoginSettings.md +18 -0
- data/docs/AccountSettingsApi.md +224 -0
- data/docs/AccountSettingsAssignedTemplatesSection.md +46 -0
- data/docs/AccountSettingsEffectiveSection.md +38 -0
- data/docs/AccountSettingsForIdPApi.md +489 -0
- data/docs/AccountSettingsMeta.md +24 -0
- data/docs/AccountSettingsRequest.md +40 -0
- data/docs/AccountSettingsResponse.md +48 -0
- data/docs/AccountSettingsTemplateApi.md +720 -0
- data/docs/AccountSettingsTemplateAssignmentsApi.md +376 -0
- data/docs/AccountSettingsTemplateList.md +30 -0
- data/docs/AccountSettingsTemplateRequest.md +24 -0
- data/docs/AccountSettingsTemplateResponse.md +44 -0
- data/docs/AccountSettingsUserDomainRestriction.md +22 -0
- data/docs/AccountSettingsUserMFAResponse.md +28 -0
- data/docs/ActionControls.md +22 -0
- data/docs/ActionControlsIdentities.md +20 -0
- data/docs/ActivitiesApi.md +149 -0
- data/docs/Activity.md +20 -0
- data/docs/AddAccountIdpSettingRequest.md +22 -0
- data/docs/ApiKey.md +44 -33
- data/docs/ApiKeyInsideCreateServiceIdRequest.md +18 -13
- data/docs/ApiKeyList.md +20 -19
- data/docs/ApikeyActivity.md +28 -0
- data/docs/ApikeyActivityServiceid.md +20 -0
- data/docs/ApikeyActivityUser.md +24 -0
- data/docs/AssignedTemplatesAccountSettings.md +40 -0
- data/docs/CommonAccountSettingsRequest.md +36 -0
- data/docs/CommonAccountSettingsResponse.md +34 -0
- data/docs/ConsumersResponse.md +20 -0
- data/docs/ConsumersResponseConsumersInner.md +20 -0
- data/docs/CreateApiKeyRequest.md +24 -17
- data/docs/CreateIdpRequest.md +30 -0
- data/docs/CreateIdpRequestProperties.md +20 -0
- data/docs/CreateIdpRequestPropertiesIdp.md +26 -0
- data/docs/CreateIdpRequestPropertiesSp.md +32 -0
- data/docs/CreateIdpRequestPropertiesSpAuthnContext.md +20 -0
- data/docs/CreateIdpRequestSecrets.md +20 -0
- data/docs/CreateIdpRequestSecretsIdp.md +22 -0
- data/docs/CreateIdpRequestSecretsIdpSigningInner.md +20 -0
- data/docs/CreateIdpRequestSecretsSp.md +18 -0
- data/docs/CreateIdpRequestSecretsSpSigningInner.md +24 -0
- data/docs/CreateProfileLinkRequest.md +24 -0
- data/docs/CreateProfileLinkRequestLink.md +26 -0
- data/docs/CreateServiceIdGroupRequest.md +22 -0
- data/docs/CreateServiceIdRequest.md +18 -15
- data/docs/CreateTemplateAssignmentRequest.md +24 -0
- data/docs/CreateTrustedProfileRequest.md +24 -0
- data/docs/EffectiveAccountSettingsResponse.md +26 -0
- data/docs/EnityHistoryRecord.md +18 -17
- data/docs/EntityActivity.md +22 -0
- data/docs/Error.md +14 -13
- data/docs/ExceptionResponse.md +14 -13
- data/docs/ExceptionResponseContext.md +30 -29
- data/docs/IDPManagementApi.md +692 -0
- data/docs/IdBasedMfaEnrollment.md +26 -0
- data/docs/IdentityCount.md +20 -0
- data/docs/IdentityLimitsUsageRequest.md +42 -0
- data/docs/IdentityLimitsUsageResponse.md +44 -0
- data/docs/IdentityLimitsUsageResponseApikeysPerIdentity.md +20 -0
- data/docs/IdentityLimitsUsageResponseClaimRulesPerGroup.md +20 -0
- data/docs/IdentityLimitsUsageResponseClaimRulesPerProfile.md +20 -0
- data/docs/IdentityLimitsUsageResponseServiceidsPerGroup.md +20 -0
- data/docs/IdentityLimitsUsageResponseTemplateVersionsPerTemplate.md +20 -0
- data/docs/IdentityPreferenceResponse.md +28 -0
- data/docs/IdentityPreferencesApi.md +304 -0
- data/docs/IdentityPreferencesResponse.md +18 -0
- data/docs/Idp.md +38 -0
- data/docs/LimitCount.md +20 -0
- data/docs/ListIdPSettings200Response.md +18 -0
- data/docs/ListIdps200Response.md +18 -0
- data/docs/MFAEnrollmentStatusApi.md +216 -0
- data/docs/MFARequirementsResponse.md +12 -11
- data/docs/MfaEnrollmentTypeStatus.md +20 -0
- data/docs/MfaOptions.md +15 -0
- data/docs/OidcExceptionResponse.md +16 -15
- data/docs/PolicyTemplateReference.md +20 -0
- data/docs/ProfileClaimRule.md +36 -0
- data/docs/ProfileClaimRuleConditions.md +22 -0
- data/docs/ProfileClaimRuleList.md +20 -0
- data/docs/ProfileClaimRuleRequest.md +30 -0
- data/docs/ProfileCount.md +20 -0
- data/docs/ProfileIdentitiesResponse.md +20 -0
- data/docs/ProfileIdentitiesUpdateRequest.md +18 -0
- data/docs/ProfileIdentityRequest.md +24 -0
- data/docs/ProfileIdentityResponse.md +26 -0
- data/docs/ProfileLink.md +32 -0
- data/docs/ProfileLinkLink.md +26 -0
- data/docs/ProfileLinkList.md +18 -0
- data/docs/Report.md +34 -0
- data/docs/ReportMfaEnrollmentStatus.md +28 -0
- data/docs/ReportReference.md +18 -0
- data/docs/ResponseContext.md +28 -27
- data/docs/RetrictActions.md +15 -0
- data/docs/SamlMetadataImportResponse.md +42 -0
- data/docs/ServiceIDGroupsApi.md +347 -0
- data/docs/ServiceIDsApi.md +515 -0
- data/docs/ServiceId.md +38 -33
- data/docs/ServiceIdGroup.md +34 -0
- data/docs/ServiceIdGroupCount.md +20 -0
- data/docs/ServiceIdGroupList.md +18 -0
- data/docs/ServiceIdList.md +20 -19
- data/docs/ShareScope.md +20 -0
- data/docs/TemplateAccountSettings.md +40 -0
- data/docs/TemplateAccountSettingsAllOfRestrictUserDomains.md +20 -0
- data/docs/TemplateAssignmentListResponse.md +30 -0
- data/docs/TemplateAssignmentResource.md +18 -0
- data/docs/TemplateAssignmentResourceError.md +24 -0
- data/docs/TemplateAssignmentResponse.md +48 -0
- data/docs/TemplateAssignmentResponseResource.md +24 -0
- data/docs/TemplateAssignmentResponseResourceDetail.md +26 -0
- data/docs/TemplateCount.md +20 -0
- data/docs/TemplateProfileComponentRequest.md +26 -0
- data/docs/TemplateProfileComponentResponse.md +26 -0
- data/docs/TestResult.md +28 -0
- data/docs/TestResultStepsInner.md +24 -0
- data/docs/TestTriggerResponse.md +20 -0
- data/docs/TokenResponse.md +18 -17
- data/docs/TokenRetrievalApi.md +461 -0
- data/docs/TrustedProfile.md +50 -0
- data/docs/TrustedProfileTemplateApi.md +720 -0
- data/docs/TrustedProfileTemplateAssignmentsApi.md +376 -0
- data/docs/TrustedProfileTemplateClaimRule.md +26 -0
- data/docs/TrustedProfileTemplateList.md +30 -0
- data/docs/TrustedProfileTemplateRequest.md +28 -0
- data/docs/TrustedProfileTemplateResponse.md +48 -0
- data/docs/TrustedProfilesApi.md +1414 -0
- data/docs/TrustedProfilesList.md +30 -0
- data/docs/UpdateAccountIdpSettingRequest.md +22 -0
- data/docs/UpdateAccountLoginSettings.md +18 -0
- data/docs/UpdateApiKeyRequest.md +16 -9
- data/docs/UpdateIdPRequest.md +28 -0
- data/docs/UpdateIdPRequestProperties.md +20 -0
- data/docs/UpdateIdPRequestPropertiesIdp.md +24 -0
- data/docs/UpdateIdPRequestSecrets.md +20 -0
- data/docs/UpdateIdPRequestSecretsIdp.md +20 -0
- data/docs/UpdatePreferenceRequest.md +20 -0
- data/docs/UpdateServiceIdGroupRequest.md +20 -0
- data/docs/UpdateServiceIdRequest.md +12 -11
- data/docs/UpdateTemplateAssignmentRequest.md +18 -0
- data/docs/UpdateTrustedProfileRequest.md +22 -0
- data/docs/UserActivity.md +26 -0
- data/docs/UserMFAResolved.md +24 -0
- data/docs/UserMfa.md +20 -0
- data/docs/UserMfaEnrollments.md +24 -0
- data/docs/UserReportMfaEnrollmentStatus.md +30 -0
- data/docs/UserVisbilityRetrictActions.md +15 -0
- data/docs/UserVisbilityRetrictActionsForTemplate.md +15 -0
- data/git_push.sh +3 -4
- data/ibm_cloud_iam.gemspec +6 -6
- data/lib/ibm_cloud_iam/api/account_limits_api.rb +208 -0
- data/lib/ibm_cloud_iam/api/account_settings_api.rb +262 -0
- data/lib/ibm_cloud_iam/api/account_settings_for_id_p_api.rb +571 -0
- data/lib/ibm_cloud_iam/api/account_settings_template_api.rb +823 -0
- data/lib/ibm_cloud_iam/api/account_settings_template_assignments_api.rb +422 -0
- data/lib/ibm_cloud_iam/api/activities_api.rb +174 -0
- data/lib/ibm_cloud_iam/api/api_keys_api.rb +786 -0
- data/lib/ibm_cloud_iam/api/identity_preferences_api.rb +357 -0
- data/lib/ibm_cloud_iam/api/idp_management_api.rb +744 -0
- data/lib/ibm_cloud_iam/api/mfa_enrollment_status_api.rb +248 -0
- data/lib/ibm_cloud_iam/api/service_id_groups_api.rb +392 -0
- data/lib/ibm_cloud_iam/api/service_ids_api.rb +575 -0
- data/lib/ibm_cloud_iam/api/token_retrieval_api.rb +557 -0
- data/lib/ibm_cloud_iam/api/trusted_profile_template_api.rb +823 -0
- data/lib/ibm_cloud_iam/api/trusted_profile_template_assignments_api.rb +422 -0
- data/lib/ibm_cloud_iam/api/trusted_profiles_api.rb +1630 -0
- data/lib/ibm_cloud_iam/api_client.rb +74 -65
- data/lib/ibm_cloud_iam/api_error.rb +4 -3
- data/lib/ibm_cloud_iam/api_model_base.rb +88 -0
- data/lib/ibm_cloud_iam/configuration.rb +75 -15
- data/lib/ibm_cloud_iam/models/access_group_count.rb +159 -0
- data/lib/ibm_cloud_iam/models/account_based_mfa_enrollment.rb +243 -0
- data/lib/ibm_cloud_iam/models/account_idp_settings.rb +244 -0
- data/lib/ibm_cloud_iam/models/account_login_settings.rb +147 -0
- data/lib/ibm_cloud_iam/models/account_settings_assigned_templates_section.rb +377 -0
- data/lib/ibm_cloud_iam/models/account_settings_effective_section.rb +282 -0
- data/lib/ibm_cloud_iam/models/account_settings_meta.rb +179 -0
- data/lib/ibm_cloud_iam/models/account_settings_request.rb +301 -0
- data/lib/ibm_cloud_iam/models/account_settings_response.rb +567 -0
- data/lib/ibm_cloud_iam/models/account_settings_template_list.rb +256 -0
- data/lib/ibm_cloud_iam/models/account_settings_template_request.rb +178 -0
- data/lib/ibm_cloud_iam/models/account_settings_template_response.rb +416 -0
- data/lib/ibm_cloud_iam/models/account_settings_user_domain_restriction.rb +188 -0
- data/lib/ibm_cloud_iam/models/account_settings_user_mfa_response.rb +261 -0
- data/lib/ibm_cloud_iam/models/action_controls.rb +199 -0
- data/lib/ibm_cloud_iam/models/action_controls_identities.rb +190 -0
- data/lib/ibm_cloud_iam/models/activity.rb +175 -0
- data/lib/ibm_cloud_iam/models/add_account_idp_setting_request.rb +243 -0
- data/lib/ibm_cloud_iam/models/api_key.rb +188 -104
- data/lib/ibm_cloud_iam/models/api_key_inside_create_service_id_request.rb +70 -99
- data/lib/ibm_cloud_iam/models/api_key_list.rb +46 -95
- data/lib/ibm_cloud_iam/models/apikey_activity.rb +231 -0
- data/lib/ibm_cloud_iam/models/apikey_activity_serviceid.rb +159 -0
- data/lib/ibm_cloud_iam/models/apikey_activity_user.rb +179 -0
- data/lib/ibm_cloud_iam/models/assigned_templates_account_settings.rb +296 -0
- data/lib/ibm_cloud_iam/models/common_account_settings_request.rb +272 -0
- data/lib/ibm_cloud_iam/models/common_account_settings_response.rb +260 -0
- data/lib/ibm_cloud_iam/models/consumers_response.rb +158 -0
- data/lib/ibm_cloud_iam/models/consumers_response_consumers_inner.rb +158 -0
- data/lib/ibm_cloud_iam/models/create_api_key_request.rb +92 -99
- data/lib/ibm_cloud_iam/models/create_idp_request.rb +283 -0
- data/lib/ibm_cloud_iam/models/create_idp_request_properties.rb +157 -0
- data/lib/ibm_cloud_iam/models/create_idp_request_properties_idp.rb +189 -0
- data/lib/ibm_cloud_iam/models/create_idp_request_properties_sp.rb +222 -0
- data/lib/ibm_cloud_iam/models/create_idp_request_properties_sp_authn_context.rb +163 -0
- data/lib/ibm_cloud_iam/models/create_idp_request_secrets.rb +157 -0
- data/lib/ibm_cloud_iam/models/create_idp_request_secrets_idp.rb +173 -0
- data/lib/ibm_cloud_iam/models/create_idp_request_secrets_idp_signing_inner.rb +192 -0
- data/lib/ibm_cloud_iam/models/create_idp_request_secrets_sp.rb +151 -0
- data/lib/ibm_cloud_iam/models/create_idp_request_secrets_sp_signing_inner.rb +212 -0
- data/lib/ibm_cloud_iam/models/create_profile_link_request.rb +211 -0
- data/lib/ibm_cloud_iam/models/create_profile_link_request_link.rb +206 -0
- data/lib/ibm_cloud_iam/models/create_service_id_group_request.rb +203 -0
- data/lib/ibm_cloud_iam/models/create_service_id_request.rb +68 -95
- data/lib/ibm_cloud_iam/models/create_template_assignment_request.rb +280 -0
- data/lib/ibm_cloud_iam/models/create_trusted_profile_request.rb +213 -0
- data/lib/ibm_cloud_iam/models/effective_account_settings_response.rb +239 -0
- data/lib/ibm_cloud_iam/models/enity_history_record.rb +112 -101
- data/lib/ibm_cloud_iam/models/entity_activity.rb +185 -0
- data/lib/ibm_cloud_iam/models/error.rb +69 -94
- data/lib/ibm_cloud_iam/models/exception_response.rb +57 -94
- data/lib/ibm_cloud_iam/models/exception_response_context.rb +33 -94
- data/lib/ibm_cloud_iam/models/id_based_mfa_enrollment.rb +270 -0
- data/lib/ibm_cloud_iam/models/identity_count.rb +159 -0
- data/lib/ibm_cloud_iam/models/identity_limits_usage_request.rb +283 -0
- data/lib/ibm_cloud_iam/models/identity_limits_usage_response.rb +265 -0
- data/lib/ibm_cloud_iam/models/identity_limits_usage_response_apikeys_per_identity.rb +178 -0
- data/lib/ibm_cloud_iam/models/identity_limits_usage_response_claim_rules_per_group.rb +178 -0
- data/lib/ibm_cloud_iam/models/identity_limits_usage_response_claim_rules_per_profile.rb +178 -0
- data/lib/ibm_cloud_iam/models/identity_limits_usage_response_serviceids_per_group.rb +178 -0
- data/lib/ibm_cloud_iam/models/identity_limits_usage_response_template_versions_per_template.rb +178 -0
- data/lib/ibm_cloud_iam/models/identity_preference_response.rb +200 -0
- data/lib/ibm_cloud_iam/models/identity_preferences_response.rb +167 -0
- data/lib/ibm_cloud_iam/models/idp.rb +239 -0
- data/lib/ibm_cloud_iam/models/limit_count.rb +176 -0
- data/lib/ibm_cloud_iam/models/list_id_p_settings200_response.rb +149 -0
- data/lib/ibm_cloud_iam/models/list_idps200_response.rb +149 -0
- data/lib/ibm_cloud_iam/models/mfa_enrollment_type_status.rb +192 -0
- data/lib/ibm_cloud_iam/models/mfa_options.rb +45 -0
- data/lib/ibm_cloud_iam/models/mfa_requirements_response.rb +69 -94
- data/lib/ibm_cloud_iam/models/oidc_exception_response.rb +57 -94
- data/lib/ibm_cloud_iam/models/policy_template_reference.rb +193 -0
- data/lib/ibm_cloud_iam/models/profile_claim_rule.rb +342 -0
- data/lib/ibm_cloud_iam/models/profile_claim_rule_conditions.rb +219 -0
- data/lib/ibm_cloud_iam/models/profile_claim_rule_list.rb +176 -0
- data/lib/ibm_cloud_iam/models/profile_claim_rule_request.rb +243 -0
- data/lib/ibm_cloud_iam/models/profile_count.rb +159 -0
- data/lib/ibm_cloud_iam/models/profile_identities_response.rb +160 -0
- data/lib/ibm_cloud_iam/models/profile_identities_update_request.rb +150 -0
- data/lib/ibm_cloud_iam/models/profile_identity_request.rb +238 -0
- data/lib/ibm_cloud_iam/models/profile_identity_response.rb +265 -0
- data/lib/ibm_cloud_iam/models/profile_link.rb +320 -0
- data/lib/ibm_cloud_iam/models/profile_link_link.rb +188 -0
- data/lib/ibm_cloud_iam/models/profile_link_list.rb +167 -0
- data/lib/ibm_cloud_iam/models/report.rb +321 -0
- data/lib/ibm_cloud_iam/models/report_mfa_enrollment_status.rb +268 -0
- data/lib/ibm_cloud_iam/models/report_reference.rb +165 -0
- data/lib/ibm_cloud_iam/models/response_context.rb +33 -94
- data/lib/ibm_cloud_iam/models/retrict_actions.rb +41 -0
- data/lib/ibm_cloud_iam/models/saml_metadata_import_response.rb +494 -0
- data/lib/ibm_cloud_iam/models/service_id.rb +184 -108
- data/lib/ibm_cloud_iam/models/service_id_group.rb +313 -0
- data/lib/ibm_cloud_iam/models/service_id_group_count.rb +159 -0
- data/lib/ibm_cloud_iam/models/service_id_group_list.rb +167 -0
- data/lib/ibm_cloud_iam/models/service_id_list.rb +47 -96
- data/lib/ibm_cloud_iam/models/share_scope.rb +190 -0
- data/lib/ibm_cloud_iam/models/template_account_settings.rb +296 -0
- data/lib/ibm_cloud_iam/models/template_account_settings_all_of_restrict_user_domains.rb +159 -0
- data/lib/ibm_cloud_iam/models/template_assignment_list_response.rb +227 -0
- data/lib/ibm_cloud_iam/models/template_assignment_resource.rb +149 -0
- data/lib/ibm_cloud_iam/models/template_assignment_resource_error.rb +179 -0
- data/lib/ibm_cloud_iam/models/template_assignment_response.rb +506 -0
- data/lib/ibm_cloud_iam/models/template_assignment_response_resource.rb +196 -0
- data/lib/ibm_cloud_iam/models/template_assignment_response_resource_detail.rb +203 -0
- data/lib/ibm_cloud_iam/models/template_count.rb +159 -0
- data/lib/ibm_cloud_iam/models/template_profile_component_request.rb +210 -0
- data/lib/ibm_cloud_iam/models/template_profile_component_response.rb +210 -0
- data/lib/ibm_cloud_iam/models/test_result.rb +194 -0
- data/lib/ibm_cloud_iam/models/test_result_steps_inner.rb +174 -0
- data/lib/ibm_cloud_iam/models/test_trigger_response.rb +156 -0
- data/lib/ibm_cloud_iam/models/token_response.rb +34 -105
- data/lib/ibm_cloud_iam/models/trusted_profile.rb +411 -0
- data/lib/ibm_cloud_iam/models/trusted_profile_template_claim_rule.rb +248 -0
- data/lib/ibm_cloud_iam/models/trusted_profile_template_list.rb +256 -0
- data/lib/ibm_cloud_iam/models/trusted_profile_template_request.rb +199 -0
- data/lib/ibm_cloud_iam/models/trusted_profile_template_response.rb +369 -0
- data/lib/ibm_cloud_iam/models/trusted_profiles_list.rb +227 -0
- data/lib/ibm_cloud_iam/models/update_account_idp_setting_request.rb +202 -0
- data/lib/ibm_cloud_iam/models/update_account_login_settings.rb +148 -0
- data/lib/ibm_cloud_iam/models/update_api_key_request.rb +68 -99
- data/lib/ibm_cloud_iam/models/update_id_p_request.rb +198 -0
- data/lib/ibm_cloud_iam/models/update_id_p_request_properties.rb +157 -0
- data/lib/ibm_cloud_iam/models/update_id_p_request_properties_idp.rb +179 -0
- data/lib/ibm_cloud_iam/models/update_id_p_request_secrets.rb +157 -0
- data/lib/ibm_cloud_iam/models/update_id_p_request_secrets_idp.rb +163 -0
- data/lib/ibm_cloud_iam/models/update_preference_request.rb +161 -0
- data/lib/ibm_cloud_iam/models/update_service_id_group_request.rb +176 -0
- data/lib/ibm_cloud_iam/models/update_service_id_request.rb +34 -95
- data/lib/ibm_cloud_iam/models/update_template_assignment_request.rb +175 -0
- data/lib/ibm_cloud_iam/models/update_trusted_profile_request.rb +169 -0
- data/lib/ibm_cloud_iam/models/user_activity.rb +222 -0
- data/lib/ibm_cloud_iam/models/user_mfa.rb +179 -0
- data/lib/ibm_cloud_iam/models/user_mfa_enrollments.rb +193 -0
- data/lib/ibm_cloud_iam/models/user_mfa_resolved.rb +178 -0
- data/lib/ibm_cloud_iam/models/user_report_mfa_enrollment_status.rb +291 -0
- data/lib/ibm_cloud_iam/models/user_visbility_retrict_actions.rb +40 -0
- data/lib/ibm_cloud_iam/models/user_visbility_retrict_actions_for_template.rb +41 -0
- data/lib/ibm_cloud_iam/version.rb +4 -4
- data/lib/ibm_cloud_iam.rb +140 -9
- data/spec/api/account_limits_api_spec.rb +75 -0
- data/spec/api/account_settings_api_spec.rb +80 -0
- data/spec/api/account_settings_for_id_p_api_spec.rb +132 -0
- data/spec/api/account_settings_template_api_spec.rb +184 -0
- data/spec/api/account_settings_template_assignments_api_spec.rb +112 -0
- data/spec/api/activities_api_spec.rb +64 -0
- data/spec/api/api_keys_api_spec.rb +182 -0
- data/spec/api/identity_preferences_api_spec.rb +98 -0
- data/spec/api/idp_management_api_spec.rb +166 -0
- data/spec/api/mfa_enrollment_status_api_spec.rb +77 -0
- data/spec/api/service_id_groups_api_spec.rb +102 -0
- data/spec/api/service_ids_api_spec.rb +143 -0
- data/spec/api/token_retrieval_api_spec.rb +134 -0
- data/spec/api/trusted_profile_template_api_spec.rb +184 -0
- data/spec/api/trusted_profile_template_assignments_api_spec.rb +112 -0
- data/spec/api/trusted_profiles_api_spec.rb +328 -0
- data/spec/models/access_group_count_spec.rb +42 -0
- data/spec/models/account_based_mfa_enrollment_spec.rb +54 -0
- data/spec/models/account_idp_settings_spec.rb +82 -0
- data/spec/models/account_login_settings_spec.rb +36 -0
- data/spec/models/account_settings_assigned_templates_section_spec.rb +120 -0
- data/spec/models/account_settings_effective_section_spec.rb +96 -0
- data/spec/models/account_settings_meta_spec.rb +54 -0
- data/spec/models/account_settings_request_spec.rb +102 -0
- data/spec/models/account_settings_response_spec.rb +126 -0
- data/spec/models/account_settings_template_list_spec.rb +72 -0
- data/spec/models/account_settings_template_request_spec.rb +54 -0
- data/spec/models/account_settings_template_response_spec.rb +114 -0
- data/spec/models/account_settings_user_domain_restriction_spec.rb +48 -0
- data/spec/models/account_settings_user_mfa_response_spec.rb +66 -0
- data/spec/models/action_controls_identities_spec.rb +42 -0
- data/spec/models/action_controls_spec.rb +48 -0
- data/spec/models/activity_spec.rb +42 -0
- data/spec/models/add_account_idp_setting_request_spec.rb +52 -0
- data/spec/models/api_key_inside_create_service_id_request_spec.rb +24 -17
- data/spec/models/api_key_list_spec.rb +15 -20
- data/spec/models/api_key_spec.rb +52 -27
- data/spec/models/apikey_activity_serviceid_spec.rb +42 -0
- data/spec/models/apikey_activity_spec.rb +66 -0
- data/spec/models/apikey_activity_user_spec.rb +54 -0
- data/spec/models/assigned_templates_account_settings_spec.rb +102 -0
- data/spec/models/common_account_settings_request_spec.rb +90 -0
- data/spec/models/common_account_settings_response_spec.rb +84 -0
- data/spec/models/consumers_response_consumers_inner_spec.rb +42 -0
- data/spec/models/consumers_response_spec.rb +42 -0
- data/spec/models/create_api_key_request_spec.rb +32 -19
- data/spec/models/create_idp_request_properties_idp_spec.rb +60 -0
- data/spec/models/create_idp_request_properties_sp_authn_context_spec.rb +42 -0
- data/spec/models/create_idp_request_properties_sp_spec.rb +78 -0
- data/spec/models/create_idp_request_properties_spec.rb +42 -0
- data/spec/models/create_idp_request_secrets_idp_signing_inner_spec.rb +46 -0
- data/spec/models/create_idp_request_secrets_idp_spec.rb +48 -0
- data/spec/models/create_idp_request_secrets_sp_signing_inner_spec.rb +58 -0
- data/spec/models/create_idp_request_secrets_sp_spec.rb +36 -0
- data/spec/models/create_idp_request_secrets_spec.rb +42 -0
- data/spec/models/create_idp_request_spec.rb +76 -0
- data/spec/models/create_profile_link_request_link_spec.rb +60 -0
- data/spec/models/create_profile_link_request_spec.rb +54 -0
- data/spec/models/create_service_id_group_request_spec.rb +48 -0
- data/spec/models/create_service_id_request_spec.rb +19 -18
- data/spec/models/create_template_assignment_request_spec.rb +58 -0
- data/spec/models/create_trusted_profile_request_spec.rb +54 -0
- data/spec/models/effective_account_settings_response_spec.rb +60 -0
- data/spec/models/enity_history_record_spec.rb +14 -19
- data/spec/models/entity_activity_spec.rb +48 -0
- data/spec/models/error_spec.rb +12 -17
- data/spec/models/exception_response_context_spec.rb +20 -25
- data/spec/models/exception_response_spec.rb +12 -17
- data/spec/models/id_based_mfa_enrollment_spec.rb +64 -0
- data/spec/models/identity_count_spec.rb +42 -0
- data/spec/models/identity_limits_usage_request_spec.rb +108 -0
- data/spec/models/identity_limits_usage_response_apikeys_per_identity_spec.rb +42 -0
- data/spec/models/identity_limits_usage_response_claim_rules_per_group_spec.rb +42 -0
- data/spec/models/identity_limits_usage_response_claim_rules_per_profile_spec.rb +42 -0
- data/spec/models/identity_limits_usage_response_serviceids_per_group_spec.rb +42 -0
- data/spec/models/identity_limits_usage_response_spec.rb +114 -0
- data/spec/models/identity_limits_usage_response_template_versions_per_template_spec.rb +42 -0
- data/spec/models/identity_preference_response_spec.rb +66 -0
- data/spec/models/identity_preferences_response_spec.rb +36 -0
- data/spec/models/idp_spec.rb +96 -0
- data/spec/models/limit_count_spec.rb +42 -0
- data/spec/models/list_id_p_settings200_response_spec.rb +36 -0
- data/spec/models/list_idps200_response_spec.rb +36 -0
- data/spec/models/mfa_enrollment_type_status_spec.rb +42 -0
- data/spec/models/mfa_options_spec.rb +30 -0
- data/spec/models/mfa_requirements_response_spec.rb +11 -16
- data/spec/models/oidc_exception_response_spec.rb +13 -18
- data/spec/models/policy_template_reference_spec.rb +42 -0
- data/spec/models/profile_claim_rule_conditions_spec.rb +48 -0
- data/spec/models/profile_claim_rule_list_spec.rb +42 -0
- data/spec/models/profile_claim_rule_request_spec.rb +72 -0
- data/spec/models/profile_claim_rule_spec.rb +90 -0
- data/spec/models/profile_count_spec.rb +42 -0
- data/spec/models/profile_identities_response_spec.rb +42 -0
- data/spec/models/profile_identities_update_request_spec.rb +36 -0
- data/spec/models/profile_identity_request_spec.rb +58 -0
- data/spec/models/profile_identity_response_spec.rb +64 -0
- data/spec/models/profile_link_link_spec.rb +60 -0
- data/spec/models/profile_link_list_spec.rb +36 -0
- data/spec/models/profile_link_spec.rb +78 -0
- data/spec/models/report_mfa_enrollment_status_spec.rb +66 -0
- data/spec/models/report_reference_spec.rb +36 -0
- data/spec/models/report_spec.rb +84 -0
- data/spec/models/response_context_spec.rb +19 -24
- data/spec/models/retrict_actions_spec.rb +30 -0
- data/spec/models/saml_metadata_import_response_spec.rb +112 -0
- data/spec/models/service_id_group_count_spec.rb +42 -0
- data/spec/models/service_id_group_list_spec.rb +36 -0
- data/spec/models/service_id_group_spec.rb +84 -0
- data/spec/models/service_id_list_spec.rb +15 -20
- data/spec/models/service_id_spec.rb +34 -27
- data/spec/models/share_scope_spec.rb +46 -0
- data/spec/models/template_account_settings_all_of_restrict_user_domains_spec.rb +42 -0
- data/spec/models/template_account_settings_spec.rb +102 -0
- data/spec/models/template_assignment_list_response_spec.rb +72 -0
- data/spec/models/template_assignment_resource_error_spec.rb +54 -0
- data/spec/models/template_assignment_resource_spec.rb +36 -0
- data/spec/models/template_assignment_response_resource_detail_spec.rb +60 -0
- data/spec/models/template_assignment_response_resource_spec.rb +54 -0
- data/spec/models/template_assignment_response_spec.rb +126 -0
- data/spec/models/template_count_spec.rb +42 -0
- data/spec/models/template_profile_component_request_spec.rb +60 -0
- data/spec/models/template_profile_component_response_spec.rb +60 -0
- data/spec/models/test_result_spec.rb +66 -0
- data/spec/models/test_result_steps_inner_spec.rb +54 -0
- data/spec/models/test_trigger_response_spec.rb +42 -0
- data/spec/models/token_response_spec.rb +14 -19
- data/spec/models/trusted_profile_spec.rb +132 -0
- data/spec/models/trusted_profile_template_claim_rule_spec.rb +64 -0
- data/spec/models/trusted_profile_template_list_spec.rb +72 -0
- data/spec/models/trusted_profile_template_request_spec.rb +66 -0
- data/spec/models/trusted_profile_template_response_spec.rb +126 -0
- data/spec/models/trusted_profiles_list_spec.rb +72 -0
- data/spec/models/update_account_idp_setting_request_spec.rb +52 -0
- data/spec/models/update_account_login_settings_spec.rb +36 -0
- data/spec/models/update_api_key_request_spec.rb +28 -15
- data/spec/models/update_id_p_request_properties_idp_spec.rb +54 -0
- data/spec/models/update_id_p_request_properties_spec.rb +42 -0
- data/spec/models/update_id_p_request_secrets_idp_spec.rb +42 -0
- data/spec/models/update_id_p_request_secrets_spec.rb +42 -0
- data/spec/models/update_id_p_request_spec.rb +66 -0
- data/spec/models/update_preference_request_spec.rb +42 -0
- data/spec/models/update_service_id_group_request_spec.rb +42 -0
- data/spec/models/update_service_id_request_spec.rb +11 -16
- data/spec/models/update_template_assignment_request_spec.rb +36 -0
- data/spec/models/update_trusted_profile_request_spec.rb +48 -0
- data/spec/models/user_activity_spec.rb +60 -0
- data/spec/models/user_mfa_enrollments_spec.rb +54 -0
- data/spec/models/user_mfa_resolved_spec.rb +54 -0
- data/spec/models/user_mfa_spec.rb +42 -0
- data/spec/models/user_report_mfa_enrollment_status_spec.rb +72 -0
- data/spec/models/user_visbility_retrict_actions_for_template_spec.rb +30 -0
- data/spec/models/user_visbility_retrict_actions_spec.rb +30 -0
- data/spec/spec_helper.rb +3 -3
- metadata +549 -35
- data/docs/IdentityOperationsApi.md +0 -828
- data/docs/InlineObject.md +0 -19
- data/docs/InlineObject1.md +0 -23
- data/docs/InlineObject2.md +0 -21
- data/docs/InlineObject3.md +0 -25
- data/docs/TokenOperationsApi.md +0 -226
- data/lib/ibm_cloud_iam/api/identity_operations_api.rb +0 -1083
- data/lib/ibm_cloud_iam/api/token_operations_api.rb +0 -351
- data/lib/ibm_cloud_iam/models/inline_object.rb +0 -229
- data/lib/ibm_cloud_iam/models/inline_object1.rb +0 -254
- data/lib/ibm_cloud_iam/models/inline_object2.rb +0 -244
- data/lib/ibm_cloud_iam/models/inline_object3.rb +0 -269
- data/spec/api/identity_operations_api_spec.rb +0 -253
- data/spec/api/token_operations_api_spec.rb +0 -94
- data/spec/api_client_spec.rb +0 -226
- data/spec/configuration_spec.rb +0 -42
- data/spec/models/inline_object1_spec.rb +0 -59
- data/spec/models/inline_object2_spec.rb +0 -53
- data/spec/models/inline_object3_spec.rb +0 -65
- data/spec/models/inline_object_spec.rb +0 -47
|
@@ -1,20 +1,21 @@
|
|
|
1
1
|
=begin
|
|
2
|
-
#IAM Identity Services
|
|
2
|
+
#IAM Identity Services
|
|
3
3
|
|
|
4
|
-
#The IAM Identity Service API allows for the management of Identities (Service IDs, ApiKeys).
|
|
4
|
+
# ## Introduction The IAM Identity Service API is used to manage service IDs, API key identities, trusted profiles, account security settings and to create IAM access tokens for a user or service ID. With trusted profile templates and assignments you can centrally manage access for child accounts in your organization from the root enterprise account. Similarly with settings templates and assignments, you can centrally administer account security settings. For more information, see [Working with template versions](https://cloud.ibm.com/docs/secure-enterprise?topic=secure-enterprise-working-with-versions&interface=ui) and [Best practices for assigning access in an enterprise](https://cloud.ibm.com/docs/secure-enterprise?topic=secure-enterprise-access-enterprises). SDKs for Java, Node, Python, and Go are available to make it easier to programmatically access the API from your code. The client libraries that are provided by the SDKs implement best practices for using the API and reduce the amount of code that you need to write. The tab for each language includes code examples that demonstrate how to use the client libraries. For more information about using the SDKs, see the [IBM Cloud SDK Common project](https://github.com/IBM/ibm-cloud-sdk-common) on GitHub. Installing the Java SDK Maven ```xml <dependency> <groupId>com.ibm.cloud</groupId> <artifactId>iam-identity</artifactId> <version>{version}</version> </dependency> ``` Gradle ```bash compile 'com.ibm.cloud:iam-identity:{version}' ``` Replace `{version}` in these examples with the release version. View on GitHub [https://github.com/IBM/platform-services-java-sdk](https://github.com/IBM/platform-services-java-sdk) Installing the Go SDK Go modules (recommended): Add the following import in your code, and then run `go build` or `go mod tidy` ```go import ( \"github.com/IBM/platform-services-go-sdk/iamidentityv1\" ) ``` ```bash go get -u github.com/IBM/platform-services-go-sdk/iamidentityv1 ``` View on GitHub [https://github.com/IBM/platform-services-go-sdk](https://github.com/IBM/platform-services-go-sdk) Installing the Node SDK ```bash npm install @ibm-cloud/platform-services ``` View on GitHub [https://github.com/IBM/platform-services-node-sdk](https://github.com/IBM/platform-services-node-sdk) Installing the Python SDK ```bash pip install --upgrade \"ibm-platform-services\" ``` View on GitHub [https://github.com/IBM/platform-services-python-sdk](https://github.com/IBM/platform-services-python-sdk) The examples that are provided on this page demonstrate how to use IAM Identity Service For more information and detailed examples, check out the [IBM Cloud SDK Common project on GitHub](https://github.com/IBM/ibm-cloud-sdk-common/blob/master/README.md). The examples that are provided on this page demonstrate how to use IAM Identity Service For more information and detailed examples, check out the [IBM Cloud SDK Common project on GitHub](https://github.com/IBM/ibm-cloud-sdk-common/blob/master/README.md). The examples that are provided on this page demonstrate how to use IAM Identity Service For more information and detailed examples, check out the [IBM Cloud SDK Common project on GitHub](https://github.com/IBM/ibm-cloud-sdk-common/blob/master/README.md). The examples that are provided on this page demonstrate how to use IAM Identity Service For more information and detailed examples, check out the [IBM Cloud SDK Common project on GitHub](https://github.com/IBM/ibm-cloud-sdk-common/blob/master/README.md). ## Endpoint URLs The IAM Identity Services API uses the following public global endpoint URL. When you call the API, add the path for each method to form the complete API endpoint for your requests. ```bash https://iam.cloud.ibm.com ``` Virtual private cloud (VPC) based access requires a virtual private endpoint gateway (VPE gateway). For more information , see [Creating an endpoint gateway](https://cloud.ibm.com/docs/vpc?topic=vpc-ordering-endpoint-gateway). * Private endpoint URL for VPC infrastructure: `https://private.iam.cloud.ibm.com`. VPE gateway creation is supported in all datacenters (see https://cloud.ibm.com/docs/overview?topic=overview-locations#regions). If you enabled service endpoints in your account, you can send API requests over the IBM Cloud® private network at the following base endpoint URLs. For more information, see [Enabling VRF and service endpoints](https://cloud.ibm.com/docs/account?topic=account-vrf-service-endpoint). * Private endpoint URLs for classic infrastructure. Supported URLs: * Sydney: `https://private.au-syd.iam.cloud.ibm.com` * Sao Paulo: `https://private.br-sao.iam.cloud.ibm.com` * Montreal: `https://private.ca-mon.iam.cloud.ibm.com` * Toronto: `https://private.ca-tor.iam.cloud.ibm.com` * Frankfurt DC: `https://private.eu-de.iam.cloud.ibm.com` * London: `https://private.eu-gb.iam.cloud.ibm.com` * Madrid: `https://private.eu-es.iam.cloud.ibm.com` * Tokyo: `https://private.jp-tok.iam.cloud.ibm.com` * Osaka: `https://private.jp-osa.iam.cloud.ibm.com` * Washington DC: `https://private.us-east.iam.cloud.ibm.com` * Dallas: `https://private.us-south.iam.cloud.ibm.com` IAM is a global service and deployed to multiple MZRs world wide. IAM can be reached from all locations using the public global endpoint or using one of the private endpoints. Each request is sent to the closest region related to the client that invokes the call to IAM. Example API request ```bash curl -u \"apikey:{apikey}\" -X {request_method} \"https://iam.cloud.ibm.com/{method_endpoint}\" ``` Replace `{apikey}`, `{request_method}`, and `{method_endpoint}` in this example with the values for your particular API call. ## Authentication Authorization to the Identity Services REST API is enforced by using an IBM Cloud Identity and Access Management (IAM) access token. The token is used to determine the actions that a user or service ID has access to when they use the API. You can generate an access token by first [creating an API key](https://cloud.ibm.com/docs/account?topic=account-iamtoken_from_apikey) and then exchanging your API key for an IBM Cloud IAM token. Don't have an API key? Try running `ibmcloud iam oauth-tokens` in the [IBM Cloud Shell](https://cloud.ibm.com/shell) to quickly generate a personal access token. When you use the SDK, configure an IAM authenticator with the IAM API key. The authenticator automatically obtains the IAM access token for the API key and includes it with each request. You can construct an authenticator in either of two ways: - Programmatically by constructing an IAM authenticator instance and supplying your IAM API key - By defining the API key in external configuration properties and then using the SDK authenticator factory to construct an IAM authenticator that uses the configured IAM API key In this example of using external configuration properties, an IAM authenticator instance is created with the configured API key, and then the service client is constructed with this authenticator instance and the configured service URL. For more information, see the Authentication section of the [IBM Cloud SDK Common](https://github.com/IBM/ibm-cloud-sdk-common/blob/main/README.md) documentation. To call each method, you'll need to be assigned a role that includes the required IAM actions. Each method lists the associated action. For more information about IAM actions and how they map to roles, see [IAM Identity service](https://cloud.ibm.com/docs/account?topic=account-account-services#identity-service-account-management). To retrieve your access token: ```bash curl -X POST \\ \"https://iam.cloud.ibm.com/identity/token\" \\ --header 'Content-Type: application/x-www-form-urlencoded' \\ --header 'Accept: application/json' \\ --data-urlencode 'grant_type=urn:ibm:params:oauth:grant-type:apikey' \\ --data-urlencode 'apikey=<API_KEY>' ``` Replace `<API_KEY>` with your IAM API key. Setting client options through external configuration Example environment variables, where `<SERVICE_URL>` is the endpoint URL and `<API_KEY>` is your IAM API key ```sh export IAM_IDENTITY_URL=<SERVICE_URL> export IAM_IDENTITY_AUTHTYPE=iam export IAM_IDENTITY_APIKEY=<API_KEY> ``` Example of constructing the service client ```go import { \"github.com/IBM/platform-services-go-sdk/iamidentityv1\" } ... serviceClientOptions := &iamidentityv1.IamIdentityV1Options{} serviceClient, err := iamidentityv1.NewIamIdentityV1UsingExternalConfig(serviceClientOptions) ``` Setting client options through external configuration Example environment variables, where `<SERVICE_URL>` is the endpoint URL and `<API_KEY>` is your IAM API key ```sh export IAM_IDENTITY_URL=<SERVICE_URL> export IAM_IDENTITY_AUTHTYPE=iam export IAM_IDENTITY_APIKEY=<API_KEY> ``` Example of constructing the service client ```java import com.ibm.cloud.platform_services.iam_identity.v1.IamIdentity; ... IamIdentity serviceClient = IamIdentity.newInstance(); ``` Setting client options through external configuration Example environment variables, where `<SERVICE_URL>` is the endpoint URL and `<API_KEY>` is your IAM API key ```sh export IAM_IDENTITY_URL=<SERVICE_URL> export IAM_IDENTITY_AUTHTYPE=iam export IAM_IDENTITY_APIKEY=<API_KEY> ``` Example of constructing the service client ```javascript const IamIdentityV1 = require('@ibm-cloud/platform-services/iam-identity/v1'); ... const serviceClient = IamIdentityV1.newInstance({}); ``` Setting client options through external configuration Example environment variables, where `<SERVICE_URL>` is the endpoint URL and `<API_KEY>` is your IAM API key ```sh export IAM_IDENTITY_URL=<SERVICE_URL> export IAM_IDENTITY_AUTHTYPE=iam export IAM_IDENTITY_APIKEY=<API_KEY> ``` Example of constructing the service client ```python from ibm_platform_services import IamIdentityV1 ... service_client = IamIdentityV1.new_instance() ``` You authenticate to the API by using Cloud Identity and Access Management (IAM). You can pass either a bearer token in an authorization header or an [API key](https://cloud.ibm.com/docs/account?topic=account-manapikey). The SDK provides initialization methods for each form of authentication. - Use the API key to have the SDK manage the lifecycle of the access token. The SDK requests an access token, ensures that the access token is valid, includes the access token in each outgoing request, and refreshes it when it expires. - Use the access token to manage the lifecycle yourself. Keep in mind that access tokens are valid for 1 hour, so you must refresh them regularly to maintain access. For more information, see [IAM authentication with the SDK](https://github.com/IBM/ibm-cloud-sdk-common/blob/master/README.md#authentication). For more information, see [IAM authentication with the SDK](https://github.com/IBM/ibm-cloud-sdk-common/blob/master/README.md#authentication). For more information, see [IAM authentication with the SDK](https://github.com/IBM/ibm-cloud-sdk-common/blob/master/README.md#authentication). For more information, see [IAM authentication with the SDK](https://github.com/IBM/ibm-cloud-sdk-common/blob/master/README.md#authentication). ## Auditing You can monitor API activity within your account by using the IBM Cloud Logs service. Whenever an API method is called, an event is generated that you can then track and audit from within IBM Cloud Logs. The specific event type is listed for each individual method. If an event is tracked for a method, you can find it listed with the method. For more information about how to track IAM activity, see [Activity tracking events for IAM](https://cloud.ibm.com/docs/account?topic=account-at_events_iam). ## Error handling The IAM Token Service uses standard HTTP response codes to indicate whether a method completed successfully. A `200` response always indicates success. A `400` type response indicates that a parameter validation failed and can occur if required parameters are missing or if any parameter values are invalid. A `401` or `403` response indicates that the incoming request did not contain valid authentication information. A `500` type response indicates an internal server error that is seen in an unexpected error situation. The Identity Services REST APIs return standard HTTP status codes to indicate the success or failure of a request. The format of the response is represented in JSON as follows: ```json { \"trace\": \"9daee671-916a-4678-850b-10b911f0236d\", \"errors\": [ { \"code\": \"invalid_access_token\", \"message\": \"The provided access token provided is invalid.\" } ] \"status_code\": 401 } ``` If an operation cannot be fulfilled, an appropriate 400 or 500 series HTTP response is returned from the server. The operations that are defined in the `Reference` section describe example errors that might be returned from a failed request. All responses from the Identity Services REST API are in JSON format. The following table show the potential error codes the API might return. | HTTP Error Code | Description | Recovery | |-----------------|-------------|----------| | `200` | Success | The request was successful. | | `201` | Created | The resource was successfully created. | | `204` | No Content | The request was successful. No response body is provided. | | `400` | Bad Request | The input parameters in the request body are either incomplete or in the wrong format. Be sure to include all required parameters in your request. | | `401` | Unauthorized | You are not authorized to make this request. The token is either missing or expired. Get a new valid token and try again. | | `403` | Forbidden | The supplied authentication is not authorized to perform the operation. If this error persists, contact the account owner to check your permissions. | | `404` | Not Found | The requested resource can't be found. | | `409` | Conflict | The entity is already in the requested state. | | `429` | Too Many Requests | Too many requests have been made within a time window. Wait before calling the API again. | | `500` | Internal error | Error that is seen in an unexpected error situation. | ## Additional headers Some additional headers might be required to make successful requests to the API. Those additional headers are: An optional transaction ID can be passed to your request, which can be useful for tracking calls through multiple services using one identifier. The header key must be set to `Transaction-Id` and the value is anything that you choose. If there is not a transaction ID that is passed in, then one is generated randomly. ## API Parameters Some API parameter have additional details that need to be considered while using it in a request. Those API parameters are as follow: ### Filtering list results When listing service IDs, trusted profiles or API keys you can filter the result set by providing an optional `filter` parameter. The exact syntax of this parameter is described below. Query syntax will follow the SCIM query syntax with reduced operator support. The value must be URL encoded. Only the following operators are supported. * Supported attribute operators- - `sw` - starts with - `sw_ci` - starts with ingnore case - non SCIM standard - `ew` - ends with - `ew_ci` - ends with ingnore case - non SCIM standard - `co` - contains - `co_ci` - contains ingnore case - non SCIM standard * Supported operators- - `and` - `or` * Grouping operators- - `()` * Data Values -`Text` * Sample - `name co \"Foo\" and description sw \"Bar\"`
|
|
5
5
|
|
|
6
6
|
The version of the OpenAPI document: 1.0.0
|
|
7
7
|
|
|
8
8
|
Generated by: https://openapi-generator.tech
|
|
9
|
-
|
|
9
|
+
Generator version: 7.23.0
|
|
10
10
|
|
|
11
11
|
=end
|
|
12
12
|
|
|
13
13
|
require 'date'
|
|
14
|
+
require 'time'
|
|
14
15
|
|
|
15
16
|
module IbmCloudIam
|
|
16
|
-
# Response body format for API key V1 REST requests
|
|
17
|
-
class ApiKey
|
|
17
|
+
# Response body format for API key V1 REST requests.
|
|
18
|
+
class ApiKey < ApiModelBase
|
|
18
19
|
attr_accessor :context
|
|
19
20
|
|
|
20
21
|
# Unique identifier of this API Key.
|
|
@@ -29,18 +30,30 @@ module IbmCloudIam
|
|
|
29
30
|
# The API key cannot be changed if set to true.
|
|
30
31
|
attr_accessor :locked
|
|
31
32
|
|
|
32
|
-
#
|
|
33
|
+
# Defines if API key is disabled, API key cannot be used if 'disabled' is set to true.
|
|
34
|
+
attr_accessor :disabled
|
|
35
|
+
|
|
36
|
+
# If set contains a date time string of the creation date in ISO format.
|
|
33
37
|
attr_accessor :created_at
|
|
34
38
|
|
|
35
39
|
# IAM ID of the user or service which created the API key.
|
|
36
40
|
attr_accessor :created_by
|
|
37
41
|
|
|
38
|
-
# If set contains a date time string of the last modification date in ISO format
|
|
42
|
+
# If set contains a date time string of the last modification date in ISO format.
|
|
39
43
|
attr_accessor :modified_at
|
|
40
44
|
|
|
41
45
|
# Name of the API key. The name is not checked for uniqueness. Therefore multiple names with the same value can exist. Access is done via the UUID of the API key.
|
|
42
46
|
attr_accessor :name
|
|
43
47
|
|
|
48
|
+
# Defines whether you can manage CLI login sessions for the API key. When `true`, sessions are created and can be reviewed or revoked. When `false`, no sessions are tracked. To block access, delete or rotate the API key. Available only for user API keys.
|
|
49
|
+
attr_accessor :support_sessions
|
|
50
|
+
|
|
51
|
+
# Defines the action to take when API key is leaked, valid values are 'none', 'disable' and 'delete'.
|
|
52
|
+
attr_accessor :action_when_leaked
|
|
53
|
+
|
|
54
|
+
# Date and time when the API key becomes invalid, ISO 8601 datetime in the format 'yyyy-MM-ddTHH:mm+0000'. **WARNING** An API key will be permanently and irrevocably deleted when both the expires_at and modified_at timestamps are more than ninety (90) days in the past, regardless of the key’s locked status or any other state.
|
|
55
|
+
attr_accessor :expires_at
|
|
56
|
+
|
|
44
57
|
# The optional description of the API key. The 'description' property is only available if a description was provided during a create of an API key.
|
|
45
58
|
attr_accessor :description
|
|
46
59
|
|
|
@@ -53,9 +66,11 @@ module IbmCloudIam
|
|
|
53
66
|
# The API key value. This property only contains the API key value for the following cases: create an API key, update a service ID API key that stores the API key value as retrievable, or get a service ID API key that stores the API key value as retrievable. All other operations don't return the API key value, for example all user API key related operations, except for create, don't contain the API key value.
|
|
54
67
|
attr_accessor :apikey
|
|
55
68
|
|
|
56
|
-
# History of the API key
|
|
69
|
+
# History of the API key.
|
|
57
70
|
attr_accessor :history
|
|
58
71
|
|
|
72
|
+
attr_accessor :activity
|
|
73
|
+
|
|
59
74
|
# Attribute mapping from ruby-style variable name to JSON key.
|
|
60
75
|
def self.attribute_map
|
|
61
76
|
{
|
|
@@ -64,18 +79,33 @@ module IbmCloudIam
|
|
|
64
79
|
:'entity_tag' => :'entity_tag',
|
|
65
80
|
:'crn' => :'crn',
|
|
66
81
|
:'locked' => :'locked',
|
|
82
|
+
:'disabled' => :'disabled',
|
|
67
83
|
:'created_at' => :'created_at',
|
|
68
84
|
:'created_by' => :'created_by',
|
|
69
85
|
:'modified_at' => :'modified_at',
|
|
70
86
|
:'name' => :'name',
|
|
87
|
+
:'support_sessions' => :'support_sessions',
|
|
88
|
+
:'action_when_leaked' => :'action_when_leaked',
|
|
89
|
+
:'expires_at' => :'expires_at',
|
|
71
90
|
:'description' => :'description',
|
|
72
91
|
:'iam_id' => :'iam_id',
|
|
73
92
|
:'account_id' => :'account_id',
|
|
74
93
|
:'apikey' => :'apikey',
|
|
75
|
-
:'history' => :'history'
|
|
94
|
+
:'history' => :'history',
|
|
95
|
+
:'activity' => :'activity'
|
|
76
96
|
}
|
|
77
97
|
end
|
|
78
98
|
|
|
99
|
+
# Returns attribute mapping this model knows about
|
|
100
|
+
def self.acceptable_attribute_map
|
|
101
|
+
attribute_map
|
|
102
|
+
end
|
|
103
|
+
|
|
104
|
+
# Returns all the JSON keys this model knows about
|
|
105
|
+
def self.acceptable_attributes
|
|
106
|
+
acceptable_attribute_map.values
|
|
107
|
+
end
|
|
108
|
+
|
|
79
109
|
# Attribute type mapping.
|
|
80
110
|
def self.openapi_types
|
|
81
111
|
{
|
|
@@ -84,15 +114,20 @@ module IbmCloudIam
|
|
|
84
114
|
:'entity_tag' => :'String',
|
|
85
115
|
:'crn' => :'String',
|
|
86
116
|
:'locked' => :'Boolean',
|
|
87
|
-
:'
|
|
117
|
+
:'disabled' => :'Boolean',
|
|
118
|
+
:'created_at' => :'Time',
|
|
88
119
|
:'created_by' => :'String',
|
|
89
|
-
:'modified_at' => :'
|
|
120
|
+
:'modified_at' => :'Time',
|
|
90
121
|
:'name' => :'String',
|
|
122
|
+
:'support_sessions' => :'Boolean',
|
|
123
|
+
:'action_when_leaked' => :'String',
|
|
124
|
+
:'expires_at' => :'String',
|
|
91
125
|
:'description' => :'String',
|
|
92
126
|
:'iam_id' => :'String',
|
|
93
127
|
:'account_id' => :'String',
|
|
94
128
|
:'apikey' => :'String',
|
|
95
|
-
:'history' => :'Array<EnityHistoryRecord>'
|
|
129
|
+
:'history' => :'Array<EnityHistoryRecord>',
|
|
130
|
+
:'activity' => :'Activity'
|
|
96
131
|
}
|
|
97
132
|
end
|
|
98
133
|
|
|
@@ -110,9 +145,10 @@ module IbmCloudIam
|
|
|
110
145
|
end
|
|
111
146
|
|
|
112
147
|
# check to see if the attribute exists and convert string to symbol for hash key
|
|
148
|
+
acceptable_attribute_map = self.class.acceptable_attribute_map
|
|
113
149
|
attributes = attributes.each_with_object({}) { |(k, v), h|
|
|
114
|
-
if (!
|
|
115
|
-
fail ArgumentError, "`#{k}` is not a valid attribute in `IbmCloudIam::ApiKey`. Please check the name to make sure it's valid. List of attributes: " +
|
|
150
|
+
if (!acceptable_attribute_map.key?(k.to_sym))
|
|
151
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `IbmCloudIam::ApiKey`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
|
|
116
152
|
end
|
|
117
153
|
h[k.to_sym] = v
|
|
118
154
|
}
|
|
@@ -123,6 +159,8 @@ module IbmCloudIam
|
|
|
123
159
|
|
|
124
160
|
if attributes.key?(:'id')
|
|
125
161
|
self.id = attributes[:'id']
|
|
162
|
+
else
|
|
163
|
+
self.id = nil
|
|
126
164
|
end
|
|
127
165
|
|
|
128
166
|
if attributes.key?(:'entity_tag')
|
|
@@ -131,10 +169,18 @@ module IbmCloudIam
|
|
|
131
169
|
|
|
132
170
|
if attributes.key?(:'crn')
|
|
133
171
|
self.crn = attributes[:'crn']
|
|
172
|
+
else
|
|
173
|
+
self.crn = nil
|
|
134
174
|
end
|
|
135
175
|
|
|
136
176
|
if attributes.key?(:'locked')
|
|
137
177
|
self.locked = attributes[:'locked']
|
|
178
|
+
else
|
|
179
|
+
self.locked = nil
|
|
180
|
+
end
|
|
181
|
+
|
|
182
|
+
if attributes.key?(:'disabled')
|
|
183
|
+
self.disabled = attributes[:'disabled']
|
|
138
184
|
end
|
|
139
185
|
|
|
140
186
|
if attributes.key?(:'created_at')
|
|
@@ -143,6 +189,8 @@ module IbmCloudIam
|
|
|
143
189
|
|
|
144
190
|
if attributes.key?(:'created_by')
|
|
145
191
|
self.created_by = attributes[:'created_by']
|
|
192
|
+
else
|
|
193
|
+
self.created_by = nil
|
|
146
194
|
end
|
|
147
195
|
|
|
148
196
|
if attributes.key?(:'modified_at')
|
|
@@ -151,6 +199,20 @@ module IbmCloudIam
|
|
|
151
199
|
|
|
152
200
|
if attributes.key?(:'name')
|
|
153
201
|
self.name = attributes[:'name']
|
|
202
|
+
else
|
|
203
|
+
self.name = nil
|
|
204
|
+
end
|
|
205
|
+
|
|
206
|
+
if attributes.key?(:'support_sessions')
|
|
207
|
+
self.support_sessions = attributes[:'support_sessions']
|
|
208
|
+
end
|
|
209
|
+
|
|
210
|
+
if attributes.key?(:'action_when_leaked')
|
|
211
|
+
self.action_when_leaked = attributes[:'action_when_leaked']
|
|
212
|
+
end
|
|
213
|
+
|
|
214
|
+
if attributes.key?(:'expires_at')
|
|
215
|
+
self.expires_at = attributes[:'expires_at']
|
|
154
216
|
end
|
|
155
217
|
|
|
156
218
|
if attributes.key?(:'description')
|
|
@@ -159,14 +221,20 @@ module IbmCloudIam
|
|
|
159
221
|
|
|
160
222
|
if attributes.key?(:'iam_id')
|
|
161
223
|
self.iam_id = attributes[:'iam_id']
|
|
224
|
+
else
|
|
225
|
+
self.iam_id = nil
|
|
162
226
|
end
|
|
163
227
|
|
|
164
228
|
if attributes.key?(:'account_id')
|
|
165
229
|
self.account_id = attributes[:'account_id']
|
|
230
|
+
else
|
|
231
|
+
self.account_id = nil
|
|
166
232
|
end
|
|
167
233
|
|
|
168
234
|
if attributes.key?(:'apikey')
|
|
169
235
|
self.apikey = attributes[:'apikey']
|
|
236
|
+
else
|
|
237
|
+
self.apikey = nil
|
|
170
238
|
end
|
|
171
239
|
|
|
172
240
|
if attributes.key?(:'history')
|
|
@@ -174,11 +242,16 @@ module IbmCloudIam
|
|
|
174
242
|
self.history = value
|
|
175
243
|
end
|
|
176
244
|
end
|
|
245
|
+
|
|
246
|
+
if attributes.key?(:'activity')
|
|
247
|
+
self.activity = attributes[:'activity']
|
|
248
|
+
end
|
|
177
249
|
end
|
|
178
250
|
|
|
179
251
|
# Show invalid properties with the reasons. Usually used together with valid?
|
|
180
252
|
# @return Array for valid properties with the reasons
|
|
181
253
|
def list_invalid_properties
|
|
254
|
+
warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
|
|
182
255
|
invalid_properties = Array.new
|
|
183
256
|
if @id.nil?
|
|
184
257
|
invalid_properties.push('invalid value for "id", id cannot be nil.')
|
|
@@ -218,6 +291,7 @@ module IbmCloudIam
|
|
|
218
291
|
# Check to see if the all the properties in the model are valid
|
|
219
292
|
# @return true if the model is valid
|
|
220
293
|
def valid?
|
|
294
|
+
warn '[DEPRECATED] the `valid?` method is obsolete'
|
|
221
295
|
return false if @id.nil?
|
|
222
296
|
return false if @crn.nil?
|
|
223
297
|
return false if @locked.nil?
|
|
@@ -229,6 +303,86 @@ module IbmCloudIam
|
|
|
229
303
|
true
|
|
230
304
|
end
|
|
231
305
|
|
|
306
|
+
# Custom attribute writer method with validation
|
|
307
|
+
# @param [Object] id Value to be assigned
|
|
308
|
+
def id=(id)
|
|
309
|
+
if id.nil?
|
|
310
|
+
fail ArgumentError, 'id cannot be nil'
|
|
311
|
+
end
|
|
312
|
+
|
|
313
|
+
@id = id
|
|
314
|
+
end
|
|
315
|
+
|
|
316
|
+
# Custom attribute writer method with validation
|
|
317
|
+
# @param [Object] crn Value to be assigned
|
|
318
|
+
def crn=(crn)
|
|
319
|
+
if crn.nil?
|
|
320
|
+
fail ArgumentError, 'crn cannot be nil'
|
|
321
|
+
end
|
|
322
|
+
|
|
323
|
+
@crn = crn
|
|
324
|
+
end
|
|
325
|
+
|
|
326
|
+
# Custom attribute writer method with validation
|
|
327
|
+
# @param [Object] locked Value to be assigned
|
|
328
|
+
def locked=(locked)
|
|
329
|
+
if locked.nil?
|
|
330
|
+
fail ArgumentError, 'locked cannot be nil'
|
|
331
|
+
end
|
|
332
|
+
|
|
333
|
+
@locked = locked
|
|
334
|
+
end
|
|
335
|
+
|
|
336
|
+
# Custom attribute writer method with validation
|
|
337
|
+
# @param [Object] created_by Value to be assigned
|
|
338
|
+
def created_by=(created_by)
|
|
339
|
+
if created_by.nil?
|
|
340
|
+
fail ArgumentError, 'created_by cannot be nil'
|
|
341
|
+
end
|
|
342
|
+
|
|
343
|
+
@created_by = created_by
|
|
344
|
+
end
|
|
345
|
+
|
|
346
|
+
# Custom attribute writer method with validation
|
|
347
|
+
# @param [Object] name Value to be assigned
|
|
348
|
+
def name=(name)
|
|
349
|
+
if name.nil?
|
|
350
|
+
fail ArgumentError, 'name cannot be nil'
|
|
351
|
+
end
|
|
352
|
+
|
|
353
|
+
@name = name
|
|
354
|
+
end
|
|
355
|
+
|
|
356
|
+
# Custom attribute writer method with validation
|
|
357
|
+
# @param [Object] iam_id Value to be assigned
|
|
358
|
+
def iam_id=(iam_id)
|
|
359
|
+
if iam_id.nil?
|
|
360
|
+
fail ArgumentError, 'iam_id cannot be nil'
|
|
361
|
+
end
|
|
362
|
+
|
|
363
|
+
@iam_id = iam_id
|
|
364
|
+
end
|
|
365
|
+
|
|
366
|
+
# Custom attribute writer method with validation
|
|
367
|
+
# @param [Object] account_id Value to be assigned
|
|
368
|
+
def account_id=(account_id)
|
|
369
|
+
if account_id.nil?
|
|
370
|
+
fail ArgumentError, 'account_id cannot be nil'
|
|
371
|
+
end
|
|
372
|
+
|
|
373
|
+
@account_id = account_id
|
|
374
|
+
end
|
|
375
|
+
|
|
376
|
+
# Custom attribute writer method with validation
|
|
377
|
+
# @param [Object] apikey Value to be assigned
|
|
378
|
+
def apikey=(apikey)
|
|
379
|
+
if apikey.nil?
|
|
380
|
+
fail ArgumentError, 'apikey cannot be nil'
|
|
381
|
+
end
|
|
382
|
+
|
|
383
|
+
@apikey = apikey
|
|
384
|
+
end
|
|
385
|
+
|
|
232
386
|
# Checks equality by comparing each attribute.
|
|
233
387
|
# @param [Object] Object to be compared
|
|
234
388
|
def ==(o)
|
|
@@ -239,15 +393,20 @@ module IbmCloudIam
|
|
|
239
393
|
entity_tag == o.entity_tag &&
|
|
240
394
|
crn == o.crn &&
|
|
241
395
|
locked == o.locked &&
|
|
396
|
+
disabled == o.disabled &&
|
|
242
397
|
created_at == o.created_at &&
|
|
243
398
|
created_by == o.created_by &&
|
|
244
399
|
modified_at == o.modified_at &&
|
|
245
400
|
name == o.name &&
|
|
401
|
+
support_sessions == o.support_sessions &&
|
|
402
|
+
action_when_leaked == o.action_when_leaked &&
|
|
403
|
+
expires_at == o.expires_at &&
|
|
246
404
|
description == o.description &&
|
|
247
405
|
iam_id == o.iam_id &&
|
|
248
406
|
account_id == o.account_id &&
|
|
249
407
|
apikey == o.apikey &&
|
|
250
|
-
history == o.history
|
|
408
|
+
history == o.history &&
|
|
409
|
+
activity == o.activity
|
|
251
410
|
end
|
|
252
411
|
|
|
253
412
|
# @see the `==` method
|
|
@@ -259,89 +418,30 @@ module IbmCloudIam
|
|
|
259
418
|
# Calculates hash code according to all attributes.
|
|
260
419
|
# @return [Integer] Hash code
|
|
261
420
|
def hash
|
|
262
|
-
[context, id, entity_tag, crn, locked, created_at, created_by, modified_at, name, description, iam_id, account_id, apikey, history].hash
|
|
421
|
+
[context, id, entity_tag, crn, locked, disabled, created_at, created_by, modified_at, name, support_sessions, action_when_leaked, expires_at, description, iam_id, account_id, apikey, history, activity].hash
|
|
263
422
|
end
|
|
264
423
|
|
|
265
424
|
# Builds the object from hash
|
|
266
425
|
# @param [Hash] attributes Model attributes in the form of hash
|
|
267
426
|
# @return [Object] Returns the model itself
|
|
268
427
|
def self.build_from_hash(attributes)
|
|
269
|
-
new.build_from_hash(attributes)
|
|
270
|
-
end
|
|
271
|
-
|
|
272
|
-
# Builds the object from hash
|
|
273
|
-
# @param [Hash] attributes Model attributes in the form of hash
|
|
274
|
-
# @return [Object] Returns the model itself
|
|
275
|
-
def build_from_hash(attributes)
|
|
276
428
|
return nil unless attributes.is_a?(Hash)
|
|
277
|
-
|
|
278
|
-
|
|
429
|
+
attributes = attributes.transform_keys(&:to_sym)
|
|
430
|
+
transformed_hash = {}
|
|
431
|
+
openapi_types.each_pair do |key, type|
|
|
432
|
+
if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
|
|
433
|
+
transformed_hash["#{key}"] = nil
|
|
434
|
+
elsif type =~ /\AArray<(.*)>/i
|
|
279
435
|
# check to ensure the input is an array given that the attribute
|
|
280
436
|
# is documented as an array but the input is not
|
|
281
|
-
if attributes[
|
|
282
|
-
|
|
283
|
-
end
|
|
284
|
-
elsif !attributes[self.class.attribute_map[key]].nil?
|
|
285
|
-
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
|
286
|
-
elsif attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
|
|
287
|
-
self.send("#{key}=", nil)
|
|
288
|
-
end
|
|
289
|
-
end
|
|
290
|
-
|
|
291
|
-
self
|
|
292
|
-
end
|
|
293
|
-
|
|
294
|
-
# Deserializes the data based on type
|
|
295
|
-
# @param string type Data type
|
|
296
|
-
# @param string value Value to be deserialized
|
|
297
|
-
# @return [Object] Deserialized data
|
|
298
|
-
def _deserialize(type, value)
|
|
299
|
-
case type.to_sym
|
|
300
|
-
when :DateTime
|
|
301
|
-
DateTime.parse(value)
|
|
302
|
-
when :Date
|
|
303
|
-
Date.parse(value)
|
|
304
|
-
when :String
|
|
305
|
-
value.to_s
|
|
306
|
-
when :Integer
|
|
307
|
-
value.to_i
|
|
308
|
-
when :Float
|
|
309
|
-
value.to_f
|
|
310
|
-
when :Boolean
|
|
311
|
-
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
|
312
|
-
true
|
|
313
|
-
else
|
|
314
|
-
false
|
|
315
|
-
end
|
|
316
|
-
when :Object
|
|
317
|
-
# generic object (usually a Hash), return directly
|
|
318
|
-
value
|
|
319
|
-
when /\AArray<(?<inner_type>.+)>\z/
|
|
320
|
-
inner_type = Regexp.last_match[:inner_type]
|
|
321
|
-
value.map { |v| _deserialize(inner_type, v) }
|
|
322
|
-
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
|
323
|
-
k_type = Regexp.last_match[:k_type]
|
|
324
|
-
v_type = Regexp.last_match[:v_type]
|
|
325
|
-
{}.tap do |hash|
|
|
326
|
-
value.each do |k, v|
|
|
327
|
-
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
|
437
|
+
if attributes[attribute_map[key]].is_a?(Array)
|
|
438
|
+
transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
|
|
328
439
|
end
|
|
440
|
+
elsif !attributes[attribute_map[key]].nil?
|
|
441
|
+
transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
|
|
329
442
|
end
|
|
330
|
-
else # model
|
|
331
|
-
IbmCloudIam.const_get(type).build_from_hash(value)
|
|
332
443
|
end
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
# Returns the string representation of the object
|
|
336
|
-
# @return [String] String presentation of the object
|
|
337
|
-
def to_s
|
|
338
|
-
to_hash.to_s
|
|
339
|
-
end
|
|
340
|
-
|
|
341
|
-
# to_body is an alias to to_hash (backward compatibility)
|
|
342
|
-
# @return [Hash] Returns the object in the form of hash
|
|
343
|
-
def to_body
|
|
344
|
-
to_hash
|
|
444
|
+
new(transformed_hash)
|
|
345
445
|
end
|
|
346
446
|
|
|
347
447
|
# Returns the object in the form of hash
|
|
@@ -354,28 +454,12 @@ module IbmCloudIam
|
|
|
354
454
|
is_nullable = self.class.openapi_nullable.include?(attr)
|
|
355
455
|
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
|
356
456
|
end
|
|
357
|
-
|
|
457
|
+
|
|
358
458
|
hash[param] = _to_hash(value)
|
|
359
459
|
end
|
|
360
460
|
hash
|
|
361
461
|
end
|
|
362
462
|
|
|
363
|
-
# Outputs non-array value in the form of hash
|
|
364
|
-
# For object, use to_hash. Otherwise, just return the value
|
|
365
|
-
# @param [Object] value Any valid value
|
|
366
|
-
# @return [Hash] Returns the value in the form of hash
|
|
367
|
-
def _to_hash(value)
|
|
368
|
-
if value.is_a?(Array)
|
|
369
|
-
value.compact.map { |v| _to_hash(v) }
|
|
370
|
-
elsif value.is_a?(Hash)
|
|
371
|
-
{}.tap do |hash|
|
|
372
|
-
value.each { |k, v| hash[k] = _to_hash(v) }
|
|
373
|
-
end
|
|
374
|
-
elsif value.respond_to? :to_hash
|
|
375
|
-
value.to_hash
|
|
376
|
-
else
|
|
377
|
-
value
|
|
378
|
-
end
|
|
379
|
-
end
|
|
380
463
|
end
|
|
464
|
+
|
|
381
465
|
end
|