Welcome to the unofficial Node.js API for Reclaim.ai! This library is designed to help you interact with the Reclaim.ai API in your Node.js applications. Please note that this library is not officially supported by Reclaim.ai and was reverse engineered for educational purposes.
First, install the library using npm:
npm install reclaim-unofficial-api
Then, you can import the ReclaimClient
from the library:
import { ReclaimClient } from 'reclaim-unofficial-api';
You'll need to provide an access token either in the .env file or when creating a new ReclaimClient
instance:
const client = new ReclaimClient({ accessToken: 'your-access-token' });
You can get an access token in the Reclaim.ai web app by going here.
The ReclaimClient
provides access to various modules:
client.tasks
: Interact with tasks in Reclaim.ai.client.habits
: Interact with habits in Reclaim.ai.client.users
: Interact with users in Reclaim.ai.client.calendars
: Interact with calendars in Reclaim.ai.client.analytics
: Interact with analytics in Reclaim.ai.
Each module provides methods for interacting with the respective resources in the Reclaim.ai API.
Method | Description | Status |
---|---|---|
search |
Search for tasks. | β |
create |
Create a new task. | β |
get |
Get an existing task. | β |
update |
Update an existing task. | β |
delete |
Delete an existing task. | β |
markComplete |
Mark a task as complete. | β |
Method | Description | Status |
---|---|---|
search |
Search for habits. | β |
create |
Create a new habit. | β |
get |
Get an existing habit. | β |
update |
Update an existing habit. | β |
delete |
Delete an existing habit. | β |
Method | Description | Status |
---|---|---|
current |
Get the current user. | β |
update |
Update the current user. | β |
Method | Description | Status |
---|---|---|
primary |
Get the primary calendar. | β |
Method | Description | Status |
---|---|---|
get |
Get analytics. | β |
More methods will be added in the future. If you need a specific method, please open an issue or submit a pull request!
const tasks = await client.tasks.search();
const tasks = await client.tasks.search({ title: 'My Ticket' });
const task = await client.tasks.create({
title: "My Ticket",
eventColor: null,
eventCategory: "WORK",
timeChunksRequired: 8,
minChunkSize: 4,
maxChunkSize: 8,
alwaysPrivate: true,
timeSchemeId: "989b3027-46c4-4729-bdec-1070fc4d8c0f",
priority: "P2",
snoozeUntil: "2029-11-17T06:00:00.000Z",
due: "2029-11-21T16:30:00.000Z",
onDeck: false,
});
const task = await client.tasks.update(12345, {
title: "My Updated Ticket",
});
const task = await client.tasks.delete(12345);
const analytics = await client.analytics.get({ start: "2021-01-01", end: "2021-01-31", metricName: [ "DURATION_BY_CATEGORY", "DURATION_BY_DATE_BY_CATEGORY" ] });
const user = await client.users.current();
Check out the examples directory for more examples.
This library was reverse engineered from the Reclaim.ai API and may be incomplete or inaccurate. Use at your own risk.
Every 12 hours a Github Action runs to test the library against the Reclaim.ai API. If the tests fail, the library may be out of date. Please open an issue or submit a pull request if you notice any issues. Thanks!
Big thanks to the author of the reclaim-sdk Python library for reverse engineering the Reclaim.ai API β your work inspired this library! π
This project is licensed under the terms of the MIT license. See the LICENSE file for details.