Skip to content

Latest commit

 

History

History
1552 lines (1098 loc) · 59.7 KB

File metadata and controls

1552 lines (1098 loc) · 59.7 KB

watchtowr_api_sdk.DomainsApi

All URIs are relative to https://your-tenant-id.sg.client.watchtowr.io

Method HTTP request Description
assign_domain_to_business_units POST /api/client/assets/domain/show/{id}/business-units Assign Domain to Business Units
create_asset_domain_note POST /api/client/assets/domain/show/{id}/note Create Note
create_custom_property_domain POST /api/client/assets/domain/show/{id}/custom-property Create Custom Property
delete_asset_domain_note DELETE /api/client/assets/domain/show/{id}/note/{noteId} Delete Note
delete_custom_property_domain DELETE /api/client/assets/domain/show/{id}/custom-property/{customPropertyId} Delete Custom Property
get_asset_domain_changelog GET /api/client/assets/domain/show/{id}/changelog Get Domain Changelog
get_asset_domain_details GET /api/client/assets/domain/show/{id} Get Domain Details
get_asset_domain_dns_records GET /api/client/assets/domain/show/{id}/dns-records List DNS Records
get_asset_domain_engine_settings GET /api/client/assets/domain/show/{id}/engine-settings Get Domain Engine Settings
get_asset_domain_notes GET /api/client/assets/domain/show/{id}/notes List Notes
get_custom_properties_domain GET /api/client/assets/domain/show/{id}/custom-properties List Custom Properties
get_list_asset_domains GET /api/client/assets/domain/list List Domains
set_criticality_domain PUT /api/client/assets/domain/show/{id}/criticality Set Criticality
unassign_domain_from_business_units DELETE /api/client/assets/domain/show/{id}/business-units Unassign Domain from Business Units
update_asset_domain_engine_settings PUT /api/client/assets/domain/show/{id}/engine-settings Update Domain Engine Settings
update_asset_domain_note PUT /api/client/assets/domain/show/{id}/note/{noteId} Update Note
update_asset_domain_status PUT /api/client/assets/domain/update-status/{id} Update Status
update_custom_property_domain PUT /api/client/assets/domain/show/{id}/custom-property/{customPropertyId} Update Custom Property

assign_domain_to_business_units

ClientDomainData assign_domain_to_business_units(id, hostname_business_unit_ids_dto)

Assign Domain to Business Units

Assign a specific Domain asset to a list of Business Units

Example

  • Bearer (API_TOKEN) Authentication (bearer):
import watchtowr_api_sdk
from watchtowr_api_sdk.models.client_domain_data import ClientDomainData
from watchtowr_api_sdk.models.hostname_business_unit_ids_dto import HostnameBusinessUnitIDsDTO
from watchtowr_api_sdk.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to https://your-tenant-id.sg.client.watchtowr.io
# See configuration.py for a list of all supported configuration parameters.
configuration = watchtowr_api_sdk.Configuration(
    host = "https://your-tenant-id.sg.client.watchtowr.io"
)

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

# Configure Bearer authorization (API_TOKEN): bearer
configuration = watchtowr_api_sdk.Configuration(
    access_token = os.environ["BEARER_TOKEN"]
)

# Enter a context with an instance of the API client
with watchtowr_api_sdk.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = watchtowr_api_sdk.DomainsApi(api_client)
    id = 3.4 # float | The Domain asset's ID.
    hostname_business_unit_ids_dto = watchtowr_api_sdk.HostnameBusinessUnitIDsDTO() # HostnameBusinessUnitIDsDTO | 

    try:
        # Assign Domain to Business Units
        api_response = api_instance.assign_domain_to_business_units(id, hostname_business_unit_ids_dto)
        print("The response of DomainsApi->assign_domain_to_business_units:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling DomainsApi->assign_domain_to_business_units: %s\n" % e)

Parameters

Name Type Description Notes
id float The Domain asset's ID.
hostname_business_unit_ids_dto HostnameBusinessUnitIDsDTO

Return type

ClientDomainData

Authorization

bearer

HTTP request headers

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

HTTP response details

Status code Description Response headers
200 Success -
401 Unauthorized -
403 Forbidden -
404 Not Found -
409 Conflict -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

create_asset_domain_note

ClientNoteData create_asset_domain_note(id, create_client_note_dto)

Create Note

Create a Note for a specific Domain asset.

Example

  • Bearer (API_TOKEN) Authentication (bearer):
import watchtowr_api_sdk
from watchtowr_api_sdk.models.client_note_data import ClientNoteData
from watchtowr_api_sdk.models.create_client_note_dto import CreateClientNoteDto
from watchtowr_api_sdk.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to https://your-tenant-id.sg.client.watchtowr.io
# See configuration.py for a list of all supported configuration parameters.
configuration = watchtowr_api_sdk.Configuration(
    host = "https://your-tenant-id.sg.client.watchtowr.io"
)

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

# Configure Bearer authorization (API_TOKEN): bearer
configuration = watchtowr_api_sdk.Configuration(
    access_token = os.environ["BEARER_TOKEN"]
)

