airflow_client.client.AssetStateStoreApi

All URIs are relative to http://localhost

MethodHTTP requestDescription
clear_asset_state_storeDELETE /api/v2/assets/{asset_id}/state-storeClear Asset State Store
delete_asset_state_storeDELETE /api/v2/assets/{asset_id}/state-store/{key}Delete Asset State Store
get_asset_state_storeGET /api/v2/assets/{asset_id}/state-store/{key}Get Asset State Store
list_asset_state_storeGET /api/v2/assets/{asset_id}/state-storeList Asset State Store
set_asset_state_storePUT /api/v2/assets/{asset_id}/state-store/{key}Set Asset State Store

clear_asset_state_store

clear_asset_state_store(asset_id)

Clear Asset State Store

Delete all state store keys for an asset.

Example

  • OAuth Authentication (OAuth2PasswordBearer):
  • Bearer Authentication (HTTPBearer):
import airflow_client.client
from airflow_client.client.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 = airflow_client.client.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.access_token = os.environ["ACCESS_TOKEN"]

# Configure Bearer authorization: HTTPBearer
configuration = airflow_client.client.Configuration(
    access_token = os.environ["BEARER_TOKEN"]
)

# Enter a context with an instance of the API client
with airflow_client.client.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = airflow_client.client.AssetStateStoreApi(api_client)
    asset_id = 56 # int | 

    try:
        # Clear Asset State Store
        api_instance.clear_asset_state_store(asset_id)
    except Exception as e:
        print("Exception when calling AssetStateStoreApi->clear_asset_state_store: %s\n" % e)

Parameters

NameTypeDescriptionNotes
asset_idint

Return type

void (empty response body)

Authorization

OAuth2PasswordBearer, HTTPBearer

HTTP request headers

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

HTTP response details

Status codeDescriptionResponse headers
204Successful Response-
401Unauthorized-
403Forbidden-
404Not Found-
422Validation Error-

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

delete_asset_state_store

delete_asset_state_store(key, asset_id)

Delete Asset State Store

Delete a single asset state store key. No-op if the key does not exist.

Example

  • OAuth Authentication (OAuth2PasswordBearer):
  • Bearer Authentication (HTTPBearer):
import airflow_client.client
from airflow_client.client.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 = airflow_client.client.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.access_token = os.environ["ACCESS_TOKEN"]

# Configure Bearer authorization: HTTPBearer
configuration = airflow_client.client.Configuration(
    access_token = os.environ["BEARER_TOKEN"]
)

# Enter a context with an instance of the API client
with airflow_client.client.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = airflow_client.client.AssetStateStoreApi(api_client)
    key = 'key_example' # str | 
    asset_id = 56 # int | 

    try:
        # Delete Asset State Store
        api_instance.delete_asset_state_store(key, asset_id)
    except Exception as e:
        print("Exception when calling AssetStateStoreApi->delete_asset_state_store: %s\n" % e)

Parameters

NameTypeDescriptionNotes
keystr
asset_idint

Return type

void (empty response body)

Authorization

OAuth2PasswordBearer, HTTPBearer

HTTP request headers

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

HTTP response details

Status codeDescriptionResponse headers
204Successful Response-
401Unauthorized-
403Forbidden-
404Not Found-
422Validation Error-

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

get_asset_state_store

AssetStateStoreResponse get_asset_state_store(key, asset_id)

Get Asset State Store

Get a single asset state store entry.

Example

  • OAuth Authentication (OAuth2PasswordBearer):
  • Bearer Authentication (HTTPBearer):
import airflow_client.client
from airflow_client.client.models.asset_state_store_response import AssetStateStoreResponse
from airflow_client.client.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 = airflow_client.client.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.access_token = os.environ["ACCESS_TOKEN"]

# Configure Bearer authorization: HTTPBearer
configuration = airflow_client.client.Configuration(
    access_token = os.environ["BEARER_TOKEN"]
)

