toggl_api 0.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/.gitignore +17 -0
- data/Gemfile +4 -0
- data/LICENSE +20 -0
- data/LICENSE.txt +22 -0
- data/README.md +48 -0
- data/Rakefile +1 -0
- data/lib/toggl_api.rb +7 -0
- data/lib/toggl_api/api/client.rb +42 -0
- data/lib/toggl_api/api/project.rb +46 -0
- data/lib/toggl_api/api/project_user.rb +38 -0
- data/lib/toggl_api/api/tag.rb +24 -0
- data/lib/toggl_api/api/task.rb +38 -0
- data/lib/toggl_api/api/time_entry.rb +73 -0
- data/lib/toggl_api/api/user.rb +46 -0
- data/lib/toggl_api/api/workspace.rb +36 -0
- data/lib/toggl_api/api/workspace_user.rb +32 -0
- data/lib/toggl_api/base.rb +39 -0
- data/lib/toggl_api/error.rb +8 -0
- data/lib/toggl_api/report.rb +30 -0
- data/lib/toggl_api/request.rb +100 -0
- data/lib/toggl_api/version.rb +3 -0
- data/test/base_test.rb +38 -0
- data/test/fixtures/authentication.json +44 -0
- data/test/fixtures/bulk_update_tasks.json +24 -0
- data/test/fixtures/bulk_update_time_entries.json +29 -0
- data/test/fixtures/client.json +11 -0
- data/test/fixtures/client_projects.json +21 -0
- data/test/fixtures/clients.json +15 -0
- data/test/fixtures/create_client.json +8 -0
- data/test/fixtures/create_project.json +13 -0
- data/test/fixtures/create_project_user.json +0 -0
- data/test/fixtures/create_tag.json +7 -0
- data/test/fixtures/create_task.json +10 -0
- data/test/fixtures/create_time_entry.json +13 -0
- data/test/fixtures/invite_users_to_workspace.json +12 -0
- data/test/fixtures/project.json +13 -0
- data/test/fixtures/project_users.json +18 -0
- data/test/fixtures/relations_of_workspace_and_user.json +22 -0
- data/test/fixtures/report_failure.json +8 -0
- data/test/fixtures/report_success.json +6 -0
- data/test/fixtures/reset_api_token.json +2 -0
- data/test/fixtures/signup.json +19 -0
- data/test/fixtures/start_time_entry.json +13 -0
- data/test/fixtures/stop_time_entry.json +13 -0
- data/test/fixtures/task.json +10 -0
- data/test/fixtures/time_entries.json +24 -0
- data/test/fixtures/time_entry.json +15 -0
- data/test/fixtures/update_client.json +9 -0
- data/test/fixtures/update_project.json +12 -0
- data/test/fixtures/update_project_user.json +0 -0
- data/test/fixtures/update_tag.json +7 -0
- data/test/fixtures/update_task.json +13 -0
- data/test/fixtures/update_time_entry.json +15 -0
- data/test/fixtures/update_user.json +31 -0
- data/test/fixtures/update_workspace_user.json +9 -0
- data/test/fixtures/workspace_clients.json +19 -0
- data/test/fixtures/workspace_projects.json +21 -0
- data/test/fixtures/workspace_tasks.json +29 -0
- data/test/fixtures/workspace_users.json +47 -0
- data/test/fixtures/workspaces.json +12 -0
- data/test/helper.rb +10 -0
- data/test/test_client.rb +51 -0
- data/test/test_project.rb +94 -0
- data/test/test_report.rb +53 -0
- data/test/test_tag.rb +30 -0
- data/test/test_task.rb +51 -0
- data/test/test_time_entry.rb +69 -0
- data/test/test_user.rb +53 -0
- data/test/test_workspace.rb +72 -0
- data/toggl_api.gemspec +30 -0
- metadata +260 -0
|
File without changes
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
{
|
|
2
|
+
"data":{[
|
|
3
|
+
"id":3511220,
|
|
4
|
+
"uid":35934278,
|
|
5
|
+
"wid":777,
|
|
6
|
+
"admin":false,
|
|
7
|
+
"active":false,
|
|
8
|
+
"email":"jane.swift@toggl.com",
|
|
9
|
+
"invite_url":"https://toggl.com/user/accept_invitation?code=ec2876e421234dfasd0fa1c55370d3940"
|
|
10
|
+
]},
|
|
11
|
+
"notifications":["To add more users you have to Upgrade"]
|
|
12
|
+
}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
[
|
|
2
|
+
{
|
|
3
|
+
"id":3123855,
|
|
4
|
+
"uid":35224123,
|
|
5
|
+
"wid":777,
|
|
6
|
+
"admin":false,
|
|
7
|
+
"active":false,
|
|
8
|
+
"email":"John@toggl.com",
|
|
9
|
+
"at":"2013-05-17T16:50:36+03:00",
|
|
10
|
+
"name":"John Swift",
|
|
11
|
+
"invite_url":"https://toggl.com/user/accept_invitation?code=fb3ad3db5dasd123c2b529e3a519826"
|
|
12
|
+
},{
|
|
13
|
+
"id":200066,
|
|
14
|
+
"uid":21961,
|
|
15
|
+
"wid":777,
|
|
16
|
+
"admin":true,
|
|
17
|
+
"active":true,
|
|
18
|
+
"email":"Jane@toggl.com",
|
|
19
|
+
"at":"2012-04-11T22:59:33+03:00",
|
|
20
|
+
"name":"Jane"
|
|
21
|
+
}
|
|
22
|
+
]
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
{
|
|
2
|
+
"data":{
|
|
3
|
+
"id":599978901,
|
|
4
|
+
"api_token":"808lolae4eab897cce9729a53642124effe",
|
|
5
|
+
"default_wid":983493,
|
|
6
|
+
"email":"test.user@toggl.com",
|
|
7
|
+
"fullname":"Test User",
|
|
8
|
+
"jquery_timeofday_format":"",
|
|
9
|
+
"jquery_date_format":"",
|
|
10
|
+
"timeofday_format":"",
|
|
11
|
+
"date_format":"",
|
|
12
|
+
"store_start_and_stop_time":false,
|
|
13
|
+
"beginning_of_week":0,
|
|
14
|
+
"sidebar_piechart":false,
|
|
15
|
+
"timeline_experiment":false,
|
|
16
|
+
"new_blog_post":{},
|
|
17
|
+
"invitation":{}
|
|
18
|
+
}
|
|
19
|
+
}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
[
|
|
2
|
+
{
|
|
3
|
+
"id":436691234,
|
|
4
|
+
"wid":777,
|
|
5
|
+
"pid":123,
|
|
6
|
+
"billable":true,
|
|
7
|
+
"start":"2013-03-11T11:36:00+00:00",
|
|
8
|
+
"stop":"2013-03-11T15:36:00+00:00",
|
|
9
|
+
"duration":14400,
|
|
10
|
+
"description":"Meeting with the client",
|
|
11
|
+
"tags":[""],
|
|
12
|
+
"at":"2013-03-11T15:36:58+00:00"
|
|
13
|
+
},{
|
|
14
|
+
"id":436776436,
|
|
15
|
+
"wid":777,
|
|
16
|
+
"billable":false,
|
|
17
|
+
"start":"2013-03-12T10:32:43+00:00",
|
|
18
|
+
"stop":"2013-03-12T14:32:43+00:00",
|
|
19
|
+
"duration":18400,
|
|
20
|
+
"description":"important work",
|
|
21
|
+
"tags":[""],
|
|
22
|
+
"at":"2013-03-12T14:32:43+00:00"
|
|
23
|
+
}
|
|
24
|
+
]
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
{
|
|
2
|
+
"data":{
|
|
3
|
+
"id":436694100,
|
|
4
|
+
"wid":777,
|
|
5
|
+
"pid":193791,
|
|
6
|
+
"tid":13350500,
|
|
7
|
+
"billable":false,
|
|
8
|
+
"start":"2013-02-27T01:24:00+00:00",
|
|
9
|
+
"stop":"2013-02-27T07:24:00+00:00",
|
|
10
|
+
"duration":21600,
|
|
11
|
+
"description":"Some serious work",
|
|
12
|
+
"tags":["billed"],
|
|
13
|
+
"at":"2013-02-27T13:49:18+00:00"
|
|
14
|
+
}
|
|
15
|
+
}
|
|
File without changes
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
{
|
|
2
|
+
"data":
|
|
3
|
+
{
|
|
4
|
+
"id":436694100,
|
|
5
|
+
"pid":123,
|
|
6
|
+
"wid":777,
|
|
7
|
+
"billable":false,
|
|
8
|
+
"start":"2013-03-05T07:58:58.000Z",
|
|
9
|
+
"stop":"2013-03-05T08:58:58.000Z",
|
|
10
|
+
"duration":1240,
|
|
11
|
+
"description":"Meeting with possible clients",
|
|
12
|
+
"billable": true,
|
|
13
|
+
"at": "2013-03-05T12:34:50+00:00"
|
|
14
|
+
}
|
|
15
|
+
}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
{
|
|
2
|
+
"data":{
|
|
3
|
+
"id":123123123,
|
|
4
|
+
"api_token":"1971800d4d82861d8f2c1651fea4d212",
|
|
5
|
+
"default_wid":777,
|
|
6
|
+
"email":"john@toggl.com",
|
|
7
|
+
"fullname":"John Smith",
|
|
8
|
+
"jquery_timeofday_format":"h:i A",
|
|
9
|
+
"jquery_date_format":"d.m.Y",
|
|
10
|
+
"timeofday_format":"h:mm A",
|
|
11
|
+
"date_format":"DD.MM.YYYY",
|
|
12
|
+
"store_start_and_stop_time":true,
|
|
13
|
+
"beginning_of_week":1,
|
|
14
|
+
"language":"en_US",
|
|
15
|
+
"image_url":"https://www.toggl.com/system/avatars/9000/small/open-uri20121116-2767-b1qr8l.png",
|
|
16
|
+
"sidebar_piechart":false,
|
|
17
|
+
"at":"2013-08-12T11:55:58+03:00",
|
|
18
|
+
"retention":9,
|
|
19
|
+
"record_timeline":true,
|
|
20
|
+
"render_timeline":true,
|
|
21
|
+
"timeline_enabled":true,
|
|
22
|
+
"timeline_experiment":true,
|
|
23
|
+
"new_blog_post":{},
|
|
24
|
+
"timezone":"Europe/Tallinn",
|
|
25
|
+
"openid_enabled":true,
|
|
26
|
+
"send_product_emails":true,
|
|
27
|
+
"send_weekly_report":true,
|
|
28
|
+
"send_timer_notifications":true,
|
|
29
|
+
"invitation":{}
|
|
30
|
+
}
|
|
31
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
[
|
|
2
|
+
{
|
|
3
|
+
"id":123,
|
|
4
|
+
"wid":777,
|
|
5
|
+
"name":"Rising Start-Up",
|
|
6
|
+
"at":"2013-03-06T09:06:13+00:00",
|
|
7
|
+
"notes":"Arrange a discount for them",
|
|
8
|
+
"hrate":2,
|
|
9
|
+
"cur":"USD"
|
|
10
|
+
},{
|
|
11
|
+
"id":987,
|
|
12
|
+
"wid":777,
|
|
13
|
+
"name":"Big Company Inc",
|
|
14
|
+
"at":"2013-03-06T09:05:40+00:00",
|
|
15
|
+
"notes":"We had some lovely projects with them",
|
|
16
|
+
"hrate":10,
|
|
17
|
+
"cur":"EUR"
|
|
18
|
+
}
|
|
19
|
+
]
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
[
|
|
2
|
+
{
|
|
3
|
+
"id":909,
|
|
4
|
+
"wid":777,
|
|
5
|
+
"cid":987,
|
|
6
|
+
"name":"Very lucrative project",
|
|
7
|
+
"billable":false,
|
|
8
|
+
"is_private":true,
|
|
9
|
+
"active":true,
|
|
10
|
+
"at":"2013-03-06T09:15:18+00:00"
|
|
11
|
+
},{
|
|
12
|
+
"id":32123,
|
|
13
|
+
"wid":777,
|
|
14
|
+
"cid":123,
|
|
15
|
+
"name":"Factory server infrastructure",
|
|
16
|
+
"billable":true,
|
|
17
|
+
"is_private":true,
|
|
18
|
+
"active":true,
|
|
19
|
+
"at":"2013-03-06T09:16:06+00:00"
|
|
20
|
+
}
|
|
21
|
+
]
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
[
|
|
2
|
+
{
|
|
3
|
+
"name":"SWOT",
|
|
4
|
+
"id":13512097,
|
|
5
|
+
"wid":777,
|
|
6
|
+
"pid":32123,
|
|
7
|
+
"uid":123123,
|
|
8
|
+
"active":true,
|
|
9
|
+
"at":"2013-03-06T09:15:51+00:00",
|
|
10
|
+
"estimated_seconds":7200
|
|
11
|
+
},{
|
|
12
|
+
"name":"development",
|
|
13
|
+
"id":133504498,
|
|
14
|
+
"wid":777,
|
|
15
|
+
"pid":32123,
|
|
16
|
+
"active":true,
|
|
17
|
+
"at":"2013-03-06T09:15:59+00:00",
|
|
18
|
+
"estimated_seconds":0
|
|
19
|
+
},{
|
|
20
|
+
"name":"analyze SEO",
|
|
21
|
+
"id":1335112300,
|
|
22
|
+
"wid":777,
|
|
23
|
+
"pid":909,
|
|
24
|
+
"active":true,
|
|
25
|
+
"at":"2013-03-06T09:18:57+00:00",
|
|
26
|
+
"estimated_seconds":21600
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
]
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
[
|
|
2
|
+
{
|
|
3
|
+
"id":123123,
|
|
4
|
+
"default_wid":777,
|
|
5
|
+
"email":"john@swift.com",
|
|
6
|
+
"fullname":"John Swift",
|
|
7
|
+
"jquery_timeofday_format":"h:i A",
|
|
8
|
+
"jquery_date_format":"m/d/Y",
|
|
9
|
+
"timeofday_format":"h:mm A",
|
|
10
|
+
"date_format":"MM/DD/YYYY",
|
|
11
|
+
"store_start_and_stop_time":true,
|
|
12
|
+
"beginning_of_week":0,
|
|
13
|
+
"language":"en_US",
|
|
14
|
+
"image_url":"https://www.toggl.com/system/avatars/123123/small/open-uri20121116-2767-b1qr8l.png",
|
|
15
|
+
"sidebar_piechart":false,
|
|
16
|
+
"at":"2013-03-06T08:57:12+00:00",
|
|
17
|
+
"retention":9,
|
|
18
|
+
"record_timeline":true,
|
|
19
|
+
"render_timeline":true,
|
|
20
|
+
"timeline_enabled":true,
|
|
21
|
+
"timeline_experiment":true,
|
|
22
|
+
"new_blog_post":{},
|
|
23
|
+
"should_upgrade":true,
|
|
24
|
+
"invitation":{}
|
|
25
|
+
},{
|
|
26
|
+
"id":321321,
|
|
27
|
+
"email":"Happy@worker.com",
|
|
28
|
+
"fullname":"Happy Worker",
|
|
29
|
+
"jquery_timeofday_format":"h:i A",
|
|
30
|
+
"jquery_date_format":"m/d/Y",
|
|
31
|
+
"timeofday_format":"h:mm A",
|
|
32
|
+
"date_format":"MM/DD/YYYY",
|
|
33
|
+
"store_start_and_stop_time":true,
|
|
34
|
+
"beginning_of_week":1,
|
|
35
|
+
"language":"en_US",
|
|
36
|
+
"image_url":"https://www.toggl.com/images/profile.png",
|
|
37
|
+
"sidebar_piechart":false,
|
|
38
|
+
"at":"2013-03-06T08:46:07+00:00",
|
|
39
|
+
"created_at":"2013-03-06T07:52:03+00:00",
|
|
40
|
+
"retention":9,
|
|
41
|
+
"render_timeline":true,
|
|
42
|
+
"timeline_experiment":true,
|
|
43
|
+
"new_blog_post":{},
|
|
44
|
+
"should_upgrade":true,
|
|
45
|
+
"invitation":{}
|
|
46
|
+
}
|
|
47
|
+
]
|