novu 1.0.0 → 1.1.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: 3579a3791831450fecdf80f372bbae150bc2170738786009087bed40da0173a2
4
- data.tar.gz: 6a6b9250d0ecc25ec3445408972564e6b9c25736bdf45e173c3159d500244c5e
3
+ metadata.gz: 8098df85728b855aa460c4d47d3348b62b3069d92f4d8efa90e25ab6d14751c8
4
+ data.tar.gz: 474eb3049b5644e82c3c8e9181bcc36ba1a9439991a9be0ee41d4eb4f5fa832d
5
5
  SHA512:
6
- metadata.gz: 8025a85e201b29fd21903c8ca6ca6c952e32a17ac5f07a696e8f80a5a652c0d9da0026ea2b40885c48ba9c53bfbc92c402487d2b14deeaff0d42546baeaaef7c
7
- data.tar.gz: e432287331101e7f04abb8ebb094a78f469a244f6e9ae1ea3c6935c5e6000ec10595822c2d8dbc6efa473d969acbb31cf714e6d43469adf5b4702e5180ee092e
6
+ metadata.gz: ee43d0f49189f0a8c0ee99bf2c2d61e7105966d431f8c1131984a59f7301524727fa872d5be74acec538f28bf0f5feee2d94b1fa654c8a6b386b941a33a7e1e5
7
+ data.tar.gz: cad2d1570af4855e753b13748c65067bab400c0f13c90aecdadcfe5bfb9bda3ff722883dc5cab5d0111577eb2486c5e757d0d4d67c52a054caf69d1ef08ae03e
data/Gemfile CHANGED
@@ -12,6 +12,9 @@ group :test do
12
12
  gem "webmock"
13
13
  end
14
14
 
15
+ gem "exponential-backoff"
16
+ gem 'mocha'
15
17
  gem "rubocop", "~> 1.21"
18
+ gem 'uuid', '~> 2.3', '>= 2.3.9'
16
19
 
17
20
  # gem 'pry-debugger-jruby'
data/README.md CHANGED
@@ -37,7 +37,7 @@ To use the library, first initialize the client with your API token:
37
37
  ```ruby
38
38
  require 'novu'
39
39
 
40
- client = Novu::Client.new('YOUR_NOVU_API_TOKEN')
40
+ client = Novu::Client.new(access_token: 'YOUR_NOVU_API_TOKEN')
41
41
  ```
42
42
 
43
43
  You can then call methods on the client to interact with the Novu API:
