# Fraud History

## Retrieve fraud history

<mark style="color:blue;">`GET`</mark> `https://api.waldo.ai/history/fraud/:customerId`

#### Path Parameters

| Field                                        | Type   | Description          |
| -------------------------------------------- | ------ | -------------------- |
| customerId<mark style="color:red;">\*</mark> | String | Waldo AI customer id |

#### Headers

| Name                                            | Type   | Description                                |
| ----------------------------------------------- | ------ | ------------------------------------------ |
| Authorization<mark style="color:red;">\*</mark> | String | The token in the format `Bearer eyJhbG...` |
| Content-Type<mark style="color:red;">\*</mark>  | String | Expected type is `application/json`        |

#### Response

{% tabs %}
{% tab title="200: OK KYC History Available" %}

```json
{
  "active": {
    "date": 1724152019860,
    "score": 0.9
  },
  "history": [
    {
      "date": 1724152019860,
      "score": 0.9
    }
  ]
}
```

{% endtab %}

{% tab title="403: Forbidden Missing authorization header" %}

```json
{
  "code": "NOT_AUTHORIZED",
  "message": "Not authorized."
}
```

{% endtab %}

{% tab title="401: Unauthorized Invalid token or expired" %}

```json
{
  "code": "INVALID_TOKEN",
  "message": "Invalid token."
}
```

{% endtab %}

{% tab title="403: Forbidden Service not authorized" %}

```json
{
  "code": "NOT_AUTHORIZED",
  "message": "You are not authorized to perform this action. Please contact support for assistance."
}
```

{% endtab %}

{% tab title="403: Forbidden Inactive API key" %}

```json
{
  "code": "API_KEY_REVOKED",
  "message": "This API key has been revoked. Please visit the Waldo AI dashboard to review your API key."
}
```

{% endtab %}

{% tab title="400: Bad Request Missing query parameters" %}
The query should include the following parameters:  `customerId`

```json
{
  "code": "INVALID_DATA",
  "message": "Invalid customer ID."
}
```

{% endtab %}

{% tab title="404: Customer not found" %}
Customer was not found, or has not been evaluated yet.

```json
{
  "code": "NOT_FOUND",
  "message": "Fraud history not found."
}
```

{% endtab %}
{% endtabs %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.waldo.ai/api-reference/fraud-history.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
