Skip to content

Commit 0f0579f

Browse files
release: 8.2.0 (#641)
* fix(mcp): fix options parsing * feat(api): api update * fix(mcp): fix env parsing * fix(mcp): update code tool prompt * chore(internal): codegen related update * chore(internal): codegen related update * chore(internal): codegen related update * chore(internal): codegen related update * chore: fix typo in descriptions * release: 8.2.0 --------- Co-authored-by: stainless-app[bot] <142633134+stainless-app[bot]@users.noreply.github.com>
1 parent 1bcd487 commit 0f0579f

18 files changed

Lines changed: 81 additions & 47 deletions

File tree

.release-please-manifest.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
{
2-
".": "8.1.1"
2+
".": "8.2.0"
33
}

.stats.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
configured_endpoints: 46
2-
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/finch%2Ffinch-ded87cb73affcaff9cf779d9cfd119a4026cfc1757b39be95d933edea48a0328.yml
3-
openapi_spec_hash: 0e6394b222fc68d7607114e70b72d23e
2+
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/finch%2Ffinch-46f433f34d440aa1dfcc48cc8d822c598571b68be2f723ec99e1b4fba6c13b1e.yml
3+
openapi_spec_hash: 5b5cd728776723ac773900f7e8a32c05
44
config_hash: 0892e2e0eeb0343a022afa62e9080dd1

CHANGELOG.md

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,29 @@
11
# Changelog
22

3+
## 8.2.0 (2026-01-13)
4+
5+
Full Changelog: [v8.1.1...v8.2.0](https://github.com/Finch-API/finch-api-node/compare/v8.1.1...v8.2.0)
6+
7+
### Features
8+
9+
* **api:** api update ([07174ee](https://github.com/Finch-API/finch-api-node/commit/07174eed580ea7be80172df97f7de41fc9bf09fd))
10+
11+
12+
### Bug Fixes
13+
14+
* **mcp:** fix env parsing ([da539c1](https://github.com/Finch-API/finch-api-node/commit/da539c18318057054f9f7a6e39a8d8a8c62ef04b))
15+
* **mcp:** fix options parsing ([50db4af](https://github.com/Finch-API/finch-api-node/commit/50db4af071d340114f0e129d4843fd92be84d391))
16+
* **mcp:** update code tool prompt ([f3b178b](https://github.com/Finch-API/finch-api-node/commit/f3b178b2683dd7f86bba4034e5d8baf7db0e52fe))
17+
18+
19+
### Chores
20+
21+
* fix typo in descriptions ([3ea6c6f](https://github.com/Finch-API/finch-api-node/commit/3ea6c6fd84e2db27791d5e01e3841c383713cf6e))
22+
* **internal:** codegen related update ([2fc7cb3](https://github.com/Finch-API/finch-api-node/commit/2fc7cb3ba446371be9d018a2625039e95e850b26))
23+
* **internal:** codegen related update ([65d66db](https://github.com/Finch-API/finch-api-node/commit/65d66db7811483626e17ad740b7740467948b066))
24+
* **internal:** codegen related update ([36d593e](https://github.com/Finch-API/finch-api-node/commit/36d593ed51b766a5493fa07ff38e7123f6b2ccac))
25+
* **internal:** codegen related update ([55094b0](https://github.com/Finch-API/finch-api-node/commit/55094b0eac5fff043ca2a0e177843a7eb8a73c97))
26+
327
## 8.1.1 (2026-01-06)
428

529
Full Changelog: [v8.1.0...v8.1.1](https://github.com/Finch-API/finch-api-node/compare/v8.1.0...v8.1.1)

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@tryfinch/finch-api",
3-
"version": "8.1.1",
3+
"version": "8.2.0",
44
"description": "The official TypeScript library for the Finch API",
55
"author": "Finch <founders@tryfinch.com>",
66
"types": "dist/index.d.ts",

packages/mcp-server/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@tryfinch/finch-api-mcp",
3-
"version": "8.1.1",
3+
"version": "8.2.0",
44
"description": "The official MCP Server for the Finch API",
55
"author": "Finch <founders@tryfinch.com>",
66
"types": "dist/index.d.ts",

packages/mcp-server/src/code-tool.ts

Lines changed: 23 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,28 @@ import { McpTool, Metadata, ToolCallResult, asErrorResult, asTextContentResult }
44
import { Tool } from '@modelcontextprotocol/sdk/types.js';
55
import { readEnv } from './server';
66
import { WorkerInput, WorkerOutput } from './code-tool-types';
7+
8+
const prompt = `Runs JavaScript code to interact with the Finch API.
9+
10+
You are a skilled programmer writing code to interface with the service.
11+
Define an async function named "run" that takes a single parameter of an initialized SDK client and it will be run.
12+
For example:
13+
14+
\`\`\`
15+
async function run(client) {
16+
const page = await client.hris.directory.list();
17+
const individualInDirectory = page.individuals[0]
18+
19+
console.log(individualInDirectory.id);
20+
}
21+
\`\`\`
22+
23+
You will be returned anything that your function returns, plus the results of any console.log statements.
24+
Do not add try-catch blocks for single API calls. The tool will handle errors for you.
25+
Do not add comments unless necessary for generating better code.
26+
Code will run in a container, and cannot interact with the network outside of the given SDK client.
27+
Variables will not persist between calls, so make sure to return or log any data you might need later.`;
28+
729
/**
830
* A tool that runs code against a copy of the SDK.
931
*
@@ -17,8 +39,7 @@ export function codeTool(): McpTool {
1739
const metadata: Metadata = { resource: 'all', operation: 'write', tags: [] };
1840
const tool: Tool = {
1941
name: 'execute',
20-
description:
21-
'Runs JavaScript code to interact with the API.\n\nYou are a skilled programmer writing code to interface with the service.\nDefine an async function named "run" that takes a single parameter of an initialized SDK client and it will be run.\nWrite code within this template:\n\n```\nasync function run(client) {\n // Fill this out\n}\n```\n\nYou will be returned anything that your function returns, plus the results of any console.log statements.\nIf any code triggers an error, the tool will return an error response, so you do not need to add error handling unless you want to output something more helpful than the raw error.\nIt is not necessary to add comments to code, unless by adding those comments you believe that you can generate better code.\nThis code will run in a container, and you will not be able to use fetch or otherwise interact with the network calls other than through the client you are given.\nAny variables you define won\'t live between successive uses of this call, so make sure to return or log any data you might need later.',
42+
description: prompt,
2243
inputSchema: { type: 'object', properties: { code: { type: 'string' } } },
2344
};
2445
const handler = async (_: unknown, args: any): Promise<ToolCallResult> => {
@@ -36,7 +57,6 @@ export function codeTool(): McpTool {
3657
...(stainlessAPIKey && { Authorization: stainlessAPIKey }),
3758
'Content-Type': 'application/json',
3859
client_envs: JSON.stringify({
39-
FINCH_ACCESS_TOKEN: readEnv('FINCH_ACCESS_TOKEN'),
4060
FINCH_CLIENT_ID: readEnv('FINCH_CLIENT_ID'),
4161
FINCH_CLIENT_SECRET: readEnv('FINCH_CLIENT_SECRET'),
4262
FINCH_WEBHOOK_SECRET: readEnv('FINCH_WEBHOOK_SECRET'),

packages/mcp-server/src/options.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ export function parseCLIOptions(): CLIOptions {
5555
const transport = argv.transport as 'stdio' | 'http';
5656

5757
return {
58-
includeDocsTools,
58+
...(includeDocsTools !== undefined && { includeDocsTools }),
5959
transport,
6060
port: argv.port,
6161
socket: argv.socket,
@@ -87,6 +87,6 @@ export function parseQueryOptions(defaultOptions: McpOptions, query: unknown): M
8787
: defaultOptions.includeDocsTools;
8888

8989
return {
90-
includeDocsTools: docsTools,
90+
...(docsTools !== undefined && { includeDocsTools: docsTools }),
9191
};
9292
}

packages/mcp-server/src/server.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ export const newMcpServer = () =>
2121
new McpServer(
2222
{
2323
name: 'tryfinch_finch_api_api',
24-
version: '8.1.1',
24+
version: '8.2.0',
2525
},
2626
{ capabilities: { tools: {}, logging: {} } },
2727
);

packages/mcp-server/tests/options.test.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ describe('parseCLIOptions', () => {
2626
const result = parseCLIOptions();
2727

2828
expect(result.transport).toBe('http');
29-
expect(result.port).toBe('2222');
29+
expect(result.port).toBe(2222);
3030
cleanup();
3131
});
3232
});
@@ -38,13 +38,13 @@ describe('parseQueryOptions', () => {
3838
const query = '';
3939
const result = parseQueryOptions(defaultOptions, query);
4040

41-
expect(result).toBe({});
41+
expect(result).toEqual({});
4242
});
4343

4444
it('should handle invalid query string gracefully', () => {
45-
const query = 'invalid=value&operation=invalid-operation';
45+
const query = 'invalid=value&tools=invalid-operation';
4646

47-
// Should throw due to Zod validation for invalid operation
47+
// Should throw due to Zod validation for invalid tools
4848
expect(() => parseQueryOptions(defaultOptions, query)).toThrow();
4949
});
5050
});

src/resources/hris/company/pay-statement-item/pay-statement-item.ts

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,9 +21,8 @@ export class PayStatementItem extends APIResource {
2121
rules: RulesAPI.Rules = new RulesAPI.Rules(this._client);
2222

2323
/**
24-
* **Beta:** this endpoint currently serves employers onboarded after March 4th and
25-
* historical support will be added soon Retrieve a list of detailed pay statement
26-
* items for the access token's connection account.
24+
* Retrieve a list of detailed pay statement items for the access token's
25+
* connection account.
2726
*
2827
* @example
2928
* ```ts

0 commit comments

Comments
 (0)