# Enter a context with an instance of the API client
with watchtowr_api_sdk.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = watchtowr_api_sdk.DomainsApi(api_client)
    id = 3.4 # float | The asset ID of the Domain to create a new note for.
    create_client_note_dto = watchtowr_api_sdk.CreateClientNoteDto() # CreateClientNoteDto | 

    try:
        # Create Note
        api_response = api_instance.create_asset_domain_note(id, create_client_note_dto)
        print("The response of DomainsApi->create_asset_domain_note:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling DomainsApi->create_asset_domain_note: %s\n" % e)

Parameters

Name Type Description Notes
id float The asset ID of the Domain to create a new note for.
create_client_note_dto CreateClientNoteDto

Return type

ClientNoteData

Authorization

bearer

HTTP request headers

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

HTTP response details

Status code Description Response headers
200 Success -
401 Unauthorized -
404 Not Found -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

create_custom_property_domain

ClientCustomProperty create_custom_property_domain(id, create_client_custom_property_dto)

Create Custom Property

Create a Custom Property for a specific Domain asset.

Example

  • Bearer (API_TOKEN) Authentication (bearer):
import watchtowr_api_sdk
from watchtowr_api_sdk.models.client_custom_property import ClientCustomProperty
from watchtowr_api_sdk.models.create_client_custom_property_dto import CreateClientCustomPropertyDto
from watchtowr_api_sdk.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to https://your-tenant-id.sg.client.watchtowr.io
# See configuration.py for a list of all supported configuration parameters.
configuration = watchtowr_api_sdk.Configuration(
    host = "https://your-tenant-id.sg.client.watchtowr.io"
)

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

# Configure Bearer authorization (API_TOKEN): bearer
configuration = watchtowr_api_sdk.Configuration(
    access_token = os.environ["BEARER_TOKEN"]
)

# Enter a context with an instance of the API client
with watchtowr_api_sdk.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = watchtowr_api_sdk.DomainsApi(api_client)
    id = 3.4 # float | The asset ID of the Domain to create a new custom property for.
    create_client_custom_property_dto = watchtowr_api_sdk.CreateClientCustomPropertyDto() # CreateClientCustomPropertyDto | 

    try:
        # Create Custom Property
        api_response = api_instance.create_custom_property_domain(id, create_client_custom_property_dto)
        print("The response of DomainsApi->create_custom_property_domain:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling DomainsApi->create_custom_property_domain: %s\n" % e)

Parameters

Name Type Description Notes
id float The asset ID of the Domain to create a new custom property for.
create_client_custom_property_dto CreateClientCustomPropertyDto

Return type

ClientCustomProperty

Authorization

bearer

HTTP request headers

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

HTTP response details

Status code Description Response headers
200 Success -
401 Unauthorized -
403 Forbidden -
404 Not Found -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

delete_asset_domain_note

DeleteNoteSucces delete_asset_domain_note(id, note_id)

Delete Note

Delete a Note for a specific Domain asset.

Example

  • Bearer (API_TOKEN) Authentication (bearer):
import watchtowr_api_sdk
from watchtowr_api_sdk.models.delete_note_succes import DeleteNoteSucces
from watchtowr_api_sdk.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to https://your-tenant-id.sg.client.watchtowr.io
# See configuration.py for a list of all supported configuration parameters.
configuration = watchtowr_api_sdk.Configuration(
    host = "https://your-tenant-id.sg.client.watchtowr.io"
)

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

# Configure Bearer authorization (API_TOKEN): bearer
configuration = watchtowr_api_sdk.Configuration(
    access_token = os.environ["BEARER_TOKEN"]
)

# Enter a context with an instance of the API client
with watchtowr_api_sdk.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = watchtowr_api_sdk.DomainsApi(api_client)
    id = 3.4 # float | The asset ID of a Domain with a note to delete.
    note_id = 3.4 # float | The ID of the note to delete.

    try:
        # Delete Note
        api_response = api_instance.delete_asset_domain_note(id, note_id)
        print("The response of DomainsApi->delete_asset_domain_note:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling DomainsApi->delete_asset_domain_note: %s\n" % e)

Parameters

Name Type Description Notes
id float The asset ID of a Domain with a note to delete.
note_id float The ID of the note to delete.

Return type

DeleteNoteSucces

Authorization

bearer

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status code Description Response headers
200 Success -
401 Unauthorized -
404 Not Found -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

delete_custom_property_domain

RemoveClientCustomPropertyResponseDto delete_custom_property_domain(id, custom_property_id)

Delete Custom Property

Delete a Custom Property for a specific Domain asset.

Example

  • Bearer (API_TOKEN) Authentication (bearer):
import watchtowr_api_sdk
from watchtowr_api_sdk.models.remove_client_custom_property_response_dto import RemoveClientCustomPropertyResponseDto
from watchtowr_api_sdk.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to https://your-tenant-id.sg.client.watchtowr.io
# See configuration.py for a list of all supported configuration parameters.
configuration = watchtowr_api_sdk.Configuration(
    host = "https://your-tenant-id.sg.client.watchtowr.io"
)

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

