<!--
generated-by:  capability-manifest skill (.claude/skills/capability-manifest)
sdk-version:   3.27.1
source-sha:    433a02d5170e2b5ce858c428b6bec7584eafbe17
source-date:   2026-08-12T02:18:28+01:00
do-not-edit:   re-run the skill instead of hand-editing
-->

# Atlan Application SDK — Capability Manifest

> Canonical inventory of every public symbol exposed by `application_sdk`,
> plus every typed Input/Output contract.
> Read this before reading SDK source. Generated by `.claude/skills/capability-manifest`.
>
> **To check if current:** `awk '/^source-sha:/{print $2}' docs/agents/sdk-capabilities.md` vs `git log -1 --format=%H -- application_sdk/`

## Subpackage Index

| Subpackage | Purpose | Exports |
|---|---|---|
| `application_sdk.app` | Core developer abstractions — App, @task, @entrypoint, Input, Output, RetryPolicy, mcp_tool | 26 |
| `application_sdk.clients` | Connection clients (SQL, Redis, Azure) and ClientInterface ABC | 11 |
| `application_sdk.common` | Shared utilities — SQL filters, concurrency helpers, TaskStatistics, DataframeType | 11 |
| `application_sdk.contracts` | Typed Pydantic Input/Output base classes, payload safety, storage and type helpers | 28 |
| `application_sdk.credentials` | Credential resolvers (Atlan, OAuth, Git, agent), registry, vault spec | 41 |
| `application_sdk.errors` | Structured error codes — ErrorCode dataclass and cross-component constants (APP_ERROR, HANDLER_ERROR, CONTRACT_VALIDATION, etc.) | 56 |
| `application_sdk.execution` | Task/workflow execution — retry, heartbeat, sandbox, AppWorker, Temporal client | 20 |
| `application_sdk.handler` | HTTP handler framework — Handler ABC, DefaultHandler, preflight, auth, service factory | 22 |
| `application_sdk.infrastructure` | Protocol-based infrastructure (StateStore, SecretStore, PubSub, Bindings, CapacityPool) | 37 |
| `application_sdk.main` | Dev entry point — run_dev_combined() and AppConfig for local execution and container startup | 2 |
| `application_sdk.observability` | Logging context — ExecutionContext, CorrelationContext, request/correlation helpers | 11 |
| `application_sdk.outputs` | Output collectors and record models for Automation Engine | 4 |
| `application_sdk.storage` | Object-store abstraction — factory, formats, batch, transfer, cloud bindings | 39 |
| `application_sdk.templates` | SQL metadata extractor templates and their contracts | 5 |
| `application_sdk.testing` | Test infrastructure — mocks, fixtures, hypothesis strategies, integration helpers | 15 |

## Subpackage Details

## `application_sdk.app`

Core developer abstractions — App, @task, @entrypoint, Input, Output, RetryPolicy, mcp_tool

### Classes

#### `App`

- **Import:** `from application_sdk.app import App`
- **Signature:** `class App`
- **Summary:** Base class for all Apps.
- **Defined in:** `application_sdk/app/base.py`

#### `AppContext`

- **Import:** `from application_sdk.app import AppContext`
- **Signature:** `class AppContext(app_name: str, ...)`
- **Summary:** Execution context passed to Apps during execution.
- **Defined in:** `application_sdk/app/context.py`

#### `AppError`

- **Import:** `from application_sdk.app import AppError`
- **Signature:** `class AppError(message: str, ...)`
- **Summary:** Deprecated: use ``application_sdk.errors.AppError`` directly — removed in v4.0.
- **Defined in:** `application_sdk/app/base.py`

#### `AppRegistry`

- **Import:** `from application_sdk.app import AppRegistry`
- **Signature:** `class AppRegistry`
- **Summary:** Registry for App discovery and registration.
- **Defined in:** `application_sdk/app/registry.py`

#### `AtlanClientMixin`

- **Import:** `from application_sdk.app import AtlanClientMixin`
- **Signature:** `class AtlanClientMixin`
- **Summary:** Mixin providing cached async Atlan client access for App subclasses.
- **Defined in:** `application_sdk/credentials/atlan_client.py`

#### `EntryPointMetadata`

- **Import:** `from application_sdk.app import EntryPointMetadata`
- **Signature:** `class EntryPointMetadata(name: str, ...)`
- **Summary:** Metadata about a registered entry point.
- **Defined in:** `application_sdk/app/entrypoint.py`

#### `Input`

- **Import:** `from application_sdk.app import Input`
- **Signature:** `class Input`
- **Summary:** Base class for all input contracts (Apps and tasks).
- **Defined in:** `application_sdk/contracts/base.py`

#### `NonRetryableError`

- **Import:** `from application_sdk.app import NonRetryableError`
- **Signature:** `class NonRetryableError`
- **Summary:** Deprecated: use a typed ``AppError`` subclass with ``default_retryable = False`` — removed in v4.0.
- **Defined in:** `application_sdk/app/base.py`

#### `Output`

- **Import:** `from application_sdk.app import Output`
- **Signature:** `class Output`
- **Summary:** Base class for all output contracts (Apps and tasks).
- **Defined in:** `application_sdk/contracts/base.py`

#### `OutputStatus`

- **Import:** `from application_sdk.app import OutputStatus`
- **Signature:** `class OutputStatus`
- **Summary:** Standard run-result status used on :class:`Output`.
- **Defined in:** `application_sdk/contracts/base.py`

#### `RetryableError`

- **Import:** `from application_sdk.app import RetryableError`
- **Signature:** `class RetryableError`
- **Summary:** Deprecated: use a typed ``AppError`` subclass with ``default_retryable = True`` — removed in v4.0.
- **Defined in:** `application_sdk/app/base.py`

#### `RetryPolicy`

- **Import:** `from application_sdk.app import RetryPolicy`
- **Signature:** `class RetryPolicy(max_attempts: int = 3, ...)`
- **Summary:** Configuration for retry behavior.
- **Defined in:** `application_sdk/execution/retry.py`

#### `TaskMetadata`

- **Import:** `from application_sdk.app import TaskMetadata`
- **Signature:** `class TaskMetadata(name: str, ...)`
- **Summary:** Metadata about a registered task.
- **Defined in:** `application_sdk/app/task.py`

#### `TaskRegistry`

- **Import:** `from application_sdk.app import TaskRegistry`
- **Signature:** `class TaskRegistry`
- **Summary:** Registry for Task discovery and registration.
- **Defined in:** `application_sdk/app/registry.py`

### Decorators

#### `@entrypoint`

- **Import:** `from application_sdk.app import entrypoint`
- **Signature:** `entrypoint(func: F | None = None, *, name: str | None = None, default: bool = False) -> F | Callable[[F], F]`
- **Summary:** Decorator to mark a method as an independently-triggerable entry point.
- **Defined in:** `application_sdk/app/entrypoint.py`

#### `@task`

- **Import:** `from application_sdk.app import task`
- **Signature:** `task(func: F | None = None, *, ...)`
- **Summary:** Decorator to mark a method as a task (Temporal activity).
- **Defined in:** `application_sdk/app/task.py`

### Functions

#### `entrypoint_module_segment`

- **Import:** `from application_sdk.app import entrypoint_module_segment`
- **Signature:** `entrypoint_module_segment(name: str)`
- **Summary:** Convert a kebab-case entry-point name to its Python module segment.
- **Defined in:** `application_sdk/app/entrypoint.py`

#### `mcp_tool`

- **Import:** `from application_sdk.app import mcp_tool`
- **Summary:** _(no docstring)_

### Constants and Enums

#### `InteractionUnfinishedPolicy`

- **Import:** `from application_sdk.app import InteractionUnfinishedPolicy`
- **Signature:** `InteractionUnfinishedPolicy`
- **Summary:** Policy applied to in-flight runtime interactions when an app run exits.
- **Defined in:** `application_sdk/app/__init__.py`

#### `now`

- **Import:** `from application_sdk.app import now`
- **Signature:** `now`
- **Summary:** Return the current time from the app run's perspective (deterministic).
- **Defined in:** `application_sdk/app/__init__.py`

#### `query`

- **Import:** `from application_sdk.app import query`
- **Signature:** `query`
- **Summary:** Declare a ``@query`` runtime interaction that reads live state without mutation.
- **Defined in:** `application_sdk/app/__init__.py`

#### `signal`

- **Import:** `from application_sdk.app import signal`
- **Signature:** `signal`
- **Summary:** Declare a ``@signal`` runtime interaction on an App subclass.
- **Defined in:** `application_sdk/app/__init__.py`

#### `sleep`

- **Import:** `from application_sdk.app import sleep`
- **Signature:** `sleep`
- **Summary:** Sleep for a given duration inside an app run (deterministic).
- **Defined in:** `application_sdk/app/__init__.py`

#### `update`

- **Import:** `from application_sdk.app import update`
- **Signature:** `update`
- **Summary:** Declare a ``@update`` runtime interaction that mutates state and returns a typed response.
- **Defined in:** `application_sdk/app/__init__.py`

#### `uuid4`

- **Import:** `from application_sdk.app import uuid4`
- **Signature:** `uuid4`
- **Summary:** Generate a determinism-safe v4 UUID inside an app run.
- **Defined in:** `application_sdk/app/__init__.py`

#### `wait_condition`

- **Import:** `from application_sdk.app import wait_condition`
- **Signature:** `wait_condition`
- **Summary:** Suspend ``run()`` or a runtime interaction until a predicate becomes ``True``.
- **Defined in:** `application_sdk/app/__init__.py`

## `application_sdk.clients`

Connection clients (SQL, Redis, Azure) and ClientInterface ABC

### Classes

#### `AsyncBaseSQLClient`

- **Import:** `from application_sdk.clients import AsyncBaseSQLClient`
- **Signature:** `class AsyncBaseSQLClient`
- **Summary:** Asynchronous SQL client for database operations.
- **Defined in:** `application_sdk/clients/sql.py`

#### `AzureAuthProvider`

- **Import:** `from application_sdk.clients import AzureAuthProvider`
- **Signature:** `class AzureAuthProvider()`
- **Summary:** Azure authentication provider for handling Service Principal authentication.
- **Defined in:** `application_sdk/clients/azure/auth.py`

#### `AzureClient`

- **Import:** `from application_sdk.clients import AzureClient`
- **Signature:** `class AzureClient(credentials: dict[str, Any] | None = None, max_workers: int = 10, **kwargs: Any)`
- **Summary:** Main Azure client for the application-sdk framework.
- **Defined in:** `application_sdk/clients/azure/client.py`

#### `BaseClient`

- **Import:** `from application_sdk.clients import BaseClient`
- **Signature:** `class BaseClient(credentials: dict[str, Any] = {}, http_headers: HeaderTypes = {})`
- **Summary:** Base client for non-SQL based applications.
- **Defined in:** `application_sdk/clients/base.py`

#### `BaseSQLClient`

- **Import:** `from application_sdk.clients import BaseSQLClient`
- **Signature:** `class BaseSQLClient(use_server_side_cursor: bool = USE_SERVER_SIDE_CURSOR, ...)`
- **Summary:** SQL client for database operations.
- **Defined in:** `application_sdk/clients/sql.py`

#### `ClientInterface`

- **Import:** `from application_sdk.clients import ClientInterface`
- **Signature:** `class ClientInterface`
- **Summary:** Base interface class for implementing client connections.
- **Defined in:** `application_sdk/clients/_interface.py`

#### `DatabaseConfig`

- **Import:** `from application_sdk.clients import DatabaseConfig`
- **Signature:** `class DatabaseConfig`
- **Summary:** Pydantic model for database connection configuration.
- **Defined in:** `application_sdk/clients/models.py`

#### `RedisClient`

- **Import:** `from application_sdk.clients import RedisClient`
- **Signature:** `class RedisClient()`
- **Summary:** Synchronous Redis client for distributed locking.
- **Defined in:** `application_sdk/clients/redis.py`

#### `RedisClientAsync`

- **Import:** `from application_sdk.clients import RedisClientAsync`
- **Signature:** `class RedisClientAsync()`
- **Summary:** Asynchronous Redis client for distributed locking.
- **Defined in:** `application_sdk/clients/redis.py`

### Functions

#### `create_ssl_context_with_custom_certs`

- **Import:** `from application_sdk.clients import create_ssl_context_with_custom_certs`
- **Signature:** `create_ssl_context_with_custom_certs(cert_dir: str)`
- **Summary:** Create an SSL context that includes both default system certificates and custom certificates.
- **Defined in:** `application_sdk/clients/ssl_utils.py`

#### `get_ssl_context`

- **Import:** `from application_sdk.clients import get_ssl_context`
- **Signature:** `get_ssl_context()`
- **Summary:** Get the SSL verification context for HTTP clients (httpx, aiohttp, etc.).
- **Defined in:** `application_sdk/clients/ssl_utils.py`

## `application_sdk.common`

Shared utilities — SQL filters, concurrency helpers, TaskStatistics, DataframeType

### Classes

#### `DataframeType`

- **Import:** `from application_sdk.common import DataframeType`
- **Signature:** `class DataframeType`
- **Summary:** Enumeration of dataframe types.
- **Defined in:** `application_sdk/common/types.py`

#### `FilterPattern`

- **Import:** `from application_sdk.common import FilterPattern`
- **Signature:** `class FilterPattern(include: list[re.Pattern[str]], exclude: list[re.Pattern[str]])`
- **Summary:** A compiled include/exclude filter with uniform regex-or-exact semantics.
- **Defined in:** `application_sdk/common/filter_matching.py`

#### `TaskResult`

- **Import:** `from application_sdk.common import TaskResult`
- **Signature:** `class TaskResult`
- **Summary:** _(no docstring)_
- **Defined in:** `application_sdk/common/models.py`

#### `TaskStatistics`

- **Import:** `from application_sdk.common import TaskStatistics`
- **Signature:** `class TaskStatistics(total_record_count: int = 0, ...)`
- **Summary:** Statistics produced by a completed task.
- **Defined in:** `application_sdk/common/models.py`

### Functions

#### `filter_matches`

- **Import:** `from application_sdk.common import filter_matches`
- **Signature:** `filter_matches(candidate: str, *, ...)`
- **Summary:** Convenience one-shot: compile ``include``/``exclude`` and test ``candidate``.
- **Defined in:** `application_sdk/common/filter_matching.py`

#### `get_actual_cpu_count`

- **Import:** `from application_sdk.common import get_actual_cpu_count`
- **Signature:** `get_actual_cpu_count()`
- **Summary:** Get the actual number of CPUs available to the current process.
- **Defined in:** `application_sdk/common/concurrency.py`

#### `get_safe_num_threads`

- **Import:** `from application_sdk.common import get_safe_num_threads`
- **Signature:** `get_safe_num_threads()`
- **Summary:** Get recommended number of threads for parallel processing.
- **Defined in:** `application_sdk/common/concurrency.py`

#### `normalize_filters`

- **Import:** `from application_sdk.common import normalize_filters`
- **Signature:** `normalize_filters(filter_dict: dict[str, FilterValue], is_include: bool)`
- **Summary:** Normalize filter dict to fully-anchored ``db.schema`` regex patterns.
- **Defined in:** `application_sdk/common/sql_filters.py`

#### `prepare_filters`

- **Import:** `from application_sdk.common import prepare_filters`
- **Signature:** `prepare_filters(include_filter_str: str, exclude_filter_str: str)`
- **Summary:** Prepare include/exclude filters for SQL queries.
- **Defined in:** `application_sdk/common/sql_filters.py`

#### `prepare_query`

- **Import:** `from application_sdk.common import prepare_query`
- **Signature:** `prepare_query(query: str | None, ...)`
- **Summary:** Prepare a SQL query by applying include/exclude filters.
- **Defined in:** `application_sdk/common/sql_filters.py`

#### `read_sql_files`

- **Import:** `from application_sdk.common import read_sql_files`
- **Signature:** `read_sql_files(queries_prefix: str = f'{os.path.dirname(os.path.abspath(__file__))}/queries')`
- **Summary:** Read all SQL files from a directory and return as a name→content mapping.
- **Defined in:** `application_sdk/common/sql_filters.py`

## `application_sdk.contracts`

Typed Pydantic Input/Output base classes, payload safety, storage and type helpers

### Classes

#### `ConnectionRef`

- **Import:** `from application_sdk.contracts import ConnectionRef`
- **Signature:** `class ConnectionRef`
- **Summary:** Typed replacement for ``connection: dict[str, Any]`` in Temporal contracts.
- **Defined in:** `application_sdk/contracts/types.py`

#### `ContractMetadata`

- **Import:** `from application_sdk.contracts import ContractMetadata`
- **Signature:** `class ContractMetadata`
- **Summary:** Metadata about a contract for registration and discovery.
- **Defined in:** `application_sdk/contracts/base.py`

#### `ContractValidationError`

- **Import:** `from application_sdk.contracts import ContractValidationError`
- **Signature:** `class ContractValidationError(message: str, ...)`
- **Summary:** Deprecated: use ``application_sdk.errors.InvalidInputError`` — removed in v4.0.
- **Defined in:** `application_sdk/contracts/base.py`

#### `DownloadInput`

- **Import:** `from application_sdk.contracts import DownloadInput`
- **Signature:** `class DownloadInput`
- **Summary:** Input for ``App.download``.
- **Defined in:** `application_sdk/contracts/storage.py`

#### `DownloadOutput`

- **Import:** `from application_sdk.contracts import DownloadOutput`
- **Signature:** `class DownloadOutput`
- **Summary:** Output from ``App.download``.
- **Defined in:** `application_sdk/contracts/storage.py`

#### `FileReference`

- **Import:** `from application_sdk.contracts import FileReference`
- **Signature:** `class FileReference`
- **Summary:** Reference to externally-stored data (for large payloads).
- **Defined in:** `application_sdk/contracts/types.py`

#### `GitReference`

- **Import:** `from application_sdk.contracts import GitReference`
- **Signature:** `class GitReference`
- **Summary:** Reference to a Git repository for workflow inputs.
- **Defined in:** `application_sdk/contracts/types.py`

