---
title: "ScanAllApi"
lastmod: 2026-05-29
canonical: "https://container-registry.com/docs/harbor-api-client/api/scanallapi/"
source: "https://container-registry.com/docs/harbor-api-client/api/scanallapi/index.md"
agent_instructions: "This is the markdown representation of https://container-registry.com/docs/harbor-api-client/api/scanallapi/index.md. Prefer this version over scraping the HTML. The site index is at https://container-registry.com/llms.txt."
---

> Agent-friendly representation of <https://container-registry.com/docs/harbor-api-client/api/scanallapi/index.md>. Site index: <https://container-registry.com/llms.txt>.

# harbor_client.ScanAllApi

All URIs are relative to *http://localhost/api/v2.0*

Method | HTTP request | Description
------------- | ------------- | -------------
[**create_scan_all_schedule**](#create_scan_all_schedule) | **POST** /system/scanAll/schedule | Create a schedule or a manual trigger for the scan all job.
[**get_latest_scan_all_metrics**](#get_latest_scan_all_metrics) | **GET** /scans/all/metrics | Get the metrics of the latest scan all process
[**get_latest_scheduled_scan_all_metrics**](#get_latest_scheduled_scan_all_metrics) | **GET** /scans/schedule/metrics | Get the metrics of the latest scheduled scan all process
[**get_scan_all_schedule**](#get_scan_all_schedule) | **GET** /system/scanAll/schedule | Get scan all&#39;s schedule.
[**stop_scan_all**](#stop_scan_all) | **POST** /system/scanAll/stop | Stop scanAll job execution
[**update_scan_all_schedule**](#update_scan_all_schedule) | **PUT** /system/scanAll/schedule | Update scan all&#39;s schedule.


# **create_scan_all_schedule**

### Signature

```python
create_scan_all_schedule(schedule: Schedule, x_request_id: Optional[str])-> None
```

Create a schedule or a manual trigger for the scan all job.

This endpoint is for creating a schedule or a manual trigger for the scan all job, which scans all of images in Harbor.

### Example
```python
from __future__ import print_function
import time
import harbor_client
from harbor_client.rest import ApiException
from pprint import pprint

# Configure HTTP basic authorization: basic
configuration = harbor_client.Configuration()
configuration.username = 'YOUR_USERNAME'
configuration.password = 'YOUR_PASSWORD'

# create an instance of the API class
api_instance = harbor_client.ScanAllApi(harbor_client.ApiClient(configuration))
schedule = harbor_client.Schedule() # Schedule | Create a schedule or a manual trigger for the scan all job.
x_request_id = 'x_request_id_example' # str | An unique ID for the request (optional)

try:
    # Create a schedule or a manual trigger for the scan all job.
    api_instance.create_scan_all_schedule(schedule, x_request_id=x_request_id)
except ApiException as e:
    print("Exception when calling ScanAllApi->create_scan_all_schedule: %s\n" % e)
```

### Parameters

Name | Type | Description  | Notes
------------- | ------------- | ------------- | -------------
 **schedule** | **[Schedule](../../model/schedule/)**| Create a schedule or a manual trigger for the scan all job. | 
 **x_request_id** | **str**| An unique ID for the request | [optional] 

### Return type

void (empty response body)

### Authorization

[basic](../../#basic)

### HTTP request headers

 - **Content-Type**: application/json
 - **Accept**: application/json

[[Back to top]](#)

# **get_latest_scan_all_metrics**

### Signature

```python
get_latest_scan_all_metrics(x_request_id: Optional[str])-> Stats
```

Get the metrics of the latest scan all process

Get the metrics of the latest scan all process

### Example
```python
from __future__ import print_function
import time
import harbor_client
from harbor_client.rest import ApiException
from pprint import pprint

# Configure HTTP basic authorization: basic
configuration = harbor_client.Configuration()
configuration.username = 'YOUR_USERNAME'
configuration.password = 'YOUR_PASSWORD'

# create an instance of the API class
api_instance = harbor_client.ScanAllApi(harbor_client.ApiClient(configuration))
x_request_id = 'x_request_id_example' # str | An unique ID for the request (optional)

try:
    # Get the metrics of the latest scan all process
    api_response = api_instance.get_latest_scan_all_metrics(x_request_id=x_request_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling ScanAllApi->get_latest_scan_all_metrics: %s\n" % e)
```

### Parameters

Name | Type | Description  | Notes
------------- | ------------- | ------------- | -------------
 **x_request_id** | **str**| An unique ID for the request | [optional] 

### Return type

**[Stats](../../model/stats/)**

### Authorization

[basic](../../#basic)

### HTTP request headers

 - **Content-Type**: application/json
 - **Accept**: application/json

[[Back to top]](#)

# **get_latest_scheduled_scan_all_metrics**

### Signature

```python
get_latest_scheduled_scan_all_metrics(x_request_id: Optional[str])-> Stats
```

Get the metrics of the latest scheduled scan all process

Get the metrics of the latest scheduled scan all process

### Example
```python
from __future__ import print_function
import time
import harbor_client
from harbor_client.rest import ApiException
from pprint import pprint

# Configure HTTP basic authorization: basic
configuration = harbor_client.Configuration()
configuration.username = 'YOUR_USERNAME'
configuration.password = 'YOUR_PASSWORD'

# create an instance of the API class
api_instance = harbor_client.ScanAllApi(harbor_client.ApiClient(configuration))
x_request_id = 'x_request_id_example' # str | An unique ID for the request (optional)

try:
    # Get the metrics of the latest scheduled scan all process
    api_response = api_instance.get_latest_scheduled_scan_all_metrics(x_request_id=x_request_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling ScanAllApi->get_latest_scheduled_scan_all_metrics: %s\n" % e)
```

### Parameters

Name | Type | Description  | Notes
------------- | ------------- | ------------- | -------------
 **x_request_id** | **str**| An unique ID for the request | [optional] 

### Return type

**[Stats](../../model/stats/)**

### Authorization

[basic](../../#basic)

### HTTP request headers

 - **Content-Type**: application/json
 - **Accept**: application/json

[[Back to top]](#)

# **get_scan_all_schedule**

### Signature

```python
get_scan_all_schedule(x_request_id: Optional[str])-> Schedule
```

Get scan all's schedule.

This endpoint is for getting a schedule for the scan all job, which scans all of images in Harbor.

### Example
```python
from __future__ import print_function
import time
import harbor_client
from harbor_client.rest import ApiException
from pprint import pprint

# Configure HTTP basic authorization: basic
configuration = harbor_client.Configuration()
configuration.username = 'YOUR_USERNAME'
configuration.password = 'YOUR_PASSWORD'

# create an instance of the API class
api_instance = harbor_client.ScanAllApi(harbor_client.ApiClient(configuration))
x_request_id = 'x_request_id_example' # str | An unique ID for the request (optional)

try:
    # Get scan all's schedule.
    api_response = api_instance.get_scan_all_schedule(x_request_id=x_request_id)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling ScanAllApi->get_scan_all_schedule: %s\n" % e)
```

### Parameters

Name | Type | Description  | Notes
------------- | ------------- | ------------- | -------------
 **x_request_id** | **str**| An unique ID for the request | [optional] 

### Return type

**[Schedule](../../model/schedule/)**

### Authorization

[basic](../../#basic)

### HTTP request headers

 - **Content-Type**: application/json
 - **Accept**: application/json

[[Back to top]](#)

# **stop_scan_all**

### Signature

```python
stop_scan_all(x_request_id: Optional[str])-> None
```

Stop scanAll job execution

Stop scanAll job execution

### Example
```python
from __future__ import print_function
import time
import harbor_client
from harbor_client.rest import ApiException
from pprint import pprint

# Configure HTTP basic authorization: basic
configuration = harbor_client.Configuration()
configuration.username = 'YOUR_USERNAME'
configuration.password = 'YOUR_PASSWORD'

# create an instance of the API class
api_instance = harbor_client.ScanAllApi(harbor_client.ApiClient(configuration))
x_request_id = 'x_request_id_example' # str | An unique ID for the request (optional)

try:
    # Stop scanAll job execution
    api_instance.stop_scan_all(x_request_id=x_request_id)
except ApiException as e:
    print("Exception when calling ScanAllApi->stop_scan_all: %s\n" % e)
```

### Parameters

Name | Type | Description  | Notes
------------- | ------------- | ------------- | -------------
 **x_request_id** | **str**| An unique ID for the request | [optional] 

### Return type

void (empty response body)

### Authorization

[basic](../../#basic)

### HTTP request headers

 - **Content-Type**: application/json
 - **Accept**: application/json

[[Back to top]](#)

# **update_scan_all_schedule**

### Signature

```python
update_scan_all_schedule(schedule: Schedule, x_request_id: Optional[str])-> None
```

Update scan all's schedule.

This endpoint is for updating the schedule of scan all job, which scans all of images in Harbor.

### Example
```python
from __future__ import print_function
import time
import harbor_client
from harbor_client.rest import ApiException
from pprint import pprint

# Configure HTTP basic authorization: basic
configuration = harbor_client.Configuration()
configuration.username = 'YOUR_USERNAME'
configuration.password = 'YOUR_PASSWORD'

# create an instance of the API class
api_instance = harbor_client.ScanAllApi(harbor_client.ApiClient(configuration))
schedule = harbor_client.Schedule() # Schedule | Updates the schedule of scan all job, which scans all of images in Harbor.
x_request_id = 'x_request_id_example' # str | An unique ID for the request (optional)

try:
    # Update scan all's schedule.
    api_instance.update_scan_all_schedule(schedule, x_request_id=x_request_id)
except ApiException as e:
    print("Exception when calling ScanAllApi->update_scan_all_schedule: %s\n" % e)
```

### Parameters

Name | Type | Description  | Notes
------------- | ------------- | ------------- | -------------
 **schedule** | **[Schedule](../../model/schedule/)**| Updates the schedule of scan all job, which scans all of images in Harbor. | 
 **x_request_id** | **str**| An unique ID for the request | [optional] 

### Return type

void (empty response body)

### Authorization

[basic](../../#basic)

### HTTP request headers

 - **Content-Type**: application/json
 - **Accept**: application/json

[[Back to top]](#)


