MCPcopy Index your code
hub / github.com/anomalyco/opencode / generateState

Function generateState

packages/opencode/src/plugin/digitalocean.ts:40–45  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

38let pendingOAuth: PendingOAuth | undefined
39
40function generateState(): string {
41 const bytes = crypto.getRandomValues(new Uint8Array(32))
42 return Array.from(bytes)
43 .map((b) => b.toString(16).padStart(2, "0"))
44 .join("")
45}
46
47function redirectUri(): string {
48 return `http://localhost:${OAUTH_PORT}${OAUTH_REDIRECT_PATH}`

Callers 1

authorizeFunction · 0.70

Calls 1

fromMethod · 0.45

Tested by

no test coverage detected