chartmogul-ruby 3.2.0 → 3.3.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (118) hide show
  1. checksums.yaml +4 -4
  2. data/.gitignore +2 -1
  3. data/changelog.md +11 -0
  4. data/chartmogul-ruby.gemspec +1 -1
  5. data/lib/chartmogul/api/actions/custom.rb +2 -1
  6. data/lib/chartmogul/concerns/pageable_with_cursor.rb +4 -0
  7. data/lib/chartmogul/contact.rb +1 -4
  8. data/lib/chartmogul/customer.rb +13 -1
  9. data/lib/chartmogul/customer_invoices.rb +5 -1
  10. data/lib/chartmogul/enrichment/customer.rb +1 -0
  11. data/lib/chartmogul/invoice.rb +1 -0
  12. data/lib/chartmogul/metrics/activity.rb +1 -4
  13. data/lib/chartmogul/metrics/customers/activity.rb +5 -0
  14. data/lib/chartmogul/metrics/customers/subscription.rb +5 -0
  15. data/lib/chartmogul/plan.rb +1 -0
  16. data/lib/chartmogul/plan_group.rb +1 -0
  17. data/lib/chartmogul/plan_groups/plans.rb +11 -0
  18. data/lib/chartmogul/subscription.rb +5 -0
  19. data/lib/chartmogul/subscription_event.rb +17 -0
  20. data/lib/chartmogul/version.rb +1 -1
  21. metadata +5 -102
  22. data/fixtures/vcr_cassettes/ChartMogul_APIResource/connection/works_in_a_threaded_environment.yml +0 -112
  23. data/fixtures/vcr_cassettes/ChartMogul_APIResource/connection/works_when_credentials_are_updated.yml +0 -77
  24. data/fixtures/vcr_cassettes/ChartMogul_Account/returns_details_of_current_account.yml +0 -64
  25. data/fixtures/vcr_cassettes/ChartMogul_Contact/API_Interactions/creates_contact_correctly.yml +0 -134
  26. data/fixtures/vcr_cassettes/ChartMogul_Contact/API_Interactions/destroys_contact_correctly.yml +0 -99
  27. data/fixtures/vcr_cassettes/ChartMogul_Contact/API_Interactions/merges_contact_correctly.yml +0 -105
  28. data/fixtures/vcr_cassettes/ChartMogul_Contact/API_Interactions/paginates_correctly.yml +0 -133
  29. data/fixtures/vcr_cassettes/ChartMogul_Contact/API_Interactions/updates_contact_correctly.yml +0 -102
  30. data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/adds_custom_attributes.yml +0 -80
  31. data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/adds_required_tags.yml +0 -79
  32. data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/can_page_through_search_endpoint.yml +0 -43
  33. data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/correctly_handles_a_422_response.yml +0 -50
  34. data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/correctly_interracts_with_the_API.yml +0 -192
  35. data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/creates_a_contact_belonging_to_the_customer_correctly.yml +0 -72
  36. data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/lists_the_contacts_belonging_to_the_customer_correctly.yml +0 -72
  37. data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/merges_customers.yml +0 -185
  38. data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/raises_401_if_invalid_credentials.yml +0 -38
  39. data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/raises_404_if_no_customers_found.yml +0 -38
  40. data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/raises_422_for_update_with_invalid_data.yml +0 -86
  41. data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/removes_custom_attributes.yml +0 -80
  42. data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/removes_tags.yml +0 -80
  43. data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/respects_camel_case_for_all_customers_endpoint.yml +0 -45
  44. data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/returns_all_customers_through_list_all_endpoint.yml +0 -47
  45. data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/returns_customer_through_retrieve_endpoint.yml +0 -42
  46. data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/returns_right_customers_through_search_endpoint.yml +0 -43
  47. data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/updates_custom_attributes.yml +0 -81
  48. data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/updates_customer.yml +0 -139
  49. data/fixtures/vcr_cassettes/ChartMogul_Customer/API_Interactions/updates_customer_using_class_method.yml +0 -53
  50. data/fixtures/vcr_cassettes/ChartMogul_Customer/_find_by_external_id/when_external_id_is_provided/returns_matching_user_if_exists.yml +0 -102
  51. 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
  52. data/fixtures/vcr_cassettes/ChartMogul_CustomerInvoices/API_Interactions/correctly_interracts_with_the_API.yml +0 -337
  53. data/fixtures/vcr_cassettes/ChartMogul_DataSource/API_Interactions/correctly_interracts_with_the_API.yml +0 -189
  54. data/fixtures/vcr_cassettes/ChartMogul_DataSource/API_Interactions/correctly_raises_errors_on_404.yml +0 -46
  55. data/fixtures/vcr_cassettes/ChartMogul_DataSource/API_Interactions/correctly_raises_errors_on_422.yml +0 -48
  56. data/fixtures/vcr_cassettes/ChartMogul_DataSource/API_Interactions/retrieves_existing_data_source_matching_uuid.yml +0 -101
  57. data/fixtures/vcr_cassettes/ChartMogul_Invoice/API_Interactions/deletes_an_invoice.yml +0 -37
  58. data/fixtures/vcr_cassettes/ChartMogul_Invoice/API_Interactions/deletes_an_invoice_with_class_method.yml +0 -37
  59. data/fixtures/vcr_cassettes/ChartMogul_Invoice/API_Interactions/raises_error_on_deleting_non-existing_invoice.yml +0 -42
  60. data/fixtures/vcr_cassettes/ChartMogul_Invoice/API_Interactions/retrieves_existing_invoice_by_uuid.yml +0 -50
  61. data/fixtures/vcr_cassettes/ChartMogul_Invoice/API_Interactions/returns_all_invoices_through_list_all_endpoint.yml +0 -46
  62. data/fixtures/vcr_cassettes/ChartMogul_Metrics_ARPA/behaves_like_Metrics_API_resource/behaves_like_Summary/should_have_summary.yml +0 -42
  63. data/fixtures/vcr_cassettes/ChartMogul_Metrics_ARPA/behaves_like_Metrics_API_resource/should_have_entries.yml +0 -42
  64. data/fixtures/vcr_cassettes/ChartMogul_Metrics_ARR/behaves_like_Metrics_API_resource/behaves_like_Summary/should_have_summary.yml +0 -42
  65. data/fixtures/vcr_cassettes/ChartMogul_Metrics_ARR/behaves_like_Metrics_API_resource/should_have_entries.yml +0 -42
  66. data/fixtures/vcr_cassettes/ChartMogul_Metrics_ASP/behaves_like_Metrics_API_resource/behaves_like_Summary/should_have_summary.yml +0 -40
  67. data/fixtures/vcr_cassettes/ChartMogul_Metrics_ASP/behaves_like_Metrics_API_resource/should_have_entries.yml +0 -40
  68. data/fixtures/vcr_cassettes/ChartMogul_Metrics_ActivitiesExport/get_activities_export.yml +0 -43
  69. data/fixtures/vcr_cassettes/ChartMogul_Metrics_ActivitiesExport/post_activities_export.yml +0 -83
  70. data/fixtures/vcr_cassettes/ChartMogul_Metrics_Activity/behaves_like_PageableWithAnchor/should_be_pageable.yml +0 -44
  71. data/fixtures/vcr_cassettes/ChartMogul_Metrics_Activity/should_have_Activity_entries.yml +0 -44
  72. data/fixtures/vcr_cassettes/ChartMogul_Metrics_Activity.yml +0 -37
  73. data/fixtures/vcr_cassettes/ChartMogul_Metrics_AllKeyMetric/should_have_entries.yml +0 -42
  74. data/fixtures/vcr_cassettes/ChartMogul_Metrics_AllKeyMetric/should_have_summary.yml +0 -42
  75. data/fixtures/vcr_cassettes/ChartMogul_Metrics_CustomerChurnRate/behaves_like_Metrics_API_resource/behaves_like_Summary/should_have_summary.yml +0 -40
  76. data/fixtures/vcr_cassettes/ChartMogul_Metrics_CustomerChurnRate/behaves_like_Metrics_API_resource/should_have_entries.yml +0 -40
  77. data/fixtures/vcr_cassettes/ChartMogul_Metrics_CustomerCount/behaves_like_Metrics_API_resource/behaves_like_Summary/should_have_summary.yml +0 -42
  78. data/fixtures/vcr_cassettes/ChartMogul_Metrics_CustomerCount/behaves_like_Metrics_API_resource/should_have_entries.yml +0 -42
  79. data/fixtures/vcr_cassettes/ChartMogul_Metrics_Customers_Activity/behaves_like_Pageable/should_be_pageable.yml +0 -41
  80. data/fixtures/vcr_cassettes/ChartMogul_Metrics_Customers_Activity/should_have_Activity_entries.yml +0 -41
  81. data/fixtures/vcr_cassettes/ChartMogul_Metrics_Customers_Subscription/behaves_like_Pageable/should_be_pageable.yml +0 -40
  82. data/fixtures/vcr_cassettes/ChartMogul_Metrics_Customers_Subscription/should_have_Subscription_entries.yml +0 -40
  83. data/fixtures/vcr_cassettes/ChartMogul_Metrics_LTV/behaves_like_Metrics_API_resource/behaves_like_Summary/should_have_summary.yml +0 -40
  84. data/fixtures/vcr_cassettes/ChartMogul_Metrics_LTV/behaves_like_Metrics_API_resource/should_have_entries.yml +0 -40
  85. data/fixtures/vcr_cassettes/ChartMogul_Metrics_MRR/behaves_like_Summary/should_have_summary.yml +0 -42
  86. data/fixtures/vcr_cassettes/ChartMogul_Metrics_MRR/should_have_entries.yml +0 -42
  87. data/fixtures/vcr_cassettes/ChartMogul_Metrics_MRRChurnRate/behaves_like_Metrics_API_resource/behaves_like_Summary/should_have_summary.yml +0 -40
  88. data/fixtures/vcr_cassettes/ChartMogul_Metrics_MRRChurnRate/behaves_like_Metrics_API_resource/should_have_entries.yml +0 -40
  89. data/fixtures/vcr_cassettes/ChartMogul_Ping/pings/and_fails_on_incorrect_credentials.yml +0 -38
  90. data/fixtures/vcr_cassettes/ChartMogul_Ping/pings/and_fails_with_500_internal_server_error.yml +0 -40
  91. data/fixtures/vcr_cassettes/ChartMogul_Ping/pings/and_fails_with_504_gateway_timeout_error.yml +0 -40
  92. data/fixtures/vcr_cassettes/ChartMogul_Ping/pings/when_credentials_correct.yml +0 -38
  93. data/fixtures/vcr_cassettes/ChartMogul_Plan/API_Interactions/correctly_handles_a_422_error.yml +0 -51
  94. data/fixtures/vcr_cassettes/ChartMogul_Plan/API_Interactions/correctly_interacts_with_the_API.yml +0 -152
  95. data/fixtures/vcr_cassettes/ChartMogul_Plan/API_Interactions/deletes_existing_plan.yml +0 -198
  96. data/fixtures/vcr_cassettes/ChartMogul_Plan/API_Interactions/retrieves_existing_plan_by_uuid.yml +0 -151
  97. data/fixtures/vcr_cassettes/ChartMogul_Plan/API_Interactions/updates_existing_plan.yml +0 -198
  98. data/fixtures/vcr_cassettes/ChartMogul_Plan/API_Interactions/updates_existing_plan_using_class_method.yml +0 -164
  99. data/fixtures/vcr_cassettes/ChartMogul_PlanGroup/API_interactions/correctly_handles_a_422_error.yml +0 -50
  100. data/fixtures/vcr_cassettes/ChartMogul_PlanGroup/API_interactions/deletes_a_plan_group.yml +0 -293
  101. data/fixtures/vcr_cassettes/ChartMogul_PlanGroup/API_interactions/retrieves_existing_plan_group_by_uuid.yml +0 -251
  102. data/fixtures/vcr_cassettes/ChartMogul_PlanGroup/API_interactions/returns_an_array_of_plan_groups.yml +0 -357
  103. data/fixtures/vcr_cassettes/ChartMogul_PlanGroup/API_interactions/updates_existing_plan_group_name.yml +0 -304
  104. data/fixtures/vcr_cassettes/ChartMogul_PlanGroup/API_interactions/updates_existing_plan_group_name_via_class_method.yml +0 -297
  105. data/fixtures/vcr_cassettes/ChartMogul_PlanGroup/API_interactions/updates_existing_plan_group_plans.yml +0 -411
  106. 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
  107. data/fixtures/vcr_cassettes/ChartMogul_Subscription/API_Interactions/connects_subscriptions.yml +0 -436
  108. data/fixtures/vcr_cassettes/ChartMogul_Subscription/API_Interactions/correctly_interracts_with_the_API.yml +0 -340
  109. data/fixtures/vcr_cassettes/ChartMogul_Subscription/API_Interactions/has_multiple_aliases.yml +0 -101
  110. 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
  111. data/fixtures/vcr_cassettes/ChartMogul_Subscription/_update_cancellation_dates/when_array_includes_invalid_entries/raises_an_exception.yml +0 -93
  112. 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
  113. 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
  114. data/fixtures/vcr_cassettes/ChartMogul_SubscriptionEvent/API_interactions/creates_a_new_subscription_event.yml +0 -320
  115. data/fixtures/vcr_cassettes/ChartMogul_SubscriptionEvent/API_interactions/deletes_the_subscription_event.yml +0 -377
  116. data/fixtures/vcr_cassettes/ChartMogul_SubscriptionEvent/API_interactions/lists_all_subscription_events.yml +0 -320
  117. data/fixtures/vcr_cassettes/ChartMogul_SubscriptionEvent/API_interactions/updates_the_subscription_event.yml +0 -377
  118. data/fixtures/vcr_cassettes/ChartMogul_Transactions_Payment/API_Interactions/correctly_interracts_with_the_API.yml +0 -243
