MCPcopy Create free account
hub / github.com/UsefulSoftwareCo/executor / post

Function post

e2e/cloud/admin-mfa-api.test.ts:38–43  ·  view source on GitHub ↗
(action: string, cookie: string, code?: string)

Source from the content-addressed store, hash-verified

36 });
37 expect(billing.status).toBe(200);
38 const post = (action: string, cookie: string, code?: string) =>
39 fetch(new URL(`/api/auth/admin-mfa/${action}`, target.baseUrl), {
40 method: "POST",
41 headers: { ...headers, origin: new URL(target.baseUrl).origin, cookie },
42 body: JSON.stringify(code === undefined ? {} : { code }),
43 });
44 const noOrigin = await fetch(new URL("/api/auth/admin-mfa/start", target.baseUrl), {
45 method: "POST",
46 headers,

Callers 1

Calls 1

fetchFunction · 0.50

Tested by

no test coverage detected