# Configure Bearer authorization (API_TOKEN): bearer
configuration = watchtowr_api_sdk.Configuration(
    access_token = os.environ["BEARER_TOKEN"]
)

# Enter a context with an instance of the API client
with watchtowr_api_sdk.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = watchtowr_api_sdk.DomainsApi(api_client)
    id = 3.4 # float | The asset ID of a Domain with a custom property to delete.
    custom_property_id = 3.4 # float | The ID of the custom property to delete.

    try:
        # Delete Custom Property
        api_response = api_instance.delete_custom_property_domain(id, custom_property_id)
        print("The response of DomainsApi->delete_custom_property_domain:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling DomainsApi->delete_custom_property_domain: %s\n" % e)

Parameters

Name Type Description Notes
id float The asset ID of a Domain with a custom property to delete.
custom_property_id float The ID of the custom property to delete.

Return type

RemoveClientCustomPropertyResponseDto

Authorization

bearer

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status code Description Response headers
200 Success -
401 Unauthorized -
403 Forbidden -
404 Not Found -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

get_asset_domain_changelog

GetAssetDomainChangelog200Response get_asset_domain_changelog(id, page=page, page_size=page_size)

Get Domain Changelog

Get paginated changelog for a specific Domain asset.

Example

  • Bearer (API_TOKEN) Authentication (bearer):
import watchtowr_api_sdk
from watchtowr_api_sdk.models.get_asset_domain_changelog200_response import GetAssetDomainChangelog200Response
from watchtowr_api_sdk.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to https://your-tenant-id.sg.client.watchtowr.io
# See configuration.py for a list of all supported configuration parameters.
configuration = watchtowr_api_sdk.Configuration(
    host = "https://your-tenant-id.sg.client.watchtowr.io"
)

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

# Configure Bearer authorization (API_TOKEN): bearer
configuration = watchtowr_api_sdk.Configuration(
    access_token = os.environ["BEARER_TOKEN"]
)

# Enter a context with an instance of the API client
with watchtowr_api_sdk.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = watchtowr_api_sdk.DomainsApi(api_client)
    id = 3.4 # float | The asset ID of the Domain to retrieve changelog for.
    page = 1 # float | The page number for paginated results. If the page field is not provided in the request, it defaults to 1, which corresponds to the first page of results. (optional)
    page_size = 10 # float | The number of items to be included on each page of paginated results. If the pageSize field is not specified, it defaults to 10. The maximum for pageSize is 30. (optional)

    try:
        # Get Domain Changelog
        api_response = api_instance.get_asset_domain_changelog(id, page=page, page_size=page_size)
        print("The response of DomainsApi->get_asset_domain_changelog:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling DomainsApi->get_asset_domain_changelog: %s\n" % e)

Parameters

Name Type Description Notes
id float The asset ID of the Domain to retrieve changelog for.
page float The page number for paginated results. If the page field is not provided in the request, it defaults to 1, which corresponds to the first page of results. [optional]
page_size float The number of items to be included on each page of paginated results. If the pageSize field is not specified, it defaults to 10. The maximum for pageSize is 30. [optional]

Return type

GetAssetDomainChangelog200Response

Authorization

bearer

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status code Description Response headers
200 Success -
401 Unauthorized -
403 Forbidden -
404 Not Found -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

get_asset_domain_details

ClientDomainData get_asset_domain_details(id)

Get Domain Details

Get the details of a specific Domain asset.

Example

  • Bearer (API_TOKEN) Authentication (bearer):
import watchtowr_api_sdk
from watchtowr_api_sdk.models.client_domain_data import ClientDomainData
from watchtowr_api_sdk.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to https://your-tenant-id.sg.client.watchtowr.io
# See configuration.py for a list of all supported configuration parameters.
configuration = watchtowr_api_sdk.Configuration(
    host = "https://your-tenant-id.sg.client.watchtowr.io"
)

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

# Configure Bearer authorization (API_TOKEN): bearer
configuration = watchtowr_api_sdk.Configuration(
    access_token = os.environ["BEARER_TOKEN"]
)

# Enter a context with an instance of the API client
with watchtowr_api_sdk.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = watchtowr_api_sdk.DomainsApi(api_client)
    id = 3.4 # float | The asset ID of the Domain to retrieve.

    try:
        # Get Domain Details
        api_response = api_instance.get_asset_domain_details(id)
        print("The response of DomainsApi->get_asset_domain_details:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling DomainsApi->get_asset_domain_details: %s\n" % e)

Parameters

Name Type Description Notes
id float The asset ID of the Domain to retrieve.

Return type

ClientDomainData

Authorization

bearer

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status code Description Response headers
200 Success -
401 Unauthorized -
403 Forbidden -
404 Not Found -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

get_asset_domain_dns_records

ClientDnsRecordListData get_asset_domain_dns_records(id, page=page, page_size=page_size)

List DNS Records

List DNS Records of a specific Domain asset.

Example

  • Bearer (API_TOKEN) Authentication (bearer):