@@ -1,185 +0,0 @@
1
- ---
2
- http_interactions:
3
- - request:
4
- method: get
5
- uri: https://api.chartmogul.com/v1/customers/cus_35da5436-a730-11e6-a5a0-d32f2a781b50
6
- body:
7
- encoding: UTF-8
8
- string: "{}"
9
- headers:
10
- User-Agent:
11
- - Faraday v0.9.2
12
- Content-Type:
13
- - application/json
14
- Authorization:
15
- - Basic hidden
16
- response:
17
- status:
18
- code: 200
19
- message:
20
- headers:
21
- server:
22
- - nginx/1.10.1
23
- date:
24
- - Thu, 10 Nov 2016 10:32:07 GMT
25
- content-type:
26
- - application/json
27
- content-length:
28
- - '496'
29
- connection:
30
- - close
31
- status:
32
- - 200 OK
33
- access-control-allow-credentials:
34
- - 'true'
35
- body:
36
- encoding: UTF-8
37
- string: '{"id":6474477,"uuid":"cus_35da5436-a730-11e6-a5a0-d32f2a781b50","external_id":"8b5b6aff-ca49-4079-9273-1268a64ac462","name":"from@merge.com","email":"from@merge.com","status":"Lead","customer-since":null,"attributes":{"tags":[]},"address":{"country":"Comoros","state":null,"city":null,"address_zip":null},"mrr":0,"arr":0,"billing-system-url":null,"chartmogul-url":"https://app.chartmogul.com/#customers/6474477-from_merge_com","billing-system-type":"Manual","currency":"UGX","currency-sign":null}'
38
- http_version:
39
- recorded_at: Thu, 10 Nov 2016 10:32:07 GMT
40
- - request:
41
- method: get
42
- uri: https://api.chartmogul.com/v1/customers/cus_fc5451ee-a72f-11e6-9019-3b1a0ecf3c73
43
- body:
44
- encoding: UTF-8
45
- string: "{}"
46
- headers:
47
- User-Agent:
48
- - Faraday v0.9.2
49
- Content-Type:
50
- - application/json
51
- Authorization:
52
- - Basic hidden
53
- response:
54
- status:
55
- code: 200
56
- message:
57
- headers:
58
- server:
59
- - nginx/1.10.1
60
- date:
61
- - Thu, 10 Nov 2016 10:32:07 GMT
62
- content-type:
63
- - application/json
64
- content-length:
65
- - '495'
66
- connection:
67
- - close
68
- status:
69
- - 200 OK
70
- access-control-allow-credentials:
71
- - 'true'
72
- body:
73
- encoding: UTF-8
74
- string: '{"id":6474475,"uuid":"cus_fc5451ee-a72f-11e6-9019-3b1a0ecf3c73","external_id":"7ea39c1b-2286-4cb7-b1c8-9a63e8358875","name":"into@merge.com","email":"into@merge.com","status":"Lead","customer-since":null,"attributes":{"tags":[]},"address":{"country":"Angola","state":null,"city":null,"address_zip":null},"mrr":0,"arr":0,"billing-system-url":null,"chartmogul-url":"https://app.chartmogul.com/#customers/6474475-into_merge_com","billing-system-type":"Manual","currency":"UGX","currency-sign":null}'
75
- http_version:
76
- recorded_at: Thu, 10 Nov 2016 10:32:07 GMT
77
- - request:
78
- method: post
79
- uri: https://api.chartmogul.com/v1/customers/merges
80
- body:
81
- encoding: UTF-8
82
- string: '{"from":{"customer_uuid":"cus_35da5436-a730-11e6-a5a0-d32f2a781b50"},"into":{"customer_uuid":"cus_fc5451ee-a72f-11e6-9019-3b1a0ecf3c73"}}'
83
- headers:
84
- User-Agent:
85
- - Faraday v0.9.2
86
- Content-Type:
87
- - application/json
88
- Authorization:
89
- - Basic hidden
90
- response:
91
- status:
92
- code: 202
93
- message:
94
- headers:
95
- server:
96
- - nginx/1.10.1
97
- date:
98
- - Thu, 10 Nov 2016 10:32:07 GMT
99
- content-type:
100
- - application/json
101
- content-length:
102
- - '2'
103
- connection:
104
- - close
105
- status:
106
- - 202 Accepted
107
- body:
108
- encoding: UTF-8
109
- string: "{}"
110
- http_version:
111
- recorded_at: Thu, 10 Nov 2016 10:32:07 GMT
112
- - request:
113
- method: get
114
- uri: https://api.chartmogul.com/v1/customers/cus_35da5436-a730-11e6-a5a0-d32f2a781b50
115
- body:
116
- encoding: UTF-8
117
- string: "{}"
118
- headers:
119
- User-Agent:
120
- - Faraday v0.9.2
121
- Content-Type:
122
- - application/json
123
- Authorization:
124
- - Basic hidden
125
- response:
126
- status:
127
- code: 404
128
- message:
129
- headers:
130
- server:
131
- - nginx/1.10.1
132
- date:
133
- - Thu, 10 Nov 2016 10:37:08 GMT
134
- content-type:
135
- - application/json
136
- content-length:
137
- - '111'
138
- connection:
139
- - close
140
- status:
141
- - 404 Not Found
142
- body:
143
- encoding: UTF-8
144
- string: '{"code":404,"message":"Customer \"35da5436-a730-11e6-a5a0-d32f2a781b50\"
145
- does not exist","param":"customer_id"}'
146
- http_version:
147
- recorded_at: Thu, 10 Nov 2016 10:37:08 GMT
148
- - request:
149
- method: get
150
- uri: https://api.chartmogul.com/v1/customers/cus_fc5451ee-a72f-11e6-9019-3b1a0ecf3c73
151
- body:
152
- encoding: UTF-8
153
- string: "{}"
154
- headers:
155
- User-Agent:
156
- - Faraday v0.9.2
157
- Content-Type:
158
- - application/json
159
- Authorization:
160
- - Basic hidden
161
- response:
162
- status:
163
- code: 200
164
- message:
165
- headers:
166
- server:
167
- - nginx/1.10.1
168
- date:
169
- - Thu, 10 Nov 2016 10:45:35 GMT
170
- content-type:
171
- - application/json
172
- content-length:
173
- - '512'
174
- connection:
175
- - close
176
- status:
177
- - 200 OK
178
- access-control-allow-credentials:
179
- - 'true'
180
- body:
181
- encoding: UTF-8
182
- string: '{"id":6474475,"uuid":"cus_fc5451ee-a72f-11e6-9019-3b1a0ecf3c73","external_id":"7ea39c1b-2286-4cb7-b1c8-9a63e8358875","name":"into@merge.com","email":"into@merge.com","status":"Lead","customer-since":null,"attributes":{"tags":["merged-customer"]},"address":{"country":"Angola","state":null,"city":null,"address_zip":null},"mrr":0,"arr":0,"billing-system-url":null,"chartmogul-url":"https://app.chartmogul.com/#customers/6474475-into_merge_com","billing-system-type":"Manual","currency":"UGX","currency-sign":null}'
183
- http_version:
184
- recorded_at: Thu, 10 Nov 2016 10:45:35 GMT
185
- recorded_with: VCR 3.0.3
@@ -1,38 +0,0 @@
1
- ---
2
- http_interactions:
3
- - request:
4
- method: get
5
- uri: https://api.chartmogul.com/v1/customers?per_page=10
6
- body:
7
- encoding: US-ASCII
8
- string: ''
9
- headers:
10
- User-Agent:
11
- - Faraday v0.10.0
12
- Content-Type:
13
- - application/json
14
- Authorization:
15
- - Basic hidden
16
- response:
17
- status:
18
- code: 401
19
- message:
20
- headers:
21
- server:
22
- - nginx/1.10.1
23
- date:
24
- - Wed, 28 Dec 2016 17:04:19 GMT
25
- content-type:
26
- - application/json
27
- content-length:
28
- - '63'
29
- connection:
30
- - close
31
- status:
32
- - 401 Unauthorized
33
- body:
34
- encoding: UTF-8
35
- string: '{"code":401,"message":"No valid API key provided","param":null}'
36
- http_version:
37
- recorded_at: Wed, 28 Dec 2016 17:04:19 GMT
38
- recorded_with: VCR 3.0.3
@@ -1,38 +0,0 @@
1
- ---
2
- http_interactions:
3
- - request:
4
- method: get
5
- uri: https://api.chartmogul.com/v1/customers/search?email=no%40email.com
6
- body:
7
- encoding: UTF-8
8
- string: '{}'
9
- headers:
10
- User-Agent:
11
- - Faraday v0.9.2
12
- Content-Type:
13
- - application/json
14
- Authorization:
15
- - Basic hidden
16
- response:
17
- status:
18
- code: 404
19
- message:
20
- headers:
21
- server:
22
- - nginx/1.9.10
23
- date:
24
- - Wed, 29 Jun 2016 12:47:11 GMT
25
- content-type:
26
- - application/json
27
- content-length:
28
- - '94'
29
- connection:
30
- - close
31
- status:
32
- - 404 Not Found
33
- body:
34
- encoding: UTF-8
35
- string: '{"code":404,"message":"Can''t find any customers with email: \"no@email.com\"","param":"email"}'
36
- http_version:
37
- recorded_at: Wed, 29 Jun 2016 12:47:11 GMT
38
- recorded_with: VCR 3.0.3
@@ -1,86 +0,0 @@
1
- ---
2
- http_interactions:
3
- - request:
4
- method: get
5
- uri: https://api.chartmogul.com/v1/customers/cus_782b0716-a728-11e6-8eab-a7d0e8cd5c1e
6
- body:
7
- encoding: UTF-8
8
- string: "{}"
9
- headers:
10
- User-Agent:
11
- - Faraday v0.9.2
12
- Content-Type:
13
- - application/json
14
- Authorization:
15
- - Basic hidden
16
- response:
17
- status:
18
- code: 200
19
- message:
20
- headers:
21
- server:
22
- - nginx/1.10.1
23
- date:
24
- - Thu, 10 Nov 2016 14:35:00 GMT
25
- content-type:
26
- - application/json
27
- content-length:
28
- - '1104'
29
- connection:
30
- - close
31
- vary:
32
- - Accept-Encoding
33
- status:
34
- - 200 OK
35
- access-control-allow-credentials:
36
- - 'true'
37
- body:
38
- encoding: UTF-8
39
- string: '{"id":6474391,"uuid":"cus_782b0716-a728-11e6-8eab-a7d0e8cd5c1e","external_id":"14c58821-ad87-467d-956f-95f35f2cdd3d","name":"Currywurst","email":"curry@wurst.com","status":"Lead","customer-since":null,"attributes":{"tags":["wurst"],"clearbit":{"company":{"category":{"industry":"Commercial
40
- Services \u0026 Supplies","industryGroup":"Commercial \u0026 Professional
41
- Services","sector":"Industrials","subIndustry":"Corporate \u0026 Business"},"geo":{"city":"Lakewood","country":"United
42
- States","postalCode":"80228","state":"Colorado","streetName":"South Union
43
- Boulevard","streetNumber":"165","subPremise":"260"},"metrics":{"alexaGlobalRank":3418524,"alexaUsRank":793393},"name":"CCG","timeZone":"America/Denver","twitter":{"followers":1449,"handle":"CustomerProfit"},"type":"private","utcOffset":-7}},"custom":{"meinung":["lecker"]}},"address":{"country":"Germany","state":"New
44
- York","city":"Berlin","address_zip":null},"mrr":0,"arr":0,"billing-system-url":null,"chartmogul-url":"https://app.chartmogul.com/#customers/6474391-Currywurst","billing-system-type":"Manual","currency":"UGX","currency-sign":null}'
45
- http_version:
46
- recorded_at: Thu, 10 Nov 2016 14:35:00 GMT
47
- - request:
48
- method: patch
49
- uri: https://api.chartmogul.com/v1/customers/cus_782b0716-a728-11e6-8eab-a7d0e8cd5c1e
50
- body:
51
- encoding: UTF-8
52
- string: '{"name":"Currywurst","email":"schnitzel.com","attributes":{"tags":["wurst"],"clearbit":{"company":{"category":{"industry":"Commercial
53
- Services & Supplies","industry_group":"Commercial & Professional Services","sector":"Industrials","sub_industry":"Corporate
54
- & Business"},"geo":{"city":"Lakewood","country":"United States","postal_code":"80228","state":"Colorado","street_name":"South
55
- Union Boulevard","street_number":"165","sub_premise":"260"},"metrics":{"alexa_global_rank":3418524,"alexa_us_rank":793393},"name":"CCG","time_zone":"America/Denver","twitter":{"followers":1449,"handle":"CustomerProfit"},"type":"private","utc_offset":-7}},"custom":{"meinung":["lecker"]}}}'
56
- headers:
57
- User-Agent:
58
- - Faraday v0.9.2
59
- Content-Type:
60
- - application/json
61
- Authorization:
62
- - Basic hidden
63
- response:
64
- status:
65
- code: 422
66
- message:
67
- headers:
68
- server:
69
- - nginx/1.10.1
70
- date:
71
- - Thu, 10 Nov 2016 14:35:00 GMT
72
- content-type:
73
- - application/json
74
- content-length:
75
- - '104'
76
- connection:
77
- - close
78
- status:
79
- - 422 Unprocessable Entity
80
- body:
81
- encoding: UTF-8
82
- string: '{"code":422,"message":"The value provided does not appear to be a valid
83
- email address.","param":"email"}'
84
- http_version:
85
- recorded_at: Thu, 10 Nov 2016 14:35:00 GMT
86
- recorded_with: VCR 3.0.3
@@ -1,80 +0,0 @@
1
- ---
2
- http_interactions:
3
- - request:
4
- method: get
5
- uri: https://api.chartmogul.com/v1/customers/cus_07393ece-aab1-4255-8bcd-0ef11e24b047
6
- body:
7
- encoding: UTF-8
8
- string: '{}'
9
- headers:
10
- User-Agent:
11
- - Faraday v0.9.2
12
- Content-Type:
13
- - application/json
14
- Authorization:
15
- - Basic hidden
16
- response:
17
- status:
18
- code: 200
19
- message:
20
- headers:
21
- server:
22
- - nginx/1.9.10
23
- date:
24
- - Wed, 29 Jun 2016 13:57:20 GMT
25
- content-type:
26
- - application/json
27
- content-length:
28
- - '685'
29
- connection:
30
- - close
31
- status:
32
- - 200 OK
33
- access-control-allow-credentials:
34
- - 'true'
35
- body:
36
- encoding: UTF-8
37
- string: '{"id":20268060,"uuid":"cus_07393ece-aab1-4255-8bcd-0ef11e24b047","external_id":"cus_0001","name":"Adam
38
- Smith","email":"adam@smith.com","status":"Cancelled","customer-since":"2016-05-01T12:00:00+00:00","attributes":{"tags":["another-tag"],"custom":{"string_key":"Another
39
- String Value","integer_key":"5678","timestamp_key":"2016-02-01 00:00:00 UTC","boolean_key":"f"}},"address":{"country":"United
40
- States","state":null,"city":"New York","address_line1":null,"address_line2":null,"address_zip":""},"mrr":0,"arr":0,"billing-system-url":null,"chartmogul-url":"https://app.chartmogul.com/#customers/20268060-Adam_Smith","billing-system-type":"ImportApi","currency":"USD","currency-sign":"$"}'
41
- http_version:
42
- recorded_at: Wed, 29 Jun 2016 13:57:20 GMT
43
- - request:
44
- method: delete
45
- uri: https://api.chartmogul.com/v1/customers/cus_07393ece-aab1-4255-8bcd-0ef11e24b047/attributes/custom
46
- body:
47
- encoding: UTF-8
48
- string: '{"custom":["string_key","integer_key","timestamp_key","boolean_key"]}'
49
- headers:
50
- User-Agent:
51
- - Faraday v0.9.2
52
- Content-Type:
53
- - application/json
54
- Authorization:
55
- - Basic hidden
56
- response:
57
- status:
58
- code: 200
59
- message:
60
- headers:
61
- server:
62
- - nginx/1.9.10
63
- date:
64
- - Wed, 29 Jun 2016 13:57:20 GMT
65
- content-type:
66
- - application/json
67
- content-length:
68
- - '2'
69
- connection:
70
- - close
71
- status:
72
- - 200 OK
73
- access-control-allow-credentials:
74
- - 'true'
75
- body:
76
- encoding: UTF-8
77
- string: '{}'
78
- http_version:
79
- recorded_at: Wed, 29 Jun 2016 13:57:20 GMT
80
- recorded_with: VCR 3.0.3
@@ -1,80 +0,0 @@
1
- ---
2
- http_interactions:
3
- - request:
4
- method: get
5
- uri: https://api.chartmogul.com/v1/customers/cus_07393ece-aab1-4255-8bcd-0ef11e24b047
6
- body:
7
- encoding: UTF-8
8
- string: '{}'
9
- headers:
10
- User-Agent:
11
- - Faraday v0.9.2
12
- Content-Type:
13
- - application/json
14
- Authorization:
15
- - Basic hidden
16
- response:
17
- status:
18
- code: 200
19
- message:
20
- headers:
21
- server:
22
- - nginx/1.9.10
23
- date:
24
- - Wed, 29 Jun 2016 12:47:10 GMT
25
- content-type:
26
- - application/json
27
- content-length:
28
- - '695'
29
- connection:
30
- - close
31
- status:
32
- - 200 OK
33
- access-control-allow-credentials:
34
- - 'true'
35
- body:
36
- encoding: UTF-8
37
- string: '{"id":20268060,"uuid":"cus_07393ece-aab1-4255-8bcd-0ef11e24b047","external_id":"cus_0001","name":"Adam
38
- Smith","email":"adam@smith.com","status":"Cancelled","customer-since":"2016-05-01T12:00:00+00:00","attributes":{"tags":["example","another-tag"],"custom":{"string_key":"Another
39
- String Value","integer_key":"5678","timestamp_key":"2016-02-01 00:00:00 UTC","boolean_key":"f"}},"address":{"country":"United
40
- States","state":null,"city":"New York","address_line1":null,"address_line2":null,"address_zip":""},"mrr":0,"arr":0,"billing-system-url":null,"chartmogul-url":"https://app.chartmogul.com/#customers/20268060-Adam_Smith","billing-system-type":"ImportApi","currency":"USD","currency-sign":"$"}'
41
- http_version:
42
- recorded_at: Wed, 29 Jun 2016 12:47:10 GMT
43
- - request:
44
- method: delete
45
- uri: https://api.chartmogul.com/v1/customers/cus_07393ece-aab1-4255-8bcd-0ef11e24b047/attributes/tags
46
- body:
47
- encoding: UTF-8
48
- string: '{"tags":["example"]}'
49
- headers:
50
- User-Agent:
51
- - Faraday v0.9.2
52
- Content-Type:
53
- - application/json
54
- Authorization:
55
- - Basic hidden
56
- response:
57
- status:
58
- code: 200
59
- message:
60
- headers:
61
- server:
62
- - nginx/1.9.10
63
- date:
64
- - Wed, 29 Jun 2016 12:47:11 GMT
65
- content-type:
66
- - application/json
67
- content-length:
68
- - '24'
69
- connection:
70
- - close
71
- status:
72
- - 200 OK
73
- access-control-allow-credentials:
74
- - 'true'
75
- body:
76
- encoding: UTF-8
77
- string: '{"tags":["another-tag"]}'
78
- http_version:
79
- recorded_at: Wed, 29 Jun 2016 12:47:11 GMT
80
- recorded_with: VCR 3.0.3
@@ -1,45 +0,0 @@
1
- ---
2
- http_interactions:
3
- - request:
4
- method: get
5
- uri: https://api.chartmogul.com/v1/customers?per_page=10
6
- body:
7
- encoding: US-ASCII
8
- string: ''
9
- headers:
10
- User-Agent:
11
- - Faraday v0.9.2
12
- Content-Type:
13
- - application/json
14
- Authorization:
15
- - Basic hidden
16
- response:
17
- status:
18
- code: 200
19
- message:
20
- headers:
21
- server:
22
- - nginx/1.9.10
23
- date:
24
- - Wed, 29 Jun 2016 12:45:27 GMT
25
- content-type:
26
- - application/json
27
- content-length:
28
- - '1297'
29
- connection:
30
- - close
31
- vary:
32
- - Accept-Encoding
33
- status:
34
- - 200 OK
35
- access-control-allow-credentials:
36
- - 'true'
37
- body:
38
- encoding: UTF-8
39
- string: '{"entries":[{"id":20286023,"uuid":"cus_db011fbe-b8d5-46d4-9949-dff12fe0744b","external_id":"cus_0001","name":"Zuora
40
- Customer","email":"zuora@customer.com","status":"Active","customer-since":"2015-08-01T00:00:00+00:00","attributes":{"tags":["another-tag"],"custom":{"String_key":"String
41
- Value","integer_key":1234,"timestamp_key":"2016-01-31T00:00:00.000Z","boolean_key":true}},"address":{"country":"United
42
- States","state":null,"city":"San Francisco","address_line1":null,"address_line2":null,"address_zip":""},"mrr":7500,"arr":90000,"billing-system-url":null,"chartmogul-url":"https://app.chartmogul.com/#customers/20286023-Zuora_Customer","billing-system-type":"ImportApi","currency":"USD","currency-sign":"$"}],"has_more":false,"per_page":10,"page":1}'
43
- http_version:
44
- recorded_at: Wed, 29 Jun 2016 12:45:27 GMT
45
- recorded_with: VCR 3.0.3
@@ -1,47 +0,0 @@
1
- ---
2
- http_interactions:
3
- - request:
4
- method: get
5
- uri: https://api.chartmogul.com/v1/customers?per_page=10
6
- body:
7
- encoding: US-ASCII
8
- string: ''
9
- headers:
10
- User-Agent:
11
- - Faraday v0.9.2
12
- Content-Type:
13
- - application/json
14
- Authorization:
15
- - Basic hidden
16
- response:
17
- status:
18
- code: 200
19
- message:
20
- headers:
21
- server:
22
- - nginx/1.9.10
23
- date:
24
- - Wed, 29 Jun 2016 12:45:27 GMT
25
- content-type:
26
- - application/json
27
- content-length:
28
- - '1297'
29
- connection:
30
- - close
31
- vary:
32
- - Accept-Encoding
33
- status:
34
- - 200 OK
35
- access-control-allow-credentials:
36
- - 'true'
37
- body:
38
- encoding: UTF-8
39
- string: '{"entries":[{"id":20286023,"uuid":"cus_db011fbe-b8d5-46d4-9949-dff12fe0744b","external_id":"cus_0001","name":"Zuora
40
- Customer","email":"zuora@customer.com","status":"Active","customer-since":"2015-08-01T00:00:00+00:00","attributes":{"tags":["another-tag"],"custom":{"string_key":"String
41
- Value","integer_key":1234,"timestamp_key":"2016-01-31T00:00:00.000Z","boolean_key":true}},"address":{"country":"United
42
- States","state":null,"city":"San Francisco","address_line1":null,"address_line2":null,"address_zip":""},"mrr":7500,"arr":90000,"billing-system-url":null,"chartmogul-url":"https://app.chartmogul.com/#customers/20286023-Zuora_Customer","billing-system-type":"ImportApi","currency":"USD","currency-sign":"$"},{"id":20268060,"uuid":"cus_07393ece-aab1-4255-8bcd-0ef11e24b047","external_id":"cus_0001","name":"Adam
43
- Smith","email":"adam@smith.com","status":"Cancelled","customer-since":"2016-05-01T12:00:00+00:00","attributes":{"tags":[]},"address":{"country":"United
44
- States","state":null,"city":"New York","address_line1":null,"address_line2":null,"address_zip":""},"mrr":0,"arr":0,"billing-system-url":null,"chartmogul-url":"https://app.chartmogul.com/#customers/20268060-Adam_Smith","billing-system-type":"ImportApi","currency":"USD","currency-sign":"$"}],"has_more":false,"per_page":10,"page":1}'
45
- http_version:
46
- recorded_at: Wed, 29 Jun 2016 12:45:27 GMT
47
- recorded_with: VCR 3.0.3
@@ -1,42 +0,0 @@
1
- ---
2
- http_interactions:
3
- - request:
4
- method: get
5
- uri: https://api.chartmogul.com/v1/customers/cus_07393ece-aab1-4255-8bcd-0ef11e24b047
6
- body:
7
- encoding: UTF-8
8
- string: '{}'
9
- headers:
10
- User-Agent:
11
- - Faraday v0.9.2
12
- Content-Type:
13
- - application/json
14
- Authorization:
15
- - Basic hidden
16
- response:
17
- status:
18
- code: 200
19
- message:
20
- headers:
21
- server:
22
- - nginx/1.9.10
23
- date:
24
- - Wed, 29 Jun 2016 12:47:08 GMT
25
- content-type:
26
- - application/json
27
- content-length:
28
- - '544'
29
- connection:
30
- - close
31
- status:
32
- - 200 OK
33
- access-control-allow-credentials:
34
- - 'true'
35
- body:
36
- encoding: UTF-8
37
- string: '{"id":20268060,"uuid":"cus_07393ece-aab1-4255-8bcd-0ef11e24b047","external_id":"cus_0001","name":"Adam
38
- Smith","email":"adam@smith.com","status":"Cancelled","customer-since":"2016-05-01T12:00:00+00:00","attributes":{"tags":[]},"address":{"country":"United
39
- States","state":null,"city":"New York","address_line1":null,"address_line2":null,"address_zip":""},"mrr":0,"arr":0,"billing-system-url":null,"chartmogul-url":"https://app.chartmogul.com/#customers/20268060-Adam_Smith","billing-system-type":"ImportApi","currency":"USD","currency-sign":"$"}'
40
- http_version:
41
- recorded_at: Wed, 29 Jun 2016 12:47:08 GMT
42
- recorded_with: VCR 3.0.3