{"openapi":"3.1.0","info":{"title":"Apicbase Stock, Counts and Waste (your key) API","version":"0.1.0","description":"Apicbase Stock, Counts and Waste (your key) lets an AI assistant read your own Apicbase Inventory data through the Apicbase Inventory API with a key you supply (Apicbase API access token). Read-only: 12 tools (list_inventory_stock_items, list_stock_levels, get_stock_item_level, list_count_events, list_waste_events, list_creation_events, list_incoming_transfers, list_outgoing_transfers,...\n\nEvery operation is read-only or compute-only. The same tools are available over MCP (streamable HTTP) at https://byok-apicbase-inventory.connectorbay.com/mcp.","contact":{"name":"Unify Dynamics LLC","email":"agent@connectorbay.com","url":"https://connectorbay.com/byok-apicbase-inventory/docs"},"termsOfService":"https://connectorbay.com/byok-apicbase-inventory/terms"},"servers":[{"url":"https://byok-apicbase-inventory.connectorbay.com"}],"externalDocs":{"url":"https://connectorbay.com/byok-apicbase-inventory/docs"},"security":[{"upstreamKey":[]}],"components":{"securitySchemes":{"bearer":{"type":"http","scheme":"bearer","description":"Optional. A Pro API key raises rate limits; no credentials are required."},"upstreamKey":{"type":"apiKey","in":"header","name":"X-Upstream-Key","description":"Your own key for the service this connector wraps (bring your own key). Used for that one call only; never stored, logged or cached."}},"schemas":{"Error":{"type":"object","properties":{"ok":{"const":false},"error":{"type":"object"}}}}},"paths":{"/v1/tools/list_inventory_stock_items":{"post":{"operationId":"list_inventory_stock_items","summary":"List the stock items an outlet keeps in inventory with content, ingredient, average price and active flag. Use for \"Whic","description":"List the stock items an outlet keeps in inventory with content, ingredient, average price and active flag. Use for \"Which stock items does outlet 829100725420008 keep in Apicbase\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"outlet_id":{"description":"Outlet ID (from the library connector's list_outlets).","maxLength":32,"title":"Outlet Id","type":"string"},"page":{"anyOf":[{"maximum":100000,"minimum":1,"type":"integer"},{"type":"null"}],"default":1,"description":"Page number, starting at 1.","title":"Page"}},"required":["outlet_id"],"title":"list_inventory_stock_itemsArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/list_stock_levels":{"post":{"operationId":"list_stock_levels","summary":"List current stock per item at one outlet: quantity, stock value, par level and minimum quantity. Use for \"How much stoc","description":"List current stock per item at one outlet: quantity, stock value, par level and minimum quantity. Use for \"How much stock does my Apicbase outlet hold right now\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"outlet_id":{"description":"Outlet ID (from the library connector's list_outlets).","maxLength":32,"title":"Outlet Id","type":"string"},"countable_only":{"anyOf":[{"type":"boolean"},{"type":"null"}],"default":null,"description":"True to list only items that can be counted.","title":"Countable Only"},"page":{"anyOf":[{"maximum":100000,"minimum":1,"type":"integer"},{"type":"null"}],"default":1,"description":"Page number, starting at 1.","title":"Page"}},"required":["outlet_id"],"title":"list_stock_levelsArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/get_stock_item_level":{"post":{"operationId":"get_stock_item_level","summary":"Get one stock item's inventory at an outlet: quantity, value, par, minimum, storage locations and the totals including l","description":"Get one stock item's inventory at an outlet: quantity, value, par, minimum, storage locations and the totals including linked items. Use for \"How many Cola cans does outlet 829100725420008 have in Apicbase\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"outlet_id":{"description":"Outlet ID (from the library connector's list_outlets).","maxLength":32,"title":"Outlet Id","type":"string"},"stock_item_id":{"description":"Stock item ID.","maxLength":32,"title":"Stock Item Id","type":"string"}},"required":["outlet_id","stock_item_id"],"title":"get_stock_item_levelArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/list_count_events":{"post":{"operationId":"list_count_events","summary":"List stock counts (top counts) of one outlet with name, status, dates, remarks and stock value difference. Use for \"When","description":"List stock counts (top counts) of one outlet with name, status, dates, remarks and stock value difference. Use for \"When were the last stock counts at my Apicbase outlet\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"outlet_id":{"description":"Outlet ID (from the library connector's list_outlets).","maxLength":32,"title":"Outlet Id","type":"string"},"status":{"anyOf":[{"enum":["0","1","2"],"type":"string"},{"type":"null"}],"default":null,"description":"Only events with this status: 0 opened, 1 reopened, 2 closed.","title":"Status"},"ordering":{"anyOf":[{"maxLength":40,"type":"string"},{"type":"null"}],"default":null,"description":"Field to sort by; prefix with - for descending (for example -created).","title":"Ordering"},"page":{"anyOf":[{"maximum":100000,"minimum":1,"type":"integer"},{"type":"null"}],"default":1,"description":"Page number, starting at 1.","title":"Page"}},"required":["outlet_id"],"title":"list_count_eventsArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/list_waste_events":{"post":{"operationId":"list_waste_events","summary":"List waste events of one outlet with name, status, dates, remarks and stock value lost. Use for \"How much waste was logg","description":"List waste events of one outlet with name, status, dates, remarks and stock value lost. Use for \"How much waste was logged at my Apicbase outlet\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"outlet_id":{"description":"Outlet ID (from the library connector's list_outlets).","maxLength":32,"title":"Outlet Id","type":"string"},"status":{"anyOf":[{"enum":["0","1","2"],"type":"string"},{"type":"null"}],"default":null,"description":"Only events with this status: 0 opened, 1 reopened, 2 closed.","title":"Status"},"ordering":{"anyOf":[{"maxLength":40,"type":"string"},{"type":"null"}],"default":null,"description":"Field to sort by; prefix with - for descending (for example -created).","title":"Ordering"},"page":{"anyOf":[{"maximum":100000,"minimum":1,"type":"integer"},{"type":"null"}],"default":1,"description":"Page number, starting at 1.","title":"Page"}},"required":["outlet_id"],"title":"list_waste_eventsArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/list_creation_events":{"post":{"operationId":"list_creation_events","summary":"List production (creation) events of one outlet with name, status, dates, remarks and stock value. Use for \"What was pro","description":"List production (creation) events of one outlet with name, status, dates, remarks and stock value. Use for \"What was produced at my Apicbase outlet\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"outlet_id":{"description":"Outlet ID (from the library connector's list_outlets).","maxLength":32,"title":"Outlet Id","type":"string"},"status":{"anyOf":[{"enum":["0","1","2"],"type":"string"},{"type":"null"}],"default":null,"description":"Only events with this status: 0 opened, 1 reopened, 2 closed.","title":"Status"},"ordering":{"anyOf":[{"maxLength":40,"type":"string"},{"type":"null"}],"default":null,"description":"Field to sort by; prefix with - for descending (for example -created).","title":"Ordering"},"page":{"anyOf":[{"maximum":100000,"minimum":1,"type":"integer"},{"type":"null"}],"default":1,"description":"Page number, starting at 1.","title":"Page"}},"required":["outlet_id"],"title":"list_creation_eventsArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/list_incoming_transfers":{"post":{"operationId":"list_incoming_transfers","summary":"List stock transfers received by one outlet from other outlets, with status, dates and stock value. Use for \"Which trans","description":"List stock transfers received by one outlet from other outlets, with status, dates and stock value. Use for \"Which transfers came into my Apicbase outlet\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"outlet_id":{"description":"Outlet ID (from the library connector's list_outlets).","maxLength":32,"title":"Outlet Id","type":"string"},"status":{"anyOf":[{"enum":["0","1","2"],"type":"string"},{"type":"null"}],"default":null,"description":"Only events with this status: 0 opened, 1 reopened, 2 closed.","title":"Status"},"ordering":{"anyOf":[{"maxLength":40,"type":"string"},{"type":"null"}],"default":null,"description":"Field to sort by; prefix with - for descending (for example -created).","title":"Ordering"},"page":{"anyOf":[{"maximum":100000,"minimum":1,"type":"integer"},{"type":"null"}],"default":1,"description":"Page number, starting at 1.","title":"Page"}},"required":["outlet_id"],"title":"list_incoming_transfersArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/list_outgoing_transfers":{"post":{"operationId":"list_outgoing_transfers","summary":"List stock transfers sent from one outlet to other outlets, with in-progress flag, dates and stock value. Use for \"Which","description":"List stock transfers sent from one outlet to other outlets, with in-progress flag, dates and stock value. Use for \"Which transfers left my Apicbase outlet\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"outlet_id":{"description":"Outlet ID (from the library connector's list_outlets).","maxLength":32,"title":"Outlet Id","type":"string"},"status":{"anyOf":[{"enum":["0","1","2"],"type":"string"},{"type":"null"}],"default":null,"description":"Only events with this status: 0 opened, 1 reopened, 2 closed.","title":"Status"},"ordering":{"anyOf":[{"maxLength":40,"type":"string"},{"type":"null"}],"default":null,"description":"Field to sort by; prefix with - for descending (for example -created).","title":"Ordering"},"page":{"anyOf":[{"maximum":100000,"minimum":1,"type":"integer"},{"type":"null"}],"default":1,"description":"Page number, starting at 1.","title":"Page"}},"required":["outlet_id"],"title":"list_outgoing_transfersArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/list_manual_sales_events":{"post":{"operationId":"list_manual_sales_events","summary":"List manual sales events of one outlet (sales entered by hand) with status, dates and stock value. Use for \"What manual ","description":"List manual sales events of one outlet (sales entered by hand) with status, dates and stock value. Use for \"What manual sales were entered at my Apicbase outlet\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"outlet_id":{"description":"Outlet ID (from the library connector's list_outlets).","maxLength":32,"title":"Outlet Id","type":"string"},"status":{"anyOf":[{"enum":["0","1","2"],"type":"string"},{"type":"null"}],"default":null,"description":"Only events with this status: 0 opened, 1 reopened, 2 closed.","title":"Status"},"page":{"anyOf":[{"maximum":100000,"minimum":1,"type":"integer"},{"type":"null"}],"default":1,"description":"Page number, starting at 1.","title":"Page"}},"required":["outlet_id"],"title":"list_manual_sales_eventsArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/list_stock_periods":{"post":{"operationId":"list_stock_periods","summary":"List the stock periods (accounting periods) of one outlet with status, dates and opening and closing stock value. Use fo","description":"List the stock periods (accounting periods) of one outlet with status, dates and opening and closing stock value. Use for \"What stock periods does my Apicbase outlet have\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"outlet_id":{"description":"Outlet ID (from the library connector's list_outlets).","maxLength":32,"title":"Outlet Id","type":"string"},"status":{"anyOf":[{"maxLength":20,"type":"string"},{"type":"null"}],"default":null,"description":"Only periods with this status, for example OPEN or CLOSED.","title":"Status"},"page":{"anyOf":[{"maximum":100000,"minimum":1,"type":"integer"},{"type":"null"}],"default":1,"description":"Page number, starting at 1.","title":"Page"}},"required":["outlet_id"],"title":"list_stock_periodsArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/get_stock_period_summary":{"post":{"operationId":"get_stock_period_summary","summary":"Get the summary of one stock period: opening and closing stock, goods received, production, transfers, sales, waste, cou","description":"Get the summary of one stock period: opening and closing stock, goods received, production, transfers, sales, waste, counts and variance. Use for \"Summarize stock period 794100593140001 at my Apicbase outlet\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"outlet_id":{"description":"Outlet ID (from the library connector's list_outlets).","maxLength":32,"title":"Outlet Id","type":"string"},"period_id":{"description":"Stock period ID (from list_stock_periods).","maxLength":32,"title":"Period Id","type":"string"}},"required":["outlet_id","period_id"],"title":"get_stock_period_summaryArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}},"/v1/tools/list_inventory_event_log":{"post":{"operationId":"list_inventory_event_log","summary":"List the inventory event log of one outlet: each stock movement with type, date, quantity, value and resulting stock. Ca","description":"List the inventory event log of one outlet: each stock movement with type, date, quantity, value and resulting stock. Can filter by event type. Use for \"What stock movements happened at my Apicbase outlet\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"outlet_id":{"description":"Outlet ID (from the library connector's list_outlets).","maxLength":32,"title":"Outlet Id","type":"string"},"event_type":{"anyOf":[{"maxLength":30,"type":"string"},{"type":"null"}],"default":null,"description":"Only movements of this type, for example COUNT, WASTE or DELIVERY.","title":"Event Type"},"page":{"anyOf":[{"maximum":100000,"minimum":1,"type":"integer"},{"type":"null"}],"default":1,"description":"Page number, starting at 1.","title":"Page"}},"required":["outlet_id"],"title":"list_inventory_event_logArguments","type":"object"}}}},"responses":{"200":{"description":"Tool result. `ok: true` on success; `ok: false` with a structured `error` (provider_unavailable, upstream_error, bad_input) when the tool could not answer.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"422":{"description":"Arguments failed validation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded (see Retry-After)","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-read-only":true}}}}