#### `HeartbeatDetails`

- **Import:** `from application_sdk.contracts import HeartbeatDetails`
- **Signature:** `class HeartbeatDetails`
- **Summary:** Base class for heartbeat progress contracts.
- **Defined in:** `application_sdk/contracts/base.py`

#### `Input`

- **Import:** `from application_sdk.contracts import Input`
- **Signature:** `class Input`
- **Summary:** Base class for all input contracts (Apps and tasks).
- **Defined in:** `application_sdk/contracts/base.py`

#### `InputContract`

- **Import:** `from application_sdk.contracts import InputContract`
- **Signature:** `class InputContract`
- **Summary:** Protocol marker for App input contracts.
- **Defined in:** `application_sdk/contracts/base.py`

#### `Lazy`

- **Import:** `from application_sdk.contracts import Lazy`
- **Signature:** `class Lazy`
- **Summary:** Marker: this FileReference field is NOT auto-materialized before the activity runs.
- **Defined in:** `application_sdk/contracts/types.py`

#### `MaxItems`

- **Import:** `from application_sdk.contracts import MaxItems`
- **Signature:** `class MaxItems(limit: int)`
- **Summary:** Constraint marker indicating maximum collection size.
- **Defined in:** `application_sdk/contracts/types.py`

#### `Output`

- **Import:** `from application_sdk.contracts import Output`
- **Signature:** `class Output`
- **Summary:** Base class for all output contracts (Apps and tasks).
- **Defined in:** `application_sdk/contracts/base.py`

#### `OutputContract`

- **Import:** `from application_sdk.contracts import OutputContract`
- **Signature:** `class OutputContract`
- **Summary:** Protocol marker for App output contracts.
- **Defined in:** `application_sdk/contracts/base.py`

#### `PayloadSafetyError`

- **Import:** `from application_sdk.contracts import PayloadSafetyError`
- **Signature:** `class PayloadSafetyError(cls_name: str, field_name: str, field_type: type, reason: str)`
- **Summary:** Raised when a contract field uses a type that risks exceeding payload limits.
- **Defined in:** `application_sdk/contracts/base.py`

#### `PublishInputMixin`

- **Import:** `from application_sdk.contracts import PublishInputMixin`
- **Signature:** `class PublishInputMixin`
- **Summary:** Mixin for apps whose workflow output feeds the Publish App.
- **Defined in:** `application_sdk/contracts/base.py`

#### `Record`

- **Import:** `from application_sdk.contracts import Record`
- **Signature:** `class Record`
- **Summary:** Base class for domain records passed between Apps.
- **Defined in:** `application_sdk/contracts/base.py`

#### `SerializableEnum`

- **Import:** `from application_sdk.contracts import SerializableEnum`
- **Signature:** `class SerializableEnum`
- **Summary:** Base class for enums that need to be serialized through Temporal.
- **Defined in:** `application_sdk/contracts/base.py`

#### `StorageTier`

- **Import:** `from application_sdk.contracts import StorageTier`
- **Signature:** `class StorageTier`
- **Summary:** Storage lifecycle tier for a ``FileReference``.
- **Defined in:** `application_sdk/contracts/types.py`

#### `UploadInput`

- **Import:** `from application_sdk.contracts import UploadInput`
- **Signature:** `class UploadInput`
- **Summary:** Input for ``App.upload``.
- **Defined in:** `application_sdk/contracts/storage.py`

#### `UploadOutput`

- **Import:** `from application_sdk.contracts import UploadOutput`
- **Signature:** `class UploadOutput`
- **Summary:** Output from ``App.upload``.
- **Defined in:** `application_sdk/contracts/storage.py`

### Functions

#### `get_contract_fields`

- **Import:** `from application_sdk.contracts import get_contract_fields`
- **Signature:** `get_contract_fields(cls: type)`
- **Summary:** Get the fields and their types from a contract class.
- **Defined in:** `application_sdk/contracts/base.py`

#### `has_default`

- **Import:** `from application_sdk.contracts import has_default`
- **Signature:** `has_default(cls: type, field_name: str)`
- **Summary:** Check if a contract field has a default value.
- **Defined in:** `application_sdk/contracts/base.py`

#### `is_backwards_compatible`

- **Import:** `from application_sdk.contracts import is_backwards_compatible`
- **Signature:** `is_backwards_compatible(old_cls: type, new_cls: type)`
- **Summary:** Check if a new contract version is backwards compatible with the old.
- **Defined in:** `application_sdk/contracts/base.py`

#### `validate_is_contract`

- **Import:** `from application_sdk.contracts import validate_is_contract`
- **Signature:** `validate_is_contract(cls: type, context: str = 'contract')`
- **Summary:** Validate that a class is an Input, Output, HeartbeatDetails, or Record subclass.
- **Defined in:** `application_sdk/contracts/base.py`

#### `validate_payload_safety`

- **Import:** `from application_sdk.contracts import validate_payload_safety`
- **Signature:** `validate_payload_safety(cls: type, *, skip_fields: set[str] | None = None)`
- **Summary:** Validate that all fields in a contract use payload-safe types.
- **Defined in:** `application_sdk/contracts/base.py`

### Constants and Enums

#### `BoundedDict`

- **Import:** `from application_sdk.contracts import BoundedDict`
- **Signature:** `BoundedDict`
- **Summary:** Bounded dict type. Use: Annotated[dict[K, V], MaxItems(N)]
- **Defined in:** `application_sdk/contracts/types.py`

#### `BoundedList`

- **Import:** `from application_sdk.contracts import BoundedList`
- **Signature:** `BoundedList`
- **Summary:** Bounded list type. Use: Annotated[list[T], MaxItems(N)]
- **Defined in:** `application_sdk/contracts/types.py`

## `application_sdk.credentials`

Credential resolvers (Atlan, OAuth, Git, agent), registry, vault spec

### Classes

#### `AgentCredentialSpec`

- **Import:** `from application_sdk.credentials import AgentCredentialSpec`
- **Signature:** `class AgentCredentialSpec`
- **Summary:** Typed envelope for an agent-shape credential payload.
- **Defined in:** `application_sdk/credentials/spec.py`

#### `ApiKeyCredential`

- **Import:** `from application_sdk.credentials import ApiKeyCredential`
- **Signature:** `class ApiKeyCredential`
- **Summary:** API key credential.
- **Defined in:** `application_sdk/credentials/types.py`

#### `AtlanApiToken`

- **Import:** `from application_sdk.credentials import AtlanApiToken`
- **Signature:** `class AtlanApiToken`
- **Summary:** Atlan API token credential.
- **Defined in:** `application_sdk/credentials/atlan.py`

#### `AtlanClientMixin`

- **Import:** `from application_sdk.credentials import AtlanClientMixin`
- **Signature:** `class AtlanClientMixin`
- **Summary:** Mixin providing cached async Atlan client access for App subclasses.
- **Defined in:** `application_sdk/credentials/atlan_client.py`

#### `AtlanOAuthClient`

- **Import:** `from application_sdk.credentials import AtlanOAuthClient`
- **Signature:** `class AtlanOAuthClient`
- **Summary:** Atlan OAuth 2.0 client credential.
- **Defined in:** `application_sdk/credentials/atlan.py`

#### `BasicCredential`

- **Import:** `from application_sdk.credentials import BasicCredential`
- **Signature:** `class BasicCredential`
- **Summary:** Username + password credential.
- **Defined in:** `application_sdk/credentials/types.py`

#### `BearerTokenCredential`

- **Import:** `from application_sdk.credentials import BearerTokenCredential`
- **Signature:** `class BearerTokenCredential`
- **Summary:** Bearer token credential.
- **Defined in:** `application_sdk/credentials/types.py`

#### `CertificateCredential`

- **Import:** `from application_sdk.credentials import CertificateCredential`
- **Signature:** `class CertificateCredential`
- **Summary:** Certificate-based credential (mTLS / client cert).
- **Defined in:** `application_sdk/credentials/types.py`

#### `Credential`

- **Import:** `from application_sdk.credentials import Credential`
- **Signature:** `class Credential`
- **Summary:** Protocol for typed credentials.
- **Defined in:** `application_sdk/credentials/types.py`

#### `CredentialError`

- **Import:** `from application_sdk.credentials import CredentialError`
- **Signature:** `class CredentialError(message: str, ...)`
- **Summary:** Generic credential-subsystem failure (category=AUTH).
- **Defined in:** `application_sdk/credentials/errors.py`

#### `CredentialNotFoundError`

- **Import:** `from application_sdk.credentials import CredentialNotFoundError`
- **Signature:** `class CredentialNotFoundError(credential_name: str)`
- **Summary:** The requested credential was not found in the secret store or registry.
- **Defined in:** `application_sdk/credentials/errors.py`

#### `CredentialParseError`

- **Import:** `from application_sdk.credentials import CredentialParseError`
- **Signature:** `class CredentialParseError(message: str, ...)`
- **Summary:** Credential data could not be parsed (malformed payload).
- **Defined in:** `application_sdk/credentials/errors.py`

#### `CredentialRef`

- **Import:** `from application_sdk.credentials import CredentialRef`
- **Signature:** `class CredentialRef`
- **Summary:** A reference to a credential in the secret store.
- **Defined in:** `application_sdk/credentials/ref.py`

#### `CredentialResolvable`

- **Import:** `from application_sdk.credentials import CredentialResolvable`
- **Signature:** `class CredentialResolvable`
- **Summary:** Protocol for inputs that carry credential routing fields.
- **Defined in:** `application_sdk/credentials/ref.py`

#### `CredentialResolver`

- **Import:** `from application_sdk.credentials import CredentialResolver`
- **Signature:** `class CredentialResolver(secret_store: SecretStore, registry: CredentialTypeRegistry | None = None)`
- **Summary:** Resolves a CredentialRef to a typed Credential.
- **Defined in:** `application_sdk/credentials/resolver.py`

#### `CredentialTypeRegistry`

- **Import:** `from application_sdk.credentials import CredentialTypeRegistry`
- **Signature:** `class CredentialTypeRegistry`
- **Summary:** Singleton registry mapping credential_type strings to (class, parser) pairs.
- **Defined in:** `application_sdk/credentials/registry.py`

#### `CredentialValidationError`

- **Import:** `from application_sdk.credentials import CredentialValidationError`
- **Signature:** `class CredentialValidationError(message: str, ...)`
- **Summary:** Credential failed schema or business-rule validation.
- **Defined in:** `application_sdk/credentials/errors.py`

#### `GitSshCredential`

- **Import:** `from application_sdk.credentials import GitSshCredential`
- **Signature:** `class GitSshCredential`
- **Summary:** SSH key credential for Git operations.
- **Defined in:** `application_sdk/credentials/git.py`

#### `GitTokenCredential`

- **Import:** `from application_sdk.credentials import GitTokenCredential`
- **Signature:** `class GitTokenCredential`
- **Summary:** HTTPS PAT / deploy-token credential for Git operations.
- **Defined in:** `application_sdk/credentials/git.py`

#### `OAuthClientCredential`

- **Import:** `from application_sdk.credentials import OAuthClientCredential`
- **Signature:** `class OAuthClientCredential`
- **Summary:** OAuth 2.0 client credential.
- **Defined in:** `application_sdk/credentials/types.py`

#### `OAuthTokenError`

- **Import:** `from application_sdk.credentials import OAuthTokenError`
- **Signature:** `class OAuthTokenError(message: str, *, cause: Exception | None = None)`
- **Summary:** Raised when an OAuth 2.0 token exchange or refresh fails (category=AUTH).
- **Defined in:** `application_sdk/credentials/oauth.py`

#### `OAuthTokenService`

- **Import:** `from application_sdk.credentials import OAuthTokenService`
- **Signature:** `class OAuthTokenService(credential: OAuthClientCredential)`
- **Summary:** General-purpose OAuth 2.0 client_credentials token service.
- **Defined in:** `application_sdk/credentials/oauth.py`

#### `RawCredential`

- **Import:** `from application_sdk.credentials import RawCredential`
- **Signature:** `class RawCredential`
- **Summary:** Wrapper for raw dict credentials (legacy / unknown types).
- **Defined in:** `application_sdk/credentials/types.py`

### Functions

#### `api_key_ref`

- **Import:** `from application_sdk.credentials import api_key_ref`
- **Signature:** `api_key_ref(name: str, *, store_name: str = 'default')`
- **Summary:** Create a CredentialRef for an API key credential.
- **Defined in:** `application_sdk/credentials/ref.py`

#### `atlan_api_token_ref`

- **Import:** `from application_sdk.credentials import atlan_api_token_ref`
- **Signature:** `atlan_api_token_ref(name: str, *, store_name: str = 'default')`
- **Summary:** Create a CredentialRef for an Atlan API token credential.
- **Defined in:** `application_sdk/credentials/ref.py`

#### `atlan_oauth_client_ref`

- **Import:** `from application_sdk.credentials import atlan_oauth_client_ref`
- **Signature:** `atlan_oauth_client_ref(name: str, *, store_name: str = 'default')`
- **Summary:** Create a CredentialRef for an Atlan OAuth client credential.
- **Defined in:** `application_sdk/credentials/ref.py`

#### `basic_ref`

- **Import:** `from application_sdk.credentials import basic_ref`
- **Signature:** `basic_ref(name: str, *, store_name: str = 'default')`
- **Summary:** Create a CredentialRef for a basic (username/password) credential.
- **Defined in:** `application_sdk/credentials/ref.py`

#### `bearer_token_ref`

- **Import:** `from application_sdk.credentials import bearer_token_ref`
- **Signature:** `bearer_token_ref(name: str, *, store_name: str = 'default')`
- **Summary:** Create a CredentialRef for a bearer token credential.
- **Defined in:** `application_sdk/credentials/ref.py`

#### `camel_to_kebab`

- **Import:** `from application_sdk.credentials import camel_to_kebab`
- **Signature:** `camel_to_kebab(key: str)`
- **Summary:** Convert a camelCase key to kebab-case.
- **Defined in:** `application_sdk/common/transforms.py`

#### `certificate_ref`

- **Import:** `from application_sdk.credentials import certificate_ref`
- **Signature:** `certificate_ref(name: str, *, store_name: str = 'default')`
- **Summary:** Create a CredentialRef for a certificate credential.
- **Defined in:** `application_sdk/credentials/ref.py`

#### `create_async_atlan_client`

- **Import:** `from application_sdk.credentials import create_async_atlan_client`
- **Signature:** `create_async_atlan_client(cred: Credential, *, extra_headers: dict[str, str] | None = None)`
- **Summary:** Create a pyatlan_v9 AsyncAtlanClient from a resolved Atlan credential.
- **Defined in:** `application_sdk/credentials/atlan_client.py`

#### `expand_dotted_keys`

- **Import:** `from application_sdk.credentials import expand_dotted_keys`
- **Signature:** `expand_dotted_keys(flat: dict[str, Any])`
- **Summary:** Expand dotted keys into nested dicts.
- **Defined in:** `application_sdk/common/transforms.py`

#### `get_registry`

- **Import:** `from application_sdk.credentials import get_registry`
- **Signature:** `get_registry()`
- **Summary:** Return the global CredentialTypeRegistry singleton.
- **Defined in:** `application_sdk/credentials/registry.py`

#### `git_ssh_ref`

- **Import:** `from application_sdk.credentials import git_ssh_ref`
- **Signature:** `git_ssh_ref(name: str, *, store_name: str = 'default')`
- **Summary:** Create a CredentialRef for a Git SSH credential.
- **Defined in:** `application_sdk/credentials/ref.py`

#### `git_token_ref`

- **Import:** `from application_sdk.credentials import git_token_ref`
- **Signature:** `git_token_ref(name: str, *, store_name: str = 'default')`
- **Summary:** Create a CredentialRef for a Git token (PAT/deploy token) credential.
- **Defined in:** `application_sdk/credentials/ref.py`

#### `kebab_to_camel`

- **Import:** `from application_sdk.credentials import kebab_to_camel`
- **Signature:** `kebab_to_camel(key: str)`
- **Summary:** Convert a kebab-case key to camelCase.
- **Defined in:** `application_sdk/common/transforms.py`

#### `legacy_credential_ref`

- **Import:** `from application_sdk.credentials import legacy_credential_ref`
- **Signature:** `legacy_credential_ref(guid: str, credential_type: str = 'unknown')`
- **Summary:** Create a CredentialRef from a platform-issued credential GUID.
- **Defined in:** `application_sdk/credentials/ref.py`

#### `oauth_client_ref`

- **Import:** `from application_sdk.credentials import oauth_client_ref`
- **Signature:** `oauth_client_ref(name: str, *, store_name: str = 'default')`
- **Summary:** Create a CredentialRef for an OAuth client credential.
- **Defined in:** `application_sdk/credentials/ref.py`

#### `parse_credentials_extra`

- **Import:** `from application_sdk.credentials import parse_credentials_extra`
- **Signature:** `parse_credentials_extra(credentials: dict[str, Any], *, strict: bool = True)`
- **Summary:** Decode the ``extra`` field of a credential dict.
- **Defined in:** `application_sdk/credentials/utils.py`

#### `register_credential_type`

- **Import:** `from application_sdk.credentials import register_credential_type`
- **Signature:** `register_credential_type(name: str, cls: type, parser: CredentialParser)`
- **Summary:** Register a custom credential type in the global registry.
- **Defined in:** `application_sdk/credentials/registry.py`

#### `transform_agent_credentials`

- **Import:** `from application_sdk.credentials import transform_agent_credentials`
- **Signature:** `transform_agent_credentials(agent_json: dict[str, Any])`
- **Summary:** Transform raw agent JSON into the format connectors expect.
- **Defined in:** `application_sdk/common/transforms.py`

## `application_sdk.errors`

Structured error codes — ErrorCode dataclass and cross-component constants (APP_ERROR, HANDLER_ERROR, CONTRACT_VALIDATION, etc.)

