@getmcpads/meta-ads-mcp-server 1.0.0

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.
@@ -0,0 +1,47 @@
1
+ import { McpServer } from '@modelcontextprotocol/sdk/server/mcp.js';
2
+
3
+ /**
4
+ * meta-ads-mcp-server: an open-source MCP server for the Facebook (Meta) Ads API.
5
+ * Copyright 2026 GetMCPAds. https://www.getmcpads.com
6
+ * SPDX-License-Identifier: Apache-2.0
7
+ */
8
+ interface MetaConfig {
9
+ accessToken: string;
10
+ apiVersion?: string;
11
+ /**
12
+ * Write tools are registered only when this is true.
13
+ * Reading needs `ads_read`; writing needs `ads_management`.
14
+ */
15
+ enableWrites?: boolean;
16
+ }
17
+ interface ServerConfig {
18
+ meta?: MetaConfig;
19
+ logLevel: "debug" | "info" | "warn" | "error";
20
+ }
21
+
22
+ /**
23
+ * meta-ads-mcp-server: an open-source MCP server for the Facebook (Meta) Ads API.
24
+ * Copyright 2026 GetMCPAds. https://www.getmcpads.com
25
+ * SPDX-License-Identifier: Apache-2.0
26
+ */
27
+
28
+ declare const PACKAGE_VERSION = "1.0.0";
29
+ /**
30
+ * Create and configure the MCP server.
31
+ */
32
+ declare function createServer(config: ServerConfig): McpServer;
33
+
34
+ /**
35
+ * Load configuration from environment variables.
36
+ *
37
+ * `META_ACCESS_TOKEN` is the only required variable. Everything else is
38
+ * optional and has a sensible default.
39
+ */
40
+ declare function loadConfig(): ServerConfig;
41
+
42
+ /**
43
+ * Connect the MCP server to stdio transport (for Claude Desktop, Claude Code, Cursor).
44
+ */
45
+ declare function startStdioTransport(server: McpServer): Promise<void>;
46
+
47
+ export { type MetaConfig, PACKAGE_VERSION, type ServerConfig, createServer, loadConfig, startStdioTransport };