UNPKG

@it_kyryl/arbitrage_admin_schema

Version:

Schema for arbitrage admin panel

134 lines 4.64 kB
import { z } from "zod"; export declare const binomV2UserApiRole: z.ZodEnum<["user", "admin"]>; export declare const binomV2UserApiPermissionSubject: z.ZodEnum<["CAMPAIGN", "CAMPAIGN_GROUP", "OFFER", "OFFER_GROUP", "ROTATION", "ROTATION_GROUP", "TRAFFIC_SOURCE", "LANDING", "LANDING_GROUP", "DOMAIN", "DEFAULT_COLUMN", "CUSTOM_COLUMN", "AFFILIATE_NETWORK"]>; export declare const binomV2UserApiResponseSchema: z.ZodObject<{ id: z.ZodNumber; login: z.ZodString; role: z.ZodEnum<["user", "admin"]>; }, "strip", z.ZodTypeAny, { id: number; login: string; role: "user" | "admin"; }, { id: number; login: string; role: "user" | "admin"; }>; export type BinomV2UserApiResponseSchemaT = z.infer<typeof binomV2UserApiResponseSchema>; export declare const userPermissionGroup: z.ZodObject<{ id: z.ZodString; name: z.ZodString; }, "strip", z.ZodTypeAny, { id: string; name: string; }, { id: string; name: string; }>; export declare const binomV2UserApiIdentityResponseSchema: z.ZodObject<{ identity: z.ZodObject<{ userId: z.ZodString; login: z.ZodString; createdAt: z.ZodString; }, "strip", z.ZodTypeAny, { createdAt: string; login: string; userId: string; }, { createdAt: string; login: string; userId: string; }>; role: z.ZodEnum<["user", "admin"]>; permissions: z.ZodArray<z.ZodObject<{ canCreate: z.ZodBoolean; accessLevel: z.ZodString; subject: z.ZodEnum<["CAMPAIGN", "CAMPAIGN_GROUP", "OFFER", "OFFER_GROUP", "ROTATION", "ROTATION_GROUP", "TRAFFIC_SOURCE", "LANDING", "LANDING_GROUP", "DOMAIN", "DEFAULT_COLUMN", "CUSTOM_COLUMN", "AFFILIATE_NETWORK"]>; modifyGroups: z.ZodArray<z.ZodObject<{ id: z.ZodString; name: z.ZodString; }, "strip", z.ZodTypeAny, { id: string; name: string; }, { id: string; name: string; }>, "many">; readGroups: z.ZodArray<z.ZodObject<{ id: z.ZodString; name: z.ZodString; }, "strip", z.ZodTypeAny, { id: string; name: string; }, { id: string; name: string; }>, "many">; }, "strip", z.ZodTypeAny, { accessLevel: string; subject: "CAMPAIGN" | "CAMPAIGN_GROUP" | "OFFER" | "OFFER_GROUP" | "ROTATION" | "ROTATION_GROUP" | "TRAFFIC_SOURCE" | "LANDING" | "LANDING_GROUP" | "DOMAIN" | "DEFAULT_COLUMN" | "CUSTOM_COLUMN" | "AFFILIATE_NETWORK"; canCreate: boolean; modifyGroups: { id: string; name: string; }[]; readGroups: { id: string; name: string; }[]; }, { accessLevel: string; subject: "CAMPAIGN" | "CAMPAIGN_GROUP" | "OFFER" | "OFFER_GROUP" | "ROTATION" | "ROTATION_GROUP" | "TRAFFIC_SOURCE" | "LANDING" | "LANDING_GROUP" | "DOMAIN" | "DEFAULT_COLUMN" | "CUSTOM_COLUMN" | "AFFILIATE_NETWORK"; canCreate: boolean; modifyGroups: { id: string; name: string; }[]; readGroups: { id: string; name: string; }[]; }>, "many">; }, "strip", z.ZodTypeAny, { role: "user" | "admin"; identity: { createdAt: string; login: string; userId: string; }; permissions: { accessLevel: string; subject: "CAMPAIGN" | "CAMPAIGN_GROUP" | "OFFER" | "OFFER_GROUP" | "ROTATION" | "ROTATION_GROUP" | "TRAFFIC_SOURCE" | "LANDING" | "LANDING_GROUP" | "DOMAIN" | "DEFAULT_COLUMN" | "CUSTOM_COLUMN" | "AFFILIATE_NETWORK"; canCreate: boolean; modifyGroups: { id: string; name: string; }[]; readGroups: { id: string; name: string; }[]; }[]; }, { role: "user" | "admin"; identity: { createdAt: string; login: string; userId: string; }; permissions: { accessLevel: string; subject: "CAMPAIGN" | "CAMPAIGN_GROUP" | "OFFER" | "OFFER_GROUP" | "ROTATION" | "ROTATION_GROUP" | "TRAFFIC_SOURCE" | "LANDING" | "LANDING_GROUP" | "DOMAIN" | "DEFAULT_COLUMN" | "CUSTOM_COLUMN" | "AFFILIATE_NETWORK"; canCreate: boolean; modifyGroups: { id: string; name: string; }[]; readGroups: { id: string; name: string; }[]; }[]; }>; export type BinomV2UserApiIdentityResponseSchemaT = z.infer<typeof binomV2UserApiIdentityResponseSchema>; //# sourceMappingURL=user.d.ts.map