Skip to content

Releases: vanling1111/amazon-ads-api-python-sdk

v2.2.0 — Complete API Surface

10 Apr 14:34

Choose a tag to compare

v2.2.0 — Complete API Surface

Breaking Changes

  • experimental changed from method (client.experimental(acknowledge_risk=True)) to property (client.experimental)

New: 94 API Paths Exposed

All generated API classes are now accessible through the client property tree.

L1 Core Additions:

  • client.sb.themes/media/reports_v2/optimization/forecasts/targeting/brand_video/legacy_migration/stores
  • client.sd.reports/optimization/locations/brand_safety/moderation
  • client.dsp.target_kpi
  • client.accounts.budgets/advertising/test
  • client.sp.eligibility/theme/promotion_groups/global_recs

L1 Cross-cutting APIs (new):

  • client.audiences_discovery
  • client.product_selector
  • client.locations
  • client.exports

L2 Reference Module Restructured:

  • client.reference.amc → sub-module with .administration, .audiences, .reporting
  • client.reference.retail_ad_service → sub-module with .campaigns, .ad_groups, .product_ads, .targets
  • client.reference.data_provider.audience_metadata, .hashed_records
  • client.reference.unified → Amazon Ads v1 Unified API

L3 Services Module Restructured:

  • client.services.reporting → sub-module: .reports_v3, .stores_analytics, .brand_metrics, .mmm
  • client.services.insights → sub-module: .audience_insights, .keyword_insights
  • client.services.common.stores, .assets, .history, .attribution
  • client.services.media_planning.reach_forecasting
  • client.services.ads_data_manager
  • client.services.brand_associations

L4 Experimental Module Enhanced:

  • client.experimental.sponsored_tv → sub-module: .campaigns, .ad_groups, .ads, .targeting, .creatives
  • client.experimental.moderation → sub-module: .pre_moderation, .unified_moderation
  • client.experimental.persona_builder (new)
  • client.experimental.partner_opportunities (new)

Full Changelog

v2.1.0...v2.2.0

v2.1.0 - Full API Coverage with Code Generation

10 Apr 14:02

Choose a tag to compare

🚀 v2.1.0 — Full-Coverage Async Python SDK

Highlights

  • 自动代码生成系统:从 80 个 OpenAPI 规范自动生成 4,941 个 Pydantic v2 类型模型和 650 个异步 API 方法
  • 三层架构:手写便捷层 → 自动生成 thin client → 自动生成 Pydantic models
  • 冲突解决:内置优先级系统自动处理多版本 spec 中的路径冲突
  • CI/CD:GitHub Actions 自动 lint、测试、验证生成代码一致性
  • 每日 spec 更新检测:自动检查 Amazon 官方 API 变更并创建 Issue

API Coverage

类别 覆盖
Sponsored Products (SP) ✅ 完整
Sponsored Brands (SB) ✅ 完整
Sponsored Display (SD) ✅ 完整
Sponsored TV (STV) ✅ 完整
DSP ✅ 完整
AMC (Amazon Marketing Cloud) ✅ 完整
Reporting v3 ✅ 完整
Accounts / Profiles / Portfolios ✅ 完整
Creative Assets ✅ 完整
Attribution ✅ 完整
Brand Metrics / Insights ✅ 完整
其他 60+ 模块 ✅ 完整

Dependencies

  • Python >= 3.11
  • httpx[http2] >= 0.27.0
  • pydantic >= 2.0.0
  • loguru >= 0.7.0

Installation

pip install amazon-ads-api

v1.0.0 - Initial Release

15 Dec 03:13

Choose a tag to compare

Amazon Ads API Python SDK v1.0.0

First Release

100% API Coverage - 682 endpoints verified against 59 official OpenAPI specifications

Core Features

  • 4-Tier API Governance - L1 Gold/L2 Silver/L3 Bronze/L4 Red classification
  • 88 SDK Modules - Covers SP/SB/SD/DSP/AMC/Stream and more
  • OpenAPI Verified - L1 APIs 100% validated against official specs
  • Async Support - Built on httpx with HTTP/2 support
  • Auto Authentication - OAuth2 token auto-refresh
  • Auto Retry - Built-in exponential backoff retry mechanism
  • Rate Limiting - Automatic rate limit handling
  • Type Safety - Complete type hints throughout
  • Comprehensive Tests - 73 tests (62 unit + 6 integration + 5 e2e)

Installation

\\�ash
pip install amazon-ads-api
\\

Quick Start

\\python
from amazon_ads_api import AmazonAdsClient

client = AmazonAdsClient(
client_id='your-client-id',
client_secret='your-client-secret',
refresh_token='your-refresh-token',
profile_id='your-profile-id'
)

Get campaigns

campaigns = await client.sp.campaigns.list_campaigns()
\\

Documentation

Links

What's Included

L1 Core APIs (OpenAPI Verified)

  • Sponsored Products (SP)
  • Sponsored Brands (SB)
  • Sponsored Display (SD)
  • Amazon DSP
  • Profiles & Portfolios
  • And more...

L2 Reference APIs

  • Amazon Marketing Cloud (AMC)
  • Amazon Marketing Stream
  • Retail Ad Service
  • Attribution API

L3 Service APIs

  • Reporting v3
  • Insights
  • Recommendations
  • Media Planning

L4 Experimental APIs

  • Sponsored TV
  • Ad Library
  • Localization
  • Moderation