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

# Litigator Scrub Multiple Numbers

> Check phone numbers against the litigator database using POST request

Check a list of phone numbers against the litigator database using an HTTP POST request. Use this method for large batches (over 50 phone numbers, up to 10,000).

## Request

### Headers

<ParamField header="loginId" type="string">
  API Key
</ParamField>

<ParamField header="Content-Type" type="string" required>
  Must be `application/json`
</ParamField>

### Request Body

<ParamField body="PhoneList" type="string" required>
  Comma-separated list of 10-digit phone numbers to check (up to 10,000 numbers)
</ParamField>

<ParamField body="CampaignId" type="integer">
  Optional campaign ID for tracking purposes
</ParamField>

<ParamField body="ProjId" type="string">
  Optional project ID for tracking and settings purposes
</ParamField>

<ParamField body="OutputFormat" type="string" default="JsonArray">
  Optional Output format: `JsonArray` (default) or `JsonObject`. By default
  returns `JsonArray`.
</ParamField>

## Example Request

<CodeGroup>
  ```bash cURL theme={null}
  curl --location --request POST \
    'https://dataapi.dncscrub.com/v1.5/Scrub/litigator' \
    --header 'Content-Type: application/json' \
    --header 'loginId: YOUR_API_KEY' \
    --data-raw '{
      "PhoneList": "2675466417,5039367187,7075276405"
    }'
  ```

  ```bash cURL (loginId in body) theme={null}
  curl --location --request POST \
    'https://dataapi.dncscrub.com/v1.5/Scrub/litigator' \
    --header 'Content-Type: application/json' \
    --data-raw '{
      "PhoneList": "2675466417,5039367187,7075276405",
      "LoginId": "YOUR_API_KEY"
    }'
  ```

  ```javascript JavaScript theme={null}
  const response = await fetch(
    "https://dataapi.dncscrub.com/v1.5/Scrub/litigator",
    {
      method: "POST",
      headers: {
        "Content-Type": "application/json",
        loginId: "YOUR_API_KEY",
      },
      body: JSON.stringify({
        PhoneList: "2675466417,5039367187,7075276405",
      }),
    }
  );
  const data = await response.json();
  console.log(data);
  ```

  ```csharp C# theme={null}
  using (var client = new HttpClient())
  {
      client.DefaultRequestHeaders.Add("loginId", "YOUR_API_KEY");

      var content = new StringContent(
          JsonSerializer.Serialize(new { PhoneList = "2675466417,5039367187,7075276405" }),
          Encoding.UTF8,
          "application/json"
      );

      var response = await client.PostAsync(
          "https://dataapi.dncscrub.com/v1.5/Scrub/litigator",
          content
      );

      var result = await response.Content.ReadAsStringAsync();
      Console.WriteLine(result);
  }
  ```
</CodeGroup>

<ResponseExample>
  ```json Response theme={null}
  [
    {
      "Phone": 2675466417,
      "IsLitigator": true
    },
    {
      "Phone": 5039367187,
      "IsLitigator": true
    },
    {
      "Phone": 7075276405,
      "IsLitigator": false
    }
  ]
  ```
</ResponseExample>

## Response Fields

<ResponseField name="Phone" type="integer">
  The 10-digit phone number that was checked
</ResponseField>

<ResponseField name="IsLitigator" type="boolean">
  `true` if the phone number is associated with a known TCPA litigator, `false`
  otherwise
</ResponseField>

## Error Responses

| Status           | Description                                                                 |
| ---------------- | --------------------------------------------------------------------------- |
| 400 Bad Request  | Invalid phone number format, malformed JSON, or missing required parameters |
| 401 Unauthorized | Invalid or missing API key                                                  |
| 404 Not Found    | Endpoint not found or invalid URL                                           |

## Batch Processing Example

When processing large lists, you may want to batch and process results:

```javascript theme={null}
async function checkLitigators(phoneNumbers) {
  // Join phone numbers into comma-separated string
  const phoneList = phoneNumbers.join(",");

  const response = await fetch(
    "https://dataapi.dncscrub.com/v1.5/Scrub/litigator",
    {
      method: "POST",
      headers: {
        "Content-Type": "application/json",
        loginId: "YOUR_API_KEY",
      },
      body: JSON.stringify({ PhoneList: phoneList }),
    }
  );

  const results = await response.json();

  // Separate litigators from safe numbers
  const litigators = results.filter((r) => r.IsLitigator);
  const safe = results.filter((r) => !r.IsLitigator);

  return {
    litigators: litigators.map((r) => r.Phone),
    safe: safe.map((r) => r.Phone),
    totalChecked: results.length,
  };
}

// Usage
const phones = ["2675466417", "5039367187", "7075276405"];
const result = await checkLitigators(phones);
console.log(`Found ${result.litigators.length} litigators`);
```

## Security Best Practice

For additional security, pass the `loginId` in the HTTP header rather than in the JSON body. This prevents your API key from appearing in application logs.
