Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 8 additions & 6 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -1,12 +1,14 @@
name: CI
on:
push:
branches-ignore:
- 'generated'
- 'codegen/**'
- 'integrated/**'
- 'stl-preview-head/**'
- 'stl-preview-base/**'
branches:
- '**'
- '!integrated/**'
- '!stl-preview-head/**'
- '!stl-preview-base/**'
- '!generated'
- '!codegen/**'
- 'codegen/stl/**'
pull_request:
branches-ignore:
- 'stl-preview-head/**'
Expand Down
2 changes: 1 addition & 1 deletion .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
".": "0.29.3"
".": "0.30.0"
}
4 changes: 2 additions & 2 deletions .stats.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
configured_endpoints: 20
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/brand-dev%2Fbrand.dev-584d3486a6c5bf7b68dcaacb0bde2ef5f648c158e5c5ebccc7a7684d95abc832.yml
openapi_spec_hash: 29a53e1f96a2c5d9407f1a0938e301bf
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/brand-dev%2Fbrand.dev-67e4ffa39d74649a6ae6b21e9f86cffa83c8a02d640ca6b4d4a3e619b54fbd38.yml
openapi_spec_hash: 762e7ea7ae23297cc6b01f600a485410
config_hash: 4cd3173ea1cce7183640aae49cfbb374
14 changes: 14 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,19 @@
# Changelog

## 0.30.0 (2026-03-18)