import watchtowr_api_sdk
from watchtowr_api_sdk.models.client_dns_record_list_data import ClientDnsRecordListData
from watchtowr_api_sdk.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to https://your-tenant-id.sg.client.watchtowr.io
# See configuration.py for a list of all supported configuration parameters.
configuration = watchtowr_api_sdk.Configuration(
    host = "https://your-tenant-id.sg.client.watchtowr.io"
)

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

# Configure Bearer authorization (API_TOKEN): bearer
configuration = watchtowr_api_sdk.Configuration(
    access_token = os.environ["BEARER_TOKEN"]
)

# Enter a context with an instance of the API client
with watchtowr_api_sdk.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = watchtowr_api_sdk.DomainsApi(api_client)
    id = 3.4 # float | The asset ID of the Domain to list DNS records of.
    page = 1 # float | The page number for paginated results. If the page field is not provided in the request, it defaults to 1, which corresponds to the first page of results. (optional)
    page_size = 10 # float | The number of items to be included on each page of paginated results. If the pageSize field is not specified, it defaults to 10. The maximum for pageSize is 30. (optional)

    try:
        # List DNS Records
        api_response = api_instance.get_asset_domain_dns_records(id, page=page, page_size=page_size)
        print("The response of DomainsApi->get_asset_domain_dns_records:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling DomainsApi->get_asset_domain_dns_records: %s\n" % e)

Parameters

Name Type Description Notes
id float The asset ID of the Domain to list DNS records of.
page float The page number for paginated results. If the page field is not provided in the request, it defaults to 1, which corresponds to the first page of results. [optional]
page_size float The number of items to be included on each page of paginated results. If the pageSize field is not specified, it defaults to 10. The maximum for pageSize is 30. [optional]

Return type

ClientDnsRecordListData

Authorization

bearer

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status code Description Response headers
200 Success -
401 Unauthorized -
404 Not Found -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

get_asset_domain_engine_settings

ClientEngineSettingsData get_asset_domain_engine_settings(id)

Get Domain Engine Settings

Get the engine settings for a specific domain asset.

Example

  • Bearer (API_TOKEN) Authentication (bearer):
import watchtowr_api_sdk
from watchtowr_api_sdk.models.client_engine_settings_data import ClientEngineSettingsData
from watchtowr_api_sdk.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to https://your-tenant-id.sg.client.watchtowr.io
# See configuration.py for a list of all supported configuration parameters.
configuration = watchtowr_api_sdk.Configuration(
    host = "https://your-tenant-id.sg.client.watchtowr.io"
)

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

# Configure Bearer authorization (API_TOKEN): bearer
configuration = watchtowr_api_sdk.Configuration(
    access_token = os.environ["BEARER_TOKEN"]
)

# Enter a context with an instance of the API client
with watchtowr_api_sdk.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = watchtowr_api_sdk.DomainsApi(api_client)
    id = 3.4 # float | The asset ID of the domain to retrieve engine settings for.

    try:
        # Get Domain Engine Settings
        api_response = api_instance.get_asset_domain_engine_settings(id)
        print("The response of DomainsApi->get_asset_domain_engine_settings:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling DomainsApi->get_asset_domain_engine_settings: %s\n" % e)

Parameters

Name Type Description Notes
id float The asset ID of the domain to retrieve engine settings for.

Return type

ClientEngineSettingsData

Authorization

bearer

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status code Description Response headers
200 Success -
401 Unauthorized -
403 Forbidden -
404 Not Found -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

get_asset_domain_notes

ClientNoteListData get_asset_domain_notes(id, page=page, page_size=page_size)

List Notes

List the Notes of a specific Domain asset.

Example

  • Bearer (API_TOKEN) Authentication (bearer):
import watchtowr_api_sdk
from watchtowr_api_sdk.models.client_note_list_data import ClientNoteListData
from watchtowr_api_sdk.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to https://your-tenant-id.sg.client.watchtowr.io
# See configuration.py for a list of all supported configuration parameters.
configuration = watchtowr_api_sdk.Configuration(
    host = "https://your-tenant-id.sg.client.watchtowr.io"
)

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

# Configure Bearer authorization (API_TOKEN): bearer
configuration = watchtowr_api_sdk.Configuration(
    access_token = os.environ["BEARER_TOKEN"]
)

# Enter a context with an instance of the API client
with watchtowr_api_sdk.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = watchtowr_api_sdk.DomainsApi(api_client)
    id = 3.4 # float | The asset ID of the Domain to list notes of.
    page = 1 # float | The page number for paginated results. If the page field is not provided in the request, it defaults to 1, which corresponds to the first page of results. (optional)
    page_size = 10 # float | The number of items to be included on each page of paginated results. If the pageSize field is not specified, it defaults to 10. The maximum for pageSize is 30. (optional)

    try:
        # List Notes
        api_response = api_instance.get_asset_domain_notes(id, page=page, page_size=page_size)
        print("The response of DomainsApi->get_asset_domain_notes:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling DomainsApi->get_asset_domain_notes: %s\n" % e)

Parameters

