API References
The Tailor Platform exposes its functionality through APIs defined using Protocol Buffers. Using ConnectRPC, we support both gRPC and HTTP protocols. This guide shows you how to interact with these APIs using different approaches.
Overview
All platform services are exposed through the OperatorService
, a unified gRPC API for managing workspaces, applications, and platform components. The .proto files defining these services are available in our GitHub repository.
Using the APIs
You can interact with Tailor Platform APIs using curl by making HTTP requests to the API endpoints.
See Authentication for details on obtaining an access token.
Once authenticated, you can proceed with API requests:
Creating a Workspace
<span><span style="color: var(--shiki-token-function)">curl</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">-X</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">POST</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string-expression)">"https://api.tailor.tech/tailor.v1.OperatorService/CreateWorkspace"</span><span style="color: var(--shiki-color-text)"> \</span></span>
<span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">-H</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string-expression)">"Authorization: Bearer YOUR_ACCESS_TOKEN"</span><span style="color: var(--shiki-color-text)"> \</span></span>
<span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">-H</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string-expression)">"Content-Type: application/json"</span><span style="color: var(--shiki-color-text)"> \</span></span>
<span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">-d</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string-expression)">'{</span></span>
<span><span style="color: var(--shiki-token-string-expression)"> "workspace_name": "my-workspace",</span></span>
<span><span style="color: var(--shiki-token-string-expression)"> "workspace_region": "us-west",</span></span>
<span><span style="color: var(--shiki-token-string-expression)"> "organization_id": "org-123",</span></span>
<span><span style="color: var(--shiki-token-string-expression)"> "delete_protection": true</span></span>
<span><span style="color: var(--shiki-token-string-expression)"> }'</span></span>
<span></span>
Authentication
All API calls require authentication using Bearer tokens. Use tailorctl to authenticate:
<span><span style="color: var(--shiki-token-function)">tailorctl</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">auth</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">login</span></span>
<span><span style="color: var(--shiki-token-function)">tailorctl</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">auth</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">get</span><span style="color: var(--shiki-color-text)"> </span><span style="color: var(--shiki-token-string)">accessToken</span></span>
<span></span>
See the Auth Guide for detailed authentication setup.
Common Operations
Workspace Management
CreateWorkspace
- Create a new workspaceGetWorkspace
- Retrieve workspace detailsListWorkspaces
- List all accessible workspacesUpdateWorkspace
- Modify workspace settingsDeleteWorkspace
- Remove a workspace
Application Services
CreateApplication
- Deploy a new applicationCreateTailorDBService
- Set up database servicesCreatePipelineService
- Configure data processingCreateAuthService
- Enable authenticationCreateExecutorService
- Set up job execution
Error Handling
All APIs return standard gRPC status codes. Common error responses include:
UNAUTHENTICATED
(16) - Invalid or missing authenticationPERMISSION_DENIED
(7) - Insufficient permissionsNOT_FOUND
(5) - Resource does not existALREADY_EXISTS
(6) - Resource already existsINVALID_ARGUMENT
(3) - Invalid request parameters
Related Documentation
For implementation details and usage examples, refer to: