Skip to content

feat!: regenerate SDK for API 2026-09-30 with simba-3.5 - #27

Merged
vitalragaz merged 290 commits into
mainfrom
feat/regenerate-2026-09-30
Oct 29, 2026
Merged

vitalragaz merged 290 commits into
mainfrom
feat/regenerate-2026-09-30

Conversation

@vitalragaz

@vitalragaz vitalragaz commented Oct 27, 2026 •

Copy link
Copy Markdown
Contributor

@speechify/api catches up with the API: simba-3.5, projects, workspaces, audio watermark verification and webhook endpoints, with API version 2026-09-30 as the default. Merging releases 5.0.0.

Why: Fern has pushed every regeneration since August to sdk-release, and nobody merged it, so 4.0.1 predates simba-3.5. This PR merges sdk-release, taking generated files from it and hand-kept files from main. It then regenerates src/ locally from SpeechifyInc/speechify-api#4744's spec, which also makes future regenerations arrive as PRs like this one.

What to look at

  • SpeechifyEnvironment.Default is { base, websocket }. The WebSocket URL used to be called production because of the AsyncAPI server's name. SpeechifyInc/speechify-api#4744 renames that server, so the name is right in the same major that turns the environment into an object.
  • src/api/resources/audio/client/Client.ts is generated again and leaves .fernignore. It was shielded to pass eventDiscriminator: "type" to core.Stream, and the rest of it had gone stale. It read environment as a string, so new SpeechifyClient() threw base.includes is not a function, and it sent version 2026-09-13 while every other client sent 2026-09-30. The generated client parses each SSE data: line, which is correct for how the API frames events: one named event, one single-line JSON payload carrying type, then a blank line. The 413 now comes from the spec, so ContentTooLargeError stays.
  • tests/custom.test.ts (new, hand-kept): offline tests of a client built with no options. They pin the environment shape, check the URL, Bearer header and one Speechify-Version across resource clients, read a with-timestamps stream framed exactly as the API writes it (final speech.done included), and check that a 413 throws ContentTooLargeError.
  • README.md, reference.md (hand-kept): examples use simba-3.5 and version 2026-09-30. reference.md is regenerated (projects, workspaces, watermark, webhook endpoints) and keeps the streamWithTimestamps narrowing example. Neither names an environment URL, and regenerating from SpeechifyInc/speechify-api#4744's spec changes neither.
  • Unchanged on purpose: LICENSE stays MIT and in .fernignore. package.json stays at 4.0.1 so release-please bumps it. AGENTS.md documents regeneration PRs and the title rule.

Merge order and follow-ups

  • Merge and release this first. SpeechifyInc/speechify-api#4744 pins the docs snippets to 5.0.0, so it merges only after 5.0.0 is on npm and PyPI.
  • If SpeechifyInc/speechify-api#4741 merges before this, sdk-release moves once more. Merge it into this branch again before merging. Its noSerdeLayer: true changes no byte of the SDK; I checked.
  • Follow-up after the release, not now: reset sdk-release to main, or delete it once SpeechifyInc/speechify-api#4744 is live.

How verified

  • pnpm build passes. pnpm exec vitest run --maxWorkers=2: 32 files, 663 tests pass.
  • Offline smoke test of client.audio.speech() on the default environment: it hits https://api.speechify.ai/v1/audio/speech with a Bearer header (tests/custom.test.ts).
  • Local fern generate --local (generator 3.70.1) on SpeechifyInc/speechify-api#4744's spec reproduces this branch's src/ byte for byte, apart from the shielded Stream.ts and the version strings. It also reproduces the hand-kept reference.md unchanged.
  • The README snippet type-checks under strict tsc.
Investigation detail
  • sdk-release head: 2e88613. No other open PR touches src/.
  • An earlier revision of this PR got eventDiscriminator back through x-fern-discriminator-context: protocol in the spec. That annotation made the Python generator yield event classes that do not match its declared union, so it was dropped. The shielded Stream.ts (abort fix) keeps its named-event parser for any stream that asks for it.
  • The generated audio client adds ConflictError (409) on the synthesis calls, as the spec declares. It extends SpeechifyError, so existing catches still match.

