chartmogul-ruby 3.3.0 → 4.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/workflows/test.yml +1 -1
- data/.gitignore +2 -1
- data/README.md +1 -1
- data/changelog.md +15 -0
- data/chartmogul-ruby.gemspec +2 -2
- data/lib/chartmogul/api/actions/custom.rb +2 -1
- data/lib/chartmogul/concerns/pageable_with_cursor.rb +4 -0
- data/lib/chartmogul/contact.rb +1 -4
- data/lib/chartmogul/customer.rb +13 -1
- data/lib/chartmogul/customer_invoices.rb +5 -1
- data/lib/chartmogul/enrichment/customer.rb +1 -0
- data/lib/chartmogul/errors/deprecated_parameter_error.rb +6 -0
- data/lib/chartmogul/invoice.rb +1 -0
- data/lib/chartmogul/metrics/activity.rb +1 -4
- data/lib/chartmogul/metrics/customers/activity.rb +5 -0
- data/lib/chartmogul/metrics/customers/subscription.rb +5 -0
- data/lib/chartmogul/plan.rb +1 -0
- data/lib/chartmogul/plan_group.rb +1 -0
- data/lib/chartmogul/plan_groups/plans.rb +11 -0
- data/lib/chartmogul/resource_path.rb +6 -1
- data/lib/chartmogul/subscription.rb +5 -0
- data/lib/chartmogul/subscription_event.rb +1 -0
- data/lib/chartmogul/version.rb +1 -1
- data/lib/chartmogul.rb +1 -0
- metadata +6 -103
- data/fixtures/vcr_cassettes/ChartMogul_APIResource/connection/works_in_a_threaded_environment.yml +0 -112
- data/fixtures/vcr_cassettes/ChartMogul_APIResource/connection/works_when_credentials_are_updated.yml +0 -77
- data/fixtures/vcr_cassettes/ChartMogul_Account/returns_details_of_current_account.yml +0 -64
- data/fixtures/vcr_cassettes/ChartMogul_Contact/API_Interactions/creates_contact_correctly.yml +0 -134
- data/fixtures/vcr_cassettes/ChartMogul_Contact/API_Interactions/destroys_contact_correctly.yml +0 -99
- data/fixtures/vcr_cassettes/ChartMogul_Contact/API_Interactions/merges_contact_correctly.yml +0 -105
- data/fixtures/vcr_cassettes/ChartMogul_Contact/API_Interactions/paginates_correctly.yml +0 -133
- data/fixtures/vcr_cassettes/ChartMogul_Contact/API_Interactions/updates_contact_correctly.yml +0 -102
- data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/adds_custom_attributes.yml +0 -80
- data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/adds_required_tags.yml +0 -79
- data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/can_page_through_search_endpoint.yml +0 -43
- data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/correctly_handles_a_422_response.yml +0 -50
- data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/correctly_interracts_with_the_API.yml +0 -192
- data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/creates_a_contact_belonging_to_the_customer_correctly.yml +0 -72
- data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/lists_the_contacts_belonging_to_the_customer_correctly.yml +0 -72
- data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/merges_customers.yml +0 -185
- data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/raises_401_if_invalid_credentials.yml +0 -38
- data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/raises_404_if_no_customers_found.yml +0 -38
- data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/raises_422_for_update_with_invalid_data.yml +0 -86
- data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/removes_custom_attributes.yml +0 -80
- data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/removes_tags.yml +0 -80
- data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/respects_camel_case_for_all_customers_endpoint.yml +0 -45
- data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/returns_all_customers_through_list_all_endpoint.yml +0 -47
- data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/returns_customer_through_retrieve_endpoint.yml +0 -42
- data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/returns_right_customers_through_search_endpoint.yml +0 -43
- data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/updates_custom_attributes.yml +0 -81
- data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/updates_customer.yml +0 -139
- data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/updates_customer_using_class_method.yml +0 -53
- data/fixtures/vcr_cassettes/ChartMogul_Customer/_find_by_external_id/when_external_id_is_provided/returns_matching_user_if_exists.yml +0 -102
- data/fixtures/vcr_cassettes/ChartMogul_Customer/_find_by_external_id/when_external_id_is_provided/returns_nil_if_customer_does_not_exist.yml +0 -101
- data/fixtures/vcr_cassettes/ChartMogul_CustomerInvoices/API_Interactions/correctly_interracts_with_the_API.yml +0 -337
- data/fixtures/vcr_cassettes/ChartMogul_DataSource/API_Interactions/correctly_interracts_with_the_API.yml +0 -189
- data/fixtures/vcr_cassettes/ChartMogul_DataSource/API_Interactions/correctly_raises_errors_on_404.yml +0 -46
- data/fixtures/vcr_cassettes/ChartMogul_DataSource/API_Interactions/correctly_raises_errors_on_422.yml +0 -48
- data/fixtures/vcr_cassettes/ChartMogul_DataSource/API_Interactions/retrieves_existing_data_source_matching_uuid.yml +0 -101
- data/fixtures/vcr_cassettes/ChartMogul_Invoice/API_Interactions/deletes_an_invoice.yml +0 -37
- data/fixtures/vcr_cassettes/ChartMogul_Invoice/API_Interactions/deletes_an_invoice_with_class_method.yml +0 -37
- data/fixtures/vcr_cassettes/ChartMogul_Invoice/API_Interactions/raises_error_on_deleting_non-existing_invoice.yml +0 -42
- data/fixtures/vcr_cassettes/ChartMogul_Invoice/API_Interactions/retrieves_existing_invoice_by_uuid.yml +0 -50
- data/fixtures/vcr_cassettes/ChartMogul_Invoice/API_Interactions/returns_all_invoices_through_list_all_endpoint.yml +0 -46
- data/fixtures/vcr_cassettes/ChartMogul_Metrics_ARPA/behaves_like_Metrics_API_resource/behaves_like_Summary/should_have_summary.yml +0 -42
- data/fixtures/vcr_cassettes/ChartMogul_Metrics_ARPA/behaves_like_Metrics_API_resource/should_have_entries.yml +0 -42
- data/fixtures/vcr_cassettes/ChartMogul_Metrics_ARR/behaves_like_Metrics_API_resource/behaves_like_Summary/should_have_summary.yml +0 -42
- data/fixtures/vcr_cassettes/ChartMogul_Metrics_ARR/behaves_like_Metrics_API_resource/should_have_entries.yml +0 -42
- data/fixtures/vcr_cassettes/ChartMogul_Metrics_ASP/behaves_like_Metrics_API_resource/behaves_like_Summary/should_have_summary.yml +0 -40
- data/fixtures/vcr_cassettes/ChartMogul_Metrics_ASP/behaves_like_Metrics_API_resource/should_have_entries.yml +0 -40
- data/fixtures/vcr_cassettes/ChartMogul_Metrics_ActivitiesExport/get_activities_export.yml +0 -43
- data/fixtures/vcr_cassettes/ChartMogul_Metrics_ActivitiesExport/post_activities_export.yml +0 -83
- data/fixtures/vcr_cassettes/ChartMogul_Metrics_Activity/behaves_like_PageableWithAnchor/should_be_pageable.yml +0 -44
- data/fixtures/vcr_cassettes/ChartMogul_Metrics_Activity/should_have_Activity_entries.yml +0 -44
- data/fixtures/vcr_cassettes/ChartMogul_Metrics_Activity.yml +0 -37
- data/fixtures/vcr_cassettes/ChartMogul_Metrics_AllKeyMetric/should_have_entries.yml +0 -42
- data/fixtures/vcr_cassettes/ChartMogul_Metrics_AllKeyMetric/should_have_summary.yml +0 -42
- data/fixtures/vcr_cassettes/ChartMogul_Metrics_CustomerChurnRate/behaves_like_Metrics_API_resource/behaves_like_Summary/should_have_summary.yml +0 -40
- data/fixtures/vcr_cassettes/ChartMogul_Metrics_CustomerChurnRate/behaves_like_Metrics_API_resource/should_have_entries.yml +0 -40
- data/fixtures/vcr_cassettes/ChartMogul_Metrics_CustomerCount/behaves_like_Metrics_API_resource/behaves_like_Summary/should_have_summary.yml +0 -42
- data/fixtures/vcr_cassettes/ChartMogul_Metrics_CustomerCount/behaves_like_Metrics_API_resource/should_have_entries.yml +0 -42
- data/fixtures/vcr_cassettes/ChartMogul_Metrics_Customers_Activity/behaves_like_Pageable/should_be_pageable.yml +0 -41
- data/fixtures/vcr_cassettes/ChartMogul_Metrics_Customers_Activity/should_have_Activity_entries.yml +0 -41
- data/fixtures/vcr_cassettes/ChartMogul_Metrics_Customers_Subscription/behaves_like_Pageable/should_be_pageable.yml +0 -40
- data/fixtures/vcr_cassettes/ChartMogul_Metrics_Customers_Subscription/should_have_Subscription_entries.yml +0 -40
- data/fixtures/vcr_cassettes/ChartMogul_Metrics_LTV/behaves_like_Metrics_API_resource/behaves_like_Summary/should_have_summary.yml +0 -40
- data/fixtures/vcr_cassettes/ChartMogul_Metrics_LTV/behaves_like_Metrics_API_resource/should_have_entries.yml +0 -40
- data/fixtures/vcr_cassettes/ChartMogul_Metrics_MRR/behaves_like_Summary/should_have_summary.yml +0 -42
- data/fixtures/vcr_cassettes/ChartMogul_Metrics_MRR/should_have_entries.yml +0 -42
- data/fixtures/vcr_cassettes/ChartMogul_Metrics_MRRChurnRate/behaves_like_Metrics_API_resource/behaves_like_Summary/should_have_summary.yml +0 -40
- data/fixtures/vcr_cassettes/ChartMogul_Metrics_MRRChurnRate/behaves_like_Metrics_API_resource/should_have_entries.yml +0 -40
- data/fixtures/vcr_cassettes/ChartMogul_Ping/pings/and_fails_on_incorrect_credentials.yml +0 -38
- data/fixtures/vcr_cassettes/ChartMogul_Ping/pings/and_fails_with_500_internal_server_error.yml +0 -40
- data/fixtures/vcr_cassettes/ChartMogul_Ping/pings/and_fails_with_504_gateway_timeout_error.yml +0 -40
- data/fixtures/vcr_cassettes/ChartMogul_Ping/pings/when_credentials_correct.yml +0 -38
- data/fixtures/vcr_cassettes/ChartMogul_Plan/API_Interactions/correctly_handles_a_422_error.yml +0 -51
- data/fixtures/vcr_cassettes/ChartMogul_Plan/API_Interactions/correctly_interacts_with_the_API.yml +0 -152
- data/fixtures/vcr_cassettes/ChartMogul_Plan/API_Interactions/deletes_existing_plan.yml +0 -198
- data/fixtures/vcr_cassettes/ChartMogul_Plan/API_Interactions/retrieves_existing_plan_by_uuid.yml +0 -151
- data/fixtures/vcr_cassettes/ChartMogul_Plan/API_Interactions/updates_existing_plan.yml +0 -198
- data/fixtures/vcr_cassettes/ChartMogul_Plan/API_Interactions/updates_existing_plan_using_class_method.yml +0 -164
- data/fixtures/vcr_cassettes/ChartMogul_PlanGroup/API_interactions/correctly_handles_a_422_error.yml +0 -50
- data/fixtures/vcr_cassettes/ChartMogul_PlanGroup/API_interactions/deletes_a_plan_group.yml +0 -293
- data/fixtures/vcr_cassettes/ChartMogul_PlanGroup/API_interactions/retrieves_existing_plan_group_by_uuid.yml +0 -251
- data/fixtures/vcr_cassettes/ChartMogul_PlanGroup/API_interactions/returns_an_array_of_plan_groups.yml +0 -357
- data/fixtures/vcr_cassettes/ChartMogul_PlanGroup/API_interactions/updates_existing_plan_group_name.yml +0 -304
- data/fixtures/vcr_cassettes/ChartMogul_PlanGroup/API_interactions/updates_existing_plan_group_name_via_class_method.yml +0 -297
- data/fixtures/vcr_cassettes/ChartMogul_PlanGroup/API_interactions/updates_existing_plan_group_plans.yml +0 -411
- data/fixtures/vcr_cassettes/ChartMogul_PlanGroups_Plans/API_interactions/given_a_plan_group_uuid_returns_an_array_of_plans_in_the_plan_group.yml +0 -252
- data/fixtures/vcr_cassettes/ChartMogul_Subscription/API_Interactions/connects_subscriptions.yml +0 -436
- data/fixtures/vcr_cassettes/ChartMogul_Subscription/API_Interactions/correctly_interracts_with_the_API.yml +0 -340
- data/fixtures/vcr_cassettes/ChartMogul_Subscription/API_Interactions/has_multiple_aliases.yml +0 -101
- data/fixtures/vcr_cassettes/ChartMogul_Subscription/_update_cancellation_dates/when_array_has_time_objects/is_setting_the_cancellation_dates_of_the_subscription.yml +0 -138
- data/fixtures/vcr_cassettes/ChartMogul_Subscription/_update_cancellation_dates/when_array_includes_invalid_entries/raises_an_exception.yml +0 -93
- data/fixtures/vcr_cassettes/ChartMogul_Subscription/_update_cancellation_dates/when_array_includes_valid_entries/is_setting_the_cancellation_dates_of_the_subscription.yml +0 -138
- data/fixtures/vcr_cassettes/ChartMogul_Subscription/_update_cancellation_dates/when_array_is_empty/makes_an_API_call_and_removes_the_cancellation_dates.yml +0 -138
- data/fixtures/vcr_cassettes/ChartMogul_SubscriptionEvent/API_interactions/creates_a_new_subscription_event.yml +0 -320
- data/fixtures/vcr_cassettes/ChartMogul_SubscriptionEvent/API_interactions/creates_a_new_subscription_event_through_initialization.yml +0 -320
- data/fixtures/vcr_cassettes/ChartMogul_SubscriptionEvent/API_interactions/deletes_the_subscription_event.yml +0 -377
- data/fixtures/vcr_cassettes/ChartMogul_SubscriptionEvent/API_interactions/lists_all_subscription_events.yml +0 -320
- data/fixtures/vcr_cassettes/ChartMogul_SubscriptionEvent/API_interactions/updates_the_subscription_event.yml +0 -377
- data/fixtures/vcr_cassettes/ChartMogul_Transactions_Payment/API_Interactions/correctly_interracts_with_the_API.yml +0 -243
@@ -1,337 +0,0 @@
|
|
1
|
-
---
|
2
|
-
http_interactions:
|
3
|
-
- request:
|
4
|
-
method: post
|
5
|
-
uri: https://api.chartmogul.com/v1/data_sources
|
6
|
-
body:
|
7
|
-
encoding: UTF-8
|
8
|
-
string: '{"name":"Customer Invoices Test Data Source"}'
|
9
|
-
headers:
|
10
|
-
User-Agent:
|
11
|
-
- Faraday v1.0.1
|
12
|
-
Content-Type:
|
13
|
-
- application/json
|
14
|
-
Authorization:
|
15
|
-
- Basic hidden
|
16
|
-
response:
|
17
|
-
status:
|
18
|
-
code: 201
|
19
|
-
message: Created
|
20
|
-
headers:
|
21
|
-
server:
|
22
|
-
- nginx/1.10.1
|
23
|
-
date:
|
24
|
-
- Fri, 14 Aug 2020 08:21:40 GMT
|
25
|
-
content-type:
|
26
|
-
- application/json
|
27
|
-
transfer-encoding:
|
28
|
-
- chunked
|
29
|
-
connection:
|
30
|
-
- keep-alive
|
31
|
-
status:
|
32
|
-
- 201 Created
|
33
|
-
access-control-allow-credentials:
|
34
|
-
- 'true'
|
35
|
-
body:
|
36
|
-
encoding: UTF-8
|
37
|
-
string: '{"uuid":"ds_2db7bab6-de07-11ea-a4dd-7f82d51c3d05","name":"Customer
|
38
|
-
Invoices Test Data Source","system":"Import API","created_at":"2020-08-14T08:21:40.103Z","status":"idle"}'
|
39
|
-
http_version:
|
40
|
-
recorded_at: Fri, 14 Aug 2020 08:21:40 GMT
|
41
|
-
- request:
|
42
|
-
method: post
|
43
|
-
uri: https://api.chartmogul.com/v1/customers
|
44
|
-
body:
|
45
|
-
encoding: UTF-8
|
46
|
-
string: '{"external_id":"test_cus_ext_id","name":"Test Customer","email":"test@customer.com","country":"DE","city":"Berlin","data_source_uuid":"ds_2db7bab6-de07-11ea-a4dd-7f82d51c3d05"}'
|
47
|
-
headers:
|
48
|
-
User-Agent:
|
49
|
-
- Faraday v1.0.1
|
50
|
-
Content-Type:
|
51
|
-
- application/json
|
52
|
-
Authorization:
|
53
|
-
- Basic hidden
|
54
|
-
response:
|
55
|
-
status:
|
56
|
-
code: 201
|
57
|
-
message: Created
|
58
|
-
headers:
|
59
|
-
server:
|
60
|
-
- nginx/1.10.1
|
61
|
-
date:
|
62
|
-
- Fri, 14 Aug 2020 08:21:40 GMT
|
63
|
-
content-type:
|
64
|
-
- application/json
|
65
|
-
transfer-encoding:
|
66
|
-
- chunked
|
67
|
-
connection:
|
68
|
-
- keep-alive
|
69
|
-
status:
|
70
|
-
- 201 Created
|
71
|
-
access-control-allow-credentials:
|
72
|
-
- 'true'
|
73
|
-
body:
|
74
|
-
encoding: UTF-8
|
75
|
-
string: '{"id":58654367,"uuid":"cus_2e010ebe-de07-11ea-a4dd-ff06789b4dcf","external_id":"test_cus_ext_id","name":"Test
|
76
|
-
Customer","email":"test@customer.com","status":"Lead","customer-since":null,"attributes":{"custom":{},"clearbit":{},"stripe":{},"tags":[]},"data_source_uuid":"ds_2db7bab6-de07-11ea-a4dd-7f82d51c3d05","data_source_uuids":["ds_2db7bab6-de07-11ea-a4dd-7f82d51c3d05"],"external_ids":["test_cus_ext_id"],"company":"","country":"DE","state":null,"city":"Berlin","zip":null,"lead_created_at":null,"free_trial_started_at":null,"address":{"country":"Germany","state":null,"city":"Berlin","address_zip":null},"mrr":0,"arr":0,"billing-system-url":null,"chartmogul-url":"https://app.chartmogul.com/#customers/58654367-Test_Customer","billing-system-type":"Import
|
77
|
-
API","currency":"USD","currency-sign":"$"}'
|
78
|
-
http_version:
|
79
|
-
recorded_at: Fri, 14 Aug 2020 08:21:40 GMT
|
80
|
-
- request:
|
81
|
-
method: post
|
82
|
-
uri: https://api.chartmogul.com/v1/plans
|
83
|
-
body:
|
84
|
-
encoding: UTF-8
|
85
|
-
string: '{"name":"Test Plan","interval_count":7,"interval_unit":"day","external_id":"test_cus_pl_ext_id","data_source_uuid":"ds_2db7bab6-de07-11ea-a4dd-7f82d51c3d05"}'
|
86
|
-
headers:
|
87
|
-
User-Agent:
|
88
|
-
- Faraday v1.0.1
|
89
|
-
Content-Type:
|
90
|
-
- application/json
|
91
|
-
Authorization:
|
92
|
-
- Basic hidden
|
93
|
-
response:
|
94
|
-
status:
|
95
|
-
code: 201
|
96
|
-
message: Created
|
97
|
-
headers:
|
98
|
-
server:
|
99
|
-
- nginx/1.10.1
|
100
|
-
date:
|
101
|
-
- Fri, 14 Aug 2020 08:21:41 GMT
|
102
|
-
content-type:
|
103
|
-
- application/json; charset=utf-8
|
104
|
-
transfer-encoding:
|
105
|
-
- chunked
|
106
|
-
connection:
|
107
|
-
- keep-alive
|
108
|
-
status:
|
109
|
-
- 201 Created
|
110
|
-
x-frame-options:
|
111
|
-
- SAMEORIGIN
|
112
|
-
x-xss-protection:
|
113
|
-
- 1; mode=block
|
114
|
-
x-content-type-options:
|
115
|
-
- nosniff
|
116
|
-
x-download-options:
|
117
|
-
- noopen
|
118
|
-
x-permitted-cross-domain-policies:
|
119
|
-
- none
|
120
|
-
referrer-policy:
|
121
|
-
- strict-origin-when-cross-origin
|
122
|
-
etag:
|
123
|
-
- W/"1d19bf324f0b6bf397ba8851cb55543c"
|
124
|
-
cache-control:
|
125
|
-
- max-age=0, private, must-revalidate
|
126
|
-
x-request-id:
|
127
|
-
- cbb7d1e3-f3a4-4ba2-b85c-7d3eed91922d
|
128
|
-
x-runtime:
|
129
|
-
- '0.350185'
|
130
|
-
strict-transport-security:
|
131
|
-
- max-age=15768000
|
132
|
-
body:
|
133
|
-
encoding: UTF-8
|
134
|
-
string: '{"external_id":"test_cus_pl_ext_id","name":"Test Plan","interval_count":7,"interval_unit":"day","data_source_uuid":"ds_2db7bab6-de07-11ea-a4dd-7f82d51c3d05","uuid":"pl_2e010ebf-de07-11ea-a4dd-8bf0a8234993"}'
|
135
|
-
http_version:
|
136
|
-
recorded_at: Fri, 14 Aug 2020 08:21:41 GMT
|
137
|
-
- request:
|
138
|
-
method: get
|
139
|
-
uri: https://api.chartmogul.com/v1/import/customers/cus_2e010ebe-de07-11ea-a4dd-ff06789b4dcf/invoices
|
140
|
-
body:
|
141
|
-
encoding: US-ASCII
|
142
|
-
string: ''
|
143
|
-
headers:
|
144
|
-
User-Agent:
|
145
|
-
- Faraday v1.0.1
|
146
|
-
Content-Type:
|
147
|
-
- application/json
|
148
|
-
Authorization:
|
149
|
-
- Basic hidden
|
150
|
-
response:
|
151
|
-
status:
|
152
|
-
code: 200
|
153
|
-
message: OK
|
154
|
-
headers:
|
155
|
-
server:
|
156
|
-
- nginx/1.10.1
|
157
|
-
date:
|
158
|
-
- Fri, 14 Aug 2020 08:21:41 GMT
|
159
|
-
content-type:
|
160
|
-
- application/json; charset=utf-8
|
161
|
-
transfer-encoding:
|
162
|
-
- chunked
|
163
|
-
connection:
|
164
|
-
- keep-alive
|
165
|
-
vary:
|
166
|
-
- Accept-Encoding, Accept-Encoding
|
167
|
-
status:
|
168
|
-
- 200 OK
|
169
|
-
x-frame-options:
|
170
|
-
- SAMEORIGIN
|
171
|
-
x-xss-protection:
|
172
|
-
- 1; mode=block
|
173
|
-
x-content-type-options:
|
174
|
-
- nosniff
|
175
|
-
x-download-options:
|
176
|
-
- noopen
|
177
|
-
x-permitted-cross-domain-policies:
|
178
|
-
- none
|
179
|
-
referrer-policy:
|
180
|
-
- strict-origin-when-cross-origin
|
181
|
-
etag:
|
182
|
-
- W/"aeef59b540af9e5982db384f237518a2"
|
183
|
-
cache-control:
|
184
|
-
- max-age=0, private, must-revalidate
|
185
|
-
x-request-id:
|
186
|
-
- 47e6129d-8195-4273-9c31-170905e27755
|
187
|
-
x-runtime:
|
188
|
-
- '0.179805'
|
189
|
-
strict-transport-security:
|
190
|
-
- max-age=15768000
|
191
|
-
body:
|
192
|
-
encoding: ASCII-8BIT
|
193
|
-
string: '{"customer_uuid":"cus_2e010ebe-de07-11ea-a4dd-ff06789b4dcf","invoices":[],"current_page":1,"total_pages":0}'
|
194
|
-
http_version:
|
195
|
-
recorded_at: Fri, 14 Aug 2020 08:21:42 GMT
|
196
|
-
- request:
|
197
|
-
method: post
|
198
|
-
uri: https://api.chartmogul.com/v1/import/customers/cus_2e010ebe-de07-11ea-a4dd-ff06789b4dcf/invoices
|
199
|
-
body:
|
200
|
-
encoding: UTF-8
|
201
|
-
string: '{"invoices":[{"date":"2016-01-01 12:00:00 UTC","currency":"USD","line_items":[{"type":"subscription","subscription_external_id":"test_cus_sub_ext_id","service_period_start":"2016-01-01
|
202
|
-
12:00:00 UTC","service_period_end":"2016-02-01 12:00:00 UTC","amount_in_cents":1000,"cancelled_at":"2016-01-15
|
203
|
-
12:00:00 UTC","prorated":false,"quantity":5,"discount_amount_in_cents":1200,"discount_code":"DISCCODE","tax_amount_in_cents":200,"external_id":"test_cus_li_ext_id","plan_uuid":"pl_2e010ebf-de07-11ea-a4dd-8bf0a8234993"}],"transactions":[{"type":"payment","date":"2016-01-01
|
204
|
-
12:00:00 UTC","result":"successful","external_id":"test_cus_tr_ext_id"}],"external_id":"test_cus_inv_ext_id","customer_external_id":"test_cus_ext_id","due_date":"2016-01-07
|
205
|
-
12:00:00 UTC"}],"customer_uuid":"cus_2e010ebe-de07-11ea-a4dd-ff06789b4dcf"}'
|
206
|
-
headers:
|
207
|
-
User-Agent:
|
208
|
-
- Faraday v1.0.1
|
209
|
-
Content-Type:
|
210
|
-
- application/json
|
211
|
-
Authorization:
|
212
|
-
- Basic hidden
|
213
|
-
response:
|
214
|
-
status:
|
215
|
-
code: 201
|
216
|
-
message: Created
|
217
|
-
headers:
|
218
|
-
server:
|
219
|
-
- nginx/1.10.1
|
220
|
-
date:
|
221
|
-
- Fri, 14 Aug 2020 08:21:43 GMT
|
222
|
-
content-type:
|
223
|
-
- application/json; charset=utf-8
|
224
|
-
transfer-encoding:
|
225
|
-
- chunked
|
226
|
-
connection:
|
227
|
-
- keep-alive
|
228
|
-
status:
|
229
|
-
- 201 Created
|
230
|
-
x-frame-options:
|
231
|
-
- SAMEORIGIN
|
232
|
-
x-xss-protection:
|
233
|
-
- 1; mode=block
|
234
|
-
x-content-type-options:
|
235
|
-
- nosniff
|
236
|
-
x-download-options:
|
237
|
-
- noopen
|
238
|
-
x-permitted-cross-domain-policies:
|
239
|
-
- none
|
240
|
-
referrer-policy:
|
241
|
-
- strict-origin-when-cross-origin
|
242
|
-
etag:
|
243
|
-
- W/"2f2be4d16bccef7180e8df0515ebfd2f"
|
244
|
-
cache-control:
|
245
|
-
- max-age=0, private, must-revalidate
|
246
|
-
x-request-id:
|
247
|
-
- ccdcc2fb-0a04-4307-94c8-f8482ec6bd09
|
248
|
-
x-runtime:
|
249
|
-
- '1.437992'
|
250
|
-
strict-transport-security:
|
251
|
-
- max-age=15768000
|
252
|
-
body:
|
253
|
-
encoding: UTF-8
|
254
|
-
string: '{"invoices":[{"uuid":"inv_deb98a20-3e71-49df-a49a-ac9d29c004be","date":"2016-01-01T12:00:00.000Z","due_date":"2016-01-07T12:00:00.000Z","external_id":"test_cus_inv_ext_id","currency":"USD","line_items":[{"uuid":"li_ffa7fad8-c393-45d2-aec4-2a869ece67c5","external_id":"test_cus_li_ext_id","type":"subscription","subscription_uuid":"sub_f3fa6a4e-8fc8-4843-95f2-062bc17826c6","subscription_external_id":"test_cus_sub_ext_id","prorated":false,"service_period_start":"2016-01-01T12:00:00.000Z","service_period_end":"2016-02-01T12:00:00.000Z","plan_uuid":"pl_2e010ebf-de07-11ea-a4dd-8bf0a8234993","amount_in_cents":1000,"quantity":5,"discount_code":"DISCCODE","discount_amount_in_cents":1200,"tax_amount_in_cents":200,"transaction_fees_in_cents":0,"account_code":""}],"transactions":[{"uuid":"tr_ff121f19-ef39-4bc8-824e-225d1b33e5da","external_id":"test_cus_tr_ext_id","type":"payment","date":"2016-01-01T12:00:00.000Z","result":"successful"}]}]}'
|
255
|
-
http_version:
|
256
|
-
recorded_at: Fri, 14 Aug 2020 08:21:43 GMT
|
257
|
-
- request:
|
258
|
-
method: delete
|
259
|
-
uri: https://api.chartmogul.com/v1/data_sources/ds_2db7bab6-de07-11ea-a4dd-7f82d51c3d05/customers/cus_2e010ebe-de07-11ea-a4dd-ff06789b4dcf/invoices
|
260
|
-
body:
|
261
|
-
encoding: US-ASCII
|
262
|
-
string: ''
|
263
|
-
headers:
|
264
|
-
User-Agent:
|
265
|
-
- Faraday v1.0.1
|
266
|
-
Authorization:
|
267
|
-
- Basic hidden
|
268
|
-
response:
|
269
|
-
status:
|
270
|
-
code: 204
|
271
|
-
message: No Content
|
272
|
-
headers:
|
273
|
-
server:
|
274
|
-
- nginx/1.10.1
|
275
|
-
date:
|
276
|
-
- Fri, 14 Aug 2020 08:21:44 GMT
|
277
|
-
connection:
|
278
|
-
- keep-alive
|
279
|
-
status:
|
280
|
-
- 204 No Content
|
281
|
-
x-frame-options:
|
282
|
-
- SAMEORIGIN
|
283
|
-
x-xss-protection:
|
284
|
-
- 1; mode=block
|
285
|
-
x-content-type-options:
|
286
|
-
- nosniff
|
287
|
-
x-download-options:
|
288
|
-
- noopen
|
289
|
-
x-permitted-cross-domain-policies:
|
290
|
-
- none
|
291
|
-
referrer-policy:
|
292
|
-
- strict-origin-when-cross-origin
|
293
|
-
cache-control:
|
294
|
-
- no-cache
|
295
|
-
x-request-id:
|
296
|
-
- c03bcf86-5a42-4655-b015-76ffc653ec91
|
297
|
-
x-runtime:
|
298
|
-
- '0.353793'
|
299
|
-
strict-transport-security:
|
300
|
-
- max-age=15768000
|
301
|
-
body:
|
302
|
-
encoding: UTF-8
|
303
|
-
string: ''
|
304
|
-
http_version:
|
305
|
-
recorded_at: Fri, 14 Aug 2020 08:21:44 GMT
|
306
|
-
- request:
|
307
|
-
method: delete
|
308
|
-
uri: https://api.chartmogul.com/v1/data_sources/ds_2db7bab6-de07-11ea-a4dd-7f82d51c3d05
|
309
|
-
body:
|
310
|
-
encoding: US-ASCII
|
311
|
-
string: ''
|
312
|
-
headers:
|
313
|
-
User-Agent:
|
314
|
-
- Faraday v1.0.1
|
315
|
-
Authorization:
|
316
|
-
- Basic hidden
|
317
|
-
response:
|
318
|
-
status:
|
319
|
-
code: 204
|
320
|
-
message: No Content
|
321
|
-
headers:
|
322
|
-
server:
|
323
|
-
- nginx/1.10.1
|
324
|
-
date:
|
325
|
-
- Fri, 14 Aug 2020 08:21:44 GMT
|
326
|
-
connection:
|
327
|
-
- keep-alive
|
328
|
-
status:
|
329
|
-
- 204 No Content
|
330
|
-
access-control-allow-credentials:
|
331
|
-
- 'true'
|
332
|
-
body:
|
333
|
-
encoding: UTF-8
|
334
|
-
string: ''
|
335
|
-
http_version:
|
336
|
-
recorded_at: Fri, 14 Aug 2020 08:21:44 GMT
|
337
|
-
recorded_with: VCR 5.1.0
|
@@ -1,189 +0,0 @@
|
|
1
|
-
---
|
2
|
-
http_interactions:
|
3
|
-
- request:
|
4
|
-
method: post
|
5
|
-
uri: https://api.chartmogul.com/v1/data_sources
|
6
|
-
body:
|
7
|
-
encoding: UTF-8
|
8
|
-
string: '{"name":"Test Data Source"}'
|
9
|
-
headers:
|
10
|
-
User-Agent:
|
11
|
-
- Faraday v0.9.1
|
12
|
-
Content-Type:
|
13
|
-
- application/json
|
14
|
-
Authorization:
|
15
|
-
- Basic hidden
|
16
|
-
response:
|
17
|
-
status:
|
18
|
-
code: 201
|
19
|
-
message:
|
20
|
-
headers:
|
21
|
-
server:
|
22
|
-
- nginx/1.9.10
|
23
|
-
date:
|
24
|
-
- Sun, 05 Jun 2016 17:02:43 GMT
|
25
|
-
content-type:
|
26
|
-
- application/json; charset=utf-8
|
27
|
-
transfer-encoding:
|
28
|
-
- chunked
|
29
|
-
connection:
|
30
|
-
- close
|
31
|
-
x-frame-options:
|
32
|
-
- SAMEORIGIN
|
33
|
-
x-xss-protection:
|
34
|
-
- 1; mode=block
|
35
|
-
x-content-type-options:
|
36
|
-
- nosniff
|
37
|
-
etag:
|
38
|
-
- W/"2cbdc42d67c582b8b8e9b5b649142c6d"
|
39
|
-
cache-control:
|
40
|
-
- max-age=0, private, must-revalidate
|
41
|
-
x-request-id:
|
42
|
-
- 8e251145-840a-4a38-ba7c-468416d00c7a
|
43
|
-
x-runtime:
|
44
|
-
- '0.195234'
|
45
|
-
strict-transport-security:
|
46
|
-
- max-age=15768000
|
47
|
-
body:
|
48
|
-
encoding: UTF-8
|
49
|
-
string: '{"uuid":"ds_9afd5143-3884-4977-9281-dbb5f15df461","name":"Test Data
|
50
|
-
Source","created_at":"2016-06-05T17:02:43.282Z","status":"never_imported"}'
|
51
|
-
http_version:
|
52
|
-
recorded_at: Sun, 05 Jun 2016 17:02:43 GMT
|
53
|
-
- request:
|
54
|
-
method: get
|
55
|
-
uri: https://api.chartmogul.com/v1/data_sources
|
56
|
-
body:
|
57
|
-
encoding: US-ASCII
|
58
|
-
string: ''
|
59
|
-
headers:
|
60
|
-
User-Agent:
|
61
|
-
- Faraday v0.9.1
|
62
|
-
Authorization:
|
63
|
-
- Basic hidden
|
64
|
-
response:
|
65
|
-
status:
|
66
|
-
code: 200
|
67
|
-
message:
|
68
|
-
headers:
|
69
|
-
server:
|
70
|
-
- nginx/1.9.10
|
71
|
-
date:
|
72
|
-
- Sun, 05 Jun 2016 17:02:43 GMT
|
73
|
-
content-type:
|
74
|
-
- application/json; charset=utf-8
|
75
|
-
transfer-encoding:
|
76
|
-
- chunked
|
77
|
-
connection:
|
78
|
-
- close
|
79
|
-
x-frame-options:
|
80
|
-
- SAMEORIGIN
|
81
|
-
x-xss-protection:
|
82
|
-
- 1; mode=block
|
83
|
-
x-content-type-options:
|
84
|
-
- nosniff
|
85
|
-
etag:
|
86
|
-
- W/"8d1f4cac283a3aecfeea3e952b417e64"
|
87
|
-
cache-control:
|
88
|
-
- max-age=0, private, must-revalidate
|
89
|
-
x-request-id:
|
90
|
-
- a8ee9d0b-364e-4f70-a17f-bfb4883e6ba7
|
91
|
-
x-runtime:
|
92
|
-
- '0.264734'
|
93
|
-
strict-transport-security:
|
94
|
-
- max-age=15768000
|
95
|
-
body:
|
96
|
-
encoding: UTF-8
|
97
|
-
string: '{"data_sources":[{"uuid":"ds_9afd5143-3884-4977-9281-dbb5f15df461","name":"Test
|
98
|
-
Data Source","created_at":"2016-06-05T17:02:43.282Z","status":"never_imported"}]}'
|
99
|
-
http_version:
|
100
|
-
recorded_at: Sun, 05 Jun 2016 17:02:43 GMT
|
101
|
-
- request:
|
102
|
-
method: delete
|
103
|
-
uri: https://api.chartmogul.com/v1/data_sources/ds_9afd5143-3884-4977-9281-dbb5f15df461
|
104
|
-
body:
|
105
|
-
encoding: US-ASCII
|
106
|
-
string: ''
|
107
|
-
headers:
|
108
|
-
User-Agent:
|
109
|
-
- Faraday v0.9.1
|
110
|
-
Authorization:
|
111
|
-
- Basic hidden
|
112
|
-
response:
|
113
|
-
status:
|
114
|
-
code: 204
|
115
|
-
message:
|
116
|
-
headers:
|
117
|
-
server:
|
118
|
-
- nginx/1.9.10
|
119
|
-
date:
|
120
|
-
- Sun, 05 Jun 2016 17:02:44 GMT
|
121
|
-
connection:
|
122
|
-
- close
|
123
|
-
x-frame-options:
|
124
|
-
- SAMEORIGIN
|
125
|
-
x-xss-protection:
|
126
|
-
- 1; mode=block
|
127
|
-
x-content-type-options:
|
128
|
-
- nosniff
|
129
|
-
cache-control:
|
130
|
-
- no-cache
|
131
|
-
x-request-id:
|
132
|
-
- 11210672-f1bf-4590-9db3-77894c7aa619
|
133
|
-
x-runtime:
|
134
|
-
- '0.008042'
|
135
|
-
strict-transport-security:
|
136
|
-
- max-age=15768000
|
137
|
-
body:
|
138
|
-
encoding: UTF-8
|
139
|
-
string: ''
|
140
|
-
http_version:
|
141
|
-
recorded_at: Sun, 05 Jun 2016 17:02:44 GMT
|
142
|
-
- request:
|
143
|
-
method: get
|
144
|
-
uri: https://api.chartmogul.com/v1/data_sources
|
145
|
-
body:
|
146
|
-
encoding: US-ASCII
|
147
|
-
string: ''
|
148
|
-
headers:
|
149
|
-
User-Agent:
|
150
|
-
- Faraday v0.9.1
|
151
|
-
Authorization:
|
152
|
-
- Basic hidden
|
153
|
-
response:
|
154
|
-
status:
|
155
|
-
code: 200
|
156
|
-
message:
|
157
|
-
headers:
|
158
|
-
server:
|
159
|
-
- nginx/1.9.10
|
160
|
-
date:
|
161
|
-
- Sun, 05 Jun 2016 17:02:54 GMT
|
162
|
-
content-type:
|
163
|
-
- application/json; charset=utf-8
|
164
|
-
transfer-encoding:
|
165
|
-
- chunked
|
166
|
-
connection:
|
167
|
-
- close
|
168
|
-
x-frame-options:
|
169
|
-
- SAMEORIGIN
|
170
|
-
x-xss-protection:
|
171
|
-
- 1; mode=block
|
172
|
-
x-content-type-options:
|
173
|
-
- nosniff
|
174
|
-
etag:
|
175
|
-
- W/"fff2ed4cc06b2b7851a2db975ef7e229"
|
176
|
-
cache-control:
|
177
|
-
- max-age=0, private, must-revalidate
|
178
|
-
x-request-id:
|
179
|
-
- 1340397d-947c-4483-a970-d3707ea5d8a3
|
180
|
-
x-runtime:
|
181
|
-
- '0.121280'
|
182
|
-
strict-transport-security:
|
183
|
-
- max-age=15768000
|
184
|
-
body:
|
185
|
-
encoding: UTF-8
|
186
|
-
string: '{"data_sources":[]}'
|
187
|
-
http_version:
|
188
|
-
recorded_at: Sun, 05 Jun 2016 17:02:54 GMT
|
189
|
-
recorded_with: VCR 3.0.3
|
@@ -1,46 +0,0 @@
|
|
1
|
-
---
|
2
|
-
http_interactions:
|
3
|
-
- request:
|
4
|
-
method: delete
|
5
|
-
uri: https://api.chartmogul.com/v1/data_sources/1234-a-uuid-that-doesnt-exist
|
6
|
-
body:
|
7
|
-
encoding: US-ASCII
|
8
|
-
string: ''
|
9
|
-
headers:
|
10
|
-
User-Agent:
|
11
|
-
- Faraday v0.9.1
|
12
|
-
Authorization:
|
13
|
-
- Basic hidden
|
14
|
-
response:
|
15
|
-
status:
|
16
|
-
code: 404
|
17
|
-
message:
|
18
|
-
headers:
|
19
|
-
server:
|
20
|
-
- nginx/1.9.10
|
21
|
-
date:
|
22
|
-
- Sun, 05 Jun 2016 17:05:01 GMT
|
23
|
-
content-type:
|
24
|
-
- application/json; charset=utf-8
|
25
|
-
transfer-encoding:
|
26
|
-
- chunked
|
27
|
-
connection:
|
28
|
-
- close
|
29
|
-
x-frame-options:
|
30
|
-
- SAMEORIGIN
|
31
|
-
x-xss-protection:
|
32
|
-
- 1; mode=block
|
33
|
-
x-content-type-options:
|
34
|
-
- nosniff
|
35
|
-
cache-control:
|
36
|
-
- no-cache
|
37
|
-
x-request-id:
|
38
|
-
- f12d6c48-58f5-4ccd-b398-ff4e7acb93bc
|
39
|
-
x-runtime:
|
40
|
-
- '0.010826'
|
41
|
-
body:
|
42
|
-
encoding: UTF-8
|
43
|
-
string: '{"error":"Data source not found"}'
|
44
|
-
http_version:
|
45
|
-
recorded_at: Sun, 05 Jun 2016 17:05:01 GMT
|
46
|
-
recorded_with: VCR 3.0.3
|
@@ -1,48 +0,0 @@
|
|
1
|
-
---
|
2
|
-
http_interactions:
|
3
|
-
- request:
|
4
|
-
method: post
|
5
|
-
uri: https://api.chartmogul.com/v1/data_sources
|
6
|
-
body:
|
7
|
-
encoding: UTF-8
|
8
|
-
string: '{"name":null}'
|
9
|
-
headers:
|
10
|
-
User-Agent:
|
11
|
-
- Faraday v0.9.1
|
12
|
-
Content-Type:
|
13
|
-
- application/json
|
14
|
-
Authorization:
|
15
|
-
- Basic hidden
|
16
|
-
response:
|
17
|
-
status:
|
18
|
-
code: 422
|
19
|
-
message:
|
20
|
-
headers:
|
21
|
-
server:
|
22
|
-
- nginx/1.9.10
|
23
|
-
date:
|
24
|
-
- Sun, 05 Jun 2016 17:04:50 GMT
|
25
|
-
content-type:
|
26
|
-
- application/json; charset=utf-8
|
27
|
-
transfer-encoding:
|
28
|
-
- chunked
|
29
|
-
connection:
|
30
|
-
- close
|
31
|
-
x-frame-options:
|
32
|
-
- SAMEORIGIN
|
33
|
-
x-xss-protection:
|
34
|
-
- 1; mode=block
|
35
|
-
x-content-type-options:
|
36
|
-
- nosniff
|
37
|
-
cache-control:
|
38
|
-
- no-cache
|
39
|
-
x-request-id:
|
40
|
-
- 76a25073-4c20-49fb-83b2-bbad2c361b0d
|
41
|
-
x-runtime:
|
42
|
-
- '0.009928'
|
43
|
-
body:
|
44
|
-
encoding: UTF-8
|
45
|
-
string: '{"errors":{"name":"A name is required for each data source."}}'
|
46
|
-
http_version:
|
47
|
-
recorded_at: Sun, 05 Jun 2016 17:04:50 GMT
|
48
|
-
recorded_with: VCR 3.0.3
|