> For the complete documentation index, see [llms.txt](https://docs.boldmetrics.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.boldmetrics.io/common-api-topics.md).

# Common API Topics

## Authentication

Authentication to the Bold Metrics API is performed by submitting your ID and API key in the query parameters:

* *client\_id*: \<ID>
* *user\_key*: \<API\_key>

Both these values will be provided by Bold Metrics. All API requests must be made via HTTPS. **Please keep this API key private, as charges may be based on calls using this key.**

## Error Object

As the API goes through the request, specific errors are returned and appended sequentially inside of the 400 error.

JSON examples of each error:

```
{
  "code": 400,
  "message": {
    "overall": "Validation errors",
    "specifics": [
      {
        "field": "height",
        "message": "Missing data for required field."
      }
    ]
  }
}

{
  "message": {
    "code": 400,
    "overall": "Validation errors",
    "specifics": [
      {
        "field": "jean_waist",
        "message": "waist_circum_preferred is greater than maximum value 67.01."
      },
      {
        "field": "height",
        "message": "height is greater than maximum value 85.94."
      }
    ]
  }
}
```

All errors are returned as JSON objects. However, it's possible an internal server error could occur that will cause the API to return HTML instead of JSON.

If the API is abruptly shot down by a bug or error, our server will return an HTML 500 error, such as the following:

```
<!DOCTYPE HTML PUBLIC “-//W3C//DTD HTML 3.2 Final//EN”>
<title>500 Internal Server Error</title>
<h1>Internal Server Error</h1>
<p>The server encountered an internal error and was unable to complete your
request. Either the server is overloaded or there is an error in the application.</p>
```

## Outlier Detection

Outlier Detection will outline any issues with the customer's inputs. These could be either inputs that are out of bounds or simply unlikely combinations, such as a weight of 300 lbs. and a waist measurement of 28".

An outlier error will look something like the following. A *outlier\_status* flag set to *true* and a *outlier\_messages* object specifying which body measurements are inconsistent with one another.

```
"outlier": true,
"outlier_messages": {
  "overall": "Confidence errors",
  "specifics": [
    {
      "field": "",
      "message": "\"hip_circum\" is inconsistent with \"sleeve_inseam\"."
    },
    {
      "field": "",
      "message": "\"jean_inseam\" is inconsistent with \"sleeve_inseam\"."
    },
  ]
},
```

The API will still predict the body dimensions as there are times when the body is only a slight outlier, allowing the ability to check inputs to confirm if the customer is indeed an outlier.

## Rate Limiting

Rate limiting for the API is based on the number of requests that have been negotiated in your agreement. To increase the number of available requests, please email [concierge@boldmetrics.com](mailto:concierge%40boldmetrics.com). **The current global policy is 25 request per second.**


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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.boldmetrics.io/common-api-topics.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.
