yandex-api-fotki 0.1.0 → 0.1.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 +28 -4
- data/lib/yandex-api-fotki.rb +1 -0
- data/lib/yandex/api/fotki/version.rb +1 -1
- data/yandex-api-fotki.gemspec +1 -1
- metadata +11 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e9cfa966b4c28bc21388f42d9d6fd49b86c48c8c
|
4
|
+
data.tar.gz: 2d42f03a50f897d18348baab278897363f2db6ae
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 678536b7cefb8e10b51b64959339f256934f851d8bc4ae33ec8f95b5087dff7521e22182a6f179252fe279c212213779d554bc2044d8a7e54172a080979019f7
|
7
|
+
data.tar.gz: ce87d1d8042c2b8b3ec4298eac849d84737617dee4cdf268c73aa3877a0669d451304da6cafef68d93dc6cf260a32781b9a1ccbe55180a36cd3714a9d1f69794
|
data/README.md
CHANGED
@@ -1,5 +1,6 @@
|
|
1
1
|
# Yandex::Api::Fotki
|
2
2
|
|
3
|
+
[![Gem Version](https://badge.fury.io/rb/yandex-api-fotki.svg)](https://rubygems.org/gems/yandex-api-fotki)
|
3
4
|
[![Build Status](https://travis-ci.org/1v/yandex-api-fotki.svg?branch=master)](https://travis-ci.org/1v/yandex-api-fotki)
|
4
5
|
[![Dependency Status](https://gemnasium.com/badges/github.com/1v/yandex-api-fotki.svg)](https://gemnasium.com/github.com/1v/yandex-api-fotki)
|
5
6
|
[![Code Climate](https://codeclimate.com/github/1v/yandex-api-fotki/badges/gpa.svg)](https://codeclimate.com/github/1v/yandex-api-fotki)
|
@@ -22,22 +23,45 @@ And then execute:
|
|
22
23
|
Or install it yourself as:
|
23
24
|
|
24
25
|
$ gem install yandex-api-fotki
|
26
|
+
|
27
|
+
And require:
|
28
|
+
```ruby
|
29
|
+
require 'yandex-api-fotki'
|
30
|
+
```
|
25
31
|
|
26
32
|
## Usage
|
27
|
-
|
33
|
+
Instruction how to get OAUTH_CODE [`tech.yandex.ru`](https://tech.yandex.ru/oauth/doc/dg/tasks/get-oauth-token-docpage/)
|
28
34
|
```ruby
|
29
35
|
fotki = Yandex::API::Fotki.oauth(OAUTH_CODE)
|
30
36
|
photo = fotki.photos.upload(:image => File.new('/file.png'),
|
31
37
|
:access => 'private',
|
32
38
|
:album => 123456,
|
33
39
|
:title => "My Image")
|
34
|
-
|
35
|
-
=>
|
40
|
+
photo.id
|
41
|
+
=> 123456
|
42
|
+
photo.links
|
43
|
+
=> {
|
44
|
+
"XXS" => {
|
45
|
+
"height" => "75",
|
46
|
+
"href" => "http://img-fotki.yandex.ru/get/123456/123456468.56be/0_123bcc_ad08a9de_XXS",
|
47
|
+
"size" => "XXS",
|
48
|
+
"width" => "75"
|
49
|
+
},
|
50
|
+
...
|
51
|
+
"orig" => {
|
52
|
+
"bytesize" => "0",
|
53
|
+
"height" => "237",
|
54
|
+
"href" => "http://img-fotki.yandex.ru/get/123456/123456468.56be/0_1234bcc_ad08a9de_orig",
|
55
|
+
"size" => "orig",
|
56
|
+
"width" => "200"
|
57
|
+
}
|
58
|
+
}
|
36
59
|
```
|
60
|
+
All available options: [`tech.yandex.ru`](https://tech.yandex.ru/fotki/doc/concepts/add-photo-docpage/#multipart-format)
|
37
61
|
|
38
62
|
## Documentation
|
39
63
|
|
40
|
-
http://www.rubydoc.info/github/1v/yandex-api-fotki/
|
64
|
+
[`www.rubydoc.info`](http://www.rubydoc.info/github/1v/yandex-api-fotki/)
|
41
65
|
|
42
66
|
## License
|
43
67
|
|
@@ -0,0 +1 @@
|
|
1
|
+
require_relative 'yandex/api/fotki'
|
data/yandex-api-fotki.gemspec
CHANGED
@@ -27,5 +27,5 @@ Gem::Specification.new do |spec|
|
|
27
27
|
spec.add_development_dependency "bundler", "~> 1.13"
|
28
28
|
spec.add_development_dependency "rake", "~> 10.0"
|
29
29
|
spec.add_development_dependency "rspec", "~> 3.0"
|
30
|
-
spec.add_development_dependency "codeclimate-test-reporter"
|
30
|
+
spec.add_development_dependency "codeclimate-test-reporter", "~> 0.6", ">= 0.6.0"
|
31
31
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: yandex-api-fotki
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- github.com/1v
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-10-
|
11
|
+
date: 2016-10-08 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rest-client
|
@@ -90,16 +90,22 @@ dependencies:
|
|
90
90
|
name: codeclimate-test-reporter
|
91
91
|
requirement: !ruby/object:Gem::Requirement
|
92
92
|
requirements:
|
93
|
+
- - "~>"
|
94
|
+
- !ruby/object:Gem::Version
|
95
|
+
version: '0.6'
|
93
96
|
- - ">="
|
94
97
|
- !ruby/object:Gem::Version
|
95
|
-
version:
|
98
|
+
version: 0.6.0
|
96
99
|
type: :development
|
97
100
|
prerelease: false
|
98
101
|
version_requirements: !ruby/object:Gem::Requirement
|
99
102
|
requirements:
|
103
|
+
- - "~>"
|
104
|
+
- !ruby/object:Gem::Version
|
105
|
+
version: '0.6'
|
100
106
|
- - ">="
|
101
107
|
- !ruby/object:Gem::Version
|
102
|
-
version:
|
108
|
+
version: 0.6.0
|
103
109
|
description: Yandex Fotki API wrapper
|
104
110
|
email:
|
105
111
|
- forwardin@yandex.ru
|
@@ -118,6 +124,7 @@ files:
|
|
118
124
|
- Rakefile
|
119
125
|
- bin/console
|
120
126
|
- bin/setup
|
127
|
+
- lib/yandex-api-fotki.rb
|
121
128
|
- lib/yandex/api/fotki.rb
|
122
129
|
- lib/yandex/api/fotki/version.rb
|
123
130
|
- yandex-api-fotki.gemspec
|