> ## 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.

# One-Time Scan Status

> Check the status of a one-time scan job

Check the status of a one-time scan job submitted via the [Submit One-Time Scan](/api-reference/trustcall/one-time-scan-submit) endpoint.

## Request

### Headers

<ParamField header="loginId" type="string" required>
  Your API Key (LoginId from your DNCScrub account)
</ParamField>

### Query Parameters

<ParamField query="jobId" type="string" required>
  The job ID (UUID) returned from the POST OneTimeScan endpoint
</ParamField>

## Example Request

<CodeGroup>
  ```bash cURL theme={null}
  curl --location --request GET \
    'https://dataapi.dncscrub.com/v1.5/TrustCall/OneTimeScan?jobId=a1b2c3d4-e5f6-7890-abcd-ef1234567890' \
    --header 'loginId: YOUR_API_KEY'
  ```

  ```javascript JavaScript theme={null}
  const response = await fetch(
    'https://dataapi.dncscrub.com/v1.5/TrustCall/OneTimeScan?jobId=a1b2c3d4-e5f6-7890-abcd-ef1234567890',
    {
      method: 'GET',
      headers: { 'loginId': 'YOUR_API_KEY' }
    }
  );
  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 url = "https://dataapi.dncscrub.com/v1.5/TrustCall/OneTimeScan?jobId=a1b2c3d4-e5f6-7890-abcd-ef1234567890";
      var response = await client.GetStringAsync(url);
      Console.WriteLine(response);
  }
  ```
</CodeGroup>

<ResponseExample>
  ```json Response (Processing) theme={null}
  {
    "JobId": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
    "Status": "Processing",
    "PhoneCount": 3,
    "ProcessedCount": 1
  }
  ```
</ResponseExample>

<ResponseExample>
  ```json Response (Complete) theme={null}
  {
    "JobId": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
    "Status": "Complete",
    "PhoneCount": 3,
    "ProcessedCount": 3,
    "Results": [
      {
        "Phone": "5039367187",
        "CurrScore": "Clean",
        "VerizonScore": "Clean",
        "ATTScore": "Clean",
        "TMobileScore": "Clean",
        "RoboKillerStatus": "Clean",
        "NomoroboStatus": "Clean",
        "FTCComplaints": null
      },
      {
        "Phone": "8084565302",
        "CurrScore": "Medium",
        "VerizonScore": "Clean",
        "ATTScore": "Flagged",
        "TMobileScore": "Clean",
        "RoboKillerStatus": "Clean",
        "NomoroboStatus": "Clean",
        "FTCComplaints": null
      },
      {
        "Phone": "7867056421",
        "CurrScore": "High",
        "VerizonScore": "Flagged",
        "ATTScore": "Flagged",
        "TMobileScore": "Clean",
        "RoboKillerStatus": "Clean",
        "NomoroboStatus": "Flagged",
        "FTCComplaints": [
          {
            "FTCComplaintId": "79923e06b1c74d47e6ad5826b7554046",
            "Phone": "7867056421",
            "CreatedDate": "08/15/2022 22:22:39",
            "ViolationDate": "07/29/2022 12:04:00",
            "Subject": "Dropped call or no message"
          }
        ]
      }
    ]
  }
  ```
</ResponseExample>

## Response Fields

<ResponseField name="JobId" type="string (UUID)">
  The scan job identifier
</ResponseField>

<ResponseField name="Status" type="string">
  Current job status:

  * `Submitted` - Job received, not yet started
  * `Processing` - Scan in progress
  * `Complete` - Scan finished, results available
  * `Failed` - Scan encountered an error
</ResponseField>

<ResponseField name="PhoneCount" type="integer">
  Total number of phone numbers in the job
</ResponseField>

<ResponseField name="ProcessedCount" type="integer">
  Number of phone numbers processed so far
</ResponseField>

<ResponseField name="Results" type="array">
  Array of scan results (only present when `Status` is `Complete`). See result fields below.
</ResponseField>

## Result Fields

<ResponseField name="Phone" type="string">
  The phone number that was scanned
</ResponseField>

<ResponseField name="CurrScore" type="string">
  Current average carrier spam score: `Clean`, `Medium`, or `High`
</ResponseField>

<ResponseField name="VerizonScore" type="string">
  Verizon carrier status: `Clean` or `Flagged`
</ResponseField>

<ResponseField name="ATTScore" type="string">
  AT\&T carrier status: `Clean` or `Flagged`
</ResponseField>

<ResponseField name="TMobileScore" type="string">
  T-Mobile carrier status: `Clean` or `Flagged`
</ResponseField>

<ResponseField name="RoboKillerStatus" type="string">
  RoboKiller app status (if `carrierandapps` scan type)
</ResponseField>

<ResponseField name="NomoroboStatus" type="string">
  Nomorobo app status (if `carrierandapps` scan type)
</ResponseField>

<ResponseField name="FTCComplaints" type="array | null">
  Array of FTC complaints (if `carrierandapps` scan type)
</ResponseField>

## Error Responses

| Status           | Description                        |
| ---------------- | ---------------------------------- |
| 400 Bad Request  | Invalid or missing job ID          |
| 401 Unauthorized | Invalid or missing API key         |
| 403 Forbidden    | Job belongs to a different account |
| 500 Server Error | Internal server error              |

## Polling Example

```javascript theme={null}
async function waitForScanResults(jobId, apiKey, maxWaitMs = 300000) {
  const startTime = Date.now();
  const pollInterval = 5000; // 5 seconds

  while (Date.now() - startTime < maxWaitMs) {
    const response = await fetch(
      `https://dataapi.dncscrub.com/v1.5/TrustCall/OneTimeScan?jobId=${jobId}`,
      { headers: { 'loginId': apiKey } }
    );

    const data = await response.json();

    if (data.Status === 'Complete') {
      return data.Results;
    }

    if (data.Status === 'Failed') {
      throw new Error('Scan job failed');
    }

    console.log(`Processing: ${data.ProcessedCount}/${data.PhoneCount}`);
    await new Promise(resolve => setTimeout(resolve, pollInterval));
  }

  throw new Error('Scan timed out');
}
```
