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

# Domain Health

> Check whether Nimble is seeing healthy traffic to specific domains right now

Domain Health reports whether a target site is up or failing, sourced from real request outcomes across Search, SERP, ecommerce, and Extract traffic. Use it to confirm a failure is the domain's fault, not Nimble's, before opening a support ticket.

## Quick Start

### Example Request

<CodeGroup>
  ```python Python theme={"system"}
  from nimble_python import Nimble

  nimble = Nimble(api_key="YOUR-API-KEY")

  result = nimble.domain_health.check(
      domains=["walmart.com", "hannaford.com"]
  )

  for domain in result.domains:
      print(f"{domain.domain}: {domain.status} ({domain.success_rate})")
  ```

  ```typescript TypeScript theme={"system"}
  import Nimble from "@nimble-way/nimble-js";

  const nimble = new Nimble({ apiKey: "YOUR-API-KEY" });

  const result = await nimble.domainHealth.check({
    domains: ["walmart.com", "hannaford.com"],
  });

  result.domains.forEach(domain => {
    console.log(`${domain.domain}: ${domain.status} (${domain.success_rate})`);
  });
  ```

  ```go Go theme={"system"}
  package main

  import (
      "context"
      "fmt"

      nimble "github.com/Nimbleway/nimble-go"
      "github.com/Nimbleway/nimble-go/option"
  )

  func main() {
      client := nimble.NewClient(option.WithAPIKey("YOUR-API-KEY"))

      result, err := client.DomainHealth.Check(context.Background(), nimble.DomainHealthCheckParams{
          Domains: []string{"walmart.com", "hannaford.com"},
      })
      if err != nil {
          panic(err)
      }
      for _, domain := range result.Domains {
          fmt.Printf("%s: %s (%v)\n", domain.Domain, domain.Status, domain.SuccessRate)
      }
  }
  ```

  ```bash CLI theme={"system"}
  nimble domain-health check \
    --domains walmart.com,hannaford.com
  ```

  ```bash cURL theme={"system"}
  curl -X POST 'https://sdk.nimbleway.com/v1/domain-health/check' \
  --header 'Authorization: Bearer <YOUR-API-KEY>' \
  --header 'Content-Type: application/json' \
  --data-raw '{
      "domains": ["walmart.com", "hannaford.com"]
  }'
  ```
</CodeGroup>

### Example Response

```json theme={"system"}
{
  "domains": [
    {
      "domain": "walmart.com",
      "status": "up",
      "success_rate": 0.94,
      "consecutive_bad_windows": 0,
      "history": [
        {
          "hours_ago": 0,
          "window_start": "2026-08-24T11:00:00Z",
          "window_end": "2026-08-24T12:00:00Z",
          "status": "up",
          "success_rate": 0.95
        },
        {"...": "5 more hourly buckets"}
      ]
    },
    {
      "domain": "hannaford.com",
      "status": "down",
      "success_rate": 0.0,
      "consecutive_bad_windows": 6,
      "history": [
        {"...": "6 hourly buckets"}
      ]
    }
  ]
}
```

## Parameters

<ParamField body="domains" type="string[]" required>
  Domains to check, 1–100 per request. Pass the bare domain (e.g. `walmart.com`), not a full URL.
</ParamField>

## Response

Each entry in `domains` reports the live status plus a 6-hour trend:

| Field                     | Description                                                                                                                       |
| ------------------------- | --------------------------------------------------------------------------------------------------------------------------------- |
| `domain`                  | The domain checked                                                                                                                |
| `status`                  | `up`, `degraded`, `down`, or `unknown`                                                                                            |
| `success_rate`            | Success rate over the live detection window                                                                                       |
| `consecutive_bad_windows` | Consecutive 10-minute windows below the success threshold                                                                         |
| `history`                 | 6 hourly buckets, most recent completed hour first, each with `hours_ago`, `window_start`, `window_end`, `status`, `success_rate` |

### Status values

| Status     | Meaning                                                           |
| ---------- | ----------------------------------------------------------------- |
| `up`       | Latest window's success rate is at or above the healthy threshold |
| `degraded` | 1–2 consecutive bad windows                                       |
| `down`     | 3 or more consecutive bad windows                                 |
| `unknown`  | Fewer than 10 samples for that domain in the lookback window      |

<Note>
  Status comes from real request outcomes across Search, SERP, ecommerce, and Extract traffic, not a synthetic check. A domain with no recent traffic on your account returns `unknown`.
</Note>

## Errors

| Status | Meaning                                                                |
| ------ | ---------------------------------------------------------------------- |
| `400`  | `domains` is empty or has more than 100 entries                        |
| `401`  | Missing or invalid API key                                             |
| `429`  | Rate limited                                                           |
| `503`  | Health data temporarily unavailable. Never reported as `up` by default |

<Note>
  Typical response time is under 2 seconds (p95) for 1-100 domains.
</Note>

## Next steps

<CardGroup cols={2}>
  <Card icon="chart-line" href="https://status.nimbleway.com" title="Status Page">
    Live, product-wide status for Search, SERP, ecommerce, and Extract
  </Card>

  <Card icon="code" href="/api-reference/domain-health/check-domain-health" title="API Reference">
    Full request and response schema
  </Card>
</CardGroup>
