/*
 * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
 */
import * as z from "zod/v3";
import { safeParse } from "../../lib/schemas.js";
export const ConversationsOrderByField = {
    Id: "id",
    UserMessageCount: "userMessageCount",
    OrganizationId: "organizationId",
    ProjectId: "projectId",
    IntegrationId: "integrationId",
    FirstMessageTime: "firstMessageTime",
    Type: "type",
    Properties: "properties",
    UserProperties: "userProperties",
    IdHour: "id_hour",
    IdDay: "id_day",
    IdWeek: "id_week",
    IdMonth: "id_month",
    UserMessageCountHour: "userMessageCount_hour",
    UserMessageCountDay: "userMessageCount_day",
    UserMessageCountWeek: "userMessageCount_week",
    UserMessageCountMonth: "userMessageCount_month",
    OrganizationIdHour: "organizationId_hour",
    OrganizationIdDay: "organizationId_day",
    OrganizationIdWeek: "organizationId_week",
    OrganizationIdMonth: "organizationId_month",
    ProjectIdHour: "projectId_hour",
    ProjectIdDay: "projectId_day",
    ProjectIdWeek: "projectId_week",
    ProjectIdMonth: "projectId_month",
    IntegrationIdHour: "integrationId_hour",
    IntegrationIdDay: "integrationId_day",
    IntegrationIdWeek: "integrationId_week",
    IntegrationIdMonth: "integrationId_month",
    FirstMessageTimeHour: "firstMessageTime_hour",
    FirstMessageTimeDay: "firstMessageTime_day",
    FirstMessageTimeWeek: "firstMessageTime_week",
    FirstMessageTimeMonth: "firstMessageTime_month",
    TypeHour: "type_hour",
    TypeDay: "type_day",
    TypeWeek: "type_week",
    TypeMonth: "type_month",
    PropertiesHour: "properties_hour",
    PropertiesDay: "properties_day",
    PropertiesWeek: "properties_week",
    PropertiesMonth: "properties_month",
    UserPropertiesHour: "userProperties_hour",
    UserPropertiesDay: "userProperties_day",
    UserPropertiesWeek: "userProperties_week",
    UserPropertiesMonth: "userProperties_month",
    SumId: "sum_id",
    SumUserMessageCount: "sum_userMessageCount",
    SumOrganizationId: "sum_organizationId",
    SumProjectId: "sum_projectId",
    SumIntegrationId: "sum_integrationId",
    SumFirstMessageTime: "sum_firstMessageTime",
    SumType: "sum_type",
    SumProperties: "sum_properties",
    SumUserProperties: "sum_userProperties",
    CountId: "count_id",
    CountUserMessageCount: "count_userMessageCount",
    CountOrganizationId: "count_organizationId",
    CountProjectId: "count_projectId",
    CountIntegrationId: "count_integrationId",
    CountFirstMessageTime: "count_firstMessageTime",
    CountType: "count_type",
    CountProperties: "count_properties",
    CountUserProperties: "count_userProperties",
    AvgId: "avg_id",
    AvgUserMessageCount: "avg_userMessageCount",
    AvgOrganizationId: "avg_organizationId",
    AvgProjectId: "avg_projectId",
    AvgIntegrationId: "avg_integrationId",
    AvgFirstMessageTime: "avg_firstMessageTime",
    AvgType: "avg_type",
    AvgProperties: "avg_properties",
    AvgUserProperties: "avg_userProperties",
    MinId: "min_id",
    MinUserMessageCount: "min_userMessageCount",
    MinOrganizationId: "min_organizationId",
    MinProjectId: "min_projectId",
    MinIntegrationId: "min_integrationId",
    MinFirstMessageTime: "min_firstMessageTime",
    MinType: "min_type",
    MinProperties: "min_properties",
    MinUserProperties: "min_userProperties",
    MaxId: "max_id",
    MaxUserMessageCount: "max_userMessageCount",
    MaxOrganizationId: "max_organizationId",
    MaxProjectId: "max_projectId",
    MaxIntegrationId: "max_integrationId",
    MaxFirstMessageTime: "max_firstMessageTime",
    MaxType: "max_type",
    MaxProperties: "max_properties",
    MaxUserProperties: "max_userProperties",
};
export const Direction = {
    Asc: "asc",
    Desc: "desc",
};
/** @internal */
export const ConversationsOrderByField$inboundSchema = z.nativeEnum(ConversationsOrderByField);
/** @internal */
export const ConversationsOrderByField$outboundSchema = ConversationsOrderByField$inboundSchema;
/** @internal */
export const Direction$inboundSchema = z
    .nativeEnum(Direction);
/** @internal */
export const Direction$outboundSchema = Direction$inboundSchema;
/** @internal */
export const ConversationsOrderBy$inboundSchema = z.object({
    field: ConversationsOrderByField$inboundSchema,
    direction: Direction$inboundSchema,
});
/** @internal */
export const ConversationsOrderBy$outboundSchema = z.object({
    field: ConversationsOrderByField$outboundSchema,
    direction: Direction$outboundSchema,
});
export function conversationsOrderByToJSON(conversationsOrderBy) {
    return JSON.stringify(ConversationsOrderBy$outboundSchema.parse(conversationsOrderBy));
}
export function conversationsOrderByFromJSON(jsonString) {
    return safeParse(jsonString, (x) => ConversationsOrderBy$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'ConversationsOrderBy' from JSON`);
}
//# sourceMappingURL=conversationsorderby.js.map