akeyless 4.2.3 → 4.2.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +54 -2
- data/docs/AccountGeneralSettings.md +2 -0
- data/docs/AcmeAccount.md +22 -0
- data/docs/AuthMethodRoleAssociation.md +2 -0
- data/docs/AwsStorage.md +28 -0
- data/docs/AzureStorage.md +28 -0
- data/docs/BastionConfigReplyObj.md +28 -0
- data/docs/BastionGlobalConf.md +24 -0
- data/docs/ChangeAdminAccountPassword.md +26 -0
- data/docs/Configure.md +8 -0
- data/docs/Connect.md +2 -2
- data/docs/CreateClassicKey.md +8 -0
- data/docs/CreateDFCKey.md +8 -0
- data/docs/CreatePKICertIssuer.md +5 -1
- data/docs/DeactivateAcmeAccount.md +28 -0
- data/docs/DynamicSecretUpdateArtifactory.md +1 -1
- data/docs/DynamicSecretUpdateAws.md +1 -1
- data/docs/DynamicSecretUpdateAzure.md +1 -1
- data/docs/DynamicSecretUpdateCassandra.md +1 -1
- data/docs/DynamicSecretUpdateChef.md +1 -1
- data/docs/DynamicSecretUpdateCustom.md +1 -1
- data/docs/DynamicSecretUpdateDockerhub.md +1 -1
- data/docs/DynamicSecretUpdateEks.md +1 -1
- data/docs/DynamicSecretUpdateGcp.md +1 -1
- data/docs/DynamicSecretUpdateGithub.md +1 -1
- data/docs/DynamicSecretUpdateGitlab.md +1 -1
- data/docs/DynamicSecretUpdateGke.md +1 -1
- data/docs/DynamicSecretUpdateGoogleWorkspace.md +1 -1
- data/docs/DynamicSecretUpdateHanaDb.md +1 -1
- data/docs/DynamicSecretUpdateK8s.md +1 -1
- data/docs/DynamicSecretUpdateLdap.md +1 -1
- data/docs/DynamicSecretUpdateMongoDb.md +1 -1
- data/docs/DynamicSecretUpdateMsSql.md +1 -1
- data/docs/DynamicSecretUpdateMySql.md +1 -1
- data/docs/DynamicSecretUpdateOracleDb.md +1 -1
- data/docs/DynamicSecretUpdatePing.md +1 -1
- data/docs/DynamicSecretUpdateVenafi.md +1 -1
- data/docs/EmailPassAccessRules.md +3 -1
- data/docs/EventForwarderCreateEmail.md +2 -2
- data/docs/EventForwarderCreateServiceNow.md +1 -1
- data/docs/EventForwarderCreateSlack.md +1 -1
- data/docs/EventForwarderCreateWebhook.md +1 -1
- data/docs/EventForwarderUpdateEmail.md +2 -2
- data/docs/EventForwarderUpdateServiceNow.md +1 -1
- data/docs/EventForwarderUpdateSlack.md +1 -1
- data/docs/EventForwarderUpdateWebhook.md +1 -1
- data/docs/GatewayGetRemoteAccess.md +22 -0
- data/docs/GatewayUpdateItem.md +2 -0
- data/docs/GatewayUpdateRemoteAccess.md +36 -0
- data/docs/GatewayUpdateRemoteAccessRdpRecordings.md +46 -0
- data/docs/GenerateAcmeEab.md +24 -0
- data/docs/GenerateAcmeEabOutput.md +22 -0
- data/docs/GetGroupOutput.md +2 -0
- data/docs/GetKubeExecCreds.md +1 -1
- data/docs/GetPKICertificate.md +1 -1
- data/docs/Group.md +2 -0
- data/docs/GwUpdateRemoteAccessSessionLogsAwsS3.md +42 -0
- data/docs/GwUpdateRemoteAccessSessionLogsAzureAnalytics.md +32 -0
- data/docs/GwUpdateRemoteAccessSessionLogsDatadog.md +38 -0
- data/docs/GwUpdateRemoteAccessSessionLogsElasticsearch.md +48 -0
- data/docs/GwUpdateRemoteAccessSessionLogsGoogleChronicle.md +36 -0
- data/docs/GwUpdateRemoteAccessSessionLogsLogstash.md +36 -0
- data/docs/GwUpdateRemoteAccessSessionLogsLogzIo.md +32 -0
- data/docs/GwUpdateRemoteAccessSessionLogsSplunk.md +42 -0
- data/docs/GwUpdateRemoteAccessSessionLogsStdout.md +28 -0
- data/docs/GwUpdateRemoteAccessSessionLogsSumologic.md +34 -0
- data/docs/GwUpdateRemoteAccessSessionLogsSyslog.md +40 -0
- data/docs/ItemGeneralInfo.md +4 -0
- data/docs/ListAcmeAccounts.md +24 -0
- data/docs/ListAcmeAccountsOutput.md +18 -0
- data/docs/NextAutoRotationEvent.md +18 -0
- data/docs/PKICertificateIssueDetails.md +4 -0
- data/docs/PasswordExpirationInfo.md +24 -0
- data/docs/ResetAccessKey.md +24 -0
- data/docs/ResetAuthMethodAccessKeyOutput.md +18 -0
- data/docs/RoleAssociationDetails.md +2 -0
- data/docs/RoleAuthMethodAssociation.md +2 -0
- data/docs/RollbackSecret.md +2 -0
- data/docs/RotatedSecretCreateAws.md +2 -0
- data/docs/RotatedSecretCreateAzure.md +2 -0
- data/docs/RotatedSecretCreateCassandra.md +2 -0
- data/docs/RotatedSecretCreateCustom.md +2 -0
- data/docs/RotatedSecretCreateDockerhub.md +2 -0
- data/docs/RotatedSecretCreateGcp.md +2 -0
- data/docs/RotatedSecretCreateHanadb.md +2 -0
- data/docs/RotatedSecretCreateLdap.md +2 -0
- data/docs/RotatedSecretCreateMongodb.md +2 -0
- data/docs/RotatedSecretCreateMssql.md +2 -0
- data/docs/RotatedSecretCreateMysql.md +2 -0
- data/docs/RotatedSecretCreateOracledb.md +2 -0
- data/docs/RotatedSecretCreatePostgresql.md +2 -0
- data/docs/RotatedSecretCreateRedis.md +2 -0
- data/docs/RotatedSecretCreateRedshift.md +2 -0
- data/docs/RotatedSecretCreateSnowflake.md +2 -0
- data/docs/RotatedSecretCreateSsh.md +2 -0
- data/docs/RotatedSecretCreateWindows.md +2 -0
- data/docs/RotatedSecretUpdateAws.md +2 -0
- data/docs/RotatedSecretUpdateAzure.md +2 -0
- data/docs/RotatedSecretUpdateCassandra.md +2 -0
- data/docs/RotatedSecretUpdateCustom.md +2 -0
- data/docs/RotatedSecretUpdateDockerhub.md +2 -0
- data/docs/RotatedSecretUpdateGcp.md +2 -0
- data/docs/RotatedSecretUpdateHanadb.md +2 -0
- data/docs/RotatedSecretUpdateLdap.md +2 -0
- data/docs/RotatedSecretUpdateMongodb.md +2 -0
- data/docs/RotatedSecretUpdateMssql.md +2 -0
- data/docs/RotatedSecretUpdateMysql.md +2 -0
- data/docs/RotatedSecretUpdateOracledb.md +2 -0
- data/docs/RotatedSecretUpdatePostgresql.md +2 -0
- data/docs/RotatedSecretUpdateRedis.md +2 -0
- data/docs/RotatedSecretUpdateRedshift.md +2 -0
- data/docs/RotatedSecretUpdateSnowflake.md +2 -0
- data/docs/RotatedSecretUpdateSsh.md +2 -0
- data/docs/RotatedSecretUpdateWindows.md +2 -0
- data/docs/SshBastionConf.md +24 -0
- data/docs/SshBastionSessionTermination.md +26 -0
- data/docs/UpdateAccountSettings.md +6 -0
- data/docs/UpdateClassicKeyCertificate.md +2 -0
- data/docs/UpdateItem.md +4 -0
- data/docs/UpdatePKICertIssuer.md +5 -1
- data/docs/UpdateRotationSettings.md +2 -0
- data/docs/UpdateTarget.md +1 -1
- data/docs/UploadRSA.md +2 -0
- data/docs/V2Api.md +1356 -225
- data/docs/WebBastionConf.md +20 -0
- data/docs/WebBastionGuacamole.md +18 -0
- data/docs/WebBastionRdpRecord.md +22 -0
- data/lib/akeyless/api/v2_api.rb +1360 -219
- data/lib/akeyless/models/account_general_settings.rb +10 -1
- data/lib/akeyless/models/acme_account.rb +234 -0
- data/lib/akeyless/models/auth_method_role_association.rb +10 -1
- data/lib/akeyless/models/aws_storage.rb +260 -0
- data/lib/akeyless/models/azure_storage.rb +260 -0
- data/lib/akeyless/models/bastion_config_reply_obj.rb +259 -0
- data/lib/akeyless/models/bastion_global_conf.rb +243 -0
- data/lib/akeyless/models/change_admin_account_password.rb +271 -0
- data/lib/akeyless/models/configure.rb +41 -1
- data/lib/akeyless/models/connect.rb +11 -11
- data/lib/akeyless/models/create_classic_key.rb +45 -1
- data/lib/akeyless/models/create_dfc_key.rb +45 -1
- data/lib/akeyless/models/create_pki_cert_issuer.rb +24 -2
- data/lib/akeyless/models/deactivate_acme_account.rb +282 -0
- data/lib/akeyless/models/dynamic_secret_update_artifactory.rb +1 -1
- data/lib/akeyless/models/dynamic_secret_update_aws.rb +1 -1
- data/lib/akeyless/models/dynamic_secret_update_azure.rb +1 -1
- data/lib/akeyless/models/dynamic_secret_update_cassandra.rb +1 -1
- data/lib/akeyless/models/dynamic_secret_update_chef.rb +1 -1
- data/lib/akeyless/models/dynamic_secret_update_custom.rb +1 -1
- data/lib/akeyless/models/dynamic_secret_update_dockerhub.rb +1 -1
- data/lib/akeyless/models/dynamic_secret_update_eks.rb +1 -1
- data/lib/akeyless/models/dynamic_secret_update_gcp.rb +1 -1
- data/lib/akeyless/models/dynamic_secret_update_github.rb +1 -1
- data/lib/akeyless/models/dynamic_secret_update_gitlab.rb +1 -1
- data/lib/akeyless/models/dynamic_secret_update_gke.rb +1 -1
- data/lib/akeyless/models/dynamic_secret_update_google_workspace.rb +1 -1
- data/lib/akeyless/models/dynamic_secret_update_hana_db.rb +1 -1
- data/lib/akeyless/models/dynamic_secret_update_k8s.rb +1 -1
- data/lib/akeyless/models/dynamic_secret_update_ldap.rb +1 -1
- data/lib/akeyless/models/dynamic_secret_update_mongo_db.rb +1 -1
- data/lib/akeyless/models/dynamic_secret_update_ms_sql.rb +1 -1
- data/lib/akeyless/models/dynamic_secret_update_my_sql.rb +1 -1
- data/lib/akeyless/models/dynamic_secret_update_oracle_db.rb +1 -1
- data/lib/akeyless/models/dynamic_secret_update_ping.rb +1 -1
- data/lib/akeyless/models/dynamic_secret_update_venafi.rb +1 -1
- data/lib/akeyless/models/email_pass_access_rules.rb +14 -4
- data/lib/akeyless/models/event_forwarder_create_email.rb +2 -2
- data/lib/akeyless/models/event_forwarder_create_service_now.rb +1 -1
- data/lib/akeyless/models/event_forwarder_create_slack.rb +1 -1
- data/lib/akeyless/models/event_forwarder_create_webhook.rb +1 -1
- data/lib/akeyless/models/event_forwarder_update_email.rb +2 -2
- data/lib/akeyless/models/event_forwarder_update_service_now.rb +1 -1
- data/lib/akeyless/models/event_forwarder_update_slack.rb +1 -1
- data/lib/akeyless/models/event_forwarder_update_webhook.rb +1 -1
- data/lib/akeyless/models/gateway_get_remote_access.rb +238 -0
- data/lib/akeyless/models/gateway_update_item.rb +13 -1
- data/lib/akeyless/models/gateway_update_remote_access.rb +318 -0
- data/lib/akeyless/models/gateway_update_remote_access_rdp_recordings.rb +358 -0
- data/lib/akeyless/models/generate_acme_eab.rb +254 -0
- data/lib/akeyless/models/generate_acme_eab_output.rb +232 -0
- data/lib/akeyless/models/get_group_output.rb +10 -1
- data/lib/akeyless/models/get_kube_exec_creds.rb +1 -1
- data/lib/akeyless/models/get_pki_certificate.rb +1 -1
- data/lib/akeyless/models/group.rb +10 -1
- data/lib/akeyless/models/gw_update_remote_access_session_logs_aws_s3.rb +346 -0
- data/lib/akeyless/models/gw_update_remote_access_session_logs_azure_analytics.rb +294 -0
- data/lib/akeyless/models/gw_update_remote_access_session_logs_datadog.rb +330 -0
- data/lib/akeyless/models/gw_update_remote_access_session_logs_elasticsearch.rb +376 -0
- data/lib/akeyless/models/gw_update_remote_access_session_logs_google_chronicle.rb +314 -0
- data/lib/akeyless/models/gw_update_remote_access_session_logs_logstash.rb +316 -0
- data/lib/akeyless/models/gw_update_remote_access_session_logs_logz_io.rb +294 -0
- data/lib/akeyless/models/gw_update_remote_access_session_logs_splunk.rb +350 -0
- data/lib/akeyless/models/gw_update_remote_access_session_logs_stdout.rb +274 -0
- data/lib/akeyless/models/gw_update_remote_access_session_logs_sumologic.rb +308 -0
- data/lib/akeyless/models/gw_update_remote_access_session_logs_syslog.rb +342 -0
- data/lib/akeyless/models/item_general_info.rb +23 -1
- data/lib/akeyless/models/list_acme_accounts.rb +255 -0
- data/lib/akeyless/models/list_acme_accounts_output.rb +216 -0
- data/lib/akeyless/models/next_auto_rotation_event.rb +214 -0
- data/lib/akeyless/models/password_expiration_info.rb +242 -0
- data/lib/akeyless/models/pki_certificate_issue_details.rb +19 -1
- data/lib/akeyless/models/reset_access_key.rb +255 -0
- data/lib/akeyless/models/reset_auth_method_access_key_output.rb +215 -0
- data/lib/akeyless/models/role_association_details.rb +10 -1
- data/lib/akeyless/models/role_auth_method_association.rb +10 -1
- data/lib/akeyless/models/rollback_secret.rb +13 -1
- data/lib/akeyless/models/rotated_secret_create_aws.rb +13 -1
- data/lib/akeyless/models/rotated_secret_create_azure.rb +13 -1
- data/lib/akeyless/models/rotated_secret_create_cassandra.rb +13 -1
- data/lib/akeyless/models/rotated_secret_create_custom.rb +13 -1
- data/lib/akeyless/models/rotated_secret_create_dockerhub.rb +13 -1
- data/lib/akeyless/models/rotated_secret_create_gcp.rb +13 -1
- data/lib/akeyless/models/rotated_secret_create_hanadb.rb +13 -1
- data/lib/akeyless/models/rotated_secret_create_ldap.rb +13 -1
- data/lib/akeyless/models/rotated_secret_create_mongodb.rb +13 -1
- data/lib/akeyless/models/rotated_secret_create_mssql.rb +13 -1
- data/lib/akeyless/models/rotated_secret_create_mysql.rb +13 -1
- data/lib/akeyless/models/rotated_secret_create_oracledb.rb +13 -1
- data/lib/akeyless/models/rotated_secret_create_postgresql.rb +13 -1
- data/lib/akeyless/models/rotated_secret_create_redis.rb +13 -1
- data/lib/akeyless/models/rotated_secret_create_redshift.rb +13 -1
- data/lib/akeyless/models/rotated_secret_create_snowflake.rb +13 -1
- data/lib/akeyless/models/rotated_secret_create_ssh.rb +13 -1
- data/lib/akeyless/models/rotated_secret_create_windows.rb +13 -1
- data/lib/akeyless/models/rotated_secret_update_aws.rb +13 -1
- data/lib/akeyless/models/rotated_secret_update_azure.rb +13 -1
- data/lib/akeyless/models/rotated_secret_update_cassandra.rb +13 -1
- data/lib/akeyless/models/rotated_secret_update_custom.rb +13 -1
- data/lib/akeyless/models/rotated_secret_update_dockerhub.rb +13 -1
- data/lib/akeyless/models/rotated_secret_update_gcp.rb +13 -1
- data/lib/akeyless/models/rotated_secret_update_hanadb.rb +13 -1
- data/lib/akeyless/models/rotated_secret_update_ldap.rb +13 -1
- data/lib/akeyless/models/rotated_secret_update_mongodb.rb +13 -1
- data/lib/akeyless/models/rotated_secret_update_mssql.rb +13 -1
- data/lib/akeyless/models/rotated_secret_update_mysql.rb +13 -1
- data/lib/akeyless/models/rotated_secret_update_oracledb.rb +13 -1
- data/lib/akeyless/models/rotated_secret_update_postgresql.rb +13 -1
- data/lib/akeyless/models/rotated_secret_update_redis.rb +13 -1
- data/lib/akeyless/models/rotated_secret_update_redshift.rb +13 -1
- data/lib/akeyless/models/rotated_secret_update_snowflake.rb +13 -1
- data/lib/akeyless/models/rotated_secret_update_ssh.rb +13 -1
- data/lib/akeyless/models/rotated_secret_update_windows.rb +13 -1
- data/lib/akeyless/models/ssh_bastion_conf.rb +241 -0
- data/lib/akeyless/models/ssh_bastion_session_termination.rb +250 -0
- data/lib/akeyless/models/update_account_settings.rb +31 -1
- data/lib/akeyless/models/update_classic_key_certificate.rb +10 -1
- data/lib/akeyless/models/update_item.rb +22 -1
- data/lib/akeyless/models/update_pki_cert_issuer.rb +24 -2
- data/lib/akeyless/models/update_rotation_settings.rb +13 -1
- data/lib/akeyless/models/update_target.rb +1 -1
- data/lib/akeyless/models/upload_rsa.rb +13 -1
- data/lib/akeyless/models/web_bastion_conf.rb +223 -0
- data/lib/akeyless/models/web_bastion_guacamole.rb +214 -0
- data/lib/akeyless/models/web_bastion_rdp_record.rb +232 -0
- data/lib/akeyless/version.rb +1 -1
- data/lib/akeyless.rb +34 -0
- data/spec/models/acme_account_spec.rb +48 -0
- data/spec/models/aws_storage_spec.rb +66 -0
- data/spec/models/azure_storage_spec.rb +66 -0
- data/spec/models/bastion_config_reply_obj_spec.rb +66 -0
- data/spec/models/bastion_global_conf_spec.rb +54 -0
- data/spec/models/change_admin_account_password_spec.rb +60 -0
- data/spec/models/deactivate_acme_account_spec.rb +66 -0
- data/spec/models/gateway_get_remote_access_spec.rb +48 -0
- data/spec/models/gateway_update_remote_access_rdp_recordings_spec.rb +120 -0
- data/spec/models/gateway_update_remote_access_spec.rb +90 -0
- data/spec/models/generate_acme_eab_output_spec.rb +48 -0
- data/spec/models/generate_acme_eab_spec.rb +54 -0
- data/spec/models/gw_update_remote_access_session_logs_aws_s3_spec.rb +108 -0
- data/spec/models/gw_update_remote_access_session_logs_azure_analytics_spec.rb +78 -0
- data/spec/models/gw_update_remote_access_session_logs_datadog_spec.rb +96 -0
- data/spec/models/gw_update_remote_access_session_logs_elasticsearch_spec.rb +126 -0
- data/spec/models/gw_update_remote_access_session_logs_google_chronicle_spec.rb +90 -0
- data/spec/models/gw_update_remote_access_session_logs_logstash_spec.rb +90 -0
- data/spec/models/gw_update_remote_access_session_logs_logz_io_spec.rb +78 -0
- data/spec/models/gw_update_remote_access_session_logs_splunk_spec.rb +108 -0
- data/spec/models/gw_update_remote_access_session_logs_stdout_spec.rb +66 -0
- data/spec/models/gw_update_remote_access_session_logs_sumologic_spec.rb +84 -0
- data/spec/models/gw_update_remote_access_session_logs_syslog_spec.rb +102 -0
- data/spec/models/list_acme_accounts_output_spec.rb +36 -0
- data/spec/models/list_acme_accounts_spec.rb +54 -0
- data/spec/models/next_auto_rotation_event_spec.rb +36 -0
- data/spec/models/password_expiration_info_spec.rb +54 -0
- data/spec/models/reset_access_key_spec.rb +54 -0
- data/spec/models/reset_auth_method_access_key_output_spec.rb +36 -0
- data/spec/models/ssh_bastion_conf_spec.rb +54 -0
- data/spec/models/ssh_bastion_session_termination_spec.rb +60 -0
- data/spec/models/web_bastion_conf_spec.rb +42 -0
- data/spec/models/web_bastion_guacamole_spec.rb +36 -0
- data/spec/models/web_bastion_rdp_record_spec.rb +48 -0
- metadata +1117 -981
@@ -0,0 +1,358 @@
|
|
1
|
+
=begin
|
2
|
+
#Akeyless API
|
3
|
+
|
4
|
+
#The purpose of this application is to provide access to Akeyless API.
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 2.0
|
7
|
+
Contact: support@akeyless.io
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
Generator version: 7.9.0-SNAPSHOT
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
require 'time'
|
15
|
+
|
16
|
+
module Akeyless
|
17
|
+
# gatewayUpdateRemoteAccessRdpRecordings is a command that update remote access rdp recording config
|
18
|
+
class GatewayUpdateRemoteAccessRdpRecordings
|
19
|
+
# AWS access key id. For more information refer to https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_access-keys.html
|
20
|
+
attr_accessor :aws_storage_access_key_id
|
21
|
+
|
22
|
+
# The AWS bucket name. For more information refer to https://docs.aws.amazon.com/s3/
|
23
|
+
attr_accessor :aws_storage_bucket_name
|
24
|
+
|
25
|
+
# The folder name in S3 bucket. For more information refer to https://docs.aws.amazon.com/s3/
|
26
|
+
attr_accessor :aws_storage_bucket_prefix
|
27
|
+
|
28
|
+
# The region where the storage is located
|
29
|
+
attr_accessor :aws_storage_region
|
30
|
+
|
31
|
+
# AWS secret access key. For more information refer to https://docs.aws.amazon.com/IAM/latest/UserGuide/id_credentials_access-keys.html
|
32
|
+
attr_accessor :aws_storage_secret_access_key
|
33
|
+
|
34
|
+
# Azure account name. For more information refer to https://learn.microsoft.com/en-us/azure/storage/common/storage-account-overview
|
35
|
+
attr_accessor :azure_storage_account_name
|
36
|
+
|
37
|
+
# Azure client id. For more information refer to https://learn.microsoft.com/en-us/azure/storage/common/storage-account-get-info?tabs=portal
|
38
|
+
attr_accessor :azure_storage_client_id
|
39
|
+
|
40
|
+
# Azure client secret. For more information refer to https://learn.microsoft.com/en-us/azure/storage/common/storage-account-get-info?tabs=portal
|
41
|
+
attr_accessor :azure_storage_client_secret
|
42
|
+
|
43
|
+
# Azure container name. For more information refer to https://learn.microsoft.com/en-us/rest/api/storageservices/naming-and-referencing-containers--blobs--and-metadata
|
44
|
+
attr_accessor :azure_storage_container_name
|
45
|
+
|
46
|
+
# Azure tenant id. For more information refer to https://learn.microsoft.com/en-us/entra/fundamentals/how-to-find-tenant
|
47
|
+
attr_accessor :azure_storage_tenant_id
|
48
|
+
|
49
|
+
# Set output format to JSON
|
50
|
+
attr_accessor :json
|
51
|
+
|
52
|
+
# Enable recording of rdp session [true/false]
|
53
|
+
attr_accessor :rdp_session_recording
|
54
|
+
|
55
|
+
# Rdp session recording storage destination [local/aws/azure]
|
56
|
+
attr_accessor :rdp_session_storage
|
57
|
+
|
58
|
+
# Authentication token (see `/auth` and `/configure`)
|
59
|
+
attr_accessor :token
|
60
|
+
|
61
|
+
# The universal identity token, Required only for universal_identity authentication
|
62
|
+
attr_accessor :uid_token
|
63
|
+
|
64
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
65
|
+
def self.attribute_map
|
66
|
+
{
|
67
|
+
:'aws_storage_access_key_id' => :'aws-storage-access-key-id',
|
68
|
+
:'aws_storage_bucket_name' => :'aws-storage-bucket-name',
|
69
|
+
:'aws_storage_bucket_prefix' => :'aws-storage-bucket-prefix',
|
70
|
+
:'aws_storage_region' => :'aws-storage-region',
|
71
|
+
:'aws_storage_secret_access_key' => :'aws-storage-secret-access-key',
|
72
|
+
:'azure_storage_account_name' => :'azure-storage-account-name',
|
73
|
+
:'azure_storage_client_id' => :'azure-storage-client-id',
|
74
|
+
:'azure_storage_client_secret' => :'azure-storage-client-secret',
|
75
|
+
:'azure_storage_container_name' => :'azure-storage-container-name',
|
76
|
+
:'azure_storage_tenant_id' => :'azure-storage-tenant-id',
|
77
|
+
:'json' => :'json',
|
78
|
+
:'rdp_session_recording' => :'rdp-session-recording',
|
79
|
+
:'rdp_session_storage' => :'rdp-session-storage',
|
80
|
+
:'token' => :'token',
|
81
|
+
:'uid_token' => :'uid-token'
|
82
|
+
}
|
83
|
+
end
|
84
|
+
|
85
|
+
# Returns all the JSON keys this model knows about
|
86
|
+
def self.acceptable_attributes
|
87
|
+
attribute_map.values
|
88
|
+
end
|
89
|
+
|
90
|
+
# Attribute type mapping.
|
91
|
+
def self.openapi_types
|
92
|
+
{
|
93
|
+
:'aws_storage_access_key_id' => :'String',
|
94
|
+
:'aws_storage_bucket_name' => :'String',
|
95
|
+
:'aws_storage_bucket_prefix' => :'String',
|
96
|
+
:'aws_storage_region' => :'String',
|
97
|
+
:'aws_storage_secret_access_key' => :'String',
|
98
|
+
:'azure_storage_account_name' => :'String',
|
99
|
+
:'azure_storage_client_id' => :'String',
|
100
|
+
:'azure_storage_client_secret' => :'String',
|
101
|
+
:'azure_storage_container_name' => :'String',
|
102
|
+
:'azure_storage_tenant_id' => :'String',
|
103
|
+
:'json' => :'Boolean',
|
104
|
+
:'rdp_session_recording' => :'String',
|
105
|
+
:'rdp_session_storage' => :'String',
|
106
|
+
:'token' => :'String',
|
107
|
+
:'uid_token' => :'String'
|
108
|
+
}
|
109
|
+
end
|
110
|
+
|
111
|
+
# List of attributes with nullable: true
|
112
|
+
def self.openapi_nullable
|
113
|
+
Set.new([
|
114
|
+
])
|
115
|
+
end
|
116
|
+
|
117
|
+
# Initializes the object
|
118
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
119
|
+
def initialize(attributes = {})
|
120
|
+
if (!attributes.is_a?(Hash))
|
121
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `Akeyless::GatewayUpdateRemoteAccessRdpRecordings` initialize method"
|
122
|
+
end
|
123
|
+
|
124
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
125
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
126
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
127
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `Akeyless::GatewayUpdateRemoteAccessRdpRecordings`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
128
|
+
end
|
129
|
+
h[k.to_sym] = v
|
130
|
+
}
|
131
|
+
|
132
|
+
if attributes.key?(:'aws_storage_access_key_id')
|
133
|
+
self.aws_storage_access_key_id = attributes[:'aws_storage_access_key_id']
|
134
|
+
end
|
135
|
+
|
136
|
+
if attributes.key?(:'aws_storage_bucket_name')
|
137
|
+
self.aws_storage_bucket_name = attributes[:'aws_storage_bucket_name']
|
138
|
+
end
|
139
|
+
|
140
|
+
if attributes.key?(:'aws_storage_bucket_prefix')
|
141
|
+
self.aws_storage_bucket_prefix = attributes[:'aws_storage_bucket_prefix']
|
142
|
+
end
|
143
|
+
|
144
|
+
if attributes.key?(:'aws_storage_region')
|
145
|
+
self.aws_storage_region = attributes[:'aws_storage_region']
|
146
|
+
end
|
147
|
+
|
148
|
+
if attributes.key?(:'aws_storage_secret_access_key')
|
149
|
+
self.aws_storage_secret_access_key = attributes[:'aws_storage_secret_access_key']
|
150
|
+
end
|
151
|
+
|
152
|
+
if attributes.key?(:'azure_storage_account_name')
|
153
|
+
self.azure_storage_account_name = attributes[:'azure_storage_account_name']
|
154
|
+
end
|
155
|
+
|
156
|
+
if attributes.key?(:'azure_storage_client_id')
|
157
|
+
self.azure_storage_client_id = attributes[:'azure_storage_client_id']
|
158
|
+
end
|
159
|
+
|
160
|
+
if attributes.key?(:'azure_storage_client_secret')
|
161
|
+
self.azure_storage_client_secret = attributes[:'azure_storage_client_secret']
|
162
|
+
end
|
163
|
+
|
164
|
+
if attributes.key?(:'azure_storage_container_name')
|
165
|
+
self.azure_storage_container_name = attributes[:'azure_storage_container_name']
|
166
|
+
end
|
167
|
+
|
168
|
+
if attributes.key?(:'azure_storage_tenant_id')
|
169
|
+
self.azure_storage_tenant_id = attributes[:'azure_storage_tenant_id']
|
170
|
+
end
|
171
|
+
|
172
|
+
if attributes.key?(:'json')
|
173
|
+
self.json = attributes[:'json']
|
174
|
+
else
|
175
|
+
self.json = false
|
176
|
+
end
|
177
|
+
|
178
|
+
if attributes.key?(:'rdp_session_recording')
|
179
|
+
self.rdp_session_recording = attributes[:'rdp_session_recording']
|
180
|
+
end
|
181
|
+
|
182
|
+
if attributes.key?(:'rdp_session_storage')
|
183
|
+
self.rdp_session_storage = attributes[:'rdp_session_storage']
|
184
|
+
end
|
185
|
+
|
186
|
+
if attributes.key?(:'token')
|
187
|
+
self.token = attributes[:'token']
|
188
|
+
end
|
189
|
+
|
190
|
+
if attributes.key?(:'uid_token')
|
191
|
+
self.uid_token = attributes[:'uid_token']
|
192
|
+
end
|
193
|
+
end
|
194
|
+
|
195
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
196
|
+
# @return Array for valid properties with the reasons
|
197
|
+
def list_invalid_properties
|
198
|
+
warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
|
199
|
+
invalid_properties = Array.new
|
200
|
+
invalid_properties
|
201
|
+
end
|
202
|
+
|
203
|
+
# Check to see if the all the properties in the model are valid
|
204
|
+
# @return true if the model is valid
|
205
|
+
def valid?
|
206
|
+
warn '[DEPRECATED] the `valid?` method is obsolete'
|
207
|
+
true
|
208
|
+
end
|
209
|
+
|
210
|
+
# Checks equality by comparing each attribute.
|
211
|
+
# @param [Object] Object to be compared
|
212
|
+
def ==(o)
|
213
|
+
return true if self.equal?(o)
|
214
|
+
self.class == o.class &&
|
215
|
+
aws_storage_access_key_id == o.aws_storage_access_key_id &&
|
216
|
+
aws_storage_bucket_name == o.aws_storage_bucket_name &&
|
217
|
+
aws_storage_bucket_prefix == o.aws_storage_bucket_prefix &&
|
218
|
+
aws_storage_region == o.aws_storage_region &&
|
219
|
+
aws_storage_secret_access_key == o.aws_storage_secret_access_key &&
|
220
|
+
azure_storage_account_name == o.azure_storage_account_name &&
|
221
|
+
azure_storage_client_id == o.azure_storage_client_id &&
|
222
|
+
azure_storage_client_secret == o.azure_storage_client_secret &&
|
223
|
+
azure_storage_container_name == o.azure_storage_container_name &&
|
224
|
+
azure_storage_tenant_id == o.azure_storage_tenant_id &&
|
225
|
+
json == o.json &&
|
226
|
+
rdp_session_recording == o.rdp_session_recording &&
|
227
|
+
rdp_session_storage == o.rdp_session_storage &&
|
228
|
+
token == o.token &&
|
229
|
+
uid_token == o.uid_token
|
230
|
+
end
|
231
|
+
|
232
|
+
# @see the `==` method
|
233
|
+
# @param [Object] Object to be compared
|
234
|
+
def eql?(o)
|
235
|
+
self == o
|
236
|
+
end
|
237
|
+
|
238
|
+
# Calculates hash code according to all attributes.
|
239
|
+
# @return [Integer] Hash code
|
240
|
+
def hash
|
241
|
+
[aws_storage_access_key_id, aws_storage_bucket_name, aws_storage_bucket_prefix, aws_storage_region, aws_storage_secret_access_key, azure_storage_account_name, azure_storage_client_id, azure_storage_client_secret, azure_storage_container_name, azure_storage_tenant_id, json, rdp_session_recording, rdp_session_storage, token, uid_token].hash
|
242
|
+
end
|
243
|
+
|
244
|
+
# Builds the object from hash
|
245
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
246
|
+
# @return [Object] Returns the model itself
|
247
|
+
def self.build_from_hash(attributes)
|
248
|
+
return nil unless attributes.is_a?(Hash)
|
249
|
+
attributes = attributes.transform_keys(&:to_sym)
|
250
|
+
transformed_hash = {}
|
251
|
+
openapi_types.each_pair do |key, type|
|
252
|
+
if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
|
253
|
+
transformed_hash["#{key}"] = nil
|
254
|
+
elsif type =~ /\AArray<(.*)>/i
|
255
|
+
# check to ensure the input is an array given that the attribute
|
256
|
+
# is documented as an array but the input is not
|
257
|
+
if attributes[attribute_map[key]].is_a?(Array)
|
258
|
+
transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
|
259
|
+
end
|
260
|
+
elsif !attributes[attribute_map[key]].nil?
|
261
|
+
transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
|
262
|
+
end
|
263
|
+
end
|
264
|
+
new(transformed_hash)
|
265
|
+
end
|
266
|
+
|
267
|
+
# Deserializes the data based on type
|
268
|
+
# @param string type Data type
|
269
|
+
# @param string value Value to be deserialized
|
270
|
+
# @return [Object] Deserialized data
|
271
|
+
def self._deserialize(type, value)
|
272
|
+
case type.to_sym
|
273
|
+
when :Time
|
274
|
+
Time.parse(value)
|
275
|
+
when :Date
|
276
|
+
Date.parse(value)
|
277
|
+
when :String
|
278
|
+
value.to_s
|
279
|
+
when :Integer
|
280
|
+
value.to_i
|
281
|
+
when :Float
|
282
|
+
value.to_f
|
283
|
+
when :Boolean
|
284
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
285
|
+
true
|
286
|
+
else
|
287
|
+
false
|
288
|
+
end
|
289
|
+
when :Object
|
290
|
+
# generic object (usually a Hash), return directly
|
291
|
+
value
|
292
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
293
|
+
inner_type = Regexp.last_match[:inner_type]
|
294
|
+
value.map { |v| _deserialize(inner_type, v) }
|
295
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
296
|
+
k_type = Regexp.last_match[:k_type]
|
297
|
+
v_type = Regexp.last_match[:v_type]
|
298
|
+
{}.tap do |hash|
|
299
|
+
value.each do |k, v|
|
300
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
301
|
+
end
|
302
|
+
end
|
303
|
+
else # model
|
304
|
+
# models (e.g. Pet) or oneOf
|
305
|
+
klass = Akeyless.const_get(type)
|
306
|
+
klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
307
|
+
end
|
308
|
+
end
|
309
|
+
|
310
|
+
# Returns the string representation of the object
|
311
|
+
# @return [String] String presentation of the object
|
312
|
+
def to_s
|
313
|
+
to_hash.to_s
|
314
|
+
end
|
315
|
+
|
316
|
+
# to_body is an alias to to_hash (backward compatibility)
|
317
|
+
# @return [Hash] Returns the object in the form of hash
|
318
|
+
def to_body
|
319
|
+
to_hash
|
320
|
+
end
|
321
|
+
|
322
|
+
# Returns the object in the form of hash
|
323
|
+
# @return [Hash] Returns the object in the form of hash
|
324
|
+
def to_hash
|
325
|
+
hash = {}
|
326
|
+
self.class.attribute_map.each_pair do |attr, param|
|
327
|
+
value = self.send(attr)
|
328
|
+
if value.nil?
|
329
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
330
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
331
|
+
end
|
332
|
+
|
333
|
+
hash[param] = _to_hash(value)
|
334
|
+
end
|
335
|
+
hash
|
336
|
+
end
|
337
|
+
|
338
|
+
# Outputs non-array value in the form of hash
|
339
|
+
# For object, use to_hash. Otherwise, just return the value
|
340
|
+
# @param [Object] value Any valid value
|
341
|
+
# @return [Hash] Returns the value in the form of hash
|
342
|
+
def _to_hash(value)
|
343
|
+
if value.is_a?(Array)
|
344
|
+
value.compact.map { |v| _to_hash(v) }
|
345
|
+
elsif value.is_a?(Hash)
|
346
|
+
{}.tap do |hash|
|
347
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
348
|
+
end
|
349
|
+
elsif value.respond_to? :to_hash
|
350
|
+
value.to_hash
|
351
|
+
else
|
352
|
+
value
|
353
|
+
end
|
354
|
+
end
|
355
|
+
|
356
|
+
end
|
357
|
+
|
358
|
+
end
|
@@ -0,0 +1,254 @@
|
|
1
|
+
=begin
|
2
|
+
#Akeyless API
|
3
|
+
|
4
|
+
#The purpose of this application is to provide access to Akeyless API.
|
5
|
+
|
6
|
+
The version of the OpenAPI document: 2.0
|
7
|
+
Contact: support@akeyless.io
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
Generator version: 7.9.0-SNAPSHOT
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
require 'time'
|
15
|
+
|
16
|
+
module Akeyless
|
17
|
+
class GenerateAcmeEab
|
18
|
+
# The name of the PKI certificate issuer
|
19
|
+
attr_accessor :cert_issuer_name
|
20
|
+
|
21
|
+
# Set output format to JSON
|
22
|
+
attr_accessor :json
|
23
|
+
|
24
|
+
# Authentication token (see `/auth` and `/configure`)
|
25
|
+
attr_accessor :token
|
26
|
+
|
27
|
+
# The universal identity token, Required only for universal_identity authentication
|
28
|
+
attr_accessor :uid_token
|
29
|
+
|
30
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
31
|
+
def self.attribute_map
|
32
|
+
{
|
33
|
+
:'cert_issuer_name' => :'cert-issuer-name',
|
34
|
+
:'json' => :'json',
|
35
|
+
:'token' => :'token',
|
36
|
+
:'uid_token' => :'uid-token'
|
37
|
+
}
|
38
|
+
end
|
39
|
+
|
40
|
+
# Returns all the JSON keys this model knows about
|
41
|
+
def self.acceptable_attributes
|
42
|
+
attribute_map.values
|
43
|
+
end
|
44
|
+
|
45
|
+
# Attribute type mapping.
|
46
|
+
def self.openapi_types
|
47
|
+
{
|
48
|
+
:'cert_issuer_name' => :'String',
|
49
|
+
:'json' => :'Boolean',
|
50
|
+
:'token' => :'String',
|
51
|
+
:'uid_token' => :'String'
|
52
|
+
}
|
53
|
+
end
|
54
|
+
|
55
|
+
# List of attributes with nullable: true
|
56
|
+
def self.openapi_nullable
|
57
|
+
Set.new([
|
58
|
+
])
|
59
|
+
end
|
60
|
+
|
61
|
+
# Initializes the object
|
62
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
63
|
+
def initialize(attributes = {})
|
64
|
+
if (!attributes.is_a?(Hash))
|
65
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `Akeyless::GenerateAcmeEab` initialize method"
|
66
|
+
end
|
67
|
+
|
68
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
69
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
70
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
71
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `Akeyless::GenerateAcmeEab`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
72
|
+
end
|
73
|
+
h[k.to_sym] = v
|
74
|
+
}
|
75
|
+
|
76
|
+
if attributes.key?(:'cert_issuer_name')
|
77
|
+
self.cert_issuer_name = attributes[:'cert_issuer_name']
|
78
|
+
else
|
79
|
+
self.cert_issuer_name = nil
|
80
|
+
end
|
81
|
+
|
82
|
+
if attributes.key?(:'json')
|
83
|
+
self.json = attributes[:'json']
|
84
|
+
else
|
85
|
+
self.json = false
|
86
|
+
end
|
87
|
+
|
88
|
+
if attributes.key?(:'token')
|
89
|
+
self.token = attributes[:'token']
|
90
|
+
end
|
91
|
+
|
92
|
+
if attributes.key?(:'uid_token')
|
93
|
+
self.uid_token = attributes[:'uid_token']
|
94
|
+
end
|
95
|
+
end
|
96
|
+
|
97
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
98
|
+
# @return Array for valid properties with the reasons
|
99
|
+
def list_invalid_properties
|
100
|
+
warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
|
101
|
+
invalid_properties = Array.new
|
102
|
+
if @cert_issuer_name.nil?
|
103
|
+
invalid_properties.push('invalid value for "cert_issuer_name", cert_issuer_name cannot be nil.')
|
104
|
+
end
|
105
|
+
|
106
|
+
invalid_properties
|
107
|
+
end
|
108
|
+
|
109
|
+
# Check to see if the all the properties in the model are valid
|
110
|
+
# @return true if the model is valid
|
111
|
+
def valid?
|
112
|
+
warn '[DEPRECATED] the `valid?` method is obsolete'
|
113
|
+
return false if @cert_issuer_name.nil?
|
114
|
+
true
|
115
|
+
end
|
116
|
+
|
117
|
+
# Checks equality by comparing each attribute.
|
118
|
+
# @param [Object] Object to be compared
|
119
|
+
def ==(o)
|
120
|
+
return true if self.equal?(o)
|
121
|
+
self.class == o.class &&
|
122
|
+
cert_issuer_name == o.cert_issuer_name &&
|
123
|
+
json == o.json &&
|
124
|
+
token == o.token &&
|
125
|
+
uid_token == o.uid_token
|
126
|
+
end
|
127
|
+
|
128
|
+
# @see the `==` method
|
129
|
+
# @param [Object] Object to be compared
|
130
|
+
def eql?(o)
|
131
|
+
self == o
|
132
|
+
end
|
133
|
+
|
134
|
+
# Calculates hash code according to all attributes.
|
135
|
+
# @return [Integer] Hash code
|
136
|
+
def hash
|
137
|
+
[cert_issuer_name, json, token, uid_token].hash
|
138
|
+
end
|
139
|
+
|
140
|
+
# Builds the object from hash
|
141
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
142
|
+
# @return [Object] Returns the model itself
|
143
|
+
def self.build_from_hash(attributes)
|
144
|
+
return nil unless attributes.is_a?(Hash)
|
145
|
+
attributes = attributes.transform_keys(&:to_sym)
|
146
|
+
transformed_hash = {}
|
147
|
+
openapi_types.each_pair do |key, type|
|
148
|
+
if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
|
149
|
+
transformed_hash["#{key}"] = nil
|
150
|
+
elsif type =~ /\AArray<(.*)>/i
|
151
|
+
# check to ensure the input is an array given that the attribute
|
152
|
+
# is documented as an array but the input is not
|
153
|
+
if attributes[attribute_map[key]].is_a?(Array)
|
154
|
+
transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
|
155
|
+
end
|
156
|
+
elsif !attributes[attribute_map[key]].nil?
|
157
|
+
transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
|
158
|
+
end
|
159
|
+
end
|
160
|
+
new(transformed_hash)
|
161
|
+
end
|
162
|
+
|
163
|
+
# Deserializes the data based on type
|
164
|
+
# @param string type Data type
|
165
|
+
# @param string value Value to be deserialized
|
166
|
+
# @return [Object] Deserialized data
|
167
|
+
def self._deserialize(type, value)
|
168
|
+
case type.to_sym
|
169
|
+
when :Time
|
170
|
+
Time.parse(value)
|
171
|
+
when :Date
|
172
|
+
Date.parse(value)
|
173
|
+
when :String
|
174
|
+
value.to_s
|
175
|
+
when :Integer
|
176
|
+
value.to_i
|
177
|
+
when :Float
|
178
|
+
value.to_f
|
179
|
+
when :Boolean
|
180
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
181
|
+
true
|
182
|
+
else
|
183
|
+
false
|
184
|
+
end
|
185
|
+
when :Object
|
186
|
+
# generic object (usually a Hash), return directly
|
187
|
+
value
|
188
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
189
|
+
inner_type = Regexp.last_match[:inner_type]
|
190
|
+
value.map { |v| _deserialize(inner_type, v) }
|
191
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
192
|
+
k_type = Regexp.last_match[:k_type]
|
193
|
+
v_type = Regexp.last_match[:v_type]
|
194
|
+
{}.tap do |hash|
|
195
|
+
value.each do |k, v|
|
196
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
197
|
+
end
|
198
|
+
end
|
199
|
+
else # model
|
200
|
+
# models (e.g. Pet) or oneOf
|
201
|
+
klass = Akeyless.const_get(type)
|
202
|
+
klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
203
|
+
end
|
204
|
+
end
|
205
|
+
|
206
|
+
# Returns the string representation of the object
|
207
|
+
# @return [String] String presentation of the object
|
208
|
+
def to_s
|
209
|
+
to_hash.to_s
|
210
|
+
end
|
211
|
+
|
212
|
+
# to_body is an alias to to_hash (backward compatibility)
|
213
|
+
# @return [Hash] Returns the object in the form of hash
|
214
|
+
def to_body
|
215
|
+
to_hash
|
216
|
+
end
|
217
|
+
|
218
|
+
# Returns the object in the form of hash
|
219
|
+
# @return [Hash] Returns the object in the form of hash
|
220
|
+
def to_hash
|
221
|
+
hash = {}
|
222
|
+
self.class.attribute_map.each_pair do |attr, param|
|
223
|
+
value = self.send(attr)
|
224
|
+
if value.nil?
|
225
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
226
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
227
|
+
end
|
228
|
+
|
229
|
+
hash[param] = _to_hash(value)
|
230
|
+
end
|
231
|
+
hash
|
232
|
+
end
|
233
|
+
|
234
|
+
# Outputs non-array value in the form of hash
|
235
|
+
# For object, use to_hash. Otherwise, just return the value
|
236
|
+
# @param [Object] value Any valid value
|
237
|
+
# @return [Hash] Returns the value in the form of hash
|
238
|
+
def _to_hash(value)
|
239
|
+
if value.is_a?(Array)
|
240
|
+
value.compact.map { |v| _to_hash(v) }
|
241
|
+
elsif value.is_a?(Hash)
|
242
|
+
{}.tap do |hash|
|
243
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
244
|
+
end
|
245
|
+
elsif value.respond_to? :to_hash
|
246
|
+
value.to_hash
|
247
|
+
else
|
248
|
+
value
|
249
|
+
end
|
250
|
+
end
|
251
|
+
|
252
|
+
end
|
253
|
+
|
254
|
+
end
|