### Classes

#### `AlreadyExistsError`

- **Import:** `from application_sdk.errors import AlreadyExistsError`
- **Signature:** `class AlreadyExistsError(*, ...)`
- **Summary:** Entity the caller tried to create already exists.
- **Defined in:** `application_sdk/errors/leaves.py`

#### `AppError`

- **Import:** `from application_sdk.errors import AppError`
- **Signature:** `class AppError(*, ...)`
- **Summary:** Canonical SDK exception base.
- **Defined in:** `application_sdk/errors/base.py`

#### `AppPermissionDeniedError`

- **Import:** `from application_sdk.errors import AppPermissionDeniedError`
- **Signature:** `class AppPermissionDeniedError(*, ...)`
- **Summary:** Authenticated but not authorised.
- **Defined in:** `application_sdk/errors/leaves.py`

#### `AppTimeoutError`

- **Import:** `from application_sdk.errors import AppTimeoutError`
- **Signature:** `class AppTimeoutError(*, ...)`
- **Summary:** A bounded wait elapsed.
- **Defined in:** `application_sdk/errors/leaves.py`

#### `Audience`

- **Import:** `from application_sdk.errors import Audience`
- **Signature:** `class Audience`
- **Summary:** Who needs to take action to resolve this failure.
- **Defined in:** `application_sdk/errors/categories.py`

#### `AuthError`

- **Import:** `from application_sdk.errors import AuthError`
- **Signature:** `class AuthError(*, ...)`
- **Summary:** _(no docstring)_
- **Defined in:** `application_sdk/errors/leaves.py`

#### `CancelledError`

- **Import:** `from application_sdk.errors import CancelledError`
- **Signature:** `class CancelledError(*, ...)`
- **Summary:** _(no docstring)_
- **Defined in:** `application_sdk/errors/leaves.py`

#### `ColdStartRaceError`

- **Import:** `from application_sdk.errors import ColdStartRaceError`
- **Signature:** `class ColdStartRaceError`
- **Summary:** Marker for a :class:`DependencyUnavailableError` that specifically means
- **Defined in:** `application_sdk/errors/leaves.py`

#### `DataIntegrityError`

- **Import:** `from application_sdk.errors import DataIntegrityError`
- **Signature:** `class DataIntegrityError(*, ...)`
- **Summary:** _(no docstring)_
- **Defined in:** `application_sdk/errors/leaves.py`

#### `DependencyUnavailableError`

- **Import:** `from application_sdk.errors import DependencyUnavailableError`
- **Signature:** `class DependencyUnavailableError(*, ...)`
- **Summary:** Required Atlan-internal platform service is temporarily down or degraded.
- **Defined in:** `application_sdk/errors/leaves.py`

#### `ErrorCode`

- **Import:** `from application_sdk.errors import ErrorCode`
- **Signature:** `class ErrorCode(component: str, id: int) -> None`
- **Summary:** Structured error code for monitoring and alerting.
- **Defined in:** `application_sdk/errors/__init__.py`

#### `FailureCategory`

- **Import:** `from application_sdk.errors import FailureCategory`
- **Signature:** `class FailureCategory`
- **Summary:** Single-axis failure classification.
- **Defined in:** `application_sdk/errors/categories.py`

#### `FailureDetails`

- **Import:** `from application_sdk.errors import FailureDetails`
- **Signature:** `class FailureDetails`
- **Summary:** Pydantic envelope serialized into ``ApplicationError.details=[…]``.
- **Defined in:** `application_sdk/errors/wire.py`

#### `InternalError`

- **Import:** `from application_sdk.errors import InternalError`
- **Signature:** `class InternalError(*, ...)`
- **Summary:** _(no docstring)_
- **Defined in:** `application_sdk/errors/leaves.py`

#### `InvalidInputError`

- **Import:** `from application_sdk.errors import InvalidInputError`
- **Signature:** `class InvalidInputError(*, ...)`
- **Summary:** _(no docstring)_
- **Defined in:** `application_sdk/errors/leaves.py`

#### `NotFoundError`

- **Import:** `from application_sdk.errors import NotFoundError`
- **Signature:** `class NotFoundError(*, ...)`
- **Summary:** _(no docstring)_
- **Defined in:** `application_sdk/errors/leaves.py`

#### `PreconditionError`

- **Import:** `from application_sdk.errors import PreconditionError`
- **Signature:** `class PreconditionError(*, ...)`
- **Summary:** System state forbids the operation.
- **Defined in:** `application_sdk/errors/leaves.py`

#### `RateLimitedError`

- **Import:** `from application_sdk.errors import RateLimitedError`
- **Signature:** `class RateLimitedError(*, ...)`
- **Summary:** _(no docstring)_
- **Defined in:** `application_sdk/errors/leaves.py`

#### `ResourceExhaustedError`

- **Import:** `from application_sdk.errors import ResourceExhaustedError`
- **Signature:** `class ResourceExhaustedError(*, ...)`
- **Summary:** _(no docstring)_
- **Defined in:** `application_sdk/errors/leaves.py`

#### `SourceUnavailableError`

- **Import:** `from application_sdk.errors import SourceUnavailableError`
- **Signature:** `class SourceUnavailableError(*, ...)`
- **Summary:** Customer-controlled source system is temporarily unreachable.
- **Defined in:** `application_sdk/errors/leaves.py`

#### `UnimplementedError`

- **Import:** `from application_sdk.errors import UnimplementedError`
- **Signature:** `class UnimplementedError(*, ...)`
- **Summary:** Operation not supported or capability not yet built.
- **Defined in:** `application_sdk/errors/leaves.py`

### Functions

#### `redact_secrets`

- **Import:** `from application_sdk.errors import redact_secrets`
- **Signature:** `redact_secrets(text: str)`
- **Summary:** Redact URL userinfo and known secret query-params from a string.
- **Defined in:** `application_sdk/errors/base.py`

#### `safe_traceback`

- **Import:** `from application_sdk.errors import safe_traceback`
- **Signature:** `safe_traceback(exc: BaseException | None, max_len: int = _TRACEBACK_MAX_LEN)`
- **Summary:** Return a secret-redacted, length-capped full-frame traceback.
- **Defined in:** `application_sdk/errors/base.py`

#### `sanitize_cause_repr`

- **Import:** `from application_sdk.errors import sanitize_cause_repr`
- **Signature:** `sanitize_cause_repr(exc: BaseException)`
- **Summary:** Return a length-capped, secret-redacted string for a cause exception.
- **Defined in:** `application_sdk/errors/base.py`

### Constants and Enums

#### `APP_ALREADY_REGISTERED`

- **Import:** `from application_sdk.errors import APP_ALREADY_REGISTERED`
- **Signature:** `APP_ALREADY_REGISTERED`
- **Summary:** Deprecated legacy error code — use AppError subclasses (removed in v4.0).
- **Defined in:** `application_sdk/errors/__init__.py`

#### `APP_CONTEXT_ERROR`

- **Import:** `from application_sdk.errors import APP_CONTEXT_ERROR`
- **Signature:** `APP_CONTEXT_ERROR`
- **Summary:** Deprecated legacy error code — use AppError subclasses (removed in v4.0).
- **Defined in:** `application_sdk/errors/__init__.py`

#### `APP_ERROR`

- **Import:** `from application_sdk.errors import APP_ERROR`
- **Signature:** `APP_ERROR`
- **Summary:** Deprecated legacy error code — use AppError subclasses (removed in v4.0).
- **Defined in:** `application_sdk/errors/__init__.py`

#### `APP_NON_RETRYABLE`

- **Import:** `from application_sdk.errors import APP_NON_RETRYABLE`
- **Signature:** `APP_NON_RETRYABLE`
- **Summary:** Deprecated legacy error code — use AppError subclasses (removed in v4.0).
- **Defined in:** `application_sdk/errors/__init__.py`

#### `APP_NOT_FOUND`

- **Import:** `from application_sdk.errors import APP_NOT_FOUND`
- **Signature:** `APP_NOT_FOUND`
- **Summary:** Deprecated legacy error code — use AppError subclasses (removed in v4.0).
- **Defined in:** `application_sdk/errors/__init__.py`

#### `BINDING_ERROR`

- **Import:** `from application_sdk.errors import BINDING_ERROR`
- **Signature:** `BINDING_ERROR`
- **Summary:** Deprecated legacy error code — use AppError subclasses (removed in v4.0).
- **Defined in:** `application_sdk/errors/__init__.py`

#### `CONTRACT_VALIDATION`

- **Import:** `from application_sdk.errors import CONTRACT_VALIDATION`
- **Signature:** `CONTRACT_VALIDATION`
- **Summary:** Deprecated legacy error code — use AppError subclasses (removed in v4.0).
- **Defined in:** `application_sdk/errors/__init__.py`

#### `CREDENTIAL_ERROR`

- **Import:** `from application_sdk.errors import CREDENTIAL_ERROR`
- **Signature:** `CREDENTIAL_ERROR`
- **Summary:** Deprecated legacy error code — use AppError subclasses (removed in v4.0).
- **Defined in:** `application_sdk/errors/__init__.py`

#### `CREDENTIAL_NOT_FOUND`

- **Import:** `from application_sdk.errors import CREDENTIAL_NOT_FOUND`
- **Signature:** `CREDENTIAL_NOT_FOUND`
- **Summary:** Deprecated legacy error code — use AppError subclasses (removed in v4.0).
- **Defined in:** `application_sdk/errors/__init__.py`

#### `CREDENTIAL_PARSE_ERROR`

- **Import:** `from application_sdk.errors import CREDENTIAL_PARSE_ERROR`
- **Signature:** `CREDENTIAL_PARSE_ERROR`
- **Summary:** Deprecated legacy error code — use AppError subclasses (removed in v4.0).
- **Defined in:** `application_sdk/errors/__init__.py`

#### `CREDENTIAL_VALIDATION_ERROR`

- **Import:** `from application_sdk.errors import CREDENTIAL_VALIDATION_ERROR`
- **Signature:** `CREDENTIAL_VALIDATION_ERROR`
- **Summary:** Deprecated legacy error code — use AppError subclasses (removed in v4.0).
- **Defined in:** `application_sdk/errors/__init__.py`

#### `CREDENTIAL_VAULT_ERROR`

- **Import:** `from application_sdk.errors import CREDENTIAL_VAULT_ERROR`
- **Signature:** `CREDENTIAL_VAULT_ERROR`
- **Summary:** Deprecated legacy error code — use AppError subclasses (removed in v4.0).
- **Defined in:** `application_sdk/errors/__init__.py`

#### `DISCOVERY_ERROR`

- **Import:** `from application_sdk.errors import DISCOVERY_ERROR`
- **Signature:** `DISCOVERY_ERROR`
- **Summary:** Deprecated legacy error code — use AppError subclasses (removed in v4.0).
- **Defined in:** `application_sdk/errors/__init__.py`

#### `EVENT_BUS`

- **Import:** `from application_sdk.errors import EVENT_BUS`
- **Signature:** `EVENT_BUS`
- **Summary:** Deprecated legacy error code — use AppError subclasses (removed in v4.0).
- **Defined in:** `application_sdk/errors/__init__.py`

#### `EVENT_PUBLISH`

- **Import:** `from application_sdk.errors import EVENT_PUBLISH`
- **Signature:** `EVENT_PUBLISH`
- **Summary:** Deprecated legacy error code — use AppError subclasses (removed in v4.0).
- **Defined in:** `application_sdk/errors/__init__.py`

#### `EXECUTION_ACTIVITY_ERROR`

- **Import:** `from application_sdk.errors import EXECUTION_ACTIVITY_ERROR`
- **Signature:** `EXECUTION_ACTIVITY_ERROR`
- **Summary:** Deprecated legacy error code — use AppError subclasses (removed in v4.0).
- **Defined in:** `application_sdk/errors/__init__.py`

#### `EXECUTION_ERROR`

- **Import:** `from application_sdk.errors import EXECUTION_ERROR`
- **Signature:** `EXECUTION_ERROR`
- **Summary:** Deprecated legacy error code — use AppError subclasses (removed in v4.0).
- **Defined in:** `application_sdk/errors/__init__.py`

#### `EXECUTION_WORKER_ERROR`

- **Import:** `from application_sdk.errors import EXECUTION_WORKER_ERROR`
- **Signature:** `EXECUTION_WORKER_ERROR`
- **Summary:** Deprecated legacy error code — use AppError subclasses (removed in v4.0).
- **Defined in:** `application_sdk/errors/__init__.py`

#### `HANDLER_ERROR`

- **Import:** `from application_sdk.errors import HANDLER_ERROR`
- **Signature:** `HANDLER_ERROR`
- **Summary:** Deprecated legacy error code — use AppError subclasses (removed in v4.0).
- **Defined in:** `application_sdk/errors/__init__.py`

#### `PAYLOAD_SAFETY`

- **Import:** `from application_sdk.errors import PAYLOAD_SAFETY`
- **Signature:** `PAYLOAD_SAFETY`
- **Summary:** Deprecated legacy error code — use AppError subclasses (removed in v4.0).
- **Defined in:** `application_sdk/errors/__init__.py`

#### `PUBSUB_ERROR`

- **Import:** `from application_sdk.errors import PUBSUB_ERROR`
- **Signature:** `PUBSUB_ERROR`
- **Summary:** Deprecated legacy error code — use AppError subclasses (removed in v4.0).
- **Defined in:** `application_sdk/errors/__init__.py`

#### `SECRET_NOT_FOUND`

- **Import:** `from application_sdk.errors import SECRET_NOT_FOUND`
- **Signature:** `SECRET_NOT_FOUND`
- **Summary:** Deprecated legacy error code — use AppError subclasses (removed in v4.0).
- **Defined in:** `application_sdk/errors/__init__.py`

#### `SECRET_STORE_ERROR`

- **Import:** `from application_sdk.errors import SECRET_STORE_ERROR`
- **Signature:** `SECRET_STORE_ERROR`
- **Summary:** Deprecated legacy error code — use AppError subclasses (removed in v4.0).
- **Defined in:** `application_sdk/errors/__init__.py`

#### `SEGMENT_ERROR`

- **Import:** `from application_sdk.errors import SEGMENT_ERROR`
- **Signature:** `SEGMENT_ERROR`
- **Summary:** Deprecated legacy error code — use AppError subclasses (removed in v4.0).
- **Defined in:** `application_sdk/errors/__init__.py`

#### `STATE_STORE_ERROR`

- **Import:** `from application_sdk.errors import STATE_STORE_ERROR`
- **Signature:** `STATE_STORE_ERROR`
- **Summary:** Deprecated legacy error code — use AppError subclasses (removed in v4.0).
- **Defined in:** `application_sdk/errors/__init__.py`

#### `STORAGE_CONFIG`

- **Import:** `from application_sdk.errors import STORAGE_CONFIG`
- **Signature:** `STORAGE_CONFIG`
- **Summary:** Deprecated legacy error code — use AppError subclasses (removed in v4.0).
- **Defined in:** `application_sdk/errors/__init__.py`

#### `STORAGE_EMPTY_UPLOAD`

- **Import:** `from application_sdk.errors import STORAGE_EMPTY_UPLOAD`
- **Signature:** `STORAGE_EMPTY_UPLOAD`
- **Summary:** Deprecated legacy error code — use AppError subclasses (removed in v4.0).
- **Defined in:** `application_sdk/errors/__init__.py`

#### `STORAGE_NOT_FOUND`

- **Import:** `from application_sdk.errors import STORAGE_NOT_FOUND`
- **Signature:** `STORAGE_NOT_FOUND`
- **Summary:** Deprecated legacy error code — use AppError subclasses (removed in v4.0).
- **Defined in:** `application_sdk/errors/__init__.py`

#### `STORAGE_OPERATION`

- **Import:** `from application_sdk.errors import STORAGE_OPERATION`
- **Signature:** `STORAGE_OPERATION`
- **Summary:** Deprecated legacy error code — use AppError subclasses (removed in v4.0).
- **Defined in:** `application_sdk/errors/__init__.py`

#### `STORAGE_PERMISSION`

- **Import:** `from application_sdk.errors import STORAGE_PERMISSION`
- **Signature:** `STORAGE_PERMISSION`
- **Summary:** Deprecated legacy error code — use AppError subclasses (removed in v4.0).
- **Defined in:** `application_sdk/errors/__init__.py`

#### `TASK_NOT_FOUND`

- **Import:** `from application_sdk.errors import TASK_NOT_FOUND`
- **Signature:** `TASK_NOT_FOUND`
- **Summary:** Deprecated legacy error code — use AppError subclasses (removed in v4.0).
- **Defined in:** `application_sdk/errors/__init__.py`

#### `WORKER_EVICTED_TYPE`

- **Import:** `from application_sdk.errors import WORKER_EVICTED_TYPE`
- **Signature:** `WORKER_EVICTED_TYPE`
- **Summary:** _(no docstring)_
- **Defined in:** `application_sdk/errors/leaves.py`

## `application_sdk.execution`

Task/workflow execution — retry, heartbeat, sandbox, AppWorker, Temporal client

### Classes

#### `ApplicationError`

- **Import:** `from application_sdk.execution import ApplicationError`
- **Signature:** `class ApplicationError`
- **Summary:** Framework application error.
- **Defined in:** `application_sdk/execution/errors.py`

#### `AppWorker`

- **Import:** `from application_sdk.execution import AppWorker`
- **Signature:** `class AppWorker(worker: Worker, ...)`
- **Summary:** Wraps Temporal Worker to emit worker_start on startup and to push
- **Defined in:** `application_sdk/execution/_temporal/worker.py`

#### `RetryPolicy`

- **Import:** `from application_sdk.execution import RetryPolicy`
- **Signature:** `class RetryPolicy(max_attempts: int = 3, ...)`
- **Summary:** Configuration for retry behavior.
- **Defined in:** `application_sdk/execution/retry.py`

#### `TemporalActivityError`

