Skip to content

Commit 1653e90

Browse files
npslaneyclaude
andcommitted
refactor(api-contract): remove mcpContract, use unified contract
Remove the separate mcp/ directory and mcpContract export. All contracts are now in the unified contract object. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
1 parent 05c871c commit 1653e90

6 files changed

Lines changed: 1 addition & 263 deletions

File tree

src/contracts/mcp/checkouts.ts

Lines changed: 0 additions & 68 deletions
This file was deleted.

src/contracts/mcp/customers.ts

Lines changed: 0 additions & 56 deletions
This file was deleted.

src/contracts/mcp/index.ts

Lines changed: 0 additions & 15 deletions
This file was deleted.

src/contracts/mcp/orders.ts

Lines changed: 0 additions & 39 deletions
This file was deleted.

src/contracts/mcp/products.ts

Lines changed: 0 additions & 66 deletions
This file was deleted.

src/index.ts

Lines changed: 1 addition & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,5 @@
11
import { checkout } from "./contracts/checkout";
22
import { customer } from "./contracts/customer";
3-
import {
4-
checkouts as mcpCheckouts,
5-
customers as mcpCustomers,
6-
orders as mcpOrders,
7-
products as mcpProducts,
8-
} from "./contracts/mcp";
93
import { onboarding } from "./contracts/onboarding";
104
import { order } from "./contracts/order";
115
import { products } from "./contracts/products";
@@ -59,21 +53,9 @@ export {
5953
RecurringIntervalInputSchema,
6054
} from "./schemas/product-price-input";
6155

62-
// SDK contract - consumed by SDK clients
56+
// Unified contract - consumed by both SDK and MCP
6357
export const contract = { checkout, customer, onboarding, order, products };
6458

65-
/**
66-
* MCP contract - separate namespace for MCP tools.
67-
* NOT consumed by SDK, only by MCP server via /rpc/mcp endpoint.
68-
* Uses OAuth authentication (not API key auth).
69-
*/
70-
export const mcpContract = {
71-
customers: mcpCustomers,
72-
products: mcpProducts,
73-
orders: mcpOrders,
74-
checkouts: mcpCheckouts,
75-
};
76-
7759
export type { MetadataValidationError } from "./validation/metadata-validation";
7860
export {
7961
MAX_KEY_COUNT,

0 commit comments

Comments
 (0)