BREAKING CHANGE: the default API version moves to 2026-09-30, the model unions narrow, and environment takes an object.

  • Requests now send Speechify-Version: 2026-09-30 instead of 2026-09-13. On that version simba-english and simba-multilingual return 400 model_retired, and output_format: pcm_16000 returns real 16 kHz audio instead of 24 kHz bytes labelled 16 kHz.
  • To keep the 4.x wire behaviour, pin the version: new SpeechifyClient({ version: "2026-09-13" })
  • GetSpeechRequest.Model and GetStreamRequest.Model drop simba-english and simba-multilingual and add simba-3.5, so code that names a Simba 1.6 id stops compiling.
  • environment no longer accepts a URL string. SpeechifyEnvironment.Default is now { base: "https://api.speechify.ai", websocket: "wss://api.speechify.ai" }. For a custom REST URL, pass baseUrl: "https://...".

fern-api Bot and others added 23 commits September 26, 2026 21:00
…rom main

Conflicts resolved by rule: every Fern-generated file comes from sdk-release
(840e0cb regeneration); every .fernignore-listed file and the release-please
state (package.json version, .fern/metadata.json sdkVersion) comes from main.
The shielded src/api/resources/audio/client/Client.ts existed only to pass
eventDiscriminator: "type" to core.Stream. Frozen since August, it read the
new {base, production} environment as a string (TypeError on every
client.audio.speech() with the default environment, 3 TS2345 build errors),
pinned Speechify-Version 2026-09-13 and had no watermark getter.

It is now the generator's output for the 840e0cb spec plus the
x-fern-discriminator-context annotation that SpeechifyInc/speechify-api adds,
so the next regeneration produces the same file. tests/custom.test.ts covers
the default environment, which no generated test does.
…rface

reference.md is the generator's output for this spec (it adds projects,
workspaces, audio.watermark and webhooks.endpoints, which the frozen copy
never had) with the hand-kept streamWithTimestamps example re-applied.
Both files default to Speechify-Version 2026-09-30 and simba-3.5.
The shielded Client.ts carried this mapping as a hand edit. The spec now
declares 413 on the three synthesis operations (SpeechifyInc/speechify-api,
same change set), and this file is what the generator emits from it.
@vitalragaz
vitalragaz marked this pull request as draft October 27, 2026 15:48
Regenerated from SpeechifyInc/speechify-api#4744's spec, which renames the
AsyncAPI server from production to websocket. The audio client parses each
SSE data: line again (no eventDiscriminator): the protocol annotation that
added it is gone from the spec because it broke the Python SDK's stream types.
tests/custom.test.ts pins the environment shape and reads a stream framed as
the API writes it, final speech.done included.
@vitalragaz
vitalragaz marked this pull request as ready for review October 27, 2026 16:11
@vitalragaz vitalragaz mentioned this pull request Oct 27, 2026
@vitalragaz
vitalragaz merged commit dac5216 into main Oct 29, 2026
7 checks passed
vitalragaz pushed a commit that referenced this pull request Oct 29, 2026
🤖 I have created a release *beep* *boop*
---


##
[5.0.0](4.0.1...5.0.0)
(2026-10-29)


### ⚠ BREAKING CHANGES

* the default API version moves to 2026-09-30, the model unions narrow,
and `environment` takes an object.
    - Requests now send `Speechify-Version: 2026-09-30` instead of
    2026-09-13. On that version `simba-english` and `simba-multilingual`
return 400 `model_retired`, and `output_format: pcm_16000` returns real
    16 kHz audio instead of 24 kHz bytes labelled 16 kHz.
    - To keep the 4.x wire behaviour, pin the version: `new
    SpeechifyClient({ version: "2026-09-13" })`
    - `GetSpeechRequest.Model` and `GetStreamRequest.Model` drop
`simba-english` and `simba-multilingual` and add `simba-3.5`, so code
    that names a Simba 1.6 id stops compiling.
    - `environment` no longer accepts a URL string.
    `SpeechifyEnvironment.Default` is now `{ base:
"https://api.speechify.ai", websocket: "wss://api.speechify.ai" }`. For
    a custom REST URL, pass `baseUrl: "https://..."`.

### Features

* regenerate SDK for API 2026-09-30 with simba-3.5
([#27](#27))
([dac5216](dac5216))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant