|
1 | | -#!/usr/bin/env node |
2 | | - |
3 | | -// ============================================================================= |
4 | | -// PRIMARY API - Simplified Setup (Recommended) |
5 | | -// ============================================================================= |
6 | | - |
7 | | -// Treasurer - core payment authorization |
| 1 | +// Simplified factories (recommended) |
8 | 2 | export { |
9 | 3 | createAmpersendTreasurer, |
10 | 4 | AmpersendTreasurer, |
11 | 5 | type AmpersendTreasurerConfig, |
12 | 6 | type SimpleAmpersendTreasurerConfig, |
13 | 7 | type FullAmpersendTreasurerConfig, |
14 | 8 | } from "./ampersend/index.ts" |
15 | | - |
16 | | -// MCP Proxy - simplified setup |
17 | 9 | export { createAmpersendProxy, type SimpleProxyOptions } from "./mcp/proxy/factory.ts" |
18 | | - |
19 | | -// MCP Client - simplified setup |
20 | 10 | export { createAmpersendMcpClient, type SimpleClientOptions } from "./mcp/client/factory.ts" |
21 | | - |
22 | | -// HTTP Client - simplified setup |
23 | 11 | export { createAmpersendHttpClient, type SimpleHttpClientOptions } from "./x402/http/factory.ts" |
24 | 12 |
|
25 | | -// ============================================================================= |
26 | | -// TYPES - For type annotations |
27 | | -// ============================================================================= |
| 13 | +// Types |
28 | 14 | export type { X402Treasurer, Authorization, PaymentContext, PaymentStatus } from "./x402/index.ts" |
29 | 15 | export type { X402Wallet, SmartAccountConfig } from "./x402/index.ts" |
30 | 16 |
|
31 | | -// ============================================================================= |
32 | | -// ADVANCED - Building blocks (NaiveTreasurer requires deep import) |
33 | | -// ============================================================================= |
34 | | - |
35 | | -// Wallets |
| 17 | +// Advanced building blocks |
36 | 18 | export { AccountWallet, SmartAccountWallet, WalletError } from "./x402/index.ts" |
37 | | - |
38 | | -// Advanced MCP (original functions that take treasurer directly) |
39 | 19 | export { initializeProxyServer } from "./mcp/proxy/index.ts" |
40 | 20 | export { Client } from "./mcp/client/index.ts" |
41 | | - |
42 | | -// Advanced HTTP |
43 | 21 | export { wrapWithAmpersend } from "./x402/http/index.ts" |
44 | | - |
45 | | -// ============================================================================= |
46 | | -// NOTE: NaiveTreasurer is NOT exported here - use deep import for testing: |
47 | | -// import { NaiveTreasurer } from "@ampersend_ai/ampersend-sdk/x402/treasurers" |
48 | | -// ============================================================================= |
0 commit comments