Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/7eggs/node-toggl-api
Toggl API for Node.js
https://github.com/7eggs/node-toggl-api
Last synced: 3 months ago
JSON representation
Toggl API for Node.js
- Host: GitHub
- URL: https://github.com/7eggs/node-toggl-api
- Owner: 7eggs
- License: mit
- Created: 2014-06-03T19:40:23.000Z (over 10 years ago)
- Default Branch: master
- Last Pushed: 2024-05-08T14:29:36.000Z (6 months ago)
- Last Synced: 2024-07-18T02:49:39.832Z (4 months ago)
- Language: JavaScript
- Homepage: http://7eggs.github.io/node-toggl-api/
- Size: 616 KB
- Stars: 120
- Watchers: 8
- Forks: 44
- Open Issues: 5
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
toggl-api
==========[Toggl](https://www.toggl.com/) API for Node.js. Library is based on official Toggl API [documentation](https://github.com/toggl/toggl_api_docs).
## Installation
npm install toggl-api --save
## How to use
```javascript
var TogglClient = require('toggl-api');
var toggl = new TogglClient({apiToken: '1971800d4d82861d8f2c1651fea4d212'});toggl.startTimeEntry({
description: 'Some cool work',
billable: true
}, function(err, timeEntry) {
// handle error// working 10 seconds
setTimeout(function() {
toggl.stopTimeEntry(timeEntry.id, function(err) {
// handle errortoggl.updateTimeEntry(timeEntry.id, {tags: ['finished']}, function(err) {
toggl.destroy()
});
});
}, 120000);
});
```## Documentation
Documentation is available at: [http://7eggs.github.io/node-toggl-api/](http://7eggs.github.io/node-toggl-api/)
## TODO
* TESTS
* Update argument quantity logic on all calls
* Documentation in Markdown format
* Remove custom data validator
* v9 migration
* add support for new endpoints:
* /workspaces/{workspace_id}/clients/{client_id}/archive
* /workspaces/{workspace_id}/clients/{client_id}/restore
* /organizations/{organization_id}/invitations/{invitation_code}/resend
* /organizations/invitations/{invitation_code}/accept
* /organizations/invitations/{invitation_code}/reject