(path: string, workflowId: string)
| 5 | const logger = createLogger('WorkspaceForkSocket') |
| 6 | |
| 7 | async function postToRealtime(path: string, workflowId: string): Promise<void> { |
| 8 | const response = await fetch(`${getSocketServerUrl()}${path}`, { |
| 9 | method: 'POST', |
| 10 | headers: { 'Content-Type': 'application/json', 'x-api-key': env.INTERNAL_API_SECRET }, |
| 11 | body: JSON.stringify({ workflowId }), |
| 12 | }) |
| 13 | if (!response.ok) { |
| 14 | throw new Error(`${path} responded ${response.status}`) |
| 15 | } |
| 16 | } |
| 17 | |
| 18 | /** |
| 19 | * Notify connected canvas clients that a fork promote/rollback force-replaced a |
no test coverage detected