scaleapi-ruby 0.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.document +5 -0
- data/CONTRIBUTING.md +29 -0
- data/Gemfile +19 -0
- data/Gemfile.lock +121 -0
- data/LICENSE.md +25 -0
- data/README.md +237 -0
- data/Rakefile +52 -0
- data/VERSION +1 -0
- data/lib/scale.rb +42 -0
- data/lib/scale/api.rb +104 -0
- data/lib/scale/callbacks/base.rb +25 -0
- data/lib/scale/callbacks/task.rb +23 -0
- data/lib/scale/endpoints/endpoint.rb +31 -0
- data/lib/scale/endpoints/tasks/cancel_task.rb +23 -0
- data/lib/scale/endpoints/tasks/create_annotation_task.rb +16 -0
- data/lib/scale/endpoints/tasks/create_categorization_task.rb +16 -0
- data/lib/scale/endpoints/tasks/create_comparison_task.rb +16 -0
- data/lib/scale/endpoints/tasks/create_phonecall_task.rb +16 -0
- data/lib/scale/endpoints/tasks/create_transcription_task.rb +16 -0
- data/lib/scale/endpoints/tasks/list_tasks.rb +27 -0
- data/lib/scale/endpoints/tasks/retrieve_task.rb +23 -0
- data/lib/scale/endpoints/tasks/task_endpoint.rb +22 -0
- data/lib/scale/generic_error.rb +4 -0
- data/lib/scale/http_error.rb +16 -0
- data/lib/scale/resources/base.rb +6 -0
- data/lib/scale/resources/task.rb +26 -0
- data/test/callbacks/test_task_callback.rb +35 -0
- data/test/fixtures/callback.json +29 -0
- data/test/fixtures/vcr_cassettes/tasks.yml +2629 -0
- data/test/helper.rb +42 -0
- data/test/tasks/test_cancel_task.rb +21 -0
- data/test/tasks/test_create_annotation_task.rb +40 -0
- data/test/tasks/test_create_categorization_task.rb +40 -0
- data/test/tasks/test_create_comparison_task.rb +43 -0
- data/test/tasks/test_create_phonecall_task.rb +41 -0
- data/test/tasks/test_create_transcription_task.rb +41 -0
- data/test/tasks/test_list_tasks.rb +14 -0
- data/test/tasks/test_retrieve_task.rb +37 -0
- data/test/test_api.rb +27 -0
- metadata +182 -0
data/test/helper.rb
ADDED
@@ -0,0 +1,42 @@
|
|
1
|
+
require 'rubygems'
|
2
|
+
require 'bundler'
|
3
|
+
begin
|
4
|
+
Bundler.setup(:default, :development)
|
5
|
+
rescue Bundler::BundlerError => e
|
6
|
+
$stderr.puts e.message
|
7
|
+
$stderr.puts 'Run `bundle install` to install missing gems'
|
8
|
+
exit e.status_code
|
9
|
+
end
|
10
|
+
require 'test/unit'
|
11
|
+
require 'shoulda'
|
12
|
+
|
13
|
+
$LOAD_PATH.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
|
14
|
+
$LOAD_PATH.unshift(File.dirname(__FILE__))
|
15
|
+
require 'scale'
|
16
|
+
|
17
|
+
class Test::Unit::TestCase
|
18
|
+
def scale
|
19
|
+
@scale ||= Scale.setup api_key: (ENV['SCALE_API_KEY'] || 'test_abcdefghijklmopqrstuvwxyz'),
|
20
|
+
default_request_params: { callback_url: 'http://www.example.com/callback' },
|
21
|
+
callback_key: 'TEST'
|
22
|
+
end
|
23
|
+
|
24
|
+
def load_file(file)
|
25
|
+
File.read "test/fixtures/#{file}"
|
26
|
+
end
|
27
|
+
|
28
|
+
def load_json(file)
|
29
|
+
Scale.hash JSON.parse(load_file(file))
|
30
|
+
end
|
31
|
+
end
|
32
|
+
|
33
|
+
require 'vcr'
|
34
|
+
|
35
|
+
VCR.configure do |config|
|
36
|
+
config.cassette_library_dir = 'test/fixtures/vcr_cassettes'
|
37
|
+
config.hook_into :webmock
|
38
|
+
config.default_cassette_options = config.default_cassette_options.merge(
|
39
|
+
match_requests_on: %i(method uri host path query body headers),
|
40
|
+
record: :new_episodes
|
41
|
+
)
|
42
|
+
end
|
@@ -0,0 +1,21 @@
|
|
1
|
+
require 'helper'
|
2
|
+
|
3
|
+
class TestCancelTask < Test::Unit::TestCase
|
4
|
+
context 'cancel a completed task' do
|
5
|
+
should 'raise an error' do
|
6
|
+
VCR.use_cassette 'tasks' do
|
7
|
+
# First, create a task
|
8
|
+
task = scale.create_phonecall_task instruction: "Call this person and tell me his email address. Ask if he's happy too.",
|
9
|
+
phone_number: '5055006865',
|
10
|
+
entity_name: 'Alexandr Wang',
|
11
|
+
fields: { email: 'Email Address' },
|
12
|
+
choices: ['He is happy', 'He is not happy']
|
13
|
+
|
14
|
+
# Then, try canceling it
|
15
|
+
assert_raise Scale::HttpError do
|
16
|
+
scale.cancel_task task.id
|
17
|
+
end
|
18
|
+
end
|
19
|
+
end
|
20
|
+
end
|
21
|
+
end
|
@@ -0,0 +1,40 @@
|
|
1
|
+
require 'helper'
|
2
|
+
|
3
|
+
class TestCreateAnnotationTask < Test::Unit::TestCase
|
4
|
+
context 'create a annotation task' do
|
5
|
+
setup do
|
6
|
+
@valid_parameters = Scale.hash instruction: 'Draw a box around each baby cow and big cow.',
|
7
|
+
attachment_type: "image",
|
8
|
+
attachment: "http://i.imgur.com/v4cBreD.jpg",
|
9
|
+
objects_to_annotate: ["baby cow", "big cow"],
|
10
|
+
with_labels: true
|
11
|
+
|
12
|
+
@invalid_parameters = Scale.hash
|
13
|
+
end
|
14
|
+
|
15
|
+
should 'create a valid annotation task' do
|
16
|
+
VCR.use_cassette 'tasks' do
|
17
|
+
task = scale.create_annotation_task @valid_parameters
|
18
|
+
assert_equal task.class, Scale::Resources::Task
|
19
|
+
assert_equal task.params, @valid_parameters.select { |k| %Q(attachment_type attachment objects_to_annotate with_labels).include? k.to_s }
|
20
|
+
end
|
21
|
+
end
|
22
|
+
|
23
|
+
should 'raise a 400 (bad request) error with invalid parameters' do
|
24
|
+
VCR.use_cassette 'tasks' do
|
25
|
+
assert_raise Scale::HttpError do
|
26
|
+
scale.create_annotation_task @invalid_parameters
|
27
|
+
end
|
28
|
+
|
29
|
+
begin
|
30
|
+
scale.create_annotation_task @invalid_parameters
|
31
|
+
rescue => e
|
32
|
+
exception = e
|
33
|
+
end
|
34
|
+
|
35
|
+
assert_equal exception.code, 400
|
36
|
+
assert_equal exception.message, 'Please provide a plaintext instruction to the worker in the instruction field.'
|
37
|
+
end
|
38
|
+
end
|
39
|
+
end
|
40
|
+
end
|
@@ -0,0 +1,40 @@
|
|
1
|
+
require 'helper'
|
2
|
+
|
3
|
+
class TestCreateCategorizationTask < Test::Unit::TestCase
|
4
|
+
context 'create a categorization task' do
|
5
|
+
setup do
|
6
|
+
@valid_parameters = Scale.hash instruction: 'Is this company public or private?',
|
7
|
+
attachment_type: 'website',
|
8
|
+
attachment: 'http://www.google.com/',
|
9
|
+
categories: ['public', 'private'],
|
10
|
+
allow_multiple: false
|
11
|
+
|
12
|
+
@invalid_parameters = Scale.hash instruction: 'Test instruction'
|
13
|
+
end
|
14
|
+
|
15
|
+
should 'create a valid categorization task' do
|
16
|
+
VCR.use_cassette 'tasks' do
|
17
|
+
task = scale.create_categorization_task @valid_parameters
|
18
|
+
assert_equal task.class, Scale::Resources::Task
|
19
|
+
assert_equal task.params, @valid_parameters.select { |k| %Q(attachment_type attachment categories allow_multiple).include? k.to_s }
|
20
|
+
end
|
21
|
+
end
|
22
|
+
|
23
|
+
should 'raise a 400 (bad request) error with invalid parameters' do
|
24
|
+
VCR.use_cassette 'tasks' do
|
25
|
+
assert_raise Scale::HttpError do
|
26
|
+
scale.create_categorization_task @invalid_parameters
|
27
|
+
end
|
28
|
+
|
29
|
+
begin
|
30
|
+
scale.create_categorization_task @invalid_parameters
|
31
|
+
rescue => e
|
32
|
+
exception = e
|
33
|
+
end
|
34
|
+
|
35
|
+
assert_equal exception.code, 400
|
36
|
+
assert_equal exception.message, 'Please provide an attachment as a URL or plaintext.'
|
37
|
+
end
|
38
|
+
end
|
39
|
+
end
|
40
|
+
end
|
@@ -0,0 +1,43 @@
|
|
1
|
+
require 'helper'
|
2
|
+
|
3
|
+
class TestCreateAnnotationTask < Test::Unit::TestCase
|
4
|
+
context 'create a comparison task' do
|
5
|
+
setup do
|
6
|
+
@valid_parameters = Scale.hash instruction: 'Do the objects in these images have the same pattern?',
|
7
|
+
attachment_type: 'image',
|
8
|
+
choices: ['yes', 'no'],
|
9
|
+
attachments: [
|
10
|
+
'http://i.ebayimg.com/00/$T2eC16dHJGwFFZKjy5ZjBRfNyMC4Ig~~_32.JPG',
|
11
|
+
'http://images.wisegeek.com/checkered-tablecloth.jpg'
|
12
|
+
]
|
13
|
+
|
14
|
+
@invalid_parameters = Scale.hash instruction: 'Test instruction',
|
15
|
+
choices: ['a', 'b']
|
16
|
+
end
|
17
|
+
|
18
|
+
should 'create a valid comparison task' do
|
19
|
+
VCR.use_cassette 'tasks' do
|
20
|
+
task = scale.create_comparison_task @valid_parameters
|
21
|
+
assert_equal task.class, Scale::Resources::Task
|
22
|
+
assert_equal task.params, @valid_parameters.select { |k| %Q(attachment_type choices attachments).include? k.to_s }
|
23
|
+
end
|
24
|
+
end
|
25
|
+
|
26
|
+
should 'raise a 400 (bad request) error with invalid parameters' do
|
27
|
+
VCR.use_cassette 'tasks' do
|
28
|
+
assert_raise Scale::HttpError do
|
29
|
+
scale.create_comparison_task @invalid_parameters
|
30
|
+
end
|
31
|
+
|
32
|
+
begin
|
33
|
+
scale.create_comparison_task @invalid_parameters
|
34
|
+
rescue => e
|
35
|
+
exception = e
|
36
|
+
end
|
37
|
+
|
38
|
+
assert_equal exception.code, 400
|
39
|
+
assert_equal exception.message, 'Please provide attachments for the worker to compare for the task.'
|
40
|
+
end
|
41
|
+
end
|
42
|
+
end
|
43
|
+
end
|
@@ -0,0 +1,41 @@
|
|
1
|
+
require 'helper'
|
2
|
+
|
3
|
+
class TestCreatePhonecallTask < Test::Unit::TestCase
|
4
|
+
context 'create a phonecall task' do
|
5
|
+
setup do
|
6
|
+
@valid_parameters = Scale.hash instruction: "Call this person and tell me his email address. Ask if he's happy too.",
|
7
|
+
phone_number: '5055006865',
|
8
|
+
entity_name: 'Alexandr Wang',
|
9
|
+
fields: { email: 'Email Address' },
|
10
|
+
choices: ['He is happy', 'He is not happy']
|
11
|
+
|
12
|
+
@invalid_parameters = Scale.hash instruction: 'Test instruction',
|
13
|
+
phone_number: '5055006865'
|
14
|
+
end
|
15
|
+
|
16
|
+
should 'create a valid phone call task' do
|
17
|
+
VCR.use_cassette 'tasks' do
|
18
|
+
task = scale.create_phonecall_task @valid_parameters
|
19
|
+
assert_equal task.class, Scale::Resources::Task
|
20
|
+
assert_equal task.params, @valid_parameters.select { |k| %Q(phone_number entity_name fields choices).include? k.to_s }
|
21
|
+
end
|
22
|
+
end
|
23
|
+
|
24
|
+
should 'raise a 400 (bad request) error with invalid parameters' do
|
25
|
+
VCR.use_cassette 'tasks' do
|
26
|
+
assert_raise Scale::HttpError do
|
27
|
+
scale.create_phonecall_task @invalid_parameters
|
28
|
+
end
|
29
|
+
|
30
|
+
begin
|
31
|
+
scale.create_phonecall_task @invalid_parameters
|
32
|
+
rescue => e
|
33
|
+
exception = e
|
34
|
+
end
|
35
|
+
|
36
|
+
assert_equal exception.code, 400
|
37
|
+
assert_equal exception.message, 'Please provide an entity name (name, business name, etc.) corresponding to the phone number for the worker.'
|
38
|
+
end
|
39
|
+
end
|
40
|
+
end
|
41
|
+
end
|
@@ -0,0 +1,41 @@
|
|
1
|
+
require 'helper'
|
2
|
+
|
3
|
+
class TestCreateTranscriptionTask < Test::Unit::TestCase
|
4
|
+
context 'create a categorization task' do
|
5
|
+
setup do
|
6
|
+
@valid_parameters = Scale.hash instruction: 'Transcribe the given fields. Then for each news item on the page, transcribe the information for the row.',
|
7
|
+
attachment_type: 'website',
|
8
|
+
attachment: 'http://www.google.com/',
|
9
|
+
fields: { title: 'Title of Webpage', top_result: 'Title of the top result' },
|
10
|
+
row_fields: { username: 'Username of submitter', comment_count: 'Number of comments' }
|
11
|
+
|
12
|
+
@invalid_parameters = Scale.hash instruction: 'Test instruction',
|
13
|
+
attachment_type: 'website'
|
14
|
+
end
|
15
|
+
|
16
|
+
should 'create a valid transcription task' do
|
17
|
+
VCR.use_cassette 'tasks' do
|
18
|
+
task = scale.create_transcription_task @valid_parameters
|
19
|
+
assert_equal task.class, Scale::Resources::Task
|
20
|
+
assert_equal task.params, @valid_parameters.select { |k| %Q(attachment_type attachment fields row_fields).include? k.to_s }
|
21
|
+
end
|
22
|
+
end
|
23
|
+
|
24
|
+
should 'raise a 400 (bad request) error with invalid parameters' do
|
25
|
+
VCR.use_cassette 'tasks' do
|
26
|
+
assert_raise Scale::HttpError do
|
27
|
+
scale.create_transcription_task @invalid_parameters
|
28
|
+
end
|
29
|
+
|
30
|
+
begin
|
31
|
+
scale.create_transcription_task @invalid_parameters
|
32
|
+
rescue => e
|
33
|
+
exception = e
|
34
|
+
end
|
35
|
+
|
36
|
+
assert_equal exception.code, 400
|
37
|
+
assert_equal exception.message, 'Please provide an attachment as a URL or plaintext.'
|
38
|
+
end
|
39
|
+
end
|
40
|
+
end
|
41
|
+
end
|
@@ -0,0 +1,14 @@
|
|
1
|
+
require 'helper'
|
2
|
+
|
3
|
+
class TestListTasks < Test::Unit::TestCase
|
4
|
+
context 'list available tasks' do
|
5
|
+
should 'retrieve a list of tasks' do
|
6
|
+
VCR.use_cassette 'tasks' do
|
7
|
+
tasks = scale.tasks
|
8
|
+
assert_equal(tasks.class, Array)
|
9
|
+
assert(tasks.count > 0)
|
10
|
+
assert tasks.all? { |t| t.is_a? Scale::Resources::Task }
|
11
|
+
end
|
12
|
+
end
|
13
|
+
end
|
14
|
+
end
|
@@ -0,0 +1,37 @@
|
|
1
|
+
require 'helper'
|
2
|
+
|
3
|
+
class TestRetrieveTask < Test::Unit::TestCase
|
4
|
+
context 'retrieve an available tasks' do
|
5
|
+
should 'return a task object' do
|
6
|
+
VCR.use_cassette 'tasks' do
|
7
|
+
# First, create a task
|
8
|
+
task1 = scale.create_phonecall_task instruction: "Call this person and tell me his email address. Ask if he's happy too.",
|
9
|
+
phone_number: '5055006865',
|
10
|
+
entity_name: 'Alexandr Wang',
|
11
|
+
fields: { email: 'Email Address' },
|
12
|
+
choices: ['He is happy', 'He is not happy']
|
13
|
+
|
14
|
+
# Retrieve that task, and compare it with the previous task
|
15
|
+
task2 = scale.retrieve_task task1.id
|
16
|
+
assert_equal(task1.id, task2.id)
|
17
|
+
assert_equal(task1.instruction, task2.instruction)
|
18
|
+
assert_equal(task1.callback_url, task2.callback_url)
|
19
|
+
assert_equal(task1.created_at, task2.created_at)
|
20
|
+
end
|
21
|
+
end
|
22
|
+
end
|
23
|
+
|
24
|
+
context 'retrieve a non existent tasks' do
|
25
|
+
setup do
|
26
|
+
@fake_task_id = 'abcdefghijklmn0123456789'
|
27
|
+
end
|
28
|
+
|
29
|
+
should 'raise an http error' do
|
30
|
+
VCR.use_cassette 'tasks' do
|
31
|
+
assert_raise Scale::HttpError do
|
32
|
+
scale.retrieve_task @fake_task_id
|
33
|
+
end
|
34
|
+
end
|
35
|
+
end
|
36
|
+
end
|
37
|
+
end
|
data/test/test_api.rb
ADDED
@@ -0,0 +1,27 @@
|
|
1
|
+
require 'helper'
|
2
|
+
|
3
|
+
class TestAPI < Test::Unit::TestCase
|
4
|
+
context 'create a valid API handler' do
|
5
|
+
should 'create an API object with default parameters' do
|
6
|
+
assert_nothing_raised do
|
7
|
+
Scale.setup api_key: scale.api_key
|
8
|
+
end
|
9
|
+
end
|
10
|
+
end
|
11
|
+
|
12
|
+
context 'create an API handler with an invalid token' do
|
13
|
+
should 'raise an error' do
|
14
|
+
assert_raise Scale::GenericError do
|
15
|
+
Scale.setup api_key: ''
|
16
|
+
end
|
17
|
+
end
|
18
|
+
end
|
19
|
+
|
20
|
+
context 'create an API handler with an invalid endpoint' do
|
21
|
+
should 'raise an error' do
|
22
|
+
assert_raise Scale::GenericError do
|
23
|
+
Scale.setup endpoint: 'invalid-url'
|
24
|
+
end
|
25
|
+
end
|
26
|
+
end
|
27
|
+
end
|
metadata
ADDED
@@ -0,0 +1,182 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: scaleapi-ruby
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.0.1
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Daniel Herzog
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
date: 2016-09-21 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: rest-client
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - ">="
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '0'
|
20
|
+
type: :runtime
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - ">="
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '0'
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: activesupport
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - ">="
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '0'
|
34
|
+
type: :runtime
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - ">="
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: '0'
|
41
|
+
- !ruby/object:Gem::Dependency
|
42
|
+
name: rdoc
|
43
|
+
requirement: !ruby/object:Gem::Requirement
|
44
|
+
requirements:
|
45
|
+
- - "~>"
|
46
|
+
- !ruby/object:Gem::Version
|
47
|
+
version: '3.12'
|
48
|
+
type: :development
|
49
|
+
prerelease: false
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - "~>"
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: '3.12'
|
55
|
+
- !ruby/object:Gem::Dependency
|
56
|
+
name: bundler
|
57
|
+
requirement: !ruby/object:Gem::Requirement
|
58
|
+
requirements:
|
59
|
+
- - "~>"
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '1.0'
|
62
|
+
type: :development
|
63
|
+
prerelease: false
|
64
|
+
version_requirements: !ruby/object:Gem::Requirement
|
65
|
+
requirements:
|
66
|
+
- - "~>"
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: '1.0'
|
69
|
+
- !ruby/object:Gem::Dependency
|
70
|
+
name: juwelier
|
71
|
+
requirement: !ruby/object:Gem::Requirement
|
72
|
+
requirements:
|
73
|
+
- - "~>"
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
version: 2.1.0
|
76
|
+
type: :development
|
77
|
+
prerelease: false
|
78
|
+
version_requirements: !ruby/object:Gem::Requirement
|
79
|
+
requirements:
|
80
|
+
- - "~>"
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: 2.1.0
|
83
|
+
- !ruby/object:Gem::Dependency
|
84
|
+
name: pry
|
85
|
+
requirement: !ruby/object:Gem::Requirement
|
86
|
+
requirements:
|
87
|
+
- - ">="
|
88
|
+
- !ruby/object:Gem::Version
|
89
|
+
version: '0'
|
90
|
+
type: :development
|
91
|
+
prerelease: false
|
92
|
+
version_requirements: !ruby/object:Gem::Requirement
|
93
|
+
requirements:
|
94
|
+
- - ">="
|
95
|
+
- !ruby/object:Gem::Version
|
96
|
+
version: '0'
|
97
|
+
- !ruby/object:Gem::Dependency
|
98
|
+
name: pry-nav
|
99
|
+
requirement: !ruby/object:Gem::Requirement
|
100
|
+
requirements:
|
101
|
+
- - ">="
|
102
|
+
- !ruby/object:Gem::Version
|
103
|
+
version: '0'
|
104
|
+
type: :development
|
105
|
+
prerelease: false
|
106
|
+
version_requirements: !ruby/object:Gem::Requirement
|
107
|
+
requirements:
|
108
|
+
- - ">="
|
109
|
+
- !ruby/object:Gem::Version
|
110
|
+
version: '0'
|
111
|
+
description: A ruby gem wrapper for the Scale API, containing all the endpoints available.
|
112
|
+
email: info@danielherzog.es
|
113
|
+
executables: []
|
114
|
+
extensions: []
|
115
|
+
extra_rdoc_files:
|
116
|
+
- LICENSE.md
|
117
|
+
- README.md
|
118
|
+
files:
|
119
|
+
- ".document"
|
120
|
+
- CONTRIBUTING.md
|
121
|
+
- Gemfile
|
122
|
+
- Gemfile.lock
|
123
|
+
- LICENSE.md
|
124
|
+
- README.md
|
125
|
+
- Rakefile
|
126
|
+
- VERSION
|
127
|
+
- lib/scale.rb
|
128
|
+
- lib/scale/api.rb
|
129
|
+
- lib/scale/callbacks/base.rb
|
130
|
+
- lib/scale/callbacks/task.rb
|
131
|
+
- lib/scale/endpoints/endpoint.rb
|
132
|
+
- lib/scale/endpoints/tasks/cancel_task.rb
|
133
|
+
- lib/scale/endpoints/tasks/create_annotation_task.rb
|
134
|
+
- lib/scale/endpoints/tasks/create_categorization_task.rb
|
135
|
+
- lib/scale/endpoints/tasks/create_comparison_task.rb
|
136
|
+
- lib/scale/endpoints/tasks/create_phonecall_task.rb
|
137
|
+
- lib/scale/endpoints/tasks/create_transcription_task.rb
|
138
|
+
- lib/scale/endpoints/tasks/list_tasks.rb
|
139
|
+
- lib/scale/endpoints/tasks/retrieve_task.rb
|
140
|
+
- lib/scale/endpoints/tasks/task_endpoint.rb
|
141
|
+
- lib/scale/generic_error.rb
|
142
|
+
- lib/scale/http_error.rb
|
143
|
+
- lib/scale/resources/base.rb
|
144
|
+
- lib/scale/resources/task.rb
|
145
|
+
- test/callbacks/test_task_callback.rb
|
146
|
+
- test/fixtures/callback.json
|
147
|
+
- test/fixtures/vcr_cassettes/tasks.yml
|
148
|
+
- test/helper.rb
|
149
|
+
- test/tasks/test_cancel_task.rb
|
150
|
+
- test/tasks/test_create_annotation_task.rb
|
151
|
+
- test/tasks/test_create_categorization_task.rb
|
152
|
+
- test/tasks/test_create_comparison_task.rb
|
153
|
+
- test/tasks/test_create_phonecall_task.rb
|
154
|
+
- test/tasks/test_create_transcription_task.rb
|
155
|
+
- test/tasks/test_list_tasks.rb
|
156
|
+
- test/tasks/test_retrieve_task.rb
|
157
|
+
- test/test_api.rb
|
158
|
+
homepage: http://github.com/wikiti/scaleapi-ruby
|
159
|
+
licenses:
|
160
|
+
- MIT
|
161
|
+
metadata: {}
|
162
|
+
post_install_message:
|
163
|
+
rdoc_options: []
|
164
|
+
require_paths:
|
165
|
+
- lib
|
166
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
167
|
+
requirements:
|
168
|
+
- - ">="
|
169
|
+
- !ruby/object:Gem::Version
|
170
|
+
version: '0'
|
171
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
172
|
+
requirements:
|
173
|
+
- - ">="
|
174
|
+
- !ruby/object:Gem::Version
|
175
|
+
version: '0'
|
176
|
+
requirements: []
|
177
|
+
rubyforge_project:
|
178
|
+
rubygems_version: 2.4.5.1
|
179
|
+
signing_key:
|
180
|
+
specification_version: 4
|
181
|
+
summary: A ruby gem wrapper for the Scale API
|
182
|
+
test_files: []
|