panoptes-client 1.0.0 → 1.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +4 -0
- data/README.md +1 -1
- data/lib/panoptes/client/collections.rb +5 -0
- data/lib/panoptes/client/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 39aeafa72adb7b23aa7f2c92feb0e0fa673c2fe88c85a4d007362ad5609a5aa1
|
4
|
+
data.tar.gz: 35626ac17f0645ed4de74a9ec9e85515152a0b8b8f6a55bde827f9c2b29e779e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0727eb9c0a4d26eec16972c82e6b122ce74e966458a8850de2197905d496dff2ab454fcd9e286f42d71d53d6240ab2faffedb5bf624ccfa02e361ced61174165
|
7
|
+
data.tar.gz: 7505d21379cf1cff27d679c512267bbdde3ce2672410f9716dd4b6345f00e111c37a6f6c1aa8b26ddf49fed8f4da2de1c55d56a1ef30b5a71eaef35f8f4f5a4d
|
data/CHANGELOG.md
CHANGED
data/README.md
CHANGED
@@ -18,7 +18,7 @@ In general, this library is supposed to be a thin, flat layer over our [HTTP-bas
|
|
18
18
|
|
19
19
|
## Development
|
20
20
|
|
21
|
-
After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake
|
21
|
+
After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake spec` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
|
22
22
|
|
23
23
|
The test suite uses VCR to record HTTP requests, so if you're not making any new requests you should be fine with the existing cassettes. If you are, the test suite uses environment variables to pull in authentication credentials. You'll need to [create an OAuth application on staging](https://panoptes-staging.zooniverse.org/oauth/applications), and set the following env vars:
|
24
24
|
|
@@ -3,6 +3,11 @@
|
|
3
3
|
module Panoptes
|
4
4
|
class Client
|
5
5
|
module Collections
|
6
|
+
def collection(collection_id)
|
7
|
+
response = panoptes.get("/collections/#{collection_id}")
|
8
|
+
response['collections'].first
|
9
|
+
end
|
10
|
+
|
6
11
|
def add_subjects_to_collection(collection_id, subject_ids)
|
7
12
|
panoptes.post("/collections/#{collection_id}/links/subjects", subjects: subject_ids)
|
8
13
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: panoptes-client
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.1.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Marten Veldthuis
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: exe
|
12
12
|
cert_chain: []
|
13
|
-
date:
|
13
|
+
date: 2020-04-08 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: deprecate
|
@@ -204,7 +204,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
204
204
|
- !ruby/object:Gem::Version
|
205
205
|
version: '0'
|
206
206
|
requirements: []
|
207
|
-
rubygems_version: 3.0.
|
207
|
+
rubygems_version: 3.0.3
|
208
208
|
signing_key:
|
209
209
|
specification_version: 4
|
210
210
|
summary: API wrapper for https://panoptes.zooniverse.org
|