airflow.providers.akeyless.hooks.akeyless

Hook for Akeyless Vault Platform.

Attributes

VALID_AUTH_TYPES

Classes

AkeylessHook

Hook to interact with the Akeyless Vault Platform.

Module Contents

airflow.providers.akeyless.hooks.akeyless.VALID_AUTH_TYPES = ('api_key', 'aws_iam', 'gcp', 'azure_ad', 'uid', 'jwt', 'k8s', 'certificate')[source]
class airflow.providers.akeyless.hooks.akeyless.AkeylessHook(akeyless_conn_id=default_conn_name, **kwargs)[source]

Bases: airflow.providers.common.compat.sdk.BaseHook

Hook to interact with the Akeyless Vault Platform.

Thin wrapper around the akeyless Python SDK.

Connection fields:

  • Host -> API URL (default https://api.akeyless.io)

  • Login -> Access ID

  • Password -> Access Key (for api_key auth)

  • Extra -> JSON with access_type and auth-method-specific fields

Parameters:

akeyless_conn_id (str) – Airflow connection ID.

conn_name_attr = 'akeyless_conn_id'[source]
default_conn_name = 'akeyless_default'[source]
conn_type = 'akeyless'[source]
hook_name = 'Akeyless'[source]
akeyless_conn_id = 'akeyless_default'[source]
property client: akeyless.V2Api[source]

Return an akeyless.V2Api client (cached).

get_conn()[source]

Return the underlying akeyless.V2Api client.

authenticate()[source]

Authenticate and return an API token.

For uid auth the token is the UID token itself. For all other methods, calls akeyless.Auth.

get_secret_value(name)[source]

Get a static secret value by path.

get_secret_values(names)[source]

Get multiple static secret values.

create_secret(name, value, description=None)[source]

Create a static secret.

update_secret_value(name, value)[source]

Update a static secret’s value.

delete_item(name)[source]

Delete a secret/item.

describe_item(name)[source]

Describe a secret/item (returns metadata).

list_items(path='/')[source]

List items under a path.

get_dynamic_secret_value(name)[source]

Generate a dynamic secret value (e.g. DB credentials).

get_rotated_secret_value(name)[source]

Retrieve a rotated secret value.

test_connection()[source]

Validate connectivity from the Airflow UI.

classmethod get_connection_form_widgets()[source]

Return widgets for the Airflow connection form.

classmethod get_ui_field_behaviour()[source]

Return custom field behaviour for the Airflow UI.

Was this entry helpful?