Name Type Description Notes
id float The asset ID of the Domain to list notes of.
page float The page number for paginated results. If the page field is not provided in the request, it defaults to 1, which corresponds to the first page of results. [optional]
page_size float The number of items to be included on each page of paginated results. If the pageSize field is not specified, it defaults to 10. The maximum for pageSize is 30. [optional]

Return type

ClientNoteListData

Authorization

bearer

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status code Description Response headers
200 Success -
401 Unauthorized -
404 Not Found -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

get_custom_properties_domain

PaginatedClientCustomProperty get_custom_properties_domain(id, page=page, page_size=page_size)

List Custom Properties

List the Custom Properties of a specific Domain asset.

Example

  • Bearer (API_TOKEN) Authentication (bearer):
import watchtowr_api_sdk
from watchtowr_api_sdk.models.paginated_client_custom_property import PaginatedClientCustomProperty
from watchtowr_api_sdk.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to https://your-tenant-id.sg.client.watchtowr.io
# See configuration.py for a list of all supported configuration parameters.
configuration = watchtowr_api_sdk.Configuration(
    host = "https://your-tenant-id.sg.client.watchtowr.io"
)

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

# Configure Bearer authorization (API_TOKEN): bearer
configuration = watchtowr_api_sdk.Configuration(
    access_token = os.environ["BEARER_TOKEN"]
)

# Enter a context with an instance of the API client
with watchtowr_api_sdk.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = watchtowr_api_sdk.DomainsApi(api_client)
    id = 3.4 # float | The asset ID of the Domain to list custom properties of.
    page = 1 # float | The page number for paginated results. If the page field is not provided in the request, it defaults to 1, which corresponds to the first page of results. (optional)
    page_size = 10 # float | The number of items to be included on each page of paginated results. If the pageSize field is not specified, it defaults to 10. The maximum for pageSize is 30. (optional)

    try:
        # List Custom Properties
        api_response = api_instance.get_custom_properties_domain(id, page=page, page_size=page_size)
        print("The response of DomainsApi->get_custom_properties_domain:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling DomainsApi->get_custom_properties_domain: %s\n" % e)

Parameters

Name Type Description Notes
id float The asset ID of the Domain to list custom properties of.
page float The page number for paginated results. If the page field is not provided in the request, it defaults to 1, which corresponds to the first page of results. [optional]
page_size float The number of items to be included on each page of paginated results. If the pageSize field is not specified, it defaults to 10. The maximum for pageSize is 30. [optional]

Return type

PaginatedClientCustomProperty

Authorization

bearer

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status code Description Response headers
200 Success -
401 Unauthorized -
403 Forbidden -
404 Not Found -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

get_list_asset_domains

PaginatedClientDomain get_list_asset_domains(page=page, page_size=page_size, asset_name=asset_name, statuses=statuses, source=source, integration_connections=integration_connections, business_unit_ids=business_unit_ids, created_from=created_from, created_to=created_to, custom_property_key=custom_property_key, custom_property_value=custom_property_value)

List Domains

List all discovered Domain assets, ordered by date identified.

Example

  • Bearer (API_TOKEN) Authentication (bearer):
import watchtowr_api_sdk
from watchtowr_api_sdk.models.paginated_client_domain import PaginatedClientDomain
from watchtowr_api_sdk.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to https://your-tenant-id.sg.client.watchtowr.io
# See configuration.py for a list of all supported configuration parameters.
configuration = watchtowr_api_sdk.Configuration(
    host = "https://your-tenant-id.sg.client.watchtowr.io"
)

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

# Configure Bearer authorization (API_TOKEN): bearer
configuration = watchtowr_api_sdk.Configuration(
    access_token = os.environ["BEARER_TOKEN"]
)

# Enter a context with an instance of the API client
with watchtowr_api_sdk.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = watchtowr_api_sdk.DomainsApi(api_client)
    page = 1 # float | The page number for paginated results. If the page field is not provided in the request, it defaults to 1, which corresponds to the first page of results. (optional)
    page_size = 10 # float | The number of items to be included on each page of paginated results. If the pageSize field is not specified, it defaults to 10. The maximum for pageSize is 100. (optional)
    asset_name = 'watchtowr.com' # str | Search domain assets by name. (optional)
    statuses = ['statuses_example'] # List[str] | Filter assets by one or more comma separated asset statuses. Valid statuses are:       * verified       * incorrect identification       * pending       * verifiedOutOfScope       * verifiedReducedAttack       * parked  (optional)
    source = 'watchtowr-cloud-integration-aws-hosts' # str | Filter assets by the source that discovered the asset. (optional)
    integration_connections = '123:aws,456:azure,789:googlecloud' # str | Filter assets by integration connections (comma-separated list of integrationId:integrationType pairs).  Valid integration types: aws, googlecloud, azure, cloudflare, alibabacloud, prismacloud, prismacloudapigee, huaweicloud, tencentcloud, wiz, servicenowcmdb, akamaiedge, fastly, markmonitor, armiscentrix, qualysvmdr, tenablevm, orcasecurity, crowdstrikefalconspotlight, taniumvm, rapid7insightvm, fastlywaf, cloudflarewaf, awswaf  Format: integrationId:integrationType (e.g., 123:aws) Multiple connections: separate with commas (e.g., 123:aws,456:azure,789:googlecloud) (optional)
    business_unit_ids = '1,2,3' # str | Filter assets by a list of comma separated business unit IDs that the asset is related to. (optional)
    created_from = '2013-10-20T19:20:30+01:00' # datetime | Filter assets created after a given date and time. (optional)
    created_to = '2013-10-20T19:20:30+01:00' # datetime | Filter assets created before a given date and time. (optional)
    custom_property_key = 'environment' # str | Filter assets by custom property key. (optional)
    custom_property_value = 'production' # str | Filter assets by custom property value. Must be used together with customPropertyKey. (optional)

    try:
        # List Domains
        api_response = api_instance.get_list_asset_domains(page=page, page_size=page_size, asset_name=asset_name, statuses=statuses, source=source, integration_connections=integration_connections, business_unit_ids=business_unit_ids, created_from=created_from, created_to=created_to, custom_property_key=custom_property_key, custom_property_value=custom_property_value)
        print("The response of DomainsApi->get_list_asset_domains:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling DomainsApi->get_list_asset_domains: %s\n" % e)