- **Import:** `from application_sdk.execution import TemporalActivityError`
- **Signature:** `class TemporalActivityError(message: str, ...)`
- **Summary:** Error raised on activity failure. _(re-exported from `temporalio.exceptions.ActivityError`)_

#### `TemporalAuthConfig`

- **Import:** `from application_sdk.execution import TemporalAuthConfig`
- **Signature:** `class TemporalAuthConfig(client_id: str = '', ...)`
- **Summary:** Configuration for Temporal OAuth authentication.
- **Defined in:** `application_sdk/execution/_temporal/auth.py`

#### `TemporalAuthManager`

- **Import:** `from application_sdk.execution import TemporalAuthManager`
- **Signature:** `class TemporalAuthManager(config: TemporalAuthConfig, ...)`
- **Summary:** Manages OAuth token lifecycle for Temporal client connections.
- **Defined in:** `application_sdk/execution/_temporal/auth.py`

#### `TemporalCancelledError`

- **Import:** `from application_sdk.execution import TemporalCancelledError`
- **Signature:** `class TemporalCancelledError(message: str = 'Cancelled', *details: Any)`
- **Summary:** Error raised on workflow/activity cancellation. _(re-exported from `temporalio.exceptions.CancelledError`)_

#### `TemporalChildWorkflowError`

- **Import:** `from application_sdk.execution import TemporalChildWorkflowError`
- **Signature:** `class TemporalChildWorkflowError(message: str, ...)`
- **Summary:** Error raised on child workflow failure. _(re-exported from `temporalio.exceptions.ChildWorkflowError`)_

#### `TemporalClient`

- **Import:** `from application_sdk.execution import TemporalClient`
- **Signature:** `class TemporalClient(service_client: 'temporalio.service.ServiceClient', ...)`
- **Summary:** Client for accessing Temporal. _(re-exported from `temporalio.client.Client`)_

#### `TemporalExecutorBackend`

- **Import:** `from application_sdk.execution import TemporalExecutorBackend`
- **Signature:** `class TemporalExecutorBackend(client: Client, task_queue: str = 'application-sdk')`
- **Summary:** Temporal-based executor backend for running Apps as workflows.
- **Defined in:** `application_sdk/execution/_temporal/backend.py`

#### `TemporalTerminatedError`

- **Import:** `from application_sdk.execution import TemporalTerminatedError`
- **Signature:** `class TemporalTerminatedError(message: str, *details: Any)`
- **Summary:** Error raised on workflow cancellation. _(re-exported from `temporalio.exceptions.TerminatedError`)_

#### `TemporalTimeoutError`

- **Import:** `from application_sdk.execution import TemporalTimeoutError`
- **Signature:** `class TemporalTimeoutError(message: str, ...)`
- **Summary:** Error raised on workflow/activity timeout. _(re-exported from `temporalio.exceptions.TimeoutError`)_

#### `TemporalWorkflowFailureError`

- **Import:** `from application_sdk.execution import TemporalWorkflowFailureError`
- **Signature:** `class TemporalWorkflowFailureError(*, cause: 'BaseException')`
- **Summary:** Error that occurs when a workflow is unsuccessful. _(re-exported from `temporalio.client.WorkflowFailureError`)_

### Functions

#### `build_output_path`

- **Import:** `from application_sdk.execution import build_output_path`
- **Signature:** `build_output_path()`
- **Summary:** SDK-internal: compose the standardized output path for the current run.
- **Defined in:** `application_sdk/execution/_temporal/activity_utils.py`

#### `create_data_converter`

- **Import:** `from application_sdk.execution import create_data_converter`
- **Signature:** `create_data_converter(additional_converters: list[EncodingPayloadConverter] | None = None)`
- **Summary:** Create a data converter with Pydantic support.
- **Defined in:** `application_sdk/execution/_temporal/converter.py`

#### `create_data_converter_for_app`

- **Import:** `from application_sdk.execution import create_data_converter_for_app`
- **Signature:** `create_data_converter_for_app(app_class: type[App])`
- **Summary:** Create a data converter for a specific app, including any app-specific converters.
- **Defined in:** `application_sdk/execution/_temporal/converter.py`

#### `create_temporal_client`

- **Import:** `from application_sdk.execution import create_temporal_client`
- **Signature:** `create_temporal_client(host: str = 'localhost:7233', *, ...)`
- **Summary:** Create a Temporal client with optional TLS and auth.
- **Defined in:** `application_sdk/execution/_temporal/backend.py`

#### `create_worker`

- **Import:** `from application_sdk.execution import create_worker`
- **Signature:** `create_worker(client: Client, *, ...)`
- **Summary:** Create a Temporal worker for registered Apps.
- **Defined in:** `application_sdk/execution/_temporal/worker.py`

#### `get_object_store_prefix`

- **Import:** `from application_sdk.execution import get_object_store_prefix`
- **Signature:** `get_object_store_prefix(path: str)`
- **Summary:** Convert a local-path or object-store-path into an object-store prefix.
- **Defined in:** `application_sdk/execution/_temporal/activity_utils.py`

#### `needs_lock`

- **Import:** `from application_sdk.execution import needs_lock`
- **Signature:** `needs_lock(max_locks: int = 5, lock_name: Optional[str] = None)`
- **Summary:** Decorator to mark activities that require distributed locking.
- **Defined in:** `application_sdk/execution/decorators.py`

## `application_sdk.handler`

HTTP handler framework — Handler ABC, DefaultHandler, preflight, auth, service factory

### Classes

#### `ApiMetadataObject`

- **Import:** `from application_sdk.handler import ApiMetadataObject`
- **Signature:** `class ApiMetadataObject`
- **Summary:** A node for the **apitree** frontend widget.
- **Defined in:** `application_sdk/handler/contracts.py`

#### `ApiMetadataOutput`

- **Import:** `from application_sdk.handler import ApiMetadataOutput`
- **Signature:** `class ApiMetadataOutput`
- **Summary:** Metadata output for BI / API connectors (apitree widget).
- **Defined in:** `application_sdk/handler/contracts.py`

#### `AuthInput`

- **Import:** `from application_sdk.handler import AuthInput`
- **Signature:** `class AuthInput`
- **Summary:** Input for the test_auth handler operation.
- **Defined in:** `application_sdk/handler/contracts.py`

#### `AuthOutput`

- **Import:** `from application_sdk.handler import AuthOutput`
- **Signature:** `class AuthOutput`
- **Summary:** Output from the test_auth handler operation.
- **Defined in:** `application_sdk/handler/contracts.py`

#### `AuthStatus`

- **Import:** `from application_sdk.handler import AuthStatus`
- **Signature:** `class AuthStatus`
- **Summary:** Result of an authentication attempt.
- **Defined in:** `application_sdk/handler/contracts.py`

#### `BaseConnectionConfig`

- **Import:** `from application_sdk.handler import BaseConnectionConfig`
- **Signature:** `class BaseConnectionConfig`
- **Summary:** Base type for preflight and metadata connection configuration.
- **Defined in:** `application_sdk/handler/contracts.py`

#### `BaseMetadataConfig`

- **Import:** `from application_sdk.handler import BaseMetadataConfig`
- **Signature:** `class BaseMetadataConfig`
- **Summary:** Base type for form-level metadata forwarded alongside preflight credentials.
- **Defined in:** `application_sdk/handler/contracts.py`

#### `DefaultHandler`

- **Import:** `from application_sdk.handler import DefaultHandler`
- **Signature:** `class DefaultHandler`
- **Summary:** Pass-through handler that always returns SUCCESS/READY/empty.
- **Defined in:** `application_sdk/handler/base.py`

#### `Handler`

- **Import:** `from application_sdk.handler import Handler`
- **Signature:** `class Handler`
- **Summary:** Abstract base class for per-app handler implementations.
- **Defined in:** `application_sdk/handler/base.py`

#### `HandlerContext`

- **Import:** `from application_sdk.handler import HandlerContext`
- **Signature:** `class HandlerContext(app_name: str, ...)`
- **Summary:** Execution context passed to Handlers during request processing.
- **Defined in:** `application_sdk/handler/context.py`

#### `HandlerCredential`

- **Import:** `from application_sdk.handler import HandlerCredential`
- **Signature:** `class HandlerCredential`
- **Summary:** A single credential key-value pair for HTTP handler inputs.
- **Defined in:** `application_sdk/handler/contracts.py`

#### `HandlerError`

- **Import:** `from application_sdk.handler import HandlerError`
- **Signature:** `class HandlerError(message: str, ...)`
- **Summary:** Deprecated: use a typed ``AppError`` subclass — removed in v4.0.
- **Defined in:** `application_sdk/handler/base.py`

#### `MetadataInput`

- **Import:** `from application_sdk.handler import MetadataInput`
- **Signature:** `class MetadataInput`
- **Summary:** Input for the fetch_metadata handler operation.
- **Defined in:** `application_sdk/handler/contracts.py`

#### `MetadataOutput`

- **Import:** `from application_sdk.handler import MetadataOutput`
- **Signature:** `class MetadataOutput`
- **Summary:** Base output from the fetch_metadata handler operation.
- **Defined in:** `application_sdk/handler/contracts.py`

#### `PreflightCheck`

- **Import:** `from application_sdk.handler import PreflightCheck`
- **Signature:** `class PreflightCheck`
- **Summary:** Result of a single preflight check.
- **Defined in:** `application_sdk/handler/contracts.py`

#### `PreflightInput`

- **Import:** `from application_sdk.handler import PreflightInput`
- **Signature:** `class PreflightInput`
- **Summary:** Input for the preflight_check handler operation.
- **Defined in:** `application_sdk/handler/contracts.py`

#### `PreflightOutput`

- **Import:** `from application_sdk.handler import PreflightOutput`
- **Signature:** `class PreflightOutput`
- **Summary:** Output from the preflight_check handler operation.
- **Defined in:** `application_sdk/handler/contracts.py`

#### `PreflightStatus`

- **Import:** `from application_sdk.handler import PreflightStatus`
- **Signature:** `class PreflightStatus`
- **Summary:** Overall preflight verdict — decides the gate.
- **Defined in:** `application_sdk/handler/contracts.py`

#### `SqlMetadataObject`

- **Import:** `from application_sdk.handler import SqlMetadataObject`
- **Signature:** `class SqlMetadataObject`
- **Summary:** A row for the **sqltree** frontend widget.
- **Defined in:** `application_sdk/handler/contracts.py`

#### `SqlMetadataOutput`

- **Import:** `from application_sdk.handler import SqlMetadataOutput`
- **Signature:** `class SqlMetadataOutput`
- **Summary:** Metadata output for SQL connectors (sqltree widget).
- **Defined in:** `application_sdk/handler/contracts.py`

### Functions

#### `create_app_handler_service`

- **Import:** `from application_sdk.handler import create_app_handler_service`
- **Signature:** `create_app_handler_service(handler: Handler, *, ...)`
- **Summary:** Create a FastAPI app for a single handler.
- **Defined in:** `application_sdk/handler/service.py`

#### `run_app_handler_service`

- **Import:** `from application_sdk.handler import run_app_handler_service`
- **Signature:** `run_app_handler_service(handler: Handler, *, ...)`
- **Summary:** Create and run the handler service with uvicorn.
- **Defined in:** `application_sdk/handler/service.py`

## `application_sdk.infrastructure`

Protocol-based infrastructure (StateStore, SecretStore, PubSub, Bindings, CapacityPool)

### Classes

#### `AsyncDaprClient`

- **Import:** `from application_sdk.infrastructure import AsyncDaprClient`
- **Signature:** `class AsyncDaprClient(base_url: str | None = None, ...)`
- **Summary:** Thin async wrapper around the Dapr sidecar HTTP API.
- **Defined in:** `application_sdk/infrastructure/_dapr/http.py`

#### `Binding`

- **Import:** `from application_sdk.infrastructure import Binding`
- **Signature:** `class Binding`
- **Summary:** Protocol for generic bindings.
- **Defined in:** `application_sdk/infrastructure/bindings.py`

#### `BindingError`

- **Import:** `from application_sdk.infrastructure import BindingError`
- **Signature:** `class BindingError(message: str, ...)`
- **Summary:** Deprecated: use ``application_sdk.errors.DependencyUnavailableError`` — removed in v4.0.
- **Defined in:** `application_sdk/infrastructure/bindings.py`

#### `BindingRequest`

- **Import:** `from application_sdk.infrastructure import BindingRequest`
- **Signature:** `class BindingRequest(operation: str, data: bytes | None = None, metadata: dict[str, str] = dict())`
- **Summary:** Request to invoke a binding.
- **Defined in:** `application_sdk/infrastructure/bindings.py`

#### `BindingResponse`

- **Import:** `from application_sdk.infrastructure import BindingResponse`
- **Signature:** `class BindingResponse(data: bytes | None = None, metadata: dict[str, str] = dict())`
- **Summary:** Response from a binding invocation.
- **Defined in:** `application_sdk/infrastructure/bindings.py`

#### `CapacityPool`

- **Import:** `from application_sdk.infrastructure import CapacityPool`
- **Signature:** `class CapacityPool`
- **Summary:** Protocol for distributed capacity management.
- **Defined in:** `application_sdk/infrastructure/capacity.py`

#### `CredentialVault`

- **Import:** `from application_sdk.infrastructure import CredentialVault`
- **Signature:** `class CredentialVault`
- **Summary:** Protocol for GUID-based runtime credential resolution.
- **Defined in:** `application_sdk/infrastructure/credential_vault.py`

#### `CredentialVaultError`

- **Import:** `from application_sdk.infrastructure import CredentialVaultError`
- **Signature:** `class CredentialVaultError(message: str, ...)`
- **Summary:** Deprecated: use ``application_sdk.errors.DependencyUnavailableError`` — removed in v4.0.
- **Defined in:** `application_sdk/infrastructure/credential_vault.py`

#### `DaprBinding`

- **Import:** `from application_sdk.infrastructure import DaprBinding`
- **Signature:** `class DaprBinding(client: AsyncDaprClient, binding_name: str)`
- **Summary:** Dapr-backed binding implementation.
- **Defined in:** `application_sdk/infrastructure/_dapr/client.py`

#### `DaprCredentialVault`

- **Import:** `from application_sdk.infrastructure import DaprCredentialVault`
- **Signature:** `class DaprCredentialVault(client: AsyncDaprClient, ...)`
- **Summary:** Dapr-backed credential vault for GUID-based runtime credential resolution.
- **Defined in:** `application_sdk/infrastructure/_dapr/credential_vault.py`

#### `DaprPubSub`

- **Import:** `from application_sdk.infrastructure import DaprPubSub`
- **Signature:** `class DaprPubSub(client: AsyncDaprClient, pubsub_name: str = 'pubsub')`
- **Summary:** Dapr-backed pub/sub implementation.
- **Defined in:** `application_sdk/infrastructure/_dapr/client.py`

#### `DaprSecretStore`

- **Import:** `from application_sdk.infrastructure import DaprSecretStore`
- **Signature:** `class DaprSecretStore(client: AsyncDaprClient, store_name: str = 'secretstore')`
- **Summary:** Dapr-backed secret store implementation.
- **Defined in:** `application_sdk/infrastructure/_dapr/client.py`

#### `DaprStateStore`

- **Import:** `from application_sdk.infrastructure import DaprStateStore`
- **Signature:** `class DaprStateStore(client: AsyncDaprClient, store_name: str = 'statestore')`
- **Summary:** Dapr-backed state store implementation.
- **Defined in:** `application_sdk/infrastructure/_dapr/client.py`

#### `EnvironmentSecretStore`

- **Import:** `from application_sdk.infrastructure import EnvironmentSecretStore`
- **Signature:** `class EnvironmentSecretStore(prefix: str = '')`
- **Summary:** Secret store backed by environment variables.
- **Defined in:** `application_sdk/infrastructure/secrets.py`

#### `InfrastructureContext`

- **Import:** `from application_sdk.infrastructure import InfrastructureContext`
- **Signature:** `class InfrastructureContext(state_store: StateStore | None = None, ...)`
- **Summary:** Holds the current infrastructure services for a process.
- **Defined in:** `application_sdk/infrastructure/context.py`

#### `InputBinding`

- **Import:** `from application_sdk.infrastructure import InputBinding`
- **Signature:** `class InputBinding`
- **Summary:** Protocol for input bindings (event sources).
- **Defined in:** `application_sdk/infrastructure/bindings.py`

#### `LocalCapacityPool`

- **Import:** `from application_sdk.infrastructure import LocalCapacityPool`
- **Signature:** `class LocalCapacityPool`
- **Summary:** Local-only capacity pool (no coordination).
- **Defined in:** `application_sdk/infrastructure/capacity.py`

#### `Message`

- **Import:** `from application_sdk.infrastructure import Message`
- **Signature:** `class Message(data: dict[str, Any], metadata: dict[str, str] = dict(), id: str | None = None, topic: str | None = None)`
- **Summary:** A pub/sub message.
- **Defined in:** `application_sdk/infrastructure/pubsub.py`

#### `OutputBinding`

- **Import:** `from application_sdk.infrastructure import OutputBinding`
- **Signature:** `class OutputBinding`
- **Summary:** Protocol for output bindings (event sinks).
- **Defined in:** `application_sdk/infrastructure/bindings.py`

#### `PubSub`

- **Import:** `from application_sdk.infrastructure import PubSub`
- **Signature:** `class PubSub`
- **Summary:** Protocol for pub/sub messaging.
- **Defined in:** `application_sdk/infrastructure/pubsub.py`

#### `PubSubError`

- **Import:** `from application_sdk.infrastructure import PubSubError`
- **Signature:** `class PubSubError(message: str, ...)`
- **Summary:** Deprecated: use ``application_sdk.errors.DependencyUnavailableError`` — removed in v4.0.
- **Defined in:** `application_sdk/infrastructure/pubsub.py`

#### `SecretNotFoundError`

- **Import:** `from application_sdk.infrastructure import SecretNotFoundError`
- **Signature:** `class SecretNotFoundError(secret_name: str)`
- **Summary:** The requested secret key was not found in the secret store.
- **Defined in:** `application_sdk/infrastructure/secrets.py`

