> ## Documentation Index
> Fetch the complete documentation index at: https://docs-xcor.paloaltonetworks.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Route logs from Fluent Bit

> Learn how to route logs from Fluent Bit to Palo Alto Networks Cortex XCOR.

You can use Fluent Bit to send logs to Palo Alto Networks Cortex XCOR. To do
so, add an
[HTTP output plugin](https://docs.fluentbit.io/manual/pipeline/outputs/http)
that specifies your Cortex XCOR tenant as its destination.

## Example configuration

To route logs from Fluent Bit to Cortex XCOR, Cortex XCOR recommends
configuring an HTTP output plugin with the following parameters and values:

> [tab] YAML configuration
>
> ```yaml theme={null}
> pipeline:
>   # ...
>   outputs:
>     - name: http
>       match: "kube.*"
>       alias: Cortex XCOR
>       host: TENANT
>       port: 443
>       uri: /api/v1/data/logs/ingest
>       header: "API-Token ${API_TOKEN}"
>       format: json
>       compress: zstd
>       json_date_format: iso8601
>       json_date_key: TIME
>       tls: true
>       tls.verify: true
>       tls.debug: 1
>       net.keepalive: true
>       net.keepalive_idle_timeout: 30s
>       net.connect_timeout: 10s
>       net.connect_timeout_log_error: true
>       net.keepalive_max_recycle: 2000
> ```

> [tab] Classic configuration
>
> ```ini theme={null}
> [OUTPUT]
>     Name                          http
>     Match                         kube.*
>     Alias                         Cortex XCOR
>     Host                          TENANT
>     Port                          443
>     URI                           /api/v1/data/logs/ingest
>     Header                        API-Token ${API_TOKEN}
>     Format                        json
>     Compress                      zstd
>     json_date_format              iso8601
>     json_date_key                 TIME
>     tls                           On
>     tls.verify                    On
>     tls.debug                     1
>     net.keepalive                 On
>     net.keepalive_idle_timeout    30s
>     net.connect_timeout           10s
>     net.connect_timeout_log_error On
>     net.keepalive_max_recycle     2000
> ```

* Replace *`API_TOKEN`* with the API token generated from your [service account](https://docs-xcor.paloaltonetworks.com/administer/accounts-teams/service-accounts.md). Cortex XCOR recommends storing your API token in a separate file or Kubernetes Secret and calling it using an environment variable, such as `$API_TOKEN`.

  > [!NOTE]
  >
  > The service account must have read access to route log data to Cortex XCOR.

* Replace *`TENANT`* with the name of your Cortex XCOR tenant.

* Replace *`TIME`* with the value you assigned to timestamps in your
  [log normalization settings](https://docs-xcor.paloaltonetworks.com/control/shaping/shape-logs/normalize-logs.md).
  If you didn't set up log normalization for timestamps, replace *`TIME`*
  with `timestamp`.


## Related topics

- [Ingest log data](https://docs-xcor.paloaltonetworks.com/ingest/logs.md)
- [Integrate with Cortex XCOR](https://docs-xcor.paloaltonetworks.com/integrate.md)
- [Fluent Bit source plugin](https://docs-xcor.paloaltonetworks.com/ingest/pipeline/plugins/source-plugins/fluent-bit.md)
- [Palo Alto Networks Telemetry Pipeline v3](https://docs-xcor.paloaltonetworks.com/ingest/pipeline/v3.md)
- [Route logs through Palo Alto Networks Telemetry Pipeline](https://docs-xcor.paloaltonetworks.com/ingest/logs/pipeline-logs.md)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.