taskrabbit 0.0.7 → 0.0.8
Sign up to get free protection for your applications and to get access to all the features.
- data/.env.example +15 -0
- data/.gitignore +1 -0
- data/.rvmrc +1 -1
- data/CHANGELOG.md +4 -0
- data/Gemfile +2 -0
- data/lib/taskrabbit.rb +1 -0
- data/lib/taskrabbit/api.rb +1 -0
- data/lib/taskrabbit/offer.rb +15 -0
- data/lib/taskrabbit/smash.rb +17 -2
- data/lib/taskrabbit/task.rb +11 -1
- data/lib/taskrabbit/version.rb +1 -1
- data/spec/spec_helper.rb +8 -4
- data/spec/support/cassettes/account/no_user.yml +2 -2
- data/spec/support/cassettes/account/properties.yml +46 -27
- data/spec/support/cassettes/account/tasks.yml +10 -10
- data/spec/support/cassettes/account/with_user.yml +5 -5
- data/spec/support/cassettes/cities/all.yml +2 -2
- data/spec/support/cassettes/cities/find.yml +2 -2
- data/spec/support/cassettes/cities/properties.yml +2 -2
- data/spec/support/cassettes/errors/404.yml +28 -356
- data/spec/support/cassettes/locations/properties.yml +8 -8
- data/spec/support/cassettes/tasks/all.yml +2 -2
- data/spec/support/cassettes/tasks/create/default.yml +3 -3
- data/spec/support/cassettes/tasks/create/using_account.yml +3 -3
- data/spec/support/cassettes/tasks/create/with_invalid_params.yml +3 -3
- data/spec/support/cassettes/tasks/create/with_location.yml +3 -3
- data/spec/support/cassettes/tasks/create/with_times.yml +45 -0
- data/spec/support/cassettes/tasks/create/without_credit_card.yml +2 -2
- data/spec/support/cassettes/tasks/create/without_user.yml +2 -2
- data/spec/support/cassettes/tasks/delete.yml +6 -6
- data/spec/support/cassettes/tasks/find.yml +41 -26
- data/spec/support/cassettes/tasks/properties.yml +41 -26
- data/spec/support/cassettes/tasks/save.yml +6 -6
- data/spec/support/cassettes/tasks/update.yml +6 -6
- data/spec/support/cassettes/tasks/with_offers_properties.yml +45 -0
- data/spec/support/cassettes/tasks/without_client.yml +27 -23
- data/spec/support/cassettes/users/find.yml +61 -23
- data/spec/support/cassettes/users/properties.yml +35 -27
- data/spec/support/cassettes/users/tasks/all.yml +42 -27
- data/spec/taskrabbit/account_spec.rb +10 -10
- data/spec/taskrabbit/api_spec.rb +1 -1
- data/spec/taskrabbit/city_spec.rb +3 -3
- data/spec/taskrabbit/location_spec.rb +1 -1
- data/spec/taskrabbit/offer_spec.rb +23 -0
- data/spec/taskrabbit/smash_spec.rb +19 -0
- data/spec/taskrabbit/task_spec.rb +36 -22
- data/spec/taskrabbit/user_spec.rb +10 -10
- metadata +11 -3
@@ -2,13 +2,13 @@
|
|
2
2
|
- !ruby/struct:VCR::HTTPInteraction
|
3
3
|
request: !ruby/struct:VCR::Request
|
4
4
|
method: :get
|
5
|
-
uri:
|
5
|
+
uri: https://taskrabbitdev.com/api/v1/account?
|
6
6
|
body:
|
7
7
|
headers:
|
8
|
-
x-client-application:
|
9
|
-
-
|
10
|
-
authorization:
|
11
|
-
- OAuth
|
8
|
+
x-client-application:
|
9
|
+
- <API_SECRET>
|
10
|
+
authorization:
|
11
|
+
- OAuth <USER_WITH_CARD>
|
12
12
|
response: !ruby/struct:VCR::Response
|
13
13
|
status: !ruby/struct:VCR::ResponseStatus
|
14
14
|
code: 200
|
@@ -33,13 +33,13 @@
|
|
33
33
|
- !ruby/struct:VCR::HTTPInteraction
|
34
34
|
request: !ruby/struct:VCR::Request
|
35
35
|
method: :get
|
36
|
-
uri:
|
36
|
+
uri: https://taskrabbitdev.com/api/v1/users/49720/locations?
|
37
37
|
body:
|
38
38
|
headers:
|
39
39
|
x-client-application:
|
40
|
-
-
|
40
|
+
- <API_SECRET>
|
41
41
|
authorization:
|
42
|
-
- OAuth
|
42
|
+
- OAuth <USER_WITH_CARD>
|
43
43
|
response: !ruby/struct:VCR::Response
|
44
44
|
status: !ruby/struct:VCR::ResponseStatus
|
45
45
|
code: 200
|
@@ -2,11 +2,11 @@
|
|
2
2
|
- !ruby/struct:VCR::HTTPInteraction
|
3
3
|
request: !ruby/struct:VCR::Request
|
4
4
|
method: :get
|
5
|
-
uri:
|
5
|
+
uri: https://taskrabbitdev.com/api/v1/tasks?include[task][]=errors&include[task][]=links&include[task][]=error&include[task][]=id&include[task][]=name&include[task][]=user&include[task][]=runner&include[task][]=runners&include[task][]=named_price&include[task][]=charge_price&include[task][]=cost_in_cents&include[task][]=number_runners_to_fill&include[task][]=state_label&include[task][]=city_id&include[task][]=city&include[task][]=description&include[task][]=private_description&include[task][]=private_runner&include[task][]=virtual&include[task][]=state&include[task][]=assignment_type&include[task][]=complete_by_time&include[task][]=state_changed_at&include[task][]=assign_by_time&include[task][]=location_visits&include[task][]=offers&include[task][]=other_locations_attributes&include[task][]=uploaded_photos_attributes&include[task][]=uploaded_sounds_attributes
|
6
6
|
body:
|
7
7
|
headers:
|
8
8
|
x-client-application:
|
9
|
-
-
|
9
|
+
- <API_SECRET>
|
10
10
|
authorization:
|
11
11
|
- OAuth
|
12
12
|
response: !ruby/struct:VCR::Response
|
@@ -2,13 +2,13 @@
|
|
2
2
|
- !ruby/struct:VCR::HTTPInteraction
|
3
3
|
request: !ruby/struct:VCR::Request
|
4
4
|
method: :post
|
5
|
-
uri:
|
5
|
+
uri: https://taskrabbitdev.com/api/v1/tasks?
|
6
6
|
body: task[name]=My%20First%20Task&task[named_price]=20&task[city_id]=4
|
7
7
|
headers:
|
8
8
|
x-client-application:
|
9
|
-
-
|
9
|
+
- <API_SECRET>
|
10
10
|
authorization:
|
11
|
-
- OAuth
|
11
|
+
- OAuth <USER_WITH_CARD>
|
12
12
|
response: !ruby/struct:VCR::Response
|
13
13
|
status: !ruby/struct:VCR::ResponseStatus
|
14
14
|
code: 201
|
@@ -2,13 +2,13 @@
|
|
2
2
|
- !ruby/struct:VCR::HTTPInteraction
|
3
3
|
request: !ruby/struct:VCR::Request
|
4
4
|
method: :post
|
5
|
-
uri:
|
5
|
+
uri: https://taskrabbitdev.com/api/v1/tasks?
|
6
6
|
body: task[name]=My%20First%20Task&task[named_price]=20&task[city_id]=4
|
7
7
|
headers:
|
8
8
|
x-client-application:
|
9
|
-
-
|
9
|
+
- <API_SECRET>
|
10
10
|
authorization:
|
11
|
-
- OAuth
|
11
|
+
- OAuth <USER_WITH_CARD>
|
12
12
|
response: !ruby/struct:VCR::Response
|
13
13
|
status: !ruby/struct:VCR::ResponseStatus
|
14
14
|
code: 422
|
@@ -2,13 +2,13 @@
|
|
2
2
|
- !ruby/struct:VCR::HTTPInteraction
|
3
3
|
request: !ruby/struct:VCR::Request
|
4
4
|
method: :post
|
5
|
-
uri:
|
5
|
+
uri: https://taskrabbitdev.com/api/v1/tasks?
|
6
6
|
body:
|
7
7
|
headers:
|
8
8
|
x-client-application:
|
9
|
-
-
|
9
|
+
- <API_SECRET>
|
10
10
|
authorization:
|
11
|
-
- OAuth
|
11
|
+
- OAuth <USER_WITH_CARD>
|
12
12
|
response: !ruby/struct:VCR::Response
|
13
13
|
status: !ruby/struct:VCR::ResponseStatus
|
14
14
|
code: 422
|
@@ -2,13 +2,13 @@
|
|
2
2
|
- !ruby/struct:VCR::HTTPInteraction
|
3
3
|
request: !ruby/struct:VCR::Request
|
4
4
|
method: :post
|
5
|
-
uri:
|
5
|
+
uri: https://taskrabbitdev.com/api/v1/tasks?
|
6
6
|
body: task[name]=My%20First%20Task&task[named_price]=20&task[city_id]=4&task[other_locations_attributes][][city]=Boston&task[other_locations_attributes][][address]=123%20Main%20St&task[other_locations_attributes][][name]=Home&task[other_locations_attributes][][zip]=02154&task[other_locations_attributes][][lng]=-71.059774&task[other_locations_attributes][][lat]=42.358432&task[other_locations_attributes][][state]=MA&task[other_locations_attributes][][name]=Middle%20of%20the%20park&task[other_locations_attributes][][lng]=-71.059772&task[other_locations_attributes][][lat]=42.358430
|
7
7
|
headers:
|
8
8
|
x-client-application:
|
9
|
-
-
|
9
|
+
- <API_SECRET>
|
10
10
|
authorization:
|
11
|
-
- OAuth
|
11
|
+
- OAuth <USER_WITH_CARD>
|
12
12
|
response: !ruby/struct:VCR::Response
|
13
13
|
status: !ruby/struct:VCR::ResponseStatus
|
14
14
|
code: 200
|
@@ -0,0 +1,45 @@
|
|
1
|
+
---
|
2
|
+
- !ruby/struct:VCR::HTTPInteraction
|
3
|
+
request: !ruby/struct:VCR::Request
|
4
|
+
method: :post
|
5
|
+
uri: https://taskrabbitdev.com:443/api/v1/tasks?
|
6
|
+
body: task[description]=&task[private_description]=&task[private_runner]=false&task[virtual]=false&task[name]=My%20First%20Task&task[named_price]=20&task[city_id]=4&task[complete_by_time]=1702411800&task[assign_by_time]=1701465000
|
7
|
+
headers:
|
8
|
+
x-client-application:
|
9
|
+
- <API_SECRET>
|
10
|
+
authorization:
|
11
|
+
- OAuth <USER_WITH_CARD>
|
12
|
+
response: !ruby/struct:VCR::Response
|
13
|
+
status: !ruby/struct:VCR::ResponseStatus
|
14
|
+
code: 200
|
15
|
+
message: OK
|
16
|
+
headers:
|
17
|
+
server:
|
18
|
+
- nginx/1.0.11
|
19
|
+
date:
|
20
|
+
- Wed, 10 Oct 2012 05:38:58 GMT
|
21
|
+
content-type:
|
22
|
+
- application/json; charset=utf-8
|
23
|
+
status:
|
24
|
+
- 200 OK
|
25
|
+
etag:
|
26
|
+
- ! '"2a1d2e4369a81524428d843953cb1484"'
|
27
|
+
cache-control:
|
28
|
+
- max-age=0, private, must-revalidate
|
29
|
+
set-cookie:
|
30
|
+
- current_geo=1053; path=/; expires=Mon, 10-Dec-2012 06:38:58 GMT; secure
|
31
|
+
x-runtime:
|
32
|
+
- '0.532811'
|
33
|
+
x-ua-compatible:
|
34
|
+
- IE=Edge,chrome=1
|
35
|
+
strict-transport-security:
|
36
|
+
- max-age=31536000
|
37
|
+
content-length:
|
38
|
+
- '1040'
|
39
|
+
body: ! '{"charge_price":20,"id":132,"named_price":20,"runners":{"items":[]},"cost_in_cents":0,"assign_by_time":1701465000,"assignment_type":"auto","description_properties":[{"value":"","title":"Description","key":"description"},{"value":"","title":"Private
|
40
|
+
description","key":"private_description"},{"value":1701465000,"title":"If unassigned,
|
41
|
+
Task will expire on","key":"assign_by_time"},{"value":1702411800,"title":"Task
|
42
|
+
should be completed by","key":"complete_by_time"}],"state_label":"posted","city":{"id":1060,"lng":-74.005973,"lat":40.714353,"name":"New
|
43
|
+
York City","links":{"get":"/api/v1/cities/4"}},"state_changed_at":1349847538,"name":"My
|
44
|
+
First Task","state":"opened","private_runner":false,"complete_by_time":1702411800,"runner_fee":0,"links":{"put":"/api/v1/tasks/132","html":"http://s-app1.taskrabbit.com/tasks/my-first-task--15","get":"/api/v1/tasks/132","authenticated":"http://s-app1.taskrabbit.com/go/f628a10b1384beb11bd617706d93ecec821e47520a27c9cd0b71f64399e289ec3d66c5d247d6248768f2a5fb47a7267e7360","delete":"/api/v1/tasks/132"}}'
|
45
|
+
http_version: '1.1'
|
@@ -2,11 +2,11 @@
|
|
2
2
|
- !ruby/struct:VCR::HTTPInteraction
|
3
3
|
request: !ruby/struct:VCR::Request
|
4
4
|
method: :post
|
5
|
-
uri:
|
5
|
+
uri: https://taskrabbitdev.com/api/v1/tasks?
|
6
6
|
body: task[name]=My%20First%20Task&task[named_price]=20&task[city_id]=4
|
7
7
|
headers:
|
8
8
|
x-client-application:
|
9
|
-
-
|
9
|
+
- <API_SECRET>
|
10
10
|
authorization:
|
11
11
|
- OAuth sjCuNHsxMRkFiJGpLWZzYJksDjfnXtDvDcPuuDkn
|
12
12
|
response: !ruby/struct:VCR::Response
|
@@ -2,11 +2,11 @@
|
|
2
2
|
- !ruby/struct:VCR::HTTPInteraction
|
3
3
|
request: !ruby/struct:VCR::Request
|
4
4
|
method: :post
|
5
|
-
uri:
|
5
|
+
uri: https://taskrabbitdev.com/api/v1/tasks?
|
6
6
|
body: task[name]=My%20First%20Task&task[named_price]=20&task[city_id]=4
|
7
7
|
headers:
|
8
8
|
x-client-application:
|
9
|
-
-
|
9
|
+
- <API_SECRET>
|
10
10
|
authorization:
|
11
11
|
- OAuth
|
12
12
|
response: !ruby/struct:VCR::Response
|
@@ -2,13 +2,13 @@
|
|
2
2
|
- !ruby/struct:VCR::HTTPInteraction
|
3
3
|
request: !ruby/struct:VCR::Request
|
4
4
|
method: :post
|
5
|
-
uri:
|
5
|
+
uri: https://taskrabbitdev.com/api/v1/tasks?
|
6
6
|
body: task[name]=My%20First%20Task&task[named_price]=20&task[city_id]=4
|
7
7
|
headers:
|
8
8
|
x-client-application:
|
9
|
-
-
|
9
|
+
- <API_SECRET>
|
10
10
|
authorization:
|
11
|
-
- OAuth
|
11
|
+
- OAuth <USER_WITH_CARD>
|
12
12
|
response: !ruby/struct:VCR::Response
|
13
13
|
status: !ruby/struct:VCR::ResponseStatus
|
14
14
|
code: 200
|
@@ -33,13 +33,13 @@
|
|
33
33
|
- !ruby/struct:VCR::HTTPInteraction
|
34
34
|
request: !ruby/struct:VCR::Request
|
35
35
|
method: :delete
|
36
|
-
uri:
|
36
|
+
uri: https://taskrabbitdev.com/api/v1/tasks/22678?
|
37
37
|
body:
|
38
38
|
headers:
|
39
39
|
x-client-application:
|
40
|
-
-
|
40
|
+
- <API_SECRET>
|
41
41
|
authorization:
|
42
|
-
- OAuth
|
42
|
+
- OAuth <USER_WITH_CARD>
|
43
43
|
response: !ruby/struct:VCR::Response
|
44
44
|
status: !ruby/struct:VCR::ResponseStatus
|
45
45
|
code: 200
|
@@ -1,32 +1,47 @@
|
|
1
|
-
---
|
2
|
-
- !ruby/struct:VCR::HTTPInteraction
|
3
|
-
request: !ruby/struct:VCR::Request
|
1
|
+
---
|
2
|
+
- !ruby/struct:VCR::HTTPInteraction
|
3
|
+
request: !ruby/struct:VCR::Request
|
4
4
|
method: :get
|
5
|
-
uri:
|
5
|
+
uri: https://taskrabbitdev.com/api/v1/tasks/52?include[task][]=errors&include[task][]=links&include[task][]=error&include[task][]=id&include[task][]=name&include[task][]=user&include[task][]=runner&include[task][]=runners&include[task][]=named_price&include[task][]=charge_price&include[task][]=cost_in_cents&include[task][]=number_runners_to_fill&include[task][]=state_label&include[task][]=city_id&include[task][]=city&include[task][]=description&include[task][]=private_description&include[task][]=private_runner&include[task][]=virtual&include[task][]=state&include[task][]=assignment_type&include[task][]=complete_by_time&include[task][]=state_changed_at&include[task][]=assign_by_time&include[task][]=location_visits&include[task][]=offers&include[task][]=other_locations_attributes&include[task][]=uploaded_photos_attributes&include[task][]=uploaded_sounds_attributes
|
6
6
|
body:
|
7
|
-
headers:
|
8
|
-
x-client-application:
|
9
|
-
-
|
10
|
-
authorization:
|
7
|
+
headers:
|
8
|
+
x-client-application:
|
9
|
+
- <API_SECRET>
|
10
|
+
authorization:
|
11
11
|
- OAuth
|
12
|
-
response: !ruby/struct:VCR::Response
|
13
|
-
status: !ruby/struct:VCR::ResponseStatus
|
12
|
+
response: !ruby/struct:VCR::Response
|
13
|
+
status: !ruby/struct:VCR::ResponseStatus
|
14
14
|
code: 200
|
15
15
|
message: OK
|
16
|
-
headers:
|
17
|
-
|
18
|
-
-
|
19
|
-
|
16
|
+
headers:
|
17
|
+
server:
|
18
|
+
- nginx/1.0.11
|
19
|
+
date:
|
20
|
+
- Wed, 12 Sep 2012 23:03:41 GMT
|
21
|
+
content-type:
|
20
22
|
- application/json; charset=utf-8
|
21
|
-
|
22
|
-
-
|
23
|
-
|
24
|
-
-
|
25
|
-
|
26
|
-
-
|
27
|
-
|
28
|
-
- "
|
29
|
-
|
30
|
-
-
|
31
|
-
|
32
|
-
|
23
|
+
status:
|
24
|
+
- 200 OK
|
25
|
+
x-runtime:
|
26
|
+
- '0.128537'
|
27
|
+
content-length:
|
28
|
+
- '1417'
|
29
|
+
etag:
|
30
|
+
- ! '"1f50fdd2204ea47e6340962b9a4e95b5"'
|
31
|
+
x-ua-compatible:
|
32
|
+
- IE=Edge,chrome=1
|
33
|
+
cache-control:
|
34
|
+
- max-age=0, private, must-revalidate
|
35
|
+
body: ! '{"links":{"html":"http://s-app1.taskrabbit.com/tasks/house-cleaning-7091","get":"/api/v1/tasks/52"},"runners":{"items":[]},"user":{"links":{"get":"/api/v1/users/40","avatar_url":"http://s-app1.taskrabbit.com/images/default_avatars/poster_thumb.png"},"friend_code_url":"http://taskrabbit.com/PAL/40","id":40,"short_name":"UserWith","display_name":"UserWith
|
36
|
+
c.","city":{"lat":37.77493,"links":{"get":"/api/v1/cities/3"},"id":1053,"name":"SF
|
37
|
+
Bay Area","lng":-122.419416},"full_name":"UserWith c."},"cost_in_cents":0,"id":52,"state_changed_at":1347490579,"description":"I
|
38
|
+
need to clean my house","city":{"links":{"get":"/api/v1/cities/3"},"lat":37.77493,"id":1053,"lng":-122.419416,"name":"SF
|
39
|
+
Bay Area"},"assign_by_time":1347577200,"name":"House Cleaning","state_label":"posted","complete_by_time":1347663600,"description_properties":[{"value":"I
|
40
|
+
need to clean my house","key":"description","title":"Description"},{"value":"Regular
|
41
|
+
Maintenance","key":"task_field_16","title":"Level of cleaning"},{"value":"Multiple
|
42
|
+
Rooms, 1 Bathroom","key":"task_field_17","title":"Size of house"},{"value":"Cleaning
|
43
|
+
supplies are already in the house","key":"task_field_18","title":"Do you have
|
44
|
+
all the necessary cleaning supplies at your house"},{"value":1347577200,"key":"assign_by_time","title":"If
|
45
|
+
unassigned, Task will expire on"},{"value":1347663600,"key":"complete_by_time","title":"Task
|
46
|
+
should be completed by"}],"state":"opened"}'
|
47
|
+
http_version: '1.1'
|
@@ -1,32 +1,47 @@
|
|
1
|
-
---
|
2
|
-
- !ruby/struct:VCR::HTTPInteraction
|
3
|
-
request: !ruby/struct:VCR::Request
|
1
|
+
---
|
2
|
+
- !ruby/struct:VCR::HTTPInteraction
|
3
|
+
request: !ruby/struct:VCR::Request
|
4
4
|
method: :get
|
5
|
-
uri:
|
5
|
+
uri: https://taskrabbitdev.com/api/v1/tasks/52?include[task][]=errors&include[task][]=links&include[task][]=error&include[task][]=id&include[task][]=name&include[task][]=user&include[task][]=runner&include[task][]=runners&include[task][]=named_price&include[task][]=charge_price&include[task][]=cost_in_cents&include[task][]=number_runners_to_fill&include[task][]=state_label&include[task][]=city_id&include[task][]=city&include[task][]=description&include[task][]=private_description&include[task][]=private_runner&include[task][]=virtual&include[task][]=state&include[task][]=assignment_type&include[task][]=complete_by_time&include[task][]=state_changed_at&include[task][]=assign_by_time&include[task][]=location_visits&include[task][]=offers&include[task][]=other_locations_attributes&include[task][]=uploaded_photos_attributes&include[task][]=uploaded_sounds_attributes
|
6
6
|
body:
|
7
|
-
headers:
|
8
|
-
x-client-application:
|
9
|
-
-
|
10
|
-
authorization:
|
7
|
+
headers:
|
8
|
+
x-client-application:
|
9
|
+
- <API_SECRET>
|
10
|
+
authorization:
|
11
11
|
- OAuth
|
12
|
-
response: !ruby/struct:VCR::Response
|
13
|
-
status: !ruby/struct:VCR::ResponseStatus
|
12
|
+
response: !ruby/struct:VCR::Response
|
13
|
+
status: !ruby/struct:VCR::ResponseStatus
|
14
14
|
code: 200
|
15
15
|
message: OK
|
16
|
-
headers:
|
17
|
-
|
18
|
-
-
|
19
|
-
|
16
|
+
headers:
|
17
|
+
server:
|
18
|
+
- nginx/1.0.11
|
19
|
+
date:
|
20
|
+
- Wed, 12 Sep 2012 23:03:40 GMT
|
21
|
+
content-type:
|
20
22
|
- application/json; charset=utf-8
|
21
|
-
|
22
|
-
-
|
23
|
-
|
24
|
-
-
|
25
|
-
|
26
|
-
-
|
27
|
-
|
28
|
-
- "
|
29
|
-
|
30
|
-
-
|
31
|
-
|
32
|
-
|
23
|
+
status:
|
24
|
+
- 200 OK
|
25
|
+
x-runtime:
|
26
|
+
- '0.152650'
|
27
|
+
content-length:
|
28
|
+
- '1417'
|
29
|
+
etag:
|
30
|
+
- ! '"1f50fdd2204ea47e6340962b9a4e95b5"'
|
31
|
+
x-ua-compatible:
|
32
|
+
- IE=Edge,chrome=1
|
33
|
+
cache-control:
|
34
|
+
- max-age=0, private, must-revalidate
|
35
|
+
body: ! '{"links":{"html":"http://s-app1.taskrabbit.com/tasks/house-cleaning-7091","get":"/api/v1/tasks/52"},"runners":{"items":[]},"user":{"links":{"get":"/api/v1/users/40","avatar_url":"http://s-app1.taskrabbit.com/images/default_avatars/poster_thumb.png"},"friend_code_url":"http://taskrabbit.com/PAL/40","id":40,"short_name":"UserWith","display_name":"UserWith
|
36
|
+
c.","city":{"lat":37.77493,"links":{"get":"/api/v1/cities/3"},"id":1053,"name":"SF
|
37
|
+
Bay Area","lng":-122.419416},"full_name":"UserWith c."},"cost_in_cents":0,"id":52,"state_changed_at":1347490579,"description":"I
|
38
|
+
need to clean my house","city":{"links":{"get":"/api/v1/cities/3"},"lat":37.77493,"id":1053,"lng":-122.419416,"name":"SF
|
39
|
+
Bay Area"},"assign_by_time":1347577200,"name":"House Cleaning","state_label":"posted","complete_by_time":1347663600,"description_properties":[{"value":"I
|
40
|
+
need to clean my house","key":"description","title":"Description"},{"value":"Regular
|
41
|
+
Maintenance","key":"task_field_16","title":"Level of cleaning"},{"value":"Multiple
|
42
|
+
Rooms, 1 Bathroom","key":"task_field_17","title":"Size of house"},{"value":"Cleaning
|
43
|
+
supplies are already in the house","key":"task_field_18","title":"Do you have
|
44
|
+
all the necessary cleaning supplies at your house"},{"value":1347577200,"key":"assign_by_time","title":"If
|
45
|
+
unassigned, Task will expire on"},{"value":1347663600,"key":"complete_by_time","title":"Task
|
46
|
+
should be completed by"}],"state":"opened"}'
|
47
|
+
http_version: '1.1'
|
@@ -2,13 +2,13 @@
|
|
2
2
|
- !ruby/struct:VCR::HTTPInteraction
|
3
3
|
request: !ruby/struct:VCR::Request
|
4
4
|
method: :post
|
5
|
-
uri:
|
5
|
+
uri: https://taskrabbitdev.com/api/v1/tasks?
|
6
6
|
body: task[name]=My%20First%20Task&task[named_price]=20&task[city_id]=4
|
7
7
|
headers:
|
8
8
|
x-client-application:
|
9
|
-
-
|
9
|
+
- <API_SECRET>
|
10
10
|
authorization:
|
11
|
-
- OAuth
|
11
|
+
- OAuth <USER_WITH_CARD>
|
12
12
|
response: !ruby/struct:VCR::Response
|
13
13
|
status: !ruby/struct:VCR::ResponseStatus
|
14
14
|
code: 200
|
@@ -33,13 +33,13 @@
|
|
33
33
|
- !ruby/struct:VCR::HTTPInteraction
|
34
34
|
request: !ruby/struct:VCR::Request
|
35
35
|
method: :get
|
36
|
-
uri:
|
36
|
+
uri: https://taskrabbitdev.com/api/v1/tasks/22679?include[task][]=errors&include[task][]=links&include[task][]=error&include[task][]=id&include[task][]=name&include[task][]=user&include[task][]=runner&include[task][]=runners&include[task][]=named_price&include[task][]=charge_price&include[task][]=cost_in_cents&include[task][]=number_runners_to_fill&include[task][]=state_label&include[task][]=city_id&include[task][]=city&include[task][]=description&include[task][]=private_description&include[task][]=private_runner&include[task][]=virtual&include[task][]=state&include[task][]=assignment_type&include[task][]=complete_by_time&include[task][]=state_changed_at&include[task][]=assign_by_time&include[task][]=location_visits&include[task][]=offers&include[task][]=other_locations_attributes&include[task][]=uploaded_photos_attributes&include[task][]=uploaded_sounds_attributes
|
37
37
|
body:
|
38
38
|
headers:
|
39
39
|
x-client-application:
|
40
|
-
-
|
40
|
+
- <API_SECRET>
|
41
41
|
authorization:
|
42
|
-
- OAuth
|
42
|
+
- OAuth <USER_WITH_CARD>
|
43
43
|
response: !ruby/struct:VCR::Response
|
44
44
|
status: !ruby/struct:VCR::ResponseStatus
|
45
45
|
code: 200
|
@@ -2,13 +2,13 @@
|
|
2
2
|
- !ruby/struct:VCR::HTTPInteraction
|
3
3
|
request: !ruby/struct:VCR::Request
|
4
4
|
method: :post
|
5
|
-
uri:
|
5
|
+
uri: https://taskrabbitdev.com/api/v1/tasks?
|
6
6
|
body: task[name]=My%20First%20Task&task[named_price]=20&task[city_id]=4
|
7
7
|
headers:
|
8
8
|
x-client-application:
|
9
|
-
-
|
9
|
+
- <API_SECRET>
|
10
10
|
authorization:
|
11
|
-
- OAuth
|
11
|
+
- OAuth <USER_WITH_CARD>
|
12
12
|
response: !ruby/struct:VCR::Response
|
13
13
|
status: !ruby/struct:VCR::ResponseStatus
|
14
14
|
code: 200
|
@@ -33,13 +33,13 @@
|
|
33
33
|
- !ruby/struct:VCR::HTTPInteraction
|
34
34
|
request: !ruby/struct:VCR::Request
|
35
35
|
method: :put
|
36
|
-
uri:
|
36
|
+
uri: https://taskrabbitdev.com/api/v1/tasks/22680?
|
37
37
|
body: name=New%20Name&id=22680
|
38
38
|
headers:
|
39
39
|
x-client-application:
|
40
|
-
-
|
40
|
+
- <API_SECRET>
|
41
41
|
authorization:
|
42
|
-
- OAuth
|
42
|
+
- OAuth <USER_WITH_CARD>
|
43
43
|
response: !ruby/struct:VCR::Response
|
44
44
|
status: !ruby/struct:VCR::ResponseStatus
|
45
45
|
code: 200
|