@@ -549,6 +549,61 @@ client.notifications_graph_stats({
549
549
  client.notification('<insert-notification-id>')
550
550
  ```
551
551
 
552
+ ### Organizations
553
+
554
+ - Create an organization: `create_organization(body)`
555
+
556
+ ```ruby
557
+ client.create_organization({
558
+ 'logo' => '<insert-organization-logo>',
559
+ 'name' => '<insert-organization-name>',
560
+ })
561
+ ```
562
+
563
+ - Get all organizations: `organizations()`
564
+
565
+ ```ruby
566
+ client.organizations()
567
+ ```
568
+
569
+ - Get current organization: `current_organization()`
570
+
571
+ ```ruby
572
+ client.current_organization()
573
+ ```
574
+
575
+ - Get all members of current organization: `current_organization_members()`
576
+
577
+ ```ruby
578
+ client.current_organization_members()
579
+ ```
580
+
581
+ - Rename organization: `rename_organization(body)`
582
+
583
+ ```ruby
584
+ client.rename_organization({
585
+ name: '<insert-organization-name>'
586
+ })
587
+ ```
588
+
589
+ - Rename organization: `organization_branding(body)`
590
+
591
+ ```ruby
592
+ client.organization_branding({
593
+ logo: '<insert-organization-logo>',
594
+ color: '<insert-organization-color>',
595
+ fontColor: '<insert-organization-fontColor>',
596
+ contentBackground: '<insert-organization-contentBackground>',
597
+ fontFamily: '<insert-organization-fontFamily>'
598
+ })
599
+ ```
600
+
601
+ - Delete member from organization: `delete_organization_member(member_id)`
602
+
603
+ ```ruby
604
+ client.delete_organization_member('<insert-member-id>')
605
+ ```
606
+
552
607
  ### Subscribers
553
608
 
554
609
  - Get subscribers: `subscribers(query = {}) `
@@ -841,8 +896,55 @@ client.delete_topic('<insert-topic-key>')
841
896
  client.subscriber_topic('<insert-topic-key>', '<insert-externalSubscriberId>')
842
897
  ```
843
898
 
899
+ ### Idempotent Request
900
+
901
+ This SDK allows you to perform idempotent requests, that is safely retrying requests without accidentally performing the same operation twice.
902
+ To achieve this, provide an `idempotency_key` argument during initialization of the NOVU client. We strongly recommend that you use [UUID](https://datatracker.ietf.org/doc/html/rfc4122) format when you're generating your idempotency key.
903
+
904
+ ```ruby
905
+ client = Novu::Client.new(
906
+ access_token: '<your-novu-api_key>',
907
+ idempotency_key: '<your-idempotency-key>'
908
+ )
909
+ ```
910
+
911
+ ### Exponential Retry Mechanism
912
+
913
+ You can configure this SDK to retry failed requests. This is done by using [Exponential backoff strategy](https://en.wikipedia.org/wiki/Exponential_backoff). It is a common algorithm for retrying requests. The retries gradually extend the waiting time until reaching a specific limit. The concept is to prevent overloading the server with simultaneous requests once it is back online, especially in cases of temporary downtime.
914
+
915
+ ```ruby
916
+ client = Novu::Client.new(
917
+ access_token: '<your-novu-api_key>',
918
+ idempotency_key: '<your-idempotency-key>',
919
+ enable_retry: true, # it is disabled by default,
920
+ retry_config: {
921
+ max_retries: 3,
922
+ initial_delay: 4,
923
+ max_delay: 60
924
+ }
925
+ )
926
+ ```
927
+
928
+ ## The retry configuration is explained in the following table:
929
+ | Options | Detail | Default Value | Data Type |
930
+ | ------------- | -------------------------------------------------------------------| --------------- | --------- |
931
+ | max_retries | Specifies total number of retries to perform in case of failure | 1 | Integer |
932
+ | initial_delay | Specifies the minimum time to wait before retrying (in seconds) | 4 | Integer |
933
+ | max_delay | Specifies the maximum time to wait before retrying (in seconds) | 60 | Integer |
934
+ | enable_retry | enabling/disable the Exponential Retry mechanism | false | Boolean |
935
+
936
+
844
937
  ### For more information about these methods and their parameters, see the [API documentation](https://docs.novu.co/api-reference).
845
938
 
846
939
  ## Contributing
847
940
 
848
- Bug reports and pull requests are welcome on GitHub at https://github.com/novuhq/novu-ruby
941
+ Bug reports and pull requests are welcome [here.](https://github.com/novuhq/novu-ruby)
942
+
943
+ ## Support and Feedback
944
+
945
+ Be sure to visit the Novu official [documentation website](https://docs.novu.co/docs) for additional information about our API.
946
+ If you need additional assistance, join our Discord server [here](https://discord.novu.co).
947
+
948
+ ## License
949
+
950
+ Novu Ruby SDK is licensed under the MIT License - see the [LICENSE](https://github.com/novuhq/novu-ruby/blob/main/LICENSE.txt) file for details.
@@ -3,6 +3,7 @@
3
3
  module Novu
4
4
  class Api
5
5
  module Connection
6
+
6
7
  def get(path, options = {})
7
8
  request :get, path, options
8
9
  end
@@ -25,8 +26,36 @@ module Novu
25
26
 
26
27
  private
27
28
 
29
+ # Send API Request
30
+ #
31
+ # It applies exponential backoff strategy (if enabled) for failed requests.
32
+ # It also performs an idempotent request to safely retry requests without having duplication operations.
33
+ #
28
34
  def request(http_method, path, options)
35
+
36
+ if http_method.to_s == 'post' || http_method.to_s == 'patch'
37
+ self.class.default_options[:headers].merge!({ "Idempotency-Key" => "#{@idempotency_key.to_s.strip}" })
38
+ end
39
+
29
40
  response = self.class.send(http_method, path, options)
41
+
42
+ if ! [401, 403, 409, 500, 502, 503, 504].include?(response.code) && ! @enable_retry
43
+ response
44
+ elsif @enable_retry
45
+
46
+ if @retry_attempts < @max_retries
47
+ @retry_attempts += 1
48
+
49
+ @backoff.intervals.each do |interval|
50
+ sleep(interval)
51
+ request(http_method, path, options)
52
+ end
53
+ else
54
+ raise StandardError, "Max retry attempts reached"
55
+ end
56
+ else
57
+ response
58
+ end
30
59
  end
31
60
  end
32
61
  end
@@ -0,0 +1,81 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Novu
4
+ class Api
5
+ # Module Novu::Api::Organizations provides an API for managing Organization within your Novu account.
6
+ #
7
+ # This module includes methods for creating, retrieving, updating and deleting organization.
8
+ #
9
+ # For more information on the Novu API see https://api.novu.co/api#/Organizations, https://docs.novu.co/api-reference/organizations/create-organization.
10
+ module Organizations
11
+ # Create an organization
12
+ #
13
+ # @bodyparams:
14
+ # @param `logo` [String] - A valid image URL with one of the following extensions: jpg, jpeg, png, gif, svg.
15
+ # @param `name` [String] - A human-readable name of the organization.
16
+ #
17
+ # @return [Hash] data - The list of information with respect to the created organization.
18
+ # @return [number] status - The status code. Returns 200 if the organization has been successfully created.
19
+ def create_organization(body)
20
+ post("/organizations", body: body)
21
+ end
22
+
23
+ # Get all organizations
24
+ #
25
+ # @return [Hash] data - The list of organizations already created.
26
+ # @return [number] status - Returns 200 if successful
27
+ def organizations()
28
+ get("/organizations")
29
+ end
30
+
31
+ # Get details of the current organization
32
+ #
33
+ # @return [Hash] data - The details of the current organization.
34
+ # @return [number] status - Returns 200 if successful
35
+ def current_organization()
36
+ get("/organizations/me")
37
+ end
38
+
39
+ # Get all members of the current organization
40
+ #
41
+ # @return [Hash] data - The list of all members of the current organization.
42
+ # @return [number] status - Returns 200 if successful
43
+ def current_organization_members()
44
+ get("/organizations/members")
45
+ end
46
+
47
+ # Rename organization name
48
+ #
49
+ # @return [Hash] data - The list of updated details of the organization.
50
+ # @return [number] status - Returns 200 if successful
51
+ def rename_organization(body)
52
+ patch("/organizations", body: body)
53
+ end
54
+
55
+ # Update organization branding details
56
+ #
57
+ # @bodyparams:
58
+ # @param `logo` [String] - A valid image URL with one of the following extensions: jpg, jpeg, png, gif, svg.
59
+ # @param `color` [String] - The hexadecimal color style of the organization.
60
+ # @param `contentBackground` [String] - The hexadecimal content background style of the organization.
61
+ # @param `fontColor` [String] - The hexadecimal font color style of the organization.
62
+ # @param `fontFamily` [String(optional)] - The font family style of the organization.
63
+ #
64
+ # @return [Hash] data - The list of branding details of the organization.
65
+ # @return [number] status - Returns 200 if successful
66
+ def organization_branding(body)
67
+ put("/organizations/branding", body: body)
68
+ end
69
+
70
+ # Remove a member from organization
71
+ #
72
+ # @pathparams
73
+ # @param `member_id` [String]
74
+ #
75
+ # @return [number] status - The status code. Returns 200 if memeber was removed successfully by their id.
76
+ def delete_organization_member(member_id)
77
+ delete("/organizations/members/#{member_id}")
78
+ end
79
+ end
80
+ end
81
+ end
data/lib/novu/client.rb CHANGED
@@ -14,6 +14,7 @@ require "novu/api/messages"
14
14
  require "novu/api/notification_groups"
15
15
  require "novu/api/notification_templates"
16
16
  require "novu/api/notification"
17
+ require "novu/api/organizations"
17
18
  require "novu/api/subscribers"
18
19
  require "novu/api/tenants"
19
20
  require "novu/api/topics"
@@ -35,6 +36,7 @@ module Novu
35
36
  include Novu::Api::NotificationGroups
36
37
  include Novu::Api::NotificationTemplates
37
38
  include Novu::Api::Notification
39
+ include Novu::Api::Organizations
38
40
  include Novu::Api::Subscribers
39
41
  include Novu::Api::Tenants
40
42
  include Novu::Api::Topics
@@ -42,13 +44,48 @@ module Novu
42
44
  base_uri "https://api.novu.co/v1"
43
45
  format :json
44
46
 
45
- def initialize(access_token = nil)
47
+ attr_accessor :enable_retry, :max_retries, :initial_delay, :max_delay, :idempotency_key
48
+
49
+ # @param `access_token` [String]
50
+ # @param `idempotency_key` [String]
51
+ # @param `enable_retry` [Boolean]
52
+ # @param `retry_config` [Hash]
53
+ # - max_retries [Integer]
54
+ # - initial_delay [Integer]
55
+ # - max_delay [Integer]
56
+ def initialize(access_token: nil, idempotency_key: nil, enable_retry: false, retry_config: {} )
46
57
  raise ArgumentError, "Api Key cannot be blank or nil" if access_token.blank?
47
58
 
59
+ @idempotency_key = idempotency_key.blank? ? UUID.new.generate : idempotency_key
60
+
61
+ @enable_retry = enable_retry
48
62
  @access_token = access_token.to_s.strip
63
+ @retry_attempts = 0
64
+
65
+ retry_config = defaults_retry_config.merge(retry_config)
66
+ @max_retries = retry_config[:max_retries]
67
+ @initial_delay = retry_config[:initial_delay]
68
+ @max_delay = retry_config[:max_delay]
69
+
49
70
  self.class.default_options.merge!(headers: { "Authorization" => "ApiKey #{@access_token}" })
71
+
72
+ # Configure the exponential backoff - specifying initial and maximal delays, default is 4s and 60s respectively
73
+ if @enable_retry
74
+ @retry_config = retry_config
75
+ @backoff = ExponentialBackoff.new(@initial_delay, @max_delay)
76
+ end
50
77
  rescue ArgumentError => e
51
78
  puts "Error initializing Novu client: #{e.message}"
52
79
  end
80
+
81
+ private
82
+
83
+ # @retun [Hash]
84
+ # - max_retries [Integer]
85
+ # - initial_delay [Integer]
86
+ # - max_delay [Integer]
87
+ def defaults_retry_config
88
+ { max_retries: 1, initial_delay: 4, max_delay: 60 }
89
+ end
53
90
  end
54
91
  end
data/lib/novu/version.rb CHANGED
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Novu
4
- VERSION = "1.0.0"
4
+ VERSION = "1.1.0"
5
5
  end
data/lib/novu.rb CHANGED
@@ -1,9 +1,11 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  require "active_support/core_ext/hash"
4
+ require "exponential_backoff"
4
5
  require "httparty"
5
6
  require_relative "novu/version"
6
7
  require_relative "novu/client"
8
+ require "uuid"
7
9
 
8
10
  module Novu
9
11
  # class Error < StandardError; end
data/techstack.md ADDED
@@ -0,0 +1,125 @@
1
+ <!--
2
+ &lt;--- Readme.md Snippet without images Start ---&gt;
3
+ ## Tech Stack
4
+ novuhq/novu-ruby is built on the following main stack:
5
+
6
+ - [Ruby](https://www.ruby-lang.org) – Languages
7
+ - [RSpec](https://rspec.info/) – Testing Frameworks
8
+ - [RuboCop](http://batsov.com/rubocop/) – Code Review
9
+ - [Shell](https://en.wikipedia.org/wiki/Shell_script) – Shells
10
+ - [GitHub Actions](https://github.com/features/actions) – Continuous Integration
11
+
12
+ Full tech stack [here](/techstack.md)
13
+
14
+ &lt;--- Readme.md Snippet without images End ---&gt;
15
+
16
+ &lt;--- Readme.md Snippet with images Start ---&gt;
17
+ ## Tech Stack
18
+ novuhq/novu-ruby is built on the following main stack:
19
+
20
+ - <img width='25' height='25' src='https://img.stackshare.io/service/989/ruby.png' alt='Ruby'/> [Ruby](https://www.ruby-lang.org) – Languages
21
+ - <img width='25' height='25' src='https://img.stackshare.io/service/2539/logo.png' alt='RSpec'/> [RSpec](https://rspec.info/) – Testing Frameworks
22
+ - <img width='25' height='25' src='https://img.stackshare.io/service/2643/rubocop.png' alt='RuboCop'/> [RuboCop](http://batsov.com/rubocop/) – Code Review
23
+ - <img width='25' height='25' src='https://img.stackshare.io/service/4631/default_c2062d40130562bdc836c13dbca02d318205a962.png' alt='Shell'/> [Shell](https://en.wikipedia.org/wiki/Shell_script) – Shells
24
+ - <img width='25' height='25' src='https://img.stackshare.io/service/11563/actions.png' alt='GitHub Actions'/> [GitHub Actions](https://github.com/features/actions) – Continuous Integration
25
+
26
+ Full tech stack [here](/techstack.md)
27
+
28
+ &lt;--- Readme.md Snippet with images End ---&gt;
29
+ -->
30
+ <div align="center">
31
+
32
+ # Tech Stack File
33
+ ![](https://img.stackshare.io/repo.svg "repo") [novuhq/novu-ruby](https://github.com/novuhq/novu-ruby)![](https://img.stackshare.io/public_badge.svg "public")
34
+ <br/><br/>
35
+ |11<br/>Tools used|01/05/24 <br/>Report generated|
36
+ |------|------|
37
+ </div>
38
+
39
+ ## <img src='https://img.stackshare.io/languages.svg'/> Languages (1)
40
+ <table><tr>
41
+ <td align='center'>
42
+ <img width='36' height='36' src='https://img.stackshare.io/service/989/ruby.png' alt='Ruby'>
43
+ <br>
44
+ <sub><a href="https://www.ruby-lang.org">Ruby</a></sub>
45
+ <br>
46
+ <sub></sub>
47
+ </td>
48
+
49
+ </tr>
50
+ </table>
51
+
52
+ ## <img src='https://img.stackshare.io/devops.svg'/> DevOps (5)
53
+ <table><tr>
54
+ <td align='center'>
55
+ <img width='36' height='36' src='https://img.stackshare.io/service/1046/git.png' alt='Git'>
56
+ <br>
57
+ <sub><a href="http://git-scm.com/">Git</a></sub>
58
+ <br>
59
+ <sub></sub>
60
+ </td>
61
+
62
+ <td align='center'>
63
+ <img width='36' height='36' src='https://img.stackshare.io/service/11563/actions.png' alt='GitHub Actions'>
64
+ <br>
65
+ <sub><a href="https://github.com/features/actions">GitHub Actions</a></sub>
66
+ <br>
67
+ <sub></sub>
68
+ </td>
69
+
70
+ <td align='center'>
71
+ <img width='36' height='36' src='https://img.stackshare.io/service/2539/logo.png' alt='RSpec'>
72
+ <br>
73
+ <sub><a href="https://rspec.info/">RSpec</a></sub>
74
+ <br>
75
+ <sub>v3.12.0</sub>
76
+ </td>
77
+
78
+ <td align='center'>
79
+ <img width='36' height='36' src='https://img.stackshare.io/service/2643/rubocop.png' alt='RuboCop'>
80
+ <br>
81
+ <sub><a href="http://batsov.com/rubocop/">RuboCop</a></sub>
82
+ <br>
83
+ <sub>v1.46.0</sub>
84
+ </td>
85
+
86
+ <td align='center'>
87
+ <img width='36' height='36' src='https://img.stackshare.io/service/12795/5jL6-BA5_400x400.jpeg' alt='RubyGems'>
88
+ <br>
89
+ <sub><a href="https://rubygems.org/">RubyGems</a></sub>
90
+ <br>
91
+ <sub></sub>
92
+ </td>
93
+
94
+ </tr>
95
+ </table>
96
+
97
+ ## Other (1)
98
+ <table><tr>
99
+ <td align='center'>
100
+ <img width='36' height='36' src='https://img.stackshare.io/service/4631/default_c2062d40130562bdc836c13dbca02d318205a962.png' alt='Shell'>
101
+ <br>
102
+ <sub><a href="https://en.wikipedia.org/wiki/Shell_script">Shell</a></sub>
103
+ <br>
104
+ <sub></sub>
105
+ </td>
106
+
107
+ </tr>
108
+ </table>
109
+
110
+
111
+ ## <img src='https://img.stackshare.io/group.svg' /> Open source packages (4)</h2>
112
+
113
+ ## <img width='24' height='24' src='https://img.stackshare.io/service/12795/5jL6-BA5_400x400.jpeg'/> RubyGems (4)
114
+
115
+ |NAME|VERSION|LAST UPDATED|LAST UPDATED BY|LICENSE|VULNERABILITIES|
116
+ |:------|:------|:------|:------|:------|:------|
117
+ |[activesupport](https://rubygems.org/activesupport)|v6.1.7|10/12/23|unicodeveloper |MIT|N/A|
118
+ |[httparty](https://rubygems.org/httparty)|v0.21.0|10/12/23|unicodeveloper |MIT|N/A|
119
+ |[rake](https://rubygems.org/rake)|v13.0.6|02/28/23|Aman Saini |MIT|N/A|
120
+ |[webmock](https://rubygems.org/webmock)|v3.18.1|03/10/23|Aman Saini |MIT|N/A|
121
+
122
+ <br/>
123
+ <div align='center'>
124
+
125
+ Generated via [Stack File](https://github.com/marketplace/stack-file)
data/techstack.yml ADDED
@@ -0,0 +1,152 @@
1
+ repo_name: novuhq/novu-ruby
2
+ report_id: 64174126c2978ebffd866b5b5a64f248
3
+ version: 0.1
4
+ repo_type: Public
5
+ timestamp: '2024-01-05T09:22:44+00:00'
6
+ requested_by: sumitsaurabh927
7
+ provider: github
8
+ branch: main
9
+ detected_tools_count: 11
10
+ tools:
11
+ - name: Ruby
12
+ description: A dynamic, interpreted, open source programming language with a focus
13
+ on simplicity and productivity
14
+ website_url: https://www.ruby-lang.org
15
+ open_source: true
16
+ hosted_saas: false
17
+ category: Languages & Frameworks
18
+ sub_category: Languages
19
+ image_url: https://img.stackshare.io/service/989/ruby.png
20
+ detection_source_url: https://github.com/novuhq/novu-ruby
21
+ detection_source: Repo Metadata
22
+ - name: Git
23
+ description: Fast, scalable, distributed revision control system
24
+ website_url: http://git-scm.com/
25
+ open_source: true
26
+ hosted_saas: false
27
+ category: Build, Test, Deploy
28
+ sub_category: Version Control System
29
+ image_url: https://img.stackshare.io/service/1046/git.png
30
+ detection_source_url: https://github.com/novuhq/novu-ruby
31
+ detection_source: Repo Metadata
32
+ - name: GitHub Actions
33
+ description: Automate your workflow from idea to production
34
+ website_url: https://github.com/features/actions
35
+ open_source: false
36
+ hosted_saas: true
37
+ category: Build, Test, Deploy
38
+ sub_category: Continuous Integration
39
+ image_url: https://img.stackshare.io/service/11563/actions.png
40
+ detection_source_url: https://github.com/novuhq/novu-ruby/blob/main/.github/workflows/release.yml
41
+ detection_source: ".github/workflows/release.yml"
42
+ last_updated_by: Kolawole Ezekiel
43
+ last_updated_on: 2023-10-09 13:30:34.000000000 Z
44
+ - name: RSpec
45
+ description: Behaviour Driven Development for Ruby
46
+ website_url: https://rspec.info/
47
+ version: 3.12.0
48
+ license: MIT
49
+ open_source: true
50
+ hosted_saas: false
51
+ category: Build, Test, Deploy
52
+ sub_category: Testing Frameworks
53
+ image_url: https://img.stackshare.io/service/2539/logo.png
54
+ detection_source_url: https://github.com/novuhq/novu-ruby/blob/main/Gemfile.lock
55
+ detection_source: Gemfile
56
+ last_updated_by: Aman Saini
57
+ last_updated_on: 2023-02-28 06:58:36.000000000 Z
58
+ - name: RuboCop
59
+ description: A Ruby static code analyzer, based on the community Ruby style guide
60
+ website_url: http://batsov.com/rubocop/
61
+ version: 1.46.0
62
+ license: MIT
63
+ open_source: true
64
+ hosted_saas: false
65
+ category: Build, Test, Deploy
66
+ sub_category: Code Review
67
+ image_url: https://img.stackshare.io/service/2643/rubocop.png
68
+ detection_source_url: https://github.com/novuhq/novu-ruby/blob/main/Gemfile.lock
69
+ detection_source: Gemfile
70
+ last_updated_by: Aman Saini
71
+ last_updated_on: 2023-02-28 06:58:36.000000000 Z
72
+ - name: RubyGems
73
+ description: Easily download, install, and use ruby software packages on your system
74
+ website_url: https://rubygems.org/
75
+ open_source: false
76
+ hosted_saas: false
77
+ category: Build, Test, Deploy
78
+ sub_category: Package Managers
79
+ image_url: https://img.stackshare.io/service/12795/5jL6-BA5_400x400.jpeg
80
+ detection_source_url: https://github.com/novuhq/novu-ruby/blob/main/novu.gemspec
81
+ detection_source: novu.gemspec
82
+ last_updated_by: Aman Saini
83
+ last_updated_on: 2023-02-28 06:58:36.000000000 Z
84
+ - name: Shell
85
+ description: A shell is a text-based terminal, used for manipulating programs and
86
+ files. Shell scripts typically manage program execution.
87
+ website_url: https://en.wikipedia.org/wiki/Shell_script
88
+ open_source: false
89
+ hosted_saas: false
90
+ category: Languages & Frameworks
91
+ sub_category: Languages
92
+ image_url: https://img.stackshare.io/service/4631/default_c2062d40130562bdc836c13dbca02d318205a962.png
93
+ detection_source_url: https://github.com/novuhq/novu-ruby
94
+ detection_source: Repo Metadata
95
+ - name: activesupport
96
+ description: A toolkit of support libraries and Ruby core extensions extracted from
97
+ the Rails framework
98
+ package_url: https://rubygems.org/activesupport
99
+ version: 6.1.7
100
+ license: MIT
101
+ open_source: true
102
+ hosted_saas: false
103
+ category: Libraries
104
+ sub_category: RubyGems Packages
105
+ image_url: https://img.stackshare.io/package/18817/default_b17f14dbef6c1275120b34d9ec2eff5942499bd5.png
106
+ detection_source_url: https://github.com/novuhq/novu-ruby/blob/main/Gemfile.lock
107
+ detection_source: novu.gemspec
108
+ last_updated_by: unicodeveloper
109
+ last_updated_on: 2023-10-12 04:34:34.000000000 Z
110
+ - name: httparty
111
+ description: Makes http fun! Also
112
+ package_url: https://rubygems.org/httparty
113
+ version: 0.21.0
114
+ license: MIT
115
+ open_source: true
116
+ hosted_saas: false
117
+ category: Libraries
118
+ sub_category: RubyGems Packages
119
+ image_url: https://img.stackshare.io/package/18832/default_8c2fa81d8b8e48c679685199823ce30d598d3e87.png
120
+ detection_source_url: https://github.com/novuhq/novu-ruby/blob/main/Gemfile.lock
121
+ detection_source: novu.gemspec
122
+ last_updated_by: unicodeveloper
123
+ last_updated_on: 2023-10-12 04:34:34.000000000 Z
124
+ - name: rake
125
+ description: Rake is a Make-like program implemented in Ruby
126
+ package_url: https://rubygems.org/rake
127
+ version: 13.0.6
128
+ license: MIT
129
+ open_source: true
130
+ hosted_saas: false
131
+ category: Libraries
132
+ sub_category: RubyGems Packages
133
+ image_url: https://img.stackshare.io/package/18812/default_f582e4648f4682adb72d2b201218cda7f8e894ac.png
134
+ detection_source_url: https://github.com/novuhq/novu-ruby/blob/main/Gemfile.lock
135
+ detection_source: Gemfile
136
+ last_updated_by: Aman Saini
137
+ last_updated_on: 2023-02-28 06:58:36.000000000 Z
138
+ - name: webmock
139
+ description: WebMock allows stubbing HTTP requests and setting expectations on HTTP
140
+ requests
141
+ package_url: https://rubygems.org/webmock
142
+ version: 3.18.1
143
+ license: MIT
144
+ open_source: true
145
+ hosted_saas: false
146
+ category: Libraries
147
+ sub_category: RubyGems Packages
148
+ image_url: https://img.stackshare.io/package/18824/default_6564ae059af6c4ea7065fd2329370c7a05341cf8.png
149
+ detection_source_url: https://github.com/novuhq/novu-ruby/blob/main/Gemfile.lock
150
+ detection_source: Gemfile
151
+ last_updated_by: Aman Saini
152
+ last_updated_on: 2023-03-10 06:01:34.000000000 Z
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: novu
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Aman Saini
@@ -10,7 +10,7 @@ authors:
10
10
  autorequire:
11
11
  bindir: exe
12
12
  cert_chain: []
13
- date: 2023-10-12 00:00:00.000000000 Z
13
+ date: 2024-01-16 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  requirement: !ruby/object:Gem::Requirement
@@ -19,8 +19,8 @@ dependencies:
19
19
  - !ruby/object:Gem::Version
20
20
  version: '0.21'
21
21
  name: httparty
22
- prerelease: false
23
22
  type: :runtime
23
+ prerelease: false
24
24
  version_requirements: !ruby/object:Gem::Requirement
25
25
  requirements:
26
26
  - - "~>"
@@ -29,15 +29,15 @@ dependencies:
29
29
  - !ruby/object:Gem::Dependency
30
30
  requirement: !ruby/object:Gem::Requirement
31
31
  requirements:
32
- - - '='
32
+ - - ">="
33
33
  - !ruby/object:Gem::Version
34
34
  version: 6.1.7.2
35
35
  name: activesupport
36
- prerelease: false
37
36
  type: :runtime
37
+ prerelease: false
38
38
  version_requirements: !ruby/object:Gem::Requirement
39
39
  requirements:
40
- - - '='
40
+ - - ">="
41
41
  - !ruby/object:Gem::Version
42
42
  version: 6.1.7.2
43
43
  description: Client library for Novu API.
@@ -54,7 +54,6 @@ files:
54
54
  - CHANGELOG.md
55
55
  - CODE_OF_CONDUCT.md
56
56
  - Gemfile
57
- - Gemfile.lock
58
57
  - LICENSE.txt
59
58
  - README.md
60
59
  - Rakefile
@@ -73,12 +72,15 @@ files:
73
72
  - lib/novu/api/notification.rb
74
73
  - lib/novu/api/notification_groups.rb
75
74
  - lib/novu/api/notification_templates.rb
75
+ - lib/novu/api/organizations.rb
76
76
  - lib/novu/api/subscribers.rb
77
77
  - lib/novu/api/tenants.rb
78
78
  - lib/novu/api/topics.rb
79
79
  - lib/novu/client.rb
80
80
  - lib/novu/version.rb
81
81
  - sig/novu.rbs
82
+ - techstack.md
83
+ - techstack.yml
82
84
  homepage: https://github.com/novuhq/novu-ruby
83
85
  licenses:
84
86
  - MIT
data/Gemfile.lock DELETED
@@ -1,93 +0,0 @@
1
- PATH
2
- remote: .
3
- specs:
4
- novu (1.0.0)
5
- activesupport (= 6.1.7.2)
6
- httparty (~> 0.21)
7
-
8
- GEM
9
- remote: https://rubygems.org/
10
- specs:
11
- activesupport (6.1.7.2)
12
- concurrent-ruby (~> 1.0, >= 1.0.2)
13
- i18n (>= 1.6, < 2)
14
- minitest (>= 5.1)
15
- tzinfo (~> 2.0)
16
- zeitwerk (~> 2.3)
17
- addressable (2.8.1)
18
- public_suffix (>= 2.0.2, < 6.0)
19
- ast (2.4.2)
20
- concurrent-ruby (1.2.2)
21
- crack (0.4.5)
22
- rexml
23
- diff-lcs (1.5.0)
24
- hashdiff (1.0.1)
25
- httparty (0.21.0)
26
- mini_mime (>= 1.0.0)
27
- multi_xml (>= 0.5.2)
28
- i18n (1.12.0)
29
- concurrent-ruby (~> 1.0)
30
- json (2.6.3)
31
- json (2.6.3-java)
32
- mini_mime (1.1.2)
33
- minitest (5.17.0)
34
- multi_xml (0.6.0)
35
- parallel (1.22.1)
36
- parser (3.2.1.0)
37
- ast (~> 2.4.1)
38
- public_suffix (5.0.1)
39
- rainbow (3.1.1)
40
- rake (13.0.6)
41
- regexp_parser (2.7.0)
42
- rexml (3.2.5)
43
- rspec (3.12.0)
44
- rspec-core (~> 3.12.0)
45
- rspec-expectations (~> 3.12.0)
46
- rspec-mocks (~> 3.12.0)
47
- rspec-core (3.12.1)
48
- rspec-support (~> 3.12.0)
49
- rspec-expectations (3.12.2)
50
- diff-lcs (>= 1.2.0, < 2.0)
51
- rspec-support (~> 3.12.0)
52
- rspec-mocks (3.12.3)
53
- diff-lcs (>= 1.2.0, < 2.0)
54
- rspec-support (~> 3.12.0)
55
- rspec-support (3.12.0)
56
- rubocop (1.46.0)
57
- json (~> 2.3)
58
- parallel (~> 1.10)
59
- parser (>= 3.2.0.0)
60
- rainbow (>= 2.2.2, < 4.0)
61
- regexp_parser (>= 1.8, < 3.0)
62
- rexml (>= 3.2.5, < 4.0)
63
- rubocop-ast (>= 1.26.0, < 2.0)
64
- ruby-progressbar (~> 1.7)
65
- unicode-display_width (>= 2.4.0, < 3.0)
66
- rubocop-ast (1.27.0)
67
- parser (>= 3.2.1.0)
68
- ruby-progressbar (1.11.0)
69
- tzinfo (2.0.6)
70
- concurrent-ruby (~> 1.0)
71
- unicode-display_width (2.4.2)
72
- webmock (3.18.1)
73
- addressable (>= 2.8.0)
74
- crack (>= 0.3.2)
75
- hashdiff (>= 0.4.0, < 2.0.0)
76
- zeitwerk (2.6.7)
77
-
78
- PLATFORMS
79
- ruby
80
- universal-java-11
81
- universal-java-17
82
- x86_64-darwin-21
83
- x86_64-linux
84
-
85
- DEPENDENCIES
86
- novu!
87
- rake (~> 13.0)
88
- rspec
89
- rubocop (~> 1.21)
90
- webmock
91
-
92
- BUNDLED WITH
93
- 2.4.1