# Azure Log Analytics

![](https://4005883584-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F1NBbcZmdFBruUw1adUIg%2Fuploads%2Fgit-blob-257937256c2f5950d0a098755cbc92a479827630%2Fimage%20\(7\).png?alt=media)

Azure output plugin allows to ingest your records into [Azure Log Analytics](https://azure.microsoft.com/en-us/services/log-analytics/) service.

To get more details about how to setup Azure Log Analytics, please refer to the following documentation: [Azure Log Analytics](https://docs.microsoft.com/en-us/azure/log-analytics/)

## Configuration Parameters

| Key             | Description                                                                                                                                                   | default    |
| --------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------- |
| Customer\_ID    | Customer ID or WorkspaceID string.                                                                                                                            |            |
| Shared\_Key     | The primary or the secondary Connected Sources client authentication key.                                                                                     |            |
| Log\_Type       | The name of the event type.                                                                                                                                   | fluentbit  |
| Time\_Key       | Optional parameter to specify the key name where the timestamp will be stored.                                                                                | @timestamp |
| Time\_Generated | If enabled, the HTTP request header 'time-generated-field' will be included so Azure can override the timestamp with the key specified by 'time\_key' option. | off        |

## Getting Started

In order to insert records into an Azure Log Analytics instance, you can run the plugin from the command line or through the configuration file:

### Command Line

The **azure** plugin, can read the parameters from the command line in two ways, through the **-p** argument (property), e.g:

```
$ fluent-bit -i cpu -o azure -p customer_id=abc -p shared_key=def -m '*' -f 1
```

### Configuration File

In your main configuration file append the following *Input* & *Output* sections:

```
[INPUT]
    Name  cpu

[OUTPUT]
    Name        azure
    Match       *
    Customer_ID abc
    Shared_Key  def
```