Full Changelog: [v0.29.3...v0.30.0](https://github.com/brand-dot-dev/typescript-sdk/compare/v0.29.3...v0.30.0)

### Features

* **api:** api update ([bde4a7d](https://github.com/brand-dot-dev/typescript-sdk/commit/bde4a7dbf808e1ecf8084805b598c684d18b8ae9))


### Chores

* **internal:** support x-stainless-mcp-client-permissions headers in MCP servers ([e167d33](https://github.com/brand-dot-dev/typescript-sdk/commit/e167d33619f4ec64d1c30279a8104e35aceef339))
* **internal:** tweak CI branches ([7143eb4](https://github.com/brand-dot-dev/typescript-sdk/commit/7143eb47d5df5b11f51dc8a47c4eb128f23f0e57))

## 0.29.3 (2026-03-14)

Full Changelog: [v0.29.2...v0.29.3](https://github.com/brand-dot-dev/typescript-sdk/compare/v0.29.2...v0.29.3)
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "brand.dev",
"version": "0.29.3",
"version": "0.30.0",
"description": "The official TypeScript library for the Brand Dev API",
"author": "Brand Dev <hello@brand.dev>",
"types": "dist/index.d.ts",
Expand Down
2 changes: 1 addition & 1 deletion packages/mcp-server/manifest.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"dxt_version": "0.2",
"name": "brand.dev-mcp",
"version": "0.29.3",
"version": "0.30.0",
"description": "The official MCP Server for the Brand Dev API",
"author": {
"name": "Brand Dev",
Expand Down
2 changes: 1 addition & 1 deletion packages/mcp-server/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "brand.dev-mcp",
"version": "0.29.3",
"version": "0.30.0",
"description": "The official MCP Server for the Brand Dev API",
"author": "Brand Dev <hello@brand.dev>",
"types": "dist/index.d.ts",
Expand Down
30 changes: 29 additions & 1 deletion packages/mcp-server/src/http.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,9 +40,37 @@ const newServer = async ({
}
}

// Parse x-stainless-mcp-client-permissions header to override permission options
//
// Note: Permissions are best-effort and intended to prevent clients from doing unexpected things;
// they're not a hard security boundary, so we allow arbitrary, client-driven overrides.
//
// See the Stainless MCP documentation for more details.
let effectiveMcpOptions = mcpOptions;
const clientPermissionsHeader = req.headers['x-stainless-mcp-client-permissions'];
if (typeof clientPermissionsHeader === 'string') {
try {
const parsed = JSON.parse(clientPermissionsHeader);
if (parsed && typeof parsed === 'object' && !Array.isArray(parsed)) {
effectiveMcpOptions = {
...mcpOptions,
...(typeof parsed.allow_http_gets === 'boolean' && { codeAllowHttpGets: parsed.allow_http_gets }),
...(Array.isArray(parsed.allowed_methods) && { codeAllowedMethods: parsed.allowed_methods }),
...(Array.isArray(parsed.blocked_methods) && { codeBlockedMethods: parsed.blocked_methods }),
};
getLogger().info(
{ clientPermissions: parsed },
'Overriding code execution permissions from x-stainless-mcp-client-permissions header',
);
}
} catch (error) {
getLogger().warn({ error }, 'Failed to parse x-stainless-mcp-client-permissions header');
}
}

await initMcpServer({
server: server,
mcpOptions: mcpOptions,
mcpOptions: effectiveMcpOptions,
clientOptions: {
...clientOptions,
...authOptions,
Expand Down
2 changes: 1 addition & 1 deletion packages/mcp-server/src/server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ export const newMcpServer = async (stainlessApiKey: string | undefined) =>
new McpServer(
{
name: 'brand_dev_api',
version: '0.29.3',
version: '0.30.0',
},
{
instructions: await getInstructions(stainlessApiKey),
Expand Down
245 changes: 245 additions & 0 deletions src/resources/brand.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5660,6 +5660,251 @@ export interface BrandRetrieveByNameParams {
*/
name: string;

/**
* Optional country code (GL parameter) to specify the country. This affects the
* geographic location used for search queries.
*/
country_gl?:
| 'ad'
| 'ae'
| 'af'
| 'ag'
| 'ai'
| 'al'
| 'am'
| 'an'
| 'ao'
| 'aq'
| 'ar'
| 'as'
| 'at'
| 'au'
| 'aw'
| 'az'
| 'ba'
| 'bb'
| 'bd'
| 'be'
| 'bf'
| 'bg'
| 'bh'
| 'bi'
| 'bj'
| 'bm'
| 'bn'
| 'bo'
| 'br'
| 'bs'
| 'bt'
| 'bv'
| 'bw'
| 'by'
| 'bz'
| 'ca'
| 'cc'
| 'cd'
| 'cf'
| 'cg'
| 'ch'
| 'ci'
| 'ck'
| 'cl'
| 'cm'
| 'cn'
| 'co'
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
| 'so'
| 'sr'
| 'st'
| 'sv'
| 'sy'
| 'sz'
| 'tc'
| 'td'
| 'tf'
| 'tg'
| 'th'
| 'tj'
| 'tk'
| 'tl'
| 'tm'
| 'tn'
| 'to'
| 'tr'
| 'tt'
| 'tv'
| 'tw'
| 'tz'
| 'ua'
| 'ug'
| 'um'
| 'us'
| 'uy'
| 'uz'
| 'va'
| 'vc'
| 've'
| 'vg'
| 'vi'
| 'vn'
| 'vu'
| 'wf'
| 'ws'
| 'ye'
| 'yt'
| 'za'
| 'zm'
| 'zw';

/**
* Optional parameter to force the language of the retrieved brand data.
*/
Expand Down
2 changes: 1 addition & 1 deletion src/version.ts
Original file line number Diff line number Diff line change
@@ -1 +1 @@
export const VERSION = '0.29.3'; // x-release-please-version
export const VERSION = '0.30.0'; // x-release-please-version
1 change: 1 addition & 0 deletions tests/api-resources/brand.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -257,6 +257,7 @@ describe('resource brand', () => {
test.skip('retrieveByName: required and optional params', async () => {
const response = await client.brand.retrieveByName({
name: 'xxx',
country_gl: 'ad',
force_language: 'albanian',
maxSpeed: true,
timeoutMS: 1000,
Expand Down
Loading