{"openapi":"3.1.0","info":{"title":"Brex Budgets (BYOK) API","version":"0.1.0","description":"Brex Budgets (BYOK) lets an AI assistant read your own Brex Budgets data through the Brex Budgets API with a key you supply (Brex user token with read scopes for budgets and fields). Read-only: 9 tools (list_budget_programs, get_budget_program, list_budgets, get_budget, list_spend_limits, get_spend_limit, list_custom_fields, get_custom_field, list_custom_field_values). The BYOK key travels with...\n\nEvery operation is read-only or compute-only. The same tools are available over MCP (streamable HTTP) at https://byok-brex-budgets-fields.connectorbay.com/mcp.","contact":{"name":"Unify Dynamics LLC","email":"agent@connectorbay.com","url":"https://connectorbay.com/byok-brex-budgets-fields/docs"},"termsOfService":"https://connectorbay.com/byok-brex-budgets-fields/terms"},"servers":[{"url":"https://byok-brex-budgets-fields.connectorbay.com"}],"externalDocs":{"url":"https://connectorbay.com/byok-brex-budgets-fields/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_budget_programs":{"post":{"operationId":"list_budget_programs","summary":"List budget programs (templates that create budgets for groups of employees) with blueprints, existing budget ids and st","description":"List budget programs (templates that create budgets for groups of employees) with blueprints, existing budget ids and status. Owner and member user ids are not returned. Use for \"Which Brex budget programs do we run\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"cursor":{"anyOf":[{"maxLength":300,"type":"string"},{"type":"null"}],"default":null,"description":"Pagination cursor: the next_cursor value of the previous page; leave empty for the first page.","title":"Cursor"},"limit":{"anyOf":[{"maximum":1000,"minimum":1,"type":"integer"},{"type":"null"}],"default":null,"description":"Maximum items per page (Brex default applies when empty; page on with next_cursor).","title":"Limit"}},"title":"list_budget_programsArguments","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_budget_program":{"post":{"operationId":"get_budget_program","summary":"Get one Brex budget program by id with its blueprints, linked budget ids and status. Use for \"What does Brex budget prog","description":"Get one Brex budget program by id with its blueprints, linked budget ids and status. Use for \"What does Brex budget program bp_1 define\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"id":{"description":"Budget program id.","maxLength":200,"title":"Id","type":"string"}},"required":["id"],"title":"get_budget_programArguments","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_budgets":{"post":{"operationId":"list_budgets","summary":"List Brex budgets with name, parent budget, period, dates, amount and status. Owner and member user ids are not returned","description":"List Brex budgets with name, parent budget, period, dates, amount and status. Owner and member user ids are not returned. Use for \"What budgets do we have in Brex and how big are they\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"cursor":{"anyOf":[{"maxLength":300,"type":"string"},{"type":"null"}],"default":null,"description":"Pagination cursor: the next_cursor value of the previous page; leave empty for the first page.","title":"Cursor"},"limit":{"anyOf":[{"maximum":1000,"minimum":1,"type":"integer"},{"type":"null"}],"default":null,"description":"Maximum items per page (Brex default applies when empty; page on with next_cursor).","title":"Limit"}},"title":"list_budgetsArguments","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_budget":{"post":{"operationId":"get_budget","summary":"Get one Brex budget by id with period, dates, amount, status and limit type. Use for \"What is the amount of Brex budget ","description":"Get one Brex budget by id with period, dates, amount, status and limit type. Use for \"What is the amount of Brex budget bud_1\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"id":{"description":"Budget id.","maxLength":200,"title":"Id","type":"string"}},"required":["id"],"title":"get_budgetArguments","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_spend_limits":{"post":{"operationId":"list_spend_limits","summary":"List Brex spend limits with name, status, period, spend type, per-transaction limit, visibility, current period balance,","description":"List Brex spend limits with name, status, period, spend type, per-transaction limit, visibility, current period balance, department and legal entity. Owner and member user ids are not returned. Use for \"Which Brex spend limits are active and how much is left in each\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"cursor":{"anyOf":[{"maxLength":300,"type":"string"},{"type":"null"}],"default":null,"description":"Pagination cursor: the next_cursor value of the previous page; leave empty for the first page.","title":"Cursor"},"limit":{"anyOf":[{"maximum":1000,"minimum":1,"type":"integer"},{"type":"null"}],"default":null,"description":"Maximum items per page (Brex default applies when empty; page on with next_cursor).","title":"Limit"}},"title":"list_spend_limitsArguments","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_spend_limit":{"post":{"operationId":"get_spend_limit","summary":"Get one Brex spend limit by id with status, period, spend type, per-transaction limit and current period balance. Owner ","description":"Get one Brex spend limit by id with status, period, spend type, per-transaction limit and current period balance. Owner and member user ids are not returned. Use for \"How much of Brex spend limit sl_1 has been used this period\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"id":{"description":"Spend limit id.","maxLength":200,"title":"Id","type":"string"}},"required":["id"],"title":"get_spend_limitArguments","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_custom_fields":{"post":{"operationId":"list_custom_fields","summary":"List custom accounting fields (such as cost center or project) defined in Brex with name, remote id, group and whether d","description":"List custom accounting fields (such as cost center or project) defined in Brex with name, remote id, group and whether disabled. Use for \"Which custom fields does Brex have for expense coding\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"cursor":{"anyOf":[{"maxLength":300,"type":"string"},{"type":"null"}],"default":null,"description":"Pagination cursor: the next_cursor value of the previous page; leave empty for the first page.","title":"Cursor"},"limit":{"anyOf":[{"maximum":1000,"minimum":1,"type":"integer"},{"type":"null"}],"default":null,"description":"Maximum items per page (Brex default applies when empty; page on with next_cursor).","title":"Limit"}},"title":"list_custom_fieldsArguments","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_custom_field":{"post":{"operationId":"get_custom_field","summary":"Get one Brex custom field by id with name, remote id, group and disabled state. Use for \"What is Brex custom field cf_1\"","description":"Get one Brex custom field by id with name, remote id, group and disabled state. Use for \"What is Brex custom field cf_1\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"id":{"description":"Field Brex id.","maxLength":200,"title":"Id","type":"string"}},"required":["id"],"title":"get_custom_fieldArguments","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_custom_field_values":{"post":{"operationId":"list_custom_field_values","summary":"List the allowed values of one Brex custom field, optionally filtered by value text. Use for \"What values can the Cost c","description":"List the allowed values of one Brex custom field, optionally filtered by value text. Use for \"What values can the Cost center field take in Brex\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"field_id":{"description":"Field Brex id.","maxLength":200,"title":"Field Id","type":"string"},"value":{"anyOf":[{"maxLength":200,"type":"string"},{"type":"null"}],"default":null,"description":"Only values equal to this text.","title":"Value"},"cursor":{"anyOf":[{"maxLength":300,"type":"string"},{"type":"null"}],"default":null,"description":"Pagination cursor: the next_cursor value of the previous page; leave empty for the first page.","title":"Cursor"},"limit":{"anyOf":[{"maximum":1000,"minimum":1,"type":"integer"},{"type":"null"}],"default":null,"description":"Maximum items per page (Brex default applies when empty; page on with next_cursor).","title":"Limit"}},"required":["field_id"],"title":"list_custom_field_valuesArguments","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}}}}