6989a98d75
- Arkitektur: docs/auth/passwordless-architecture.md - Backend: iom/quixzoom-auth-service/ (FastAPI + Redis) - Webb: quixzoom-market-pages/se/login/ (QR-kod + polling) - App: iom/quixzoom-app/src/features/auth/ (push + deep links) Flöde: QR-kod → app-godkännande → webb-inloggad
35 lines
1.0 KiB
JavaScript
35 lines
1.0 KiB
JavaScript
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
import { APIResource } from "../../core/resource.mjs";
|
|
import { buildHeaders } from "../../internal/headers.mjs";
|
|
/**
|
|
* Turn audio into text or text into audio.
|
|
*/
|
|
export class Speech extends APIResource {
|
|
/**
|
|
* Generates audio from the input text.
|
|
*
|
|
* Returns the audio file content, or a stream of audio events.
|
|
*
|
|
* @example
|
|
* ```ts
|
|
* const speech = await client.audio.speech.create({
|
|
* input: 'input',
|
|
* model: 'tts-1',
|
|
* voice: 'alloy',
|
|
* });
|
|
*
|
|
* const content = await speech.blob();
|
|
* console.log(content);
|
|
* ```
|
|
*/
|
|
create(body, options) {
|
|
return this._client.post('/audio/speech', {
|
|
body,
|
|
...options,
|
|
headers: buildHeaders([{ Accept: 'application/octet-stream' }, options?.headers]),
|
|
__security: { bearerAuth: true },
|
|
__binaryResponse: true,
|
|
});
|
|
}
|
|
}
|
|
//# sourceMappingURL=speech.mjs.map
|