{"openapi":"3.1.0","info":{"title":"Cloudflare Magic Transit (BYOK) API","version":"0.1.0","description":"Cloudflare Magic Transit (BYOK) lets an AI assistant read your own Cloudflare Magic Transit data through the Cloudflare Magic Transit API with a key you supply (Cloudflare API token with Magic Transit and Magic WAN read permission). Read-only: 9 tools (list_sites, list_site_lans, list_gre_tunnels, list_ipsec_tunnels, list_interconnects, list_static_routes, list_connectors, list_account_apps,...\n\nEvery operation is read-only or compute-only. The same tools are available over MCP (streamable HTTP) at https://byok-cloudflare-magic-transit.connectorbay.com/mcp.","contact":{"name":"Unify Dynamics LLC","email":"agent@connectorbay.com","url":"https://connectorbay.com/byok-cloudflare-magic-transit/docs"},"termsOfService":"https://connectorbay.com/byok-cloudflare-magic-transit/terms"},"servers":[{"url":"https://byok-cloudflare-magic-transit.connectorbay.com"}],"externalDocs":{"url":"https://connectorbay.com/byok-cloudflare-magic-transit/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_sites":{"post":{"operationId":"list_sites","summary":"List Magic WAN sites with name, description, high availability mode and connector ids. Needs Magic WAN or Magic Transit ","description":"List Magic WAN sites with name, description, high availability mode and connector ids. Needs Magic WAN or Magic Transit on the account. Use for \"Which Magic WAN sites do I have\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"account_id":{"description":"Cloudflare account id (32-character hex string shown in the dashboard URL, or from the Cloudflare connector's list_accounts).","maxLength":40,"title":"Account Id","type":"string"},"connector_id":{"anyOf":[{"maxLength":64,"type":"string"},{"type":"null"}],"default":null,"description":"Only sites that use this connector id.","title":"Connector Id"}},"required":["account_id"],"title":"list_sitesArguments","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_site_lans":{"post":{"operationId":"list_site_lans","summary":"List the LANs of a Magic WAN site with VLAN, physical port, breakout and prioritization flags and routed subnets. Needs ","description":"List the LANs of a Magic WAN site with VLAN, physical port, breakout and prioritization flags and routed subnets. Needs Magic WAN or Magic Transit on the account. Use for \"Which LANs does site c4c7f0a2-2b1f-4a54-9a5e-7d3e9f1b2c3d have\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"account_id":{"description":"Cloudflare account id (32-character hex string shown in the dashboard URL, or from the Cloudflare connector's list_accounts).","maxLength":40,"title":"Account Id","type":"string"},"site_id":{"description":"Magic WAN site id, as returned by list_sites.","maxLength":64,"title":"Site Id","type":"string"}},"required":["account_id","site_id"],"title":"list_site_lansArguments","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_gre_tunnels":{"post":{"operationId":"list_gre_tunnels","summary":"List Magic GRE tunnels with endpoints, interface address, MTU, TTL, BGP status and health check settings. Needs Magic WA","description":"List Magic GRE tunnels with endpoints, interface address, MTU, TTL, BGP status and health check settings. Needs Magic WAN or Magic Transit on the account. Use for \"Which GRE tunnels are configured in Magic WAN\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"account_id":{"description":"Cloudflare account id (32-character hex string shown in the dashboard URL, or from the Cloudflare connector's list_accounts).","maxLength":40,"title":"Account Id","type":"string"}},"required":["account_id"],"title":"list_gre_tunnelsArguments","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_ipsec_tunnels":{"post":{"operationId":"list_ipsec_tunnels","summary":"List Magic IPsec tunnels with endpoints, interface address, replay protection, BGP status and health check settings. Pre","description":"List Magic IPsec tunnels with endpoints, interface address, replay protection, BGP status and health check settings. Pre-shared keys are never returned. Needs Magic WAN or Magic Transit on the account. Use for \"Which IPsec tunnels are configured in Magic WAN\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"account_id":{"description":"Cloudflare account id (32-character hex string shown in the dashboard URL, or from the Cloudflare connector's list_accounts).","maxLength":40,"title":"Account Id","type":"string"}},"required":["account_id"],"title":"list_ipsec_tunnelsArguments","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_interconnects":{"post":{"operationId":"list_interconnects","summary":"List Cloudflare Network Interconnects used by Magic with colo, interface address, MTU and health check settings. Needs M","description":"List Cloudflare Network Interconnects used by Magic with colo, interface address, MTU and health check settings. Needs Magic WAN or Magic Transit on the account. Use for \"Which network interconnects does my Magic WAN use\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"account_id":{"description":"Cloudflare account id (32-character hex string shown in the dashboard URL, or from the Cloudflare connector's list_accounts).","maxLength":40,"title":"Account Id","type":"string"}},"required":["account_id"],"title":"list_interconnectsArguments","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_static_routes":{"post":{"operationId":"list_static_routes","summary":"List Magic static routes with prefix, next hop, priority, weight and scope. Needs Magic WAN or Magic Transit on the acco","description":"List Magic static routes with prefix, next hop, priority, weight and scope. Needs Magic WAN or Magic Transit on the account. Use for \"Which static routes does Magic WAN have\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"account_id":{"description":"Cloudflare account id (32-character hex string shown in the dashboard URL, or from the Cloudflare connector's list_accounts).","maxLength":40,"title":"Account Id","type":"string"}},"required":["account_id"],"title":"list_static_routesArguments","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_connectors":{"post":{"operationId":"list_connectors","summary":"List Magic WAN Connector devices with activation state, last heartbeat, software version and timezone. License keys are ","description":"List Magic WAN Connector devices with activation state, last heartbeat, software version and timezone. License keys are not returned. Needs Magic WAN or Magic Transit on the account. Use for \"Are my Magic WAN connectors online\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"account_id":{"description":"Cloudflare account id (32-character hex string shown in the dashboard URL, or from the Cloudflare connector's list_accounts).","maxLength":40,"title":"Account Id","type":"string"},"device_type":{"anyOf":[{"enum":["MANAGED","LICENSED"],"type":"string"},{"type":"null"}],"default":null,"description":"Only connectors of this device type.","title":"Device Type"}},"required":["account_id"],"title":"list_connectorsArguments","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_account_apps":{"post":{"operationId":"list_account_apps","summary":"List Magic WAN applications (account and managed) with type, hostnames and IP subnets used for traffic steering. Needs M","description":"List Magic WAN applications (account and managed) with type, hostnames and IP subnets used for traffic steering. Needs Magic WAN or Magic Transit on the account. Use for \"Which applications are defined for Magic WAN traffic steering\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"account_id":{"description":"Cloudflare account id (32-character hex string shown in the dashboard URL, or from the Cloudflare connector's list_accounts).","maxLength":40,"title":"Account Id","type":"string"}},"required":["account_id"],"title":"list_account_appsArguments","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_bgp_settings":{"post":{"operationId":"get_bgp_settings","summary":"Show the account's Magic BGP settings: Cloudflare ASN and last modification time. Needs Magic WAN or Magic Transit on th","description":"Show the account's Magic BGP settings: Cloudflare ASN and last modification time. Needs Magic WAN or Magic Transit on the account. Use for \"What is the Cloudflare ASN for my Magic BGP sessions\".","tags":["tools"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"properties":{"account_id":{"description":"Cloudflare account id (32-character hex string shown in the dashboard URL, or from the Cloudflare connector's list_accounts).","maxLength":40,"title":"Account Id","type":"string"}},"required":["account_id"],"title":"get_bgp_settingsArguments","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}}}}