From b75e6158412524a5530a07b38817c02dc61a2cc1 Mon Sep 17 00:00:00 2001 From: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com> Date: Wed, 6 May 2026 18:06:53 +0000 Subject: [PATCH] Add manifest.json, tool annotations, and privacy policy for Anthropic Connector listing - Add manifest.json per DXT spec v0.3 with author, server config, user_config, and privacy_policies - Add title and readOnlyHint annotations to all 72 tools across 15 files - Add Privacy Policy section to README.md referencing https://www.pexcard.com/legal/privacy-policy/ Addresses user stories #136503, #136504, #136505 under feature #136502. Co-Authored-By: tbaker@pexcard.com --- README.md | 4 +++ manifest.json | 48 ++++++++++++++++++++++++++ src/tools/bill.ts | 8 +++++ src/tools/business.ts | 60 ++++++++++++++++++++++++++++----- src/tools/callback.ts | 10 +++++- src/tools/card.ts | 14 ++++++++ src/tools/credit.ts | 12 ++++++- src/tools/details.ts | 20 +++++++++++ src/tools/group.ts | 8 ++++- src/tools/partner.ts | 6 +++- src/tools/payment.ts | 6 ++++ src/tools/spending-ruleset.ts | 22 ++++++++++-- src/tools/token-provisioning.ts | 10 +++++- src/tools/token.ts | 18 ++++++++-- src/tools/transactions.ts | 20 +++++++++++ src/tools/vendor-card.ts | 2 ++ src/tools/vendor.ts | 4 +++ 17 files changed, 253 insertions(+), 19 deletions(-) create mode 100644 manifest.json diff --git a/README.md b/README.md index aad3fc8..741713a 100644 --- a/README.md +++ b/README.md @@ -258,6 +258,10 @@ Once connected, you can ask Claude things like: - "What are the spending rules for card 12345?" - "Show me pending payments" +## Privacy Policy + +The PEX MCP Server acts as a pass-through to the PEX Card API. It does not independently collect, store, or transmit user data beyond what is required to fulfill API requests. All data handling is governed by the [PEX Privacy Policy](https://www.pexcard.com/legal/privacy-policy/). + ## License MIT diff --git a/manifest.json b/manifest.json new file mode 100644 index 0000000..4101781 --- /dev/null +++ b/manifest.json @@ -0,0 +1,48 @@ +{ + "manifest_version": "0.3", + "name": "pex-mcp-server", + "display_name": "PEX Card", + "version": "1.0.3", + "description": "Access PEX business accounts, cards, transactions, and more", + "author": { + "name": "PEX Card", + "url": "https://github.com/pexcard" + }, + "repository": { + "type": "git", + "url": "https://github.com/pexcard/mcp.git" + }, + "homepage": "https://github.com/pexcard/mcp", + "server": { + "type": "node", + "entry_point": "dist/index.js", + "mcp_config": { + "command": "node", + "args": ["${__dirname}/dist/index.js"], + "env": { + "PEX_API_URL": "${user_config.pex_api_url}", + "PEX_API_TOKEN": "${user_config.pex_api_token}" + } + } + }, + "tools_generated": true, + "keywords": ["pex", "expense-management", "corporate-cards", "finance"], + "license": "MIT", + "privacy_policies": ["https://www.pexcard.com/legal/privacy-policy/"], + "user_config": { + "pex_api_url": { + "type": "string", + "title": "PEX API URL", + "description": "PEX API base URL", + "required": true, + "default": "https://coreapi.pexcard.com/v4" + }, + "pex_api_token": { + "type": "string", + "title": "PEX API Token", + "description": "Your PEX API authentication token", + "sensitive": true, + "required": true + } + } +} diff --git a/src/tools/bill.ts b/src/tools/bill.ts index 23a0fc2..7570d00 100644 --- a/src/tools/bill.ts +++ b/src/tools/bill.ts @@ -7,7 +7,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_bill", { + title: "Get Bill", description: "Get bill payment details by bill ID", + annotations: { readOnlyHint: true }, inputSchema: { billId: z.number().describe("Bill ID"), }, @@ -25,7 +27,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_bill_payments", { + title: "Get Bill Payments", description: "Get payments for a specific bill", + annotations: { readOnlyHint: true }, inputSchema: { billId: z.number().describe("Bill ID"), }, @@ -43,7 +47,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_bill_payment_request", { + title: "Get Bill Payment Request", description: "Get a specific bill payment request by ID", + annotations: { readOnlyHint: true }, inputSchema: { id: z.number().describe("Bill payment request ID"), }, @@ -61,7 +67,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_search_bills", { + title: "Search Bills", description: "Search bills with optional filters", + annotations: { readOnlyHint: true }, inputSchema: { createdDateFrom: z.string().optional().describe("Created date from (ISO 8601)"), createdDateTo: z.string().optional().describe("Created date to (ISO 8601)"), diff --git a/src/tools/business.ts b/src/tools/business.ts index 5849866..4bd33f9 100644 --- a/src/tools/business.ts +++ b/src/tools/business.ts @@ -6,7 +6,11 @@ import { toolResponse, toolError } from "./utils.js"; export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_business_profile", - { description: "Get business profile details including name, address, phone, and status" }, + { + title: "Get Business Profile", + description: "Get business profile details including name, address, phone, and status", + annotations: { readOnlyHint: true }, + }, async () => { try { const result = await client.get("/Business/Profile"); @@ -19,7 +23,11 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_business_balance", - { description: "Get business account balance" }, + { + title: "Get Business Balance", + description: "Get business account balance", + annotations: { readOnlyHint: true }, + }, async () => { try { const result = await client.get("/Business/Balance"); @@ -32,7 +40,11 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_business_admins", - { description: "Get list of all business administrators" }, + { + title: "Get Business Admins", + description: "Get list of all business administrators", + annotations: { readOnlyHint: true }, + }, async () => { try { const result = await client.get("/Business/Admin"); @@ -46,7 +58,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_business_admin", { + title: "Get Business Admin", description: "Get a specific business administrator by ID", + annotations: { readOnlyHint: true }, inputSchema: { id: z.number().describe("Administrator ID"), }, @@ -63,7 +77,11 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_business_tags", - { description: "Get all business tags" }, + { + title: "Get Business Tags", + description: "Get all business tags", + annotations: { readOnlyHint: true }, + }, async () => { try { const result = await client.get("/Business/Configuration/Tags"); @@ -77,7 +95,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_business_tag", { + title: "Get Business Tag", description: "Get a specific business tag by ID", + annotations: { readOnlyHint: true }, inputSchema: { id: z.number().describe("Tag ID"), }, @@ -94,7 +114,11 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_business_linked", - { description: "Get linked businesses" }, + { + title: "Get Linked Businesses", + description: "Get linked businesses", + annotations: { readOnlyHint: true }, + }, async () => { try { const result = await client.get("/Business/Linked"); @@ -107,7 +131,11 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_business_bank_account", - { description: "Get business bank account details" }, + { + title: "Get Business Bank Account", + description: "Get business bank account details", + annotations: { readOnlyHint: true }, + }, async () => { try { const result = await client.get("/Business/BankAccount"); @@ -120,7 +148,11 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_business_one_time_transfer", - { description: "Get business one-time transfer details" }, + { + title: "Get Business One-Time Transfer", + description: "Get business one-time transfer details", + annotations: { readOnlyHint: true }, + }, async () => { try { const result = await client.get("/Business/OneTimeTransfer"); @@ -133,7 +165,11 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_business_my_profile", - { description: "Get the current user's business profile" }, + { + title: "Get My Business Profile", + description: "Get the current user's business profile", + annotations: { readOnlyHint: true }, + }, async () => { try { const result = await client.get("/Business/MyProfile"); @@ -147,8 +183,10 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_business_billing", { + title: "Get Business Billing", description: "Get business billing information for a specific month. Current month values are estimates; finalized after billing cycle ends.", + annotations: { readOnlyHint: true }, inputSchema: { month: z.number().describe("Month (1–12)"), year: z.number().describe("Year (e.g. 2025)"), @@ -166,7 +204,11 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_business_settings", - { description: "Get business settings" }, + { + title: "Get Business Settings", + description: "Get business settings", + annotations: { readOnlyHint: true }, + }, async () => { try { const result = await client.get("/Business/Settings"); diff --git a/src/tools/callback.ts b/src/tools/callback.ts index b4d7779..61a94e5 100644 --- a/src/tools/callback.ts +++ b/src/tools/callback.ts @@ -6,7 +6,11 @@ import { toolResponse, toolError } from "./utils.js"; export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_callback_types", - { description: "Get available callback subscription types" }, + { + title: "Get Callback Types", + description: "Get available callback subscription types", + annotations: { readOnlyHint: true }, + }, async () => { try { const result = await client.get("/callback-subscription/types"); @@ -20,7 +24,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_list_callback_subscriptions", { + title: "List Callback Subscriptions", description: "Get all callback subscriptions for the business, optionally filtered by type", + annotations: { readOnlyHint: true }, inputSchema: { type: z .string() @@ -43,7 +49,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_callback_subscription", { + title: "Get Callback Subscription", description: "Get a specific callback subscription by ID", + annotations: { readOnlyHint: true }, inputSchema: { id: z.number().describe("Subscription ID"), }, diff --git a/src/tools/card.ts b/src/tools/card.ts index 1325a08..82cd10b 100644 --- a/src/tools/card.ts +++ b/src/tools/card.ts @@ -7,7 +7,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_card", { + title: "Get Card", description: "Get card profile/details by card account ID", + annotations: { readOnlyHint: true }, inputSchema: { id: z.number().describe("Card account ID"), }, @@ -25,7 +27,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_card_spend_rules", { + title: "Get Card Spend Rules", description: "Get spending rules for a specific card", + annotations: { readOnlyHint: true }, inputSchema: { id: z.number().describe("Card account ID"), }, @@ -43,7 +47,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_card_advanced_spend_rules", { + title: "Get Card Advanced Spend Rules", description: "Get advanced spending rules for a specific card", + annotations: { readOnlyHint: true }, inputSchema: { id: z.number().describe("Card account ID"), }, @@ -61,7 +67,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_card_load_limit_remaining", { + title: "Get Card Load Limit Remaining", description: "Get remaining card load limit for a specific card", + annotations: { readOnlyHint: true }, inputSchema: { id: z.number().describe("Card account ID"), }, @@ -79,7 +87,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_card_order", { + title: "Get Card Order", description: "Get a specific card order by ID", + annotations: { readOnlyHint: true }, inputSchema: { id: z.number().describe("Card order ID"), }, @@ -97,7 +107,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_card_scheduled_funding_rules", { + title: "Get Card Scheduled Funding Rules", description: "Get scheduled funding rules for a specific card", + annotations: { readOnlyHint: true }, inputSchema: { id: z.number().describe("Card account ID"), }, @@ -115,7 +127,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_card_orders", { + title: "Get Card Orders", description: "Get card orders within an optional date range", + annotations: { readOnlyHint: true }, inputSchema: { startDate: z.string().optional().describe("Start date (ISO 8601)"), endDate: z.string().optional().describe("End date (ISO 8601)"), diff --git a/src/tools/credit.ts b/src/tools/credit.ts index f008f25..dccd81a 100644 --- a/src/tools/credit.ts +++ b/src/tools/credit.ts @@ -6,7 +6,11 @@ import { toolResponse, toolError } from "./utils.js"; export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_credit_lines", - { description: "Get credit line information for the business" }, + { + title: "Get Credit Lines", + description: "Get credit line information for the business", + annotations: { readOnlyHint: true }, + }, async () => { try { const result = await client.get("/CreditLinesInfo"); @@ -20,7 +24,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_invoices", { + title: "Get Invoices", description: "Get business invoices starting from a given date", + annotations: { readOnlyHint: true }, inputSchema: { startDate: z.string().describe("Start date (ISO 8601 date-time)"), }, @@ -38,7 +44,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_invoice_allocations", { + title: "Get Invoice Allocations", description: "Get allocations for a specific invoice", + annotations: { readOnlyHint: true }, inputSchema: { id: z.number().describe("Invoice ID"), }, @@ -56,7 +64,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_invoice_payments", { + title: "Get Invoice Payments", description: "Get payments for a specific invoice", + annotations: { readOnlyHint: true }, inputSchema: { id: z.number().describe("Invoice ID"), }, diff --git a/src/tools/details.ts b/src/tools/details.ts index f38d971..5b2e4e8 100644 --- a/src/tools/details.ts +++ b/src/tools/details.ts @@ -7,7 +7,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_account_details", { + title: "Get Account Details", description: "Get cardholder account details by account ID", + annotations: { readOnlyHint: true }, inputSchema: { id: z.number().describe("Account ID"), }, @@ -25,7 +27,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_advanced_account_details", { + title: "Get Advanced Account Details", description: "Get advanced cardholder account details by account ID", + annotations: { readOnlyHint: true }, inputSchema: { id: z.number().describe("Account ID"), }, @@ -43,7 +47,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_network_transactions", { + title: "Get Network Transactions", description: "Get network transactions for the business within a date range. Results are paginated.", + annotations: { readOnlyHint: true }, inputSchema: { startDate: z.string().describe("Start date (ISO 8601)"), endDate: z.string().describe("End date (ISO 8601)"), @@ -72,7 +78,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_cardholder_network_transactions", { + title: "Get Cardholder Network Transactions", description: "Get network transactions for a specific cardholder within a date range", + annotations: { readOnlyHint: true }, inputSchema: { id: z.number().describe("Cardholder account ID"), startDate: z.string().describe("Start date (ISO 8601)"), @@ -95,7 +103,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_transaction_detail", { + title: "Get Transaction Detail", description: "Get transaction details for a specific transaction by ID", + annotations: { readOnlyHint: true }, inputSchema: { id: z.number().describe("Transaction ID"), }, @@ -113,7 +123,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_all_account_details", { + title: "Get All Account Details", description: "Get all cardholder account details for the business. Results are paginated to handle large datasets.", + annotations: { readOnlyHint: true }, inputSchema: { page: z.number().optional().default(1).describe("Page number (1-based, default: 1)"), pageSize: z.number().optional().default(50).describe("Results per page (default: 50, max: 100)"), @@ -137,7 +149,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_account_balance", { + title: "Get Account Balance", description: "Get account balance for a specific cardholder", + annotations: { readOnlyHint: true }, inputSchema: { id: z.number().describe("Account ID"), }, @@ -155,7 +169,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_account_remaining_limits", { + title: "Get Account Remaining Limits", description: "Get remaining spending limits for a specific cardholder", + annotations: { readOnlyHint: true }, inputSchema: { id: z.number().describe("Account ID"), }, @@ -173,7 +189,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_transaction_details", { + title: "Get Transaction Details", description: "Get transaction details for the business within a date range. Results are paginated.", + annotations: { readOnlyHint: true }, inputSchema: { startDate: z.string().describe("Start date (ISO 8601)"), endDate: z.string().describe("End date (ISO 8601)"), @@ -206,7 +224,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_all_cardholder_transactions", { + title: "Get All Cardholder Transactions", description: "Get all cardholder transactions within a date range. Results are paginated.", + annotations: { readOnlyHint: true }, inputSchema: { startDate: z.string().describe("Start date (ISO 8601)"), endDate: z.string().describe("End date (ISO 8601)"), diff --git a/src/tools/group.ts b/src/tools/group.ts index ec441e8..af3d5fa 100644 --- a/src/tools/group.ts +++ b/src/tools/group.ts @@ -6,7 +6,11 @@ import { toolResponse, toolError, paginateArray } from "./utils.js"; export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_list_groups", - { description: "Get all cardholder groups for the business" }, + { + title: "List Groups", + description: "Get all cardholder groups for the business", + annotations: { readOnlyHint: true }, + }, async () => { try { const result = await client.get("/Group"); @@ -20,7 +24,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_group_cardholders", { + title: "Get Group Cardholders", description: "Get cardholders belonging to a specific group. Results are paginated.", + annotations: { readOnlyHint: true }, inputSchema: { id: z.number().describe("Group ID"), page: z.number().optional().default(1).describe("Page number (1-based, default: 1)"), diff --git a/src/tools/partner.ts b/src/tools/partner.ts index 88853eb..d9ca0f4 100644 --- a/src/tools/partner.ts +++ b/src/tools/partner.ts @@ -5,7 +5,11 @@ import { toolResponse, toolError } from "./utils.js"; export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_partner", - { description: "Get partner details for the current business" }, + { + title: "Get Partner", + description: "Get partner details for the current business", + annotations: { readOnlyHint: true }, + }, async () => { try { const result = await client.get("/Partner"); diff --git a/src/tools/payment.ts b/src/tools/payment.ts index f7329aa..369c198 100644 --- a/src/tools/payment.ts +++ b/src/tools/payment.ts @@ -7,8 +7,10 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_payments", { + title: "Get Payments", description: "Get paginated list of business payments with optional filtering by status, dates, etc.", + annotations: { readOnlyHint: true }, inputSchema: { page: z.number().optional().describe("Page number (1-based)"), size: z.number().optional().describe("Results per page"), @@ -73,7 +75,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_payment_transfer", { + title: "Get Payment Transfer", description: "Get a specific payment transfer by ID", + annotations: { readOnlyHint: true }, inputSchema: { id: z.number().describe("Transfer ID"), }, @@ -91,7 +95,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_payment_request", { + title: "Get Payment Request", description: "Get a specific payment request by ID", + annotations: { readOnlyHint: true }, inputSchema: { id: z.number().describe("Payment request ID"), }, diff --git a/src/tools/spending-ruleset.ts b/src/tools/spending-ruleset.ts index 53a69cc..2834adb 100644 --- a/src/tools/spending-ruleset.ts +++ b/src/tools/spending-ruleset.ts @@ -6,7 +6,11 @@ import { toolResponse, toolError, paginateArray } from "./utils.js"; export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_list_spending_rulesets", - { description: "Get all spending rulesets for the business" }, + { + title: "List Spending Rulesets", + description: "Get all spending rulesets for the business", + annotations: { readOnlyHint: true }, + }, async () => { try { const result = await client.get("/SpendingRuleset"); @@ -20,7 +24,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_spending_ruleset", { + title: "Get Spending Ruleset", description: "Get a specific spending ruleset by ID", + annotations: { readOnlyHint: true }, inputSchema: { id: z.number().describe("Ruleset ID"), }, @@ -38,7 +44,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_spending_ruleset_cards", { + title: "Get Spending Ruleset Cards", description: "Get cards assigned to a specific spending ruleset. Results are paginated.", + annotations: { readOnlyHint: true }, inputSchema: { id: z.number().describe("Ruleset ID"), page: z.number().optional().default(1).describe("Page number (1-based, default: 1)"), @@ -58,7 +66,11 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_list_advanced_spending_rulesets", - { description: "Get all advanced spending rulesets for the business" }, + { + title: "List Advanced Spending Rulesets", + description: "Get all advanced spending rulesets for the business", + annotations: { readOnlyHint: true }, + }, async () => { try { const result = await client.get("/SpendingRuleset/Advanced"); @@ -72,8 +84,10 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_mcc_categories", { + title: "Get MCC Categories", description: "Get Merchant Category Code (MCC) categories. Filter by predefined and/or custom categories.", + annotations: { readOnlyHint: true }, inputSchema: { includePredefined: z.boolean().optional().describe("Include predefined categories"), includeCustom: z.boolean().optional().describe("Include custom categories"), @@ -95,7 +109,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_advanced_spending_ruleset", { + title: "Get Advanced Spending Ruleset", description: "Get a specific advanced spending ruleset by ID", + annotations: { readOnlyHint: true }, inputSchema: { id: z.number().describe("Ruleset ID"), }, @@ -113,7 +129,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_advanced_spending_ruleset_cards", { + title: "Get Advanced Spending Ruleset Cards", description: "Get cards assigned to a specific advanced spending ruleset. Results are paginated.", + annotations: { readOnlyHint: true }, inputSchema: { id: z.number().describe("Ruleset ID"), page: z.number().optional().default(1).describe("Page number (1-based, default: 1)"), diff --git a/src/tools/token-provisioning.ts b/src/tools/token-provisioning.ts index 86e9fe6..d0c3841 100644 --- a/src/tools/token-provisioning.ts +++ b/src/tools/token-provisioning.ts @@ -6,7 +6,11 @@ import { toolResponse, toolError } from "./utils.js"; export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_token_provisioning_mode", - { description: "Get the business token provisioning mode" }, + { + title: "Get Token Provisioning Mode", + description: "Get the business token provisioning mode", + annotations: { readOnlyHint: true }, + }, async () => { try { const result = await client.get("/TokenProvisioning/Mode"); @@ -20,7 +24,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_cardholder_provisioning_mode", { + title: "Get Cardholder Provisioning Mode", description: "Get token provisioning mode for a specific cardholder", + annotations: { readOnlyHint: true }, inputSchema: { id: z.number().describe("Cardholder account ID"), }, @@ -38,7 +44,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_issued_tokens", { + title: "Get Issued Tokens", description: "Get issued tokens for a specific cardholder", + annotations: { readOnlyHint: true }, inputSchema: { id: z.number().describe("Cardholder account ID"), }, diff --git a/src/tools/token.ts b/src/tools/token.ts index 7abf8e2..92522f3 100644 --- a/src/tools/token.ts +++ b/src/tools/token.ts @@ -5,7 +5,11 @@ import { toolResponse, toolError } from "./utils.js"; export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_current_token", - { description: "Get details of the current authentication token" }, + { + title: "Get Current Token", + description: "Get details of the current authentication token", + annotations: { readOnlyHint: true }, + }, async () => { try { const result = await client.get("/Token/Current"); @@ -18,7 +22,11 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_list_tokens", - { description: "Get all tokens for the authenticated user" }, + { + title: "List Tokens", + description: "Get all tokens for the authenticated user", + annotations: { readOnlyHint: true }, + }, async () => { try { const result = await client.get("/Token"); @@ -31,7 +39,11 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_auth_tokens", - { description: "Get a list of basic token details for the authenticated user and app" }, + { + title: "Get Auth Tokens", + description: "Get a list of basic token details for the authenticated user and app", + annotations: { readOnlyHint: true }, + }, async () => { try { const result = await client.get("/Token/GetAuthTokens"); diff --git a/src/tools/transactions.ts b/src/tools/transactions.ts index 118b4c2..647bcb9 100644 --- a/src/tools/transactions.ts +++ b/src/tools/transactions.ts @@ -54,8 +54,10 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_business_transactions", { + title: "Get Business Transactions", description: "Get paginated business transactions with optional date, amount, and category filters", + annotations: { readOnlyHint: true }, inputSchema: { ...paginationSchema, ...categoryFilterSchema, @@ -74,7 +76,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_business_transaction", { + title: "Get Business Transaction", description: "Get a specific business transaction by ID", + annotations: { readOnlyHint: true }, inputSchema: { transactionId: z.number().describe("Transaction ID"), }, @@ -94,8 +98,10 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_cardholder_transactions", { + title: "Get Cardholder Transactions", description: "Get paginated cardholder transactions. Optionally filter by cardholder account ID.", + annotations: { readOnlyHint: true }, inputSchema: { cardholderAccountId: z .number() @@ -121,8 +127,10 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_cardholder_transaction", { + title: "Get Cardholder Transaction", description: "Get a specific cardholder transaction by transaction ID, optionally scoped to a cardholder", + annotations: { readOnlyHint: true }, inputSchema: { transactionId: z.number().describe("Transaction ID"), cardholderAccountId: z @@ -147,8 +155,10 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_cardholder_purchases", { + title: "Get Cardholder Purchases", description: "Get paginated cardholder purchases. Optionally filter by cardholder account ID and approval status.", + annotations: { readOnlyHint: true }, inputSchema: { cardholderAccountId: z .number() @@ -179,8 +189,10 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_cardholder_purchase", { + title: "Get Cardholder Purchase", description: "Get a specific cardholder purchase by transaction ID, optionally scoped to a cardholder", + annotations: { readOnlyHint: true }, inputSchema: { transactionId: z.number().describe("Transaction ID"), cardholderAccountId: z @@ -205,8 +217,10 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_cardholder_declines", { + title: "Get Cardholder Declines", description: "Get paginated cardholder declines. Optionally filter by cardholder account ID.", + annotations: { readOnlyHint: true }, inputSchema: { cardholderAccountId: z .number() @@ -231,7 +245,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_transaction_attachments", { + title: "Get Transaction Attachments", description: "Get all attachments for a transaction", + annotations: { readOnlyHint: true }, inputSchema: { transactionId: z.number().describe("Transaction ID"), }, @@ -249,7 +265,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_transaction_attachment", { + title: "Get Transaction Attachment", description: "Get a specific attachment for a transaction", + annotations: { readOnlyHint: true }, inputSchema: { transactionId: z.number().describe("Transaction ID"), attachmentId: z.string().describe("Attachment ID"), @@ -277,7 +295,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_transaction_tags", { + title: "Get Transaction Tags", description: "Get tags for a specific transaction", + annotations: { readOnlyHint: true }, inputSchema: { transactionId: z.number().describe("Transaction ID"), }, diff --git a/src/tools/vendor-card.ts b/src/tools/vendor-card.ts index d052931..8ca7663 100644 --- a/src/tools/vendor-card.ts +++ b/src/tools/vendor-card.ts @@ -7,7 +7,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_vendor_card_order", { + title: "Get Vendor Card Order", description: "Get vendor card order details by order ID", + annotations: { readOnlyHint: true }, inputSchema: { orderId: z.number().describe("Vendor card order ID"), }, diff --git a/src/tools/vendor.ts b/src/tools/vendor.ts index 667457a..f760555 100644 --- a/src/tools/vendor.ts +++ b/src/tools/vendor.ts @@ -7,8 +7,10 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_list_vendors", { + title: "List Vendors", description: "Get paginated list of vendors with optional filtering by cardholder, status, and status trigger", + annotations: { readOnlyHint: true }, inputSchema: { cardholderAcctId: z.number().optional().describe("Filter by cardholder account ID"), vendorStatuses: z @@ -44,7 +46,9 @@ export function register(server: McpServer, client: PexClient): void { server.registerTool( "pex_get_vendor", { + title: "Get Vendor", description: "Get a specific vendor by ID", + annotations: { readOnlyHint: true }, inputSchema: { id: z.number().describe("Vendor ID"), },