Getting Started¶
Installation¶
Install the package and its development dependencies with uv:
uv sync --group dev
Create a Client¶
To call the Adobe Target Admin API you need:
- your Adobe Target tenant ID
- an Adobe API key
- either a pre-existing bearer token or Adobe IMS OAuth Server-to-Server credentials
The SDK currently supports:
StaticTokenAuthProviderfor an already-issued bearer tokenOAuthServerToServerAuthProviderfor Adobe IMS client-credentials token acquisitionOAuthUserAuthProviderfor Adobe IMS user-auth flows
For setup guidance and links to Adobe's official authentication docs, see Authentication.
Static token example:
from adobe_target_admin import StaticTokenAuthProvider, TargetClient
client = TargetClient(
tenant="your-tenant-id",
api_key="your-api-key",
auth_provider=StaticTokenAuthProvider("your-access-token"),
)
OAuth Server-to-Server example:
from adobe_target_admin import OAuthServerToServerAuthProvider, TargetClient
auth_provider = OAuthServerToServerAuthProvider(
client_id="your-client-id",
client_secret="your-client-secret",
scopes=["your-scope"],
)
client = TargetClient(
tenant="your-tenant-id",
api_key="your-api-key",
auth_provider=auth_provider,
)
First Calls¶
from adobe_target_admin import ActivitiesListParams
properties = client.properties.list()
offer = client.offers.content.get("123")
ab_activity = client.activities.ab.get("123")
activities = client.activities.list(
params=ActivitiesListParams(mbox="homepage-hero"),
)
xt_orders_report = client.reports.xt.orders("123")
These calls return generated Pydantic models:
client.properties.list() -> PropertyListclient.offers.content.get("123") -> ContentOfferclient.activities.ab.get("123") -> ABActivityclient.activities.list(params=ActivitiesListParams(...)) -> ActivityListclient.reports.xt.orders("123") -> ActivityOrdersReport
The public client is organized by namespaces such as activities, audiences,
offers, and reports.
For the complete method inventory, request models, response models, and Adobe doc links, use:
Low-level raw request access is still available:
client.request(...) -> httpx.Response