python-amazon-ad-api 2.1.6__py3-none-any.whl → 2.1.8__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- ad_api/api/v1/ads.py +28 -0
- ad_api/api/v1/campaigns.py +28 -0
- ad_api/api/v1/location_indexes.py +30 -0
- ad_api/api/v1/targets.py +28 -0
- ad_api/version.py +1 -1
- {python_amazon_ad_api-2.1.6.dist-info → python_amazon_ad_api-2.1.8.dist-info}/METADATA +1 -1
- {python_amazon_ad_api-2.1.6.dist-info → python_amazon_ad_api-2.1.8.dist-info}/RECORD +10 -10
- {python_amazon_ad_api-2.1.6.dist-info → python_amazon_ad_api-2.1.8.dist-info}/WHEEL +0 -0
- {python_amazon_ad_api-2.1.6.dist-info → python_amazon_ad_api-2.1.8.dist-info}/licenses/LICENSE +0 -0
- {python_amazon_ad_api-2.1.6.dist-info → python_amazon_ad_api-2.1.8.dist-info}/top_level.txt +0 -0
ad_api/api/v1/ads.py
CHANGED
|
@@ -51,6 +51,13 @@ class Ads(Client):
|
|
|
51
51
|
"""
|
|
52
52
|
schema_version = 'application/json'
|
|
53
53
|
headers = {"Accept": schema_version, "Content-Type": schema_version}
|
|
54
|
+
|
|
55
|
+
# Optional account header, taken from kwargs and removed before the
|
|
56
|
+
# call is built: left in kwargs it would travel in the query string.
|
|
57
|
+
account_id = kwargs.pop('account_id', None)
|
|
58
|
+
if account_id:
|
|
59
|
+
headers["Amazon-Ads-AccountId"] = account_id
|
|
60
|
+
|
|
54
61
|
return self._request(kwargs.pop('path'), data=Utils.convert_body(kwargs.pop('body'), False), params=kwargs, headers=headers)
|
|
55
62
|
|
|
56
63
|
@sp_endpoint('/adsApi/v1/create/ads', method='POST')
|
|
@@ -103,6 +110,13 @@ class Ads(Client):
|
|
|
103
110
|
"""
|
|
104
111
|
schema_version = 'application/json'
|
|
105
112
|
headers = {"Accept": schema_version, "Content-Type": schema_version}
|
|
113
|
+
|
|
114
|
+
# Optional account header, taken from kwargs and removed before the
|
|
115
|
+
# call is built: left in kwargs it would travel in the query string.
|
|
116
|
+
account_id = kwargs.pop('account_id', None)
|
|
117
|
+
if account_id:
|
|
118
|
+
headers["Amazon-Ads-AccountId"] = account_id
|
|
119
|
+
|
|
106
120
|
return self._request(kwargs.pop('path'), data=Utils.convert_body(kwargs.pop('body'), False), params=kwargs, headers=headers)
|
|
107
121
|
|
|
108
122
|
@sp_endpoint('/adsApi/v1/update/ads', method='POST')
|
|
@@ -137,6 +151,13 @@ class Ads(Client):
|
|
|
137
151
|
"""
|
|
138
152
|
schema_version = 'application/json'
|
|
139
153
|
headers = {"Accept": schema_version, "Content-Type": schema_version}
|
|
154
|
+
|
|
155
|
+
# Optional account header, taken from kwargs and removed before the
|
|
156
|
+
# call is built: left in kwargs it would travel in the query string.
|
|
157
|
+
account_id = kwargs.pop('account_id', None)
|
|
158
|
+
if account_id:
|
|
159
|
+
headers["Amazon-Ads-AccountId"] = account_id
|
|
160
|
+
|
|
140
161
|
return self._request(kwargs.pop('path'), data=Utils.convert_body(kwargs.pop('body'), False), params=kwargs, headers=headers)
|
|
141
162
|
|
|
142
163
|
@sp_endpoint('/adsApi/v1/delete/ads', method='POST')
|
|
@@ -160,4 +181,11 @@ class Ads(Client):
|
|
|
160
181
|
"""
|
|
161
182
|
schema_version = 'application/json'
|
|
162
183
|
headers = {"Accept": schema_version, "Content-Type": schema_version}
|
|
184
|
+
|
|
185
|
+
# Optional account header, taken from kwargs and removed before the
|
|
186
|
+
# call is built: left in kwargs it would travel in the query string.
|
|
187
|
+
account_id = kwargs.pop('account_id', None)
|
|
188
|
+
if account_id:
|
|
189
|
+
headers["Amazon-Ads-AccountId"] = account_id
|
|
190
|
+
|
|
163
191
|
return self._request(kwargs.pop('path'), data=Utils.convert_body(kwargs.pop('body'), False), params=kwargs, headers=headers)
|
ad_api/api/v1/campaigns.py
CHANGED
|
@@ -52,6 +52,13 @@ class Campaigns(Client):
|
|
|
52
52
|
"""
|
|
53
53
|
schema_version = 'application/json'
|
|
54
54
|
headers = {"Accept": schema_version, "Content-Type": schema_version}
|
|
55
|
+
|
|
56
|
+
# Optional account header, taken from kwargs and removed before the
|
|
57
|
+
# call is built: left in kwargs it would travel in the query string.
|
|
58
|
+
account_id = kwargs.pop('account_id', None)
|
|
59
|
+
if account_id:
|
|
60
|
+
headers["Amazon-Ads-AccountId"] = account_id
|
|
61
|
+
|
|
55
62
|
return self._request(kwargs.pop('path'), data=Utils.convert_body(kwargs.pop('body'), False), params=kwargs, headers=headers)
|
|
56
63
|
|
|
57
64
|
@sp_endpoint('/adsApi/v1/delete/campaigns', method='POST')
|
|
@@ -75,6 +82,13 @@ class Campaigns(Client):
|
|
|
75
82
|
"""
|
|
76
83
|
schema_version = 'application/json'
|
|
77
84
|
headers = {"Accept": schema_version, "Content-Type": schema_version}
|
|
85
|
+
|
|
86
|
+
# Optional account header, taken from kwargs and removed before the
|
|
87
|
+
# call is built: left in kwargs it would travel in the query string.
|
|
88
|
+
account_id = kwargs.pop('account_id', None)
|
|
89
|
+
if account_id:
|
|
90
|
+
headers["Amazon-Ads-AccountId"] = account_id
|
|
91
|
+
|
|
78
92
|
return self._request(kwargs.pop('path'), data=Utils.convert_body(kwargs.pop('body'), False), params=kwargs, headers=headers)
|
|
79
93
|
|
|
80
94
|
@sp_endpoint('/adsApi/v1/update/campaigns', method='POST')
|
|
@@ -123,6 +137,13 @@ class Campaigns(Client):
|
|
|
123
137
|
"""
|
|
124
138
|
schema_version = 'application/json'
|
|
125
139
|
headers = {"Accept": schema_version, "Content-Type": schema_version}
|
|
140
|
+
|
|
141
|
+
# Optional account header, taken from kwargs and removed before the
|
|
142
|
+
# call is built: left in kwargs it would travel in the query string.
|
|
143
|
+
account_id = kwargs.pop('account_id', None)
|
|
144
|
+
if account_id:
|
|
145
|
+
headers["Amazon-Ads-AccountId"] = account_id
|
|
146
|
+
|
|
126
147
|
return self._request(kwargs.pop('path'), data=Utils.convert_body(kwargs.pop('body'), False), params=kwargs, headers=headers)
|
|
127
148
|
|
|
128
149
|
@sp_endpoint('/adsApi/v1/create/campaigns', method='POST')
|
|
@@ -177,4 +198,11 @@ class Campaigns(Client):
|
|
|
177
198
|
"""
|
|
178
199
|
schema_version = 'application/json'
|
|
179
200
|
headers = {"Accept": schema_version, "Content-Type": schema_version}
|
|
201
|
+
|
|
202
|
+
# Optional account header, taken from kwargs and removed before the
|
|
203
|
+
# call is built: left in kwargs it would travel in the query string.
|
|
204
|
+
account_id = kwargs.pop('account_id', None)
|
|
205
|
+
if account_id:
|
|
206
|
+
headers["Amazon-Ads-AccountId"] = account_id
|
|
207
|
+
|
|
180
208
|
return self._request(kwargs.pop('path'), data=Utils.convert_body(kwargs.pop('body'), False), params=kwargs, headers=headers)
|
|
@@ -44,6 +44,16 @@ class LocationIndexes(Client):
|
|
|
44
44
|
"""
|
|
45
45
|
schema_version = 'application/json'
|
|
46
46
|
headers = {"Accept": schema_version, "Content-Type": schema_version}
|
|
47
|
+
|
|
48
|
+
# Optional account headers, taken from kwargs and removed before the
|
|
49
|
+
# call is built: left in kwargs they would travel in the query string.
|
|
50
|
+
account_id = kwargs.pop('account_id', None)
|
|
51
|
+
manager_account_id = kwargs.pop('manager_account_id', None)
|
|
52
|
+
if account_id:
|
|
53
|
+
headers["Amazon-Ads-AccountId"] = account_id
|
|
54
|
+
if manager_account_id:
|
|
55
|
+
headers["Amazon-Ads-Manager-AccountId"] = manager_account_id
|
|
56
|
+
|
|
47
57
|
return self._request(kwargs.pop('path'), data=Utils.convert_body(kwargs.pop('body'), False), params=kwargs, headers=headers)
|
|
48
58
|
|
|
49
59
|
@sp_endpoint('/adsApi/v1/locationIndexes', method='GET')
|
|
@@ -106,6 +116,16 @@ class LocationIndexes(Client):
|
|
|
106
116
|
"""
|
|
107
117
|
schema_version = 'application/json'
|
|
108
118
|
headers = {"Accept": schema_version, "Content-Type": schema_version}
|
|
119
|
+
|
|
120
|
+
# Optional account headers, taken from kwargs and removed before the
|
|
121
|
+
# call is built: left in kwargs they would travel in the query string.
|
|
122
|
+
account_id = kwargs.pop('account_id', None)
|
|
123
|
+
manager_account_id = kwargs.pop('manager_account_id', None)
|
|
124
|
+
if account_id:
|
|
125
|
+
headers["Amazon-Ads-AccountId"] = account_id
|
|
126
|
+
if manager_account_id:
|
|
127
|
+
headers["Amazon-Ads-Manager-AccountId"] = manager_account_id
|
|
128
|
+
|
|
109
129
|
return self._request(kwargs.pop('path'), data=Utils.convert_body(kwargs.pop('body'), False), params=kwargs, headers=headers)
|
|
110
130
|
|
|
111
131
|
@sp_endpoint('/adsApi/v1/update/locationIndexes', method='POST')
|
|
@@ -128,4 +148,14 @@ class LocationIndexes(Client):
|
|
|
128
148
|
"""
|
|
129
149
|
schema_version = 'application/json'
|
|
130
150
|
headers = {"Accept": schema_version, "Content-Type": schema_version}
|
|
151
|
+
|
|
152
|
+
# Optional account headers, taken from kwargs and removed before the
|
|
153
|
+
# call is built: left in kwargs they would travel in the query string.
|
|
154
|
+
account_id = kwargs.pop('account_id', None)
|
|
155
|
+
manager_account_id = kwargs.pop('manager_account_id', None)
|
|
156
|
+
if account_id:
|
|
157
|
+
headers["Amazon-Ads-AccountId"] = account_id
|
|
158
|
+
if manager_account_id:
|
|
159
|
+
headers["Amazon-Ads-Manager-AccountId"] = manager_account_id
|
|
160
|
+
|
|
131
161
|
return self._request(kwargs.pop('path'), data=Utils.convert_body(kwargs.pop('body'), False), params=kwargs, headers=headers)
|
ad_api/api/v1/targets.py
CHANGED
|
@@ -64,6 +64,13 @@ class Targets(Client):
|
|
|
64
64
|
"""
|
|
65
65
|
schema_version = 'application/json'
|
|
66
66
|
headers = {"Accept": schema_version, "Content-Type": schema_version}
|
|
67
|
+
|
|
68
|
+
# Optional account header, taken from kwargs and removed before the
|
|
69
|
+
# call is built: left in kwargs it would travel in the query string.
|
|
70
|
+
account_id = kwargs.pop('account_id', None)
|
|
71
|
+
if account_id:
|
|
72
|
+
headers["Amazon-Ads-AccountId"] = account_id
|
|
73
|
+
|
|
67
74
|
return self._request(kwargs.pop('path'), data=Utils.convert_body(kwargs.pop('body'), False), params=kwargs, headers=headers)
|
|
68
75
|
|
|
69
76
|
@sp_endpoint('/adsApi/v1/create/targets', method='POST')
|
|
@@ -141,6 +148,13 @@ class Targets(Client):
|
|
|
141
148
|
"""
|
|
142
149
|
schema_version = 'application/json'
|
|
143
150
|
headers = {"Accept": schema_version, "Content-Type": schema_version}
|
|
151
|
+
|
|
152
|
+
# Optional account header, taken from kwargs and removed before the
|
|
153
|
+
# call is built: left in kwargs it would travel in the query string.
|
|
154
|
+
account_id = kwargs.pop('account_id', None)
|
|
155
|
+
if account_id:
|
|
156
|
+
headers["Amazon-Ads-AccountId"] = account_id
|
|
157
|
+
|
|
144
158
|
return self._request(kwargs.pop('path'), data=Utils.convert_body(kwargs.pop('body'), False), params=kwargs, headers=headers)
|
|
145
159
|
|
|
146
160
|
@sp_endpoint('/adsApi/v1/update/targets', method='POST')
|
|
@@ -179,6 +193,13 @@ class Targets(Client):
|
|
|
179
193
|
"""
|
|
180
194
|
schema_version = 'application/json'
|
|
181
195
|
headers = {"Accept": schema_version, "Content-Type": schema_version}
|
|
196
|
+
|
|
197
|
+
# Optional account header, taken from kwargs and removed before the
|
|
198
|
+
# call is built: left in kwargs it would travel in the query string.
|
|
199
|
+
account_id = kwargs.pop('account_id', None)
|
|
200
|
+
if account_id:
|
|
201
|
+
headers["Amazon-Ads-AccountId"] = account_id
|
|
202
|
+
|
|
182
203
|
return self._request(kwargs.pop('path'), data=Utils.convert_body(kwargs.pop('body'), False), params=kwargs, headers=headers)
|
|
183
204
|
|
|
184
205
|
@sp_endpoint('/adsApi/v1/delete/targets', method='POST')
|
|
@@ -202,4 +223,11 @@ class Targets(Client):
|
|
|
202
223
|
"""
|
|
203
224
|
schema_version = 'application/json'
|
|
204
225
|
headers = {"Accept": schema_version, "Content-Type": schema_version}
|
|
226
|
+
|
|
227
|
+
# Optional account header, taken from kwargs and removed before the
|
|
228
|
+
# call is built: left in kwargs it would travel in the query string.
|
|
229
|
+
account_id = kwargs.pop('account_id', None)
|
|
230
|
+
if account_id:
|
|
231
|
+
headers["Amazon-Ads-AccountId"] = account_id
|
|
232
|
+
|
|
205
233
|
return self._request(kwargs.pop('path'), data=Utils.convert_body(kwargs.pop('body'), False), params=kwargs, headers=headers)
|
ad_api/version.py
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
__version__ = "2.1.
|
|
1
|
+
__version__ = "2.1.8"
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
ad_api/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
2
|
-
ad_api/version.py,sha256=
|
|
2
|
+
ad_api/version.py,sha256=Zs7yBsCpiMSJW2PP_mZoH_3cEDqJwh80ulBcmuMBwMU,22
|
|
3
3
|
ad_api/api/__init__.py,sha256=Ain-1s6B4eywYsw3CdYQc2C1KTQdAZy2L3T90KJDYdI,1995
|
|
4
4
|
ad_api/api/account.py,sha256=X6VPoPsEfGwuABUYVWJATiUpgHSCAz0BreQOHCze9To,4613
|
|
5
5
|
ad_api/api/account_budgets.py,sha256=jFce5eLWAFK3ydjnYR7_Sv7B0-gHTG5bMTx_TcHyy1A,2319
|
|
@@ -100,24 +100,24 @@ ad_api/api/v1/__init__.py,sha256=K7rmsKJnWebiarPZknUIcXJKvoIDPI5dBVNrIJGWa2I,137
|
|
|
100
100
|
ad_api/api/v1/ad_associations.py,sha256=g5L8hAIagmsb-yQ09hP7z1zbVVe868NlpOOokv-Mouc,5812
|
|
101
101
|
ad_api/api/v1/ad_extensions.py,sha256=kL-7xHaXXqb2jXTwZrY0oGttLAG0CW_IjBAqL_CI92U,5519
|
|
102
102
|
ad_api/api/v1/ad_groups.py,sha256=SN2NRzs9P-IvSe_OWyKZoX2Nvcx9afqoELi96ZKOB1k,13939
|
|
103
|
-
ad_api/api/v1/ads.py,sha256=
|
|
103
|
+
ad_api/api/v1/ads.py,sha256=RVZbh1ijNrNwGEGj4IkJa8q2Zu89KaKo5BfE-S32W3A,9089
|
|
104
104
|
ad_api/api/v1/advertiser_accounts.py,sha256=Y_QqOIt6ggmysEBT59JhrdvTlZ5OQnPduMKX43JTdDU,5468
|
|
105
105
|
ad_api/api/v1/brand_store_edition_publish_versions.py,sha256=HVeO4ZiPdtjVoVoxQk2xIa8fhcLXSMCquSO1CP4Hbu4,4894
|
|
106
106
|
ad_api/api/v1/brand_store_editions.py,sha256=xW4z2jDWhNJn86tWlT3eLIRr0NEpxLhW1eA-T_hiXcI,2160
|
|
107
107
|
ad_api/api/v1/brand_store_pages.py,sha256=uag4VY4bWgHnYtk7O1GAPub1KpwUwVLowoP_xEjotzI,2766
|
|
108
108
|
ad_api/api/v1/brand_stores.py,sha256=zlBsKiOwmdSiIG9filgdqUlPnV6AX-gE6S5nNyAQACc,2131
|
|
109
|
-
ad_api/api/v1/campaigns.py,sha256=
|
|
109
|
+
ad_api/api/v1/campaigns.py,sha256=4A-sg1i3N_0DQPXunkNGnRM2iV-hZR-yE041EVejAPQ,10721
|
|
110
110
|
ad_api/api/v1/geo_locations.py,sha256=gH1kR1rPQuIdzStB6wvWI40-XRo5yFyVI9AYYcjN5_8,2641
|
|
111
111
|
ad_api/api/v1/label_object_associations.py,sha256=zXuD5cUAfqL-PRObvjOM54KC356HFqnzA5ehpGSJPYk,2597
|
|
112
112
|
ad_api/api/v1/labels.py,sha256=jjPmafIQZTh99Ztj5MCcDC7UyoFFN0YuWdn2syqd3Yg,2438
|
|
113
|
-
ad_api/api/v1/location_indexes.py,sha256=
|
|
113
|
+
ad_api/api/v1/location_indexes.py,sha256=xV2g8DuNh6ayNwl55YiLEkbAFPfR6AeM92AH7VWC6dg,7266
|
|
114
114
|
ad_api/api/v1/manager_accounts.py,sha256=iiW0bjS23rn2R_In3Zisn0mSFQsQ6iy6KgkO_JxT-H4,5101
|
|
115
115
|
ad_api/api/v1/portfolios.py,sha256=jAbFxPO27laeMhwpzU8_JZJ5sVMdod1eap7Uw88sZIY,8889
|
|
116
116
|
ad_api/api/v1/recommendation_types.py,sha256=aEBfXu1EhzcRk9Nhin8_ieFiNnBiusX_vWviJw_qD08,2077
|
|
117
117
|
ad_api/api/v1/recommendations.py,sha256=lb3Jwtwcmq3L8j0HAUKzOt8o_xQRJRduXcjklX_tFw8,4305
|
|
118
118
|
ad_api/api/v1/reports.py,sha256=vJmWhIsALkX27HeijTsSUz3zrYhUBm4RodTCieJD8Y8,6657
|
|
119
119
|
ad_api/api/v1/selling_accounts.py,sha256=0_R4yzvXGp_gFyfcZeWJyeIr7Wh4eGpLfK12podXqGA,1941
|
|
120
|
-
ad_api/api/v1/targets.py,sha256=
|
|
120
|
+
ad_api/api/v1/targets.py,sha256=Oyuh7r8Tj3VrwOulCYkYGoONfTH0ve9XdfLK86DZB3U,13503
|
|
121
121
|
ad_api/auth/__init__.py,sha256=B_yKdmsHENQaKfMFAIcSxQqG4aBUmNBm5orKIMUYObk,229
|
|
122
122
|
ad_api/auth/access_token_client.py,sha256=2B5bVXRu54FMhN1B08tjmSIYhc-XoKggZq7tL9ObewI,2997
|
|
123
123
|
ad_api/auth/access_token_response.py,sha256=zlkfo3oWjkhAqNJIUOM0S4g_FvpgDa3IwNLxlREM89A,275
|
|
@@ -134,8 +134,8 @@ ad_api/base/marketplaces.py,sha256=44lvCcluXNpqTprWQ80e3weSQmQbJoWL-WDSOWVbCyQ,4
|
|
|
134
134
|
ad_api/base/utils.py,sha256=_qnCBOvyJTLgaZjJzUWTi38GGLHkQszXELs79133Rb4,5618
|
|
135
135
|
ad_api/shared/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
136
136
|
ad_api/shared/base_client.py,sha256=zOL_LTh-58URWf3ZDlrwmqXXbd6PX66QF5hrr2p83yY,356
|
|
137
|
-
python_amazon_ad_api-2.1.
|
|
138
|
-
python_amazon_ad_api-2.1.
|
|
139
|
-
python_amazon_ad_api-2.1.
|
|
140
|
-
python_amazon_ad_api-2.1.
|
|
141
|
-
python_amazon_ad_api-2.1.
|
|
137
|
+
python_amazon_ad_api-2.1.8.dist-info/licenses/LICENSE,sha256=h2rpqlmmLy-4l1tN6KpWAFxx1JEMYeEFrMrZUbx_B_o,1105
|
|
138
|
+
python_amazon_ad_api-2.1.8.dist-info/METADATA,sha256=dJZcJ64haUWv1i67UnKKIb_KSJqhCnoaMERTnBUyUss,54257
|
|
139
|
+
python_amazon_ad_api-2.1.8.dist-info/WHEEL,sha256=mOdXR9C3wMVov7cSY8PY-XCzo3SmmWCHvGQr5csJoao,91
|
|
140
|
+
python_amazon_ad_api-2.1.8.dist-info/top_level.txt,sha256=nN9twUos-8pkP514ZwpvRU9YL9L2XyQyHsMQFfudGTU,7
|
|
141
|
+
python_amazon_ad_api-2.1.8.dist-info/RECORD,,
|
|
File without changes
|
{python_amazon_ad_api-2.1.6.dist-info → python_amazon_ad_api-2.1.8.dist-info}/licenses/LICENSE
RENAMED
|
File without changes
|
|
File without changes
|