plainrouter-sdk 0.1.1 → 0.5.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 +11 -4
- data/lib/plainrouter/client.rb +75 -2
- data/lib/plainrouter/openapi/api/action_dry_run_api_api.rb +96 -0
- data/lib/plainrouter/openapi/api/action_proposal_api_api.rb +96 -0
- data/lib/plainrouter/openapi/api/action_read_api_api.rb +404 -0
- data/lib/plainrouter/openapi/api/ad_test_api_api.rb +259 -0
- data/lib/plainrouter/openapi/api/cookie_declaration_api.rb +90 -0
- data/lib/plainrouter/openapi/api/creative_api.rb +181 -0
- data/lib/plainrouter/openapi/api/deployment_plan_api.rb +306 -0
- data/lib/plainrouter/openapi/api/event_api.rb +15 -15
- data/lib/plainrouter/openapi/api/meta_inventory_exposure_api.rb +121 -0
- data/lib/plainrouter/openapi/api/operations_api.rb +24 -28
- data/lib/plainrouter/openapi/api/sandbox_api.rb +74 -17
- data/lib/plainrouter/openapi/api_client.rb +2 -2
- data/lib/plainrouter/openapi/api_error.rb +2 -2
- data/lib/plainrouter/openapi/api_model_base.rb +2 -2
- data/lib/plainrouter/openapi/configuration.rb +52 -3
- data/lib/plainrouter/openapi/models/action_batch_read.rb +164 -0
- data/lib/plainrouter/openapi/models/action_batch_read_data.rb +450 -0
- data/lib/plainrouter/openapi/models/action_current_disposition.rb +306 -0
- data/lib/plainrouter/openapi/models/action_current_disposition_outcome_payload.rb +238 -0
- data/lib/plainrouter/openapi/models/action_current_disposition_outcome_payload_baseline.rb +103 -0
- data/lib/plainrouter/openapi/models/action_current_disposition_outcome_payload_baseline_any_of.rb +245 -0
- data/lib/plainrouter/openapi/models/action_current_disposition_outcome_payload_inverse.rb +206 -0
- data/lib/plainrouter/openapi/models/action_current_disposition_outcome_payload_metrics.rb +103 -0
- data/lib/plainrouter/openapi/models/action_current_disposition_outcome_payload_metrics_any_of.rb +276 -0
- data/lib/plainrouter/openapi/models/action_decision_receipt_read.rb +244 -0
- data/lib/plainrouter/openapi/models/action_decision_receipt_read_chain_entry.rb +190 -0
- data/lib/plainrouter/openapi/models/action_detail_read.rb +164 -0
- data/lib/plainrouter/openapi/models/action_dry_run_read.rb +164 -0
- data/lib/plainrouter/openapi/models/action_dry_run_read_dry_run.rb +166 -0
- data/lib/plainrouter/openapi/models/action_dry_run_read_dry_run_actions_inner.rb +103 -0
- data/lib/plainrouter/openapi/models/action_dry_run_read_dry_run_actions_inner_any_of.rb +376 -0
- data/lib/plainrouter/openapi/models/action_dry_run_read_dry_run_actions_inner_any_of1.rb +268 -0
- data/lib/plainrouter/openapi/models/action_dry_run_read_dry_run_actions_inner_any_of_diff.rb +162 -0
- data/lib/plainrouter/openapi/models/action_dry_run_read_dry_run_actions_inner_any_of_target_entity.rb +199 -0
- data/lib/plainrouter/openapi/models/action_list_read.rb +192 -0
- data/lib/plainrouter/openapi/models/action_list_read_meta.rb +242 -0
- data/lib/plainrouter/openapi/models/action_policy_read.rb +164 -0
- data/lib/plainrouter/openapi/models/action_policy_read_data.rb +278 -0
- data/lib/plainrouter/openapi/models/action_policy_result.rb +374 -0
- data/lib/plainrouter/openapi/models/action_proposal_input.rb +406 -0
- data/lib/plainrouter/openapi/models/action_proposal_input_actions_inner.rb +115 -0
- data/lib/plainrouter/openapi/models/action_proposal_input_actions_inner_any_of.rb +303 -0
- data/lib/plainrouter/openapi/models/action_proposal_input_actions_inner_any_of1.rb +303 -0
- data/lib/plainrouter/openapi/models/action_proposal_input_actions_inner_any_of10.rb +303 -0
- data/lib/plainrouter/openapi/models/action_proposal_input_actions_inner_any_of10_params.rb +356 -0
- data/lib/plainrouter/openapi/models/action_proposal_input_actions_inner_any_of11.rb +303 -0
- data/lib/plainrouter/openapi/models/action_proposal_input_actions_inner_any_of11_params.rb +173 -0
- data/lib/plainrouter/openapi/models/action_proposal_input_actions_inner_any_of12.rb +303 -0
- data/lib/plainrouter/openapi/models/action_proposal_input_actions_inner_any_of12_params.rb +188 -0
- data/lib/plainrouter/openapi/models/action_proposal_input_actions_inner_any_of13.rb +303 -0
- data/lib/plainrouter/openapi/models/action_proposal_input_actions_inner_any_of13_params.rb +259 -0
- data/lib/plainrouter/openapi/models/action_proposal_input_actions_inner_any_of2.rb +303 -0
- data/lib/plainrouter/openapi/models/action_proposal_input_actions_inner_any_of3.rb +303 -0
- data/lib/plainrouter/openapi/models/action_proposal_input_actions_inner_any_of4.rb +303 -0
- data/lib/plainrouter/openapi/models/action_proposal_input_actions_inner_any_of4_target_entity.rb +253 -0
- data/lib/plainrouter/openapi/models/action_proposal_input_actions_inner_any_of5.rb +303 -0
- data/lib/plainrouter/openapi/models/action_proposal_input_actions_inner_any_of6.rb +303 -0
- data/lib/plainrouter/openapi/models/action_proposal_input_actions_inner_any_of7.rb +303 -0
- data/lib/plainrouter/openapi/models/action_proposal_input_actions_inner_any_of8.rb +303 -0
- data/lib/plainrouter/openapi/models/action_proposal_input_actions_inner_any_of9.rb +303 -0
- data/lib/plainrouter/openapi/models/action_proposal_input_actions_inner_any_of_params.rb +173 -0
- data/lib/plainrouter/openapi/models/action_proposal_input_actions_inner_any_of_target_entity.rb +264 -0
- data/lib/plainrouter/openapi/models/action_proposal_input_evidence_inner.rb +262 -0
- data/lib/plainrouter/openapi/models/action_proposal_read.rb +164 -0
- data/lib/plainrouter/openapi/models/action_proposal_read_proposal.rb +452 -0
- data/lib/plainrouter/openapi/models/action_proposal_read_proposal_actions_inner.rb +386 -0
- data/lib/plainrouter/openapi/models/action_proposal_read_proposal_actions_inner_params.rb +103 -0
- data/lib/plainrouter/openapi/models/action_proposal_read_proposal_proposed_by.rb +202 -0
- data/lib/plainrouter/openapi/models/action_read_item.rb +574 -0
- data/lib/plainrouter/openapi/models/action_read_item_evidence.rb +105 -0
- data/lib/plainrouter/openapi/models/action_read_item_evidence_any_of.rb +190 -0
- data/lib/plainrouter/openapi/models/action_read_item_evidence_any_of1.rb +242 -0
- data/lib/plainrouter/openapi/models/action_read_item_evidence_any_of2.rb +217 -0
- data/lib/plainrouter/openapi/models/action_read_item_evidence_any_of_outcome.rb +238 -0
- data/lib/plainrouter/openapi/models/action_read_item_proposer.rb +198 -0
- data/lib/plainrouter/openapi/models/actions_api_dry_run401_response.rb +103 -0
- data/lib/plainrouter/openapi/models/actions_tests_api_index404_response.rb +103 -0
- data/lib/plainrouter/openapi/models/actions_tests_api_store_request.rb +467 -0
- data/lib/plainrouter/openapi/models/actions_tests_api_store_request_maximum_spend_minor.rb +104 -0
- data/lib/plainrouter/openapi/models/ad_test.rb +552 -0
- data/lib/plainrouter/openapi/models/ad_test_create_read.rb +164 -0
- data/lib/plainrouter/openapi/models/ad_test_create_read_test.rb +675 -0
- data/lib/plainrouter/openapi/models/ad_test_create_read_test_members_inner.rb +232 -0
- data/lib/plainrouter/openapi/models/ad_test_create_read_test_pause_proposals_inner.rb +286 -0
- data/lib/plainrouter/openapi/models/ad_test_create_read_test_verdict.rb +336 -0
- data/lib/plainrouter/openapi/models/ad_test_create_read_test_verdict_daily_facts_inner.rb +374 -0
- data/lib/plainrouter/openapi/models/ad_test_create_read_test_verdict_halt_details.rb +285 -0
- data/lib/plainrouter/openapi/models/ad_test_create_read_test_verdict_halt_details_baseline.rb +190 -0
- data/lib/plainrouter/openapi/models/ad_test_create_read_test_verdict_halt_details_observed_destinations_inner.rb +216 -0
- data/lib/plainrouter/openapi/models/ad_test_create_read_test_verdict_members_inner.rb +349 -0
- data/lib/plainrouter/openapi/models/ad_test_daily_fact_read.rb +374 -0
- data/lib/plainrouter/openapi/models/ad_test_event_choice.rb +190 -0
- data/lib/plainrouter/openapi/models/ad_test_list_read.rb +218 -0
- data/lib/plainrouter/openapi/models/ad_test_list_read_observed_conversion_events_inner.rb +190 -0
- data/lib/plainrouter/openapi/models/ad_test_list_read_tests.rb +396 -0
- data/lib/plainrouter/openapi/models/ad_test_read.rb +675 -0
- data/lib/plainrouter/openapi/models/ad_test_show_read.rb +164 -0
- data/lib/plainrouter/openapi/models/ad_test_verdict_member_read.rb +349 -0
- data/lib/plainrouter/openapi/models/ad_test_verdict_read.rb +336 -0
- data/lib/plainrouter/openapi/models/agent_credential_error.rb +214 -0
- data/lib/plainrouter/openapi/models/api_route_not_found.rb +216 -0
- data/lib/plainrouter/openapi/models/api_route_not_found_error.rb +240 -0
- data/lib/plainrouter/openapi/models/api_route_not_found_request.rb +190 -0
- data/lib/plainrouter/openapi/models/api_route_not_found_resources.rb +190 -0
- data/lib/plainrouter/openapi/models/cookie_declaration.rb +177 -0
- data/lib/plainrouter/openapi/models/cookie_declaration_categories.rb +268 -0
- data/lib/plainrouter/openapi/models/cookie_declaration_categories_necessary.rb +194 -0
- data/lib/plainrouter/openapi/models/cookie_declaration_item.rb +280 -0
- data/lib/plainrouter/openapi/models/create_event200_response.rb +2 -2
- data/lib/plainrouter/openapi/models/create_event202_response.rb +218 -0
- data/lib/plainrouter/openapi/models/create_event202_response_warnings_inner.rb +240 -0
- data/lib/plainrouter/openapi/models/create_event_request.rb +2 -2
- data/lib/plainrouter/openapi/models/create_event_request_any_of.rb +3 -3
- data/lib/plainrouter/openapi/models/create_event_request_any_of1.rb +3 -3
- data/lib/plainrouter/openapi/models/create_event_request_any_of_event_time.rb +2 -2
- data/lib/plainrouter/openapi/models/create_event_request_any_of_value_data.rb +2 -2
- data/lib/plainrouter/openapi/models/creative_intake_read.rb +164 -0
- data/lib/plainrouter/openapi/models/creative_intake_read_creative.rb +451 -0
- data/lib/plainrouter/openapi/models/creative_intake_read_creative_tags.rb +104 -0
- data/lib/plainrouter/openapi/models/creative_intake_rejected.rb +164 -0
- data/lib/plainrouter/openapi/models/creative_intake_rejected_error.rb +190 -0
- data/lib/plainrouter/openapi/models/creative_intake_tags.rb +257 -0
- data/lib/plainrouter/openapi/models/delete_user_data200_response.rb +2 -2
- data/lib/plainrouter/openapi/models/delete_user_data_request.rb +35 -36
- data/lib/plainrouter/openapi/models/delivery_status.rb +2 -2
- data/lib/plainrouter/openapi/models/deployment_plan.rb +593 -0
- data/lib/plainrouter/openapi/models/deployment_plan_read.rb +268 -0
- data/lib/plainrouter/openapi/models/deployment_plan_read_copy.rb +266 -0
- data/lib/plainrouter/openapi/models/deployment_plan_read_creatives_inner.rb +320 -0
- data/lib/plainrouter/openapi/models/deployment_plan_read_creatives_inner_copy.rb +267 -0
- data/lib/plainrouter/openapi/models/destination.rb +30 -3
- data/lib/plainrouter/openapi/models/destination_credential_source.rb +3 -4
- data/lib/plainrouter/openapi/models/destination_status.rb +2 -2
- data/lib/plainrouter/openapi/models/destination_type.rb +4 -3
- data/lib/plainrouter/openapi/models/emq_snapshot.rb +30 -3
- data/lib/plainrouter/openapi/models/error_message.rb +2 -2
- data/lib/plainrouter/openapi/models/event.rb +89 -45
- data/lib/plainrouter/openapi/models/execute_deployment_plan_request.rb +200 -0
- data/lib/plainrouter/openapi/models/get_cookie_declaration404_response.rb +103 -0
- data/lib/plainrouter/openapi/models/get_emq_report200_response.rb +2 -2
- data/lib/plainrouter/openapi/models/get_emq_report200_response_snapshots_inner.rb +30 -3
- data/lib/plainrouter/openapi/models/get_event200_response.rb +2 -2
- data/lib/plainrouter/openapi/models/get_event200_response_deliveries_inner.rb +30 -3
- data/lib/plainrouter/openapi/models/get_event200_response_event.rb +31 -4
- data/lib/plainrouter/openapi/models/get_event200_response_event_consent.rb +2 -2
- data/lib/plainrouter/openapi/models/get_event200_response_event_deliveries_inner.rb +30 -3
- data/lib/plainrouter/openapi/models/get_event200_response_event_user_data_hashed.rb +104 -0
- data/lib/plainrouter/openapi/models/get_event200_response_lineage.rb +2 -2
- data/lib/plainrouter/openapi/models/get_event200_response_lineage_children_inner.rb +31 -4
- data/lib/plainrouter/openapi/models/get_event200_response_lineage_parent.rb +31 -4
- data/lib/plainrouter/openapi/models/get_inventory_metrics200_response.rb +324 -0
- data/lib/plainrouter/openapi/models/get_inventory_metrics200_response_account.rb +264 -0
- data/lib/plainrouter/openapi/models/get_inventory_metrics200_response_changes_inner.rb +304 -0
- data/lib/plainrouter/openapi/models/get_inventory_metrics200_response_effective_range.rb +190 -0
- data/lib/plainrouter/openapi/models/get_inventory_metrics200_response_metrics_inner.rb +492 -0
- data/lib/plainrouter/openapi/models/get_inventory_metrics200_response_object_metrics_inner.rb +304 -0
- data/lib/plainrouter/openapi/models/get_inventory_metrics200_response_object_metrics_inner_meta.rb +268 -0
- data/lib/plainrouter/openapi/models/get_inventory_metrics200_response_staleness.rb +200 -0
- data/lib/plainrouter/openapi/models/get_inventory_metrics200_response_sync.rb +186 -0
- data/lib/plainrouter/openapi/models/get_reconciliation_report200_response.rb +2 -2
- data/lib/plainrouter/openapi/models/get_reconciliation_report200_response_reports_inner.rb +30 -3
- data/lib/plainrouter/openapi/models/get_reconciliation_report200_response_reports_inner_buckets_value.rb +2 -2
- data/lib/plainrouter/openapi/models/get_reconciliation_report200_response_reports_inner_event_counts.rb +2 -2
- data/lib/plainrouter/openapi/models/get_reconciliation_report200_response_reports_inner_event_counts_accepted.rb +2 -2
- data/lib/plainrouter/openapi/models/get_sandbox200_response.rb +2 -2
- data/lib/plainrouter/openapi/models/get_sandbox200_response_self_serve_key.rb +32 -6
- data/lib/plainrouter/openapi/models/{create_sandbox_key201_response.rb → get_sandbox200_response_self_serve_key_issued_key.rb} +6 -6
- data/lib/plainrouter/openapi/models/{create_sandbox_key201_response_use.rb → get_sandbox200_response_self_serve_key_issued_key_use.rb} +5 -5
- data/lib/plainrouter/openapi/models/get_sandbox200_response_try.rb +2 -2
- data/lib/plainrouter/openapi/models/get_sandbox200_response_try_body.rb +2 -2
- data/lib/plainrouter/openapi/models/get_sandbox200_response_try_body_value_data.rb +2 -2
- data/lib/plainrouter/openapi/models/ingestion_warning_code.rb +40 -0
- data/lib/plainrouter/openapi/models/jurisdiction_policy_class.rb +2 -2
- data/lib/plainrouter/openapi/models/launch_intent_read.rb +164 -0
- data/lib/plainrouter/openapi/models/launch_intent_read_intent.rb +330 -0
- data/lib/plainrouter/openapi/models/launch_intent_read_intent_actions_inner.rb +238 -0
- data/lib/plainrouter/openapi/models/launch_intent_status.rb +46 -0
- data/lib/plainrouter/openapi/models/launch_plans_copy403_response.rb +103 -0
- data/lib/plainrouter/openapi/models/launch_plans_copy404_response.rb +103 -0
- data/lib/plainrouter/openapi/models/launch_plans_execute422_response.rb +103 -0
- data/lib/plainrouter/openapi/models/launch_plans_index200_response.rb +164 -0
- data/lib/plainrouter/openapi/models/launch_plans_index200_response_plans.rb +244 -0
- data/lib/plainrouter/openapi/models/launch_plans_show200_response.rb +164 -0
- data/lib/plainrouter/openapi/models/list_events200_response.rb +2 -2
- data/lib/plainrouter/openapi/models/list_events200_response_events.rb +2 -2
- data/lib/plainrouter/openapi/models/list_events200_response_events_links_inner.rb +2 -2
- data/lib/plainrouter/openapi/models/list_events200_response_metrics.rb +2 -2
- data/lib/plainrouter/openapi/models/list_events_by_cursor200_response.rb +2 -2
- data/lib/plainrouter/openapi/models/list_events_by_cursor200_response_events.rb +2 -2
- data/lib/plainrouter/openapi/models/plan_copy_forbidden.rb +164 -0
- data/lib/plainrouter/openapi/models/plan_copy_forbidden_error.rb +214 -0
- data/lib/plainrouter/openapi/models/plan_copy_not_found.rb +164 -0
- data/lib/plainrouter/openapi/models/plan_copy_not_found_error.rb +214 -0
- data/lib/plainrouter/openapi/models/plan_copy_read.rb +164 -0
- data/lib/plainrouter/openapi/models/plan_copy_read_plan.rb +347 -0
- data/lib/plainrouter/openapi/models/plan_copy_rejected.rb +164 -0
- data/lib/plainrouter/openapi/models/plan_copy_rejected_error.rb +214 -0
- data/lib/plainrouter/openapi/models/plan_execute_conflict.rb +164 -0
- data/lib/plainrouter/openapi/models/plan_execute_conflict_error.rb +214 -0
- data/lib/plainrouter/openapi/models/plan_execute_rejected.rb +164 -0
- data/lib/plainrouter/openapi/models/plan_execute_rejected_error.rb +214 -0
- data/lib/plainrouter/openapi/models/proposal_replay_conflict.rb +214 -0
- data/lib/plainrouter/openapi/models/proposal_replay_conflict_errors.rb +178 -0
- data/lib/plainrouter/openapi/models/reconciliation_report.rb +31 -3
- data/lib/plainrouter/openapi/models/replay_deliveries202_response.rb +2 -2
- data/lib/plainrouter/openapi/models/replay_deliveries_request.rb +2 -2
- data/lib/plainrouter/openapi/models/send_test_purchase200_response.rb +2 -2
- data/lib/plainrouter/openapi/models/send_test_purchase422_response.rb +2 -2
- data/lib/plainrouter/openapi/models/send_test_purchase_request.rb +2 -2
- data/lib/plainrouter/openapi/models/set_destination_test_mode200_response.rb +2 -2
- data/lib/plainrouter/openapi/models/set_destination_test_mode200_response_destination.rb +30 -3
- data/lib/plainrouter/openapi/models/set_destination_test_mode_request.rb +2 -2
- data/lib/plainrouter/openapi/models/store_creative403_response.rb +103 -0
- data/lib/plainrouter/openapi/models/store_creative413_response.rb +103 -0
- data/lib/plainrouter/openapi/models/store_creative422_response.rb +103 -0
- data/lib/plainrouter/openapi/models/store_creative_from_url_request.rb +208 -0
- data/lib/plainrouter/openapi/models/store_creative_from_url_request_tags.rb +257 -0
- data/lib/plainrouter/openapi/models/store_creative_request.rb +219 -0
- data/lib/plainrouter/openapi/models/store_creative_request_tags.rb +257 -0
- data/lib/plainrouter/openapi/models/traffic_class.rb +2 -2
- data/lib/plainrouter/openapi/models/validate_sandbox_event200_response.rb +2 -2
- data/lib/plainrouter/openapi/models/validate_sandbox_event_request.rb +2 -2
- data/lib/plainrouter/openapi/models/validate_sandbox_event_request_value_data.rb +2 -2
- data/lib/plainrouter/openapi/models/validation_error.rb +2 -2
- data/lib/plainrouter/openapi/models/workspace_lock_timeout.rb +164 -0
- data/lib/plainrouter/openapi/models/workspace_lock_timeout_error.rb +214 -0
- data/lib/plainrouter/openapi/version.rb +3 -3
- data/lib/plainrouter/openapi.rb +164 -4
- data/lib/plainrouter/version.rb +1 -1
- metadata +167 -7
|
@@ -0,0 +1,552 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
#Plainrouter Conversion API
|
|
3
|
+
|
|
4
|
+
#Plainrouter public Signals Conversion API.
|
|
5
|
+
|
|
6
|
+
The version of the OpenAPI document: 0.5.0
|
|
7
|
+
|
|
8
|
+
Generated by: https://openapi-generator.tech
|
|
9
|
+
Generator version: 7.25.0
|
|
10
|
+
|
|
11
|
+
=end
|
|
12
|
+
|
|
13
|
+
require 'date'
|
|
14
|
+
require 'time'
|
|
15
|
+
|
|
16
|
+
module PlainRouter::OpenAPI
|
|
17
|
+
class AdTest < ApiModelBase
|
|
18
|
+
attr_accessor :id
|
|
19
|
+
|
|
20
|
+
attr_accessor :workspace_id
|
|
21
|
+
|
|
22
|
+
attr_accessor :platform_ad_account_id
|
|
23
|
+
|
|
24
|
+
attr_accessor :ad_set_id
|
|
25
|
+
|
|
26
|
+
attr_accessor :axis
|
|
27
|
+
|
|
28
|
+
attr_accessor :event_name
|
|
29
|
+
|
|
30
|
+
attr_accessor :arrivals_floor
|
|
31
|
+
|
|
32
|
+
attr_accessor :minimum_conversions
|
|
33
|
+
|
|
34
|
+
attr_accessor :maximum_days
|
|
35
|
+
|
|
36
|
+
attr_accessor :maximum_spend_minor
|
|
37
|
+
|
|
38
|
+
attr_accessor :anomaly_threshold_percent
|
|
39
|
+
|
|
40
|
+
attr_accessor :currency
|
|
41
|
+
|
|
42
|
+
attr_accessor :timezone
|
|
43
|
+
|
|
44
|
+
attr_accessor :first_day
|
|
45
|
+
|
|
46
|
+
attr_accessor :created_at
|
|
47
|
+
|
|
48
|
+
attr_accessor :updated_at
|
|
49
|
+
|
|
50
|
+
attr_accessor :count_health_click_threshold
|
|
51
|
+
|
|
52
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
|
53
|
+
def self.attribute_map
|
|
54
|
+
{
|
|
55
|
+
:'id' => :'id',
|
|
56
|
+
:'workspace_id' => :'workspace_id',
|
|
57
|
+
:'platform_ad_account_id' => :'platform_ad_account_id',
|
|
58
|
+
:'ad_set_id' => :'ad_set_id',
|
|
59
|
+
:'axis' => :'axis',
|
|
60
|
+
:'event_name' => :'event_name',
|
|
61
|
+
:'arrivals_floor' => :'arrivals_floor',
|
|
62
|
+
:'minimum_conversions' => :'minimum_conversions',
|
|
63
|
+
:'maximum_days' => :'maximum_days',
|
|
64
|
+
:'maximum_spend_minor' => :'maximum_spend_minor',
|
|
65
|
+
:'anomaly_threshold_percent' => :'anomaly_threshold_percent',
|
|
66
|
+
:'currency' => :'currency',
|
|
67
|
+
:'timezone' => :'timezone',
|
|
68
|
+
:'first_day' => :'first_day',
|
|
69
|
+
:'created_at' => :'created_at',
|
|
70
|
+
:'updated_at' => :'updated_at',
|
|
71
|
+
:'count_health_click_threshold' => :'count_health_click_threshold'
|
|
72
|
+
}
|
|
73
|
+
end
|
|
74
|
+
|
|
75
|
+
# Returns attribute mapping this model knows about
|
|
76
|
+
def self.acceptable_attribute_map
|
|
77
|
+
attribute_map
|
|
78
|
+
end
|
|
79
|
+
|
|
80
|
+
# Returns all the JSON keys this model knows about
|
|
81
|
+
def self.acceptable_attributes
|
|
82
|
+
acceptable_attribute_map.values
|
|
83
|
+
end
|
|
84
|
+
|
|
85
|
+
# Attribute type mapping.
|
|
86
|
+
def self.openapi_types
|
|
87
|
+
{
|
|
88
|
+
:'id' => :'String',
|
|
89
|
+
:'workspace_id' => :'Integer',
|
|
90
|
+
:'platform_ad_account_id' => :'Integer',
|
|
91
|
+
:'ad_set_id' => :'String',
|
|
92
|
+
:'axis' => :'String',
|
|
93
|
+
:'event_name' => :'String',
|
|
94
|
+
:'arrivals_floor' => :'Integer',
|
|
95
|
+
:'minimum_conversions' => :'Integer',
|
|
96
|
+
:'maximum_days' => :'Integer',
|
|
97
|
+
:'maximum_spend_minor' => :'String',
|
|
98
|
+
:'anomaly_threshold_percent' => :'String',
|
|
99
|
+
:'currency' => :'String',
|
|
100
|
+
:'timezone' => :'String',
|
|
101
|
+
:'first_day' => :'Time',
|
|
102
|
+
:'created_at' => :'Time',
|
|
103
|
+
:'updated_at' => :'Time',
|
|
104
|
+
:'count_health_click_threshold' => :'Integer'
|
|
105
|
+
}
|
|
106
|
+
end
|
|
107
|
+
|
|
108
|
+
# List of attributes with nullable: true
|
|
109
|
+
def self.openapi_nullable
|
|
110
|
+
Set.new([
|
|
111
|
+
:'maximum_spend_minor',
|
|
112
|
+
:'count_health_click_threshold'
|
|
113
|
+
])
|
|
114
|
+
end
|
|
115
|
+
|
|
116
|
+
# Initializes the object
|
|
117
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
118
|
+
def initialize(attributes = {})
|
|
119
|
+
if (!attributes.is_a?(Hash))
|
|
120
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `PlainRouter::OpenAPI::AdTest` initialize method"
|
|
121
|
+
end
|
|
122
|
+
|
|
123
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
|
124
|
+
acceptable_attribute_map = self.class.acceptable_attribute_map
|
|
125
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
|
126
|
+
if (!acceptable_attribute_map.key?(k.to_sym))
|
|
127
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `PlainRouter::OpenAPI::AdTest`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
|
|
128
|
+
end
|
|
129
|
+
h[k.to_sym] = v
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
if attributes.key?(:'id')
|
|
133
|
+
self.id = attributes[:'id']
|
|
134
|
+
else
|
|
135
|
+
self.id = nil
|
|
136
|
+
end
|
|
137
|
+
|
|
138
|
+
if attributes.key?(:'workspace_id')
|
|
139
|
+
self.workspace_id = attributes[:'workspace_id']
|
|
140
|
+
else
|
|
141
|
+
self.workspace_id = nil
|
|
142
|
+
end
|
|
143
|
+
|
|
144
|
+
if attributes.key?(:'platform_ad_account_id')
|
|
145
|
+
self.platform_ad_account_id = attributes[:'platform_ad_account_id']
|
|
146
|
+
else
|
|
147
|
+
self.platform_ad_account_id = nil
|
|
148
|
+
end
|
|
149
|
+
|
|
150
|
+
if attributes.key?(:'ad_set_id')
|
|
151
|
+
self.ad_set_id = attributes[:'ad_set_id']
|
|
152
|
+
else
|
|
153
|
+
self.ad_set_id = nil
|
|
154
|
+
end
|
|
155
|
+
|
|
156
|
+
if attributes.key?(:'axis')
|
|
157
|
+
self.axis = attributes[:'axis']
|
|
158
|
+
else
|
|
159
|
+
self.axis = nil
|
|
160
|
+
end
|
|
161
|
+
|
|
162
|
+
if attributes.key?(:'event_name')
|
|
163
|
+
self.event_name = attributes[:'event_name']
|
|
164
|
+
else
|
|
165
|
+
self.event_name = nil
|
|
166
|
+
end
|
|
167
|
+
|
|
168
|
+
if attributes.key?(:'arrivals_floor')
|
|
169
|
+
self.arrivals_floor = attributes[:'arrivals_floor']
|
|
170
|
+
else
|
|
171
|
+
self.arrivals_floor = nil
|
|
172
|
+
end
|
|
173
|
+
|
|
174
|
+
if attributes.key?(:'minimum_conversions')
|
|
175
|
+
self.minimum_conversions = attributes[:'minimum_conversions']
|
|
176
|
+
else
|
|
177
|
+
self.minimum_conversions = nil
|
|
178
|
+
end
|
|
179
|
+
|
|
180
|
+
if attributes.key?(:'maximum_days')
|
|
181
|
+
self.maximum_days = attributes[:'maximum_days']
|
|
182
|
+
else
|
|
183
|
+
self.maximum_days = nil
|
|
184
|
+
end
|
|
185
|
+
|
|
186
|
+
if attributes.key?(:'maximum_spend_minor')
|
|
187
|
+
self.maximum_spend_minor = attributes[:'maximum_spend_minor']
|
|
188
|
+
else
|
|
189
|
+
self.maximum_spend_minor = nil
|
|
190
|
+
end
|
|
191
|
+
|
|
192
|
+
if attributes.key?(:'anomaly_threshold_percent')
|
|
193
|
+
self.anomaly_threshold_percent = attributes[:'anomaly_threshold_percent']
|
|
194
|
+
else
|
|
195
|
+
self.anomaly_threshold_percent = nil
|
|
196
|
+
end
|
|
197
|
+
|
|
198
|
+
if attributes.key?(:'currency')
|
|
199
|
+
self.currency = attributes[:'currency']
|
|
200
|
+
else
|
|
201
|
+
self.currency = nil
|
|
202
|
+
end
|
|
203
|
+
|
|
204
|
+
if attributes.key?(:'timezone')
|
|
205
|
+
self.timezone = attributes[:'timezone']
|
|
206
|
+
else
|
|
207
|
+
self.timezone = nil
|
|
208
|
+
end
|
|
209
|
+
|
|
210
|
+
if attributes.key?(:'first_day')
|
|
211
|
+
self.first_day = attributes[:'first_day']
|
|
212
|
+
else
|
|
213
|
+
self.first_day = nil
|
|
214
|
+
end
|
|
215
|
+
|
|
216
|
+
if attributes.key?(:'created_at')
|
|
217
|
+
self.created_at = attributes[:'created_at']
|
|
218
|
+
else
|
|
219
|
+
self.created_at = nil
|
|
220
|
+
end
|
|
221
|
+
|
|
222
|
+
if attributes.key?(:'updated_at')
|
|
223
|
+
self.updated_at = attributes[:'updated_at']
|
|
224
|
+
else
|
|
225
|
+
self.updated_at = nil
|
|
226
|
+
end
|
|
227
|
+
|
|
228
|
+
if attributes.key?(:'count_health_click_threshold')
|
|
229
|
+
self.count_health_click_threshold = attributes[:'count_health_click_threshold']
|
|
230
|
+
else
|
|
231
|
+
self.count_health_click_threshold = nil
|
|
232
|
+
end
|
|
233
|
+
end
|
|
234
|
+
|
|
235
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
|
236
|
+
# @return Array for valid properties with the reasons
|
|
237
|
+
def list_invalid_properties
|
|
238
|
+
warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
|
|
239
|
+
invalid_properties = Array.new
|
|
240
|
+
if @id.nil?
|
|
241
|
+
invalid_properties.push('invalid value for "id", id cannot be nil.')
|
|
242
|
+
end
|
|
243
|
+
|
|
244
|
+
if @workspace_id.nil?
|
|
245
|
+
invalid_properties.push('invalid value for "workspace_id", workspace_id cannot be nil.')
|
|
246
|
+
end
|
|
247
|
+
|
|
248
|
+
if @platform_ad_account_id.nil?
|
|
249
|
+
invalid_properties.push('invalid value for "platform_ad_account_id", platform_ad_account_id cannot be nil.')
|
|
250
|
+
end
|
|
251
|
+
|
|
252
|
+
if @ad_set_id.nil?
|
|
253
|
+
invalid_properties.push('invalid value for "ad_set_id", ad_set_id cannot be nil.')
|
|
254
|
+
end
|
|
255
|
+
|
|
256
|
+
if @axis.nil?
|
|
257
|
+
invalid_properties.push('invalid value for "axis", axis cannot be nil.')
|
|
258
|
+
end
|
|
259
|
+
|
|
260
|
+
if @event_name.nil?
|
|
261
|
+
invalid_properties.push('invalid value for "event_name", event_name cannot be nil.')
|
|
262
|
+
end
|
|
263
|
+
|
|
264
|
+
if @arrivals_floor.nil?
|
|
265
|
+
invalid_properties.push('invalid value for "arrivals_floor", arrivals_floor cannot be nil.')
|
|
266
|
+
end
|
|
267
|
+
|
|
268
|
+
if @minimum_conversions.nil?
|
|
269
|
+
invalid_properties.push('invalid value for "minimum_conversions", minimum_conversions cannot be nil.')
|
|
270
|
+
end
|
|
271
|
+
|
|
272
|
+
if @maximum_days.nil?
|
|
273
|
+
invalid_properties.push('invalid value for "maximum_days", maximum_days cannot be nil.')
|
|
274
|
+
end
|
|
275
|
+
|
|
276
|
+
if @anomaly_threshold_percent.nil?
|
|
277
|
+
invalid_properties.push('invalid value for "anomaly_threshold_percent", anomaly_threshold_percent cannot be nil.')
|
|
278
|
+
end
|
|
279
|
+
|
|
280
|
+
if @currency.nil?
|
|
281
|
+
invalid_properties.push('invalid value for "currency", currency cannot be nil.')
|
|
282
|
+
end
|
|
283
|
+
|
|
284
|
+
if @timezone.nil?
|
|
285
|
+
invalid_properties.push('invalid value for "timezone", timezone cannot be nil.')
|
|
286
|
+
end
|
|
287
|
+
|
|
288
|
+
if @first_day.nil?
|
|
289
|
+
invalid_properties.push('invalid value for "first_day", first_day cannot be nil.')
|
|
290
|
+
end
|
|
291
|
+
|
|
292
|
+
if @created_at.nil?
|
|
293
|
+
invalid_properties.push('invalid value for "created_at", created_at cannot be nil.')
|
|
294
|
+
end
|
|
295
|
+
|
|
296
|
+
if @updated_at.nil?
|
|
297
|
+
invalid_properties.push('invalid value for "updated_at", updated_at cannot be nil.')
|
|
298
|
+
end
|
|
299
|
+
|
|
300
|
+
invalid_properties
|
|
301
|
+
end
|
|
302
|
+
|
|
303
|
+
# Check to see if the all the properties in the model are valid
|
|
304
|
+
# @return true if the model is valid
|
|
305
|
+
def valid?
|
|
306
|
+
warn '[DEPRECATED] the `valid?` method is obsolete'
|
|
307
|
+
return false if @id.nil?
|
|
308
|
+
return false if @workspace_id.nil?
|
|
309
|
+
return false if @platform_ad_account_id.nil?
|
|
310
|
+
return false if @ad_set_id.nil?
|
|
311
|
+
return false if @axis.nil?
|
|
312
|
+
return false if @event_name.nil?
|
|
313
|
+
return false if @arrivals_floor.nil?
|
|
314
|
+
return false if @minimum_conversions.nil?
|
|
315
|
+
return false if @maximum_days.nil?
|
|
316
|
+
return false if @anomaly_threshold_percent.nil?
|
|
317
|
+
return false if @currency.nil?
|
|
318
|
+
return false if @timezone.nil?
|
|
319
|
+
return false if @first_day.nil?
|
|
320
|
+
return false if @created_at.nil?
|
|
321
|
+
return false if @updated_at.nil?
|
|
322
|
+
true
|
|
323
|
+
end
|
|
324
|
+
|
|
325
|
+
# Custom attribute writer method with validation
|
|
326
|
+
# @param [Object] id Value to be assigned
|
|
327
|
+
def id=(id)
|
|
328
|
+
if id.nil?
|
|
329
|
+
fail ArgumentError, 'id cannot be nil'
|
|
330
|
+
end
|
|
331
|
+
|
|
332
|
+
@id = id
|
|
333
|
+
end
|
|
334
|
+
|
|
335
|
+
# Custom attribute writer method with validation
|
|
336
|
+
# @param [Object] workspace_id Value to be assigned
|
|
337
|
+
def workspace_id=(workspace_id)
|
|
338
|
+
if workspace_id.nil?
|
|
339
|
+
fail ArgumentError, 'workspace_id cannot be nil'
|
|
340
|
+
end
|
|
341
|
+
|
|
342
|
+
@workspace_id = workspace_id
|
|
343
|
+
end
|
|
344
|
+
|
|
345
|
+
# Custom attribute writer method with validation
|
|
346
|
+
# @param [Object] platform_ad_account_id Value to be assigned
|
|
347
|
+
def platform_ad_account_id=(platform_ad_account_id)
|
|
348
|
+
if platform_ad_account_id.nil?
|
|
349
|
+
fail ArgumentError, 'platform_ad_account_id cannot be nil'
|
|
350
|
+
end
|
|
351
|
+
|
|
352
|
+
@platform_ad_account_id = platform_ad_account_id
|
|
353
|
+
end
|
|
354
|
+
|
|
355
|
+
# Custom attribute writer method with validation
|
|
356
|
+
# @param [Object] ad_set_id Value to be assigned
|
|
357
|
+
def ad_set_id=(ad_set_id)
|
|
358
|
+
if ad_set_id.nil?
|
|
359
|
+
fail ArgumentError, 'ad_set_id cannot be nil'
|
|
360
|
+
end
|
|
361
|
+
|
|
362
|
+
@ad_set_id = ad_set_id
|
|
363
|
+
end
|
|
364
|
+
|
|
365
|
+
# Custom attribute writer method with validation
|
|
366
|
+
# @param [Object] axis Value to be assigned
|
|
367
|
+
def axis=(axis)
|
|
368
|
+
if axis.nil?
|
|
369
|
+
fail ArgumentError, 'axis cannot be nil'
|
|
370
|
+
end
|
|
371
|
+
|
|
372
|
+
@axis = axis
|
|
373
|
+
end
|
|
374
|
+
|
|
375
|
+
# Custom attribute writer method with validation
|
|
376
|
+
# @param [Object] event_name Value to be assigned
|
|
377
|
+
def event_name=(event_name)
|
|
378
|
+
if event_name.nil?
|
|
379
|
+
fail ArgumentError, 'event_name cannot be nil'
|
|
380
|
+
end
|
|
381
|
+
|
|
382
|
+
@event_name = event_name
|
|
383
|
+
end
|
|
384
|
+
|
|
385
|
+
# Custom attribute writer method with validation
|
|
386
|
+
# @param [Object] arrivals_floor Value to be assigned
|
|
387
|
+
def arrivals_floor=(arrivals_floor)
|
|
388
|
+
if arrivals_floor.nil?
|
|
389
|
+
fail ArgumentError, 'arrivals_floor cannot be nil'
|
|
390
|
+
end
|
|
391
|
+
|
|
392
|
+
@arrivals_floor = arrivals_floor
|
|
393
|
+
end
|
|
394
|
+
|
|
395
|
+
# Custom attribute writer method with validation
|
|
396
|
+
# @param [Object] minimum_conversions Value to be assigned
|
|
397
|
+
def minimum_conversions=(minimum_conversions)
|
|
398
|
+
if minimum_conversions.nil?
|
|
399
|
+
fail ArgumentError, 'minimum_conversions cannot be nil'
|
|
400
|
+
end
|
|
401
|
+
|
|
402
|
+
@minimum_conversions = minimum_conversions
|
|
403
|
+
end
|
|
404
|
+
|
|
405
|
+
# Custom attribute writer method with validation
|
|
406
|
+
# @param [Object] maximum_days Value to be assigned
|
|
407
|
+
def maximum_days=(maximum_days)
|
|
408
|
+
if maximum_days.nil?
|
|
409
|
+
fail ArgumentError, 'maximum_days cannot be nil'
|
|
410
|
+
end
|
|
411
|
+
|
|
412
|
+
@maximum_days = maximum_days
|
|
413
|
+
end
|
|
414
|
+
|
|
415
|
+
# Custom attribute writer method with validation
|
|
416
|
+
# @param [Object] anomaly_threshold_percent Value to be assigned
|
|
417
|
+
def anomaly_threshold_percent=(anomaly_threshold_percent)
|
|
418
|
+
if anomaly_threshold_percent.nil?
|
|
419
|
+
fail ArgumentError, 'anomaly_threshold_percent cannot be nil'
|
|
420
|
+
end
|
|
421
|
+
|
|
422
|
+
@anomaly_threshold_percent = anomaly_threshold_percent
|
|
423
|
+
end
|
|
424
|
+
|
|
425
|
+
# Custom attribute writer method with validation
|
|
426
|
+
# @param [Object] currency Value to be assigned
|
|
427
|
+
def currency=(currency)
|
|
428
|
+
if currency.nil?
|
|
429
|
+
fail ArgumentError, 'currency cannot be nil'
|
|
430
|
+
end
|
|
431
|
+
|
|
432
|
+
@currency = currency
|
|
433
|
+
end
|
|
434
|
+
|
|
435
|
+
# Custom attribute writer method with validation
|
|
436
|
+
# @param [Object] timezone Value to be assigned
|
|
437
|
+
def timezone=(timezone)
|
|
438
|
+
if timezone.nil?
|
|
439
|
+
fail ArgumentError, 'timezone cannot be nil'
|
|
440
|
+
end
|
|
441
|
+
|
|
442
|
+
@timezone = timezone
|
|
443
|
+
end
|
|
444
|
+
|
|
445
|
+
# Custom attribute writer method with validation
|
|
446
|
+
# @param [Object] first_day Value to be assigned
|
|
447
|
+
def first_day=(first_day)
|
|
448
|
+
if first_day.nil?
|
|
449
|
+
fail ArgumentError, 'first_day cannot be nil'
|
|
450
|
+
end
|
|
451
|
+
|
|
452
|
+
@first_day = first_day
|
|
453
|
+
end
|
|
454
|
+
|
|
455
|
+
# Custom attribute writer method with validation
|
|
456
|
+
# @param [Object] created_at Value to be assigned
|
|
457
|
+
def created_at=(created_at)
|
|
458
|
+
if created_at.nil?
|
|
459
|
+
fail ArgumentError, 'created_at cannot be nil'
|
|
460
|
+
end
|
|
461
|
+
|
|
462
|
+
@created_at = created_at
|
|
463
|
+
end
|
|
464
|
+
|
|
465
|
+
# Custom attribute writer method with validation
|
|
466
|
+
# @param [Object] updated_at Value to be assigned
|
|
467
|
+
def updated_at=(updated_at)
|
|
468
|
+
if updated_at.nil?
|
|
469
|
+
fail ArgumentError, 'updated_at cannot be nil'
|
|
470
|
+
end
|
|
471
|
+
|
|
472
|
+
@updated_at = updated_at
|
|
473
|
+
end
|
|
474
|
+
|
|
475
|
+
# Checks equality by comparing each attribute.
|
|
476
|
+
# @param [Object] Object to be compared
|
|
477
|
+
def ==(o)
|
|
478
|
+
return true if self.equal?(o)
|
|
479
|
+
self.class == o.class &&
|
|
480
|
+
id == o.id &&
|
|
481
|
+
workspace_id == o.workspace_id &&
|
|
482
|
+
platform_ad_account_id == o.platform_ad_account_id &&
|
|
483
|
+
ad_set_id == o.ad_set_id &&
|
|
484
|
+
axis == o.axis &&
|
|
485
|
+
event_name == o.event_name &&
|
|
486
|
+
arrivals_floor == o.arrivals_floor &&
|
|
487
|
+
minimum_conversions == o.minimum_conversions &&
|
|
488
|
+
maximum_days == o.maximum_days &&
|
|
489
|
+
maximum_spend_minor == o.maximum_spend_minor &&
|
|
490
|
+
anomaly_threshold_percent == o.anomaly_threshold_percent &&
|
|
491
|
+
currency == o.currency &&
|
|
492
|
+
timezone == o.timezone &&
|
|
493
|
+
first_day == o.first_day &&
|
|
494
|
+
created_at == o.created_at &&
|
|
495
|
+
updated_at == o.updated_at &&
|
|
496
|
+
count_health_click_threshold == o.count_health_click_threshold
|
|
497
|
+
end
|
|
498
|
+
|
|
499
|
+
# @see the `==` method
|
|
500
|
+
# @param [Object] Object to be compared
|
|
501
|
+
def eql?(o)
|
|
502
|
+
self == o
|
|
503
|
+
end
|
|
504
|
+
|
|
505
|
+
# Calculates hash code according to all attributes.
|
|
506
|
+
# @return [Integer] Hash code
|
|
507
|
+
def hash
|
|
508
|
+
[id, workspace_id, platform_ad_account_id, ad_set_id, axis, event_name, arrivals_floor, minimum_conversions, maximum_days, maximum_spend_minor, anomaly_threshold_percent, currency, timezone, first_day, created_at, updated_at, count_health_click_threshold].hash
|
|
509
|
+
end
|
|
510
|
+
|
|
511
|
+
# Builds the object from hash
|
|
512
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
513
|
+
# @return [Object] Returns the model itself
|
|
514
|
+
def self.build_from_hash(attributes)
|
|
515
|
+
return nil unless attributes.is_a?(Hash)
|
|
516
|
+
attributes = attributes.transform_keys(&:to_sym)
|
|
517
|
+
transformed_hash = {}
|
|
518
|
+
openapi_types.each_pair do |key, type|
|
|
519
|
+
if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
|
|
520
|
+
transformed_hash["#{key}"] = nil
|
|
521
|
+
elsif type =~ /\AArray<(.*)>/i
|
|
522
|
+
# check to ensure the input is an array given that the attribute
|
|
523
|
+
# is documented as an array but the input is not
|
|
524
|
+
if attributes[attribute_map[key]].is_a?(Array)
|
|
525
|
+
transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
|
|
526
|
+
end
|
|
527
|
+
elsif !attributes[attribute_map[key]].nil?
|
|
528
|
+
transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
|
|
529
|
+
end
|
|
530
|
+
end
|
|
531
|
+
new(transformed_hash)
|
|
532
|
+
end
|
|
533
|
+
|
|
534
|
+
# Returns the object in the form of hash
|
|
535
|
+
# @return [Hash] Returns the object in the form of hash
|
|
536
|
+
def to_hash
|
|
537
|
+
hash = {}
|
|
538
|
+
self.class.attribute_map.each_pair do |attr, param|
|
|
539
|
+
value = self.send(attr)
|
|
540
|
+
if value.nil?
|
|
541
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
|
542
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
|
543
|
+
end
|
|
544
|
+
|
|
545
|
+
hash[param] = _to_hash(value)
|
|
546
|
+
end
|
|
547
|
+
hash
|
|
548
|
+
end
|
|
549
|
+
|
|
550
|
+
end
|
|
551
|
+
|
|
552
|
+
end
|
|
@@ -0,0 +1,164 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
#Plainrouter Conversion API
|
|
3
|
+
|
|
4
|
+
#Plainrouter public Signals Conversion API.
|
|
5
|
+
|
|
6
|
+
The version of the OpenAPI document: 0.5.0
|
|
7
|
+
|
|
8
|
+
Generated by: https://openapi-generator.tech
|
|
9
|
+
Generator version: 7.25.0
|
|
10
|
+
|
|
11
|
+
=end
|
|
12
|
+
|
|
13
|
+
require 'date'
|
|
14
|
+
require 'time'
|
|
15
|
+
|
|
16
|
+
module PlainRouter::OpenAPI
|
|
17
|
+
class AdTestCreateRead < ApiModelBase
|
|
18
|
+
attr_accessor :test
|
|
19
|
+
|
|
20
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
|
21
|
+
def self.attribute_map
|
|
22
|
+
{
|
|
23
|
+
:'test' => :'test'
|
|
24
|
+
}
|
|
25
|
+
end
|
|
26
|
+
|
|
27
|
+
# Returns attribute mapping this model knows about
|
|
28
|
+
def self.acceptable_attribute_map
|
|
29
|
+
attribute_map
|
|
30
|
+
end
|
|
31
|
+
|
|
32
|
+
# Returns all the JSON keys this model knows about
|
|
33
|
+
def self.acceptable_attributes
|
|
34
|
+
acceptable_attribute_map.values
|
|
35
|
+
end
|
|
36
|
+
|
|
37
|
+
# Attribute type mapping.
|
|
38
|
+
def self.openapi_types
|
|
39
|
+
{
|
|
40
|
+
:'test' => :'AdTestCreateReadTest'
|
|
41
|
+
}
|
|
42
|
+
end
|
|
43
|
+
|
|
44
|
+
# List of attributes with nullable: true
|
|
45
|
+
def self.openapi_nullable
|
|
46
|
+
Set.new([
|
|
47
|
+
])
|
|
48
|
+
end
|
|
49
|
+
|
|
50
|
+
# Initializes the object
|
|
51
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
52
|
+
def initialize(attributes = {})
|
|
53
|
+
if (!attributes.is_a?(Hash))
|
|
54
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `PlainRouter::OpenAPI::AdTestCreateRead` initialize method"
|
|
55
|
+
end
|
|
56
|
+
|
|
57
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
|
58
|
+
acceptable_attribute_map = self.class.acceptable_attribute_map
|
|
59
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
|
60
|
+
if (!acceptable_attribute_map.key?(k.to_sym))
|
|
61
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `PlainRouter::OpenAPI::AdTestCreateRead`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
|
|
62
|
+
end
|
|
63
|
+
h[k.to_sym] = v
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
if attributes.key?(:'test')
|
|
67
|
+
self.test = attributes[:'test']
|
|
68
|
+
else
|
|
69
|
+
self.test = nil
|
|
70
|
+
end
|
|
71
|
+
end
|
|
72
|
+
|
|
73
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
|
74
|
+
# @return Array for valid properties with the reasons
|
|
75
|
+
def list_invalid_properties
|
|
76
|
+
warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
|
|
77
|
+
invalid_properties = Array.new
|
|
78
|
+
if @test.nil?
|
|
79
|
+
invalid_properties.push('invalid value for "test", test cannot be nil.')
|
|
80
|
+
end
|
|
81
|
+
|
|
82
|
+
invalid_properties
|
|
83
|
+
end
|
|
84
|
+
|
|
85
|
+
# Check to see if the all the properties in the model are valid
|
|
86
|
+
# @return true if the model is valid
|
|
87
|
+
def valid?
|
|
88
|
+
warn '[DEPRECATED] the `valid?` method is obsolete'
|
|
89
|
+
return false if @test.nil?
|
|
90
|
+
true
|
|
91
|
+
end
|
|
92
|
+
|
|
93
|
+
# Custom attribute writer method with validation
|
|
94
|
+
# @param [Object] test Value to be assigned
|
|
95
|
+
def test=(test)
|
|
96
|
+
if test.nil?
|
|
97
|
+
fail ArgumentError, 'test cannot be nil'
|
|
98
|
+
end
|
|
99
|
+
|
|
100
|
+
@test = test
|
|
101
|
+
end
|
|
102
|
+
|
|
103
|
+
# Checks equality by comparing each attribute.
|
|
104
|
+
# @param [Object] Object to be compared
|
|
105
|
+
def ==(o)
|
|
106
|
+
return true if self.equal?(o)
|
|
107
|
+
self.class == o.class &&
|
|
108
|
+
test == o.test
|
|
109
|
+
end
|
|
110
|
+
|
|
111
|
+
# @see the `==` method
|
|
112
|
+
# @param [Object] Object to be compared
|
|
113
|
+
def eql?(o)
|
|
114
|
+
self == o
|
|
115
|
+
end
|
|
116
|
+
|
|
117
|
+
# Calculates hash code according to all attributes.
|
|
118
|
+
# @return [Integer] Hash code
|
|
119
|
+
def hash
|
|
120
|
+
[test].hash
|
|
121
|
+
end
|
|
122
|
+
|
|
123
|
+
# Builds the object from hash
|
|
124
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
125
|
+
# @return [Object] Returns the model itself
|
|
126
|
+
def self.build_from_hash(attributes)
|
|
127
|
+
return nil unless attributes.is_a?(Hash)
|
|
128
|
+
attributes = attributes.transform_keys(&:to_sym)
|
|
129
|
+
transformed_hash = {}
|
|
130
|
+
openapi_types.each_pair do |key, type|
|
|
131
|
+
if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
|
|
132
|
+
transformed_hash["#{key}"] = nil
|
|
133
|
+
elsif type =~ /\AArray<(.*)>/i
|
|
134
|
+
# check to ensure the input is an array given that the attribute
|
|
135
|
+
# is documented as an array but the input is not
|
|
136
|
+
if attributes[attribute_map[key]].is_a?(Array)
|
|
137
|
+
transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
|
|
138
|
+
end
|
|
139
|
+
elsif !attributes[attribute_map[key]].nil?
|
|
140
|
+
transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
|
|
141
|
+
end
|
|
142
|
+
end
|
|
143
|
+
new(transformed_hash)
|
|
144
|
+
end
|
|
145
|
+
|
|
146
|
+
# Returns the object in the form of hash
|
|
147
|
+
# @return [Hash] Returns the object in the form of hash
|
|
148
|
+
def to_hash
|
|
149
|
+
hash = {}
|
|
150
|
+
self.class.attribute_map.each_pair do |attr, param|
|
|
151
|
+
value = self.send(attr)
|
|
152
|
+
if value.nil?
|
|
153
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
|
154
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
|
155
|
+
end
|
|
156
|
+
|
|
157
|
+
hash[param] = _to_hash(value)
|
|
158
|
+
end
|
|
159
|
+
hash
|
|
160
|
+
end
|
|
161
|
+
|
|
162
|
+
end
|
|
163
|
+
|
|
164
|
+
end
|