From 071bf9fead1e4fd83819ccad85e1cffb6145ab03 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Thu, 7 May 2026 14:53:05 +0000 Subject: [PATCH 1/4] chore: redact api-key headers in debug logs --- src/internal/utils/log.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/internal/utils/log.ts b/src/internal/utils/log.ts index a646c534..95d2eee8 100644 --- a/src/internal/utils/log.ts +++ b/src/internal/utils/log.ts @@ -107,6 +107,8 @@ export const formatRequestDetails = (details: { name, ( name.toLowerCase() === 'authorization' || + name.toLowerCase() === 'api-key' || + name.toLowerCase() === 'x-api-key' || name.toLowerCase() === 'cookie' || name.toLowerCase() === 'set-cookie' ) ? From 306ba11dc0e555f7d76c90eed21bd83a1e691458 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Thu, 7 May 2026 18:12:14 +0000 Subject: [PATCH 2/4] feat(api): add unit param and travel attributes to auth rules v2 conditions --- .stats.yml | 4 +- packages/mcp-server/src/local-docs-search.ts | 4 +- src/resources/auth-rules/v2/v2.ts | 45 +++++++++++++++----- 3 files changed, 38 insertions(+), 15 deletions(-) diff --git a/.stats.yml b/.stats.yml index 883f26c0..11ef5a19 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 191 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic/lithic-0f374e78a0212145a2f55a55dfc39a612de19094d5152ae26b1bc74b01b9e343.yml -openapi_spec_hash: ec888cdaebea979a2cd6231ca04c346c +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic/lithic-af9701d01abffc53ba2bf56c06415d893460e6b420f122e602cf4afe67bbf57b.yml +openapi_spec_hash: 963688b09480159a06865075c94a2577 config_hash: 01dfc901bb6d54b0f582155d779bcbe0 diff --git a/packages/mcp-server/src/local-docs-search.ts b/packages/mcp-server/src/local-docs-search.ts index aa57fa94..7dddd40c 100644 --- a/packages/mcp-server/src/local-docs-search.ts +++ b/packages/mcp-server/src/local-docs-search.ts @@ -1173,12 +1173,12 @@ const EMBEDDED_METHODS: MethodEntry[] = [ qualified: 'client.authRules.v2.draft', params: [ 'auth_rule_token: string;', - "parameters?: { conditions: { attribute: conditional_attribute; operation: conditional_operation; value: conditional_value; }[]; } | { period: { duration: number; type: 'CUSTOM'; } | { type: 'DAY'; } | { type: 'WEEK'; day_of_week?: number; } | { type: 'MONTH'; day_of_month?: number; } | { type: 'YEAR'; day_of_month?: number; month?: number; }; scope: 'CARD' | 'ACCOUNT'; filters?: { exclude_countries?: string[]; exclude_mccs?: string[]; include_countries?: string[]; include_mccs?: string[]; include_pan_entry_modes?: string[]; }; limit_amount?: number; limit_count?: number; } | { merchants: { comment?: string; descriptor?: string; merchant_id?: string; }[]; } | { action: 'DECLINE' | 'CHALLENGE'; conditions: { attribute: string; operation: string; value: string | number | string[] | string; }[]; } | { action: 'DECLINE' | 'CHALLENGE'; conditions: { attribute: string; operation: string; value: string | number | string[] | string; parameters?: { interval?: 'LIFETIME' | '7D' | '30D' | '90D'; scope?: 'CARD' | 'ACCOUNT' | 'BUSINESS_ACCOUNT'; }; }[]; } | { action: { type: 'APPROVE'; } | { code: string; type: 'RETURN'; }; conditions: { attribute: 'COMPANY_NAME' | 'COMPANY_ID' | 'TIMESTAMP' | 'TRANSACTION_AMOUNT' | 'SEC_CODE' | 'MEMO'; operation: string; value: string | number | string[] | string; }[]; } | { action: { type: 'DECLINE'; reason?: string; } | { type: 'REQUIRE_TFA'; reason?: string; }; conditions: { attribute: string; operation: string; value: string | number | string[] | string; }[]; } | { action: { key: string; type: 'TAG'; value: string; } | { queue_token: string; scope: 'CARD' | 'ACCOUNT'; type: 'CREATE_CASE'; }; conditions: { attribute: string; operation: string; value: string | number | string[] | string; parameters?: { filters?: spend_velocity_filters; period?: velocity_limit_period; scope?: 'CARD' | 'ACCOUNT' | 'GLOBAL'; }; }[]; } | { code: string; features: { type: 'AUTHORIZATION'; name?: string; } | { type: 'AUTHENTICATION'; name?: string; } | { type: 'TOKENIZATION'; name?: string; } | { type: 'ACH_RECEIPT'; name?: string; } | { type: 'CARD'; name?: string; } | { type: 'ACCOUNT_HOLDER'; name?: string; } | { type: 'IP_METADATA'; name?: string; } | { period: velocity_limit_period; scope: 'CARD' | 'ACCOUNT'; type: 'SPEND_VELOCITY'; filters?: velocity_limit_filters; name?: string; } | { scope: 'CARD' | 'ACCOUNT' | 'BUSINESS_ACCOUNT'; type: 'TRANSACTION_HISTORY_SIGNALS'; name?: string; }[]; };", + "parameters?: { conditions: { attribute: conditional_attribute; operation: conditional_operation; value: conditional_value; }[]; } | { period: { duration: number; type: 'CUSTOM'; } | { type: 'DAY'; } | { type: 'WEEK'; day_of_week?: number; } | { type: 'MONTH'; day_of_month?: number; } | { type: 'YEAR'; day_of_month?: number; month?: number; }; scope: 'CARD' | 'ACCOUNT'; filters?: { exclude_countries?: string[]; exclude_mccs?: string[]; include_countries?: string[]; include_mccs?: string[]; include_pan_entry_modes?: string[]; }; limit_amount?: number; limit_count?: number; } | { merchants: { comment?: string; descriptor?: string; merchant_id?: string; }[]; } | { action: 'DECLINE' | 'CHALLENGE'; conditions: { attribute: string; operation: string; value: string | number | string[] | string; }[]; } | { action: 'DECLINE' | 'CHALLENGE'; conditions: { attribute: string; operation: string; value: string | number | string[] | string; parameters?: { interval?: 'LIFETIME' | '7D' | '30D' | '90D'; scope?: 'CARD' | 'ACCOUNT' | 'BUSINESS_ACCOUNT'; unit?: 'MPH' | 'KPH' | 'MILES' | 'KILOMETERS'; }; }[]; } | { action: { type: 'APPROVE'; } | { code: string; type: 'RETURN'; }; conditions: { attribute: 'COMPANY_NAME' | 'COMPANY_ID' | 'TIMESTAMP' | 'TRANSACTION_AMOUNT' | 'SEC_CODE' | 'MEMO'; operation: string; value: string | number | string[] | string; }[]; } | { action: { type: 'DECLINE'; reason?: string; } | { type: 'REQUIRE_TFA'; reason?: string; }; conditions: { attribute: string; operation: string; value: string | number | string[] | string; }[]; } | { action: { key: string; type: 'TAG'; value: string; } | { queue_token: string; scope: 'CARD' | 'ACCOUNT'; type: 'CREATE_CASE'; }; conditions: { attribute: string; operation: string; value: string | number | string[] | string; parameters?: { filters?: spend_velocity_filters; period?: velocity_limit_period; scope?: 'CARD' | 'ACCOUNT' | 'GLOBAL'; }; }[]; } | { code: string; features: { type: 'AUTHORIZATION'; name?: string; } | { type: 'AUTHENTICATION'; name?: string; } | { type: 'TOKENIZATION'; name?: string; } | { type: 'ACH_RECEIPT'; name?: string; } | { type: 'CARD'; name?: string; } | { type: 'ACCOUNT_HOLDER'; name?: string; } | { type: 'IP_METADATA'; name?: string; } | { period: velocity_limit_period; scope: 'CARD' | 'ACCOUNT'; type: 'SPEND_VELOCITY'; filters?: velocity_limit_filters; name?: string; } | { scope: 'CARD' | 'ACCOUNT' | 'BUSINESS_ACCOUNT'; type: 'TRANSACTION_HISTORY_SIGNALS'; name?: string; }[]; };", ], response: "{ token: string; account_tokens: string[]; business_account_tokens: string[]; card_tokens: string[]; current_version: { parameters: object | object | object | object | object | object | object | object | object; version: number; }; draft_version: { error: string; parameters: object | object | object | object | object | object | object | object | object; state: 'PENDING' | 'SHADOWING' | 'ERROR'; version: number; }; event_stream: string; lithic_managed: boolean; name: string; program_level: boolean; state: 'ACTIVE' | 'INACTIVE'; type: 'CONDITIONAL_BLOCK' | 'VELOCITY_LIMIT' | 'MERCHANT_LOCK' | 'CONDITIONAL_ACTION' | 'TYPESCRIPT_CODE'; excluded_account_tokens?: string[]; excluded_business_account_tokens?: string[]; excluded_card_tokens?: string[]; }", markdown: - "## draft\n\n`client.authRules.v2.draft(auth_rule_token: string, parameters?: { conditions: auth_rule_condition[]; } | { period: velocity_limit_period; scope: 'CARD' | 'ACCOUNT'; filters?: velocity_limit_filters; limit_amount?: number; limit_count?: number; } | { merchants: object[]; } | { action: 'DECLINE' | 'CHALLENGE'; conditions: object[]; } | { action: 'DECLINE' | 'CHALLENGE'; conditions: object[]; } | { action: object | object; conditions: object[]; } | { action: object | object; conditions: object[]; } | { action: card_transaction_update_action; conditions: object[]; } | { code: string; features: rule_feature[]; }): { token: string; account_tokens: string[]; business_account_tokens: string[]; card_tokens: string[]; current_version: object; draft_version: object; event_stream: event_stream; lithic_managed: boolean; name: string; program_level: boolean; state: 'ACTIVE' | 'INACTIVE'; type: 'CONDITIONAL_BLOCK' | 'VELOCITY_LIMIT' | 'MERCHANT_LOCK' | 'CONDITIONAL_ACTION' | 'TYPESCRIPT_CODE'; excluded_account_tokens?: string[]; excluded_business_account_tokens?: string[]; excluded_card_tokens?: string[]; }`\n\n**post** `/v2/auth_rules/{auth_rule_token}/draft`\n\nCreates a new draft version of a rule that will be ran in shadow mode.\n\nThis can also be utilized to reset the draft parameters, causing a draft version to no longer be ran in shadow mode.\n\n\n### Parameters\n\n- `auth_rule_token: string`\n\n- `parameters?: { conditions: { attribute: conditional_attribute; operation: conditional_operation; value: conditional_value; }[]; } | { period: { duration: number; type: 'CUSTOM'; } | { type: 'DAY'; } | { type: 'WEEK'; day_of_week?: number; } | { type: 'MONTH'; day_of_month?: number; } | { type: 'YEAR'; day_of_month?: number; month?: number; }; scope: 'CARD' | 'ACCOUNT'; filters?: { exclude_countries?: string[]; exclude_mccs?: string[]; include_countries?: string[]; include_mccs?: string[]; include_pan_entry_modes?: string[]; }; limit_amount?: number; limit_count?: number; } | { merchants: { comment?: string; descriptor?: string; merchant_id?: string; }[]; } | { action: 'DECLINE' | 'CHALLENGE'; conditions: { attribute: string; operation: string; value: string | number | string[] | string; }[]; } | { action: 'DECLINE' | 'CHALLENGE'; conditions: { attribute: string; operation: string; value: string | number | string[] | string; parameters?: { interval?: 'LIFETIME' | '7D' | '30D' | '90D'; scope?: 'CARD' | 'ACCOUNT' | 'BUSINESS_ACCOUNT'; }; }[]; } | { action: { type: 'APPROVE'; } | { code: string; type: 'RETURN'; }; conditions: { attribute: 'COMPANY_NAME' | 'COMPANY_ID' | 'TIMESTAMP' | 'TRANSACTION_AMOUNT' | 'SEC_CODE' | 'MEMO'; operation: string; value: string | number | string[] | string; }[]; } | { action: { type: 'DECLINE'; reason?: string; } | { type: 'REQUIRE_TFA'; reason?: string; }; conditions: { attribute: string; operation: string; value: string | number | string[] | string; }[]; } | { action: { key: string; type: 'TAG'; value: string; } | { queue_token: string; scope: 'CARD' | 'ACCOUNT'; type: 'CREATE_CASE'; }; conditions: { attribute: string; operation: string; value: string | number | string[] | string; parameters?: { filters?: spend_velocity_filters; period?: velocity_limit_period; scope?: 'CARD' | 'ACCOUNT' | 'GLOBAL'; }; }[]; } | { code: string; features: { type: 'AUTHORIZATION'; name?: string; } | { type: 'AUTHENTICATION'; name?: string; } | { type: 'TOKENIZATION'; name?: string; } | { type: 'ACH_RECEIPT'; name?: string; } | { type: 'CARD'; name?: string; } | { type: 'ACCOUNT_HOLDER'; name?: string; } | { type: 'IP_METADATA'; name?: string; } | { period: velocity_limit_period; scope: 'CARD' | 'ACCOUNT'; type: 'SPEND_VELOCITY'; filters?: velocity_limit_filters; name?: string; } | { scope: 'CARD' | 'ACCOUNT' | 'BUSINESS_ACCOUNT'; type: 'TRANSACTION_HISTORY_SIGNALS'; name?: string; }[]; }`\n Parameters for the Auth Rule\n\n### Returns\n\n- `{ token: string; account_tokens: string[]; business_account_tokens: string[]; card_tokens: string[]; current_version: { parameters: object | object | object | object | object | object | object | object | object; version: number; }; draft_version: { error: string; parameters: object | object | object | object | object | object | object | object | object; state: 'PENDING' | 'SHADOWING' | 'ERROR'; version: number; }; event_stream: string; lithic_managed: boolean; name: string; program_level: boolean; state: 'ACTIVE' | 'INACTIVE'; type: 'CONDITIONAL_BLOCK' | 'VELOCITY_LIMIT' | 'MERCHANT_LOCK' | 'CONDITIONAL_ACTION' | 'TYPESCRIPT_CODE'; excluded_account_tokens?: string[]; excluded_business_account_tokens?: string[]; excluded_card_tokens?: string[]; }`\n\n - `token: string`\n - `account_tokens: string[]`\n - `business_account_tokens: string[]`\n - `card_tokens: string[]`\n - `current_version: { parameters: { conditions: object[]; } | { period: object | object | object | object | object; scope: 'CARD' | 'ACCOUNT'; filters?: object; limit_amount?: number; limit_count?: number; } | { merchants: { comment?: string; descriptor?: string; merchant_id?: string; }[]; } | { action: 'DECLINE' | 'CHALLENGE'; conditions: { attribute: string; operation: conditional_operation; value: conditional_value; }[]; } | { action: 'DECLINE' | 'CHALLENGE'; conditions: { attribute: string; operation: conditional_operation; value: conditional_value; parameters?: object; }[]; } | { action: { type: 'APPROVE'; } | { code: string; type: 'RETURN'; }; conditions: { attribute: 'COMPANY_NAME' | 'COMPANY_ID' | 'TIMESTAMP' | 'TRANSACTION_AMOUNT' | 'SEC_CODE' | 'MEMO'; operation: conditional_operation; value: conditional_value; }[]; } | { action: { type: 'DECLINE'; reason?: string; } | { type: 'REQUIRE_TFA'; reason?: string; }; conditions: { attribute: string; operation: conditional_operation; value: conditional_value; }[]; } | { action: object | object; conditions: { attribute: string; operation: conditional_operation; value: conditional_value; parameters?: object; }[]; } | { code: string; features: object | object | object | object | object | object | object | object | object[]; }; version: number; }`\n - `draft_version: { error: string; parameters: { conditions: object[]; } | { period: object | object | object | object | object; scope: 'CARD' | 'ACCOUNT'; filters?: object; limit_amount?: number; limit_count?: number; } | { merchants: { comment?: string; descriptor?: string; merchant_id?: string; }[]; } | { action: 'DECLINE' | 'CHALLENGE'; conditions: { attribute: string; operation: conditional_operation; value: conditional_value; }[]; } | { action: 'DECLINE' | 'CHALLENGE'; conditions: { attribute: string; operation: conditional_operation; value: conditional_value; parameters?: object; }[]; } | { action: { type: 'APPROVE'; } | { code: string; type: 'RETURN'; }; conditions: { attribute: 'COMPANY_NAME' | 'COMPANY_ID' | 'TIMESTAMP' | 'TRANSACTION_AMOUNT' | 'SEC_CODE' | 'MEMO'; operation: conditional_operation; value: conditional_value; }[]; } | { action: { type: 'DECLINE'; reason?: string; } | { type: 'REQUIRE_TFA'; reason?: string; }; conditions: { attribute: string; operation: conditional_operation; value: conditional_value; }[]; } | { action: object | object; conditions: { attribute: string; operation: conditional_operation; value: conditional_value; parameters?: object; }[]; } | { code: string; features: object | object | object | object | object | object | object | object | object[]; }; state: 'PENDING' | 'SHADOWING' | 'ERROR'; version: number; }`\n - `event_stream: string`\n - `lithic_managed: boolean`\n - `name: string`\n - `program_level: boolean`\n - `state: 'ACTIVE' | 'INACTIVE'`\n - `type: 'CONDITIONAL_BLOCK' | 'VELOCITY_LIMIT' | 'MERCHANT_LOCK' | 'CONDITIONAL_ACTION' | 'TYPESCRIPT_CODE'`\n - `excluded_account_tokens?: string[]`\n - `excluded_business_account_tokens?: string[]`\n - `excluded_card_tokens?: string[]`\n\n### Example\n\n```typescript\nimport Lithic from 'lithic';\n\nconst client = new Lithic();\n\nconst authRule = await client.authRules.v2.draft('182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e');\n\nconsole.log(authRule);\n```", + "## draft\n\n`client.authRules.v2.draft(auth_rule_token: string, parameters?: { conditions: auth_rule_condition[]; } | { period: velocity_limit_period; scope: 'CARD' | 'ACCOUNT'; filters?: velocity_limit_filters; limit_amount?: number; limit_count?: number; } | { merchants: object[]; } | { action: 'DECLINE' | 'CHALLENGE'; conditions: object[]; } | { action: 'DECLINE' | 'CHALLENGE'; conditions: object[]; } | { action: object | object; conditions: object[]; } | { action: object | object; conditions: object[]; } | { action: card_transaction_update_action; conditions: object[]; } | { code: string; features: rule_feature[]; }): { token: string; account_tokens: string[]; business_account_tokens: string[]; card_tokens: string[]; current_version: object; draft_version: object; event_stream: event_stream; lithic_managed: boolean; name: string; program_level: boolean; state: 'ACTIVE' | 'INACTIVE'; type: 'CONDITIONAL_BLOCK' | 'VELOCITY_LIMIT' | 'MERCHANT_LOCK' | 'CONDITIONAL_ACTION' | 'TYPESCRIPT_CODE'; excluded_account_tokens?: string[]; excluded_business_account_tokens?: string[]; excluded_card_tokens?: string[]; }`\n\n**post** `/v2/auth_rules/{auth_rule_token}/draft`\n\nCreates a new draft version of a rule that will be ran in shadow mode.\n\nThis can also be utilized to reset the draft parameters, causing a draft version to no longer be ran in shadow mode.\n\n\n### Parameters\n\n- `auth_rule_token: string`\n\n- `parameters?: { conditions: { attribute: conditional_attribute; operation: conditional_operation; value: conditional_value; }[]; } | { period: { duration: number; type: 'CUSTOM'; } | { type: 'DAY'; } | { type: 'WEEK'; day_of_week?: number; } | { type: 'MONTH'; day_of_month?: number; } | { type: 'YEAR'; day_of_month?: number; month?: number; }; scope: 'CARD' | 'ACCOUNT'; filters?: { exclude_countries?: string[]; exclude_mccs?: string[]; include_countries?: string[]; include_mccs?: string[]; include_pan_entry_modes?: string[]; }; limit_amount?: number; limit_count?: number; } | { merchants: { comment?: string; descriptor?: string; merchant_id?: string; }[]; } | { action: 'DECLINE' | 'CHALLENGE'; conditions: { attribute: string; operation: string; value: string | number | string[] | string; }[]; } | { action: 'DECLINE' | 'CHALLENGE'; conditions: { attribute: string; operation: string; value: string | number | string[] | string; parameters?: { interval?: 'LIFETIME' | '7D' | '30D' | '90D'; scope?: 'CARD' | 'ACCOUNT' | 'BUSINESS_ACCOUNT'; unit?: 'MPH' | 'KPH' | 'MILES' | 'KILOMETERS'; }; }[]; } | { action: { type: 'APPROVE'; } | { code: string; type: 'RETURN'; }; conditions: { attribute: 'COMPANY_NAME' | 'COMPANY_ID' | 'TIMESTAMP' | 'TRANSACTION_AMOUNT' | 'SEC_CODE' | 'MEMO'; operation: string; value: string | number | string[] | string; }[]; } | { action: { type: 'DECLINE'; reason?: string; } | { type: 'REQUIRE_TFA'; reason?: string; }; conditions: { attribute: string; operation: string; value: string | number | string[] | string; }[]; } | { action: { key: string; type: 'TAG'; value: string; } | { queue_token: string; scope: 'CARD' | 'ACCOUNT'; type: 'CREATE_CASE'; }; conditions: { attribute: string; operation: string; value: string | number | string[] | string; parameters?: { filters?: spend_velocity_filters; period?: velocity_limit_period; scope?: 'CARD' | 'ACCOUNT' | 'GLOBAL'; }; }[]; } | { code: string; features: { type: 'AUTHORIZATION'; name?: string; } | { type: 'AUTHENTICATION'; name?: string; } | { type: 'TOKENIZATION'; name?: string; } | { type: 'ACH_RECEIPT'; name?: string; } | { type: 'CARD'; name?: string; } | { type: 'ACCOUNT_HOLDER'; name?: string; } | { type: 'IP_METADATA'; name?: string; } | { period: velocity_limit_period; scope: 'CARD' | 'ACCOUNT'; type: 'SPEND_VELOCITY'; filters?: velocity_limit_filters; name?: string; } | { scope: 'CARD' | 'ACCOUNT' | 'BUSINESS_ACCOUNT'; type: 'TRANSACTION_HISTORY_SIGNALS'; name?: string; }[]; }`\n Parameters for the Auth Rule\n\n### Returns\n\n- `{ token: string; account_tokens: string[]; business_account_tokens: string[]; card_tokens: string[]; current_version: { parameters: object | object | object | object | object | object | object | object | object; version: number; }; draft_version: { error: string; parameters: object | object | object | object | object | object | object | object | object; state: 'PENDING' | 'SHADOWING' | 'ERROR'; version: number; }; event_stream: string; lithic_managed: boolean; name: string; program_level: boolean; state: 'ACTIVE' | 'INACTIVE'; type: 'CONDITIONAL_BLOCK' | 'VELOCITY_LIMIT' | 'MERCHANT_LOCK' | 'CONDITIONAL_ACTION' | 'TYPESCRIPT_CODE'; excluded_account_tokens?: string[]; excluded_business_account_tokens?: string[]; excluded_card_tokens?: string[]; }`\n\n - `token: string`\n - `account_tokens: string[]`\n - `business_account_tokens: string[]`\n - `card_tokens: string[]`\n - `current_version: { parameters: { conditions: object[]; } | { period: object | object | object | object | object; scope: 'CARD' | 'ACCOUNT'; filters?: object; limit_amount?: number; limit_count?: number; } | { merchants: { comment?: string; descriptor?: string; merchant_id?: string; }[]; } | { action: 'DECLINE' | 'CHALLENGE'; conditions: { attribute: string; operation: conditional_operation; value: conditional_value; }[]; } | { action: 'DECLINE' | 'CHALLENGE'; conditions: { attribute: string; operation: conditional_operation; value: conditional_value; parameters?: object; }[]; } | { action: { type: 'APPROVE'; } | { code: string; type: 'RETURN'; }; conditions: { attribute: 'COMPANY_NAME' | 'COMPANY_ID' | 'TIMESTAMP' | 'TRANSACTION_AMOUNT' | 'SEC_CODE' | 'MEMO'; operation: conditional_operation; value: conditional_value; }[]; } | { action: { type: 'DECLINE'; reason?: string; } | { type: 'REQUIRE_TFA'; reason?: string; }; conditions: { attribute: string; operation: conditional_operation; value: conditional_value; }[]; } | { action: object | object; conditions: { attribute: string; operation: conditional_operation; value: conditional_value; parameters?: object; }[]; } | { code: string; features: object | object | object | object | object | object | object | object | object[]; }; version: number; }`\n - `draft_version: { error: string; parameters: { conditions: object[]; } | { period: object | object | object | object | object; scope: 'CARD' | 'ACCOUNT'; filters?: object; limit_amount?: number; limit_count?: number; } | { merchants: { comment?: string; descriptor?: string; merchant_id?: string; }[]; } | { action: 'DECLINE' | 'CHALLENGE'; conditions: { attribute: string; operation: conditional_operation; value: conditional_value; }[]; } | { action: 'DECLINE' | 'CHALLENGE'; conditions: { attribute: string; operation: conditional_operation; value: conditional_value; parameters?: object; }[]; } | { action: { type: 'APPROVE'; } | { code: string; type: 'RETURN'; }; conditions: { attribute: 'COMPANY_NAME' | 'COMPANY_ID' | 'TIMESTAMP' | 'TRANSACTION_AMOUNT' | 'SEC_CODE' | 'MEMO'; operation: conditional_operation; value: conditional_value; }[]; } | { action: { type: 'DECLINE'; reason?: string; } | { type: 'REQUIRE_TFA'; reason?: string; }; conditions: { attribute: string; operation: conditional_operation; value: conditional_value; }[]; } | { action: object | object; conditions: { attribute: string; operation: conditional_operation; value: conditional_value; parameters?: object; }[]; } | { code: string; features: object | object | object | object | object | object | object | object | object[]; }; state: 'PENDING' | 'SHADOWING' | 'ERROR'; version: number; }`\n - `event_stream: string`\n - `lithic_managed: boolean`\n - `name: string`\n - `program_level: boolean`\n - `state: 'ACTIVE' | 'INACTIVE'`\n - `type: 'CONDITIONAL_BLOCK' | 'VELOCITY_LIMIT' | 'MERCHANT_LOCK' | 'CONDITIONAL_ACTION' | 'TYPESCRIPT_CODE'`\n - `excluded_account_tokens?: string[]`\n - `excluded_business_account_tokens?: string[]`\n - `excluded_card_tokens?: string[]`\n\n### Example\n\n```typescript\nimport Lithic from 'lithic';\n\nconst client = new Lithic();\n\nconst authRule = await client.authRules.v2.draft('182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e');\n\nconsole.log(authRule);\n```", perLanguage: { typescript: { method: 'client.authRules.v2.draft', diff --git a/src/resources/auth-rules/v2/v2.ts b/src/resources/auth-rules/v2/v2.ts index 83f9f3ae..f1db4265 100644 --- a/src/resources/auth-rules/v2/v2.ts +++ b/src/resources/auth-rules/v2/v2.ts @@ -878,6 +878,15 @@ export namespace ConditionalAuthorizationActionParameters { * `parameters` required. * - `THREE_DS_SUCCESS_RATE`: The 3DS authentication success rate for the card, as * a percentage from 0.0 to 100.0. Card-scoped only; no `parameters` required. + * - `TRAVEL_SPEED`: The estimated speed of travel derived from the distance + * between the postal code centers of the last card-present transaction and the + * current transaction, divided by the elapsed time. Null if there is no prior + * card-present transaction, if either postal code cannot be geocoded, or if + * elapsed time is zero. Requires `parameters.unit` set to `MPH` or `KPH`. + * - `DISTANCE_FROM_LAST_TRANSACTION`: The estimated distance between the postal + * code centers of the last card-present transaction and the current transaction. + * Null if there is no prior card-present transaction or if either postal code + * cannot be geocoded. Requires `parameters.unit` set to `MILES` or `KILOMETERS`. */ attribute: | 'MCC' @@ -916,7 +925,9 @@ export namespace ConditionalAuthorizationActionParameters { | 'TIME_SINCE_LAST_TRANSACTION' | 'DISTINCT_COUNTRY_COUNT' | 'IS_NEW_MERCHANT' - | 'THREE_DS_SUCCESS_RATE'; + | 'THREE_DS_SUCCESS_RATE' + | 'TRAVEL_SPEED' + | 'DISTANCE_FROM_LAST_TRANSACTION'; /** * The operation to apply to the attribute @@ -929,22 +940,24 @@ export namespace ConditionalAuthorizationActionParameters { value: V2API.ConditionalValue; /** - * Additional parameters required for transaction history signal attributes. - * Required when `attribute` is one of `AMOUNT_Z_SCORE`, `AVG_TRANSACTION_AMOUNT`, - * `STDEV_TRANSACTION_AMOUNT`, `IS_NEW_COUNTRY`, `IS_NEW_MCC`, - * `IS_FIRST_TRANSACTION`, `CONSECUTIVE_DECLINES`, `TIME_SINCE_LAST_TRANSACTION`, - * or `DISTINCT_COUNTRY_COUNT`. Not used for other attributes. + * Additional parameters for certain attributes. Required when `attribute` is one + * of `AMOUNT_Z_SCORE`, `AVG_TRANSACTION_AMOUNT`, `STDEV_TRANSACTION_AMOUNT`, + * `IS_NEW_COUNTRY`, `IS_NEW_MCC`, `IS_FIRST_TRANSACTION`, `CONSECUTIVE_DECLINES`, + * `TIME_SINCE_LAST_TRANSACTION`, or `DISTINCT_COUNTRY_COUNT` (require `scope`); or + * `TRAVEL_SPEED` or `DISTANCE_FROM_LAST_TRANSACTION` (require `unit`). Not used + * for other attributes. */ parameters?: Condition.Parameters; } export namespace Condition { /** - * Additional parameters required for transaction history signal attributes. - * Required when `attribute` is one of `AMOUNT_Z_SCORE`, `AVG_TRANSACTION_AMOUNT`, - * `STDEV_TRANSACTION_AMOUNT`, `IS_NEW_COUNTRY`, `IS_NEW_MCC`, - * `IS_FIRST_TRANSACTION`, `CONSECUTIVE_DECLINES`, `TIME_SINCE_LAST_TRANSACTION`, - * or `DISTINCT_COUNTRY_COUNT`. Not used for other attributes. + * Additional parameters for certain attributes. Required when `attribute` is one + * of `AMOUNT_Z_SCORE`, `AVG_TRANSACTION_AMOUNT`, `STDEV_TRANSACTION_AMOUNT`, + * `IS_NEW_COUNTRY`, `IS_NEW_MCC`, `IS_FIRST_TRANSACTION`, `CONSECUTIVE_DECLINES`, + * `TIME_SINCE_LAST_TRANSACTION`, or `DISTINCT_COUNTRY_COUNT` (require `scope`); or + * `TRAVEL_SPEED` or `DISTANCE_FROM_LAST_TRANSACTION` (require `unit`). Not used + * for other attributes. */ export interface Parameters { /** @@ -958,6 +971,16 @@ export namespace ConditionalAuthorizationActionParameters { * The entity scope to evaluate the attribute against. */ scope?: 'CARD' | 'ACCOUNT' | 'BUSINESS_ACCOUNT'; + + /** + * The unit for impossible travel attributes. Required when `attribute` is + * `TRAVEL_SPEED` or `DISTANCE_FROM_LAST_TRANSACTION`. + * + * For `TRAVEL_SPEED`: `MPH` (miles per hour) or `KPH` (kilometers per hour). + * + * For `DISTANCE_FROM_LAST_TRANSACTION`: `MILES` or `KILOMETERS`. + */ + unit?: 'MPH' | 'KPH' | 'MILES' | 'KILOMETERS'; } } } From e5f850d44eb9df6a5015f337954c287a294b7324 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Fri, 8 May 2026 17:08:17 +0000 Subject: [PATCH 3/4] feat(api): add retrieveSignals methods to accounts and cards --- .stats.yml | 6 +- api.md | 6 + packages/mcp-server/src/code-tool-worker.ts | 2 + packages/mcp-server/src/local-docs-search.ts | 102 +++++++++ packages/mcp-server/src/methods.ts | 12 ++ src/client.ts | 4 +- src/resources/accounts.ts | 23 +++ src/resources/auth-rules/auth-rules.ts | 207 +++++++++++++++++++ src/resources/auth-rules/index.ts | 2 +- src/resources/cards/cards.ts | 20 ++ src/resources/index.ts | 2 +- tests/api-resources/accounts.test.ts | 11 + tests/api-resources/cards/cards.test.ts | 11 + 13 files changed, 401 insertions(+), 7 deletions(-) diff --git a/.stats.yml b/.stats.yml index 11ef5a19..9a940850 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ -configured_endpoints: 191 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic/lithic-af9701d01abffc53ba2bf56c06415d893460e6b420f122e602cf4afe67bbf57b.yml +configured_endpoints: 193 +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/lithic/lithic-00f07b0edcc0c3c5ef79920ced7f58dac2434df5e4c27ff6041783e8228315f9.yml openapi_spec_hash: 963688b09480159a06865075c94a2577 -config_hash: 01dfc901bb6d54b0f582155d779bcbe0 +config_hash: 265a2b679964f4ad5706de101ad2a942 diff --git a/api.md b/api.md index 68106b5c..cc5fca0d 100644 --- a/api.md +++ b/api.md @@ -34,6 +34,7 @@ Methods: - client.accounts.retrieve(accountToken) -> Account - client.accounts.update(accountToken, { ...params }) -> Account - client.accounts.list({ ...params }) -> AccountsCursorPage +- client.accounts.retrieveSignals(accountToken) -> SignalsResponse - client.accounts.retrieveSpendLimits(accountToken) -> AccountSpendLimits # AccountHolders @@ -78,6 +79,10 @@ Methods: # AuthRules +Types: + +- SignalsResponse + ## V2 Types: @@ -207,6 +212,7 @@ Methods: - client.cards.provision(cardToken, { ...params }) -> CardProvisionResponse - client.cards.reissue(cardToken, { ...params }) -> Card - client.cards.renew(cardToken, { ...params }) -> Card +- client.cards.retrieveSignals(cardToken) -> SignalsResponse - client.cards.retrieveSpendLimits(cardToken) -> CardSpendLimits - client.cards.searchByPan({ ...params }) -> Card - client.cards.webProvision(cardToken, { ...params }) -> CardWebProvisionResponse diff --git a/packages/mcp-server/src/code-tool-worker.ts b/packages/mcp-server/src/code-tool-worker.ts index 3da4b418..0e25078f 100644 --- a/packages/mcp-server/src/code-tool-worker.ts +++ b/packages/mcp-server/src/code-tool-worker.ts @@ -111,6 +111,7 @@ const fuse = new Fuse( 'client.apiStatus', 'client.accounts.list', 'client.accounts.retrieve', + 'client.accounts.retrieveSignals', 'client.accounts.retrieveSpendLimits', 'client.accounts.update', 'client.accountHolders.create', @@ -158,6 +159,7 @@ const fuse = new Fuse( 'client.cards.reissue', 'client.cards.renew', 'client.cards.retrieve', + 'client.cards.retrieveSignals', 'client.cards.retrieveSpendLimits', 'client.cards.searchByPan', 'client.cards.update', diff --git a/packages/mcp-server/src/local-docs-search.ts b/packages/mcp-server/src/local-docs-search.ts index 7dddd40c..8821a583 100644 --- a/packages/mcp-server/src/local-docs-search.ts +++ b/packages/mcp-server/src/local-docs-search.ts @@ -313,6 +313,57 @@ const EMBEDDED_METHODS: MethodEntry[] = [ }, }, }, + { + name: 'retrieve_signals', + endpoint: '/v1/accounts/{account_token}/signals', + httpMethod: 'get', + summary: 'Fetch account signals', + description: + "Returns behavioral feature state derived from an account's transaction history.\n\nThese signals expose the same data used by behavioral rule attributes (e.g. `AMOUNT_Z_SCORE`\nwith `scope: ACCOUNT`, `IS_NEW_COUNTRY` with `scope: ACCOUNT`) and custom code\n`TRANSACTION_HISTORY_SIGNALS` features, allowing clients to inspect feature values before\nwriting rules and debug rule behavior.\n\nNote: 3DS fields are not available at the account scope and will be null.\n", + stainlessPath: '(resource) accounts > (method) retrieve_signals', + qualified: 'client.accounts.retrieveSignals', + params: ['account_token: string;'], + response: + '{ approved_txn_amount_m2: number; approved_txn_amount_m2_30d: number; approved_txn_amount_m2_7d: number; approved_txn_amount_m2_90d: number; approved_txn_count: number; approved_txn_count_30d: number; approved_txn_count_7d: number; approved_txn_count_90d: number; avg_transaction_amount: number; avg_transaction_amount_30d: number; avg_transaction_amount_7d: number; avg_transaction_amount_90d: number; distinct_country_count: number; distinct_mcc_count: number; first_txn_at: string; is_first_transaction: boolean; last_cp_country: string; last_cp_postal_code: string; last_cp_timestamp: string; last_txn_approved_at: string; seen_countries: string[]; seen_mccs: string[]; seen_merchants: string[]; stdev_transaction_amount: number; stdev_transaction_amount_30d: number; stdev_transaction_amount_7d: number; stdev_transaction_amount_90d: number; three_ds_success_count: number; three_ds_success_rate: number; three_ds_total_count: number; time_since_last_transaction_days: number; }', + markdown: + "## retrieve_signals\n\n`client.accounts.retrieveSignals(account_token: string): { approved_txn_amount_m2: number; approved_txn_amount_m2_30d: number; approved_txn_amount_m2_7d: number; approved_txn_amount_m2_90d: number; approved_txn_count: number; approved_txn_count_30d: number; approved_txn_count_7d: number; approved_txn_count_90d: number; avg_transaction_amount: number; avg_transaction_amount_30d: number; avg_transaction_amount_7d: number; avg_transaction_amount_90d: number; distinct_country_count: number; distinct_mcc_count: number; first_txn_at: string; is_first_transaction: boolean; last_cp_country: string; last_cp_postal_code: string; last_cp_timestamp: string; last_txn_approved_at: string; seen_countries: string[]; seen_mccs: string[]; seen_merchants: string[]; stdev_transaction_amount: number; stdev_transaction_amount_30d: number; stdev_transaction_amount_7d: number; stdev_transaction_amount_90d: number; three_ds_success_count: number; three_ds_success_rate: number; three_ds_total_count: number; time_since_last_transaction_days: number; }`\n\n**get** `/v1/accounts/{account_token}/signals`\n\nReturns behavioral feature state derived from an account's transaction history.\n\nThese signals expose the same data used by behavioral rule attributes (e.g. `AMOUNT_Z_SCORE`\nwith `scope: ACCOUNT`, `IS_NEW_COUNTRY` with `scope: ACCOUNT`) and custom code\n`TRANSACTION_HISTORY_SIGNALS` features, allowing clients to inspect feature values before\nwriting rules and debug rule behavior.\n\nNote: 3DS fields are not available at the account scope and will be null.\n\n\n### Parameters\n\n- `account_token: string`\n\n### Returns\n\n- `{ approved_txn_amount_m2: number; approved_txn_amount_m2_30d: number; approved_txn_amount_m2_7d: number; approved_txn_amount_m2_90d: number; approved_txn_count: number; approved_txn_count_30d: number; approved_txn_count_7d: number; approved_txn_count_90d: number; avg_transaction_amount: number; avg_transaction_amount_30d: number; avg_transaction_amount_7d: number; avg_transaction_amount_90d: number; distinct_country_count: number; distinct_mcc_count: number; first_txn_at: string; is_first_transaction: boolean; last_cp_country: string; last_cp_postal_code: string; last_cp_timestamp: string; last_txn_approved_at: string; seen_countries: string[]; seen_mccs: string[]; seen_merchants: string[]; stdev_transaction_amount: number; stdev_transaction_amount_30d: number; stdev_transaction_amount_7d: number; stdev_transaction_amount_90d: number; three_ds_success_count: number; three_ds_success_rate: number; three_ds_total_count: number; time_since_last_transaction_days: number; }`\n Behavioral feature state for a card or account derived from its transaction history.\n\nDerived statistical features (averages, standard deviations, z-scores) are computed using Welford's online algorithm over approved transactions. Average fields are null when fewer than 5 approved transactions have been recorded. Standard deviation fields are null when fewer than 30 approved transactions have been recorded.\n\n3DS fields (`three_ds_success_rate`, `three_ds_success_count`, `three_ds_total_count`) are card-scoped and will be null for account responses.\n\nRaw fields (`seen_countries`, `seen_mccs`, `approved_txn_amount_m2`, etc.) are included so clients can compute their own transaction-specific derivations, such as checking whether a new transaction's country is in `seen_countries` to determine `is_new_country`, or computing a z-score using the raw mean and M2 values.\n\n - `approved_txn_amount_m2: number`\n - `approved_txn_amount_m2_30d: number`\n - `approved_txn_amount_m2_7d: number`\n - `approved_txn_amount_m2_90d: number`\n - `approved_txn_count: number`\n - `approved_txn_count_30d: number`\n - `approved_txn_count_7d: number`\n - `approved_txn_count_90d: number`\n - `avg_transaction_amount: number`\n - `avg_transaction_amount_30d: number`\n - `avg_transaction_amount_7d: number`\n - `avg_transaction_amount_90d: number`\n - `distinct_country_count: number`\n - `distinct_mcc_count: number`\n - `first_txn_at: string`\n - `is_first_transaction: boolean`\n - `last_cp_country: string`\n - `last_cp_postal_code: string`\n - `last_cp_timestamp: string`\n - `last_txn_approved_at: string`\n - `seen_countries: string[]`\n - `seen_mccs: string[]`\n - `seen_merchants: string[]`\n - `stdev_transaction_amount: number`\n - `stdev_transaction_amount_30d: number`\n - `stdev_transaction_amount_7d: number`\n - `stdev_transaction_amount_90d: number`\n - `three_ds_success_count: number`\n - `three_ds_success_rate: number`\n - `three_ds_total_count: number`\n - `time_since_last_transaction_days: number`\n\n### Example\n\n```typescript\nimport Lithic from 'lithic';\n\nconst client = new Lithic();\n\nconst signalsResponse = await client.accounts.retrieveSignals('182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e');\n\nconsole.log(signalsResponse);\n```", + perLanguage: { + typescript: { + method: 'client.accounts.retrieveSignals', + example: + "import Lithic from 'lithic';\n\nconst client = new Lithic({\n apiKey: process.env['LITHIC_API_KEY'], // This is the default and can be omitted\n});\n\nconst signalsResponse = await client.accounts.retrieveSignals(\n '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',\n);\n\nconsole.log(signalsResponse.approved_txn_amount_m2);", + }, + python: { + method: 'accounts.retrieve_signals', + example: + 'import os\nfrom lithic import Lithic\n\nclient = Lithic(\n api_key=os.environ.get("LITHIC_API_KEY"), # This is the default and can be omitted\n)\nsignals_response = client.accounts.retrieve_signals(\n "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",\n)\nprint(signals_response.approved_txn_amount_m2)', + }, + java: { + method: 'accounts().retrieveSignals', + example: + 'package com.lithic.api.example;\n\nimport com.lithic.api.client.LithicClient;\nimport com.lithic.api.client.okhttp.LithicOkHttpClient;\nimport com.lithic.api.models.AccountRetrieveSignalsParams;\nimport com.lithic.api.models.SignalsResponse;\n\npublic final class Main {\n private Main() {}\n\n public static void main(String[] args) {\n LithicClient client = LithicOkHttpClient.fromEnv();\n\n SignalsResponse signalsResponse = client.accounts().retrieveSignals("182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e");\n }\n}', + }, + kotlin: { + method: 'accounts().retrieveSignals', + example: + 'package com.lithic.api.example\n\nimport com.lithic.api.client.LithicClient\nimport com.lithic.api.client.okhttp.LithicOkHttpClient\nimport com.lithic.api.models.AccountRetrieveSignalsParams\nimport com.lithic.api.models.SignalsResponse\n\nfun main() {\n val client: LithicClient = LithicOkHttpClient.fromEnv()\n\n val signalsResponse: SignalsResponse = client.accounts().retrieveSignals("182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e")\n}', + }, + go: { + method: 'client.Accounts.GetSignals', + example: + 'package main\n\nimport (\n\t"context"\n\t"fmt"\n\n\t"github.com/lithic-com/lithic-go"\n\t"github.com/lithic-com/lithic-go/option"\n)\n\nfunc main() {\n\tclient := lithic.NewClient(\n\t\toption.WithAPIKey("My Lithic API Key"),\n\t)\n\tsignalsResponse, err := client.Accounts.GetSignals(context.TODO(), "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e")\n\tif err != nil {\n\t\tpanic(err.Error())\n\t}\n\tfmt.Printf("%+v\\n", signalsResponse.ApprovedTxnAmountM2)\n}\n', + }, + ruby: { + method: 'accounts.retrieve_signals', + example: + 'require "lithic"\n\nlithic = Lithic::Client.new(\n api_key: "My Lithic API Key",\n environment: "sandbox" # defaults to "production"\n)\n\nsignals_response = lithic.accounts.retrieve_signals("182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e")\n\nputs(signals_response)', + }, + http: { + example: + 'curl https://api.lithic.com/v1/accounts/$ACCOUNT_TOKEN/signals \\\n -H "Authorization: $LITHIC_API_KEY"', + }, + }, + }, { name: 'create', endpoint: '/v1/account_holders', @@ -2702,6 +2753,57 @@ const EMBEDDED_METHODS: MethodEntry[] = [ }, }, }, + { + name: 'retrieve_signals', + endpoint: '/v1/cards/{card_token}/signals', + httpMethod: 'get', + summary: 'Fetch card signals', + description: + "Returns behavioral feature state derived from a card's transaction history.\n\nThese signals expose the same data used by behavioral rule attributes (e.g. `AMOUNT_Z_SCORE` with `scope: CARD`, `IS_NEW_COUNTRY` with `scope: CARD`) and custom code `TRANSACTION_HISTORY_SIGNALS` features, allowing clients to inspect feature values before writing rules and debug rule behavior.\n", + stainlessPath: '(resource) cards > (method) retrieve_signals', + qualified: 'client.cards.retrieveSignals', + params: ['card_token: string;'], + response: + '{ approved_txn_amount_m2: number; approved_txn_amount_m2_30d: number; approved_txn_amount_m2_7d: number; approved_txn_amount_m2_90d: number; approved_txn_count: number; approved_txn_count_30d: number; approved_txn_count_7d: number; approved_txn_count_90d: number; avg_transaction_amount: number; avg_transaction_amount_30d: number; avg_transaction_amount_7d: number; avg_transaction_amount_90d: number; distinct_country_count: number; distinct_mcc_count: number; first_txn_at: string; is_first_transaction: boolean; last_cp_country: string; last_cp_postal_code: string; last_cp_timestamp: string; last_txn_approved_at: string; seen_countries: string[]; seen_mccs: string[]; seen_merchants: string[]; stdev_transaction_amount: number; stdev_transaction_amount_30d: number; stdev_transaction_amount_7d: number; stdev_transaction_amount_90d: number; three_ds_success_count: number; three_ds_success_rate: number; three_ds_total_count: number; time_since_last_transaction_days: number; }', + markdown: + "## retrieve_signals\n\n`client.cards.retrieveSignals(card_token: string): { approved_txn_amount_m2: number; approved_txn_amount_m2_30d: number; approved_txn_amount_m2_7d: number; approved_txn_amount_m2_90d: number; approved_txn_count: number; approved_txn_count_30d: number; approved_txn_count_7d: number; approved_txn_count_90d: number; avg_transaction_amount: number; avg_transaction_amount_30d: number; avg_transaction_amount_7d: number; avg_transaction_amount_90d: number; distinct_country_count: number; distinct_mcc_count: number; first_txn_at: string; is_first_transaction: boolean; last_cp_country: string; last_cp_postal_code: string; last_cp_timestamp: string; last_txn_approved_at: string; seen_countries: string[]; seen_mccs: string[]; seen_merchants: string[]; stdev_transaction_amount: number; stdev_transaction_amount_30d: number; stdev_transaction_amount_7d: number; stdev_transaction_amount_90d: number; three_ds_success_count: number; three_ds_success_rate: number; three_ds_total_count: number; time_since_last_transaction_days: number; }`\n\n**get** `/v1/cards/{card_token}/signals`\n\nReturns behavioral feature state derived from a card's transaction history.\n\nThese signals expose the same data used by behavioral rule attributes (e.g. `AMOUNT_Z_SCORE` with `scope: CARD`, `IS_NEW_COUNTRY` with `scope: CARD`) and custom code `TRANSACTION_HISTORY_SIGNALS` features, allowing clients to inspect feature values before writing rules and debug rule behavior.\n\n\n### Parameters\n\n- `card_token: string`\n\n### Returns\n\n- `{ approved_txn_amount_m2: number; approved_txn_amount_m2_30d: number; approved_txn_amount_m2_7d: number; approved_txn_amount_m2_90d: number; approved_txn_count: number; approved_txn_count_30d: number; approved_txn_count_7d: number; approved_txn_count_90d: number; avg_transaction_amount: number; avg_transaction_amount_30d: number; avg_transaction_amount_7d: number; avg_transaction_amount_90d: number; distinct_country_count: number; distinct_mcc_count: number; first_txn_at: string; is_first_transaction: boolean; last_cp_country: string; last_cp_postal_code: string; last_cp_timestamp: string; last_txn_approved_at: string; seen_countries: string[]; seen_mccs: string[]; seen_merchants: string[]; stdev_transaction_amount: number; stdev_transaction_amount_30d: number; stdev_transaction_amount_7d: number; stdev_transaction_amount_90d: number; three_ds_success_count: number; three_ds_success_rate: number; three_ds_total_count: number; time_since_last_transaction_days: number; }`\n Behavioral feature state for a card or account derived from its transaction history.\n\nDerived statistical features (averages, standard deviations, z-scores) are computed using Welford's online algorithm over approved transactions. Average fields are null when fewer than 5 approved transactions have been recorded. Standard deviation fields are null when fewer than 30 approved transactions have been recorded.\n\n3DS fields (`three_ds_success_rate`, `three_ds_success_count`, `three_ds_total_count`) are card-scoped and will be null for account responses.\n\nRaw fields (`seen_countries`, `seen_mccs`, `approved_txn_amount_m2`, etc.) are included so clients can compute their own transaction-specific derivations, such as checking whether a new transaction's country is in `seen_countries` to determine `is_new_country`, or computing a z-score using the raw mean and M2 values.\n\n - `approved_txn_amount_m2: number`\n - `approved_txn_amount_m2_30d: number`\n - `approved_txn_amount_m2_7d: number`\n - `approved_txn_amount_m2_90d: number`\n - `approved_txn_count: number`\n - `approved_txn_count_30d: number`\n - `approved_txn_count_7d: number`\n - `approved_txn_count_90d: number`\n - `avg_transaction_amount: number`\n - `avg_transaction_amount_30d: number`\n - `avg_transaction_amount_7d: number`\n - `avg_transaction_amount_90d: number`\n - `distinct_country_count: number`\n - `distinct_mcc_count: number`\n - `first_txn_at: string`\n - `is_first_transaction: boolean`\n - `last_cp_country: string`\n - `last_cp_postal_code: string`\n - `last_cp_timestamp: string`\n - `last_txn_approved_at: string`\n - `seen_countries: string[]`\n - `seen_mccs: string[]`\n - `seen_merchants: string[]`\n - `stdev_transaction_amount: number`\n - `stdev_transaction_amount_30d: number`\n - `stdev_transaction_amount_7d: number`\n - `stdev_transaction_amount_90d: number`\n - `three_ds_success_count: number`\n - `three_ds_success_rate: number`\n - `three_ds_total_count: number`\n - `time_since_last_transaction_days: number`\n\n### Example\n\n```typescript\nimport Lithic from 'lithic';\n\nconst client = new Lithic();\n\nconst signalsResponse = await client.cards.retrieveSignals('182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e');\n\nconsole.log(signalsResponse);\n```", + perLanguage: { + typescript: { + method: 'client.cards.retrieveSignals', + example: + "import Lithic from 'lithic';\n\nconst client = new Lithic({\n apiKey: process.env['LITHIC_API_KEY'], // This is the default and can be omitted\n});\n\nconst signalsResponse = await client.cards.retrieveSignals('182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e');\n\nconsole.log(signalsResponse.approved_txn_amount_m2);", + }, + python: { + method: 'cards.retrieve_signals', + example: + 'import os\nfrom lithic import Lithic\n\nclient = Lithic(\n api_key=os.environ.get("LITHIC_API_KEY"), # This is the default and can be omitted\n)\nsignals_response = client.cards.retrieve_signals(\n "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e",\n)\nprint(signals_response.approved_txn_amount_m2)', + }, + java: { + method: 'cards().retrieveSignals', + example: + 'package com.lithic.api.example;\n\nimport com.lithic.api.client.LithicClient;\nimport com.lithic.api.client.okhttp.LithicOkHttpClient;\nimport com.lithic.api.models.CardRetrieveSignalsParams;\nimport com.lithic.api.models.SignalsResponse;\n\npublic final class Main {\n private Main() {}\n\n public static void main(String[] args) {\n LithicClient client = LithicOkHttpClient.fromEnv();\n\n SignalsResponse signalsResponse = client.cards().retrieveSignals("182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e");\n }\n}', + }, + kotlin: { + method: 'cards().retrieveSignals', + example: + 'package com.lithic.api.example\n\nimport com.lithic.api.client.LithicClient\nimport com.lithic.api.client.okhttp.LithicOkHttpClient\nimport com.lithic.api.models.CardRetrieveSignalsParams\nimport com.lithic.api.models.SignalsResponse\n\nfun main() {\n val client: LithicClient = LithicOkHttpClient.fromEnv()\n\n val signalsResponse: SignalsResponse = client.cards().retrieveSignals("182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e")\n}', + }, + go: { + method: 'client.Cards.GetSignals', + example: + 'package main\n\nimport (\n\t"context"\n\t"fmt"\n\n\t"github.com/lithic-com/lithic-go"\n\t"github.com/lithic-com/lithic-go/option"\n)\n\nfunc main() {\n\tclient := lithic.NewClient(\n\t\toption.WithAPIKey("My Lithic API Key"),\n\t)\n\tsignalsResponse, err := client.Cards.GetSignals(context.TODO(), "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e")\n\tif err != nil {\n\t\tpanic(err.Error())\n\t}\n\tfmt.Printf("%+v\\n", signalsResponse.ApprovedTxnAmountM2)\n}\n', + }, + ruby: { + method: 'cards.retrieve_signals', + example: + 'require "lithic"\n\nlithic = Lithic::Client.new(\n api_key: "My Lithic API Key",\n environment: "sandbox" # defaults to "production"\n)\n\nsignals_response = lithic.cards.retrieve_signals("182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e")\n\nputs(signals_response)', + }, + http: { + example: + 'curl https://api.lithic.com/v1/cards/$CARD_TOKEN/signals \\\n -H "Authorization: $LITHIC_API_KEY"', + }, + }, + }, { name: 'renew', endpoint: '/v1/cards/{card_token}/renew', diff --git a/packages/mcp-server/src/methods.ts b/packages/mcp-server/src/methods.ts index 2af49292..41531e65 100644 --- a/packages/mcp-server/src/methods.ts +++ b/packages/mcp-server/src/methods.ts @@ -34,6 +34,12 @@ export const sdkMethods: SdkMethod[] = [ httpMethod: 'get', httpPath: '/v1/accounts', }, + { + clientCallName: 'client.accounts.retrieveSignals', + fullyQualifiedName: 'accounts.retrieveSignals', + httpMethod: 'get', + httpPath: '/v1/accounts/{account_token}/signals', + }, { clientCallName: 'client.accounts.retrieveSpendLimits', fullyQualifiedName: 'accounts.retrieveSpendLimits', @@ -316,6 +322,12 @@ export const sdkMethods: SdkMethod[] = [ httpMethod: 'post', httpPath: '/v1/cards/{card_token}/renew', }, + { + clientCallName: 'client.cards.retrieveSignals', + fullyQualifiedName: 'cards.retrieveSignals', + httpMethod: 'get', + httpPath: '/v1/cards/{card_token}/signals', + }, { clientCallName: 'client.cards.retrieveSpendLimits', fullyQualifiedName: 'cards.retrieveSpendLimits', diff --git a/src/client.ts b/src/client.ts index 43064e57..ba109c19 100644 --- a/src/client.ts +++ b/src/client.ts @@ -267,7 +267,7 @@ import { KYCExempt, RequiredDocument, } from './resources/account-holders/account-holders'; -import { AuthRules } from './resources/auth-rules/auth-rules'; +import { AuthRules, SignalsResponse } from './resources/auth-rules/auth-rules'; import { Card, CardConvertPhysicalParams, @@ -1256,7 +1256,7 @@ export declare namespace Lithic { type AccountHolderUploadDocumentParams as AccountHolderUploadDocumentParams, }; - export { AuthRules as AuthRules }; + export { AuthRules as AuthRules, type SignalsResponse as SignalsResponse }; export { AuthStreamEnrollment as AuthStreamEnrollment, type AuthStreamSecret as AuthStreamSecret }; diff --git a/src/resources/accounts.ts b/src/resources/accounts.ts index 5468f897..3b78513b 100644 --- a/src/resources/accounts.ts +++ b/src/resources/accounts.ts @@ -1,6 +1,7 @@ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. import { APIResource } from '../core/resource'; +import * as AuthRulesAPI from './auth-rules/auth-rules'; import { APIPromise } from '../core/api-promise'; import { CursorPage, type CursorPageParams, PagePromise } from '../core/pagination'; import { RequestOptions } from '../internal/request-options'; @@ -56,6 +57,28 @@ export class Accounts extends APIResource { return this._client.getAPIList('/v1/accounts', CursorPage, { query, ...options }); } + /** + * Returns behavioral feature state derived from an account's transaction history. + * + * These signals expose the same data used by behavioral rule attributes (e.g. + * `AMOUNT_Z_SCORE` with `scope: ACCOUNT`, `IS_NEW_COUNTRY` with `scope: ACCOUNT`) + * and custom code `TRANSACTION_HISTORY_SIGNALS` features, allowing clients to + * inspect feature values before writing rules and debug rule behavior. + * + * Note: 3DS fields are not available at the account scope and will be null. + * + * @example + * ```ts + * const signalsResponse = + * await client.accounts.retrieveSignals( + * '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e', + * ); + * ``` + */ + retrieveSignals(accountToken: string, options?: RequestOptions): APIPromise { + return this._client.get(path`/v1/accounts/${accountToken}/signals`, options); + } + /** * Get an Account's available spend limits, which is based on the spend limit * configured on the Account and the amount already spent over the spend limit's diff --git a/src/resources/auth-rules/auth-rules.ts b/src/resources/auth-rules/auth-rules.ts index acc63a26..ec6614f4 100644 --- a/src/resources/auth-rules/auth-rules.ts +++ b/src/resources/auth-rules/auth-rules.ts @@ -46,9 +46,216 @@ export class AuthRules extends APIResource { v2: V2API.V2 = new V2API.V2(this._client); } +/** + * Behavioral feature state for a card or account derived from its transaction + * history. + * + * Derived statistical features (averages, standard deviations, z-scores) are + * computed using Welford's online algorithm over approved transactions. Average + * fields are null when fewer than 5 approved transactions have been recorded. + * Standard deviation fields are null when fewer than 30 approved transactions have + * been recorded. + * + * 3DS fields (`three_ds_success_rate`, `three_ds_success_count`, + * `three_ds_total_count`) are card-scoped and will be null for account responses. + * + * Raw fields (`seen_countries`, `seen_mccs`, `approved_txn_amount_m2`, etc.) are + * included so clients can compute their own transaction-specific derivations, such + * as checking whether a new transaction's country is in `seen_countries` to + * determine `is_new_country`, or computing a z-score using the raw mean and M2 + * values. + */ +export interface SignalsResponse { + /** + * The Welford M2 accumulator for lifetime approved transaction amounts. Used + * together with `avg_transaction_amount` and `approved_txn_count` to compute the + * z-score of a new transaction amount (variance = M2 / (count - 1)). + */ + approved_txn_amount_m2: number | null; + + /** + * The Welford M2 accumulator for approved transaction amounts over the last 30 + * days. + */ + approved_txn_amount_m2_30d: number | null; + + /** + * The Welford M2 accumulator for approved transaction amounts over the last 7 + * days. + */ + approved_txn_amount_m2_7d: number | null; + + /** + * The Welford M2 accumulator for approved transaction amounts over the last 90 + * days. + */ + approved_txn_amount_m2_90d: number | null; + + /** + * The total number of approved transactions over the entity's lifetime. + */ + approved_txn_count: number | null; + + /** + * The number of approved transactions in the last 30 days. + */ + approved_txn_count_30d: number | null; + + /** + * The number of approved transactions in the last 7 days. + */ + approved_txn_count_7d: number | null; + + /** + * The number of approved transactions in the last 90 days. + */ + approved_txn_count_90d: number | null; + + /** + * The average approved transaction amount over the entity's lifetime, in cents. + * Null if fewer than 5 approved transactions have been recorded. + */ + avg_transaction_amount: number | null; + + /** + * The average approved transaction amount over the last 30 days, in cents. Null if + * fewer than 5 approved transactions in window. + */ + avg_transaction_amount_30d: number | null; + + /** + * The average approved transaction amount over the last 7 days, in cents. Null if + * fewer than 5 approved transactions in window. + */ + avg_transaction_amount_7d: number | null; + + /** + * The average approved transaction amount over the last 90 days, in cents. Null if + * fewer than 5 approved transactions in window. + */ + avg_transaction_amount_90d: number | null; + + /** + * The number of distinct merchant countries seen in the entity's transaction + * history. + */ + distinct_country_count: number | null; + + /** + * The number of distinct MCCs seen in the entity's transaction history. + */ + distinct_mcc_count: number | null; + + /** + * The timestamp of the first approved transaction for the entity, in ISO 8601 + * format. + */ + first_txn_at: string | null; + + /** + * Whether the entity has no prior transaction history. Returns true if no history + * is found. Null if transaction history exists but a first transaction timestamp + * is unavailable. + */ + is_first_transaction: boolean | null; + + /** + * The merchant country of the last card-present transaction. + */ + last_cp_country: string | null; + + /** + * The merchant postal code of the last card-present transaction. + */ + last_cp_postal_code: string | null; + + /** + * The timestamp of the last card-present transaction, in ISO 8601 format. + */ + last_cp_timestamp: string | null; + + /** + * The timestamp of the most recent approved transaction for the entity, in ISO + * 8601 format. + */ + last_txn_approved_at: string | null; + + /** + * The set of merchant countries seen in the entity's transaction history. Clients + * can use this to determine whether a new transaction's country is novel (i.e. + * compute `is_new_country`). + */ + seen_countries: Array | null; + + /** + * The set of MCCs seen in the entity's transaction history. Clients can use this + * to determine whether a new transaction's MCC is novel (i.e. compute + * `is_new_mcc`). + */ + seen_mccs: Array | null; + + /** + * The set of card acceptor IDs seen in the card's approved transaction history, + * capped at the 1000 most recently seen. Null for account responses. Clients can + * use this to determine whether a new transaction's merchant is novel (i.e. + * compute `is_new_merchant`). + */ + seen_merchants: Array | null; + + /** + * The standard deviation of approved transaction amounts over the entity's + * lifetime, in cents. Null if fewer than 30 approved transactions have been + * recorded. + */ + stdev_transaction_amount: number | null; + + /** + * The standard deviation of approved transaction amounts over the last 30 days, in + * cents. Null if fewer than 30 approved transactions in window. + */ + stdev_transaction_amount_30d: number | null; + + /** + * The standard deviation of approved transaction amounts over the last 7 days, in + * cents. Null if fewer than 30 approved transactions in window. + */ + stdev_transaction_amount_7d: number | null; + + /** + * The standard deviation of approved transaction amounts over the last 90 days, in + * cents. Null if fewer than 30 approved transactions in window. + */ + stdev_transaction_amount_90d: number | null; + + /** + * The number of successful 3DS authentications for the card. Null for account + * responses. + */ + three_ds_success_count: number | null; + + /** + * The 3DS authentication success rate for the card, as a percentage from 0.0 to + * 100.0. Null for account responses. + */ + three_ds_success_rate: number | null; + + /** + * The total number of 3DS authentication attempts for the card. Null for account + * responses. + */ + three_ds_total_count: number | null; + + /** + * The number of days since the last approved transaction on the entity. + */ + time_since_last_transaction_days: number | null; +} + AuthRules.V2 = V2; export declare namespace AuthRules { + export { type SignalsResponse as SignalsResponse }; + export { V2 as V2, type AuthRule as AuthRule, diff --git a/src/resources/auth-rules/index.ts b/src/resources/auth-rules/index.ts index edb2dd74..156095ab 100644 --- a/src/resources/auth-rules/index.ts +++ b/src/resources/auth-rules/index.ts @@ -1,6 +1,6 @@ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. -export { AuthRules } from './auth-rules'; +export { AuthRules, type SignalsResponse } from './auth-rules'; export { V2, type AuthRule, diff --git a/src/resources/cards/cards.ts b/src/resources/cards/cards.ts index 93f4fd71..13e4007b 100644 --- a/src/resources/cards/cards.ts +++ b/src/resources/cards/cards.ts @@ -2,6 +2,7 @@ import { APIResource } from '../../core/resource'; import * as Shared from '../shared'; +import * as AuthRulesAPI from '../auth-rules/auth-rules'; import * as BalancesAPI from './balances'; import { BalanceListParams, Balances } from './balances'; import * as FinancialTransactionsAPI from './financial-transactions'; @@ -352,6 +353,25 @@ export class Cards extends APIResource { return this._client.post(path`/v1/cards/${cardToken}/renew`, { body, ...options }); } + /** + * Returns behavioral feature state derived from a card's transaction history. + * + * These signals expose the same data used by behavioral rule attributes (e.g. + * `AMOUNT_Z_SCORE` with `scope: CARD`, `IS_NEW_COUNTRY` with `scope: CARD`) and + * custom code `TRANSACTION_HISTORY_SIGNALS` features, allowing clients to inspect + * feature values before writing rules and debug rule behavior. + * + * @example + * ```ts + * const signalsResponse = await client.cards.retrieveSignals( + * '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e', + * ); + * ``` + */ + retrieveSignals(cardToken: string, options?: RequestOptions): APIPromise { + return this._client.get(path`/v1/cards/${cardToken}/signals`, options); + } + /** * Get a Card's available spend limit, which is based on the spend limit configured * on the Card and the amount already spent over the spend limit's duration. For diff --git a/src/resources/index.ts b/src/resources/index.ts index 61dfe07c..31f6c61f 100644 --- a/src/resources/index.ts +++ b/src/resources/index.ts @@ -39,7 +39,7 @@ export { type AccountListParams, type AccountsCursorPage, } from './accounts'; -export { AuthRules } from './auth-rules/auth-rules'; +export { AuthRules, type SignalsResponse } from './auth-rules/auth-rules'; export { AuthStreamEnrollment, type AuthStreamSecret } from './auth-stream-enrollment'; export { Balances, type Balance, type BalanceListParams, type BalancesSinglePage } from './balances'; export { diff --git a/tests/api-resources/accounts.test.ts b/tests/api-resources/accounts.test.ts index d18a4b41..1b94b7d6 100644 --- a/tests/api-resources/accounts.test.ts +++ b/tests/api-resources/accounts.test.ts @@ -58,6 +58,17 @@ describe('resource accounts', () => { ).rejects.toThrow(Lithic.NotFoundError); }); + test('retrieveSignals', async () => { + const responsePromise = client.accounts.retrieveSignals('182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e'); + const rawResponse = await responsePromise.asResponse(); + expect(rawResponse).toBeInstanceOf(Response); + const response = await responsePromise; + expect(response).not.toBeInstanceOf(Response); + const dataAndResponse = await responsePromise.withResponse(); + expect(dataAndResponse.data).toBe(response); + expect(dataAndResponse.response).toBe(rawResponse); + }); + test('retrieveSpendLimits', async () => { const responsePromise = client.accounts.retrieveSpendLimits('182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e'); const rawResponse = await responsePromise.asResponse(); diff --git a/tests/api-resources/cards/cards.test.ts b/tests/api-resources/cards/cards.test.ts index 737dae32..73d52bd8 100644 --- a/tests/api-resources/cards/cards.test.ts +++ b/tests/api-resources/cards/cards.test.ts @@ -242,6 +242,17 @@ describe('resource cards', () => { }); }); + test('retrieveSignals', async () => { + const responsePromise = client.cards.retrieveSignals('182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e'); + const rawResponse = await responsePromise.asResponse(); + expect(rawResponse).toBeInstanceOf(Response); + const response = await responsePromise; + expect(response).not.toBeInstanceOf(Response); + const dataAndResponse = await responsePromise.withResponse(); + expect(dataAndResponse.data).toBe(response); + expect(dataAndResponse.response).toBe(rawResponse); + }); + test('retrieveSpendLimits', async () => { const responsePromise = client.cards.retrieveSpendLimits('182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e'); const rawResponse = await responsePromise.asResponse(); From 489e043efd3a6134954b04f6220b660517602160 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Fri, 8 May 2026 17:09:01 +0000 Subject: [PATCH 4/4] release: 0.139.0 --- .release-please-manifest.json | 2 +- CHANGELOG.md | 14 ++++++++++++++ package.json | 2 +- packages/mcp-server/manifest.json | 2 +- packages/mcp-server/package.json | 2 +- packages/mcp-server/src/server.ts | 2 +- src/version.ts | 2 +- 7 files changed, 20 insertions(+), 6 deletions(-) diff --git a/.release-please-manifest.json b/.release-please-manifest.json index a51a25af..93396555 100644 --- a/.release-please-manifest.json +++ b/.release-please-manifest.json @@ -1,3 +1,3 @@ { - ".": "0.138.0" + ".": "0.139.0" } diff --git a/CHANGELOG.md b/CHANGELOG.md index 46cea6ca..70cc51c3 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,19 @@ # Changelog +## 0.139.0 (2026-05-08) + +Full Changelog: [v0.138.0...v0.139.0](https://github.com/lithic-com/lithic-node/compare/v0.138.0...v0.139.0) + +### Features + +* **api:** add retrieveSignals methods to accounts and cards ([e5f850d](https://github.com/lithic-com/lithic-node/commit/e5f850d44eb9df6a5015f337954c287a294b7324)) +* **api:** add unit param and travel attributes to auth rules v2 conditions ([306ba11](https://github.com/lithic-com/lithic-node/commit/306ba11dc0e555f7d76c90eed21bd83a1e691458)) + + +### Chores + +* redact api-key headers in debug logs ([071bf9f](https://github.com/lithic-com/lithic-node/commit/071bf9fead1e4fd83819ccad85e1cffb6145ab03)) + ## 0.138.0 (2026-05-06) Full Changelog: [v0.137.0...v0.138.0](https://github.com/lithic-com/lithic-node/compare/v0.137.0...v0.138.0) diff --git a/package.json b/package.json index 256c5a4f..c920b378 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "lithic", - "version": "0.138.0", + "version": "0.139.0", "description": "The official TypeScript library for the Lithic API", "author": "Lithic ", "types": "dist/index.d.ts", diff --git a/packages/mcp-server/manifest.json b/packages/mcp-server/manifest.json index 8eb6ef11..4fdea2c5 100644 --- a/packages/mcp-server/manifest.json +++ b/packages/mcp-server/manifest.json @@ -1,7 +1,7 @@ { "dxt_version": "0.2", "name": "lithic-mcp", - "version": "0.138.0", + "version": "0.139.0", "description": "The official MCP Server for the Lithic API", "author": { "name": "Lithic", diff --git a/packages/mcp-server/package.json b/packages/mcp-server/package.json index 87f7f80d..19b9831a 100644 --- a/packages/mcp-server/package.json +++ b/packages/mcp-server/package.json @@ -1,6 +1,6 @@ { "name": "lithic-mcp", - "version": "0.138.0", + "version": "0.139.0", "description": "The official MCP Server for the Lithic API", "author": "Lithic ", "types": "dist/index.d.ts", diff --git a/packages/mcp-server/src/server.ts b/packages/mcp-server/src/server.ts index 8e1d7fcd..7612b3f1 100644 --- a/packages/mcp-server/src/server.ts +++ b/packages/mcp-server/src/server.ts @@ -29,7 +29,7 @@ export const newMcpServer = async ({ new McpServer( { name: 'lithic_api', - version: '0.138.0', + version: '0.139.0', }, { instructions: await getInstructions({ stainlessApiKey, customInstructionsPath }), diff --git a/src/version.ts b/src/version.ts index 26aad63c..d8122e8a 100644 --- a/src/version.ts +++ b/src/version.ts @@ -1 +1 @@ -export const VERSION = '0.138.0'; // x-release-please-version +export const VERSION = '0.139.0'; // x-release-please-version