meta-ads-mcp 0.10.1__tar.gz → 0.10.2__tar.gz

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.
Files changed (76) hide show
  1. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/PKG-INFO +7 -17
  2. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/README.md +6 -16
  3. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/meta_ads_mcp/__init__.py +1 -1
  4. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/meta_ads_mcp/core/adsets.py +4 -3
  5. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/pyproject.toml +1 -1
  6. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/tests/test_mobile_app_adset_creation.py +51 -0
  7. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/.github/workflows/publish.yml +0 -0
  8. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/.github/workflows/test.yml +0 -0
  9. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/.gitignore +0 -0
  10. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/CUSTOM_META_APP.md +0 -0
  11. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/Dockerfile +0 -0
  12. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/LICENSE +0 -0
  13. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/LOCAL_INSTALLATION.md +0 -0
  14. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/META_API_NOTES.md +0 -0
  15. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/RELEASE.md +0 -0
  16. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/STREAMABLE_HTTP_SETUP.md +0 -0
  17. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/examples/README.md +0 -0
  18. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/examples/example_http_client.py +0 -0
  19. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/future_improvements.md +0 -0
  20. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/images/meta-ads-example.png +0 -0
  21. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/meta_ads_auth.sh +0 -0
  22. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/meta_ads_mcp/__main__.py +0 -0
  23. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/meta_ads_mcp/core/__init__.py +0 -0
  24. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/meta_ads_mcp/core/accounts.py +0 -0
  25. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/meta_ads_mcp/core/ads.py +0 -0
  26. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/meta_ads_mcp/core/ads_library.py +0 -0
  27. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/meta_ads_mcp/core/api.py +0 -0
  28. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/meta_ads_mcp/core/auth.py +0 -0
  29. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/meta_ads_mcp/core/authentication.py +0 -0
  30. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/meta_ads_mcp/core/budget_schedules.py +0 -0
  31. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/meta_ads_mcp/core/callback_server.py +0 -0
  32. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/meta_ads_mcp/core/campaigns.py +0 -0
  33. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/meta_ads_mcp/core/duplication.py +0 -0
  34. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/meta_ads_mcp/core/http_auth_integration.py +0 -0
  35. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/meta_ads_mcp/core/insights.py +0 -0
  36. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/meta_ads_mcp/core/openai_deep_research.py +0 -0
  37. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/meta_ads_mcp/core/pipeboard_auth.py +0 -0
  38. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/meta_ads_mcp/core/reports.py +0 -0
  39. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/meta_ads_mcp/core/resources.py +0 -0
  40. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/meta_ads_mcp/core/server.py +0 -0
  41. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/meta_ads_mcp/core/targeting.py +0 -0
  42. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/meta_ads_mcp/core/utils.py +0 -0
  43. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/requirements.txt +0 -0
  44. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/setup.py +0 -0
  45. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/smithery.yaml +0 -0
  46. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/tests/README.md +0 -0
  47. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/tests/README_REGRESSION_TESTS.md +0 -0
  48. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/tests/__init__.py +0 -0
  49. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/tests/conftest.py +0 -0
  50. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/tests/e2e_account_info_search_issue.py +0 -0
  51. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/tests/test_account_info_access_fix.py +0 -0
  52. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/tests/test_account_search.py +0 -0
  53. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/tests/test_budget_update.py +0 -0
  54. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/tests/test_budget_update_e2e.py +0 -0
  55. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/tests/test_dsa_beneficiary.py +0 -0
  56. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/tests/test_dsa_integration.py +0 -0
  57. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/tests/test_duplication.py +0 -0
  58. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/tests/test_duplication_regression.py +0 -0
  59. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/tests/test_dynamic_creatives.py +0 -0
  60. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/tests/test_estimate_audience_size.py +0 -0
  61. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/tests/test_estimate_audience_size_e2e.py +0 -0
  62. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/tests/test_get_account_pages.py +0 -0
  63. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/tests/test_get_ad_creatives_fix.py +0 -0
  64. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/tests/test_get_ad_image_quality_improvements.py +0 -0
  65. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/tests/test_get_ad_image_regression.py +0 -0
  66. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/tests/test_http_transport.py +0 -0
  67. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/tests/test_insights_actions_and_values.py +0 -0
  68. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/tests/test_integration_openai_mcp.py +0 -0
  69. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/tests/test_mobile_app_adset_issue.py +0 -0
  70. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/tests/test_openai.py +0 -0
  71. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/tests/test_openai_mcp_deep_research.py +0 -0
  72. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/tests/test_page_discovery.py +0 -0
  73. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/tests/test_page_discovery_integration.py +0 -0
  74. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/tests/test_targeting.py +0 -0
  75. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/tests/test_targeting_search_e2e.py +0 -0
  76. {meta_ads_mcp-0.10.1 → meta_ads_mcp-0.10.2}/tests/test_update_ad_creative_id.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: meta-ads-mcp
