All URIs are relative to http://localhost
| Method | HTTP request | Description |
|---|---|---|
| create_configs | POST /api/v2/configs | |
| delete_config | DELETE /api/v2/configs/{configId} | |
| get_config_by_id | GET /api/v2/configs/{configId} | |
| get_config_categorie_by_id | GET /api/v2/config-categories/{configCategorieId} | |
| get_config_categorie_subcategories | GET /api/v2/config-categories/{configCategorieId}/subcategories | |
| get_config_categories | GET /api/v2/config-categories | |
| get_configs | GET /api/v2/configs | |
| get_resources_custom_import_operations | GET /api/v2/resources/custom-import-operations | |
| patch_config | PATCH /api/v2/configs/{configId} | |
| start_configs_batch_delete | POST /api/v2/configs/operations/batch-delete | |
| start_configs_export_all | POST /api/v2/configs/operations/exportAll | |
| start_configs_import | POST /api/v2/configs/operations/import | |
| start_configs_import_all | POST /api/v2/configs/operations/importAll | |
| update_config | PUT /api/v2/configs/{configId} |
List[ConfigMetadata] create_configs(configs=configs)
Save or import a new configuration. If the ConfigData field is not provided, this is implemented as a Save operation, only recording the metadata.
- OAuth Authentication (OAuth2):
- OAuth Authentication (OAuth2):
import cyperf
from cyperf.models.config_metadata import ConfigMetadata
from cyperf.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to http://localhost
# See configuration.py for a list of all supported configuration parameters.
configuration = cyperf.Configuration(
host = "http://localhost"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
configuration.refresh_token = os.environ["OFFLINE_TOKEN_FROM_CYPERF_UI"]
configuration.refresh_token = os.environ["OFFLINE_TOKEN_FROM_CYPERF_UI"]
# Enter a context with an instance of the API client
with cyperf.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = cyperf.ConfigurationsApi(api_client)
configs = [cyperf.ConfigMetadata()] # List[ConfigMetadata] | (optional)
try:
api_response = api_instance.create_configs(configs=configs)
print("The response of ConfigurationsApi->create_configs:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling ConfigurationsApi->create_configs: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| configs | List[ConfigMetadata] | [optional] |
- Content-Type: application/json, application/x-zip, application/zip, multipart/form-data
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 201 | The configuration that was saved or imported | - |
| 400 | Bad request | - |
| 500 | Unexpected error | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
delete_config(config_id)
Delete a particular configuration.
- OAuth Authentication (OAuth2):
- OAuth Authentication (OAuth2):
import cyperf
from cyperf.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to http://localhost
# See configuration.py for a list of all supported configuration parameters.
configuration = cyperf.Configuration(
host = "http://localhost"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
configuration.refresh_token = os.environ["OFFLINE_TOKEN_FROM_CYPERF_UI"]
configuration.refresh_token = os.environ["OFFLINE_TOKEN_FROM_CYPERF_UI"]
# Enter a context with an instance of the API client
with cyperf.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = cyperf.ConfigurationsApi(api_client)
config_id = 'config_id_example' # str | The ID of the config.
try:
api_instance.delete_config(config_id)
except Exception as e:
print("Exception when calling ConfigurationsApi->delete_config: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| config_id | str | The ID of the config. |
void (empty response body)
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 204 | The configuration was successfully deleted. | - |
| 403 | The initiator of the request does not have enough privileges to perform the action. | - |
| 404 | A configuration with the specified ID was not found. | - |
| 500 | Unexpected error | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
ConfigMetadata get_config_by_id(config_id, include=include, resolve_dependencies=resolve_dependencies)
Get a particular configuration.
- OAuth Authentication (OAuth2):
- OAuth Authentication (OAuth2):
import cyperf
from cyperf.models.config_metadata import ConfigMetadata
from cyperf.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to http://localhost
# See configuration.py for a list of all supported configuration parameters.
configuration = cyperf.Configuration(
host = "http://localhost"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
configuration.refresh_token = os.environ["OFFLINE_TOKEN_FROM_CYPERF_UI"]
configuration.refresh_token = os.environ["OFFLINE_TOKEN_FROM_CYPERF_UI"]
# Enter a context with an instance of the API client
with cyperf.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = cyperf.ConfigurationsApi(api_client)
config_id = 'config_id_example' # str | The ID of the config.
include = 'include_example' # str | Specifies if the sub-fields that are objects should be included (eg. 'configData'). (optional)
resolve_dependencies = 'resolve_dependencies_example' # str | Specifies if the content of the referenced files (action payloads and TLS files) should be included. (optional)
try:
api_response = api_instance.get_config_by_id(config_id, include=include, resolve_dependencies=resolve_dependencies)
print("The response of ConfigurationsApi->get_config_by_id:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling ConfigurationsApi->get_config_by_id: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| config_id | str | The ID of the config. | |
| include | str | Specifies if the sub-fields that are objects should be included (eg. 'configData'). | [optional] |
| resolve_dependencies | str | Specifies if the content of the referenced files (action payloads and TLS files) should be included. | [optional] |
- Content-Type: Not defined
- Accept: application/json, application/x-zip, application/zip, multipart/form-data
| Status code | Description | Response headers |
|---|---|---|
| 200 | The requested configuration | - |
| 404 | A configuration with the specified ID was not found. | - |
| 500 | Unexpected error | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
ConfigCategory get_config_categorie_by_id(config_categorie_id)
returns a single configuration category with its subcategories.
- OAuth Authentication (OAuth2):
- OAuth Authentication (OAuth2):
import cyperf
from cyperf.models.config_category import ConfigCategory
from cyperf.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to http://localhost
# See configuration.py for a list of all supported configuration parameters.
configuration = cyperf.Configuration(
host = "http://localhost"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
configuration.refresh_token = os.environ["OFFLINE_TOKEN_FROM_CYPERF_UI"]
configuration.refresh_token = os.environ["OFFLINE_TOKEN_FROM_CYPERF_UI"]
# Enter a context with an instance of the API client
with cyperf.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = cyperf.ConfigurationsApi(api_client)
config_categorie_id = 'config_categorie_id_example' # str | The ID of the config categorie.
try:
api_response = api_instance.get_config_categorie_by_id(config_categorie_id)
print("The response of ConfigurationsApi->get_config_categorie_by_id:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling ConfigurationsApi->get_config_categorie_by_id: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| config_categorie_id | str | The ID of the config categorie. |
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | The filtered configuration category with subcategories | - |
| 500 | Internal server error | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
GetConfigCategorieSubcategories200Response get_config_categorie_subcategories(config_categorie_id, take=take, skip=skip)
- OAuth Authentication (OAuth2):
- OAuth Authentication (OAuth2):
import cyperf
from cyperf.models.get_config_categorie_subcategories200_response import GetConfigCategorieSubcategories200Response
from cyperf.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to http://localhost
# See configuration.py for a list of all supported configuration parameters.
configuration = cyperf.Configuration(
host = "http://localhost"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
configuration.refresh_token = os.environ["OFFLINE_TOKEN_FROM_CYPERF_UI"]
configuration.refresh_token = os.environ["OFFLINE_TOKEN_FROM_CYPERF_UI"]
# Enter a context with an instance of the API client
with cyperf.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = cyperf.ConfigurationsApi(api_client)
config_categorie_id = 'config_categorie_id_example' # str | The ID of the config categorie.
take = 56 # int | The number of search results to return (optional)
skip = 56 # int | The number of search results to skip (optional)
try:
api_response = api_instance.get_config_categorie_subcategories(config_categorie_id, take=take, skip=skip)
print("The response of ConfigurationsApi->get_config_categorie_subcategories:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling ConfigurationsApi->get_config_categorie_subcategories: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| config_categorie_id | str | The ID of the config categorie. | |
| take | int | The number of search results to return | [optional] |
| skip | int | The number of search results to skip | [optional] |
GetConfigCategorieSubcategories200Response
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | The list of subcategories for the specified category | - |
| 400 | Missing or invalid category parameter | - |
| 500 | Internal server error | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
GetConfigCategories200Response get_config_categories(take=take, skip=skip)
Get the list of available configuration categories.
- OAuth Authentication (OAuth2):
- OAuth Authentication (OAuth2):
import cyperf
from cyperf.models.get_config_categories200_response import GetConfigCategories200Response
from cyperf.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to http://localhost
# See configuration.py for a list of all supported configuration parameters.
configuration = cyperf.Configuration(
host = "http://localhost"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
configuration.refresh_token = os.environ["OFFLINE_TOKEN_FROM_CYPERF_UI"]
configuration.refresh_token = os.environ["OFFLINE_TOKEN_FROM_CYPERF_UI"]
# Enter a context with an instance of the API client
with cyperf.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = cyperf.ConfigurationsApi(api_client)
take = 56 # int | The number of search results to return (optional)
skip = 56 # int | The number of search results to skip (optional)
try:
api_response = api_instance.get_config_categories(take=take, skip=skip)
print("The response of ConfigurationsApi->get_config_categories:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling ConfigurationsApi->get_config_categories: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| take | int | The number of search results to return | [optional] |
| skip | int | The number of search results to skip | [optional] |
GetConfigCategories200Response
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | The list of configuration categories | - |
| 500 | Unexpected error | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
GetConfigs200Response get_configs(take=take, skip=skip, search_col=search_col, search_val=search_val, filter_mode=filter_mode, sort=sort)
Get all the configurations available to the current user.
- OAuth Authentication (OAuth2):
- OAuth Authentication (OAuth2):
import cyperf
from cyperf.models.get_configs200_response import GetConfigs200Response
from cyperf.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to http://localhost
# See configuration.py for a list of all supported configuration parameters.
configuration = cyperf.Configuration(
host = "http://localhost"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
configuration.refresh_token = os.environ["OFFLINE_TOKEN_FROM_CYPERF_UI"]
configuration.refresh_token = os.environ["OFFLINE_TOKEN_FROM_CYPERF_UI"]
# Enter a context with an instance of the API client
with cyperf.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = cyperf.ConfigurationsApi(api_client)
take = 56 # int | The number of search results to return (optional)
skip = 56 # int | The number of search results to skip (optional)
search_col = 'search_col_example' # str | A list of comma-separated columns used to search for the supplied values (optional)
search_val = 'search_val_example' # str | The keywords used to filter the items (optional)
filter_mode = 'filter_mode_example' # str | The operator applied to the supplied values (optional)
sort = 'sort_example' # str | A list of comma-separated field:direction pairs used to sort the items where direction must be asc or dsc (optional)
try:
api_response = api_instance.get_configs(take=take, skip=skip, search_col=search_col, search_val=search_val, filter_mode=filter_mode, sort=sort)
print("The response of ConfigurationsApi->get_configs:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling ConfigurationsApi->get_configs: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| take | int | The number of search results to return | [optional] |
| skip | int | The number of search results to skip | [optional] |
| search_col | str | A list of comma-separated columns used to search for the supplied values | [optional] |
| search_val | str | The keywords used to filter the items | [optional] |
| filter_mode | str | The operator applied to the supplied values | [optional] |
| sort | str | A list of comma-separated field:direction pairs used to sort the items where direction must be asc or dsc | [optional] |
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | The list of configurations | - |
| 500 | Unexpected error | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
GetResourcesCustomImportOperations200Response get_resources_custom_import_operations(take=take, skip=skip)
Get all the custom import config operations.
- OAuth Authentication (OAuth2):
- OAuth Authentication (OAuth2):
import cyperf
from cyperf.models.get_resources_custom_import_operations200_response import GetResourcesCustomImportOperations200Response
from cyperf.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to http://localhost
# See configuration.py for a list of all supported configuration parameters.
configuration = cyperf.Configuration(
host = "http://localhost"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
configuration.refresh_token = os.environ["OFFLINE_TOKEN_FROM_CYPERF_UI"]
configuration.refresh_token = os.environ["OFFLINE_TOKEN_FROM_CYPERF_UI"]
# Enter a context with an instance of the API client
with cyperf.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = cyperf.ConfigurationsApi(api_client)
take = 56 # int | The number of search results to return (optional)
skip = 56 # int | The number of search results to skip (optional)
try:
api_response = api_instance.get_resources_custom_import_operations(take=take, skip=skip)
print("The response of ConfigurationsApi->get_resources_custom_import_operations:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling ConfigurationsApi->get_resources_custom_import_operations: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| take | int | The number of search results to return | [optional] |
| skip | int | The number of search results to skip | [optional] |
GetResourcesCustomImportOperations200Response
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | The list of custom import config operations | - |
| 500 | Unexpected error | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
patch_config(config_id, config_metadata=config_metadata)
Update a particular configuration. Only non-null fields are updated.
- OAuth Authentication (OAuth2):
- OAuth Authentication (OAuth2):
import cyperf
from cyperf.models.config_metadata import ConfigMetadata
from cyperf.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to http://localhost
# See configuration.py for a list of all supported configuration parameters.
configuration = cyperf.Configuration(
host = "http://localhost"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
configuration.refresh_token = os.environ["OFFLINE_TOKEN_FROM_CYPERF_UI"]
configuration.refresh_token = os.environ["OFFLINE_TOKEN_FROM_CYPERF_UI"]
# Enter a context with an instance of the API client
with cyperf.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = cyperf.ConfigurationsApi(api_client)
config_id = 'config_id_example' # str | The ID of the config.
config_metadata = cyperf.ConfigMetadata() # ConfigMetadata | (optional)
try:
api_instance.patch_config(config_id, config_metadata=config_metadata)
except Exception as e:
print("Exception when calling ConfigurationsApi->patch_config: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| config_id | str | The ID of the config. | |
| config_metadata | ConfigMetadata | [optional] |
void (empty response body)
- Content-Type: application/json
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 204 | The configuration was successfully updated. | - |
| 404 | A configuration with the specified ID was not found. | - |
| 500 | Unexpected error | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
AsyncContext start_configs_batch_delete(start_agents_batch_delete_request_inner=start_agents_batch_delete_request_inner)
Remove multiple configurations.
- OAuth Authentication (OAuth2):
- OAuth Authentication (OAuth2):
import cyperf
from cyperf.models.async_context import AsyncContext
from cyperf.models.start_agents_batch_delete_request_inner import StartAgentsBatchDeleteRequestInner
from cyperf.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to http://localhost
# See configuration.py for a list of all supported configuration parameters.
configuration = cyperf.Configuration(
host = "http://localhost"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
configuration.refresh_token = os.environ["OFFLINE_TOKEN_FROM_CYPERF_UI"]
configuration.refresh_token = os.environ["OFFLINE_TOKEN_FROM_CYPERF_UI"]
# Enter a context with an instance of the API client
with cyperf.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = cyperf.ConfigurationsApi(api_client)
start_agents_batch_delete_request_inner = [cyperf.StartAgentsBatchDeleteRequestInner()] # List[StartAgentsBatchDeleteRequestInner] | (optional)
try:
api_response = api_instance.start_configs_batch_delete(start_agents_batch_delete_request_inner=start_agents_batch_delete_request_inner)
print("The response of ConfigurationsApi->start_configs_batch_delete:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling ConfigurationsApi->start_configs_batch_delete: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| start_agents_batch_delete_request_inner | List[StartAgentsBatchDeleteRequestInner] | [optional] |
- Content-Type: application/json
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 202 | Details about the operation that just started | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
AsyncContext start_configs_export_all(export_all_operation=export_all_operation)
Export all configurations owned by the current user. Optionally, provide a list of config IDs to export.
- OAuth Authentication (OAuth2):
- OAuth Authentication (OAuth2):
import cyperf
from cyperf.models.async_context import AsyncContext
from cyperf.models.export_all_operation import ExportAllOperation
from cyperf.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to http://localhost
# See configuration.py for a list of all supported configuration parameters.
configuration = cyperf.Configuration(
host = "http://localhost"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
configuration.refresh_token = os.environ["OFFLINE_TOKEN_FROM_CYPERF_UI"]
configuration.refresh_token = os.environ["OFFLINE_TOKEN_FROM_CYPERF_UI"]
# Enter a context with an instance of the API client
with cyperf.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = cyperf.ConfigurationsApi(api_client)
export_all_operation = cyperf.ExportAllOperation() # ExportAllOperation | (optional)
try:
api_response = api_instance.start_configs_export_all(export_all_operation=export_all_operation)
print("The response of ConfigurationsApi->start_configs_export_all:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling ConfigurationsApi->start_configs_export_all: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| export_all_operation | ExportAllOperation | [optional] |
- Content-Type: application/json
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 202 | Details about the operation that just started | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
AsyncContext start_configs_import(body=body)
Import a single configuration from the specified file.
- OAuth Authentication (OAuth2):
- OAuth Authentication (OAuth2):
import cyperf
from cyperf.models.async_context import AsyncContext
from cyperf.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to http://localhost
# See configuration.py for a list of all supported configuration parameters.
configuration = cyperf.Configuration(
host = "http://localhost"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
configuration.refresh_token = os.environ["OFFLINE_TOKEN_FROM_CYPERF_UI"]
configuration.refresh_token = os.environ["OFFLINE_TOKEN_FROM_CYPERF_UI"]
# Enter a context with an instance of the API client
with cyperf.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = cyperf.ConfigurationsApi(api_client)
body = None # bytearray | (optional)
try:
api_response = api_instance.start_configs_import(body=body)
print("The response of ConfigurationsApi->start_configs_import:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling ConfigurationsApi->start_configs_import: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| body | bytearray | [optional] |
- Content-Type: application/x-zip, application/zip, multipart/form-data
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 202 | Details about the operation that just started | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
AsyncContext start_configs_import_all(import_all_operation=import_all_operation)
Import all configurations from the specified file.
- OAuth Authentication (OAuth2):
- OAuth Authentication (OAuth2):
import cyperf
from cyperf.models.async_context import AsyncContext
from cyperf.models.import_all_operation import ImportAllOperation
from cyperf.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to http://localhost
# See configuration.py for a list of all supported configuration parameters.
configuration = cyperf.Configuration(
host = "http://localhost"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
configuration.refresh_token = os.environ["OFFLINE_TOKEN_FROM_CYPERF_UI"]
configuration.refresh_token = os.environ["OFFLINE_TOKEN_FROM_CYPERF_UI"]
# Enter a context with an instance of the API client
with cyperf.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = cyperf.ConfigurationsApi(api_client)
import_all_operation = cyperf.ImportAllOperation() # ImportAllOperation | (optional)
try:
api_response = api_instance.start_configs_import_all(import_all_operation=import_all_operation)
print("The response of ConfigurationsApi->start_configs_import_all:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling ConfigurationsApi->start_configs_import_all: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| import_all_operation | ImportAllOperation | [optional] |
- Content-Type: application/json
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 202 | Details about the operation that just started | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
ConfigMetadata update_config(config_id, config_metadata=config_metadata)
Update a particular configuration.
- OAuth Authentication (OAuth2):
- OAuth Authentication (OAuth2):
import cyperf
from cyperf.models.config_metadata import ConfigMetadata
from cyperf.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to http://localhost
# See configuration.py for a list of all supported configuration parameters.
configuration = cyperf.Configuration(
host = "http://localhost"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
configuration.refresh_token = os.environ["OFFLINE_TOKEN_FROM_CYPERF_UI"]
configuration.refresh_token = os.environ["OFFLINE_TOKEN_FROM_CYPERF_UI"]
# Enter a context with an instance of the API client
with cyperf.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = cyperf.ConfigurationsApi(api_client)
config_id = 'config_id_example' # str | The ID of the config.
config_metadata = cyperf.ConfigMetadata() # ConfigMetadata | (optional)
try:
api_response = api_instance.update_config(config_id, config_metadata=config_metadata)
print("The response of ConfigurationsApi->update_config:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling ConfigurationsApi->update_config: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| config_id | str | The ID of the config. | |
| config_metadata | ConfigMetadata | [optional] |
- Content-Type: application/json
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | The updated configuration | - |
| 400 | Bad request | - |
| 404 | A configuration with the specified ID was not found. | - |
| 500 | Unexpected error | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]