<commit_before># Django Datadog

A simple Django middleware for submitting timings and exceptions to Datadog.

## Installation

Download the code into your project and install it.

```bash
git clone git://github.com/conorbranagan/django-datadog.git
cd django-datadog
python setup.py install
```

Add `datadog` to your list of installed apps.

```python
INSTALLED_APPS += ('datadog')
```

Add the following configuration to your projects' `settings.py` file:

```python
DATADOG_API_KEY = 'YOUR_API_KEY'
DATADOG_APP_KEY = 'YOUR_APP_KEY'
DATADOG_APP_NAME = 'my_app' # Used for namespace metric names
```

The API and app keys can be found at https://app.datadoghq.com/account/settings#api

Add the Datadog request handler to your middleware in `settings.py`.

```python
MIDDLEWHARE_CLASSES += ('datadog.middleware.DatadogMiddleware')
```

## Usage<commit_msg>fix wording in readme<commit_after># Django Datadog

A simple Django middleware for submitting timings and exceptions to Datadog.

## Installation

Download the code into your project and install it.

```bash
git clone git://github.com/conorbranagan/django-datadog.git
cd django-datadog
python setup.py install
```

Add `datadog` to your list of installed apps.

```python
INSTALLED_APPS += ('datadog')
```

Add the following configuration to your projects' `settings.py` file:

```python
DATADOG_API_KEY = 'YOUR_API_KEY'
DATADOG_APP_KEY = 'YOUR_APP_KEY'
DATADOG_APP_NAME = 'my_app' # Used to namespace metric names
```

The API and app keys can be found at https://app.datadoghq.com/account/settings#api

Add the Datadog request handler to your middleware in `settings.py`.

```python
MIDDLEWHARE_CLASSES += ('datadog.middleware.DatadogMiddleware')
```

## Usage
{'fraction_non_alphanumeric': 0.10238510762070971, 'fraction_numerical': 0.0, 'mean_word_length': 5.2773722627737225, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '32180', 'n_tokens_mistral': 602, 'n_tokens_neox': 564, 'n_words': 180}