3
- Version: 0.10.1
3
+ Version: 0.10.2
4
4
  Summary: Model Context Protocol (MCP) server for interacting with Meta Ads API
5
5
  Project-URL: Homepage, https://github.com/pipeboard-co/meta-ads-mcp
6
6
  Project-URL: Bug Tracker, https://github.com/pipeboard-co/meta-ads-mcp/issues
@@ -410,24 +410,14 @@ For local installation configuration, authentication options, and advanced techn
410
410
 
411
411
  ## Licensing
412
412
 
413
- Meta Ads MCP is licensed under the [Business Source License 1.1](LICENSE). This means:
413
+ Meta Ads MCP is licensed under the [Business Source License 1.1](LICENSE), which means:
414
414
 
415
- ### ✅ **What you CAN do:**
416
- - ✅ **Use for free** - Individual and business use at no cost
417
- - ✅ **Modify and customize** - Edit the source code for your needs
418
- - ✅ **Internal commercial use** - Deploy within your organization
419
- - ✅ **Redistribute** - Share the software with others
420
- - ✅ **Create derivative works** - Build upon the codebase
415
+ - ✅ **Free to use** for individual and business purposes
416
+ - ✅ **Modify and customize** as needed
417
+ - ✅ **Redistribute** to others
418
+ - ✅ **Becomes fully open source** (Apache 2.0) on January 1, 2029
421
419
 
422
- ### **What you CANNOT do:**
423
- - ❌ **Offer as competing SaaS** - Cannot offer this as a hosted service that competes with ARTELL SOLUÇÕES TECNOLÓGICAS LTDA's commercial offerings
424
-
425
- ### 🔄 **Future Open Source:**
426
- - **Change Date**: January 1, 2029
427
- - **After Change Date**: Automatically converts to Apache License 2.0 (fully open source)
428
- - **No restrictions**: After the change date, you can use it for any purpose, including competing services
429
-
430
- This licensing model ensures the software remains accessible while protecting the commercial interests of the original developers. For questions about commercial licensing or use cases, please contact us.
420
+ The only restriction is that you cannot offer this as a competing hosted service. For questions about commercial licensing, please contact us.
431
421
 
432
422
  ## Privacy and Security
433
423
 
@@ -385,24 +385,14 @@ For local installation configuration, authentication options, and advanced techn
385
385
 
386
386
  ## Licensing
387
387
 
388
- Meta Ads MCP is licensed under the [Business Source License 1.1](LICENSE). This means:
388
+ Meta Ads MCP is licensed under the [Business Source License 1.1](LICENSE), which means:
389
389
 
390
- ### ✅ **What you CAN do:**
391
- - ✅ **Use for free** - Individual and business use at no cost
392
- - ✅ **Modify and customize** - Edit the source code for your needs
393
- - ✅ **Internal commercial use** - Deploy within your organization
394
- - ✅ **Redistribute** - Share the software with others
395
- - ✅ **Create derivative works** - Build upon the codebase
390
+ - ✅ **Free to use** for individual and business purposes
391
+ - ✅ **Modify and customize** as needed
392
+ - ✅ **Redistribute** to others
393
+ - ✅ **Becomes fully open source** (Apache 2.0) on January 1, 2029
396
394
 
397
- ### **What you CANNOT do:**
398
- - ❌ **Offer as competing SaaS** - Cannot offer this as a hosted service that competes with ARTELL SOLUÇÕES TECNOLÓGICAS LTDA's commercial offerings
399
-
400
- ### 🔄 **Future Open Source:**
401
- - **Change Date**: January 1, 2029
402
- - **After Change Date**: Automatically converts to Apache License 2.0 (fully open source)
403
- - **No restrictions**: After the change date, you can use it for any purpose, including competing services
404
-
405
- This licensing model ensures the software remains accessible while protecting the commercial interests of the original developers. For questions about commercial licensing or use cases, please contact us.
395
+ The only restriction is that you cannot offer this as a competing hosted service. For questions about commercial licensing, please contact us.
406
396
 
407
397
  ## Privacy and Security
408
398
 
@@ -7,7 +7,7 @@ with the Claude LLM.
7
7
 
8
8
  from meta_ads_mcp.core.server import main
9
9
 
10
- __version__ = "0.10.1"
10
+ __version__ = "0.10.2"
11
11
 
