// the find
facebook/facebook-python-business-sdk
Python SDK for Meta Marketing APIs
Official Facebook/Meta Python SDK for the Marketing API and related Business APIs. Covers campaigns, ad sets, creatives, custom audiences, pixels, and more. Primarily useful for ad tech companies, agencies, and tools that need to programmatically manage Meta advertising accounts.
- Auto-generated from the API codegen tool, so object definitions stay in sync with the actual API surface — you get Field classes with string constants instead of magic strings scattered everywhere
- Batch request support is well-integrated: you can queue calls and flush them together, which matters a lot when dealing with rate limits at scale
- Large example library covering most common use cases (campaign creation, custom audiences, DPA, server-side API, async requests), which compensates for sparse inline documentation
- Multi-session support for handling multiple access tokens in the same process is handled cleanly via separate FacebookAdsApi instances
- README still documents Python 2.7 sys.path hacks and 'python2.7/site-packages' paths — this is embarrassing in 2024 and signals the docs haven't been seriously maintained
- No type hints anywhere in the adobjects layer; everything returns generic dict-like objects, so IDE autocomplete is useless and you won't catch field name typos until runtime
- Bug reporting was moved off GitHub issues entirely to Meta's developer bug channel, which historically has slow response times and zero public visibility — you can't search previous issues to see if your problem is known
- The SDK is entirely request/response shaped around the older Graph API patterns; there's no async/await support, so high-concurrency use cases require workarounds or threads