#### `SecretStore`

- **Import:** `from application_sdk.infrastructure import SecretStore`
- **Signature:** `class SecretStore`
- **Summary:** Protocol for secrets management.
- **Defined in:** `application_sdk/infrastructure/secrets.py`

#### `SecretStoreError`

- **Import:** `from application_sdk.infrastructure import SecretStoreError`
- **Signature:** `class SecretStoreError(message: str, ...)`
- **Summary:** Generic secret-store failure (category=DEPENDENCY_UNAVAILABLE).
- **Defined in:** `application_sdk/infrastructure/secrets.py`

#### `SecretStoreUnavailableError`

- **Import:** `from application_sdk.infrastructure import SecretStoreUnavailableError`
- **Signature:** `class SecretStoreUnavailableError(secret_name: str, *, cause: Exception | None = None)`
- **Summary:** The secret store / Dapr sidecar was *unreachable* — a transport failure
- **Defined in:** `application_sdk/infrastructure/secrets.py`

#### `StateStore`

- **Import:** `from application_sdk.infrastructure import StateStore`
- **Signature:** `class StateStore`
- **Summary:** Protocol for state storage.
- **Defined in:** `application_sdk/infrastructure/state.py`

#### `StateStoreError`

- **Import:** `from application_sdk.infrastructure import StateStoreError`
- **Signature:** `class StateStoreError(message: str, ...)`
- **Summary:** Deprecated: use ``application_sdk.errors.DependencyUnavailableError`` — removed in v4.0.
- **Defined in:** `application_sdk/infrastructure/state.py`

#### `Subscription`

- **Import:** `from application_sdk.infrastructure import Subscription`
- **Signature:** `class Subscription`
- **Summary:** Protocol for pub/sub subscriptions.
- **Defined in:** `application_sdk/infrastructure/pubsub.py`

### Functions

#### `clear_infrastructure`

- **Import:** `from application_sdk.infrastructure import clear_infrastructure`
- **Signature:** `clear_infrastructure()`
- **Summary:** Clear the current infrastructure context.
- **Defined in:** `application_sdk/infrastructure/context.py`

#### `configure_capacity_pool`

- **Import:** `from application_sdk.infrastructure import configure_capacity_pool`
- **Signature:** `configure_capacity_pool(pool: CapacityPool)`
- **Summary:** Configure the global capacity pool for distributed rate limiting.
- **Defined in:** `application_sdk/infrastructure/capacity.py`

#### `get_capacity_pool`

- **Import:** `from application_sdk.infrastructure import get_capacity_pool`
- **Signature:** `get_capacity_pool()`
- **Summary:** Get the configured capacity pool.
- **Defined in:** `application_sdk/infrastructure/capacity.py`

#### `get_deployment_secret`

- **Import:** `from application_sdk.infrastructure import get_deployment_secret`
- **Signature:** `get_deployment_secret(key: str)`
- **Summary:** Get a specific key from deployment configuration in the deployment secret store.
- **Defined in:** `application_sdk/infrastructure/secrets.py`

#### `get_infrastructure`

- **Import:** `from application_sdk.infrastructure import get_infrastructure`
- **Signature:** `get_infrastructure()`
- **Summary:** Get the current infrastructure context.
- **Defined in:** `application_sdk/infrastructure/context.py`

#### `retry_past_dapr_cold_start`

- **Import:** `from application_sdk.infrastructure import retry_past_dapr_cold_start`
- **Signature:** `retry_past_dapr_cold_start(call: Callable[[], Awaitable[_T]], *, description: str, component: str)`
- **Summary:** Retry an idempotent Dapr-backed call past a cold sidecar.
- **Defined in:** `application_sdk/infrastructure/_dapr/http.py`

#### `set_infrastructure`

- **Import:** `from application_sdk.infrastructure import set_infrastructure`
- **Signature:** `set_infrastructure(ctx: InfrastructureContext)`
- **Summary:** Set the current infrastructure context.
- **Defined in:** `application_sdk/infrastructure/context.py`

### Constants and Enums

#### `DAPR_SECRET_STORE_COMPONENT`

- **Import:** `from application_sdk.infrastructure import DAPR_SECRET_STORE_COMPONENT`
- **Signature:** `DAPR_SECRET_STORE_COMPONENT`
- **Summary:** _(no docstring)_
- **Defined in:** `application_sdk/infrastructure/_dapr/http.py`

#### `MessageHandler`

- **Import:** `from application_sdk.infrastructure import MessageHandler`
- **Signature:** `MessageHandler`
- **Summary:** _(no docstring)_
- **Defined in:** `application_sdk/infrastructure/pubsub.py`

## `application_sdk.main`

Dev entry point — run_dev_combined() and AppConfig for local execution and container startup

### Classes

#### `AppConfig`

- **Import:** `from application_sdk.main import AppConfig`
- **Signature:** `class AppConfig(mode: str, ...)`
- **Summary:** Runtime configuration for app execution.
- **Defined in:** `application_sdk/main.py`

### Functions

#### `run_dev_combined`

- **Import:** `from application_sdk.main import run_dev_combined`
- **Signature:** `run_dev_combined(app_class: type[App], *, ...)`
- **Summary:** Run worker + handler in a single process for local development.
- **Defined in:** `application_sdk/main.py`

## `application_sdk.observability`

Logging context — ExecutionContext, CorrelationContext, request/correlation helpers

### Classes

#### `AtlanLoggerAdapter`

- **Import:** `from application_sdk.observability import AtlanLoggerAdapter`
- **Signature:** `class AtlanLoggerAdapter(logger_name: str)`
- **Summary:** A custom logger adapter for Atlan that extends AtlanObservability.
- **Defined in:** `application_sdk/observability/logger_adaptor.py`

#### `CorrelationContext`

- **Import:** `from application_sdk.observability import CorrelationContext`
- **Signature:** `class CorrelationContext(correlation_id: str = '')`
- **Summary:** Holds the current correlation ID for a request or workflow run.
- **Defined in:** `application_sdk/observability/correlation.py`

#### `ExecutionContext`

- **Import:** `from application_sdk.observability import ExecutionContext`
- **Signature:** `class ExecutionContext(execution_type: str = 'none', ...)`
- **Summary:** Immutable snapshot of the current Temporal execution context.
- **Defined in:** `application_sdk/observability/context.py`

### Functions

#### `get_correlation_context`

- **Import:** `from application_sdk.observability import get_correlation_context`
- **Signature:** `get_correlation_context()`
- **Summary:** Get the current correlation context.
- **Defined in:** `application_sdk/observability/correlation.py`

#### `get_execution_context`

- **Import:** `from application_sdk.observability import get_execution_context`
- **Signature:** `get_execution_context()`
- **Summary:** Return the current execution context (never raises).
- **Defined in:** `application_sdk/observability/context.py`

#### `get_logger`

- **Import:** `from application_sdk.observability import get_logger`
- **Signature:** `get_logger(name: str | None = None)`
- **Summary:** Get or create an instance of AtlanLoggerAdapter.
- **Defined in:** `application_sdk/observability/logger_adaptor.py`

#### `metrics`

- **Import:** `from application_sdk.observability import metrics`
- **Summary:** OTel-native metrics API for app authors.
- **Defined in:** `application_sdk/observability/metrics.py`

#### `set_correlation_context`

- **Import:** `from application_sdk.observability import set_correlation_context`
- **Signature:** `set_correlation_context(ctx: CorrelationContext)`
- **Summary:** Set the current correlation context.
- **Defined in:** `application_sdk/observability/correlation.py`

#### `set_execution_context`

- **Import:** `from application_sdk.observability import set_execution_context`
- **Signature:** `set_execution_context(ctx: ExecutionContext)`
- **Summary:** Set the current execution context.
- **Defined in:** `application_sdk/observability/context.py`

### Constants and Enums

#### `correlation_context`

- **Import:** `from application_sdk.observability import correlation_context`
- **Signature:** `correlation_context: ContextVar[dict[str, Any] | None]`
- **Summary:** _(no docstring)_
- **Defined in:** `application_sdk/observability/context.py`

#### `request_context`

- **Import:** `from application_sdk.observability import request_context`
- **Signature:** `request_context: ContextVar[dict[str, Any] | None]`
- **Summary:** _(no docstring)_
- **Defined in:** `application_sdk/observability/context.py`

## `application_sdk.outputs`

Output collectors and record models for Automation Engine

### Classes

#### `Artifact`

- **Import:** `from application_sdk.outputs import Artifact`
- **Signature:** `class Artifact`
- **Summary:** A reference to a downloadable file artifact.
- **Defined in:** `application_sdk/outputs/models.py`

#### `Metric`

- **Import:** `from application_sdk.outputs import Metric`
- **Signature:** `class Metric`
- **Summary:** A single metric to expose in workflow output.
- **Defined in:** `application_sdk/outputs/models.py`

#### `OutputCollector`

- **Import:** `from application_sdk.outputs import OutputCollector`
- **Signature:** `class OutputCollector()`
- **Summary:** Collects metrics and artifacts during workflow or activity execution.
- **Defined in:** `application_sdk/outputs/collector.py`

### Functions

#### `get_outputs`

- **Import:** `from application_sdk.outputs import get_outputs`
- **Signature:** `get_outputs() -> OutputCollector`
- **Summary:** Get the output collector for the current execution context.
- **Defined in:** `application_sdk/outputs/__init__.py`

## `application_sdk.storage`

Object-store abstraction — factory, formats, batch, transfer, cloud bindings

### Classes

#### `BindingSecretRefs`

- **Import:** `from application_sdk.storage import BindingSecretRefs`
- **Signature:** `class BindingSecretRefs(secret_store: str | None = None, refs: list[tuple[str, str]] = list())`
- **Summary:** Which secrets a Dapr component needs, and which store holds them.
- **Defined in:** `application_sdk/storage/binding.py`

#### `BoundStore`

- **Import:** `from application_sdk.storage import BoundStore`
- **Signature:** `class BoundStore(store: ObjectStore, put_attributes: dict[str, str] | None = None)`
- **Summary:** An :class:`~obstore.store.ObjectStore` paired with per-write put attributes.
- **Defined in:** `application_sdk/storage/ops.py`

#### `CloudStore`

- **Import:** `from application_sdk.storage import CloudStore`
- **Signature:** `class CloudStore(store: ObjectStore, *, provider: str = 'unknown', put_attributes: dict[str, str] | None = None)`
- **Summary:** Async client for external customer-provided cloud object stores.
- **Defined in:** `application_sdk/storage/cloud.py`

#### `ObjectStoreCheckResult`

- **Import:** `from application_sdk.storage import ObjectStoreCheckResult`
- **Signature:** `class ObjectStoreCheckResult(label: str, ...)`
- **Summary:** Structured outcome of a single object-store access probe.
- **Defined in:** `application_sdk/storage/preflight.py`

#### `ObjectStorePreflightError`

- **Import:** `from application_sdk.storage import ObjectStorePreflightError`
- **Signature:** `class ObjectStorePreflightError(message: str, ...)`
- **Summary:** One or more object stores failed the SDR boot-time access preflight.
- **Defined in:** `application_sdk/storage/errors.py`

#### `StorageBindingBrokenError`

- **Import:** `from application_sdk.storage import StorageBindingBrokenError`
- **Signature:** `class StorageBindingBrokenError(message: str, ...)`
- **Summary:** Dapr component YAML exists but has unresolvable configuration.
- **Defined in:** `application_sdk/storage/errors.py`

#### `StorageBindingNotFoundError`

- **Import:** `from application_sdk.storage import StorageBindingNotFoundError`
- **Signature:** `class StorageBindingNotFoundError(message: str, ...)`
- **Summary:** No Dapr component with the given name exists in the components directory.
- **Defined in:** `application_sdk/storage/errors.py`

#### `StorageConfigError`

- **Import:** `from application_sdk.storage import StorageConfigError`
- **Signature:** `class StorageConfigError(message: str, ...)`
- **Summary:** Storage configuration is invalid (e.g., missing bucket name).
- **Defined in:** `application_sdk/storage/errors.py`

#### `StorageError`

- **Import:** `from application_sdk.storage import StorageError`
- **Signature:** `class StorageError(message: str, ...)`
- **Summary:** Generic storage-subsystem failure (category=DEPENDENCY_UNAVAILABLE).
- **Defined in:** `application_sdk/storage/errors.py`

#### `StorageNotFoundError`

- **Import:** `from application_sdk.storage import StorageNotFoundError`
- **Signature:** `class StorageNotFoundError(message: str, ...)`
- **Summary:** Object or key not found in the store.
- **Defined in:** `application_sdk/storage/errors.py`

#### `StoragePermissionError`

- **Import:** `from application_sdk.storage import StoragePermissionError`
- **Signature:** `class StoragePermissionError(message: str, ...)`
- **Summary:** Bucket or object access denied.
- **Defined in:** `application_sdk/storage/errors.py`

### Functions

#### `check_object_store_access`

- **Import:** `from application_sdk.storage import check_object_store_access`
- **Signature:** `check_object_store_access(infra: InfrastructureContext | None)`
- **Summary:** Non-raising object-store access probe for the interactive SDR preflight.
- **Defined in:** `application_sdk/storage/preflight.py`

#### `create_local_store`

- **Import:** `from application_sdk.storage import create_local_store`
- **Signature:** `create_local_store(root_path: str | Path)`
- **Summary:** Create a ``LocalStore`` rooted at *root_path*.
- **Defined in:** `application_sdk/storage/factory.py`

#### `create_memory_store`

- **Import:** `from application_sdk.storage import create_memory_store`
- **Signature:** `create_memory_store()`
- **Summary:** Create an in-memory store suitable for unit tests.
- **Defined in:** `application_sdk/storage/factory.py`

#### `create_store_from_binding`

- **Import:** `from application_sdk.storage import create_store_from_binding`
- **Signature:** `create_store_from_binding(name: str, *, secrets: SecretMap | None = None, ...)`
- **Summary:** Create an obstore store from a Dapr component binding YAML file.
- **Defined in:** `application_sdk/storage/binding.py`

#### `create_store_from_binding_optional`

- **Import:** `from application_sdk.storage import create_store_from_binding_optional`
- **Signature:** `create_store_from_binding_optional(name: str, *, secrets: SecretMap | None = None, ...)`
- **Summary:** Create an obstore store from a Dapr component binding, or ``None`` if absent.
- **Defined in:** `application_sdk/storage/binding.py`

#### `create_store_from_binding_with_put_attrs`

- **Import:** `from application_sdk.storage import create_store_from_binding_with_put_attrs`
- **Signature:** `create_store_from_binding_with_put_attrs(name: str, *, secrets: SecretMap | None = None, ...)`
- **Summary:** Create an obstore store and any associated put attributes from a Dapr binding.
- **Defined in:** `application_sdk/storage/binding.py`

#### `delete`

- **Import:** `from application_sdk.storage import delete`
- **Signature:** `delete(key: str, store: BoundStore | ObjectStore | None = None, *, normalize: bool = True)`
- **Summary:** Delete the object at *key*.
- **Defined in:** `application_sdk/storage/ops.py`

#### `delete_prefix`

- **Import:** `from application_sdk.storage import delete_prefix`
- **Signature:** `delete_prefix(prefix: str, store: ObjectStore | None = None, *, normalize: bool = True)`
- **Summary:** Delete all objects whose key starts with *prefix*.
- **Defined in:** `application_sdk/storage/batch.py`

#### `download_file`

- **Import:** `from application_sdk.storage import download_file`
- **Signature:** `download_file(key: str, *, ...)`
- **Summary:** Stream-download *key* from the store to a local file.
- **Defined in:** `application_sdk/storage/ops.py`

#### `download_file_chunked`

- **Import:** `from application_sdk.storage import download_file_chunked`
- **Signature:** `download_file_chunked(key: str, *, ...)`
- **Summary:** Download *key* using parallel range GETs, writing chunks at fixed offsets.
- **Defined in:** `application_sdk/storage/chunked.py`

#### `download_prefix`

- **Import:** `from application_sdk.storage import download_prefix`
- **Signature:** `download_prefix(prefix: str, *, ...)`
- **Summary:** Download all objects under *prefix* to a local directory.
- **Defined in:** `application_sdk/storage/batch.py`

#### `exists`

- **Import:** `from application_sdk.storage import exists`
- **Signature:** `exists(key: str, store: BoundStore | ObjectStore | None = None, *, normalize: bool = True)`
- **Summary:** Return ``True`` if *key* exists in the store.
- **Defined in:** `application_sdk/storage/ops.py`

#### `get_file_meta`

- **Import:** `from application_sdk.storage import get_file_meta`
- **Signature:** `get_file_meta(key: str, store: BoundStore | ObjectStore | None = None, *, normalize: bool = True)`
- **Summary:** Return ``(size_bytes, e_tag)`` for *key*, or ``None`` if not found.
- **Defined in:** `application_sdk/storage/ops.py`

#### `is_sidecar_key`

- **Import:** `from application_sdk.storage import is_sidecar_key`
- **Signature:** `is_sidecar_key(key: str)`
- **Summary:** Return ``True`` if *key* is a SHA-256 sidecar rather than a data object.
- **Defined in:** `application_sdk/storage/batch.py`

#### `list_data_keys`

- **Import:** `from application_sdk.storage import list_data_keys`
- **Signature:** `list_data_keys(prefix: str = '', store: BoundStore | ObjectStore | None = None, *, normalize: bool = True)`
- **Summary:** List data object keys under *prefix*, excluding SHA-256 sidecars.
- **Defined in:** `application_sdk/storage/batch.py`

#### `list_data_keys_with_meta`

- **Import:** `from application_sdk.storage import list_data_keys_with_meta`
- **Signature:** `list_data_keys_with_meta(prefix: str = '', store: BoundStore | ObjectStore | None = None, *, normalize: bool = True)`
- **Summary:** Like :func:`list_data_keys`, but return ``(key, size_bytes, e_tag)`` tuples.
- **Defined in:** `application_sdk/storage/batch.py`