12
12
  __all__ = [
13
13
  'get_ad_accounts',
@@ -130,8 +130,9 @@ async def create_adset(
130
130
  promoted_object: Mobile app configuration for APP_INSTALLS campaigns. Required fields: application_id, object_store_url.
131
131
  Optional fields: custom_event_type, pixel_id, page_id.
132
132
  Example: {"application_id": "123456789012345", "object_store_url": "https://apps.apple.com/app/id123456789"}
133
- destination_type: Where users are directed after clicking the ad (e.g., 'APP_STORE', 'DEEPLINK', 'APP_INSTALL').
134
- Required for mobile app campaigns.
133
+ destination_type: Where users are directed after clicking the ad (e.g., 'APP_STORE', 'DEEPLINK', 'APP_INSTALL', 'ON_AD').
134
+ Required for mobile app campaigns and lead generation campaigns.
135
+ Use 'ON_AD' for lead generation campaigns where user interaction happens within the ad.
135
136
  access_token: Meta API access token (optional - will use cached token if not provided)
136
137
  """
137
138
  # Check required parameters
@@ -196,7 +197,7 @@ async def create_adset(
196
197
 
197
198
  # Validate destination_type if provided
198
199
  if destination_type:
199
- valid_destination_types = ["APP_STORE", "DEEPLINK", "APP_INSTALL"]
200
+ valid_destination_types = ["APP_STORE", "DEEPLINK", "APP_INSTALL", "ON_AD"]
200
201
  if destination_type not in valid_destination_types:
201
202
  return json.dumps({
202
203
  "error": f"Invalid destination_type: {destination_type}",
@@ -4,7 +4,7 @@ build-backend = "hatchling.build"
4
4
 
5
5
  [project]
6
6
  name = "meta-ads-mcp"
7
- version = "0.10.1"
7
+ version = "0.10.2"
8
8
  description = "Model Context Protocol (MCP) server for interacting with Meta Ads API"
9
9
  readme = "README.md"
10
10
  requires-python = ">=3.10"
@@ -409,6 +409,57 @@ class TestMobileAppAdsetCreation:
409
409
  params = call_args[0][2]
410
410
  assert params['destination_type'] == "APP_INSTALL"
411
411
 
412
+ @pytest.mark.asyncio
413
+ async def test_on_ad_destination_type_for_lead_generation(
414
+ self, mock_api_request, mock_auth_manager, valid_mobile_app_params
415
+ ):
416
+ """Test ON_AD destination_type for lead generation campaigns (Issue #009 fix)"""
417
+
418
+ # Create a lead generation adset configuration (without promoted_object since it's for lead gen, not mobile apps)
419
+ lead_gen_params = valid_mobile_app_params.copy()
420
+ lead_gen_params.update({
421
+ "optimization_goal": "LEAD_GENERATION",
422
+ "billing_event": "IMPRESSIONS"
423
+ })
424
+
425
+ result = await create_adset(
426
+ **lead_gen_params,
427
+ destination_type="ON_AD"
428
+ )
429
+
430
+ # Should pass validation and include destination_type in API call
431
+ call_args = mock_api_request.call_args
432
+ params = call_args[0][2]
433
+ assert params['destination_type'] == "ON_AD"
434
+
435
+ @pytest.mark.asyncio
436
+ async def test_on_ad_validation_passes(
437
+ self, mock_api_request, mock_auth_manager, valid_mobile_app_params
438
+ ):
439
+ """Test that ON_AD destination_type passes validation (Issue #009 regression test)"""
440
+
441
+ # Use parameters that work with ON_AD (lead generation, not mobile app)
442
+ lead_gen_params = valid_mobile_app_params.copy()
443
+ lead_gen_params.update({
444
+ "optimization_goal": "LEAD_GENERATION",
445
+ "billing_event": "IMPRESSIONS"
446
+ })
447
+
448
+ result = await create_adset(
449
+ **lead_gen_params,
450
+ destination_type="ON_AD"
451
+ )
452
+
453
+ result_data = json.loads(result)
454
+
455
+ # Should NOT return a validation error about destination_type
456
+ # Before the fix, this would return: "Invalid destination_type: ON_AD"
457
+ if "data" in result_data:
458
+ error_data = json.loads(result_data["data"])
459
+ assert "error" not in error_data or "destination_type" not in error_data.get("error", "").lower()
460
+ else:
461
+ assert "error" not in result_data or "destination_type" not in result_data.get("error", "").lower()
462
+
412
463
  # Test: Error Handling
413
464
  @pytest.mark.asyncio
414
465
  async def test_meta_api_error_handling(
File without changes
File without changes
File without changes
File without changes
File without changes