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

# HTTP Configuration

<Warning>
  🔐 Do not send <strong>Personal Identifiable Information (PII)</strong> to AppSignal. Filter PII (e.g., names, emails) from logs and use an ID, hash, or pseudonymized identifier instead. <br /> <br /> For **HIPAA-covered entities**, more information about signing a Business Associate Agreement (BAA) can be found in our [Business Add-Ons documentation](/support/business-add-ons).
</Warning>

The HTTP endpoint is the most flexible endpoint to send logs to AppSignal.
You can format the message in multiple ways as described below.

If you are using a language that has an integration library for AppSignal, we recommend using one of the [integration libraries](/logging/integrations) instead of the HTTP endpoint.

If you are creating a custom integration, we recommend using the [HTTP-JSON](/logging/endpoints/http-json) endpoint to guarantee the messages are formatted exactly as intended.

## Endpoint

You can `POST` logs to AppSignal. Your logs must be formatted in `JSON`, `Logfmt` or `Plaintext` and sent to the following endpoint:

```sh Shell theme={null}
https://appsignal-endpoint.net/logs?api_key=YOUR_LOG_SOURCE_API_KEY
```

*Replace `YOUR_LOG_SOURCE_API_KEY` with the key provided when [creating a log source](/logging/configuration#creating-a-log-source).*

We will use the time our servers receive the `POST` request as the log timestamp. The default severity will be `INFO`. You can send the `hostname`, `severity` and `group/appname` parameters by appending them to the URL, for example:

```sh Shell theme={null}
https://appsignal-endpoint.net/logs?group=app&hostname=frontend1&severity=debug&api_key=YOUR_LOG_SOURCE_API_KEY
```

You can send multiple log lines by separating each log line with a-formatted message overrides the hostname newline character: `\n`

## Structured messages

In order to add additional metadata to a log line, you can send a structured message.

### Plaintext

By default the source is created with the `Plaintext` formatter selected,
you can send any string as the message part of the log line, for example:

<CodeGroup>
  ```shell Shell theme={null}
  This is a log message
  And this is another message
  ```
</CodeGroup>

Will result in two log lines with the message `This is a log message` and `And this is another message` respectively.

### Logfmt

When `Logfmt` is selected as the message format, you can send a log line with key-value pairs separated by a space, for example:

<CodeGroup>
  ```shell Shell theme={null}
  This is a log message user_id=123 action=login
  This is another log message user_id=123 action=logout
  ```
</CodeGroup>

Will result in two log lines with the message `This is a log message` and `This is another log message` respectively, and the following attributes:

<CodeGroup>
  ```json JSON theme={null}
  {
    "user_id": 123,
    "action": "login"
  }
  ```
</CodeGroup>

<CodeGroup>
  ```json JSON theme={null}
  {
    "user_id": 123,
    "action": "logout"
  }
  ```
</CodeGroup>

### JSON

When `JSON` is selected as the message format, you can send a log line with a JSON object, for example:

<CodeGroup>
  ```shell Shell theme={null}
  {"message": "This is a log message", "user_id": 123, "action": "login"}
  {"msg": "This is another log message", "user_id": 123, "action": "logout"}
  ```
</CodeGroup>

We expect either a `msg` or `message` key for the log line message, and any other keys will be added as attributes. If no `msg` or `message` key is provided, we'll use the entire (unparsed) JSON object as the message. Attributes will still be parsed and added to this line.

You can read more about the specifics of message formatting in our [formatting](/logging/formatting) documentation.