#### `list_keys`

- **Import:** `from application_sdk.storage import list_keys`
- **Signature:** `list_keys(prefix: str = '', *, ...)`
- **Summary:** List all object keys under *prefix*.
- **Defined in:** `application_sdk/storage/batch.py`

#### `list_keys_with_meta`

- **Import:** `from application_sdk.storage import list_keys_with_meta`
- **Signature:** `list_keys_with_meta(prefix: str = '', *, ...)`
- **Summary:** Like :func:`list_keys`, but return ``(key, size_bytes, e_tag)`` tuples.
- **Defined in:** `application_sdk/storage/batch.py`

#### `normalize_key`

- **Import:** `from application_sdk.storage import normalize_key`
- **Signature:** `normalize_key(key: str)`
- **Summary:** Normalise a local or object-store path into a clean object-store key.
- **Defined in:** `application_sdk/storage/ops.py`

#### `put_json`

- **Import:** `from application_sdk.storage import put_json`
- **Signature:** `put_json(key: str, obj: JsonValue, store: BoundStore | ObjectStore | None = None, *, normalize: bool = True)`
- **Summary:** Serialise *obj* to JSON and write to *key*.
- **Defined in:** `application_sdk/storage/ops.py`

#### `read_binding_secret_refs`

- **Import:** `from application_sdk.storage import read_binding_secret_refs`
- **Signature:** `read_binding_secret_refs(name: str, *, components_dir: Path | str = Path('./components'))`
- **Summary:** Report the ``secretKeyRef`` entries of the component named *name*.
- **Defined in:** `application_sdk/storage/binding.py`

#### `set_fetched_binding_secrets`

- **Import:** `from application_sdk.storage import set_fetched_binding_secrets`
- **Signature:** `set_fetched_binding_secrets(name: str, secrets: SecretMap)`
- **Summary:** Publish the secrets startup fetched for *name* to later sync callers.
- **Defined in:** `application_sdk/storage/binding.py`

#### `upload_file`

- **Import:** `from application_sdk.storage import upload_file`
- **Signature:** `upload_file(key: str, *, ...)`
- **Summary:** Stream-upload a local file to *key* in the store.
- **Defined in:** `application_sdk/storage/ops.py`

#### `upload_file_from_bytes`

- **Import:** `from application_sdk.storage import upload_file_from_bytes`
- **Signature:** `upload_file_from_bytes(key: str, content: bytes, store: ObjectStore | None = None, *, normalize: bool = True)`
- **Summary:** Upload bytes directly to *key* in the store.
- **Defined in:** `application_sdk/storage/batch.py`

#### `upload_prefix`

- **Import:** `from application_sdk.storage import upload_prefix`
- **Signature:** `upload_prefix(local_dir: str | Path, *, ...)`
- **Summary:** Upload all files under *local_dir* to the store under *prefix*.
- **Defined in:** `application_sdk/storage/batch.py`

#### `verify_object_store_access`

- **Import:** `from application_sdk.storage import verify_object_store_access`
- **Signature:** `verify_object_store_access(infra: InfrastructureContext)`
- **Summary:** In SDR mode, verify read+write access to every configured object store.
- **Defined in:** `application_sdk/storage/preflight.py`

### Constants and Enums

#### `SecretMap`

- **Import:** `from application_sdk.storage import SecretMap`
- **Signature:** `SecretMap`
- **Summary:** _(no docstring)_
- **Defined in:** `application_sdk/storage/binding.py`

#### `SIDECAR_SUFFIX`

- **Import:** `from application_sdk.storage import SIDECAR_SUFFIX`
- **Signature:** `SIDECAR_SUFFIX`
- **Summary:** _(no docstring)_
- **Defined in:** `application_sdk/storage/batch.py`

## `application_sdk.templates`

SQL metadata extractor templates and their contracts

### Classes

#### `BaseMetadataExtractor`

- **Import:** `from application_sdk.templates import BaseMetadataExtractor`
- **Signature:** `class BaseMetadataExtractor`
- **Summary:** Base App for all metadata extraction connectors.
- **Defined in:** `application_sdk/templates/base_metadata_extractor.py`

#### `IncrementalSqlMetadataExtractor`

- **Import:** `from application_sdk.templates import IncrementalSqlMetadataExtractor`
- **Signature:** `class IncrementalSqlMetadataExtractor`
- **Summary:** Base class for incremental SQL metadata extraction apps.
- **Defined in:** `application_sdk/templates/incremental_sql_metadata_extractor.py`

#### `SqlApp`

- **Import:** `from application_sdk.templates import SqlApp`
- **Signature:** `class SqlApp`
- **Summary:** Consolidated SQL metadata extraction App.
- **Defined in:** `application_sdk/templates/sql_app.py`

#### `SqlMetadataExtractor`

- **Import:** `from application_sdk.templates import SqlMetadataExtractor`
- **Signature:** `class SqlMetadataExtractor`
- **Summary:** Base class for SQL metadata extraction apps.
- **Defined in:** `application_sdk/templates/sql_metadata_extractor.py`

#### `SqlQueryExtractor`

- **Import:** `from application_sdk.templates import SqlQueryExtractor`
- **Signature:** `class SqlQueryExtractor`
- **Summary:** Abstract base class for SQL query extraction apps.
- **Defined in:** `application_sdk/templates/sql_query_extractor.py`

## `application_sdk.testing`

Test infrastructure — mocks, fixtures, hypothesis strategies, integration helpers

### Classes

#### `MockBinding`

- **Import:** `from application_sdk.testing import MockBinding`
- **Signature:** `class MockBinding(name: str = 'mock')`
- **Summary:** In-memory binding with call-tracking for unit tests.
- **Defined in:** `application_sdk/testing/mocks.py`

#### `MockCredentialStore`

- **Import:** `from application_sdk.testing import MockCredentialStore`
- **Signature:** `class MockCredentialStore()`
- **Summary:** In-memory credential store for unit tests.
- **Defined in:** `application_sdk/testing/mocks.py`

#### `MockHeartbeatController`

- **Import:** `from application_sdk.testing import MockHeartbeatController`
- **Signature:** `class MockHeartbeatController`
- **Summary:** NoopHeartbeatController with a public call-tracking API.
- **Defined in:** `application_sdk/testing/mocks.py`

#### `MockPubSub`

- **Import:** `from application_sdk.testing import MockPubSub`
- **Signature:** `class MockPubSub()`
- **Summary:** In-memory pub/sub with call-tracking for unit tests.
- **Defined in:** `application_sdk/testing/mocks.py`

#### `MockSecretStore`

- **Import:** `from application_sdk.testing import MockSecretStore`
- **Signature:** `class MockSecretStore(secrets: dict[str, str] | None = None)`
- **Summary:** In-memory secret store with call-tracking for unit tests.
- **Defined in:** `application_sdk/testing/mocks.py`

#### `MockStateStore`

- **Import:** `from application_sdk.testing import MockStateStore`
- **Signature:** `class MockStateStore()`
- **Summary:** In-memory state store with call-tracking for unit tests.
- **Defined in:** `application_sdk/testing/mocks.py`

### Functions

#### `app_context`

- **Import:** `from application_sdk.testing import app_context`
- **Signature:** `app_context(mock_state_store: MockStateStore, mock_secret_store: MockSecretStore)`
- **Summary:** AppContext wired with MockStateStore and MockSecretStore.
- **Defined in:** `application_sdk/testing/fixtures.py`

#### `clean_app_registry`

- **Import:** `from application_sdk.testing import clean_app_registry`
- **Signature:** `clean_app_registry()`
- **Summary:** AppRegistry reset before and after each test.
- **Defined in:** `application_sdk/testing/fixtures.py`

#### `clean_task_registry`

- **Import:** `from application_sdk.testing import clean_task_registry`
- **Signature:** `clean_task_registry()`
- **Summary:** TaskRegistry reset before and after each test.
- **Defined in:** `application_sdk/testing/fixtures.py`

#### `mock_binding`

- **Import:** `from application_sdk.testing import mock_binding`
- **Signature:** `mock_binding()`
- **Summary:** Fresh MockBinding instance.
- **Defined in:** `application_sdk/testing/fixtures.py`

#### `mock_credential_store`

- **Import:** `from application_sdk.testing import mock_credential_store`
- **Signature:** `mock_credential_store()`
- **Summary:** Fresh MockCredentialStore instance.
- **Defined in:** `application_sdk/testing/fixtures.py`

#### `mock_heartbeat`

- **Import:** `from application_sdk.testing import mock_heartbeat`
- **Signature:** `mock_heartbeat()`
- **Summary:** Fresh MockHeartbeatController instance.
- **Defined in:** `application_sdk/testing/fixtures.py`

#### `mock_pubsub`

- **Import:** `from application_sdk.testing import mock_pubsub`
- **Signature:** `mock_pubsub()`
- **Summary:** Fresh MockPubSub instance.
- **Defined in:** `application_sdk/testing/fixtures.py`

#### `mock_secret_store`

- **Import:** `from application_sdk.testing import mock_secret_store`
- **Signature:** `mock_secret_store()`
- **Summary:** Fresh MockSecretStore instance.
- **Defined in:** `application_sdk/testing/fixtures.py`

#### `mock_state_store`

- **Import:** `from application_sdk.testing import mock_state_store`
- **Signature:** `mock_state_store()`
- **Summary:** Fresh MockStateStore instance.
- **Defined in:** `application_sdk/testing/fixtures.py`

## Contracts

Strongly-typed Pydantic models for SDK methods. Contracts in `application_sdk.contracts` inherit from `Input`/`Output`; contracts in `application_sdk.handler.contracts` are direct `pydantic.BaseModel` subclasses.

### `application_sdk.contracts`

#### `ConnectionRef`

- **Import:** `from application_sdk.contracts import ConnectionRef`
- **Summary:** Typed replacement for ``connection: dict[str, Any]`` in Temporal contracts.
- **Fields:**
  - `type_name: str` `= Field(default='Connection')`
  - `attributes: ConnectionAttributes` `= Field(default_factory=ConnectionAttributes)`
- **Defined in:** `application_sdk/contracts/types.py`

#### `ContractMetadata`

- **Import:** `from application_sdk.contracts import ContractMetadata`
- **Summary:** Metadata about a contract for registration and discovery.
- **Fields:**
  - `name: str`
  - `version: str`
  - `cls: type`
  - `is_input: bool`
  - `schema_hash: str | None`
  - `deprecated: bool` `= False`
  - `deprecation_message: str | None`
- **Defined in:** `application_sdk/contracts/base.py`

#### `ContractValidationError`

- **Import:** `from application_sdk.contracts import ContractValidationError`
- **Summary:** Deprecated: use ``application_sdk.errors.InvalidInputError`` — removed in v4.0.
- **Fields:**
  - `DEFAULT_ERROR_CODE: ClassVar[ErrorCode]` `= CONTRACT_VALIDATION`
  - `code: ClassVar[str]` `= 'INVALID_INPUT_CONTRACT_VALIDATION'`
  - `error_code: ErrorCode`
- **Defined in:** `application_sdk/contracts/base.py`

#### `DownloadInput`

- **Import:** `from application_sdk.contracts import DownloadInput`
- **Summary:** Input for ``App.download``.
- **Fields:**
  - `storage_path: str` `= ''`
  - `local_path: str | None`
  - `ref: FileReference | None`
  - `skip_if_exists: bool` `= False`
- **Defined in:** `application_sdk/contracts/storage.py`

#### `DownloadOutput`

- **Import:** `from application_sdk.contracts import DownloadOutput`
- **Summary:** Output from ``App.download``.
- **Fields:**
  - `ref: FileReference` `= Field(default_factory=FileReference)`
  - `synced: bool` `= False`
  - `reason: str` `= ''`
- **Defined in:** `application_sdk/contracts/storage.py`

#### `FileReference`

- **Import:** `from application_sdk.contracts import FileReference`
- **Summary:** Reference to externally-stored data (for large payloads).
- **Fields:**
  - `local_path: str | None`
  - `storage_path: str | None`
  - `is_durable: bool` `= False`
  - `file_count: int` `= 1`
  - `tier: StorageTier` `= StorageTier.TRANSIENT`
  - `auto_materialize: bool` `= True`
- **Defined in:** `application_sdk/contracts/types.py`

#### `GitReference`

- **Import:** `from application_sdk.contracts import GitReference`
- **Summary:** Reference to a Git repository for workflow inputs.
- **Fields:**
  - `repo_url: str`
  - `branch: str` `= 'main'`
  - `path: str` `= ''`
  - `tag: str` `= ''`
  - `commit: str` `= ''`
  - `credential: CredentialRef | None`
- **Defined in:** `application_sdk/contracts/types.py`

#### `HeartbeatDetails`

- **Import:** `from application_sdk.contracts import HeartbeatDetails`
- **Summary:** Base class for heartbeat progress contracts.
- **Defined in:** `application_sdk/contracts/base.py`

#### `Input`

- **Import:** `from application_sdk.contracts import Input`
- **Summary:** Base class for all input contracts (Apps and tasks).
- **Fields:**
  - `workflow_id: str` `= ''` — Temporal workflow ID for the current run.
  - `correlation_id: str` `= ''` — Caller-supplied correlation ID for tracing across systems.
  - `app_name: str` `= ''` — Per-entrypoint app name stamped into node args by the contract toolkit
- **Defined in:** `application_sdk/contracts/base.py`

#### `Output`

- **Import:** `from application_sdk.contracts import Output`
- **Summary:** Base class for all output contracts (Apps and tasks).
- **Fields:**
  - `status: OutputStatus` `= OutputStatus.SUCCESS` — Coarse-grained run outcome — see :class:`OutputStatus`. Defaults to
  - `metrics: dict[str, Any] | None` — Metrics collected by the OutputInterceptor (e.g. assets-extracted).
  - `artifacts: dict[str, Any] | None` — Artifact references collected by the OutputInterceptor.
- **Defined in:** `application_sdk/contracts/base.py`

#### `PublishInputMixin`

- **Import:** `from application_sdk.contracts import PublishInputMixin`
- **Summary:** Mixin for apps whose workflow output feeds the Publish App.
- **Fields:**
  - `PUBLISH_STATE_PREFIX_TEMPLATE: ClassVar[str]` `= 'persistent-artifacts/apps/atlan-publish-app/state/{connection_qn}/publish-state'`
  - `STAGING_DATA_PREFIX_TEMPLATE: ClassVar[str]` `= 'persistent-artifacts/apps/atlan-publish-app/state/{connection_qn}'`
  - `CURRENT_STATE_PREFIX_TEMPLATE: ClassVar[str]` `= 'argo-artifacts/{connection_qn}/current-state'`
  - `output_path: str` `= ''` — SDK output path. Used to derive ``transformed_data_prefix``.
  - `output_prefix: str` `= ''` — Prefix to strip from ``output_path`` before deriving transformed prefix.
  - `transformed_data_prefix: str` `= ''` — Object-store-relative path to transformed data files.
  - `connection_qualified_name: str` `= ''` — Qualified name of the Atlan connection.
  - `publish_state_prefix: str` `= ''` — Auto-derived from ``connection_qualified_name`` if not set.
  - `staging_data_prefix: str` `= ''` — Auto-derived from ``connection_qualified_name`` if not set.
  - `current_state_prefix: str` `= ''` — Auto-derived from ``connection_qualified_name`` if not set.
- **Defined in:** `application_sdk/contracts/base.py`

#### `Record`

- **Import:** `from application_sdk.contracts import Record`
- **Summary:** Base class for domain records passed between Apps.
- **Fields:**
  - `id: str` — Unique identifier for this record.
- **Defined in:** `application_sdk/contracts/base.py`

#### `UploadInput`

- **Import:** `from application_sdk.contracts import UploadInput`
- **Summary:** Input for ``App.upload``.
- **Fields:**
  - `local_path: str` `= ''`
  - `ref: FileReference | None`
  - `storage_path: str | None`
  - `storage_subdir: str | None`
  - `tier: StorageTier` `= StorageTier.RETAINED`
  - `skip_if_exists: bool` `= False`
  - `raise_on_empty: bool` `= False`
- **Defined in:** `application_sdk/contracts/storage.py`

#### `UploadOutput`

- **Import:** `from application_sdk.contracts import UploadOutput`
- **Summary:** Output from ``App.upload``.
- **Fields:**
  - `ref: FileReference` `= Field(default_factory=FileReference)`
  - `synced: bool` `= False`
  - `reason: str` `= ''`
- **Defined in:** `application_sdk/contracts/storage.py`

### `application_sdk.handler.contracts`

#### `AgentCredentialSpec`

- **Import:** `from application_sdk.handler.contracts import AgentCredentialSpec`
- **Summary:** Typed envelope for an agent-shape credential payload.
- **Fields:**
  - `agent_name: str` `= Field(default='', alias='agent-name')` — Name of the Secure Agent instance. Used by ``is_populated()`` to
  - `secret_manager: str` `= Field(default='', alias='secret-manager')` — Secret store backend: ``awssecretmanager``, ``azurekeyvault``,
  - `secret_path: str` `= Field(default='', alias='secret-path')` — Path / ARN / name of the secret in the external secret manager.
  - `auth_type: str` `= Field(default='', alias='auth-type')` — Authentication strategy: ``basic``, ``noauth``, ``gcp-wif``,
  - `host: str` `= ''` — Database / service hostname. Required for JDBC connectors.
  - `port: int` `= 0` — Database / service port.
  - `connect_by: str` `= Field(default='', alias='connectBy')` — Connection method hint (``host``, ``url``, etc.).
  - `agent_type: str` `= Field(default='', alias='agent-type')` — Agent framework version. ``new-app-framework`` for SA 2.0 agents.
  - `key_type: str` `= Field(default='', alias='key-type')` — Secret key layout: ``multi-key``, ``single-key``, etc.
  - `aws_region: str` `= Field(default='', alias='aws-region')` — AWS region for the secret manager.
  - `aws_auth_method: str` `= Field(default='', alias='aws-auth-method')` — AWS auth method: ``iam``, ``iam-assume-role``, ``access-key``.
  - `azure_auth_method: str` `= Field(default='', alias='azure-auth-method')` — Azure auth method: ``managed_identity``, ``service_principal``.
