MCPcopy Index your code
hub / github.com/coder/coder / stopWorkspace

Function stopWorkspace

site/src/api/queries/workspaces.ts:348–360  ·  view source on GitHub ↗
(
	workspace: Workspace,
	queryClient: QueryClient,
)

Source from the content-addressed store, hash-verified

346};
347
348export const stopWorkspace = (
349 workspace: Workspace,
350 queryClient: QueryClient,
351) => {
352 return {
353 mutationFn: ({ logLevel }: { logLevel?: ProvisionerLogLevel }) => {
354 return API.stopWorkspace(workspace.id, logLevel);
355 },
356 onSuccess: async (build: WorkspaceBuild) => {
357 await updateWorkspaceBuild(build, queryClient);
358 },
359 };
360};
361
362export const startWorkspace = (
363 workspace: Workspace,

Callers 2

WorkspaceReadyPageFunction · 0.90
WorkspaceActionsCellFunction · 0.90

Calls 1

updateWorkspaceBuildFunction · 0.85

Tested by

no test coverage detected