parseapi 0.1.0 → 0.2.1

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: db102dc0d021fa26f14dfdb337e38ead8d770d6a49b99d9b185ff4caf1c1cc17
4
- data.tar.gz: d78a937301d8084f9a3ddfb0004419931309448223dbbe98302effcef101ba8c
3
+ metadata.gz: e4c6ab4b71acb2d8fbfd29ee797b05b3c731be5bd57f00df8a3147fadc40b9aa
4
+ data.tar.gz: 176cf120dac886d1cfdfca1622ad6b0ffc575fc6730606bf43d6c0e9c4562561
5
5
  SHA512:
6
- metadata.gz: 16e8e88149664cb0c07e72fda814f32ae22ca630ddc67e0f950e12d4a4d4542f41169b4b73f0cfe73565f36318eadbe13e64dc9be8dfaccdec2721d583d51938
7
- data.tar.gz: b90d2a5589adc9c5c97e0ff8499cdd847e8a332133aec087dcdd26cb51233faca40434342245658c894231ab0126c4b5466d8523f61969243e4813aece87e1e7
6
+ metadata.gz: d17692b3a20373508da5a33fa90dfbbbdfc7f4c9b8f7d033e305962177c158254e81e09444294e72ea05cea355f3499ddeba3325be697122a52bbe720bc42c82
7
+ data.tar.gz: 90ad0d41b12be8866972c02bc8b484898b8009237e9d34584689e7d57fa8da836f664e037c3594666240f149364aab0126558b0a75fc08606d828a4fc912c46c
data/README.md CHANGED
@@ -23,7 +23,14 @@ One method per endpoint, named after the route.
23
23
  parse.ip('8.8.8.8')
24
24
  parse.ip_self
25
25
  parse.email('hello@gmail.com')
26
+ parse.vat('DE136695976')
27
+ parse.iban('DE89370400440532013000')
28
+ parse.npi('1881018208')
26
29
  parse.phone('+14155552671')
30
+ parse.carrier('+14155552671')
31
+ parse.caller('+14155552671')
32
+ parse.hlr('+14155552671')
33
+ parse.postal('SW1A 1AA')
27
34
  parse.postal('28202', country: 'US')
28
35
  parse.postal_nearby('28202', country: 'US', radius: 40)
29
36
  parse.postal_distance('28202', '10001', country: 'US')
@@ -31,8 +38,10 @@ parse.city('charlotte', country: 'US')
31
38
  parse.city_id('city_mb8mbqrkz8zb')
32
39
  parse.city_search('char', country: 'US', limit: 10)
33
40
  parse.city_nearest(35.2271, -80.8431)
41
+ parse.city_nearby('denver', radius: 8, unit: 'mi')
34
42
  parse.country('US')
35
43
  parse.country_states('US')
44
+ parse.state('colorado')
36
45
  parse.state('NC', country: 'US')
37
46
  parse.state_districts('NC', country: 'US')
38
47
  parse.district('37081')
@@ -41,6 +50,7 @@ parse.continent_countries('NA')
41
50
  parse.currency('USD')
42
51
  parse.currency_rate('USD', 'EUR')
43
52
  parse.language('en')
53
+ parse.name('BILLY OSHALL')
44
54
  parse.timezone('America/New_York')
45
55
  parse.holiday('US', year: 2026)
46
56
  parse.holiday_date('US', '2026-12-25')
@@ -50,6 +60,7 @@ parse.weather(40.7128, -74.006)
50
60
  parse.domain('example.com')
51
61
  parse.mx('example.com')
52
62
  parse.useragent(ua_string)
63
+ parse.vin('1HGCM82633A004352')
53
64
  parse.emoji('rocket')
54
65
  parse.emoji_search('fire')