- **Defined in:** `application_sdk/credentials/spec.py`

#### `ApiMetadataObject`

- **Import:** `from application_sdk.handler.contracts import ApiMetadataObject`
- **Summary:** A node for the **apitree** frontend widget.
- **Fields:**
  - `value: str` — Unique identifier for this node (used as the selection value).
  - `title: str` — Display label shown in the tree UI.
  - `node_type: str` `= ''` — Optional type discriminator (e.g., 'tag', 'project', 'folder').
  - `children: list[ApiMetadataObject]` `= []` — Child nodes (empty for leaf nodes).
- **Defined in:** `application_sdk/handler/contracts.py`

#### `ApiMetadataOutput`

- **Import:** `from application_sdk.handler.contracts import ApiMetadataOutput`
- **Summary:** Metadata output for BI / API connectors (apitree widget).
- **Fields:**
  - `objects: list[ApiMetadataObject]` `= []` — Top-level tree nodes.
- **Defined in:** `application_sdk/handler/contracts.py`

#### `AuthInput`

- **Import:** `from application_sdk.handler.contracts import AuthInput`
- **Summary:** Input for the test_auth handler operation.
- **Fields:**
  - `credentials: list[HandlerCredential]` `= []` — Credentials to authenticate with.
  - `connection_id: str` `= ''` — Optional connection ID for context.
  - `entrypoint: str` `= ''` — Bare entry-point name (e.g. ``asset-export-advanced``) — authoritative
  - `entrypoint_ref: str` `= Field(default='', validation_alias=(AliasChoices('entrypoint_ref', 'connector')), serialization_alias='connector')` — App-qualified entry-point reference (``{app_name}-{entrypoint.name}``).
  - `timeout_seconds: int` `= 30` — Maximum seconds to wait for auth response.
  - `agent_json: AgentCredentialSpec | None` `= Field(default=None, validation_alias=(AliasChoices('agent_json', 'agentJson', 'agent-json')))` — Optional agent-shape credential *reference* (SDR / customer-infra only).
- **Defined in:** `application_sdk/handler/contracts.py`

#### `AuthOutput`

- **Import:** `from application_sdk.handler.contracts import AuthOutput`
- **Summary:** Output from the test_auth handler operation.
- **Fields:**
  - `status: AuthStatus` — Authentication result status.
  - `message: str` `= ''` — Human-readable status message.
  - `identities: list[str]` `= []` — Verified identities (e.g., usernames, roles).
  - `scopes: list[str]` `= []` — Authorized scopes or permissions.
  - `expires_at: str` `= ''` — ISO-8601 expiry timestamp (empty if no expiry).
- **Defined in:** `application_sdk/handler/contracts.py`

#### `CloudEventEnvelope`

- **Import:** `from application_sdk.handler.contracts import CloudEventEnvelope`
- **Summary:** Minimal representation of a Dapr CloudEvent envelope.
- **Fields:**
  - `id: str`
  - `source: str`
  - `specversion: str`
  - `type: str`
  - `time: str`
  - `topic: str`
  - `data: dict[str, Any]`
  - `datacontenttype: str` `= 'application/json'`
- **Defined in:** `application_sdk/handler/contracts.py`

#### `EventFilterRule`

- **Import:** `from application_sdk.handler.contracts import EventFilterRule`
- **Summary:** A single filter rule for matching incoming Dapr cloud events.
- **Fields:**
  - `path: str` — CEL path to evaluate (e.g., 'event.data.type').
  - `operator: str` — Comparison operator (e.g., '==').
  - `value: str` — Expected value (e.g., 'metadata_extraction').
- **Defined in:** `application_sdk/handler/contracts.py`

#### `EventTriggerConfig`

- **Import:** `from application_sdk.handler.contracts import EventTriggerConfig`
- **Summary:** Configuration for an event-triggered workflow.
- **Fields:**
  - `event_id: str` — Unique identifier used as the route segment (e.g., 'my-trigger').
  - `event_type: str` — Dapr topic / event type (e.g., 'metadata_extraction').
  - `event_name: str` — Logical event name used in subscription filter rules.
  - `event_filters: list[EventFilterRule]` `= []` — Additional CEL filter rules applied to the event.
- **Defined in:** `application_sdk/handler/contracts.py`

#### `FailureDetails`

- **Import:** `from application_sdk.handler.contracts import FailureDetails`
- **Summary:** Pydantic envelope serialized into ``ApplicationError.details=[…]``.
- **Fields:**
  - `category: FailureCategory`
  - `code: str`
  - `retryable: bool`
  - `audience: Audience` `= Audience.APP_OWNER`
  - `message: str`
  - `suggested_action: str | None`
  - `evidence: dict[str, Any]` `= Field(default_factory=dict)`
  - `app_name: str | None`
  - `run_id: str | None`
  - `cause_repr: str | None`
- **Defined in:** `application_sdk/errors/wire.py`

#### `FileUploadResponse`

- **Import:** `from application_sdk.handler.contracts import FileUploadResponse`
- **Summary:** Response from a file upload operation.
- **Fields:**
  - `id: str` `= ''`
  - `version: str` `= '1'`
  - `is_active: bool` `= True`
  - `created_at: int` `= 0`
  - `updated_at: int` `= 0`
  - `file_name: str` `= ''`
  - `raw_name: str` `= ''`
  - `key: str` `= ''`
  - `extension: str` `= ''`
  - `content_type: str` `= ''`
  - `file_size: int` `= 0`
  - `is_uploaded: bool` `= False`
  - `uploaded_at: str` `= ''`
- **Defined in:** `application_sdk/handler/contracts.py`

#### `HandlerCredential`

- **Import:** `from application_sdk.handler.contracts import HandlerCredential`
- **Summary:** A single credential key-value pair for HTTP handler inputs.
- **Fields:**
  - `key: str` — Credential key (e.g., 'api_key', 'username').
  - `value: str` — Credential value (sensitive — never log this directly).
- **Defined in:** `application_sdk/handler/contracts.py`

#### `MetadataInput`