# Enter a context with an instance of the API client
with airflow_client.client.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = airflow_client.client.AssetStateStoreApi(api_client)
    key = 'key_example' # str | 
    asset_id = 56 # int | 

    try:
        # Get Asset State Store
        api_response = api_instance.get_asset_state_store(key, asset_id)
        print("The response of AssetStateStoreApi->get_asset_state_store:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling AssetStateStoreApi->get_asset_state_store: %s\n" % e)

Parameters

NameTypeDescriptionNotes
keystr
asset_idint

Return type

AssetStateStoreResponse

Authorization

OAuth2PasswordBearer, HTTPBearer

HTTP request headers

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

HTTP response details

Status codeDescriptionResponse headers
200Successful Response-
401Unauthorized-
403Forbidden-
404Not Found-
422Validation Error-

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

list_asset_state_store

AssetStateStoreCollectionResponse list_asset_state_store(asset_id, limit=limit, offset=offset)

List Asset State Store

List all state store entries for an asset.

Example

  • OAuth Authentication (OAuth2PasswordBearer):
  • Bearer Authentication (HTTPBearer):
import airflow_client.client
from airflow_client.client.models.asset_state_store_collection_response import AssetStateStoreCollectionResponse
from airflow_client.client.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 = airflow_client.client.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.access_token = os.environ["ACCESS_TOKEN"]

# Configure Bearer authorization: HTTPBearer
configuration = airflow_client.client.Configuration(
    access_token = os.environ["BEARER_TOKEN"]
)

# Enter a context with an instance of the API client
with airflow_client.client.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = airflow_client.client.AssetStateStoreApi(api_client)
    asset_id = 56 # int | 
    limit = 50 # int |  (optional) (default to 50)
    offset = 0 # int |  (optional) (default to 0)

    try:
        # List Asset State Store
        api_response = api_instance.list_asset_state_store(asset_id, limit=limit, offset=offset)
        print("The response of AssetStateStoreApi->list_asset_state_store:\n")
        pprint(api_response)
    except Exception as e:
        print("Exception when calling AssetStateStoreApi->list_asset_state_store: %s\n" % e)

Parameters

NameTypeDescriptionNotes
asset_idint
limitint[optional] [default to 50]
offsetint[optional] [default to 0]

Return type

AssetStateStoreCollectionResponse

Authorization

OAuth2PasswordBearer, HTTPBearer

HTTP request headers

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

HTTP response details

Status codeDescriptionResponse headers
200Successful Response-
401Unauthorized-
403Forbidden-
404Not Found-
422Validation Error-

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

set_asset_state_store

set_asset_state_store(key, asset_id, asset_state_store_body)

Set Asset State Store

Set an asset state store value. Creates or overwrites the key.

Example

  • OAuth Authentication (OAuth2PasswordBearer):
  • Bearer Authentication (HTTPBearer):
import airflow_client.client
from airflow_client.client.models.asset_state_store_body import AssetStateStoreBody
from airflow_client.client.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 = airflow_client.client.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.access_token = os.environ["ACCESS_TOKEN"]

# Configure Bearer authorization: HTTPBearer
configuration = airflow_client.client.Configuration(
    access_token = os.environ["BEARER_TOKEN"]
)

# Enter a context with an instance of the API client
with airflow_client.client.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = airflow_client.client.AssetStateStoreApi(api_client)
    key = 'key_example' # str | 
    asset_id = 56 # int | 
    asset_state_store_body = airflow_client.client.AssetStateStoreBody() # AssetStateStoreBody | 

    try:
        # Set Asset State Store
        api_instance.set_asset_state_store(key, asset_id, asset_state_store_body)
    except Exception as e:
        print("Exception when calling AssetStateStoreApi->set_asset_state_store: %s\n" % e)

Parameters

NameTypeDescriptionNotes
keystr
asset_idint
asset_state_store_bodyAssetStateStoreBody

Return type

void (empty response body)

Authorization

OAuth2PasswordBearer, HTTPBearer

HTTP request headers

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

HTTP response details

Status codeDescriptionResponse headers
204Successful Response-
401Unauthorized-
403Forbidden-
404Not Found-
422Validation Error-

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