Parameters

Name Type Description Notes
page float The page number for paginated results. If the page field is not provided in the request, it defaults to 1, which corresponds to the first page of results. [optional]
page_size float The number of items to be included on each page of paginated results. If the pageSize field is not specified, it defaults to 10. The maximum for pageSize is 100. [optional]
asset_name str Search domain assets by name. [optional]
statuses List[str] Filter assets by one or more comma separated asset statuses. Valid statuses are: * verified * incorrect identification * pending * verifiedOutOfScope * verifiedReducedAttack * parked [optional]
source str Filter assets by the source that discovered the asset. [optional]
integration_connections str Filter assets by integration connections (comma-separated list of integrationId:integrationType pairs). Valid integration types: aws, googlecloud, azure, cloudflare, alibabacloud, prismacloud, prismacloudapigee, huaweicloud, tencentcloud, wiz, servicenowcmdb, akamaiedge, fastly, markmonitor, armiscentrix, qualysvmdr, tenablevm, orcasecurity, crowdstrikefalconspotlight, taniumvm, rapid7insightvm, fastlywaf, cloudflarewaf, awswaf Format: integrationId:integrationType (e.g., 123:aws) Multiple connections: separate with commas (e.g., 123:aws,456:azure,789:googlecloud) [optional]
business_unit_ids str Filter assets by a list of comma separated business unit IDs that the asset is related to. [optional]
created_from datetime Filter assets created after a given date and time. [optional]
created_to datetime Filter assets created before a given date and time. [optional]
custom_property_key str Filter assets by custom property key. [optional]
custom_property_value str Filter assets by custom property value. Must be used together with customPropertyKey. [optional]

Return type

PaginatedClientDomain

Authorization

bearer

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status code Description Response headers
200 Success -
401 Unauthorized -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

set_criticality_domain

SetCriticalityDataResponseDto set_criticality_domain(id, set_criticality_dto)

Set Criticality

Set or update the criticality level of a specific Domain asset.

Example

  • Bearer (API_TOKEN) Authentication (bearer):
import watchtowr_api_sdk
from watchtowr_api_sdk.models.set_criticality_data_response_dto import SetCriticalityDataResponseDto
from watchtowr_api_sdk.models.set_criticality_dto import SetCriticalityDto
from watchtowr_api_sdk.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to https://your-tenant-id.sg.client.watchtowr.io
# See configuration.py for a list of all supported configuration parameters.
configuration = watchtowr_api_sdk.Configuration(
    host = "https://your-tenant-id.sg.client.watchtowr.io"
)

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

# Configure Bearer authorization (API_TOKEN): bearer
configuration = watchtowr_api_sdk.Configuration(
    access_token = os.environ["BEARER_TOKEN"]
)

# Enter a context with an instance of the API client
with watchtowr_api_sdk.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = watchtowr_api_sdk.DomainsApi(api_client)
    id = 3.4 # float | The asset ID of the Domain to set criticality for.
    set_criticality_dto = watchtowr_api_sdk.SetCriticalityDto() # SetCriticalityDto | 

    try:
        # Set Criticality
        api_response = api_instance.set_criticality_domain(id, set_criticality_dto)
        print("The response of DomainsApi->set_criticality_domain:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling DomainsApi->set_criticality_domain: %s\n" % e)

Parameters

Name Type Description Notes
id float The asset ID of the Domain to set criticality for.
set_criticality_dto SetCriticalityDto

Return type

SetCriticalityDataResponseDto

Authorization

bearer

HTTP request headers

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

HTTP response details

Status code Description Response headers
200 Success -
401 Unauthorized -
403 Forbidden -
404 Not Found -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

unassign_domain_from_business_units

ClientDomainData unassign_domain_from_business_units(id, business_unit_ids, cascade_subdomain, cascade_ip)

