npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

basecamp-api-v3

v1.0.3

Published

This TypeScript library provides an API wrapper for interacting with Basecamp resources, including People, Projects, Todo Sets, Todo Lists, Comments, and Authorization.

Downloads

6

Readme

Basecamp API V3

This TypeScript library provides an API wrapper for interacting with Basecamp resources, including People, Projects, Todo Sets, Todo Lists, Comments, and Authorization.

Installation

You can install the library using npm or yarn:

  npm install basecamp-api-v3

or with yarn:

  yarn add basecamp-api-v3

Import Modules

import {
  Authorization,
  People,
  Projects,
  Todosets,
  Todolists,
  TodolistsGroups,
  Todos,
  Comments
} from 'basecamp-api-v3'

Usage/Examples

Authorization

Generate Code by Basecamp Login

const params = {
  url: 'basecamp_url',
  email: '[email protected]',
  password: 'password123',
  sphereKey: 'sphere_key'
}

const response = await Authorization.generateCodeByBasecampLogin(params)

Generate Access Token by Code

const params = {
  clientId: 'client_id',
  clientSecret: 'client_secret',
  code: 'auth_code',
  redirectUri: 'redirect_url'
}

const response = await Authorization.generateAccessTokenByCode(params)

Generate Access Token by Refresh Token

const params = {
  clientId: 'client_id',
  clientSecret: 'client_secret',
  refreshToken: 'refresh_token'
}

const response = await Authorization.generateAccessTokenByRefreshToken(params)

People

Get All People

const params = {
  accountId: 'account_id',
  authorization: 'Bearer token'
}

const response = await People.getAllPeople(params)

Get People on a Project

const params = {
  accountId: 'account_id',
  authorization: 'Bearer token',
  projectId: 'project_id'
}

const response = await People.getPeopleOnAProject(params)

Get Pingable People

const params = {
  accountId: 'account_id',
  authorization: 'Bearer token',
}

const response = await People.getPingablePeople(params)

Get My Personal Info

const params = {
  accountId: 'account_id',
  authorization: 'Bearer token',
}

const response = await People.getMyPersonalInfo(params)

Get Person

const params = {
  accountId: 'account_id',
  authorization: 'Bearer token',
  peopleId: 'people_id'
}

const response = await People.getPerson(params)

Projects

Get All Projects

const params = {
  accountId: 'account_id',
  authorization: 'Bearer token',
  status: ''
}

const response = await Projects.getAllProjects(params)

Get A Project

const params = {
  accountId: 'account_id',
  authorization: 'Bearer token',
  projectId: 'project_id'
}

const response = await Projects.getAProject(params)

Todosets

Get A Todoset

const params = {
  accountId: 'account_id',
  authorization: 'Bearer token',
  projectId: 'project_id',
  todosetId: 'todoset_id
}

const response = await Todosets.getTodoset(params)

Todolists

Get All Todolists

const params = {
  accountId: 'account_id',
  authorization: 'Bearer token',
  projectId: 'project_id',
  todosetId: 'todoset_id'
}

const response = await Todolists.getTodolists(params)

Get A Todolist

const params = {
  accountId: 'account_id',
  authorization: 'Bearer token',
  projectId: 'project_id',
  todolistId: 'todolist_id'
}

const response = await Todolists.getATodolist(params)

Create A Todolist

const params = {
  accountId: 'account_id',
  authorization: 'Bearer token',
  projectId: 'project_id',
  todosetId: 'todoset_id',
  name: 'Todolist Name',
  description: 'Todolist Description'
}

const response = await Todolists.createATodolist(params)

Update A Todolist

const params = {
  accountId: 'account_id',
  authorization: 'Bearer token',
  projectId: 'project_id',
  todolistId: 'todolist_id',
  name: 'Todolist Name',
  description: 'Todolist Description'
}

const response = await Todolists.updateATodolist(params)

TodolistsGroups

Get All Todolist Groups

