nzbn-ruby 0.1.5 → 0.1.6
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 +4 -4
- data/CHANGELOG.md +5 -0
- data/lib/nzbn/client.rb +2 -3
- data/lib/nzbn/version.rb +1 -1
- metadata +1 -2
- data/nzbn-ruby.gemspec +0 -36
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 6d534a41f82db0a2b137a0cd850749fdfc1c85ecc090cd226d2268997ec75a8d
|
|
4
|
+
data.tar.gz: a290d6cd3347116b5b4d20180ff16834dbe250b0a48ee8058b3261be1fa6cc32
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 9b28cc5915381c31ce1cdf5fecee02212f3d0a8d923d58fe42c28d9eeb371c31b113dbb632cc20a0bf8b566a9cbc7ec6e72249051b5b69bc449e1e7f67817e36
|
|
7
|
+
data.tar.gz: 3b8b72ef58086b594c65a90faecd474e1ba872be9592d1ca975ef6fa213e1d639ee7a5d3f43c7a4f17566aef306cf3323d1134d47b0dd113611d653da544ae2e
|
data/CHANGELOG.md
CHANGED
|
@@ -5,6 +5,11 @@ All notable changes to this project will be documented in this file.
|
|
|
5
5
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
|
6
6
|
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
7
|
|
|
8
|
+
## [0.1.6] - 2026-03-13
|
|
9
|
+
|
|
10
|
+
### Fixed
|
|
11
|
+
- Fixed URL path construction in `Client#request` to correctly parse base path from `base_url` and prepend it to request paths, preventing duplicate or missing path segments with Faraday
|
|
12
|
+
|
|
8
13
|
## [0.1.5] - 2026-03-13
|
|
9
14
|
|
|
10
15
|
### Added
|
data/lib/nzbn/client.rb
CHANGED
|
@@ -119,13 +119,12 @@ module Nzbn
|
|
|
119
119
|
def request(method, path, data, headers)
|
|
120
120
|
request_id = SecureRandom.uuid
|
|
121
121
|
full_url = "#{configuration.base_url}#{path}"
|
|
122
|
-
|
|
123
122
|
log_request(method, full_url, request_id, data)
|
|
124
|
-
|
|
125
123
|
merged_headers = default_headers(request_id).merge(headers)
|
|
124
|
+
base_path = URI.parse(configuration.base_url).path
|
|
126
125
|
|
|
127
126
|
response = connection.public_send(method) do |req|
|
|
128
|
-
req.url path
|
|
127
|
+
req.url "#{base_path}#{path}"
|
|
129
128
|
req.headers = merged_headers
|
|
130
129
|
|
|
131
130
|
case method
|
data/lib/nzbn/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: nzbn-ruby
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.1.
|
|
4
|
+
version: 0.1.6
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Nhan Nguyen
|
|
@@ -141,7 +141,6 @@ files:
|
|
|
141
141
|
- lib/nzbn/models/watchlist.rb
|
|
142
142
|
- lib/nzbn/models/website.rb
|
|
143
143
|
- lib/nzbn/version.rb
|
|
144
|
-
- nzbn-ruby.gemspec
|
|
145
144
|
homepage: https://github.com/nnhansg/nzbn-ruby
|
|
146
145
|
licenses:
|
|
147
146
|
- MIT
|
data/nzbn-ruby.gemspec
DELETED
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
# frozen_string_literal: true
|
|
2
|
-
|
|
3
|
-
require_relative 'lib/nzbn/version'
|
|
4
|
-
|
|
5
|
-
Gem::Specification.new do |spec|
|
|
6
|
-
spec.name = 'nzbn-ruby'
|
|
7
|
-
spec.version = Nzbn::VERSION
|
|
8
|
-
spec.authors = ['Nhan Nguyen']
|
|
9
|
-
spec.email = ['nnhansg@gmail.com']
|
|
10
|
-
|
|
11
|
-
spec.summary = 'Ruby client for the New Zealand Business Number (NZBN) API'
|
|
12
|
-
spec.description = 'A Ruby gem for interacting with the NZBN API v5. Search entities, manage watchlists, and access NZ business data.'
|
|
13
|
-
spec.homepage = 'https://github.com/nnhansg/nzbn-ruby'
|
|
14
|
-
spec.license = 'MIT'
|
|
15
|
-
|
|
16
|
-
spec.metadata['homepage_uri'] = spec.homepage
|
|
17
|
-
spec.metadata['source_code_uri'] = spec.homepage
|
|
18
|
-
spec.metadata['changelog_uri'] = "#{spec.homepage}/blob/main/CHANGELOG.md"
|
|
19
|
-
|
|
20
|
-
spec.files = Dir.chdir(__dir__) do
|
|
21
|
-
`git ls-files -z`.split("\x0").reject do |f|
|
|
22
|
-
(f == __FILE__) || f.match(%r{\A(?:(?:bin|test|spec|features)/|\.(?:git|travis|circleci)|appveyor)})
|
|
23
|
-
end
|
|
24
|
-
end
|
|
25
|
-
|
|
26
|
-
spec.files += Dir['lib/**/*.rb']
|
|
27
|
-
spec.require_paths = ['lib']
|
|
28
|
-
|
|
29
|
-
spec.add_dependency 'faraday', '~> 1.0'
|
|
30
|
-
spec.add_dependency 'json', '~> 2.1'
|
|
31
|
-
|
|
32
|
-
spec.add_development_dependency 'bundler', '>= 1.0'
|
|
33
|
-
spec.add_development_dependency 'rake', '~> 13.0'
|
|
34
|
-
spec.add_development_dependency 'rspec', '~> 3.0'
|
|
35
|
-
spec.add_development_dependency 'webmock', '~> 3.0'
|
|
36
|
-
end
|