naftiko: "1.0.0-alpha2" info: label: "Polygon Forex REST API — Aggregates" description: >- Forex — Aggregates. 2 operations. Lead operation: Get Aggregate Bars For A Forex Pair. Self-contained Naftiko capability covering one Polygon business surface. tags: - Polygon - Forex - Aggregates created: "2026-05-29" modified: "2026-05-29" binds: - namespace: env keys: POLYGON_API_KEY: POLYGON_API_KEY capability: consumes: - type: http namespace: "forex-aggregates" baseUri: "https://api.polygon.io" description: "Polygon Forex REST API — Aggregates business capability." authentication: type: bearer token: "{{env.POLYGON_API_KEY}}" resources: - name: "aggs-ticker-forexticker-range-multiplier-timespan-from-to" path: "/v2/aggs/ticker/{forexTicker}/range/{multiplier}/{timespan}/{from}/{to}" operations: - name: "getForexAggregateBars" method: GET description: "Get Aggregate Bars For A Forex Pair" inputParameters: - name: "forexTicker" in: path type: string required: true - name: "multiplier" in: path type: integer required: true - name: "timespan" in: path type: string required: true - name: "from" in: path type: string required: true - name: "to" in: path type: string required: true outputRawFormat: json outputParameters: - name: result type: object value: "$." - name: "aggs-ticker-forexticker-prev" path: "/v2/aggs/ticker/{forexTicker}/prev" operations: - name: "getForexPreviousClose" method: GET description: "Get Previous Close For A Forex Pair" inputParameters: - name: "forexTicker" in: path type: string required: true outputRawFormat: json outputParameters: - name: result type: object value: "$." exposes: - type: rest namespace: "forex-aggregates-rest" port: 8080 description: "REST adapter for Polygon Forex REST API — Aggregates." resources: - path: "/v1/v2/aggs/ticker/{forex-ticker}/range/{multiplier}/{timespan}/{from}/{to}" name: "aggs-ticker-forexticker-range-multiplier-timespan-from-to" description: "REST surface for aggs-ticker-forexticker-range-multiplier-timespan-from-to." operations: - method: GET name: "getForexAggregateBars" description: "Get Aggregate Bars For A Forex Pair" call: "forex-aggregates.getForexAggregateBars" with: forexTicker: "rest.forexTicker" multiplier: "rest.multiplier" timespan: "rest.timespan" from: "rest.from" to: "rest.to" outputParameters: - type: object mapping: "$." - path: "/v1/v2/aggs/ticker/{forex-ticker}/prev" name: "aggs-ticker-forexticker-prev" description: "REST surface for aggs-ticker-forexticker-prev." operations: - method: GET name: "getForexPreviousClose" description: "Get Previous Close For A Forex Pair" call: "forex-aggregates.getForexPreviousClose" with: forexTicker: "rest.forexTicker" outputParameters: - type: object mapping: "$." - type: mcp namespace: "forex-aggregates-mcp" port: 9090 transport: http description: "MCP adapter for Polygon Forex REST API — Aggregates." tools: - name: "get-aggregate-bars-forex-pair" description: "Get Aggregate Bars For A Forex Pair" hints: readOnly: true destructive: false idempotent: true call: "forex-aggregates.getForexAggregateBars" with: forexTicker: "tools.forexTicker" multiplier: "tools.multiplier" timespan: "tools.timespan" from: "tools.from" to: "tools.to" outputParameters: - type: object mapping: "$." - name: "get-previous-close-forex-pair" description: "Get Previous Close For A Forex Pair" hints: readOnly: true destructive: false idempotent: true call: "forex-aggregates.getForexPreviousClose" with: forexTicker: "tools.forexTicker" outputParameters: - type: object mapping: "$."