GET / jobs /: id / tasks (specified has made the task)

GET / jobs /: id / tasks (specified has made the task)

Introduction

When publishing tasks later, this API allows the requestor can view the tasks arising from specified work state, workers get the results submitted and decided according to the results of the work specified approve or reject the specified work.

HTTP Request

URL

https://api.crowdsdom.com/v1/jobs/:id/tasks

HTTP Method

GET

HTTP Header

Content-Type: application/json
Authorization: YOUR_ACCESS_TOKEN

parameter

URL

The following parameters directly on the URL http request.

name description Type Default Required
id To obtain the specified work tasks unique identification number String None Yes

Reply

If http request successfully obtained a list of specified work tasks will be returned status code: 200 and a designated work array.
If not successful, the system will return to the code and the cause of the error.

Examples

Python requests to directly call the API interface as an example:

request

1
2
3
4
5
6
7
8

import requests

API_URL = 'https://api.crowdsdom.com/v1/jobs/507f191e810c19729de860ea/tasks'

headers = {'Authorization': 'YOUR_ACCESS_TOKEN'}

response = requests.get(API_URL, headers=headers)

Reply

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52

[
{
id: '507f191e810c19729devxbbx',
status: 'submitted',
expirationTime: "Mon Oct 26 2015 07:17:24 GMT+0800 (CST)",
rejectionTime: null,
approvalTime: null,
submitTime: "Mon Oct 26 2015 07:17:24 GMT+0800 (CST)",
acceptTime: "Mon Oct 26 2015 07:17:24 GMT+0800 (CST)",
deadline: ,
answers: [
{
questionId: 'sentiment',
answer: ['neutral']

}
],
jobId: '507f191e810c19729de860ea',
contributorId: '507f191e810c19729de8adfaf'
},
{
id: '507f191e810c19bcvbfghbcv',
status: 'approved',
expirationTime: "Mon Oct 26 2015 07:17:24 GMT+0800 (CST)",
rejectionTime: null,
approvalTime: "Mon Oct 26 2015 07:17:24 GMT+0800 (CST)",
submitTime: "Mon Oct 26 2015 07:17:24 GMT+0800 (CST)",
acceptTime: "Mon Oct 26 2015 07:17:24 GMT+0800 (CST)",
answers: [
{
questionId: 'sentiment',
answer: ['positive']

}
],
jobId: '507f191e810c19729de860ea',
contributorId: '507f191e810c19729dgdfbvb'
},
{
id: '507f191e810c197dgdsfgrthgf',
status: 'init',
expirationTime: "Mon Oct 26 2015 07:17:24 GMT+0800 (CST)",
rejectionTime: null,
approvalTime: null,
submitTime: null,
acceptTime: "Mon Oct 26 2015 07:17:24 GMT+0800 (CST)",
jobId: '507f191e810c19729de860ea',
contributorId: '507f191e810c19729xvbxaf'
}

]

Original: Large column  GET / jobs /: id / tasks ( specified has made the task)


Guess you like

Origin www.cnblogs.com/wangziqiang123/p/11618459.html