MCPcopy Create free account
hub / github.com/simstudioai/sim / resolveOptions

Function resolveOptions

apps/sim/hooks/queries/oauth/oauth-credentials.ts:69–85  ·  view source on GitHub ↗
(
  enabledOrOptions?: boolean | UseOAuthCredentialsOptions
)

Source from the content-addressed store, hash-verified

67}
68
69function resolveOptions(
70 enabledOrOptions?: boolean | UseOAuthCredentialsOptions
71): Required<UseOAuthCredentialsOptions> {
72 if (typeof enabledOrOptions === 'boolean') {
73 return {
74 enabled: enabledOrOptions,
75 workspaceId: '',
76 workflowId: '',
77 }
78 }
79
80 return {
81 enabled: enabledOrOptions?.enabled ?? true,
82 workspaceId: enabledOrOptions?.workspaceId ?? '',
83 workflowId: enabledOrOptions?.workflowId ?? '',
84 }
85}
86
87export function useOAuthCredentials(
88 providerId?: string,

Callers 1

useOAuthCredentialsFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected