SDKs

Python SDK

Install and use the Dime.Sheets Python client library.

Python SDK

The Python SDK provides a synchronous client for the Dime.Sheets API, built on httpx.

Installation

pip install dimesheets

Quick start

from dimesheets import DimeSheetsClient

client = DimeSheetsClient(api_key="your-api-key")

projects = client.projects.get_all()
for project in projects:
    print(f"{project.external_id}: {project.name}")

Configuration

ParameterTypeDefaultDescription
api_keystr--API key for authentication
base_urlstrhttps://app.dimesheets.comAPI base URL

The client can be used as a context manager to ensure proper cleanup:

with DimeSheetsClient(api_key="your-api-key") as client:
    projects = client.projects.get_all()

Resources

Projects

all_projects = client.projects.get_all()
project = client.projects.get_by_external_id("proj-100")
created = client.projects.create({"name": "New Project", "external_id": "proj-101"})
updated = client.projects.update("proj-101", {"name": "Updated Name"})
client.projects.delete("proj-101")

Tasks

tasks = client.tasks.get_all()
task = client.tasks.get_by_external_id("task-200")
created = client.tasks.create({"name": "Design", "project_id": 3, "external_id": "task-201"})
updated = client.tasks.update("task-201", {"name": "Updated task"})
client.tasks.delete("task-201")

Clients

clients = client.clients.get_all()
one = client.clients.get_by_external_id("client-acme")

Time Entries

entries = client.time_entries.get_all()
filtered = client.time_entries.get_all(start_date="2026-04-01", end_date="2026-04-30")
created = client.time_entries.create({
    "task_id": 3,
    "date": "2026-04-05T00:00:00Z",
    "duration": 2.5,
    "description": "API integration work",
    "is_billable": True,
})

Timesheets

timesheet = client.timesheets.get_by_id(12)

Reports

report = client.reports.get(start_date="2026-04-01", end_date="2026-04-30")
utilization = client.reports.get_utilization(start_date="2026-04-01", end_date="2026-04-30")
budget = client.reports.get_budget()

Timesheet Period Templates

templates = client.timesheet_period_templates.get_all()
template = client.timesheet_period_templates.get_by_external_id("tpl-weekly")

Timesheet Periods

periods = client.timesheet_periods.get_all()
filtered = client.timesheet_periods.get_filtered(year=2026, status=0)
period = client.timesheet_periods.get_by_external_id("period-2026-w14")

Integration

result = client.integration.upsert_projects([
    {"external_id": "erp-001", "name": "ERP Project"},
])
print(f"Succeeded: {result.succeeded}/{result.total}")

Models

The SDK uses Pydantic models for all request and response types. Models are available in dimesheets.models and enums in dimesheets.enums:

from dimesheets.enums import TimesheetStatus, PeriodCadence, TimesheetPeriodStatus