chartmogul-ruby 4.6.0 → 4.7.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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 57622c3436470549ee626a80890f7e4c653b9fc8442d0bcc8ef0924e3c04024d
4
- data.tar.gz: 3e8eed3926ee08f02f550af2d2fc1d11723fa62a8746c99a3d8cea96c6787331
3
+ metadata.gz: 412ac47a1b6aa99718ae0d49b5637ca3440d002fc3df7b65a559de92ee9855cc
4
+ data.tar.gz: be62073fffa5ab0fb374df1305fc9eeac218d489e6f664cd76bb452b95f85e94
5
5
  SHA512:
6
- metadata.gz: 3e14cdf4980d1ad01eae66cf60a38daa7e114255e7d36bdd66280eb8bf7e2b9d39fc2222e96614db3bd48f68ff5429bf6b1432f9307b4727587431976741bdc6
7
- data.tar.gz: a020f1c354000a5629471cf7da8e10ed8a26720c71f2af6319a8ca42b8fa36d3663fc22f206bf9b85ba1951c38f892d77043062665c49da9667619d9ba7bf813
6
+ metadata.gz: 1f48e0c1e88f9a0a33ffcc4d496c6127845f6e995967444e5dfaeedeab2f48a76480e063592eb90128f4adfc6b97846021dcacc1aea9932461d7fb759ccd76d6
7
+ data.tar.gz: 5898d26b2120e9506451238a97d565aa1093664db3352b9374f802b406f5c0034cdf5e4fb66fbf98313a38a6d6cfd1f81e991654addcd120d8195ab446473b0f
data/changelog.md CHANGED
@@ -1,5 +1,8 @@
1
1
  # chartmogul-ruby Change Log
2
2
 
3
+ ## Version 4.7.0 - April 25, 2025
4
+ - Adds support for Tasks (https://dev.chartmogul.com/reference/tasks)
5
+
3
6
  ## Version 4.6.0 - March 14, 2025
4
7
  - Adds support for disconnecting subscriptions
5
8
  - Adds support for `transaction_fees_in_cents` attribute on transactions
@@ -113,6 +113,14 @@ module ChartMogul
113
113
  Opportunity.create!(options.merge(customer_uuid: uuid))
114
114
  end
115
115
 
116
+ def tasks(options = {})
117
+ Tasks.all(options.merge(customer_uuid: uuid))
118
+ end
119
+
120
+ def create_task(options = {})
121
+ Task.create!(options.merge(customer_uuid: uuid))
122
+ end
123
+
116
124
  # Enrichment
117
125
  def tags
118
126
  @attributes[:tags]
@@ -0,0 +1,39 @@
1
+ # frozen_string_literal: true
2
+
3
+ require 'forwardable'
4
+
5
+ module ChartMogul
6
+ class Task < APIResource
7
+ set_resource_name 'Task'
8
+ set_resource_path '/v1/tasks'
9
+
10
+ readonly_attr :customer_uuid
11
+ readonly_attr :task_uuid
12
+ readonly_attr :created_at
13
+ readonly_attr :updated_at
14
+
15
+ writeable_attr :task_details
16
+ writeable_attr :assignee
17
+ writeable_attr :due_date
18
+ writeable_attr :completed_at
19
+
20
+ include API::Actions::Create
21
+ include API::Actions::Destroy
22
+ include API::Actions::Retrieve
23
+ include API::Actions::Update
24
+
25
+ def self.all(options = {})
26
+ Tasks.all(options)
27
+ end
28
+ end
29
+
30
+ class Tasks < APIResource
31
+ set_resource_name 'Tasks'
32
+ set_resource_path '/v1/tasks'
33
+
34
+ include Concerns::Entries
35
+ include Concerns::PageableWithCursor
36
+
37
+ set_entry_class Task
38
+ end
39
+ end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module ChartMogul
4
- VERSION = '4.6.0'
4
+ VERSION = '4.7.0'
5
5
  end
data/lib/chartmogul.rb CHANGED
@@ -65,6 +65,7 @@ require 'chartmogul/plan_groups/plans'
65
65
  require 'chartmogul/account'
66
66
  require 'chartmogul/subscription_event'
67
67
  require 'chartmogul/opportunity'
68
+ require 'chartmogul/task'
68
69
 
69
70
  require 'chartmogul/metrics/arpa'
70
71
  require 'chartmogul/metrics/arr'
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: chartmogul-ruby
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.6.0
4
+ version: 4.7.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Petr Kopac
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2025-03-17 00:00:00.000000000 Z
11
+ date: 2025-04-28 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday
@@ -260,6 +260,7 @@ files:
260
260
  - lib/chartmogul/subscription_event.rb
261
261
  - lib/chartmogul/summary.rb
262
262
  - lib/chartmogul/summary_all.rb
263
+ - lib/chartmogul/task.rb
263
264
  - lib/chartmogul/transactions/payment.rb
264
265
  - lib/chartmogul/transactions/refund.rb
265
266
  - lib/chartmogul/utils/hash_snake_caser.rb
@@ -290,7 +291,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
290
291
  - !ruby/object:Gem::Version
291
292
  version: '0'
292
293
  requirements: []
293
- rubygems_version: 3.2.3
294
+ rubygems_version: 3.5.15
294
295
  signing_key:
295
296
  specification_version: 4
296
297
  summary: Chartmogul API Ruby Client