Unassign Domain from Business Units

Unassign a specific Domain asset from a list of Business Units

Example

  • Bearer (API_TOKEN) Authentication (bearer):
import watchtowr_api_sdk
from watchtowr_api_sdk.models.client_domain_data import ClientDomainData
from watchtowr_api_sdk.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to https://your-tenant-id.sg.client.watchtowr.io
# See configuration.py for a list of all supported configuration parameters.
configuration = watchtowr_api_sdk.Configuration(
    host = "https://your-tenant-id.sg.client.watchtowr.io"
)

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

# Configure Bearer authorization (API_TOKEN): bearer
configuration = watchtowr_api_sdk.Configuration(
    access_token = os.environ["BEARER_TOKEN"]
)

# Enter a context with an instance of the API client
with watchtowr_api_sdk.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = watchtowr_api_sdk.DomainsApi(api_client)
    id = 3.4 # float | The Domain asset's ID.
    business_unit_ids = ['business_unit_ids_example'] # List[str] | List of comma-seperated business unit IDs to unassign from the asset.
    cascade_subdomain = 'cascade_subdomain_example' # str | Cascade business units to domain's subdomains
    cascade_ip = 'cascade_ip_example' # str | Cascade business units to domain's ipaddresses

    try:
        # Unassign Domain from Business Units
        api_response = api_instance.unassign_domain_from_business_units(id, business_unit_ids, cascade_subdomain, cascade_ip)
        print("The response of DomainsApi->unassign_domain_from_business_units:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling DomainsApi->unassign_domain_from_business_units: %s\n" % e)

Parameters

Name Type Description Notes
id float The Domain asset's ID.
business_unit_ids List[str] List of comma-seperated business unit IDs to unassign from the asset.
cascade_subdomain str Cascade business units to domain's subdomains
cascade_ip str Cascade business units to domain's ipaddresses

Return type

ClientDomainData

Authorization

bearer

HTTP request headers

  • Content-Type: Not defined
  • Accept: application/json

HTTP response details

Status code Description Response headers
200 Success -
401 Unauthorized -
403 Forbidden -
404 Not Found -
409 Conflict -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

update_asset_domain_engine_settings

ClientEngineSettingsData update_asset_domain_engine_settings(id, update_client_engine_settings_dto)

Update Domain Engine Settings

Update the engine settings for a specific domain asset.

Example

  • Bearer (API_TOKEN) Authentication (bearer):
import watchtowr_api_sdk
from watchtowr_api_sdk.models.client_engine_settings_data import ClientEngineSettingsData
from watchtowr_api_sdk.models.update_client_engine_settings_dto import UpdateClientEngineSettingsDto
from watchtowr_api_sdk.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to https://your-tenant-id.sg.client.watchtowr.io
# See configuration.py for a list of all supported configuration parameters.
configuration = watchtowr_api_sdk.Configuration(
    host = "https://your-tenant-id.sg.client.watchtowr.io"
)

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

# Configure Bearer authorization (API_TOKEN): bearer
configuration = watchtowr_api_sdk.Configuration(
    access_token = os.environ["BEARER_TOKEN"]
)

# Enter a context with an instance of the API client
with watchtowr_api_sdk.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = watchtowr_api_sdk.DomainsApi(api_client)
    id = 3.4 # float | The asset ID of the domain to update engine settings for.
    update_client_engine_settings_dto = watchtowr_api_sdk.UpdateClientEngineSettingsDto() # UpdateClientEngineSettingsDto | 

    try:
        # Update Domain Engine Settings
        api_response = api_instance.update_asset_domain_engine_settings(id, update_client_engine_settings_dto)
        print("The response of DomainsApi->update_asset_domain_engine_settings:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling DomainsApi->update_asset_domain_engine_settings: %s\n" % e)

Parameters

Name Type Description Notes
id float The asset ID of the domain to update engine settings for.
update_client_engine_settings_dto UpdateClientEngineSettingsDto

Return type

ClientEngineSettingsData

Authorization

bearer

HTTP request headers

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

HTTP response details

Status code Description Response headers
200 Success -
401 Unauthorized -
403 Forbidden -
404 Not Found -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

update_asset_domain_note

ClientNoteData update_asset_domain_note(id, note_id, create_client_note_dto)

Update Note

Update a Note for a specific Domain asset.

Example

  • Bearer (API_TOKEN) Authentication (bearer):
import watchtowr_api_sdk
from watchtowr_api_sdk.models.client_note_data import ClientNoteData
from watchtowr_api_sdk.models.create_client_note_dto import CreateClientNoteDto
from watchtowr_api_sdk.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to https://your-tenant-id.sg.client.watchtowr.io
# See configuration.py for a list of all supported configuration parameters.
configuration = watchtowr_api_sdk.Configuration(
    host = "https://your-tenant-id.sg.client.watchtowr.io"
)

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

# Configure Bearer authorization (API_TOKEN): bearer
configuration = watchtowr_api_sdk.Configuration(
    access_token = os.environ["BEARER_TOKEN"]
)