- **Import:** `from application_sdk.handler.contracts import MetadataInput`
- **Summary:** Input for the fetch_metadata handler operation.
- **Fields:**
  - `credentials: list[HandlerCredential]` `= []` — Credentials to use for metadata discovery.
  - `entrypoint: str` `= ''` — Bare entry-point name (e.g. ``asset-export-advanced``) — authoritative
  - `entrypoint_ref: str` `= Field(default='', validation_alias=(AliasChoices('entrypoint_ref', 'connector')), serialization_alias='connector')` — App-qualified entry-point reference (``{app_name}-{entrypoint.name}``).
  - `metadata_template_key: str` `= Field(default='', validation_alias=(AliasChoices('metadata_template_key', 'metadataTemplateKey', 'type')))` — Metadata source routing key for multi-source metadata widgets (e.g.
  - `connection_config: BaseConnectionConfig` `= Field(default_factory=BaseConnectionConfig)` — Connection configuration.
  - `object_filter: str` `= ''` — Filter pattern (e.g., 'public.*', 'mydb.myschema.*').
  - `include_fields: bool` `= True` — Whether to include field/column details.
  - `max_objects: int` `= 1000` — Maximum number of objects to return.
  - `timeout_seconds: int` `= 120` — Maximum seconds to wait for metadata fetch.
  - `agent_json: AgentCredentialSpec | None` `= Field(default=None, validation_alias=(AliasChoices('agent_json', 'agentJson', 'agent-json')))` — Optional agent-shape credential *reference* (SDR / customer-infra only).
- **Defined in:** `application_sdk/handler/contracts.py`

#### `MetadataOutput`

- **Import:** `from application_sdk.handler.contracts import MetadataOutput`
- **Summary:** Base output from the fetch_metadata handler operation.
- **Fields:**
  - `objects: list[Any]` `= []` — Metadata objects. Subclasses narrow this type.
- **Defined in:** `application_sdk/handler/contracts.py`

#### `PreflightCheck`

- **Import:** `from application_sdk.handler.contracts import PreflightCheck`
- **Summary:** Result of a single preflight check.
- **Fields:**
  - `name: str` `= Field(..., min_length=1)` — Check name (e.g., 'connectivity', 'permissions').
  - `passed: bool` `= False` — Whether the check passed.
  - `message: str` `= ''` — Deprecated: prefer :attr:`error`. Human-facing line shown when ``error``
  - `error: FailureDetails | None` — Typed failure for a failed check — set only on failed checks.
  - `duration_ms: float` `= 0.0` — How long the check took in milliseconds.
  - `resolved_message: str` — Message under the precedence rule: a failed check's ``error`` wins.
  - `resolved_suggested_action: str` — Suggested action from a failed check's ``error``; empty otherwise.
- **Defined in:** `application_sdk/handler/contracts.py`

#### `PreflightInput`

- **Import:** `from application_sdk.handler.contracts import PreflightInput`
- **Summary:** Input for the preflight_check handler operation.
- **Fields:**
  - `credentials: list[HandlerCredential]` `= []` — Credentials to use during preflight.
  - `credentials_by_name: dict[str, list[HandlerCredential]]` `= Field(default_factory=dict)` — Resolved credentials grouped by ref name for multi-credential apps.
  - `entrypoint: str` `= ''` — Bare entry-point name (e.g. ``asset-export-advanced``) — authoritative
  - `entrypoint_ref: str` `= Field(default='', validation_alias=(AliasChoices('entrypoint_ref', 'connector')), serialization_alias='connector')` — App-qualified entry-point reference (``{app_name}-{entrypoint.name}``).
  - `connection_config: BaseConnectionConfig` `= Field(default_factory=BaseConnectionConfig)` — Connection configuration (host, port, database, etc.).
  - `metadata: BaseMetadataConfig` `= Field(default_factory=BaseMetadataConfig)` — Form-level metadata forwarded by heracles alongside the credential.
  - `checks_to_run: list[str]` `= []` — Specific checks to run (empty = run all).
  - `timeout_seconds: int` `= 60` — Maximum seconds the handler has to run all checks.
  - `agent_json: AgentCredentialSpec | None` `= Field(default=None, validation_alias=(AliasChoices('agent_json', 'agentJson', 'agent-json')))` — Optional agent-shape credential *reference* (SDR / customer-infra only).
- **Defined in:** `application_sdk/handler/contracts.py`

#### `PreflightOutput`

- **Import:** `from application_sdk.handler.contracts import PreflightOutput`
- **Summary:** Output from the preflight_check handler operation.
- **Fields:**
  - `status: PreflightStatus` — Overall verdict — decides the gate. ``NOT_READY`` blocks the run only in
  - `checks: list[PreflightCheck]` `= []` — Individual check results (display + failure attribution).
  - `message: str` `= ''` — Human-readable summary. Seeds the gate's abort reason when set.
  - `total_duration_ms: float` `= 0.0` — Total time for all checks in milliseconds.
- **Defined in:** `application_sdk/handler/contracts.py`

#### `SqlMetadataObject`

- **Import:** `from application_sdk.handler.contracts import SqlMetadataObject`
- **Summary:** A row for the **sqltree** frontend widget.
- **Fields:**
  - `TABLE_CATALOG: str` — Database / catalog name.
  - `TABLE_SCHEMA: str` — Schema name.
- **Defined in:** `application_sdk/handler/contracts.py`

#### `SqlMetadataOutput`

- **Import:** `from application_sdk.handler.contracts import SqlMetadataOutput`
- **Summary:** Metadata output for SQL connectors (sqltree widget).
- **Fields:**
  - `objects: list[SqlMetadataObject]` `= []` — Discovered catalog/schema pairs.
- **Defined in:** `application_sdk/handler/contracts.py`

#### `SubscriptionConfig`

- **Import:** `from application_sdk.handler.contracts import SubscriptionConfig`
- **Summary:** Configuration for a Dapr pub/sub subscription with a custom handler.
- **Fields:**
  - `component_name: str` — Dapr pubsub component name.
  - `topic: str` — Topic to subscribe to.
  - `route: str` — Route path segment served at /subscriptions/v1/{route}.
  - `handler: Callable[..., Awaitable[Any]]` — Async callback invoked when a message arrives on this topic.
  - `bulk_enabled: bool` `= False` — Enable bulk subscribe for higher throughput.
  - `bulk_max_messages: int` `= 100` — Maximum messages per bulk batch.
  - `bulk_max_await_ms: int` `= 40` — Maximum milliseconds to wait for a full bulk batch.
  - `dead_letter_topic: str | None` — Optional dead-letter topic for failed messages.
- **Defined in:** `application_sdk/handler/contracts.py`

### `application_sdk.templates.contracts`

#### `ExecuteColumnBatchInput`

- **Import:** `from application_sdk.templates.contracts import ExecuteColumnBatchInput`
- **Summary:** Input for executing a single incremental column batch.
- **Fields:**
  - `batch_index: int` `= 0` — Zero-based index of this batch within the total.
  - `total_batches: int` `= 1` — Total number of batches.
  - `batches_s3_prefix: str` `= ''` — S3 prefix where the batch JSON files are stored.
  - `application_name: str` `= ''`
- **Defined in:** `application_sdk/templates/contracts/incremental_sql.py`

#### `ExecuteColumnBatchOutput`

- **Import:** `from application_sdk.templates.contracts import ExecuteColumnBatchOutput`
- **Summary:** Output from executing a single incremental column batch.
- **Fields:**
  - `batch_index: int` `= 0`
  - `records: int` `= 0`
  - `status: str` `= ''`
- **Defined in:** `application_sdk/templates/contracts/incremental_sql.py`

#### `ExtractionInput`

- **Import:** `from application_sdk.templates.contracts import ExtractionInput`
- **Summary:** Top-level input for a SQL metadata extraction run.
- **Fields:**
  - `preflight_credential_refs: ClassVar[dict[str, str]]` `= {}` — Opt-in map of ``{ref_name: guid_field}`` for multi-credential apps.
  - `workflow_id: str` `= ''` — Temporal workflow ID for this run.
  - `connection: ConnectionRef` `= Field(default_factory=ConnectionRef)` — Typed connection reference (qualified name, name, admin users, etc.).
  - `credential_guid: str` `= ''` — GUID of credentials stored in the secret store.
  - `credential_ref: CredentialRef | None` — Typed credential reference — preferred over credential_guid for new apps.
  - `extraction_method: str` `= ''` — ``"agent"`` or ``"direct"``. Empty defaults to direct.
  - `agent_json: AgentCredentialSpec | None` — Typed agent credential spec. Non-None when extraction_method is agent.
  - `output_prefix: str` `= ''` — Object store prefix for all output artifacts.
  - `output_path: str` `= ''` — Local or object store path for output files.
  - `exclude_filter: FilterMap | str` `= Field(default='', json_schema_extra=_FILTER_FIELD_JSON_SCHEMA_EXTRA)` — Filter for excluding schemas/tables.
  - `include_filter: FilterMap | str` `= Field(default='', json_schema_extra=_FILTER_FIELD_JSON_SCHEMA_EXTRA)` — Filter for including schemas/tables.
  - `temp_table_regex: Annotated[str, Field(pattern=SAFE_FILTER_PATTERN)]` `= ''` — Regex pattern identifying temporary tables.
  - `source_tag_prefix: str` `= ''` — Tag prefix for source-level metadata.
- **Defined in:** `application_sdk/templates/contracts/sql_metadata.py`

#### `ExtractionOutput`

- **Import:** `from application_sdk.templates.contracts import ExtractionOutput`
- **Summary:** Top-level output from a SQL metadata extraction run.
- **Fields:**
  - `workflow_id: str` `= ''`
  - `success: bool` `= False`
  - `databases_extracted: int` `= 0`
  - `schemas_extracted: int` `= 0`
  - `tables_extracted: int` `= 0`
  - `views_extracted: int` `= 0`
  - `columns_extracted: int` `= 0`
  - `procedures_extracted: int` `= 0`
  - `processes_extracted: int` `= 0`
  - `records_uploaded: int` `= 0`
  - `error: str` `= ''`
  - `output_path: str` `= ''` — Resolved local base path used during extraction. Subclasses that need
- **Defined in:** `application_sdk/templates/contracts/sql_metadata.py`

#### `ExtractionTaskInput`

- **Import:** `from application_sdk.templates.contracts import ExtractionTaskInput`
- **Summary:** Fields shared by all per-task inputs derived from ExtractionInput.
- **Fields:**
  - `workflow_id: str` `= ''`
  - `connection: ConnectionRef` `= Field(default_factory=ConnectionRef)`
  - `credential_guid: str` `= ''`
  - `credential_ref: CredentialRef | None`
  - `output_prefix: str` `= ''`
  - `output_path: str` `= ''`
  - `exclude_filter: FilterMap | str` `= Field(default='', json_schema_extra=_FILTER_FIELD_JSON_SCHEMA_EXTRA)`
  - `include_filter: FilterMap | str` `= Field(default='', json_schema_extra=_FILTER_FIELD_JSON_SCHEMA_EXTRA)`
  - `temp_table_regex: Annotated[str, Field(pattern=SAFE_FILTER_PATTERN)]` `= ''`
  - `source_tag_prefix: str` `= ''`
- **Defined in:** `application_sdk/templates/contracts/sql_metadata.py`

#### `ExtractionTaskOutput`

- **Import:** `from application_sdk.templates.contracts import ExtractionTaskOutput`
- **Summary:** Output from a per-entity ``extract_*`` task.
- **Fields:**
  - `typename: str` `= ''`
  - `total_record_count: int` `= 0`
  - `raw_file: FileReference | None` — ``FileReference`` to the extract's raw output.
- **Defined in:** `application_sdk/templates/contracts/sql_metadata.py`

#### `FetchColumnsIncrementalInput`

- **Import:** `from application_sdk.templates.contracts import FetchColumnsIncrementalInput`
- **Summary:** Input for the incremental fetch_columns task.
- **Defined in:** `application_sdk/templates/contracts/incremental_sql.py`

#### `FetchColumnsInput`

- **Import:** `from application_sdk.templates.contracts import FetchColumnsInput`
- **Summary:** Input for fetching columns from the source.
- **Defined in:** `application_sdk/templates/contracts/sql_metadata.py`

#### `FetchColumnsOutput`

- **Import:** `from application_sdk.templates.contracts import FetchColumnsOutput`
- **Summary:** Output from fetching columns.
- **Fields:**
  - `chunk_count: int` `= 0`
  - `total_record_count: int` `= 0`
- **Defined in:** `application_sdk/templates/contracts/sql_metadata.py`

#### `FetchDatabasesInput`

- **Import:** `from application_sdk.templates.contracts import FetchDatabasesInput`
- **Summary:** Input for fetching databases from the source.
- **Defined in:** `application_sdk/templates/contracts/sql_metadata.py`

#### `FetchDatabasesOutput`

- **Import:** `from application_sdk.templates.contracts import FetchDatabasesOutput`
- **Summary:** Output from fetching databases.
- **Fields:**
  - `databases: Annotated[list[str], MaxItems(10000)]` `= Field(default_factory=list)`
  - `chunk_count: int` `= 0`
  - `total_record_count: int` `= 0`
- **Defined in:** `application_sdk/templates/contracts/sql_metadata.py`

#### `FetchIncrementalMarkerInput`

- **Import:** `from application_sdk.templates.contracts import FetchIncrementalMarkerInput`
- **Summary:** Input for the fetch_incremental_marker task.
- **Fields:**
  - `connection_qualified_name: str` `= ''` — Connection qualified name used to locate the persistent marker file.
  - `application_name: str` `= ''` — Application name for S3 path resolution.
  - `existing_marker: str | None` — Pre-existing marker value (e.g., from a manual workflow override).
  - `prepone_enabled: bool` `= True` — Whether to move the marker back by ``prepone_hours``.
  - `prepone_hours: float` `= 3.0` — Hours to subtract from the marker when preponing is enabled.
- **Defined in:** `application_sdk/templates/contracts/incremental_sql.py`

#### `FetchIncrementalMarkerOutput`

- **Import:** `from application_sdk.templates.contracts import FetchIncrementalMarkerOutput`
- **Summary:** Output from the fetch_incremental_marker task.
- **Fields:**
  - `marker_timestamp: str` `= ''` — Processed marker from the previous run; empty on the first run.
  - `next_marker_timestamp: str` `= ''` — New marker timestamp generated for the current run.
- **Defined in:** `application_sdk/templates/contracts/incremental_sql.py`

#### `FetchProceduresInput`

- **Import:** `from application_sdk.templates.contracts import FetchProceduresInput`
- **Summary:** Input for fetching stored procedures from the source.
- **Defined in:** `application_sdk/templates/contracts/sql_metadata.py`

#### `FetchProceduresOutput`

- **Import:** `from application_sdk.templates.contracts import FetchProceduresOutput`
- **Summary:** Output from fetching stored procedures.
- **Fields:**
  - `chunk_count: int` `= 0`
  - `total_record_count: int` `= 0`
- **Defined in:** `application_sdk/templates/contracts/sql_metadata.py`

#### `FetchSchemasInput`

- **Import:** `from application_sdk.templates.contracts import FetchSchemasInput`
- **Summary:** Input for fetching schemas from the source.
- **Defined in:** `application_sdk/templates/contracts/sql_metadata.py`

#### `FetchSchemasOutput`

- **Import:** `from application_sdk.templates.contracts import FetchSchemasOutput`
- **Summary:** Output from fetching schemas.
- **Fields:**
  - `schemas: Annotated[list[str], MaxItems(10000)]` `= Field(default_factory=list)`
  - `chunk_count: int` `= 0`
  - `total_record_count: int` `= 0`
- **Defined in:** `application_sdk/templates/contracts/sql_metadata.py`

#### `FetchTablesIncrementalInput`

- **Import:** `from application_sdk.templates.contracts import FetchTablesIncrementalInput`
- **Summary:** Input for the incremental fetch_tables task.
- **Defined in:** `application_sdk/templates/contracts/incremental_sql.py`

#### `FetchTablesInput`

- **Import:** `from application_sdk.templates.contracts import FetchTablesInput`
- **Summary:** Input for fetching tables from the source.
- **Defined in:** `application_sdk/templates/contracts/sql_metadata.py`

#### `FetchTablesOutput`

- **Import:** `from application_sdk.templates.contracts import FetchTablesOutput`
- **Summary:** Output from fetching tables.
- **Fields:**
  - `tables: Annotated[list[str], MaxItems(100000)]` `= Field(default_factory=list)`
  - `chunk_count: int` `= 0`
  - `total_record_count: int` `= 0`
- **Defined in:** `application_sdk/templates/contracts/sql_metadata.py`

#### `FetchViewsInput`

- **Import:** `from application_sdk.templates.contracts import FetchViewsInput`
- **Summary:** Input for fetching views from the source.
- **Defined in:** `application_sdk/templates/contracts/sql_metadata.py`

#### `FetchViewsOutput`

- **Import:** `from application_sdk.templates.contracts import FetchViewsOutput`
- **Summary:** Output from fetching views.
- **Fields:**
  - `chunk_count: int` `= 0`
  - `total_record_count: int` `= 0`
- **Defined in:** `application_sdk/templates/contracts/sql_metadata.py`

#### `IncrementalExtractionInput`

- **Import:** `from application_sdk.templates.contracts import IncrementalExtractionInput`
- **Summary:** Top-level input for an incremental SQL metadata extraction run.
- **Fields:**
  - `incremental_extraction: bool` `= False` — Enable incremental extraction mode.
  - `column_batch_size: int` `= 25000` — Number of tables per batch for incremental column extraction.
  - `column_chunk_size: int` `= 100000` — Number of column records per output chunk file.
  - `copy_workers: int` `= 3` — Parallel workers for file copy operations during state snapshot.
  - `upload_concurrency: int` `= Field(default=4, gt=0)` — Max concurrent object-store requests for the current-state and
  - `prepone_marker_timestamp: bool` `= True` — Whether to move the marker back by ``prepone_marker_hours``.
  - `prepone_marker_hours: int` `= 3` — Hours to subtract from the marker when preponing is enabled.
- **Defined in:** `application_sdk/templates/contracts/incremental_sql.py`

#### `IncrementalExtractionOutput`

- **Import:** `from application_sdk.templates.contracts import IncrementalExtractionOutput`
- **Summary:** Top-level output from an incremental SQL metadata extraction run.
- **Fields:**
  - `current_state_files: int` `= 0` — Number of files written to the current-state snapshot.
  - `incremental_diff_files: int` `= 0` — Number of files in the incremental diff (0 on first run).
  - `column_batches_executed: int` `= 0` — Number of incremental column batches executed.
  - `changed_tables: int` `= 0` — Tables detected as changed since last run.
  - `backfill_tables: int` `= 0` — Tables detected as needing backfill (new tables).
  - `marker_updated: bool` `= False` — Whether the incremental marker was updated after this run.
- **Defined in:** `application_sdk/templates/contracts/incremental_sql.py`

#### `IncrementalTaskInput`

- **Import:** `from application_sdk.templates.contracts import IncrementalTaskInput`
- **Summary:** Base task input with incremental runtime state.
- **Fields:**
  - `incremental_extraction: bool` `= False` — Whether incremental extraction is enabled for this run.
  - `marker_timestamp: str` `= ''` — Marker timestamp from previous run; empty string means full extraction.
  - `current_state_available: bool` `= False` — Whether a current-state snapshot from a previous run is available.
  - `column_chunk_size: int` `= 100000` — Number of column records per output chunk file.
- **Defined in:** `application_sdk/templates/contracts/incremental_sql.py`

#### `PrepareColumnQueriesInput`

- **Import:** `from application_sdk.templates.contracts import PrepareColumnQueriesInput`
- **Summary:** Input for the prepare_column_extraction_queries task.
- **Fields:**
  - `connection_qualified_name: str` `= ''` — Connection qualified name for persistent artifact path resolution.
  - `current_state_s3_prefix: str` `= ''` — S3 prefix of the current-state snapshot for backfill comparison.
  - `column_batch_size: int` `= 25000` — Number of tables per batch file.
  - `application_name: str` `= ''`
- **Defined in:** `application_sdk/templates/contracts/incremental_sql.py`

#### `PrepareColumnQueriesOutput`

- **Import:** `from application_sdk.templates.contracts import PrepareColumnQueriesOutput`
- **Summary:** Output from the prepare_column_extraction_queries task.
- **Fields:**
  - `total_batches: int` `= 0`
  - `changed_tables: int` `= 0`
  - `backfill_tables: int` `= 0`
  - `total_tables: int` `= 0`
  - `batches_s3_prefix: str` `= ''`
  - `batches_local_dir: str` `= ''`
- **Defined in:** `application_sdk/templates/contracts/incremental_sql.py`

#### `PrimeAuthOutput`

- **Import:** `from application_sdk.templates.contracts import PrimeAuthOutput`
- **Summary:** Output from the ``prime_sql_auth`` task (BLDX-1295).
- **Fields:**
  - `duration_ms: float` `= 0.0` — Wall-clock time spent on the probe connection + ``SELECT 1`` + close.
  - `success: bool` `= True` — Whether the probe completed cleanly. ``False`` means the probe
  - `failure: FailureDetails | None` — Typed classification of the probe failure, produced inside
  - `error_type: str | None` — Exception class name of the probe failure's **root cause** (e.g.
  - `error_message: str | None` — Truncated, secret-redacted message of the probe failure's **root
- **Defined in:** `application_sdk/templates/contracts/sql_metadata.py`

#### `QueryBatchInput`

- **Import:** `from application_sdk.templates.contracts import QueryBatchInput`
- **Summary:** Input for the get_query_batches task.
- **Fields:**
  - `workflow_args: Annotated[dict[str, str | int | float | bool | None], MaxItems(100)]` `= Field(default_factory=dict)`
- **Defined in:** `application_sdk/templates/contracts/sql_query.py`

#### `QueryBatchOutput`

- **Import:** `from application_sdk.templates.contracts import QueryBatchOutput`
- **Summary:** Output from the get_query_batches task.
- **Fields:**
  - `total_batches: int` `= 0`
  - `batch_size: int` `= 0`
  - `total_count: int` `= 0`
- **Defined in:** `application_sdk/templates/contracts/sql_query.py`

#### `QueryExtractionInput`

- **Import:** `from application_sdk.templates.contracts import QueryExtractionInput`
- **Summary:** Top-level input for a SQL query extraction run.
- **Fields:**
  - `workflow_id: str` `= ''` — Temporal workflow ID for this run.
  - `connection: ConnectionRef` `= Field(default_factory=ConnectionRef)` — Typed connection reference (qualified name, name, admin users, etc.).
  - `credential_guid: str` `= ''` — GUID of credentials stored in the secret store.
  - `credential_ref: CredentialRef | None` — Typed credential reference — preferred over credential_guid for new apps.
  - `output_prefix: str` `= ''` — Object store prefix for output artifacts.
  - `output_path: str` `= ''` — Local or object store path for output files.
  - `lookback_days: int` `= 30` — Number of days of query history to extract.
  - `batch_size: int` `= 100000` — Number of queries per batch.
  - `exclude_users: Annotated[list[str], MaxItems(1000)]` `= Field(default_factory=list)` — Users whose queries should be excluded.
- **Defined in:** `application_sdk/templates/contracts/sql_query.py`

#### `QueryExtractionOutput`

- **Import:** `from application_sdk.templates.contracts import QueryExtractionOutput`
- **Summary:** Top-level output from a SQL query extraction run.
- **Fields:**
  - `workflow_id: str` `= ''`
  - `success: bool` `= False`
  - `total_batches: int` `= 0`
  - `total_queries: int` `= 0`
  - `records_uploaded: int` `= 0`
  - `error: str` `= ''`
- **Defined in:** `application_sdk/templates/contracts/sql_query.py`

#### `QueryFetchInput`

- **Import:** `from application_sdk.templates.contracts import QueryFetchInput`
- **Summary:** Input for the fetch_queries task.
- **Fields:**
  - `workflow_args: Annotated[dict[str, str | int | float | bool | None], MaxItems(100)]` `= Field(default_factory=dict)`
  - `batch_number: int` `= 0`
  - `batch_size: int` `= 100000`
- **Defined in:** `application_sdk/templates/contracts/sql_query.py`

#### `QueryFetchOutput`

- **Import:** `from application_sdk.templates.contracts import QueryFetchOutput`
- **Summary:** Output from the fetch_queries task.
- **Fields:**
  - `batch_number: int` `= 0`
  - `queries_fetched: int` `= 0`
  - `chunk_count: int` `= 0`
- **Defined in:** `application_sdk/templates/contracts/sql_query.py`

#### `ReadCurrentStateInput`

- **Import:** `from application_sdk.templates.contracts import ReadCurrentStateInput`
- **Summary:** Input for the read_current_state task.
- **Fields:**
  - `connection_qualified_name: str` `= ''`
  - `application_name: str` `= ''`
- **Defined in:** `application_sdk/templates/contracts/incremental_sql.py`

#### `ReadCurrentStateOutput`

- **Import:** `from application_sdk.templates.contracts import ReadCurrentStateOutput`
- **Summary:** Output from the read_current_state task.
- **Fields:**
  - `current_state_path: str` `= ''` — Local filesystem path where the current state was downloaded.
  - `current_state_s3_prefix: str` `= ''` — S3 prefix for the current-state folder.
  - `current_state_available: bool` `= False` — Whether a non-empty current-state snapshot was found.
  - `current_state_json_count: int` `= 0` — Number of JSON files in the downloaded current state.
- **Defined in:** `application_sdk/templates/contracts/incremental_sql.py`

#### `TransformInput`

- **Import:** `from application_sdk.templates.contracts import TransformInput`
- **Summary:** Input for transform tasks.
- **Fields:**
  - `typename: str` `= ''` — **Deprecated** — kept for backward compatibility with existing
  - `file_names: Annotated[list[str], MaxItems(10000)]` `= Field(default_factory=list)` — **Deprecated and unused** — retained on the schema as a no-op
  - `chunk_start: int` `= 0` — **Deprecated** — chunk-offset hint used by the legacy
  - `raw_file: FileReference | None` — Durable ``FileReference`` to the matching extract's raw output.
- **Defined in:** `application_sdk/templates/contracts/sql_metadata.py`

#### `TransformOutput`

- **Import:** `from application_sdk.templates.contracts import TransformOutput`
- **Summary:** Output from the v3 ``transform_*`` tasks.
- **Fields:**
  - `typename: str` `= ''`
  - `total_record_count: int` `= 0`
  - `chunk_count: int` `= 0`
  - `transformed_file: FileReference | None` — ``FileReference`` to the transformed asset output.
- **Defined in:** `application_sdk/templates/contracts/sql_metadata.py`

#### `UpdateMarkerInput`

- **Import:** `from application_sdk.templates.contracts import UpdateMarkerInput`
- **Summary:** Input for the update_incremental_marker task.
- **Fields:**
  - `connection_qualified_name: str` `= ''`
  - `next_marker_timestamp: str` `= ''`
  - `application_name: str` `= ''`
- **Defined in:** `application_sdk/templates/contracts/incremental_sql.py`

#### `UpdateMarkerOutput`

- **Import:** `from application_sdk.templates.contracts import UpdateMarkerOutput`
- **Summary:** Output from the update_incremental_marker task.
- **Fields:**
  - `marker_written: bool` `= False`
  - `marker_timestamp: str` `= ''`
  - `s3_key: str` `= ''`
- **Defined in:** `application_sdk/templates/contracts/incremental_sql.py`

#### `UploadInput`

- **Import:** `from application_sdk.templates.contracts import UploadInput`
- **Summary:** Input for the deprecated ``upload_to_atlan`` task.
- **Fields:**
  - `output_path: str` `= ''` — Local path (file or directory) to push to the platform via App.upload.
- **Defined in:** `application_sdk/templates/contracts/base_metadata_extraction.py`

#### `UploadOutput`

- **Import:** `from application_sdk.templates.contracts import UploadOutput`
- **Summary:** Output from the deprecated ``upload_to_atlan`` task.
- **Fields:**
  - `migrated_files: int` `= 0` — Number of files successfully uploaded.
  - `total_files: int` `= 0` — Total number of files attempted (matches ``migrated_files`` on success).
- **Defined in:** `application_sdk/templates/contracts/base_metadata_extraction.py`

#### `WriteCurrentStateInput`

- **Import:** `from application_sdk.templates.contracts import WriteCurrentStateInput`
- **Summary:** Input for the write_current_state task.
- **Fields:**
  - `workflow_run_id: str` `= ''` — Temporal run ID used to name the incremental diff subfolder.
  - `current_state_s3_prefix: str` `= ''` — S3 prefix for the existing current-state (for previous-state download).
  - `copy_workers: int` `= 3` — Parallel workers for file copy operations.
  - `upload_concurrency: int` `= Field(default=4, gt=0)` — Max concurrent object-store requests when uploading the current-state
  - `application_name: str` `= ''`
- **Defined in:** `application_sdk/templates/contracts/incremental_sql.py`

#### `WriteCurrentStateOutput`

- **Import:** `from application_sdk.templates.contracts import WriteCurrentStateOutput`
- **Summary:** Output from the write_current_state task.
- **Fields:**
  - `current_state_path: str` `= ''`
  - `current_state_s3_prefix: str` `= ''`
  - `current_state_files: int` `= 0`
  - `incremental_diff_path: str` `= ''`
  - `incremental_diff_s3_prefix: str` `= ''`
  - `incremental_diff_files: int` `= 0`
- **Defined in:** `application_sdk/templates/contracts/incremental_sql.py`