55
66
  ```
@@ -55,6 +55,14 @@ module ParseAPI
55
55
  get("/continent/#{seg(code)}/countries")
56
56
  end
57
57
 
58
+ def bloc(code)
59
+ get("/bloc/#{seg(code)}")
60
+ end
61
+
62
+ def bloc_countries(code)
63
+ get("/bloc/#{seg(code)}/countries")
64
+ end
65
+
58
66
  def country(code)
59
67
  get("/country/#{seg(code)}")
60
68
  end
@@ -63,16 +71,16 @@ module ParseAPI
63
71
  get("/country/#{seg(code)}/states")
64
72
  end
65
73
 
66
- def state(code, country:)
74
+ def state(code, country: nil)
67
75
  get("/state/#{seg(code)}", country: country)
68
76
  end
69
77
 
70
- def state_districts(code, country:)
78
+ def state_districts(code, country: nil)
71
79
  get("/state/#{seg(code)}/districts", country: country)
72
80
  end
73
81
 
74
- def district(code, country: nil)
75
- get("/district/#{seg(code)}", country: country)
82
+ def district(code, country: nil, state: nil)
83
+ get("/district/#{seg(code)}", country: country, state: state)
76
84
  end
77
85
 
78
86
  def city(name, country: nil, state: nil)
@@ -91,15 +99,19 @@ module ParseAPI
91
99
  get('/city', lat: lat, lon: lon)
92
100
  end
93
101
 
94
- def postal(code, country:)
102
+ def city_nearby(name, radius: nil, unit: nil, country: nil, state: nil, limit: nil)
103
+ get("/city/#{seg(name)}/nearby", radius: radius, unit: unit, country: country, state: state, limit: limit)
104
+ end
105
+
106
+ def postal(code, country: nil)
95
107
  get("/postal/#{seg(code)}", country: country)
96
108
  end
97
109
 
98
- def postal_nearby(code, country:, radius: nil, unit: nil)
110
+ def postal_nearby(code, country: nil, radius: nil, unit: nil)
99
111
  get("/postal/#{seg(code)}/nearby", country: country, radius: radius, unit: unit)
100
112
  end
101
113
 
102
- def postal_distance(from, to, country:)
114
+ def postal_distance(from, to, country: nil)
103
115
  get("/postal/#{seg(from)}/distance/#{seg(to)}", country: country)
104
116
  end
105
117
 
@@ -107,10 +119,34 @@ module ParseAPI
107
119
  get("/email/#{seg(email)}", deep: deep)
108
120
  end
109
121
 
122
+ def vat(number, country: nil, deep: false, from: nil)
123
+ get("/vat/#{seg(number)}", country: country, deep: deep, from: from)
124
+ end
125
+
126
+ def iban(iban, country: nil)
127
+ get("/iban/#{seg(iban)}", country: country)
128
+ end
129
+
130
+ def npi(npi, deep: false)
131
+ get("/npi/#{seg(npi)}", deep: deep)
132
+ end
133
+
110
134
  def phone(number, country: nil, deep: false)
111
135
  get("/phone/#{seg(number)}", country: country, deep: deep)
112
136
  end
113
137
 
138
+ def carrier(number, country: nil)
139
+ get("/carrier/#{seg(number)}", country: country)
140
+ end
141
+
142
+ def caller(number, country: nil)
143
+ get("/caller/#{seg(number)}", country: country)
144
+ end
145
+
146
+ def hlr(number, country: nil)
147
+ get("/hlr/#{seg(number)}", country: country)
148
+ end
149
+
114
150
  def domain(domain, deep: false)
115
151
  get("/domain/#{seg(domain)}", deep: deep)
116
152
  end
@@ -123,18 +159,34 @@ module ParseAPI
123
159
  get('/useragent', { deep: deep }, { 'User-Agent' => ua })
124
160
  end
125
161
 
162
+ def vin(vin, deep: false)
163
+ get("/vin/#{seg(vin)}", deep: deep)
164
+ end
165
+
166
+ def tariff(code, deep: false, origin: nil)
167
+ get("/tariff/#{seg(code)}", deep: deep, origin: origin)
168
+ end
169
+
170
+ def tariff_search(q)
171
+ get('/tariff', q: q)
172
+ end
173
+
126
174
  def currency(code)
127
175
  get("/currency/#{seg(code)}")
128
176
  end
129
177
 
130
- def currency_rate(base, quote)
131
- get("/currency/#{seg(base)}/#{seg(quote)}")
178
+ def currency_rate(base, quote, date: nil, amount: nil)
179
+ get("/currency/#{seg(base)}/#{seg(quote)}", date: date, amount: amount)
132
180
  end
133
181
 
134
182
  def language(code)
135
183
  get("/language/#{seg(code)}")
136
184
  end
137
185
 
186
+ def name(name)
187
+ get("/name/#{seg(name)}")
188
+ end
189
+
138
190
  def timezone(id, at: nil)
139
191
  get("/timezone/#{seg(id)}", at: at)
140
192
  end
@@ -1,3 +1,3 @@
1
1
  module ParseAPI
2
- VERSION = '0.1.0'.freeze
2
+ VERSION = '0.2.1'.freeze
3
3
  end
metadata CHANGED
@@ -1,16 +1,16 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: parseapi
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.2.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - parseAPI
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2026-08-13 00:00:00.000000000 Z
11
+ date: 2026-09-02 00:00:00.000000000 Z
12
12
  dependencies: []
13
- description:
13
+ description:
14
14
  email:
15
15
  - hello@parseapi.com
16
16
  executables: []
@@ -29,7 +29,7 @@ metadata:
29
29
  homepage_uri: https://parseapi.com
30
30
  source_code_uri: https://github.com/parseapi/ruby
31
31
  documentation_uri: https://parseapi.com/docs
32
- post_install_message:
32
+ post_install_message:
33
33
  rdoc_options: []
34
34
  require_paths:
35
35
  - lib
@@ -44,8 +44,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
44
44
  - !ruby/object:Gem::Version
45
45
  version: '0'
46
46
  requirements: []
47
- rubygems_version: 3.0.3.1
48
- signing_key:
47
+ rubygems_version: 3.5.22
48
+ signing_key:
49
49
  specification_version: 4
50
50
  summary: Official parseAPI client for Ruby. One key, minimal JSON, fast.
51
51
  test_files: []