{"openapi":"3.1.0","info":{"title":"Turtini Public API","description":"Read and write your org's data on the Turtini platform from external code — AI-IDE-edited sites, server-side functions, CLI tools. All endpoints are Bearer-authenticated with org-scoped API keys minted at Settings → Partner Dev.","version":"1.0.0","contact":{"name":"Turtini","url":"https://turtini.com"},"license":{"name":"Turtini Platform Terms","url":"https://turtini.com/terms"}},"servers":[{"url":"https://api.turtini.com","description":"Production"}],"externalDocs":{"description":"Developer docs (in-app)","url":"https://turtini.com/account?section=developer"},"components":{"securitySchemes":{"bearerAuth":{"type":"http","scheme":"bearer","bearerFormat":"turtini_<32 base64url chars>","description":"Org-scoped API key. Mint at Settings → Partner Dev → API Keys with the scopes you need. Wildcards: `*:read` covers all read endpoints, `*:write` covers all write endpoints."},"oauth2":{"type":"oauth2","description":"Per-user OAuth 2.0 — recommended for any app where multiple end users should each authenticate as themselves rather than sharing one API key. Each user picks which org to authorize and which scopes to grant.","flows":{"authorizationCode":{"authorizationUrl":"https://turtini.com/oauth/authorize","tokenUrl":"https://api.turtini.com/v1/oauth/token","refreshUrl":"https://api.turtini.com/v1/oauth/token","scopes":{"*:read":"Read everything","*:write":"Create and update everything","contacts:read":"Read contacts","contacts:write":"Create contacts","accounts:read":"Read accounts","opportunities:read":"Read opportunitys","quotes:read":"Read quotes","products:read":"Read products","notes:write":"Create notes","articles:read":"Read articles","articles:write":"Create articles","events:read":"Read events","events:write":"Create events","grants:read":"Read grants","restaurants:read":"Read restaurants","menuItems:read":"Read menuitems","menuItems:write":"Create menuitems","restaurantOrders:read":"Read restaurantorders","restaurantOrders:write":"Create restaurantorders","restaurantTables:read":"Read restauranttables","retailStores:read":"Read retailstores","retailProducts:read":"Read retailproducts","retailProducts:write":"Create retailproducts","retailOrders:read":"Read retailorders","retailOrders:write":"Create retailorders","lodgingProperties:read":"Read lodgingpropertys","lodgingRoomTypes:read":"Read lodgingroomtypes","lodgingRooms:read":"Read lodgingrooms","lodgingReservations:read":"Read lodgingreservations","lodgingReservations:write":"Create lodgingreservations","lodgingRoomCharges:read":"Read lodgingroomcharges","lodgingRoomCharges:write":"Create lodgingroomcharges","invoices:read":"Read invoices","bills:read":"Read bills","bills:write":"Create bills","journalEntries:read":"Read journalentrys","projects:read":"Read projects","projects:write":"Create projects","tasks:read":"Read tasks","tasks:write":"Create tasks","buildings:read":"Read buildings","units:read":"Read units","workOrders:read":"Read workorders","workOrders:write":"Create workorders","devices:read":"Read devices","leases:read":"Read leases","tenants:read":"Read tenants","subscriptionPlans:read":"Read subscriptionplans","subscriptions:read":"Read subscriptions","runbooks:read":"Read runbooks","fieldServiceJobs:read":"Read fieldservicejobs","websites:read":"Read websites","contracts:read":"Read contracts","signatures:read":"Read signaturerequests","emailCampaigns:read":"Read emailcampaigns","employees:read":"Read employees","travelTrips:read":"Read traveltrips","context:read":"Natural-language org-context queries (Layer D / Wally bridge). Used by AI agents to ask grounded questions about the org without hand-fed schema.","functions:read":"List and inspect customer-authored functions deployed to this org. Required by the Turtini CLI to read deployment status.","functions:write":"Deploy, pause, resume, and delete customer-authored functions that subscribe to platform events. Required by the Turtini CLI to publish new bundles.","scratchOrgs:read":"List ephemeral developer/test orgs you own. Required by the Turtini CLI to show org status.","scratchOrgs:write":"Create, extend, and delete ephemeral developer/test orgs. Required by the Turtini CLI to spin up isolated test tenants.","packages:read":"List your org's published marketplace packages. Required by the Turtini CLI to show publish status.","packages:write":"Publish, update, and withdraw pro-code marketplace packages from your org. Required by the Turtini CLI to ship installable function packages.","email:send":"Send transactional or campaign email through Turtini's pipeline.","wellness:vitals.read":"View heart rate, blood pressure, glucose, weight, sleep, and other readings from your connected monitors. Used by hospital networks you grant access to.","wellness:labs.read":"View clinical lab results (A1c, lipid panel, CBC, etc.) you have shared.","wellness:meds.read":"View active and historical prescriptions.","wellness:conditions.read":"View your problem list / diagnoses.","wellness:imaging.read":"View imaging report narratives (X-ray, MRI, CT). Images themselves are never copied into Turtini.","wellness:vitals.write":"Record vitals on your behalf (in-clinic BP, glucose meter, weight). Every reading is logged and you see it in the Care tab.","wellness:meds.write":"Record new or changed prescriptions on your behalf. You see every change in the Care tab."}}}}},"parameters":{"Limit":{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},"PageToken":{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},"CreatedAfter":{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},"CreatedBefore":{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}},"IdempotencyKey":{"name":"Idempotency-Key","in":"header","required":false,"description":"Optional UUID-shaped value. Repeated requests with the same key replay the cached response for 24h.","schema":{"type":"string","maxLength":256}}},"schemas":{"ErrorEnvelope":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message"],"properties":{"code":{"type":"string"},"message":{"type":"string"}}}}},"SearchResponse":{"type":"object","required":["query","results","scoped","totalMatches"],"properties":{"query":{"type":"string"},"totalMatches":{"type":"integer"},"scoped":{"type":"array","items":{"type":"string"},"description":"Entities the API key has read scope for and that were searched."},"results":{"type":"object","additionalProperties":{"type":"array","items":{"type":"object","additionalProperties":true}},"description":"Per-entity grouped matches. Keys mirror the `scoped` array; values are arrays of matching records (full doc shape varies by entity)."}}},"AuthVerifyResponse":{"type":"object","required":["orgId","orgName","orgSlug","keyId","scopes"],"properties":{"orgId":{"type":"string"},"orgName":{"type":"string"},"orgSlug":{"type":"string"},"keyId":{"type":"string"},"scopes":{"type":"array","items":{"type":"string"}}}},"MeResponse":{"type":"object","required":["org","modules","key"],"properties":{"org":{"type":"object","required":["orgId","orgName","orgSlug","lifecycleStatus","governmentOrg"],"properties":{"orgId":{"type":"string"},"orgName":{"type":"string"},"orgSlug":{"type":"string"},"pricingPlan":{"type":"string","nullable":true,"description":"One of: org, negotiated, standard, growth, professional, scale, enterprise. Null if not yet set."},"lifecycleStatus":{"type":"string","enum":["active","paused","canceling","soft_purged"]},"governmentOrg":{"type":"boolean"}}},"modules":{"type":"array","items":{"type":"string"},"description":"Active Turtini module keys for this org (e.g. \"crm\", \"accounting\", \"lodging\"). Sorted."},"user":{"type":"object","nullable":true,"description":"Present only when authenticated via OAuth (per-user grant). Null when authenticated via a server API key.","required":["userId","role"],"properties":{"userId":{"type":"string"},"role":{"type":"string","nullable":true,"description":"Role within the org: owner / admin / member / viewer. Null if the user is not a member."}}},"key":{"type":"object","required":["keyId","scopes"],"properties":{"keyId":{"type":"string"},"scopes":{"type":"array","items":{"type":"string"}}}}}},"OrgContextQueryRequest":{"type":"object","required":["query"],"properties":{"query":{"type":"string","maxLength":4000,"description":"Natural-language question about the connected org."}}},"OrgContextQueryResponse":{"type":"object","required":["answer","org","usage"],"properties":{"answer":{"type":"string"},"org":{"type":"object","required":["orgId","orgName","orgSlug"],"properties":{"orgId":{"type":"string"},"orgName":{"type":"string"},"orgSlug":{"type":"string"}}},"usage":{"type":"object","properties":{"inputTokens":{"type":"integer"},"outputTokens":{"type":"integer"},"cacheReadTokens":{"type":"integer"},"cacheCreateTokens":{"type":"integer"}}}}},"Contact":{"type":"object","required":["id","firstName","lastName","orgId","createdAt","updatedAt"],"properties":{"id":{"type":"string"},"firstName":{"type":"string"},"lastName":{"type":"string"},"email":{"type":"string"},"phone":{"type":"string"},"accountId":{"type":"string"},"title":{"type":"string"},"orgId":{"type":"string"},"source":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseContact":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Contact"}},"nextPageToken":{"type":["string","null"]}}},"ContactCreateInput":{"type":"object","required":["firstName","lastName"],"properties":{"firstName":{"type":"string","maxLength":200},"lastName":{"type":"string","maxLength":200},"email":{"type":"string","format":"email"},"phone":{"type":"string","maxLength":50},"accountId":{"type":"string"},"title":{"type":"string","maxLength":200}},"additionalProperties":false},"Account":{"type":"object","required":["id","name","orgId","createdAt","updatedAt"],"properties":{"id":{"type":"string"},"name":{"type":"string"},"orgId":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseAccount":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Account"}},"nextPageToken":{"type":["string","null"]}}},"Opportunity":{"type":"object","required":["id","name","stage","orgId","createdAt","updatedAt"],"properties":{"id":{"type":"string"},"name":{"type":"string"},"stage":{"type":"string"},"amount":{"type":"number"},"orgId":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseOpportunity":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Opportunity"}},"nextPageToken":{"type":["string","null"]}}},"Quote":{"type":"object","required":["id","orgId","createdAt"],"properties":{"id":{"type":"string"},"number":{"type":"string","description":"Human-readable quote / invoice number."},"accountId":{"type":"string"},"opportunityId":{"type":"string"},"status":{"type":"string","description":"draft | sent | accepted | rejected | invoiced | paid (varies by org workflow)."},"total":{"type":"number"},"currency":{"type":"string"},"orgId":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseQuote":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Quote"}},"nextPageToken":{"type":["string","null"]}}},"Product":{"type":"object","required":["id","name","orgId","createdAt"],"properties":{"id":{"type":"string"},"name":{"type":"string"},"sku":{"type":"string"},"price":{"type":"number"},"currency":{"type":"string"},"family":{"type":"string"},"orgId":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseProduct":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Product"}},"nextPageToken":{"type":["string","null"]}}},"NoteCreateInput":{"type":"object","required":["entity","entityId","text"],"properties":{"entity":{"type":"string","enum":["account","opportunity","contact"],"description":"Which CRM record to attach the note to."},"entityId":{"type":"string","description":"ID of the parent record. Must belong to the caller's org."},"text":{"type":"string","maxLength":10000,"description":"Plain-text note body."}},"additionalProperties":false},"Note":{"type":"object","required":["id","text","authorId","authorName","createdAt","orgId","via","path","parent"],"properties":{"id":{"type":"string"},"text":{"type":"string"},"authorId":{"type":"string","description":"apiKey:<keyId> when written via this API."},"authorName":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"orgId":{"type":"string"},"via":{"type":"string","enum":["public_api"]},"path":{"type":"string","description":"Firestore path of the created note doc, e.g. accounts/<id>/notes/<noteId>."},"parent":{"type":"object","required":["entity","id"],"properties":{"entity":{"type":"string","enum":["account","opportunity","contact"]},"id":{"type":"string"}}}}},"Article":{"type":"object","required":["id","title","body","status","authorOrgId","createdAt","updatedAt"],"properties":{"id":{"type":"string"},"title":{"type":"string"},"body":{"type":"string"},"summary":{"type":"string"},"tags":{"type":"array","items":{"type":"string"}},"visibility":{"type":"string","enum":["public","internal"]},"status":{"type":"string"},"authorOrgId":{"type":"string"},"authorOrgName":{"type":"string"},"authorId":{"type":"string"},"authorName":{"type":"string"},"articleTypeId":{"type":"string"},"moderationStatus":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseArticle":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Article"}},"nextPageToken":{"type":["string","null"]}}},"ArticleCreateInput":{"type":"object","required":["title","body"],"properties":{"title":{"type":"string","maxLength":300},"body":{"type":"string","maxLength":200000,"description":"HTML or Markdown."},"summary":{"type":"string","maxLength":1000},"articleTypeId":{"type":"string"},"visibility":{"type":"string","enum":["public","internal"],"default":"internal"},"tags":{"type":"array","items":{"type":"string"},"maxItems":30}},"additionalProperties":false},"Event":{"type":"object","required":["id","title","slug","date","status","visibility","orgId","createdAt","updatedAt"],"properties":{"id":{"type":"string"},"title":{"type":"string"},"slug":{"type":"string"},"date":{"type":"string","description":"ISO date or full ISO datetime."},"startTime":{"type":"string"},"endTime":{"type":"string"},"endDate":{"type":"string"},"location":{"type":"string"},"description":{"type":"string"},"status":{"type":"string","enum":["published","draft"]},"visibility":{"type":"string","enum":["public","private"]},"orgId":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseEvent":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Event"}},"nextPageToken":{"type":["string","null"]}}},"EventCreateInput":{"type":"object","required":["title","date"],"properties":{"title":{"type":"string","maxLength":300},"date":{"type":"string","description":"ISO date or YYYY-MM-DD."},"startTime":{"type":"string","description":"HH:mm."},"endTime":{"type":"string"},"endDate":{"type":"string"},"location":{"type":"string","maxLength":500},"description":{"type":"string","maxLength":5000},"status":{"type":"string","enum":["published","draft"],"default":"draft"},"visibility":{"type":"string","enum":["public","private"],"default":"private"},"slug":{"type":"string","pattern":"^[a-z0-9-]+$"}},"additionalProperties":false},"Grant":{"type":"object","required":["id","title","category","status","visibility","authorOrgId","createdAt","updatedAt"],"properties":{"id":{"type":"string"},"title":{"type":"string"},"slug":{"type":"string"},"summary":{"type":"string"},"description":{"type":"string"},"category":{"type":"string","enum":["mutual-aid","scholarship","event-sponsorship","programmatic","emergency","capacity-building","community","other"]},"funderName":{"type":"string"},"funderUrl":{"type":"string"},"minAward":{"type":"number"},"maxAward":{"type":"number"},"totalPool":{"type":"number"},"currency":{"type":"string"},"openAt":{"type":"string","format":"date-time"},"deadlineAt":{"type":"string","format":"date-time"},"decisionByAt":{"type":"string","format":"date-time"},"cycle":{"type":"string","enum":["one-time","rolling","quarterly","annual"]},"eligibility":{"type":"string"},"reviewCriteria":{"type":"string"},"tags":{"type":"array","items":{"type":"string"}},"visibility":{"type":"string","enum":["internal","public"]},"status":{"type":"string","enum":["draft","open","closed","awarded","archived"]},"applicationCount":{"type":"integer"},"awardedCount":{"type":"integer"},"awardedTotal":{"type":"number"},"authorOrgId":{"type":"string"},"authorOrgName":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}}},"ListResponseGrant":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Grant"}},"nextPageToken":{"type":["string","null"]}}},"Restaurant":{"type":"object","required":["id","name","orgId","createdAt"],"properties":{"id":{"type":"string"},"name":{"type":"string"},"address":{"type":"string"},"phone":{"type":"string"},"cuisineType":{"type":"string"},"orgId":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseRestaurant":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Restaurant"}},"nextPageToken":{"type":["string","null"]}}},"MenuItem":{"type":"object","required":["id","name","orgId","createdAt"],"properties":{"id":{"type":"string"},"restaurantId":{"type":"string"},"name":{"type":"string"},"description":{"type":"string"},"category":{"type":"string"},"price":{"type":"number"},"currency":{"type":"string"},"available":{"type":"boolean"},"imageUrl":{"type":"string"},"tags":{"type":"array","items":{"type":"string"}},"orgId":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseMenuItem":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/MenuItem"}},"nextPageToken":{"type":["string","null"]}}},"MenuItemCreateInput":{"type":"object","required":["restaurantId","name"],"properties":{"restaurantId":{"type":"string"},"name":{"type":"string","maxLength":200},"description":{"type":"string","maxLength":2000},"category":{"type":"string","maxLength":100},"price":{"type":"number","minimum":0},"available":{"type":"boolean","default":true},"tags":{"type":"array","items":{"type":"string"},"maxItems":30}},"additionalProperties":false},"RestaurantOrder":{"type":"object","required":["id","orgId","createdAt"],"properties":{"id":{"type":"string"},"number":{"type":"string"},"restaurantId":{"type":"string"},"tableId":{"type":"string"},"tableName":{"type":"string"},"serverId":{"type":"string"},"serverName":{"type":"string"},"status":{"type":"string","description":"open | paid | voided"},"paymentMethod":{"type":"string","description":"cash | card | room-charge"},"subtotal":{"type":"number"},"tax":{"type":"number"},"tip":{"type":"number"},"total":{"type":"number"},"currency":{"type":"string"},"reservationId":{"type":"string"},"roomChargeId":{"type":"string"},"orgId":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseRestaurantOrder":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/RestaurantOrder"}},"nextPageToken":{"type":["string","null"]}}},"RestaurantOrderCreateInput":{"type":"object","required":["restaurantId","items"],"properties":{"restaurantId":{"type":"string"},"tableId":{"type":"string"},"tableNumber":{"type":"string"},"orderNumber":{"type":"string","description":"Counter-pickup queue display (e.g. \"A47\")."},"serverName":{"type":"string"},"notes":{"type":"string","maxLength":2000},"contactEmail":{"type":"string","format":"email"},"tax":{"type":"number","minimum":0},"tipAmount":{"type":"number","minimum":0},"items":{"type":"array","minItems":1,"items":{"type":"object","required":["name","price","quantity"],"properties":{"menuItemId":{"type":"string"},"retailProductId":{"type":"string"},"name":{"type":"string","maxLength":200},"price":{"type":"number","minimum":0},"quantity":{"type":"number","minimum":0},"notes":{"type":"string","maxLength":1000}},"additionalProperties":false}}},"additionalProperties":false},"RestaurantTable":{"type":"object","required":["id","name","orgId","createdAt"],"properties":{"id":{"type":"string"},"restaurantId":{"type":"string"},"name":{"type":"string"},"section":{"type":"string"},"capacity":{"type":"integer"},"orgId":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseRestaurantTable":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/RestaurantTable"}},"nextPageToken":{"type":["string","null"]}}},"RetailStore":{"type":"object","required":["id","name","orgId","createdAt"],"properties":{"id":{"type":"string"},"name":{"type":"string"},"address":{"type":"string"},"phone":{"type":"string"},"orgId":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseRetailStore":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/RetailStore"}},"nextPageToken":{"type":["string","null"]}}},"RetailProduct":{"type":"object","required":["id","name","orgId","createdAt"],"properties":{"id":{"type":"string"},"storeId":{"type":"string"},"name":{"type":"string"},"sku":{"type":"string"},"barcode":{"type":"string"},"category":{"type":"string"},"description":{"type":"string"},"price":{"type":"number"},"currency":{"type":"string"},"currentStock":{"type":"number"},"tags":{"type":"array","items":{"type":"string"}},"orgId":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseRetailProduct":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/RetailProduct"}},"nextPageToken":{"type":["string","null"]}}},"RetailProductCreateInput":{"type":"object","required":["storeId","name"],"properties":{"storeId":{"type":"string"},"name":{"type":"string","maxLength":200},"sku":{"type":"string","maxLength":100},"barcode":{"type":"string","maxLength":100},"category":{"type":"string","maxLength":100},"description":{"type":"string","maxLength":2000},"price":{"type":"number","minimum":0},"currentStock":{"type":"number","minimum":0}},"additionalProperties":false},"RetailOrder":{"type":"object","required":["id","orgId","createdAt"],"properties":{"id":{"type":"string"},"number":{"type":"string"},"storeId":{"type":"string"},"customerId":{"type":"string"},"customerName":{"type":"string"},"status":{"type":"string","description":"open | paid | refunded | voided"},"paymentMethod":{"type":"string"},"subtotal":{"type":"number"},"tax":{"type":"number"},"total":{"type":"number"},"currency":{"type":"string"},"reservationId":{"type":"string"},"roomChargeId":{"type":"string"},"orgId":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseRetailOrder":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/RetailOrder"}},"nextPageToken":{"type":["string","null"]}}},"RetailOrderCreateInput":{"type":"object","required":["storeId","items"],"properties":{"storeId":{"type":"string"},"customerId":{"type":"string"},"customerName":{"type":"string","maxLength":300},"tax":{"type":"number","minimum":0},"items":{"type":"array","minItems":1,"items":{"type":"object","required":["name","price","quantity"],"properties":{"retailProductId":{"type":"string"},"name":{"type":"string","maxLength":200},"price":{"type":"number","minimum":0},"quantity":{"type":"number","minimum":0},"notes":{"type":"string","maxLength":1000}},"additionalProperties":false}}},"additionalProperties":false},"LodgingProperty":{"type":"object","required":["id","name","orgId","createdAt"],"properties":{"id":{"type":"string"},"name":{"type":"string"},"address":{"type":"string"},"city":{"type":"string"},"state":{"type":"string"},"country":{"type":"string"},"timezone":{"type":"string"},"phone":{"type":"string"},"orgId":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseLodgingProperty":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/LodgingProperty"}},"nextPageToken":{"type":["string","null"]}}},"LodgingRoomType":{"type":"object","required":["id","name","orgId","createdAt"],"properties":{"id":{"type":"string"},"propertyId":{"type":"string"},"name":{"type":"string"},"description":{"type":"string"},"baseRate":{"type":"number"},"maxOccupancy":{"type":"integer"},"currency":{"type":"string"},"orgId":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseLodgingRoomType":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/LodgingRoomType"}},"nextPageToken":{"type":["string","null"]}}},"LodgingRoom":{"type":"object","required":["id","orgId","createdAt"],"properties":{"id":{"type":"string"},"propertyId":{"type":"string"},"roomTypeId":{"type":"string"},"name":{"type":"string"},"number":{"type":"string"},"floor":{"type":"string"},"status":{"type":"string","description":"available | occupied | dirty | clean | inspected | out-of-order"},"housekeepingState":{"type":"string"},"orgId":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseLodgingRoom":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/LodgingRoom"}},"nextPageToken":{"type":["string","null"]}}},"LodgingReservation":{"type":"object","required":["id","orgId","createdAt"],"properties":{"id":{"type":"string"},"propertyId":{"type":"string"},"roomId":{"type":"string"},"roomTypeId":{"type":"string"},"guestId":{"type":"string"},"guestName":{"type":"string"},"guestEmail":{"type":"string"},"confirmationCode":{"type":"string"},"status":{"type":"string","description":"inquiry | confirmed | checked-in | checked-out | cancelled | no-show"},"checkIn":{"type":"string","format":"date"},"checkOut":{"type":"string","format":"date"},"adults":{"type":"integer"},"children":{"type":"integer"},"baseTotal":{"type":"number"},"roomChargesTotal":{"type":"number"},"taxesTotal":{"type":"number"},"total":{"type":"number"},"currency":{"type":"string"},"source":{"type":"string","description":"direct | airbnb | vrbo | booking.com | etc."},"externalUid":{"type":"string"},"orgId":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseLodgingReservation":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/LodgingReservation"}},"nextPageToken":{"type":["string","null"]}}},"LodgingReservationCreateInput":{"type":"object","required":["propertyId","roomTypeId","checkIn","checkOut","guestName"],"properties":{"propertyId":{"type":"string"},"roomTypeId":{"type":"string"},"checkIn":{"type":"string","format":"date"},"checkOut":{"type":"string","format":"date"},"guestName":{"type":"string","maxLength":300},"guestEmail":{"type":"string","format":"email"},"guestPhone":{"type":"string","maxLength":50},"adults":{"type":"integer","minimum":1,"default":1},"children":{"type":"integer","minimum":0,"default":0},"ratePerNight":{"type":"number","minimum":0},"subtotal":{"type":"number","minimum":0},"taxAmount":{"type":"number","minimum":0},"total":{"type":"number","minimum":0},"status":{"type":"string","enum":["inquiry","confirmed"],"default":"inquiry"},"notes":{"type":"string","maxLength":2000}},"additionalProperties":false},"LodgingRoomCharge":{"type":"object","required":["id","orgId","createdAt"],"properties":{"id":{"type":"string"},"reservationId":{"type":"string"},"propertyId":{"type":"string"},"description":{"type":"string"},"amount":{"type":"number"},"currency":{"type":"string"},"origin":{"type":"string","description":"restaurant | retail | manual | minibar | etc."},"originOrderId":{"type":"string"},"orgId":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseLodgingRoomCharge":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/LodgingRoomCharge"}},"nextPageToken":{"type":["string","null"]}}},"LodgingRoomChargeCreateInput":{"type":"object","required":["reservationId","description","amount"],"properties":{"reservationId":{"type":"string"},"description":{"type":"string","maxLength":500},"category":{"type":"string","enum":["food_beverage","retail","spa","parking","phone","minibar","laundry","other"],"default":"other"},"amount":{"type":"number","minimum":0},"quantity":{"type":"number","minimum":1,"default":1}},"additionalProperties":false},"Invoice":{"type":"object","required":["id","orgId","createdAt"],"properties":{"id":{"type":"string"},"invoiceNumber":{"type":"string"},"quoteId":{"type":"string"},"quoteNumber":{"type":"string"},"opportunityId":{"type":"string"},"opportunityName":{"type":"string"},"accountId":{"type":"string"},"accountName":{"type":"string"},"contactName":{"type":"string"},"contactEmail":{"type":"string"},"status":{"type":"string","description":"unpaid | paid | void"},"totalPrice":{"type":"number"},"invoiceDate":{"type":"string","format":"date"},"dueDate":{"type":"string","format":"date"},"paidAt":{"type":"string","format":"date-time","nullable":true},"paymentLinkUrl":{"type":"string"},"orgId":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseInvoice":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Invoice"}},"nextPageToken":{"type":["string","null"]}}},"Bill":{"type":"object","required":["id","orgId","createdAt"],"properties":{"id":{"type":"string"},"billNumber":{"type":"string"},"vendorId":{"type":"string"},"vendorName":{"type":"string"},"status":{"type":"string","description":"draft | approved | processing | paid | voided"},"totalAmount":{"type":"number"},"date":{"type":"string","format":"date"},"dueDate":{"type":"string","format":"date"},"reference":{"type":"string","description":"Vendor's own invoice number."},"description":{"type":"string"},"source":{"type":"string","description":"manual | email"},"needsReview":{"type":"boolean"},"lines":{"type":"array","items":{"type":"object","properties":{"accountId":{"type":"string"},"accountCode":{"type":"string"},"accountName":{"type":"string"},"description":{"type":"string"},"amount":{"type":"number"}}}},"orgId":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseBill":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Bill"}},"nextPageToken":{"type":["string","null"]}}},"BillCreateInput":{"type":"object","required":["vendorId","date","dueDate","lines"],"properties":{"vendorId":{"type":"string"},"date":{"type":"string","format":"date"},"dueDate":{"type":"string","format":"date"},"reference":{"type":"string","maxLength":200,"description":"Vendor's own invoice number."},"description":{"type":"string","maxLength":2000},"status":{"type":"string","enum":["draft","approved"],"default":"draft"},"lines":{"type":"array","minItems":1,"items":{"type":"object","required":["accountId","amount"],"properties":{"accountId":{"type":"string"},"amount":{"type":"number"},"description":{"type":"string","maxLength":1000}},"additionalProperties":false}}},"additionalProperties":false},"JournalEntry":{"type":"object","required":["id","orgId","createdAt"],"properties":{"id":{"type":"string"},"entryNumber":{"type":"string"},"date":{"type":"string","format":"date"},"description":{"type":"string"},"reference":{"type":"string"},"source":{"type":"string","description":"invoice | bill | payment | manual | payroll | ..."},"totalAmount":{"type":"number"},"lines":{"type":"array","items":{"type":"object","properties":{"accountId":{"type":"string"},"accountCode":{"type":"string"},"accountName":{"type":"string"},"debit":{"type":"number"},"credit":{"type":"number"},"description":{"type":"string"}}}},"orgId":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseJournalEntry":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/JournalEntry"}},"nextPageToken":{"type":["string","null"]}}},"Project":{"type":"object","required":["id","name","orgId","createdAt"],"properties":{"id":{"type":"string"},"name":{"type":"string"},"description":{"type":"string"},"status":{"type":"string","description":"planning | in-progress | on-hold | done | cancelled"},"startDate":{"type":"string","format":"date"},"endDate":{"type":"string","format":"date"},"ownerId":{"type":"string"},"ownerName":{"type":"string"},"budget":{"type":"number"},"currency":{"type":"string"},"progress":{"type":"number","description":"0–1 ratio."},"orgId":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseProject":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Project"}},"nextPageToken":{"type":["string","null"]}}},"ProjectCreateInput":{"type":"object","required":["name"],"properties":{"name":{"type":"string","maxLength":200},"description":{"type":"string","maxLength":5000},"status":{"type":"string","enum":["planning","in-progress","on-hold","done","cancelled"],"default":"planning"},"startDate":{"type":"string","format":"date"},"endDate":{"type":"string","format":"date"},"budget":{"type":"number","minimum":0},"currency":{"type":"string","maxLength":10}},"additionalProperties":false},"Task":{"type":"object","required":["id","title","orgId","createdAt"],"properties":{"id":{"type":"string"},"projectId":{"type":"string"},"title":{"type":"string"},"description":{"type":"string"},"status":{"type":"string","description":"todo | in-progress | blocked | done"},"priority":{"type":"string","description":"low | normal | high | urgent"},"assigneeId":{"type":"string"},"assigneeName":{"type":"string"},"dueDate":{"type":"string","format":"date"},"orgId":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseTask":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Task"}},"nextPageToken":{"type":["string","null"]}}},"TaskCreateInput":{"type":"object","required":["title"],"properties":{"title":{"type":"string","maxLength":300},"description":{"type":"string","maxLength":10000},"projectId":{"type":"string"},"status":{"type":"string","enum":["todo","in-progress","blocked","done"],"default":"todo"},"priority":{"type":"string","enum":["low","normal","high","urgent"],"default":"normal"},"dueDate":{"type":"string","format":"date"}},"additionalProperties":false},"Building":{"type":"object","required":["id","name","orgId","createdAt"],"properties":{"id":{"type":"string"},"name":{"type":"string"},"address":{"type":"string"},"city":{"type":"string"},"state":{"type":"string"},"country":{"type":"string"},"orgId":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseBuilding":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Building"}},"nextPageToken":{"type":["string","null"]}}},"Unit":{"type":"object","required":["id","orgId","createdAt"],"properties":{"id":{"type":"string"},"buildingId":{"type":"string"},"number":{"type":"string"},"name":{"type":"string"},"floor":{"type":"string"},"bedrooms":{"type":"integer"},"bathrooms":{"type":"number"},"squareFeet":{"type":"integer"},"status":{"type":"string"},"tenantName":{"type":"string"},"orgId":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseUnit":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Unit"}},"nextPageToken":{"type":["string","null"]}}},"WorkOrder":{"type":"object","required":["id","title","orgId","createdAt"],"properties":{"id":{"type":"string"},"buildingId":{"type":"string"},"unitId":{"type":"string"},"title":{"type":"string"},"description":{"type":"string"},"status":{"type":"string","description":"open | in-progress | on-hold | done | cancelled"},"priority":{"type":"string"},"assigneeId":{"type":"string"},"assigneeName":{"type":"string"},"dueDate":{"type":"string","format":"date"},"completedAt":{"type":"string","format":"date-time"},"orgId":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseWorkOrder":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/WorkOrder"}},"nextPageToken":{"type":["string","null"]}}},"WorkOrderCreateInput":{"type":"object","required":["title"],"properties":{"title":{"type":"string","maxLength":300},"description":{"type":"string","maxLength":10000},"buildingId":{"type":"string"},"unitId":{"type":"string"},"priority":{"type":"string","enum":["low","normal","high","urgent"],"default":"normal"},"status":{"type":"string","enum":["open","in-progress","on-hold","done","cancelled"],"default":"open"},"dueDate":{"type":"string","format":"date"}},"additionalProperties":false},"Device":{"type":"object","required":["id","name","orgId","createdAt"],"properties":{"id":{"type":"string"},"buildingId":{"type":"string"},"unitId":{"type":"string"},"name":{"type":"string"},"kind":{"type":"string","description":"thermostat | lock | sensor | camera | meter | etc."},"vendor":{"type":"string"},"model":{"type":"string"},"location":{"type":"string"},"status":{"type":"string","description":"online | offline | unknown"},"orgId":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseDevice":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Device"}},"nextPageToken":{"type":["string","null"]}}},"Lease":{"type":"object","required":["id","orgId","createdAt"],"properties":{"id":{"type":"string"},"unitId":{"type":"string"},"unitNumber":{"type":"string"},"tenantId":{"type":"string"},"tenantName":{"type":"string"},"status":{"type":"string","description":"draft | active | ended | evicted"},"startDate":{"type":"string","format":"date"},"endDate":{"type":"string","format":"date"},"rent":{"type":"number"},"deposit":{"type":"number"},"currency":{"type":"string"},"orgId":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseLease":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Lease"}},"nextPageToken":{"type":["string","null"]}}},"Tenant":{"type":"object","required":["id","orgId","createdAt"],"properties":{"id":{"type":"string"},"firstName":{"type":"string"},"lastName":{"type":"string"},"email":{"type":"string"},"phone":{"type":"string"},"unitId":{"type":"string"},"status":{"type":"string"},"orgId":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseTenant":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Tenant"}},"nextPageToken":{"type":["string","null"]}}},"SubscriptionPlan":{"type":"object","required":["id","name","orgId","createdAt"],"properties":{"id":{"type":"string"},"name":{"type":"string"},"description":{"type":"string"},"tier":{"type":"string"},"price":{"type":"number"},"interval":{"type":"string","description":"month | year | week | one-time"},"currency":{"type":"string"},"active":{"type":"boolean"},"orgId":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseSubscriptionPlan":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/SubscriptionPlan"}},"nextPageToken":{"type":["string","null"]}}},"Subscription":{"type":"object","required":["id","orgId","createdAt"],"properties":{"id":{"type":"string"},"planId":{"type":"string"},"memberId":{"type":"string"},"memberName":{"type":"string"},"memberEmail":{"type":"string"},"status":{"type":"string","description":"active | trialing | past_due | canceled"},"startedAt":{"type":"string","format":"date-time"},"currentPeriodStart":{"type":"string","format":"date-time"},"currentPeriodEnd":{"type":"string","format":"date-time"},"orgId":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseSubscription":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Subscription"}},"nextPageToken":{"type":["string","null"]}}},"Runbook":{"type":"object","required":["id","title","authorOrgId","createdAt"],"properties":{"id":{"type":"string"},"title":{"type":"string"},"summary":{"type":"string"},"category":{"type":"string"},"tags":{"type":"array","items":{"type":"string"}},"visibility":{"type":"string","enum":["public","internal"]},"authorOrgId":{"type":"string"},"authorOrgName":{"type":"string"},"templateMode":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseRunbook":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Runbook"}},"nextPageToken":{"type":["string","null"]}}},"FieldServiceJob":{"type":"object","required":["id","orgId","createdAt"],"properties":{"id":{"type":"string"},"title":{"type":"string"},"customerId":{"type":"string"},"customerName":{"type":"string"},"address":{"type":"string"},"status":{"type":"string","description":"scheduled | en-route | on-site | done | cancelled"},"assigneeId":{"type":"string"},"assigneeName":{"type":"string"},"scheduledAt":{"type":"string","format":"date-time"},"completedAt":{"type":"string","format":"date-time"},"orgId":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseFieldServiceJob":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/FieldServiceJob"}},"nextPageToken":{"type":["string","null"]}}},"Website":{"type":"object","required":["id","orgId","createdAt"],"properties":{"id":{"type":"string"},"name":{"type":"string"},"slug":{"type":"string"},"status":{"type":"string"},"publishedAt":{"type":"string","format":"date-time"},"customDomain":{"type":"string"},"templateId":{"type":"string"},"inheritTemplateUpdates":{"type":"boolean"},"orgId":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseWebsite":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Website"}},"nextPageToken":{"type":["string","null"]}}},"Contract":{"type":"object","required":["id","title","orgId","createdAt"],"properties":{"id":{"type":"string"},"title":{"type":"string"},"counterparty":{"type":"string"},"type":{"type":"string"},"status":{"type":"string","description":"draft | sent | signed | active | expired"},"startDate":{"type":"string","format":"date"},"endDate":{"type":"string","format":"date"},"value":{"type":"number"},"currency":{"type":"string"},"orgId":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseContract":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Contract"}},"nextPageToken":{"type":["string","null"]}}},"SignatureRequest":{"type":"object","required":["id","orgId","createdAt"],"properties":{"id":{"type":"string"},"title":{"type":"string"},"status":{"type":"string","description":"sent | viewed | signed | declined | voided"},"signerName":{"type":"string"},"signerEmail":{"type":"string"},"documentUrl":{"type":"string"},"signedAt":{"type":"string","format":"date-time"},"orgId":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseSignatureRequest":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/SignatureRequest"}},"nextPageToken":{"type":["string","null"]}}},"EmailCampaign":{"type":"object","required":["id","orgId","createdAt"],"properties":{"id":{"type":"string"},"name":{"type":"string"},"subject":{"type":"string"},"status":{"type":"string","description":"draft | scheduled | sending | sent | paused"},"audienceId":{"type":"string"},"audienceName":{"type":"string"},"scheduledAt":{"type":"string","format":"date-time"},"sentAt":{"type":"string","format":"date-time"},"recipientCount":{"type":"integer"},"openCount":{"type":"integer"},"clickCount":{"type":"integer"},"orgId":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseEmailCampaign":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/EmailCampaign"}},"nextPageToken":{"type":["string","null"]}}},"Employee":{"type":"object","required":["id","orgId","createdAt"],"properties":{"id":{"type":"string"},"firstName":{"type":"string"},"lastName":{"type":"string"},"email":{"type":"string"},"phone":{"type":"string"},"role":{"type":"string"},"department":{"type":"string"},"status":{"type":"string","description":"active | onboarding | terminated"},"startDate":{"type":"string","format":"date"},"orgId":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseEmployee":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Employee"}},"nextPageToken":{"type":["string","null"]}}},"TravelTrip":{"type":"object","required":["id","orgId","createdAt"],"properties":{"id":{"type":"string"},"name":{"type":"string"},"destination":{"type":"string"},"startDate":{"type":"string","format":"date"},"endDate":{"type":"string","format":"date"},"travelerId":{"type":"string"},"travelerName":{"type":"string"},"status":{"type":"string"},"totalCost":{"type":"number"},"currency":{"type":"string"},"orgId":{"type":"string"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"ListResponseTravelTrip":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/TravelTrip"}},"nextPageToken":{"type":["string","null"]}}}}},"security":[{"bearerAuth":[]},{"oauth2":[]}],"paths":{"/v1/auth/verify":{"get":{"operationId":"verifyAuth","tags":["Auth"],"summary":"Verify the API key and return its org context","description":"Useful for CLI `whoami`, smoke tests, or surfacing the connected org in a UI before a destructive action.","responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuthVerifyResponse"}}}},"401":{"description":"Missing or invalid API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/me":{"get":{"operationId":"getMe","tags":["Auth"],"summary":"Authoritative org + modules + role snapshot for the connected key","description":"Returns the org, active modules, user role (OAuth only), and key scopes in one read. Use to answer \"what is this org?\" / \"what modules are active?\" without scraping the web. Any valid scope authorizes the call.","responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MeResponse"}}}},"401":{"description":"Missing or invalid API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/search":{"get":{"operationId":"searchOrg","tags":["Search"],"summary":"Unified text search across the org","description":"One call, every entity. Substring-matches `q` across all read-scoped entities and returns grouped results. Narrow with `entities=accounts,contacts`. Requires any read scope.","parameters":[{"name":"q","in":"query","required":true,"schema":{"type":"string","minLength":2},"description":"Free-text query. Multi-word queries match when every token appears in *some* searchable field."},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":50,"default":10},"description":"Max matches per entity."},{"name":"entities","in":"query","required":false,"schema":{"type":"string"},"description":"Comma-separated whitelist (e.g. `accounts,contacts`) — narrows which scoped entities are searched."}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SearchResponse"}}}},"400":{"description":"q missing or too short","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}},"401":{"description":"Missing or invalid API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}},"403":{"description":"API key has no read scopes","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/org-context/query":{"post":{"operationId":"queryOrgContext","tags":["Org Context"],"summary":"Ask a natural-language question about the connected org","description":"Single-turn text Q&A grounded in the org's real state (modules enabled, counts, recent activity). Use for \"summarize last week of CRM activity\" / \"what's our pricing tier?\" Required scope: `context:read`.","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrgContextQueryRequest"}}}},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrgContextQueryResponse"}}}},"400":{"description":"Validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/contacts":{"get":{"operationId":"listContacts","tags":["Contacts"],"summary":"List contacts","description":"Paginated list of CRM contacts, newest-first by createdAt. Required scope: `contacts:read` (or `*:read`).","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseContact"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}},"post":{"operationId":"createContact","tags":["Contacts"],"summary":"Create a contact","description":"Required scope: `contacts:write` (or `*:write`).","parameters":[{"name":"Idempotency-Key","in":"header","required":false,"description":"Optional UUID-shaped value. Repeated requests with the same key replay the cached response for 24h.","schema":{"type":"string","maxLength":256}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ContactCreateInput"}}}},"responses":{"201":{"description":"Created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Contact"}}}},"400":{"description":"Validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/accounts":{"get":{"operationId":"listAccounts","tags":["Accounts"],"summary":"List accounts","description":"Read-only in V1. Required scope: `accounts:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseAccount"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/opportunities":{"get":{"operationId":"listOpportunities","tags":["Opportunities"],"summary":"List opportunities","description":"Read-only in V1. Required scope: `opportunities:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseOpportunity"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/quotes":{"get":{"operationId":"listQuotes","tags":["Quotes"],"summary":"List quotes & invoices","description":"Returns the org's quotes and invoices, newest-first. Useful for AI assistants answering \"did we send X a quote?\" or \"what's the status of the Acme renewal invoice?\". Required scope: `quotes:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseQuote"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/products":{"get":{"operationId":"listProducts","tags":["Products"],"summary":"List products","description":"Returns the org's product catalog. Use this to pick line items when assembling quotes, or to look up a product by SKU on the client side. Required scope: `products:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseProduct"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/notes":{"post":{"operationId":"createNote","tags":["Notes"],"summary":"Append a note to an account, opportunity, or contact","description":"Log a follow-up, summarize a meeting, drop a reminder on a CRM record. Cross-org references return 404 to prevent existence probing. Required scope: `notes:write`.","parameters":[{"name":"Idempotency-Key","in":"header","required":false,"description":"Optional UUID-shaped value. Repeated requests with the same key replay the cached response for 24h.","schema":{"type":"string","maxLength":256}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/NoteCreateInput"}}}},"responses":{"201":{"description":"Created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Note"}}}},"400":{"description":"Validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/articles":{"get":{"operationId":"listArticles","tags":["Articles"],"summary":"List articles","description":"Required scope: `articles:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseArticle"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}},"post":{"operationId":"createArticle","tags":["Articles"],"summary":"Create an article","description":"Required scope: `articles:write`. Status is always set to `draft` — publish via the in-app review workflow.","parameters":[{"name":"Idempotency-Key","in":"header","required":false,"description":"Optional UUID-shaped value. Repeated requests with the same key replay the cached response for 24h.","schema":{"type":"string","maxLength":256}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ArticleCreateInput"}}}},"responses":{"201":{"description":"Created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Article"}}}},"400":{"description":"Validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/events":{"get":{"operationId":"listEvents","tags":["Events"],"summary":"List events","description":"Required scope: `events:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseEvent"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}},"post":{"operationId":"createEvent","tags":["Events"],"summary":"Create an event","description":"Required scope: `events:write`.","parameters":[{"name":"Idempotency-Key","in":"header","required":false,"description":"Optional UUID-shaped value. Repeated requests with the same key replay the cached response for 24h.","schema":{"type":"string","maxLength":256}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EventCreateInput"}}}},"responses":{"201":{"description":"Created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Event"}}}},"400":{"description":"Validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/grants":{"get":{"operationId":"listGrants","tags":["Grants"],"summary":"List grant programs your organization offers","description":"Every grant program authored by this org — all statuses (draft/open/closed/awarded/archived) and visibilities. Required scope: `grants:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseGrant"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/restaurants":{"get":{"operationId":"listRestaurants","tags":["Restaurants"],"summary":"List restaurants","description":"Every restaurant operated by this org. Required scope: `restaurants:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseRestaurant"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/menuItems":{"get":{"operationId":"listMenuItems","tags":["MenuItems"],"summary":"List menu items","description":"Every menu item across all restaurants this org runs. Use `restaurantId` on the response to filter client-side. Required scope: `menuItems:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseMenuItem"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}},"post":{"operationId":"createMenuItem","tags":["MenuItems"],"summary":"Create a menu item","description":"Add a menu item to a restaurant in this org. Required scope: `menuItems:write`.","parameters":[{"name":"Idempotency-Key","in":"header","required":false,"description":"Optional UUID-shaped value. Repeated requests with the same key replay the cached response for 24h.","schema":{"type":"string","maxLength":256}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MenuItemCreateInput"}}}},"responses":{"201":{"description":"Created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MenuItem"}}}},"400":{"description":"Validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/restaurantOrders":{"get":{"operationId":"listRestaurantOrders","tags":["RestaurantOrders"],"summary":"List restaurant orders","description":"Restaurant orders/checks newest-first, including paid, voided, and pending. Required scope: `restaurantOrders:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseRestaurantOrder"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}},"post":{"operationId":"createRestaurantOrder","tags":["RestaurantOrders"],"summary":"Open a restaurant order","description":"Open a check with line items. Status defaults to `open`; transition to `paid` via the in-app workflow to drive folio post + inventory drain. Required scope: `restaurantOrders:write`.","parameters":[{"name":"Idempotency-Key","in":"header","required":false,"description":"Optional UUID-shaped value. Repeated requests with the same key replay the cached response for 24h.","schema":{"type":"string","maxLength":256}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RestaurantOrderCreateInput"}}}},"responses":{"201":{"description":"Created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RestaurantOrder"}}}},"400":{"description":"Validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/restaurantTables":{"get":{"operationId":"listRestaurantTables","tags":["RestaurantTables"],"summary":"List restaurant tables","description":"Restaurant tables and their seating. Required scope: `restaurantTables:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseRestaurantTable"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/retailStores":{"get":{"operationId":"listRetailStores","tags":["RetailStores"],"summary":"List retail stores","description":"Retail stores operated by this org. Required scope: `retailStores:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseRetailStore"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/retailProducts":{"get":{"operationId":"listRetailProducts","tags":["RetailProducts"],"summary":"List retail products (SKUs)","description":"Retail catalog. Distinct from CRM `/v1/products` — these are point-of-sale SKUs. Required scope: `retailProducts:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseRetailProduct"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}},"post":{"operationId":"createRetailProduct","tags":["RetailProducts"],"summary":"Create a retail product (SKU)","description":"Add a SKU to a retail store. Required scope: `retailProducts:write`.","parameters":[{"name":"Idempotency-Key","in":"header","required":false,"description":"Optional UUID-shaped value. Repeated requests with the same key replay the cached response for 24h.","schema":{"type":"string","maxLength":256}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RetailProductCreateInput"}}}},"responses":{"201":{"description":"Created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RetailProduct"}}}},"400":{"description":"Validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/retailOrders":{"get":{"operationId":"listRetailOrders","tags":["RetailOrders"],"summary":"List retail orders","description":"POS sales newest-first. Required scope: `retailOrders:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseRetailOrder"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}},"post":{"operationId":"createRetailOrder","tags":["RetailOrders"],"summary":"Open a retail order","description":"Open a POS order with line items. Status defaults to `open`. Required scope: `retailOrders:write`.","parameters":[{"name":"Idempotency-Key","in":"header","required":false,"description":"Optional UUID-shaped value. Repeated requests with the same key replay the cached response for 24h.","schema":{"type":"string","maxLength":256}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RetailOrderCreateInput"}}}},"responses":{"201":{"description":"Created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RetailOrder"}}}},"400":{"description":"Validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/lodgingProperties":{"get":{"operationId":"listLodgingProperties","tags":["LodgingProperties"],"summary":"List lodging properties","description":"Lodging properties operated by this org. Required scope: `lodgingProperties:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseLodgingProperty"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/lodgingRoomTypes":{"get":{"operationId":"listLodgingRoomTypes","tags":["LodgingRoomTypes"],"summary":"List lodging room types","description":"Room types and base rates. Required scope: `lodgingRoomTypes:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseLodgingRoomType"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/lodgingRooms":{"get":{"operationId":"listLodgingRooms","tags":["LodgingRooms"],"summary":"List lodging rooms","description":"Individual rooms across this org's properties. Required scope: `lodgingRooms:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseLodgingRoom"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/lodgingReservations":{"get":{"operationId":"listLodgingReservations","tags":["LodgingReservations"],"summary":"List lodging reservations","description":"Reservations across all stays — past, current, future. Required scope: `lodgingReservations:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseLodgingReservation"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}},"post":{"operationId":"createLodgingReservation","tags":["LodgingReservations"],"summary":"Create a lodging reservation","description":"Book a stay. Status defaults to `inquiry`; pass `confirmed` only when payment is held. Pre-compute `subtotal/total` via the rate-plan resolver client-side or pass `ratePerNight` for naive multiply. Required scope: `lodgingReservations:write`.","parameters":[{"name":"Idempotency-Key","in":"header","required":false,"description":"Optional UUID-shaped value. Repeated requests with the same key replay the cached response for 24h.","schema":{"type":"string","maxLength":256}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LodgingReservationCreateInput"}}}},"responses":{"201":{"description":"Created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LodgingReservation"}}}},"400":{"description":"Validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/lodgingRoomCharges":{"get":{"operationId":"listLodgingRoomCharges","tags":["LodgingRoomCharges"],"summary":"List folio room charges","description":"Charges posted to a guest's folio (room-charge bus across Restaurant + Retail). Required scope: `lodgingRoomCharges:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseLodgingRoomCharge"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}},"post":{"operationId":"createLodgingRoomCharge","tags":["LodgingRoomCharges"],"summary":"Post a folio room charge","description":"Direct folio post (manual source). Use this for incidentals (parking, spa, minibar). Restaurant/Retail orders auto-post their own charges via paymentMethod=room-charge. Required scope: `lodgingRoomCharges:write`.","parameters":[{"name":"Idempotency-Key","in":"header","required":false,"description":"Optional UUID-shaped value. Repeated requests with the same key replay the cached response for 24h.","schema":{"type":"string","maxLength":256}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LodgingRoomChargeCreateInput"}}}},"responses":{"201":{"description":"Created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LodgingRoomCharge"}}}},"400":{"description":"Validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/invoices":{"get":{"operationId":"listInvoices","tags":["Invoices"],"summary":"List invoices","description":"Customer-facing invoices (CPQ-issued), newest-first. Required scope: `invoices:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseInvoice"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/bills":{"get":{"operationId":"listBills","tags":["Bills"],"summary":"List bills","description":"Vendor bills (AP). Includes forwarded-email expenses (source=email). Required scope: `bills:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseBill"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}},"post":{"operationId":"createBill","tags":["Bills"],"summary":"Record a vendor bill","description":"Record an AP bill with line items. Status defaults to `draft`. Each line's `accountId` must reference this org's chart of accounts. Required scope: `bills:write`.","parameters":[{"name":"Idempotency-Key","in":"header","required":false,"description":"Optional UUID-shaped value. Repeated requests with the same key replay the cached response for 24h.","schema":{"type":"string","maxLength":256}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BillCreateInput"}}}},"responses":{"201":{"description":"Created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Bill"}}}},"400":{"description":"Validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/journalEntries":{"get":{"operationId":"listJournalEntries","tags":["JournalEntries"],"summary":"List GL journal entries","description":"Hash-chained journal entries newest-first. Each line carries debit/credit + GL account. Required scope: `journalEntries:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseJournalEntry"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/projects":{"get":{"operationId":"listProjects","tags":["Projects"],"summary":"List projects","description":"Projects with status, budget, and dates. Required scope: `projects:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseProject"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}},"post":{"operationId":"createProject","tags":["Projects"],"summary":"Create a project","description":"Create a new project. Required scope: `projects:write`.","parameters":[{"name":"Idempotency-Key","in":"header","required":false,"description":"Optional UUID-shaped value. Repeated requests with the same key replay the cached response for 24h.","schema":{"type":"string","maxLength":256}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProjectCreateInput"}}}},"responses":{"201":{"description":"Created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Project"}}}},"400":{"description":"Validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/tasks":{"get":{"operationId":"listTasks","tags":["Tasks"],"summary":"List tasks","description":"Work items, optionally filtered by `projectId` on the response. Required scope: `tasks:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseTask"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}},"post":{"operationId":"createTask","tags":["Tasks"],"summary":"Create a task","description":"Create a task, optionally linked to a project. Required scope: `tasks:write`.","parameters":[{"name":"Idempotency-Key","in":"header","required":false,"description":"Optional UUID-shaped value. Repeated requests with the same key replay the cached response for 24h.","schema":{"type":"string","maxLength":256}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskCreateInput"}}}},"responses":{"201":{"description":"Created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Task"}}}},"400":{"description":"Validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/buildings":{"get":{"operationId":"listBuildings","tags":["Buildings"],"summary":"List buildings","description":"Buildings managed by this org. Required scope: `buildings:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseBuilding"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/units":{"get":{"operationId":"listUnits","tags":["Units"],"summary":"List units","description":"Units (apartments, suites, lots) inside this org's buildings. Required scope: `units:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseUnit"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/workOrders":{"get":{"operationId":"listWorkOrders","tags":["WorkOrders"],"summary":"List work orders","description":"Maintenance and service work orders. Required scope: `workOrders:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseWorkOrder"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}},"post":{"operationId":"createWorkOrder","tags":["WorkOrders"],"summary":"Create a work order","description":"Create a maintenance or service work order. Required scope: `workOrders:write`.","parameters":[{"name":"Idempotency-Key","in":"header","required":false,"description":"Optional UUID-shaped value. Repeated requests with the same key replay the cached response for 24h.","schema":{"type":"string","maxLength":256}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WorkOrderCreateInput"}}}},"responses":{"201":{"description":"Created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WorkOrder"}}}},"400":{"description":"Validation error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/devices":{"get":{"operationId":"listDevices","tags":["Devices"],"summary":"List property IoT devices","description":"Vendor-neutral IoT devices wired into Property Operations. Required scope: `devices:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseDevice"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/leases":{"get":{"operationId":"listLeases","tags":["Leases"],"summary":"List leases","description":"Active and historical rental leases. Required scope: `leases:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseLease"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/tenants":{"get":{"operationId":"listTenants","tags":["Tenants"],"summary":"List tenants","description":"Tenants of rental units. Required scope: `tenants:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseTenant"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/subscriptionPlans":{"get":{"operationId":"listSubscriptionPlans","tags":["SubscriptionPlans"],"summary":"List subscription plans","description":"Membership tiers, tithing levels, donation tiers. Required scope: `subscriptionPlans:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseSubscriptionPlan"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/subscriptions":{"get":{"operationId":"listSubscriptions","tags":["Subscriptions"],"summary":"List subscriptions","description":"Member subscriptions tied to plans. Required scope: `subscriptions:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseSubscription"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/runbooks":{"get":{"operationId":"listRunbooks","tags":["Runbooks"],"summary":"List runbooks","description":"Step-by-step operational guides. Required scope: `runbooks:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseRunbook"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/fieldServiceJobs":{"get":{"operationId":"listFieldServiceJobs","tags":["FieldServiceJobs"],"summary":"List field service jobs","description":"Dispatch jobs (visits, repairs, install). Required scope: `fieldServiceJobs:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseFieldServiceJob"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/websites":{"get":{"operationId":"listWebsites","tags":["Websites"],"summary":"List Builder sites","description":"Sites authored in Builder. Required scope: `websites:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseWebsite"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/contracts":{"get":{"operationId":"listContracts","tags":["Contracts"],"summary":"List contracts","description":"Contracts (master service agreements, NDAs, statements of work). Required scope: `contracts:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseContract"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/signatures":{"get":{"operationId":"listSignatures","tags":["Signatures"],"summary":"List signature requests","description":"E-signature requests. Required scope: `signatures:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseSignatureRequest"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/emailCampaigns":{"get":{"operationId":"listEmailCampaigns","tags":["EmailCampaigns"],"summary":"List email campaigns","description":"Email campaigns with metrics (opens, clicks, sends). Required scope: `emailCampaigns:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseEmailCampaign"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/employees":{"get":{"operationId":"listEmployees","tags":["Employees"],"summary":"List employees","description":"Workforce roster. Required scope: `employees:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseEmployee"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}},"/v1/travelTrips":{"get":{"operationId":"listTravelTrips","tags":["TravelTrips"],"summary":"List travel trips","description":"Business trips with bookings (flights, hotels, ground). Required scope: `travelTrips:read`.","parameters":[{"name":"limit","in":"query","required":false,"description":"Max records to return on this page (1–500).","schema":{"type":"integer","minimum":1,"maximum":500,"default":100}},{"name":"pageToken","in":"query","required":false,"description":"Opaque cursor returned by a prior call's `nextPageToken`. Omit for the first page.","schema":{"type":"string"}},{"name":"createdAfter","in":"query","required":false,"description":"Inclusive lower bound on `createdAt` as ISO 8601 (e.g. 2026-04-30T00:00:00Z). Use to scope a listing to a time window — \"what changed since last week\" — instead of paginating the whole collection.","schema":{"type":"string","format":"date-time"}},{"name":"createdBefore","in":"query","required":false,"description":"Exclusive upper bound on `createdAt` as ISO 8601. Pair with `createdAfter` to bound both sides.","schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListResponseTravelTrip"}}}},"401":{"description":"Unauthorized","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorEnvelope"}}}}}}}}}