Skip to content

Commit

Permalink
📝 Source Amazon Ads: add info agency account to docs/spec/error messa…
Browse files Browse the repository at this point in the history
…ges (#37655)
  • Loading branch information
darynaishchenko authored May 7, 2024
1 parent 787352c commit c9c5acb
Show file tree
Hide file tree
Showing 7 changed files with 18 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,6 @@ acceptance_tests:
tests:
- spec_path: integration_tests/spec.json
backward_compatibility_tests_config:
disable_for_version: 3.4.3
disable_for_version: 5.0.0
connector_image: airbyte/source-amazon-ads:dev
test_strictness_level: high
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@
},
"profiles": {
"title": "Profile IDs",
"description": "Profile IDs you want to fetch data for. See <a href=\"https://advertising.amazon.com/API/docs/en-us/concepts/authorization/profiles\">docs</a> for more details. Note: If Marketplace IDs are also selected, profiles will be selected if they match the Profile ID OR the Marketplace ID.",
"description": "Profile IDs you want to fetch data for. The Amazon Ads source connector supports only profiles with seller and vendor type, profiles with agency type will be ignored. See <a href=\"https://advertising.amazon.com/API/docs/en-us/concepts/authorization/profiles\">docs</a> for more details. Note: If Marketplace IDs are also selected, profiles will be selected if they match the Profile ID OR the Marketplace ID.",
"order": 6,
"type": "array",
"items": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ data:
connectorSubtype: api
connectorType: source
definitionId: c6b0a29e-1da9-4512-9002-7bfd0cba2246
dockerImageTag: 5.0.0
dockerImageTag: 5.0.1
dockerRepository: airbyte/source-amazon-ads
documentationUrl: https://docs.airbyte.com/integrations/sources/amazon-ads
githubIssueLabel: source-amazon-ads
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ requires = [ "poetry-core>=1.0.0",]
build-backend = "poetry.core.masonry.api"

[tool.poetry]
version = "5.0.0"
version = "5.0.1"
name = "source-amazon-ads"
description = "Source implementation for Amazon Ads."
authors = [ "Airbyte <contact@airbyte.io>",]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ spec:
type: string
profiles:
title: Profile IDs
description: 'Profile IDs you want to fetch data for. See <a href="https://advertising.amazon.com/API/docs/en-us/concepts/authorization/profiles">docs</a> for more details. Note: If Marketplace IDs are also selected, profiles will be selected if they match the Profile ID OR the Marketplace ID.'
description: 'Profile IDs you want to fetch data for. The Amazon Ads source connector supports only profiles with seller and vendor type, profiles with agency type will be ignored. See <a href="https://advertising.amazon.com/API/docs/en-us/concepts/authorization/profiles">docs</a> for more details. Note: If Marketplace IDs are also selected, profiles will be selected if they match the Profile ID OR the Marketplace ID.'
order: 6
type: array
items:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,10 @@ def check_connection(self, logger: logging.Logger, config: Mapping[str, Any]) ->
profiles_list = Profiles(config, authenticator=self._make_authenticator(config)).get_all_profiles()
filtered_profiles = self._choose_profiles(config, profiles_list)
if not filtered_profiles:
return False, "No profiles found after filtering by Profile ID and Marketplace ID"
return False, (
"No profiles with seller or vendor type found after filtering by Profile ID and Marketplace ID."
" If you have only agency profile, please use accounts associated with the profile of seller/vendor type."
)
return True, None

def streams(self, config: Mapping[str, Any]) -> List[Stream]:
Expand Down
11 changes: 9 additions & 2 deletions docs/integrations/sources/amazon-ads.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ To use the [Amazon Ads API](https://advertising.amazon.com/API/docs/en-us), you
5. Log in and Authorize to the Amazon account.
6. Select **Region** to pull data from **North America (NA)**, **Europe (EU)**, **Far East (FE)**. See [docs](https://advertising.amazon.com/API/docs/en-us/info/api-overview#api-endpoints) for more details.
7. **Start Date (Optional)** is used for generating reports starting from the specified start date. This should be in YYYY-MM-DD format and not more than 60 days in the past. If a date is not specified, today's date is used. The date is treated in the timezone of the processed profile.
8. **Profile IDs (Optional)** you want to fetch data for. See [docs](https://advertising.amazon.com/API/docs/en-us/concepts/authorization/profiles) for more details.
8. **Profile IDs (Optional)** you want to fetch data for. The Amazon Ads source connector supports only profiles with seller and vendor type, profiles with agency type will be ignored. See [docs](https://advertising.amazon.com/API/docs/en-us/concepts/authorization/profiles) for more details.
9. **Marketplace IDs (Optional)** you want to fetch data for. _Note: If Profile IDs are also selected, profiles will be selected if they match the Profile ID **OR** the Marketplace ID._
10. Click **Set up source**.
<!-- /env:cloud -->
Expand All @@ -45,10 +45,16 @@ To use the [Amazon Ads API](https://advertising.amazon.com/API/docs/en-us), you
3. **Refresh Token**. See [onboarding process](https://advertising.amazon.com/API/docs/en-us/setting-up/overview) for more details.
4. Select **Region** to pull data from **North America (NA)**, **Europe (EU)**, **Far East (FE)**. See [docs](https://advertising.amazon.com/API/docs/en-us/info/api-overview#api-endpoints) for more details.
5. **Start Date (Optional)** is used for generating reports starting from the specified start date. This should be in YYYY-MM-DD format and not more than 60 days in the past. If a date is not specified, today's date is used. The date is treated in the timezone of the processed profile.
6. **Profile IDs (Optional)** you want to fetch data for. See [docs](https://advertising.amazon.com/API/docs/en-us/concepts/authorization/profiles) for more details.
6. **Profile IDs (Optional)** you want to fetch data for. The Amazon Ads source connector supports only profiles with seller and vendor type, profiles with agency type will be ignored. See [docs](https://advertising.amazon.com/API/docs/en-us/concepts/authorization/profiles) for more details.
7. **Marketplace IDs (Optional)** you want to fetch data for. _Note: If Profile IDs are also selected, profiles will be selected if they match the Profile ID **OR** the Marketplace ID._
<!-- /env:oss -->

:::note
The Amazon Ads source connector uses Sponsored Products, Sponsored Brands, and Sponsored Display APIs which are not compatible with agency account type. See [docs](https://advertising.amazon.com/API/docs/en-us/concepts/authorization/profiles) for more details.
If you have only agency profile, please use accounts associated with the profile of seller/vendor type.
:::


## Supported sync modes
The Amazon Ads source connector supports the following [sync modes](https://docs.airbyte.com/cloud/core-concepts/#connection-sync-mode):
- Full Refresh
Expand Down Expand Up @@ -114,6 +120,7 @@ Information about expected report generation waiting time can be found [here](ht

| Version | Date | Pull Request | Subject |
|:--------|:-----------|:---------------------------------------------------------|:----------------------------------------------------------------------------------------------------------------|
| 5.0.1 | 2024-04-29 | [37655](https://github.com/airbytehq/airbyte/pull/37655) | Update error messages and spec with info about `agency` profile type. |
| 5.0.0 | 2024-03-22 | [36169](https://github.com/airbytehq/airbyte/pull/36169) | Update `SponsoredBrand` and `SponsoredProduct` streams due to API endpoint deprecation |
| 4.1.0 | 2024-03-19 | [36267](https://github.com/airbytehq/airbyte/pull/36267) | Pin airbyte-cdk version to `^0` |
| 4.0.4 | 2024-02-23 | [35481](https://github.com/airbytehq/airbyte/pull/35481) | Migrate source to `YamlDeclarativeSource` with custom `check_connection` |
Expand Down

0 comments on commit c9c5acb

Please sign in to comment.