@vocalstack/payload 0.11.1 → 0.11.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/api.d.ts +1 -1
- package/dist/endpoints/stream.js +2 -2
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/package.json +1 -1
package/dist/api.d.ts
CHANGED
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
*/
|
|
7
7
|
import { VocalStack } from '@vocalstack/js-sdk';
|
|
8
8
|
/** Lets VocalStack record transcriptions made here as origin `payload`. */
|
|
9
|
-
export declare const USER_AGENT = "VocalStack-Payload/0.11.
|
|
9
|
+
export declare const USER_AGENT = "VocalStack-Payload/0.11.2";
|
|
10
10
|
export declare const DEFAULT_API_URL = "https://api.vocalstack.com";
|
|
11
11
|
export declare const DEFAULT_DASHBOARD_URL = "https://app.vocalstack.com";
|
|
12
12
|
export type JobState = 'cropping' | 'done' | 'failed' | 'fetching' | 'queued' | 'stopped' | 'transcribing';
|
package/dist/endpoints/stream.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { DEFAULT_API_URL, VocalStackAPI } from '../api.js';
|
|
1
|
+
import { DEFAULT_API_URL, USER_AGENT, VocalStackAPI } from '../api.js';
|
|
2
2
|
import { resolveAPIKey } from '../settings.js';
|
|
3
3
|
import { attachWords } from '../text.js';
|
|
4
4
|
import { apiError, checkJob, locate, refileWith, toSentences } from './transcribe.js';
|
|
@@ -87,7 +87,7 @@ export function streamEndpoint(collection, options, rowFields) {
|
|
|
87
87
|
heartbeat = setInterval(() => !closed && controller.enqueue(encoder.encode(': ping\n\n')), 15000);
|
|
88
88
|
const wsURL = `${apiURL.replace(/^http/, 'ws')}/v1/transcriptions/${encodeURIComponent(transcriptionId)}/subscribe`;
|
|
89
89
|
// Node's WebSocket (undici) takes headers, which the DOM type does not know about.
|
|
90
|
-
socket = new WebSocket(wsURL, { headers: { authorization: `Bearer ${apiKey}
|
|
90
|
+
socket = new WebSocket(wsURL, { headers: { authorization: `Bearer ${apiKey}`, 'user-agent': USER_AGENT } });
|
|
91
91
|
socket.onmessage = (message) => {
|
|
92
92
|
let frame;
|
|
93
93
|
try {
|
package/dist/version.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
export declare const PACKAGE_NAME = "@vocalstack/payload";
|
|
2
|
-
export declare const VERSION = "0.11.
|
|
2
|
+
export declare const VERSION = "0.11.2";
|
package/dist/version.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vocalstack/payload",
|
|
3
|
-
"version": "0.11.
|
|
3
|
+
"version": "0.11.2",
|
|
4
4
|
"description": "VocalStack for Payload CMS: transcribe audio, translate it into other languages and read it aloud, kept in your own database and storage.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|