Skip to content
Sarj Workspace Sync

execution/reviewed-posthog-membership

@sarj-ai/workspace-sync/execution/reviewed-posthog-membership ยท Source

import { z } from "zod";
export declare const ReviewedPosthogMembershipSchema: z.ZodObject<{
action: z.ZodDiscriminatedUnion<[z.ZodObject<{
googleUserId: z.core.$ZodBranded<z.ZodString, "GoogleUserId", "out">;
email: z.ZodPipe<z.ZodEmail, z.ZodTransform<string, string>>;
type: z.ZodLiteral<"invite">;
}, z.core.$strict>, z.ZodObject<{
googleUserId: z.core.$ZodBranded<z.ZodString, "GoogleUserId", "out">;
email: z.ZodPipe<z.ZodEmail, z.ZodTransform<string, string>>;
type: z.ZodLiteral<"cancel-invite">;
inviteId: z.ZodString;
}, z.core.$strict>, z.ZodObject<{
googleUserId: z.core.$ZodBranded<z.ZodString, "GoogleUserId", "out">;
email: z.ZodPipe<z.ZodEmail, z.ZodTransform<string, string>>;
type: z.ZodLiteral<"remove-member">;
userUuid: z.ZodString;
}, z.core.$strict>, z.ZodObject<{
googleUserId: z.core.$ZodBranded<z.ZodString, "GoogleUserId", "out">;
email: z.ZodPipe<z.ZodEmail, z.ZodTransform<string, string>>;
type: z.ZodLiteral<"retire-grant">;
}, z.core.$strict>, z.ZodObject<{
googleUserId: z.core.$ZodBranded<z.ZodString, "GoogleUserId", "out">;
email: z.ZodPipe<z.ZodEmail, z.ZodTransform<string, string>>;
type: z.ZodLiteral<"bind-member">;
userUuid: z.ZodString;
}, z.core.$strict>], "type">;
expectedPlanHash: z.ZodString;
sourceAuthorityFingerprint: z.ZodString;
organizationId: z.ZodString;
}, z.core.$strict>;
export type ReviewedPosthogMembership = z.output<typeof ReviewedPosthogMembershipSchema>;
export declare function posthogMembershipSourceIdentity(raw: ReviewedPosthogMembership): {
kind: "identity";
systemId: "posthog";
googleUserId: string & z.$brand<"GoogleUserId">;
providerAccountId: string;
};
export declare function posthogMembershipResourceId(raw: ReviewedPosthogMembership): string;
export declare function posthogMembershipManagedSlice(raw: ReviewedPosthogMembership, state: "converged" | "pending"): z.JSONType;