# Enter a context with an instance of the API client
with watchtowr_api_sdk.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = watchtowr_api_sdk.DomainsApi(api_client)
    id = 3.4 # float | The asset ID of the Domain to update a note of.
    note_id = 3.4 # float | The ID of the note to update.
    create_client_note_dto = watchtowr_api_sdk.CreateClientNoteDto() # CreateClientNoteDto | 

    try:
        # Update Note
        api_response = api_instance.update_asset_domain_note(id, note_id, create_client_note_dto)
        print("The response of DomainsApi->update_asset_domain_note:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling DomainsApi->update_asset_domain_note: %s\n" % e)

Parameters

Name Type Description Notes
id float The asset ID of the Domain to update a note of.
note_id float The ID of the note to update.
create_client_note_dto CreateClientNoteDto

Return type

ClientNoteData

Authorization

bearer

HTTP request headers

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

HTTP response details

Status code Description Response headers
200 Success -
401 Unauthorized -
404 Not Found -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

update_asset_domain_status

ClientDomainData update_asset_domain_status(id, update_client_legacy_asset_status_dto)

Update Status

Update Status of a specific Domain asset.

Example

  • Bearer (API_TOKEN) Authentication (bearer):
import watchtowr_api_sdk
from watchtowr_api_sdk.models.client_domain_data import ClientDomainData
from watchtowr_api_sdk.models.update_client_legacy_asset_status_dto import UpdateClientLegacyAssetStatusDto
from watchtowr_api_sdk.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to https://your-tenant-id.sg.client.watchtowr.io
# See configuration.py for a list of all supported configuration parameters.
configuration = watchtowr_api_sdk.Configuration(
    host = "https://your-tenant-id.sg.client.watchtowr.io"
)

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

# Configure Bearer authorization (API_TOKEN): bearer
configuration = watchtowr_api_sdk.Configuration(
    access_token = os.environ["BEARER_TOKEN"]
)

# Enter a context with an instance of the API client
with watchtowr_api_sdk.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = watchtowr_api_sdk.DomainsApi(api_client)
    id = 3.4 # float | The asset ID of the Domain to update status of.
    update_client_legacy_asset_status_dto = watchtowr_api_sdk.UpdateClientLegacyAssetStatusDto() # UpdateClientLegacyAssetStatusDto | 

    try:
        # Update Status
        api_response = api_instance.update_asset_domain_status(id, update_client_legacy_asset_status_dto)
        print("The response of DomainsApi->update_asset_domain_status:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling DomainsApi->update_asset_domain_status: %s\n" % e)

Parameters

Name Type Description Notes
id float The asset ID of the Domain to update status of.
update_client_legacy_asset_status_dto UpdateClientLegacyAssetStatusDto

Return type

ClientDomainData

Authorization

bearer

HTTP request headers

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

HTTP response details

Status code Description Response headers
200 Success -
401 Unauthorized -
404 Not Found -

[Back to top] [Back to API list] [Back to Model list] [Back to README]

update_custom_property_domain

ClientCustomProperty update_custom_property_domain(id, custom_property_id, update_client_custom_property_dto)

Update Custom Property

Update a Custom Property for a specific Domain asset.

Example

  • Bearer (API_TOKEN) Authentication (bearer):
import watchtowr_api_sdk
from watchtowr_api_sdk.models.client_custom_property import ClientCustomProperty
from watchtowr_api_sdk.models.update_client_custom_property_dto import UpdateClientCustomPropertyDto
from watchtowr_api_sdk.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to https://your-tenant-id.sg.client.watchtowr.io
# See configuration.py for a list of all supported configuration parameters.
configuration = watchtowr_api_sdk.Configuration(
    host = "https://your-tenant-id.sg.client.watchtowr.io"
)

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

# Configure Bearer authorization (API_TOKEN): bearer
configuration = watchtowr_api_sdk.Configuration(
    access_token = os.environ["BEARER_TOKEN"]
)

# Enter a context with an instance of the API client
with watchtowr_api_sdk.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = watchtowr_api_sdk.DomainsApi(api_client)
    id = 3.4 # float | The asset ID of a Domain with a custom property to update.
    custom_property_id = 3.4 # float | The ID of the custom property to update.
    update_client_custom_property_dto = watchtowr_api_sdk.UpdateClientCustomPropertyDto() # UpdateClientCustomPropertyDto | 

    try:
        # Update Custom Property
        api_response = api_instance.update_custom_property_domain(id, custom_property_id, update_client_custom_property_dto)
        print("The response of DomainsApi->update_custom_property_domain:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling DomainsApi->update_custom_property_domain: %s\n" % e)

Parameters

Name Type Description Notes
id float The asset ID of a Domain with a custom property to update.
custom_property_id float The ID of the custom property to update.
update_client_custom_property_dto UpdateClientCustomPropertyDto

Return type

ClientCustomProperty

Authorization

bearer

HTTP request headers

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

HTTP response details

Status code Description Response headers
200 Success -
401 Unauthorized -
403 Forbidden -
404 Not Found -

[Back to top] [Back to API list] [Back to Model list] [Back to README]