{"openapi":"3.1.0","info":{"title":"Looped API","description":"API for the Looped Platform","version":"2026.6.2"},"security":[{"ApiKeyAuth":[]}],"components":{"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-API-Key"}}},"x-tagGroups":[{"name":"Invoices","tags":["invoice","client"]},{"name":"Track","tags":["time","tag","project","section"]}],"paths":{"/v1/invoices/clients":{"post":{"operationId":"postV1InvoicesClients","description":"Create a new client. Clients are used as recipients on invoices. The `name`, `email`, `line1`, and `postalCode` fields are required.","tags":["client"],"responses":{"201":{"description":"Client created successfully","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"email":{"type":"string"},"phone":{"type":"string"},"vatNumber":{"type":"string"},"line1":{"type":"string"},"line2":{"type":"string"},"line3":{"type":"string"},"postalCode":{"type":"string"},"teamId":{"type":"string"},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["id","name","email","phone","vatNumber","line1","line2","line3","postalCode","teamId","createdAt","updatedAt"]}}}},"400":{"description":"Validation error — invalid or missing fields","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}},"required":["error"]}}}},"401":{"description":"Unauthorized — missing or invalid API key","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}},"required":["error"]}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}},"required":["error"]}}}}},"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1},"email":{"type":"string","description":"Client email address"},"phone":{"default":"","type":"string"},"vatNumber":{"default":"","type":"string"},"line1":{"type":"string","minLength":1},"line2":{"default":"","type":"string"},"line3":{"default":"","type":"string"},"postalCode":{"type":"string","minLength":1}},"required":["name","email","line1","postalCode"]}}}}},"get":{"operationId":"getV1InvoicesClients","description":"List all clients for the authenticated team. Returns an array of client records.","tags":["client"],"responses":{"200":{"description":"A list of clients","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"email":{"type":"string"},"phone":{"type":"string"},"vatNumber":{"type":"string"},"line1":{"type":"string"},"line2":{"type":"string"},"line3":{"type":"string"},"postalCode":{"type":"string"},"teamId":{"type":"string"},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["id","name","email","phone","vatNumber","line1","line2","line3","postalCode","teamId","createdAt","updatedAt"]}}}}},"401":{"description":"Unauthorized — missing or invalid API key","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}},"required":["error"]}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}},"required":["error"]}}}}}}},"/v1/invoices/clients/{id}":{"get":{"operationId":"getV1InvoicesClients:id","description":"Retrieve a single client by their ID.","tags":["client"],"responses":{"200":{"description":"The requested client","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"email":{"type":"string"},"phone":{"type":"string"},"vatNumber":{"type":"string"},"line1":{"type":"string"},"line2":{"type":"string"},"line3":{"type":"string"},"postalCode":{"type":"string"},"teamId":{"type":"string"},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["id","name","email","phone","vatNumber","line1","line2","line3","postalCode","teamId","createdAt","updatedAt"]}}}},"401":{"description":"Unauthorized — missing or invalid API key","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}},"required":["error"]}}}},"404":{"description":"Client not found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}},"required":["error"]}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}},"required":["error"]}}}}},"parameters":[{"schema":{"type":"string"},"in":"path","name":"id","required":true}]},"patch":{"operationId":"patchV1InvoicesClients:id","description":"Update an existing client. All fields are required in the request body as this performs a full replacement of the client record.","tags":["client"],"responses":{"200":{"description":"The updated client","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"email":{"type":"string"},"phone":{"type":"string"},"vatNumber":{"type":"string"},"line1":{"type":"string"},"line2":{"type":"string"},"line3":{"type":"string"},"postalCode":{"type":"string"},"teamId":{"type":"string"},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["id","name","email","phone","vatNumber","line1","line2","line3","postalCode","teamId","createdAt","updatedAt"]}}}},"400":{"description":"Validation error — invalid or missing fields","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}},"required":["error"]}}}},"401":{"description":"Unauthorized — missing or invalid API key","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}},"required":["error"]}}}},"404":{"description":"Client not found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}},"required":["error"]}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}},"required":["error"]}}}}},"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1},"email":{"type":"string","description":"Client email address"},"phone":{"default":"","type":"string"},"vatNumber":{"default":"","type":"string"},"line1":{"type":"string","minLength":1},"line2":{"default":"","type":"string"},"line3":{"default":"","type":"string"},"postalCode":{"type":"string","minLength":1}},"required":["name","email","line1","postalCode"]}}}},"parameters":[{"schema":{"type":"string"},"in":"path","name":"id","required":true}]},"delete":{"operationId":"deleteV1InvoicesClients:id","description":"Permanently delete a client by their ID. This will fail if the client has existing invoices.","tags":["client"],"responses":{"200":{"description":"Client deleted successfully","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"]}}}},"401":{"description":"Unauthorized — missing or invalid API key","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}},"required":["error"]}}}},"404":{"description":"Client not found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}},"required":["error"]}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}},"required":["error"]}}}}},"parameters":[{"schema":{"type":"string"},"in":"path","name":"id","required":true}]}},"/v1/invoices/pdf":{"get":{"operationId":"getV1InvoicesPdf","description":"Generate a PDF of an invoice. Public — pass the invoice `id` as a query parameter. Set `download=true` for a file attachment. Proxies to the invoices app's PDF renderer.","tags":["invoice"],"responses":{"200":{"description":"The generated PDF file","content":{"application/pdf":{"schema":{"type":"string","format":"binary"}}}},"500":{"description":"Failed to generate PDF","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}},"required":["error"]}}}}},"parameters":[{"in":"query","name":"id","schema":{"type":"string"},"required":true},{"in":"query","name":"download","schema":{"default":false,"type":"boolean"}}]}},"/v1/invoices":{"post":{"operationId":"postV1Invoices","description":"Create a new invoice. Provide either `clientId` to reference an existing client, or a `client` object with `email`, `name`, and optionally `address` to create or match a client inline. At least one line item is required. The `subtotal` and `total` are computed server-side. Line item position is determined by array order.","tags":["invoice"],"responses":{"201":{"description":"Invoice created successfully","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"serial":{"type":"string"},"description":{"anyOf":[{"type":"string"},{"type":"null"}]},"issueDate":{"type":"string"},"dueDate":{"anyOf":[{"type":"string"},{"type":"null"}]},"status":{"type":"string","enum":["PENDING","PAID","PAID_PARTIAL","EXPIRED","OVERDUE"]},"currency":{"type":"string"},"subtotal":{"type":"number"},"taxPercentage":{"type":"number"},"tax":{"type":"number"},"total":{"type":"number"},"clientId":{"type":"string"},"sendersAddressId":{"type":"string"},"teamId":{"type":"string"},"lineItems":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"description":{"type":"string"},"unitPrice":{"type":"number"},"quantity":{"type":"number"},"amount":{"type":"number"},"position":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"invoiceId":{"type":"string"},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["id","description","unitPrice","quantity","amount","position","invoiceId","createdAt","updatedAt"]}},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["id","serial","description","issueDate","dueDate","status","currency","subtotal","taxPercentage","tax","total","clientId","sendersAddressId","teamId","lineItems","createdAt","updatedAt"]}}}},"400":{"description":"Validation error — invalid or missing fields","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}},"required":["error"]}}}},"401":{"description":"Unauthorized — missing or invalid API key","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}},"required":["error"]}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}},"required":["error"]}}}}},"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"clientId":{"type":"string","description":"ID of an existing client"},"client":{"type":"object","properties":{"email":{"type":"string","description":"Client email address"},"name":{"type":"string","minLength":1,"description":"Client name"},"address":{"type":"object","properties":{"line1":{"type":"string"},"line2":{"type":"string"},"line3":{"type":"string"},"postalCode":{"type":"string"}}}},"required":["email","name"],"description":"Inline client details (required if clientId is not provided)"},"lineItems":{"minItems":1,"type":"array","items":{"type":"object","properties":{"description":{"type":"string"},"unitPrice":{"type":"number","minimum":0},"quantity":{"type":"number","exclusiveMinimum":0},"amount":{"type":"number","minimum":0}}}},"issueDate":{"type":"string","description":"ISO 8601 datetime (e.g. 2025-01-15T09:30:00Z)"},"dueDate":{"type":"string","description":"ISO 8601 datetime (e.g. 2025-02-15T09:30:00Z)"},"description":{"type":"string"},"status":{"type":"string","enum":["PENDING","PAID","PAID_PARTIAL","EXPIRED","OVERDUE"]},"sendersAddressId":{"type":"string"},"taxPercentage":{"default":0,"type":"number","minimum":0},"tax":{"default":0,"type":"number","minimum":0}},"required":["lineItems"]}}}}},"get":{"operationId":"getV1Invoices","description":"List all invoices for the authenticated team. Returns an array of invoices with their line items.","tags":["invoice"],"responses":{"200":{"description":"A list of invoices","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"serial":{"type":"string"},"description":{"anyOf":[{"type":"string"},{"type":"null"}]},"issueDate":{"type":"string"},"dueDate":{"anyOf":[{"type":"string"},{"type":"null"}]},"status":{"type":"string","enum":["PENDING","PAID","PAID_PARTIAL","EXPIRED","OVERDUE"]},"currency":{"type":"string"},"subtotal":{"type":"number"},"taxPercentage":{"type":"number"},"tax":{"type":"number"},"total":{"type":"number"},"clientId":{"type":"string"},"sendersAddressId":{"type":"string"},"teamId":{"type":"string"},"lineItems":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"description":{"type":"string"},"unitPrice":{"type":"number"},"quantity":{"type":"number"},"amount":{"type":"number"},"position":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"invoiceId":{"type":"string"},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["id","description","unitPrice","quantity","amount","position","invoiceId","createdAt","updatedAt"]}},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["id","serial","description","issueDate","dueDate","status","currency","subtotal","taxPercentage","tax","total","clientId","sendersAddressId","teamId","lineItems","createdAt","updatedAt"]}}}}},"401":{"description":"Unauthorized — missing or invalid API key","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}},"required":["error"]}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}},"required":["error"]}}}}}}},"/v1/invoices/{id}/mark":{"patch":{"operationId":"patchV1Invoices:idMark","description":"Mark an invoice as paid. Updates the invoice status to PAID. No request body is required.","tags":["invoice"],"responses":{"200":{"description":"Invoice marked as paid","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"serial":{"type":"string"},"description":{"anyOf":[{"type":"string"},{"type":"null"}]},"issueDate":{"type":"string"},"dueDate":{"anyOf":[{"type":"string"},{"type":"null"}]},"status":{"type":"string","enum":["PENDING","PAID","PAID_PARTIAL","EXPIRED","OVERDUE"]},"currency":{"type":"string"},"subtotal":{"type":"number"},"taxPercentage":{"type":"number"},"tax":{"type":"number"},"total":{"type":"number"},"clientId":{"type":"string"},"sendersAddressId":{"type":"string"},"teamId":{"type":"string"},"lineItems":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"description":{"type":"string"},"unitPrice":{"type":"number"},"quantity":{"type":"number"},"amount":{"type":"number"},"position":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"invoiceId":{"type":"string"},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["id","description","unitPrice","quantity","amount","position","invoiceId","createdAt","updatedAt"]}},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["id","serial","description","issueDate","dueDate","status","currency","subtotal","taxPercentage","tax","total","clientId","sendersAddressId","teamId","lineItems","createdAt","updatedAt"]}}}},"401":{"description":"Unauthorized — missing or invalid API key","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}},"required":["error"]}}}},"404":{"description":"Invoice not found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}},"required":["error"]}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}},"required":["error"]}}}}},"parameters":[{"schema":{"type":"string"},"in":"path","name":"id","required":true}]}},"/v1/invoices/{id}":{"get":{"operationId":"getV1Invoices:id","description":"Retrieve a single invoice by its ID, including all line items.","tags":["invoice"],"responses":{"200":{"description":"The requested invoice","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"serial":{"type":"string"},"description":{"anyOf":[{"type":"string"},{"type":"null"}]},"issueDate":{"type":"string"},"dueDate":{"anyOf":[{"type":"string"},{"type":"null"}]},"status":{"type":"string","enum":["PENDING","PAID","PAID_PARTIAL","EXPIRED","OVERDUE"]},"currency":{"type":"string"},"subtotal":{"type":"number"},"taxPercentage":{"type":"number"},"tax":{"type":"number"},"total":{"type":"number"},"clientId":{"type":"string"},"sendersAddressId":{"type":"string"},"teamId":{"type":"string"},"lineItems":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"description":{"type":"string"},"unitPrice":{"type":"number"},"quantity":{"type":"number"},"amount":{"type":"number"},"position":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"invoiceId":{"type":"string"},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["id","description","unitPrice","quantity","amount","position","invoiceId","createdAt","updatedAt"]}},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["id","serial","description","issueDate","dueDate","status","currency","subtotal","taxPercentage","tax","total","clientId","sendersAddressId","teamId","lineItems","createdAt","updatedAt"]}}}},"401":{"description":"Unauthorized — missing or invalid API key","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}},"required":["error"]}}}},"404":{"description":"Invoice not found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}},"required":["error"]}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}},"required":["error"]}}}}},"parameters":[{"schema":{"type":"string"},"in":"path","name":"id","required":true}]},"patch":{"operationId":"patchV1Invoices:id","description":"Update an existing invoice. All fields are optional — only provided fields will be updated. If `lineItems` is provided, it replaces all existing line items. The `subtotal` and `total` are recomputed server-side.","tags":["invoice"],"responses":{"200":{"description":"The updated invoice","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"serial":{"type":"string"},"description":{"anyOf":[{"type":"string"},{"type":"null"}]},"issueDate":{"type":"string"},"dueDate":{"anyOf":[{"type":"string"},{"type":"null"}]},"status":{"type":"string","enum":["PENDING","PAID","PAID_PARTIAL","EXPIRED","OVERDUE"]},"currency":{"type":"string"},"subtotal":{"type":"number"},"taxPercentage":{"type":"number"},"tax":{"type":"number"},"total":{"type":"number"},"clientId":{"type":"string"},"sendersAddressId":{"type":"string"},"teamId":{"type":"string"},"lineItems":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"description":{"type":"string"},"unitPrice":{"type":"number"},"quantity":{"type":"number"},"amount":{"type":"number"},"position":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"invoiceId":{"type":"string"},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["id","description","unitPrice","quantity","amount","position","invoiceId","createdAt","updatedAt"]}},"createdAt":{"type":"string"},"updatedAt":{"type":"string"}},"required":["id","serial","description","issueDate","dueDate","status","currency","subtotal","taxPercentage","tax","total","clientId","sendersAddressId","teamId","lineItems","createdAt","updatedAt"]}}}},"400":{"description":"Validation error — invalid fields","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}},"required":["error"]}}}},"401":{"description":"Unauthorized — missing or invalid API key","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}},"required":["error"]}}}},"404":{"description":"Invoice not found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}},"required":["error"]}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}},"required":["error"]}}}}},"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"clientId":{"type":"string"},"issueDate":{"type":"string","description":"ISO 8601 datetime (e.g. 2025-01-15T09:30:00Z)"},"dueDate":{"type":"string","description":"ISO 8601 datetime (e.g. 2025-02-15T09:30:00Z)"},"description":{"type":"string"},"status":{"type":"string","enum":["PENDING","PAID","PAID_PARTIAL","EXPIRED","OVERDUE"]},"sendersAddressId":{"type":"string"},"taxPercentage":{"default":0,"type":"number","minimum":0},"tax":{"default":0,"type":"number","minimum":0},"lineItems":{"minItems":1,"type":"array","items":{"type":"object","properties":{"description":{"type":"string"},"unitPrice":{"type":"number","minimum":0},"quantity":{"type":"number","exclusiveMinimum":0},"amount":{"type":"number","minimum":0}}}}}}}}},"parameters":[{"schema":{"type":"string"},"in":"path","name":"id","required":true}]},"delete":{"operationId":"deleteV1Invoices:id","description":"Permanently delete an invoice by its ID. This action cannot be undone.","tags":["invoice"],"responses":{"200":{"description":"Invoice deleted successfully","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string"}},"required":["message"]}}}},"401":{"description":"Unauthorized — missing or invalid API key","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}},"required":["error"]}}}},"404":{"description":"Invoice not found","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}},"required":["error"]}}}},"500":{"description":"Internal server error","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}},"required":["error"]}}}}},"parameters":[{"schema":{"type":"string"},"in":"path","name":"id","required":true}]}},"/v1/track/time":{"get":{"operationId":"getV1TrackTime","description":"List time entries for a given date. Use `frequency` to expand the range to a full week or month.","tags":["time"],"responses":{"400":{"description":"Validation error — missing or invalid query parameters","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"}},"required":["error"]}}}}},"parameters":[{"in":"query","name":"date","schema":{"type":"string"},"required":true,"description":"Date to fetch entries for (e.g. 2025-01-15)"},{"in":"query","name":"frequency","schema":{"type":"string","enum":["day","week","month"]},"description":"Time range relative to date"}]},"post":{"operationId":"postV1TrackTime","description":"Create a time entry","tags":["time"],"responses":{},"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"durationSeconds":{"type":"integer","exclusiveMinimum":0,"maximum":9007199254740991},"taskName":{"type":"string","minLength":1,"maxLength":255},"description":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}]},"date":{"type":"string","description":"ISO 8601 datetime (e.g. 2025-01-15T09:30:00Z)"},"userId":{"description":"User ID to log time for. Admins and owners only.","type":"string"},"projectId":{"anyOf":[{"type":"string"},{"type":"null"}]},"sectionId":{"anyOf":[{"type":"string"},{"type":"null"}]},"tags":{"default":[],"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"title":{"type":"string"}},"required":["id","title"]}},"aiGenerated":{"default":false,"type":"boolean"}},"required":["durationSeconds","taskName","date"]}}}}}},"/v1/track/time/{id}":{"get":{"operationId":"getV1TrackTime:id","description":"Get a time entry by ID","tags":["time"],"responses":{},"parameters":[{"schema":{"type":"string"},"in":"path","name":"id","required":true}]},"patch":{"operationId":"patchV1TrackTime:id","description":"Update a time entry","tags":["time"],"responses":{},"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"taskName":{"type":"string","minLength":1,"maxLength":255},"description":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}]},"date":{"type":"string","description":"ISO 8601 datetime (e.g. 2025-01-15T09:30:00Z)"},"durationSeconds":{"type":"integer","exclusiveMinimum":0,"maximum":9007199254740991},"userId":{"description":"User ID to move the time entry to. Admins and owners only.","type":"string"},"projectId":{"anyOf":[{"type":"string"},{"type":"null"}]},"sectionId":{"anyOf":[{"type":"string"},{"type":"null"}]},"tags":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"title":{"type":"string"}},"required":["id","title"]}}}}}}},"parameters":[{"schema":{"type":"string"},"in":"path","name":"id","required":true}]},"delete":{"operationId":"deleteV1TrackTime:id","description":"Delete a time entry","tags":["time"],"responses":{},"parameters":[{"schema":{"type":"string"},"in":"path","name":"id","required":true}]}},"/v1/track/tags":{"get":{"operationId":"getV1TrackTags","description":"List all tags","tags":["tag"],"responses":{}},"post":{"operationId":"postV1TrackTags","description":"Create a tag","tags":["tag"],"responses":{},"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"title":{"type":"string","minLength":1,"maxLength":255}},"required":["title"]}}}}}},"/v1/track/tags/{id}":{"patch":{"operationId":"patchV1TrackTags:id","description":"Update a tag","tags":["tag"],"responses":{},"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"title":{"type":"string","minLength":1,"maxLength":255}},"required":["title"]}}}},"parameters":[{"schema":{"type":"string"},"in":"path","name":"id","required":true}]},"delete":{"operationId":"deleteV1TrackTags:id","description":"Delete a tag","tags":["tag"],"responses":{},"parameters":[{"schema":{"type":"string"},"in":"path","name":"id","required":true}]}},"/v1/track/projects":{"get":{"operationId":"getV1TrackProjects","description":"List all projects for the authenticated user's team","tags":["project"],"responses":{}},"post":{"operationId":"postV1TrackProjects","description":"Create a new project with a title and optional code","tags":["project"],"responses":{},"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"title":{"type":"string","minLength":1,"maxLength":255},"code":{"type":"string","maxLength":50}},"required":["title"]}}}}}},"/v1/track/projects/{id}":{"put":{"operationId":"putV1TrackProjects:id","description":"Update a project's title, code, or status","tags":["project"],"responses":{},"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","minLength":1},"data":{"type":"object","properties":{"title":{"type":"string","minLength":1,"maxLength":255},"code":{"type":"string","maxLength":50},"status":{"type":"string","enum":["PENDING","ACTIVE","COMPLETED","ARCHIVED"]}}}},"required":["id"]}}}},"parameters":[{"schema":{"type":"string"},"in":"path","name":"id","required":true}]},"delete":{"operationId":"deleteV1TrackProjects:id","description":"Delete a project (only if it has no time entries)","tags":["project"],"responses":{},"parameters":[{"schema":{"type":"string"},"in":"path","name":"id","required":true}]}},"/v1/track/sections":{"get":{"operationId":"getV1TrackSections","description":"List all sections for a specific project","tags":["section"],"responses":{},"parameters":[{"in":"query","name":"projectId","schema":{"type":"string","minLength":1},"required":true}]},"post":{"operationId":"postV1TrackSections","description":"Create a new section within a project","tags":["section"],"responses":{},"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"title":{"type":"string","minLength":1,"maxLength":255},"projectId":{"type":"string","minLength":1}},"required":["title","projectId"]}}}}}},"/v1/track/sections/{id}":{"put":{"operationId":"putV1TrackSections:id","description":"Update a section's title","tags":["section"],"responses":{},"requestBody":{"content":{"application/json":{"schema":{"type":"object","properties":{"title":{"type":"string","minLength":1,"maxLength":255}}}}}},"parameters":[{"schema":{"type":"string"},"in":"path","name":"id","required":true}]},"delete":{"operationId":"deleteV1TrackSections:id","description":"Delete a section (only if it has no time entries)","tags":["section"],"responses":{},"parameters":[{"schema":{"type":"string"},"in":"path","name":"id","required":true}]}}}}