Arcane bing
This package is based on bingads.
Get Started
pip install arcane-bing
Example Usage
Reporting
bing_client = Client(
credentials=Config.BING_ADS_CREDENTIALS,
secrets_bucket=Config.SECRETS_BUCKET,
refresh_token_location=Config.BING_ADS_REFRESH_TOKEN,
storage_client=storage_client
)
reporting_service_manager, reporting_service = bing_client.get_bing_ads_api_client()
report_request = build_campaigns_report(reporting_service, bing_account_id)
result_file_path = bing_client.submit_and_download(report_request, reporting_service_manager)
Campaign Service
⚠️ For some API methods, you must provide the client's account id and the manager's customer id
from arcane.bing import Client
from arcane.bing.helpers import parse_webfault_errors, parse_bing_response
bing_client = Client(
credentials=Config.BING_ADS_CREDENTIALS,
secrets_bucket=Config.SECRETS_BUCKET,
refresh_token_location=Config.BING_ADS_REFRESH_TOKEN,
storage_client=storage_client,
customer_id=CUSTOMER_ID,
account_id=ACCOUNT_ID
)
campaign_service = bing_client.get_service_client(service_name='CampaignManagement')
try:
response = campaign_service.GetCampaignsByAccountId(AccountId=ACCOUNT_ID)
all_campaigns = parse_bing_response(response)['Campaign']
# do stuff with all_campaigns
except WebFault as e:
bing_error = parse_webfault_errors(e)
# do stuff with bing_error
Release files for arcane-bing 0.5.10
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| arcane_bing-0.5.10.tar.gz | 5.5 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| arcane_bing-0.5.10-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 12.7 kB
Release files / arcane_bing-0.5.10.tar.gz
| Download URL | arcane_bing-0.5.10.tar.gz |
|---|---|
| Size | 5.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
fc08f6532a89fcbed23fcdbc910bff6bbd911cdb46e8ab7861652d8af8b28af1
|
|
BLAKE2b-256 checksum How to use checksums |
d8a64f36cb7f6e535f5455cf14937a4d6f47dae5c9b2b8cc388963d10467ff86
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/2.4.3 CPython/3.12.14 Linux/6.17.0-1022-azure
|
Release files / arcane_bing-0.5.10-py3-none-any.whl
| Download URL | arcane_bing-0.5.10-py3-none-any.whl |
|---|---|
| Size | 7.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
d84cf8352c1909108ea7ff06ed4f764a2c79944fb9bb0d581dea361b49165746
|
|
BLAKE2b-256 checksum How to use checksums |
0b3811d12ae52422d9dace6f569504dc964fedfb5e6764a2accbb52b305e7ca4
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/2.4.3 CPython/3.12.14 Linux/6.17.0-1022-azure
|