const params = {
  accountId: 'account_id',
  authorization: 'Bearer token',
  projectId: 'project_id',
  todolistId: 'todolist_id',
}

const response = await TodolistsGroups.listTodolistGroups(params)

Get A Todolist Group

const params = {
  accountId: 'account_id',
  authorization: 'Bearer token',
  projectId: 'project_id',
  todolistId: 'todolist_id',
}

const response = await TodolistsGroups.getATodolistGroup(params)

Create A Todolist Group

const params = {
  accountId: 'account_id',
  authorization: 'Bearer token',
  projectId: 'project_id',
  todolistId: 'todolist_id',
  name: 'Todolist Group Name',
  color: 'Todolist Color'
}

const response = await TodolistsGroups.createATodolistGroup(params)

Todos

Get All Todos

const params = {
  accountId: 'account_id',
  authorization: 'Bearer token',
  projectId: 'project_id',
  todolistId: 'todolist_id',
  status: 'status',
  completed: completed
}

const response = await Todos.getTodos(params)

Get A Todo

const params = {
  accountId: 'account_id',
  authorization: 'Bearer token',
  projectId: 'project_id',
  todoId: 'todo_id',
}

const response = await Todos.getATodo(params)

Create A Todo

const params = {
  accountId: 'account_id',
  authorization: 'Bearer token',
  projectId: 'project_id',
  todolistId: 'todolist_id',
  content: 'Todo Title',
  description: 'Todo Description',
  assignee_ids: ['assignee_id'],
  completion_subscriber_ids: ['completion_subscriber_ids'],
  notify: true,
  due_on: 'MM/DD/YYYY',
  starts_on: 'MM/DD/YYYY',
}

const response = await Todos.createATodo(params)

Update A Todo

const params = {
  accountId: 'account_id',
  authorization: 'Bearer token',
  projectId: 'project_id',
  todoId: 'todo_id',
  content: 'Todo Title',
  description: 'Todo Description',
  assignee_ids: ['assignee_id'],
  completion_subscriber_ids: ['completion_subscriber_ids'],
  notify: true,
  due_on: 'MM/DD/YYYY',
  starts_on: 'MM/DD/YYYY',
}

const response = await Todos.updateATodo(params)

Complete A Todo

const params = {
  accountId: 'account_id',
  authorization: 'Bearer token',
  projectId: 'project_id',
  todoId: 'todo_id',
}

const response = await Todos.completeATodo(params)

Uncomplete A Todo

const params = {
  accountId: 'account_id',
  authorization: 'Bearer token',
  projectId: 'project_id',
  todoId: 'todo_id',
}

const response = await Todos.uncompleteATodo(params)

Reposition A Todo

const params = {
  accountId: 'account_id',
  authorization: 'Bearer token',
  projectId: 'project_id',
  todoId: 'todo_id',
  position: 1
}

const response = await Todos.repositionATodo(params)

Comments

Get All Comments

const params = {
  accountId: 'account_id',
  authorization: 'Bearer token',
  projectId: 'project_id',
  recordingId: 'recording_id'
}

const response = await Comments.getComments(params)

Get a Specific Comment

const params = {
  accountId: 'account_id',
  authorization: 'Bearer token',
  projectId: 'project_id',
  commentId: 'comment_id'
}

const response = await Comments.getAComment(params)

Create a Comment

const params = {
  accountId: 'account_id',
  authorization: 'Bearer token',
  projectId: 'project_id',
  recordingId: 'recording_id',
  content: 'Comment'
}

const response = await Comments.createAComment(params)

Update a Comment

const params = {
  accountId: 'account_id',
  authorization: 'Bearer token',
  projectId: 'project_id',
  commentId: 'comment_id',
  content: 'Updated comment'
}

const response = await Comments.updateAComment(params)

Error Handling

All functions return a response object with success, status, data, and message fields for easier error handling.

License

MIT

Authors

Support

If you find this project helpful, consider supporting it!

Donate with PayPal

Or donate directly via PayPal: https://www.paypal.me/SirTim21