Skip to content

API Reference

This section provides detailed documentation for all Totis API endpoints.

Base URL

https://api.usetotis.com/api/v1

Authentication

All endpoints (except public ones) require a Bearer token in the Authorization header:

Authorization: Bearer YOUR_ACCESS_TOKEN

See Authentication for details on obtaining tokens.

Endpoints Overview

Authentication

Method Endpoint Description
POST /login/oauth/access_token Obtain access token

User Management

Method Endpoint Description
GET /user Get current user
GET /user/workspaces List user's workspaces
GET /user/workspaces/{workspaceSlug}/projects List workspace projects
PUT /user/profile Update user profile
POST /user/security/change-password Change password
POST /user/security/reset-password Initiate password reset

Workspaces

Method Endpoint Description
POST /workspace Create workspace
GET /workspace/{workspaceSlug} Get workspace
POST /workspace/{workspaceSlug} Update workspace
DELETE /workspace/{workspaceSlug} Delete workspace
GET /workspace/{workspaceSlug}/members List members
POST /workspace/{workspaceSlug}/invite Invite user
PUT /workspace/{workspaceSlug}/member/{userId} Update member role
DELETE /workspace/{workspaceSlug}/member/{userId} Remove member

Projects

Method Endpoint Description
PUT /workspace/{workspaceSlug}/project Create project
GET /workspace/{workspaceSlug}/project/{projectSlug} Get project
POST /workspace/{workspaceSlug}/project/{projectSlug} Update project
DELETE /workspace/{workspaceSlug}/project/{projectSlug} Delete project
GET /workspace/{workspaceSlug}/project/{projectSlug}/metrics Get project metrics

Builds

Method Endpoint Description
GET /workspace/{ws}/project/{proj}/build Search builds
POST /workspace/{ws}/project/{proj}/build Create build
PUT /workspace/{ws}/project/{proj}/build/{id} Update build
DELETE /workspace/{ws}/project/{proj}/build/{id} Delete build

Files

Method Endpoint Description
POST /workspace/{ws}/project/{proj}/build/{id}/sign Get signed upload URL
POST /workspace/{ws}/project/{proj}/build/{id}/upload Confirm file upload
GET /workspace/{ws}/project/{proj}/build/{id}/file List build files
GET /workspace/{ws}/project/{proj}/build/file/{fileId} Get file download URL
DELETE /workspace/{ws}/project/{proj}/build/file/{fileId} Delete file
Method Endpoint Description
POST /workspace/{ws}/project/{proj}/build/files/{fileId}/public-link Create public link
GET /workspace/{ws}/project/{proj}/build/{id}/public-links List public links
DELETE /workspace/{ws}/project/{proj}/build/files/{fileId}/public-links/{linkId} Delete public link
GET /public/file/{publicLinkId}/{fileName} Download via public link
GET /public/file/{publicLinkId}/qr Get QR code for public link

Payments

Method Endpoint Description
GET /payment/workspace/{workspaceSlug}/plans List available plans
GET /payment/workspace/{workspaceSlug}/subscription Get current subscription
GET /payment/workspace/{workspaceSlug}/usage Get workspace usage
POST /payment/workspace/{workspaceSlug}/checkout Create checkout session
POST /payment/workspace/{workspaceSlug}/change-plan Change subscription plan
POST /payment/workspace/{workspaceSlug}/cancel Cancel subscription

Onboarding

Method Endpoint Description
POST /onboarding/signup Register new user
POST /onboarding/signup/resend-verification Resend verification email
POST /onboarding/profile Save onboarding profile

Error Codes

Code Description
UNAUTHORIZED Authentication required or token invalid
FORBIDDEN Insufficient permissions
NOT_FOUND Resource not found
BAD_REQUEST Invalid request parameters
SLUG_ALREADY_EXISTS Workspace/project slug already taken
STORAGE_LIMIT_EXCEEDED Workspace storage limit reached
PROJECT_LIMIT_EXCEEDED Maximum projects limit reached