songstats-ruby-sdk 0.2.0 → 0.2.2

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: 68f9bea062fc60a216913e84f5baee27b28f18711eb83c6b9e705a81ffe68a9b
4
- data.tar.gz: 5b3dcd8661f8555c6315d0e304aad2069faf645d88d06389ae4ee3be52598211
3
+ metadata.gz: 678efe691b09dd1b199a958941452a11a379c35b5ec2d513770cbb7b4dfd4916
4
+ data.tar.gz: 7a61b9da530280690cc0331313279265a3ee7ef14df25e7c99c175b5532057ed
5
5
  SHA512:
6
- metadata.gz: f419d4f531a1ebc3d11149e946636c0561f039fac22e96b972f0f296fd34a6f43aa1cb7fa64e8aca374d9cda935b57484a2123f34232374b58e77465d3989148
7
- data.tar.gz: 232391634c9586fdb9ea2d09501f27e9e44c6f4c9842b4d42ca5164ec7cc4a011e5325b44e8b6370cd133c575f137ad10c1b0fbe038191275df0e117ac18cd70
6
+ metadata.gz: 872e844983aea4a1f363044092a89e0aab944ba775d0fa312436e99311da158df01120bf1b1a261a9034b9959a1dcd847f050c8b77954714295098ea35e726d0
7
+ data.tar.gz: 773a5510f81f2084444b7a66882bedcf71d826c84a6945f1227f91d91e0a8e64f83ab01a61758ea133bc8daf4b91df14f3cf3d982dff8f381ca08f3081fbebc4
data/CHANGELOG.md CHANGED
@@ -2,16 +2,28 @@
2
2
 
3
3
  All notable changes to this project are documented in this file.
4
4
 
5
+ ## [0.2.2] - 2026-09-08
6
+
7
+ ### Changed
8
+
9
+ - Updated API documentation links to `developers.stats.company/songstats`.
10
+
11
+ ### Fixed
12
+
13
+ - Fixed standalone Ruby usage failing during parameter normalization without ActiveSupport loaded.
14
+
15
+ ## [0.2.1] - 2026-06-14
16
+
17
+ ### Changed
18
+
19
+ - Updated the default Enterprise API host from `data.songstats.com` to `api.songstats.com`.
20
+
5
21
  ## [0.2.0] - 2026-02-19
6
22
 
7
23
  ### Changed
8
24
 
9
25
  - Removed `charts` resource client from the SDK surface
10
26
  - Removed `stations` resource client from the SDK surface
11
- - Kept `info` endpoints:
12
- - `client.info.sources` (`/sources`)
13
- - `client.info.status` (`/status`)
14
- - `client.info.definitions` (`/definitions`)
15
27
 
16
28
  ## [0.1.0] - 2026-02-19
17
29
 
data/README.md CHANGED
@@ -3,7 +3,8 @@
3
3
  Official Ruby client for the **Songstats Enterprise API**.
4
4
 
5
5
  📦 RubyGems: https://rubygems.org/gems/songstats-ruby-sdk
6
- 📚 API Documentation: https://docs.songstats.com
6
+ 📚 API Documentation: https://developers.stats.company/songstats<br>
7
+ 🔑 API Key Access: Please contact api@songstats.com
7
8
 
8
9
  ---
9
10
 
@@ -15,7 +15,7 @@ module SongstatsSDK
15
15
  }.freeze
16
16
 
17
17
  def request(method:, base_url:, path:, headers:, params:, json:, timeout:)
18
- uri = URI.join("#{base_url.chomp('/')}/", path.sub(%r{\A/}, ""))
18
+ uri = URI.join("#{base_url.chomp('/')}/", path.delete_prefix('/'))
19
19
  query = URI.encode_www_form(params || {})
20
20
  uri.query = [uri.query, query].compact.reject(&:empty?).join("&") unless query.empty?
21
21
 
@@ -39,7 +39,7 @@ module SongstatsSDK
39
39
  end
40
40
 
41
41
  class HTTPClient
42
- DEFAULT_BASE_URL = "https://data.songstats.com"
42
+ DEFAULT_BASE_URL = "https://api.songstats.com"
43
43
  DEFAULT_TIMEOUT_SECONDS = 30
44
44
  RETRYABLE_STATUS_CODES = [429, 500, 502, 503, 504].freeze
45
45
  RETRYABLE_EXCEPTIONS = [
@@ -72,7 +72,7 @@ module SongstatsSDK
72
72
  end
73
73
 
74
74
  def request(method, path, params: nil, json: nil)
75
- endpoint = "/enterprise/v1/#{path.to_s.sub(%r{\A/}, "")}"
75
+ endpoint = "/enterprise/v1/#{path.to_s.delete_prefix('/')}"
76
76
  attempts = 0
77
77
 
78
78
  loop do
@@ -22,7 +22,7 @@ module SongstatsSDK
22
22
  end
23
23
 
24
24
  def normalize_params(params)
25
- return nil if params.nil? || params.empty?
25
+ return nil if params.nil? || params.empty? # rubocop:disable Rails/Blank -- This SDK does not depend on ActiveSupport.
26
26
 
27
27
  normalized = {}
28
28
  params.each do |key, value|
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module SongstatsSDK
4
- VERSION = "0.2.0"
4
+ VERSION = "0.2.2"
5
5
  end
metadata CHANGED
@@ -1,14 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: songstats-ruby-sdk
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Songstats
8
- autorequire:
9
8
  bindir: bin
10
9
  cert_chain: []
11
- date: 2026-02-19 00:00:00.000000000 Z
10
+ date: 1980-01-02 00:00:00.000000000 Z
12
11
  dependencies: []
13
12
  description: Typed Ruby client for Songstats Enterprise API resources.
14
13
  email:
@@ -39,7 +38,7 @@ metadata:
39
38
  source_code_uri: https://github.com/songstats/songstats-ruby-sdk
40
39
  bug_tracker_uri: https://github.com/songstats/songstats-ruby-sdk/issues
41
40
  allowed_push_host: https://rubygems.org
42
- post_install_message:
41
+ rubygems_mfa_required: 'true'
43
42
  rdoc_options: []
44
43
  require_paths:
45
44
  - lib
@@ -47,15 +46,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
47
46
  requirements:
48
47
  - - ">="
49
48
  - !ruby/object:Gem::Version
50
- version: 3.0.0
49
+ version: 3.2.0
51
50
  required_rubygems_version: !ruby/object:Gem::Requirement
52
51
  requirements:
53
52
  - - ">="
54
53
  - !ruby/object:Gem::Version
55
54
  version: '0'
56
55
  requirements: []
57
- rubygems_version: 3.5.17
58
- signing_key:
56
+ rubygems_version: 4.0.16
59
57
  specification_version: 4
60
58
  summary: Ruby SDK for the Songstats Enterprise API.
61
59
  test_files: []