MCPcopy Index your code
hub / github.com/simstudioai/sim / useUnsubscribe

Function useUnsubscribe

apps/sim/hooks/queries/unsubscribe.ts:30–38  ·  view source on GitHub ↗
(email?: string, token?: string)

Source from the content-addressed store, hash-verified

28 * Auto-runs on mount once both `email` and `token` are present.
29 */
30export function useUnsubscribe(email?: string, token?: string) {
31 return useQuery({
32 queryKey: unsubscribeKeys.detail(email, token),
33 queryFn: ({ signal }) => fetchUnsubscribe(email as string, token as string, signal),
34 enabled: Boolean(email) && Boolean(token),
35 staleTime: 5 * 60 * 1000,
36 retry: false,
37 })
38}
39
40interface UnsubscribeVariables {
41 email: string

Callers 2

UnsubscribeContentFunction · 0.90

Calls 1

fetchUnsubscribeFunction · 0.85

Tested by

no test coverage detected