yandex_locator 1.0.0 → 1.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +13 -0
- data/lib/yandex_locator/version.rb +1 -1
- data/yandex_locator.gemspec +1 -0
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 7d4f4c021f6cdd349e4858d07da66bedb940bea9
|
4
|
+
data.tar.gz: fd26a9b5116248ab9c56187a683227f5a42749c5
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a16b1c541878f2adad22680755e7ab3e75040d3c1e40713c66a423448854d6b6559ac64aa6254fe4763f92b2e6996a78e2a454380ac2cb05fde9af92df642341
|
7
|
+
data.tar.gz: f63de8df0f370190c420ae73c7617af249492e6c905200c49b8f87926afda40e2973314177485d9eab4fdaf5bc53b1990e072a3440b37292b567d57f0adb6be5
|
data/README.md
CHANGED
@@ -8,6 +8,8 @@
|
|
8
8
|
|
9
9
|
Ruby gem for Yandex locator (https://tech.yandex.ru/locator/). Yandex locator is a service that finds mobile devices in a region delineated by a circle. The service returns longitude, latitude and precision.
|
10
10
|
|
11
|
+
Yandex locator can lookup by IP, wifi networks, gsm cells
|
12
|
+
|
11
13
|
## Installation
|
12
14
|
|
13
15
|
Add this line to your application's Gemfile:
|
@@ -64,6 +66,17 @@ Make request
|
|
64
66
|
result.position
|
65
67
|
# => {"altitude"=>0.0, "altitude_precision"=>30.0, "latitude"=>56.87141036987305, "longitude"=>60.61107635498047, "precision"=>1066.041137695312, "type"=>"gsm"}
|
66
68
|
```
|
69
|
+
Location Handle
|
70
|
+
```ruby
|
71
|
+
result = client.lookup(ip: '176.69.53.253')
|
72
|
+
if result.position
|
73
|
+
# do thangs....
|
74
|
+
else
|
75
|
+
p result.error['text']
|
76
|
+
end
|
77
|
+
```
|
78
|
+
|
79
|
+
|
67
80
|
|
68
81
|
|
69
82
|
## Development
|
data/yandex_locator.gemspec
CHANGED
@@ -12,6 +12,7 @@ Gem::Specification.new do |spec|
|
|
12
12
|
spec.summary = %q{ruby gem for yandex locator}
|
13
13
|
spec.description = %q{ruby gem for yandex locator}
|
14
14
|
spec.homepage = "https://github.com/sergey-chechaev/yandex_locator.git"
|
15
|
+
spec.license = "MIT"
|
15
16
|
|
16
17
|
spec.files = `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
|
17
18
|
spec.bindir = "exe"
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: yandex_locator
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Sergey Chechaev
|
@@ -60,7 +60,8 @@ files:
|
|
60
60
|
- lib/yandex_locator/version.rb
|
61
61
|
- yandex_locator.gemspec
|
62
62
|
homepage: https://github.com/sergey-chechaev/yandex_locator.git
|
63
|
-
licenses:
|
63
|
+
licenses:
|
64
|
+
- MIT
|
64
65
|
metadata: {}
|
65
66
|
post_install_message:
|
66
67
|
rdoc_options: []
|