
/**
 * Client
**/

import * as runtime from '@prisma/client/runtime/library.js';
import $Types = runtime.Types // general types
import $Public = runtime.Types.Public
import $Utils = runtime.Types.Utils
import $Extensions = runtime.Types.Extensions
import $Result = runtime.Types.Result

export type PrismaPromise<T> = $Public.PrismaPromise<T>


/**
 * Model User
 * 
 */
export type User = $Result.DefaultSelection<Prisma.$UserPayload>
/**
 * Model RefreshToken
 * 
 */
export type RefreshToken = $Result.DefaultSelection<Prisma.$RefreshTokenPayload>
/**
 * Model PasswordResetToken
 * 
 */
export type PasswordResetToken = $Result.DefaultSelection<Prisma.$PasswordResetTokenPayload>
/**
 * Model AuditLog
 * 
 */
export type AuditLog = $Result.DefaultSelection<Prisma.$AuditLogPayload>
/**
 * Model Trip
 * 
 */
export type Trip = $Result.DefaultSelection<Prisma.$TripPayload>
/**
 * Model Punch
 * 
 */
export type Punch = $Result.DefaultSelection<Prisma.$PunchPayload>
/**
 * Model GpsPoint
 * 
 */
export type GpsPoint = $Result.DefaultSelection<Prisma.$GpsPointPayload>
/**
 * Model GpsStop
 * 
 */
export type GpsStop = $Result.DefaultSelection<Prisma.$GpsStopPayload>
/**
 * Model Notification
 * 
 */
export type Notification = $Result.DefaultSelection<Prisma.$NotificationPayload>
/**
 * Model SystemConfig
 * 
 */
export type SystemConfig = $Result.DefaultSelection<Prisma.$SystemConfigPayload>
/**
 * Model DailySummary
 * 
 */
export type DailySummary = $Result.DefaultSelection<Prisma.$DailySummaryPayload>
/**
 * Model MonthlySummary
 * 
 */
export type MonthlySummary = $Result.DefaultSelection<Prisma.$MonthlySummaryPayload>

/**
 * Enums
 */
export namespace $Enums {
  export const UserRole: {
  SUPER_ADMIN: 'SUPER_ADMIN',
  ADMIN: 'ADMIN',
  HOD: 'HOD',
  REPORTING_MANAGER: 'REPORTING_MANAGER',
  EMPLOYEE: 'EMPLOYEE'
};

export type UserRole = (typeof UserRole)[keyof typeof UserRole]


export const UserStatus: {
  ACTIVE: 'ACTIVE',
  INACTIVE: 'INACTIVE'
};

export type UserStatus = (typeof UserStatus)[keyof typeof UserStatus]


export const TripStatus: {
  CREATED: 'CREATED',
  STARTED: 'STARTED',
  TRAVELLING: 'TRAVELLING',
  ARRIVED: 'ARRIVED',
  MEETING_STARTED: 'MEETING_STARTED',
  MEETING_COMPLETED: 'MEETING_COMPLETED',
  RETURN_TRIP: 'RETURN_TRIP',
  COMPLETED: 'COMPLETED',
  CANCELLED: 'CANCELLED'
};

export type TripStatus = (typeof TripStatus)[keyof typeof TripStatus]


export const PunchType: {
  DEPARTURE: 'DEPARTURE',
  ARRIVAL: 'ARRIVAL',
  MEETING_START: 'MEETING_START',
  MEETING_END: 'MEETING_END'
};

export type PunchType = (typeof PunchType)[keyof typeof PunchType]


export const VehicleType: {
  CAR: 'CAR',
  BIKE: 'BIKE',
  SCOOTER: 'SCOOTER',
  OTHER: 'OTHER'
};

export type VehicleType = (typeof VehicleType)[keyof typeof VehicleType]


export const FuelType: {
  PETROL: 'PETROL',
  DIESEL: 'DIESEL',
  CNG: 'CNG',
  ELECTRIC: 'ELECTRIC',
  OTHER: 'OTHER'
};

export type FuelType = (typeof FuelType)[keyof typeof FuelType]


export const LeadType: {
  HOT: 'HOT',
  WARM: 'WARM',
  COLD: 'COLD',
  EXISTING: 'EXISTING',
  OTHER: 'OTHER'
};

export type LeadType = (typeof LeadType)[keyof typeof LeadType]


export const NotificationType: {
  TRIP_STARTED: 'TRIP_STARTED',
  ARRIVAL_COMPLETED: 'ARRIVAL_COMPLETED',
  MEETING_STARTED: 'MEETING_STARTED',
  MEETING_ENDED: 'MEETING_ENDED',
  EMPLOYEE_OFFLINE: 'EMPLOYEE_OFFLINE',
  GPS_STOPPED: 'GPS_STOPPED'
};

export type NotificationType = (typeof NotificationType)[keyof typeof NotificationType]


export const EmployeePresence: {
  ONLINE: 'ONLINE',
  OFFLINE: 'OFFLINE',
  ON_TRIP: 'ON_TRIP',
  IN_MEETING: 'IN_MEETING',
  IDLE: 'IDLE'
};

export type EmployeePresence = (typeof EmployeePresence)[keyof typeof EmployeePresence]

}

export type UserRole = $Enums.UserRole

export const UserRole: typeof $Enums.UserRole

export type UserStatus = $Enums.UserStatus

export const UserStatus: typeof $Enums.UserStatus

export type TripStatus = $Enums.TripStatus

export const TripStatus: typeof $Enums.TripStatus

export type PunchType = $Enums.PunchType

export const PunchType: typeof $Enums.PunchType

export type VehicleType = $Enums.VehicleType

export const VehicleType: typeof $Enums.VehicleType

export type FuelType = $Enums.FuelType

export const FuelType: typeof $Enums.FuelType

export type LeadType = $Enums.LeadType

export const LeadType: typeof $Enums.LeadType

export type NotificationType = $Enums.NotificationType

export const NotificationType: typeof $Enums.NotificationType

export type EmployeePresence = $Enums.EmployeePresence

export const EmployeePresence: typeof $Enums.EmployeePresence

/**
 * ##  Prisma Client ʲˢ
 *
 * Type-safe database client for TypeScript & Node.js
 * @example
 * ```
 * const prisma = new PrismaClient()
 * // Fetch zero or more Users
 * const users = await prisma.user.findMany()
 * ```
 *
 *
 * Read more in our [docs](https://www.prisma.io/docs/reference/tools-and-interfaces/prisma-client).
 */
export class PrismaClient<
  ClientOptions extends Prisma.PrismaClientOptions = Prisma.PrismaClientOptions,
  const U = 'log' extends keyof ClientOptions ? ClientOptions['log'] extends Array<Prisma.LogLevel | Prisma.LogDefinition> ? Prisma.GetEvents<ClientOptions['log']> : never : never,
  ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs
> {
  [K: symbol]: { types: Prisma.TypeMap<ExtArgs>['other'] }

    /**
   * ##  Prisma Client ʲˢ
   *
   * Type-safe database client for TypeScript & Node.js
   * @example
   * ```
   * const prisma = new PrismaClient()
   * // Fetch zero or more Users
   * const users = await prisma.user.findMany()
   * ```
   *
   *
   * Read more in our [docs](https://www.prisma.io/docs/reference/tools-and-interfaces/prisma-client).
   */

  constructor(optionsArg ?: Prisma.Subset<ClientOptions, Prisma.PrismaClientOptions>);
  $on<V extends U>(eventType: V, callback: (event: V extends 'query' ? Prisma.QueryEvent : Prisma.LogEvent) => void): PrismaClient;

  /**
   * Connect with the database
   */
  $connect(): $Utils.JsPromise<void>;

  /**
   * Disconnect from the database
   */
  $disconnect(): $Utils.JsPromise<void>;

/**
   * Executes a prepared raw query and returns the number of affected rows.
   * @example
   * ```
   * const result = await prisma.$executeRaw`UPDATE User SET cool = ${true} WHERE email = ${'user@email.com'};`
   * ```
   *
   * Read more in our [docs](https://www.prisma.io/docs/reference/tools-and-interfaces/prisma-client/raw-database-access).
   */
  $executeRaw<T = unknown>(query: TemplateStringsArray | Prisma.Sql, ...values: any[]): Prisma.PrismaPromise<number>;

  /**
   * Executes a raw query and returns the number of affected rows.
   * Susceptible to SQL injections, see documentation.
   * @example
   * ```
   * const result = await prisma.$executeRawUnsafe('UPDATE User SET cool = $1 WHERE email = $2 ;', true, 'user@email.com')
   * ```
   *
   * Read more in our [docs](https://www.prisma.io/docs/reference/tools-and-interfaces/prisma-client/raw-database-access).
   */
  $executeRawUnsafe<T = unknown>(query: string, ...values: any[]): Prisma.PrismaPromise<number>;

  /**
   * Performs a prepared raw query and returns the `SELECT` data.
   * @example
   * ```
   * const result = await prisma.$queryRaw`SELECT * FROM User WHERE id = ${1} OR email = ${'user@email.com'};`
   * ```
   *
   * Read more in our [docs](https://www.prisma.io/docs/reference/tools-and-interfaces/prisma-client/raw-database-access).
   */
  $queryRaw<T = unknown>(query: TemplateStringsArray | Prisma.Sql, ...values: any[]): Prisma.PrismaPromise<T>;

  /**
   * Performs a raw query and returns the `SELECT` data.
   * Susceptible to SQL injections, see documentation.
   * @example
   * ```
   * const result = await prisma.$queryRawUnsafe('SELECT * FROM User WHERE id = $1 OR email = $2;', 1, 'user@email.com')
   * ```
   *
   * Read more in our [docs](https://www.prisma.io/docs/reference/tools-and-interfaces/prisma-client/raw-database-access).
   */
  $queryRawUnsafe<T = unknown>(query: string, ...values: any[]): Prisma.PrismaPromise<T>;


  /**
   * Allows the running of a sequence of read/write operations that are guaranteed to either succeed or fail as a whole.
   * @example
   * ```
   * const [george, bob, alice] = await prisma.$transaction([
   *   prisma.user.create({ data: { name: 'George' } }),
   *   prisma.user.create({ data: { name: 'Bob' } }),
   *   prisma.user.create({ data: { name: 'Alice' } }),
   * ])
   * ```
   * 
   * Read more in our [docs](https://www.prisma.io/docs/concepts/components/prisma-client/transactions).
   */
  $transaction<P extends Prisma.PrismaPromise<any>[]>(arg: [...P], options?: { isolationLevel?: Prisma.TransactionIsolationLevel }): $Utils.JsPromise<runtime.Types.Utils.UnwrapTuple<P>>

  $transaction<R>(fn: (prisma: Omit<PrismaClient, runtime.ITXClientDenyList>) => $Utils.JsPromise<R>, options?: { maxWait?: number, timeout?: number, isolationLevel?: Prisma.TransactionIsolationLevel }): $Utils.JsPromise<R>


  $extends: $Extensions.ExtendsHook<"extends", Prisma.TypeMapCb<ClientOptions>, ExtArgs, $Utils.Call<Prisma.TypeMapCb<ClientOptions>, {
    extArgs: ExtArgs
  }>>

      /**
   * `prisma.user`: Exposes CRUD operations for the **User** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more Users
    * const users = await prisma.user.findMany()
    * ```
    */
  get user(): Prisma.UserDelegate<ExtArgs, ClientOptions>;

  /**
   * `prisma.refreshToken`: Exposes CRUD operations for the **RefreshToken** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more RefreshTokens
    * const refreshTokens = await prisma.refreshToken.findMany()
    * ```
    */
  get refreshToken(): Prisma.RefreshTokenDelegate<ExtArgs, ClientOptions>;

  /**
   * `prisma.passwordResetToken`: Exposes CRUD operations for the **PasswordResetToken** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more PasswordResetTokens
    * const passwordResetTokens = await prisma.passwordResetToken.findMany()
    * ```
    */
  get passwordResetToken(): Prisma.PasswordResetTokenDelegate<ExtArgs, ClientOptions>;

  /**
   * `prisma.auditLog`: Exposes CRUD operations for the **AuditLog** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more AuditLogs
    * const auditLogs = await prisma.auditLog.findMany()
    * ```
    */
  get auditLog(): Prisma.AuditLogDelegate<ExtArgs, ClientOptions>;

  /**
   * `prisma.trip`: Exposes CRUD operations for the **Trip** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more Trips
    * const trips = await prisma.trip.findMany()
    * ```
    */
  get trip(): Prisma.TripDelegate<ExtArgs, ClientOptions>;

  /**
   * `prisma.punch`: Exposes CRUD operations for the **Punch** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more Punches
    * const punches = await prisma.punch.findMany()
    * ```
    */
  get punch(): Prisma.PunchDelegate<ExtArgs, ClientOptions>;

  /**
   * `prisma.gpsPoint`: Exposes CRUD operations for the **GpsPoint** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more GpsPoints
    * const gpsPoints = await prisma.gpsPoint.findMany()
    * ```
    */
  get gpsPoint(): Prisma.GpsPointDelegate<ExtArgs, ClientOptions>;

  /**
   * `prisma.gpsStop`: Exposes CRUD operations for the **GpsStop** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more GpsStops
    * const gpsStops = await prisma.gpsStop.findMany()
    * ```
    */
  get gpsStop(): Prisma.GpsStopDelegate<ExtArgs, ClientOptions>;

  /**
   * `prisma.notification`: Exposes CRUD operations for the **Notification** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more Notifications
    * const notifications = await prisma.notification.findMany()
    * ```
    */
  get notification(): Prisma.NotificationDelegate<ExtArgs, ClientOptions>;

  /**
   * `prisma.systemConfig`: Exposes CRUD operations for the **SystemConfig** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more SystemConfigs
    * const systemConfigs = await prisma.systemConfig.findMany()
    * ```
    */
  get systemConfig(): Prisma.SystemConfigDelegate<ExtArgs, ClientOptions>;

  /**
   * `prisma.dailySummary`: Exposes CRUD operations for the **DailySummary** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more DailySummaries
    * const dailySummaries = await prisma.dailySummary.findMany()
    * ```
    */
  get dailySummary(): Prisma.DailySummaryDelegate<ExtArgs, ClientOptions>;

  /**
   * `prisma.monthlySummary`: Exposes CRUD operations for the **MonthlySummary** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more MonthlySummaries
    * const monthlySummaries = await prisma.monthlySummary.findMany()
    * ```
    */
  get monthlySummary(): Prisma.MonthlySummaryDelegate<ExtArgs, ClientOptions>;
}

export namespace Prisma {
  export import DMMF = runtime.DMMF

  export type PrismaPromise<T> = $Public.PrismaPromise<T>

  /**
   * Validator
   */
  export import validator = runtime.Public.validator

  /**
   * Prisma Errors
   */
  export import PrismaClientKnownRequestError = runtime.PrismaClientKnownRequestError
  export import PrismaClientUnknownRequestError = runtime.PrismaClientUnknownRequestError
  export import PrismaClientRustPanicError = runtime.PrismaClientRustPanicError
  export import PrismaClientInitializationError = runtime.PrismaClientInitializationError
  export import PrismaClientValidationError = runtime.PrismaClientValidationError

  /**
   * Re-export of sql-template-tag
   */
  export import sql = runtime.sqltag
  export import empty = runtime.empty
  export import join = runtime.join
  export import raw = runtime.raw
  export import Sql = runtime.Sql



  /**
   * Decimal.js
   */
  export import Decimal = runtime.Decimal

  export type DecimalJsLike = runtime.DecimalJsLike

  /**
   * Metrics
   */
  export type Metrics = runtime.Metrics
  export type Metric<T> = runtime.Metric<T>
  export type MetricHistogram = runtime.MetricHistogram
  export type MetricHistogramBucket = runtime.MetricHistogramBucket

  /**
  * Extensions
  */
  export import Extension = $Extensions.UserArgs
  export import getExtensionContext = runtime.Extensions.getExtensionContext
  export import Args = $Public.Args
  export import Payload = $Public.Payload
  export import Result = $Public.Result
  export import Exact = $Public.Exact

  /**
   * Prisma Client JS version: 6.19.3
   * Query Engine version: c2990dca591cba766e3b7ef5d9e8a84796e47ab7
   */
  export type PrismaVersion = {
    client: string
  }

  export const prismaVersion: PrismaVersion

  /**
   * Utility Types
   */


  export import Bytes = runtime.Bytes
  export import JsonObject = runtime.JsonObject
  export import JsonArray = runtime.JsonArray
  export import JsonValue = runtime.JsonValue
  export import InputJsonObject = runtime.InputJsonObject
  export import InputJsonArray = runtime.InputJsonArray
  export import InputJsonValue = runtime.InputJsonValue

  /**
   * Types of the values used to represent different kinds of `null` values when working with JSON fields.
   *
   * @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field
   */
  namespace NullTypes {
    /**
    * Type of `Prisma.DbNull`.
    *
    * You cannot use other instances of this class. Please use the `Prisma.DbNull` value.
    *
    * @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field
    */
    class DbNull {
      private DbNull: never
      private constructor()
    }

    /**
    * Type of `Prisma.JsonNull`.
    *
    * You cannot use other instances of this class. Please use the `Prisma.JsonNull` value.
    *
    * @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field
    */
    class JsonNull {
      private JsonNull: never
      private constructor()
    }

    /**
    * Type of `Prisma.AnyNull`.
    *
    * You cannot use other instances of this class. Please use the `Prisma.AnyNull` value.
    *
    * @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field
    */
    class AnyNull {
      private AnyNull: never
      private constructor()
    }
  }

  /**
   * Helper for filtering JSON entries that have `null` on the database (empty on the db)
   *
   * @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field
   */
  export const DbNull: NullTypes.DbNull

  /**
   * Helper for filtering JSON entries that have JSON `null` values (not empty on the db)
   *
   * @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field
   */
  export const JsonNull: NullTypes.JsonNull

  /**
   * Helper for filtering JSON entries that are `Prisma.DbNull` or `Prisma.JsonNull`
   *
   * @see https://www.prisma.io/docs/concepts/components/prisma-client/working-with-fields/working-with-json-fields#filtering-on-a-json-field
   */
  export const AnyNull: NullTypes.AnyNull

  type SelectAndInclude = {
    select: any
    include: any
  }

  type SelectAndOmit = {
    select: any
    omit: any
  }

  /**
   * Get the type of the value, that the Promise holds.
   */
  export type PromiseType<T extends PromiseLike<any>> = T extends PromiseLike<infer U> ? U : T;

  /**
   * Get the return type of a function which returns a Promise.
   */
  export type PromiseReturnType<T extends (...args: any) => $Utils.JsPromise<any>> = PromiseType<ReturnType<T>>

  /**
   * From T, pick a set of properties whose keys are in the union K
   */
  type Prisma__Pick<T, K extends keyof T> = {
      [P in K]: T[P];
  };


  export type Enumerable<T> = T | Array<T>;

  export type RequiredKeys<T> = {
    [K in keyof T]-?: {} extends Prisma__Pick<T, K> ? never : K
  }[keyof T]

  export type TruthyKeys<T> = keyof {
    [K in keyof T as T[K] extends false | undefined | null ? never : K]: K
  }

  export type TrueKeys<T> = TruthyKeys<Prisma__Pick<T, RequiredKeys<T>>>

  /**
   * Subset
   * @desc From `T` pick properties that exist in `U`. Simple version of Intersection
   */
  export type Subset<T, U> = {
    [key in keyof T]: key extends keyof U ? T[key] : never;
  };

  /**
   * SelectSubset
   * @desc From `T` pick properties that exist in `U`. Simple version of Intersection.
   * Additionally, it validates, if both select and include are present. If the case, it errors.
   */
  export type SelectSubset<T, U> = {
    [key in keyof T]: key extends keyof U ? T[key] : never
  } &
    (T extends SelectAndInclude
      ? 'Please either choose `select` or `include`.'
      : T extends SelectAndOmit
        ? 'Please either choose `select` or `omit`.'
        : {})

  /**
   * Subset + Intersection
   * @desc From `T` pick properties that exist in `U` and intersect `K`
   */
  export type SubsetIntersection<T, U, K> = {
    [key in keyof T]: key extends keyof U ? T[key] : never
  } &
    K

  type Without<T, U> = { [P in Exclude<keyof T, keyof U>]?: never };

  /**
   * XOR is needed to have a real mutually exclusive union type
   * https://stackoverflow.com/questions/42123407/does-typescript-support-mutually-exclusive-types
   */
  type XOR<T, U> =
    T extends object ?
    U extends object ?
      (Without<T, U> & U) | (Without<U, T> & T)
    : U : T


  /**
   * Is T a Record?
   */
  type IsObject<T extends any> = T extends Array<any>
  ? False
  : T extends Date
  ? False
  : T extends Uint8Array
  ? False
  : T extends BigInt
  ? False
  : T extends object
  ? True
  : False


  /**
   * If it's T[], return T
   */
  export type UnEnumerate<T extends unknown> = T extends Array<infer U> ? U : T

  /**
   * From ts-toolbelt
   */

  type __Either<O extends object, K extends Key> = Omit<O, K> &
    {
      // Merge all but K
      [P in K]: Prisma__Pick<O, P & keyof O> // With K possibilities
    }[K]

  type EitherStrict<O extends object, K extends Key> = Strict<__Either<O, K>>

  type EitherLoose<O extends object, K extends Key> = ComputeRaw<__Either<O, K>>

  type _Either<
    O extends object,
    K extends Key,
    strict extends Boolean
  > = {
    1: EitherStrict<O, K>
    0: EitherLoose<O, K>
  }[strict]

  type Either<
    O extends object,
    K extends Key,
    strict extends Boolean = 1
  > = O extends unknown ? _Either<O, K, strict> : never

  export type Union = any

  type PatchUndefined<O extends object, O1 extends object> = {
    [K in keyof O]: O[K] extends undefined ? At<O1, K> : O[K]
  } & {}

  /** Helper Types for "Merge" **/
  export type IntersectOf<U extends Union> = (
    U extends unknown ? (k: U) => void : never
  ) extends (k: infer I) => void
    ? I
    : never

  export type Overwrite<O extends object, O1 extends object> = {
      [K in keyof O]: K extends keyof O1 ? O1[K] : O[K];
  } & {};

  type _Merge<U extends object> = IntersectOf<Overwrite<U, {
      [K in keyof U]-?: At<U, K>;
  }>>;

  type Key = string | number | symbol;
  type AtBasic<O extends object, K extends Key> = K extends keyof O ? O[K] : never;
  type AtStrict<O extends object, K extends Key> = O[K & keyof O];
  type AtLoose<O extends object, K extends Key> = O extends unknown ? AtStrict<O, K> : never;
  export type At<O extends object, K extends Key, strict extends Boolean = 1> = {
      1: AtStrict<O, K>;
      0: AtLoose<O, K>;
  }[strict];

  export type ComputeRaw<A extends any> = A extends Function ? A : {
    [K in keyof A]: A[K];
  } & {};

  export type OptionalFlat<O> = {
    [K in keyof O]?: O[K];
  } & {};

  type _Record<K extends keyof any, T> = {
    [P in K]: T;
  };

  // cause typescript not to expand types and preserve names
  type NoExpand<T> = T extends unknown ? T : never;

  // this type assumes the passed object is entirely optional
  type AtLeast<O extends object, K extends string> = NoExpand<
    O extends unknown
    ? | (K extends keyof O ? { [P in K]: O[P] } & O : O)
      | {[P in keyof O as P extends K ? P : never]-?: O[P]} & O
    : never>;

  type _Strict<U, _U = U> = U extends unknown ? U & OptionalFlat<_Record<Exclude<Keys<_U>, keyof U>, never>> : never;

  export type Strict<U extends object> = ComputeRaw<_Strict<U>>;
  /** End Helper Types for "Merge" **/

  export type Merge<U extends object> = ComputeRaw<_Merge<Strict<U>>>;

  /**
  A [[Boolean]]
  */
  export type Boolean = True | False

  // /**
  // 1
  // */
  export type True = 1

  /**
  0
  */
  export type False = 0

  export type Not<B extends Boolean> = {
    0: 1
    1: 0
  }[B]

  export type Extends<A1 extends any, A2 extends any> = [A1] extends [never]
    ? 0 // anything `never` is false
    : A1 extends A2
    ? 1
    : 0

  export type Has<U extends Union, U1 extends Union> = Not<
    Extends<Exclude<U1, U>, U1>
  >

  export type Or<B1 extends Boolean, B2 extends Boolean> = {
    0: {
      0: 0
      1: 1
    }
    1: {
      0: 1
      1: 1
    }
  }[B1][B2]

  export type Keys<U extends Union> = U extends unknown ? keyof U : never

  type Cast<A, B> = A extends B ? A : B;

  export const type: unique symbol;



  /**
   * Used by group by
   */

  export type GetScalarType<T, O> = O extends object ? {
    [P in keyof T]: P extends keyof O
      ? O[P]
      : never
  } : never

  type FieldPaths<
    T,
    U = Omit<T, '_avg' | '_sum' | '_count' | '_min' | '_max'>
  > = IsObject<T> extends True ? U : T

  type GetHavingFields<T> = {
    [K in keyof T]: Or<
      Or<Extends<'OR', K>, Extends<'AND', K>>,
      Extends<'NOT', K>
    > extends True
      ? // infer is only needed to not hit TS limit
        // based on the brilliant idea of Pierre-Antoine Mills
        // https://github.com/microsoft/TypeScript/issues/30188#issuecomment-478938437
        T[K] extends infer TK
        ? GetHavingFields<UnEnumerate<TK> extends object ? Merge<UnEnumerate<TK>> : never>
        : never
      : {} extends FieldPaths<T[K]>
      ? never
      : K
  }[keyof T]

  /**
   * Convert tuple to union
   */
  type _TupleToUnion<T> = T extends (infer E)[] ? E : never
  type TupleToUnion<K extends readonly any[]> = _TupleToUnion<K>
  type MaybeTupleToUnion<T> = T extends any[] ? TupleToUnion<T> : T

  /**
   * Like `Pick`, but additionally can also accept an array of keys
   */
  type PickEnumerable<T, K extends Enumerable<keyof T> | keyof T> = Prisma__Pick<T, MaybeTupleToUnion<K>>

  /**
   * Exclude all keys with underscores
   */
  type ExcludeUnderscoreKeys<T extends string> = T extends `_${string}` ? never : T


  export type FieldRef<Model, FieldType> = runtime.FieldRef<Model, FieldType>

  type FieldRefInputType<Model, FieldType> = Model extends never ? never : FieldRef<Model, FieldType>


  export const ModelName: {
    User: 'User',
    RefreshToken: 'RefreshToken',
    PasswordResetToken: 'PasswordResetToken',
    AuditLog: 'AuditLog',
    Trip: 'Trip',
    Punch: 'Punch',
    GpsPoint: 'GpsPoint',
    GpsStop: 'GpsStop',
    Notification: 'Notification',
    SystemConfig: 'SystemConfig',
    DailySummary: 'DailySummary',
    MonthlySummary: 'MonthlySummary'
  };

  export type ModelName = (typeof ModelName)[keyof typeof ModelName]


  export type Datasources = {
    db?: Datasource
  }

  interface TypeMapCb<ClientOptions = {}> extends $Utils.Fn<{extArgs: $Extensions.InternalArgs }, $Utils.Record<string, any>> {
    returns: Prisma.TypeMap<this['params']['extArgs'], ClientOptions extends { omit: infer OmitOptions } ? OmitOptions : {}>
  }

  export type TypeMap<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs, GlobalOmitOptions = {}> = {
    globalOmitOptions: {
      omit: GlobalOmitOptions
    }
    meta: {
      modelProps: "user" | "refreshToken" | "passwordResetToken" | "auditLog" | "trip" | "punch" | "gpsPoint" | "gpsStop" | "notification" | "systemConfig" | "dailySummary" | "monthlySummary"
      txIsolationLevel: Prisma.TransactionIsolationLevel
    }
    model: {
      User: {
        payload: Prisma.$UserPayload<ExtArgs>
        fields: Prisma.UserFieldRefs
        operations: {
          findUnique: {
            args: Prisma.UserFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$UserPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.UserFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$UserPayload>
          }
          findFirst: {
            args: Prisma.UserFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$UserPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.UserFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$UserPayload>
          }
          findMany: {
            args: Prisma.UserFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$UserPayload>[]
          }
          create: {
            args: Prisma.UserCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$UserPayload>
          }
          createMany: {
            args: Prisma.UserCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          createManyAndReturn: {
            args: Prisma.UserCreateManyAndReturnArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$UserPayload>[]
          }
          delete: {
            args: Prisma.UserDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$UserPayload>
          }
          update: {
            args: Prisma.UserUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$UserPayload>
          }
          deleteMany: {
            args: Prisma.UserDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.UserUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateManyAndReturn: {
            args: Prisma.UserUpdateManyAndReturnArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$UserPayload>[]
          }
          upsert: {
            args: Prisma.UserUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$UserPayload>
          }
          aggregate: {
            args: Prisma.UserAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateUser>
          }
          groupBy: {
            args: Prisma.UserGroupByArgs<ExtArgs>
            result: $Utils.Optional<UserGroupByOutputType>[]
          }
          count: {
            args: Prisma.UserCountArgs<ExtArgs>
            result: $Utils.Optional<UserCountAggregateOutputType> | number
          }
        }
      }
      RefreshToken: {
        payload: Prisma.$RefreshTokenPayload<ExtArgs>
        fields: Prisma.RefreshTokenFieldRefs
        operations: {
          findUnique: {
            args: Prisma.RefreshTokenFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$RefreshTokenPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.RefreshTokenFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$RefreshTokenPayload>
          }
          findFirst: {
            args: Prisma.RefreshTokenFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$RefreshTokenPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.RefreshTokenFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$RefreshTokenPayload>
          }
          findMany: {
            args: Prisma.RefreshTokenFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$RefreshTokenPayload>[]
          }
          create: {
            args: Prisma.RefreshTokenCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$RefreshTokenPayload>
          }
          createMany: {
            args: Prisma.RefreshTokenCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          createManyAndReturn: {
            args: Prisma.RefreshTokenCreateManyAndReturnArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$RefreshTokenPayload>[]
          }
          delete: {
            args: Prisma.RefreshTokenDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$RefreshTokenPayload>
          }
          update: {
            args: Prisma.RefreshTokenUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$RefreshTokenPayload>
          }
          deleteMany: {
            args: Prisma.RefreshTokenDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.RefreshTokenUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateManyAndReturn: {
            args: Prisma.RefreshTokenUpdateManyAndReturnArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$RefreshTokenPayload>[]
          }
          upsert: {
            args: Prisma.RefreshTokenUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$RefreshTokenPayload>
          }
          aggregate: {
            args: Prisma.RefreshTokenAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateRefreshToken>
          }
          groupBy: {
            args: Prisma.RefreshTokenGroupByArgs<ExtArgs>
            result: $Utils.Optional<RefreshTokenGroupByOutputType>[]
          }
          count: {
            args: Prisma.RefreshTokenCountArgs<ExtArgs>
            result: $Utils.Optional<RefreshTokenCountAggregateOutputType> | number
          }
        }
      }
      PasswordResetToken: {
        payload: Prisma.$PasswordResetTokenPayload<ExtArgs>
        fields: Prisma.PasswordResetTokenFieldRefs
        operations: {
          findUnique: {
            args: Prisma.PasswordResetTokenFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$PasswordResetTokenPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.PasswordResetTokenFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$PasswordResetTokenPayload>
          }
          findFirst: {
            args: Prisma.PasswordResetTokenFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$PasswordResetTokenPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.PasswordResetTokenFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$PasswordResetTokenPayload>
          }
          findMany: {
            args: Prisma.PasswordResetTokenFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$PasswordResetTokenPayload>[]
          }
          create: {
            args: Prisma.PasswordResetTokenCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$PasswordResetTokenPayload>
          }
          createMany: {
            args: Prisma.PasswordResetTokenCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          createManyAndReturn: {
            args: Prisma.PasswordResetTokenCreateManyAndReturnArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$PasswordResetTokenPayload>[]
          }
          delete: {
            args: Prisma.PasswordResetTokenDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$PasswordResetTokenPayload>
          }
          update: {
            args: Prisma.PasswordResetTokenUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$PasswordResetTokenPayload>
          }
          deleteMany: {
            args: Prisma.PasswordResetTokenDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.PasswordResetTokenUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateManyAndReturn: {
            args: Prisma.PasswordResetTokenUpdateManyAndReturnArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$PasswordResetTokenPayload>[]
          }
          upsert: {
            args: Prisma.PasswordResetTokenUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$PasswordResetTokenPayload>
          }
          aggregate: {
            args: Prisma.PasswordResetTokenAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregatePasswordResetToken>
          }
          groupBy: {
            args: Prisma.PasswordResetTokenGroupByArgs<ExtArgs>
            result: $Utils.Optional<PasswordResetTokenGroupByOutputType>[]
          }
          count: {
            args: Prisma.PasswordResetTokenCountArgs<ExtArgs>
            result: $Utils.Optional<PasswordResetTokenCountAggregateOutputType> | number
          }
        }
      }
      AuditLog: {
        payload: Prisma.$AuditLogPayload<ExtArgs>
        fields: Prisma.AuditLogFieldRefs
        operations: {
          findUnique: {
            args: Prisma.AuditLogFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$AuditLogPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.AuditLogFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$AuditLogPayload>
          }
          findFirst: {
            args: Prisma.AuditLogFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$AuditLogPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.AuditLogFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$AuditLogPayload>
          }
          findMany: {
            args: Prisma.AuditLogFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$AuditLogPayload>[]
          }
          create: {
            args: Prisma.AuditLogCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$AuditLogPayload>
          }
          createMany: {
            args: Prisma.AuditLogCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          createManyAndReturn: {
            args: Prisma.AuditLogCreateManyAndReturnArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$AuditLogPayload>[]
          }
          delete: {
            args: Prisma.AuditLogDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$AuditLogPayload>
          }
          update: {
            args: Prisma.AuditLogUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$AuditLogPayload>
          }
          deleteMany: {
            args: Prisma.AuditLogDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.AuditLogUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateManyAndReturn: {
            args: Prisma.AuditLogUpdateManyAndReturnArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$AuditLogPayload>[]
          }
          upsert: {
            args: Prisma.AuditLogUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$AuditLogPayload>
          }
          aggregate: {
            args: Prisma.AuditLogAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateAuditLog>
          }
          groupBy: {
            args: Prisma.AuditLogGroupByArgs<ExtArgs>
            result: $Utils.Optional<AuditLogGroupByOutputType>[]
          }
          count: {
            args: Prisma.AuditLogCountArgs<ExtArgs>
            result: $Utils.Optional<AuditLogCountAggregateOutputType> | number
          }
        }
      }
      Trip: {
        payload: Prisma.$TripPayload<ExtArgs>
        fields: Prisma.TripFieldRefs
        operations: {
          findUnique: {
            args: Prisma.TripFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$TripPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.TripFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$TripPayload>
          }
          findFirst: {
            args: Prisma.TripFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$TripPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.TripFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$TripPayload>
          }
          findMany: {
            args: Prisma.TripFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$TripPayload>[]
          }
          create: {
            args: Prisma.TripCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$TripPayload>
          }
          createMany: {
            args: Prisma.TripCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          createManyAndReturn: {
            args: Prisma.TripCreateManyAndReturnArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$TripPayload>[]
          }
          delete: {
            args: Prisma.TripDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$TripPayload>
          }
          update: {
            args: Prisma.TripUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$TripPayload>
          }
          deleteMany: {
            args: Prisma.TripDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.TripUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateManyAndReturn: {
            args: Prisma.TripUpdateManyAndReturnArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$TripPayload>[]
          }
          upsert: {
            args: Prisma.TripUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$TripPayload>
          }
          aggregate: {
            args: Prisma.TripAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateTrip>
          }
          groupBy: {
            args: Prisma.TripGroupByArgs<ExtArgs>
            result: $Utils.Optional<TripGroupByOutputType>[]
          }
          count: {
            args: Prisma.TripCountArgs<ExtArgs>
            result: $Utils.Optional<TripCountAggregateOutputType> | number
          }
        }
      }
      Punch: {
        payload: Prisma.$PunchPayload<ExtArgs>
        fields: Prisma.PunchFieldRefs
        operations: {
          findUnique: {
            args: Prisma.PunchFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$PunchPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.PunchFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$PunchPayload>
          }
          findFirst: {
            args: Prisma.PunchFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$PunchPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.PunchFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$PunchPayload>
          }
          findMany: {
            args: Prisma.PunchFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$PunchPayload>[]
          }
          create: {
            args: Prisma.PunchCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$PunchPayload>
          }
          createMany: {
            args: Prisma.PunchCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          createManyAndReturn: {
            args: Prisma.PunchCreateManyAndReturnArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$PunchPayload>[]
          }
          delete: {
            args: Prisma.PunchDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$PunchPayload>
          }
          update: {
            args: Prisma.PunchUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$PunchPayload>
          }
          deleteMany: {
            args: Prisma.PunchDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.PunchUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateManyAndReturn: {
            args: Prisma.PunchUpdateManyAndReturnArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$PunchPayload>[]
          }
          upsert: {
            args: Prisma.PunchUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$PunchPayload>
          }
          aggregate: {
            args: Prisma.PunchAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregatePunch>
          }
          groupBy: {
            args: Prisma.PunchGroupByArgs<ExtArgs>
            result: $Utils.Optional<PunchGroupByOutputType>[]
          }
          count: {
            args: Prisma.PunchCountArgs<ExtArgs>
            result: $Utils.Optional<PunchCountAggregateOutputType> | number
          }
        }
      }
      GpsPoint: {
        payload: Prisma.$GpsPointPayload<ExtArgs>
        fields: Prisma.GpsPointFieldRefs
        operations: {
          findUnique: {
            args: Prisma.GpsPointFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GpsPointPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.GpsPointFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GpsPointPayload>
          }
          findFirst: {
            args: Prisma.GpsPointFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GpsPointPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.GpsPointFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GpsPointPayload>
          }
          findMany: {
            args: Prisma.GpsPointFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GpsPointPayload>[]
          }
          create: {
            args: Prisma.GpsPointCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GpsPointPayload>
          }
          createMany: {
            args: Prisma.GpsPointCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          createManyAndReturn: {
            args: Prisma.GpsPointCreateManyAndReturnArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GpsPointPayload>[]
          }
          delete: {
            args: Prisma.GpsPointDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GpsPointPayload>
          }
          update: {
            args: Prisma.GpsPointUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GpsPointPayload>
          }
          deleteMany: {
            args: Prisma.GpsPointDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.GpsPointUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateManyAndReturn: {
            args: Prisma.GpsPointUpdateManyAndReturnArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GpsPointPayload>[]
          }
          upsert: {
            args: Prisma.GpsPointUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GpsPointPayload>
          }
          aggregate: {
            args: Prisma.GpsPointAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateGpsPoint>
          }
          groupBy: {
            args: Prisma.GpsPointGroupByArgs<ExtArgs>
            result: $Utils.Optional<GpsPointGroupByOutputType>[]
          }
          count: {
            args: Prisma.GpsPointCountArgs<ExtArgs>
            result: $Utils.Optional<GpsPointCountAggregateOutputType> | number
          }
        }
      }
      GpsStop: {
        payload: Prisma.$GpsStopPayload<ExtArgs>
        fields: Prisma.GpsStopFieldRefs
        operations: {
          findUnique: {
            args: Prisma.GpsStopFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GpsStopPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.GpsStopFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GpsStopPayload>
          }
          findFirst: {
            args: Prisma.GpsStopFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GpsStopPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.GpsStopFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GpsStopPayload>
          }
          findMany: {
            args: Prisma.GpsStopFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GpsStopPayload>[]
          }
          create: {
            args: Prisma.GpsStopCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GpsStopPayload>
          }
          createMany: {
            args: Prisma.GpsStopCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          createManyAndReturn: {
            args: Prisma.GpsStopCreateManyAndReturnArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GpsStopPayload>[]
          }
          delete: {
            args: Prisma.GpsStopDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GpsStopPayload>
          }
          update: {
            args: Prisma.GpsStopUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GpsStopPayload>
          }
          deleteMany: {
            args: Prisma.GpsStopDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.GpsStopUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateManyAndReturn: {
            args: Prisma.GpsStopUpdateManyAndReturnArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GpsStopPayload>[]
          }
          upsert: {
            args: Prisma.GpsStopUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GpsStopPayload>
          }
          aggregate: {
            args: Prisma.GpsStopAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateGpsStop>
          }
          groupBy: {
            args: Prisma.GpsStopGroupByArgs<ExtArgs>
            result: $Utils.Optional<GpsStopGroupByOutputType>[]
          }
          count: {
            args: Prisma.GpsStopCountArgs<ExtArgs>
            result: $Utils.Optional<GpsStopCountAggregateOutputType> | number
          }
        }
      }
      Notification: {
        payload: Prisma.$NotificationPayload<ExtArgs>
        fields: Prisma.NotificationFieldRefs
        operations: {
          findUnique: {
            args: Prisma.NotificationFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$NotificationPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.NotificationFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$NotificationPayload>
          }
          findFirst: {
            args: Prisma.NotificationFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$NotificationPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.NotificationFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$NotificationPayload>
          }
          findMany: {
            args: Prisma.NotificationFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$NotificationPayload>[]
          }
          create: {
            args: Prisma.NotificationCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$NotificationPayload>
          }
          createMany: {
            args: Prisma.NotificationCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          createManyAndReturn: {
            args: Prisma.NotificationCreateManyAndReturnArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$NotificationPayload>[]
          }
          delete: {
            args: Prisma.NotificationDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$NotificationPayload>
          }
          update: {
            args: Prisma.NotificationUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$NotificationPayload>
          }
          deleteMany: {
            args: Prisma.NotificationDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.NotificationUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateManyAndReturn: {
            args: Prisma.NotificationUpdateManyAndReturnArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$NotificationPayload>[]
          }
          upsert: {
            args: Prisma.NotificationUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$NotificationPayload>
          }
          aggregate: {
            args: Prisma.NotificationAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateNotification>
          }
          groupBy: {
            args: Prisma.NotificationGroupByArgs<ExtArgs>
            result: $Utils.Optional<NotificationGroupByOutputType>[]
          }
          count: {
            args: Prisma.NotificationCountArgs<ExtArgs>
            result: $Utils.Optional<NotificationCountAggregateOutputType> | number
          }
        }
      }
      SystemConfig: {
        payload: Prisma.$SystemConfigPayload<ExtArgs>
        fields: Prisma.SystemConfigFieldRefs
        operations: {
          findUnique: {
            args: Prisma.SystemConfigFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SystemConfigPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.SystemConfigFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SystemConfigPayload>
          }
          findFirst: {
            args: Prisma.SystemConfigFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SystemConfigPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.SystemConfigFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SystemConfigPayload>
          }
          findMany: {
            args: Prisma.SystemConfigFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SystemConfigPayload>[]
          }
          create: {
            args: Prisma.SystemConfigCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SystemConfigPayload>
          }
          createMany: {
            args: Prisma.SystemConfigCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          createManyAndReturn: {
            args: Prisma.SystemConfigCreateManyAndReturnArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SystemConfigPayload>[]
          }
          delete: {
            args: Prisma.SystemConfigDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SystemConfigPayload>
          }
          update: {
            args: Prisma.SystemConfigUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SystemConfigPayload>
          }
          deleteMany: {
            args: Prisma.SystemConfigDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.SystemConfigUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateManyAndReturn: {
            args: Prisma.SystemConfigUpdateManyAndReturnArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SystemConfigPayload>[]
          }
          upsert: {
            args: Prisma.SystemConfigUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SystemConfigPayload>
          }
          aggregate: {
            args: Prisma.SystemConfigAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateSystemConfig>
          }
          groupBy: {
            args: Prisma.SystemConfigGroupByArgs<ExtArgs>
            result: $Utils.Optional<SystemConfigGroupByOutputType>[]
          }
          count: {
            args: Prisma.SystemConfigCountArgs<ExtArgs>
            result: $Utils.Optional<SystemConfigCountAggregateOutputType> | number
          }
        }
      }
      DailySummary: {
        payload: Prisma.$DailySummaryPayload<ExtArgs>
        fields: Prisma.DailySummaryFieldRefs
        operations: {
          findUnique: {
            args: Prisma.DailySummaryFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$DailySummaryPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.DailySummaryFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$DailySummaryPayload>
          }
          findFirst: {
            args: Prisma.DailySummaryFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$DailySummaryPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.DailySummaryFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$DailySummaryPayload>
          }
          findMany: {
            args: Prisma.DailySummaryFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$DailySummaryPayload>[]
          }
          create: {
            args: Prisma.DailySummaryCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$DailySummaryPayload>
          }
          createMany: {
            args: Prisma.DailySummaryCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          createManyAndReturn: {
            args: Prisma.DailySummaryCreateManyAndReturnArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$DailySummaryPayload>[]
          }
          delete: {
            args: Prisma.DailySummaryDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$DailySummaryPayload>
          }
          update: {
            args: Prisma.DailySummaryUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$DailySummaryPayload>
          }
          deleteMany: {
            args: Prisma.DailySummaryDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.DailySummaryUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateManyAndReturn: {
            args: Prisma.DailySummaryUpdateManyAndReturnArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$DailySummaryPayload>[]
          }
          upsert: {
            args: Prisma.DailySummaryUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$DailySummaryPayload>
          }
          aggregate: {
            args: Prisma.DailySummaryAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateDailySummary>
          }
          groupBy: {
            args: Prisma.DailySummaryGroupByArgs<ExtArgs>
            result: $Utils.Optional<DailySummaryGroupByOutputType>[]
          }
          count: {
            args: Prisma.DailySummaryCountArgs<ExtArgs>
            result: $Utils.Optional<DailySummaryCountAggregateOutputType> | number
          }
        }
      }
      MonthlySummary: {
        payload: Prisma.$MonthlySummaryPayload<ExtArgs>
        fields: Prisma.MonthlySummaryFieldRefs
        operations: {
          findUnique: {
            args: Prisma.MonthlySummaryFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$MonthlySummaryPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.MonthlySummaryFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$MonthlySummaryPayload>
          }
          findFirst: {
            args: Prisma.MonthlySummaryFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$MonthlySummaryPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.MonthlySummaryFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$MonthlySummaryPayload>
          }
          findMany: {
            args: Prisma.MonthlySummaryFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$MonthlySummaryPayload>[]
          }
          create: {
            args: Prisma.MonthlySummaryCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$MonthlySummaryPayload>
          }
          createMany: {
            args: Prisma.MonthlySummaryCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          createManyAndReturn: {
            args: Prisma.MonthlySummaryCreateManyAndReturnArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$MonthlySummaryPayload>[]
          }
          delete: {
            args: Prisma.MonthlySummaryDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$MonthlySummaryPayload>
          }
          update: {
            args: Prisma.MonthlySummaryUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$MonthlySummaryPayload>
          }
          deleteMany: {
            args: Prisma.MonthlySummaryDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.MonthlySummaryUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateManyAndReturn: {
            args: Prisma.MonthlySummaryUpdateManyAndReturnArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$MonthlySummaryPayload>[]
          }
          upsert: {
            args: Prisma.MonthlySummaryUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$MonthlySummaryPayload>
          }
          aggregate: {
            args: Prisma.MonthlySummaryAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateMonthlySummary>
          }
          groupBy: {
            args: Prisma.MonthlySummaryGroupByArgs<ExtArgs>
            result: $Utils.Optional<MonthlySummaryGroupByOutputType>[]
          }
          count: {
            args: Prisma.MonthlySummaryCountArgs<ExtArgs>
            result: $Utils.Optional<MonthlySummaryCountAggregateOutputType> | number
          }
        }
      }
    }
  } & {
    other: {
      payload: any
      operations: {
        $executeRaw: {
          args: [query: TemplateStringsArray | Prisma.Sql, ...values: any[]],
          result: any
        }
        $executeRawUnsafe: {
          args: [query: string, ...values: any[]],
          result: any
        }
        $queryRaw: {
          args: [query: TemplateStringsArray | Prisma.Sql, ...values: any[]],
          result: any
        }
        $queryRawUnsafe: {
          args: [query: string, ...values: any[]],
          result: any
        }
      }
    }
  }
  export const defineExtension: $Extensions.ExtendsHook<"define", Prisma.TypeMapCb, $Extensions.DefaultArgs>
  export type DefaultPrismaClient = PrismaClient
  export type ErrorFormat = 'pretty' | 'colorless' | 'minimal'
  export interface PrismaClientOptions {
    /**
     * Overwrites the datasource url from your schema.prisma file
     */
    datasources?: Datasources
    /**
     * Overwrites the datasource url from your schema.prisma file
     */
    datasourceUrl?: string
    /**
     * @default "colorless"
     */
    errorFormat?: ErrorFormat
    /**
     * @example
     * ```
     * // Shorthand for `emit: 'stdout'`
     * log: ['query', 'info', 'warn', 'error']
     * 
     * // Emit as events only
     * log: [
     *   { emit: 'event', level: 'query' },
     *   { emit: 'event', level: 'info' },
     *   { emit: 'event', level: 'warn' }
     *   { emit: 'event', level: 'error' }
     * ]
     * 
     * / Emit as events and log to stdout
     * og: [
     *  { emit: 'stdout', level: 'query' },
     *  { emit: 'stdout', level: 'info' },
     *  { emit: 'stdout', level: 'warn' }
     *  { emit: 'stdout', level: 'error' }
     * 
     * ```
     * Read more in our [docs](https://www.prisma.io/docs/reference/tools-and-interfaces/prisma-client/logging#the-log-option).
     */
    log?: (LogLevel | LogDefinition)[]
    /**
     * The default values for transactionOptions
     * maxWait ?= 2000
     * timeout ?= 5000
     */
    transactionOptions?: {
      maxWait?: number
      timeout?: number
      isolationLevel?: Prisma.TransactionIsolationLevel
    }
    /**
     * Instance of a Driver Adapter, e.g., like one provided by `@prisma/adapter-planetscale`
     */
    adapter?: runtime.SqlDriverAdapterFactory | null
    /**
     * Global configuration for omitting model fields by default.
     * 
     * @example
     * ```
     * const prisma = new PrismaClient({
     *   omit: {
     *     user: {
     *       password: true
     *     }
     *   }
     * })
     * ```
     */
    omit?: Prisma.GlobalOmitConfig
  }
  export type GlobalOmitConfig = {
    user?: UserOmit
    refreshToken?: RefreshTokenOmit
    passwordResetToken?: PasswordResetTokenOmit
    auditLog?: AuditLogOmit
    trip?: TripOmit
    punch?: PunchOmit
    gpsPoint?: GpsPointOmit
    gpsStop?: GpsStopOmit
    notification?: NotificationOmit
    systemConfig?: SystemConfigOmit
    dailySummary?: DailySummaryOmit
    monthlySummary?: MonthlySummaryOmit
  }

  /* Types for Logging */
  export type LogLevel = 'info' | 'query' | 'warn' | 'error'
  export type LogDefinition = {
    level: LogLevel
    emit: 'stdout' | 'event'
  }

  export type CheckIsLogLevel<T> = T extends LogLevel ? T : never;

  export type GetLogType<T> = CheckIsLogLevel<
    T extends LogDefinition ? T['level'] : T
  >;

  export type GetEvents<T extends any[]> = T extends Array<LogLevel | LogDefinition>
    ? GetLogType<T[number]>
    : never;

  export type QueryEvent = {
    timestamp: Date
    query: string
    params: string
    duration: number
    target: string
  }

  export type LogEvent = {
    timestamp: Date
    message: string
    target: string
  }
  /* End Types for Logging */


  export type PrismaAction =
    | 'findUnique'
    | 'findUniqueOrThrow'
    | 'findMany'
    | 'findFirst'
    | 'findFirstOrThrow'
    | 'create'
    | 'createMany'
    | 'createManyAndReturn'
    | 'update'
    | 'updateMany'
    | 'updateManyAndReturn'
    | 'upsert'
    | 'delete'
    | 'deleteMany'
    | 'executeRaw'
    | 'queryRaw'
    | 'aggregate'
    | 'count'
    | 'runCommandRaw'
    | 'findRaw'
    | 'groupBy'

  // tested in getLogLevel.test.ts
  export function getLogLevel(log: Array<LogLevel | LogDefinition>): LogLevel | undefined;

  /**
   * `PrismaClient` proxy available in interactive transactions.
   */
  export type TransactionClient = Omit<Prisma.DefaultPrismaClient, runtime.ITXClientDenyList>

  export type Datasource = {
    url?: string
  }

  /**
   * Count Types
   */


  /**
   * Count Type UserCountOutputType
   */

  export type UserCountOutputType = {
    directReports: number
    refreshTokens: number
    trips: number
    gpsPoints: number
    auditLogs: number
    notifications: number
  }

  export type UserCountOutputTypeSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    directReports?: boolean | UserCountOutputTypeCountDirectReportsArgs
    refreshTokens?: boolean | UserCountOutputTypeCountRefreshTokensArgs
    trips?: boolean | UserCountOutputTypeCountTripsArgs
    gpsPoints?: boolean | UserCountOutputTypeCountGpsPointsArgs
    auditLogs?: boolean | UserCountOutputTypeCountAuditLogsArgs
    notifications?: boolean | UserCountOutputTypeCountNotificationsArgs
  }

  // Custom InputTypes
  /**
   * UserCountOutputType without action
   */
  export type UserCountOutputTypeDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the UserCountOutputType
     */
    select?: UserCountOutputTypeSelect<ExtArgs> | null
  }

  /**
   * UserCountOutputType without action
   */
  export type UserCountOutputTypeCountDirectReportsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: UserWhereInput
  }

  /**
   * UserCountOutputType without action
   */
  export type UserCountOutputTypeCountRefreshTokensArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: RefreshTokenWhereInput
  }

  /**
   * UserCountOutputType without action
   */
  export type UserCountOutputTypeCountTripsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: TripWhereInput
  }

  /**
   * UserCountOutputType without action
   */
  export type UserCountOutputTypeCountGpsPointsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: GpsPointWhereInput
  }

  /**
   * UserCountOutputType without action
   */
  export type UserCountOutputTypeCountAuditLogsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: AuditLogWhereInput
  }

  /**
   * UserCountOutputType without action
   */
  export type UserCountOutputTypeCountNotificationsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: NotificationWhereInput
  }


  /**
   * Count Type TripCountOutputType
   */

  export type TripCountOutputType = {
    punches: number
    gpsPoints: number
    stops: number
  }

  export type TripCountOutputTypeSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    punches?: boolean | TripCountOutputTypeCountPunchesArgs
    gpsPoints?: boolean | TripCountOutputTypeCountGpsPointsArgs
    stops?: boolean | TripCountOutputTypeCountStopsArgs
  }

  // Custom InputTypes
  /**
   * TripCountOutputType without action
   */
  export type TripCountOutputTypeDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the TripCountOutputType
     */
    select?: TripCountOutputTypeSelect<ExtArgs> | null
  }

  /**
   * TripCountOutputType without action
   */
  export type TripCountOutputTypeCountPunchesArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: PunchWhereInput
  }

  /**
   * TripCountOutputType without action
   */
  export type TripCountOutputTypeCountGpsPointsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: GpsPointWhereInput
  }

  /**
   * TripCountOutputType without action
   */
  export type TripCountOutputTypeCountStopsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: GpsStopWhereInput
  }


  /**
   * Models
   */

  /**
   * Model User
   */

  export type AggregateUser = {
    _count: UserCountAggregateOutputType | null
    _min: UserMinAggregateOutputType | null
    _max: UserMaxAggregateOutputType | null
  }

  export type UserMinAggregateOutputType = {
    id: string | null
    uid: string | null
    email: string | null
    passwordHash: string | null
    fullName: string | null
    employeeCode: string | null
    mobileNumber: string | null
    sittingLocation: string | null
    reportingManagerId: string | null
    role: $Enums.UserRole | null
    deviceId: string | null
    profileImage: string | null
    status: $Enums.UserStatus | null
    fcmToken: string | null
    isRooted: boolean | null
    presence: $Enums.EmployeePresence | null
    lastSeenAt: Date | null
    createdAt: Date | null
    updatedAt: Date | null
  }

  export type UserMaxAggregateOutputType = {
    id: string | null
    uid: string | null
    email: string | null
    passwordHash: string | null
    fullName: string | null
    employeeCode: string | null
    mobileNumber: string | null
    sittingLocation: string | null
    reportingManagerId: string | null
    role: $Enums.UserRole | null
    deviceId: string | null
    profileImage: string | null
    status: $Enums.UserStatus | null
    fcmToken: string | null
    isRooted: boolean | null
    presence: $Enums.EmployeePresence | null
    lastSeenAt: Date | null
    createdAt: Date | null
    updatedAt: Date | null
  }

  export type UserCountAggregateOutputType = {
    id: number
    uid: number
    email: number
    passwordHash: number
    fullName: number
    employeeCode: number
    mobileNumber: number
    sittingLocation: number
    reportingManagerId: number
    role: number
    deviceId: number
    profileImage: number
    status: number
    fcmToken: number
    isRooted: number
    presence: number
    lastSeenAt: number
    createdAt: number
    updatedAt: number
    _all: number
  }


  export type UserMinAggregateInputType = {
    id?: true
    uid?: true
    email?: true
    passwordHash?: true
    fullName?: true
    employeeCode?: true
    mobileNumber?: true
    sittingLocation?: true
    reportingManagerId?: true
    role?: true
    deviceId?: true
    profileImage?: true
    status?: true
    fcmToken?: true
    isRooted?: true
    presence?: true
    lastSeenAt?: true
    createdAt?: true
    updatedAt?: true
  }

  export type UserMaxAggregateInputType = {
    id?: true
    uid?: true
    email?: true
    passwordHash?: true
    fullName?: true
    employeeCode?: true
    mobileNumber?: true
    sittingLocation?: true
    reportingManagerId?: true
    role?: true
    deviceId?: true
    profileImage?: true
    status?: true
    fcmToken?: true
    isRooted?: true
    presence?: true
    lastSeenAt?: true
    createdAt?: true
    updatedAt?: true
  }

  export type UserCountAggregateInputType = {
    id?: true
    uid?: true
    email?: true
    passwordHash?: true
    fullName?: true
    employeeCode?: true
    mobileNumber?: true
    sittingLocation?: true
    reportingManagerId?: true
    role?: true
    deviceId?: true
    profileImage?: true
    status?: true
    fcmToken?: true
    isRooted?: true
    presence?: true
    lastSeenAt?: true
    createdAt?: true
    updatedAt?: true
    _all?: true
  }

  export type UserAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which User to aggregate.
     */
    where?: UserWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Users to fetch.
     */
    orderBy?: UserOrderByWithRelationInput | UserOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: UserWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Users from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` Users.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned Users
    **/
    _count?: true | UserCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: UserMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: UserMaxAggregateInputType
  }

  export type GetUserAggregateType<T extends UserAggregateArgs> = {
        [P in keyof T & keyof AggregateUser]: P extends '_count' | 'count'
      ? T[P] extends true
        ? number
        : GetScalarType<T[P], AggregateUser[P]>
      : GetScalarType<T[P], AggregateUser[P]>
  }




  export type UserGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: UserWhereInput
    orderBy?: UserOrderByWithAggregationInput | UserOrderByWithAggregationInput[]
    by: UserScalarFieldEnum[] | UserScalarFieldEnum
    having?: UserScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: UserCountAggregateInputType | true
    _min?: UserMinAggregateInputType
    _max?: UserMaxAggregateInputType
  }

  export type UserGroupByOutputType = {
    id: string
    uid: string
    email: string
    passwordHash: string
    fullName: string
    employeeCode: string
    mobileNumber: string | null
    sittingLocation: string | null
    reportingManagerId: string | null
    role: $Enums.UserRole
    deviceId: string | null
    profileImage: string | null
    status: $Enums.UserStatus
    fcmToken: string | null
    isRooted: boolean
    presence: $Enums.EmployeePresence
    lastSeenAt: Date | null
    createdAt: Date
    updatedAt: Date
    _count: UserCountAggregateOutputType | null
    _min: UserMinAggregateOutputType | null
    _max: UserMaxAggregateOutputType | null
  }

  type GetUserGroupByPayload<T extends UserGroupByArgs> = Prisma.PrismaPromise<
    Array<
      PickEnumerable<UserGroupByOutputType, T['by']> &
        {
          [P in ((keyof T) & (keyof UserGroupByOutputType))]: P extends '_count'
            ? T[P] extends boolean
              ? number
              : GetScalarType<T[P], UserGroupByOutputType[P]>
            : GetScalarType<T[P], UserGroupByOutputType[P]>
        }
      >
    >


  export type UserSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    uid?: boolean
    email?: boolean
    passwordHash?: boolean
    fullName?: boolean
    employeeCode?: boolean
    mobileNumber?: boolean
    sittingLocation?: boolean
    reportingManagerId?: boolean
    role?: boolean
    deviceId?: boolean
    profileImage?: boolean
    status?: boolean
    fcmToken?: boolean
    isRooted?: boolean
    presence?: boolean
    lastSeenAt?: boolean
    createdAt?: boolean
    updatedAt?: boolean
    reportingManager?: boolean | User$reportingManagerArgs<ExtArgs>
    directReports?: boolean | User$directReportsArgs<ExtArgs>
    refreshTokens?: boolean | User$refreshTokensArgs<ExtArgs>
    trips?: boolean | User$tripsArgs<ExtArgs>
    gpsPoints?: boolean | User$gpsPointsArgs<ExtArgs>
    auditLogs?: boolean | User$auditLogsArgs<ExtArgs>
    notifications?: boolean | User$notificationsArgs<ExtArgs>
    _count?: boolean | UserCountOutputTypeDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["user"]>

  export type UserSelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    uid?: boolean
    email?: boolean
    passwordHash?: boolean
    fullName?: boolean
    employeeCode?: boolean
    mobileNumber?: boolean
    sittingLocation?: boolean
    reportingManagerId?: boolean
    role?: boolean
    deviceId?: boolean
    profileImage?: boolean
    status?: boolean
    fcmToken?: boolean
    isRooted?: boolean
    presence?: boolean
    lastSeenAt?: boolean
    createdAt?: boolean
    updatedAt?: boolean
    reportingManager?: boolean | User$reportingManagerArgs<ExtArgs>
  }, ExtArgs["result"]["user"]>

  export type UserSelectUpdateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    uid?: boolean
    email?: boolean
    passwordHash?: boolean
    fullName?: boolean
    employeeCode?: boolean
    mobileNumber?: boolean
    sittingLocation?: boolean
    reportingManagerId?: boolean
    role?: boolean
    deviceId?: boolean
    profileImage?: boolean
    status?: boolean
    fcmToken?: boolean
    isRooted?: boolean
    presence?: boolean
    lastSeenAt?: boolean
    createdAt?: boolean
    updatedAt?: boolean
    reportingManager?: boolean | User$reportingManagerArgs<ExtArgs>
  }, ExtArgs["result"]["user"]>

  export type UserSelectScalar = {
    id?: boolean
    uid?: boolean
    email?: boolean
    passwordHash?: boolean
    fullName?: boolean
    employeeCode?: boolean
    mobileNumber?: boolean
    sittingLocation?: boolean
    reportingManagerId?: boolean
    role?: boolean
    deviceId?: boolean
    profileImage?: boolean
    status?: boolean
    fcmToken?: boolean
    isRooted?: boolean
    presence?: boolean
    lastSeenAt?: boolean
    createdAt?: boolean
    updatedAt?: boolean
  }

  export type UserOmit<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetOmit<"id" | "uid" | "email" | "passwordHash" | "fullName" | "employeeCode" | "mobileNumber" | "sittingLocation" | "reportingManagerId" | "role" | "deviceId" | "profileImage" | "status" | "fcmToken" | "isRooted" | "presence" | "lastSeenAt" | "createdAt" | "updatedAt", ExtArgs["result"]["user"]>
  export type UserInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    reportingManager?: boolean | User$reportingManagerArgs<ExtArgs>
    directReports?: boolean | User$directReportsArgs<ExtArgs>
    refreshTokens?: boolean | User$refreshTokensArgs<ExtArgs>
    trips?: boolean | User$tripsArgs<ExtArgs>
    gpsPoints?: boolean | User$gpsPointsArgs<ExtArgs>
    auditLogs?: boolean | User$auditLogsArgs<ExtArgs>
    notifications?: boolean | User$notificationsArgs<ExtArgs>
    _count?: boolean | UserCountOutputTypeDefaultArgs<ExtArgs>
  }
  export type UserIncludeCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    reportingManager?: boolean | User$reportingManagerArgs<ExtArgs>
  }
  export type UserIncludeUpdateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    reportingManager?: boolean | User$reportingManagerArgs<ExtArgs>
  }

  export type $UserPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "User"
    objects: {
      reportingManager: Prisma.$UserPayload<ExtArgs> | null
      directReports: Prisma.$UserPayload<ExtArgs>[]
      refreshTokens: Prisma.$RefreshTokenPayload<ExtArgs>[]
      trips: Prisma.$TripPayload<ExtArgs>[]
      gpsPoints: Prisma.$GpsPointPayload<ExtArgs>[]
      auditLogs: Prisma.$AuditLogPayload<ExtArgs>[]
      notifications: Prisma.$NotificationPayload<ExtArgs>[]
    }
    scalars: $Extensions.GetPayloadResult<{
      id: string
      uid: string
      email: string
      passwordHash: string
      fullName: string
      employeeCode: string
      mobileNumber: string | null
      sittingLocation: string | null
      reportingManagerId: string | null
      role: $Enums.UserRole
      deviceId: string | null
      profileImage: string | null
      status: $Enums.UserStatus
      fcmToken: string | null
      isRooted: boolean
      presence: $Enums.EmployeePresence
      lastSeenAt: Date | null
      createdAt: Date
      updatedAt: Date
    }, ExtArgs["result"]["user"]>
    composites: {}
  }

  type UserGetPayload<S extends boolean | null | undefined | UserDefaultArgs> = $Result.GetResult<Prisma.$UserPayload, S>

  type UserCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
    Omit<UserFindManyArgs, 'select' | 'include' | 'distinct' | 'omit'> & {
      select?: UserCountAggregateInputType | true
    }

  export interface UserDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs, GlobalOmitOptions = {}> {
    [K: symbol]: { types: Prisma.TypeMap<ExtArgs>['model']['User'], meta: { name: 'User' } }
    /**
     * Find zero or one User that matches the filter.
     * @param {UserFindUniqueArgs} args - Arguments to find a User
     * @example
     * // Get one User
     * const user = await prisma.user.findUnique({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findUnique<T extends UserFindUniqueArgs>(args: SelectSubset<T, UserFindUniqueArgs<ExtArgs>>): Prisma__UserClient<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "findUnique", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>

    /**
     * Find one User that matches the filter or throw an error with `error.code='P2025'`
     * if no matches were found.
     * @param {UserFindUniqueOrThrowArgs} args - Arguments to find a User
     * @example
     * // Get one User
     * const user = await prisma.user.findUniqueOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findUniqueOrThrow<T extends UserFindUniqueOrThrowArgs>(args: SelectSubset<T, UserFindUniqueOrThrowArgs<ExtArgs>>): Prisma__UserClient<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Find the first User that matches the filter.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {UserFindFirstArgs} args - Arguments to find a User
     * @example
     * // Get one User
     * const user = await prisma.user.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends UserFindFirstArgs>(args?: SelectSubset<T, UserFindFirstArgs<ExtArgs>>): Prisma__UserClient<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "findFirst", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>

    /**
     * Find the first User that matches the filter or
     * throw `PrismaKnownClientError` with `P2025` code if no matches were found.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {UserFindFirstOrThrowArgs} args - Arguments to find a User
     * @example
     * // Get one User
     * const user = await prisma.user.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends UserFindFirstOrThrowArgs>(args?: SelectSubset<T, UserFindFirstOrThrowArgs<ExtArgs>>): Prisma__UserClient<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "findFirstOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Find zero or more Users that matches the filter.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {UserFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all Users
     * const users = await prisma.user.findMany()
     * 
     * // Get first 10 Users
     * const users = await prisma.user.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const userWithIdOnly = await prisma.user.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends UserFindManyArgs>(args?: SelectSubset<T, UserFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "findMany", GlobalOmitOptions>>

    /**
     * Create a User.
     * @param {UserCreateArgs} args - Arguments to create a User.
     * @example
     * // Create one User
     * const User = await prisma.user.create({
     *   data: {
     *     // ... data to create a User
     *   }
     * })
     * 
     */
    create<T extends UserCreateArgs>(args: SelectSubset<T, UserCreateArgs<ExtArgs>>): Prisma__UserClient<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "create", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Create many Users.
     * @param {UserCreateManyArgs} args - Arguments to create many Users.
     * @example
     * // Create many Users
     * const user = await prisma.user.createMany({
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     *     
     */
    createMany<T extends UserCreateManyArgs>(args?: SelectSubset<T, UserCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>

    /**
     * Create many Users and returns the data saved in the database.
     * @param {UserCreateManyAndReturnArgs} args - Arguments to create many Users.
     * @example
     * // Create many Users
     * const user = await prisma.user.createManyAndReturn({
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * 
     * // Create many Users and only return the `id`
     * const userWithIdOnly = await prisma.user.createManyAndReturn({
     *   select: { id: true },
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * 
     */
    createManyAndReturn<T extends UserCreateManyAndReturnArgs>(args?: SelectSubset<T, UserCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "createManyAndReturn", GlobalOmitOptions>>

    /**
     * Delete a User.
     * @param {UserDeleteArgs} args - Arguments to delete one User.
     * @example
     * // Delete one User
     * const User = await prisma.user.delete({
     *   where: {
     *     // ... filter to delete one User
     *   }
     * })
     * 
     */
    delete<T extends UserDeleteArgs>(args: SelectSubset<T, UserDeleteArgs<ExtArgs>>): Prisma__UserClient<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "delete", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Update one User.
     * @param {UserUpdateArgs} args - Arguments to update one User.
     * @example
     * // Update one User
     * const user = await prisma.user.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends UserUpdateArgs>(args: SelectSubset<T, UserUpdateArgs<ExtArgs>>): Prisma__UserClient<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "update", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Delete zero or more Users.
     * @param {UserDeleteManyArgs} args - Arguments to filter Users to delete.
     * @example
     * // Delete a few Users
     * const { count } = await prisma.user.deleteMany({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     * 
     */
    deleteMany<T extends UserDeleteManyArgs>(args?: SelectSubset<T, UserDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>

    /**
     * Update zero or more Users.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {UserUpdateManyArgs} args - Arguments to update one or more rows.
     * @example
     * // Update many Users
     * const user = await prisma.user.updateMany({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    updateMany<T extends UserUpdateManyArgs>(args: SelectSubset<T, UserUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>

    /**
     * Update zero or more Users and returns the data updated in the database.
     * @param {UserUpdateManyAndReturnArgs} args - Arguments to update many Users.
     * @example
     * // Update many Users
     * const user = await prisma.user.updateManyAndReturn({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * 
     * // Update zero or more Users and only return the `id`
     * const userWithIdOnly = await prisma.user.updateManyAndReturn({
     *   select: { id: true },
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * 
     */
    updateManyAndReturn<T extends UserUpdateManyAndReturnArgs>(args: SelectSubset<T, UserUpdateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "updateManyAndReturn", GlobalOmitOptions>>

    /**
     * Create or update one User.
     * @param {UserUpsertArgs} args - Arguments to update or create a User.
     * @example
     * // Update or create a User
     * const user = await prisma.user.upsert({
     *   create: {
     *     // ... data to create a User
     *   },
     *   update: {
     *     // ... in case it already exists, update
     *   },
     *   where: {
     *     // ... the filter for the User we want to update
     *   }
     * })
     */
    upsert<T extends UserUpsertArgs>(args: SelectSubset<T, UserUpsertArgs<ExtArgs>>): Prisma__UserClient<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "upsert", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>


    /**
     * Count the number of Users.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {UserCountArgs} args - Arguments to filter Users to count.
     * @example
     * // Count the number of Users
     * const count = await prisma.user.count({
     *   where: {
     *     // ... the filter for the Users we want to count
     *   }
     * })
    **/
    count<T extends UserCountArgs>(
      args?: Subset<T, UserCountArgs>,
    ): Prisma.PrismaPromise<
      T extends $Utils.Record<'select', any>
        ? T['select'] extends true
          ? number
          : GetScalarType<T['select'], UserCountAggregateOutputType>
        : number
    >

    /**
     * Allows you to perform aggregations operations on a User.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {UserAggregateArgs} args - Select which aggregations you would like to apply and on what fields.
     * @example
     * // Ordered by age ascending
     * // Where email contains prisma.io
     * // Limited to the 10 users
     * const aggregations = await prisma.user.aggregate({
     *   _avg: {
     *     age: true,
     *   },
     *   where: {
     *     email: {
     *       contains: "prisma.io",
     *     },
     *   },
     *   orderBy: {
     *     age: "asc",
     *   },
     *   take: 10,
     * })
    **/
    aggregate<T extends UserAggregateArgs>(args: Subset<T, UserAggregateArgs>): Prisma.PrismaPromise<GetUserAggregateType<T>>

    /**
     * Group by User.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {UserGroupByArgs} args - Group by arguments.
     * @example
     * // Group by city, order by createdAt, get count
     * const result = await prisma.user.groupBy({
     *   by: ['city', 'createdAt'],
     *   orderBy: {
     *     createdAt: true
     *   },
     *   _count: {
     *     _all: true
     *   },
     * })
     * 
    **/
    groupBy<
      T extends UserGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: UserGroupByArgs['orderBy'] }
        : { orderBy?: UserGroupByArgs['orderBy'] },
      OrderFields extends ExcludeUnderscoreKeys<Keys<MaybeTupleToUnion<T['orderBy']>>>,
      ByFields extends MaybeTupleToUnion<T['by']>,
      ByValid extends Has<ByFields, OrderFields>,
      HavingFields extends GetHavingFields<T['having']>,
      HavingValid extends Has<ByFields, HavingFields>,
      ByEmpty extends T['by'] extends never[] ? True : False,
      InputErrors extends ByEmpty extends True
      ? `Error: "by" must not be empty.`
      : HavingValid extends False
      ? {
          [P in HavingFields]: P extends ByFields
            ? never
            : P extends string
            ? `Error: Field "${P}" used in "having" needs to be provided in "by".`
            : [
                Error,
                'Field ',
                P,
                ` in "having" needs to be provided in "by"`,
              ]
        }[HavingFields]
      : 'take' extends Keys<T>
      ? 'orderBy' extends Keys<T>
        ? ByValid extends True
          ? {}
          : {
              [P in OrderFields]: P extends ByFields
                ? never
                : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
            }[OrderFields]
        : 'Error: If you provide "take", you also need to provide "orderBy"'
      : 'skip' extends Keys<T>
      ? 'orderBy' extends Keys<T>
        ? ByValid extends True
          ? {}
          : {
              [P in OrderFields]: P extends ByFields
                ? never
                : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
            }[OrderFields]
        : 'Error: If you provide "skip", you also need to provide "orderBy"'
      : ByValid extends True
      ? {}
      : {
          [P in OrderFields]: P extends ByFields
            ? never
            : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
        }[OrderFields]
    >(args: SubsetIntersection<T, UserGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetUserGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the User model
   */
  readonly fields: UserFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for User.
   * Why is this prefixed with `Prisma__`?
   * Because we want to prevent naming conflicts as mentioned in
   * https://github.com/prisma/prisma-client-js/issues/707
   */
  export interface Prisma__UserClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs, GlobalOmitOptions = {}> extends Prisma.PrismaPromise<T> {
    readonly [Symbol.toStringTag]: "PrismaPromise"
    reportingManager<T extends User$reportingManagerArgs<ExtArgs> = {}>(args?: Subset<T, User$reportingManagerArgs<ExtArgs>>): Prisma__UserClient<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>
    directReports<T extends User$directReportsArgs<ExtArgs> = {}>(args?: Subset<T, User$directReportsArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
    refreshTokens<T extends User$refreshTokensArgs<ExtArgs> = {}>(args?: Subset<T, User$refreshTokensArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$RefreshTokenPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
    trips<T extends User$tripsArgs<ExtArgs> = {}>(args?: Subset<T, User$tripsArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$TripPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
    gpsPoints<T extends User$gpsPointsArgs<ExtArgs> = {}>(args?: Subset<T, User$gpsPointsArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$GpsPointPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
    auditLogs<T extends User$auditLogsArgs<ExtArgs> = {}>(args?: Subset<T, User$auditLogsArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$AuditLogPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
    notifications<T extends User$notificationsArgs<ExtArgs> = {}>(args?: Subset<T, User$notificationsArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$NotificationPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
    /**
     * Attaches callbacks for the resolution and/or rejection of the Promise.
     * @param onfulfilled The callback to execute when the Promise is resolved.
     * @param onrejected The callback to execute when the Promise is rejected.
     * @returns A Promise for the completion of which ever callback is executed.
     */
    then<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): $Utils.JsPromise<TResult1 | TResult2>
    /**
     * Attaches a callback for only the rejection of the Promise.
     * @param onrejected The callback to execute when the Promise is rejected.
     * @returns A Promise for the completion of the callback.
     */
    catch<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): $Utils.JsPromise<T | TResult>
    /**
     * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The
     * resolved value cannot be modified from the callback.
     * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected).
     * @returns A Promise for the completion of the callback.
     */
    finally(onfinally?: (() => void) | undefined | null): $Utils.JsPromise<T>
  }




  /**
   * Fields of the User model
   */
  interface UserFieldRefs {
    readonly id: FieldRef<"User", 'String'>
    readonly uid: FieldRef<"User", 'String'>
    readonly email: FieldRef<"User", 'String'>
    readonly passwordHash: FieldRef<"User", 'String'>
    readonly fullName: FieldRef<"User", 'String'>
    readonly employeeCode: FieldRef<"User", 'String'>
    readonly mobileNumber: FieldRef<"User", 'String'>
    readonly sittingLocation: FieldRef<"User", 'String'>
    readonly reportingManagerId: FieldRef<"User", 'String'>
    readonly role: FieldRef<"User", 'UserRole'>
    readonly deviceId: FieldRef<"User", 'String'>
    readonly profileImage: FieldRef<"User", 'String'>
    readonly status: FieldRef<"User", 'UserStatus'>
    readonly fcmToken: FieldRef<"User", 'String'>
    readonly isRooted: FieldRef<"User", 'Boolean'>
    readonly presence: FieldRef<"User", 'EmployeePresence'>
    readonly lastSeenAt: FieldRef<"User", 'DateTime'>
    readonly createdAt: FieldRef<"User", 'DateTime'>
    readonly updatedAt: FieldRef<"User", 'DateTime'>
  }
    

  // Custom InputTypes
  /**
   * User findUnique
   */
  export type UserFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the User
     */
    select?: UserSelect<ExtArgs> | null
    /**
     * Omit specific fields from the User
     */
    omit?: UserOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: UserInclude<ExtArgs> | null
    /**
     * Filter, which User to fetch.
     */
    where: UserWhereUniqueInput
  }

  /**
   * User findUniqueOrThrow
   */
  export type UserFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the User
     */
    select?: UserSelect<ExtArgs> | null
    /**
     * Omit specific fields from the User
     */
    omit?: UserOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: UserInclude<ExtArgs> | null
    /**
     * Filter, which User to fetch.
     */
    where: UserWhereUniqueInput
  }

  /**
   * User findFirst
   */
  export type UserFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the User
     */
    select?: UserSelect<ExtArgs> | null
    /**
     * Omit specific fields from the User
     */
    omit?: UserOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: UserInclude<ExtArgs> | null
    /**
     * Filter, which User to fetch.
     */
    where?: UserWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Users to fetch.
     */
    orderBy?: UserOrderByWithRelationInput | UserOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for Users.
     */
    cursor?: UserWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Users from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` Users.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of Users.
     */
    distinct?: UserScalarFieldEnum | UserScalarFieldEnum[]
  }

  /**
   * User findFirstOrThrow
   */
  export type UserFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the User
     */
    select?: UserSelect<ExtArgs> | null
    /**
     * Omit specific fields from the User
     */
    omit?: UserOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: UserInclude<ExtArgs> | null
    /**
     * Filter, which User to fetch.
     */
    where?: UserWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Users to fetch.
     */
    orderBy?: UserOrderByWithRelationInput | UserOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for Users.
     */
    cursor?: UserWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Users from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` Users.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of Users.
     */
    distinct?: UserScalarFieldEnum | UserScalarFieldEnum[]
  }

  /**
   * User findMany
   */
  export type UserFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the User
     */
    select?: UserSelect<ExtArgs> | null
    /**
     * Omit specific fields from the User
     */
    omit?: UserOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: UserInclude<ExtArgs> | null
    /**
     * Filter, which Users to fetch.
     */
    where?: UserWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Users to fetch.
     */
    orderBy?: UserOrderByWithRelationInput | UserOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing Users.
     */
    cursor?: UserWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Users from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` Users.
     */
    skip?: number
    distinct?: UserScalarFieldEnum | UserScalarFieldEnum[]
  }

  /**
   * User create
   */
  export type UserCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the User
     */
    select?: UserSelect<ExtArgs> | null
    /**
     * Omit specific fields from the User
     */
    omit?: UserOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: UserInclude<ExtArgs> | null
    /**
     * The data needed to create a User.
     */
    data: XOR<UserCreateInput, UserUncheckedCreateInput>
  }

  /**
   * User createMany
   */
  export type UserCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many Users.
     */
    data: UserCreateManyInput | UserCreateManyInput[]
  }

  /**
   * User createManyAndReturn
   */
  export type UserCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the User
     */
    select?: UserSelectCreateManyAndReturn<ExtArgs> | null
    /**
     * Omit specific fields from the User
     */
    omit?: UserOmit<ExtArgs> | null
    /**
     * The data used to create many Users.
     */
    data: UserCreateManyInput | UserCreateManyInput[]
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: UserIncludeCreateManyAndReturn<ExtArgs> | null
  }

  /**
   * User update
   */
  export type UserUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the User
     */
    select?: UserSelect<ExtArgs> | null
    /**
     * Omit specific fields from the User
     */
    omit?: UserOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: UserInclude<ExtArgs> | null
    /**
     * The data needed to update a User.
     */
    data: XOR<UserUpdateInput, UserUncheckedUpdateInput>
    /**
     * Choose, which User to update.
     */
    where: UserWhereUniqueInput
  }

  /**
   * User updateMany
   */
  export type UserUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update Users.
     */
    data: XOR<UserUpdateManyMutationInput, UserUncheckedUpdateManyInput>
    /**
     * Filter which Users to update
     */
    where?: UserWhereInput
    /**
     * Limit how many Users to update.
     */
    limit?: number
  }

  /**
   * User updateManyAndReturn
   */
  export type UserUpdateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the User
     */
    select?: UserSelectUpdateManyAndReturn<ExtArgs> | null
    /**
     * Omit specific fields from the User
     */
    omit?: UserOmit<ExtArgs> | null
    /**
     * The data used to update Users.
     */
    data: XOR<UserUpdateManyMutationInput, UserUncheckedUpdateManyInput>
    /**
     * Filter which Users to update
     */
    where?: UserWhereInput
    /**
     * Limit how many Users to update.
     */
    limit?: number
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: UserIncludeUpdateManyAndReturn<ExtArgs> | null
  }

  /**
   * User upsert
   */
  export type UserUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the User
     */
    select?: UserSelect<ExtArgs> | null
    /**
     * Omit specific fields from the User
     */
    omit?: UserOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: UserInclude<ExtArgs> | null
    /**
     * The filter to search for the User to update in case it exists.
     */
    where: UserWhereUniqueInput
    /**
     * In case the User found by the `where` argument doesn't exist, create a new User with this data.
     */
    create: XOR<UserCreateInput, UserUncheckedCreateInput>
    /**
     * In case the User was found with the provided `where` argument, update it with this data.
     */
    update: XOR<UserUpdateInput, UserUncheckedUpdateInput>
  }

  /**
   * User delete
   */
  export type UserDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the User
     */
    select?: UserSelect<ExtArgs> | null
    /**
     * Omit specific fields from the User
     */
    omit?: UserOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: UserInclude<ExtArgs> | null
    /**
     * Filter which User to delete.
     */
    where: UserWhereUniqueInput
  }

  /**
   * User deleteMany
   */
  export type UserDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which Users to delete
     */
    where?: UserWhereInput
    /**
     * Limit how many Users to delete.
     */
    limit?: number
  }

  /**
   * User.reportingManager
   */
  export type User$reportingManagerArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the User
     */
    select?: UserSelect<ExtArgs> | null
    /**
     * Omit specific fields from the User
     */
    omit?: UserOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: UserInclude<ExtArgs> | null
    where?: UserWhereInput
  }

  /**
   * User.directReports
   */
  export type User$directReportsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the User
     */
    select?: UserSelect<ExtArgs> | null
    /**
     * Omit specific fields from the User
     */
    omit?: UserOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: UserInclude<ExtArgs> | null
    where?: UserWhereInput
    orderBy?: UserOrderByWithRelationInput | UserOrderByWithRelationInput[]
    cursor?: UserWhereUniqueInput
    take?: number
    skip?: number
    distinct?: UserScalarFieldEnum | UserScalarFieldEnum[]
  }

  /**
   * User.refreshTokens
   */
  export type User$refreshTokensArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the RefreshToken
     */
    select?: RefreshTokenSelect<ExtArgs> | null
    /**
     * Omit specific fields from the RefreshToken
     */
    omit?: RefreshTokenOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: RefreshTokenInclude<ExtArgs> | null
    where?: RefreshTokenWhereInput
    orderBy?: RefreshTokenOrderByWithRelationInput | RefreshTokenOrderByWithRelationInput[]
    cursor?: RefreshTokenWhereUniqueInput
    take?: number
    skip?: number
    distinct?: RefreshTokenScalarFieldEnum | RefreshTokenScalarFieldEnum[]
  }

  /**
   * User.trips
   */
  export type User$tripsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Trip
     */
    select?: TripSelect<ExtArgs> | null
    /**
     * Omit specific fields from the Trip
     */
    omit?: TripOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: TripInclude<ExtArgs> | null
    where?: TripWhereInput
    orderBy?: TripOrderByWithRelationInput | TripOrderByWithRelationInput[]
    cursor?: TripWhereUniqueInput
    take?: number
    skip?: number
    distinct?: TripScalarFieldEnum | TripScalarFieldEnum[]
  }

  /**
   * User.gpsPoints
   */
  export type User$gpsPointsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the GpsPoint
     */
    select?: GpsPointSelect<ExtArgs> | null
    /**
     * Omit specific fields from the GpsPoint
     */
    omit?: GpsPointOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GpsPointInclude<ExtArgs> | null
    where?: GpsPointWhereInput
    orderBy?: GpsPointOrderByWithRelationInput | GpsPointOrderByWithRelationInput[]
    cursor?: GpsPointWhereUniqueInput
    take?: number
    skip?: number
    distinct?: GpsPointScalarFieldEnum | GpsPointScalarFieldEnum[]
  }

  /**
   * User.auditLogs
   */
  export type User$auditLogsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the AuditLog
     */
    select?: AuditLogSelect<ExtArgs> | null
    /**
     * Omit specific fields from the AuditLog
     */
    omit?: AuditLogOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: AuditLogInclude<ExtArgs> | null
    where?: AuditLogWhereInput
    orderBy?: AuditLogOrderByWithRelationInput | AuditLogOrderByWithRelationInput[]
    cursor?: AuditLogWhereUniqueInput
    take?: number
    skip?: number
    distinct?: AuditLogScalarFieldEnum | AuditLogScalarFieldEnum[]
  }

  /**
   * User.notifications
   */
  export type User$notificationsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Notification
     */
    select?: NotificationSelect<ExtArgs> | null
    /**
     * Omit specific fields from the Notification
     */
    omit?: NotificationOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: NotificationInclude<ExtArgs> | null
    where?: NotificationWhereInput
    orderBy?: NotificationOrderByWithRelationInput | NotificationOrderByWithRelationInput[]
    cursor?: NotificationWhereUniqueInput
    take?: number
    skip?: number
    distinct?: NotificationScalarFieldEnum | NotificationScalarFieldEnum[]
  }

  /**
   * User without action
   */
  export type UserDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the User
     */
    select?: UserSelect<ExtArgs> | null
    /**
     * Omit specific fields from the User
     */
    omit?: UserOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: UserInclude<ExtArgs> | null
  }


  /**
   * Model RefreshToken
   */

  export type AggregateRefreshToken = {
    _count: RefreshTokenCountAggregateOutputType | null
    _min: RefreshTokenMinAggregateOutputType | null
    _max: RefreshTokenMaxAggregateOutputType | null
  }

  export type RefreshTokenMinAggregateOutputType = {
    id: string | null
    userId: string | null
    tokenHash: string | null
    deviceId: string | null
    expiresAt: Date | null
    createdAt: Date | null
  }

  export type RefreshTokenMaxAggregateOutputType = {
    id: string | null
    userId: string | null
    tokenHash: string | null
    deviceId: string | null
    expiresAt: Date | null
    createdAt: Date | null
  }

  export type RefreshTokenCountAggregateOutputType = {
    id: number
    userId: number
    tokenHash: number
    deviceId: number
    expiresAt: number
    createdAt: number
    _all: number
  }


  export type RefreshTokenMinAggregateInputType = {
    id?: true
    userId?: true
    tokenHash?: true
    deviceId?: true
    expiresAt?: true
    createdAt?: true
  }

  export type RefreshTokenMaxAggregateInputType = {
    id?: true
    userId?: true
    tokenHash?: true
    deviceId?: true
    expiresAt?: true
    createdAt?: true
  }

  export type RefreshTokenCountAggregateInputType = {
    id?: true
    userId?: true
    tokenHash?: true
    deviceId?: true
    expiresAt?: true
    createdAt?: true
    _all?: true
  }

  export type RefreshTokenAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which RefreshToken to aggregate.
     */
    where?: RefreshTokenWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of RefreshTokens to fetch.
     */
    orderBy?: RefreshTokenOrderByWithRelationInput | RefreshTokenOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: RefreshTokenWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` RefreshTokens from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` RefreshTokens.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned RefreshTokens
    **/
    _count?: true | RefreshTokenCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: RefreshTokenMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: RefreshTokenMaxAggregateInputType
  }

  export type GetRefreshTokenAggregateType<T extends RefreshTokenAggregateArgs> = {
        [P in keyof T & keyof AggregateRefreshToken]: P extends '_count' | 'count'
      ? T[P] extends true
        ? number
        : GetScalarType<T[P], AggregateRefreshToken[P]>
      : GetScalarType<T[P], AggregateRefreshToken[P]>
  }




  export type RefreshTokenGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: RefreshTokenWhereInput
    orderBy?: RefreshTokenOrderByWithAggregationInput | RefreshTokenOrderByWithAggregationInput[]
    by: RefreshTokenScalarFieldEnum[] | RefreshTokenScalarFieldEnum
    having?: RefreshTokenScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: RefreshTokenCountAggregateInputType | true
    _min?: RefreshTokenMinAggregateInputType
    _max?: RefreshTokenMaxAggregateInputType
  }

  export type RefreshTokenGroupByOutputType = {
    id: string
    userId: string
    tokenHash: string
    deviceId: string | null
    expiresAt: Date
    createdAt: Date
    _count: RefreshTokenCountAggregateOutputType | null
    _min: RefreshTokenMinAggregateOutputType | null
    _max: RefreshTokenMaxAggregateOutputType | null
  }

  type GetRefreshTokenGroupByPayload<T extends RefreshTokenGroupByArgs> = Prisma.PrismaPromise<
    Array<
      PickEnumerable<RefreshTokenGroupByOutputType, T['by']> &
        {
          [P in ((keyof T) & (keyof RefreshTokenGroupByOutputType))]: P extends '_count'
            ? T[P] extends boolean
              ? number
              : GetScalarType<T[P], RefreshTokenGroupByOutputType[P]>
            : GetScalarType<T[P], RefreshTokenGroupByOutputType[P]>
        }
      >
    >


  export type RefreshTokenSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    userId?: boolean
    tokenHash?: boolean
    deviceId?: boolean
    expiresAt?: boolean
    createdAt?: boolean
    user?: boolean | UserDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["refreshToken"]>

  export type RefreshTokenSelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    userId?: boolean
    tokenHash?: boolean
    deviceId?: boolean
    expiresAt?: boolean
    createdAt?: boolean
    user?: boolean | UserDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["refreshToken"]>

  export type RefreshTokenSelectUpdateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    userId?: boolean
    tokenHash?: boolean
    deviceId?: boolean
    expiresAt?: boolean
    createdAt?: boolean
    user?: boolean | UserDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["refreshToken"]>

  export type RefreshTokenSelectScalar = {
    id?: boolean
    userId?: boolean
    tokenHash?: boolean
    deviceId?: boolean
    expiresAt?: boolean
    createdAt?: boolean
  }

  export type RefreshTokenOmit<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetOmit<"id" | "userId" | "tokenHash" | "deviceId" | "expiresAt" | "createdAt", ExtArgs["result"]["refreshToken"]>
  export type RefreshTokenInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    user?: boolean | UserDefaultArgs<ExtArgs>
  }
  export type RefreshTokenIncludeCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    user?: boolean | UserDefaultArgs<ExtArgs>
  }
  export type RefreshTokenIncludeUpdateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    user?: boolean | UserDefaultArgs<ExtArgs>
  }

  export type $RefreshTokenPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "RefreshToken"
    objects: {
      user: Prisma.$UserPayload<ExtArgs>
    }
    scalars: $Extensions.GetPayloadResult<{
      id: string
      userId: string
      tokenHash: string
      deviceId: string | null
      expiresAt: Date
      createdAt: Date
    }, ExtArgs["result"]["refreshToken"]>
    composites: {}
  }

  type RefreshTokenGetPayload<S extends boolean | null | undefined | RefreshTokenDefaultArgs> = $Result.GetResult<Prisma.$RefreshTokenPayload, S>

  type RefreshTokenCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
    Omit<RefreshTokenFindManyArgs, 'select' | 'include' | 'distinct' | 'omit'> & {
      select?: RefreshTokenCountAggregateInputType | true
    }

  export interface RefreshTokenDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs, GlobalOmitOptions = {}> {
    [K: symbol]: { types: Prisma.TypeMap<ExtArgs>['model']['RefreshToken'], meta: { name: 'RefreshToken' } }
    /**
     * Find zero or one RefreshToken that matches the filter.
     * @param {RefreshTokenFindUniqueArgs} args - Arguments to find a RefreshToken
     * @example
     * // Get one RefreshToken
     * const refreshToken = await prisma.refreshToken.findUnique({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findUnique<T extends RefreshTokenFindUniqueArgs>(args: SelectSubset<T, RefreshTokenFindUniqueArgs<ExtArgs>>): Prisma__RefreshTokenClient<$Result.GetResult<Prisma.$RefreshTokenPayload<ExtArgs>, T, "findUnique", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>

    /**
     * Find one RefreshToken that matches the filter or throw an error with `error.code='P2025'`
     * if no matches were found.
     * @param {RefreshTokenFindUniqueOrThrowArgs} args - Arguments to find a RefreshToken
     * @example
     * // Get one RefreshToken
     * const refreshToken = await prisma.refreshToken.findUniqueOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findUniqueOrThrow<T extends RefreshTokenFindUniqueOrThrowArgs>(args: SelectSubset<T, RefreshTokenFindUniqueOrThrowArgs<ExtArgs>>): Prisma__RefreshTokenClient<$Result.GetResult<Prisma.$RefreshTokenPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Find the first RefreshToken that matches the filter.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {RefreshTokenFindFirstArgs} args - Arguments to find a RefreshToken
     * @example
     * // Get one RefreshToken
     * const refreshToken = await prisma.refreshToken.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends RefreshTokenFindFirstArgs>(args?: SelectSubset<T, RefreshTokenFindFirstArgs<ExtArgs>>): Prisma__RefreshTokenClient<$Result.GetResult<Prisma.$RefreshTokenPayload<ExtArgs>, T, "findFirst", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>

    /**
     * Find the first RefreshToken that matches the filter or
     * throw `PrismaKnownClientError` with `P2025` code if no matches were found.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {RefreshTokenFindFirstOrThrowArgs} args - Arguments to find a RefreshToken
     * @example
     * // Get one RefreshToken
     * const refreshToken = await prisma.refreshToken.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends RefreshTokenFindFirstOrThrowArgs>(args?: SelectSubset<T, RefreshTokenFindFirstOrThrowArgs<ExtArgs>>): Prisma__RefreshTokenClient<$Result.GetResult<Prisma.$RefreshTokenPayload<ExtArgs>, T, "findFirstOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Find zero or more RefreshTokens that matches the filter.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {RefreshTokenFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all RefreshTokens
     * const refreshTokens = await prisma.refreshToken.findMany()
     * 
     * // Get first 10 RefreshTokens
     * const refreshTokens = await prisma.refreshToken.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const refreshTokenWithIdOnly = await prisma.refreshToken.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends RefreshTokenFindManyArgs>(args?: SelectSubset<T, RefreshTokenFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$RefreshTokenPayload<ExtArgs>, T, "findMany", GlobalOmitOptions>>

    /**
     * Create a RefreshToken.
     * @param {RefreshTokenCreateArgs} args - Arguments to create a RefreshToken.
     * @example
     * // Create one RefreshToken
     * const RefreshToken = await prisma.refreshToken.create({
     *   data: {
     *     // ... data to create a RefreshToken
     *   }
     * })
     * 
     */
    create<T extends RefreshTokenCreateArgs>(args: SelectSubset<T, RefreshTokenCreateArgs<ExtArgs>>): Prisma__RefreshTokenClient<$Result.GetResult<Prisma.$RefreshTokenPayload<ExtArgs>, T, "create", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Create many RefreshTokens.
     * @param {RefreshTokenCreateManyArgs} args - Arguments to create many RefreshTokens.
     * @example
     * // Create many RefreshTokens
     * const refreshToken = await prisma.refreshToken.createMany({
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     *     
     */
    createMany<T extends RefreshTokenCreateManyArgs>(args?: SelectSubset<T, RefreshTokenCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>

    /**
     * Create many RefreshTokens and returns the data saved in the database.
     * @param {RefreshTokenCreateManyAndReturnArgs} args - Arguments to create many RefreshTokens.
     * @example
     * // Create many RefreshTokens
     * const refreshToken = await prisma.refreshToken.createManyAndReturn({
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * 
     * // Create many RefreshTokens and only return the `id`
     * const refreshTokenWithIdOnly = await prisma.refreshToken.createManyAndReturn({
     *   select: { id: true },
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * 
     */
    createManyAndReturn<T extends RefreshTokenCreateManyAndReturnArgs>(args?: SelectSubset<T, RefreshTokenCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$RefreshTokenPayload<ExtArgs>, T, "createManyAndReturn", GlobalOmitOptions>>

    /**
     * Delete a RefreshToken.
     * @param {RefreshTokenDeleteArgs} args - Arguments to delete one RefreshToken.
     * @example
     * // Delete one RefreshToken
     * const RefreshToken = await prisma.refreshToken.delete({
     *   where: {
     *     // ... filter to delete one RefreshToken
     *   }
     * })
     * 
     */
    delete<T extends RefreshTokenDeleteArgs>(args: SelectSubset<T, RefreshTokenDeleteArgs<ExtArgs>>): Prisma__RefreshTokenClient<$Result.GetResult<Prisma.$RefreshTokenPayload<ExtArgs>, T, "delete", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Update one RefreshToken.
     * @param {RefreshTokenUpdateArgs} args - Arguments to update one RefreshToken.
     * @example
     * // Update one RefreshToken
     * const refreshToken = await prisma.refreshToken.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends RefreshTokenUpdateArgs>(args: SelectSubset<T, RefreshTokenUpdateArgs<ExtArgs>>): Prisma__RefreshTokenClient<$Result.GetResult<Prisma.$RefreshTokenPayload<ExtArgs>, T, "update", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Delete zero or more RefreshTokens.
     * @param {RefreshTokenDeleteManyArgs} args - Arguments to filter RefreshTokens to delete.
     * @example
     * // Delete a few RefreshTokens
     * const { count } = await prisma.refreshToken.deleteMany({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     * 
     */
    deleteMany<T extends RefreshTokenDeleteManyArgs>(args?: SelectSubset<T, RefreshTokenDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>

    /**
     * Update zero or more RefreshTokens.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {RefreshTokenUpdateManyArgs} args - Arguments to update one or more rows.
     * @example
     * // Update many RefreshTokens
     * const refreshToken = await prisma.refreshToken.updateMany({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    updateMany<T extends RefreshTokenUpdateManyArgs>(args: SelectSubset<T, RefreshTokenUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>

    /**
     * Update zero or more RefreshTokens and returns the data updated in the database.
     * @param {RefreshTokenUpdateManyAndReturnArgs} args - Arguments to update many RefreshTokens.
     * @example
     * // Update many RefreshTokens
     * const refreshToken = await prisma.refreshToken.updateManyAndReturn({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * 
     * // Update zero or more RefreshTokens and only return the `id`
     * const refreshTokenWithIdOnly = await prisma.refreshToken.updateManyAndReturn({
     *   select: { id: true },
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * 
     */
    updateManyAndReturn<T extends RefreshTokenUpdateManyAndReturnArgs>(args: SelectSubset<T, RefreshTokenUpdateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$RefreshTokenPayload<ExtArgs>, T, "updateManyAndReturn", GlobalOmitOptions>>

    /**
     * Create or update one RefreshToken.
     * @param {RefreshTokenUpsertArgs} args - Arguments to update or create a RefreshToken.
     * @example
     * // Update or create a RefreshToken
     * const refreshToken = await prisma.refreshToken.upsert({
     *   create: {
     *     // ... data to create a RefreshToken
     *   },
     *   update: {
     *     // ... in case it already exists, update
     *   },
     *   where: {
     *     // ... the filter for the RefreshToken we want to update
     *   }
     * })
     */
    upsert<T extends RefreshTokenUpsertArgs>(args: SelectSubset<T, RefreshTokenUpsertArgs<ExtArgs>>): Prisma__RefreshTokenClient<$Result.GetResult<Prisma.$RefreshTokenPayload<ExtArgs>, T, "upsert", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>


    /**
     * Count the number of RefreshTokens.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {RefreshTokenCountArgs} args - Arguments to filter RefreshTokens to count.
     * @example
     * // Count the number of RefreshTokens
     * const count = await prisma.refreshToken.count({
     *   where: {
     *     // ... the filter for the RefreshTokens we want to count
     *   }
     * })
    **/
    count<T extends RefreshTokenCountArgs>(
      args?: Subset<T, RefreshTokenCountArgs>,
    ): Prisma.PrismaPromise<
      T extends $Utils.Record<'select', any>
        ? T['select'] extends true
          ? number
          : GetScalarType<T['select'], RefreshTokenCountAggregateOutputType>
        : number
    >

    /**
     * Allows you to perform aggregations operations on a RefreshToken.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {RefreshTokenAggregateArgs} args - Select which aggregations you would like to apply and on what fields.
     * @example
     * // Ordered by age ascending
     * // Where email contains prisma.io
     * // Limited to the 10 users
     * const aggregations = await prisma.user.aggregate({
     *   _avg: {
     *     age: true,
     *   },
     *   where: {
     *     email: {
     *       contains: "prisma.io",
     *     },
     *   },
     *   orderBy: {
     *     age: "asc",
     *   },
     *   take: 10,
     * })
    **/
    aggregate<T extends RefreshTokenAggregateArgs>(args: Subset<T, RefreshTokenAggregateArgs>): Prisma.PrismaPromise<GetRefreshTokenAggregateType<T>>

    /**
     * Group by RefreshToken.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {RefreshTokenGroupByArgs} args - Group by arguments.
     * @example
     * // Group by city, order by createdAt, get count
     * const result = await prisma.user.groupBy({
     *   by: ['city', 'createdAt'],
     *   orderBy: {
     *     createdAt: true
     *   },
     *   _count: {
     *     _all: true
     *   },
     * })
     * 
    **/
    groupBy<
      T extends RefreshTokenGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: RefreshTokenGroupByArgs['orderBy'] }
        : { orderBy?: RefreshTokenGroupByArgs['orderBy'] },
      OrderFields extends ExcludeUnderscoreKeys<Keys<MaybeTupleToUnion<T['orderBy']>>>,
      ByFields extends MaybeTupleToUnion<T['by']>,
      ByValid extends Has<ByFields, OrderFields>,
      HavingFields extends GetHavingFields<T['having']>,
      HavingValid extends Has<ByFields, HavingFields>,
      ByEmpty extends T['by'] extends never[] ? True : False,
      InputErrors extends ByEmpty extends True
      ? `Error: "by" must not be empty.`
      : HavingValid extends False
      ? {
          [P in HavingFields]: P extends ByFields
            ? never
            : P extends string
            ? `Error: Field "${P}" used in "having" needs to be provided in "by".`
            : [
                Error,
                'Field ',
                P,
                ` in "having" needs to be provided in "by"`,
              ]
        }[HavingFields]
      : 'take' extends Keys<T>
      ? 'orderBy' extends Keys<T>
        ? ByValid extends True
          ? {}
          : {
              [P in OrderFields]: P extends ByFields
                ? never
                : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
            }[OrderFields]
        : 'Error: If you provide "take", you also need to provide "orderBy"'
      : 'skip' extends Keys<T>
      ? 'orderBy' extends Keys<T>
        ? ByValid extends True
          ? {}
          : {
              [P in OrderFields]: P extends ByFields
                ? never
                : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
            }[OrderFields]
        : 'Error: If you provide "skip", you also need to provide "orderBy"'
      : ByValid extends True
      ? {}
      : {
          [P in OrderFields]: P extends ByFields
            ? never
            : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
        }[OrderFields]
    >(args: SubsetIntersection<T, RefreshTokenGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetRefreshTokenGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the RefreshToken model
   */
  readonly fields: RefreshTokenFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for RefreshToken.
   * Why is this prefixed with `Prisma__`?
   * Because we want to prevent naming conflicts as mentioned in
   * https://github.com/prisma/prisma-client-js/issues/707
   */
  export interface Prisma__RefreshTokenClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs, GlobalOmitOptions = {}> extends Prisma.PrismaPromise<T> {
    readonly [Symbol.toStringTag]: "PrismaPromise"
    user<T extends UserDefaultArgs<ExtArgs> = {}>(args?: Subset<T, UserDefaultArgs<ExtArgs>>): Prisma__UserClient<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | Null, Null, ExtArgs, GlobalOmitOptions>
    /**
     * Attaches callbacks for the resolution and/or rejection of the Promise.
     * @param onfulfilled The callback to execute when the Promise is resolved.
     * @param onrejected The callback to execute when the Promise is rejected.
     * @returns A Promise for the completion of which ever callback is executed.
     */
    then<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): $Utils.JsPromise<TResult1 | TResult2>
    /**
     * Attaches a callback for only the rejection of the Promise.
     * @param onrejected The callback to execute when the Promise is rejected.
     * @returns A Promise for the completion of the callback.
     */
    catch<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): $Utils.JsPromise<T | TResult>
    /**
     * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The
     * resolved value cannot be modified from the callback.
     * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected).
     * @returns A Promise for the completion of the callback.
     */
    finally(onfinally?: (() => void) | undefined | null): $Utils.JsPromise<T>
  }




  /**
   * Fields of the RefreshToken model
   */
  interface RefreshTokenFieldRefs {
    readonly id: FieldRef<"RefreshToken", 'String'>
    readonly userId: FieldRef<"RefreshToken", 'String'>
    readonly tokenHash: FieldRef<"RefreshToken", 'String'>
    readonly deviceId: FieldRef<"RefreshToken", 'String'>
    readonly expiresAt: FieldRef<"RefreshToken", 'DateTime'>
    readonly createdAt: FieldRef<"RefreshToken", 'DateTime'>
  }
    

  // Custom InputTypes
  /**
   * RefreshToken findUnique
   */
  export type RefreshTokenFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the RefreshToken
     */
    select?: RefreshTokenSelect<ExtArgs> | null
    /**
     * Omit specific fields from the RefreshToken
     */
    omit?: RefreshTokenOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: RefreshTokenInclude<ExtArgs> | null
    /**
     * Filter, which RefreshToken to fetch.
     */
    where: RefreshTokenWhereUniqueInput
  }

  /**
   * RefreshToken findUniqueOrThrow
   */
  export type RefreshTokenFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the RefreshToken
     */
    select?: RefreshTokenSelect<ExtArgs> | null
    /**
     * Omit specific fields from the RefreshToken
     */
    omit?: RefreshTokenOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: RefreshTokenInclude<ExtArgs> | null
    /**
     * Filter, which RefreshToken to fetch.
     */
    where: RefreshTokenWhereUniqueInput
  }

  /**
   * RefreshToken findFirst
   */
  export type RefreshTokenFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the RefreshToken
     */
    select?: RefreshTokenSelect<ExtArgs> | null
    /**
     * Omit specific fields from the RefreshToken
     */
    omit?: RefreshTokenOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: RefreshTokenInclude<ExtArgs> | null
    /**
     * Filter, which RefreshToken to fetch.
     */
    where?: RefreshTokenWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of RefreshTokens to fetch.
     */
    orderBy?: RefreshTokenOrderByWithRelationInput | RefreshTokenOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for RefreshTokens.
     */
    cursor?: RefreshTokenWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` RefreshTokens from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` RefreshTokens.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of RefreshTokens.
     */
    distinct?: RefreshTokenScalarFieldEnum | RefreshTokenScalarFieldEnum[]
  }

  /**
   * RefreshToken findFirstOrThrow
   */
  export type RefreshTokenFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the RefreshToken
     */
    select?: RefreshTokenSelect<ExtArgs> | null
    /**
     * Omit specific fields from the RefreshToken
     */
    omit?: RefreshTokenOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: RefreshTokenInclude<ExtArgs> | null
    /**
     * Filter, which RefreshToken to fetch.
     */
    where?: RefreshTokenWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of RefreshTokens to fetch.
     */
    orderBy?: RefreshTokenOrderByWithRelationInput | RefreshTokenOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for RefreshTokens.
     */
    cursor?: RefreshTokenWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` RefreshTokens from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` RefreshTokens.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of RefreshTokens.
     */
    distinct?: RefreshTokenScalarFieldEnum | RefreshTokenScalarFieldEnum[]
  }

  /**
   * RefreshToken findMany
   */
  export type RefreshTokenFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the RefreshToken
     */
    select?: RefreshTokenSelect<ExtArgs> | null
    /**
     * Omit specific fields from the RefreshToken
     */
    omit?: RefreshTokenOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: RefreshTokenInclude<ExtArgs> | null
    /**
     * Filter, which RefreshTokens to fetch.
     */
    where?: RefreshTokenWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of RefreshTokens to fetch.
     */
    orderBy?: RefreshTokenOrderByWithRelationInput | RefreshTokenOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing RefreshTokens.
     */
    cursor?: RefreshTokenWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` RefreshTokens from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` RefreshTokens.
     */
    skip?: number
    distinct?: RefreshTokenScalarFieldEnum | RefreshTokenScalarFieldEnum[]
  }

  /**
   * RefreshToken create
   */
  export type RefreshTokenCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the RefreshToken
     */
    select?: RefreshTokenSelect<ExtArgs> | null
    /**
     * Omit specific fields from the RefreshToken
     */
    omit?: RefreshTokenOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: RefreshTokenInclude<ExtArgs> | null
    /**
     * The data needed to create a RefreshToken.
     */
    data: XOR<RefreshTokenCreateInput, RefreshTokenUncheckedCreateInput>
  }

  /**
   * RefreshToken createMany
   */
  export type RefreshTokenCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many RefreshTokens.
     */
    data: RefreshTokenCreateManyInput | RefreshTokenCreateManyInput[]
  }

  /**
   * RefreshToken createManyAndReturn
   */
  export type RefreshTokenCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the RefreshToken
     */
    select?: RefreshTokenSelectCreateManyAndReturn<ExtArgs> | null
    /**
     * Omit specific fields from the RefreshToken
     */
    omit?: RefreshTokenOmit<ExtArgs> | null
    /**
     * The data used to create many RefreshTokens.
     */
    data: RefreshTokenCreateManyInput | RefreshTokenCreateManyInput[]
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: RefreshTokenIncludeCreateManyAndReturn<ExtArgs> | null
  }

  /**
   * RefreshToken update
   */
  export type RefreshTokenUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the RefreshToken
     */
    select?: RefreshTokenSelect<ExtArgs> | null
    /**
     * Omit specific fields from the RefreshToken
     */
    omit?: RefreshTokenOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: RefreshTokenInclude<ExtArgs> | null
    /**
     * The data needed to update a RefreshToken.
     */
    data: XOR<RefreshTokenUpdateInput, RefreshTokenUncheckedUpdateInput>
    /**
     * Choose, which RefreshToken to update.
     */
    where: RefreshTokenWhereUniqueInput
  }

  /**
   * RefreshToken updateMany
   */
  export type RefreshTokenUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update RefreshTokens.
     */
    data: XOR<RefreshTokenUpdateManyMutationInput, RefreshTokenUncheckedUpdateManyInput>
    /**
     * Filter which RefreshTokens to update
     */
    where?: RefreshTokenWhereInput
    /**
     * Limit how many RefreshTokens to update.
     */
    limit?: number
  }

  /**
   * RefreshToken updateManyAndReturn
   */
  export type RefreshTokenUpdateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the RefreshToken
     */
    select?: RefreshTokenSelectUpdateManyAndReturn<ExtArgs> | null
    /**
     * Omit specific fields from the RefreshToken
     */
    omit?: RefreshTokenOmit<ExtArgs> | null
    /**
     * The data used to update RefreshTokens.
     */
    data: XOR<RefreshTokenUpdateManyMutationInput, RefreshTokenUncheckedUpdateManyInput>
    /**
     * Filter which RefreshTokens to update
     */
    where?: RefreshTokenWhereInput
    /**
     * Limit how many RefreshTokens to update.
     */
    limit?: number
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: RefreshTokenIncludeUpdateManyAndReturn<ExtArgs> | null
  }

  /**
   * RefreshToken upsert
   */
  export type RefreshTokenUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the RefreshToken
     */
    select?: RefreshTokenSelect<ExtArgs> | null
    /**
     * Omit specific fields from the RefreshToken
     */
    omit?: RefreshTokenOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: RefreshTokenInclude<ExtArgs> | null
    /**
     * The filter to search for the RefreshToken to update in case it exists.
     */
    where: RefreshTokenWhereUniqueInput
    /**
     * In case the RefreshToken found by the `where` argument doesn't exist, create a new RefreshToken with this data.
     */
    create: XOR<RefreshTokenCreateInput, RefreshTokenUncheckedCreateInput>
    /**
     * In case the RefreshToken was found with the provided `where` argument, update it with this data.
     */
    update: XOR<RefreshTokenUpdateInput, RefreshTokenUncheckedUpdateInput>
  }

  /**
   * RefreshToken delete
   */
  export type RefreshTokenDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the RefreshToken
     */
    select?: RefreshTokenSelect<ExtArgs> | null
    /**
     * Omit specific fields from the RefreshToken
     */
    omit?: RefreshTokenOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: RefreshTokenInclude<ExtArgs> | null
    /**
     * Filter which RefreshToken to delete.
     */
    where: RefreshTokenWhereUniqueInput
  }

  /**
   * RefreshToken deleteMany
   */
  export type RefreshTokenDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which RefreshTokens to delete
     */
    where?: RefreshTokenWhereInput
    /**
     * Limit how many RefreshTokens to delete.
     */
    limit?: number
  }

  /**
   * RefreshToken without action
   */
  export type RefreshTokenDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the RefreshToken
     */
    select?: RefreshTokenSelect<ExtArgs> | null
    /**
     * Omit specific fields from the RefreshToken
     */
    omit?: RefreshTokenOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: RefreshTokenInclude<ExtArgs> | null
  }


  /**
   * Model PasswordResetToken
   */

  export type AggregatePasswordResetToken = {
    _count: PasswordResetTokenCountAggregateOutputType | null
    _min: PasswordResetTokenMinAggregateOutputType | null
    _max: PasswordResetTokenMaxAggregateOutputType | null
  }

  export type PasswordResetTokenMinAggregateOutputType = {
    id: string | null
    email: string | null
    tokenHash: string | null
    expiresAt: Date | null
    consumed: boolean | null
    createdAt: Date | null
  }

  export type PasswordResetTokenMaxAggregateOutputType = {
    id: string | null
    email: string | null
    tokenHash: string | null
    expiresAt: Date | null
    consumed: boolean | null
    createdAt: Date | null
  }

  export type PasswordResetTokenCountAggregateOutputType = {
    id: number
    email: number
    tokenHash: number
    expiresAt: number
    consumed: number
    createdAt: number
    _all: number
  }


  export type PasswordResetTokenMinAggregateInputType = {
    id?: true
    email?: true
    tokenHash?: true
    expiresAt?: true
    consumed?: true
    createdAt?: true
  }

  export type PasswordResetTokenMaxAggregateInputType = {
    id?: true
    email?: true
    tokenHash?: true
    expiresAt?: true
    consumed?: true
    createdAt?: true
  }

  export type PasswordResetTokenCountAggregateInputType = {
    id?: true
    email?: true
    tokenHash?: true
    expiresAt?: true
    consumed?: true
    createdAt?: true
    _all?: true
  }

  export type PasswordResetTokenAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which PasswordResetToken to aggregate.
     */
    where?: PasswordResetTokenWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of PasswordResetTokens to fetch.
     */
    orderBy?: PasswordResetTokenOrderByWithRelationInput | PasswordResetTokenOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: PasswordResetTokenWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` PasswordResetTokens from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` PasswordResetTokens.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned PasswordResetTokens
    **/
    _count?: true | PasswordResetTokenCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: PasswordResetTokenMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: PasswordResetTokenMaxAggregateInputType
  }

  export type GetPasswordResetTokenAggregateType<T extends PasswordResetTokenAggregateArgs> = {
        [P in keyof T & keyof AggregatePasswordResetToken]: P extends '_count' | 'count'
      ? T[P] extends true
        ? number
        : GetScalarType<T[P], AggregatePasswordResetToken[P]>
      : GetScalarType<T[P], AggregatePasswordResetToken[P]>
  }




  export type PasswordResetTokenGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: PasswordResetTokenWhereInput
    orderBy?: PasswordResetTokenOrderByWithAggregationInput | PasswordResetTokenOrderByWithAggregationInput[]
    by: PasswordResetTokenScalarFieldEnum[] | PasswordResetTokenScalarFieldEnum
    having?: PasswordResetTokenScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: PasswordResetTokenCountAggregateInputType | true
    _min?: PasswordResetTokenMinAggregateInputType
    _max?: PasswordResetTokenMaxAggregateInputType
  }

  export type PasswordResetTokenGroupByOutputType = {
    id: string
    email: string
    tokenHash: string
    expiresAt: Date
    consumed: boolean
    createdAt: Date
    _count: PasswordResetTokenCountAggregateOutputType | null
    _min: PasswordResetTokenMinAggregateOutputType | null
    _max: PasswordResetTokenMaxAggregateOutputType | null
  }

  type GetPasswordResetTokenGroupByPayload<T extends PasswordResetTokenGroupByArgs> = Prisma.PrismaPromise<
    Array<
      PickEnumerable<PasswordResetTokenGroupByOutputType, T['by']> &
        {
          [P in ((keyof T) & (keyof PasswordResetTokenGroupByOutputType))]: P extends '_count'
            ? T[P] extends boolean
              ? number
              : GetScalarType<T[P], PasswordResetTokenGroupByOutputType[P]>
            : GetScalarType<T[P], PasswordResetTokenGroupByOutputType[P]>
        }
      >
    >


  export type PasswordResetTokenSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    email?: boolean
    tokenHash?: boolean
    expiresAt?: boolean
    consumed?: boolean
    createdAt?: boolean
  }, ExtArgs["result"]["passwordResetToken"]>

  export type PasswordResetTokenSelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    email?: boolean
    tokenHash?: boolean
    expiresAt?: boolean
    consumed?: boolean
    createdAt?: boolean
  }, ExtArgs["result"]["passwordResetToken"]>

  export type PasswordResetTokenSelectUpdateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    email?: boolean
    tokenHash?: boolean
    expiresAt?: boolean
    consumed?: boolean
    createdAt?: boolean
  }, ExtArgs["result"]["passwordResetToken"]>

  export type PasswordResetTokenSelectScalar = {
    id?: boolean
    email?: boolean
    tokenHash?: boolean
    expiresAt?: boolean
    consumed?: boolean
    createdAt?: boolean
  }

  export type PasswordResetTokenOmit<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetOmit<"id" | "email" | "tokenHash" | "expiresAt" | "consumed" | "createdAt", ExtArgs["result"]["passwordResetToken"]>

  export type $PasswordResetTokenPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "PasswordResetToken"
    objects: {}
    scalars: $Extensions.GetPayloadResult<{
      id: string
      email: string
      tokenHash: string
      expiresAt: Date
      consumed: boolean
      createdAt: Date
    }, ExtArgs["result"]["passwordResetToken"]>
    composites: {}
  }

  type PasswordResetTokenGetPayload<S extends boolean | null | undefined | PasswordResetTokenDefaultArgs> = $Result.GetResult<Prisma.$PasswordResetTokenPayload, S>

  type PasswordResetTokenCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
    Omit<PasswordResetTokenFindManyArgs, 'select' | 'include' | 'distinct' | 'omit'> & {
      select?: PasswordResetTokenCountAggregateInputType | true
    }

  export interface PasswordResetTokenDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs, GlobalOmitOptions = {}> {
    [K: symbol]: { types: Prisma.TypeMap<ExtArgs>['model']['PasswordResetToken'], meta: { name: 'PasswordResetToken' } }
    /**
     * Find zero or one PasswordResetToken that matches the filter.
     * @param {PasswordResetTokenFindUniqueArgs} args - Arguments to find a PasswordResetToken
     * @example
     * // Get one PasswordResetToken
     * const passwordResetToken = await prisma.passwordResetToken.findUnique({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findUnique<T extends PasswordResetTokenFindUniqueArgs>(args: SelectSubset<T, PasswordResetTokenFindUniqueArgs<ExtArgs>>): Prisma__PasswordResetTokenClient<$Result.GetResult<Prisma.$PasswordResetTokenPayload<ExtArgs>, T, "findUnique", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>

    /**
     * Find one PasswordResetToken that matches the filter or throw an error with `error.code='P2025'`
     * if no matches were found.
     * @param {PasswordResetTokenFindUniqueOrThrowArgs} args - Arguments to find a PasswordResetToken
     * @example
     * // Get one PasswordResetToken
     * const passwordResetToken = await prisma.passwordResetToken.findUniqueOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findUniqueOrThrow<T extends PasswordResetTokenFindUniqueOrThrowArgs>(args: SelectSubset<T, PasswordResetTokenFindUniqueOrThrowArgs<ExtArgs>>): Prisma__PasswordResetTokenClient<$Result.GetResult<Prisma.$PasswordResetTokenPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Find the first PasswordResetToken that matches the filter.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {PasswordResetTokenFindFirstArgs} args - Arguments to find a PasswordResetToken
     * @example
     * // Get one PasswordResetToken
     * const passwordResetToken = await prisma.passwordResetToken.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends PasswordResetTokenFindFirstArgs>(args?: SelectSubset<T, PasswordResetTokenFindFirstArgs<ExtArgs>>): Prisma__PasswordResetTokenClient<$Result.GetResult<Prisma.$PasswordResetTokenPayload<ExtArgs>, T, "findFirst", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>

    /**
     * Find the first PasswordResetToken that matches the filter or
     * throw `PrismaKnownClientError` with `P2025` code if no matches were found.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {PasswordResetTokenFindFirstOrThrowArgs} args - Arguments to find a PasswordResetToken
     * @example
     * // Get one PasswordResetToken
     * const passwordResetToken = await prisma.passwordResetToken.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends PasswordResetTokenFindFirstOrThrowArgs>(args?: SelectSubset<T, PasswordResetTokenFindFirstOrThrowArgs<ExtArgs>>): Prisma__PasswordResetTokenClient<$Result.GetResult<Prisma.$PasswordResetTokenPayload<ExtArgs>, T, "findFirstOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Find zero or more PasswordResetTokens that matches the filter.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {PasswordResetTokenFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all PasswordResetTokens
     * const passwordResetTokens = await prisma.passwordResetToken.findMany()
     * 
     * // Get first 10 PasswordResetTokens
     * const passwordResetTokens = await prisma.passwordResetToken.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const passwordResetTokenWithIdOnly = await prisma.passwordResetToken.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends PasswordResetTokenFindManyArgs>(args?: SelectSubset<T, PasswordResetTokenFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$PasswordResetTokenPayload<ExtArgs>, T, "findMany", GlobalOmitOptions>>

    /**
     * Create a PasswordResetToken.
     * @param {PasswordResetTokenCreateArgs} args - Arguments to create a PasswordResetToken.
     * @example
     * // Create one PasswordResetToken
     * const PasswordResetToken = await prisma.passwordResetToken.create({
     *   data: {
     *     // ... data to create a PasswordResetToken
     *   }
     * })
     * 
     */
    create<T extends PasswordResetTokenCreateArgs>(args: SelectSubset<T, PasswordResetTokenCreateArgs<ExtArgs>>): Prisma__PasswordResetTokenClient<$Result.GetResult<Prisma.$PasswordResetTokenPayload<ExtArgs>, T, "create", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Create many PasswordResetTokens.
     * @param {PasswordResetTokenCreateManyArgs} args - Arguments to create many PasswordResetTokens.
     * @example
     * // Create many PasswordResetTokens
     * const passwordResetToken = await prisma.passwordResetToken.createMany({
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     *     
     */
    createMany<T extends PasswordResetTokenCreateManyArgs>(args?: SelectSubset<T, PasswordResetTokenCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>

    /**
     * Create many PasswordResetTokens and returns the data saved in the database.
     * @param {PasswordResetTokenCreateManyAndReturnArgs} args - Arguments to create many PasswordResetTokens.
     * @example
     * // Create many PasswordResetTokens
     * const passwordResetToken = await prisma.passwordResetToken.createManyAndReturn({
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * 
     * // Create many PasswordResetTokens and only return the `id`
     * const passwordResetTokenWithIdOnly = await prisma.passwordResetToken.createManyAndReturn({
     *   select: { id: true },
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * 
     */
    createManyAndReturn<T extends PasswordResetTokenCreateManyAndReturnArgs>(args?: SelectSubset<T, PasswordResetTokenCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$PasswordResetTokenPayload<ExtArgs>, T, "createManyAndReturn", GlobalOmitOptions>>

    /**
     * Delete a PasswordResetToken.
     * @param {PasswordResetTokenDeleteArgs} args - Arguments to delete one PasswordResetToken.
     * @example
     * // Delete one PasswordResetToken
     * const PasswordResetToken = await prisma.passwordResetToken.delete({
     *   where: {
     *     // ... filter to delete one PasswordResetToken
     *   }
     * })
     * 
     */
    delete<T extends PasswordResetTokenDeleteArgs>(args: SelectSubset<T, PasswordResetTokenDeleteArgs<ExtArgs>>): Prisma__PasswordResetTokenClient<$Result.GetResult<Prisma.$PasswordResetTokenPayload<ExtArgs>, T, "delete", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Update one PasswordResetToken.
     * @param {PasswordResetTokenUpdateArgs} args - Arguments to update one PasswordResetToken.
     * @example
     * // Update one PasswordResetToken
     * const passwordResetToken = await prisma.passwordResetToken.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends PasswordResetTokenUpdateArgs>(args: SelectSubset<T, PasswordResetTokenUpdateArgs<ExtArgs>>): Prisma__PasswordResetTokenClient<$Result.GetResult<Prisma.$PasswordResetTokenPayload<ExtArgs>, T, "update", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Delete zero or more PasswordResetTokens.
     * @param {PasswordResetTokenDeleteManyArgs} args - Arguments to filter PasswordResetTokens to delete.
     * @example
     * // Delete a few PasswordResetTokens
     * const { count } = await prisma.passwordResetToken.deleteMany({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     * 
     */
    deleteMany<T extends PasswordResetTokenDeleteManyArgs>(args?: SelectSubset<T, PasswordResetTokenDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>

    /**
     * Update zero or more PasswordResetTokens.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {PasswordResetTokenUpdateManyArgs} args - Arguments to update one or more rows.
     * @example
     * // Update many PasswordResetTokens
     * const passwordResetToken = await prisma.passwordResetToken.updateMany({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    updateMany<T extends PasswordResetTokenUpdateManyArgs>(args: SelectSubset<T, PasswordResetTokenUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>

    /**
     * Update zero or more PasswordResetTokens and returns the data updated in the database.
     * @param {PasswordResetTokenUpdateManyAndReturnArgs} args - Arguments to update many PasswordResetTokens.
     * @example
     * // Update many PasswordResetTokens
     * const passwordResetToken = await prisma.passwordResetToken.updateManyAndReturn({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * 
     * // Update zero or more PasswordResetTokens and only return the `id`
     * const passwordResetTokenWithIdOnly = await prisma.passwordResetToken.updateManyAndReturn({
     *   select: { id: true },
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * 
     */
    updateManyAndReturn<T extends PasswordResetTokenUpdateManyAndReturnArgs>(args: SelectSubset<T, PasswordResetTokenUpdateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$PasswordResetTokenPayload<ExtArgs>, T, "updateManyAndReturn", GlobalOmitOptions>>

    /**
     * Create or update one PasswordResetToken.
     * @param {PasswordResetTokenUpsertArgs} args - Arguments to update or create a PasswordResetToken.
     * @example
     * // Update or create a PasswordResetToken
     * const passwordResetToken = await prisma.passwordResetToken.upsert({
     *   create: {
     *     // ... data to create a PasswordResetToken
     *   },
     *   update: {
     *     // ... in case it already exists, update
     *   },
     *   where: {
     *     // ... the filter for the PasswordResetToken we want to update
     *   }
     * })
     */
    upsert<T extends PasswordResetTokenUpsertArgs>(args: SelectSubset<T, PasswordResetTokenUpsertArgs<ExtArgs>>): Prisma__PasswordResetTokenClient<$Result.GetResult<Prisma.$PasswordResetTokenPayload<ExtArgs>, T, "upsert", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>


    /**
     * Count the number of PasswordResetTokens.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {PasswordResetTokenCountArgs} args - Arguments to filter PasswordResetTokens to count.
     * @example
     * // Count the number of PasswordResetTokens
     * const count = await prisma.passwordResetToken.count({
     *   where: {
     *     // ... the filter for the PasswordResetTokens we want to count
     *   }
     * })
    **/
    count<T extends PasswordResetTokenCountArgs>(
      args?: Subset<T, PasswordResetTokenCountArgs>,
    ): Prisma.PrismaPromise<
      T extends $Utils.Record<'select', any>
        ? T['select'] extends true
          ? number
          : GetScalarType<T['select'], PasswordResetTokenCountAggregateOutputType>
        : number
    >

    /**
     * Allows you to perform aggregations operations on a PasswordResetToken.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {PasswordResetTokenAggregateArgs} args - Select which aggregations you would like to apply and on what fields.
     * @example
     * // Ordered by age ascending
     * // Where email contains prisma.io
     * // Limited to the 10 users
     * const aggregations = await prisma.user.aggregate({
     *   _avg: {
     *     age: true,
     *   },
     *   where: {
     *     email: {
     *       contains: "prisma.io",
     *     },
     *   },
     *   orderBy: {
     *     age: "asc",
     *   },
     *   take: 10,
     * })
    **/
    aggregate<T extends PasswordResetTokenAggregateArgs>(args: Subset<T, PasswordResetTokenAggregateArgs>): Prisma.PrismaPromise<GetPasswordResetTokenAggregateType<T>>

    /**
     * Group by PasswordResetToken.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {PasswordResetTokenGroupByArgs} args - Group by arguments.
     * @example
     * // Group by city, order by createdAt, get count
     * const result = await prisma.user.groupBy({
     *   by: ['city', 'createdAt'],
     *   orderBy: {
     *     createdAt: true
     *   },
     *   _count: {
     *     _all: true
     *   },
     * })
     * 
    **/
    groupBy<
      T extends PasswordResetTokenGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: PasswordResetTokenGroupByArgs['orderBy'] }
        : { orderBy?: PasswordResetTokenGroupByArgs['orderBy'] },
      OrderFields extends ExcludeUnderscoreKeys<Keys<MaybeTupleToUnion<T['orderBy']>>>,
      ByFields extends MaybeTupleToUnion<T['by']>,
      ByValid extends Has<ByFields, OrderFields>,
      HavingFields extends GetHavingFields<T['having']>,
      HavingValid extends Has<ByFields, HavingFields>,
      ByEmpty extends T['by'] extends never[] ? True : False,
      InputErrors extends ByEmpty extends True
      ? `Error: "by" must not be empty.`
      : HavingValid extends False
      ? {
          [P in HavingFields]: P extends ByFields
            ? never
            : P extends string
            ? `Error: Field "${P}" used in "having" needs to be provided in "by".`
            : [
                Error,
                'Field ',
                P,
                ` in "having" needs to be provided in "by"`,
              ]
        }[HavingFields]
      : 'take' extends Keys<T>
      ? 'orderBy' extends Keys<T>
        ? ByValid extends True
          ? {}
          : {
              [P in OrderFields]: P extends ByFields
                ? never
                : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
            }[OrderFields]
        : 'Error: If you provide "take", you also need to provide "orderBy"'
      : 'skip' extends Keys<T>
      ? 'orderBy' extends Keys<T>
        ? ByValid extends True
          ? {}
          : {
              [P in OrderFields]: P extends ByFields
                ? never
                : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
            }[OrderFields]
        : 'Error: If you provide "skip", you also need to provide "orderBy"'
      : ByValid extends True
      ? {}
      : {
          [P in OrderFields]: P extends ByFields
            ? never
            : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
        }[OrderFields]
    >(args: SubsetIntersection<T, PasswordResetTokenGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetPasswordResetTokenGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the PasswordResetToken model
   */
  readonly fields: PasswordResetTokenFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for PasswordResetToken.
   * Why is this prefixed with `Prisma__`?
   * Because we want to prevent naming conflicts as mentioned in
   * https://github.com/prisma/prisma-client-js/issues/707
   */
  export interface Prisma__PasswordResetTokenClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs, GlobalOmitOptions = {}> extends Prisma.PrismaPromise<T> {
    readonly [Symbol.toStringTag]: "PrismaPromise"
    /**
     * Attaches callbacks for the resolution and/or rejection of the Promise.
     * @param onfulfilled The callback to execute when the Promise is resolved.
     * @param onrejected The callback to execute when the Promise is rejected.
     * @returns A Promise for the completion of which ever callback is executed.
     */
    then<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): $Utils.JsPromise<TResult1 | TResult2>
    /**
     * Attaches a callback for only the rejection of the Promise.
     * @param onrejected The callback to execute when the Promise is rejected.
     * @returns A Promise for the completion of the callback.
     */
    catch<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): $Utils.JsPromise<T | TResult>
    /**
     * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The
     * resolved value cannot be modified from the callback.
     * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected).
     * @returns A Promise for the completion of the callback.
     */
    finally(onfinally?: (() => void) | undefined | null): $Utils.JsPromise<T>
  }




  /**
   * Fields of the PasswordResetToken model
   */
  interface PasswordResetTokenFieldRefs {
    readonly id: FieldRef<"PasswordResetToken", 'String'>
    readonly email: FieldRef<"PasswordResetToken", 'String'>
    readonly tokenHash: FieldRef<"PasswordResetToken", 'String'>
    readonly expiresAt: FieldRef<"PasswordResetToken", 'DateTime'>
    readonly consumed: FieldRef<"PasswordResetToken", 'Boolean'>
    readonly createdAt: FieldRef<"PasswordResetToken", 'DateTime'>
  }
    

  // Custom InputTypes
  /**
   * PasswordResetToken findUnique
   */
  export type PasswordResetTokenFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the PasswordResetToken
     */
    select?: PasswordResetTokenSelect<ExtArgs> | null
    /**
     * Omit specific fields from the PasswordResetToken
     */
    omit?: PasswordResetTokenOmit<ExtArgs> | null
    /**
     * Filter, which PasswordResetToken to fetch.
     */
    where: PasswordResetTokenWhereUniqueInput
  }

  /**
   * PasswordResetToken findUniqueOrThrow
   */
  export type PasswordResetTokenFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the PasswordResetToken
     */
    select?: PasswordResetTokenSelect<ExtArgs> | null
    /**
     * Omit specific fields from the PasswordResetToken
     */
    omit?: PasswordResetTokenOmit<ExtArgs> | null
    /**
     * Filter, which PasswordResetToken to fetch.
     */
    where: PasswordResetTokenWhereUniqueInput
  }

  /**
   * PasswordResetToken findFirst
   */
  export type PasswordResetTokenFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the PasswordResetToken
     */
    select?: PasswordResetTokenSelect<ExtArgs> | null
    /**
     * Omit specific fields from the PasswordResetToken
     */
    omit?: PasswordResetTokenOmit<ExtArgs> | null
    /**
     * Filter, which PasswordResetToken to fetch.
     */
    where?: PasswordResetTokenWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of PasswordResetTokens to fetch.
     */
    orderBy?: PasswordResetTokenOrderByWithRelationInput | PasswordResetTokenOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for PasswordResetTokens.
     */
    cursor?: PasswordResetTokenWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` PasswordResetTokens from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` PasswordResetTokens.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of PasswordResetTokens.
     */
    distinct?: PasswordResetTokenScalarFieldEnum | PasswordResetTokenScalarFieldEnum[]
  }

  /**
   * PasswordResetToken findFirstOrThrow
   */
  export type PasswordResetTokenFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the PasswordResetToken
     */
    select?: PasswordResetTokenSelect<ExtArgs> | null
    /**
     * Omit specific fields from the PasswordResetToken
     */
    omit?: PasswordResetTokenOmit<ExtArgs> | null
    /**
     * Filter, which PasswordResetToken to fetch.
     */
    where?: PasswordResetTokenWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of PasswordResetTokens to fetch.
     */
    orderBy?: PasswordResetTokenOrderByWithRelationInput | PasswordResetTokenOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for PasswordResetTokens.
     */
    cursor?: PasswordResetTokenWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` PasswordResetTokens from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` PasswordResetTokens.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of PasswordResetTokens.
     */
    distinct?: PasswordResetTokenScalarFieldEnum | PasswordResetTokenScalarFieldEnum[]
  }

  /**
   * PasswordResetToken findMany
   */
  export type PasswordResetTokenFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the PasswordResetToken
     */
    select?: PasswordResetTokenSelect<ExtArgs> | null
    /**
     * Omit specific fields from the PasswordResetToken
     */
    omit?: PasswordResetTokenOmit<ExtArgs> | null
    /**
     * Filter, which PasswordResetTokens to fetch.
     */
    where?: PasswordResetTokenWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of PasswordResetTokens to fetch.
     */
    orderBy?: PasswordResetTokenOrderByWithRelationInput | PasswordResetTokenOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing PasswordResetTokens.
     */
    cursor?: PasswordResetTokenWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` PasswordResetTokens from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` PasswordResetTokens.
     */
    skip?: number
    distinct?: PasswordResetTokenScalarFieldEnum | PasswordResetTokenScalarFieldEnum[]
  }

  /**
   * PasswordResetToken create
   */
  export type PasswordResetTokenCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the PasswordResetToken
     */
    select?: PasswordResetTokenSelect<ExtArgs> | null
    /**
     * Omit specific fields from the PasswordResetToken
     */
    omit?: PasswordResetTokenOmit<ExtArgs> | null
    /**
     * The data needed to create a PasswordResetToken.
     */
    data: XOR<PasswordResetTokenCreateInput, PasswordResetTokenUncheckedCreateInput>
  }

  /**
   * PasswordResetToken createMany
   */
  export type PasswordResetTokenCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many PasswordResetTokens.
     */
    data: PasswordResetTokenCreateManyInput | PasswordResetTokenCreateManyInput[]
  }

  /**
   * PasswordResetToken createManyAndReturn
   */
  export type PasswordResetTokenCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the PasswordResetToken
     */
    select?: PasswordResetTokenSelectCreateManyAndReturn<ExtArgs> | null
    /**
     * Omit specific fields from the PasswordResetToken
     */
    omit?: PasswordResetTokenOmit<ExtArgs> | null
    /**
     * The data used to create many PasswordResetTokens.
     */
    data: PasswordResetTokenCreateManyInput | PasswordResetTokenCreateManyInput[]
  }

  /**
   * PasswordResetToken update
   */
  export type PasswordResetTokenUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the PasswordResetToken
     */
    select?: PasswordResetTokenSelect<ExtArgs> | null
    /**
     * Omit specific fields from the PasswordResetToken
     */
    omit?: PasswordResetTokenOmit<ExtArgs> | null
    /**
     * The data needed to update a PasswordResetToken.
     */
    data: XOR<PasswordResetTokenUpdateInput, PasswordResetTokenUncheckedUpdateInput>
    /**
     * Choose, which PasswordResetToken to update.
     */
    where: PasswordResetTokenWhereUniqueInput
  }

  /**
   * PasswordResetToken updateMany
   */
  export type PasswordResetTokenUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update PasswordResetTokens.
     */
    data: XOR<PasswordResetTokenUpdateManyMutationInput, PasswordResetTokenUncheckedUpdateManyInput>
    /**
     * Filter which PasswordResetTokens to update
     */
    where?: PasswordResetTokenWhereInput
    /**
     * Limit how many PasswordResetTokens to update.
     */
    limit?: number
  }

  /**
   * PasswordResetToken updateManyAndReturn
   */
  export type PasswordResetTokenUpdateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the PasswordResetToken
     */
    select?: PasswordResetTokenSelectUpdateManyAndReturn<ExtArgs> | null
    /**
     * Omit specific fields from the PasswordResetToken
     */
    omit?: PasswordResetTokenOmit<ExtArgs> | null
    /**
     * The data used to update PasswordResetTokens.
     */
    data: XOR<PasswordResetTokenUpdateManyMutationInput, PasswordResetTokenUncheckedUpdateManyInput>
    /**
     * Filter which PasswordResetTokens to update
     */
    where?: PasswordResetTokenWhereInput
    /**
     * Limit how many PasswordResetTokens to update.
     */
    limit?: number
  }

  /**
   * PasswordResetToken upsert
   */
  export type PasswordResetTokenUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the PasswordResetToken
     */
    select?: PasswordResetTokenSelect<ExtArgs> | null
    /**
     * Omit specific fields from the PasswordResetToken
     */
    omit?: PasswordResetTokenOmit<ExtArgs> | null
    /**
     * The filter to search for the PasswordResetToken to update in case it exists.
     */
    where: PasswordResetTokenWhereUniqueInput
    /**
     * In case the PasswordResetToken found by the `where` argument doesn't exist, create a new PasswordResetToken with this data.
     */
    create: XOR<PasswordResetTokenCreateInput, PasswordResetTokenUncheckedCreateInput>
    /**
     * In case the PasswordResetToken was found with the provided `where` argument, update it with this data.
     */
    update: XOR<PasswordResetTokenUpdateInput, PasswordResetTokenUncheckedUpdateInput>
  }

  /**
   * PasswordResetToken delete
   */
  export type PasswordResetTokenDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the PasswordResetToken
     */
    select?: PasswordResetTokenSelect<ExtArgs> | null
    /**
     * Omit specific fields from the PasswordResetToken
     */
    omit?: PasswordResetTokenOmit<ExtArgs> | null
    /**
     * Filter which PasswordResetToken to delete.
     */
    where: PasswordResetTokenWhereUniqueInput
  }

  /**
   * PasswordResetToken deleteMany
   */
  export type PasswordResetTokenDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which PasswordResetTokens to delete
     */
    where?: PasswordResetTokenWhereInput
    /**
     * Limit how many PasswordResetTokens to delete.
     */
    limit?: number
  }

  /**
   * PasswordResetToken without action
   */
  export type PasswordResetTokenDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the PasswordResetToken
     */
    select?: PasswordResetTokenSelect<ExtArgs> | null
    /**
     * Omit specific fields from the PasswordResetToken
     */
    omit?: PasswordResetTokenOmit<ExtArgs> | null
  }


  /**
   * Model AuditLog
   */

  export type AggregateAuditLog = {
    _count: AuditLogCountAggregateOutputType | null
    _min: AuditLogMinAggregateOutputType | null
    _max: AuditLogMaxAggregateOutputType | null
  }

  export type AuditLogMinAggregateOutputType = {
    id: string | null
    actorUserId: string | null
    actorEmail: string | null
    action: string | null
    targetType: string | null
    targetId: string | null
    ipAddress: string | null
    userAgent: string | null
    createdAt: Date | null
  }

  export type AuditLogMaxAggregateOutputType = {
    id: string | null
    actorUserId: string | null
    actorEmail: string | null
    action: string | null
    targetType: string | null
    targetId: string | null
    ipAddress: string | null
    userAgent: string | null
    createdAt: Date | null
  }

  export type AuditLogCountAggregateOutputType = {
    id: number
    actorUserId: number
    actorEmail: number
    action: number
    targetType: number
    targetId: number
    metadata: number
    ipAddress: number
    userAgent: number
    createdAt: number
    _all: number
  }


  export type AuditLogMinAggregateInputType = {
    id?: true
    actorUserId?: true
    actorEmail?: true
    action?: true
    targetType?: true
    targetId?: true
    ipAddress?: true
    userAgent?: true
    createdAt?: true
  }

  export type AuditLogMaxAggregateInputType = {
    id?: true
    actorUserId?: true
    actorEmail?: true
    action?: true
    targetType?: true
    targetId?: true
    ipAddress?: true
    userAgent?: true
    createdAt?: true
  }

  export type AuditLogCountAggregateInputType = {
    id?: true
    actorUserId?: true
    actorEmail?: true
    action?: true
    targetType?: true
    targetId?: true
    metadata?: true
    ipAddress?: true
    userAgent?: true
    createdAt?: true
    _all?: true
  }

  export type AuditLogAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which AuditLog to aggregate.
     */
    where?: AuditLogWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of AuditLogs to fetch.
     */
    orderBy?: AuditLogOrderByWithRelationInput | AuditLogOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: AuditLogWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` AuditLogs from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` AuditLogs.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned AuditLogs
    **/
    _count?: true | AuditLogCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: AuditLogMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: AuditLogMaxAggregateInputType
  }

  export type GetAuditLogAggregateType<T extends AuditLogAggregateArgs> = {
        [P in keyof T & keyof AggregateAuditLog]: P extends '_count' | 'count'
      ? T[P] extends true
        ? number
        : GetScalarType<T[P], AggregateAuditLog[P]>
      : GetScalarType<T[P], AggregateAuditLog[P]>
  }




  export type AuditLogGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: AuditLogWhereInput
    orderBy?: AuditLogOrderByWithAggregationInput | AuditLogOrderByWithAggregationInput[]
    by: AuditLogScalarFieldEnum[] | AuditLogScalarFieldEnum
    having?: AuditLogScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: AuditLogCountAggregateInputType | true
    _min?: AuditLogMinAggregateInputType
    _max?: AuditLogMaxAggregateInputType
  }

  export type AuditLogGroupByOutputType = {
    id: string
    actorUserId: string | null
    actorEmail: string | null
    action: string
    targetType: string | null
    targetId: string | null
    metadata: JsonValue | null
    ipAddress: string | null
    userAgent: string | null
    createdAt: Date
    _count: AuditLogCountAggregateOutputType | null
    _min: AuditLogMinAggregateOutputType | null
    _max: AuditLogMaxAggregateOutputType | null
  }

  type GetAuditLogGroupByPayload<T extends AuditLogGroupByArgs> = Prisma.PrismaPromise<
    Array<
      PickEnumerable<AuditLogGroupByOutputType, T['by']> &
        {
          [P in ((keyof T) & (keyof AuditLogGroupByOutputType))]: P extends '_count'
            ? T[P] extends boolean
              ? number
              : GetScalarType<T[P], AuditLogGroupByOutputType[P]>
            : GetScalarType<T[P], AuditLogGroupByOutputType[P]>
        }
      >
    >


  export type AuditLogSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    actorUserId?: boolean
    actorEmail?: boolean
    action?: boolean
    targetType?: boolean
    targetId?: boolean
    metadata?: boolean
    ipAddress?: boolean
    userAgent?: boolean
    createdAt?: boolean
    actor?: boolean | AuditLog$actorArgs<ExtArgs>
  }, ExtArgs["result"]["auditLog"]>

  export type AuditLogSelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    actorUserId?: boolean
    actorEmail?: boolean
    action?: boolean
    targetType?: boolean
    targetId?: boolean
    metadata?: boolean
    ipAddress?: boolean
    userAgent?: boolean
    createdAt?: boolean
    actor?: boolean | AuditLog$actorArgs<ExtArgs>
  }, ExtArgs["result"]["auditLog"]>

  export type AuditLogSelectUpdateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    actorUserId?: boolean
    actorEmail?: boolean
    action?: boolean
    targetType?: boolean
    targetId?: boolean
    metadata?: boolean
    ipAddress?: boolean
    userAgent?: boolean
    createdAt?: boolean
    actor?: boolean | AuditLog$actorArgs<ExtArgs>
  }, ExtArgs["result"]["auditLog"]>

  export type AuditLogSelectScalar = {
    id?: boolean
    actorUserId?: boolean
    actorEmail?: boolean
    action?: boolean
    targetType?: boolean
    targetId?: boolean
    metadata?: boolean
    ipAddress?: boolean
    userAgent?: boolean
    createdAt?: boolean
  }

  export type AuditLogOmit<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetOmit<"id" | "actorUserId" | "actorEmail" | "action" | "targetType" | "targetId" | "metadata" | "ipAddress" | "userAgent" | "createdAt", ExtArgs["result"]["auditLog"]>
  export type AuditLogInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    actor?: boolean | AuditLog$actorArgs<ExtArgs>
  }
  export type AuditLogIncludeCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    actor?: boolean | AuditLog$actorArgs<ExtArgs>
  }
  export type AuditLogIncludeUpdateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    actor?: boolean | AuditLog$actorArgs<ExtArgs>
  }

  export type $AuditLogPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "AuditLog"
    objects: {
      actor: Prisma.$UserPayload<ExtArgs> | null
    }
    scalars: $Extensions.GetPayloadResult<{
      id: string
      actorUserId: string | null
      actorEmail: string | null
      action: string
      targetType: string | null
      targetId: string | null
      metadata: Prisma.JsonValue | null
      ipAddress: string | null
      userAgent: string | null
      createdAt: Date
    }, ExtArgs["result"]["auditLog"]>
    composites: {}
  }

  type AuditLogGetPayload<S extends boolean | null | undefined | AuditLogDefaultArgs> = $Result.GetResult<Prisma.$AuditLogPayload, S>

  type AuditLogCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
    Omit<AuditLogFindManyArgs, 'select' | 'include' | 'distinct' | 'omit'> & {
      select?: AuditLogCountAggregateInputType | true
    }

  export interface AuditLogDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs, GlobalOmitOptions = {}> {
    [K: symbol]: { types: Prisma.TypeMap<ExtArgs>['model']['AuditLog'], meta: { name: 'AuditLog' } }
    /**
     * Find zero or one AuditLog that matches the filter.
     * @param {AuditLogFindUniqueArgs} args - Arguments to find a AuditLog
     * @example
     * // Get one AuditLog
     * const auditLog = await prisma.auditLog.findUnique({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findUnique<T extends AuditLogFindUniqueArgs>(args: SelectSubset<T, AuditLogFindUniqueArgs<ExtArgs>>): Prisma__AuditLogClient<$Result.GetResult<Prisma.$AuditLogPayload<ExtArgs>, T, "findUnique", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>

    /**
     * Find one AuditLog that matches the filter or throw an error with `error.code='P2025'`
     * if no matches were found.
     * @param {AuditLogFindUniqueOrThrowArgs} args - Arguments to find a AuditLog
     * @example
     * // Get one AuditLog
     * const auditLog = await prisma.auditLog.findUniqueOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findUniqueOrThrow<T extends AuditLogFindUniqueOrThrowArgs>(args: SelectSubset<T, AuditLogFindUniqueOrThrowArgs<ExtArgs>>): Prisma__AuditLogClient<$Result.GetResult<Prisma.$AuditLogPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Find the first AuditLog that matches the filter.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {AuditLogFindFirstArgs} args - Arguments to find a AuditLog
     * @example
     * // Get one AuditLog
     * const auditLog = await prisma.auditLog.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends AuditLogFindFirstArgs>(args?: SelectSubset<T, AuditLogFindFirstArgs<ExtArgs>>): Prisma__AuditLogClient<$Result.GetResult<Prisma.$AuditLogPayload<ExtArgs>, T, "findFirst", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>

    /**
     * Find the first AuditLog that matches the filter or
     * throw `PrismaKnownClientError` with `P2025` code if no matches were found.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {AuditLogFindFirstOrThrowArgs} args - Arguments to find a AuditLog
     * @example
     * // Get one AuditLog
     * const auditLog = await prisma.auditLog.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends AuditLogFindFirstOrThrowArgs>(args?: SelectSubset<T, AuditLogFindFirstOrThrowArgs<ExtArgs>>): Prisma__AuditLogClient<$Result.GetResult<Prisma.$AuditLogPayload<ExtArgs>, T, "findFirstOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Find zero or more AuditLogs that matches the filter.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {AuditLogFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all AuditLogs
     * const auditLogs = await prisma.auditLog.findMany()
     * 
     * // Get first 10 AuditLogs
     * const auditLogs = await prisma.auditLog.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const auditLogWithIdOnly = await prisma.auditLog.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends AuditLogFindManyArgs>(args?: SelectSubset<T, AuditLogFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$AuditLogPayload<ExtArgs>, T, "findMany", GlobalOmitOptions>>

    /**
     * Create a AuditLog.
     * @param {AuditLogCreateArgs} args - Arguments to create a AuditLog.
     * @example
     * // Create one AuditLog
     * const AuditLog = await prisma.auditLog.create({
     *   data: {
     *     // ... data to create a AuditLog
     *   }
     * })
     * 
     */
    create<T extends AuditLogCreateArgs>(args: SelectSubset<T, AuditLogCreateArgs<ExtArgs>>): Prisma__AuditLogClient<$Result.GetResult<Prisma.$AuditLogPayload<ExtArgs>, T, "create", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Create many AuditLogs.
     * @param {AuditLogCreateManyArgs} args - Arguments to create many AuditLogs.
     * @example
     * // Create many AuditLogs
     * const auditLog = await prisma.auditLog.createMany({
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     *     
     */
    createMany<T extends AuditLogCreateManyArgs>(args?: SelectSubset<T, AuditLogCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>

    /**
     * Create many AuditLogs and returns the data saved in the database.
     * @param {AuditLogCreateManyAndReturnArgs} args - Arguments to create many AuditLogs.
     * @example
     * // Create many AuditLogs
     * const auditLog = await prisma.auditLog.createManyAndReturn({
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * 
     * // Create many AuditLogs and only return the `id`
     * const auditLogWithIdOnly = await prisma.auditLog.createManyAndReturn({
     *   select: { id: true },
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * 
     */
    createManyAndReturn<T extends AuditLogCreateManyAndReturnArgs>(args?: SelectSubset<T, AuditLogCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$AuditLogPayload<ExtArgs>, T, "createManyAndReturn", GlobalOmitOptions>>

    /**
     * Delete a AuditLog.
     * @param {AuditLogDeleteArgs} args - Arguments to delete one AuditLog.
     * @example
     * // Delete one AuditLog
     * const AuditLog = await prisma.auditLog.delete({
     *   where: {
     *     // ... filter to delete one AuditLog
     *   }
     * })
     * 
     */
    delete<T extends AuditLogDeleteArgs>(args: SelectSubset<T, AuditLogDeleteArgs<ExtArgs>>): Prisma__AuditLogClient<$Result.GetResult<Prisma.$AuditLogPayload<ExtArgs>, T, "delete", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Update one AuditLog.
     * @param {AuditLogUpdateArgs} args - Arguments to update one AuditLog.
     * @example
     * // Update one AuditLog
     * const auditLog = await prisma.auditLog.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends AuditLogUpdateArgs>(args: SelectSubset<T, AuditLogUpdateArgs<ExtArgs>>): Prisma__AuditLogClient<$Result.GetResult<Prisma.$AuditLogPayload<ExtArgs>, T, "update", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Delete zero or more AuditLogs.
     * @param {AuditLogDeleteManyArgs} args - Arguments to filter AuditLogs to delete.
     * @example
     * // Delete a few AuditLogs
     * const { count } = await prisma.auditLog.deleteMany({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     * 
     */
    deleteMany<T extends AuditLogDeleteManyArgs>(args?: SelectSubset<T, AuditLogDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>

    /**
     * Update zero or more AuditLogs.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {AuditLogUpdateManyArgs} args - Arguments to update one or more rows.
     * @example
     * // Update many AuditLogs
     * const auditLog = await prisma.auditLog.updateMany({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    updateMany<T extends AuditLogUpdateManyArgs>(args: SelectSubset<T, AuditLogUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>

    /**
     * Update zero or more AuditLogs and returns the data updated in the database.
     * @param {AuditLogUpdateManyAndReturnArgs} args - Arguments to update many AuditLogs.
     * @example
     * // Update many AuditLogs
     * const auditLog = await prisma.auditLog.updateManyAndReturn({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * 
     * // Update zero or more AuditLogs and only return the `id`
     * const auditLogWithIdOnly = await prisma.auditLog.updateManyAndReturn({
     *   select: { id: true },
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * 
     */
    updateManyAndReturn<T extends AuditLogUpdateManyAndReturnArgs>(args: SelectSubset<T, AuditLogUpdateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$AuditLogPayload<ExtArgs>, T, "updateManyAndReturn", GlobalOmitOptions>>

    /**
     * Create or update one AuditLog.
     * @param {AuditLogUpsertArgs} args - Arguments to update or create a AuditLog.
     * @example
     * // Update or create a AuditLog
     * const auditLog = await prisma.auditLog.upsert({
     *   create: {
     *     // ... data to create a AuditLog
     *   },
     *   update: {
     *     // ... in case it already exists, update
     *   },
     *   where: {
     *     // ... the filter for the AuditLog we want to update
     *   }
     * })
     */
    upsert<T extends AuditLogUpsertArgs>(args: SelectSubset<T, AuditLogUpsertArgs<ExtArgs>>): Prisma__AuditLogClient<$Result.GetResult<Prisma.$AuditLogPayload<ExtArgs>, T, "upsert", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>


    /**
     * Count the number of AuditLogs.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {AuditLogCountArgs} args - Arguments to filter AuditLogs to count.
     * @example
     * // Count the number of AuditLogs
     * const count = await prisma.auditLog.count({
     *   where: {
     *     // ... the filter for the AuditLogs we want to count
     *   }
     * })
    **/
    count<T extends AuditLogCountArgs>(
      args?: Subset<T, AuditLogCountArgs>,
    ): Prisma.PrismaPromise<
      T extends $Utils.Record<'select', any>
        ? T['select'] extends true
          ? number
          : GetScalarType<T['select'], AuditLogCountAggregateOutputType>
        : number
    >

    /**
     * Allows you to perform aggregations operations on a AuditLog.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {AuditLogAggregateArgs} args - Select which aggregations you would like to apply and on what fields.
     * @example
     * // Ordered by age ascending
     * // Where email contains prisma.io
     * // Limited to the 10 users
     * const aggregations = await prisma.user.aggregate({
     *   _avg: {
     *     age: true,
     *   },
     *   where: {
     *     email: {
     *       contains: "prisma.io",
     *     },
     *   },
     *   orderBy: {
     *     age: "asc",
     *   },
     *   take: 10,
     * })
    **/
    aggregate<T extends AuditLogAggregateArgs>(args: Subset<T, AuditLogAggregateArgs>): Prisma.PrismaPromise<GetAuditLogAggregateType<T>>

    /**
     * Group by AuditLog.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {AuditLogGroupByArgs} args - Group by arguments.
     * @example
     * // Group by city, order by createdAt, get count
     * const result = await prisma.user.groupBy({
     *   by: ['city', 'createdAt'],
     *   orderBy: {
     *     createdAt: true
     *   },
     *   _count: {
     *     _all: true
     *   },
     * })
     * 
    **/
    groupBy<
      T extends AuditLogGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: AuditLogGroupByArgs['orderBy'] }
        : { orderBy?: AuditLogGroupByArgs['orderBy'] },
      OrderFields extends ExcludeUnderscoreKeys<Keys<MaybeTupleToUnion<T['orderBy']>>>,
      ByFields extends MaybeTupleToUnion<T['by']>,
      ByValid extends Has<ByFields, OrderFields>,
      HavingFields extends GetHavingFields<T['having']>,
      HavingValid extends Has<ByFields, HavingFields>,
      ByEmpty extends T['by'] extends never[] ? True : False,
      InputErrors extends ByEmpty extends True
      ? `Error: "by" must not be empty.`
      : HavingValid extends False
      ? {
          [P in HavingFields]: P extends ByFields
            ? never
            : P extends string
            ? `Error: Field "${P}" used in "having" needs to be provided in "by".`
            : [
                Error,
                'Field ',
                P,
                ` in "having" needs to be provided in "by"`,
              ]
        }[HavingFields]
      : 'take' extends Keys<T>
      ? 'orderBy' extends Keys<T>
        ? ByValid extends True
          ? {}
          : {
              [P in OrderFields]: P extends ByFields
                ? never
                : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
            }[OrderFields]
        : 'Error: If you provide "take", you also need to provide "orderBy"'
      : 'skip' extends Keys<T>
      ? 'orderBy' extends Keys<T>
        ? ByValid extends True
          ? {}
          : {
              [P in OrderFields]: P extends ByFields
                ? never
                : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
            }[OrderFields]
        : 'Error: If you provide "skip", you also need to provide "orderBy"'
      : ByValid extends True
      ? {}
      : {
          [P in OrderFields]: P extends ByFields
            ? never
            : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
        }[OrderFields]
    >(args: SubsetIntersection<T, AuditLogGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetAuditLogGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the AuditLog model
   */
  readonly fields: AuditLogFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for AuditLog.
   * Why is this prefixed with `Prisma__`?
   * Because we want to prevent naming conflicts as mentioned in
   * https://github.com/prisma/prisma-client-js/issues/707
   */
  export interface Prisma__AuditLogClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs, GlobalOmitOptions = {}> extends Prisma.PrismaPromise<T> {
    readonly [Symbol.toStringTag]: "PrismaPromise"
    actor<T extends AuditLog$actorArgs<ExtArgs> = {}>(args?: Subset<T, AuditLog$actorArgs<ExtArgs>>): Prisma__UserClient<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>
    /**
     * Attaches callbacks for the resolution and/or rejection of the Promise.
     * @param onfulfilled The callback to execute when the Promise is resolved.
     * @param onrejected The callback to execute when the Promise is rejected.
     * @returns A Promise for the completion of which ever callback is executed.
     */
    then<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): $Utils.JsPromise<TResult1 | TResult2>
    /**
     * Attaches a callback for only the rejection of the Promise.
     * @param onrejected The callback to execute when the Promise is rejected.
     * @returns A Promise for the completion of the callback.
     */
    catch<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): $Utils.JsPromise<T | TResult>
    /**
     * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The
     * resolved value cannot be modified from the callback.
     * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected).
     * @returns A Promise for the completion of the callback.
     */
    finally(onfinally?: (() => void) | undefined | null): $Utils.JsPromise<T>
  }




  /**
   * Fields of the AuditLog model
   */
  interface AuditLogFieldRefs {
    readonly id: FieldRef<"AuditLog", 'String'>
    readonly actorUserId: FieldRef<"AuditLog", 'String'>
    readonly actorEmail: FieldRef<"AuditLog", 'String'>
    readonly action: FieldRef<"AuditLog", 'String'>
    readonly targetType: FieldRef<"AuditLog", 'String'>
    readonly targetId: FieldRef<"AuditLog", 'String'>
    readonly metadata: FieldRef<"AuditLog", 'Json'>
    readonly ipAddress: FieldRef<"AuditLog", 'String'>
    readonly userAgent: FieldRef<"AuditLog", 'String'>
    readonly createdAt: FieldRef<"AuditLog", 'DateTime'>
  }
    

  // Custom InputTypes
  /**
   * AuditLog findUnique
   */
  export type AuditLogFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the AuditLog
     */
    select?: AuditLogSelect<ExtArgs> | null
    /**
     * Omit specific fields from the AuditLog
     */
    omit?: AuditLogOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: AuditLogInclude<ExtArgs> | null
    /**
     * Filter, which AuditLog to fetch.
     */
    where: AuditLogWhereUniqueInput
  }

  /**
   * AuditLog findUniqueOrThrow
   */
  export type AuditLogFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the AuditLog
     */
    select?: AuditLogSelect<ExtArgs> | null
    /**
     * Omit specific fields from the AuditLog
     */
    omit?: AuditLogOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: AuditLogInclude<ExtArgs> | null
    /**
     * Filter, which AuditLog to fetch.
     */
    where: AuditLogWhereUniqueInput
  }

  /**
   * AuditLog findFirst
   */
  export type AuditLogFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the AuditLog
     */
    select?: AuditLogSelect<ExtArgs> | null
    /**
     * Omit specific fields from the AuditLog
     */
    omit?: AuditLogOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: AuditLogInclude<ExtArgs> | null
    /**
     * Filter, which AuditLog to fetch.
     */
    where?: AuditLogWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of AuditLogs to fetch.
     */
    orderBy?: AuditLogOrderByWithRelationInput | AuditLogOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for AuditLogs.
     */
    cursor?: AuditLogWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` AuditLogs from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` AuditLogs.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of AuditLogs.
     */
    distinct?: AuditLogScalarFieldEnum | AuditLogScalarFieldEnum[]
  }

  /**
   * AuditLog findFirstOrThrow
   */
  export type AuditLogFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the AuditLog
     */
    select?: AuditLogSelect<ExtArgs> | null
    /**
     * Omit specific fields from the AuditLog
     */
    omit?: AuditLogOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: AuditLogInclude<ExtArgs> | null
    /**
     * Filter, which AuditLog to fetch.
     */
    where?: AuditLogWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of AuditLogs to fetch.
     */
    orderBy?: AuditLogOrderByWithRelationInput | AuditLogOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for AuditLogs.
     */
    cursor?: AuditLogWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` AuditLogs from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` AuditLogs.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of AuditLogs.
     */
    distinct?: AuditLogScalarFieldEnum | AuditLogScalarFieldEnum[]
  }

  /**
   * AuditLog findMany
   */
  export type AuditLogFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the AuditLog
     */
    select?: AuditLogSelect<ExtArgs> | null
    /**
     * Omit specific fields from the AuditLog
     */
    omit?: AuditLogOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: AuditLogInclude<ExtArgs> | null
    /**
     * Filter, which AuditLogs to fetch.
     */
    where?: AuditLogWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of AuditLogs to fetch.
     */
    orderBy?: AuditLogOrderByWithRelationInput | AuditLogOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing AuditLogs.
     */
    cursor?: AuditLogWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` AuditLogs from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` AuditLogs.
     */
    skip?: number
    distinct?: AuditLogScalarFieldEnum | AuditLogScalarFieldEnum[]
  }

  /**
   * AuditLog create
   */
  export type AuditLogCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the AuditLog
     */
    select?: AuditLogSelect<ExtArgs> | null
    /**
     * Omit specific fields from the AuditLog
     */
    omit?: AuditLogOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: AuditLogInclude<ExtArgs> | null
    /**
     * The data needed to create a AuditLog.
     */
    data: XOR<AuditLogCreateInput, AuditLogUncheckedCreateInput>
  }

  /**
   * AuditLog createMany
   */
  export type AuditLogCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many AuditLogs.
     */
    data: AuditLogCreateManyInput | AuditLogCreateManyInput[]
  }

  /**
   * AuditLog createManyAndReturn
   */
  export type AuditLogCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the AuditLog
     */
    select?: AuditLogSelectCreateManyAndReturn<ExtArgs> | null
    /**
     * Omit specific fields from the AuditLog
     */
    omit?: AuditLogOmit<ExtArgs> | null
    /**
     * The data used to create many AuditLogs.
     */
    data: AuditLogCreateManyInput | AuditLogCreateManyInput[]
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: AuditLogIncludeCreateManyAndReturn<ExtArgs> | null
  }

  /**
   * AuditLog update
   */
  export type AuditLogUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the AuditLog
     */
    select?: AuditLogSelect<ExtArgs> | null
    /**
     * Omit specific fields from the AuditLog
     */
    omit?: AuditLogOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: AuditLogInclude<ExtArgs> | null
    /**
     * The data needed to update a AuditLog.
     */
    data: XOR<AuditLogUpdateInput, AuditLogUncheckedUpdateInput>
    /**
     * Choose, which AuditLog to update.
     */
    where: AuditLogWhereUniqueInput
  }

  /**
   * AuditLog updateMany
   */
  export type AuditLogUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update AuditLogs.
     */
    data: XOR<AuditLogUpdateManyMutationInput, AuditLogUncheckedUpdateManyInput>
    /**
     * Filter which AuditLogs to update
     */
    where?: AuditLogWhereInput
    /**
     * Limit how many AuditLogs to update.
     */
    limit?: number
  }

  /**
   * AuditLog updateManyAndReturn
   */
  export type AuditLogUpdateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the AuditLog
     */
    select?: AuditLogSelectUpdateManyAndReturn<ExtArgs> | null
    /**
     * Omit specific fields from the AuditLog
     */
    omit?: AuditLogOmit<ExtArgs> | null
    /**
     * The data used to update AuditLogs.
     */
    data: XOR<AuditLogUpdateManyMutationInput, AuditLogUncheckedUpdateManyInput>
    /**
     * Filter which AuditLogs to update
     */
    where?: AuditLogWhereInput
    /**
     * Limit how many AuditLogs to update.
     */
    limit?: number
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: AuditLogIncludeUpdateManyAndReturn<ExtArgs> | null
  }

  /**
   * AuditLog upsert
   */
  export type AuditLogUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the AuditLog
     */
    select?: AuditLogSelect<ExtArgs> | null
    /**
     * Omit specific fields from the AuditLog
     */
    omit?: AuditLogOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: AuditLogInclude<ExtArgs> | null
    /**
     * The filter to search for the AuditLog to update in case it exists.
     */
    where: AuditLogWhereUniqueInput
    /**
     * In case the AuditLog found by the `where` argument doesn't exist, create a new AuditLog with this data.
     */
    create: XOR<AuditLogCreateInput, AuditLogUncheckedCreateInput>
    /**
     * In case the AuditLog was found with the provided `where` argument, update it with this data.
     */
    update: XOR<AuditLogUpdateInput, AuditLogUncheckedUpdateInput>
  }

  /**
   * AuditLog delete
   */
  export type AuditLogDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the AuditLog
     */
    select?: AuditLogSelect<ExtArgs> | null
    /**
     * Omit specific fields from the AuditLog
     */
    omit?: AuditLogOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: AuditLogInclude<ExtArgs> | null
    /**
     * Filter which AuditLog to delete.
     */
    where: AuditLogWhereUniqueInput
  }

  /**
   * AuditLog deleteMany
   */
  export type AuditLogDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which AuditLogs to delete
     */
    where?: AuditLogWhereInput
    /**
     * Limit how many AuditLogs to delete.
     */
    limit?: number
  }

  /**
   * AuditLog.actor
   */
  export type AuditLog$actorArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the User
     */
    select?: UserSelect<ExtArgs> | null
    /**
     * Omit specific fields from the User
     */
    omit?: UserOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: UserInclude<ExtArgs> | null
    where?: UserWhereInput
  }

  /**
   * AuditLog without action
   */
  export type AuditLogDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the AuditLog
     */
    select?: AuditLogSelect<ExtArgs> | null
    /**
     * Omit specific fields from the AuditLog
     */
    omit?: AuditLogOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: AuditLogInclude<ExtArgs> | null
  }


  /**
   * Model Trip
   */

  export type AggregateTrip = {
    _count: TripCountAggregateOutputType | null
    _avg: TripAvgAggregateOutputType | null
    _sum: TripSumAggregateOutputType | null
    _min: TripMinAggregateOutputType | null
    _max: TripMaxAggregateOutputType | null
  }

  export type TripAvgAggregateOutputType = {
    destinationLat: number | null
    destinationLng: number | null
    plannedDistance: number | null
    totalDistance: number | null
    travelDuration: number | null
    idleTime: number | null
    meetingDuration: number | null
    productivityScore: number | null
    tripEfficiency: number | null
  }

  export type TripSumAggregateOutputType = {
    destinationLat: number | null
    destinationLng: number | null
    plannedDistance: number | null
    totalDistance: number | null
    travelDuration: number | null
    idleTime: number | null
    meetingDuration: number | null
    productivityScore: number | null
    tripEfficiency: number | null
  }

  export type TripMinAggregateOutputType = {
    id: string | null
    tripId: string | null
    userId: string | null
    city: string | null
    fromLocation: string | null
    toLocation: string | null
    destinationLat: number | null
    destinationLng: number | null
    googlePlaceId: string | null
    plannedDistance: number | null
    vehicleType: $Enums.VehicleType | null
    fuelType: $Enums.FuelType | null
    purpose: string | null
    notes: string | null
    status: $Enums.TripStatus | null
    totalDistance: number | null
    travelDuration: number | null
    idleTime: number | null
    meetingDuration: number | null
    productivityScore: number | null
    tripEfficiency: number | null
    startedAt: Date | null
    arrivedAt: Date | null
    completedAt: Date | null
    createdAt: Date | null
    updatedAt: Date | null
  }

  export type TripMaxAggregateOutputType = {
    id: string | null
    tripId: string | null
    userId: string | null
    city: string | null
    fromLocation: string | null
    toLocation: string | null
    destinationLat: number | null
    destinationLng: number | null
    googlePlaceId: string | null
    plannedDistance: number | null
    vehicleType: $Enums.VehicleType | null
    fuelType: $Enums.FuelType | null
    purpose: string | null
    notes: string | null
    status: $Enums.TripStatus | null
    totalDistance: number | null
    travelDuration: number | null
    idleTime: number | null
    meetingDuration: number | null
    productivityScore: number | null
    tripEfficiency: number | null
    startedAt: Date | null
    arrivedAt: Date | null
    completedAt: Date | null
    createdAt: Date | null
    updatedAt: Date | null
  }

  export type TripCountAggregateOutputType = {
    id: number
    tripId: number
    userId: number
    city: number
    fromLocation: number
    toLocation: number
    destinationLat: number
    destinationLng: number
    googlePlaceId: number
    plannedDistance: number
    vehicleType: number
    fuelType: number
    purpose: number
    notes: number
    status: number
    totalDistance: number
    travelDuration: number
    idleTime: number
    meetingDuration: number
    productivityScore: number
    tripEfficiency: number
    startedAt: number
    arrivedAt: number
    completedAt: number
    createdAt: number
    updatedAt: number
    _all: number
  }


  export type TripAvgAggregateInputType = {
    destinationLat?: true
    destinationLng?: true
    plannedDistance?: true
    totalDistance?: true
    travelDuration?: true
    idleTime?: true
    meetingDuration?: true
    productivityScore?: true
    tripEfficiency?: true
  }

  export type TripSumAggregateInputType = {
    destinationLat?: true
    destinationLng?: true
    plannedDistance?: true
    totalDistance?: true
    travelDuration?: true
    idleTime?: true
    meetingDuration?: true
    productivityScore?: true
    tripEfficiency?: true
  }

  export type TripMinAggregateInputType = {
    id?: true
    tripId?: true
    userId?: true
    city?: true
    fromLocation?: true
    toLocation?: true
    destinationLat?: true
    destinationLng?: true
    googlePlaceId?: true
    plannedDistance?: true
    vehicleType?: true
    fuelType?: true
    purpose?: true
    notes?: true
    status?: true
    totalDistance?: true
    travelDuration?: true
    idleTime?: true
    meetingDuration?: true
    productivityScore?: true
    tripEfficiency?: true
    startedAt?: true
    arrivedAt?: true
    completedAt?: true
    createdAt?: true
    updatedAt?: true
  }

  export type TripMaxAggregateInputType = {
    id?: true
    tripId?: true
    userId?: true
    city?: true
    fromLocation?: true
    toLocation?: true
    destinationLat?: true
    destinationLng?: true
    googlePlaceId?: true
    plannedDistance?: true
    vehicleType?: true
    fuelType?: true
    purpose?: true
    notes?: true
    status?: true
    totalDistance?: true
    travelDuration?: true
    idleTime?: true
    meetingDuration?: true
    productivityScore?: true
    tripEfficiency?: true
    startedAt?: true
    arrivedAt?: true
    completedAt?: true
    createdAt?: true
    updatedAt?: true
  }

  export type TripCountAggregateInputType = {
    id?: true
    tripId?: true
    userId?: true
    city?: true
    fromLocation?: true
    toLocation?: true
    destinationLat?: true
    destinationLng?: true
    googlePlaceId?: true
    plannedDistance?: true
    vehicleType?: true
    fuelType?: true
    purpose?: true
    notes?: true
    status?: true
    totalDistance?: true
    travelDuration?: true
    idleTime?: true
    meetingDuration?: true
    productivityScore?: true
    tripEfficiency?: true
    startedAt?: true
    arrivedAt?: true
    completedAt?: true
    createdAt?: true
    updatedAt?: true
    _all?: true
  }

  export type TripAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which Trip to aggregate.
     */
    where?: TripWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Trips to fetch.
     */
    orderBy?: TripOrderByWithRelationInput | TripOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: TripWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Trips from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` Trips.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned Trips
    **/
    _count?: true | TripCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to average
    **/
    _avg?: TripAvgAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to sum
    **/
    _sum?: TripSumAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: TripMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: TripMaxAggregateInputType
  }

  export type GetTripAggregateType<T extends TripAggregateArgs> = {
        [P in keyof T & keyof AggregateTrip]: P extends '_count' | 'count'
      ? T[P] extends true
        ? number
        : GetScalarType<T[P], AggregateTrip[P]>
      : GetScalarType<T[P], AggregateTrip[P]>
  }




  export type TripGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: TripWhereInput
    orderBy?: TripOrderByWithAggregationInput | TripOrderByWithAggregationInput[]
    by: TripScalarFieldEnum[] | TripScalarFieldEnum
    having?: TripScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: TripCountAggregateInputType | true
    _avg?: TripAvgAggregateInputType
    _sum?: TripSumAggregateInputType
    _min?: TripMinAggregateInputType
    _max?: TripMaxAggregateInputType
  }

  export type TripGroupByOutputType = {
    id: string
    tripId: string
    userId: string
    city: string | null
    fromLocation: string | null
    toLocation: string | null
    destinationLat: number | null
    destinationLng: number | null
    googlePlaceId: string | null
    plannedDistance: number | null
    vehicleType: $Enums.VehicleType | null
    fuelType: $Enums.FuelType | null
    purpose: string | null
    notes: string | null
    status: $Enums.TripStatus
    totalDistance: number
    travelDuration: number
    idleTime: number
    meetingDuration: number
    productivityScore: number | null
    tripEfficiency: number | null
    startedAt: Date | null
    arrivedAt: Date | null
    completedAt: Date | null
    createdAt: Date
    updatedAt: Date
    _count: TripCountAggregateOutputType | null
    _avg: TripAvgAggregateOutputType | null
    _sum: TripSumAggregateOutputType | null
    _min: TripMinAggregateOutputType | null
    _max: TripMaxAggregateOutputType | null
  }

  type GetTripGroupByPayload<T extends TripGroupByArgs> = Prisma.PrismaPromise<
    Array<
      PickEnumerable<TripGroupByOutputType, T['by']> &
        {
          [P in ((keyof T) & (keyof TripGroupByOutputType))]: P extends '_count'
            ? T[P] extends boolean
              ? number
              : GetScalarType<T[P], TripGroupByOutputType[P]>
            : GetScalarType<T[P], TripGroupByOutputType[P]>
        }
      >
    >


  export type TripSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    tripId?: boolean
    userId?: boolean
    city?: boolean
    fromLocation?: boolean
    toLocation?: boolean
    destinationLat?: boolean
    destinationLng?: boolean
    googlePlaceId?: boolean
    plannedDistance?: boolean
    vehicleType?: boolean
    fuelType?: boolean
    purpose?: boolean
    notes?: boolean
    status?: boolean
    totalDistance?: boolean
    travelDuration?: boolean
    idleTime?: boolean
    meetingDuration?: boolean
    productivityScore?: boolean
    tripEfficiency?: boolean
    startedAt?: boolean
    arrivedAt?: boolean
    completedAt?: boolean
    createdAt?: boolean
    updatedAt?: boolean
    user?: boolean | UserDefaultArgs<ExtArgs>
    punches?: boolean | Trip$punchesArgs<ExtArgs>
    gpsPoints?: boolean | Trip$gpsPointsArgs<ExtArgs>
    stops?: boolean | Trip$stopsArgs<ExtArgs>
    _count?: boolean | TripCountOutputTypeDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["trip"]>

  export type TripSelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    tripId?: boolean
    userId?: boolean
    city?: boolean
    fromLocation?: boolean
    toLocation?: boolean
    destinationLat?: boolean
    destinationLng?: boolean
    googlePlaceId?: boolean
    plannedDistance?: boolean
    vehicleType?: boolean
    fuelType?: boolean
    purpose?: boolean
    notes?: boolean
    status?: boolean
    totalDistance?: boolean
    travelDuration?: boolean
    idleTime?: boolean
    meetingDuration?: boolean
    productivityScore?: boolean
    tripEfficiency?: boolean
    startedAt?: boolean
    arrivedAt?: boolean
    completedAt?: boolean
    createdAt?: boolean
    updatedAt?: boolean
    user?: boolean | UserDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["trip"]>

  export type TripSelectUpdateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    tripId?: boolean
    userId?: boolean
    city?: boolean
    fromLocation?: boolean
    toLocation?: boolean
    destinationLat?: boolean
    destinationLng?: boolean
    googlePlaceId?: boolean
    plannedDistance?: boolean
    vehicleType?: boolean
    fuelType?: boolean
    purpose?: boolean
    notes?: boolean
    status?: boolean
    totalDistance?: boolean
    travelDuration?: boolean
    idleTime?: boolean
    meetingDuration?: boolean
    productivityScore?: boolean
    tripEfficiency?: boolean
    startedAt?: boolean
    arrivedAt?: boolean
    completedAt?: boolean
    createdAt?: boolean
    updatedAt?: boolean
    user?: boolean | UserDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["trip"]>

  export type TripSelectScalar = {
    id?: boolean
    tripId?: boolean
    userId?: boolean
    city?: boolean
    fromLocation?: boolean
    toLocation?: boolean
    destinationLat?: boolean
    destinationLng?: boolean
    googlePlaceId?: boolean
    plannedDistance?: boolean
    vehicleType?: boolean
    fuelType?: boolean
    purpose?: boolean
    notes?: boolean
    status?: boolean
    totalDistance?: boolean
    travelDuration?: boolean
    idleTime?: boolean
    meetingDuration?: boolean
    productivityScore?: boolean
    tripEfficiency?: boolean
    startedAt?: boolean
    arrivedAt?: boolean
    completedAt?: boolean
    createdAt?: boolean
    updatedAt?: boolean
  }

  export type TripOmit<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetOmit<"id" | "tripId" | "userId" | "city" | "fromLocation" | "toLocation" | "destinationLat" | "destinationLng" | "googlePlaceId" | "plannedDistance" | "vehicleType" | "fuelType" | "purpose" | "notes" | "status" | "totalDistance" | "travelDuration" | "idleTime" | "meetingDuration" | "productivityScore" | "tripEfficiency" | "startedAt" | "arrivedAt" | "completedAt" | "createdAt" | "updatedAt", ExtArgs["result"]["trip"]>
  export type TripInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    user?: boolean | UserDefaultArgs<ExtArgs>
    punches?: boolean | Trip$punchesArgs<ExtArgs>
    gpsPoints?: boolean | Trip$gpsPointsArgs<ExtArgs>
    stops?: boolean | Trip$stopsArgs<ExtArgs>
    _count?: boolean | TripCountOutputTypeDefaultArgs<ExtArgs>
  }
  export type TripIncludeCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    user?: boolean | UserDefaultArgs<ExtArgs>
  }
  export type TripIncludeUpdateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    user?: boolean | UserDefaultArgs<ExtArgs>
  }

  export type $TripPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "Trip"
    objects: {
      user: Prisma.$UserPayload<ExtArgs>
      punches: Prisma.$PunchPayload<ExtArgs>[]
      gpsPoints: Prisma.$GpsPointPayload<ExtArgs>[]
      stops: Prisma.$GpsStopPayload<ExtArgs>[]
    }
    scalars: $Extensions.GetPayloadResult<{
      id: string
      tripId: string
      userId: string
      city: string | null
      fromLocation: string | null
      toLocation: string | null
      destinationLat: number | null
      destinationLng: number | null
      googlePlaceId: string | null
      plannedDistance: number | null
      vehicleType: $Enums.VehicleType | null
      fuelType: $Enums.FuelType | null
      purpose: string | null
      notes: string | null
      status: $Enums.TripStatus
      totalDistance: number
      travelDuration: number
      idleTime: number
      meetingDuration: number
      productivityScore: number | null
      tripEfficiency: number | null
      startedAt: Date | null
      arrivedAt: Date | null
      completedAt: Date | null
      createdAt: Date
      updatedAt: Date
    }, ExtArgs["result"]["trip"]>
    composites: {}
  }

  type TripGetPayload<S extends boolean | null | undefined | TripDefaultArgs> = $Result.GetResult<Prisma.$TripPayload, S>

  type TripCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
    Omit<TripFindManyArgs, 'select' | 'include' | 'distinct' | 'omit'> & {
      select?: TripCountAggregateInputType | true
    }

  export interface TripDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs, GlobalOmitOptions = {}> {
    [K: symbol]: { types: Prisma.TypeMap<ExtArgs>['model']['Trip'], meta: { name: 'Trip' } }
    /**
     * Find zero or one Trip that matches the filter.
     * @param {TripFindUniqueArgs} args - Arguments to find a Trip
     * @example
     * // Get one Trip
     * const trip = await prisma.trip.findUnique({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findUnique<T extends TripFindUniqueArgs>(args: SelectSubset<T, TripFindUniqueArgs<ExtArgs>>): Prisma__TripClient<$Result.GetResult<Prisma.$TripPayload<ExtArgs>, T, "findUnique", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>

    /**
     * Find one Trip that matches the filter or throw an error with `error.code='P2025'`
     * if no matches were found.
     * @param {TripFindUniqueOrThrowArgs} args - Arguments to find a Trip
     * @example
     * // Get one Trip
     * const trip = await prisma.trip.findUniqueOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findUniqueOrThrow<T extends TripFindUniqueOrThrowArgs>(args: SelectSubset<T, TripFindUniqueOrThrowArgs<ExtArgs>>): Prisma__TripClient<$Result.GetResult<Prisma.$TripPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Find the first Trip that matches the filter.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {TripFindFirstArgs} args - Arguments to find a Trip
     * @example
     * // Get one Trip
     * const trip = await prisma.trip.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends TripFindFirstArgs>(args?: SelectSubset<T, TripFindFirstArgs<ExtArgs>>): Prisma__TripClient<$Result.GetResult<Prisma.$TripPayload<ExtArgs>, T, "findFirst", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>

    /**
     * Find the first Trip that matches the filter or
     * throw `PrismaKnownClientError` with `P2025` code if no matches were found.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {TripFindFirstOrThrowArgs} args - Arguments to find a Trip
     * @example
     * // Get one Trip
     * const trip = await prisma.trip.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends TripFindFirstOrThrowArgs>(args?: SelectSubset<T, TripFindFirstOrThrowArgs<ExtArgs>>): Prisma__TripClient<$Result.GetResult<Prisma.$TripPayload<ExtArgs>, T, "findFirstOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Find zero or more Trips that matches the filter.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {TripFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all Trips
     * const trips = await prisma.trip.findMany()
     * 
     * // Get first 10 Trips
     * const trips = await prisma.trip.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const tripWithIdOnly = await prisma.trip.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends TripFindManyArgs>(args?: SelectSubset<T, TripFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$TripPayload<ExtArgs>, T, "findMany", GlobalOmitOptions>>

    /**
     * Create a Trip.
     * @param {TripCreateArgs} args - Arguments to create a Trip.
     * @example
     * // Create one Trip
     * const Trip = await prisma.trip.create({
     *   data: {
     *     // ... data to create a Trip
     *   }
     * })
     * 
     */
    create<T extends TripCreateArgs>(args: SelectSubset<T, TripCreateArgs<ExtArgs>>): Prisma__TripClient<$Result.GetResult<Prisma.$TripPayload<ExtArgs>, T, "create", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Create many Trips.
     * @param {TripCreateManyArgs} args - Arguments to create many Trips.
     * @example
     * // Create many Trips
     * const trip = await prisma.trip.createMany({
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     *     
     */
    createMany<T extends TripCreateManyArgs>(args?: SelectSubset<T, TripCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>

    /**
     * Create many Trips and returns the data saved in the database.
     * @param {TripCreateManyAndReturnArgs} args - Arguments to create many Trips.
     * @example
     * // Create many Trips
     * const trip = await prisma.trip.createManyAndReturn({
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * 
     * // Create many Trips and only return the `id`
     * const tripWithIdOnly = await prisma.trip.createManyAndReturn({
     *   select: { id: true },
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * 
     */
    createManyAndReturn<T extends TripCreateManyAndReturnArgs>(args?: SelectSubset<T, TripCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$TripPayload<ExtArgs>, T, "createManyAndReturn", GlobalOmitOptions>>

    /**
     * Delete a Trip.
     * @param {TripDeleteArgs} args - Arguments to delete one Trip.
     * @example
     * // Delete one Trip
     * const Trip = await prisma.trip.delete({
     *   where: {
     *     // ... filter to delete one Trip
     *   }
     * })
     * 
     */
    delete<T extends TripDeleteArgs>(args: SelectSubset<T, TripDeleteArgs<ExtArgs>>): Prisma__TripClient<$Result.GetResult<Prisma.$TripPayload<ExtArgs>, T, "delete", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Update one Trip.
     * @param {TripUpdateArgs} args - Arguments to update one Trip.
     * @example
     * // Update one Trip
     * const trip = await prisma.trip.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends TripUpdateArgs>(args: SelectSubset<T, TripUpdateArgs<ExtArgs>>): Prisma__TripClient<$Result.GetResult<Prisma.$TripPayload<ExtArgs>, T, "update", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Delete zero or more Trips.
     * @param {TripDeleteManyArgs} args - Arguments to filter Trips to delete.
     * @example
     * // Delete a few Trips
     * const { count } = await prisma.trip.deleteMany({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     * 
     */
    deleteMany<T extends TripDeleteManyArgs>(args?: SelectSubset<T, TripDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>

    /**
     * Update zero or more Trips.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {TripUpdateManyArgs} args - Arguments to update one or more rows.
     * @example
     * // Update many Trips
     * const trip = await prisma.trip.updateMany({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    updateMany<T extends TripUpdateManyArgs>(args: SelectSubset<T, TripUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>

    /**
     * Update zero or more Trips and returns the data updated in the database.
     * @param {TripUpdateManyAndReturnArgs} args - Arguments to update many Trips.
     * @example
     * // Update many Trips
     * const trip = await prisma.trip.updateManyAndReturn({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * 
     * // Update zero or more Trips and only return the `id`
     * const tripWithIdOnly = await prisma.trip.updateManyAndReturn({
     *   select: { id: true },
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * 
     */
    updateManyAndReturn<T extends TripUpdateManyAndReturnArgs>(args: SelectSubset<T, TripUpdateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$TripPayload<ExtArgs>, T, "updateManyAndReturn", GlobalOmitOptions>>

    /**
     * Create or update one Trip.
     * @param {TripUpsertArgs} args - Arguments to update or create a Trip.
     * @example
     * // Update or create a Trip
     * const trip = await prisma.trip.upsert({
     *   create: {
     *     // ... data to create a Trip
     *   },
     *   update: {
     *     // ... in case it already exists, update
     *   },
     *   where: {
     *     // ... the filter for the Trip we want to update
     *   }
     * })
     */
    upsert<T extends TripUpsertArgs>(args: SelectSubset<T, TripUpsertArgs<ExtArgs>>): Prisma__TripClient<$Result.GetResult<Prisma.$TripPayload<ExtArgs>, T, "upsert", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>


    /**
     * Count the number of Trips.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {TripCountArgs} args - Arguments to filter Trips to count.
     * @example
     * // Count the number of Trips
     * const count = await prisma.trip.count({
     *   where: {
     *     // ... the filter for the Trips we want to count
     *   }
     * })
    **/
    count<T extends TripCountArgs>(
      args?: Subset<T, TripCountArgs>,
    ): Prisma.PrismaPromise<
      T extends $Utils.Record<'select', any>
        ? T['select'] extends true
          ? number
          : GetScalarType<T['select'], TripCountAggregateOutputType>
        : number
    >

    /**
     * Allows you to perform aggregations operations on a Trip.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {TripAggregateArgs} args - Select which aggregations you would like to apply and on what fields.
     * @example
     * // Ordered by age ascending
     * // Where email contains prisma.io
     * // Limited to the 10 users
     * const aggregations = await prisma.user.aggregate({
     *   _avg: {
     *     age: true,
     *   },
     *   where: {
     *     email: {
     *       contains: "prisma.io",
     *     },
     *   },
     *   orderBy: {
     *     age: "asc",
     *   },
     *   take: 10,
     * })
    **/
    aggregate<T extends TripAggregateArgs>(args: Subset<T, TripAggregateArgs>): Prisma.PrismaPromise<GetTripAggregateType<T>>

    /**
     * Group by Trip.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {TripGroupByArgs} args - Group by arguments.
     * @example
     * // Group by city, order by createdAt, get count
     * const result = await prisma.user.groupBy({
     *   by: ['city', 'createdAt'],
     *   orderBy: {
     *     createdAt: true
     *   },
     *   _count: {
     *     _all: true
     *   },
     * })
     * 
    **/
    groupBy<
      T extends TripGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: TripGroupByArgs['orderBy'] }
        : { orderBy?: TripGroupByArgs['orderBy'] },
      OrderFields extends ExcludeUnderscoreKeys<Keys<MaybeTupleToUnion<T['orderBy']>>>,
      ByFields extends MaybeTupleToUnion<T['by']>,
      ByValid extends Has<ByFields, OrderFields>,
      HavingFields extends GetHavingFields<T['having']>,
      HavingValid extends Has<ByFields, HavingFields>,
      ByEmpty extends T['by'] extends never[] ? True : False,
      InputErrors extends ByEmpty extends True
      ? `Error: "by" must not be empty.`
      : HavingValid extends False
      ? {
          [P in HavingFields]: P extends ByFields
            ? never
            : P extends string
            ? `Error: Field "${P}" used in "having" needs to be provided in "by".`
            : [
                Error,
                'Field ',
                P,
                ` in "having" needs to be provided in "by"`,
              ]
        }[HavingFields]
      : 'take' extends Keys<T>
      ? 'orderBy' extends Keys<T>
        ? ByValid extends True
          ? {}
          : {
              [P in OrderFields]: P extends ByFields
                ? never
                : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
            }[OrderFields]
        : 'Error: If you provide "take", you also need to provide "orderBy"'
      : 'skip' extends Keys<T>
      ? 'orderBy' extends Keys<T>
        ? ByValid extends True
          ? {}
          : {
              [P in OrderFields]: P extends ByFields
                ? never
                : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
            }[OrderFields]
        : 'Error: If you provide "skip", you also need to provide "orderBy"'
      : ByValid extends True
      ? {}
      : {
          [P in OrderFields]: P extends ByFields
            ? never
            : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
        }[OrderFields]
    >(args: SubsetIntersection<T, TripGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetTripGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the Trip model
   */
  readonly fields: TripFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for Trip.
   * Why is this prefixed with `Prisma__`?
   * Because we want to prevent naming conflicts as mentioned in
   * https://github.com/prisma/prisma-client-js/issues/707
   */
  export interface Prisma__TripClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs, GlobalOmitOptions = {}> extends Prisma.PrismaPromise<T> {
    readonly [Symbol.toStringTag]: "PrismaPromise"
    user<T extends UserDefaultArgs<ExtArgs> = {}>(args?: Subset<T, UserDefaultArgs<ExtArgs>>): Prisma__UserClient<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | Null, Null, ExtArgs, GlobalOmitOptions>
    punches<T extends Trip$punchesArgs<ExtArgs> = {}>(args?: Subset<T, Trip$punchesArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$PunchPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
    gpsPoints<T extends Trip$gpsPointsArgs<ExtArgs> = {}>(args?: Subset<T, Trip$gpsPointsArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$GpsPointPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
    stops<T extends Trip$stopsArgs<ExtArgs> = {}>(args?: Subset<T, Trip$stopsArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$GpsStopPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
    /**
     * Attaches callbacks for the resolution and/or rejection of the Promise.
     * @param onfulfilled The callback to execute when the Promise is resolved.
     * @param onrejected The callback to execute when the Promise is rejected.
     * @returns A Promise for the completion of which ever callback is executed.
     */
    then<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): $Utils.JsPromise<TResult1 | TResult2>
    /**
     * Attaches a callback for only the rejection of the Promise.
     * @param onrejected The callback to execute when the Promise is rejected.
     * @returns A Promise for the completion of the callback.
     */
    catch<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): $Utils.JsPromise<T | TResult>
    /**
     * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The
     * resolved value cannot be modified from the callback.
     * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected).
     * @returns A Promise for the completion of the callback.
     */
    finally(onfinally?: (() => void) | undefined | null): $Utils.JsPromise<T>
  }




  /**
   * Fields of the Trip model
   */
  interface TripFieldRefs {
    readonly id: FieldRef<"Trip", 'String'>
    readonly tripId: FieldRef<"Trip", 'String'>
    readonly userId: FieldRef<"Trip", 'String'>
    readonly city: FieldRef<"Trip", 'String'>
    readonly fromLocation: FieldRef<"Trip", 'String'>
    readonly toLocation: FieldRef<"Trip", 'String'>
    readonly destinationLat: FieldRef<"Trip", 'Float'>
    readonly destinationLng: FieldRef<"Trip", 'Float'>
    readonly googlePlaceId: FieldRef<"Trip", 'String'>
    readonly plannedDistance: FieldRef<"Trip", 'Float'>
    readonly vehicleType: FieldRef<"Trip", 'VehicleType'>
    readonly fuelType: FieldRef<"Trip", 'FuelType'>
    readonly purpose: FieldRef<"Trip", 'String'>
    readonly notes: FieldRef<"Trip", 'String'>
    readonly status: FieldRef<"Trip", 'TripStatus'>
    readonly totalDistance: FieldRef<"Trip", 'Float'>
    readonly travelDuration: FieldRef<"Trip", 'Int'>
    readonly idleTime: FieldRef<"Trip", 'Int'>
    readonly meetingDuration: FieldRef<"Trip", 'Int'>
    readonly productivityScore: FieldRef<"Trip", 'Float'>
    readonly tripEfficiency: FieldRef<"Trip", 'Float'>
    readonly startedAt: FieldRef<"Trip", 'DateTime'>
    readonly arrivedAt: FieldRef<"Trip", 'DateTime'>
    readonly completedAt: FieldRef<"Trip", 'DateTime'>
    readonly createdAt: FieldRef<"Trip", 'DateTime'>
    readonly updatedAt: FieldRef<"Trip", 'DateTime'>
  }
    

  // Custom InputTypes
  /**
   * Trip findUnique
   */
  export type TripFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Trip
     */
    select?: TripSelect<ExtArgs> | null
    /**
     * Omit specific fields from the Trip
     */
    omit?: TripOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: TripInclude<ExtArgs> | null
    /**
     * Filter, which Trip to fetch.
     */
    where: TripWhereUniqueInput
  }

  /**
   * Trip findUniqueOrThrow
   */
  export type TripFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Trip
     */
    select?: TripSelect<ExtArgs> | null
    /**
     * Omit specific fields from the Trip
     */
    omit?: TripOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: TripInclude<ExtArgs> | null
    /**
     * Filter, which Trip to fetch.
     */
    where: TripWhereUniqueInput
  }

  /**
   * Trip findFirst
   */
  export type TripFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Trip
     */
    select?: TripSelect<ExtArgs> | null
    /**
     * Omit specific fields from the Trip
     */
    omit?: TripOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: TripInclude<ExtArgs> | null
    /**
     * Filter, which Trip to fetch.
     */
    where?: TripWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Trips to fetch.
     */
    orderBy?: TripOrderByWithRelationInput | TripOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for Trips.
     */
    cursor?: TripWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Trips from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` Trips.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of Trips.
     */
    distinct?: TripScalarFieldEnum | TripScalarFieldEnum[]
  }

  /**
   * Trip findFirstOrThrow
   */
  export type TripFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Trip
     */
    select?: TripSelect<ExtArgs> | null
    /**
     * Omit specific fields from the Trip
     */
    omit?: TripOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: TripInclude<ExtArgs> | null
    /**
     * Filter, which Trip to fetch.
     */
    where?: TripWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Trips to fetch.
     */
    orderBy?: TripOrderByWithRelationInput | TripOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for Trips.
     */
    cursor?: TripWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Trips from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` Trips.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of Trips.
     */
    distinct?: TripScalarFieldEnum | TripScalarFieldEnum[]
  }

  /**
   * Trip findMany
   */
  export type TripFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Trip
     */
    select?: TripSelect<ExtArgs> | null
    /**
     * Omit specific fields from the Trip
     */
    omit?: TripOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: TripInclude<ExtArgs> | null
    /**
     * Filter, which Trips to fetch.
     */
    where?: TripWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Trips to fetch.
     */
    orderBy?: TripOrderByWithRelationInput | TripOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing Trips.
     */
    cursor?: TripWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Trips from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` Trips.
     */
    skip?: number
    distinct?: TripScalarFieldEnum | TripScalarFieldEnum[]
  }

  /**
   * Trip create
   */
  export type TripCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Trip
     */
    select?: TripSelect<ExtArgs> | null
    /**
     * Omit specific fields from the Trip
     */
    omit?: TripOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: TripInclude<ExtArgs> | null
    /**
     * The data needed to create a Trip.
     */
    data: XOR<TripCreateInput, TripUncheckedCreateInput>
  }

  /**
   * Trip createMany
   */
  export type TripCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many Trips.
     */
    data: TripCreateManyInput | TripCreateManyInput[]
  }

  /**
   * Trip createManyAndReturn
   */
  export type TripCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Trip
     */
    select?: TripSelectCreateManyAndReturn<ExtArgs> | null
    /**
     * Omit specific fields from the Trip
     */
    omit?: TripOmit<ExtArgs> | null
    /**
     * The data used to create many Trips.
     */
    data: TripCreateManyInput | TripCreateManyInput[]
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: TripIncludeCreateManyAndReturn<ExtArgs> | null
  }

  /**
   * Trip update
   */
  export type TripUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Trip
     */
    select?: TripSelect<ExtArgs> | null
    /**
     * Omit specific fields from the Trip
     */
    omit?: TripOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: TripInclude<ExtArgs> | null
    /**
     * The data needed to update a Trip.
     */
    data: XOR<TripUpdateInput, TripUncheckedUpdateInput>
    /**
     * Choose, which Trip to update.
     */
    where: TripWhereUniqueInput
  }

  /**
   * Trip updateMany
   */
  export type TripUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update Trips.
     */
    data: XOR<TripUpdateManyMutationInput, TripUncheckedUpdateManyInput>
    /**
     * Filter which Trips to update
     */
    where?: TripWhereInput
    /**
     * Limit how many Trips to update.
     */
    limit?: number
  }

  /**
   * Trip updateManyAndReturn
   */
  export type TripUpdateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Trip
     */
    select?: TripSelectUpdateManyAndReturn<ExtArgs> | null
    /**
     * Omit specific fields from the Trip
     */
    omit?: TripOmit<ExtArgs> | null
    /**
     * The data used to update Trips.
     */
    data: XOR<TripUpdateManyMutationInput, TripUncheckedUpdateManyInput>
    /**
     * Filter which Trips to update
     */
    where?: TripWhereInput
    /**
     * Limit how many Trips to update.
     */
    limit?: number
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: TripIncludeUpdateManyAndReturn<ExtArgs> | null
  }

  /**
   * Trip upsert
   */
  export type TripUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Trip
     */
    select?: TripSelect<ExtArgs> | null
    /**
     * Omit specific fields from the Trip
     */
    omit?: TripOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: TripInclude<ExtArgs> | null
    /**
     * The filter to search for the Trip to update in case it exists.
     */
    where: TripWhereUniqueInput
    /**
     * In case the Trip found by the `where` argument doesn't exist, create a new Trip with this data.
     */
    create: XOR<TripCreateInput, TripUncheckedCreateInput>
    /**
     * In case the Trip was found with the provided `where` argument, update it with this data.
     */
    update: XOR<TripUpdateInput, TripUncheckedUpdateInput>
  }

  /**
   * Trip delete
   */
  export type TripDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Trip
     */
    select?: TripSelect<ExtArgs> | null
    /**
     * Omit specific fields from the Trip
     */
    omit?: TripOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: TripInclude<ExtArgs> | null
    /**
     * Filter which Trip to delete.
     */
    where: TripWhereUniqueInput
  }

  /**
   * Trip deleteMany
   */
  export type TripDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which Trips to delete
     */
    where?: TripWhereInput
    /**
     * Limit how many Trips to delete.
     */
    limit?: number
  }

  /**
   * Trip.punches
   */
  export type Trip$punchesArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Punch
     */
    select?: PunchSelect<ExtArgs> | null
    /**
     * Omit specific fields from the Punch
     */
    omit?: PunchOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: PunchInclude<ExtArgs> | null
    where?: PunchWhereInput
    orderBy?: PunchOrderByWithRelationInput | PunchOrderByWithRelationInput[]
    cursor?: PunchWhereUniqueInput
    take?: number
    skip?: number
    distinct?: PunchScalarFieldEnum | PunchScalarFieldEnum[]
  }

  /**
   * Trip.gpsPoints
   */
  export type Trip$gpsPointsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the GpsPoint
     */
    select?: GpsPointSelect<ExtArgs> | null
    /**
     * Omit specific fields from the GpsPoint
     */
    omit?: GpsPointOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GpsPointInclude<ExtArgs> | null
    where?: GpsPointWhereInput
    orderBy?: GpsPointOrderByWithRelationInput | GpsPointOrderByWithRelationInput[]
    cursor?: GpsPointWhereUniqueInput
    take?: number
    skip?: number
    distinct?: GpsPointScalarFieldEnum | GpsPointScalarFieldEnum[]
  }

  /**
   * Trip.stops
   */
  export type Trip$stopsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the GpsStop
     */
    select?: GpsStopSelect<ExtArgs> | null
    /**
     * Omit specific fields from the GpsStop
     */
    omit?: GpsStopOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GpsStopInclude<ExtArgs> | null
    where?: GpsStopWhereInput
    orderBy?: GpsStopOrderByWithRelationInput | GpsStopOrderByWithRelationInput[]
    cursor?: GpsStopWhereUniqueInput
    take?: number
    skip?: number
    distinct?: GpsStopScalarFieldEnum | GpsStopScalarFieldEnum[]
  }

  /**
   * Trip without action
   */
  export type TripDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Trip
     */
    select?: TripSelect<ExtArgs> | null
    /**
     * Omit specific fields from the Trip
     */
    omit?: TripOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: TripInclude<ExtArgs> | null
  }


  /**
   * Model Punch
   */

  export type AggregatePunch = {
    _count: PunchCountAggregateOutputType | null
    _avg: PunchAvgAggregateOutputType | null
    _sum: PunchSumAggregateOutputType | null
    _min: PunchMinAggregateOutputType | null
    _max: PunchMaxAggregateOutputType | null
  }

  export type PunchAvgAggregateOutputType = {
    latitude: number | null
    longitude: number | null
    batteryPercent: number | null
    gpsAccuracy: number | null
    speed: number | null
  }

  export type PunchSumAggregateOutputType = {
    latitude: number | null
    longitude: number | null
    batteryPercent: number | null
    gpsAccuracy: number | null
    speed: number | null
  }

  export type PunchMinAggregateOutputType = {
    id: string | null
    tripId: string | null
    type: $Enums.PunchType | null
    timestamp: Date | null
    latitude: number | null
    longitude: number | null
    address: string | null
    batteryPercent: number | null
    gpsAccuracy: number | null
    speed: number | null
    isMockLocation: boolean | null
    meetingSummary: string | null
    leadType: $Enums.LeadType | null
    customerNotes: string | null
    createdAt: Date | null
  }

  export type PunchMaxAggregateOutputType = {
    id: string | null
    tripId: string | null
    type: $Enums.PunchType | null
    timestamp: Date | null
    latitude: number | null
    longitude: number | null
    address: string | null
    batteryPercent: number | null
    gpsAccuracy: number | null
    speed: number | null
    isMockLocation: boolean | null
    meetingSummary: string | null
    leadType: $Enums.LeadType | null
    customerNotes: string | null
    createdAt: Date | null
  }

  export type PunchCountAggregateOutputType = {
    id: number
    tripId: number
    type: number
    timestamp: number
    latitude: number
    longitude: number
    address: number
    batteryPercent: number
    gpsAccuracy: number
    speed: number
    isMockLocation: number
    meetingSummary: number
    leadType: number
    customerNotes: number
    createdAt: number
    _all: number
  }


  export type PunchAvgAggregateInputType = {
    latitude?: true
    longitude?: true
    batteryPercent?: true
    gpsAccuracy?: true
    speed?: true
  }

  export type PunchSumAggregateInputType = {
    latitude?: true
    longitude?: true
    batteryPercent?: true
    gpsAccuracy?: true
    speed?: true
  }

  export type PunchMinAggregateInputType = {
    id?: true
    tripId?: true
    type?: true
    timestamp?: true
    latitude?: true
    longitude?: true
    address?: true
    batteryPercent?: true
    gpsAccuracy?: true
    speed?: true
    isMockLocation?: true
    meetingSummary?: true
    leadType?: true
    customerNotes?: true
    createdAt?: true
  }

  export type PunchMaxAggregateInputType = {
    id?: true
    tripId?: true
    type?: true
    timestamp?: true
    latitude?: true
    longitude?: true
    address?: true
    batteryPercent?: true
    gpsAccuracy?: true
    speed?: true
    isMockLocation?: true
    meetingSummary?: true
    leadType?: true
    customerNotes?: true
    createdAt?: true
  }

  export type PunchCountAggregateInputType = {
    id?: true
    tripId?: true
    type?: true
    timestamp?: true
    latitude?: true
    longitude?: true
    address?: true
    batteryPercent?: true
    gpsAccuracy?: true
    speed?: true
    isMockLocation?: true
    meetingSummary?: true
    leadType?: true
    customerNotes?: true
    createdAt?: true
    _all?: true
  }

  export type PunchAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which Punch to aggregate.
     */
    where?: PunchWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Punches to fetch.
     */
    orderBy?: PunchOrderByWithRelationInput | PunchOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: PunchWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Punches from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` Punches.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned Punches
    **/
    _count?: true | PunchCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to average
    **/
    _avg?: PunchAvgAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to sum
    **/
    _sum?: PunchSumAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: PunchMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: PunchMaxAggregateInputType
  }

  export type GetPunchAggregateType<T extends PunchAggregateArgs> = {
        [P in keyof T & keyof AggregatePunch]: P extends '_count' | 'count'
      ? T[P] extends true
        ? number
        : GetScalarType<T[P], AggregatePunch[P]>
      : GetScalarType<T[P], AggregatePunch[P]>
  }




  export type PunchGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: PunchWhereInput
    orderBy?: PunchOrderByWithAggregationInput | PunchOrderByWithAggregationInput[]
    by: PunchScalarFieldEnum[] | PunchScalarFieldEnum
    having?: PunchScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: PunchCountAggregateInputType | true
    _avg?: PunchAvgAggregateInputType
    _sum?: PunchSumAggregateInputType
    _min?: PunchMinAggregateInputType
    _max?: PunchMaxAggregateInputType
  }

  export type PunchGroupByOutputType = {
    id: string
    tripId: string
    type: $Enums.PunchType
    timestamp: Date
    latitude: number
    longitude: number
    address: string | null
    batteryPercent: number | null
    gpsAccuracy: number | null
    speed: number | null
    isMockLocation: boolean
    meetingSummary: string | null
    leadType: $Enums.LeadType | null
    customerNotes: string | null
    createdAt: Date
    _count: PunchCountAggregateOutputType | null
    _avg: PunchAvgAggregateOutputType | null
    _sum: PunchSumAggregateOutputType | null
    _min: PunchMinAggregateOutputType | null
    _max: PunchMaxAggregateOutputType | null
  }

  type GetPunchGroupByPayload<T extends PunchGroupByArgs> = Prisma.PrismaPromise<
    Array<
      PickEnumerable<PunchGroupByOutputType, T['by']> &
        {
          [P in ((keyof T) & (keyof PunchGroupByOutputType))]: P extends '_count'
            ? T[P] extends boolean
              ? number
              : GetScalarType<T[P], PunchGroupByOutputType[P]>
            : GetScalarType<T[P], PunchGroupByOutputType[P]>
        }
      >
    >


  export type PunchSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    tripId?: boolean
    type?: boolean
    timestamp?: boolean
    latitude?: boolean
    longitude?: boolean
    address?: boolean
    batteryPercent?: boolean
    gpsAccuracy?: boolean
    speed?: boolean
    isMockLocation?: boolean
    meetingSummary?: boolean
    leadType?: boolean
    customerNotes?: boolean
    createdAt?: boolean
    trip?: boolean | TripDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["punch"]>

  export type PunchSelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    tripId?: boolean
    type?: boolean
    timestamp?: boolean
    latitude?: boolean
    longitude?: boolean
    address?: boolean
    batteryPercent?: boolean
    gpsAccuracy?: boolean
    speed?: boolean
    isMockLocation?: boolean
    meetingSummary?: boolean
    leadType?: boolean
    customerNotes?: boolean
    createdAt?: boolean
    trip?: boolean | TripDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["punch"]>

  export type PunchSelectUpdateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    tripId?: boolean
    type?: boolean
    timestamp?: boolean
    latitude?: boolean
    longitude?: boolean
    address?: boolean
    batteryPercent?: boolean
    gpsAccuracy?: boolean
    speed?: boolean
    isMockLocation?: boolean
    meetingSummary?: boolean
    leadType?: boolean
    customerNotes?: boolean
    createdAt?: boolean
    trip?: boolean | TripDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["punch"]>

  export type PunchSelectScalar = {
    id?: boolean
    tripId?: boolean
    type?: boolean
    timestamp?: boolean
    latitude?: boolean
    longitude?: boolean
    address?: boolean
    batteryPercent?: boolean
    gpsAccuracy?: boolean
    speed?: boolean
    isMockLocation?: boolean
    meetingSummary?: boolean
    leadType?: boolean
    customerNotes?: boolean
    createdAt?: boolean
  }

  export type PunchOmit<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetOmit<"id" | "tripId" | "type" | "timestamp" | "latitude" | "longitude" | "address" | "batteryPercent" | "gpsAccuracy" | "speed" | "isMockLocation" | "meetingSummary" | "leadType" | "customerNotes" | "createdAt", ExtArgs["result"]["punch"]>
  export type PunchInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    trip?: boolean | TripDefaultArgs<ExtArgs>
  }
  export type PunchIncludeCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    trip?: boolean | TripDefaultArgs<ExtArgs>
  }
  export type PunchIncludeUpdateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    trip?: boolean | TripDefaultArgs<ExtArgs>
  }

  export type $PunchPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "Punch"
    objects: {
      trip: Prisma.$TripPayload<ExtArgs>
    }
    scalars: $Extensions.GetPayloadResult<{
      id: string
      tripId: string
      type: $Enums.PunchType
      timestamp: Date
      latitude: number
      longitude: number
      address: string | null
      batteryPercent: number | null
      gpsAccuracy: number | null
      speed: number | null
      isMockLocation: boolean
      meetingSummary: string | null
      leadType: $Enums.LeadType | null
      customerNotes: string | null
      createdAt: Date
    }, ExtArgs["result"]["punch"]>
    composites: {}
  }

  type PunchGetPayload<S extends boolean | null | undefined | PunchDefaultArgs> = $Result.GetResult<Prisma.$PunchPayload, S>

  type PunchCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
    Omit<PunchFindManyArgs, 'select' | 'include' | 'distinct' | 'omit'> & {
      select?: PunchCountAggregateInputType | true
    }

  export interface PunchDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs, GlobalOmitOptions = {}> {
    [K: symbol]: { types: Prisma.TypeMap<ExtArgs>['model']['Punch'], meta: { name: 'Punch' } }
    /**
     * Find zero or one Punch that matches the filter.
     * @param {PunchFindUniqueArgs} args - Arguments to find a Punch
     * @example
     * // Get one Punch
     * const punch = await prisma.punch.findUnique({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findUnique<T extends PunchFindUniqueArgs>(args: SelectSubset<T, PunchFindUniqueArgs<ExtArgs>>): Prisma__PunchClient<$Result.GetResult<Prisma.$PunchPayload<ExtArgs>, T, "findUnique", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>

    /**
     * Find one Punch that matches the filter or throw an error with `error.code='P2025'`
     * if no matches were found.
     * @param {PunchFindUniqueOrThrowArgs} args - Arguments to find a Punch
     * @example
     * // Get one Punch
     * const punch = await prisma.punch.findUniqueOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findUniqueOrThrow<T extends PunchFindUniqueOrThrowArgs>(args: SelectSubset<T, PunchFindUniqueOrThrowArgs<ExtArgs>>): Prisma__PunchClient<$Result.GetResult<Prisma.$PunchPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Find the first Punch that matches the filter.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {PunchFindFirstArgs} args - Arguments to find a Punch
     * @example
     * // Get one Punch
     * const punch = await prisma.punch.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends PunchFindFirstArgs>(args?: SelectSubset<T, PunchFindFirstArgs<ExtArgs>>): Prisma__PunchClient<$Result.GetResult<Prisma.$PunchPayload<ExtArgs>, T, "findFirst", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>

    /**
     * Find the first Punch that matches the filter or
     * throw `PrismaKnownClientError` with `P2025` code if no matches were found.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {PunchFindFirstOrThrowArgs} args - Arguments to find a Punch
     * @example
     * // Get one Punch
     * const punch = await prisma.punch.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends PunchFindFirstOrThrowArgs>(args?: SelectSubset<T, PunchFindFirstOrThrowArgs<ExtArgs>>): Prisma__PunchClient<$Result.GetResult<Prisma.$PunchPayload<ExtArgs>, T, "findFirstOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Find zero or more Punches that matches the filter.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {PunchFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all Punches
     * const punches = await prisma.punch.findMany()
     * 
     * // Get first 10 Punches
     * const punches = await prisma.punch.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const punchWithIdOnly = await prisma.punch.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends PunchFindManyArgs>(args?: SelectSubset<T, PunchFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$PunchPayload<ExtArgs>, T, "findMany", GlobalOmitOptions>>

    /**
     * Create a Punch.
     * @param {PunchCreateArgs} args - Arguments to create a Punch.
     * @example
     * // Create one Punch
     * const Punch = await prisma.punch.create({
     *   data: {
     *     // ... data to create a Punch
     *   }
     * })
     * 
     */
    create<T extends PunchCreateArgs>(args: SelectSubset<T, PunchCreateArgs<ExtArgs>>): Prisma__PunchClient<$Result.GetResult<Prisma.$PunchPayload<ExtArgs>, T, "create", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Create many Punches.
     * @param {PunchCreateManyArgs} args - Arguments to create many Punches.
     * @example
     * // Create many Punches
     * const punch = await prisma.punch.createMany({
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     *     
     */
    createMany<T extends PunchCreateManyArgs>(args?: SelectSubset<T, PunchCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>

    /**
     * Create many Punches and returns the data saved in the database.
     * @param {PunchCreateManyAndReturnArgs} args - Arguments to create many Punches.
     * @example
     * // Create many Punches
     * const punch = await prisma.punch.createManyAndReturn({
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * 
     * // Create many Punches and only return the `id`
     * const punchWithIdOnly = await prisma.punch.createManyAndReturn({
     *   select: { id: true },
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * 
     */
    createManyAndReturn<T extends PunchCreateManyAndReturnArgs>(args?: SelectSubset<T, PunchCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$PunchPayload<ExtArgs>, T, "createManyAndReturn", GlobalOmitOptions>>

    /**
     * Delete a Punch.
     * @param {PunchDeleteArgs} args - Arguments to delete one Punch.
     * @example
     * // Delete one Punch
     * const Punch = await prisma.punch.delete({
     *   where: {
     *     // ... filter to delete one Punch
     *   }
     * })
     * 
     */
    delete<T extends PunchDeleteArgs>(args: SelectSubset<T, PunchDeleteArgs<ExtArgs>>): Prisma__PunchClient<$Result.GetResult<Prisma.$PunchPayload<ExtArgs>, T, "delete", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Update one Punch.
     * @param {PunchUpdateArgs} args - Arguments to update one Punch.
     * @example
     * // Update one Punch
     * const punch = await prisma.punch.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends PunchUpdateArgs>(args: SelectSubset<T, PunchUpdateArgs<ExtArgs>>): Prisma__PunchClient<$Result.GetResult<Prisma.$PunchPayload<ExtArgs>, T, "update", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Delete zero or more Punches.
     * @param {PunchDeleteManyArgs} args - Arguments to filter Punches to delete.
     * @example
     * // Delete a few Punches
     * const { count } = await prisma.punch.deleteMany({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     * 
     */
    deleteMany<T extends PunchDeleteManyArgs>(args?: SelectSubset<T, PunchDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>

    /**
     * Update zero or more Punches.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {PunchUpdateManyArgs} args - Arguments to update one or more rows.
     * @example
     * // Update many Punches
     * const punch = await prisma.punch.updateMany({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    updateMany<T extends PunchUpdateManyArgs>(args: SelectSubset<T, PunchUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>

    /**
     * Update zero or more Punches and returns the data updated in the database.
     * @param {PunchUpdateManyAndReturnArgs} args - Arguments to update many Punches.
     * @example
     * // Update many Punches
     * const punch = await prisma.punch.updateManyAndReturn({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * 
     * // Update zero or more Punches and only return the `id`
     * const punchWithIdOnly = await prisma.punch.updateManyAndReturn({
     *   select: { id: true },
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * 
     */
    updateManyAndReturn<T extends PunchUpdateManyAndReturnArgs>(args: SelectSubset<T, PunchUpdateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$PunchPayload<ExtArgs>, T, "updateManyAndReturn", GlobalOmitOptions>>

    /**
     * Create or update one Punch.
     * @param {PunchUpsertArgs} args - Arguments to update or create a Punch.
     * @example
     * // Update or create a Punch
     * const punch = await prisma.punch.upsert({
     *   create: {
     *     // ... data to create a Punch
     *   },
     *   update: {
     *     // ... in case it already exists, update
     *   },
     *   where: {
     *     // ... the filter for the Punch we want to update
     *   }
     * })
     */
    upsert<T extends PunchUpsertArgs>(args: SelectSubset<T, PunchUpsertArgs<ExtArgs>>): Prisma__PunchClient<$Result.GetResult<Prisma.$PunchPayload<ExtArgs>, T, "upsert", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>


    /**
     * Count the number of Punches.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {PunchCountArgs} args - Arguments to filter Punches to count.
     * @example
     * // Count the number of Punches
     * const count = await prisma.punch.count({
     *   where: {
     *     // ... the filter for the Punches we want to count
     *   }
     * })
    **/
    count<T extends PunchCountArgs>(
      args?: Subset<T, PunchCountArgs>,
    ): Prisma.PrismaPromise<
      T extends $Utils.Record<'select', any>
        ? T['select'] extends true
          ? number
          : GetScalarType<T['select'], PunchCountAggregateOutputType>
        : number
    >

    /**
     * Allows you to perform aggregations operations on a Punch.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {PunchAggregateArgs} args - Select which aggregations you would like to apply and on what fields.
     * @example
     * // Ordered by age ascending
     * // Where email contains prisma.io
     * // Limited to the 10 users
     * const aggregations = await prisma.user.aggregate({
     *   _avg: {
     *     age: true,
     *   },
     *   where: {
     *     email: {
     *       contains: "prisma.io",
     *     },
     *   },
     *   orderBy: {
     *     age: "asc",
     *   },
     *   take: 10,
     * })
    **/
    aggregate<T extends PunchAggregateArgs>(args: Subset<T, PunchAggregateArgs>): Prisma.PrismaPromise<GetPunchAggregateType<T>>

    /**
     * Group by Punch.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {PunchGroupByArgs} args - Group by arguments.
     * @example
     * // Group by city, order by createdAt, get count
     * const result = await prisma.user.groupBy({
     *   by: ['city', 'createdAt'],
     *   orderBy: {
     *     createdAt: true
     *   },
     *   _count: {
     *     _all: true
     *   },
     * })
     * 
    **/
    groupBy<
      T extends PunchGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: PunchGroupByArgs['orderBy'] }
        : { orderBy?: PunchGroupByArgs['orderBy'] },
      OrderFields extends ExcludeUnderscoreKeys<Keys<MaybeTupleToUnion<T['orderBy']>>>,
      ByFields extends MaybeTupleToUnion<T['by']>,
      ByValid extends Has<ByFields, OrderFields>,
      HavingFields extends GetHavingFields<T['having']>,
      HavingValid extends Has<ByFields, HavingFields>,
      ByEmpty extends T['by'] extends never[] ? True : False,
      InputErrors extends ByEmpty extends True
      ? `Error: "by" must not be empty.`
      : HavingValid extends False
      ? {
          [P in HavingFields]: P extends ByFields
            ? never
            : P extends string
            ? `Error: Field "${P}" used in "having" needs to be provided in "by".`
            : [
                Error,
                'Field ',
                P,
                ` in "having" needs to be provided in "by"`,
              ]
        }[HavingFields]
      : 'take' extends Keys<T>
      ? 'orderBy' extends Keys<T>
        ? ByValid extends True
          ? {}
          : {
              [P in OrderFields]: P extends ByFields
                ? never
                : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
            }[OrderFields]
        : 'Error: If you provide "take", you also need to provide "orderBy"'
      : 'skip' extends Keys<T>
      ? 'orderBy' extends Keys<T>
        ? ByValid extends True
          ? {}
          : {
              [P in OrderFields]: P extends ByFields
                ? never
                : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
            }[OrderFields]
        : 'Error: If you provide "skip", you also need to provide "orderBy"'
      : ByValid extends True
      ? {}
      : {
          [P in OrderFields]: P extends ByFields
            ? never
            : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
        }[OrderFields]
    >(args: SubsetIntersection<T, PunchGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetPunchGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the Punch model
   */
  readonly fields: PunchFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for Punch.
   * Why is this prefixed with `Prisma__`?
   * Because we want to prevent naming conflicts as mentioned in
   * https://github.com/prisma/prisma-client-js/issues/707
   */
  export interface Prisma__PunchClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs, GlobalOmitOptions = {}> extends Prisma.PrismaPromise<T> {
    readonly [Symbol.toStringTag]: "PrismaPromise"
    trip<T extends TripDefaultArgs<ExtArgs> = {}>(args?: Subset<T, TripDefaultArgs<ExtArgs>>): Prisma__TripClient<$Result.GetResult<Prisma.$TripPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | Null, Null, ExtArgs, GlobalOmitOptions>
    /**
     * Attaches callbacks for the resolution and/or rejection of the Promise.
     * @param onfulfilled The callback to execute when the Promise is resolved.
     * @param onrejected The callback to execute when the Promise is rejected.
     * @returns A Promise for the completion of which ever callback is executed.
     */
    then<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): $Utils.JsPromise<TResult1 | TResult2>
    /**
     * Attaches a callback for only the rejection of the Promise.
     * @param onrejected The callback to execute when the Promise is rejected.
     * @returns A Promise for the completion of the callback.
     */
    catch<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): $Utils.JsPromise<T | TResult>
    /**
     * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The
     * resolved value cannot be modified from the callback.
     * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected).
     * @returns A Promise for the completion of the callback.
     */
    finally(onfinally?: (() => void) | undefined | null): $Utils.JsPromise<T>
  }




  /**
   * Fields of the Punch model
   */
  interface PunchFieldRefs {
    readonly id: FieldRef<"Punch", 'String'>
    readonly tripId: FieldRef<"Punch", 'String'>
    readonly type: FieldRef<"Punch", 'PunchType'>
    readonly timestamp: FieldRef<"Punch", 'DateTime'>
    readonly latitude: FieldRef<"Punch", 'Float'>
    readonly longitude: FieldRef<"Punch", 'Float'>
    readonly address: FieldRef<"Punch", 'String'>
    readonly batteryPercent: FieldRef<"Punch", 'Float'>
    readonly gpsAccuracy: FieldRef<"Punch", 'Float'>
    readonly speed: FieldRef<"Punch", 'Float'>
    readonly isMockLocation: FieldRef<"Punch", 'Boolean'>
    readonly meetingSummary: FieldRef<"Punch", 'String'>
    readonly leadType: FieldRef<"Punch", 'LeadType'>
    readonly customerNotes: FieldRef<"Punch", 'String'>
    readonly createdAt: FieldRef<"Punch", 'DateTime'>
  }
    

  // Custom InputTypes
  /**
   * Punch findUnique
   */
  export type PunchFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Punch
     */
    select?: PunchSelect<ExtArgs> | null
    /**
     * Omit specific fields from the Punch
     */
    omit?: PunchOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: PunchInclude<ExtArgs> | null
    /**
     * Filter, which Punch to fetch.
     */
    where: PunchWhereUniqueInput
  }

  /**
   * Punch findUniqueOrThrow
   */
  export type PunchFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Punch
     */
    select?: PunchSelect<ExtArgs> | null
    /**
     * Omit specific fields from the Punch
     */
    omit?: PunchOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: PunchInclude<ExtArgs> | null
    /**
     * Filter, which Punch to fetch.
     */
    where: PunchWhereUniqueInput
  }

  /**
   * Punch findFirst
   */
  export type PunchFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Punch
     */
    select?: PunchSelect<ExtArgs> | null
    /**
     * Omit specific fields from the Punch
     */
    omit?: PunchOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: PunchInclude<ExtArgs> | null
    /**
     * Filter, which Punch to fetch.
     */
    where?: PunchWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Punches to fetch.
     */
    orderBy?: PunchOrderByWithRelationInput | PunchOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for Punches.
     */
    cursor?: PunchWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Punches from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` Punches.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of Punches.
     */
    distinct?: PunchScalarFieldEnum | PunchScalarFieldEnum[]
  }

  /**
   * Punch findFirstOrThrow
   */
  export type PunchFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Punch
     */
    select?: PunchSelect<ExtArgs> | null
    /**
     * Omit specific fields from the Punch
     */
    omit?: PunchOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: PunchInclude<ExtArgs> | null
    /**
     * Filter, which Punch to fetch.
     */
    where?: PunchWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Punches to fetch.
     */
    orderBy?: PunchOrderByWithRelationInput | PunchOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for Punches.
     */
    cursor?: PunchWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Punches from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` Punches.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of Punches.
     */
    distinct?: PunchScalarFieldEnum | PunchScalarFieldEnum[]
  }

  /**
   * Punch findMany
   */
  export type PunchFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Punch
     */
    select?: PunchSelect<ExtArgs> | null
    /**
     * Omit specific fields from the Punch
     */
    omit?: PunchOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: PunchInclude<ExtArgs> | null
    /**
     * Filter, which Punches to fetch.
     */
    where?: PunchWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Punches to fetch.
     */
    orderBy?: PunchOrderByWithRelationInput | PunchOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing Punches.
     */
    cursor?: PunchWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Punches from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` Punches.
     */
    skip?: number
    distinct?: PunchScalarFieldEnum | PunchScalarFieldEnum[]
  }

  /**
   * Punch create
   */
  export type PunchCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Punch
     */
    select?: PunchSelect<ExtArgs> | null
    /**
     * Omit specific fields from the Punch
     */
    omit?: PunchOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: PunchInclude<ExtArgs> | null
    /**
     * The data needed to create a Punch.
     */
    data: XOR<PunchCreateInput, PunchUncheckedCreateInput>
  }

  /**
   * Punch createMany
   */
  export type PunchCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many Punches.
     */
    data: PunchCreateManyInput | PunchCreateManyInput[]
  }

  /**
   * Punch createManyAndReturn
   */
  export type PunchCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Punch
     */
    select?: PunchSelectCreateManyAndReturn<ExtArgs> | null
    /**
     * Omit specific fields from the Punch
     */
    omit?: PunchOmit<ExtArgs> | null
    /**
     * The data used to create many Punches.
     */
    data: PunchCreateManyInput | PunchCreateManyInput[]
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: PunchIncludeCreateManyAndReturn<ExtArgs> | null
  }

  /**
   * Punch update
   */
  export type PunchUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Punch
     */
    select?: PunchSelect<ExtArgs> | null
    /**
     * Omit specific fields from the Punch
     */
    omit?: PunchOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: PunchInclude<ExtArgs> | null
    /**
     * The data needed to update a Punch.
     */
    data: XOR<PunchUpdateInput, PunchUncheckedUpdateInput>
    /**
     * Choose, which Punch to update.
     */
    where: PunchWhereUniqueInput
  }

  /**
   * Punch updateMany
   */
  export type PunchUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update Punches.
     */
    data: XOR<PunchUpdateManyMutationInput, PunchUncheckedUpdateManyInput>
    /**
     * Filter which Punches to update
     */
    where?: PunchWhereInput
    /**
     * Limit how many Punches to update.
     */
    limit?: number
  }

  /**
   * Punch updateManyAndReturn
   */
  export type PunchUpdateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Punch
     */
    select?: PunchSelectUpdateManyAndReturn<ExtArgs> | null
    /**
     * Omit specific fields from the Punch
     */
    omit?: PunchOmit<ExtArgs> | null
    /**
     * The data used to update Punches.
     */
    data: XOR<PunchUpdateManyMutationInput, PunchUncheckedUpdateManyInput>
    /**
     * Filter which Punches to update
     */
    where?: PunchWhereInput
    /**
     * Limit how many Punches to update.
     */
    limit?: number
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: PunchIncludeUpdateManyAndReturn<ExtArgs> | null
  }

  /**
   * Punch upsert
   */
  export type PunchUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Punch
     */
    select?: PunchSelect<ExtArgs> | null
    /**
     * Omit specific fields from the Punch
     */
    omit?: PunchOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: PunchInclude<ExtArgs> | null
    /**
     * The filter to search for the Punch to update in case it exists.
     */
    where: PunchWhereUniqueInput
    /**
     * In case the Punch found by the `where` argument doesn't exist, create a new Punch with this data.
     */
    create: XOR<PunchCreateInput, PunchUncheckedCreateInput>
    /**
     * In case the Punch was found with the provided `where` argument, update it with this data.
     */
    update: XOR<PunchUpdateInput, PunchUncheckedUpdateInput>
  }

  /**
   * Punch delete
   */
  export type PunchDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Punch
     */
    select?: PunchSelect<ExtArgs> | null
    /**
     * Omit specific fields from the Punch
     */
    omit?: PunchOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: PunchInclude<ExtArgs> | null
    /**
     * Filter which Punch to delete.
     */
    where: PunchWhereUniqueInput
  }

  /**
   * Punch deleteMany
   */
  export type PunchDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which Punches to delete
     */
    where?: PunchWhereInput
    /**
     * Limit how many Punches to delete.
     */
    limit?: number
  }

  /**
   * Punch without action
   */
  export type PunchDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Punch
     */
    select?: PunchSelect<ExtArgs> | null
    /**
     * Omit specific fields from the Punch
     */
    omit?: PunchOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: PunchInclude<ExtArgs> | null
  }


  /**
   * Model GpsPoint
   */

  export type AggregateGpsPoint = {
    _count: GpsPointCountAggregateOutputType | null
    _avg: GpsPointAvgAggregateOutputType | null
    _sum: GpsPointSumAggregateOutputType | null
    _min: GpsPointMinAggregateOutputType | null
    _max: GpsPointMaxAggregateOutputType | null
  }

  export type GpsPointAvgAggregateOutputType = {
    latitude: number | null
    longitude: number | null
    accuracy: number | null
    speed: number | null
    bearing: number | null
    batteryLevel: number | null
  }

  export type GpsPointSumAggregateOutputType = {
    latitude: number | null
    longitude: number | null
    accuracy: number | null
    speed: number | null
    bearing: number | null
    batteryLevel: number | null
  }

  export type GpsPointMinAggregateOutputType = {
    id: string | null
    tripId: string | null
    userId: string | null
    clientPointId: string | null
    latitude: number | null
    longitude: number | null
    accuracy: number | null
    speed: number | null
    bearing: number | null
    batteryLevel: number | null
    timestamp: Date | null
    isSmoothed: boolean | null
    createdAt: Date | null
  }

  export type GpsPointMaxAggregateOutputType = {
    id: string | null
    tripId: string | null
    userId: string | null
    clientPointId: string | null
    latitude: number | null
    longitude: number | null
    accuracy: number | null
    speed: number | null
    bearing: number | null
    batteryLevel: number | null
    timestamp: Date | null
    isSmoothed: boolean | null
    createdAt: Date | null
  }

  export type GpsPointCountAggregateOutputType = {
    id: number
    tripId: number
    userId: number
    clientPointId: number
    latitude: number
    longitude: number
    accuracy: number
    speed: number
    bearing: number
    batteryLevel: number
    timestamp: number
    isSmoothed: number
    createdAt: number
    _all: number
  }


  export type GpsPointAvgAggregateInputType = {
    latitude?: true
    longitude?: true
    accuracy?: true
    speed?: true
    bearing?: true
    batteryLevel?: true
  }

  export type GpsPointSumAggregateInputType = {
    latitude?: true
    longitude?: true
    accuracy?: true
    speed?: true
    bearing?: true
    batteryLevel?: true
  }

  export type GpsPointMinAggregateInputType = {
    id?: true
    tripId?: true
    userId?: true
    clientPointId?: true
    latitude?: true
    longitude?: true
    accuracy?: true
    speed?: true
    bearing?: true
    batteryLevel?: true
    timestamp?: true
    isSmoothed?: true
    createdAt?: true
  }

  export type GpsPointMaxAggregateInputType = {
    id?: true
    tripId?: true
    userId?: true
    clientPointId?: true
    latitude?: true
    longitude?: true
    accuracy?: true
    speed?: true
    bearing?: true
    batteryLevel?: true
    timestamp?: true
    isSmoothed?: true
    createdAt?: true
  }

  export type GpsPointCountAggregateInputType = {
    id?: true
    tripId?: true
    userId?: true
    clientPointId?: true
    latitude?: true
    longitude?: true
    accuracy?: true
    speed?: true
    bearing?: true
    batteryLevel?: true
    timestamp?: true
    isSmoothed?: true
    createdAt?: true
    _all?: true
  }

  export type GpsPointAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which GpsPoint to aggregate.
     */
    where?: GpsPointWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of GpsPoints to fetch.
     */
    orderBy?: GpsPointOrderByWithRelationInput | GpsPointOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: GpsPointWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` GpsPoints from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` GpsPoints.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned GpsPoints
    **/
    _count?: true | GpsPointCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to average
    **/
    _avg?: GpsPointAvgAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to sum
    **/
    _sum?: GpsPointSumAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: GpsPointMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: GpsPointMaxAggregateInputType
  }

  export type GetGpsPointAggregateType<T extends GpsPointAggregateArgs> = {
        [P in keyof T & keyof AggregateGpsPoint]: P extends '_count' | 'count'
      ? T[P] extends true
        ? number
        : GetScalarType<T[P], AggregateGpsPoint[P]>
      : GetScalarType<T[P], AggregateGpsPoint[P]>
  }




  export type GpsPointGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: GpsPointWhereInput
    orderBy?: GpsPointOrderByWithAggregationInput | GpsPointOrderByWithAggregationInput[]
    by: GpsPointScalarFieldEnum[] | GpsPointScalarFieldEnum
    having?: GpsPointScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: GpsPointCountAggregateInputType | true
    _avg?: GpsPointAvgAggregateInputType
    _sum?: GpsPointSumAggregateInputType
    _min?: GpsPointMinAggregateInputType
    _max?: GpsPointMaxAggregateInputType
  }

  export type GpsPointGroupByOutputType = {
    id: string
    tripId: string | null
    userId: string
    clientPointId: string | null
    latitude: number
    longitude: number
    accuracy: number | null
    speed: number | null
    bearing: number | null
    batteryLevel: number | null
    timestamp: Date
    isSmoothed: boolean
    createdAt: Date
    _count: GpsPointCountAggregateOutputType | null
    _avg: GpsPointAvgAggregateOutputType | null
    _sum: GpsPointSumAggregateOutputType | null
    _min: GpsPointMinAggregateOutputType | null
    _max: GpsPointMaxAggregateOutputType | null
  }

  type GetGpsPointGroupByPayload<T extends GpsPointGroupByArgs> = Prisma.PrismaPromise<
    Array<
      PickEnumerable<GpsPointGroupByOutputType, T['by']> &
        {
          [P in ((keyof T) & (keyof GpsPointGroupByOutputType))]: P extends '_count'
            ? T[P] extends boolean
              ? number
              : GetScalarType<T[P], GpsPointGroupByOutputType[P]>
            : GetScalarType<T[P], GpsPointGroupByOutputType[P]>
        }
      >
    >


  export type GpsPointSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    tripId?: boolean
    userId?: boolean
    clientPointId?: boolean
    latitude?: boolean
    longitude?: boolean
    accuracy?: boolean
    speed?: boolean
    bearing?: boolean
    batteryLevel?: boolean
    timestamp?: boolean
    isSmoothed?: boolean
    createdAt?: boolean
    trip?: boolean | GpsPoint$tripArgs<ExtArgs>
    user?: boolean | UserDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["gpsPoint"]>

  export type GpsPointSelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    tripId?: boolean
    userId?: boolean
    clientPointId?: boolean
    latitude?: boolean
    longitude?: boolean
    accuracy?: boolean
    speed?: boolean
    bearing?: boolean
    batteryLevel?: boolean
    timestamp?: boolean
    isSmoothed?: boolean
    createdAt?: boolean
    trip?: boolean | GpsPoint$tripArgs<ExtArgs>
    user?: boolean | UserDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["gpsPoint"]>

  export type GpsPointSelectUpdateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    tripId?: boolean
    userId?: boolean
    clientPointId?: boolean
    latitude?: boolean
    longitude?: boolean
    accuracy?: boolean
    speed?: boolean
    bearing?: boolean
    batteryLevel?: boolean
    timestamp?: boolean
    isSmoothed?: boolean
    createdAt?: boolean
    trip?: boolean | GpsPoint$tripArgs<ExtArgs>
    user?: boolean | UserDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["gpsPoint"]>

  export type GpsPointSelectScalar = {
    id?: boolean
    tripId?: boolean
    userId?: boolean
    clientPointId?: boolean
    latitude?: boolean
    longitude?: boolean
    accuracy?: boolean
    speed?: boolean
    bearing?: boolean
    batteryLevel?: boolean
    timestamp?: boolean
    isSmoothed?: boolean
    createdAt?: boolean
  }

  export type GpsPointOmit<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetOmit<"id" | "tripId" | "userId" | "clientPointId" | "latitude" | "longitude" | "accuracy" | "speed" | "bearing" | "batteryLevel" | "timestamp" | "isSmoothed" | "createdAt", ExtArgs["result"]["gpsPoint"]>
  export type GpsPointInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    trip?: boolean | GpsPoint$tripArgs<ExtArgs>
    user?: boolean | UserDefaultArgs<ExtArgs>
  }
  export type GpsPointIncludeCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    trip?: boolean | GpsPoint$tripArgs<ExtArgs>
    user?: boolean | UserDefaultArgs<ExtArgs>
  }
  export type GpsPointIncludeUpdateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    trip?: boolean | GpsPoint$tripArgs<ExtArgs>
    user?: boolean | UserDefaultArgs<ExtArgs>
  }

  export type $GpsPointPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "GpsPoint"
    objects: {
      trip: Prisma.$TripPayload<ExtArgs> | null
      user: Prisma.$UserPayload<ExtArgs>
    }
    scalars: $Extensions.GetPayloadResult<{
      id: string
      tripId: string | null
      userId: string
      clientPointId: string | null
      latitude: number
      longitude: number
      accuracy: number | null
      speed: number | null
      bearing: number | null
      batteryLevel: number | null
      timestamp: Date
      isSmoothed: boolean
      createdAt: Date
    }, ExtArgs["result"]["gpsPoint"]>
    composites: {}
  }

  type GpsPointGetPayload<S extends boolean | null | undefined | GpsPointDefaultArgs> = $Result.GetResult<Prisma.$GpsPointPayload, S>

  type GpsPointCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
    Omit<GpsPointFindManyArgs, 'select' | 'include' | 'distinct' | 'omit'> & {
      select?: GpsPointCountAggregateInputType | true
    }

  export interface GpsPointDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs, GlobalOmitOptions = {}> {
    [K: symbol]: { types: Prisma.TypeMap<ExtArgs>['model']['GpsPoint'], meta: { name: 'GpsPoint' } }
    /**
     * Find zero or one GpsPoint that matches the filter.
     * @param {GpsPointFindUniqueArgs} args - Arguments to find a GpsPoint
     * @example
     * // Get one GpsPoint
     * const gpsPoint = await prisma.gpsPoint.findUnique({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findUnique<T extends GpsPointFindUniqueArgs>(args: SelectSubset<T, GpsPointFindUniqueArgs<ExtArgs>>): Prisma__GpsPointClient<$Result.GetResult<Prisma.$GpsPointPayload<ExtArgs>, T, "findUnique", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>

    /**
     * Find one GpsPoint that matches the filter or throw an error with `error.code='P2025'`
     * if no matches were found.
     * @param {GpsPointFindUniqueOrThrowArgs} args - Arguments to find a GpsPoint
     * @example
     * // Get one GpsPoint
     * const gpsPoint = await prisma.gpsPoint.findUniqueOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findUniqueOrThrow<T extends GpsPointFindUniqueOrThrowArgs>(args: SelectSubset<T, GpsPointFindUniqueOrThrowArgs<ExtArgs>>): Prisma__GpsPointClient<$Result.GetResult<Prisma.$GpsPointPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Find the first GpsPoint that matches the filter.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {GpsPointFindFirstArgs} args - Arguments to find a GpsPoint
     * @example
     * // Get one GpsPoint
     * const gpsPoint = await prisma.gpsPoint.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends GpsPointFindFirstArgs>(args?: SelectSubset<T, GpsPointFindFirstArgs<ExtArgs>>): Prisma__GpsPointClient<$Result.GetResult<Prisma.$GpsPointPayload<ExtArgs>, T, "findFirst", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>

    /**
     * Find the first GpsPoint that matches the filter or
     * throw `PrismaKnownClientError` with `P2025` code if no matches were found.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {GpsPointFindFirstOrThrowArgs} args - Arguments to find a GpsPoint
     * @example
     * // Get one GpsPoint
     * const gpsPoint = await prisma.gpsPoint.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends GpsPointFindFirstOrThrowArgs>(args?: SelectSubset<T, GpsPointFindFirstOrThrowArgs<ExtArgs>>): Prisma__GpsPointClient<$Result.GetResult<Prisma.$GpsPointPayload<ExtArgs>, T, "findFirstOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Find zero or more GpsPoints that matches the filter.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {GpsPointFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all GpsPoints
     * const gpsPoints = await prisma.gpsPoint.findMany()
     * 
     * // Get first 10 GpsPoints
     * const gpsPoints = await prisma.gpsPoint.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const gpsPointWithIdOnly = await prisma.gpsPoint.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends GpsPointFindManyArgs>(args?: SelectSubset<T, GpsPointFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$GpsPointPayload<ExtArgs>, T, "findMany", GlobalOmitOptions>>

    /**
     * Create a GpsPoint.
     * @param {GpsPointCreateArgs} args - Arguments to create a GpsPoint.
     * @example
     * // Create one GpsPoint
     * const GpsPoint = await prisma.gpsPoint.create({
     *   data: {
     *     // ... data to create a GpsPoint
     *   }
     * })
     * 
     */
    create<T extends GpsPointCreateArgs>(args: SelectSubset<T, GpsPointCreateArgs<ExtArgs>>): Prisma__GpsPointClient<$Result.GetResult<Prisma.$GpsPointPayload<ExtArgs>, T, "create", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Create many GpsPoints.
     * @param {GpsPointCreateManyArgs} args - Arguments to create many GpsPoints.
     * @example
     * // Create many GpsPoints
     * const gpsPoint = await prisma.gpsPoint.createMany({
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     *     
     */
    createMany<T extends GpsPointCreateManyArgs>(args?: SelectSubset<T, GpsPointCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>

    /**
     * Create many GpsPoints and returns the data saved in the database.
     * @param {GpsPointCreateManyAndReturnArgs} args - Arguments to create many GpsPoints.
     * @example
     * // Create many GpsPoints
     * const gpsPoint = await prisma.gpsPoint.createManyAndReturn({
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * 
     * // Create many GpsPoints and only return the `id`
     * const gpsPointWithIdOnly = await prisma.gpsPoint.createManyAndReturn({
     *   select: { id: true },
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * 
     */
    createManyAndReturn<T extends GpsPointCreateManyAndReturnArgs>(args?: SelectSubset<T, GpsPointCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$GpsPointPayload<ExtArgs>, T, "createManyAndReturn", GlobalOmitOptions>>

    /**
     * Delete a GpsPoint.
     * @param {GpsPointDeleteArgs} args - Arguments to delete one GpsPoint.
     * @example
     * // Delete one GpsPoint
     * const GpsPoint = await prisma.gpsPoint.delete({
     *   where: {
     *     // ... filter to delete one GpsPoint
     *   }
     * })
     * 
     */
    delete<T extends GpsPointDeleteArgs>(args: SelectSubset<T, GpsPointDeleteArgs<ExtArgs>>): Prisma__GpsPointClient<$Result.GetResult<Prisma.$GpsPointPayload<ExtArgs>, T, "delete", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Update one GpsPoint.
     * @param {GpsPointUpdateArgs} args - Arguments to update one GpsPoint.
     * @example
     * // Update one GpsPoint
     * const gpsPoint = await prisma.gpsPoint.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends GpsPointUpdateArgs>(args: SelectSubset<T, GpsPointUpdateArgs<ExtArgs>>): Prisma__GpsPointClient<$Result.GetResult<Prisma.$GpsPointPayload<ExtArgs>, T, "update", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Delete zero or more GpsPoints.
     * @param {GpsPointDeleteManyArgs} args - Arguments to filter GpsPoints to delete.
     * @example
     * // Delete a few GpsPoints
     * const { count } = await prisma.gpsPoint.deleteMany({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     * 
     */
    deleteMany<T extends GpsPointDeleteManyArgs>(args?: SelectSubset<T, GpsPointDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>

    /**
     * Update zero or more GpsPoints.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {GpsPointUpdateManyArgs} args - Arguments to update one or more rows.
     * @example
     * // Update many GpsPoints
     * const gpsPoint = await prisma.gpsPoint.updateMany({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    updateMany<T extends GpsPointUpdateManyArgs>(args: SelectSubset<T, GpsPointUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>

    /**
     * Update zero or more GpsPoints and returns the data updated in the database.
     * @param {GpsPointUpdateManyAndReturnArgs} args - Arguments to update many GpsPoints.
     * @example
     * // Update many GpsPoints
     * const gpsPoint = await prisma.gpsPoint.updateManyAndReturn({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * 
     * // Update zero or more GpsPoints and only return the `id`
     * const gpsPointWithIdOnly = await prisma.gpsPoint.updateManyAndReturn({
     *   select: { id: true },
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * 
     */
    updateManyAndReturn<T extends GpsPointUpdateManyAndReturnArgs>(args: SelectSubset<T, GpsPointUpdateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$GpsPointPayload<ExtArgs>, T, "updateManyAndReturn", GlobalOmitOptions>>

    /**
     * Create or update one GpsPoint.
     * @param {GpsPointUpsertArgs} args - Arguments to update or create a GpsPoint.
     * @example
     * // Update or create a GpsPoint
     * const gpsPoint = await prisma.gpsPoint.upsert({
     *   create: {
     *     // ... data to create a GpsPoint
     *   },
     *   update: {
     *     // ... in case it already exists, update
     *   },
     *   where: {
     *     // ... the filter for the GpsPoint we want to update
     *   }
     * })
     */
    upsert<T extends GpsPointUpsertArgs>(args: SelectSubset<T, GpsPointUpsertArgs<ExtArgs>>): Prisma__GpsPointClient<$Result.GetResult<Prisma.$GpsPointPayload<ExtArgs>, T, "upsert", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>


    /**
     * Count the number of GpsPoints.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {GpsPointCountArgs} args - Arguments to filter GpsPoints to count.
     * @example
     * // Count the number of GpsPoints
     * const count = await prisma.gpsPoint.count({
     *   where: {
     *     // ... the filter for the GpsPoints we want to count
     *   }
     * })
    **/
    count<T extends GpsPointCountArgs>(
      args?: Subset<T, GpsPointCountArgs>,
    ): Prisma.PrismaPromise<
      T extends $Utils.Record<'select', any>
        ? T['select'] extends true
          ? number
          : GetScalarType<T['select'], GpsPointCountAggregateOutputType>
        : number
    >

    /**
     * Allows you to perform aggregations operations on a GpsPoint.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {GpsPointAggregateArgs} args - Select which aggregations you would like to apply and on what fields.
     * @example
     * // Ordered by age ascending
     * // Where email contains prisma.io
     * // Limited to the 10 users
     * const aggregations = await prisma.user.aggregate({
     *   _avg: {
     *     age: true,
     *   },
     *   where: {
     *     email: {
     *       contains: "prisma.io",
     *     },
     *   },
     *   orderBy: {
     *     age: "asc",
     *   },
     *   take: 10,
     * })
    **/
    aggregate<T extends GpsPointAggregateArgs>(args: Subset<T, GpsPointAggregateArgs>): Prisma.PrismaPromise<GetGpsPointAggregateType<T>>

    /**
     * Group by GpsPoint.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {GpsPointGroupByArgs} args - Group by arguments.
     * @example
     * // Group by city, order by createdAt, get count
     * const result = await prisma.user.groupBy({
     *   by: ['city', 'createdAt'],
     *   orderBy: {
     *     createdAt: true
     *   },
     *   _count: {
     *     _all: true
     *   },
     * })
     * 
    **/
    groupBy<
      T extends GpsPointGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: GpsPointGroupByArgs['orderBy'] }
        : { orderBy?: GpsPointGroupByArgs['orderBy'] },
      OrderFields extends ExcludeUnderscoreKeys<Keys<MaybeTupleToUnion<T['orderBy']>>>,
      ByFields extends MaybeTupleToUnion<T['by']>,
      ByValid extends Has<ByFields, OrderFields>,
      HavingFields extends GetHavingFields<T['having']>,
      HavingValid extends Has<ByFields, HavingFields>,
      ByEmpty extends T['by'] extends never[] ? True : False,
      InputErrors extends ByEmpty extends True
      ? `Error: "by" must not be empty.`
      : HavingValid extends False
      ? {
          [P in HavingFields]: P extends ByFields
            ? never
            : P extends string
            ? `Error: Field "${P}" used in "having" needs to be provided in "by".`
            : [
                Error,
                'Field ',
                P,
                ` in "having" needs to be provided in "by"`,
              ]
        }[HavingFields]
      : 'take' extends Keys<T>
      ? 'orderBy' extends Keys<T>
        ? ByValid extends True
          ? {}
          : {
              [P in OrderFields]: P extends ByFields
                ? never
                : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
            }[OrderFields]
        : 'Error: If you provide "take", you also need to provide "orderBy"'
      : 'skip' extends Keys<T>
      ? 'orderBy' extends Keys<T>
        ? ByValid extends True
          ? {}
          : {
              [P in OrderFields]: P extends ByFields
                ? never
                : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
            }[OrderFields]
        : 'Error: If you provide "skip", you also need to provide "orderBy"'
      : ByValid extends True
      ? {}
      : {
          [P in OrderFields]: P extends ByFields
            ? never
            : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
        }[OrderFields]
    >(args: SubsetIntersection<T, GpsPointGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetGpsPointGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the GpsPoint model
   */
  readonly fields: GpsPointFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for GpsPoint.
   * Why is this prefixed with `Prisma__`?
   * Because we want to prevent naming conflicts as mentioned in
   * https://github.com/prisma/prisma-client-js/issues/707
   */
  export interface Prisma__GpsPointClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs, GlobalOmitOptions = {}> extends Prisma.PrismaPromise<T> {
    readonly [Symbol.toStringTag]: "PrismaPromise"
    trip<T extends GpsPoint$tripArgs<ExtArgs> = {}>(args?: Subset<T, GpsPoint$tripArgs<ExtArgs>>): Prisma__TripClient<$Result.GetResult<Prisma.$TripPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>
    user<T extends UserDefaultArgs<ExtArgs> = {}>(args?: Subset<T, UserDefaultArgs<ExtArgs>>): Prisma__UserClient<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | Null, Null, ExtArgs, GlobalOmitOptions>
    /**
     * Attaches callbacks for the resolution and/or rejection of the Promise.
     * @param onfulfilled The callback to execute when the Promise is resolved.
     * @param onrejected The callback to execute when the Promise is rejected.
     * @returns A Promise for the completion of which ever callback is executed.
     */
    then<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): $Utils.JsPromise<TResult1 | TResult2>
    /**
     * Attaches a callback for only the rejection of the Promise.
     * @param onrejected The callback to execute when the Promise is rejected.
     * @returns A Promise for the completion of the callback.
     */
    catch<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): $Utils.JsPromise<T | TResult>
    /**
     * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The
     * resolved value cannot be modified from the callback.
     * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected).
     * @returns A Promise for the completion of the callback.
     */
    finally(onfinally?: (() => void) | undefined | null): $Utils.JsPromise<T>
  }




  /**
   * Fields of the GpsPoint model
   */
  interface GpsPointFieldRefs {
    readonly id: FieldRef<"GpsPoint", 'String'>
    readonly tripId: FieldRef<"GpsPoint", 'String'>
    readonly userId: FieldRef<"GpsPoint", 'String'>
    readonly clientPointId: FieldRef<"GpsPoint", 'String'>
    readonly latitude: FieldRef<"GpsPoint", 'Float'>
    readonly longitude: FieldRef<"GpsPoint", 'Float'>
    readonly accuracy: FieldRef<"GpsPoint", 'Float'>
    readonly speed: FieldRef<"GpsPoint", 'Float'>
    readonly bearing: FieldRef<"GpsPoint", 'Float'>
    readonly batteryLevel: FieldRef<"GpsPoint", 'Float'>
    readonly timestamp: FieldRef<"GpsPoint", 'DateTime'>
    readonly isSmoothed: FieldRef<"GpsPoint", 'Boolean'>
    readonly createdAt: FieldRef<"GpsPoint", 'DateTime'>
  }
    

  // Custom InputTypes
  /**
   * GpsPoint findUnique
   */
  export type GpsPointFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the GpsPoint
     */
    select?: GpsPointSelect<ExtArgs> | null
    /**
     * Omit specific fields from the GpsPoint
     */
    omit?: GpsPointOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GpsPointInclude<ExtArgs> | null
    /**
     * Filter, which GpsPoint to fetch.
     */
    where: GpsPointWhereUniqueInput
  }

  /**
   * GpsPoint findUniqueOrThrow
   */
  export type GpsPointFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the GpsPoint
     */
    select?: GpsPointSelect<ExtArgs> | null
    /**
     * Omit specific fields from the GpsPoint
     */
    omit?: GpsPointOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GpsPointInclude<ExtArgs> | null
    /**
     * Filter, which GpsPoint to fetch.
     */
    where: GpsPointWhereUniqueInput
  }

  /**
   * GpsPoint findFirst
   */
  export type GpsPointFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the GpsPoint
     */
    select?: GpsPointSelect<ExtArgs> | null
    /**
     * Omit specific fields from the GpsPoint
     */
    omit?: GpsPointOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GpsPointInclude<ExtArgs> | null
    /**
     * Filter, which GpsPoint to fetch.
     */
    where?: GpsPointWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of GpsPoints to fetch.
     */
    orderBy?: GpsPointOrderByWithRelationInput | GpsPointOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for GpsPoints.
     */
    cursor?: GpsPointWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` GpsPoints from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` GpsPoints.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of GpsPoints.
     */
    distinct?: GpsPointScalarFieldEnum | GpsPointScalarFieldEnum[]
  }

  /**
   * GpsPoint findFirstOrThrow
   */
  export type GpsPointFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the GpsPoint
     */
    select?: GpsPointSelect<ExtArgs> | null
    /**
     * Omit specific fields from the GpsPoint
     */
    omit?: GpsPointOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GpsPointInclude<ExtArgs> | null
    /**
     * Filter, which GpsPoint to fetch.
     */
    where?: GpsPointWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of GpsPoints to fetch.
     */
    orderBy?: GpsPointOrderByWithRelationInput | GpsPointOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for GpsPoints.
     */
    cursor?: GpsPointWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` GpsPoints from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` GpsPoints.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of GpsPoints.
     */
    distinct?: GpsPointScalarFieldEnum | GpsPointScalarFieldEnum[]
  }

  /**
   * GpsPoint findMany
   */
  export type GpsPointFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the GpsPoint
     */
    select?: GpsPointSelect<ExtArgs> | null
    /**
     * Omit specific fields from the GpsPoint
     */
    omit?: GpsPointOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GpsPointInclude<ExtArgs> | null
    /**
     * Filter, which GpsPoints to fetch.
     */
    where?: GpsPointWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of GpsPoints to fetch.
     */
    orderBy?: GpsPointOrderByWithRelationInput | GpsPointOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing GpsPoints.
     */
    cursor?: GpsPointWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` GpsPoints from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` GpsPoints.
     */
    skip?: number
    distinct?: GpsPointScalarFieldEnum | GpsPointScalarFieldEnum[]
  }

  /**
   * GpsPoint create
   */
  export type GpsPointCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the GpsPoint
     */
    select?: GpsPointSelect<ExtArgs> | null
    /**
     * Omit specific fields from the GpsPoint
     */
    omit?: GpsPointOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GpsPointInclude<ExtArgs> | null
    /**
     * The data needed to create a GpsPoint.
     */
    data: XOR<GpsPointCreateInput, GpsPointUncheckedCreateInput>
  }

  /**
   * GpsPoint createMany
   */
  export type GpsPointCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many GpsPoints.
     */
    data: GpsPointCreateManyInput | GpsPointCreateManyInput[]
  }

  /**
   * GpsPoint createManyAndReturn
   */
  export type GpsPointCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the GpsPoint
     */
    select?: GpsPointSelectCreateManyAndReturn<ExtArgs> | null
    /**
     * Omit specific fields from the GpsPoint
     */
    omit?: GpsPointOmit<ExtArgs> | null
    /**
     * The data used to create many GpsPoints.
     */
    data: GpsPointCreateManyInput | GpsPointCreateManyInput[]
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GpsPointIncludeCreateManyAndReturn<ExtArgs> | null
  }

  /**
   * GpsPoint update
   */
  export type GpsPointUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the GpsPoint
     */
    select?: GpsPointSelect<ExtArgs> | null
    /**
     * Omit specific fields from the GpsPoint
     */
    omit?: GpsPointOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GpsPointInclude<ExtArgs> | null
    /**
     * The data needed to update a GpsPoint.
     */
    data: XOR<GpsPointUpdateInput, GpsPointUncheckedUpdateInput>
    /**
     * Choose, which GpsPoint to update.
     */
    where: GpsPointWhereUniqueInput
  }

  /**
   * GpsPoint updateMany
   */
  export type GpsPointUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update GpsPoints.
     */
    data: XOR<GpsPointUpdateManyMutationInput, GpsPointUncheckedUpdateManyInput>
    /**
     * Filter which GpsPoints to update
     */
    where?: GpsPointWhereInput
    /**
     * Limit how many GpsPoints to update.
     */
    limit?: number
  }

  /**
   * GpsPoint updateManyAndReturn
   */
  export type GpsPointUpdateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the GpsPoint
     */
    select?: GpsPointSelectUpdateManyAndReturn<ExtArgs> | null
    /**
     * Omit specific fields from the GpsPoint
     */
    omit?: GpsPointOmit<ExtArgs> | null
    /**
     * The data used to update GpsPoints.
     */
    data: XOR<GpsPointUpdateManyMutationInput, GpsPointUncheckedUpdateManyInput>
    /**
     * Filter which GpsPoints to update
     */
    where?: GpsPointWhereInput
    /**
     * Limit how many GpsPoints to update.
     */
    limit?: number
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GpsPointIncludeUpdateManyAndReturn<ExtArgs> | null
  }

  /**
   * GpsPoint upsert
   */
  export type GpsPointUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the GpsPoint
     */
    select?: GpsPointSelect<ExtArgs> | null
    /**
     * Omit specific fields from the GpsPoint
     */
    omit?: GpsPointOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GpsPointInclude<ExtArgs> | null
    /**
     * The filter to search for the GpsPoint to update in case it exists.
     */
    where: GpsPointWhereUniqueInput
    /**
     * In case the GpsPoint found by the `where` argument doesn't exist, create a new GpsPoint with this data.
     */
    create: XOR<GpsPointCreateInput, GpsPointUncheckedCreateInput>
    /**
     * In case the GpsPoint was found with the provided `where` argument, update it with this data.
     */
    update: XOR<GpsPointUpdateInput, GpsPointUncheckedUpdateInput>
  }

  /**
   * GpsPoint delete
   */
  export type GpsPointDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the GpsPoint
     */
    select?: GpsPointSelect<ExtArgs> | null
    /**
     * Omit specific fields from the GpsPoint
     */
    omit?: GpsPointOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GpsPointInclude<ExtArgs> | null
    /**
     * Filter which GpsPoint to delete.
     */
    where: GpsPointWhereUniqueInput
  }

  /**
   * GpsPoint deleteMany
   */
  export type GpsPointDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which GpsPoints to delete
     */
    where?: GpsPointWhereInput
    /**
     * Limit how many GpsPoints to delete.
     */
    limit?: number
  }

  /**
   * GpsPoint.trip
   */
  export type GpsPoint$tripArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Trip
     */
    select?: TripSelect<ExtArgs> | null
    /**
     * Omit specific fields from the Trip
     */
    omit?: TripOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: TripInclude<ExtArgs> | null
    where?: TripWhereInput
  }

  /**
   * GpsPoint without action
   */
  export type GpsPointDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the GpsPoint
     */
    select?: GpsPointSelect<ExtArgs> | null
    /**
     * Omit specific fields from the GpsPoint
     */
    omit?: GpsPointOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GpsPointInclude<ExtArgs> | null
  }


  /**
   * Model GpsStop
   */

  export type AggregateGpsStop = {
    _count: GpsStopCountAggregateOutputType | null
    _avg: GpsStopAvgAggregateOutputType | null
    _sum: GpsStopSumAggregateOutputType | null
    _min: GpsStopMinAggregateOutputType | null
    _max: GpsStopMaxAggregateOutputType | null
  }

  export type GpsStopAvgAggregateOutputType = {
    latitude: number | null
    longitude: number | null
    duration: number | null
  }

  export type GpsStopSumAggregateOutputType = {
    latitude: number | null
    longitude: number | null
    duration: number | null
  }

  export type GpsStopMinAggregateOutputType = {
    id: string | null
    tripId: string | null
    latitude: number | null
    longitude: number | null
    startedAt: Date | null
    endedAt: Date | null
    duration: number | null
    address: string | null
  }

  export type GpsStopMaxAggregateOutputType = {
    id: string | null
    tripId: string | null
    latitude: number | null
    longitude: number | null
    startedAt: Date | null
    endedAt: Date | null
    duration: number | null
    address: string | null
  }

  export type GpsStopCountAggregateOutputType = {
    id: number
    tripId: number
    latitude: number
    longitude: number
    startedAt: number
    endedAt: number
    duration: number
    address: number
    _all: number
  }


  export type GpsStopAvgAggregateInputType = {
    latitude?: true
    longitude?: true
    duration?: true
  }

  export type GpsStopSumAggregateInputType = {
    latitude?: true
    longitude?: true
    duration?: true
  }

  export type GpsStopMinAggregateInputType = {
    id?: true
    tripId?: true
    latitude?: true
    longitude?: true
    startedAt?: true
    endedAt?: true
    duration?: true
    address?: true
  }

  export type GpsStopMaxAggregateInputType = {
    id?: true
    tripId?: true
    latitude?: true
    longitude?: true
    startedAt?: true
    endedAt?: true
    duration?: true
    address?: true
  }

  export type GpsStopCountAggregateInputType = {
    id?: true
    tripId?: true
    latitude?: true
    longitude?: true
    startedAt?: true
    endedAt?: true
    duration?: true
    address?: true
    _all?: true
  }

  export type GpsStopAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which GpsStop to aggregate.
     */
    where?: GpsStopWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of GpsStops to fetch.
     */
    orderBy?: GpsStopOrderByWithRelationInput | GpsStopOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: GpsStopWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` GpsStops from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` GpsStops.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned GpsStops
    **/
    _count?: true | GpsStopCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to average
    **/
    _avg?: GpsStopAvgAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to sum
    **/
    _sum?: GpsStopSumAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: GpsStopMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: GpsStopMaxAggregateInputType
  }

  export type GetGpsStopAggregateType<T extends GpsStopAggregateArgs> = {
        [P in keyof T & keyof AggregateGpsStop]: P extends '_count' | 'count'
      ? T[P] extends true
        ? number
        : GetScalarType<T[P], AggregateGpsStop[P]>
      : GetScalarType<T[P], AggregateGpsStop[P]>
  }




  export type GpsStopGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: GpsStopWhereInput
    orderBy?: GpsStopOrderByWithAggregationInput | GpsStopOrderByWithAggregationInput[]
    by: GpsStopScalarFieldEnum[] | GpsStopScalarFieldEnum
    having?: GpsStopScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: GpsStopCountAggregateInputType | true
    _avg?: GpsStopAvgAggregateInputType
    _sum?: GpsStopSumAggregateInputType
    _min?: GpsStopMinAggregateInputType
    _max?: GpsStopMaxAggregateInputType
  }

  export type GpsStopGroupByOutputType = {
    id: string
    tripId: string
    latitude: number
    longitude: number
    startedAt: Date
    endedAt: Date | null
    duration: number | null
    address: string | null
    _count: GpsStopCountAggregateOutputType | null
    _avg: GpsStopAvgAggregateOutputType | null
    _sum: GpsStopSumAggregateOutputType | null
    _min: GpsStopMinAggregateOutputType | null
    _max: GpsStopMaxAggregateOutputType | null
  }

  type GetGpsStopGroupByPayload<T extends GpsStopGroupByArgs> = Prisma.PrismaPromise<
    Array<
      PickEnumerable<GpsStopGroupByOutputType, T['by']> &
        {
          [P in ((keyof T) & (keyof GpsStopGroupByOutputType))]: P extends '_count'
            ? T[P] extends boolean
              ? number
              : GetScalarType<T[P], GpsStopGroupByOutputType[P]>
            : GetScalarType<T[P], GpsStopGroupByOutputType[P]>
        }
      >
    >


  export type GpsStopSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    tripId?: boolean
    latitude?: boolean
    longitude?: boolean
    startedAt?: boolean
    endedAt?: boolean
    duration?: boolean
    address?: boolean
    trip?: boolean | TripDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["gpsStop"]>

  export type GpsStopSelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    tripId?: boolean
    latitude?: boolean
    longitude?: boolean
    startedAt?: boolean
    endedAt?: boolean
    duration?: boolean
    address?: boolean
    trip?: boolean | TripDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["gpsStop"]>

  export type GpsStopSelectUpdateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    tripId?: boolean
    latitude?: boolean
    longitude?: boolean
    startedAt?: boolean
    endedAt?: boolean
    duration?: boolean
    address?: boolean
    trip?: boolean | TripDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["gpsStop"]>

  export type GpsStopSelectScalar = {
    id?: boolean
    tripId?: boolean
    latitude?: boolean
    longitude?: boolean
    startedAt?: boolean
    endedAt?: boolean
    duration?: boolean
    address?: boolean
  }

  export type GpsStopOmit<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetOmit<"id" | "tripId" | "latitude" | "longitude" | "startedAt" | "endedAt" | "duration" | "address", ExtArgs["result"]["gpsStop"]>
  export type GpsStopInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    trip?: boolean | TripDefaultArgs<ExtArgs>
  }
  export type GpsStopIncludeCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    trip?: boolean | TripDefaultArgs<ExtArgs>
  }
  export type GpsStopIncludeUpdateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    trip?: boolean | TripDefaultArgs<ExtArgs>
  }

  export type $GpsStopPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "GpsStop"
    objects: {
      trip: Prisma.$TripPayload<ExtArgs>
    }
    scalars: $Extensions.GetPayloadResult<{
      id: string
      tripId: string
      latitude: number
      longitude: number
      startedAt: Date
      endedAt: Date | null
      duration: number | null
      address: string | null
    }, ExtArgs["result"]["gpsStop"]>
    composites: {}
  }

  type GpsStopGetPayload<S extends boolean | null | undefined | GpsStopDefaultArgs> = $Result.GetResult<Prisma.$GpsStopPayload, S>

  type GpsStopCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
    Omit<GpsStopFindManyArgs, 'select' | 'include' | 'distinct' | 'omit'> & {
      select?: GpsStopCountAggregateInputType | true
    }

  export interface GpsStopDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs, GlobalOmitOptions = {}> {
    [K: symbol]: { types: Prisma.TypeMap<ExtArgs>['model']['GpsStop'], meta: { name: 'GpsStop' } }
    /**
     * Find zero or one GpsStop that matches the filter.
     * @param {GpsStopFindUniqueArgs} args - Arguments to find a GpsStop
     * @example
     * // Get one GpsStop
     * const gpsStop = await prisma.gpsStop.findUnique({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findUnique<T extends GpsStopFindUniqueArgs>(args: SelectSubset<T, GpsStopFindUniqueArgs<ExtArgs>>): Prisma__GpsStopClient<$Result.GetResult<Prisma.$GpsStopPayload<ExtArgs>, T, "findUnique", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>

    /**
     * Find one GpsStop that matches the filter or throw an error with `error.code='P2025'`
     * if no matches were found.
     * @param {GpsStopFindUniqueOrThrowArgs} args - Arguments to find a GpsStop
     * @example
     * // Get one GpsStop
     * const gpsStop = await prisma.gpsStop.findUniqueOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findUniqueOrThrow<T extends GpsStopFindUniqueOrThrowArgs>(args: SelectSubset<T, GpsStopFindUniqueOrThrowArgs<ExtArgs>>): Prisma__GpsStopClient<$Result.GetResult<Prisma.$GpsStopPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Find the first GpsStop that matches the filter.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {GpsStopFindFirstArgs} args - Arguments to find a GpsStop
     * @example
     * // Get one GpsStop
     * const gpsStop = await prisma.gpsStop.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends GpsStopFindFirstArgs>(args?: SelectSubset<T, GpsStopFindFirstArgs<ExtArgs>>): Prisma__GpsStopClient<$Result.GetResult<Prisma.$GpsStopPayload<ExtArgs>, T, "findFirst", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>

    /**
     * Find the first GpsStop that matches the filter or
     * throw `PrismaKnownClientError` with `P2025` code if no matches were found.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {GpsStopFindFirstOrThrowArgs} args - Arguments to find a GpsStop
     * @example
     * // Get one GpsStop
     * const gpsStop = await prisma.gpsStop.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends GpsStopFindFirstOrThrowArgs>(args?: SelectSubset<T, GpsStopFindFirstOrThrowArgs<ExtArgs>>): Prisma__GpsStopClient<$Result.GetResult<Prisma.$GpsStopPayload<ExtArgs>, T, "findFirstOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Find zero or more GpsStops that matches the filter.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {GpsStopFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all GpsStops
     * const gpsStops = await prisma.gpsStop.findMany()
     * 
     * // Get first 10 GpsStops
     * const gpsStops = await prisma.gpsStop.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const gpsStopWithIdOnly = await prisma.gpsStop.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends GpsStopFindManyArgs>(args?: SelectSubset<T, GpsStopFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$GpsStopPayload<ExtArgs>, T, "findMany", GlobalOmitOptions>>

    /**
     * Create a GpsStop.
     * @param {GpsStopCreateArgs} args - Arguments to create a GpsStop.
     * @example
     * // Create one GpsStop
     * const GpsStop = await prisma.gpsStop.create({
     *   data: {
     *     // ... data to create a GpsStop
     *   }
     * })
     * 
     */
    create<T extends GpsStopCreateArgs>(args: SelectSubset<T, GpsStopCreateArgs<ExtArgs>>): Prisma__GpsStopClient<$Result.GetResult<Prisma.$GpsStopPayload<ExtArgs>, T, "create", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Create many GpsStops.
     * @param {GpsStopCreateManyArgs} args - Arguments to create many GpsStops.
     * @example
     * // Create many GpsStops
     * const gpsStop = await prisma.gpsStop.createMany({
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     *     
     */
    createMany<T extends GpsStopCreateManyArgs>(args?: SelectSubset<T, GpsStopCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>

    /**
     * Create many GpsStops and returns the data saved in the database.
     * @param {GpsStopCreateManyAndReturnArgs} args - Arguments to create many GpsStops.
     * @example
     * // Create many GpsStops
     * const gpsStop = await prisma.gpsStop.createManyAndReturn({
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * 
     * // Create many GpsStops and only return the `id`
     * const gpsStopWithIdOnly = await prisma.gpsStop.createManyAndReturn({
     *   select: { id: true },
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * 
     */
    createManyAndReturn<T extends GpsStopCreateManyAndReturnArgs>(args?: SelectSubset<T, GpsStopCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$GpsStopPayload<ExtArgs>, T, "createManyAndReturn", GlobalOmitOptions>>

    /**
     * Delete a GpsStop.
     * @param {GpsStopDeleteArgs} args - Arguments to delete one GpsStop.
     * @example
     * // Delete one GpsStop
     * const GpsStop = await prisma.gpsStop.delete({
     *   where: {
     *     // ... filter to delete one GpsStop
     *   }
     * })
     * 
     */
    delete<T extends GpsStopDeleteArgs>(args: SelectSubset<T, GpsStopDeleteArgs<ExtArgs>>): Prisma__GpsStopClient<$Result.GetResult<Prisma.$GpsStopPayload<ExtArgs>, T, "delete", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Update one GpsStop.
     * @param {GpsStopUpdateArgs} args - Arguments to update one GpsStop.
     * @example
     * // Update one GpsStop
     * const gpsStop = await prisma.gpsStop.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends GpsStopUpdateArgs>(args: SelectSubset<T, GpsStopUpdateArgs<ExtArgs>>): Prisma__GpsStopClient<$Result.GetResult<Prisma.$GpsStopPayload<ExtArgs>, T, "update", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Delete zero or more GpsStops.
     * @param {GpsStopDeleteManyArgs} args - Arguments to filter GpsStops to delete.
     * @example
     * // Delete a few GpsStops
     * const { count } = await prisma.gpsStop.deleteMany({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     * 
     */
    deleteMany<T extends GpsStopDeleteManyArgs>(args?: SelectSubset<T, GpsStopDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>

    /**
     * Update zero or more GpsStops.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {GpsStopUpdateManyArgs} args - Arguments to update one or more rows.
     * @example
     * // Update many GpsStops
     * const gpsStop = await prisma.gpsStop.updateMany({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    updateMany<T extends GpsStopUpdateManyArgs>(args: SelectSubset<T, GpsStopUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>

    /**
     * Update zero or more GpsStops and returns the data updated in the database.
     * @param {GpsStopUpdateManyAndReturnArgs} args - Arguments to update many GpsStops.
     * @example
     * // Update many GpsStops
     * const gpsStop = await prisma.gpsStop.updateManyAndReturn({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * 
     * // Update zero or more GpsStops and only return the `id`
     * const gpsStopWithIdOnly = await prisma.gpsStop.updateManyAndReturn({
     *   select: { id: true },
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * 
     */
    updateManyAndReturn<T extends GpsStopUpdateManyAndReturnArgs>(args: SelectSubset<T, GpsStopUpdateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$GpsStopPayload<ExtArgs>, T, "updateManyAndReturn", GlobalOmitOptions>>

    /**
     * Create or update one GpsStop.
     * @param {GpsStopUpsertArgs} args - Arguments to update or create a GpsStop.
     * @example
     * // Update or create a GpsStop
     * const gpsStop = await prisma.gpsStop.upsert({
     *   create: {
     *     // ... data to create a GpsStop
     *   },
     *   update: {
     *     // ... in case it already exists, update
     *   },
     *   where: {
     *     // ... the filter for the GpsStop we want to update
     *   }
     * })
     */
    upsert<T extends GpsStopUpsertArgs>(args: SelectSubset<T, GpsStopUpsertArgs<ExtArgs>>): Prisma__GpsStopClient<$Result.GetResult<Prisma.$GpsStopPayload<ExtArgs>, T, "upsert", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>


    /**
     * Count the number of GpsStops.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {GpsStopCountArgs} args - Arguments to filter GpsStops to count.
     * @example
     * // Count the number of GpsStops
     * const count = await prisma.gpsStop.count({
     *   where: {
     *     // ... the filter for the GpsStops we want to count
     *   }
     * })
    **/
    count<T extends GpsStopCountArgs>(
      args?: Subset<T, GpsStopCountArgs>,
    ): Prisma.PrismaPromise<
      T extends $Utils.Record<'select', any>
        ? T['select'] extends true
          ? number
          : GetScalarType<T['select'], GpsStopCountAggregateOutputType>
        : number
    >

    /**
     * Allows you to perform aggregations operations on a GpsStop.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {GpsStopAggregateArgs} args - Select which aggregations you would like to apply and on what fields.
     * @example
     * // Ordered by age ascending
     * // Where email contains prisma.io
     * // Limited to the 10 users
     * const aggregations = await prisma.user.aggregate({
     *   _avg: {
     *     age: true,
     *   },
     *   where: {
     *     email: {
     *       contains: "prisma.io",
     *     },
     *   },
     *   orderBy: {
     *     age: "asc",
     *   },
     *   take: 10,
     * })
    **/
    aggregate<T extends GpsStopAggregateArgs>(args: Subset<T, GpsStopAggregateArgs>): Prisma.PrismaPromise<GetGpsStopAggregateType<T>>

    /**
     * Group by GpsStop.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {GpsStopGroupByArgs} args - Group by arguments.
     * @example
     * // Group by city, order by createdAt, get count
     * const result = await prisma.user.groupBy({
     *   by: ['city', 'createdAt'],
     *   orderBy: {
     *     createdAt: true
     *   },
     *   _count: {
     *     _all: true
     *   },
     * })
     * 
    **/
    groupBy<
      T extends GpsStopGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: GpsStopGroupByArgs['orderBy'] }
        : { orderBy?: GpsStopGroupByArgs['orderBy'] },
      OrderFields extends ExcludeUnderscoreKeys<Keys<MaybeTupleToUnion<T['orderBy']>>>,
      ByFields extends MaybeTupleToUnion<T['by']>,
      ByValid extends Has<ByFields, OrderFields>,
      HavingFields extends GetHavingFields<T['having']>,
      HavingValid extends Has<ByFields, HavingFields>,
      ByEmpty extends T['by'] extends never[] ? True : False,
      InputErrors extends ByEmpty extends True
      ? `Error: "by" must not be empty.`
      : HavingValid extends False
      ? {
          [P in HavingFields]: P extends ByFields
            ? never
            : P extends string
            ? `Error: Field "${P}" used in "having" needs to be provided in "by".`
            : [
                Error,
                'Field ',
                P,
                ` in "having" needs to be provided in "by"`,
              ]
        }[HavingFields]
      : 'take' extends Keys<T>
      ? 'orderBy' extends Keys<T>
        ? ByValid extends True
          ? {}
          : {
              [P in OrderFields]: P extends ByFields
                ? never
                : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
            }[OrderFields]
        : 'Error: If you provide "take", you also need to provide "orderBy"'
      : 'skip' extends Keys<T>
      ? 'orderBy' extends Keys<T>
        ? ByValid extends True
          ? {}
          : {
              [P in OrderFields]: P extends ByFields
                ? never
                : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
            }[OrderFields]
        : 'Error: If you provide "skip", you also need to provide "orderBy"'
      : ByValid extends True
      ? {}
      : {
          [P in OrderFields]: P extends ByFields
            ? never
            : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
        }[OrderFields]
    >(args: SubsetIntersection<T, GpsStopGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetGpsStopGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the GpsStop model
   */
  readonly fields: GpsStopFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for GpsStop.
   * Why is this prefixed with `Prisma__`?
   * Because we want to prevent naming conflicts as mentioned in
   * https://github.com/prisma/prisma-client-js/issues/707
   */
  export interface Prisma__GpsStopClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs, GlobalOmitOptions = {}> extends Prisma.PrismaPromise<T> {
    readonly [Symbol.toStringTag]: "PrismaPromise"
    trip<T extends TripDefaultArgs<ExtArgs> = {}>(args?: Subset<T, TripDefaultArgs<ExtArgs>>): Prisma__TripClient<$Result.GetResult<Prisma.$TripPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | Null, Null, ExtArgs, GlobalOmitOptions>
    /**
     * Attaches callbacks for the resolution and/or rejection of the Promise.
     * @param onfulfilled The callback to execute when the Promise is resolved.
     * @param onrejected The callback to execute when the Promise is rejected.
     * @returns A Promise for the completion of which ever callback is executed.
     */
    then<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): $Utils.JsPromise<TResult1 | TResult2>
    /**
     * Attaches a callback for only the rejection of the Promise.
     * @param onrejected The callback to execute when the Promise is rejected.
     * @returns A Promise for the completion of the callback.
     */
    catch<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): $Utils.JsPromise<T | TResult>
    /**
     * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The
     * resolved value cannot be modified from the callback.
     * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected).
     * @returns A Promise for the completion of the callback.
     */
    finally(onfinally?: (() => void) | undefined | null): $Utils.JsPromise<T>
  }




  /**
   * Fields of the GpsStop model
   */
  interface GpsStopFieldRefs {
    readonly id: FieldRef<"GpsStop", 'String'>
    readonly tripId: FieldRef<"GpsStop", 'String'>
    readonly latitude: FieldRef<"GpsStop", 'Float'>
    readonly longitude: FieldRef<"GpsStop", 'Float'>
    readonly startedAt: FieldRef<"GpsStop", 'DateTime'>
    readonly endedAt: FieldRef<"GpsStop", 'DateTime'>
    readonly duration: FieldRef<"GpsStop", 'Int'>
    readonly address: FieldRef<"GpsStop", 'String'>
  }
    

  // Custom InputTypes
  /**
   * GpsStop findUnique
   */
  export type GpsStopFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the GpsStop
     */
    select?: GpsStopSelect<ExtArgs> | null
    /**
     * Omit specific fields from the GpsStop
     */
    omit?: GpsStopOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GpsStopInclude<ExtArgs> | null
    /**
     * Filter, which GpsStop to fetch.
     */
    where: GpsStopWhereUniqueInput
  }

  /**
   * GpsStop findUniqueOrThrow
   */
  export type GpsStopFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the GpsStop
     */
    select?: GpsStopSelect<ExtArgs> | null
    /**
     * Omit specific fields from the GpsStop
     */
    omit?: GpsStopOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GpsStopInclude<ExtArgs> | null
    /**
     * Filter, which GpsStop to fetch.
     */
    where: GpsStopWhereUniqueInput
  }

  /**
   * GpsStop findFirst
   */
  export type GpsStopFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the GpsStop
     */
    select?: GpsStopSelect<ExtArgs> | null
    /**
     * Omit specific fields from the GpsStop
     */
    omit?: GpsStopOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GpsStopInclude<ExtArgs> | null
    /**
     * Filter, which GpsStop to fetch.
     */
    where?: GpsStopWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of GpsStops to fetch.
     */
    orderBy?: GpsStopOrderByWithRelationInput | GpsStopOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for GpsStops.
     */
    cursor?: GpsStopWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` GpsStops from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` GpsStops.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of GpsStops.
     */
    distinct?: GpsStopScalarFieldEnum | GpsStopScalarFieldEnum[]
  }

  /**
   * GpsStop findFirstOrThrow
   */
  export type GpsStopFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the GpsStop
     */
    select?: GpsStopSelect<ExtArgs> | null
    /**
     * Omit specific fields from the GpsStop
     */
    omit?: GpsStopOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GpsStopInclude<ExtArgs> | null
    /**
     * Filter, which GpsStop to fetch.
     */
    where?: GpsStopWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of GpsStops to fetch.
     */
    orderBy?: GpsStopOrderByWithRelationInput | GpsStopOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for GpsStops.
     */
    cursor?: GpsStopWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` GpsStops from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` GpsStops.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of GpsStops.
     */
    distinct?: GpsStopScalarFieldEnum | GpsStopScalarFieldEnum[]
  }

  /**
   * GpsStop findMany
   */
  export type GpsStopFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the GpsStop
     */
    select?: GpsStopSelect<ExtArgs> | null
    /**
     * Omit specific fields from the GpsStop
     */
    omit?: GpsStopOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GpsStopInclude<ExtArgs> | null
    /**
     * Filter, which GpsStops to fetch.
     */
    where?: GpsStopWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of GpsStops to fetch.
     */
    orderBy?: GpsStopOrderByWithRelationInput | GpsStopOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing GpsStops.
     */
    cursor?: GpsStopWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` GpsStops from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` GpsStops.
     */
    skip?: number
    distinct?: GpsStopScalarFieldEnum | GpsStopScalarFieldEnum[]
  }

  /**
   * GpsStop create
   */
  export type GpsStopCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the GpsStop
     */
    select?: GpsStopSelect<ExtArgs> | null
    /**
     * Omit specific fields from the GpsStop
     */
    omit?: GpsStopOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GpsStopInclude<ExtArgs> | null
    /**
     * The data needed to create a GpsStop.
     */
    data: XOR<GpsStopCreateInput, GpsStopUncheckedCreateInput>
  }

  /**
   * GpsStop createMany
   */
  export type GpsStopCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many GpsStops.
     */
    data: GpsStopCreateManyInput | GpsStopCreateManyInput[]
  }

  /**
   * GpsStop createManyAndReturn
   */
  export type GpsStopCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the GpsStop
     */
    select?: GpsStopSelectCreateManyAndReturn<ExtArgs> | null
    /**
     * Omit specific fields from the GpsStop
     */
    omit?: GpsStopOmit<ExtArgs> | null
    /**
     * The data used to create many GpsStops.
     */
    data: GpsStopCreateManyInput | GpsStopCreateManyInput[]
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GpsStopIncludeCreateManyAndReturn<ExtArgs> | null
  }

  /**
   * GpsStop update
   */
  export type GpsStopUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the GpsStop
     */
    select?: GpsStopSelect<ExtArgs> | null
    /**
     * Omit specific fields from the GpsStop
     */
    omit?: GpsStopOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GpsStopInclude<ExtArgs> | null
    /**
     * The data needed to update a GpsStop.
     */
    data: XOR<GpsStopUpdateInput, GpsStopUncheckedUpdateInput>
    /**
     * Choose, which GpsStop to update.
     */
    where: GpsStopWhereUniqueInput
  }

  /**
   * GpsStop updateMany
   */
  export type GpsStopUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update GpsStops.
     */
    data: XOR<GpsStopUpdateManyMutationInput, GpsStopUncheckedUpdateManyInput>
    /**
     * Filter which GpsStops to update
     */
    where?: GpsStopWhereInput
    /**
     * Limit how many GpsStops to update.
     */
    limit?: number
  }

  /**
   * GpsStop updateManyAndReturn
   */
  export type GpsStopUpdateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the GpsStop
     */
    select?: GpsStopSelectUpdateManyAndReturn<ExtArgs> | null
    /**
     * Omit specific fields from the GpsStop
     */
    omit?: GpsStopOmit<ExtArgs> | null
    /**
     * The data used to update GpsStops.
     */
    data: XOR<GpsStopUpdateManyMutationInput, GpsStopUncheckedUpdateManyInput>
    /**
     * Filter which GpsStops to update
     */
    where?: GpsStopWhereInput
    /**
     * Limit how many GpsStops to update.
     */
    limit?: number
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GpsStopIncludeUpdateManyAndReturn<ExtArgs> | null
  }

  /**
   * GpsStop upsert
   */
  export type GpsStopUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the GpsStop
     */
    select?: GpsStopSelect<ExtArgs> | null
    /**
     * Omit specific fields from the GpsStop
     */
    omit?: GpsStopOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GpsStopInclude<ExtArgs> | null
    /**
     * The filter to search for the GpsStop to update in case it exists.
     */
    where: GpsStopWhereUniqueInput
    /**
     * In case the GpsStop found by the `where` argument doesn't exist, create a new GpsStop with this data.
     */
    create: XOR<GpsStopCreateInput, GpsStopUncheckedCreateInput>
    /**
     * In case the GpsStop was found with the provided `where` argument, update it with this data.
     */
    update: XOR<GpsStopUpdateInput, GpsStopUncheckedUpdateInput>
  }

  /**
   * GpsStop delete
   */
  export type GpsStopDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the GpsStop
     */
    select?: GpsStopSelect<ExtArgs> | null
    /**
     * Omit specific fields from the GpsStop
     */
    omit?: GpsStopOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GpsStopInclude<ExtArgs> | null
    /**
     * Filter which GpsStop to delete.
     */
    where: GpsStopWhereUniqueInput
  }

  /**
   * GpsStop deleteMany
   */
  export type GpsStopDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which GpsStops to delete
     */
    where?: GpsStopWhereInput
    /**
     * Limit how many GpsStops to delete.
     */
    limit?: number
  }

  /**
   * GpsStop without action
   */
  export type GpsStopDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the GpsStop
     */
    select?: GpsStopSelect<ExtArgs> | null
    /**
     * Omit specific fields from the GpsStop
     */
    omit?: GpsStopOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GpsStopInclude<ExtArgs> | null
  }


  /**
   * Model Notification
   */

  export type AggregateNotification = {
    _count: NotificationCountAggregateOutputType | null
    _min: NotificationMinAggregateOutputType | null
    _max: NotificationMaxAggregateOutputType | null
  }

  export type NotificationMinAggregateOutputType = {
    id: string | null
    userId: string | null
    type: $Enums.NotificationType | null
    title: string | null
    body: string | null
    read: boolean | null
    sentAt: Date | null
  }

  export type NotificationMaxAggregateOutputType = {
    id: string | null
    userId: string | null
    type: $Enums.NotificationType | null
    title: string | null
    body: string | null
    read: boolean | null
    sentAt: Date | null
  }

  export type NotificationCountAggregateOutputType = {
    id: number
    userId: number
    type: number
    title: number
    body: number
    data: number
    read: number
    sentAt: number
    _all: number
  }


  export type NotificationMinAggregateInputType = {
    id?: true
    userId?: true
    type?: true
    title?: true
    body?: true
    read?: true
    sentAt?: true
  }

  export type NotificationMaxAggregateInputType = {
    id?: true
    userId?: true
    type?: true
    title?: true
    body?: true
    read?: true
    sentAt?: true
  }

  export type NotificationCountAggregateInputType = {
    id?: true
    userId?: true
    type?: true
    title?: true
    body?: true
    data?: true
    read?: true
    sentAt?: true
    _all?: true
  }

  export type NotificationAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which Notification to aggregate.
     */
    where?: NotificationWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Notifications to fetch.
     */
    orderBy?: NotificationOrderByWithRelationInput | NotificationOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: NotificationWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Notifications from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` Notifications.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned Notifications
    **/
    _count?: true | NotificationCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: NotificationMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: NotificationMaxAggregateInputType
  }

  export type GetNotificationAggregateType<T extends NotificationAggregateArgs> = {
        [P in keyof T & keyof AggregateNotification]: P extends '_count' | 'count'
      ? T[P] extends true
        ? number
        : GetScalarType<T[P], AggregateNotification[P]>
      : GetScalarType<T[P], AggregateNotification[P]>
  }




  export type NotificationGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: NotificationWhereInput
    orderBy?: NotificationOrderByWithAggregationInput | NotificationOrderByWithAggregationInput[]
    by: NotificationScalarFieldEnum[] | NotificationScalarFieldEnum
    having?: NotificationScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: NotificationCountAggregateInputType | true
    _min?: NotificationMinAggregateInputType
    _max?: NotificationMaxAggregateInputType
  }

  export type NotificationGroupByOutputType = {
    id: string
    userId: string
    type: $Enums.NotificationType
    title: string
    body: string
    data: JsonValue | null
    read: boolean
    sentAt: Date
    _count: NotificationCountAggregateOutputType | null
    _min: NotificationMinAggregateOutputType | null
    _max: NotificationMaxAggregateOutputType | null
  }

  type GetNotificationGroupByPayload<T extends NotificationGroupByArgs> = Prisma.PrismaPromise<
    Array<
      PickEnumerable<NotificationGroupByOutputType, T['by']> &
        {
          [P in ((keyof T) & (keyof NotificationGroupByOutputType))]: P extends '_count'
            ? T[P] extends boolean
              ? number
              : GetScalarType<T[P], NotificationGroupByOutputType[P]>
            : GetScalarType<T[P], NotificationGroupByOutputType[P]>
        }
      >
    >


  export type NotificationSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    userId?: boolean
    type?: boolean
    title?: boolean
    body?: boolean
    data?: boolean
    read?: boolean
    sentAt?: boolean
    user?: boolean | UserDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["notification"]>

  export type NotificationSelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    userId?: boolean
    type?: boolean
    title?: boolean
    body?: boolean
    data?: boolean
    read?: boolean
    sentAt?: boolean
    user?: boolean | UserDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["notification"]>

  export type NotificationSelectUpdateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    userId?: boolean
    type?: boolean
    title?: boolean
    body?: boolean
    data?: boolean
    read?: boolean
    sentAt?: boolean
    user?: boolean | UserDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["notification"]>

  export type NotificationSelectScalar = {
    id?: boolean
    userId?: boolean
    type?: boolean
    title?: boolean
    body?: boolean
    data?: boolean
    read?: boolean
    sentAt?: boolean
  }

  export type NotificationOmit<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetOmit<"id" | "userId" | "type" | "title" | "body" | "data" | "read" | "sentAt", ExtArgs["result"]["notification"]>
  export type NotificationInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    user?: boolean | UserDefaultArgs<ExtArgs>
  }
  export type NotificationIncludeCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    user?: boolean | UserDefaultArgs<ExtArgs>
  }
  export type NotificationIncludeUpdateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    user?: boolean | UserDefaultArgs<ExtArgs>
  }

  export type $NotificationPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "Notification"
    objects: {
      user: Prisma.$UserPayload<ExtArgs>
    }
    scalars: $Extensions.GetPayloadResult<{
      id: string
      userId: string
      type: $Enums.NotificationType
      title: string
      body: string
      data: Prisma.JsonValue | null
      read: boolean
      sentAt: Date
    }, ExtArgs["result"]["notification"]>
    composites: {}
  }

  type NotificationGetPayload<S extends boolean | null | undefined | NotificationDefaultArgs> = $Result.GetResult<Prisma.$NotificationPayload, S>

  type NotificationCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
    Omit<NotificationFindManyArgs, 'select' | 'include' | 'distinct' | 'omit'> & {
      select?: NotificationCountAggregateInputType | true
    }

  export interface NotificationDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs, GlobalOmitOptions = {}> {
    [K: symbol]: { types: Prisma.TypeMap<ExtArgs>['model']['Notification'], meta: { name: 'Notification' } }
    /**
     * Find zero or one Notification that matches the filter.
     * @param {NotificationFindUniqueArgs} args - Arguments to find a Notification
     * @example
     * // Get one Notification
     * const notification = await prisma.notification.findUnique({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findUnique<T extends NotificationFindUniqueArgs>(args: SelectSubset<T, NotificationFindUniqueArgs<ExtArgs>>): Prisma__NotificationClient<$Result.GetResult<Prisma.$NotificationPayload<ExtArgs>, T, "findUnique", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>

    /**
     * Find one Notification that matches the filter or throw an error with `error.code='P2025'`
     * if no matches were found.
     * @param {NotificationFindUniqueOrThrowArgs} args - Arguments to find a Notification
     * @example
     * // Get one Notification
     * const notification = await prisma.notification.findUniqueOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findUniqueOrThrow<T extends NotificationFindUniqueOrThrowArgs>(args: SelectSubset<T, NotificationFindUniqueOrThrowArgs<ExtArgs>>): Prisma__NotificationClient<$Result.GetResult<Prisma.$NotificationPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Find the first Notification that matches the filter.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {NotificationFindFirstArgs} args - Arguments to find a Notification
     * @example
     * // Get one Notification
     * const notification = await prisma.notification.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends NotificationFindFirstArgs>(args?: SelectSubset<T, NotificationFindFirstArgs<ExtArgs>>): Prisma__NotificationClient<$Result.GetResult<Prisma.$NotificationPayload<ExtArgs>, T, "findFirst", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>

    /**
     * Find the first Notification that matches the filter or
     * throw `PrismaKnownClientError` with `P2025` code if no matches were found.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {NotificationFindFirstOrThrowArgs} args - Arguments to find a Notification
     * @example
     * // Get one Notification
     * const notification = await prisma.notification.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends NotificationFindFirstOrThrowArgs>(args?: SelectSubset<T, NotificationFindFirstOrThrowArgs<ExtArgs>>): Prisma__NotificationClient<$Result.GetResult<Prisma.$NotificationPayload<ExtArgs>, T, "findFirstOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Find zero or more Notifications that matches the filter.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {NotificationFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all Notifications
     * const notifications = await prisma.notification.findMany()
     * 
     * // Get first 10 Notifications
     * const notifications = await prisma.notification.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const notificationWithIdOnly = await prisma.notification.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends NotificationFindManyArgs>(args?: SelectSubset<T, NotificationFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$NotificationPayload<ExtArgs>, T, "findMany", GlobalOmitOptions>>

    /**
     * Create a Notification.
     * @param {NotificationCreateArgs} args - Arguments to create a Notification.
     * @example
     * // Create one Notification
     * const Notification = await prisma.notification.create({
     *   data: {
     *     // ... data to create a Notification
     *   }
     * })
     * 
     */
    create<T extends NotificationCreateArgs>(args: SelectSubset<T, NotificationCreateArgs<ExtArgs>>): Prisma__NotificationClient<$Result.GetResult<Prisma.$NotificationPayload<ExtArgs>, T, "create", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Create many Notifications.
     * @param {NotificationCreateManyArgs} args - Arguments to create many Notifications.
     * @example
     * // Create many Notifications
     * const notification = await prisma.notification.createMany({
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     *     
     */
    createMany<T extends NotificationCreateManyArgs>(args?: SelectSubset<T, NotificationCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>

    /**
     * Create many Notifications and returns the data saved in the database.
     * @param {NotificationCreateManyAndReturnArgs} args - Arguments to create many Notifications.
     * @example
     * // Create many Notifications
     * const notification = await prisma.notification.createManyAndReturn({
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * 
     * // Create many Notifications and only return the `id`
     * const notificationWithIdOnly = await prisma.notification.createManyAndReturn({
     *   select: { id: true },
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * 
     */
    createManyAndReturn<T extends NotificationCreateManyAndReturnArgs>(args?: SelectSubset<T, NotificationCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$NotificationPayload<ExtArgs>, T, "createManyAndReturn", GlobalOmitOptions>>

    /**
     * Delete a Notification.
     * @param {NotificationDeleteArgs} args - Arguments to delete one Notification.
     * @example
     * // Delete one Notification
     * const Notification = await prisma.notification.delete({
     *   where: {
     *     // ... filter to delete one Notification
     *   }
     * })
     * 
     */
    delete<T extends NotificationDeleteArgs>(args: SelectSubset<T, NotificationDeleteArgs<ExtArgs>>): Prisma__NotificationClient<$Result.GetResult<Prisma.$NotificationPayload<ExtArgs>, T, "delete", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Update one Notification.
     * @param {NotificationUpdateArgs} args - Arguments to update one Notification.
     * @example
     * // Update one Notification
     * const notification = await prisma.notification.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends NotificationUpdateArgs>(args: SelectSubset<T, NotificationUpdateArgs<ExtArgs>>): Prisma__NotificationClient<$Result.GetResult<Prisma.$NotificationPayload<ExtArgs>, T, "update", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Delete zero or more Notifications.
     * @param {NotificationDeleteManyArgs} args - Arguments to filter Notifications to delete.
     * @example
     * // Delete a few Notifications
     * const { count } = await prisma.notification.deleteMany({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     * 
     */
    deleteMany<T extends NotificationDeleteManyArgs>(args?: SelectSubset<T, NotificationDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>

    /**
     * Update zero or more Notifications.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {NotificationUpdateManyArgs} args - Arguments to update one or more rows.
     * @example
     * // Update many Notifications
     * const notification = await prisma.notification.updateMany({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    updateMany<T extends NotificationUpdateManyArgs>(args: SelectSubset<T, NotificationUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>

    /**
     * Update zero or more Notifications and returns the data updated in the database.
     * @param {NotificationUpdateManyAndReturnArgs} args - Arguments to update many Notifications.
     * @example
     * // Update many Notifications
     * const notification = await prisma.notification.updateManyAndReturn({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * 
     * // Update zero or more Notifications and only return the `id`
     * const notificationWithIdOnly = await prisma.notification.updateManyAndReturn({
     *   select: { id: true },
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * 
     */
    updateManyAndReturn<T extends NotificationUpdateManyAndReturnArgs>(args: SelectSubset<T, NotificationUpdateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$NotificationPayload<ExtArgs>, T, "updateManyAndReturn", GlobalOmitOptions>>

    /**
     * Create or update one Notification.
     * @param {NotificationUpsertArgs} args - Arguments to update or create a Notification.
     * @example
     * // Update or create a Notification
     * const notification = await prisma.notification.upsert({
     *   create: {
     *     // ... data to create a Notification
     *   },
     *   update: {
     *     // ... in case it already exists, update
     *   },
     *   where: {
     *     // ... the filter for the Notification we want to update
     *   }
     * })
     */
    upsert<T extends NotificationUpsertArgs>(args: SelectSubset<T, NotificationUpsertArgs<ExtArgs>>): Prisma__NotificationClient<$Result.GetResult<Prisma.$NotificationPayload<ExtArgs>, T, "upsert", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>


    /**
     * Count the number of Notifications.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {NotificationCountArgs} args - Arguments to filter Notifications to count.
     * @example
     * // Count the number of Notifications
     * const count = await prisma.notification.count({
     *   where: {
     *     // ... the filter for the Notifications we want to count
     *   }
     * })
    **/
    count<T extends NotificationCountArgs>(
      args?: Subset<T, NotificationCountArgs>,
    ): Prisma.PrismaPromise<
      T extends $Utils.Record<'select', any>
        ? T['select'] extends true
          ? number
          : GetScalarType<T['select'], NotificationCountAggregateOutputType>
        : number
    >

    /**
     * Allows you to perform aggregations operations on a Notification.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {NotificationAggregateArgs} args - Select which aggregations you would like to apply and on what fields.
     * @example
     * // Ordered by age ascending
     * // Where email contains prisma.io
     * // Limited to the 10 users
     * const aggregations = await prisma.user.aggregate({
     *   _avg: {
     *     age: true,
     *   },
     *   where: {
     *     email: {
     *       contains: "prisma.io",
     *     },
     *   },
     *   orderBy: {
     *     age: "asc",
     *   },
     *   take: 10,
     * })
    **/
    aggregate<T extends NotificationAggregateArgs>(args: Subset<T, NotificationAggregateArgs>): Prisma.PrismaPromise<GetNotificationAggregateType<T>>

    /**
     * Group by Notification.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {NotificationGroupByArgs} args - Group by arguments.
     * @example
     * // Group by city, order by createdAt, get count
     * const result = await prisma.user.groupBy({
     *   by: ['city', 'createdAt'],
     *   orderBy: {
     *     createdAt: true
     *   },
     *   _count: {
     *     _all: true
     *   },
     * })
     * 
    **/
    groupBy<
      T extends NotificationGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: NotificationGroupByArgs['orderBy'] }
        : { orderBy?: NotificationGroupByArgs['orderBy'] },
      OrderFields extends ExcludeUnderscoreKeys<Keys<MaybeTupleToUnion<T['orderBy']>>>,
      ByFields extends MaybeTupleToUnion<T['by']>,
      ByValid extends Has<ByFields, OrderFields>,
      HavingFields extends GetHavingFields<T['having']>,
      HavingValid extends Has<ByFields, HavingFields>,
      ByEmpty extends T['by'] extends never[] ? True : False,
      InputErrors extends ByEmpty extends True
      ? `Error: "by" must not be empty.`
      : HavingValid extends False
      ? {
          [P in HavingFields]: P extends ByFields
            ? never
            : P extends string
            ? `Error: Field "${P}" used in "having" needs to be provided in "by".`
            : [
                Error,
                'Field ',
                P,
                ` in "having" needs to be provided in "by"`,
              ]
        }[HavingFields]
      : 'take' extends Keys<T>
      ? 'orderBy' extends Keys<T>
        ? ByValid extends True
          ? {}
          : {
              [P in OrderFields]: P extends ByFields
                ? never
                : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
            }[OrderFields]
        : 'Error: If you provide "take", you also need to provide "orderBy"'
      : 'skip' extends Keys<T>
      ? 'orderBy' extends Keys<T>
        ? ByValid extends True
          ? {}
          : {
              [P in OrderFields]: P extends ByFields
                ? never
                : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
            }[OrderFields]
        : 'Error: If you provide "skip", you also need to provide "orderBy"'
      : ByValid extends True
      ? {}
      : {
          [P in OrderFields]: P extends ByFields
            ? never
            : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
        }[OrderFields]
    >(args: SubsetIntersection<T, NotificationGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetNotificationGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the Notification model
   */
  readonly fields: NotificationFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for Notification.
   * Why is this prefixed with `Prisma__`?
   * Because we want to prevent naming conflicts as mentioned in
   * https://github.com/prisma/prisma-client-js/issues/707
   */
  export interface Prisma__NotificationClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs, GlobalOmitOptions = {}> extends Prisma.PrismaPromise<T> {
    readonly [Symbol.toStringTag]: "PrismaPromise"
    user<T extends UserDefaultArgs<ExtArgs> = {}>(args?: Subset<T, UserDefaultArgs<ExtArgs>>): Prisma__UserClient<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | Null, Null, ExtArgs, GlobalOmitOptions>
    /**
     * Attaches callbacks for the resolution and/or rejection of the Promise.
     * @param onfulfilled The callback to execute when the Promise is resolved.
     * @param onrejected The callback to execute when the Promise is rejected.
     * @returns A Promise for the completion of which ever callback is executed.
     */
    then<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): $Utils.JsPromise<TResult1 | TResult2>
    /**
     * Attaches a callback for only the rejection of the Promise.
     * @param onrejected The callback to execute when the Promise is rejected.
     * @returns A Promise for the completion of the callback.
     */
    catch<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): $Utils.JsPromise<T | TResult>
    /**
     * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The
     * resolved value cannot be modified from the callback.
     * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected).
     * @returns A Promise for the completion of the callback.
     */
    finally(onfinally?: (() => void) | undefined | null): $Utils.JsPromise<T>
  }




  /**
   * Fields of the Notification model
   */
  interface NotificationFieldRefs {
    readonly id: FieldRef<"Notification", 'String'>
    readonly userId: FieldRef<"Notification", 'String'>
    readonly type: FieldRef<"Notification", 'NotificationType'>
    readonly title: FieldRef<"Notification", 'String'>
    readonly body: FieldRef<"Notification", 'String'>
    readonly data: FieldRef<"Notification", 'Json'>
    readonly read: FieldRef<"Notification", 'Boolean'>
    readonly sentAt: FieldRef<"Notification", 'DateTime'>
  }
    

  // Custom InputTypes
  /**
   * Notification findUnique
   */
  export type NotificationFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Notification
     */
    select?: NotificationSelect<ExtArgs> | null
    /**
     * Omit specific fields from the Notification
     */
    omit?: NotificationOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: NotificationInclude<ExtArgs> | null
    /**
     * Filter, which Notification to fetch.
     */
    where: NotificationWhereUniqueInput
  }

  /**
   * Notification findUniqueOrThrow
   */
  export type NotificationFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Notification
     */
    select?: NotificationSelect<ExtArgs> | null
    /**
     * Omit specific fields from the Notification
     */
    omit?: NotificationOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: NotificationInclude<ExtArgs> | null
    /**
     * Filter, which Notification to fetch.
     */
    where: NotificationWhereUniqueInput
  }

  /**
   * Notification findFirst
   */
  export type NotificationFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Notification
     */
    select?: NotificationSelect<ExtArgs> | null
    /**
     * Omit specific fields from the Notification
     */
    omit?: NotificationOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: NotificationInclude<ExtArgs> | null
    /**
     * Filter, which Notification to fetch.
     */
    where?: NotificationWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Notifications to fetch.
     */
    orderBy?: NotificationOrderByWithRelationInput | NotificationOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for Notifications.
     */
    cursor?: NotificationWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Notifications from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` Notifications.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of Notifications.
     */
    distinct?: NotificationScalarFieldEnum | NotificationScalarFieldEnum[]
  }

  /**
   * Notification findFirstOrThrow
   */
  export type NotificationFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Notification
     */
    select?: NotificationSelect<ExtArgs> | null
    /**
     * Omit specific fields from the Notification
     */
    omit?: NotificationOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: NotificationInclude<ExtArgs> | null
    /**
     * Filter, which Notification to fetch.
     */
    where?: NotificationWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Notifications to fetch.
     */
    orderBy?: NotificationOrderByWithRelationInput | NotificationOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for Notifications.
     */
    cursor?: NotificationWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Notifications from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` Notifications.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of Notifications.
     */
    distinct?: NotificationScalarFieldEnum | NotificationScalarFieldEnum[]
  }

  /**
   * Notification findMany
   */
  export type NotificationFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Notification
     */
    select?: NotificationSelect<ExtArgs> | null
    /**
     * Omit specific fields from the Notification
     */
    omit?: NotificationOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: NotificationInclude<ExtArgs> | null
    /**
     * Filter, which Notifications to fetch.
     */
    where?: NotificationWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Notifications to fetch.
     */
    orderBy?: NotificationOrderByWithRelationInput | NotificationOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing Notifications.
     */
    cursor?: NotificationWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Notifications from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` Notifications.
     */
    skip?: number
    distinct?: NotificationScalarFieldEnum | NotificationScalarFieldEnum[]
  }

  /**
   * Notification create
   */
  export type NotificationCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Notification
     */
    select?: NotificationSelect<ExtArgs> | null
    /**
     * Omit specific fields from the Notification
     */
    omit?: NotificationOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: NotificationInclude<ExtArgs> | null
    /**
     * The data needed to create a Notification.
     */
    data: XOR<NotificationCreateInput, NotificationUncheckedCreateInput>
  }

  /**
   * Notification createMany
   */
  export type NotificationCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many Notifications.
     */
    data: NotificationCreateManyInput | NotificationCreateManyInput[]
  }

  /**
   * Notification createManyAndReturn
   */
  export type NotificationCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Notification
     */
    select?: NotificationSelectCreateManyAndReturn<ExtArgs> | null
    /**
     * Omit specific fields from the Notification
     */
    omit?: NotificationOmit<ExtArgs> | null
    /**
     * The data used to create many Notifications.
     */
    data: NotificationCreateManyInput | NotificationCreateManyInput[]
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: NotificationIncludeCreateManyAndReturn<ExtArgs> | null
  }

  /**
   * Notification update
   */
  export type NotificationUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Notification
     */
    select?: NotificationSelect<ExtArgs> | null
    /**
     * Omit specific fields from the Notification
     */
    omit?: NotificationOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: NotificationInclude<ExtArgs> | null
    /**
     * The data needed to update a Notification.
     */
    data: XOR<NotificationUpdateInput, NotificationUncheckedUpdateInput>
    /**
     * Choose, which Notification to update.
     */
    where: NotificationWhereUniqueInput
  }

  /**
   * Notification updateMany
   */
  export type NotificationUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update Notifications.
     */
    data: XOR<NotificationUpdateManyMutationInput, NotificationUncheckedUpdateManyInput>
    /**
     * Filter which Notifications to update
     */
    where?: NotificationWhereInput
    /**
     * Limit how many Notifications to update.
     */
    limit?: number
  }

  /**
   * Notification updateManyAndReturn
   */
  export type NotificationUpdateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Notification
     */
    select?: NotificationSelectUpdateManyAndReturn<ExtArgs> | null
    /**
     * Omit specific fields from the Notification
     */
    omit?: NotificationOmit<ExtArgs> | null
    /**
     * The data used to update Notifications.
     */
    data: XOR<NotificationUpdateManyMutationInput, NotificationUncheckedUpdateManyInput>
    /**
     * Filter which Notifications to update
     */
    where?: NotificationWhereInput
    /**
     * Limit how many Notifications to update.
     */
    limit?: number
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: NotificationIncludeUpdateManyAndReturn<ExtArgs> | null
  }

  /**
   * Notification upsert
   */
  export type NotificationUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Notification
     */
    select?: NotificationSelect<ExtArgs> | null
    /**
     * Omit specific fields from the Notification
     */
    omit?: NotificationOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: NotificationInclude<ExtArgs> | null
    /**
     * The filter to search for the Notification to update in case it exists.
     */
    where: NotificationWhereUniqueInput
    /**
     * In case the Notification found by the `where` argument doesn't exist, create a new Notification with this data.
     */
    create: XOR<NotificationCreateInput, NotificationUncheckedCreateInput>
    /**
     * In case the Notification was found with the provided `where` argument, update it with this data.
     */
    update: XOR<NotificationUpdateInput, NotificationUncheckedUpdateInput>
  }

  /**
   * Notification delete
   */
  export type NotificationDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Notification
     */
    select?: NotificationSelect<ExtArgs> | null
    /**
     * Omit specific fields from the Notification
     */
    omit?: NotificationOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: NotificationInclude<ExtArgs> | null
    /**
     * Filter which Notification to delete.
     */
    where: NotificationWhereUniqueInput
  }

  /**
   * Notification deleteMany
   */
  export type NotificationDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which Notifications to delete
     */
    where?: NotificationWhereInput
    /**
     * Limit how many Notifications to delete.
     */
    limit?: number
  }

  /**
   * Notification without action
   */
  export type NotificationDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Notification
     */
    select?: NotificationSelect<ExtArgs> | null
    /**
     * Omit specific fields from the Notification
     */
    omit?: NotificationOmit<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: NotificationInclude<ExtArgs> | null
  }


  /**
   * Model SystemConfig
   */

  export type AggregateSystemConfig = {
    _count: SystemConfigCountAggregateOutputType | null
    _min: SystemConfigMinAggregateOutputType | null
    _max: SystemConfigMaxAggregateOutputType | null
  }

  export type SystemConfigMinAggregateOutputType = {
    id: string | null
    key: string | null
    updatedAt: Date | null
  }

  export type SystemConfigMaxAggregateOutputType = {
    id: string | null
    key: string | null
    updatedAt: Date | null
  }

  export type SystemConfigCountAggregateOutputType = {
    id: number
    key: number
    value: number
    updatedAt: number
    _all: number
  }


  export type SystemConfigMinAggregateInputType = {
    id?: true
    key?: true
    updatedAt?: true
  }

  export type SystemConfigMaxAggregateInputType = {
    id?: true
    key?: true
    updatedAt?: true
  }

  export type SystemConfigCountAggregateInputType = {
    id?: true
    key?: true
    value?: true
    updatedAt?: true
    _all?: true
  }

  export type SystemConfigAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which SystemConfig to aggregate.
     */
    where?: SystemConfigWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of SystemConfigs to fetch.
     */
    orderBy?: SystemConfigOrderByWithRelationInput | SystemConfigOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: SystemConfigWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` SystemConfigs from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` SystemConfigs.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned SystemConfigs
    **/
    _count?: true | SystemConfigCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: SystemConfigMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: SystemConfigMaxAggregateInputType
  }

  export type GetSystemConfigAggregateType<T extends SystemConfigAggregateArgs> = {
        [P in keyof T & keyof AggregateSystemConfig]: P extends '_count' | 'count'
      ? T[P] extends true
        ? number
        : GetScalarType<T[P], AggregateSystemConfig[P]>
      : GetScalarType<T[P], AggregateSystemConfig[P]>
  }




  export type SystemConfigGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: SystemConfigWhereInput
    orderBy?: SystemConfigOrderByWithAggregationInput | SystemConfigOrderByWithAggregationInput[]
    by: SystemConfigScalarFieldEnum[] | SystemConfigScalarFieldEnum
    having?: SystemConfigScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: SystemConfigCountAggregateInputType | true
    _min?: SystemConfigMinAggregateInputType
    _max?: SystemConfigMaxAggregateInputType
  }

  export type SystemConfigGroupByOutputType = {
    id: string
    key: string
    value: JsonValue
    updatedAt: Date
    _count: SystemConfigCountAggregateOutputType | null
    _min: SystemConfigMinAggregateOutputType | null
    _max: SystemConfigMaxAggregateOutputType | null
  }

  type GetSystemConfigGroupByPayload<T extends SystemConfigGroupByArgs> = Prisma.PrismaPromise<
    Array<
      PickEnumerable<SystemConfigGroupByOutputType, T['by']> &
        {
          [P in ((keyof T) & (keyof SystemConfigGroupByOutputType))]: P extends '_count'
            ? T[P] extends boolean
              ? number
              : GetScalarType<T[P], SystemConfigGroupByOutputType[P]>
            : GetScalarType<T[P], SystemConfigGroupByOutputType[P]>
        }
      >
    >


  export type SystemConfigSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    key?: boolean
    value?: boolean
    updatedAt?: boolean
  }, ExtArgs["result"]["systemConfig"]>

  export type SystemConfigSelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    key?: boolean
    value?: boolean
    updatedAt?: boolean
  }, ExtArgs["result"]["systemConfig"]>

  export type SystemConfigSelectUpdateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    key?: boolean
    value?: boolean
    updatedAt?: boolean
  }, ExtArgs["result"]["systemConfig"]>

  export type SystemConfigSelectScalar = {
    id?: boolean
    key?: boolean
    value?: boolean
    updatedAt?: boolean
  }

  export type SystemConfigOmit<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetOmit<"id" | "key" | "value" | "updatedAt", ExtArgs["result"]["systemConfig"]>

  export type $SystemConfigPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "SystemConfig"
    objects: {}
    scalars: $Extensions.GetPayloadResult<{
      id: string
      key: string
      value: Prisma.JsonValue
      updatedAt: Date
    }, ExtArgs["result"]["systemConfig"]>
    composites: {}
  }

  type SystemConfigGetPayload<S extends boolean | null | undefined | SystemConfigDefaultArgs> = $Result.GetResult<Prisma.$SystemConfigPayload, S>

  type SystemConfigCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
    Omit<SystemConfigFindManyArgs, 'select' | 'include' | 'distinct' | 'omit'> & {
      select?: SystemConfigCountAggregateInputType | true
    }

  export interface SystemConfigDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs, GlobalOmitOptions = {}> {
    [K: symbol]: { types: Prisma.TypeMap<ExtArgs>['model']['SystemConfig'], meta: { name: 'SystemConfig' } }
    /**
     * Find zero or one SystemConfig that matches the filter.
     * @param {SystemConfigFindUniqueArgs} args - Arguments to find a SystemConfig
     * @example
     * // Get one SystemConfig
     * const systemConfig = await prisma.systemConfig.findUnique({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findUnique<T extends SystemConfigFindUniqueArgs>(args: SelectSubset<T, SystemConfigFindUniqueArgs<ExtArgs>>): Prisma__SystemConfigClient<$Result.GetResult<Prisma.$SystemConfigPayload<ExtArgs>, T, "findUnique", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>

    /**
     * Find one SystemConfig that matches the filter or throw an error with `error.code='P2025'`
     * if no matches were found.
     * @param {SystemConfigFindUniqueOrThrowArgs} args - Arguments to find a SystemConfig
     * @example
     * // Get one SystemConfig
     * const systemConfig = await prisma.systemConfig.findUniqueOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findUniqueOrThrow<T extends SystemConfigFindUniqueOrThrowArgs>(args: SelectSubset<T, SystemConfigFindUniqueOrThrowArgs<ExtArgs>>): Prisma__SystemConfigClient<$Result.GetResult<Prisma.$SystemConfigPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Find the first SystemConfig that matches the filter.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {SystemConfigFindFirstArgs} args - Arguments to find a SystemConfig
     * @example
     * // Get one SystemConfig
     * const systemConfig = await prisma.systemConfig.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends SystemConfigFindFirstArgs>(args?: SelectSubset<T, SystemConfigFindFirstArgs<ExtArgs>>): Prisma__SystemConfigClient<$Result.GetResult<Prisma.$SystemConfigPayload<ExtArgs>, T, "findFirst", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>

    /**
     * Find the first SystemConfig that matches the filter or
     * throw `PrismaKnownClientError` with `P2025` code if no matches were found.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {SystemConfigFindFirstOrThrowArgs} args - Arguments to find a SystemConfig
     * @example
     * // Get one SystemConfig
     * const systemConfig = await prisma.systemConfig.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends SystemConfigFindFirstOrThrowArgs>(args?: SelectSubset<T, SystemConfigFindFirstOrThrowArgs<ExtArgs>>): Prisma__SystemConfigClient<$Result.GetResult<Prisma.$SystemConfigPayload<ExtArgs>, T, "findFirstOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Find zero or more SystemConfigs that matches the filter.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {SystemConfigFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all SystemConfigs
     * const systemConfigs = await prisma.systemConfig.findMany()
     * 
     * // Get first 10 SystemConfigs
     * const systemConfigs = await prisma.systemConfig.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const systemConfigWithIdOnly = await prisma.systemConfig.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends SystemConfigFindManyArgs>(args?: SelectSubset<T, SystemConfigFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$SystemConfigPayload<ExtArgs>, T, "findMany", GlobalOmitOptions>>

    /**
     * Create a SystemConfig.
     * @param {SystemConfigCreateArgs} args - Arguments to create a SystemConfig.
     * @example
     * // Create one SystemConfig
     * const SystemConfig = await prisma.systemConfig.create({
     *   data: {
     *     // ... data to create a SystemConfig
     *   }
     * })
     * 
     */
    create<T extends SystemConfigCreateArgs>(args: SelectSubset<T, SystemConfigCreateArgs<ExtArgs>>): Prisma__SystemConfigClient<$Result.GetResult<Prisma.$SystemConfigPayload<ExtArgs>, T, "create", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Create many SystemConfigs.
     * @param {SystemConfigCreateManyArgs} args - Arguments to create many SystemConfigs.
     * @example
     * // Create many SystemConfigs
     * const systemConfig = await prisma.systemConfig.createMany({
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     *     
     */
    createMany<T extends SystemConfigCreateManyArgs>(args?: SelectSubset<T, SystemConfigCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>

    /**
     * Create many SystemConfigs and returns the data saved in the database.
     * @param {SystemConfigCreateManyAndReturnArgs} args - Arguments to create many SystemConfigs.
     * @example
     * // Create many SystemConfigs
     * const systemConfig = await prisma.systemConfig.createManyAndReturn({
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * 
     * // Create many SystemConfigs and only return the `id`
     * const systemConfigWithIdOnly = await prisma.systemConfig.createManyAndReturn({
     *   select: { id: true },
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * 
     */
    createManyAndReturn<T extends SystemConfigCreateManyAndReturnArgs>(args?: SelectSubset<T, SystemConfigCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$SystemConfigPayload<ExtArgs>, T, "createManyAndReturn", GlobalOmitOptions>>

    /**
     * Delete a SystemConfig.
     * @param {SystemConfigDeleteArgs} args - Arguments to delete one SystemConfig.
     * @example
     * // Delete one SystemConfig
     * const SystemConfig = await prisma.systemConfig.delete({
     *   where: {
     *     // ... filter to delete one SystemConfig
     *   }
     * })
     * 
     */
    delete<T extends SystemConfigDeleteArgs>(args: SelectSubset<T, SystemConfigDeleteArgs<ExtArgs>>): Prisma__SystemConfigClient<$Result.GetResult<Prisma.$SystemConfigPayload<ExtArgs>, T, "delete", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Update one SystemConfig.
     * @param {SystemConfigUpdateArgs} args - Arguments to update one SystemConfig.
     * @example
     * // Update one SystemConfig
     * const systemConfig = await prisma.systemConfig.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends SystemConfigUpdateArgs>(args: SelectSubset<T, SystemConfigUpdateArgs<ExtArgs>>): Prisma__SystemConfigClient<$Result.GetResult<Prisma.$SystemConfigPayload<ExtArgs>, T, "update", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Delete zero or more SystemConfigs.
     * @param {SystemConfigDeleteManyArgs} args - Arguments to filter SystemConfigs to delete.
     * @example
     * // Delete a few SystemConfigs
     * const { count } = await prisma.systemConfig.deleteMany({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     * 
     */
    deleteMany<T extends SystemConfigDeleteManyArgs>(args?: SelectSubset<T, SystemConfigDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>

    /**
     * Update zero or more SystemConfigs.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {SystemConfigUpdateManyArgs} args - Arguments to update one or more rows.
     * @example
     * // Update many SystemConfigs
     * const systemConfig = await prisma.systemConfig.updateMany({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    updateMany<T extends SystemConfigUpdateManyArgs>(args: SelectSubset<T, SystemConfigUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>

    /**
     * Update zero or more SystemConfigs and returns the data updated in the database.
     * @param {SystemConfigUpdateManyAndReturnArgs} args - Arguments to update many SystemConfigs.
     * @example
     * // Update many SystemConfigs
     * const systemConfig = await prisma.systemConfig.updateManyAndReturn({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * 
     * // Update zero or more SystemConfigs and only return the `id`
     * const systemConfigWithIdOnly = await prisma.systemConfig.updateManyAndReturn({
     *   select: { id: true },
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * 
     */
    updateManyAndReturn<T extends SystemConfigUpdateManyAndReturnArgs>(args: SelectSubset<T, SystemConfigUpdateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$SystemConfigPayload<ExtArgs>, T, "updateManyAndReturn", GlobalOmitOptions>>

    /**
     * Create or update one SystemConfig.
     * @param {SystemConfigUpsertArgs} args - Arguments to update or create a SystemConfig.
     * @example
     * // Update or create a SystemConfig
     * const systemConfig = await prisma.systemConfig.upsert({
     *   create: {
     *     // ... data to create a SystemConfig
     *   },
     *   update: {
     *     // ... in case it already exists, update
     *   },
     *   where: {
     *     // ... the filter for the SystemConfig we want to update
     *   }
     * })
     */
    upsert<T extends SystemConfigUpsertArgs>(args: SelectSubset<T, SystemConfigUpsertArgs<ExtArgs>>): Prisma__SystemConfigClient<$Result.GetResult<Prisma.$SystemConfigPayload<ExtArgs>, T, "upsert", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>


    /**
     * Count the number of SystemConfigs.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {SystemConfigCountArgs} args - Arguments to filter SystemConfigs to count.
     * @example
     * // Count the number of SystemConfigs
     * const count = await prisma.systemConfig.count({
     *   where: {
     *     // ... the filter for the SystemConfigs we want to count
     *   }
     * })
    **/
    count<T extends SystemConfigCountArgs>(
      args?: Subset<T, SystemConfigCountArgs>,
    ): Prisma.PrismaPromise<
      T extends $Utils.Record<'select', any>
        ? T['select'] extends true
          ? number
          : GetScalarType<T['select'], SystemConfigCountAggregateOutputType>
        : number
    >

    /**
     * Allows you to perform aggregations operations on a SystemConfig.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {SystemConfigAggregateArgs} args - Select which aggregations you would like to apply and on what fields.
     * @example
     * // Ordered by age ascending
     * // Where email contains prisma.io
     * // Limited to the 10 users
     * const aggregations = await prisma.user.aggregate({
     *   _avg: {
     *     age: true,
     *   },
     *   where: {
     *     email: {
     *       contains: "prisma.io",
     *     },
     *   },
     *   orderBy: {
     *     age: "asc",
     *   },
     *   take: 10,
     * })
    **/
    aggregate<T extends SystemConfigAggregateArgs>(args: Subset<T, SystemConfigAggregateArgs>): Prisma.PrismaPromise<GetSystemConfigAggregateType<T>>

    /**
     * Group by SystemConfig.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {SystemConfigGroupByArgs} args - Group by arguments.
     * @example
     * // Group by city, order by createdAt, get count
     * const result = await prisma.user.groupBy({
     *   by: ['city', 'createdAt'],
     *   orderBy: {
     *     createdAt: true
     *   },
     *   _count: {
     *     _all: true
     *   },
     * })
     * 
    **/
    groupBy<
      T extends SystemConfigGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: SystemConfigGroupByArgs['orderBy'] }
        : { orderBy?: SystemConfigGroupByArgs['orderBy'] },
      OrderFields extends ExcludeUnderscoreKeys<Keys<MaybeTupleToUnion<T['orderBy']>>>,
      ByFields extends MaybeTupleToUnion<T['by']>,
      ByValid extends Has<ByFields, OrderFields>,
      HavingFields extends GetHavingFields<T['having']>,
      HavingValid extends Has<ByFields, HavingFields>,
      ByEmpty extends T['by'] extends never[] ? True : False,
      InputErrors extends ByEmpty extends True
      ? `Error: "by" must not be empty.`
      : HavingValid extends False
      ? {
          [P in HavingFields]: P extends ByFields
            ? never
            : P extends string
            ? `Error: Field "${P}" used in "having" needs to be provided in "by".`
            : [
                Error,
                'Field ',
                P,
                ` in "having" needs to be provided in "by"`,
              ]
        }[HavingFields]
      : 'take' extends Keys<T>
      ? 'orderBy' extends Keys<T>
        ? ByValid extends True
          ? {}
          : {
              [P in OrderFields]: P extends ByFields
                ? never
                : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
            }[OrderFields]
        : 'Error: If you provide "take", you also need to provide "orderBy"'
      : 'skip' extends Keys<T>
      ? 'orderBy' extends Keys<T>
        ? ByValid extends True
          ? {}
          : {
              [P in OrderFields]: P extends ByFields
                ? never
                : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
            }[OrderFields]
        : 'Error: If you provide "skip", you also need to provide "orderBy"'
      : ByValid extends True
      ? {}
      : {
          [P in OrderFields]: P extends ByFields
            ? never
            : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
        }[OrderFields]
    >(args: SubsetIntersection<T, SystemConfigGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetSystemConfigGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the SystemConfig model
   */
  readonly fields: SystemConfigFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for SystemConfig.
   * Why is this prefixed with `Prisma__`?
   * Because we want to prevent naming conflicts as mentioned in
   * https://github.com/prisma/prisma-client-js/issues/707
   */
  export interface Prisma__SystemConfigClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs, GlobalOmitOptions = {}> extends Prisma.PrismaPromise<T> {
    readonly [Symbol.toStringTag]: "PrismaPromise"
    /**
     * Attaches callbacks for the resolution and/or rejection of the Promise.
     * @param onfulfilled The callback to execute when the Promise is resolved.
     * @param onrejected The callback to execute when the Promise is rejected.
     * @returns A Promise for the completion of which ever callback is executed.
     */
    then<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): $Utils.JsPromise<TResult1 | TResult2>
    /**
     * Attaches a callback for only the rejection of the Promise.
     * @param onrejected The callback to execute when the Promise is rejected.
     * @returns A Promise for the completion of the callback.
     */
    catch<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): $Utils.JsPromise<T | TResult>
    /**
     * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The
     * resolved value cannot be modified from the callback.
     * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected).
     * @returns A Promise for the completion of the callback.
     */
    finally(onfinally?: (() => void) | undefined | null): $Utils.JsPromise<T>
  }




  /**
   * Fields of the SystemConfig model
   */
  interface SystemConfigFieldRefs {
    readonly id: FieldRef<"SystemConfig", 'String'>
    readonly key: FieldRef<"SystemConfig", 'String'>
    readonly value: FieldRef<"SystemConfig", 'Json'>
    readonly updatedAt: FieldRef<"SystemConfig", 'DateTime'>
  }
    

  // Custom InputTypes
  /**
   * SystemConfig findUnique
   */
  export type SystemConfigFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SystemConfig
     */
    select?: SystemConfigSelect<ExtArgs> | null
    /**
     * Omit specific fields from the SystemConfig
     */
    omit?: SystemConfigOmit<ExtArgs> | null
    /**
     * Filter, which SystemConfig to fetch.
     */
    where: SystemConfigWhereUniqueInput
  }

  /**
   * SystemConfig findUniqueOrThrow
   */
  export type SystemConfigFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SystemConfig
     */
    select?: SystemConfigSelect<ExtArgs> | null
    /**
     * Omit specific fields from the SystemConfig
     */
    omit?: SystemConfigOmit<ExtArgs> | null
    /**
     * Filter, which SystemConfig to fetch.
     */
    where: SystemConfigWhereUniqueInput
  }

  /**
   * SystemConfig findFirst
   */
  export type SystemConfigFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SystemConfig
     */
    select?: SystemConfigSelect<ExtArgs> | null
    /**
     * Omit specific fields from the SystemConfig
     */
    omit?: SystemConfigOmit<ExtArgs> | null
    /**
     * Filter, which SystemConfig to fetch.
     */
    where?: SystemConfigWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of SystemConfigs to fetch.
     */
    orderBy?: SystemConfigOrderByWithRelationInput | SystemConfigOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for SystemConfigs.
     */
    cursor?: SystemConfigWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` SystemConfigs from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` SystemConfigs.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of SystemConfigs.
     */
    distinct?: SystemConfigScalarFieldEnum | SystemConfigScalarFieldEnum[]
  }

  /**
   * SystemConfig findFirstOrThrow
   */
  export type SystemConfigFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SystemConfig
     */
    select?: SystemConfigSelect<ExtArgs> | null
    /**
     * Omit specific fields from the SystemConfig
     */
    omit?: SystemConfigOmit<ExtArgs> | null
    /**
     * Filter, which SystemConfig to fetch.
     */
    where?: SystemConfigWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of SystemConfigs to fetch.
     */
    orderBy?: SystemConfigOrderByWithRelationInput | SystemConfigOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for SystemConfigs.
     */
    cursor?: SystemConfigWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` SystemConfigs from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` SystemConfigs.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of SystemConfigs.
     */
    distinct?: SystemConfigScalarFieldEnum | SystemConfigScalarFieldEnum[]
  }

  /**
   * SystemConfig findMany
   */
  export type SystemConfigFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SystemConfig
     */
    select?: SystemConfigSelect<ExtArgs> | null
    /**
     * Omit specific fields from the SystemConfig
     */
    omit?: SystemConfigOmit<ExtArgs> | null
    /**
     * Filter, which SystemConfigs to fetch.
     */
    where?: SystemConfigWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of SystemConfigs to fetch.
     */
    orderBy?: SystemConfigOrderByWithRelationInput | SystemConfigOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing SystemConfigs.
     */
    cursor?: SystemConfigWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` SystemConfigs from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` SystemConfigs.
     */
    skip?: number
    distinct?: SystemConfigScalarFieldEnum | SystemConfigScalarFieldEnum[]
  }

  /**
   * SystemConfig create
   */
  export type SystemConfigCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SystemConfig
     */
    select?: SystemConfigSelect<ExtArgs> | null
    /**
     * Omit specific fields from the SystemConfig
     */
    omit?: SystemConfigOmit<ExtArgs> | null
    /**
     * The data needed to create a SystemConfig.
     */
    data: XOR<SystemConfigCreateInput, SystemConfigUncheckedCreateInput>
  }

  /**
   * SystemConfig createMany
   */
  export type SystemConfigCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many SystemConfigs.
     */
    data: SystemConfigCreateManyInput | SystemConfigCreateManyInput[]
  }

  /**
   * SystemConfig createManyAndReturn
   */
  export type SystemConfigCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SystemConfig
     */
    select?: SystemConfigSelectCreateManyAndReturn<ExtArgs> | null
    /**
     * Omit specific fields from the SystemConfig
     */
    omit?: SystemConfigOmit<ExtArgs> | null
    /**
     * The data used to create many SystemConfigs.
     */
    data: SystemConfigCreateManyInput | SystemConfigCreateManyInput[]
  }

  /**
   * SystemConfig update
   */
  export type SystemConfigUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SystemConfig
     */
    select?: SystemConfigSelect<ExtArgs> | null
    /**
     * Omit specific fields from the SystemConfig
     */
    omit?: SystemConfigOmit<ExtArgs> | null
    /**
     * The data needed to update a SystemConfig.
     */
    data: XOR<SystemConfigUpdateInput, SystemConfigUncheckedUpdateInput>
    /**
     * Choose, which SystemConfig to update.
     */
    where: SystemConfigWhereUniqueInput
  }

  /**
   * SystemConfig updateMany
   */
  export type SystemConfigUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update SystemConfigs.
     */
    data: XOR<SystemConfigUpdateManyMutationInput, SystemConfigUncheckedUpdateManyInput>
    /**
     * Filter which SystemConfigs to update
     */
    where?: SystemConfigWhereInput
    /**
     * Limit how many SystemConfigs to update.
     */
    limit?: number
  }

  /**
   * SystemConfig updateManyAndReturn
   */
  export type SystemConfigUpdateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SystemConfig
     */
    select?: SystemConfigSelectUpdateManyAndReturn<ExtArgs> | null
    /**
     * Omit specific fields from the SystemConfig
     */
    omit?: SystemConfigOmit<ExtArgs> | null
    /**
     * The data used to update SystemConfigs.
     */
    data: XOR<SystemConfigUpdateManyMutationInput, SystemConfigUncheckedUpdateManyInput>
    /**
     * Filter which SystemConfigs to update
     */
    where?: SystemConfigWhereInput
    /**
     * Limit how many SystemConfigs to update.
     */
    limit?: number
  }

  /**
   * SystemConfig upsert
   */
  export type SystemConfigUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SystemConfig
     */
    select?: SystemConfigSelect<ExtArgs> | null
    /**
     * Omit specific fields from the SystemConfig
     */
    omit?: SystemConfigOmit<ExtArgs> | null
    /**
     * The filter to search for the SystemConfig to update in case it exists.
     */
    where: SystemConfigWhereUniqueInput
    /**
     * In case the SystemConfig found by the `where` argument doesn't exist, create a new SystemConfig with this data.
     */
    create: XOR<SystemConfigCreateInput, SystemConfigUncheckedCreateInput>
    /**
     * In case the SystemConfig was found with the provided `where` argument, update it with this data.
     */
    update: XOR<SystemConfigUpdateInput, SystemConfigUncheckedUpdateInput>
  }

  /**
   * SystemConfig delete
   */
  export type SystemConfigDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SystemConfig
     */
    select?: SystemConfigSelect<ExtArgs> | null
    /**
     * Omit specific fields from the SystemConfig
     */
    omit?: SystemConfigOmit<ExtArgs> | null
    /**
     * Filter which SystemConfig to delete.
     */
    where: SystemConfigWhereUniqueInput
  }

  /**
   * SystemConfig deleteMany
   */
  export type SystemConfigDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which SystemConfigs to delete
     */
    where?: SystemConfigWhereInput
    /**
     * Limit how many SystemConfigs to delete.
     */
    limit?: number
  }

  /**
   * SystemConfig without action
   */
  export type SystemConfigDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SystemConfig
     */
    select?: SystemConfigSelect<ExtArgs> | null
    /**
     * Omit specific fields from the SystemConfig
     */
    omit?: SystemConfigOmit<ExtArgs> | null
  }


  /**
   * Model DailySummary
   */

  export type AggregateDailySummary = {
    _count: DailySummaryCountAggregateOutputType | null
    _avg: DailySummaryAvgAggregateOutputType | null
    _sum: DailySummarySumAggregateOutputType | null
    _min: DailySummaryMinAggregateOutputType | null
    _max: DailySummaryMaxAggregateOutputType | null
  }

  export type DailySummaryAvgAggregateOutputType = {
    totalDistance: number | null
    travelTime: number | null
    meetingTime: number | null
    idleTime: number | null
    tripsCompleted: number | null
    productivityScore: number | null
  }

  export type DailySummarySumAggregateOutputType = {
    totalDistance: number | null
    travelTime: number | null
    meetingTime: number | null
    idleTime: number | null
    tripsCompleted: number | null
    productivityScore: number | null
  }

  export type DailySummaryMinAggregateOutputType = {
    id: string | null
    userId: string | null
    date: Date | null
    totalDistance: number | null
    travelTime: number | null
    meetingTime: number | null
    idleTime: number | null
    tripsCompleted: number | null
    productivityScore: number | null
    createdAt: Date | null
    updatedAt: Date | null
  }

  export type DailySummaryMaxAggregateOutputType = {
    id: string | null
    userId: string | null
    date: Date | null
    totalDistance: number | null
    travelTime: number | null
    meetingTime: number | null
    idleTime: number | null
    tripsCompleted: number | null
    productivityScore: number | null
    createdAt: Date | null
    updatedAt: Date | null
  }

  export type DailySummaryCountAggregateOutputType = {
    id: number
    userId: number
    date: number
    totalDistance: number
    travelTime: number
    meetingTime: number
    idleTime: number
    tripsCompleted: number
    productivityScore: number
    createdAt: number
    updatedAt: number
    _all: number
  }


  export type DailySummaryAvgAggregateInputType = {
    totalDistance?: true
    travelTime?: true
    meetingTime?: true
    idleTime?: true
    tripsCompleted?: true
    productivityScore?: true
  }

  export type DailySummarySumAggregateInputType = {
    totalDistance?: true
    travelTime?: true
    meetingTime?: true
    idleTime?: true
    tripsCompleted?: true
    productivityScore?: true
  }

  export type DailySummaryMinAggregateInputType = {
    id?: true
    userId?: true
    date?: true
    totalDistance?: true
    travelTime?: true
    meetingTime?: true
    idleTime?: true
    tripsCompleted?: true
    productivityScore?: true
    createdAt?: true
    updatedAt?: true
  }

  export type DailySummaryMaxAggregateInputType = {
    id?: true
    userId?: true
    date?: true
    totalDistance?: true
    travelTime?: true
    meetingTime?: true
    idleTime?: true
    tripsCompleted?: true
    productivityScore?: true
    createdAt?: true
    updatedAt?: true
  }

  export type DailySummaryCountAggregateInputType = {
    id?: true
    userId?: true
    date?: true
    totalDistance?: true
    travelTime?: true
    meetingTime?: true
    idleTime?: true
    tripsCompleted?: true
    productivityScore?: true
    createdAt?: true
    updatedAt?: true
    _all?: true
  }

  export type DailySummaryAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which DailySummary to aggregate.
     */
    where?: DailySummaryWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of DailySummaries to fetch.
     */
    orderBy?: DailySummaryOrderByWithRelationInput | DailySummaryOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: DailySummaryWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` DailySummaries from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` DailySummaries.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned DailySummaries
    **/
    _count?: true | DailySummaryCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to average
    **/
    _avg?: DailySummaryAvgAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to sum
    **/
    _sum?: DailySummarySumAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: DailySummaryMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: DailySummaryMaxAggregateInputType
  }

  export type GetDailySummaryAggregateType<T extends DailySummaryAggregateArgs> = {
        [P in keyof T & keyof AggregateDailySummary]: P extends '_count' | 'count'
      ? T[P] extends true
        ? number
        : GetScalarType<T[P], AggregateDailySummary[P]>
      : GetScalarType<T[P], AggregateDailySummary[P]>
  }




  export type DailySummaryGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: DailySummaryWhereInput
    orderBy?: DailySummaryOrderByWithAggregationInput | DailySummaryOrderByWithAggregationInput[]
    by: DailySummaryScalarFieldEnum[] | DailySummaryScalarFieldEnum
    having?: DailySummaryScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: DailySummaryCountAggregateInputType | true
    _avg?: DailySummaryAvgAggregateInputType
    _sum?: DailySummarySumAggregateInputType
    _min?: DailySummaryMinAggregateInputType
    _max?: DailySummaryMaxAggregateInputType
  }

  export type DailySummaryGroupByOutputType = {
    id: string
    userId: string
    date: Date
    totalDistance: number
    travelTime: number
    meetingTime: number
    idleTime: number
    tripsCompleted: number
    productivityScore: number | null
    createdAt: Date
    updatedAt: Date
    _count: DailySummaryCountAggregateOutputType | null
    _avg: DailySummaryAvgAggregateOutputType | null
    _sum: DailySummarySumAggregateOutputType | null
    _min: DailySummaryMinAggregateOutputType | null
    _max: DailySummaryMaxAggregateOutputType | null
  }

  type GetDailySummaryGroupByPayload<T extends DailySummaryGroupByArgs> = Prisma.PrismaPromise<
    Array<
      PickEnumerable<DailySummaryGroupByOutputType, T['by']> &
        {
          [P in ((keyof T) & (keyof DailySummaryGroupByOutputType))]: P extends '_count'
            ? T[P] extends boolean
              ? number
              : GetScalarType<T[P], DailySummaryGroupByOutputType[P]>
            : GetScalarType<T[P], DailySummaryGroupByOutputType[P]>
        }
      >
    >


  export type DailySummarySelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    userId?: boolean
    date?: boolean
    totalDistance?: boolean
    travelTime?: boolean
    meetingTime?: boolean
    idleTime?: boolean
    tripsCompleted?: boolean
    productivityScore?: boolean
    createdAt?: boolean
    updatedAt?: boolean
  }, ExtArgs["result"]["dailySummary"]>

  export type DailySummarySelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    userId?: boolean
    date?: boolean
    totalDistance?: boolean
    travelTime?: boolean
    meetingTime?: boolean
    idleTime?: boolean
    tripsCompleted?: boolean
    productivityScore?: boolean
    createdAt?: boolean
    updatedAt?: boolean
  }, ExtArgs["result"]["dailySummary"]>

  export type DailySummarySelectUpdateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    userId?: boolean
    date?: boolean
    totalDistance?: boolean
    travelTime?: boolean
    meetingTime?: boolean
    idleTime?: boolean
    tripsCompleted?: boolean
    productivityScore?: boolean
    createdAt?: boolean
    updatedAt?: boolean
  }, ExtArgs["result"]["dailySummary"]>

  export type DailySummarySelectScalar = {
    id?: boolean
    userId?: boolean
    date?: boolean
    totalDistance?: boolean
    travelTime?: boolean
    meetingTime?: boolean
    idleTime?: boolean
    tripsCompleted?: boolean
    productivityScore?: boolean
    createdAt?: boolean
    updatedAt?: boolean
  }

  export type DailySummaryOmit<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetOmit<"id" | "userId" | "date" | "totalDistance" | "travelTime" | "meetingTime" | "idleTime" | "tripsCompleted" | "productivityScore" | "createdAt" | "updatedAt", ExtArgs["result"]["dailySummary"]>

  export type $DailySummaryPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "DailySummary"
    objects: {}
    scalars: $Extensions.GetPayloadResult<{
      id: string
      userId: string
      date: Date
      totalDistance: number
      travelTime: number
      meetingTime: number
      idleTime: number
      tripsCompleted: number
      productivityScore: number | null
      createdAt: Date
      updatedAt: Date
    }, ExtArgs["result"]["dailySummary"]>
    composites: {}
  }

  type DailySummaryGetPayload<S extends boolean | null | undefined | DailySummaryDefaultArgs> = $Result.GetResult<Prisma.$DailySummaryPayload, S>

  type DailySummaryCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
    Omit<DailySummaryFindManyArgs, 'select' | 'include' | 'distinct' | 'omit'> & {
      select?: DailySummaryCountAggregateInputType | true
    }

  export interface DailySummaryDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs, GlobalOmitOptions = {}> {
    [K: symbol]: { types: Prisma.TypeMap<ExtArgs>['model']['DailySummary'], meta: { name: 'DailySummary' } }
    /**
     * Find zero or one DailySummary that matches the filter.
     * @param {DailySummaryFindUniqueArgs} args - Arguments to find a DailySummary
     * @example
     * // Get one DailySummary
     * const dailySummary = await prisma.dailySummary.findUnique({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findUnique<T extends DailySummaryFindUniqueArgs>(args: SelectSubset<T, DailySummaryFindUniqueArgs<ExtArgs>>): Prisma__DailySummaryClient<$Result.GetResult<Prisma.$DailySummaryPayload<ExtArgs>, T, "findUnique", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>

    /**
     * Find one DailySummary that matches the filter or throw an error with `error.code='P2025'`
     * if no matches were found.
     * @param {DailySummaryFindUniqueOrThrowArgs} args - Arguments to find a DailySummary
     * @example
     * // Get one DailySummary
     * const dailySummary = await prisma.dailySummary.findUniqueOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findUniqueOrThrow<T extends DailySummaryFindUniqueOrThrowArgs>(args: SelectSubset<T, DailySummaryFindUniqueOrThrowArgs<ExtArgs>>): Prisma__DailySummaryClient<$Result.GetResult<Prisma.$DailySummaryPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Find the first DailySummary that matches the filter.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {DailySummaryFindFirstArgs} args - Arguments to find a DailySummary
     * @example
     * // Get one DailySummary
     * const dailySummary = await prisma.dailySummary.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends DailySummaryFindFirstArgs>(args?: SelectSubset<T, DailySummaryFindFirstArgs<ExtArgs>>): Prisma__DailySummaryClient<$Result.GetResult<Prisma.$DailySummaryPayload<ExtArgs>, T, "findFirst", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>

    /**
     * Find the first DailySummary that matches the filter or
     * throw `PrismaKnownClientError` with `P2025` code if no matches were found.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {DailySummaryFindFirstOrThrowArgs} args - Arguments to find a DailySummary
     * @example
     * // Get one DailySummary
     * const dailySummary = await prisma.dailySummary.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends DailySummaryFindFirstOrThrowArgs>(args?: SelectSubset<T, DailySummaryFindFirstOrThrowArgs<ExtArgs>>): Prisma__DailySummaryClient<$Result.GetResult<Prisma.$DailySummaryPayload<ExtArgs>, T, "findFirstOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Find zero or more DailySummaries that matches the filter.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {DailySummaryFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all DailySummaries
     * const dailySummaries = await prisma.dailySummary.findMany()
     * 
     * // Get first 10 DailySummaries
     * const dailySummaries = await prisma.dailySummary.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const dailySummaryWithIdOnly = await prisma.dailySummary.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends DailySummaryFindManyArgs>(args?: SelectSubset<T, DailySummaryFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$DailySummaryPayload<ExtArgs>, T, "findMany", GlobalOmitOptions>>

    /**
     * Create a DailySummary.
     * @param {DailySummaryCreateArgs} args - Arguments to create a DailySummary.
     * @example
     * // Create one DailySummary
     * const DailySummary = await prisma.dailySummary.create({
     *   data: {
     *     // ... data to create a DailySummary
     *   }
     * })
     * 
     */
    create<T extends DailySummaryCreateArgs>(args: SelectSubset<T, DailySummaryCreateArgs<ExtArgs>>): Prisma__DailySummaryClient<$Result.GetResult<Prisma.$DailySummaryPayload<ExtArgs>, T, "create", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Create many DailySummaries.
     * @param {DailySummaryCreateManyArgs} args - Arguments to create many DailySummaries.
     * @example
     * // Create many DailySummaries
     * const dailySummary = await prisma.dailySummary.createMany({
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     *     
     */
    createMany<T extends DailySummaryCreateManyArgs>(args?: SelectSubset<T, DailySummaryCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>

    /**
     * Create many DailySummaries and returns the data saved in the database.
     * @param {DailySummaryCreateManyAndReturnArgs} args - Arguments to create many DailySummaries.
     * @example
     * // Create many DailySummaries
     * const dailySummary = await prisma.dailySummary.createManyAndReturn({
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * 
     * // Create many DailySummaries and only return the `id`
     * const dailySummaryWithIdOnly = await prisma.dailySummary.createManyAndReturn({
     *   select: { id: true },
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * 
     */
    createManyAndReturn<T extends DailySummaryCreateManyAndReturnArgs>(args?: SelectSubset<T, DailySummaryCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$DailySummaryPayload<ExtArgs>, T, "createManyAndReturn", GlobalOmitOptions>>

    /**
     * Delete a DailySummary.
     * @param {DailySummaryDeleteArgs} args - Arguments to delete one DailySummary.
     * @example
     * // Delete one DailySummary
     * const DailySummary = await prisma.dailySummary.delete({
     *   where: {
     *     // ... filter to delete one DailySummary
     *   }
     * })
     * 
     */
    delete<T extends DailySummaryDeleteArgs>(args: SelectSubset<T, DailySummaryDeleteArgs<ExtArgs>>): Prisma__DailySummaryClient<$Result.GetResult<Prisma.$DailySummaryPayload<ExtArgs>, T, "delete", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Update one DailySummary.
     * @param {DailySummaryUpdateArgs} args - Arguments to update one DailySummary.
     * @example
     * // Update one DailySummary
     * const dailySummary = await prisma.dailySummary.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends DailySummaryUpdateArgs>(args: SelectSubset<T, DailySummaryUpdateArgs<ExtArgs>>): Prisma__DailySummaryClient<$Result.GetResult<Prisma.$DailySummaryPayload<ExtArgs>, T, "update", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Delete zero or more DailySummaries.
     * @param {DailySummaryDeleteManyArgs} args - Arguments to filter DailySummaries to delete.
     * @example
     * // Delete a few DailySummaries
     * const { count } = await prisma.dailySummary.deleteMany({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     * 
     */
    deleteMany<T extends DailySummaryDeleteManyArgs>(args?: SelectSubset<T, DailySummaryDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>

    /**
     * Update zero or more DailySummaries.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {DailySummaryUpdateManyArgs} args - Arguments to update one or more rows.
     * @example
     * // Update many DailySummaries
     * const dailySummary = await prisma.dailySummary.updateMany({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    updateMany<T extends DailySummaryUpdateManyArgs>(args: SelectSubset<T, DailySummaryUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>

    /**
     * Update zero or more DailySummaries and returns the data updated in the database.
     * @param {DailySummaryUpdateManyAndReturnArgs} args - Arguments to update many DailySummaries.
     * @example
     * // Update many DailySummaries
     * const dailySummary = await prisma.dailySummary.updateManyAndReturn({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * 
     * // Update zero or more DailySummaries and only return the `id`
     * const dailySummaryWithIdOnly = await prisma.dailySummary.updateManyAndReturn({
     *   select: { id: true },
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * 
     */
    updateManyAndReturn<T extends DailySummaryUpdateManyAndReturnArgs>(args: SelectSubset<T, DailySummaryUpdateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$DailySummaryPayload<ExtArgs>, T, "updateManyAndReturn", GlobalOmitOptions>>

    /**
     * Create or update one DailySummary.
     * @param {DailySummaryUpsertArgs} args - Arguments to update or create a DailySummary.
     * @example
     * // Update or create a DailySummary
     * const dailySummary = await prisma.dailySummary.upsert({
     *   create: {
     *     // ... data to create a DailySummary
     *   },
     *   update: {
     *     // ... in case it already exists, update
     *   },
     *   where: {
     *     // ... the filter for the DailySummary we want to update
     *   }
     * })
     */
    upsert<T extends DailySummaryUpsertArgs>(args: SelectSubset<T, DailySummaryUpsertArgs<ExtArgs>>): Prisma__DailySummaryClient<$Result.GetResult<Prisma.$DailySummaryPayload<ExtArgs>, T, "upsert", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>


    /**
     * Count the number of DailySummaries.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {DailySummaryCountArgs} args - Arguments to filter DailySummaries to count.
     * @example
     * // Count the number of DailySummaries
     * const count = await prisma.dailySummary.count({
     *   where: {
     *     // ... the filter for the DailySummaries we want to count
     *   }
     * })
    **/
    count<T extends DailySummaryCountArgs>(
      args?: Subset<T, DailySummaryCountArgs>,
    ): Prisma.PrismaPromise<
      T extends $Utils.Record<'select', any>
        ? T['select'] extends true
          ? number
          : GetScalarType<T['select'], DailySummaryCountAggregateOutputType>
        : number
    >

    /**
     * Allows you to perform aggregations operations on a DailySummary.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {DailySummaryAggregateArgs} args - Select which aggregations you would like to apply and on what fields.
     * @example
     * // Ordered by age ascending
     * // Where email contains prisma.io
     * // Limited to the 10 users
     * const aggregations = await prisma.user.aggregate({
     *   _avg: {
     *     age: true,
     *   },
     *   where: {
     *     email: {
     *       contains: "prisma.io",
     *     },
     *   },
     *   orderBy: {
     *     age: "asc",
     *   },
     *   take: 10,
     * })
    **/
    aggregate<T extends DailySummaryAggregateArgs>(args: Subset<T, DailySummaryAggregateArgs>): Prisma.PrismaPromise<GetDailySummaryAggregateType<T>>

    /**
     * Group by DailySummary.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {DailySummaryGroupByArgs} args - Group by arguments.
     * @example
     * // Group by city, order by createdAt, get count
     * const result = await prisma.user.groupBy({
     *   by: ['city', 'createdAt'],
     *   orderBy: {
     *     createdAt: true
     *   },
     *   _count: {
     *     _all: true
     *   },
     * })
     * 
    **/
    groupBy<
      T extends DailySummaryGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: DailySummaryGroupByArgs['orderBy'] }
        : { orderBy?: DailySummaryGroupByArgs['orderBy'] },
      OrderFields extends ExcludeUnderscoreKeys<Keys<MaybeTupleToUnion<T['orderBy']>>>,
      ByFields extends MaybeTupleToUnion<T['by']>,
      ByValid extends Has<ByFields, OrderFields>,
      HavingFields extends GetHavingFields<T['having']>,
      HavingValid extends Has<ByFields, HavingFields>,
      ByEmpty extends T['by'] extends never[] ? True : False,
      InputErrors extends ByEmpty extends True
      ? `Error: "by" must not be empty.`
      : HavingValid extends False
      ? {
          [P in HavingFields]: P extends ByFields
            ? never
            : P extends string
            ? `Error: Field "${P}" used in "having" needs to be provided in "by".`
            : [
                Error,
                'Field ',
                P,
                ` in "having" needs to be provided in "by"`,
              ]
        }[HavingFields]
      : 'take' extends Keys<T>
      ? 'orderBy' extends Keys<T>
        ? ByValid extends True
          ? {}
          : {
              [P in OrderFields]: P extends ByFields
                ? never
                : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
            }[OrderFields]
        : 'Error: If you provide "take", you also need to provide "orderBy"'
      : 'skip' extends Keys<T>
      ? 'orderBy' extends Keys<T>
        ? ByValid extends True
          ? {}
          : {
              [P in OrderFields]: P extends ByFields
                ? never
                : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
            }[OrderFields]
        : 'Error: If you provide "skip", you also need to provide "orderBy"'
      : ByValid extends True
      ? {}
      : {
          [P in OrderFields]: P extends ByFields
            ? never
            : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
        }[OrderFields]
    >(args: SubsetIntersection<T, DailySummaryGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetDailySummaryGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the DailySummary model
   */
  readonly fields: DailySummaryFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for DailySummary.
   * Why is this prefixed with `Prisma__`?
   * Because we want to prevent naming conflicts as mentioned in
   * https://github.com/prisma/prisma-client-js/issues/707
   */
  export interface Prisma__DailySummaryClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs, GlobalOmitOptions = {}> extends Prisma.PrismaPromise<T> {
    readonly [Symbol.toStringTag]: "PrismaPromise"
    /**
     * Attaches callbacks for the resolution and/or rejection of the Promise.
     * @param onfulfilled The callback to execute when the Promise is resolved.
     * @param onrejected The callback to execute when the Promise is rejected.
     * @returns A Promise for the completion of which ever callback is executed.
     */
    then<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): $Utils.JsPromise<TResult1 | TResult2>
    /**
     * Attaches a callback for only the rejection of the Promise.
     * @param onrejected The callback to execute when the Promise is rejected.
     * @returns A Promise for the completion of the callback.
     */
    catch<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): $Utils.JsPromise<T | TResult>
    /**
     * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The
     * resolved value cannot be modified from the callback.
     * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected).
     * @returns A Promise for the completion of the callback.
     */
    finally(onfinally?: (() => void) | undefined | null): $Utils.JsPromise<T>
  }




  /**
   * Fields of the DailySummary model
   */
  interface DailySummaryFieldRefs {
    readonly id: FieldRef<"DailySummary", 'String'>
    readonly userId: FieldRef<"DailySummary", 'String'>
    readonly date: FieldRef<"DailySummary", 'DateTime'>
    readonly totalDistance: FieldRef<"DailySummary", 'Float'>
    readonly travelTime: FieldRef<"DailySummary", 'Int'>
    readonly meetingTime: FieldRef<"DailySummary", 'Int'>
    readonly idleTime: FieldRef<"DailySummary", 'Int'>
    readonly tripsCompleted: FieldRef<"DailySummary", 'Int'>
    readonly productivityScore: FieldRef<"DailySummary", 'Float'>
    readonly createdAt: FieldRef<"DailySummary", 'DateTime'>
    readonly updatedAt: FieldRef<"DailySummary", 'DateTime'>
  }
    

  // Custom InputTypes
  /**
   * DailySummary findUnique
   */
  export type DailySummaryFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the DailySummary
     */
    select?: DailySummarySelect<ExtArgs> | null
    /**
     * Omit specific fields from the DailySummary
     */
    omit?: DailySummaryOmit<ExtArgs> | null
    /**
     * Filter, which DailySummary to fetch.
     */
    where: DailySummaryWhereUniqueInput
  }

  /**
   * DailySummary findUniqueOrThrow
   */
  export type DailySummaryFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the DailySummary
     */
    select?: DailySummarySelect<ExtArgs> | null
    /**
     * Omit specific fields from the DailySummary
     */
    omit?: DailySummaryOmit<ExtArgs> | null
    /**
     * Filter, which DailySummary to fetch.
     */
    where: DailySummaryWhereUniqueInput
  }

  /**
   * DailySummary findFirst
   */
  export type DailySummaryFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the DailySummary
     */
    select?: DailySummarySelect<ExtArgs> | null
    /**
     * Omit specific fields from the DailySummary
     */
    omit?: DailySummaryOmit<ExtArgs> | null
    /**
     * Filter, which DailySummary to fetch.
     */
    where?: DailySummaryWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of DailySummaries to fetch.
     */
    orderBy?: DailySummaryOrderByWithRelationInput | DailySummaryOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for DailySummaries.
     */
    cursor?: DailySummaryWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` DailySummaries from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` DailySummaries.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of DailySummaries.
     */
    distinct?: DailySummaryScalarFieldEnum | DailySummaryScalarFieldEnum[]
  }

  /**
   * DailySummary findFirstOrThrow
   */
  export type DailySummaryFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the DailySummary
     */
    select?: DailySummarySelect<ExtArgs> | null
    /**
     * Omit specific fields from the DailySummary
     */
    omit?: DailySummaryOmit<ExtArgs> | null
    /**
     * Filter, which DailySummary to fetch.
     */
    where?: DailySummaryWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of DailySummaries to fetch.
     */
    orderBy?: DailySummaryOrderByWithRelationInput | DailySummaryOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for DailySummaries.
     */
    cursor?: DailySummaryWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` DailySummaries from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` DailySummaries.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of DailySummaries.
     */
    distinct?: DailySummaryScalarFieldEnum | DailySummaryScalarFieldEnum[]
  }

  /**
   * DailySummary findMany
   */
  export type DailySummaryFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the DailySummary
     */
    select?: DailySummarySelect<ExtArgs> | null
    /**
     * Omit specific fields from the DailySummary
     */
    omit?: DailySummaryOmit<ExtArgs> | null
    /**
     * Filter, which DailySummaries to fetch.
     */
    where?: DailySummaryWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of DailySummaries to fetch.
     */
    orderBy?: DailySummaryOrderByWithRelationInput | DailySummaryOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing DailySummaries.
     */
    cursor?: DailySummaryWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` DailySummaries from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` DailySummaries.
     */
    skip?: number
    distinct?: DailySummaryScalarFieldEnum | DailySummaryScalarFieldEnum[]
  }

  /**
   * DailySummary create
   */
  export type DailySummaryCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the DailySummary
     */
    select?: DailySummarySelect<ExtArgs> | null
    /**
     * Omit specific fields from the DailySummary
     */
    omit?: DailySummaryOmit<ExtArgs> | null
    /**
     * The data needed to create a DailySummary.
     */
    data: XOR<DailySummaryCreateInput, DailySummaryUncheckedCreateInput>
  }

  /**
   * DailySummary createMany
   */
  export type DailySummaryCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many DailySummaries.
     */
    data: DailySummaryCreateManyInput | DailySummaryCreateManyInput[]
  }

  /**
   * DailySummary createManyAndReturn
   */
  export type DailySummaryCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the DailySummary
     */
    select?: DailySummarySelectCreateManyAndReturn<ExtArgs> | null
    /**
     * Omit specific fields from the DailySummary
     */
    omit?: DailySummaryOmit<ExtArgs> | null
    /**
     * The data used to create many DailySummaries.
     */
    data: DailySummaryCreateManyInput | DailySummaryCreateManyInput[]
  }

  /**
   * DailySummary update
   */
  export type DailySummaryUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the DailySummary
     */
    select?: DailySummarySelect<ExtArgs> | null
    /**
     * Omit specific fields from the DailySummary
     */
    omit?: DailySummaryOmit<ExtArgs> | null
    /**
     * The data needed to update a DailySummary.
     */
    data: XOR<DailySummaryUpdateInput, DailySummaryUncheckedUpdateInput>
    /**
     * Choose, which DailySummary to update.
     */
    where: DailySummaryWhereUniqueInput
  }

  /**
   * DailySummary updateMany
   */
  export type DailySummaryUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update DailySummaries.
     */
    data: XOR<DailySummaryUpdateManyMutationInput, DailySummaryUncheckedUpdateManyInput>
    /**
     * Filter which DailySummaries to update
     */
    where?: DailySummaryWhereInput
    /**
     * Limit how many DailySummaries to update.
     */
    limit?: number
  }

  /**
   * DailySummary updateManyAndReturn
   */
  export type DailySummaryUpdateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the DailySummary
     */
    select?: DailySummarySelectUpdateManyAndReturn<ExtArgs> | null
    /**
     * Omit specific fields from the DailySummary
     */
    omit?: DailySummaryOmit<ExtArgs> | null
    /**
     * The data used to update DailySummaries.
     */
    data: XOR<DailySummaryUpdateManyMutationInput, DailySummaryUncheckedUpdateManyInput>
    /**
     * Filter which DailySummaries to update
     */
    where?: DailySummaryWhereInput
    /**
     * Limit how many DailySummaries to update.
     */
    limit?: number
  }

  /**
   * DailySummary upsert
   */
  export type DailySummaryUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the DailySummary
     */
    select?: DailySummarySelect<ExtArgs> | null
    /**
     * Omit specific fields from the DailySummary
     */
    omit?: DailySummaryOmit<ExtArgs> | null
    /**
     * The filter to search for the DailySummary to update in case it exists.
     */
    where: DailySummaryWhereUniqueInput
    /**
     * In case the DailySummary found by the `where` argument doesn't exist, create a new DailySummary with this data.
     */
    create: XOR<DailySummaryCreateInput, DailySummaryUncheckedCreateInput>
    /**
     * In case the DailySummary was found with the provided `where` argument, update it with this data.
     */
    update: XOR<DailySummaryUpdateInput, DailySummaryUncheckedUpdateInput>
  }

  /**
   * DailySummary delete
   */
  export type DailySummaryDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the DailySummary
     */
    select?: DailySummarySelect<ExtArgs> | null
    /**
     * Omit specific fields from the DailySummary
     */
    omit?: DailySummaryOmit<ExtArgs> | null
    /**
     * Filter which DailySummary to delete.
     */
    where: DailySummaryWhereUniqueInput
  }

  /**
   * DailySummary deleteMany
   */
  export type DailySummaryDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which DailySummaries to delete
     */
    where?: DailySummaryWhereInput
    /**
     * Limit how many DailySummaries to delete.
     */
    limit?: number
  }

  /**
   * DailySummary without action
   */
  export type DailySummaryDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the DailySummary
     */
    select?: DailySummarySelect<ExtArgs> | null
    /**
     * Omit specific fields from the DailySummary
     */
    omit?: DailySummaryOmit<ExtArgs> | null
  }


  /**
   * Model MonthlySummary
   */

  export type AggregateMonthlySummary = {
    _count: MonthlySummaryCountAggregateOutputType | null
    _avg: MonthlySummaryAvgAggregateOutputType | null
    _sum: MonthlySummarySumAggregateOutputType | null
    _min: MonthlySummaryMinAggregateOutputType | null
    _max: MonthlySummaryMaxAggregateOutputType | null
  }

  export type MonthlySummaryAvgAggregateOutputType = {
    year: number | null
    month: number | null
    totalDistance: number | null
    travelTime: number | null
    meetingTime: number | null
    idleTime: number | null
    tripsCompleted: number | null
    productivityScore: number | null
  }

  export type MonthlySummarySumAggregateOutputType = {
    year: number | null
    month: number | null
    totalDistance: number | null
    travelTime: number | null
    meetingTime: number | null
    idleTime: number | null
    tripsCompleted: number | null
    productivityScore: number | null
  }

  export type MonthlySummaryMinAggregateOutputType = {
    id: string | null
    userId: string | null
    year: number | null
    month: number | null
    totalDistance: number | null
    travelTime: number | null
    meetingTime: number | null
    idleTime: number | null
    tripsCompleted: number | null
    productivityScore: number | null
  }

  export type MonthlySummaryMaxAggregateOutputType = {
    id: string | null
    userId: string | null
    year: number | null
    month: number | null
    totalDistance: number | null
    travelTime: number | null
    meetingTime: number | null
    idleTime: number | null
    tripsCompleted: number | null
    productivityScore: number | null
  }

  export type MonthlySummaryCountAggregateOutputType = {
    id: number
    userId: number
    year: number
    month: number
    totalDistance: number
    travelTime: number
    meetingTime: number
    idleTime: number
    tripsCompleted: number
    productivityScore: number
    _all: number
  }


  export type MonthlySummaryAvgAggregateInputType = {
    year?: true
    month?: true
    totalDistance?: true
    travelTime?: true
    meetingTime?: true
    idleTime?: true
    tripsCompleted?: true
    productivityScore?: true
  }

  export type MonthlySummarySumAggregateInputType = {
    year?: true
    month?: true
    totalDistance?: true
    travelTime?: true
    meetingTime?: true
    idleTime?: true
    tripsCompleted?: true
    productivityScore?: true
  }

  export type MonthlySummaryMinAggregateInputType = {
    id?: true
    userId?: true
    year?: true
    month?: true
    totalDistance?: true
    travelTime?: true
    meetingTime?: true
    idleTime?: true
    tripsCompleted?: true
    productivityScore?: true
  }

  export type MonthlySummaryMaxAggregateInputType = {
    id?: true
    userId?: true
    year?: true
    month?: true
    totalDistance?: true
    travelTime?: true
    meetingTime?: true
    idleTime?: true
    tripsCompleted?: true
    productivityScore?: true
  }

  export type MonthlySummaryCountAggregateInputType = {
    id?: true
    userId?: true
    year?: true
    month?: true
    totalDistance?: true
    travelTime?: true
    meetingTime?: true
    idleTime?: true
    tripsCompleted?: true
    productivityScore?: true
    _all?: true
  }

  export type MonthlySummaryAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which MonthlySummary to aggregate.
     */
    where?: MonthlySummaryWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of MonthlySummaries to fetch.
     */
    orderBy?: MonthlySummaryOrderByWithRelationInput | MonthlySummaryOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: MonthlySummaryWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` MonthlySummaries from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` MonthlySummaries.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned MonthlySummaries
    **/
    _count?: true | MonthlySummaryCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to average
    **/
    _avg?: MonthlySummaryAvgAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to sum
    **/
    _sum?: MonthlySummarySumAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: MonthlySummaryMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: MonthlySummaryMaxAggregateInputType
  }

  export type GetMonthlySummaryAggregateType<T extends MonthlySummaryAggregateArgs> = {
        [P in keyof T & keyof AggregateMonthlySummary]: P extends '_count' | 'count'
      ? T[P] extends true
        ? number
        : GetScalarType<T[P], AggregateMonthlySummary[P]>
      : GetScalarType<T[P], AggregateMonthlySummary[P]>
  }




  export type MonthlySummaryGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: MonthlySummaryWhereInput
    orderBy?: MonthlySummaryOrderByWithAggregationInput | MonthlySummaryOrderByWithAggregationInput[]
    by: MonthlySummaryScalarFieldEnum[] | MonthlySummaryScalarFieldEnum
    having?: MonthlySummaryScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: MonthlySummaryCountAggregateInputType | true
    _avg?: MonthlySummaryAvgAggregateInputType
    _sum?: MonthlySummarySumAggregateInputType
    _min?: MonthlySummaryMinAggregateInputType
    _max?: MonthlySummaryMaxAggregateInputType
  }

  export type MonthlySummaryGroupByOutputType = {
    id: string
    userId: string
    year: number
    month: number
    totalDistance: number
    travelTime: number
    meetingTime: number
    idleTime: number
    tripsCompleted: number
    productivityScore: number | null
    _count: MonthlySummaryCountAggregateOutputType | null
    _avg: MonthlySummaryAvgAggregateOutputType | null
    _sum: MonthlySummarySumAggregateOutputType | null
    _min: MonthlySummaryMinAggregateOutputType | null
    _max: MonthlySummaryMaxAggregateOutputType | null
  }

  type GetMonthlySummaryGroupByPayload<T extends MonthlySummaryGroupByArgs> = Prisma.PrismaPromise<
    Array<
      PickEnumerable<MonthlySummaryGroupByOutputType, T['by']> &
        {
          [P in ((keyof T) & (keyof MonthlySummaryGroupByOutputType))]: P extends '_count'
            ? T[P] extends boolean
              ? number
              : GetScalarType<T[P], MonthlySummaryGroupByOutputType[P]>
            : GetScalarType<T[P], MonthlySummaryGroupByOutputType[P]>
        }
      >
    >


  export type MonthlySummarySelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    userId?: boolean
    year?: boolean
    month?: boolean
    totalDistance?: boolean
    travelTime?: boolean
    meetingTime?: boolean
    idleTime?: boolean
    tripsCompleted?: boolean
    productivityScore?: boolean
  }, ExtArgs["result"]["monthlySummary"]>

  export type MonthlySummarySelectCreateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    userId?: boolean
    year?: boolean
    month?: boolean
    totalDistance?: boolean
    travelTime?: boolean
    meetingTime?: boolean
    idleTime?: boolean
    tripsCompleted?: boolean
    productivityScore?: boolean
  }, ExtArgs["result"]["monthlySummary"]>

  export type MonthlySummarySelectUpdateManyAndReturn<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    userId?: boolean
    year?: boolean
    month?: boolean
    totalDistance?: boolean
    travelTime?: boolean
    meetingTime?: boolean
    idleTime?: boolean
    tripsCompleted?: boolean
    productivityScore?: boolean
  }, ExtArgs["result"]["monthlySummary"]>

  export type MonthlySummarySelectScalar = {
    id?: boolean
    userId?: boolean
    year?: boolean
    month?: boolean
    totalDistance?: boolean
    travelTime?: boolean
    meetingTime?: boolean
    idleTime?: boolean
    tripsCompleted?: boolean
    productivityScore?: boolean
  }

  export type MonthlySummaryOmit<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetOmit<"id" | "userId" | "year" | "month" | "totalDistance" | "travelTime" | "meetingTime" | "idleTime" | "tripsCompleted" | "productivityScore", ExtArgs["result"]["monthlySummary"]>

  export type $MonthlySummaryPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "MonthlySummary"
    objects: {}
    scalars: $Extensions.GetPayloadResult<{
      id: string
      userId: string
      year: number
      month: number
      totalDistance: number
      travelTime: number
      meetingTime: number
      idleTime: number
      tripsCompleted: number
      productivityScore: number | null
    }, ExtArgs["result"]["monthlySummary"]>
    composites: {}
  }

  type MonthlySummaryGetPayload<S extends boolean | null | undefined | MonthlySummaryDefaultArgs> = $Result.GetResult<Prisma.$MonthlySummaryPayload, S>

  type MonthlySummaryCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> =
    Omit<MonthlySummaryFindManyArgs, 'select' | 'include' | 'distinct' | 'omit'> & {
      select?: MonthlySummaryCountAggregateInputType | true
    }

  export interface MonthlySummaryDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs, GlobalOmitOptions = {}> {
    [K: symbol]: { types: Prisma.TypeMap<ExtArgs>['model']['MonthlySummary'], meta: { name: 'MonthlySummary' } }
    /**
     * Find zero or one MonthlySummary that matches the filter.
     * @param {MonthlySummaryFindUniqueArgs} args - Arguments to find a MonthlySummary
     * @example
     * // Get one MonthlySummary
     * const monthlySummary = await prisma.monthlySummary.findUnique({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findUnique<T extends MonthlySummaryFindUniqueArgs>(args: SelectSubset<T, MonthlySummaryFindUniqueArgs<ExtArgs>>): Prisma__MonthlySummaryClient<$Result.GetResult<Prisma.$MonthlySummaryPayload<ExtArgs>, T, "findUnique", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>

    /**
     * Find one MonthlySummary that matches the filter or throw an error with `error.code='P2025'`
     * if no matches were found.
     * @param {MonthlySummaryFindUniqueOrThrowArgs} args - Arguments to find a MonthlySummary
     * @example
     * // Get one MonthlySummary
     * const monthlySummary = await prisma.monthlySummary.findUniqueOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findUniqueOrThrow<T extends MonthlySummaryFindUniqueOrThrowArgs>(args: SelectSubset<T, MonthlySummaryFindUniqueOrThrowArgs<ExtArgs>>): Prisma__MonthlySummaryClient<$Result.GetResult<Prisma.$MonthlySummaryPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Find the first MonthlySummary that matches the filter.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {MonthlySummaryFindFirstArgs} args - Arguments to find a MonthlySummary
     * @example
     * // Get one MonthlySummary
     * const monthlySummary = await prisma.monthlySummary.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends MonthlySummaryFindFirstArgs>(args?: SelectSubset<T, MonthlySummaryFindFirstArgs<ExtArgs>>): Prisma__MonthlySummaryClient<$Result.GetResult<Prisma.$MonthlySummaryPayload<ExtArgs>, T, "findFirst", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>

    /**
     * Find the first MonthlySummary that matches the filter or
     * throw `PrismaKnownClientError` with `P2025` code if no matches were found.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {MonthlySummaryFindFirstOrThrowArgs} args - Arguments to find a MonthlySummary
     * @example
     * // Get one MonthlySummary
     * const monthlySummary = await prisma.monthlySummary.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends MonthlySummaryFindFirstOrThrowArgs>(args?: SelectSubset<T, MonthlySummaryFindFirstOrThrowArgs<ExtArgs>>): Prisma__MonthlySummaryClient<$Result.GetResult<Prisma.$MonthlySummaryPayload<ExtArgs>, T, "findFirstOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Find zero or more MonthlySummaries that matches the filter.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {MonthlySummaryFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all MonthlySummaries
     * const monthlySummaries = await prisma.monthlySummary.findMany()
     * 
     * // Get first 10 MonthlySummaries
     * const monthlySummaries = await prisma.monthlySummary.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const monthlySummaryWithIdOnly = await prisma.monthlySummary.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends MonthlySummaryFindManyArgs>(args?: SelectSubset<T, MonthlySummaryFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$MonthlySummaryPayload<ExtArgs>, T, "findMany", GlobalOmitOptions>>

    /**
     * Create a MonthlySummary.
     * @param {MonthlySummaryCreateArgs} args - Arguments to create a MonthlySummary.
     * @example
     * // Create one MonthlySummary
     * const MonthlySummary = await prisma.monthlySummary.create({
     *   data: {
     *     // ... data to create a MonthlySummary
     *   }
     * })
     * 
     */
    create<T extends MonthlySummaryCreateArgs>(args: SelectSubset<T, MonthlySummaryCreateArgs<ExtArgs>>): Prisma__MonthlySummaryClient<$Result.GetResult<Prisma.$MonthlySummaryPayload<ExtArgs>, T, "create", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Create many MonthlySummaries.
     * @param {MonthlySummaryCreateManyArgs} args - Arguments to create many MonthlySummaries.
     * @example
     * // Create many MonthlySummaries
     * const monthlySummary = await prisma.monthlySummary.createMany({
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     *     
     */
    createMany<T extends MonthlySummaryCreateManyArgs>(args?: SelectSubset<T, MonthlySummaryCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>

    /**
     * Create many MonthlySummaries and returns the data saved in the database.
     * @param {MonthlySummaryCreateManyAndReturnArgs} args - Arguments to create many MonthlySummaries.
     * @example
     * // Create many MonthlySummaries
     * const monthlySummary = await prisma.monthlySummary.createManyAndReturn({
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * 
     * // Create many MonthlySummaries and only return the `id`
     * const monthlySummaryWithIdOnly = await prisma.monthlySummary.createManyAndReturn({
     *   select: { id: true },
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * 
     */
    createManyAndReturn<T extends MonthlySummaryCreateManyAndReturnArgs>(args?: SelectSubset<T, MonthlySummaryCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$MonthlySummaryPayload<ExtArgs>, T, "createManyAndReturn", GlobalOmitOptions>>

    /**
     * Delete a MonthlySummary.
     * @param {MonthlySummaryDeleteArgs} args - Arguments to delete one MonthlySummary.
     * @example
     * // Delete one MonthlySummary
     * const MonthlySummary = await prisma.monthlySummary.delete({
     *   where: {
     *     // ... filter to delete one MonthlySummary
     *   }
     * })
     * 
     */
    delete<T extends MonthlySummaryDeleteArgs>(args: SelectSubset<T, MonthlySummaryDeleteArgs<ExtArgs>>): Prisma__MonthlySummaryClient<$Result.GetResult<Prisma.$MonthlySummaryPayload<ExtArgs>, T, "delete", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Update one MonthlySummary.
     * @param {MonthlySummaryUpdateArgs} args - Arguments to update one MonthlySummary.
     * @example
     * // Update one MonthlySummary
     * const monthlySummary = await prisma.monthlySummary.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends MonthlySummaryUpdateArgs>(args: SelectSubset<T, MonthlySummaryUpdateArgs<ExtArgs>>): Prisma__MonthlySummaryClient<$Result.GetResult<Prisma.$MonthlySummaryPayload<ExtArgs>, T, "update", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

    /**
     * Delete zero or more MonthlySummaries.
     * @param {MonthlySummaryDeleteManyArgs} args - Arguments to filter MonthlySummaries to delete.
     * @example
     * // Delete a few MonthlySummaries
     * const { count } = await prisma.monthlySummary.deleteMany({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     * 
     */
    deleteMany<T extends MonthlySummaryDeleteManyArgs>(args?: SelectSubset<T, MonthlySummaryDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>

    /**
     * Update zero or more MonthlySummaries.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {MonthlySummaryUpdateManyArgs} args - Arguments to update one or more rows.
     * @example
     * // Update many MonthlySummaries
     * const monthlySummary = await prisma.monthlySummary.updateMany({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    updateMany<T extends MonthlySummaryUpdateManyArgs>(args: SelectSubset<T, MonthlySummaryUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<BatchPayload>

    /**
     * Update zero or more MonthlySummaries and returns the data updated in the database.
     * @param {MonthlySummaryUpdateManyAndReturnArgs} args - Arguments to update many MonthlySummaries.
     * @example
     * // Update many MonthlySummaries
     * const monthlySummary = await prisma.monthlySummary.updateManyAndReturn({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * 
     * // Update zero or more MonthlySummaries and only return the `id`
     * const monthlySummaryWithIdOnly = await prisma.monthlySummary.updateManyAndReturn({
     *   select: { id: true },
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: [
     *     // ... provide data here
     *   ]
     * })
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * 
     */
    updateManyAndReturn<T extends MonthlySummaryUpdateManyAndReturnArgs>(args: SelectSubset<T, MonthlySummaryUpdateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$MonthlySummaryPayload<ExtArgs>, T, "updateManyAndReturn", GlobalOmitOptions>>

    /**
     * Create or update one MonthlySummary.
     * @param {MonthlySummaryUpsertArgs} args - Arguments to update or create a MonthlySummary.
     * @example
     * // Update or create a MonthlySummary
     * const monthlySummary = await prisma.monthlySummary.upsert({
     *   create: {
     *     // ... data to create a MonthlySummary
     *   },
     *   update: {
     *     // ... in case it already exists, update
     *   },
     *   where: {
     *     // ... the filter for the MonthlySummary we want to update
     *   }
     * })
     */
    upsert<T extends MonthlySummaryUpsertArgs>(args: SelectSubset<T, MonthlySummaryUpsertArgs<ExtArgs>>): Prisma__MonthlySummaryClient<$Result.GetResult<Prisma.$MonthlySummaryPayload<ExtArgs>, T, "upsert", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>


    /**
     * Count the number of MonthlySummaries.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {MonthlySummaryCountArgs} args - Arguments to filter MonthlySummaries to count.
     * @example
     * // Count the number of MonthlySummaries
     * const count = await prisma.monthlySummary.count({
     *   where: {
     *     // ... the filter for the MonthlySummaries we want to count
     *   }
     * })
    **/
    count<T extends MonthlySummaryCountArgs>(
      args?: Subset<T, MonthlySummaryCountArgs>,
    ): Prisma.PrismaPromise<
      T extends $Utils.Record<'select', any>
        ? T['select'] extends true
          ? number
          : GetScalarType<T['select'], MonthlySummaryCountAggregateOutputType>
        : number
    >

    /**
     * Allows you to perform aggregations operations on a MonthlySummary.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {MonthlySummaryAggregateArgs} args - Select which aggregations you would like to apply and on what fields.
     * @example
     * // Ordered by age ascending
     * // Where email contains prisma.io
     * // Limited to the 10 users
     * const aggregations = await prisma.user.aggregate({
     *   _avg: {
     *     age: true,
     *   },
     *   where: {
     *     email: {
     *       contains: "prisma.io",
     *     },
     *   },
     *   orderBy: {
     *     age: "asc",
     *   },
     *   take: 10,
     * })
    **/
    aggregate<T extends MonthlySummaryAggregateArgs>(args: Subset<T, MonthlySummaryAggregateArgs>): Prisma.PrismaPromise<GetMonthlySummaryAggregateType<T>>

    /**
     * Group by MonthlySummary.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {MonthlySummaryGroupByArgs} args - Group by arguments.
     * @example
     * // Group by city, order by createdAt, get count
     * const result = await prisma.user.groupBy({
     *   by: ['city', 'createdAt'],
     *   orderBy: {
     *     createdAt: true
     *   },
     *   _count: {
     *     _all: true
     *   },
     * })
     * 
    **/
    groupBy<
      T extends MonthlySummaryGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: MonthlySummaryGroupByArgs['orderBy'] }
        : { orderBy?: MonthlySummaryGroupByArgs['orderBy'] },
      OrderFields extends ExcludeUnderscoreKeys<Keys<MaybeTupleToUnion<T['orderBy']>>>,
      ByFields extends MaybeTupleToUnion<T['by']>,
      ByValid extends Has<ByFields, OrderFields>,
      HavingFields extends GetHavingFields<T['having']>,
      HavingValid extends Has<ByFields, HavingFields>,
      ByEmpty extends T['by'] extends never[] ? True : False,
      InputErrors extends ByEmpty extends True
      ? `Error: "by" must not be empty.`
      : HavingValid extends False
      ? {
          [P in HavingFields]: P extends ByFields
            ? never
            : P extends string
            ? `Error: Field "${P}" used in "having" needs to be provided in "by".`
            : [
                Error,
                'Field ',
                P,
                ` in "having" needs to be provided in "by"`,
              ]
        }[HavingFields]
      : 'take' extends Keys<T>
      ? 'orderBy' extends Keys<T>
        ? ByValid extends True
          ? {}
          : {
              [P in OrderFields]: P extends ByFields
                ? never
                : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
            }[OrderFields]
        : 'Error: If you provide "take", you also need to provide "orderBy"'
      : 'skip' extends Keys<T>
      ? 'orderBy' extends Keys<T>
        ? ByValid extends True
          ? {}
          : {
              [P in OrderFields]: P extends ByFields
                ? never
                : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
            }[OrderFields]
        : 'Error: If you provide "skip", you also need to provide "orderBy"'
      : ByValid extends True
      ? {}
      : {
          [P in OrderFields]: P extends ByFields
            ? never
            : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
        }[OrderFields]
    >(args: SubsetIntersection<T, MonthlySummaryGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetMonthlySummaryGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the MonthlySummary model
   */
  readonly fields: MonthlySummaryFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for MonthlySummary.
   * Why is this prefixed with `Prisma__`?
   * Because we want to prevent naming conflicts as mentioned in
   * https://github.com/prisma/prisma-client-js/issues/707
   */
  export interface Prisma__MonthlySummaryClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs, GlobalOmitOptions = {}> extends Prisma.PrismaPromise<T> {
    readonly [Symbol.toStringTag]: "PrismaPromise"
    /**
     * Attaches callbacks for the resolution and/or rejection of the Promise.
     * @param onfulfilled The callback to execute when the Promise is resolved.
     * @param onrejected The callback to execute when the Promise is rejected.
     * @returns A Promise for the completion of which ever callback is executed.
     */
    then<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): $Utils.JsPromise<TResult1 | TResult2>
    /**
     * Attaches a callback for only the rejection of the Promise.
     * @param onrejected The callback to execute when the Promise is rejected.
     * @returns A Promise for the completion of the callback.
     */
    catch<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): $Utils.JsPromise<T | TResult>
    /**
     * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The
     * resolved value cannot be modified from the callback.
     * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected).
     * @returns A Promise for the completion of the callback.
     */
    finally(onfinally?: (() => void) | undefined | null): $Utils.JsPromise<T>
  }




  /**
   * Fields of the MonthlySummary model
   */
  interface MonthlySummaryFieldRefs {
    readonly id: FieldRef<"MonthlySummary", 'String'>
    readonly userId: FieldRef<"MonthlySummary", 'String'>
    readonly year: FieldRef<"MonthlySummary", 'Int'>
    readonly month: FieldRef<"MonthlySummary", 'Int'>
    readonly totalDistance: FieldRef<"MonthlySummary", 'Float'>
    readonly travelTime: FieldRef<"MonthlySummary", 'Int'>
    readonly meetingTime: FieldRef<"MonthlySummary", 'Int'>
    readonly idleTime: FieldRef<"MonthlySummary", 'Int'>
    readonly tripsCompleted: FieldRef<"MonthlySummary", 'Int'>
    readonly productivityScore: FieldRef<"MonthlySummary", 'Float'>
  }
    

  // Custom InputTypes
  /**
   * MonthlySummary findUnique
   */
  export type MonthlySummaryFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the MonthlySummary
     */
    select?: MonthlySummarySelect<ExtArgs> | null
    /**
     * Omit specific fields from the MonthlySummary
     */
    omit?: MonthlySummaryOmit<ExtArgs> | null
    /**
     * Filter, which MonthlySummary to fetch.
     */
    where: MonthlySummaryWhereUniqueInput
  }

  /**
   * MonthlySummary findUniqueOrThrow
   */
  export type MonthlySummaryFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the MonthlySummary
     */
    select?: MonthlySummarySelect<ExtArgs> | null
    /**
     * Omit specific fields from the MonthlySummary
     */
    omit?: MonthlySummaryOmit<ExtArgs> | null
    /**
     * Filter, which MonthlySummary to fetch.
     */
    where: MonthlySummaryWhereUniqueInput
  }

  /**
   * MonthlySummary findFirst
   */
  export type MonthlySummaryFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the MonthlySummary
     */
    select?: MonthlySummarySelect<ExtArgs> | null
    /**
     * Omit specific fields from the MonthlySummary
     */
    omit?: MonthlySummaryOmit<ExtArgs> | null
    /**
     * Filter, which MonthlySummary to fetch.
     */
    where?: MonthlySummaryWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of MonthlySummaries to fetch.
     */
    orderBy?: MonthlySummaryOrderByWithRelationInput | MonthlySummaryOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for MonthlySummaries.
     */
    cursor?: MonthlySummaryWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` MonthlySummaries from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` MonthlySummaries.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of MonthlySummaries.
     */
    distinct?: MonthlySummaryScalarFieldEnum | MonthlySummaryScalarFieldEnum[]
  }

  /**
   * MonthlySummary findFirstOrThrow
   */
  export type MonthlySummaryFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the MonthlySummary
     */
    select?: MonthlySummarySelect<ExtArgs> | null
    /**
     * Omit specific fields from the MonthlySummary
     */
    omit?: MonthlySummaryOmit<ExtArgs> | null
    /**
     * Filter, which MonthlySummary to fetch.
     */
    where?: MonthlySummaryWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of MonthlySummaries to fetch.
     */
    orderBy?: MonthlySummaryOrderByWithRelationInput | MonthlySummaryOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for MonthlySummaries.
     */
    cursor?: MonthlySummaryWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` MonthlySummaries from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` MonthlySummaries.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of MonthlySummaries.
     */
    distinct?: MonthlySummaryScalarFieldEnum | MonthlySummaryScalarFieldEnum[]
  }

  /**
   * MonthlySummary findMany
   */
  export type MonthlySummaryFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the MonthlySummary
     */
    select?: MonthlySummarySelect<ExtArgs> | null
    /**
     * Omit specific fields from the MonthlySummary
     */
    omit?: MonthlySummaryOmit<ExtArgs> | null
    /**
     * Filter, which MonthlySummaries to fetch.
     */
    where?: MonthlySummaryWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of MonthlySummaries to fetch.
     */
    orderBy?: MonthlySummaryOrderByWithRelationInput | MonthlySummaryOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing MonthlySummaries.
     */
    cursor?: MonthlySummaryWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` MonthlySummaries from the position of the cursor.
     */
    take?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Skip the first `n` MonthlySummaries.
     */
    skip?: number
    distinct?: MonthlySummaryScalarFieldEnum | MonthlySummaryScalarFieldEnum[]
  }

  /**
   * MonthlySummary create
   */
  export type MonthlySummaryCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the MonthlySummary
     */
    select?: MonthlySummarySelect<ExtArgs> | null
    /**
     * Omit specific fields from the MonthlySummary
     */
    omit?: MonthlySummaryOmit<ExtArgs> | null
    /**
     * The data needed to create a MonthlySummary.
     */
    data: XOR<MonthlySummaryCreateInput, MonthlySummaryUncheckedCreateInput>
  }

  /**
   * MonthlySummary createMany
   */
  export type MonthlySummaryCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many MonthlySummaries.
     */
    data: MonthlySummaryCreateManyInput | MonthlySummaryCreateManyInput[]
  }

  /**
   * MonthlySummary createManyAndReturn
   */
  export type MonthlySummaryCreateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the MonthlySummary
     */
    select?: MonthlySummarySelectCreateManyAndReturn<ExtArgs> | null
    /**
     * Omit specific fields from the MonthlySummary
     */
    omit?: MonthlySummaryOmit<ExtArgs> | null
    /**
     * The data used to create many MonthlySummaries.
     */
    data: MonthlySummaryCreateManyInput | MonthlySummaryCreateManyInput[]
  }

  /**
   * MonthlySummary update
   */
  export type MonthlySummaryUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the MonthlySummary
     */
    select?: MonthlySummarySelect<ExtArgs> | null
    /**
     * Omit specific fields from the MonthlySummary
     */
    omit?: MonthlySummaryOmit<ExtArgs> | null
    /**
     * The data needed to update a MonthlySummary.
     */
    data: XOR<MonthlySummaryUpdateInput, MonthlySummaryUncheckedUpdateInput>
    /**
     * Choose, which MonthlySummary to update.
     */
    where: MonthlySummaryWhereUniqueInput
  }

  /**
   * MonthlySummary updateMany
   */
  export type MonthlySummaryUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update MonthlySummaries.
     */
    data: XOR<MonthlySummaryUpdateManyMutationInput, MonthlySummaryUncheckedUpdateManyInput>
    /**
     * Filter which MonthlySummaries to update
     */
    where?: MonthlySummaryWhereInput
    /**
     * Limit how many MonthlySummaries to update.
     */
    limit?: number
  }

  /**
   * MonthlySummary updateManyAndReturn
   */
  export type MonthlySummaryUpdateManyAndReturnArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the MonthlySummary
     */
    select?: MonthlySummarySelectUpdateManyAndReturn<ExtArgs> | null
    /**
     * Omit specific fields from the MonthlySummary
     */
    omit?: MonthlySummaryOmit<ExtArgs> | null
    /**
     * The data used to update MonthlySummaries.
     */
    data: XOR<MonthlySummaryUpdateManyMutationInput, MonthlySummaryUncheckedUpdateManyInput>
    /**
     * Filter which MonthlySummaries to update
     */
    where?: MonthlySummaryWhereInput
    /**
     * Limit how many MonthlySummaries to update.
     */
    limit?: number
  }

  /**
   * MonthlySummary upsert
   */
  export type MonthlySummaryUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the MonthlySummary
     */
    select?: MonthlySummarySelect<ExtArgs> | null
    /**
     * Omit specific fields from the MonthlySummary
     */
    omit?: MonthlySummaryOmit<ExtArgs> | null
    /**
     * The filter to search for the MonthlySummary to update in case it exists.
     */
    where: MonthlySummaryWhereUniqueInput
    /**
     * In case the MonthlySummary found by the `where` argument doesn't exist, create a new MonthlySummary with this data.
     */
    create: XOR<MonthlySummaryCreateInput, MonthlySummaryUncheckedCreateInput>
    /**
     * In case the MonthlySummary was found with the provided `where` argument, update it with this data.
     */
    update: XOR<MonthlySummaryUpdateInput, MonthlySummaryUncheckedUpdateInput>
  }

  /**
   * MonthlySummary delete
   */
  export type MonthlySummaryDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the MonthlySummary
     */
    select?: MonthlySummarySelect<ExtArgs> | null
    /**
     * Omit specific fields from the MonthlySummary
     */
    omit?: MonthlySummaryOmit<ExtArgs> | null
    /**
     * Filter which MonthlySummary to delete.
     */
    where: MonthlySummaryWhereUniqueInput
  }

  /**
   * MonthlySummary deleteMany
   */
  export type MonthlySummaryDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which MonthlySummaries to delete
     */
    where?: MonthlySummaryWhereInput
    /**
     * Limit how many MonthlySummaries to delete.
     */
    limit?: number
  }

  /**
   * MonthlySummary without action
   */
  export type MonthlySummaryDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the MonthlySummary
     */
    select?: MonthlySummarySelect<ExtArgs> | null
    /**
     * Omit specific fields from the MonthlySummary
     */
    omit?: MonthlySummaryOmit<ExtArgs> | null
  }


  /**
   * Enums
   */

  export const TransactionIsolationLevel: {
    Serializable: 'Serializable'
  };

  export type TransactionIsolationLevel = (typeof TransactionIsolationLevel)[keyof typeof TransactionIsolationLevel]


  export const UserScalarFieldEnum: {
    id: 'id',
    uid: 'uid',
    email: 'email',
    passwordHash: 'passwordHash',
    fullName: 'fullName',
    employeeCode: 'employeeCode',
    mobileNumber: 'mobileNumber',
    sittingLocation: 'sittingLocation',
    reportingManagerId: 'reportingManagerId',
    role: 'role',
    deviceId: 'deviceId',
    profileImage: 'profileImage',
    status: 'status',
    fcmToken: 'fcmToken',
    isRooted: 'isRooted',
    presence: 'presence',
    lastSeenAt: 'lastSeenAt',
    createdAt: 'createdAt',
    updatedAt: 'updatedAt'
  };

  export type UserScalarFieldEnum = (typeof UserScalarFieldEnum)[keyof typeof UserScalarFieldEnum]


  export const RefreshTokenScalarFieldEnum: {
    id: 'id',
    userId: 'userId',
    tokenHash: 'tokenHash',
    deviceId: 'deviceId',
    expiresAt: 'expiresAt',
    createdAt: 'createdAt'
  };

  export type RefreshTokenScalarFieldEnum = (typeof RefreshTokenScalarFieldEnum)[keyof typeof RefreshTokenScalarFieldEnum]


  export const PasswordResetTokenScalarFieldEnum: {
    id: 'id',
    email: 'email',
    tokenHash: 'tokenHash',
    expiresAt: 'expiresAt',
    consumed: 'consumed',
    createdAt: 'createdAt'
  };

  export type PasswordResetTokenScalarFieldEnum = (typeof PasswordResetTokenScalarFieldEnum)[keyof typeof PasswordResetTokenScalarFieldEnum]


  export const AuditLogScalarFieldEnum: {
    id: 'id',
    actorUserId: 'actorUserId',
    actorEmail: 'actorEmail',
    action: 'action',
    targetType: 'targetType',
    targetId: 'targetId',
    metadata: 'metadata',
    ipAddress: 'ipAddress',
    userAgent: 'userAgent',
    createdAt: 'createdAt'
  };

  export type AuditLogScalarFieldEnum = (typeof AuditLogScalarFieldEnum)[keyof typeof AuditLogScalarFieldEnum]


  export const TripScalarFieldEnum: {
    id: 'id',
    tripId: 'tripId',
    userId: 'userId',
    city: 'city',
    fromLocation: 'fromLocation',
    toLocation: 'toLocation',
    destinationLat: 'destinationLat',
    destinationLng: 'destinationLng',
    googlePlaceId: 'googlePlaceId',
    plannedDistance: 'plannedDistance',
    vehicleType: 'vehicleType',
    fuelType: 'fuelType',
    purpose: 'purpose',
    notes: 'notes',
    status: 'status',
    totalDistance: 'totalDistance',
    travelDuration: 'travelDuration',
    idleTime: 'idleTime',
    meetingDuration: 'meetingDuration',
    productivityScore: 'productivityScore',
    tripEfficiency: 'tripEfficiency',
    startedAt: 'startedAt',
    arrivedAt: 'arrivedAt',
    completedAt: 'completedAt',
    createdAt: 'createdAt',
    updatedAt: 'updatedAt'
  };

  export type TripScalarFieldEnum = (typeof TripScalarFieldEnum)[keyof typeof TripScalarFieldEnum]


  export const PunchScalarFieldEnum: {
    id: 'id',
    tripId: 'tripId',
    type: 'type',
    timestamp: 'timestamp',
    latitude: 'latitude',
    longitude: 'longitude',
    address: 'address',
    batteryPercent: 'batteryPercent',
    gpsAccuracy: 'gpsAccuracy',
    speed: 'speed',
    isMockLocation: 'isMockLocation',
    meetingSummary: 'meetingSummary',
    leadType: 'leadType',
    customerNotes: 'customerNotes',
    createdAt: 'createdAt'
  };

  export type PunchScalarFieldEnum = (typeof PunchScalarFieldEnum)[keyof typeof PunchScalarFieldEnum]


  export const GpsPointScalarFieldEnum: {
    id: 'id',
    tripId: 'tripId',
    userId: 'userId',
    clientPointId: 'clientPointId',
    latitude: 'latitude',
    longitude: 'longitude',
    accuracy: 'accuracy',
    speed: 'speed',
    bearing: 'bearing',
    batteryLevel: 'batteryLevel',
    timestamp: 'timestamp',
    isSmoothed: 'isSmoothed',
    createdAt: 'createdAt'
  };

  export type GpsPointScalarFieldEnum = (typeof GpsPointScalarFieldEnum)[keyof typeof GpsPointScalarFieldEnum]


  export const GpsStopScalarFieldEnum: {
    id: 'id',
    tripId: 'tripId',
    latitude: 'latitude',
    longitude: 'longitude',
    startedAt: 'startedAt',
    endedAt: 'endedAt',
    duration: 'duration',
    address: 'address'
  };

  export type GpsStopScalarFieldEnum = (typeof GpsStopScalarFieldEnum)[keyof typeof GpsStopScalarFieldEnum]


  export const NotificationScalarFieldEnum: {
    id: 'id',
    userId: 'userId',
    type: 'type',
    title: 'title',
    body: 'body',
    data: 'data',
    read: 'read',
    sentAt: 'sentAt'
  };

  export type NotificationScalarFieldEnum = (typeof NotificationScalarFieldEnum)[keyof typeof NotificationScalarFieldEnum]


  export const SystemConfigScalarFieldEnum: {
    id: 'id',
    key: 'key',
    value: 'value',
    updatedAt: 'updatedAt'
  };

  export type SystemConfigScalarFieldEnum = (typeof SystemConfigScalarFieldEnum)[keyof typeof SystemConfigScalarFieldEnum]


  export const DailySummaryScalarFieldEnum: {
    id: 'id',
    userId: 'userId',
    date: 'date',
    totalDistance: 'totalDistance',
    travelTime: 'travelTime',
    meetingTime: 'meetingTime',
    idleTime: 'idleTime',
    tripsCompleted: 'tripsCompleted',
    productivityScore: 'productivityScore',
    createdAt: 'createdAt',
    updatedAt: 'updatedAt'
  };

  export type DailySummaryScalarFieldEnum = (typeof DailySummaryScalarFieldEnum)[keyof typeof DailySummaryScalarFieldEnum]


  export const MonthlySummaryScalarFieldEnum: {
    id: 'id',
    userId: 'userId',
    year: 'year',
    month: 'month',
    totalDistance: 'totalDistance',
    travelTime: 'travelTime',
    meetingTime: 'meetingTime',
    idleTime: 'idleTime',
    tripsCompleted: 'tripsCompleted',
    productivityScore: 'productivityScore'
  };

  export type MonthlySummaryScalarFieldEnum = (typeof MonthlySummaryScalarFieldEnum)[keyof typeof MonthlySummaryScalarFieldEnum]


  export const SortOrder: {
    asc: 'asc',
    desc: 'desc'
  };

  export type SortOrder = (typeof SortOrder)[keyof typeof SortOrder]


  export const NullableJsonNullValueInput: {
    DbNull: typeof DbNull,
    JsonNull: typeof JsonNull
  };

  export type NullableJsonNullValueInput = (typeof NullableJsonNullValueInput)[keyof typeof NullableJsonNullValueInput]


  export const JsonNullValueInput: {
    JsonNull: typeof JsonNull
  };

  export type JsonNullValueInput = (typeof JsonNullValueInput)[keyof typeof JsonNullValueInput]


  export const NullsOrder: {
    first: 'first',
    last: 'last'
  };

  export type NullsOrder = (typeof NullsOrder)[keyof typeof NullsOrder]


  export const JsonNullValueFilter: {
    DbNull: typeof DbNull,
    JsonNull: typeof JsonNull,
    AnyNull: typeof AnyNull
  };

  export type JsonNullValueFilter = (typeof JsonNullValueFilter)[keyof typeof JsonNullValueFilter]


  export const QueryMode: {
    default: 'default',
    insensitive: 'insensitive'
  };

  export type QueryMode = (typeof QueryMode)[keyof typeof QueryMode]


  /**
   * Field references
   */


  /**
   * Reference to a field of type 'String'
   */
  export type StringFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'String'>
    


  /**
   * Reference to a field of type 'UserRole'
   */
  export type EnumUserRoleFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'UserRole'>
    


  /**
   * Reference to a field of type 'UserStatus'
   */
  export type EnumUserStatusFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'UserStatus'>
    


  /**
   * Reference to a field of type 'Boolean'
   */
  export type BooleanFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'Boolean'>
    


  /**
   * Reference to a field of type 'EmployeePresence'
   */
  export type EnumEmployeePresenceFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'EmployeePresence'>
    


  /**
   * Reference to a field of type 'DateTime'
   */
  export type DateTimeFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'DateTime'>
    


  /**
   * Reference to a field of type 'Json'
   */
  export type JsonFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'Json'>
    


  /**
   * Reference to a field of type 'QueryMode'
   */
  export type EnumQueryModeFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'QueryMode'>
    


  /**
   * Reference to a field of type 'Float'
   */
  export type FloatFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'Float'>
    


  /**
   * Reference to a field of type 'VehicleType'
   */
  export type EnumVehicleTypeFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'VehicleType'>
    


  /**
   * Reference to a field of type 'FuelType'
   */
  export type EnumFuelTypeFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'FuelType'>
    


  /**
   * Reference to a field of type 'TripStatus'
   */
  export type EnumTripStatusFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'TripStatus'>
    


  /**
   * Reference to a field of type 'Int'
   */
  export type IntFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'Int'>
    


  /**
   * Reference to a field of type 'PunchType'
   */
  export type EnumPunchTypeFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'PunchType'>
    


  /**
   * Reference to a field of type 'LeadType'
   */
  export type EnumLeadTypeFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'LeadType'>
    


  /**
   * Reference to a field of type 'NotificationType'
   */
  export type EnumNotificationTypeFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'NotificationType'>
    
  /**
   * Deep Input Types
   */


  export type UserWhereInput = {
    AND?: UserWhereInput | UserWhereInput[]
    OR?: UserWhereInput[]
    NOT?: UserWhereInput | UserWhereInput[]
    id?: StringFilter<"User"> | string
    uid?: StringFilter<"User"> | string
    email?: StringFilter<"User"> | string
    passwordHash?: StringFilter<"User"> | string
    fullName?: StringFilter<"User"> | string
    employeeCode?: StringFilter<"User"> | string
    mobileNumber?: StringNullableFilter<"User"> | string | null
    sittingLocation?: StringNullableFilter<"User"> | string | null
    reportingManagerId?: StringNullableFilter<"User"> | string | null
    role?: EnumUserRoleFilter<"User"> | $Enums.UserRole
    deviceId?: StringNullableFilter<"User"> | string | null
    profileImage?: StringNullableFilter<"User"> | string | null
    status?: EnumUserStatusFilter<"User"> | $Enums.UserStatus
    fcmToken?: StringNullableFilter<"User"> | string | null
    isRooted?: BoolFilter<"User"> | boolean
    presence?: EnumEmployeePresenceFilter<"User"> | $Enums.EmployeePresence
    lastSeenAt?: DateTimeNullableFilter<"User"> | Date | string | null
    createdAt?: DateTimeFilter<"User"> | Date | string
    updatedAt?: DateTimeFilter<"User"> | Date | string
    reportingManager?: XOR<UserNullableScalarRelationFilter, UserWhereInput> | null
    directReports?: UserListRelationFilter
    refreshTokens?: RefreshTokenListRelationFilter
    trips?: TripListRelationFilter
    gpsPoints?: GpsPointListRelationFilter
    auditLogs?: AuditLogListRelationFilter
    notifications?: NotificationListRelationFilter
  }

  export type UserOrderByWithRelationInput = {
    id?: SortOrder
    uid?: SortOrder
    email?: SortOrder
    passwordHash?: SortOrder
    fullName?: SortOrder
    employeeCode?: SortOrder
    mobileNumber?: SortOrderInput | SortOrder
    sittingLocation?: SortOrderInput | SortOrder
    reportingManagerId?: SortOrderInput | SortOrder
    role?: SortOrder
    deviceId?: SortOrderInput | SortOrder
    profileImage?: SortOrderInput | SortOrder
    status?: SortOrder
    fcmToken?: SortOrderInput | SortOrder
    isRooted?: SortOrder
    presence?: SortOrder
    lastSeenAt?: SortOrderInput | SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
    reportingManager?: UserOrderByWithRelationInput
    directReports?: UserOrderByRelationAggregateInput
    refreshTokens?: RefreshTokenOrderByRelationAggregateInput
    trips?: TripOrderByRelationAggregateInput
    gpsPoints?: GpsPointOrderByRelationAggregateInput
    auditLogs?: AuditLogOrderByRelationAggregateInput
    notifications?: NotificationOrderByRelationAggregateInput
  }

  export type UserWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    uid?: string
    email?: string
    employeeCode?: string
    AND?: UserWhereInput | UserWhereInput[]
    OR?: UserWhereInput[]
    NOT?: UserWhereInput | UserWhereInput[]
    passwordHash?: StringFilter<"User"> | string
    fullName?: StringFilter<"User"> | string
    mobileNumber?: StringNullableFilter<"User"> | string | null
    sittingLocation?: StringNullableFilter<"User"> | string | null
    reportingManagerId?: StringNullableFilter<"User"> | string | null
    role?: EnumUserRoleFilter<"User"> | $Enums.UserRole
    deviceId?: StringNullableFilter<"User"> | string | null
    profileImage?: StringNullableFilter<"User"> | string | null
    status?: EnumUserStatusFilter<"User"> | $Enums.UserStatus
    fcmToken?: StringNullableFilter<"User"> | string | null
    isRooted?: BoolFilter<"User"> | boolean
    presence?: EnumEmployeePresenceFilter<"User"> | $Enums.EmployeePresence
    lastSeenAt?: DateTimeNullableFilter<"User"> | Date | string | null
    createdAt?: DateTimeFilter<"User"> | Date | string
    updatedAt?: DateTimeFilter<"User"> | Date | string
    reportingManager?: XOR<UserNullableScalarRelationFilter, UserWhereInput> | null
    directReports?: UserListRelationFilter
    refreshTokens?: RefreshTokenListRelationFilter
    trips?: TripListRelationFilter
    gpsPoints?: GpsPointListRelationFilter
    auditLogs?: AuditLogListRelationFilter
    notifications?: NotificationListRelationFilter
  }, "id" | "uid" | "email" | "employeeCode">

  export type UserOrderByWithAggregationInput = {
    id?: SortOrder
    uid?: SortOrder
    email?: SortOrder
    passwordHash?: SortOrder
    fullName?: SortOrder
    employeeCode?: SortOrder
    mobileNumber?: SortOrderInput | SortOrder
    sittingLocation?: SortOrderInput | SortOrder
    reportingManagerId?: SortOrderInput | SortOrder
    role?: SortOrder
    deviceId?: SortOrderInput | SortOrder
    profileImage?: SortOrderInput | SortOrder
    status?: SortOrder
    fcmToken?: SortOrderInput | SortOrder
    isRooted?: SortOrder
    presence?: SortOrder
    lastSeenAt?: SortOrderInput | SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
    _count?: UserCountOrderByAggregateInput
    _max?: UserMaxOrderByAggregateInput
    _min?: UserMinOrderByAggregateInput
  }

  export type UserScalarWhereWithAggregatesInput = {
    AND?: UserScalarWhereWithAggregatesInput | UserScalarWhereWithAggregatesInput[]
    OR?: UserScalarWhereWithAggregatesInput[]
    NOT?: UserScalarWhereWithAggregatesInput | UserScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"User"> | string
    uid?: StringWithAggregatesFilter<"User"> | string
    email?: StringWithAggregatesFilter<"User"> | string
    passwordHash?: StringWithAggregatesFilter<"User"> | string
    fullName?: StringWithAggregatesFilter<"User"> | string
    employeeCode?: StringWithAggregatesFilter<"User"> | string
    mobileNumber?: StringNullableWithAggregatesFilter<"User"> | string | null
    sittingLocation?: StringNullableWithAggregatesFilter<"User"> | string | null
    reportingManagerId?: StringNullableWithAggregatesFilter<"User"> | string | null
    role?: EnumUserRoleWithAggregatesFilter<"User"> | $Enums.UserRole
    deviceId?: StringNullableWithAggregatesFilter<"User"> | string | null
    profileImage?: StringNullableWithAggregatesFilter<"User"> | string | null
    status?: EnumUserStatusWithAggregatesFilter<"User"> | $Enums.UserStatus
    fcmToken?: StringNullableWithAggregatesFilter<"User"> | string | null
    isRooted?: BoolWithAggregatesFilter<"User"> | boolean
    presence?: EnumEmployeePresenceWithAggregatesFilter<"User"> | $Enums.EmployeePresence
    lastSeenAt?: DateTimeNullableWithAggregatesFilter<"User"> | Date | string | null
    createdAt?: DateTimeWithAggregatesFilter<"User"> | Date | string
    updatedAt?: DateTimeWithAggregatesFilter<"User"> | Date | string
  }

  export type RefreshTokenWhereInput = {
    AND?: RefreshTokenWhereInput | RefreshTokenWhereInput[]
    OR?: RefreshTokenWhereInput[]
    NOT?: RefreshTokenWhereInput | RefreshTokenWhereInput[]
    id?: StringFilter<"RefreshToken"> | string
    userId?: StringFilter<"RefreshToken"> | string
    tokenHash?: StringFilter<"RefreshToken"> | string
    deviceId?: StringNullableFilter<"RefreshToken"> | string | null
    expiresAt?: DateTimeFilter<"RefreshToken"> | Date | string
    createdAt?: DateTimeFilter<"RefreshToken"> | Date | string
    user?: XOR<UserScalarRelationFilter, UserWhereInput>
  }

  export type RefreshTokenOrderByWithRelationInput = {
    id?: SortOrder
    userId?: SortOrder
    tokenHash?: SortOrder
    deviceId?: SortOrderInput | SortOrder
    expiresAt?: SortOrder
    createdAt?: SortOrder
    user?: UserOrderByWithRelationInput
  }

  export type RefreshTokenWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    AND?: RefreshTokenWhereInput | RefreshTokenWhereInput[]
    OR?: RefreshTokenWhereInput[]
    NOT?: RefreshTokenWhereInput | RefreshTokenWhereInput[]
    userId?: StringFilter<"RefreshToken"> | string
    tokenHash?: StringFilter<"RefreshToken"> | string
    deviceId?: StringNullableFilter<"RefreshToken"> | string | null
    expiresAt?: DateTimeFilter<"RefreshToken"> | Date | string
    createdAt?: DateTimeFilter<"RefreshToken"> | Date | string
    user?: XOR<UserScalarRelationFilter, UserWhereInput>
  }, "id">

  export type RefreshTokenOrderByWithAggregationInput = {
    id?: SortOrder
    userId?: SortOrder
    tokenHash?: SortOrder
    deviceId?: SortOrderInput | SortOrder
    expiresAt?: SortOrder
    createdAt?: SortOrder
    _count?: RefreshTokenCountOrderByAggregateInput
    _max?: RefreshTokenMaxOrderByAggregateInput
    _min?: RefreshTokenMinOrderByAggregateInput
  }

  export type RefreshTokenScalarWhereWithAggregatesInput = {
    AND?: RefreshTokenScalarWhereWithAggregatesInput | RefreshTokenScalarWhereWithAggregatesInput[]
    OR?: RefreshTokenScalarWhereWithAggregatesInput[]
    NOT?: RefreshTokenScalarWhereWithAggregatesInput | RefreshTokenScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"RefreshToken"> | string
    userId?: StringWithAggregatesFilter<"RefreshToken"> | string
    tokenHash?: StringWithAggregatesFilter<"RefreshToken"> | string
    deviceId?: StringNullableWithAggregatesFilter<"RefreshToken"> | string | null
    expiresAt?: DateTimeWithAggregatesFilter<"RefreshToken"> | Date | string
    createdAt?: DateTimeWithAggregatesFilter<"RefreshToken"> | Date | string
  }

  export type PasswordResetTokenWhereInput = {
    AND?: PasswordResetTokenWhereInput | PasswordResetTokenWhereInput[]
    OR?: PasswordResetTokenWhereInput[]
    NOT?: PasswordResetTokenWhereInput | PasswordResetTokenWhereInput[]
    id?: StringFilter<"PasswordResetToken"> | string
    email?: StringFilter<"PasswordResetToken"> | string
    tokenHash?: StringFilter<"PasswordResetToken"> | string
    expiresAt?: DateTimeFilter<"PasswordResetToken"> | Date | string
    consumed?: BoolFilter<"PasswordResetToken"> | boolean
    createdAt?: DateTimeFilter<"PasswordResetToken"> | Date | string
  }

  export type PasswordResetTokenOrderByWithRelationInput = {
    id?: SortOrder
    email?: SortOrder
    tokenHash?: SortOrder
    expiresAt?: SortOrder
    consumed?: SortOrder
    createdAt?: SortOrder
  }

  export type PasswordResetTokenWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    AND?: PasswordResetTokenWhereInput | PasswordResetTokenWhereInput[]
    OR?: PasswordResetTokenWhereInput[]
    NOT?: PasswordResetTokenWhereInput | PasswordResetTokenWhereInput[]
    email?: StringFilter<"PasswordResetToken"> | string
    tokenHash?: StringFilter<"PasswordResetToken"> | string
    expiresAt?: DateTimeFilter<"PasswordResetToken"> | Date | string
    consumed?: BoolFilter<"PasswordResetToken"> | boolean
    createdAt?: DateTimeFilter<"PasswordResetToken"> | Date | string
  }, "id">

  export type PasswordResetTokenOrderByWithAggregationInput = {
    id?: SortOrder
    email?: SortOrder
    tokenHash?: SortOrder
    expiresAt?: SortOrder
    consumed?: SortOrder
    createdAt?: SortOrder
    _count?: PasswordResetTokenCountOrderByAggregateInput
    _max?: PasswordResetTokenMaxOrderByAggregateInput
    _min?: PasswordResetTokenMinOrderByAggregateInput
  }

  export type PasswordResetTokenScalarWhereWithAggregatesInput = {
    AND?: PasswordResetTokenScalarWhereWithAggregatesInput | PasswordResetTokenScalarWhereWithAggregatesInput[]
    OR?: PasswordResetTokenScalarWhereWithAggregatesInput[]
    NOT?: PasswordResetTokenScalarWhereWithAggregatesInput | PasswordResetTokenScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"PasswordResetToken"> | string
    email?: StringWithAggregatesFilter<"PasswordResetToken"> | string
    tokenHash?: StringWithAggregatesFilter<"PasswordResetToken"> | string
    expiresAt?: DateTimeWithAggregatesFilter<"PasswordResetToken"> | Date | string
    consumed?: BoolWithAggregatesFilter<"PasswordResetToken"> | boolean
    createdAt?: DateTimeWithAggregatesFilter<"PasswordResetToken"> | Date | string
  }

  export type AuditLogWhereInput = {
    AND?: AuditLogWhereInput | AuditLogWhereInput[]
    OR?: AuditLogWhereInput[]
    NOT?: AuditLogWhereInput | AuditLogWhereInput[]
    id?: StringFilter<"AuditLog"> | string
    actorUserId?: StringNullableFilter<"AuditLog"> | string | null
    actorEmail?: StringNullableFilter<"AuditLog"> | string | null
    action?: StringFilter<"AuditLog"> | string
    targetType?: StringNullableFilter<"AuditLog"> | string | null
    targetId?: StringNullableFilter<"AuditLog"> | string | null
    metadata?: JsonNullableFilter<"AuditLog">
    ipAddress?: StringNullableFilter<"AuditLog"> | string | null
    userAgent?: StringNullableFilter<"AuditLog"> | string | null
    createdAt?: DateTimeFilter<"AuditLog"> | Date | string
    actor?: XOR<UserNullableScalarRelationFilter, UserWhereInput> | null
  }

  export type AuditLogOrderByWithRelationInput = {
    id?: SortOrder
    actorUserId?: SortOrderInput | SortOrder
    actorEmail?: SortOrderInput | SortOrder
    action?: SortOrder
    targetType?: SortOrderInput | SortOrder
    targetId?: SortOrderInput | SortOrder
    metadata?: SortOrderInput | SortOrder
    ipAddress?: SortOrderInput | SortOrder
    userAgent?: SortOrderInput | SortOrder
    createdAt?: SortOrder
    actor?: UserOrderByWithRelationInput
  }

  export type AuditLogWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    AND?: AuditLogWhereInput | AuditLogWhereInput[]
    OR?: AuditLogWhereInput[]
    NOT?: AuditLogWhereInput | AuditLogWhereInput[]
    actorUserId?: StringNullableFilter<"AuditLog"> | string | null
    actorEmail?: StringNullableFilter<"AuditLog"> | string | null
    action?: StringFilter<"AuditLog"> | string
    targetType?: StringNullableFilter<"AuditLog"> | string | null
    targetId?: StringNullableFilter<"AuditLog"> | string | null
    metadata?: JsonNullableFilter<"AuditLog">
    ipAddress?: StringNullableFilter<"AuditLog"> | string | null
    userAgent?: StringNullableFilter<"AuditLog"> | string | null
    createdAt?: DateTimeFilter<"AuditLog"> | Date | string
    actor?: XOR<UserNullableScalarRelationFilter, UserWhereInput> | null
  }, "id">

  export type AuditLogOrderByWithAggregationInput = {
    id?: SortOrder
    actorUserId?: SortOrderInput | SortOrder
    actorEmail?: SortOrderInput | SortOrder
    action?: SortOrder
    targetType?: SortOrderInput | SortOrder
    targetId?: SortOrderInput | SortOrder
    metadata?: SortOrderInput | SortOrder
    ipAddress?: SortOrderInput | SortOrder
    userAgent?: SortOrderInput | SortOrder
    createdAt?: SortOrder
    _count?: AuditLogCountOrderByAggregateInput
    _max?: AuditLogMaxOrderByAggregateInput
    _min?: AuditLogMinOrderByAggregateInput
  }

  export type AuditLogScalarWhereWithAggregatesInput = {
    AND?: AuditLogScalarWhereWithAggregatesInput | AuditLogScalarWhereWithAggregatesInput[]
    OR?: AuditLogScalarWhereWithAggregatesInput[]
    NOT?: AuditLogScalarWhereWithAggregatesInput | AuditLogScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"AuditLog"> | string
    actorUserId?: StringNullableWithAggregatesFilter<"AuditLog"> | string | null
    actorEmail?: StringNullableWithAggregatesFilter<"AuditLog"> | string | null
    action?: StringWithAggregatesFilter<"AuditLog"> | string
    targetType?: StringNullableWithAggregatesFilter<"AuditLog"> | string | null
    targetId?: StringNullableWithAggregatesFilter<"AuditLog"> | string | null
    metadata?: JsonNullableWithAggregatesFilter<"AuditLog">
    ipAddress?: StringNullableWithAggregatesFilter<"AuditLog"> | string | null
    userAgent?: StringNullableWithAggregatesFilter<"AuditLog"> | string | null
    createdAt?: DateTimeWithAggregatesFilter<"AuditLog"> | Date | string
  }

  export type TripWhereInput = {
    AND?: TripWhereInput | TripWhereInput[]
    OR?: TripWhereInput[]
    NOT?: TripWhereInput | TripWhereInput[]
    id?: StringFilter<"Trip"> | string
    tripId?: StringFilter<"Trip"> | string
    userId?: StringFilter<"Trip"> | string
    city?: StringNullableFilter<"Trip"> | string | null
    fromLocation?: StringNullableFilter<"Trip"> | string | null
    toLocation?: StringNullableFilter<"Trip"> | string | null
    destinationLat?: FloatNullableFilter<"Trip"> | number | null
    destinationLng?: FloatNullableFilter<"Trip"> | number | null
    googlePlaceId?: StringNullableFilter<"Trip"> | string | null
    plannedDistance?: FloatNullableFilter<"Trip"> | number | null
    vehicleType?: EnumVehicleTypeNullableFilter<"Trip"> | $Enums.VehicleType | null
    fuelType?: EnumFuelTypeNullableFilter<"Trip"> | $Enums.FuelType | null
    purpose?: StringNullableFilter<"Trip"> | string | null
    notes?: StringNullableFilter<"Trip"> | string | null
    status?: EnumTripStatusFilter<"Trip"> | $Enums.TripStatus
    totalDistance?: FloatFilter<"Trip"> | number
    travelDuration?: IntFilter<"Trip"> | number
    idleTime?: IntFilter<"Trip"> | number
    meetingDuration?: IntFilter<"Trip"> | number
    productivityScore?: FloatNullableFilter<"Trip"> | number | null
    tripEfficiency?: FloatNullableFilter<"Trip"> | number | null
    startedAt?: DateTimeNullableFilter<"Trip"> | Date | string | null
    arrivedAt?: DateTimeNullableFilter<"Trip"> | Date | string | null
    completedAt?: DateTimeNullableFilter<"Trip"> | Date | string | null
    createdAt?: DateTimeFilter<"Trip"> | Date | string
    updatedAt?: DateTimeFilter<"Trip"> | Date | string
    user?: XOR<UserScalarRelationFilter, UserWhereInput>
    punches?: PunchListRelationFilter
    gpsPoints?: GpsPointListRelationFilter
    stops?: GpsStopListRelationFilter
  }

  export type TripOrderByWithRelationInput = {
    id?: SortOrder
    tripId?: SortOrder
    userId?: SortOrder
    city?: SortOrderInput | SortOrder
    fromLocation?: SortOrderInput | SortOrder
    toLocation?: SortOrderInput | SortOrder
    destinationLat?: SortOrderInput | SortOrder
    destinationLng?: SortOrderInput | SortOrder
    googlePlaceId?: SortOrderInput | SortOrder
    plannedDistance?: SortOrderInput | SortOrder
    vehicleType?: SortOrderInput | SortOrder
    fuelType?: SortOrderInput | SortOrder
    purpose?: SortOrderInput | SortOrder
    notes?: SortOrderInput | SortOrder
    status?: SortOrder
    totalDistance?: SortOrder
    travelDuration?: SortOrder
    idleTime?: SortOrder
    meetingDuration?: SortOrder
    productivityScore?: SortOrderInput | SortOrder
    tripEfficiency?: SortOrderInput | SortOrder
    startedAt?: SortOrderInput | SortOrder
    arrivedAt?: SortOrderInput | SortOrder
    completedAt?: SortOrderInput | SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
    user?: UserOrderByWithRelationInput
    punches?: PunchOrderByRelationAggregateInput
    gpsPoints?: GpsPointOrderByRelationAggregateInput
    stops?: GpsStopOrderByRelationAggregateInput
  }

  export type TripWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    tripId?: string
    AND?: TripWhereInput | TripWhereInput[]
    OR?: TripWhereInput[]
    NOT?: TripWhereInput | TripWhereInput[]
    userId?: StringFilter<"Trip"> | string
    city?: StringNullableFilter<"Trip"> | string | null
    fromLocation?: StringNullableFilter<"Trip"> | string | null
    toLocation?: StringNullableFilter<"Trip"> | string | null
    destinationLat?: FloatNullableFilter<"Trip"> | number | null
    destinationLng?: FloatNullableFilter<"Trip"> | number | null
    googlePlaceId?: StringNullableFilter<"Trip"> | string | null
    plannedDistance?: FloatNullableFilter<"Trip"> | number | null
    vehicleType?: EnumVehicleTypeNullableFilter<"Trip"> | $Enums.VehicleType | null
    fuelType?: EnumFuelTypeNullableFilter<"Trip"> | $Enums.FuelType | null
    purpose?: StringNullableFilter<"Trip"> | string | null
    notes?: StringNullableFilter<"Trip"> | string | null
    status?: EnumTripStatusFilter<"Trip"> | $Enums.TripStatus
    totalDistance?: FloatFilter<"Trip"> | number
    travelDuration?: IntFilter<"Trip"> | number
    idleTime?: IntFilter<"Trip"> | number
    meetingDuration?: IntFilter<"Trip"> | number
    productivityScore?: FloatNullableFilter<"Trip"> | number | null
    tripEfficiency?: FloatNullableFilter<"Trip"> | number | null
    startedAt?: DateTimeNullableFilter<"Trip"> | Date | string | null
    arrivedAt?: DateTimeNullableFilter<"Trip"> | Date | string | null
    completedAt?: DateTimeNullableFilter<"Trip"> | Date | string | null
    createdAt?: DateTimeFilter<"Trip"> | Date | string
    updatedAt?: DateTimeFilter<"Trip"> | Date | string
    user?: XOR<UserScalarRelationFilter, UserWhereInput>
    punches?: PunchListRelationFilter
    gpsPoints?: GpsPointListRelationFilter
    stops?: GpsStopListRelationFilter
  }, "id" | "tripId">

  export type TripOrderByWithAggregationInput = {
    id?: SortOrder
    tripId?: SortOrder
    userId?: SortOrder
    city?: SortOrderInput | SortOrder
    fromLocation?: SortOrderInput | SortOrder
    toLocation?: SortOrderInput | SortOrder
    destinationLat?: SortOrderInput | SortOrder
    destinationLng?: SortOrderInput | SortOrder
    googlePlaceId?: SortOrderInput | SortOrder
    plannedDistance?: SortOrderInput | SortOrder
    vehicleType?: SortOrderInput | SortOrder
    fuelType?: SortOrderInput | SortOrder
    purpose?: SortOrderInput | SortOrder
    notes?: SortOrderInput | SortOrder
    status?: SortOrder
    totalDistance?: SortOrder
    travelDuration?: SortOrder
    idleTime?: SortOrder
    meetingDuration?: SortOrder
    productivityScore?: SortOrderInput | SortOrder
    tripEfficiency?: SortOrderInput | SortOrder
    startedAt?: SortOrderInput | SortOrder
    arrivedAt?: SortOrderInput | SortOrder
    completedAt?: SortOrderInput | SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
    _count?: TripCountOrderByAggregateInput
    _avg?: TripAvgOrderByAggregateInput
    _max?: TripMaxOrderByAggregateInput
    _min?: TripMinOrderByAggregateInput
    _sum?: TripSumOrderByAggregateInput
  }

  export type TripScalarWhereWithAggregatesInput = {
    AND?: TripScalarWhereWithAggregatesInput | TripScalarWhereWithAggregatesInput[]
    OR?: TripScalarWhereWithAggregatesInput[]
    NOT?: TripScalarWhereWithAggregatesInput | TripScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"Trip"> | string
    tripId?: StringWithAggregatesFilter<"Trip"> | string
    userId?: StringWithAggregatesFilter<"Trip"> | string
    city?: StringNullableWithAggregatesFilter<"Trip"> | string | null
    fromLocation?: StringNullableWithAggregatesFilter<"Trip"> | string | null
    toLocation?: StringNullableWithAggregatesFilter<"Trip"> | string | null
    destinationLat?: FloatNullableWithAggregatesFilter<"Trip"> | number | null
    destinationLng?: FloatNullableWithAggregatesFilter<"Trip"> | number | null
    googlePlaceId?: StringNullableWithAggregatesFilter<"Trip"> | string | null
    plannedDistance?: FloatNullableWithAggregatesFilter<"Trip"> | number | null
    vehicleType?: EnumVehicleTypeNullableWithAggregatesFilter<"Trip"> | $Enums.VehicleType | null
    fuelType?: EnumFuelTypeNullableWithAggregatesFilter<"Trip"> | $Enums.FuelType | null
    purpose?: StringNullableWithAggregatesFilter<"Trip"> | string | null
    notes?: StringNullableWithAggregatesFilter<"Trip"> | string | null
    status?: EnumTripStatusWithAggregatesFilter<"Trip"> | $Enums.TripStatus
    totalDistance?: FloatWithAggregatesFilter<"Trip"> | number
    travelDuration?: IntWithAggregatesFilter<"Trip"> | number
    idleTime?: IntWithAggregatesFilter<"Trip"> | number
    meetingDuration?: IntWithAggregatesFilter<"Trip"> | number
    productivityScore?: FloatNullableWithAggregatesFilter<"Trip"> | number | null
    tripEfficiency?: FloatNullableWithAggregatesFilter<"Trip"> | number | null
    startedAt?: DateTimeNullableWithAggregatesFilter<"Trip"> | Date | string | null
    arrivedAt?: DateTimeNullableWithAggregatesFilter<"Trip"> | Date | string | null
    completedAt?: DateTimeNullableWithAggregatesFilter<"Trip"> | Date | string | null
    createdAt?: DateTimeWithAggregatesFilter<"Trip"> | Date | string
    updatedAt?: DateTimeWithAggregatesFilter<"Trip"> | Date | string
  }

  export type PunchWhereInput = {
    AND?: PunchWhereInput | PunchWhereInput[]
    OR?: PunchWhereInput[]
    NOT?: PunchWhereInput | PunchWhereInput[]
    id?: StringFilter<"Punch"> | string
    tripId?: StringFilter<"Punch"> | string
    type?: EnumPunchTypeFilter<"Punch"> | $Enums.PunchType
    timestamp?: DateTimeFilter<"Punch"> | Date | string
    latitude?: FloatFilter<"Punch"> | number
    longitude?: FloatFilter<"Punch"> | number
    address?: StringNullableFilter<"Punch"> | string | null
    batteryPercent?: FloatNullableFilter<"Punch"> | number | null
    gpsAccuracy?: FloatNullableFilter<"Punch"> | number | null
    speed?: FloatNullableFilter<"Punch"> | number | null
    isMockLocation?: BoolFilter<"Punch"> | boolean
    meetingSummary?: StringNullableFilter<"Punch"> | string | null
    leadType?: EnumLeadTypeNullableFilter<"Punch"> | $Enums.LeadType | null
    customerNotes?: StringNullableFilter<"Punch"> | string | null
    createdAt?: DateTimeFilter<"Punch"> | Date | string
    trip?: XOR<TripScalarRelationFilter, TripWhereInput>
  }

  export type PunchOrderByWithRelationInput = {
    id?: SortOrder
    tripId?: SortOrder
    type?: SortOrder
    timestamp?: SortOrder
    latitude?: SortOrder
    longitude?: SortOrder
    address?: SortOrderInput | SortOrder
    batteryPercent?: SortOrderInput | SortOrder
    gpsAccuracy?: SortOrderInput | SortOrder
    speed?: SortOrderInput | SortOrder
    isMockLocation?: SortOrder
    meetingSummary?: SortOrderInput | SortOrder
    leadType?: SortOrderInput | SortOrder
    customerNotes?: SortOrderInput | SortOrder
    createdAt?: SortOrder
    trip?: TripOrderByWithRelationInput
  }

  export type PunchWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    AND?: PunchWhereInput | PunchWhereInput[]
    OR?: PunchWhereInput[]
    NOT?: PunchWhereInput | PunchWhereInput[]
    tripId?: StringFilter<"Punch"> | string
    type?: EnumPunchTypeFilter<"Punch"> | $Enums.PunchType
    timestamp?: DateTimeFilter<"Punch"> | Date | string
    latitude?: FloatFilter<"Punch"> | number
    longitude?: FloatFilter<"Punch"> | number
    address?: StringNullableFilter<"Punch"> | string | null
    batteryPercent?: FloatNullableFilter<"Punch"> | number | null
    gpsAccuracy?: FloatNullableFilter<"Punch"> | number | null
    speed?: FloatNullableFilter<"Punch"> | number | null
    isMockLocation?: BoolFilter<"Punch"> | boolean
    meetingSummary?: StringNullableFilter<"Punch"> | string | null
    leadType?: EnumLeadTypeNullableFilter<"Punch"> | $Enums.LeadType | null
    customerNotes?: StringNullableFilter<"Punch"> | string | null
    createdAt?: DateTimeFilter<"Punch"> | Date | string
    trip?: XOR<TripScalarRelationFilter, TripWhereInput>
  }, "id">

  export type PunchOrderByWithAggregationInput = {
    id?: SortOrder
    tripId?: SortOrder
    type?: SortOrder
    timestamp?: SortOrder
    latitude?: SortOrder
    longitude?: SortOrder
    address?: SortOrderInput | SortOrder
    batteryPercent?: SortOrderInput | SortOrder
    gpsAccuracy?: SortOrderInput | SortOrder
    speed?: SortOrderInput | SortOrder
    isMockLocation?: SortOrder
    meetingSummary?: SortOrderInput | SortOrder
    leadType?: SortOrderInput | SortOrder
    customerNotes?: SortOrderInput | SortOrder
    createdAt?: SortOrder
    _count?: PunchCountOrderByAggregateInput
    _avg?: PunchAvgOrderByAggregateInput
    _max?: PunchMaxOrderByAggregateInput
    _min?: PunchMinOrderByAggregateInput
    _sum?: PunchSumOrderByAggregateInput
  }

  export type PunchScalarWhereWithAggregatesInput = {
    AND?: PunchScalarWhereWithAggregatesInput | PunchScalarWhereWithAggregatesInput[]
    OR?: PunchScalarWhereWithAggregatesInput[]
    NOT?: PunchScalarWhereWithAggregatesInput | PunchScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"Punch"> | string
    tripId?: StringWithAggregatesFilter<"Punch"> | string
    type?: EnumPunchTypeWithAggregatesFilter<"Punch"> | $Enums.PunchType
    timestamp?: DateTimeWithAggregatesFilter<"Punch"> | Date | string
    latitude?: FloatWithAggregatesFilter<"Punch"> | number
    longitude?: FloatWithAggregatesFilter<"Punch"> | number
    address?: StringNullableWithAggregatesFilter<"Punch"> | string | null
    batteryPercent?: FloatNullableWithAggregatesFilter<"Punch"> | number | null
    gpsAccuracy?: FloatNullableWithAggregatesFilter<"Punch"> | number | null
    speed?: FloatNullableWithAggregatesFilter<"Punch"> | number | null
    isMockLocation?: BoolWithAggregatesFilter<"Punch"> | boolean
    meetingSummary?: StringNullableWithAggregatesFilter<"Punch"> | string | null
    leadType?: EnumLeadTypeNullableWithAggregatesFilter<"Punch"> | $Enums.LeadType | null
    customerNotes?: StringNullableWithAggregatesFilter<"Punch"> | string | null
    createdAt?: DateTimeWithAggregatesFilter<"Punch"> | Date | string
  }

  export type GpsPointWhereInput = {
    AND?: GpsPointWhereInput | GpsPointWhereInput[]
    OR?: GpsPointWhereInput[]
    NOT?: GpsPointWhereInput | GpsPointWhereInput[]
    id?: StringFilter<"GpsPoint"> | string
    tripId?: StringNullableFilter<"GpsPoint"> | string | null
    userId?: StringFilter<"GpsPoint"> | string
    clientPointId?: StringNullableFilter<"GpsPoint"> | string | null
    latitude?: FloatFilter<"GpsPoint"> | number
    longitude?: FloatFilter<"GpsPoint"> | number
    accuracy?: FloatNullableFilter<"GpsPoint"> | number | null
    speed?: FloatNullableFilter<"GpsPoint"> | number | null
    bearing?: FloatNullableFilter<"GpsPoint"> | number | null
    batteryLevel?: FloatNullableFilter<"GpsPoint"> | number | null
    timestamp?: DateTimeFilter<"GpsPoint"> | Date | string
    isSmoothed?: BoolFilter<"GpsPoint"> | boolean
    createdAt?: DateTimeFilter<"GpsPoint"> | Date | string
    trip?: XOR<TripNullableScalarRelationFilter, TripWhereInput> | null
    user?: XOR<UserScalarRelationFilter, UserWhereInput>
  }

  export type GpsPointOrderByWithRelationInput = {
    id?: SortOrder
    tripId?: SortOrderInput | SortOrder
    userId?: SortOrder
    clientPointId?: SortOrderInput | SortOrder
    latitude?: SortOrder
    longitude?: SortOrder
    accuracy?: SortOrderInput | SortOrder
    speed?: SortOrderInput | SortOrder
    bearing?: SortOrderInput | SortOrder
    batteryLevel?: SortOrderInput | SortOrder
    timestamp?: SortOrder
    isSmoothed?: SortOrder
    createdAt?: SortOrder
    trip?: TripOrderByWithRelationInput
    user?: UserOrderByWithRelationInput
  }

  export type GpsPointWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    tripId_clientPointId?: GpsPointTripIdClientPointIdCompoundUniqueInput
    AND?: GpsPointWhereInput | GpsPointWhereInput[]
    OR?: GpsPointWhereInput[]
    NOT?: GpsPointWhereInput | GpsPointWhereInput[]
    tripId?: StringNullableFilter<"GpsPoint"> | string | null
    userId?: StringFilter<"GpsPoint"> | string
    clientPointId?: StringNullableFilter<"GpsPoint"> | string | null
    latitude?: FloatFilter<"GpsPoint"> | number
    longitude?: FloatFilter<"GpsPoint"> | number
    accuracy?: FloatNullableFilter<"GpsPoint"> | number | null
    speed?: FloatNullableFilter<"GpsPoint"> | number | null
    bearing?: FloatNullableFilter<"GpsPoint"> | number | null
    batteryLevel?: FloatNullableFilter<"GpsPoint"> | number | null
    timestamp?: DateTimeFilter<"GpsPoint"> | Date | string
    isSmoothed?: BoolFilter<"GpsPoint"> | boolean
    createdAt?: DateTimeFilter<"GpsPoint"> | Date | string
    trip?: XOR<TripNullableScalarRelationFilter, TripWhereInput> | null
    user?: XOR<UserScalarRelationFilter, UserWhereInput>
  }, "id" | "tripId_clientPointId">

  export type GpsPointOrderByWithAggregationInput = {
    id?: SortOrder
    tripId?: SortOrderInput | SortOrder
    userId?: SortOrder
    clientPointId?: SortOrderInput | SortOrder
    latitude?: SortOrder
    longitude?: SortOrder
    accuracy?: SortOrderInput | SortOrder
    speed?: SortOrderInput | SortOrder
    bearing?: SortOrderInput | SortOrder
    batteryLevel?: SortOrderInput | SortOrder
    timestamp?: SortOrder
    isSmoothed?: SortOrder
    createdAt?: SortOrder
    _count?: GpsPointCountOrderByAggregateInput
    _avg?: GpsPointAvgOrderByAggregateInput
    _max?: GpsPointMaxOrderByAggregateInput
    _min?: GpsPointMinOrderByAggregateInput
    _sum?: GpsPointSumOrderByAggregateInput
  }

  export type GpsPointScalarWhereWithAggregatesInput = {
    AND?: GpsPointScalarWhereWithAggregatesInput | GpsPointScalarWhereWithAggregatesInput[]
    OR?: GpsPointScalarWhereWithAggregatesInput[]
    NOT?: GpsPointScalarWhereWithAggregatesInput | GpsPointScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"GpsPoint"> | string
    tripId?: StringNullableWithAggregatesFilter<"GpsPoint"> | string | null
    userId?: StringWithAggregatesFilter<"GpsPoint"> | string
    clientPointId?: StringNullableWithAggregatesFilter<"GpsPoint"> | string | null
    latitude?: FloatWithAggregatesFilter<"GpsPoint"> | number
    longitude?: FloatWithAggregatesFilter<"GpsPoint"> | number
    accuracy?: FloatNullableWithAggregatesFilter<"GpsPoint"> | number | null
    speed?: FloatNullableWithAggregatesFilter<"GpsPoint"> | number | null
    bearing?: FloatNullableWithAggregatesFilter<"GpsPoint"> | number | null
    batteryLevel?: FloatNullableWithAggregatesFilter<"GpsPoint"> | number | null
    timestamp?: DateTimeWithAggregatesFilter<"GpsPoint"> | Date | string
    isSmoothed?: BoolWithAggregatesFilter<"GpsPoint"> | boolean
    createdAt?: DateTimeWithAggregatesFilter<"GpsPoint"> | Date | string
  }

  export type GpsStopWhereInput = {
    AND?: GpsStopWhereInput | GpsStopWhereInput[]
    OR?: GpsStopWhereInput[]
    NOT?: GpsStopWhereInput | GpsStopWhereInput[]
    id?: StringFilter<"GpsStop"> | string
    tripId?: StringFilter<"GpsStop"> | string
    latitude?: FloatFilter<"GpsStop"> | number
    longitude?: FloatFilter<"GpsStop"> | number
    startedAt?: DateTimeFilter<"GpsStop"> | Date | string
    endedAt?: DateTimeNullableFilter<"GpsStop"> | Date | string | null
    duration?: IntNullableFilter<"GpsStop"> | number | null
    address?: StringNullableFilter<"GpsStop"> | string | null
    trip?: XOR<TripScalarRelationFilter, TripWhereInput>
  }

  export type GpsStopOrderByWithRelationInput = {
    id?: SortOrder
    tripId?: SortOrder
    latitude?: SortOrder
    longitude?: SortOrder
    startedAt?: SortOrder
    endedAt?: SortOrderInput | SortOrder
    duration?: SortOrderInput | SortOrder
    address?: SortOrderInput | SortOrder
    trip?: TripOrderByWithRelationInput
  }

  export type GpsStopWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    AND?: GpsStopWhereInput | GpsStopWhereInput[]
    OR?: GpsStopWhereInput[]
    NOT?: GpsStopWhereInput | GpsStopWhereInput[]
    tripId?: StringFilter<"GpsStop"> | string
    latitude?: FloatFilter<"GpsStop"> | number
    longitude?: FloatFilter<"GpsStop"> | number
    startedAt?: DateTimeFilter<"GpsStop"> | Date | string
    endedAt?: DateTimeNullableFilter<"GpsStop"> | Date | string | null
    duration?: IntNullableFilter<"GpsStop"> | number | null
    address?: StringNullableFilter<"GpsStop"> | string | null
    trip?: XOR<TripScalarRelationFilter, TripWhereInput>
  }, "id">

  export type GpsStopOrderByWithAggregationInput = {
    id?: SortOrder
    tripId?: SortOrder
    latitude?: SortOrder
    longitude?: SortOrder
    startedAt?: SortOrder
    endedAt?: SortOrderInput | SortOrder
    duration?: SortOrderInput | SortOrder
    address?: SortOrderInput | SortOrder
    _count?: GpsStopCountOrderByAggregateInput
    _avg?: GpsStopAvgOrderByAggregateInput
    _max?: GpsStopMaxOrderByAggregateInput
    _min?: GpsStopMinOrderByAggregateInput
    _sum?: GpsStopSumOrderByAggregateInput
  }

  export type GpsStopScalarWhereWithAggregatesInput = {
    AND?: GpsStopScalarWhereWithAggregatesInput | GpsStopScalarWhereWithAggregatesInput[]
    OR?: GpsStopScalarWhereWithAggregatesInput[]
    NOT?: GpsStopScalarWhereWithAggregatesInput | GpsStopScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"GpsStop"> | string
    tripId?: StringWithAggregatesFilter<"GpsStop"> | string
    latitude?: FloatWithAggregatesFilter<"GpsStop"> | number
    longitude?: FloatWithAggregatesFilter<"GpsStop"> | number
    startedAt?: DateTimeWithAggregatesFilter<"GpsStop"> | Date | string
    endedAt?: DateTimeNullableWithAggregatesFilter<"GpsStop"> | Date | string | null
    duration?: IntNullableWithAggregatesFilter<"GpsStop"> | number | null
    address?: StringNullableWithAggregatesFilter<"GpsStop"> | string | null
  }

  export type NotificationWhereInput = {
    AND?: NotificationWhereInput | NotificationWhereInput[]
    OR?: NotificationWhereInput[]
    NOT?: NotificationWhereInput | NotificationWhereInput[]
    id?: StringFilter<"Notification"> | string
    userId?: StringFilter<"Notification"> | string
    type?: EnumNotificationTypeFilter<"Notification"> | $Enums.NotificationType
    title?: StringFilter<"Notification"> | string
    body?: StringFilter<"Notification"> | string
    data?: JsonNullableFilter<"Notification">
    read?: BoolFilter<"Notification"> | boolean
    sentAt?: DateTimeFilter<"Notification"> | Date | string
    user?: XOR<UserScalarRelationFilter, UserWhereInput>
  }

  export type NotificationOrderByWithRelationInput = {
    id?: SortOrder
    userId?: SortOrder
    type?: SortOrder
    title?: SortOrder
    body?: SortOrder
    data?: SortOrderInput | SortOrder
    read?: SortOrder
    sentAt?: SortOrder
    user?: UserOrderByWithRelationInput
  }

  export type NotificationWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    AND?: NotificationWhereInput | NotificationWhereInput[]
    OR?: NotificationWhereInput[]
    NOT?: NotificationWhereInput | NotificationWhereInput[]
    userId?: StringFilter<"Notification"> | string
    type?: EnumNotificationTypeFilter<"Notification"> | $Enums.NotificationType
    title?: StringFilter<"Notification"> | string
    body?: StringFilter<"Notification"> | string
    data?: JsonNullableFilter<"Notification">
    read?: BoolFilter<"Notification"> | boolean
    sentAt?: DateTimeFilter<"Notification"> | Date | string
    user?: XOR<UserScalarRelationFilter, UserWhereInput>
  }, "id">

  export type NotificationOrderByWithAggregationInput = {
    id?: SortOrder
    userId?: SortOrder
    type?: SortOrder
    title?: SortOrder
    body?: SortOrder
    data?: SortOrderInput | SortOrder
    read?: SortOrder
    sentAt?: SortOrder
    _count?: NotificationCountOrderByAggregateInput
    _max?: NotificationMaxOrderByAggregateInput
    _min?: NotificationMinOrderByAggregateInput
  }

  export type NotificationScalarWhereWithAggregatesInput = {
    AND?: NotificationScalarWhereWithAggregatesInput | NotificationScalarWhereWithAggregatesInput[]
    OR?: NotificationScalarWhereWithAggregatesInput[]
    NOT?: NotificationScalarWhereWithAggregatesInput | NotificationScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"Notification"> | string
    userId?: StringWithAggregatesFilter<"Notification"> | string
    type?: EnumNotificationTypeWithAggregatesFilter<"Notification"> | $Enums.NotificationType
    title?: StringWithAggregatesFilter<"Notification"> | string
    body?: StringWithAggregatesFilter<"Notification"> | string
    data?: JsonNullableWithAggregatesFilter<"Notification">
    read?: BoolWithAggregatesFilter<"Notification"> | boolean
    sentAt?: DateTimeWithAggregatesFilter<"Notification"> | Date | string
  }

  export type SystemConfigWhereInput = {
    AND?: SystemConfigWhereInput | SystemConfigWhereInput[]
    OR?: SystemConfigWhereInput[]
    NOT?: SystemConfigWhereInput | SystemConfigWhereInput[]
    id?: StringFilter<"SystemConfig"> | string
    key?: StringFilter<"SystemConfig"> | string
    value?: JsonFilter<"SystemConfig">
    updatedAt?: DateTimeFilter<"SystemConfig"> | Date | string
  }

  export type SystemConfigOrderByWithRelationInput = {
    id?: SortOrder
    key?: SortOrder
    value?: SortOrder
    updatedAt?: SortOrder
  }

  export type SystemConfigWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    key?: string
    AND?: SystemConfigWhereInput | SystemConfigWhereInput[]
    OR?: SystemConfigWhereInput[]
    NOT?: SystemConfigWhereInput | SystemConfigWhereInput[]
    value?: JsonFilter<"SystemConfig">
    updatedAt?: DateTimeFilter<"SystemConfig"> | Date | string
  }, "id" | "key">

  export type SystemConfigOrderByWithAggregationInput = {
    id?: SortOrder
    key?: SortOrder
    value?: SortOrder
    updatedAt?: SortOrder
    _count?: SystemConfigCountOrderByAggregateInput
    _max?: SystemConfigMaxOrderByAggregateInput
    _min?: SystemConfigMinOrderByAggregateInput
  }

  export type SystemConfigScalarWhereWithAggregatesInput = {
    AND?: SystemConfigScalarWhereWithAggregatesInput | SystemConfigScalarWhereWithAggregatesInput[]
    OR?: SystemConfigScalarWhereWithAggregatesInput[]
    NOT?: SystemConfigScalarWhereWithAggregatesInput | SystemConfigScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"SystemConfig"> | string
    key?: StringWithAggregatesFilter<"SystemConfig"> | string
    value?: JsonWithAggregatesFilter<"SystemConfig">
    updatedAt?: DateTimeWithAggregatesFilter<"SystemConfig"> | Date | string
  }

  export type DailySummaryWhereInput = {
    AND?: DailySummaryWhereInput | DailySummaryWhereInput[]
    OR?: DailySummaryWhereInput[]
    NOT?: DailySummaryWhereInput | DailySummaryWhereInput[]
    id?: StringFilter<"DailySummary"> | string
    userId?: StringFilter<"DailySummary"> | string
    date?: DateTimeFilter<"DailySummary"> | Date | string
    totalDistance?: FloatFilter<"DailySummary"> | number
    travelTime?: IntFilter<"DailySummary"> | number
    meetingTime?: IntFilter<"DailySummary"> | number
    idleTime?: IntFilter<"DailySummary"> | number
    tripsCompleted?: IntFilter<"DailySummary"> | number
    productivityScore?: FloatNullableFilter<"DailySummary"> | number | null
    createdAt?: DateTimeFilter<"DailySummary"> | Date | string
    updatedAt?: DateTimeFilter<"DailySummary"> | Date | string
  }

  export type DailySummaryOrderByWithRelationInput = {
    id?: SortOrder
    userId?: SortOrder
    date?: SortOrder
    totalDistance?: SortOrder
    travelTime?: SortOrder
    meetingTime?: SortOrder
    idleTime?: SortOrder
    tripsCompleted?: SortOrder
    productivityScore?: SortOrderInput | SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
  }

  export type DailySummaryWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    userId_date?: DailySummaryUserIdDateCompoundUniqueInput
    AND?: DailySummaryWhereInput | DailySummaryWhereInput[]
    OR?: DailySummaryWhereInput[]
    NOT?: DailySummaryWhereInput | DailySummaryWhereInput[]
    userId?: StringFilter<"DailySummary"> | string
    date?: DateTimeFilter<"DailySummary"> | Date | string
    totalDistance?: FloatFilter<"DailySummary"> | number
    travelTime?: IntFilter<"DailySummary"> | number
    meetingTime?: IntFilter<"DailySummary"> | number
    idleTime?: IntFilter<"DailySummary"> | number
    tripsCompleted?: IntFilter<"DailySummary"> | number
    productivityScore?: FloatNullableFilter<"DailySummary"> | number | null
    createdAt?: DateTimeFilter<"DailySummary"> | Date | string
    updatedAt?: DateTimeFilter<"DailySummary"> | Date | string
  }, "id" | "userId_date">

  export type DailySummaryOrderByWithAggregationInput = {
    id?: SortOrder
    userId?: SortOrder
    date?: SortOrder
    totalDistance?: SortOrder
    travelTime?: SortOrder
    meetingTime?: SortOrder
    idleTime?: SortOrder
    tripsCompleted?: SortOrder
    productivityScore?: SortOrderInput | SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
    _count?: DailySummaryCountOrderByAggregateInput
    _avg?: DailySummaryAvgOrderByAggregateInput
    _max?: DailySummaryMaxOrderByAggregateInput
    _min?: DailySummaryMinOrderByAggregateInput
    _sum?: DailySummarySumOrderByAggregateInput
  }

  export type DailySummaryScalarWhereWithAggregatesInput = {
    AND?: DailySummaryScalarWhereWithAggregatesInput | DailySummaryScalarWhereWithAggregatesInput[]
    OR?: DailySummaryScalarWhereWithAggregatesInput[]
    NOT?: DailySummaryScalarWhereWithAggregatesInput | DailySummaryScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"DailySummary"> | string
    userId?: StringWithAggregatesFilter<"DailySummary"> | string
    date?: DateTimeWithAggregatesFilter<"DailySummary"> | Date | string
    totalDistance?: FloatWithAggregatesFilter<"DailySummary"> | number
    travelTime?: IntWithAggregatesFilter<"DailySummary"> | number
    meetingTime?: IntWithAggregatesFilter<"DailySummary"> | number
    idleTime?: IntWithAggregatesFilter<"DailySummary"> | number
    tripsCompleted?: IntWithAggregatesFilter<"DailySummary"> | number
    productivityScore?: FloatNullableWithAggregatesFilter<"DailySummary"> | number | null
    createdAt?: DateTimeWithAggregatesFilter<"DailySummary"> | Date | string
    updatedAt?: DateTimeWithAggregatesFilter<"DailySummary"> | Date | string
  }

  export type MonthlySummaryWhereInput = {
    AND?: MonthlySummaryWhereInput | MonthlySummaryWhereInput[]
    OR?: MonthlySummaryWhereInput[]
    NOT?: MonthlySummaryWhereInput | MonthlySummaryWhereInput[]
    id?: StringFilter<"MonthlySummary"> | string
    userId?: StringFilter<"MonthlySummary"> | string
    year?: IntFilter<"MonthlySummary"> | number
    month?: IntFilter<"MonthlySummary"> | number
    totalDistance?: FloatFilter<"MonthlySummary"> | number
    travelTime?: IntFilter<"MonthlySummary"> | number
    meetingTime?: IntFilter<"MonthlySummary"> | number
    idleTime?: IntFilter<"MonthlySummary"> | number
    tripsCompleted?: IntFilter<"MonthlySummary"> | number
    productivityScore?: FloatNullableFilter<"MonthlySummary"> | number | null
  }

  export type MonthlySummaryOrderByWithRelationInput = {
    id?: SortOrder
    userId?: SortOrder
    year?: SortOrder
    month?: SortOrder
    totalDistance?: SortOrder
    travelTime?: SortOrder
    meetingTime?: SortOrder
    idleTime?: SortOrder
    tripsCompleted?: SortOrder
    productivityScore?: SortOrderInput | SortOrder
  }

  export type MonthlySummaryWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    userId_year_month?: MonthlySummaryUserIdYearMonthCompoundUniqueInput
    AND?: MonthlySummaryWhereInput | MonthlySummaryWhereInput[]
    OR?: MonthlySummaryWhereInput[]
    NOT?: MonthlySummaryWhereInput | MonthlySummaryWhereInput[]
    userId?: StringFilter<"MonthlySummary"> | string
    year?: IntFilter<"MonthlySummary"> | number
    month?: IntFilter<"MonthlySummary"> | number
    totalDistance?: FloatFilter<"MonthlySummary"> | number
    travelTime?: IntFilter<"MonthlySummary"> | number
    meetingTime?: IntFilter<"MonthlySummary"> | number
    idleTime?: IntFilter<"MonthlySummary"> | number
    tripsCompleted?: IntFilter<"MonthlySummary"> | number
    productivityScore?: FloatNullableFilter<"MonthlySummary"> | number | null
  }, "id" | "userId_year_month">

  export type MonthlySummaryOrderByWithAggregationInput = {
    id?: SortOrder
    userId?: SortOrder
    year?: SortOrder
    month?: SortOrder
    totalDistance?: SortOrder
    travelTime?: SortOrder
    meetingTime?: SortOrder
    idleTime?: SortOrder
    tripsCompleted?: SortOrder
    productivityScore?: SortOrderInput | SortOrder
    _count?: MonthlySummaryCountOrderByAggregateInput
    _avg?: MonthlySummaryAvgOrderByAggregateInput
    _max?: MonthlySummaryMaxOrderByAggregateInput
    _min?: MonthlySummaryMinOrderByAggregateInput
    _sum?: MonthlySummarySumOrderByAggregateInput
  }

  export type MonthlySummaryScalarWhereWithAggregatesInput = {
    AND?: MonthlySummaryScalarWhereWithAggregatesInput | MonthlySummaryScalarWhereWithAggregatesInput[]
    OR?: MonthlySummaryScalarWhereWithAggregatesInput[]
    NOT?: MonthlySummaryScalarWhereWithAggregatesInput | MonthlySummaryScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"MonthlySummary"> | string
    userId?: StringWithAggregatesFilter<"MonthlySummary"> | string
    year?: IntWithAggregatesFilter<"MonthlySummary"> | number
    month?: IntWithAggregatesFilter<"MonthlySummary"> | number
    totalDistance?: FloatWithAggregatesFilter<"MonthlySummary"> | number
    travelTime?: IntWithAggregatesFilter<"MonthlySummary"> | number
    meetingTime?: IntWithAggregatesFilter<"MonthlySummary"> | number
    idleTime?: IntWithAggregatesFilter<"MonthlySummary"> | number
    tripsCompleted?: IntWithAggregatesFilter<"MonthlySummary"> | number
    productivityScore?: FloatNullableWithAggregatesFilter<"MonthlySummary"> | number | null
  }

  export type UserCreateInput = {
    id?: string
    uid: string
    email: string
    passwordHash: string
    fullName: string
    employeeCode: string
    mobileNumber?: string | null
    sittingLocation?: string | null
    role?: $Enums.UserRole
    deviceId?: string | null
    profileImage?: string | null
    status?: $Enums.UserStatus
    fcmToken?: string | null
    isRooted?: boolean
    presence?: $Enums.EmployeePresence
    lastSeenAt?: Date | string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    reportingManager?: UserCreateNestedOneWithoutDirectReportsInput
    directReports?: UserCreateNestedManyWithoutReportingManagerInput
    refreshTokens?: RefreshTokenCreateNestedManyWithoutUserInput
    trips?: TripCreateNestedManyWithoutUserInput
    gpsPoints?: GpsPointCreateNestedManyWithoutUserInput
    auditLogs?: AuditLogCreateNestedManyWithoutActorInput
    notifications?: NotificationCreateNestedManyWithoutUserInput
  }

  export type UserUncheckedCreateInput = {
    id?: string
    uid: string
    email: string
    passwordHash: string
    fullName: string
    employeeCode: string
    mobileNumber?: string | null
    sittingLocation?: string | null
    reportingManagerId?: string | null
    role?: $Enums.UserRole
    deviceId?: string | null
    profileImage?: string | null
    status?: $Enums.UserStatus
    fcmToken?: string | null
    isRooted?: boolean
    presence?: $Enums.EmployeePresence
    lastSeenAt?: Date | string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    directReports?: UserUncheckedCreateNestedManyWithoutReportingManagerInput
    refreshTokens?: RefreshTokenUncheckedCreateNestedManyWithoutUserInput
    trips?: TripUncheckedCreateNestedManyWithoutUserInput
    gpsPoints?: GpsPointUncheckedCreateNestedManyWithoutUserInput
    auditLogs?: AuditLogUncheckedCreateNestedManyWithoutActorInput
    notifications?: NotificationUncheckedCreateNestedManyWithoutUserInput
  }

  export type UserUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    uid?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    fullName?: StringFieldUpdateOperationsInput | string
    employeeCode?: StringFieldUpdateOperationsInput | string
    mobileNumber?: NullableStringFieldUpdateOperationsInput | string | null
    sittingLocation?: NullableStringFieldUpdateOperationsInput | string | null
    role?: EnumUserRoleFieldUpdateOperationsInput | $Enums.UserRole
    deviceId?: NullableStringFieldUpdateOperationsInput | string | null
    profileImage?: NullableStringFieldUpdateOperationsInput | string | null
    status?: EnumUserStatusFieldUpdateOperationsInput | $Enums.UserStatus
    fcmToken?: NullableStringFieldUpdateOperationsInput | string | null
    isRooted?: BoolFieldUpdateOperationsInput | boolean
    presence?: EnumEmployeePresenceFieldUpdateOperationsInput | $Enums.EmployeePresence
    lastSeenAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    reportingManager?: UserUpdateOneWithoutDirectReportsNestedInput
    directReports?: UserUpdateManyWithoutReportingManagerNestedInput
    refreshTokens?: RefreshTokenUpdateManyWithoutUserNestedInput
    trips?: TripUpdateManyWithoutUserNestedInput
    gpsPoints?: GpsPointUpdateManyWithoutUserNestedInput
    auditLogs?: AuditLogUpdateManyWithoutActorNestedInput
    notifications?: NotificationUpdateManyWithoutUserNestedInput
  }

  export type UserUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    uid?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    fullName?: StringFieldUpdateOperationsInput | string
    employeeCode?: StringFieldUpdateOperationsInput | string
    mobileNumber?: NullableStringFieldUpdateOperationsInput | string | null
    sittingLocation?: NullableStringFieldUpdateOperationsInput | string | null
    reportingManagerId?: NullableStringFieldUpdateOperationsInput | string | null
    role?: EnumUserRoleFieldUpdateOperationsInput | $Enums.UserRole
    deviceId?: NullableStringFieldUpdateOperationsInput | string | null
    profileImage?: NullableStringFieldUpdateOperationsInput | string | null
    status?: EnumUserStatusFieldUpdateOperationsInput | $Enums.UserStatus
    fcmToken?: NullableStringFieldUpdateOperationsInput | string | null
    isRooted?: BoolFieldUpdateOperationsInput | boolean
    presence?: EnumEmployeePresenceFieldUpdateOperationsInput | $Enums.EmployeePresence
    lastSeenAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    directReports?: UserUncheckedUpdateManyWithoutReportingManagerNestedInput
    refreshTokens?: RefreshTokenUncheckedUpdateManyWithoutUserNestedInput
    trips?: TripUncheckedUpdateManyWithoutUserNestedInput
    gpsPoints?: GpsPointUncheckedUpdateManyWithoutUserNestedInput
    auditLogs?: AuditLogUncheckedUpdateManyWithoutActorNestedInput
    notifications?: NotificationUncheckedUpdateManyWithoutUserNestedInput
  }

  export type UserCreateManyInput = {
    id?: string
    uid: string
    email: string
    passwordHash: string
    fullName: string
    employeeCode: string
    mobileNumber?: string | null
    sittingLocation?: string | null
    reportingManagerId?: string | null
    role?: $Enums.UserRole
    deviceId?: string | null
    profileImage?: string | null
    status?: $Enums.UserStatus
    fcmToken?: string | null
    isRooted?: boolean
    presence?: $Enums.EmployeePresence
    lastSeenAt?: Date | string | null
    createdAt?: Date | string
    updatedAt?: Date | string
  }

  export type UserUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    uid?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    fullName?: StringFieldUpdateOperationsInput | string
    employeeCode?: StringFieldUpdateOperationsInput | string
    mobileNumber?: NullableStringFieldUpdateOperationsInput | string | null
    sittingLocation?: NullableStringFieldUpdateOperationsInput | string | null
    role?: EnumUserRoleFieldUpdateOperationsInput | $Enums.UserRole
    deviceId?: NullableStringFieldUpdateOperationsInput | string | null
    profileImage?: NullableStringFieldUpdateOperationsInput | string | null
    status?: EnumUserStatusFieldUpdateOperationsInput | $Enums.UserStatus
    fcmToken?: NullableStringFieldUpdateOperationsInput | string | null
    isRooted?: BoolFieldUpdateOperationsInput | boolean
    presence?: EnumEmployeePresenceFieldUpdateOperationsInput | $Enums.EmployeePresence
    lastSeenAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type UserUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    uid?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    fullName?: StringFieldUpdateOperationsInput | string
    employeeCode?: StringFieldUpdateOperationsInput | string
    mobileNumber?: NullableStringFieldUpdateOperationsInput | string | null
    sittingLocation?: NullableStringFieldUpdateOperationsInput | string | null
    reportingManagerId?: NullableStringFieldUpdateOperationsInput | string | null
    role?: EnumUserRoleFieldUpdateOperationsInput | $Enums.UserRole
    deviceId?: NullableStringFieldUpdateOperationsInput | string | null
    profileImage?: NullableStringFieldUpdateOperationsInput | string | null
    status?: EnumUserStatusFieldUpdateOperationsInput | $Enums.UserStatus
    fcmToken?: NullableStringFieldUpdateOperationsInput | string | null
    isRooted?: BoolFieldUpdateOperationsInput | boolean
    presence?: EnumEmployeePresenceFieldUpdateOperationsInput | $Enums.EmployeePresence
    lastSeenAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type RefreshTokenCreateInput = {
    id?: string
    tokenHash: string
    deviceId?: string | null
    expiresAt: Date | string
    createdAt?: Date | string
    user: UserCreateNestedOneWithoutRefreshTokensInput
  }

  export type RefreshTokenUncheckedCreateInput = {
    id?: string
    userId: string
    tokenHash: string
    deviceId?: string | null
    expiresAt: Date | string
    createdAt?: Date | string
  }

  export type RefreshTokenUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    tokenHash?: StringFieldUpdateOperationsInput | string
    deviceId?: NullableStringFieldUpdateOperationsInput | string | null
    expiresAt?: DateTimeFieldUpdateOperationsInput | Date | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    user?: UserUpdateOneRequiredWithoutRefreshTokensNestedInput
  }

  export type RefreshTokenUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    tokenHash?: StringFieldUpdateOperationsInput | string
    deviceId?: NullableStringFieldUpdateOperationsInput | string | null
    expiresAt?: DateTimeFieldUpdateOperationsInput | Date | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type RefreshTokenCreateManyInput = {
    id?: string
    userId: string
    tokenHash: string
    deviceId?: string | null
    expiresAt: Date | string
    createdAt?: Date | string
  }

  export type RefreshTokenUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    tokenHash?: StringFieldUpdateOperationsInput | string
    deviceId?: NullableStringFieldUpdateOperationsInput | string | null
    expiresAt?: DateTimeFieldUpdateOperationsInput | Date | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type RefreshTokenUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    tokenHash?: StringFieldUpdateOperationsInput | string
    deviceId?: NullableStringFieldUpdateOperationsInput | string | null
    expiresAt?: DateTimeFieldUpdateOperationsInput | Date | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type PasswordResetTokenCreateInput = {
    id?: string
    email: string
    tokenHash: string
    expiresAt: Date | string
    consumed?: boolean
    createdAt?: Date | string
  }

  export type PasswordResetTokenUncheckedCreateInput = {
    id?: string
    email: string
    tokenHash: string
    expiresAt: Date | string
    consumed?: boolean
    createdAt?: Date | string
  }

  export type PasswordResetTokenUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    tokenHash?: StringFieldUpdateOperationsInput | string
    expiresAt?: DateTimeFieldUpdateOperationsInput | Date | string
    consumed?: BoolFieldUpdateOperationsInput | boolean
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type PasswordResetTokenUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    tokenHash?: StringFieldUpdateOperationsInput | string
    expiresAt?: DateTimeFieldUpdateOperationsInput | Date | string
    consumed?: BoolFieldUpdateOperationsInput | boolean
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type PasswordResetTokenCreateManyInput = {
    id?: string
    email: string
    tokenHash: string
    expiresAt: Date | string
    consumed?: boolean
    createdAt?: Date | string
  }

  export type PasswordResetTokenUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    tokenHash?: StringFieldUpdateOperationsInput | string
    expiresAt?: DateTimeFieldUpdateOperationsInput | Date | string
    consumed?: BoolFieldUpdateOperationsInput | boolean
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type PasswordResetTokenUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    tokenHash?: StringFieldUpdateOperationsInput | string
    expiresAt?: DateTimeFieldUpdateOperationsInput | Date | string
    consumed?: BoolFieldUpdateOperationsInput | boolean
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type AuditLogCreateInput = {
    id?: string
    actorEmail?: string | null
    action: string
    targetType?: string | null
    targetId?: string | null
    metadata?: NullableJsonNullValueInput | InputJsonValue
    ipAddress?: string | null
    userAgent?: string | null
    createdAt?: Date | string
    actor?: UserCreateNestedOneWithoutAuditLogsInput
  }

  export type AuditLogUncheckedCreateInput = {
    id?: string
    actorUserId?: string | null
    actorEmail?: string | null
    action: string
    targetType?: string | null
    targetId?: string | null
    metadata?: NullableJsonNullValueInput | InputJsonValue
    ipAddress?: string | null
    userAgent?: string | null
    createdAt?: Date | string
  }

  export type AuditLogUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    actorEmail?: NullableStringFieldUpdateOperationsInput | string | null
    action?: StringFieldUpdateOperationsInput | string
    targetType?: NullableStringFieldUpdateOperationsInput | string | null
    targetId?: NullableStringFieldUpdateOperationsInput | string | null
    metadata?: NullableJsonNullValueInput | InputJsonValue
    ipAddress?: NullableStringFieldUpdateOperationsInput | string | null
    userAgent?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    actor?: UserUpdateOneWithoutAuditLogsNestedInput
  }

  export type AuditLogUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    actorUserId?: NullableStringFieldUpdateOperationsInput | string | null
    actorEmail?: NullableStringFieldUpdateOperationsInput | string | null
    action?: StringFieldUpdateOperationsInput | string
    targetType?: NullableStringFieldUpdateOperationsInput | string | null
    targetId?: NullableStringFieldUpdateOperationsInput | string | null
    metadata?: NullableJsonNullValueInput | InputJsonValue
    ipAddress?: NullableStringFieldUpdateOperationsInput | string | null
    userAgent?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type AuditLogCreateManyInput = {
    id?: string
    actorUserId?: string | null
    actorEmail?: string | null
    action: string
    targetType?: string | null
    targetId?: string | null
    metadata?: NullableJsonNullValueInput | InputJsonValue
    ipAddress?: string | null
    userAgent?: string | null
    createdAt?: Date | string
  }

  export type AuditLogUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    actorEmail?: NullableStringFieldUpdateOperationsInput | string | null
    action?: StringFieldUpdateOperationsInput | string
    targetType?: NullableStringFieldUpdateOperationsInput | string | null
    targetId?: NullableStringFieldUpdateOperationsInput | string | null
    metadata?: NullableJsonNullValueInput | InputJsonValue
    ipAddress?: NullableStringFieldUpdateOperationsInput | string | null
    userAgent?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type AuditLogUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    actorUserId?: NullableStringFieldUpdateOperationsInput | string | null
    actorEmail?: NullableStringFieldUpdateOperationsInput | string | null
    action?: StringFieldUpdateOperationsInput | string
    targetType?: NullableStringFieldUpdateOperationsInput | string | null
    targetId?: NullableStringFieldUpdateOperationsInput | string | null
    metadata?: NullableJsonNullValueInput | InputJsonValue
    ipAddress?: NullableStringFieldUpdateOperationsInput | string | null
    userAgent?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type TripCreateInput = {
    id?: string
    tripId?: string
    city?: string | null
    fromLocation?: string | null
    toLocation?: string | null
    destinationLat?: number | null
    destinationLng?: number | null
    googlePlaceId?: string | null
    plannedDistance?: number | null
    vehicleType?: $Enums.VehicleType | null
    fuelType?: $Enums.FuelType | null
    purpose?: string | null
    notes?: string | null
    status?: $Enums.TripStatus
    totalDistance?: number
    travelDuration?: number
    idleTime?: number
    meetingDuration?: number
    productivityScore?: number | null
    tripEfficiency?: number | null
    startedAt?: Date | string | null
    arrivedAt?: Date | string | null
    completedAt?: Date | string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    user: UserCreateNestedOneWithoutTripsInput
    punches?: PunchCreateNestedManyWithoutTripInput
    gpsPoints?: GpsPointCreateNestedManyWithoutTripInput
    stops?: GpsStopCreateNestedManyWithoutTripInput
  }

  export type TripUncheckedCreateInput = {
    id?: string
    tripId?: string
    userId: string
    city?: string | null
    fromLocation?: string | null
    toLocation?: string | null
    destinationLat?: number | null
    destinationLng?: number | null
    googlePlaceId?: string | null
    plannedDistance?: number | null
    vehicleType?: $Enums.VehicleType | null
    fuelType?: $Enums.FuelType | null
    purpose?: string | null
    notes?: string | null
    status?: $Enums.TripStatus
    totalDistance?: number
    travelDuration?: number
    idleTime?: number
    meetingDuration?: number
    productivityScore?: number | null
    tripEfficiency?: number | null
    startedAt?: Date | string | null
    arrivedAt?: Date | string | null
    completedAt?: Date | string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    punches?: PunchUncheckedCreateNestedManyWithoutTripInput
    gpsPoints?: GpsPointUncheckedCreateNestedManyWithoutTripInput
    stops?: GpsStopUncheckedCreateNestedManyWithoutTripInput
  }

  export type TripUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    tripId?: StringFieldUpdateOperationsInput | string
    city?: NullableStringFieldUpdateOperationsInput | string | null
    fromLocation?: NullableStringFieldUpdateOperationsInput | string | null
    toLocation?: NullableStringFieldUpdateOperationsInput | string | null
    destinationLat?: NullableFloatFieldUpdateOperationsInput | number | null
    destinationLng?: NullableFloatFieldUpdateOperationsInput | number | null
    googlePlaceId?: NullableStringFieldUpdateOperationsInput | string | null
    plannedDistance?: NullableFloatFieldUpdateOperationsInput | number | null
    vehicleType?: NullableEnumVehicleTypeFieldUpdateOperationsInput | $Enums.VehicleType | null
    fuelType?: NullableEnumFuelTypeFieldUpdateOperationsInput | $Enums.FuelType | null
    purpose?: NullableStringFieldUpdateOperationsInput | string | null
    notes?: NullableStringFieldUpdateOperationsInput | string | null
    status?: EnumTripStatusFieldUpdateOperationsInput | $Enums.TripStatus
    totalDistance?: FloatFieldUpdateOperationsInput | number
    travelDuration?: IntFieldUpdateOperationsInput | number
    idleTime?: IntFieldUpdateOperationsInput | number
    meetingDuration?: IntFieldUpdateOperationsInput | number
    productivityScore?: NullableFloatFieldUpdateOperationsInput | number | null
    tripEfficiency?: NullableFloatFieldUpdateOperationsInput | number | null
    startedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    arrivedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    completedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    user?: UserUpdateOneRequiredWithoutTripsNestedInput
    punches?: PunchUpdateManyWithoutTripNestedInput
    gpsPoints?: GpsPointUpdateManyWithoutTripNestedInput
    stops?: GpsStopUpdateManyWithoutTripNestedInput
  }

  export type TripUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    tripId?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    city?: NullableStringFieldUpdateOperationsInput | string | null
    fromLocation?: NullableStringFieldUpdateOperationsInput | string | null
    toLocation?: NullableStringFieldUpdateOperationsInput | string | null
    destinationLat?: NullableFloatFieldUpdateOperationsInput | number | null
    destinationLng?: NullableFloatFieldUpdateOperationsInput | number | null
    googlePlaceId?: NullableStringFieldUpdateOperationsInput | string | null
    plannedDistance?: NullableFloatFieldUpdateOperationsInput | number | null
    vehicleType?: NullableEnumVehicleTypeFieldUpdateOperationsInput | $Enums.VehicleType | null
    fuelType?: NullableEnumFuelTypeFieldUpdateOperationsInput | $Enums.FuelType | null
    purpose?: NullableStringFieldUpdateOperationsInput | string | null
    notes?: NullableStringFieldUpdateOperationsInput | string | null
    status?: EnumTripStatusFieldUpdateOperationsInput | $Enums.TripStatus
    totalDistance?: FloatFieldUpdateOperationsInput | number
    travelDuration?: IntFieldUpdateOperationsInput | number
    idleTime?: IntFieldUpdateOperationsInput | number
    meetingDuration?: IntFieldUpdateOperationsInput | number
    productivityScore?: NullableFloatFieldUpdateOperationsInput | number | null
    tripEfficiency?: NullableFloatFieldUpdateOperationsInput | number | null
    startedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    arrivedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    completedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    punches?: PunchUncheckedUpdateManyWithoutTripNestedInput
    gpsPoints?: GpsPointUncheckedUpdateManyWithoutTripNestedInput
    stops?: GpsStopUncheckedUpdateManyWithoutTripNestedInput
  }

  export type TripCreateManyInput = {
    id?: string
    tripId?: string
    userId: string
    city?: string | null
    fromLocation?: string | null
    toLocation?: string | null
    destinationLat?: number | null
    destinationLng?: number | null
    googlePlaceId?: string | null
    plannedDistance?: number | null
    vehicleType?: $Enums.VehicleType | null
    fuelType?: $Enums.FuelType | null
    purpose?: string | null
    notes?: string | null
    status?: $Enums.TripStatus
    totalDistance?: number
    travelDuration?: number
    idleTime?: number
    meetingDuration?: number
    productivityScore?: number | null
    tripEfficiency?: number | null
    startedAt?: Date | string | null
    arrivedAt?: Date | string | null
    completedAt?: Date | string | null
    createdAt?: Date | string
    updatedAt?: Date | string
  }

  export type TripUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    tripId?: StringFieldUpdateOperationsInput | string
    city?: NullableStringFieldUpdateOperationsInput | string | null
    fromLocation?: NullableStringFieldUpdateOperationsInput | string | null
    toLocation?: NullableStringFieldUpdateOperationsInput | string | null
    destinationLat?: NullableFloatFieldUpdateOperationsInput | number | null
    destinationLng?: NullableFloatFieldUpdateOperationsInput | number | null
    googlePlaceId?: NullableStringFieldUpdateOperationsInput | string | null
    plannedDistance?: NullableFloatFieldUpdateOperationsInput | number | null
    vehicleType?: NullableEnumVehicleTypeFieldUpdateOperationsInput | $Enums.VehicleType | null
    fuelType?: NullableEnumFuelTypeFieldUpdateOperationsInput | $Enums.FuelType | null
    purpose?: NullableStringFieldUpdateOperationsInput | string | null
    notes?: NullableStringFieldUpdateOperationsInput | string | null
    status?: EnumTripStatusFieldUpdateOperationsInput | $Enums.TripStatus
    totalDistance?: FloatFieldUpdateOperationsInput | number
    travelDuration?: IntFieldUpdateOperationsInput | number
    idleTime?: IntFieldUpdateOperationsInput | number
    meetingDuration?: IntFieldUpdateOperationsInput | number
    productivityScore?: NullableFloatFieldUpdateOperationsInput | number | null
    tripEfficiency?: NullableFloatFieldUpdateOperationsInput | number | null
    startedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    arrivedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    completedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type TripUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    tripId?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    city?: NullableStringFieldUpdateOperationsInput | string | null
    fromLocation?: NullableStringFieldUpdateOperationsInput | string | null
    toLocation?: NullableStringFieldUpdateOperationsInput | string | null
    destinationLat?: NullableFloatFieldUpdateOperationsInput | number | null
    destinationLng?: NullableFloatFieldUpdateOperationsInput | number | null
    googlePlaceId?: NullableStringFieldUpdateOperationsInput | string | null
    plannedDistance?: NullableFloatFieldUpdateOperationsInput | number | null
    vehicleType?: NullableEnumVehicleTypeFieldUpdateOperationsInput | $Enums.VehicleType | null
    fuelType?: NullableEnumFuelTypeFieldUpdateOperationsInput | $Enums.FuelType | null
    purpose?: NullableStringFieldUpdateOperationsInput | string | null
    notes?: NullableStringFieldUpdateOperationsInput | string | null
    status?: EnumTripStatusFieldUpdateOperationsInput | $Enums.TripStatus
    totalDistance?: FloatFieldUpdateOperationsInput | number
    travelDuration?: IntFieldUpdateOperationsInput | number
    idleTime?: IntFieldUpdateOperationsInput | number
    meetingDuration?: IntFieldUpdateOperationsInput | number
    productivityScore?: NullableFloatFieldUpdateOperationsInput | number | null
    tripEfficiency?: NullableFloatFieldUpdateOperationsInput | number | null
    startedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    arrivedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    completedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type PunchCreateInput = {
    id?: string
    type: $Enums.PunchType
    timestamp: Date | string
    latitude: number
    longitude: number
    address?: string | null
    batteryPercent?: number | null
    gpsAccuracy?: number | null
    speed?: number | null
    isMockLocation?: boolean
    meetingSummary?: string | null
    leadType?: $Enums.LeadType | null
    customerNotes?: string | null
    createdAt?: Date | string
    trip: TripCreateNestedOneWithoutPunchesInput
  }

  export type PunchUncheckedCreateInput = {
    id?: string
    tripId: string
    type: $Enums.PunchType
    timestamp: Date | string
    latitude: number
    longitude: number
    address?: string | null
    batteryPercent?: number | null
    gpsAccuracy?: number | null
    speed?: number | null
    isMockLocation?: boolean
    meetingSummary?: string | null
    leadType?: $Enums.LeadType | null
    customerNotes?: string | null
    createdAt?: Date | string
  }

  export type PunchUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    type?: EnumPunchTypeFieldUpdateOperationsInput | $Enums.PunchType
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
    latitude?: FloatFieldUpdateOperationsInput | number
    longitude?: FloatFieldUpdateOperationsInput | number
    address?: NullableStringFieldUpdateOperationsInput | string | null
    batteryPercent?: NullableFloatFieldUpdateOperationsInput | number | null
    gpsAccuracy?: NullableFloatFieldUpdateOperationsInput | number | null
    speed?: NullableFloatFieldUpdateOperationsInput | number | null
    isMockLocation?: BoolFieldUpdateOperationsInput | boolean
    meetingSummary?: NullableStringFieldUpdateOperationsInput | string | null
    leadType?: NullableEnumLeadTypeFieldUpdateOperationsInput | $Enums.LeadType | null
    customerNotes?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    trip?: TripUpdateOneRequiredWithoutPunchesNestedInput
  }

  export type PunchUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    tripId?: StringFieldUpdateOperationsInput | string
    type?: EnumPunchTypeFieldUpdateOperationsInput | $Enums.PunchType
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
    latitude?: FloatFieldUpdateOperationsInput | number
    longitude?: FloatFieldUpdateOperationsInput | number
    address?: NullableStringFieldUpdateOperationsInput | string | null
    batteryPercent?: NullableFloatFieldUpdateOperationsInput | number | null
    gpsAccuracy?: NullableFloatFieldUpdateOperationsInput | number | null
    speed?: NullableFloatFieldUpdateOperationsInput | number | null
    isMockLocation?: BoolFieldUpdateOperationsInput | boolean
    meetingSummary?: NullableStringFieldUpdateOperationsInput | string | null
    leadType?: NullableEnumLeadTypeFieldUpdateOperationsInput | $Enums.LeadType | null
    customerNotes?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type PunchCreateManyInput = {
    id?: string
    tripId: string
    type: $Enums.PunchType
    timestamp: Date | string
    latitude: number
    longitude: number
    address?: string | null
    batteryPercent?: number | null
    gpsAccuracy?: number | null
    speed?: number | null
    isMockLocation?: boolean
    meetingSummary?: string | null
    leadType?: $Enums.LeadType | null
    customerNotes?: string | null
    createdAt?: Date | string
  }

  export type PunchUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    type?: EnumPunchTypeFieldUpdateOperationsInput | $Enums.PunchType
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
    latitude?: FloatFieldUpdateOperationsInput | number
    longitude?: FloatFieldUpdateOperationsInput | number
    address?: NullableStringFieldUpdateOperationsInput | string | null
    batteryPercent?: NullableFloatFieldUpdateOperationsInput | number | null
    gpsAccuracy?: NullableFloatFieldUpdateOperationsInput | number | null
    speed?: NullableFloatFieldUpdateOperationsInput | number | null
    isMockLocation?: BoolFieldUpdateOperationsInput | boolean
    meetingSummary?: NullableStringFieldUpdateOperationsInput | string | null
    leadType?: NullableEnumLeadTypeFieldUpdateOperationsInput | $Enums.LeadType | null
    customerNotes?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type PunchUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    tripId?: StringFieldUpdateOperationsInput | string
    type?: EnumPunchTypeFieldUpdateOperationsInput | $Enums.PunchType
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
    latitude?: FloatFieldUpdateOperationsInput | number
    longitude?: FloatFieldUpdateOperationsInput | number
    address?: NullableStringFieldUpdateOperationsInput | string | null
    batteryPercent?: NullableFloatFieldUpdateOperationsInput | number | null
    gpsAccuracy?: NullableFloatFieldUpdateOperationsInput | number | null
    speed?: NullableFloatFieldUpdateOperationsInput | number | null
    isMockLocation?: BoolFieldUpdateOperationsInput | boolean
    meetingSummary?: NullableStringFieldUpdateOperationsInput | string | null
    leadType?: NullableEnumLeadTypeFieldUpdateOperationsInput | $Enums.LeadType | null
    customerNotes?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type GpsPointCreateInput = {
    id?: string
    clientPointId?: string | null
    latitude: number
    longitude: number
    accuracy?: number | null
    speed?: number | null
    bearing?: number | null
    batteryLevel?: number | null
    timestamp: Date | string
    isSmoothed?: boolean
    createdAt?: Date | string
    trip?: TripCreateNestedOneWithoutGpsPointsInput
    user: UserCreateNestedOneWithoutGpsPointsInput
  }

  export type GpsPointUncheckedCreateInput = {
    id?: string
    tripId?: string | null
    userId: string
    clientPointId?: string | null
    latitude: number
    longitude: number
    accuracy?: number | null
    speed?: number | null
    bearing?: number | null
    batteryLevel?: number | null
    timestamp: Date | string
    isSmoothed?: boolean
    createdAt?: Date | string
  }

  export type GpsPointUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    clientPointId?: NullableStringFieldUpdateOperationsInput | string | null
    latitude?: FloatFieldUpdateOperationsInput | number
    longitude?: FloatFieldUpdateOperationsInput | number
    accuracy?: NullableFloatFieldUpdateOperationsInput | number | null
    speed?: NullableFloatFieldUpdateOperationsInput | number | null
    bearing?: NullableFloatFieldUpdateOperationsInput | number | null
    batteryLevel?: NullableFloatFieldUpdateOperationsInput | number | null
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
    isSmoothed?: BoolFieldUpdateOperationsInput | boolean
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    trip?: TripUpdateOneWithoutGpsPointsNestedInput
    user?: UserUpdateOneRequiredWithoutGpsPointsNestedInput
  }

  export type GpsPointUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    tripId?: NullableStringFieldUpdateOperationsInput | string | null
    userId?: StringFieldUpdateOperationsInput | string
    clientPointId?: NullableStringFieldUpdateOperationsInput | string | null
    latitude?: FloatFieldUpdateOperationsInput | number
    longitude?: FloatFieldUpdateOperationsInput | number
    accuracy?: NullableFloatFieldUpdateOperationsInput | number | null
    speed?: NullableFloatFieldUpdateOperationsInput | number | null
    bearing?: NullableFloatFieldUpdateOperationsInput | number | null
    batteryLevel?: NullableFloatFieldUpdateOperationsInput | number | null
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
    isSmoothed?: BoolFieldUpdateOperationsInput | boolean
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type GpsPointCreateManyInput = {
    id?: string
    tripId?: string | null
    userId: string
    clientPointId?: string | null
    latitude: number
    longitude: number
    accuracy?: number | null
    speed?: number | null
    bearing?: number | null
    batteryLevel?: number | null
    timestamp: Date | string
    isSmoothed?: boolean
    createdAt?: Date | string
  }

  export type GpsPointUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    clientPointId?: NullableStringFieldUpdateOperationsInput | string | null
    latitude?: FloatFieldUpdateOperationsInput | number
    longitude?: FloatFieldUpdateOperationsInput | number
    accuracy?: NullableFloatFieldUpdateOperationsInput | number | null
    speed?: NullableFloatFieldUpdateOperationsInput | number | null
    bearing?: NullableFloatFieldUpdateOperationsInput | number | null
    batteryLevel?: NullableFloatFieldUpdateOperationsInput | number | null
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
    isSmoothed?: BoolFieldUpdateOperationsInput | boolean
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type GpsPointUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    tripId?: NullableStringFieldUpdateOperationsInput | string | null
    userId?: StringFieldUpdateOperationsInput | string
    clientPointId?: NullableStringFieldUpdateOperationsInput | string | null
    latitude?: FloatFieldUpdateOperationsInput | number
    longitude?: FloatFieldUpdateOperationsInput | number
    accuracy?: NullableFloatFieldUpdateOperationsInput | number | null
    speed?: NullableFloatFieldUpdateOperationsInput | number | null
    bearing?: NullableFloatFieldUpdateOperationsInput | number | null
    batteryLevel?: NullableFloatFieldUpdateOperationsInput | number | null
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
    isSmoothed?: BoolFieldUpdateOperationsInput | boolean
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type GpsStopCreateInput = {
    id?: string
    latitude: number
    longitude: number
    startedAt: Date | string
    endedAt?: Date | string | null
    duration?: number | null
    address?: string | null
    trip: TripCreateNestedOneWithoutStopsInput
  }

  export type GpsStopUncheckedCreateInput = {
    id?: string
    tripId: string
    latitude: number
    longitude: number
    startedAt: Date | string
    endedAt?: Date | string | null
    duration?: number | null
    address?: string | null
  }

  export type GpsStopUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    latitude?: FloatFieldUpdateOperationsInput | number
    longitude?: FloatFieldUpdateOperationsInput | number
    startedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    endedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    duration?: NullableIntFieldUpdateOperationsInput | number | null
    address?: NullableStringFieldUpdateOperationsInput | string | null
    trip?: TripUpdateOneRequiredWithoutStopsNestedInput
  }

  export type GpsStopUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    tripId?: StringFieldUpdateOperationsInput | string
    latitude?: FloatFieldUpdateOperationsInput | number
    longitude?: FloatFieldUpdateOperationsInput | number
    startedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    endedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    duration?: NullableIntFieldUpdateOperationsInput | number | null
    address?: NullableStringFieldUpdateOperationsInput | string | null
  }

  export type GpsStopCreateManyInput = {
    id?: string
    tripId: string
    latitude: number
    longitude: number
    startedAt: Date | string
    endedAt?: Date | string | null
    duration?: number | null
    address?: string | null
  }

  export type GpsStopUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    latitude?: FloatFieldUpdateOperationsInput | number
    longitude?: FloatFieldUpdateOperationsInput | number
    startedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    endedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    duration?: NullableIntFieldUpdateOperationsInput | number | null
    address?: NullableStringFieldUpdateOperationsInput | string | null
  }

  export type GpsStopUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    tripId?: StringFieldUpdateOperationsInput | string
    latitude?: FloatFieldUpdateOperationsInput | number
    longitude?: FloatFieldUpdateOperationsInput | number
    startedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    endedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    duration?: NullableIntFieldUpdateOperationsInput | number | null
    address?: NullableStringFieldUpdateOperationsInput | string | null
  }

  export type NotificationCreateInput = {
    id?: string
    type: $Enums.NotificationType
    title: string
    body: string
    data?: NullableJsonNullValueInput | InputJsonValue
    read?: boolean
    sentAt?: Date | string
    user: UserCreateNestedOneWithoutNotificationsInput
  }

  export type NotificationUncheckedCreateInput = {
    id?: string
    userId: string
    type: $Enums.NotificationType
    title: string
    body: string
    data?: NullableJsonNullValueInput | InputJsonValue
    read?: boolean
    sentAt?: Date | string
  }

  export type NotificationUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    type?: EnumNotificationTypeFieldUpdateOperationsInput | $Enums.NotificationType
    title?: StringFieldUpdateOperationsInput | string
    body?: StringFieldUpdateOperationsInput | string
    data?: NullableJsonNullValueInput | InputJsonValue
    read?: BoolFieldUpdateOperationsInput | boolean
    sentAt?: DateTimeFieldUpdateOperationsInput | Date | string
    user?: UserUpdateOneRequiredWithoutNotificationsNestedInput
  }

  export type NotificationUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    type?: EnumNotificationTypeFieldUpdateOperationsInput | $Enums.NotificationType
    title?: StringFieldUpdateOperationsInput | string
    body?: StringFieldUpdateOperationsInput | string
    data?: NullableJsonNullValueInput | InputJsonValue
    read?: BoolFieldUpdateOperationsInput | boolean
    sentAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type NotificationCreateManyInput = {
    id?: string
    userId: string
    type: $Enums.NotificationType
    title: string
    body: string
    data?: NullableJsonNullValueInput | InputJsonValue
    read?: boolean
    sentAt?: Date | string
  }

  export type NotificationUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    type?: EnumNotificationTypeFieldUpdateOperationsInput | $Enums.NotificationType
    title?: StringFieldUpdateOperationsInput | string
    body?: StringFieldUpdateOperationsInput | string
    data?: NullableJsonNullValueInput | InputJsonValue
    read?: BoolFieldUpdateOperationsInput | boolean
    sentAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type NotificationUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    type?: EnumNotificationTypeFieldUpdateOperationsInput | $Enums.NotificationType
    title?: StringFieldUpdateOperationsInput | string
    body?: StringFieldUpdateOperationsInput | string
    data?: NullableJsonNullValueInput | InputJsonValue
    read?: BoolFieldUpdateOperationsInput | boolean
    sentAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type SystemConfigCreateInput = {
    id?: string
    key: string
    value: JsonNullValueInput | InputJsonValue
    updatedAt?: Date | string
  }

  export type SystemConfigUncheckedCreateInput = {
    id?: string
    key: string
    value: JsonNullValueInput | InputJsonValue
    updatedAt?: Date | string
  }

  export type SystemConfigUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    key?: StringFieldUpdateOperationsInput | string
    value?: JsonNullValueInput | InputJsonValue
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type SystemConfigUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    key?: StringFieldUpdateOperationsInput | string
    value?: JsonNullValueInput | InputJsonValue
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type SystemConfigCreateManyInput = {
    id?: string
    key: string
    value: JsonNullValueInput | InputJsonValue
    updatedAt?: Date | string
  }

  export type SystemConfigUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    key?: StringFieldUpdateOperationsInput | string
    value?: JsonNullValueInput | InputJsonValue
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type SystemConfigUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    key?: StringFieldUpdateOperationsInput | string
    value?: JsonNullValueInput | InputJsonValue
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type DailySummaryCreateInput = {
    id?: string
    userId: string
    date: Date | string
    totalDistance?: number
    travelTime?: number
    meetingTime?: number
    idleTime?: number
    tripsCompleted?: number
    productivityScore?: number | null
    createdAt?: Date | string
    updatedAt?: Date | string
  }

  export type DailySummaryUncheckedCreateInput = {
    id?: string
    userId: string
    date: Date | string
    totalDistance?: number
    travelTime?: number
    meetingTime?: number
    idleTime?: number
    tripsCompleted?: number
    productivityScore?: number | null
    createdAt?: Date | string
    updatedAt?: Date | string
  }

  export type DailySummaryUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    date?: DateTimeFieldUpdateOperationsInput | Date | string
    totalDistance?: FloatFieldUpdateOperationsInput | number
    travelTime?: IntFieldUpdateOperationsInput | number
    meetingTime?: IntFieldUpdateOperationsInput | number
    idleTime?: IntFieldUpdateOperationsInput | number
    tripsCompleted?: IntFieldUpdateOperationsInput | number
    productivityScore?: NullableFloatFieldUpdateOperationsInput | number | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type DailySummaryUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    date?: DateTimeFieldUpdateOperationsInput | Date | string
    totalDistance?: FloatFieldUpdateOperationsInput | number
    travelTime?: IntFieldUpdateOperationsInput | number
    meetingTime?: IntFieldUpdateOperationsInput | number
    idleTime?: IntFieldUpdateOperationsInput | number
    tripsCompleted?: IntFieldUpdateOperationsInput | number
    productivityScore?: NullableFloatFieldUpdateOperationsInput | number | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type DailySummaryCreateManyInput = {
    id?: string
    userId: string
    date: Date | string
    totalDistance?: number
    travelTime?: number
    meetingTime?: number
    idleTime?: number
    tripsCompleted?: number
    productivityScore?: number | null
    createdAt?: Date | string
    updatedAt?: Date | string
  }

  export type DailySummaryUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    date?: DateTimeFieldUpdateOperationsInput | Date | string
    totalDistance?: FloatFieldUpdateOperationsInput | number
    travelTime?: IntFieldUpdateOperationsInput | number
    meetingTime?: IntFieldUpdateOperationsInput | number
    idleTime?: IntFieldUpdateOperationsInput | number
    tripsCompleted?: IntFieldUpdateOperationsInput | number
    productivityScore?: NullableFloatFieldUpdateOperationsInput | number | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type DailySummaryUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    date?: DateTimeFieldUpdateOperationsInput | Date | string
    totalDistance?: FloatFieldUpdateOperationsInput | number
    travelTime?: IntFieldUpdateOperationsInput | number
    meetingTime?: IntFieldUpdateOperationsInput | number
    idleTime?: IntFieldUpdateOperationsInput | number
    tripsCompleted?: IntFieldUpdateOperationsInput | number
    productivityScore?: NullableFloatFieldUpdateOperationsInput | number | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type MonthlySummaryCreateInput = {
    id?: string
    userId: string
    year: number
    month: number
    totalDistance?: number
    travelTime?: number
    meetingTime?: number
    idleTime?: number
    tripsCompleted?: number
    productivityScore?: number | null
  }

  export type MonthlySummaryUncheckedCreateInput = {
    id?: string
    userId: string
    year: number
    month: number
    totalDistance?: number
    travelTime?: number
    meetingTime?: number
    idleTime?: number
    tripsCompleted?: number
    productivityScore?: number | null
  }

  export type MonthlySummaryUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    year?: IntFieldUpdateOperationsInput | number
    month?: IntFieldUpdateOperationsInput | number
    totalDistance?: FloatFieldUpdateOperationsInput | number
    travelTime?: IntFieldUpdateOperationsInput | number
    meetingTime?: IntFieldUpdateOperationsInput | number
    idleTime?: IntFieldUpdateOperationsInput | number
    tripsCompleted?: IntFieldUpdateOperationsInput | number
    productivityScore?: NullableFloatFieldUpdateOperationsInput | number | null
  }

  export type MonthlySummaryUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    year?: IntFieldUpdateOperationsInput | number
    month?: IntFieldUpdateOperationsInput | number
    totalDistance?: FloatFieldUpdateOperationsInput | number
    travelTime?: IntFieldUpdateOperationsInput | number
    meetingTime?: IntFieldUpdateOperationsInput | number
    idleTime?: IntFieldUpdateOperationsInput | number
    tripsCompleted?: IntFieldUpdateOperationsInput | number
    productivityScore?: NullableFloatFieldUpdateOperationsInput | number | null
  }

  export type MonthlySummaryCreateManyInput = {
    id?: string
    userId: string
    year: number
    month: number
    totalDistance?: number
    travelTime?: number
    meetingTime?: number
    idleTime?: number
    tripsCompleted?: number
    productivityScore?: number | null
  }

  export type MonthlySummaryUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    year?: IntFieldUpdateOperationsInput | number
    month?: IntFieldUpdateOperationsInput | number
    totalDistance?: FloatFieldUpdateOperationsInput | number
    travelTime?: IntFieldUpdateOperationsInput | number
    meetingTime?: IntFieldUpdateOperationsInput | number
    idleTime?: IntFieldUpdateOperationsInput | number
    tripsCompleted?: IntFieldUpdateOperationsInput | number
    productivityScore?: NullableFloatFieldUpdateOperationsInput | number | null
  }

  export type MonthlySummaryUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    year?: IntFieldUpdateOperationsInput | number
    month?: IntFieldUpdateOperationsInput | number
    totalDistance?: FloatFieldUpdateOperationsInput | number
    travelTime?: IntFieldUpdateOperationsInput | number
    meetingTime?: IntFieldUpdateOperationsInput | number
    idleTime?: IntFieldUpdateOperationsInput | number
    tripsCompleted?: IntFieldUpdateOperationsInput | number
    productivityScore?: NullableFloatFieldUpdateOperationsInput | number | null
  }

  export type StringFilter<$PrismaModel = never> = {
    equals?: string | StringFieldRefInput<$PrismaModel>
    in?: string[]
    notIn?: string[]
    lt?: string | StringFieldRefInput<$PrismaModel>
    lte?: string | StringFieldRefInput<$PrismaModel>
    gt?: string | StringFieldRefInput<$PrismaModel>
    gte?: string | StringFieldRefInput<$PrismaModel>
    contains?: string | StringFieldRefInput<$PrismaModel>
    startsWith?: string | StringFieldRefInput<$PrismaModel>
    endsWith?: string | StringFieldRefInput<$PrismaModel>
    not?: NestedStringFilter<$PrismaModel> | string
  }

  export type StringNullableFilter<$PrismaModel = never> = {
    equals?: string | StringFieldRefInput<$PrismaModel> | null
    in?: string[] | null
    notIn?: string[] | null
    lt?: string | StringFieldRefInput<$PrismaModel>
    lte?: string | StringFieldRefInput<$PrismaModel>
    gt?: string | StringFieldRefInput<$PrismaModel>
    gte?: string | StringFieldRefInput<$PrismaModel>
    contains?: string | StringFieldRefInput<$PrismaModel>
    startsWith?: string | StringFieldRefInput<$PrismaModel>
    endsWith?: string | StringFieldRefInput<$PrismaModel>
    not?: NestedStringNullableFilter<$PrismaModel> | string | null
  }

  export type EnumUserRoleFilter<$PrismaModel = never> = {
    equals?: $Enums.UserRole | EnumUserRoleFieldRefInput<$PrismaModel>
    in?: $Enums.UserRole[]
    notIn?: $Enums.UserRole[]
    not?: NestedEnumUserRoleFilter<$PrismaModel> | $Enums.UserRole
  }

  export type EnumUserStatusFilter<$PrismaModel = never> = {
    equals?: $Enums.UserStatus | EnumUserStatusFieldRefInput<$PrismaModel>
    in?: $Enums.UserStatus[]
    notIn?: $Enums.UserStatus[]
    not?: NestedEnumUserStatusFilter<$PrismaModel> | $Enums.UserStatus
  }

  export type BoolFilter<$PrismaModel = never> = {
    equals?: boolean | BooleanFieldRefInput<$PrismaModel>
    not?: NestedBoolFilter<$PrismaModel> | boolean
  }

  export type EnumEmployeePresenceFilter<$PrismaModel = never> = {
    equals?: $Enums.EmployeePresence | EnumEmployeePresenceFieldRefInput<$PrismaModel>
    in?: $Enums.EmployeePresence[]
    notIn?: $Enums.EmployeePresence[]
    not?: NestedEnumEmployeePresenceFilter<$PrismaModel> | $Enums.EmployeePresence
  }

  export type DateTimeNullableFilter<$PrismaModel = never> = {
    equals?: Date | string | DateTimeFieldRefInput<$PrismaModel> | null
    in?: Date[] | string[] | null
    notIn?: Date[] | string[] | null
    lt?: Date | string | DateTimeFieldRefInput<$PrismaModel>
    lte?: Date | string | DateTimeFieldRefInput<$PrismaModel>
    gt?: Date | string | DateTimeFieldRefInput<$PrismaModel>
    gte?: Date | string | DateTimeFieldRefInput<$PrismaModel>
    not?: NestedDateTimeNullableFilter<$PrismaModel> | Date | string | null
  }

  export type DateTimeFilter<$PrismaModel = never> = {
    equals?: Date | string | DateTimeFieldRefInput<$PrismaModel>
    in?: Date[] | string[]
    notIn?: Date[] | string[]
    lt?: Date | string | DateTimeFieldRefInput<$PrismaModel>
    lte?: Date | string | DateTimeFieldRefInput<$PrismaModel>
    gt?: Date | string | DateTimeFieldRefInput<$PrismaModel>
    gte?: Date | string | DateTimeFieldRefInput<$PrismaModel>
    not?: NestedDateTimeFilter<$PrismaModel> | Date | string
  }

  export type UserNullableScalarRelationFilter = {
    is?: UserWhereInput | null
    isNot?: UserWhereInput | null
  }

  export type UserListRelationFilter = {
    every?: UserWhereInput
    some?: UserWhereInput
    none?: UserWhereInput
  }

  export type RefreshTokenListRelationFilter = {
    every?: RefreshTokenWhereInput
    some?: RefreshTokenWhereInput
    none?: RefreshTokenWhereInput
  }

  export type TripListRelationFilter = {
    every?: TripWhereInput
    some?: TripWhereInput
    none?: TripWhereInput
  }

  export type GpsPointListRelationFilter = {
    every?: GpsPointWhereInput
    some?: GpsPointWhereInput
    none?: GpsPointWhereInput
  }

  export type AuditLogListRelationFilter = {
    every?: AuditLogWhereInput
    some?: AuditLogWhereInput
    none?: AuditLogWhereInput
  }

  export type NotificationListRelationFilter = {
    every?: NotificationWhereInput
    some?: NotificationWhereInput
    none?: NotificationWhereInput
  }

  export type SortOrderInput = {
    sort: SortOrder
    nulls?: NullsOrder
  }

  export type UserOrderByRelationAggregateInput = {
    _count?: SortOrder
  }

  export type RefreshTokenOrderByRelationAggregateInput = {
    _count?: SortOrder
  }

  export type TripOrderByRelationAggregateInput = {
    _count?: SortOrder
  }

  export type GpsPointOrderByRelationAggregateInput = {
    _count?: SortOrder
  }

  export type AuditLogOrderByRelationAggregateInput = {
    _count?: SortOrder
  }

  export type NotificationOrderByRelationAggregateInput = {
    _count?: SortOrder
  }

  export type UserCountOrderByAggregateInput = {
    id?: SortOrder
    uid?: SortOrder
    email?: SortOrder
    passwordHash?: SortOrder
    fullName?: SortOrder
    employeeCode?: SortOrder
    mobileNumber?: SortOrder
    sittingLocation?: SortOrder
    reportingManagerId?: SortOrder
    role?: SortOrder
    deviceId?: SortOrder
    profileImage?: SortOrder
    status?: SortOrder
    fcmToken?: SortOrder
    isRooted?: SortOrder
    presence?: SortOrder
    lastSeenAt?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
  }

  export type UserMaxOrderByAggregateInput = {
    id?: SortOrder
    uid?: SortOrder
    email?: SortOrder
    passwordHash?: SortOrder
    fullName?: SortOrder
    employeeCode?: SortOrder
    mobileNumber?: SortOrder
    sittingLocation?: SortOrder
    reportingManagerId?: SortOrder
    role?: SortOrder
    deviceId?: SortOrder
    profileImage?: SortOrder
    status?: SortOrder
    fcmToken?: SortOrder
    isRooted?: SortOrder
    presence?: SortOrder
    lastSeenAt?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
  }

  export type UserMinOrderByAggregateInput = {
    id?: SortOrder
    uid?: SortOrder
    email?: SortOrder
    passwordHash?: SortOrder
    fullName?: SortOrder
    employeeCode?: SortOrder
    mobileNumber?: SortOrder
    sittingLocation?: SortOrder
    reportingManagerId?: SortOrder
    role?: SortOrder
    deviceId?: SortOrder
    profileImage?: SortOrder
    status?: SortOrder
    fcmToken?: SortOrder
    isRooted?: SortOrder
    presence?: SortOrder
    lastSeenAt?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
  }

  export type StringWithAggregatesFilter<$PrismaModel = never> = {
    equals?: string | StringFieldRefInput<$PrismaModel>
    in?: string[]
    notIn?: string[]
    lt?: string | StringFieldRefInput<$PrismaModel>
    lte?: string | StringFieldRefInput<$PrismaModel>
    gt?: string | StringFieldRefInput<$PrismaModel>
    gte?: string | StringFieldRefInput<$PrismaModel>
    contains?: string | StringFieldRefInput<$PrismaModel>
    startsWith?: string | StringFieldRefInput<$PrismaModel>
    endsWith?: string | StringFieldRefInput<$PrismaModel>
    not?: NestedStringWithAggregatesFilter<$PrismaModel> | string
    _count?: NestedIntFilter<$PrismaModel>
    _min?: NestedStringFilter<$PrismaModel>
    _max?: NestedStringFilter<$PrismaModel>
  }

  export type StringNullableWithAggregatesFilter<$PrismaModel = never> = {
    equals?: string | StringFieldRefInput<$PrismaModel> | null
    in?: string[] | null
    notIn?: string[] | null
    lt?: string | StringFieldRefInput<$PrismaModel>
    lte?: string | StringFieldRefInput<$PrismaModel>
    gt?: string | StringFieldRefInput<$PrismaModel>
    gte?: string | StringFieldRefInput<$PrismaModel>
    contains?: string | StringFieldRefInput<$PrismaModel>
    startsWith?: string | StringFieldRefInput<$PrismaModel>
    endsWith?: string | StringFieldRefInput<$PrismaModel>
    not?: NestedStringNullableWithAggregatesFilter<$PrismaModel> | string | null
    _count?: NestedIntNullableFilter<$PrismaModel>
    _min?: NestedStringNullableFilter<$PrismaModel>
    _max?: NestedStringNullableFilter<$PrismaModel>
  }

  export type EnumUserRoleWithAggregatesFilter<$PrismaModel = never> = {
    equals?: $Enums.UserRole | EnumUserRoleFieldRefInput<$PrismaModel>
    in?: $Enums.UserRole[]
    notIn?: $Enums.UserRole[]
    not?: NestedEnumUserRoleWithAggregatesFilter<$PrismaModel> | $Enums.UserRole
    _count?: NestedIntFilter<$PrismaModel>
    _min?: NestedEnumUserRoleFilter<$PrismaModel>
    _max?: NestedEnumUserRoleFilter<$PrismaModel>
  }

  export type EnumUserStatusWithAggregatesFilter<$PrismaModel = never> = {
    equals?: $Enums.UserStatus | EnumUserStatusFieldRefInput<$PrismaModel>
    in?: $Enums.UserStatus[]
    notIn?: $Enums.UserStatus[]
    not?: NestedEnumUserStatusWithAggregatesFilter<$PrismaModel> | $Enums.UserStatus
    _count?: NestedIntFilter<$PrismaModel>
    _min?: NestedEnumUserStatusFilter<$PrismaModel>
    _max?: NestedEnumUserStatusFilter<$PrismaModel>
  }

  export type BoolWithAggregatesFilter<$PrismaModel = never> = {
    equals?: boolean | BooleanFieldRefInput<$PrismaModel>
    not?: NestedBoolWithAggregatesFilter<$PrismaModel> | boolean
    _count?: NestedIntFilter<$PrismaModel>
    _min?: NestedBoolFilter<$PrismaModel>
    _max?: NestedBoolFilter<$PrismaModel>
  }

  export type EnumEmployeePresenceWithAggregatesFilter<$PrismaModel = never> = {
    equals?: $Enums.EmployeePresence | EnumEmployeePresenceFieldRefInput<$PrismaModel>
    in?: $Enums.EmployeePresence[]
    notIn?: $Enums.EmployeePresence[]
    not?: NestedEnumEmployeePresenceWithAggregatesFilter<$PrismaModel> | $Enums.EmployeePresence
    _count?: NestedIntFilter<$PrismaModel>
    _min?: NestedEnumEmployeePresenceFilter<$PrismaModel>
    _max?: NestedEnumEmployeePresenceFilter<$PrismaModel>
  }

  export type DateTimeNullableWithAggregatesFilter<$PrismaModel = never> = {
    equals?: Date | string | DateTimeFieldRefInput<$PrismaModel> | null
    in?: Date[] | string[] | null
    notIn?: Date[] | string[] | null
    lt?: Date | string | DateTimeFieldRefInput<$PrismaModel>
    lte?: Date | string | DateTimeFieldRefInput<$PrismaModel>
    gt?: Date | string | DateTimeFieldRefInput<$PrismaModel>
    gte?: Date | string | DateTimeFieldRefInput<$PrismaModel>
    not?: NestedDateTimeNullableWithAggregatesFilter<$PrismaModel> | Date | string | null
    _count?: NestedIntNullableFilter<$PrismaModel>
    _min?: NestedDateTimeNullableFilter<$PrismaModel>
    _max?: NestedDateTimeNullableFilter<$PrismaModel>
  }

  export type DateTimeWithAggregatesFilter<$PrismaModel = never> = {
    equals?: Date | string | DateTimeFieldRefInput<$PrismaModel>
    in?: Date[] | string[]
    notIn?: Date[] | string[]
    lt?: Date | string | DateTimeFieldRefInput<$PrismaModel>
    lte?: Date | string | DateTimeFieldRefInput<$PrismaModel>
    gt?: Date | string | DateTimeFieldRefInput<$PrismaModel>
    gte?: Date | string | DateTimeFieldRefInput<$PrismaModel>
    not?: NestedDateTimeWithAggregatesFilter<$PrismaModel> | Date | string
    _count?: NestedIntFilter<$PrismaModel>
    _min?: NestedDateTimeFilter<$PrismaModel>
    _max?: NestedDateTimeFilter<$PrismaModel>
  }

  export type UserScalarRelationFilter = {
    is?: UserWhereInput
    isNot?: UserWhereInput
  }

  export type RefreshTokenCountOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    tokenHash?: SortOrder
    deviceId?: SortOrder
    expiresAt?: SortOrder
    createdAt?: SortOrder
  }

  export type RefreshTokenMaxOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    tokenHash?: SortOrder
    deviceId?: SortOrder
    expiresAt?: SortOrder
    createdAt?: SortOrder
  }

  export type RefreshTokenMinOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    tokenHash?: SortOrder
    deviceId?: SortOrder
    expiresAt?: SortOrder
    createdAt?: SortOrder
  }

  export type PasswordResetTokenCountOrderByAggregateInput = {
    id?: SortOrder
    email?: SortOrder
    tokenHash?: SortOrder
    expiresAt?: SortOrder
    consumed?: SortOrder
    createdAt?: SortOrder
  }

  export type PasswordResetTokenMaxOrderByAggregateInput = {
    id?: SortOrder
    email?: SortOrder
    tokenHash?: SortOrder
    expiresAt?: SortOrder
    consumed?: SortOrder
    createdAt?: SortOrder
  }

  export type PasswordResetTokenMinOrderByAggregateInput = {
    id?: SortOrder
    email?: SortOrder
    tokenHash?: SortOrder
    expiresAt?: SortOrder
    consumed?: SortOrder
    createdAt?: SortOrder
  }
  export type JsonNullableFilter<$PrismaModel = never> =
    | PatchUndefined<
        Either<Required<JsonNullableFilterBase<$PrismaModel>>, Exclude<keyof Required<JsonNullableFilterBase<$PrismaModel>>, 'path'>>,
        Required<JsonNullableFilterBase<$PrismaModel>>
      >
    | OptionalFlat<Omit<Required<JsonNullableFilterBase<$PrismaModel>>, 'path'>>

  export type JsonNullableFilterBase<$PrismaModel = never> = {
    equals?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | JsonNullValueFilter
    path?: string
    mode?: QueryMode | EnumQueryModeFieldRefInput<$PrismaModel>
    string_contains?: string | StringFieldRefInput<$PrismaModel>
    string_starts_with?: string | StringFieldRefInput<$PrismaModel>
    string_ends_with?: string | StringFieldRefInput<$PrismaModel>
    array_starts_with?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | null
    array_ends_with?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | null
    not?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | JsonNullValueFilter
  }

  export type AuditLogCountOrderByAggregateInput = {
    id?: SortOrder
    actorUserId?: SortOrder
    actorEmail?: SortOrder
    action?: SortOrder
    targetType?: SortOrder
    targetId?: SortOrder
    metadata?: SortOrder
    ipAddress?: SortOrder
    userAgent?: SortOrder
    createdAt?: SortOrder
  }

  export type AuditLogMaxOrderByAggregateInput = {
    id?: SortOrder
    actorUserId?: SortOrder
    actorEmail?: SortOrder
    action?: SortOrder
    targetType?: SortOrder
    targetId?: SortOrder
    ipAddress?: SortOrder
    userAgent?: SortOrder
    createdAt?: SortOrder
  }

  export type AuditLogMinOrderByAggregateInput = {
    id?: SortOrder
    actorUserId?: SortOrder
    actorEmail?: SortOrder
    action?: SortOrder
    targetType?: SortOrder
    targetId?: SortOrder
    ipAddress?: SortOrder
    userAgent?: SortOrder
    createdAt?: SortOrder
  }
  export type JsonNullableWithAggregatesFilter<$PrismaModel = never> =
    | PatchUndefined<
        Either<Required<JsonNullableWithAggregatesFilterBase<$PrismaModel>>, Exclude<keyof Required<JsonNullableWithAggregatesFilterBase<$PrismaModel>>, 'path'>>,
        Required<JsonNullableWithAggregatesFilterBase<$PrismaModel>>
      >
    | OptionalFlat<Omit<Required<JsonNullableWithAggregatesFilterBase<$PrismaModel>>, 'path'>>

  export type JsonNullableWithAggregatesFilterBase<$PrismaModel = never> = {
    equals?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | JsonNullValueFilter
    path?: string
    mode?: QueryMode | EnumQueryModeFieldRefInput<$PrismaModel>
    string_contains?: string | StringFieldRefInput<$PrismaModel>
    string_starts_with?: string | StringFieldRefInput<$PrismaModel>
    string_ends_with?: string | StringFieldRefInput<$PrismaModel>
    array_starts_with?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | null
    array_ends_with?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | null
    not?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | JsonNullValueFilter
    _count?: NestedIntNullableFilter<$PrismaModel>
    _min?: NestedJsonNullableFilter<$PrismaModel>
    _max?: NestedJsonNullableFilter<$PrismaModel>
  }

  export type FloatNullableFilter<$PrismaModel = never> = {
    equals?: number | FloatFieldRefInput<$PrismaModel> | null
    in?: number[] | null
    notIn?: number[] | null
    lt?: number | FloatFieldRefInput<$PrismaModel>
    lte?: number | FloatFieldRefInput<$PrismaModel>
    gt?: number | FloatFieldRefInput<$PrismaModel>
    gte?: number | FloatFieldRefInput<$PrismaModel>
    not?: NestedFloatNullableFilter<$PrismaModel> | number | null
  }

  export type EnumVehicleTypeNullableFilter<$PrismaModel = never> = {
    equals?: $Enums.VehicleType | EnumVehicleTypeFieldRefInput<$PrismaModel> | null
    in?: $Enums.VehicleType[] | null
    notIn?: $Enums.VehicleType[] | null
    not?: NestedEnumVehicleTypeNullableFilter<$PrismaModel> | $Enums.VehicleType | null
  }

  export type EnumFuelTypeNullableFilter<$PrismaModel = never> = {
    equals?: $Enums.FuelType | EnumFuelTypeFieldRefInput<$PrismaModel> | null
    in?: $Enums.FuelType[] | null
    notIn?: $Enums.FuelType[] | null
    not?: NestedEnumFuelTypeNullableFilter<$PrismaModel> | $Enums.FuelType | null
  }

  export type EnumTripStatusFilter<$PrismaModel = never> = {
    equals?: $Enums.TripStatus | EnumTripStatusFieldRefInput<$PrismaModel>
    in?: $Enums.TripStatus[]
    notIn?: $Enums.TripStatus[]
    not?: NestedEnumTripStatusFilter<$PrismaModel> | $Enums.TripStatus
  }

  export type FloatFilter<$PrismaModel = never> = {
    equals?: number | FloatFieldRefInput<$PrismaModel>
    in?: number[]
    notIn?: number[]
    lt?: number | FloatFieldRefInput<$PrismaModel>
    lte?: number | FloatFieldRefInput<$PrismaModel>
    gt?: number | FloatFieldRefInput<$PrismaModel>
    gte?: number | FloatFieldRefInput<$PrismaModel>
    not?: NestedFloatFilter<$PrismaModel> | number
  }

  export type IntFilter<$PrismaModel = never> = {
    equals?: number | IntFieldRefInput<$PrismaModel>
    in?: number[]
    notIn?: number[]
    lt?: number | IntFieldRefInput<$PrismaModel>
    lte?: number | IntFieldRefInput<$PrismaModel>
    gt?: number | IntFieldRefInput<$PrismaModel>
    gte?: number | IntFieldRefInput<$PrismaModel>
    not?: NestedIntFilter<$PrismaModel> | number
  }

  export type PunchListRelationFilter = {
    every?: PunchWhereInput
    some?: PunchWhereInput
    none?: PunchWhereInput
  }

  export type GpsStopListRelationFilter = {
    every?: GpsStopWhereInput
    some?: GpsStopWhereInput
    none?: GpsStopWhereInput
  }

  export type PunchOrderByRelationAggregateInput = {
    _count?: SortOrder
  }

  export type GpsStopOrderByRelationAggregateInput = {
    _count?: SortOrder
  }

  export type TripCountOrderByAggregateInput = {
    id?: SortOrder
    tripId?: SortOrder
    userId?: SortOrder
    city?: SortOrder
    fromLocation?: SortOrder
    toLocation?: SortOrder
    destinationLat?: SortOrder
    destinationLng?: SortOrder
    googlePlaceId?: SortOrder
    plannedDistance?: SortOrder
    vehicleType?: SortOrder
    fuelType?: SortOrder
    purpose?: SortOrder
    notes?: SortOrder
    status?: SortOrder
    totalDistance?: SortOrder
    travelDuration?: SortOrder
    idleTime?: SortOrder
    meetingDuration?: SortOrder
    productivityScore?: SortOrder
    tripEfficiency?: SortOrder
    startedAt?: SortOrder
    arrivedAt?: SortOrder
    completedAt?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
  }

  export type TripAvgOrderByAggregateInput = {
    destinationLat?: SortOrder
    destinationLng?: SortOrder
    plannedDistance?: SortOrder
    totalDistance?: SortOrder
    travelDuration?: SortOrder
    idleTime?: SortOrder
    meetingDuration?: SortOrder
    productivityScore?: SortOrder
    tripEfficiency?: SortOrder
  }

  export type TripMaxOrderByAggregateInput = {
    id?: SortOrder
    tripId?: SortOrder
    userId?: SortOrder
    city?: SortOrder
    fromLocation?: SortOrder
    toLocation?: SortOrder
    destinationLat?: SortOrder
    destinationLng?: SortOrder
    googlePlaceId?: SortOrder
    plannedDistance?: SortOrder
    vehicleType?: SortOrder
    fuelType?: SortOrder
    purpose?: SortOrder
    notes?: SortOrder
    status?: SortOrder
    totalDistance?: SortOrder
    travelDuration?: SortOrder
    idleTime?: SortOrder
    meetingDuration?: SortOrder
    productivityScore?: SortOrder
    tripEfficiency?: SortOrder
    startedAt?: SortOrder
    arrivedAt?: SortOrder
    completedAt?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
  }

  export type TripMinOrderByAggregateInput = {
    id?: SortOrder
    tripId?: SortOrder
    userId?: SortOrder
    city?: SortOrder
    fromLocation?: SortOrder
    toLocation?: SortOrder
    destinationLat?: SortOrder
    destinationLng?: SortOrder
    googlePlaceId?: SortOrder
    plannedDistance?: SortOrder
    vehicleType?: SortOrder
    fuelType?: SortOrder
    purpose?: SortOrder
    notes?: SortOrder
    status?: SortOrder
    totalDistance?: SortOrder
    travelDuration?: SortOrder
    idleTime?: SortOrder
    meetingDuration?: SortOrder
    productivityScore?: SortOrder
    tripEfficiency?: SortOrder
    startedAt?: SortOrder
    arrivedAt?: SortOrder
    completedAt?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
  }

  export type TripSumOrderByAggregateInput = {
    destinationLat?: SortOrder
    destinationLng?: SortOrder
    plannedDistance?: SortOrder
    totalDistance?: SortOrder
    travelDuration?: SortOrder
    idleTime?: SortOrder
    meetingDuration?: SortOrder
    productivityScore?: SortOrder
    tripEfficiency?: SortOrder
  }

  export type FloatNullableWithAggregatesFilter<$PrismaModel = never> = {
    equals?: number | FloatFieldRefInput<$PrismaModel> | null
    in?: number[] | null
    notIn?: number[] | null
    lt?: number | FloatFieldRefInput<$PrismaModel>
    lte?: number | FloatFieldRefInput<$PrismaModel>
    gt?: number | FloatFieldRefInput<$PrismaModel>
    gte?: number | FloatFieldRefInput<$PrismaModel>
    not?: NestedFloatNullableWithAggregatesFilter<$PrismaModel> | number | null
    _count?: NestedIntNullableFilter<$PrismaModel>
    _avg?: NestedFloatNullableFilter<$PrismaModel>
    _sum?: NestedFloatNullableFilter<$PrismaModel>
    _min?: NestedFloatNullableFilter<$PrismaModel>
    _max?: NestedFloatNullableFilter<$PrismaModel>
  }

  export type EnumVehicleTypeNullableWithAggregatesFilter<$PrismaModel = never> = {
    equals?: $Enums.VehicleType | EnumVehicleTypeFieldRefInput<$PrismaModel> | null
    in?: $Enums.VehicleType[] | null
    notIn?: $Enums.VehicleType[] | null
    not?: NestedEnumVehicleTypeNullableWithAggregatesFilter<$PrismaModel> | $Enums.VehicleType | null
    _count?: NestedIntNullableFilter<$PrismaModel>
    _min?: NestedEnumVehicleTypeNullableFilter<$PrismaModel>
    _max?: NestedEnumVehicleTypeNullableFilter<$PrismaModel>
  }

  export type EnumFuelTypeNullableWithAggregatesFilter<$PrismaModel = never> = {
    equals?: $Enums.FuelType | EnumFuelTypeFieldRefInput<$PrismaModel> | null
    in?: $Enums.FuelType[] | null
    notIn?: $Enums.FuelType[] | null
    not?: NestedEnumFuelTypeNullableWithAggregatesFilter<$PrismaModel> | $Enums.FuelType | null
    _count?: NestedIntNullableFilter<$PrismaModel>
    _min?: NestedEnumFuelTypeNullableFilter<$PrismaModel>
    _max?: NestedEnumFuelTypeNullableFilter<$PrismaModel>
  }

  export type EnumTripStatusWithAggregatesFilter<$PrismaModel = never> = {
    equals?: $Enums.TripStatus | EnumTripStatusFieldRefInput<$PrismaModel>
    in?: $Enums.TripStatus[]
    notIn?: $Enums.TripStatus[]
    not?: NestedEnumTripStatusWithAggregatesFilter<$PrismaModel> | $Enums.TripStatus
    _count?: NestedIntFilter<$PrismaModel>
    _min?: NestedEnumTripStatusFilter<$PrismaModel>
    _max?: NestedEnumTripStatusFilter<$PrismaModel>
  }

  export type FloatWithAggregatesFilter<$PrismaModel = never> = {
    equals?: number | FloatFieldRefInput<$PrismaModel>
    in?: number[]
    notIn?: number[]
    lt?: number | FloatFieldRefInput<$PrismaModel>
    lte?: number | FloatFieldRefInput<$PrismaModel>
    gt?: number | FloatFieldRefInput<$PrismaModel>
    gte?: number | FloatFieldRefInput<$PrismaModel>
    not?: NestedFloatWithAggregatesFilter<$PrismaModel> | number
    _count?: NestedIntFilter<$PrismaModel>
    _avg?: NestedFloatFilter<$PrismaModel>
    _sum?: NestedFloatFilter<$PrismaModel>
    _min?: NestedFloatFilter<$PrismaModel>
    _max?: NestedFloatFilter<$PrismaModel>
  }

  export type IntWithAggregatesFilter<$PrismaModel = never> = {
    equals?: number | IntFieldRefInput<$PrismaModel>
    in?: number[]
    notIn?: number[]
    lt?: number | IntFieldRefInput<$PrismaModel>
    lte?: number | IntFieldRefInput<$PrismaModel>
    gt?: number | IntFieldRefInput<$PrismaModel>
    gte?: number | IntFieldRefInput<$PrismaModel>
    not?: NestedIntWithAggregatesFilter<$PrismaModel> | number
    _count?: NestedIntFilter<$PrismaModel>
    _avg?: NestedFloatFilter<$PrismaModel>
    _sum?: NestedIntFilter<$PrismaModel>
    _min?: NestedIntFilter<$PrismaModel>
    _max?: NestedIntFilter<$PrismaModel>
  }

  export type EnumPunchTypeFilter<$PrismaModel = never> = {
    equals?: $Enums.PunchType | EnumPunchTypeFieldRefInput<$PrismaModel>
    in?: $Enums.PunchType[]
    notIn?: $Enums.PunchType[]
    not?: NestedEnumPunchTypeFilter<$PrismaModel> | $Enums.PunchType
  }

  export type EnumLeadTypeNullableFilter<$PrismaModel = never> = {
    equals?: $Enums.LeadType | EnumLeadTypeFieldRefInput<$PrismaModel> | null
    in?: $Enums.LeadType[] | null
    notIn?: $Enums.LeadType[] | null
    not?: NestedEnumLeadTypeNullableFilter<$PrismaModel> | $Enums.LeadType | null
  }

  export type TripScalarRelationFilter = {
    is?: TripWhereInput
    isNot?: TripWhereInput
  }

  export type PunchCountOrderByAggregateInput = {
    id?: SortOrder
    tripId?: SortOrder
    type?: SortOrder
    timestamp?: SortOrder
    latitude?: SortOrder
    longitude?: SortOrder
    address?: SortOrder
    batteryPercent?: SortOrder
    gpsAccuracy?: SortOrder
    speed?: SortOrder
    isMockLocation?: SortOrder
    meetingSummary?: SortOrder
    leadType?: SortOrder
    customerNotes?: SortOrder
    createdAt?: SortOrder
  }

  export type PunchAvgOrderByAggregateInput = {
    latitude?: SortOrder
    longitude?: SortOrder
    batteryPercent?: SortOrder
    gpsAccuracy?: SortOrder
    speed?: SortOrder
  }

  export type PunchMaxOrderByAggregateInput = {
    id?: SortOrder
    tripId?: SortOrder
    type?: SortOrder
    timestamp?: SortOrder
    latitude?: SortOrder
    longitude?: SortOrder
    address?: SortOrder
    batteryPercent?: SortOrder
    gpsAccuracy?: SortOrder
    speed?: SortOrder
    isMockLocation?: SortOrder
    meetingSummary?: SortOrder
    leadType?: SortOrder
    customerNotes?: SortOrder
    createdAt?: SortOrder
  }

  export type PunchMinOrderByAggregateInput = {
    id?: SortOrder
    tripId?: SortOrder
    type?: SortOrder
    timestamp?: SortOrder
    latitude?: SortOrder
    longitude?: SortOrder
    address?: SortOrder
    batteryPercent?: SortOrder
    gpsAccuracy?: SortOrder
    speed?: SortOrder
    isMockLocation?: SortOrder
    meetingSummary?: SortOrder
    leadType?: SortOrder
    customerNotes?: SortOrder
    createdAt?: SortOrder
  }

  export type PunchSumOrderByAggregateInput = {
    latitude?: SortOrder
    longitude?: SortOrder
    batteryPercent?: SortOrder
    gpsAccuracy?: SortOrder
    speed?: SortOrder
  }

  export type EnumPunchTypeWithAggregatesFilter<$PrismaModel = never> = {
    equals?: $Enums.PunchType | EnumPunchTypeFieldRefInput<$PrismaModel>
    in?: $Enums.PunchType[]
    notIn?: $Enums.PunchType[]
    not?: NestedEnumPunchTypeWithAggregatesFilter<$PrismaModel> | $Enums.PunchType
    _count?: NestedIntFilter<$PrismaModel>
    _min?: NestedEnumPunchTypeFilter<$PrismaModel>
    _max?: NestedEnumPunchTypeFilter<$PrismaModel>
  }

  export type EnumLeadTypeNullableWithAggregatesFilter<$PrismaModel = never> = {
    equals?: $Enums.LeadType | EnumLeadTypeFieldRefInput<$PrismaModel> | null
    in?: $Enums.LeadType[] | null
    notIn?: $Enums.LeadType[] | null
    not?: NestedEnumLeadTypeNullableWithAggregatesFilter<$PrismaModel> | $Enums.LeadType | null
    _count?: NestedIntNullableFilter<$PrismaModel>
    _min?: NestedEnumLeadTypeNullableFilter<$PrismaModel>
    _max?: NestedEnumLeadTypeNullableFilter<$PrismaModel>
  }

  export type TripNullableScalarRelationFilter = {
    is?: TripWhereInput | null
    isNot?: TripWhereInput | null
  }

  export type GpsPointTripIdClientPointIdCompoundUniqueInput = {
    tripId: string
    clientPointId: string
  }

  export type GpsPointCountOrderByAggregateInput = {
    id?: SortOrder
    tripId?: SortOrder
    userId?: SortOrder
    clientPointId?: SortOrder
    latitude?: SortOrder
    longitude?: SortOrder
    accuracy?: SortOrder
    speed?: SortOrder
    bearing?: SortOrder
    batteryLevel?: SortOrder
    timestamp?: SortOrder
    isSmoothed?: SortOrder
    createdAt?: SortOrder
  }

  export type GpsPointAvgOrderByAggregateInput = {
    latitude?: SortOrder
    longitude?: SortOrder
    accuracy?: SortOrder
    speed?: SortOrder
    bearing?: SortOrder
    batteryLevel?: SortOrder
  }

  export type GpsPointMaxOrderByAggregateInput = {
    id?: SortOrder
    tripId?: SortOrder
    userId?: SortOrder
    clientPointId?: SortOrder
    latitude?: SortOrder
    longitude?: SortOrder
    accuracy?: SortOrder
    speed?: SortOrder
    bearing?: SortOrder
    batteryLevel?: SortOrder
    timestamp?: SortOrder
    isSmoothed?: SortOrder
    createdAt?: SortOrder
  }

  export type GpsPointMinOrderByAggregateInput = {
    id?: SortOrder
    tripId?: SortOrder
    userId?: SortOrder
    clientPointId?: SortOrder
    latitude?: SortOrder
    longitude?: SortOrder
    accuracy?: SortOrder
    speed?: SortOrder
    bearing?: SortOrder
    batteryLevel?: SortOrder
    timestamp?: SortOrder
    isSmoothed?: SortOrder
    createdAt?: SortOrder
  }

  export type GpsPointSumOrderByAggregateInput = {
    latitude?: SortOrder
    longitude?: SortOrder
    accuracy?: SortOrder
    speed?: SortOrder
    bearing?: SortOrder
    batteryLevel?: SortOrder
  }

  export type IntNullableFilter<$PrismaModel = never> = {
    equals?: number | IntFieldRefInput<$PrismaModel> | null
    in?: number[] | null
    notIn?: number[] | null
    lt?: number | IntFieldRefInput<$PrismaModel>
    lte?: number | IntFieldRefInput<$PrismaModel>
    gt?: number | IntFieldRefInput<$PrismaModel>
    gte?: number | IntFieldRefInput<$PrismaModel>
    not?: NestedIntNullableFilter<$PrismaModel> | number | null
  }

  export type GpsStopCountOrderByAggregateInput = {
    id?: SortOrder
    tripId?: SortOrder
    latitude?: SortOrder
    longitude?: SortOrder
    startedAt?: SortOrder
    endedAt?: SortOrder
    duration?: SortOrder
    address?: SortOrder
  }

  export type GpsStopAvgOrderByAggregateInput = {
    latitude?: SortOrder
    longitude?: SortOrder
    duration?: SortOrder
  }

  export type GpsStopMaxOrderByAggregateInput = {
    id?: SortOrder
    tripId?: SortOrder
    latitude?: SortOrder
    longitude?: SortOrder
    startedAt?: SortOrder
    endedAt?: SortOrder
    duration?: SortOrder
    address?: SortOrder
  }

  export type GpsStopMinOrderByAggregateInput = {
    id?: SortOrder
    tripId?: SortOrder
    latitude?: SortOrder
    longitude?: SortOrder
    startedAt?: SortOrder
    endedAt?: SortOrder
    duration?: SortOrder
    address?: SortOrder
  }

  export type GpsStopSumOrderByAggregateInput = {
    latitude?: SortOrder
    longitude?: SortOrder
    duration?: SortOrder
  }

  export type IntNullableWithAggregatesFilter<$PrismaModel = never> = {
    equals?: number | IntFieldRefInput<$PrismaModel> | null
    in?: number[] | null
    notIn?: number[] | null
    lt?: number | IntFieldRefInput<$PrismaModel>
    lte?: number | IntFieldRefInput<$PrismaModel>
    gt?: number | IntFieldRefInput<$PrismaModel>
    gte?: number | IntFieldRefInput<$PrismaModel>
    not?: NestedIntNullableWithAggregatesFilter<$PrismaModel> | number | null
    _count?: NestedIntNullableFilter<$PrismaModel>
    _avg?: NestedFloatNullableFilter<$PrismaModel>
    _sum?: NestedIntNullableFilter<$PrismaModel>
    _min?: NestedIntNullableFilter<$PrismaModel>
    _max?: NestedIntNullableFilter<$PrismaModel>
  }

  export type EnumNotificationTypeFilter<$PrismaModel = never> = {
    equals?: $Enums.NotificationType | EnumNotificationTypeFieldRefInput<$PrismaModel>
    in?: $Enums.NotificationType[]
    notIn?: $Enums.NotificationType[]
    not?: NestedEnumNotificationTypeFilter<$PrismaModel> | $Enums.NotificationType
  }

  export type NotificationCountOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    type?: SortOrder
    title?: SortOrder
    body?: SortOrder
    data?: SortOrder
    read?: SortOrder
    sentAt?: SortOrder
  }

  export type NotificationMaxOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    type?: SortOrder
    title?: SortOrder
    body?: SortOrder
    read?: SortOrder
    sentAt?: SortOrder
  }

  export type NotificationMinOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    type?: SortOrder
    title?: SortOrder
    body?: SortOrder
    read?: SortOrder
    sentAt?: SortOrder
  }

  export type EnumNotificationTypeWithAggregatesFilter<$PrismaModel = never> = {
    equals?: $Enums.NotificationType | EnumNotificationTypeFieldRefInput<$PrismaModel>
    in?: $Enums.NotificationType[]
    notIn?: $Enums.NotificationType[]
    not?: NestedEnumNotificationTypeWithAggregatesFilter<$PrismaModel> | $Enums.NotificationType
    _count?: NestedIntFilter<$PrismaModel>
    _min?: NestedEnumNotificationTypeFilter<$PrismaModel>
    _max?: NestedEnumNotificationTypeFilter<$PrismaModel>
  }
  export type JsonFilter<$PrismaModel = never> =
    | PatchUndefined<
        Either<Required<JsonFilterBase<$PrismaModel>>, Exclude<keyof Required<JsonFilterBase<$PrismaModel>>, 'path'>>,
        Required<JsonFilterBase<$PrismaModel>>
      >
    | OptionalFlat<Omit<Required<JsonFilterBase<$PrismaModel>>, 'path'>>

  export type JsonFilterBase<$PrismaModel = never> = {
    equals?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | JsonNullValueFilter
    path?: string
    mode?: QueryMode | EnumQueryModeFieldRefInput<$PrismaModel>
    string_contains?: string | StringFieldRefInput<$PrismaModel>
    string_starts_with?: string | StringFieldRefInput<$PrismaModel>
    string_ends_with?: string | StringFieldRefInput<$PrismaModel>
    array_starts_with?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | null
    array_ends_with?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | null
    not?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | JsonNullValueFilter
  }

  export type SystemConfigCountOrderByAggregateInput = {
    id?: SortOrder
    key?: SortOrder
    value?: SortOrder
    updatedAt?: SortOrder
  }

  export type SystemConfigMaxOrderByAggregateInput = {
    id?: SortOrder
    key?: SortOrder
    updatedAt?: SortOrder
  }

  export type SystemConfigMinOrderByAggregateInput = {
    id?: SortOrder
    key?: SortOrder
    updatedAt?: SortOrder
  }
  export type JsonWithAggregatesFilter<$PrismaModel = never> =
    | PatchUndefined<
        Either<Required<JsonWithAggregatesFilterBase<$PrismaModel>>, Exclude<keyof Required<JsonWithAggregatesFilterBase<$PrismaModel>>, 'path'>>,
        Required<JsonWithAggregatesFilterBase<$PrismaModel>>
      >
    | OptionalFlat<Omit<Required<JsonWithAggregatesFilterBase<$PrismaModel>>, 'path'>>

  export type JsonWithAggregatesFilterBase<$PrismaModel = never> = {
    equals?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | JsonNullValueFilter
    path?: string
    mode?: QueryMode | EnumQueryModeFieldRefInput<$PrismaModel>
    string_contains?: string | StringFieldRefInput<$PrismaModel>
    string_starts_with?: string | StringFieldRefInput<$PrismaModel>
    string_ends_with?: string | StringFieldRefInput<$PrismaModel>
    array_starts_with?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | null
    array_ends_with?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | null
    not?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | JsonNullValueFilter
    _count?: NestedIntFilter<$PrismaModel>
    _min?: NestedJsonFilter<$PrismaModel>
    _max?: NestedJsonFilter<$PrismaModel>
  }

  export type DailySummaryUserIdDateCompoundUniqueInput = {
    userId: string
    date: Date | string
  }

  export type DailySummaryCountOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    date?: SortOrder
    totalDistance?: SortOrder
    travelTime?: SortOrder
    meetingTime?: SortOrder
    idleTime?: SortOrder
    tripsCompleted?: SortOrder
    productivityScore?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
  }

  export type DailySummaryAvgOrderByAggregateInput = {
    totalDistance?: SortOrder
    travelTime?: SortOrder
    meetingTime?: SortOrder
    idleTime?: SortOrder
    tripsCompleted?: SortOrder
    productivityScore?: SortOrder
  }

  export type DailySummaryMaxOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    date?: SortOrder
    totalDistance?: SortOrder
    travelTime?: SortOrder
    meetingTime?: SortOrder
    idleTime?: SortOrder
    tripsCompleted?: SortOrder
    productivityScore?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
  }

  export type DailySummaryMinOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    date?: SortOrder
    totalDistance?: SortOrder
    travelTime?: SortOrder
    meetingTime?: SortOrder
    idleTime?: SortOrder
    tripsCompleted?: SortOrder
    productivityScore?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
  }

  export type DailySummarySumOrderByAggregateInput = {
    totalDistance?: SortOrder
    travelTime?: SortOrder
    meetingTime?: SortOrder
    idleTime?: SortOrder
    tripsCompleted?: SortOrder
    productivityScore?: SortOrder
  }

  export type MonthlySummaryUserIdYearMonthCompoundUniqueInput = {
    userId: string
    year: number
    month: number
  }

  export type MonthlySummaryCountOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    year?: SortOrder
    month?: SortOrder
    totalDistance?: SortOrder
    travelTime?: SortOrder
    meetingTime?: SortOrder
    idleTime?: SortOrder
    tripsCompleted?: SortOrder
    productivityScore?: SortOrder
  }

  export type MonthlySummaryAvgOrderByAggregateInput = {
    year?: SortOrder
    month?: SortOrder
    totalDistance?: SortOrder
    travelTime?: SortOrder
    meetingTime?: SortOrder
    idleTime?: SortOrder
    tripsCompleted?: SortOrder
    productivityScore?: SortOrder
  }

  export type MonthlySummaryMaxOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    year?: SortOrder
    month?: SortOrder
    totalDistance?: SortOrder
    travelTime?: SortOrder
    meetingTime?: SortOrder
    idleTime?: SortOrder
    tripsCompleted?: SortOrder
    productivityScore?: SortOrder
  }

  export type MonthlySummaryMinOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    year?: SortOrder
    month?: SortOrder
    totalDistance?: SortOrder
    travelTime?: SortOrder
    meetingTime?: SortOrder
    idleTime?: SortOrder
    tripsCompleted?: SortOrder
    productivityScore?: SortOrder
  }

  export type MonthlySummarySumOrderByAggregateInput = {
    year?: SortOrder
    month?: SortOrder
    totalDistance?: SortOrder
    travelTime?: SortOrder
    meetingTime?: SortOrder
    idleTime?: SortOrder
    tripsCompleted?: SortOrder
    productivityScore?: SortOrder
  }

  export type UserCreateNestedOneWithoutDirectReportsInput = {
    create?: XOR<UserCreateWithoutDirectReportsInput, UserUncheckedCreateWithoutDirectReportsInput>
    connectOrCreate?: UserCreateOrConnectWithoutDirectReportsInput
    connect?: UserWhereUniqueInput
  }

  export type UserCreateNestedManyWithoutReportingManagerInput = {
    create?: XOR<UserCreateWithoutReportingManagerInput, UserUncheckedCreateWithoutReportingManagerInput> | UserCreateWithoutReportingManagerInput[] | UserUncheckedCreateWithoutReportingManagerInput[]
    connectOrCreate?: UserCreateOrConnectWithoutReportingManagerInput | UserCreateOrConnectWithoutReportingManagerInput[]
    createMany?: UserCreateManyReportingManagerInputEnvelope
    connect?: UserWhereUniqueInput | UserWhereUniqueInput[]
  }

  export type RefreshTokenCreateNestedManyWithoutUserInput = {
    create?: XOR<RefreshTokenCreateWithoutUserInput, RefreshTokenUncheckedCreateWithoutUserInput> | RefreshTokenCreateWithoutUserInput[] | RefreshTokenUncheckedCreateWithoutUserInput[]
    connectOrCreate?: RefreshTokenCreateOrConnectWithoutUserInput | RefreshTokenCreateOrConnectWithoutUserInput[]
    createMany?: RefreshTokenCreateManyUserInputEnvelope
    connect?: RefreshTokenWhereUniqueInput | RefreshTokenWhereUniqueInput[]
  }

  export type TripCreateNestedManyWithoutUserInput = {
    create?: XOR<TripCreateWithoutUserInput, TripUncheckedCreateWithoutUserInput> | TripCreateWithoutUserInput[] | TripUncheckedCreateWithoutUserInput[]
    connectOrCreate?: TripCreateOrConnectWithoutUserInput | TripCreateOrConnectWithoutUserInput[]
    createMany?: TripCreateManyUserInputEnvelope
    connect?: TripWhereUniqueInput | TripWhereUniqueInput[]
  }

  export type GpsPointCreateNestedManyWithoutUserInput = {
    create?: XOR<GpsPointCreateWithoutUserInput, GpsPointUncheckedCreateWithoutUserInput> | GpsPointCreateWithoutUserInput[] | GpsPointUncheckedCreateWithoutUserInput[]
    connectOrCreate?: GpsPointCreateOrConnectWithoutUserInput | GpsPointCreateOrConnectWithoutUserInput[]
    createMany?: GpsPointCreateManyUserInputEnvelope
    connect?: GpsPointWhereUniqueInput | GpsPointWhereUniqueInput[]
  }

  export type AuditLogCreateNestedManyWithoutActorInput = {
    create?: XOR<AuditLogCreateWithoutActorInput, AuditLogUncheckedCreateWithoutActorInput> | AuditLogCreateWithoutActorInput[] | AuditLogUncheckedCreateWithoutActorInput[]
    connectOrCreate?: AuditLogCreateOrConnectWithoutActorInput | AuditLogCreateOrConnectWithoutActorInput[]
    createMany?: AuditLogCreateManyActorInputEnvelope
    connect?: AuditLogWhereUniqueInput | AuditLogWhereUniqueInput[]
  }

  export type NotificationCreateNestedManyWithoutUserInput = {
    create?: XOR<NotificationCreateWithoutUserInput, NotificationUncheckedCreateWithoutUserInput> | NotificationCreateWithoutUserInput[] | NotificationUncheckedCreateWithoutUserInput[]
    connectOrCreate?: NotificationCreateOrConnectWithoutUserInput | NotificationCreateOrConnectWithoutUserInput[]
    createMany?: NotificationCreateManyUserInputEnvelope
    connect?: NotificationWhereUniqueInput | NotificationWhereUniqueInput[]
  }

  export type UserUncheckedCreateNestedManyWithoutReportingManagerInput = {
    create?: XOR<UserCreateWithoutReportingManagerInput, UserUncheckedCreateWithoutReportingManagerInput> | UserCreateWithoutReportingManagerInput[] | UserUncheckedCreateWithoutReportingManagerInput[]
    connectOrCreate?: UserCreateOrConnectWithoutReportingManagerInput | UserCreateOrConnectWithoutReportingManagerInput[]
    createMany?: UserCreateManyReportingManagerInputEnvelope
    connect?: UserWhereUniqueInput | UserWhereUniqueInput[]
  }

  export type RefreshTokenUncheckedCreateNestedManyWithoutUserInput = {
    create?: XOR<RefreshTokenCreateWithoutUserInput, RefreshTokenUncheckedCreateWithoutUserInput> | RefreshTokenCreateWithoutUserInput[] | RefreshTokenUncheckedCreateWithoutUserInput[]
    connectOrCreate?: RefreshTokenCreateOrConnectWithoutUserInput | RefreshTokenCreateOrConnectWithoutUserInput[]
    createMany?: RefreshTokenCreateManyUserInputEnvelope
    connect?: RefreshTokenWhereUniqueInput | RefreshTokenWhereUniqueInput[]
  }

  export type TripUncheckedCreateNestedManyWithoutUserInput = {
    create?: XOR<TripCreateWithoutUserInput, TripUncheckedCreateWithoutUserInput> | TripCreateWithoutUserInput[] | TripUncheckedCreateWithoutUserInput[]
    connectOrCreate?: TripCreateOrConnectWithoutUserInput | TripCreateOrConnectWithoutUserInput[]
    createMany?: TripCreateManyUserInputEnvelope
    connect?: TripWhereUniqueInput | TripWhereUniqueInput[]
  }

  export type GpsPointUncheckedCreateNestedManyWithoutUserInput = {
    create?: XOR<GpsPointCreateWithoutUserInput, GpsPointUncheckedCreateWithoutUserInput> | GpsPointCreateWithoutUserInput[] | GpsPointUncheckedCreateWithoutUserInput[]
    connectOrCreate?: GpsPointCreateOrConnectWithoutUserInput | GpsPointCreateOrConnectWithoutUserInput[]
    createMany?: GpsPointCreateManyUserInputEnvelope
    connect?: GpsPointWhereUniqueInput | GpsPointWhereUniqueInput[]
  }

  export type AuditLogUncheckedCreateNestedManyWithoutActorInput = {
    create?: XOR<AuditLogCreateWithoutActorInput, AuditLogUncheckedCreateWithoutActorInput> | AuditLogCreateWithoutActorInput[] | AuditLogUncheckedCreateWithoutActorInput[]
    connectOrCreate?: AuditLogCreateOrConnectWithoutActorInput | AuditLogCreateOrConnectWithoutActorInput[]
    createMany?: AuditLogCreateManyActorInputEnvelope
    connect?: AuditLogWhereUniqueInput | AuditLogWhereUniqueInput[]
  }

  export type NotificationUncheckedCreateNestedManyWithoutUserInput = {
    create?: XOR<NotificationCreateWithoutUserInput, NotificationUncheckedCreateWithoutUserInput> | NotificationCreateWithoutUserInput[] | NotificationUncheckedCreateWithoutUserInput[]
    connectOrCreate?: NotificationCreateOrConnectWithoutUserInput | NotificationCreateOrConnectWithoutUserInput[]
    createMany?: NotificationCreateManyUserInputEnvelope
    connect?: NotificationWhereUniqueInput | NotificationWhereUniqueInput[]
  }

  export type StringFieldUpdateOperationsInput = {
    set?: string
  }

  export type NullableStringFieldUpdateOperationsInput = {
    set?: string | null
  }

  export type EnumUserRoleFieldUpdateOperationsInput = {
    set?: $Enums.UserRole
  }

  export type EnumUserStatusFieldUpdateOperationsInput = {
    set?: $Enums.UserStatus
  }

  export type BoolFieldUpdateOperationsInput = {
    set?: boolean
  }

  export type EnumEmployeePresenceFieldUpdateOperationsInput = {
    set?: $Enums.EmployeePresence
  }

  export type NullableDateTimeFieldUpdateOperationsInput = {
    set?: Date | string | null
  }

  export type DateTimeFieldUpdateOperationsInput = {
    set?: Date | string
  }

  export type UserUpdateOneWithoutDirectReportsNestedInput = {
    create?: XOR<UserCreateWithoutDirectReportsInput, UserUncheckedCreateWithoutDirectReportsInput>
    connectOrCreate?: UserCreateOrConnectWithoutDirectReportsInput
    upsert?: UserUpsertWithoutDirectReportsInput
    disconnect?: UserWhereInput | boolean
    delete?: UserWhereInput | boolean
    connect?: UserWhereUniqueInput
    update?: XOR<XOR<UserUpdateToOneWithWhereWithoutDirectReportsInput, UserUpdateWithoutDirectReportsInput>, UserUncheckedUpdateWithoutDirectReportsInput>
  }

  export type UserUpdateManyWithoutReportingManagerNestedInput = {
    create?: XOR<UserCreateWithoutReportingManagerInput, UserUncheckedCreateWithoutReportingManagerInput> | UserCreateWithoutReportingManagerInput[] | UserUncheckedCreateWithoutReportingManagerInput[]
    connectOrCreate?: UserCreateOrConnectWithoutReportingManagerInput | UserCreateOrConnectWithoutReportingManagerInput[]
    upsert?: UserUpsertWithWhereUniqueWithoutReportingManagerInput | UserUpsertWithWhereUniqueWithoutReportingManagerInput[]
    createMany?: UserCreateManyReportingManagerInputEnvelope
    set?: UserWhereUniqueInput | UserWhereUniqueInput[]
    disconnect?: UserWhereUniqueInput | UserWhereUniqueInput[]
    delete?: UserWhereUniqueInput | UserWhereUniqueInput[]
    connect?: UserWhereUniqueInput | UserWhereUniqueInput[]
    update?: UserUpdateWithWhereUniqueWithoutReportingManagerInput | UserUpdateWithWhereUniqueWithoutReportingManagerInput[]
    updateMany?: UserUpdateManyWithWhereWithoutReportingManagerInput | UserUpdateManyWithWhereWithoutReportingManagerInput[]
    deleteMany?: UserScalarWhereInput | UserScalarWhereInput[]
  }

  export type RefreshTokenUpdateManyWithoutUserNestedInput = {
    create?: XOR<RefreshTokenCreateWithoutUserInput, RefreshTokenUncheckedCreateWithoutUserInput> | RefreshTokenCreateWithoutUserInput[] | RefreshTokenUncheckedCreateWithoutUserInput[]
    connectOrCreate?: RefreshTokenCreateOrConnectWithoutUserInput | RefreshTokenCreateOrConnectWithoutUserInput[]
    upsert?: RefreshTokenUpsertWithWhereUniqueWithoutUserInput | RefreshTokenUpsertWithWhereUniqueWithoutUserInput[]
    createMany?: RefreshTokenCreateManyUserInputEnvelope
    set?: RefreshTokenWhereUniqueInput | RefreshTokenWhereUniqueInput[]
    disconnect?: RefreshTokenWhereUniqueInput | RefreshTokenWhereUniqueInput[]
    delete?: RefreshTokenWhereUniqueInput | RefreshTokenWhereUniqueInput[]
    connect?: RefreshTokenWhereUniqueInput | RefreshTokenWhereUniqueInput[]
    update?: RefreshTokenUpdateWithWhereUniqueWithoutUserInput | RefreshTokenUpdateWithWhereUniqueWithoutUserInput[]
    updateMany?: RefreshTokenUpdateManyWithWhereWithoutUserInput | RefreshTokenUpdateManyWithWhereWithoutUserInput[]
    deleteMany?: RefreshTokenScalarWhereInput | RefreshTokenScalarWhereInput[]
  }

  export type TripUpdateManyWithoutUserNestedInput = {
    create?: XOR<TripCreateWithoutUserInput, TripUncheckedCreateWithoutUserInput> | TripCreateWithoutUserInput[] | TripUncheckedCreateWithoutUserInput[]
    connectOrCreate?: TripCreateOrConnectWithoutUserInput | TripCreateOrConnectWithoutUserInput[]
    upsert?: TripUpsertWithWhereUniqueWithoutUserInput | TripUpsertWithWhereUniqueWithoutUserInput[]
    createMany?: TripCreateManyUserInputEnvelope
    set?: TripWhereUniqueInput | TripWhereUniqueInput[]
    disconnect?: TripWhereUniqueInput | TripWhereUniqueInput[]
    delete?: TripWhereUniqueInput | TripWhereUniqueInput[]
    connect?: TripWhereUniqueInput | TripWhereUniqueInput[]
    update?: TripUpdateWithWhereUniqueWithoutUserInput | TripUpdateWithWhereUniqueWithoutUserInput[]
    updateMany?: TripUpdateManyWithWhereWithoutUserInput | TripUpdateManyWithWhereWithoutUserInput[]
    deleteMany?: TripScalarWhereInput | TripScalarWhereInput[]
  }

  export type GpsPointUpdateManyWithoutUserNestedInput = {
    create?: XOR<GpsPointCreateWithoutUserInput, GpsPointUncheckedCreateWithoutUserInput> | GpsPointCreateWithoutUserInput[] | GpsPointUncheckedCreateWithoutUserInput[]
    connectOrCreate?: GpsPointCreateOrConnectWithoutUserInput | GpsPointCreateOrConnectWithoutUserInput[]
    upsert?: GpsPointUpsertWithWhereUniqueWithoutUserInput | GpsPointUpsertWithWhereUniqueWithoutUserInput[]
    createMany?: GpsPointCreateManyUserInputEnvelope
    set?: GpsPointWhereUniqueInput | GpsPointWhereUniqueInput[]
    disconnect?: GpsPointWhereUniqueInput | GpsPointWhereUniqueInput[]
    delete?: GpsPointWhereUniqueInput | GpsPointWhereUniqueInput[]
    connect?: GpsPointWhereUniqueInput | GpsPointWhereUniqueInput[]
    update?: GpsPointUpdateWithWhereUniqueWithoutUserInput | GpsPointUpdateWithWhereUniqueWithoutUserInput[]
    updateMany?: GpsPointUpdateManyWithWhereWithoutUserInput | GpsPointUpdateManyWithWhereWithoutUserInput[]
    deleteMany?: GpsPointScalarWhereInput | GpsPointScalarWhereInput[]
  }

  export type AuditLogUpdateManyWithoutActorNestedInput = {
    create?: XOR<AuditLogCreateWithoutActorInput, AuditLogUncheckedCreateWithoutActorInput> | AuditLogCreateWithoutActorInput[] | AuditLogUncheckedCreateWithoutActorInput[]
    connectOrCreate?: AuditLogCreateOrConnectWithoutActorInput | AuditLogCreateOrConnectWithoutActorInput[]
    upsert?: AuditLogUpsertWithWhereUniqueWithoutActorInput | AuditLogUpsertWithWhereUniqueWithoutActorInput[]
    createMany?: AuditLogCreateManyActorInputEnvelope
    set?: AuditLogWhereUniqueInput | AuditLogWhereUniqueInput[]
    disconnect?: AuditLogWhereUniqueInput | AuditLogWhereUniqueInput[]
    delete?: AuditLogWhereUniqueInput | AuditLogWhereUniqueInput[]
    connect?: AuditLogWhereUniqueInput | AuditLogWhereUniqueInput[]
    update?: AuditLogUpdateWithWhereUniqueWithoutActorInput | AuditLogUpdateWithWhereUniqueWithoutActorInput[]
    updateMany?: AuditLogUpdateManyWithWhereWithoutActorInput | AuditLogUpdateManyWithWhereWithoutActorInput[]
    deleteMany?: AuditLogScalarWhereInput | AuditLogScalarWhereInput[]
  }

  export type NotificationUpdateManyWithoutUserNestedInput = {
    create?: XOR<NotificationCreateWithoutUserInput, NotificationUncheckedCreateWithoutUserInput> | NotificationCreateWithoutUserInput[] | NotificationUncheckedCreateWithoutUserInput[]
    connectOrCreate?: NotificationCreateOrConnectWithoutUserInput | NotificationCreateOrConnectWithoutUserInput[]
    upsert?: NotificationUpsertWithWhereUniqueWithoutUserInput | NotificationUpsertWithWhereUniqueWithoutUserInput[]
    createMany?: NotificationCreateManyUserInputEnvelope
    set?: NotificationWhereUniqueInput | NotificationWhereUniqueInput[]
    disconnect?: NotificationWhereUniqueInput | NotificationWhereUniqueInput[]
    delete?: NotificationWhereUniqueInput | NotificationWhereUniqueInput[]
    connect?: NotificationWhereUniqueInput | NotificationWhereUniqueInput[]
    update?: NotificationUpdateWithWhereUniqueWithoutUserInput | NotificationUpdateWithWhereUniqueWithoutUserInput[]
    updateMany?: NotificationUpdateManyWithWhereWithoutUserInput | NotificationUpdateManyWithWhereWithoutUserInput[]
    deleteMany?: NotificationScalarWhereInput | NotificationScalarWhereInput[]
  }

  export type UserUncheckedUpdateManyWithoutReportingManagerNestedInput = {
    create?: XOR<UserCreateWithoutReportingManagerInput, UserUncheckedCreateWithoutReportingManagerInput> | UserCreateWithoutReportingManagerInput[] | UserUncheckedCreateWithoutReportingManagerInput[]
    connectOrCreate?: UserCreateOrConnectWithoutReportingManagerInput | UserCreateOrConnectWithoutReportingManagerInput[]
    upsert?: UserUpsertWithWhereUniqueWithoutReportingManagerInput | UserUpsertWithWhereUniqueWithoutReportingManagerInput[]
    createMany?: UserCreateManyReportingManagerInputEnvelope
    set?: UserWhereUniqueInput | UserWhereUniqueInput[]
    disconnect?: UserWhereUniqueInput | UserWhereUniqueInput[]
    delete?: UserWhereUniqueInput | UserWhereUniqueInput[]
    connect?: UserWhereUniqueInput | UserWhereUniqueInput[]
    update?: UserUpdateWithWhereUniqueWithoutReportingManagerInput | UserUpdateWithWhereUniqueWithoutReportingManagerInput[]
    updateMany?: UserUpdateManyWithWhereWithoutReportingManagerInput | UserUpdateManyWithWhereWithoutReportingManagerInput[]
    deleteMany?: UserScalarWhereInput | UserScalarWhereInput[]
  }

  export type RefreshTokenUncheckedUpdateManyWithoutUserNestedInput = {
    create?: XOR<RefreshTokenCreateWithoutUserInput, RefreshTokenUncheckedCreateWithoutUserInput> | RefreshTokenCreateWithoutUserInput[] | RefreshTokenUncheckedCreateWithoutUserInput[]
    connectOrCreate?: RefreshTokenCreateOrConnectWithoutUserInput | RefreshTokenCreateOrConnectWithoutUserInput[]
    upsert?: RefreshTokenUpsertWithWhereUniqueWithoutUserInput | RefreshTokenUpsertWithWhereUniqueWithoutUserInput[]
    createMany?: RefreshTokenCreateManyUserInputEnvelope
    set?: RefreshTokenWhereUniqueInput | RefreshTokenWhereUniqueInput[]
    disconnect?: RefreshTokenWhereUniqueInput | RefreshTokenWhereUniqueInput[]
    delete?: RefreshTokenWhereUniqueInput | RefreshTokenWhereUniqueInput[]
    connect?: RefreshTokenWhereUniqueInput | RefreshTokenWhereUniqueInput[]
    update?: RefreshTokenUpdateWithWhereUniqueWithoutUserInput | RefreshTokenUpdateWithWhereUniqueWithoutUserInput[]
    updateMany?: RefreshTokenUpdateManyWithWhereWithoutUserInput | RefreshTokenUpdateManyWithWhereWithoutUserInput[]
    deleteMany?: RefreshTokenScalarWhereInput | RefreshTokenScalarWhereInput[]
  }

  export type TripUncheckedUpdateManyWithoutUserNestedInput = {
    create?: XOR<TripCreateWithoutUserInput, TripUncheckedCreateWithoutUserInput> | TripCreateWithoutUserInput[] | TripUncheckedCreateWithoutUserInput[]
    connectOrCreate?: TripCreateOrConnectWithoutUserInput | TripCreateOrConnectWithoutUserInput[]
    upsert?: TripUpsertWithWhereUniqueWithoutUserInput | TripUpsertWithWhereUniqueWithoutUserInput[]
    createMany?: TripCreateManyUserInputEnvelope
    set?: TripWhereUniqueInput | TripWhereUniqueInput[]
    disconnect?: TripWhereUniqueInput | TripWhereUniqueInput[]
    delete?: TripWhereUniqueInput | TripWhereUniqueInput[]
    connect?: TripWhereUniqueInput | TripWhereUniqueInput[]
    update?: TripUpdateWithWhereUniqueWithoutUserInput | TripUpdateWithWhereUniqueWithoutUserInput[]
    updateMany?: TripUpdateManyWithWhereWithoutUserInput | TripUpdateManyWithWhereWithoutUserInput[]
    deleteMany?: TripScalarWhereInput | TripScalarWhereInput[]
  }

  export type GpsPointUncheckedUpdateManyWithoutUserNestedInput = {
    create?: XOR<GpsPointCreateWithoutUserInput, GpsPointUncheckedCreateWithoutUserInput> | GpsPointCreateWithoutUserInput[] | GpsPointUncheckedCreateWithoutUserInput[]
    connectOrCreate?: GpsPointCreateOrConnectWithoutUserInput | GpsPointCreateOrConnectWithoutUserInput[]
    upsert?: GpsPointUpsertWithWhereUniqueWithoutUserInput | GpsPointUpsertWithWhereUniqueWithoutUserInput[]
    createMany?: GpsPointCreateManyUserInputEnvelope
    set?: GpsPointWhereUniqueInput | GpsPointWhereUniqueInput[]
    disconnect?: GpsPointWhereUniqueInput | GpsPointWhereUniqueInput[]
    delete?: GpsPointWhereUniqueInput | GpsPointWhereUniqueInput[]
    connect?: GpsPointWhereUniqueInput | GpsPointWhereUniqueInput[]
    update?: GpsPointUpdateWithWhereUniqueWithoutUserInput | GpsPointUpdateWithWhereUniqueWithoutUserInput[]
    updateMany?: GpsPointUpdateManyWithWhereWithoutUserInput | GpsPointUpdateManyWithWhereWithoutUserInput[]
    deleteMany?: GpsPointScalarWhereInput | GpsPointScalarWhereInput[]
  }

  export type AuditLogUncheckedUpdateManyWithoutActorNestedInput = {
    create?: XOR<AuditLogCreateWithoutActorInput, AuditLogUncheckedCreateWithoutActorInput> | AuditLogCreateWithoutActorInput[] | AuditLogUncheckedCreateWithoutActorInput[]
    connectOrCreate?: AuditLogCreateOrConnectWithoutActorInput | AuditLogCreateOrConnectWithoutActorInput[]
    upsert?: AuditLogUpsertWithWhereUniqueWithoutActorInput | AuditLogUpsertWithWhereUniqueWithoutActorInput[]
    createMany?: AuditLogCreateManyActorInputEnvelope
    set?: AuditLogWhereUniqueInput | AuditLogWhereUniqueInput[]
    disconnect?: AuditLogWhereUniqueInput | AuditLogWhereUniqueInput[]
    delete?: AuditLogWhereUniqueInput | AuditLogWhereUniqueInput[]
    connect?: AuditLogWhereUniqueInput | AuditLogWhereUniqueInput[]
    update?: AuditLogUpdateWithWhereUniqueWithoutActorInput | AuditLogUpdateWithWhereUniqueWithoutActorInput[]
    updateMany?: AuditLogUpdateManyWithWhereWithoutActorInput | AuditLogUpdateManyWithWhereWithoutActorInput[]
    deleteMany?: AuditLogScalarWhereInput | AuditLogScalarWhereInput[]
  }

  export type NotificationUncheckedUpdateManyWithoutUserNestedInput = {
    create?: XOR<NotificationCreateWithoutUserInput, NotificationUncheckedCreateWithoutUserInput> | NotificationCreateWithoutUserInput[] | NotificationUncheckedCreateWithoutUserInput[]
    connectOrCreate?: NotificationCreateOrConnectWithoutUserInput | NotificationCreateOrConnectWithoutUserInput[]
    upsert?: NotificationUpsertWithWhereUniqueWithoutUserInput | NotificationUpsertWithWhereUniqueWithoutUserInput[]
    createMany?: NotificationCreateManyUserInputEnvelope
    set?: NotificationWhereUniqueInput | NotificationWhereUniqueInput[]
    disconnect?: NotificationWhereUniqueInput | NotificationWhereUniqueInput[]
    delete?: NotificationWhereUniqueInput | NotificationWhereUniqueInput[]
    connect?: NotificationWhereUniqueInput | NotificationWhereUniqueInput[]
    update?: NotificationUpdateWithWhereUniqueWithoutUserInput | NotificationUpdateWithWhereUniqueWithoutUserInput[]
    updateMany?: NotificationUpdateManyWithWhereWithoutUserInput | NotificationUpdateManyWithWhereWithoutUserInput[]
    deleteMany?: NotificationScalarWhereInput | NotificationScalarWhereInput[]
  }

  export type UserCreateNestedOneWithoutRefreshTokensInput = {
    create?: XOR<UserCreateWithoutRefreshTokensInput, UserUncheckedCreateWithoutRefreshTokensInput>
    connectOrCreate?: UserCreateOrConnectWithoutRefreshTokensInput
    connect?: UserWhereUniqueInput
  }

  export type UserUpdateOneRequiredWithoutRefreshTokensNestedInput = {
    create?: XOR<UserCreateWithoutRefreshTokensInput, UserUncheckedCreateWithoutRefreshTokensInput>
    connectOrCreate?: UserCreateOrConnectWithoutRefreshTokensInput
    upsert?: UserUpsertWithoutRefreshTokensInput
    connect?: UserWhereUniqueInput
    update?: XOR<XOR<UserUpdateToOneWithWhereWithoutRefreshTokensInput, UserUpdateWithoutRefreshTokensInput>, UserUncheckedUpdateWithoutRefreshTokensInput>
  }

  export type UserCreateNestedOneWithoutAuditLogsInput = {
    create?: XOR<UserCreateWithoutAuditLogsInput, UserUncheckedCreateWithoutAuditLogsInput>
    connectOrCreate?: UserCreateOrConnectWithoutAuditLogsInput
    connect?: UserWhereUniqueInput
  }

  export type UserUpdateOneWithoutAuditLogsNestedInput = {
    create?: XOR<UserCreateWithoutAuditLogsInput, UserUncheckedCreateWithoutAuditLogsInput>
    connectOrCreate?: UserCreateOrConnectWithoutAuditLogsInput
    upsert?: UserUpsertWithoutAuditLogsInput
    disconnect?: UserWhereInput | boolean
    delete?: UserWhereInput | boolean
    connect?: UserWhereUniqueInput
    update?: XOR<XOR<UserUpdateToOneWithWhereWithoutAuditLogsInput, UserUpdateWithoutAuditLogsInput>, UserUncheckedUpdateWithoutAuditLogsInput>
  }

  export type UserCreateNestedOneWithoutTripsInput = {
    create?: XOR<UserCreateWithoutTripsInput, UserUncheckedCreateWithoutTripsInput>
    connectOrCreate?: UserCreateOrConnectWithoutTripsInput
    connect?: UserWhereUniqueInput
  }

  export type PunchCreateNestedManyWithoutTripInput = {
    create?: XOR<PunchCreateWithoutTripInput, PunchUncheckedCreateWithoutTripInput> | PunchCreateWithoutTripInput[] | PunchUncheckedCreateWithoutTripInput[]
    connectOrCreate?: PunchCreateOrConnectWithoutTripInput | PunchCreateOrConnectWithoutTripInput[]
    createMany?: PunchCreateManyTripInputEnvelope
    connect?: PunchWhereUniqueInput | PunchWhereUniqueInput[]
  }

  export type GpsPointCreateNestedManyWithoutTripInput = {
    create?: XOR<GpsPointCreateWithoutTripInput, GpsPointUncheckedCreateWithoutTripInput> | GpsPointCreateWithoutTripInput[] | GpsPointUncheckedCreateWithoutTripInput[]
    connectOrCreate?: GpsPointCreateOrConnectWithoutTripInput | GpsPointCreateOrConnectWithoutTripInput[]
    createMany?: GpsPointCreateManyTripInputEnvelope
    connect?: GpsPointWhereUniqueInput | GpsPointWhereUniqueInput[]
  }

  export type GpsStopCreateNestedManyWithoutTripInput = {
    create?: XOR<GpsStopCreateWithoutTripInput, GpsStopUncheckedCreateWithoutTripInput> | GpsStopCreateWithoutTripInput[] | GpsStopUncheckedCreateWithoutTripInput[]
    connectOrCreate?: GpsStopCreateOrConnectWithoutTripInput | GpsStopCreateOrConnectWithoutTripInput[]
    createMany?: GpsStopCreateManyTripInputEnvelope
    connect?: GpsStopWhereUniqueInput | GpsStopWhereUniqueInput[]
  }

  export type PunchUncheckedCreateNestedManyWithoutTripInput = {
    create?: XOR<PunchCreateWithoutTripInput, PunchUncheckedCreateWithoutTripInput> | PunchCreateWithoutTripInput[] | PunchUncheckedCreateWithoutTripInput[]
    connectOrCreate?: PunchCreateOrConnectWithoutTripInput | PunchCreateOrConnectWithoutTripInput[]
    createMany?: PunchCreateManyTripInputEnvelope
    connect?: PunchWhereUniqueInput | PunchWhereUniqueInput[]
  }

  export type GpsPointUncheckedCreateNestedManyWithoutTripInput = {
    create?: XOR<GpsPointCreateWithoutTripInput, GpsPointUncheckedCreateWithoutTripInput> | GpsPointCreateWithoutTripInput[] | GpsPointUncheckedCreateWithoutTripInput[]
    connectOrCreate?: GpsPointCreateOrConnectWithoutTripInput | GpsPointCreateOrConnectWithoutTripInput[]
    createMany?: GpsPointCreateManyTripInputEnvelope
    connect?: GpsPointWhereUniqueInput | GpsPointWhereUniqueInput[]
  }

  export type GpsStopUncheckedCreateNestedManyWithoutTripInput = {
    create?: XOR<GpsStopCreateWithoutTripInput, GpsStopUncheckedCreateWithoutTripInput> | GpsStopCreateWithoutTripInput[] | GpsStopUncheckedCreateWithoutTripInput[]
    connectOrCreate?: GpsStopCreateOrConnectWithoutTripInput | GpsStopCreateOrConnectWithoutTripInput[]
    createMany?: GpsStopCreateManyTripInputEnvelope
    connect?: GpsStopWhereUniqueInput | GpsStopWhereUniqueInput[]
  }

  export type NullableFloatFieldUpdateOperationsInput = {
    set?: number | null
    increment?: number
    decrement?: number
    multiply?: number
    divide?: number
  }

  export type NullableEnumVehicleTypeFieldUpdateOperationsInput = {
    set?: $Enums.VehicleType | null
  }

  export type NullableEnumFuelTypeFieldUpdateOperationsInput = {
    set?: $Enums.FuelType | null
  }

  export type EnumTripStatusFieldUpdateOperationsInput = {
    set?: $Enums.TripStatus
  }

  export type FloatFieldUpdateOperationsInput = {
    set?: number
    increment?: number
    decrement?: number
    multiply?: number
    divide?: number
  }

  export type IntFieldUpdateOperationsInput = {
    set?: number
    increment?: number
    decrement?: number
    multiply?: number
    divide?: number
  }

  export type UserUpdateOneRequiredWithoutTripsNestedInput = {
    create?: XOR<UserCreateWithoutTripsInput, UserUncheckedCreateWithoutTripsInput>
    connectOrCreate?: UserCreateOrConnectWithoutTripsInput
    upsert?: UserUpsertWithoutTripsInput
    connect?: UserWhereUniqueInput
    update?: XOR<XOR<UserUpdateToOneWithWhereWithoutTripsInput, UserUpdateWithoutTripsInput>, UserUncheckedUpdateWithoutTripsInput>
  }

  export type PunchUpdateManyWithoutTripNestedInput = {
    create?: XOR<PunchCreateWithoutTripInput, PunchUncheckedCreateWithoutTripInput> | PunchCreateWithoutTripInput[] | PunchUncheckedCreateWithoutTripInput[]
    connectOrCreate?: PunchCreateOrConnectWithoutTripInput | PunchCreateOrConnectWithoutTripInput[]
    upsert?: PunchUpsertWithWhereUniqueWithoutTripInput | PunchUpsertWithWhereUniqueWithoutTripInput[]
    createMany?: PunchCreateManyTripInputEnvelope
    set?: PunchWhereUniqueInput | PunchWhereUniqueInput[]
    disconnect?: PunchWhereUniqueInput | PunchWhereUniqueInput[]
    delete?: PunchWhereUniqueInput | PunchWhereUniqueInput[]
    connect?: PunchWhereUniqueInput | PunchWhereUniqueInput[]
    update?: PunchUpdateWithWhereUniqueWithoutTripInput | PunchUpdateWithWhereUniqueWithoutTripInput[]
    updateMany?: PunchUpdateManyWithWhereWithoutTripInput | PunchUpdateManyWithWhereWithoutTripInput[]
    deleteMany?: PunchScalarWhereInput | PunchScalarWhereInput[]
  }

  export type GpsPointUpdateManyWithoutTripNestedInput = {
    create?: XOR<GpsPointCreateWithoutTripInput, GpsPointUncheckedCreateWithoutTripInput> | GpsPointCreateWithoutTripInput[] | GpsPointUncheckedCreateWithoutTripInput[]
    connectOrCreate?: GpsPointCreateOrConnectWithoutTripInput | GpsPointCreateOrConnectWithoutTripInput[]
    upsert?: GpsPointUpsertWithWhereUniqueWithoutTripInput | GpsPointUpsertWithWhereUniqueWithoutTripInput[]
    createMany?: GpsPointCreateManyTripInputEnvelope
    set?: GpsPointWhereUniqueInput | GpsPointWhereUniqueInput[]
    disconnect?: GpsPointWhereUniqueInput | GpsPointWhereUniqueInput[]
    delete?: GpsPointWhereUniqueInput | GpsPointWhereUniqueInput[]
    connect?: GpsPointWhereUniqueInput | GpsPointWhereUniqueInput[]
    update?: GpsPointUpdateWithWhereUniqueWithoutTripInput | GpsPointUpdateWithWhereUniqueWithoutTripInput[]
    updateMany?: GpsPointUpdateManyWithWhereWithoutTripInput | GpsPointUpdateManyWithWhereWithoutTripInput[]
    deleteMany?: GpsPointScalarWhereInput | GpsPointScalarWhereInput[]
  }

  export type GpsStopUpdateManyWithoutTripNestedInput = {
    create?: XOR<GpsStopCreateWithoutTripInput, GpsStopUncheckedCreateWithoutTripInput> | GpsStopCreateWithoutTripInput[] | GpsStopUncheckedCreateWithoutTripInput[]
    connectOrCreate?: GpsStopCreateOrConnectWithoutTripInput | GpsStopCreateOrConnectWithoutTripInput[]
    upsert?: GpsStopUpsertWithWhereUniqueWithoutTripInput | GpsStopUpsertWithWhereUniqueWithoutTripInput[]
    createMany?: GpsStopCreateManyTripInputEnvelope
    set?: GpsStopWhereUniqueInput | GpsStopWhereUniqueInput[]
    disconnect?: GpsStopWhereUniqueInput | GpsStopWhereUniqueInput[]
    delete?: GpsStopWhereUniqueInput | GpsStopWhereUniqueInput[]
    connect?: GpsStopWhereUniqueInput | GpsStopWhereUniqueInput[]
    update?: GpsStopUpdateWithWhereUniqueWithoutTripInput | GpsStopUpdateWithWhereUniqueWithoutTripInput[]
    updateMany?: GpsStopUpdateManyWithWhereWithoutTripInput | GpsStopUpdateManyWithWhereWithoutTripInput[]
    deleteMany?: GpsStopScalarWhereInput | GpsStopScalarWhereInput[]
  }

  export type PunchUncheckedUpdateManyWithoutTripNestedInput = {
    create?: XOR<PunchCreateWithoutTripInput, PunchUncheckedCreateWithoutTripInput> | PunchCreateWithoutTripInput[] | PunchUncheckedCreateWithoutTripInput[]
    connectOrCreate?: PunchCreateOrConnectWithoutTripInput | PunchCreateOrConnectWithoutTripInput[]
    upsert?: PunchUpsertWithWhereUniqueWithoutTripInput | PunchUpsertWithWhereUniqueWithoutTripInput[]
    createMany?: PunchCreateManyTripInputEnvelope
    set?: PunchWhereUniqueInput | PunchWhereUniqueInput[]
    disconnect?: PunchWhereUniqueInput | PunchWhereUniqueInput[]
    delete?: PunchWhereUniqueInput | PunchWhereUniqueInput[]
    connect?: PunchWhereUniqueInput | PunchWhereUniqueInput[]
    update?: PunchUpdateWithWhereUniqueWithoutTripInput | PunchUpdateWithWhereUniqueWithoutTripInput[]
    updateMany?: PunchUpdateManyWithWhereWithoutTripInput | PunchUpdateManyWithWhereWithoutTripInput[]
    deleteMany?: PunchScalarWhereInput | PunchScalarWhereInput[]
  }

  export type GpsPointUncheckedUpdateManyWithoutTripNestedInput = {
    create?: XOR<GpsPointCreateWithoutTripInput, GpsPointUncheckedCreateWithoutTripInput> | GpsPointCreateWithoutTripInput[] | GpsPointUncheckedCreateWithoutTripInput[]
    connectOrCreate?: GpsPointCreateOrConnectWithoutTripInput | GpsPointCreateOrConnectWithoutTripInput[]
    upsert?: GpsPointUpsertWithWhereUniqueWithoutTripInput | GpsPointUpsertWithWhereUniqueWithoutTripInput[]
    createMany?: GpsPointCreateManyTripInputEnvelope
    set?: GpsPointWhereUniqueInput | GpsPointWhereUniqueInput[]
    disconnect?: GpsPointWhereUniqueInput | GpsPointWhereUniqueInput[]
    delete?: GpsPointWhereUniqueInput | GpsPointWhereUniqueInput[]
    connect?: GpsPointWhereUniqueInput | GpsPointWhereUniqueInput[]
    update?: GpsPointUpdateWithWhereUniqueWithoutTripInput | GpsPointUpdateWithWhereUniqueWithoutTripInput[]
    updateMany?: GpsPointUpdateManyWithWhereWithoutTripInput | GpsPointUpdateManyWithWhereWithoutTripInput[]
    deleteMany?: GpsPointScalarWhereInput | GpsPointScalarWhereInput[]
  }

  export type GpsStopUncheckedUpdateManyWithoutTripNestedInput = {
    create?: XOR<GpsStopCreateWithoutTripInput, GpsStopUncheckedCreateWithoutTripInput> | GpsStopCreateWithoutTripInput[] | GpsStopUncheckedCreateWithoutTripInput[]
    connectOrCreate?: GpsStopCreateOrConnectWithoutTripInput | GpsStopCreateOrConnectWithoutTripInput[]
    upsert?: GpsStopUpsertWithWhereUniqueWithoutTripInput | GpsStopUpsertWithWhereUniqueWithoutTripInput[]
    createMany?: GpsStopCreateManyTripInputEnvelope
    set?: GpsStopWhereUniqueInput | GpsStopWhereUniqueInput[]
    disconnect?: GpsStopWhereUniqueInput | GpsStopWhereUniqueInput[]
    delete?: GpsStopWhereUniqueInput | GpsStopWhereUniqueInput[]
    connect?: GpsStopWhereUniqueInput | GpsStopWhereUniqueInput[]
    update?: GpsStopUpdateWithWhereUniqueWithoutTripInput | GpsStopUpdateWithWhereUniqueWithoutTripInput[]
    updateMany?: GpsStopUpdateManyWithWhereWithoutTripInput | GpsStopUpdateManyWithWhereWithoutTripInput[]
    deleteMany?: GpsStopScalarWhereInput | GpsStopScalarWhereInput[]
  }

  export type TripCreateNestedOneWithoutPunchesInput = {
    create?: XOR<TripCreateWithoutPunchesInput, TripUncheckedCreateWithoutPunchesInput>
    connectOrCreate?: TripCreateOrConnectWithoutPunchesInput
    connect?: TripWhereUniqueInput
  }

  export type EnumPunchTypeFieldUpdateOperationsInput = {
    set?: $Enums.PunchType
  }

  export type NullableEnumLeadTypeFieldUpdateOperationsInput = {
    set?: $Enums.LeadType | null
  }

  export type TripUpdateOneRequiredWithoutPunchesNestedInput = {
    create?: XOR<TripCreateWithoutPunchesInput, TripUncheckedCreateWithoutPunchesInput>
    connectOrCreate?: TripCreateOrConnectWithoutPunchesInput
    upsert?: TripUpsertWithoutPunchesInput
    connect?: TripWhereUniqueInput
    update?: XOR<XOR<TripUpdateToOneWithWhereWithoutPunchesInput, TripUpdateWithoutPunchesInput>, TripUncheckedUpdateWithoutPunchesInput>
  }

  export type TripCreateNestedOneWithoutGpsPointsInput = {
    create?: XOR<TripCreateWithoutGpsPointsInput, TripUncheckedCreateWithoutGpsPointsInput>
    connectOrCreate?: TripCreateOrConnectWithoutGpsPointsInput
    connect?: TripWhereUniqueInput
  }

  export type UserCreateNestedOneWithoutGpsPointsInput = {
    create?: XOR<UserCreateWithoutGpsPointsInput, UserUncheckedCreateWithoutGpsPointsInput>
    connectOrCreate?: UserCreateOrConnectWithoutGpsPointsInput
    connect?: UserWhereUniqueInput
  }

  export type TripUpdateOneWithoutGpsPointsNestedInput = {
    create?: XOR<TripCreateWithoutGpsPointsInput, TripUncheckedCreateWithoutGpsPointsInput>
    connectOrCreate?: TripCreateOrConnectWithoutGpsPointsInput
    upsert?: TripUpsertWithoutGpsPointsInput
    disconnect?: TripWhereInput | boolean
    delete?: TripWhereInput | boolean
    connect?: TripWhereUniqueInput
    update?: XOR<XOR<TripUpdateToOneWithWhereWithoutGpsPointsInput, TripUpdateWithoutGpsPointsInput>, TripUncheckedUpdateWithoutGpsPointsInput>
  }

  export type UserUpdateOneRequiredWithoutGpsPointsNestedInput = {
    create?: XOR<UserCreateWithoutGpsPointsInput, UserUncheckedCreateWithoutGpsPointsInput>
    connectOrCreate?: UserCreateOrConnectWithoutGpsPointsInput
    upsert?: UserUpsertWithoutGpsPointsInput
    connect?: UserWhereUniqueInput
    update?: XOR<XOR<UserUpdateToOneWithWhereWithoutGpsPointsInput, UserUpdateWithoutGpsPointsInput>, UserUncheckedUpdateWithoutGpsPointsInput>
  }

  export type TripCreateNestedOneWithoutStopsInput = {
    create?: XOR<TripCreateWithoutStopsInput, TripUncheckedCreateWithoutStopsInput>
    connectOrCreate?: TripCreateOrConnectWithoutStopsInput
    connect?: TripWhereUniqueInput
  }

  export type NullableIntFieldUpdateOperationsInput = {
    set?: number | null
    increment?: number
    decrement?: number
    multiply?: number
    divide?: number
  }

  export type TripUpdateOneRequiredWithoutStopsNestedInput = {
    create?: XOR<TripCreateWithoutStopsInput, TripUncheckedCreateWithoutStopsInput>
    connectOrCreate?: TripCreateOrConnectWithoutStopsInput
    upsert?: TripUpsertWithoutStopsInput
    connect?: TripWhereUniqueInput
    update?: XOR<XOR<TripUpdateToOneWithWhereWithoutStopsInput, TripUpdateWithoutStopsInput>, TripUncheckedUpdateWithoutStopsInput>
  }

  export type UserCreateNestedOneWithoutNotificationsInput = {
    create?: XOR<UserCreateWithoutNotificationsInput, UserUncheckedCreateWithoutNotificationsInput>
    connectOrCreate?: UserCreateOrConnectWithoutNotificationsInput
    connect?: UserWhereUniqueInput
  }

  export type EnumNotificationTypeFieldUpdateOperationsInput = {
    set?: $Enums.NotificationType
  }

  export type UserUpdateOneRequiredWithoutNotificationsNestedInput = {
    create?: XOR<UserCreateWithoutNotificationsInput, UserUncheckedCreateWithoutNotificationsInput>
    connectOrCreate?: UserCreateOrConnectWithoutNotificationsInput
    upsert?: UserUpsertWithoutNotificationsInput
    connect?: UserWhereUniqueInput
    update?: XOR<XOR<UserUpdateToOneWithWhereWithoutNotificationsInput, UserUpdateWithoutNotificationsInput>, UserUncheckedUpdateWithoutNotificationsInput>
  }

  export type NestedStringFilter<$PrismaModel = never> = {
    equals?: string | StringFieldRefInput<$PrismaModel>
    in?: string[]
    notIn?: string[]
    lt?: string | StringFieldRefInput<$PrismaModel>
    lte?: string | StringFieldRefInput<$PrismaModel>
    gt?: string | StringFieldRefInput<$PrismaModel>
    gte?: string | StringFieldRefInput<$PrismaModel>
    contains?: string | StringFieldRefInput<$PrismaModel>
    startsWith?: string | StringFieldRefInput<$PrismaModel>
    endsWith?: string | StringFieldRefInput<$PrismaModel>
    not?: NestedStringFilter<$PrismaModel> | string
  }

  export type NestedStringNullableFilter<$PrismaModel = never> = {
    equals?: string | StringFieldRefInput<$PrismaModel> | null
    in?: string[] | null
    notIn?: string[] | null
    lt?: string | StringFieldRefInput<$PrismaModel>
    lte?: string | StringFieldRefInput<$PrismaModel>
    gt?: string | StringFieldRefInput<$PrismaModel>
    gte?: string | StringFieldRefInput<$PrismaModel>
    contains?: string | StringFieldRefInput<$PrismaModel>
    startsWith?: string | StringFieldRefInput<$PrismaModel>
    endsWith?: string | StringFieldRefInput<$PrismaModel>
    not?: NestedStringNullableFilter<$PrismaModel> | string | null
  }

  export type NestedEnumUserRoleFilter<$PrismaModel = never> = {
    equals?: $Enums.UserRole | EnumUserRoleFieldRefInput<$PrismaModel>
    in?: $Enums.UserRole[]
    notIn?: $Enums.UserRole[]
    not?: NestedEnumUserRoleFilter<$PrismaModel> | $Enums.UserRole
  }

  export type NestedEnumUserStatusFilter<$PrismaModel = never> = {
    equals?: $Enums.UserStatus | EnumUserStatusFieldRefInput<$PrismaModel>
    in?: $Enums.UserStatus[]
    notIn?: $Enums.UserStatus[]
    not?: NestedEnumUserStatusFilter<$PrismaModel> | $Enums.UserStatus
  }

  export type NestedBoolFilter<$PrismaModel = never> = {
    equals?: boolean | BooleanFieldRefInput<$PrismaModel>
    not?: NestedBoolFilter<$PrismaModel> | boolean
  }

  export type NestedEnumEmployeePresenceFilter<$PrismaModel = never> = {
    equals?: $Enums.EmployeePresence | EnumEmployeePresenceFieldRefInput<$PrismaModel>
    in?: $Enums.EmployeePresence[]
    notIn?: $Enums.EmployeePresence[]
    not?: NestedEnumEmployeePresenceFilter<$PrismaModel> | $Enums.EmployeePresence
  }

  export type NestedDateTimeNullableFilter<$PrismaModel = never> = {
    equals?: Date | string | DateTimeFieldRefInput<$PrismaModel> | null
    in?: Date[] | string[] | null
    notIn?: Date[] | string[] | null
    lt?: Date | string | DateTimeFieldRefInput<$PrismaModel>
    lte?: Date | string | DateTimeFieldRefInput<$PrismaModel>
    gt?: Date | string | DateTimeFieldRefInput<$PrismaModel>
    gte?: Date | string | DateTimeFieldRefInput<$PrismaModel>
    not?: NestedDateTimeNullableFilter<$PrismaModel> | Date | string | null
  }

  export type NestedDateTimeFilter<$PrismaModel = never> = {
    equals?: Date | string | DateTimeFieldRefInput<$PrismaModel>
    in?: Date[] | string[]
    notIn?: Date[] | string[]
    lt?: Date | string | DateTimeFieldRefInput<$PrismaModel>
    lte?: Date | string | DateTimeFieldRefInput<$PrismaModel>
    gt?: Date | string | DateTimeFieldRefInput<$PrismaModel>
    gte?: Date | string | DateTimeFieldRefInput<$PrismaModel>
    not?: NestedDateTimeFilter<$PrismaModel> | Date | string
  }

  export type NestedStringWithAggregatesFilter<$PrismaModel = never> = {
    equals?: string | StringFieldRefInput<$PrismaModel>
    in?: string[]
    notIn?: string[]
    lt?: string | StringFieldRefInput<$PrismaModel>
    lte?: string | StringFieldRefInput<$PrismaModel>
    gt?: string | StringFieldRefInput<$PrismaModel>
    gte?: string | StringFieldRefInput<$PrismaModel>
    contains?: string | StringFieldRefInput<$PrismaModel>
    startsWith?: string | StringFieldRefInput<$PrismaModel>
    endsWith?: string | StringFieldRefInput<$PrismaModel>
    not?: NestedStringWithAggregatesFilter<$PrismaModel> | string
    _count?: NestedIntFilter<$PrismaModel>
    _min?: NestedStringFilter<$PrismaModel>
    _max?: NestedStringFilter<$PrismaModel>
  }

  export type NestedIntFilter<$PrismaModel = never> = {
    equals?: number | IntFieldRefInput<$PrismaModel>
    in?: number[]
    notIn?: number[]
    lt?: number | IntFieldRefInput<$PrismaModel>
    lte?: number | IntFieldRefInput<$PrismaModel>
    gt?: number | IntFieldRefInput<$PrismaModel>
    gte?: number | IntFieldRefInput<$PrismaModel>
    not?: NestedIntFilter<$PrismaModel> | number
  }

  export type NestedStringNullableWithAggregatesFilter<$PrismaModel = never> = {
    equals?: string | StringFieldRefInput<$PrismaModel> | null
    in?: string[] | null
    notIn?: string[] | null
    lt?: string | StringFieldRefInput<$PrismaModel>
    lte?: string | StringFieldRefInput<$PrismaModel>
    gt?: string | StringFieldRefInput<$PrismaModel>
    gte?: string | StringFieldRefInput<$PrismaModel>
    contains?: string | StringFieldRefInput<$PrismaModel>
    startsWith?: string | StringFieldRefInput<$PrismaModel>
    endsWith?: string | StringFieldRefInput<$PrismaModel>
    not?: NestedStringNullableWithAggregatesFilter<$PrismaModel> | string | null
    _count?: NestedIntNullableFilter<$PrismaModel>
    _min?: NestedStringNullableFilter<$PrismaModel>
    _max?: NestedStringNullableFilter<$PrismaModel>
  }

  export type NestedIntNullableFilter<$PrismaModel = never> = {
    equals?: number | IntFieldRefInput<$PrismaModel> | null
    in?: number[] | null
    notIn?: number[] | null
    lt?: number | IntFieldRefInput<$PrismaModel>
    lte?: number | IntFieldRefInput<$PrismaModel>
    gt?: number | IntFieldRefInput<$PrismaModel>
    gte?: number | IntFieldRefInput<$PrismaModel>
    not?: NestedIntNullableFilter<$PrismaModel> | number | null
  }

  export type NestedEnumUserRoleWithAggregatesFilter<$PrismaModel = never> = {
    equals?: $Enums.UserRole | EnumUserRoleFieldRefInput<$PrismaModel>
    in?: $Enums.UserRole[]
    notIn?: $Enums.UserRole[]
    not?: NestedEnumUserRoleWithAggregatesFilter<$PrismaModel> | $Enums.UserRole
    _count?: NestedIntFilter<$PrismaModel>
    _min?: NestedEnumUserRoleFilter<$PrismaModel>
    _max?: NestedEnumUserRoleFilter<$PrismaModel>
  }

  export type NestedEnumUserStatusWithAggregatesFilter<$PrismaModel = never> = {
    equals?: $Enums.UserStatus | EnumUserStatusFieldRefInput<$PrismaModel>
    in?: $Enums.UserStatus[]
    notIn?: $Enums.UserStatus[]
    not?: NestedEnumUserStatusWithAggregatesFilter<$PrismaModel> | $Enums.UserStatus
    _count?: NestedIntFilter<$PrismaModel>
    _min?: NestedEnumUserStatusFilter<$PrismaModel>
    _max?: NestedEnumUserStatusFilter<$PrismaModel>
  }

  export type NestedBoolWithAggregatesFilter<$PrismaModel = never> = {
    equals?: boolean | BooleanFieldRefInput<$PrismaModel>
    not?: NestedBoolWithAggregatesFilter<$PrismaModel> | boolean
    _count?: NestedIntFilter<$PrismaModel>
    _min?: NestedBoolFilter<$PrismaModel>
    _max?: NestedBoolFilter<$PrismaModel>
  }

  export type NestedEnumEmployeePresenceWithAggregatesFilter<$PrismaModel = never> = {
    equals?: $Enums.EmployeePresence | EnumEmployeePresenceFieldRefInput<$PrismaModel>
    in?: $Enums.EmployeePresence[]
    notIn?: $Enums.EmployeePresence[]
    not?: NestedEnumEmployeePresenceWithAggregatesFilter<$PrismaModel> | $Enums.EmployeePresence
    _count?: NestedIntFilter<$PrismaModel>
    _min?: NestedEnumEmployeePresenceFilter<$PrismaModel>
    _max?: NestedEnumEmployeePresenceFilter<$PrismaModel>
  }

  export type NestedDateTimeNullableWithAggregatesFilter<$PrismaModel = never> = {
    equals?: Date | string | DateTimeFieldRefInput<$PrismaModel> | null
    in?: Date[] | string[] | null
    notIn?: Date[] | string[] | null
    lt?: Date | string | DateTimeFieldRefInput<$PrismaModel>
    lte?: Date | string | DateTimeFieldRefInput<$PrismaModel>
    gt?: Date | string | DateTimeFieldRefInput<$PrismaModel>
    gte?: Date | string | DateTimeFieldRefInput<$PrismaModel>
    not?: NestedDateTimeNullableWithAggregatesFilter<$PrismaModel> | Date | string | null
    _count?: NestedIntNullableFilter<$PrismaModel>
    _min?: NestedDateTimeNullableFilter<$PrismaModel>
    _max?: NestedDateTimeNullableFilter<$PrismaModel>
  }

  export type NestedDateTimeWithAggregatesFilter<$PrismaModel = never> = {
    equals?: Date | string | DateTimeFieldRefInput<$PrismaModel>
    in?: Date[] | string[]
    notIn?: Date[] | string[]
    lt?: Date | string | DateTimeFieldRefInput<$PrismaModel>
    lte?: Date | string | DateTimeFieldRefInput<$PrismaModel>
    gt?: Date | string | DateTimeFieldRefInput<$PrismaModel>
    gte?: Date | string | DateTimeFieldRefInput<$PrismaModel>
    not?: NestedDateTimeWithAggregatesFilter<$PrismaModel> | Date | string
    _count?: NestedIntFilter<$PrismaModel>
    _min?: NestedDateTimeFilter<$PrismaModel>
    _max?: NestedDateTimeFilter<$PrismaModel>
  }
  export type NestedJsonNullableFilter<$PrismaModel = never> =
    | PatchUndefined<
        Either<Required<NestedJsonNullableFilterBase<$PrismaModel>>, Exclude<keyof Required<NestedJsonNullableFilterBase<$PrismaModel>>, 'path'>>,
        Required<NestedJsonNullableFilterBase<$PrismaModel>>
      >
    | OptionalFlat<Omit<Required<NestedJsonNullableFilterBase<$PrismaModel>>, 'path'>>

  export type NestedJsonNullableFilterBase<$PrismaModel = never> = {
    equals?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | JsonNullValueFilter
    path?: string
    mode?: QueryMode | EnumQueryModeFieldRefInput<$PrismaModel>
    string_contains?: string | StringFieldRefInput<$PrismaModel>
    string_starts_with?: string | StringFieldRefInput<$PrismaModel>
    string_ends_with?: string | StringFieldRefInput<$PrismaModel>
    array_starts_with?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | null
    array_ends_with?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | null
    not?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | JsonNullValueFilter
  }

  export type NestedFloatNullableFilter<$PrismaModel = never> = {
    equals?: number | FloatFieldRefInput<$PrismaModel> | null
    in?: number[] | null
    notIn?: number[] | null
    lt?: number | FloatFieldRefInput<$PrismaModel>
    lte?: number | FloatFieldRefInput<$PrismaModel>
    gt?: number | FloatFieldRefInput<$PrismaModel>
    gte?: number | FloatFieldRefInput<$PrismaModel>
    not?: NestedFloatNullableFilter<$PrismaModel> | number | null
  }

  export type NestedEnumVehicleTypeNullableFilter<$PrismaModel = never> = {
    equals?: $Enums.VehicleType | EnumVehicleTypeFieldRefInput<$PrismaModel> | null
    in?: $Enums.VehicleType[] | null
    notIn?: $Enums.VehicleType[] | null
    not?: NestedEnumVehicleTypeNullableFilter<$PrismaModel> | $Enums.VehicleType | null
  }

  export type NestedEnumFuelTypeNullableFilter<$PrismaModel = never> = {
    equals?: $Enums.FuelType | EnumFuelTypeFieldRefInput<$PrismaModel> | null
    in?: $Enums.FuelType[] | null
    notIn?: $Enums.FuelType[] | null
    not?: NestedEnumFuelTypeNullableFilter<$PrismaModel> | $Enums.FuelType | null
  }

  export type NestedEnumTripStatusFilter<$PrismaModel = never> = {
    equals?: $Enums.TripStatus | EnumTripStatusFieldRefInput<$PrismaModel>
    in?: $Enums.TripStatus[]
    notIn?: $Enums.TripStatus[]
    not?: NestedEnumTripStatusFilter<$PrismaModel> | $Enums.TripStatus
  }

  export type NestedFloatFilter<$PrismaModel = never> = {
    equals?: number | FloatFieldRefInput<$PrismaModel>
    in?: number[]
    notIn?: number[]
    lt?: number | FloatFieldRefInput<$PrismaModel>
    lte?: number | FloatFieldRefInput<$PrismaModel>
    gt?: number | FloatFieldRefInput<$PrismaModel>
    gte?: number | FloatFieldRefInput<$PrismaModel>
    not?: NestedFloatFilter<$PrismaModel> | number
  }

  export type NestedFloatNullableWithAggregatesFilter<$PrismaModel = never> = {
    equals?: number | FloatFieldRefInput<$PrismaModel> | null
    in?: number[] | null
    notIn?: number[] | null
    lt?: number | FloatFieldRefInput<$PrismaModel>
    lte?: number | FloatFieldRefInput<$PrismaModel>
    gt?: number | FloatFieldRefInput<$PrismaModel>
    gte?: number | FloatFieldRefInput<$PrismaModel>
    not?: NestedFloatNullableWithAggregatesFilter<$PrismaModel> | number | null
    _count?: NestedIntNullableFilter<$PrismaModel>
    _avg?: NestedFloatNullableFilter<$PrismaModel>
    _sum?: NestedFloatNullableFilter<$PrismaModel>
    _min?: NestedFloatNullableFilter<$PrismaModel>
    _max?: NestedFloatNullableFilter<$PrismaModel>
  }

  export type NestedEnumVehicleTypeNullableWithAggregatesFilter<$PrismaModel = never> = {
    equals?: $Enums.VehicleType | EnumVehicleTypeFieldRefInput<$PrismaModel> | null
    in?: $Enums.VehicleType[] | null
    notIn?: $Enums.VehicleType[] | null
    not?: NestedEnumVehicleTypeNullableWithAggregatesFilter<$PrismaModel> | $Enums.VehicleType | null
    _count?: NestedIntNullableFilter<$PrismaModel>
    _min?: NestedEnumVehicleTypeNullableFilter<$PrismaModel>
    _max?: NestedEnumVehicleTypeNullableFilter<$PrismaModel>
  }

  export type NestedEnumFuelTypeNullableWithAggregatesFilter<$PrismaModel = never> = {
    equals?: $Enums.FuelType | EnumFuelTypeFieldRefInput<$PrismaModel> | null
    in?: $Enums.FuelType[] | null
    notIn?: $Enums.FuelType[] | null
    not?: NestedEnumFuelTypeNullableWithAggregatesFilter<$PrismaModel> | $Enums.FuelType | null
    _count?: NestedIntNullableFilter<$PrismaModel>
    _min?: NestedEnumFuelTypeNullableFilter<$PrismaModel>
    _max?: NestedEnumFuelTypeNullableFilter<$PrismaModel>
  }

  export type NestedEnumTripStatusWithAggregatesFilter<$PrismaModel = never> = {
    equals?: $Enums.TripStatus | EnumTripStatusFieldRefInput<$PrismaModel>
    in?: $Enums.TripStatus[]
    notIn?: $Enums.TripStatus[]
    not?: NestedEnumTripStatusWithAggregatesFilter<$PrismaModel> | $Enums.TripStatus
    _count?: NestedIntFilter<$PrismaModel>
    _min?: NestedEnumTripStatusFilter<$PrismaModel>
    _max?: NestedEnumTripStatusFilter<$PrismaModel>
  }

  export type NestedFloatWithAggregatesFilter<$PrismaModel = never> = {
    equals?: number | FloatFieldRefInput<$PrismaModel>
    in?: number[]
    notIn?: number[]
    lt?: number | FloatFieldRefInput<$PrismaModel>
    lte?: number | FloatFieldRefInput<$PrismaModel>
    gt?: number | FloatFieldRefInput<$PrismaModel>
    gte?: number | FloatFieldRefInput<$PrismaModel>
    not?: NestedFloatWithAggregatesFilter<$PrismaModel> | number
    _count?: NestedIntFilter<$PrismaModel>
    _avg?: NestedFloatFilter<$PrismaModel>
    _sum?: NestedFloatFilter<$PrismaModel>
    _min?: NestedFloatFilter<$PrismaModel>
    _max?: NestedFloatFilter<$PrismaModel>
  }

  export type NestedIntWithAggregatesFilter<$PrismaModel = never> = {
    equals?: number | IntFieldRefInput<$PrismaModel>
    in?: number[]
    notIn?: number[]
    lt?: number | IntFieldRefInput<$PrismaModel>
    lte?: number | IntFieldRefInput<$PrismaModel>
    gt?: number | IntFieldRefInput<$PrismaModel>
    gte?: number | IntFieldRefInput<$PrismaModel>
    not?: NestedIntWithAggregatesFilter<$PrismaModel> | number
    _count?: NestedIntFilter<$PrismaModel>
    _avg?: NestedFloatFilter<$PrismaModel>
    _sum?: NestedIntFilter<$PrismaModel>
    _min?: NestedIntFilter<$PrismaModel>
    _max?: NestedIntFilter<$PrismaModel>
  }

  export type NestedEnumPunchTypeFilter<$PrismaModel = never> = {
    equals?: $Enums.PunchType | EnumPunchTypeFieldRefInput<$PrismaModel>
    in?: $Enums.PunchType[]
    notIn?: $Enums.PunchType[]
    not?: NestedEnumPunchTypeFilter<$PrismaModel> | $Enums.PunchType
  }

  export type NestedEnumLeadTypeNullableFilter<$PrismaModel = never> = {
    equals?: $Enums.LeadType | EnumLeadTypeFieldRefInput<$PrismaModel> | null
    in?: $Enums.LeadType[] | null
    notIn?: $Enums.LeadType[] | null
    not?: NestedEnumLeadTypeNullableFilter<$PrismaModel> | $Enums.LeadType | null
  }

  export type NestedEnumPunchTypeWithAggregatesFilter<$PrismaModel = never> = {
    equals?: $Enums.PunchType | EnumPunchTypeFieldRefInput<$PrismaModel>
    in?: $Enums.PunchType[]
    notIn?: $Enums.PunchType[]
    not?: NestedEnumPunchTypeWithAggregatesFilter<$PrismaModel> | $Enums.PunchType
    _count?: NestedIntFilter<$PrismaModel>
    _min?: NestedEnumPunchTypeFilter<$PrismaModel>
    _max?: NestedEnumPunchTypeFilter<$PrismaModel>
  }

  export type NestedEnumLeadTypeNullableWithAggregatesFilter<$PrismaModel = never> = {
    equals?: $Enums.LeadType | EnumLeadTypeFieldRefInput<$PrismaModel> | null
    in?: $Enums.LeadType[] | null
    notIn?: $Enums.LeadType[] | null
    not?: NestedEnumLeadTypeNullableWithAggregatesFilter<$PrismaModel> | $Enums.LeadType | null
    _count?: NestedIntNullableFilter<$PrismaModel>
    _min?: NestedEnumLeadTypeNullableFilter<$PrismaModel>
    _max?: NestedEnumLeadTypeNullableFilter<$PrismaModel>
  }

  export type NestedIntNullableWithAggregatesFilter<$PrismaModel = never> = {
    equals?: number | IntFieldRefInput<$PrismaModel> | null
    in?: number[] | null
    notIn?: number[] | null
    lt?: number | IntFieldRefInput<$PrismaModel>
    lte?: number | IntFieldRefInput<$PrismaModel>
    gt?: number | IntFieldRefInput<$PrismaModel>
    gte?: number | IntFieldRefInput<$PrismaModel>
    not?: NestedIntNullableWithAggregatesFilter<$PrismaModel> | number | null
    _count?: NestedIntNullableFilter<$PrismaModel>
    _avg?: NestedFloatNullableFilter<$PrismaModel>
    _sum?: NestedIntNullableFilter<$PrismaModel>
    _min?: NestedIntNullableFilter<$PrismaModel>
    _max?: NestedIntNullableFilter<$PrismaModel>
  }

  export type NestedEnumNotificationTypeFilter<$PrismaModel = never> = {
    equals?: $Enums.NotificationType | EnumNotificationTypeFieldRefInput<$PrismaModel>
    in?: $Enums.NotificationType[]
    notIn?: $Enums.NotificationType[]
    not?: NestedEnumNotificationTypeFilter<$PrismaModel> | $Enums.NotificationType
  }

  export type NestedEnumNotificationTypeWithAggregatesFilter<$PrismaModel = never> = {
    equals?: $Enums.NotificationType | EnumNotificationTypeFieldRefInput<$PrismaModel>
    in?: $Enums.NotificationType[]
    notIn?: $Enums.NotificationType[]
    not?: NestedEnumNotificationTypeWithAggregatesFilter<$PrismaModel> | $Enums.NotificationType
    _count?: NestedIntFilter<$PrismaModel>
    _min?: NestedEnumNotificationTypeFilter<$PrismaModel>
    _max?: NestedEnumNotificationTypeFilter<$PrismaModel>
  }
  export type NestedJsonFilter<$PrismaModel = never> =
    | PatchUndefined<
        Either<Required<NestedJsonFilterBase<$PrismaModel>>, Exclude<keyof Required<NestedJsonFilterBase<$PrismaModel>>, 'path'>>,
        Required<NestedJsonFilterBase<$PrismaModel>>
      >
    | OptionalFlat<Omit<Required<NestedJsonFilterBase<$PrismaModel>>, 'path'>>

  export type NestedJsonFilterBase<$PrismaModel = never> = {
    equals?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | JsonNullValueFilter
    path?: string
    mode?: QueryMode | EnumQueryModeFieldRefInput<$PrismaModel>
    string_contains?: string | StringFieldRefInput<$PrismaModel>
    string_starts_with?: string | StringFieldRefInput<$PrismaModel>
    string_ends_with?: string | StringFieldRefInput<$PrismaModel>
    array_starts_with?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | null
    array_ends_with?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | null
    not?: InputJsonValue | JsonFieldRefInput<$PrismaModel> | JsonNullValueFilter
  }

  export type UserCreateWithoutDirectReportsInput = {
    id?: string
    uid: string
    email: string
    passwordHash: string
    fullName: string
    employeeCode: string
    mobileNumber?: string | null
    sittingLocation?: string | null
    role?: $Enums.UserRole
    deviceId?: string | null
    profileImage?: string | null
    status?: $Enums.UserStatus
    fcmToken?: string | null
    isRooted?: boolean
    presence?: $Enums.EmployeePresence
    lastSeenAt?: Date | string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    reportingManager?: UserCreateNestedOneWithoutDirectReportsInput
    refreshTokens?: RefreshTokenCreateNestedManyWithoutUserInput
    trips?: TripCreateNestedManyWithoutUserInput
    gpsPoints?: GpsPointCreateNestedManyWithoutUserInput
    auditLogs?: AuditLogCreateNestedManyWithoutActorInput
    notifications?: NotificationCreateNestedManyWithoutUserInput
  }

  export type UserUncheckedCreateWithoutDirectReportsInput = {
    id?: string
    uid: string
    email: string
    passwordHash: string
    fullName: string
    employeeCode: string
    mobileNumber?: string | null
    sittingLocation?: string | null
    reportingManagerId?: string | null
    role?: $Enums.UserRole
    deviceId?: string | null
    profileImage?: string | null
    status?: $Enums.UserStatus
    fcmToken?: string | null
    isRooted?: boolean
    presence?: $Enums.EmployeePresence
    lastSeenAt?: Date | string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    refreshTokens?: RefreshTokenUncheckedCreateNestedManyWithoutUserInput
    trips?: TripUncheckedCreateNestedManyWithoutUserInput
    gpsPoints?: GpsPointUncheckedCreateNestedManyWithoutUserInput
    auditLogs?: AuditLogUncheckedCreateNestedManyWithoutActorInput
    notifications?: NotificationUncheckedCreateNestedManyWithoutUserInput
  }

  export type UserCreateOrConnectWithoutDirectReportsInput = {
    where: UserWhereUniqueInput
    create: XOR<UserCreateWithoutDirectReportsInput, UserUncheckedCreateWithoutDirectReportsInput>
  }

  export type UserCreateWithoutReportingManagerInput = {
    id?: string
    uid: string
    email: string
    passwordHash: string
    fullName: string
    employeeCode: string
    mobileNumber?: string | null
    sittingLocation?: string | null
    role?: $Enums.UserRole
    deviceId?: string | null
    profileImage?: string | null
    status?: $Enums.UserStatus
    fcmToken?: string | null
    isRooted?: boolean
    presence?: $Enums.EmployeePresence
    lastSeenAt?: Date | string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    directReports?: UserCreateNestedManyWithoutReportingManagerInput
    refreshTokens?: RefreshTokenCreateNestedManyWithoutUserInput
    trips?: TripCreateNestedManyWithoutUserInput
    gpsPoints?: GpsPointCreateNestedManyWithoutUserInput
    auditLogs?: AuditLogCreateNestedManyWithoutActorInput
    notifications?: NotificationCreateNestedManyWithoutUserInput
  }

  export type UserUncheckedCreateWithoutReportingManagerInput = {
    id?: string
    uid: string
    email: string
    passwordHash: string
    fullName: string
    employeeCode: string
    mobileNumber?: string | null
    sittingLocation?: string | null
    role?: $Enums.UserRole
    deviceId?: string | null
    profileImage?: string | null
    status?: $Enums.UserStatus
    fcmToken?: string | null
    isRooted?: boolean
    presence?: $Enums.EmployeePresence
    lastSeenAt?: Date | string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    directReports?: UserUncheckedCreateNestedManyWithoutReportingManagerInput
    refreshTokens?: RefreshTokenUncheckedCreateNestedManyWithoutUserInput
    trips?: TripUncheckedCreateNestedManyWithoutUserInput
    gpsPoints?: GpsPointUncheckedCreateNestedManyWithoutUserInput
    auditLogs?: AuditLogUncheckedCreateNestedManyWithoutActorInput
    notifications?: NotificationUncheckedCreateNestedManyWithoutUserInput
  }

  export type UserCreateOrConnectWithoutReportingManagerInput = {
    where: UserWhereUniqueInput
    create: XOR<UserCreateWithoutReportingManagerInput, UserUncheckedCreateWithoutReportingManagerInput>
  }

  export type UserCreateManyReportingManagerInputEnvelope = {
    data: UserCreateManyReportingManagerInput | UserCreateManyReportingManagerInput[]
  }

  export type RefreshTokenCreateWithoutUserInput = {
    id?: string
    tokenHash: string
    deviceId?: string | null
    expiresAt: Date | string
    createdAt?: Date | string
  }

  export type RefreshTokenUncheckedCreateWithoutUserInput = {
    id?: string
    tokenHash: string
    deviceId?: string | null
    expiresAt: Date | string
    createdAt?: Date | string
  }

  export type RefreshTokenCreateOrConnectWithoutUserInput = {
    where: RefreshTokenWhereUniqueInput
    create: XOR<RefreshTokenCreateWithoutUserInput, RefreshTokenUncheckedCreateWithoutUserInput>
  }

  export type RefreshTokenCreateManyUserInputEnvelope = {
    data: RefreshTokenCreateManyUserInput | RefreshTokenCreateManyUserInput[]
  }

  export type TripCreateWithoutUserInput = {
    id?: string
    tripId?: string
    city?: string | null
    fromLocation?: string | null
    toLocation?: string | null
    destinationLat?: number | null
    destinationLng?: number | null
    googlePlaceId?: string | null
    plannedDistance?: number | null
    vehicleType?: $Enums.VehicleType | null
    fuelType?: $Enums.FuelType | null
    purpose?: string | null
    notes?: string | null
    status?: $Enums.TripStatus
    totalDistance?: number
    travelDuration?: number
    idleTime?: number
    meetingDuration?: number
    productivityScore?: number | null
    tripEfficiency?: number | null
    startedAt?: Date | string | null
    arrivedAt?: Date | string | null
    completedAt?: Date | string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    punches?: PunchCreateNestedManyWithoutTripInput
    gpsPoints?: GpsPointCreateNestedManyWithoutTripInput
    stops?: GpsStopCreateNestedManyWithoutTripInput
  }

  export type TripUncheckedCreateWithoutUserInput = {
    id?: string
    tripId?: string
    city?: string | null
    fromLocation?: string | null
    toLocation?: string | null
    destinationLat?: number | null
    destinationLng?: number | null
    googlePlaceId?: string | null
    plannedDistance?: number | null
    vehicleType?: $Enums.VehicleType | null
    fuelType?: $Enums.FuelType | null
    purpose?: string | null
    notes?: string | null
    status?: $Enums.TripStatus
    totalDistance?: number
    travelDuration?: number
    idleTime?: number
    meetingDuration?: number
    productivityScore?: number | null
    tripEfficiency?: number | null
    startedAt?: Date | string | null
    arrivedAt?: Date | string | null
    completedAt?: Date | string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    punches?: PunchUncheckedCreateNestedManyWithoutTripInput
    gpsPoints?: GpsPointUncheckedCreateNestedManyWithoutTripInput
    stops?: GpsStopUncheckedCreateNestedManyWithoutTripInput
  }

  export type TripCreateOrConnectWithoutUserInput = {
    where: TripWhereUniqueInput
    create: XOR<TripCreateWithoutUserInput, TripUncheckedCreateWithoutUserInput>
  }

  export type TripCreateManyUserInputEnvelope = {
    data: TripCreateManyUserInput | TripCreateManyUserInput[]
  }

  export type GpsPointCreateWithoutUserInput = {
    id?: string
    clientPointId?: string | null
    latitude: number
    longitude: number
    accuracy?: number | null
    speed?: number | null
    bearing?: number | null
    batteryLevel?: number | null
    timestamp: Date | string
    isSmoothed?: boolean
    createdAt?: Date | string
    trip?: TripCreateNestedOneWithoutGpsPointsInput
  }

  export type GpsPointUncheckedCreateWithoutUserInput = {
    id?: string
    tripId?: string | null
    clientPointId?: string | null
    latitude: number
    longitude: number
    accuracy?: number | null
    speed?: number | null
    bearing?: number | null
    batteryLevel?: number | null
    timestamp: Date | string
    isSmoothed?: boolean
    createdAt?: Date | string
  }

  export type GpsPointCreateOrConnectWithoutUserInput = {
    where: GpsPointWhereUniqueInput
    create: XOR<GpsPointCreateWithoutUserInput, GpsPointUncheckedCreateWithoutUserInput>
  }

  export type GpsPointCreateManyUserInputEnvelope = {
    data: GpsPointCreateManyUserInput | GpsPointCreateManyUserInput[]
  }

  export type AuditLogCreateWithoutActorInput = {
    id?: string
    actorEmail?: string | null
    action: string
    targetType?: string | null
    targetId?: string | null
    metadata?: NullableJsonNullValueInput | InputJsonValue
    ipAddress?: string | null
    userAgent?: string | null
    createdAt?: Date | string
  }

  export type AuditLogUncheckedCreateWithoutActorInput = {
    id?: string
    actorEmail?: string | null
    action: string
    targetType?: string | null
    targetId?: string | null
    metadata?: NullableJsonNullValueInput | InputJsonValue
    ipAddress?: string | null
    userAgent?: string | null
    createdAt?: Date | string
  }

  export type AuditLogCreateOrConnectWithoutActorInput = {
    where: AuditLogWhereUniqueInput
    create: XOR<AuditLogCreateWithoutActorInput, AuditLogUncheckedCreateWithoutActorInput>
  }

  export type AuditLogCreateManyActorInputEnvelope = {
    data: AuditLogCreateManyActorInput | AuditLogCreateManyActorInput[]
  }

  export type NotificationCreateWithoutUserInput = {
    id?: string
    type: $Enums.NotificationType
    title: string
    body: string
    data?: NullableJsonNullValueInput | InputJsonValue
    read?: boolean
    sentAt?: Date | string
  }

  export type NotificationUncheckedCreateWithoutUserInput = {
    id?: string
    type: $Enums.NotificationType
    title: string
    body: string
    data?: NullableJsonNullValueInput | InputJsonValue
    read?: boolean
    sentAt?: Date | string
  }

  export type NotificationCreateOrConnectWithoutUserInput = {
    where: NotificationWhereUniqueInput
    create: XOR<NotificationCreateWithoutUserInput, NotificationUncheckedCreateWithoutUserInput>
  }

  export type NotificationCreateManyUserInputEnvelope = {
    data: NotificationCreateManyUserInput | NotificationCreateManyUserInput[]
  }

  export type UserUpsertWithoutDirectReportsInput = {
    update: XOR<UserUpdateWithoutDirectReportsInput, UserUncheckedUpdateWithoutDirectReportsInput>
    create: XOR<UserCreateWithoutDirectReportsInput, UserUncheckedCreateWithoutDirectReportsInput>
    where?: UserWhereInput
  }

  export type UserUpdateToOneWithWhereWithoutDirectReportsInput = {
    where?: UserWhereInput
    data: XOR<UserUpdateWithoutDirectReportsInput, UserUncheckedUpdateWithoutDirectReportsInput>
  }

  export type UserUpdateWithoutDirectReportsInput = {
    id?: StringFieldUpdateOperationsInput | string
    uid?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    fullName?: StringFieldUpdateOperationsInput | string
    employeeCode?: StringFieldUpdateOperationsInput | string
    mobileNumber?: NullableStringFieldUpdateOperationsInput | string | null
    sittingLocation?: NullableStringFieldUpdateOperationsInput | string | null
    role?: EnumUserRoleFieldUpdateOperationsInput | $Enums.UserRole
    deviceId?: NullableStringFieldUpdateOperationsInput | string | null
    profileImage?: NullableStringFieldUpdateOperationsInput | string | null
    status?: EnumUserStatusFieldUpdateOperationsInput | $Enums.UserStatus
    fcmToken?: NullableStringFieldUpdateOperationsInput | string | null
    isRooted?: BoolFieldUpdateOperationsInput | boolean
    presence?: EnumEmployeePresenceFieldUpdateOperationsInput | $Enums.EmployeePresence
    lastSeenAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    reportingManager?: UserUpdateOneWithoutDirectReportsNestedInput
    refreshTokens?: RefreshTokenUpdateManyWithoutUserNestedInput
    trips?: TripUpdateManyWithoutUserNestedInput
    gpsPoints?: GpsPointUpdateManyWithoutUserNestedInput
    auditLogs?: AuditLogUpdateManyWithoutActorNestedInput
    notifications?: NotificationUpdateManyWithoutUserNestedInput
  }

  export type UserUncheckedUpdateWithoutDirectReportsInput = {
    id?: StringFieldUpdateOperationsInput | string
    uid?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    fullName?: StringFieldUpdateOperationsInput | string
    employeeCode?: StringFieldUpdateOperationsInput | string
    mobileNumber?: NullableStringFieldUpdateOperationsInput | string | null
    sittingLocation?: NullableStringFieldUpdateOperationsInput | string | null
    reportingManagerId?: NullableStringFieldUpdateOperationsInput | string | null
    role?: EnumUserRoleFieldUpdateOperationsInput | $Enums.UserRole
    deviceId?: NullableStringFieldUpdateOperationsInput | string | null
    profileImage?: NullableStringFieldUpdateOperationsInput | string | null
    status?: EnumUserStatusFieldUpdateOperationsInput | $Enums.UserStatus
    fcmToken?: NullableStringFieldUpdateOperationsInput | string | null
    isRooted?: BoolFieldUpdateOperationsInput | boolean
    presence?: EnumEmployeePresenceFieldUpdateOperationsInput | $Enums.EmployeePresence
    lastSeenAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    refreshTokens?: RefreshTokenUncheckedUpdateManyWithoutUserNestedInput
    trips?: TripUncheckedUpdateManyWithoutUserNestedInput
    gpsPoints?: GpsPointUncheckedUpdateManyWithoutUserNestedInput
    auditLogs?: AuditLogUncheckedUpdateManyWithoutActorNestedInput
    notifications?: NotificationUncheckedUpdateManyWithoutUserNestedInput
  }

  export type UserUpsertWithWhereUniqueWithoutReportingManagerInput = {
    where: UserWhereUniqueInput
    update: XOR<UserUpdateWithoutReportingManagerInput, UserUncheckedUpdateWithoutReportingManagerInput>
    create: XOR<UserCreateWithoutReportingManagerInput, UserUncheckedCreateWithoutReportingManagerInput>
  }

  export type UserUpdateWithWhereUniqueWithoutReportingManagerInput = {
    where: UserWhereUniqueInput
    data: XOR<UserUpdateWithoutReportingManagerInput, UserUncheckedUpdateWithoutReportingManagerInput>
  }

  export type UserUpdateManyWithWhereWithoutReportingManagerInput = {
    where: UserScalarWhereInput
    data: XOR<UserUpdateManyMutationInput, UserUncheckedUpdateManyWithoutReportingManagerInput>
  }

  export type UserScalarWhereInput = {
    AND?: UserScalarWhereInput | UserScalarWhereInput[]
    OR?: UserScalarWhereInput[]
    NOT?: UserScalarWhereInput | UserScalarWhereInput[]
    id?: StringFilter<"User"> | string
    uid?: StringFilter<"User"> | string
    email?: StringFilter<"User"> | string
    passwordHash?: StringFilter<"User"> | string
    fullName?: StringFilter<"User"> | string
    employeeCode?: StringFilter<"User"> | string
    mobileNumber?: StringNullableFilter<"User"> | string | null
    sittingLocation?: StringNullableFilter<"User"> | string | null
    reportingManagerId?: StringNullableFilter<"User"> | string | null
    role?: EnumUserRoleFilter<"User"> | $Enums.UserRole
    deviceId?: StringNullableFilter<"User"> | string | null
    profileImage?: StringNullableFilter<"User"> | string | null
    status?: EnumUserStatusFilter<"User"> | $Enums.UserStatus
    fcmToken?: StringNullableFilter<"User"> | string | null
    isRooted?: BoolFilter<"User"> | boolean
    presence?: EnumEmployeePresenceFilter<"User"> | $Enums.EmployeePresence
    lastSeenAt?: DateTimeNullableFilter<"User"> | Date | string | null
    createdAt?: DateTimeFilter<"User"> | Date | string
    updatedAt?: DateTimeFilter<"User"> | Date | string
  }

  export type RefreshTokenUpsertWithWhereUniqueWithoutUserInput = {
    where: RefreshTokenWhereUniqueInput
    update: XOR<RefreshTokenUpdateWithoutUserInput, RefreshTokenUncheckedUpdateWithoutUserInput>
    create: XOR<RefreshTokenCreateWithoutUserInput, RefreshTokenUncheckedCreateWithoutUserInput>
  }

  export type RefreshTokenUpdateWithWhereUniqueWithoutUserInput = {
    where: RefreshTokenWhereUniqueInput
    data: XOR<RefreshTokenUpdateWithoutUserInput, RefreshTokenUncheckedUpdateWithoutUserInput>
  }

  export type RefreshTokenUpdateManyWithWhereWithoutUserInput = {
    where: RefreshTokenScalarWhereInput
    data: XOR<RefreshTokenUpdateManyMutationInput, RefreshTokenUncheckedUpdateManyWithoutUserInput>
  }

  export type RefreshTokenScalarWhereInput = {
    AND?: RefreshTokenScalarWhereInput | RefreshTokenScalarWhereInput[]
    OR?: RefreshTokenScalarWhereInput[]
    NOT?: RefreshTokenScalarWhereInput | RefreshTokenScalarWhereInput[]
    id?: StringFilter<"RefreshToken"> | string
    userId?: StringFilter<"RefreshToken"> | string
    tokenHash?: StringFilter<"RefreshToken"> | string
    deviceId?: StringNullableFilter<"RefreshToken"> | string | null
    expiresAt?: DateTimeFilter<"RefreshToken"> | Date | string
    createdAt?: DateTimeFilter<"RefreshToken"> | Date | string
  }

  export type TripUpsertWithWhereUniqueWithoutUserInput = {
    where: TripWhereUniqueInput
    update: XOR<TripUpdateWithoutUserInput, TripUncheckedUpdateWithoutUserInput>
    create: XOR<TripCreateWithoutUserInput, TripUncheckedCreateWithoutUserInput>
  }

  export type TripUpdateWithWhereUniqueWithoutUserInput = {
    where: TripWhereUniqueInput
    data: XOR<TripUpdateWithoutUserInput, TripUncheckedUpdateWithoutUserInput>
  }

  export type TripUpdateManyWithWhereWithoutUserInput = {
    where: TripScalarWhereInput
    data: XOR<TripUpdateManyMutationInput, TripUncheckedUpdateManyWithoutUserInput>
  }

  export type TripScalarWhereInput = {
    AND?: TripScalarWhereInput | TripScalarWhereInput[]
    OR?: TripScalarWhereInput[]
    NOT?: TripScalarWhereInput | TripScalarWhereInput[]
    id?: StringFilter<"Trip"> | string
    tripId?: StringFilter<"Trip"> | string
    userId?: StringFilter<"Trip"> | string
    city?: StringNullableFilter<"Trip"> | string | null
    fromLocation?: StringNullableFilter<"Trip"> | string | null
    toLocation?: StringNullableFilter<"Trip"> | string | null
    destinationLat?: FloatNullableFilter<"Trip"> | number | null
    destinationLng?: FloatNullableFilter<"Trip"> | number | null
    googlePlaceId?: StringNullableFilter<"Trip"> | string | null
    plannedDistance?: FloatNullableFilter<"Trip"> | number | null
    vehicleType?: EnumVehicleTypeNullableFilter<"Trip"> | $Enums.VehicleType | null
    fuelType?: EnumFuelTypeNullableFilter<"Trip"> | $Enums.FuelType | null
    purpose?: StringNullableFilter<"Trip"> | string | null
    notes?: StringNullableFilter<"Trip"> | string | null
    status?: EnumTripStatusFilter<"Trip"> | $Enums.TripStatus
    totalDistance?: FloatFilter<"Trip"> | number
    travelDuration?: IntFilter<"Trip"> | number
    idleTime?: IntFilter<"Trip"> | number
    meetingDuration?: IntFilter<"Trip"> | number
    productivityScore?: FloatNullableFilter<"Trip"> | number | null
    tripEfficiency?: FloatNullableFilter<"Trip"> | number | null
    startedAt?: DateTimeNullableFilter<"Trip"> | Date | string | null
    arrivedAt?: DateTimeNullableFilter<"Trip"> | Date | string | null
    completedAt?: DateTimeNullableFilter<"Trip"> | Date | string | null
    createdAt?: DateTimeFilter<"Trip"> | Date | string
    updatedAt?: DateTimeFilter<"Trip"> | Date | string
  }

  export type GpsPointUpsertWithWhereUniqueWithoutUserInput = {
    where: GpsPointWhereUniqueInput
    update: XOR<GpsPointUpdateWithoutUserInput, GpsPointUncheckedUpdateWithoutUserInput>
    create: XOR<GpsPointCreateWithoutUserInput, GpsPointUncheckedCreateWithoutUserInput>
  }

  export type GpsPointUpdateWithWhereUniqueWithoutUserInput = {
    where: GpsPointWhereUniqueInput
    data: XOR<GpsPointUpdateWithoutUserInput, GpsPointUncheckedUpdateWithoutUserInput>
  }

  export type GpsPointUpdateManyWithWhereWithoutUserInput = {
    where: GpsPointScalarWhereInput
    data: XOR<GpsPointUpdateManyMutationInput, GpsPointUncheckedUpdateManyWithoutUserInput>
  }

  export type GpsPointScalarWhereInput = {
    AND?: GpsPointScalarWhereInput | GpsPointScalarWhereInput[]
    OR?: GpsPointScalarWhereInput[]
    NOT?: GpsPointScalarWhereInput | GpsPointScalarWhereInput[]
    id?: StringFilter<"GpsPoint"> | string
    tripId?: StringNullableFilter<"GpsPoint"> | string | null
    userId?: StringFilter<"GpsPoint"> | string
    clientPointId?: StringNullableFilter<"GpsPoint"> | string | null
    latitude?: FloatFilter<"GpsPoint"> | number
    longitude?: FloatFilter<"GpsPoint"> | number
    accuracy?: FloatNullableFilter<"GpsPoint"> | number | null
    speed?: FloatNullableFilter<"GpsPoint"> | number | null
    bearing?: FloatNullableFilter<"GpsPoint"> | number | null
    batteryLevel?: FloatNullableFilter<"GpsPoint"> | number | null
    timestamp?: DateTimeFilter<"GpsPoint"> | Date | string
    isSmoothed?: BoolFilter<"GpsPoint"> | boolean
    createdAt?: DateTimeFilter<"GpsPoint"> | Date | string
  }

  export type AuditLogUpsertWithWhereUniqueWithoutActorInput = {
    where: AuditLogWhereUniqueInput
    update: XOR<AuditLogUpdateWithoutActorInput, AuditLogUncheckedUpdateWithoutActorInput>
    create: XOR<AuditLogCreateWithoutActorInput, AuditLogUncheckedCreateWithoutActorInput>
  }

  export type AuditLogUpdateWithWhereUniqueWithoutActorInput = {
    where: AuditLogWhereUniqueInput
    data: XOR<AuditLogUpdateWithoutActorInput, AuditLogUncheckedUpdateWithoutActorInput>
  }

  export type AuditLogUpdateManyWithWhereWithoutActorInput = {
    where: AuditLogScalarWhereInput
    data: XOR<AuditLogUpdateManyMutationInput, AuditLogUncheckedUpdateManyWithoutActorInput>
  }

  export type AuditLogScalarWhereInput = {
    AND?: AuditLogScalarWhereInput | AuditLogScalarWhereInput[]
    OR?: AuditLogScalarWhereInput[]
    NOT?: AuditLogScalarWhereInput | AuditLogScalarWhereInput[]
    id?: StringFilter<"AuditLog"> | string
    actorUserId?: StringNullableFilter<"AuditLog"> | string | null
    actorEmail?: StringNullableFilter<"AuditLog"> | string | null
    action?: StringFilter<"AuditLog"> | string
    targetType?: StringNullableFilter<"AuditLog"> | string | null
    targetId?: StringNullableFilter<"AuditLog"> | string | null
    metadata?: JsonNullableFilter<"AuditLog">
    ipAddress?: StringNullableFilter<"AuditLog"> | string | null
    userAgent?: StringNullableFilter<"AuditLog"> | string | null
    createdAt?: DateTimeFilter<"AuditLog"> | Date | string
  }

  export type NotificationUpsertWithWhereUniqueWithoutUserInput = {
    where: NotificationWhereUniqueInput
    update: XOR<NotificationUpdateWithoutUserInput, NotificationUncheckedUpdateWithoutUserInput>
    create: XOR<NotificationCreateWithoutUserInput, NotificationUncheckedCreateWithoutUserInput>
  }

  export type NotificationUpdateWithWhereUniqueWithoutUserInput = {
    where: NotificationWhereUniqueInput
    data: XOR<NotificationUpdateWithoutUserInput, NotificationUncheckedUpdateWithoutUserInput>
  }

  export type NotificationUpdateManyWithWhereWithoutUserInput = {
    where: NotificationScalarWhereInput
    data: XOR<NotificationUpdateManyMutationInput, NotificationUncheckedUpdateManyWithoutUserInput>
  }

  export type NotificationScalarWhereInput = {
    AND?: NotificationScalarWhereInput | NotificationScalarWhereInput[]
    OR?: NotificationScalarWhereInput[]
    NOT?: NotificationScalarWhereInput | NotificationScalarWhereInput[]
    id?: StringFilter<"Notification"> | string
    userId?: StringFilter<"Notification"> | string
    type?: EnumNotificationTypeFilter<"Notification"> | $Enums.NotificationType
    title?: StringFilter<"Notification"> | string
    body?: StringFilter<"Notification"> | string
    data?: JsonNullableFilter<"Notification">
    read?: BoolFilter<"Notification"> | boolean
    sentAt?: DateTimeFilter<"Notification"> | Date | string
  }

  export type UserCreateWithoutRefreshTokensInput = {
    id?: string
    uid: string
    email: string
    passwordHash: string
    fullName: string
    employeeCode: string
    mobileNumber?: string | null
    sittingLocation?: string | null
    role?: $Enums.UserRole
    deviceId?: string | null
    profileImage?: string | null
    status?: $Enums.UserStatus
    fcmToken?: string | null
    isRooted?: boolean
    presence?: $Enums.EmployeePresence
    lastSeenAt?: Date | string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    reportingManager?: UserCreateNestedOneWithoutDirectReportsInput
    directReports?: UserCreateNestedManyWithoutReportingManagerInput
    trips?: TripCreateNestedManyWithoutUserInput
    gpsPoints?: GpsPointCreateNestedManyWithoutUserInput
    auditLogs?: AuditLogCreateNestedManyWithoutActorInput
    notifications?: NotificationCreateNestedManyWithoutUserInput
  }

  export type UserUncheckedCreateWithoutRefreshTokensInput = {
    id?: string
    uid: string
    email: string
    passwordHash: string
    fullName: string
    employeeCode: string
    mobileNumber?: string | null
    sittingLocation?: string | null
    reportingManagerId?: string | null
    role?: $Enums.UserRole
    deviceId?: string | null
    profileImage?: string | null
    status?: $Enums.UserStatus
    fcmToken?: string | null
    isRooted?: boolean
    presence?: $Enums.EmployeePresence
    lastSeenAt?: Date | string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    directReports?: UserUncheckedCreateNestedManyWithoutReportingManagerInput
    trips?: TripUncheckedCreateNestedManyWithoutUserInput
    gpsPoints?: GpsPointUncheckedCreateNestedManyWithoutUserInput
    auditLogs?: AuditLogUncheckedCreateNestedManyWithoutActorInput
    notifications?: NotificationUncheckedCreateNestedManyWithoutUserInput
  }

  export type UserCreateOrConnectWithoutRefreshTokensInput = {
    where: UserWhereUniqueInput
    create: XOR<UserCreateWithoutRefreshTokensInput, UserUncheckedCreateWithoutRefreshTokensInput>
  }

  export type UserUpsertWithoutRefreshTokensInput = {
    update: XOR<UserUpdateWithoutRefreshTokensInput, UserUncheckedUpdateWithoutRefreshTokensInput>
    create: XOR<UserCreateWithoutRefreshTokensInput, UserUncheckedCreateWithoutRefreshTokensInput>
    where?: UserWhereInput
  }

  export type UserUpdateToOneWithWhereWithoutRefreshTokensInput = {
    where?: UserWhereInput
    data: XOR<UserUpdateWithoutRefreshTokensInput, UserUncheckedUpdateWithoutRefreshTokensInput>
  }

  export type UserUpdateWithoutRefreshTokensInput = {
    id?: StringFieldUpdateOperationsInput | string
    uid?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    fullName?: StringFieldUpdateOperationsInput | string
    employeeCode?: StringFieldUpdateOperationsInput | string
    mobileNumber?: NullableStringFieldUpdateOperationsInput | string | null
    sittingLocation?: NullableStringFieldUpdateOperationsInput | string | null
    role?: EnumUserRoleFieldUpdateOperationsInput | $Enums.UserRole
    deviceId?: NullableStringFieldUpdateOperationsInput | string | null
    profileImage?: NullableStringFieldUpdateOperationsInput | string | null
    status?: EnumUserStatusFieldUpdateOperationsInput | $Enums.UserStatus
    fcmToken?: NullableStringFieldUpdateOperationsInput | string | null
    isRooted?: BoolFieldUpdateOperationsInput | boolean
    presence?: EnumEmployeePresenceFieldUpdateOperationsInput | $Enums.EmployeePresence
    lastSeenAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    reportingManager?: UserUpdateOneWithoutDirectReportsNestedInput
    directReports?: UserUpdateManyWithoutReportingManagerNestedInput
    trips?: TripUpdateManyWithoutUserNestedInput
    gpsPoints?: GpsPointUpdateManyWithoutUserNestedInput
    auditLogs?: AuditLogUpdateManyWithoutActorNestedInput
    notifications?: NotificationUpdateManyWithoutUserNestedInput
  }

  export type UserUncheckedUpdateWithoutRefreshTokensInput = {
    id?: StringFieldUpdateOperationsInput | string
    uid?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    fullName?: StringFieldUpdateOperationsInput | string
    employeeCode?: StringFieldUpdateOperationsInput | string
    mobileNumber?: NullableStringFieldUpdateOperationsInput | string | null
    sittingLocation?: NullableStringFieldUpdateOperationsInput | string | null
    reportingManagerId?: NullableStringFieldUpdateOperationsInput | string | null
    role?: EnumUserRoleFieldUpdateOperationsInput | $Enums.UserRole
    deviceId?: NullableStringFieldUpdateOperationsInput | string | null
    profileImage?: NullableStringFieldUpdateOperationsInput | string | null
    status?: EnumUserStatusFieldUpdateOperationsInput | $Enums.UserStatus
    fcmToken?: NullableStringFieldUpdateOperationsInput | string | null
    isRooted?: BoolFieldUpdateOperationsInput | boolean
    presence?: EnumEmployeePresenceFieldUpdateOperationsInput | $Enums.EmployeePresence
    lastSeenAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    directReports?: UserUncheckedUpdateManyWithoutReportingManagerNestedInput
    trips?: TripUncheckedUpdateManyWithoutUserNestedInput
    gpsPoints?: GpsPointUncheckedUpdateManyWithoutUserNestedInput
    auditLogs?: AuditLogUncheckedUpdateManyWithoutActorNestedInput
    notifications?: NotificationUncheckedUpdateManyWithoutUserNestedInput
  }

  export type UserCreateWithoutAuditLogsInput = {
    id?: string
    uid: string
    email: string
    passwordHash: string
    fullName: string
    employeeCode: string
    mobileNumber?: string | null
    sittingLocation?: string | null
    role?: $Enums.UserRole
    deviceId?: string | null
    profileImage?: string | null
    status?: $Enums.UserStatus
    fcmToken?: string | null
    isRooted?: boolean
    presence?: $Enums.EmployeePresence
    lastSeenAt?: Date | string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    reportingManager?: UserCreateNestedOneWithoutDirectReportsInput
    directReports?: UserCreateNestedManyWithoutReportingManagerInput
    refreshTokens?: RefreshTokenCreateNestedManyWithoutUserInput
    trips?: TripCreateNestedManyWithoutUserInput
    gpsPoints?: GpsPointCreateNestedManyWithoutUserInput
    notifications?: NotificationCreateNestedManyWithoutUserInput
  }

  export type UserUncheckedCreateWithoutAuditLogsInput = {
    id?: string
    uid: string
    email: string
    passwordHash: string
    fullName: string
    employeeCode: string
    mobileNumber?: string | null
    sittingLocation?: string | null
    reportingManagerId?: string | null
    role?: $Enums.UserRole
    deviceId?: string | null
    profileImage?: string | null
    status?: $Enums.UserStatus
    fcmToken?: string | null
    isRooted?: boolean
    presence?: $Enums.EmployeePresence
    lastSeenAt?: Date | string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    directReports?: UserUncheckedCreateNestedManyWithoutReportingManagerInput
    refreshTokens?: RefreshTokenUncheckedCreateNestedManyWithoutUserInput
    trips?: TripUncheckedCreateNestedManyWithoutUserInput
    gpsPoints?: GpsPointUncheckedCreateNestedManyWithoutUserInput
    notifications?: NotificationUncheckedCreateNestedManyWithoutUserInput
  }

  export type UserCreateOrConnectWithoutAuditLogsInput = {
    where: UserWhereUniqueInput
    create: XOR<UserCreateWithoutAuditLogsInput, UserUncheckedCreateWithoutAuditLogsInput>
  }

  export type UserUpsertWithoutAuditLogsInput = {
    update: XOR<UserUpdateWithoutAuditLogsInput, UserUncheckedUpdateWithoutAuditLogsInput>
    create: XOR<UserCreateWithoutAuditLogsInput, UserUncheckedCreateWithoutAuditLogsInput>
    where?: UserWhereInput
  }

  export type UserUpdateToOneWithWhereWithoutAuditLogsInput = {
    where?: UserWhereInput
    data: XOR<UserUpdateWithoutAuditLogsInput, UserUncheckedUpdateWithoutAuditLogsInput>
  }

  export type UserUpdateWithoutAuditLogsInput = {
    id?: StringFieldUpdateOperationsInput | string
    uid?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    fullName?: StringFieldUpdateOperationsInput | string
    employeeCode?: StringFieldUpdateOperationsInput | string
    mobileNumber?: NullableStringFieldUpdateOperationsInput | string | null
    sittingLocation?: NullableStringFieldUpdateOperationsInput | string | null
    role?: EnumUserRoleFieldUpdateOperationsInput | $Enums.UserRole
    deviceId?: NullableStringFieldUpdateOperationsInput | string | null
    profileImage?: NullableStringFieldUpdateOperationsInput | string | null
    status?: EnumUserStatusFieldUpdateOperationsInput | $Enums.UserStatus
    fcmToken?: NullableStringFieldUpdateOperationsInput | string | null
    isRooted?: BoolFieldUpdateOperationsInput | boolean
    presence?: EnumEmployeePresenceFieldUpdateOperationsInput | $Enums.EmployeePresence
    lastSeenAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    reportingManager?: UserUpdateOneWithoutDirectReportsNestedInput
    directReports?: UserUpdateManyWithoutReportingManagerNestedInput
    refreshTokens?: RefreshTokenUpdateManyWithoutUserNestedInput
    trips?: TripUpdateManyWithoutUserNestedInput
    gpsPoints?: GpsPointUpdateManyWithoutUserNestedInput
    notifications?: NotificationUpdateManyWithoutUserNestedInput
  }

  export type UserUncheckedUpdateWithoutAuditLogsInput = {
    id?: StringFieldUpdateOperationsInput | string
    uid?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    fullName?: StringFieldUpdateOperationsInput | string
    employeeCode?: StringFieldUpdateOperationsInput | string
    mobileNumber?: NullableStringFieldUpdateOperationsInput | string | null
    sittingLocation?: NullableStringFieldUpdateOperationsInput | string | null
    reportingManagerId?: NullableStringFieldUpdateOperationsInput | string | null
    role?: EnumUserRoleFieldUpdateOperationsInput | $Enums.UserRole
    deviceId?: NullableStringFieldUpdateOperationsInput | string | null
    profileImage?: NullableStringFieldUpdateOperationsInput | string | null
    status?: EnumUserStatusFieldUpdateOperationsInput | $Enums.UserStatus
    fcmToken?: NullableStringFieldUpdateOperationsInput | string | null
    isRooted?: BoolFieldUpdateOperationsInput | boolean
    presence?: EnumEmployeePresenceFieldUpdateOperationsInput | $Enums.EmployeePresence
    lastSeenAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    directReports?: UserUncheckedUpdateManyWithoutReportingManagerNestedInput
    refreshTokens?: RefreshTokenUncheckedUpdateManyWithoutUserNestedInput
    trips?: TripUncheckedUpdateManyWithoutUserNestedInput
    gpsPoints?: GpsPointUncheckedUpdateManyWithoutUserNestedInput
    notifications?: NotificationUncheckedUpdateManyWithoutUserNestedInput
  }

  export type UserCreateWithoutTripsInput = {
    id?: string
    uid: string
    email: string
    passwordHash: string
    fullName: string
    employeeCode: string
    mobileNumber?: string | null
    sittingLocation?: string | null
    role?: $Enums.UserRole
    deviceId?: string | null
    profileImage?: string | null
    status?: $Enums.UserStatus
    fcmToken?: string | null
    isRooted?: boolean
    presence?: $Enums.EmployeePresence
    lastSeenAt?: Date | string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    reportingManager?: UserCreateNestedOneWithoutDirectReportsInput
    directReports?: UserCreateNestedManyWithoutReportingManagerInput
    refreshTokens?: RefreshTokenCreateNestedManyWithoutUserInput
    gpsPoints?: GpsPointCreateNestedManyWithoutUserInput
    auditLogs?: AuditLogCreateNestedManyWithoutActorInput
    notifications?: NotificationCreateNestedManyWithoutUserInput
  }

  export type UserUncheckedCreateWithoutTripsInput = {
    id?: string
    uid: string
    email: string
    passwordHash: string
    fullName: string
    employeeCode: string
    mobileNumber?: string | null
    sittingLocation?: string | null
    reportingManagerId?: string | null
    role?: $Enums.UserRole
    deviceId?: string | null
    profileImage?: string | null
    status?: $Enums.UserStatus
    fcmToken?: string | null
    isRooted?: boolean
    presence?: $Enums.EmployeePresence
    lastSeenAt?: Date | string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    directReports?: UserUncheckedCreateNestedManyWithoutReportingManagerInput
    refreshTokens?: RefreshTokenUncheckedCreateNestedManyWithoutUserInput
    gpsPoints?: GpsPointUncheckedCreateNestedManyWithoutUserInput
    auditLogs?: AuditLogUncheckedCreateNestedManyWithoutActorInput
    notifications?: NotificationUncheckedCreateNestedManyWithoutUserInput
  }

  export type UserCreateOrConnectWithoutTripsInput = {
    where: UserWhereUniqueInput
    create: XOR<UserCreateWithoutTripsInput, UserUncheckedCreateWithoutTripsInput>
  }

  export type PunchCreateWithoutTripInput = {
    id?: string
    type: $Enums.PunchType
    timestamp: Date | string
    latitude: number
    longitude: number
    address?: string | null
    batteryPercent?: number | null
    gpsAccuracy?: number | null
    speed?: number | null
    isMockLocation?: boolean
    meetingSummary?: string | null
    leadType?: $Enums.LeadType | null
    customerNotes?: string | null
    createdAt?: Date | string
  }

  export type PunchUncheckedCreateWithoutTripInput = {
    id?: string
    type: $Enums.PunchType
    timestamp: Date | string
    latitude: number
    longitude: number
    address?: string | null
    batteryPercent?: number | null
    gpsAccuracy?: number | null
    speed?: number | null
    isMockLocation?: boolean
    meetingSummary?: string | null
    leadType?: $Enums.LeadType | null
    customerNotes?: string | null
    createdAt?: Date | string
  }

  export type PunchCreateOrConnectWithoutTripInput = {
    where: PunchWhereUniqueInput
    create: XOR<PunchCreateWithoutTripInput, PunchUncheckedCreateWithoutTripInput>
  }

  export type PunchCreateManyTripInputEnvelope = {
    data: PunchCreateManyTripInput | PunchCreateManyTripInput[]
  }

  export type GpsPointCreateWithoutTripInput = {
    id?: string
    clientPointId?: string | null
    latitude: number
    longitude: number
    accuracy?: number | null
    speed?: number | null
    bearing?: number | null
    batteryLevel?: number | null
    timestamp: Date | string
    isSmoothed?: boolean
    createdAt?: Date | string
    user: UserCreateNestedOneWithoutGpsPointsInput
  }

  export type GpsPointUncheckedCreateWithoutTripInput = {
    id?: string
    userId: string
    clientPointId?: string | null
    latitude: number
    longitude: number
    accuracy?: number | null
    speed?: number | null
    bearing?: number | null
    batteryLevel?: number | null
    timestamp: Date | string
    isSmoothed?: boolean
    createdAt?: Date | string
  }

  export type GpsPointCreateOrConnectWithoutTripInput = {
    where: GpsPointWhereUniqueInput
    create: XOR<GpsPointCreateWithoutTripInput, GpsPointUncheckedCreateWithoutTripInput>
  }

  export type GpsPointCreateManyTripInputEnvelope = {
    data: GpsPointCreateManyTripInput | GpsPointCreateManyTripInput[]
  }

  export type GpsStopCreateWithoutTripInput = {
    id?: string
    latitude: number
    longitude: number
    startedAt: Date | string
    endedAt?: Date | string | null
    duration?: number | null
    address?: string | null
  }

  export type GpsStopUncheckedCreateWithoutTripInput = {
    id?: string
    latitude: number
    longitude: number
    startedAt: Date | string
    endedAt?: Date | string | null
    duration?: number | null
    address?: string | null
  }

  export type GpsStopCreateOrConnectWithoutTripInput = {
    where: GpsStopWhereUniqueInput
    create: XOR<GpsStopCreateWithoutTripInput, GpsStopUncheckedCreateWithoutTripInput>
  }

  export type GpsStopCreateManyTripInputEnvelope = {
    data: GpsStopCreateManyTripInput | GpsStopCreateManyTripInput[]
  }

  export type UserUpsertWithoutTripsInput = {
    update: XOR<UserUpdateWithoutTripsInput, UserUncheckedUpdateWithoutTripsInput>
    create: XOR<UserCreateWithoutTripsInput, UserUncheckedCreateWithoutTripsInput>
    where?: UserWhereInput
  }

  export type UserUpdateToOneWithWhereWithoutTripsInput = {
    where?: UserWhereInput
    data: XOR<UserUpdateWithoutTripsInput, UserUncheckedUpdateWithoutTripsInput>
  }

  export type UserUpdateWithoutTripsInput = {
    id?: StringFieldUpdateOperationsInput | string
    uid?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    fullName?: StringFieldUpdateOperationsInput | string
    employeeCode?: StringFieldUpdateOperationsInput | string
    mobileNumber?: NullableStringFieldUpdateOperationsInput | string | null
    sittingLocation?: NullableStringFieldUpdateOperationsInput | string | null
    role?: EnumUserRoleFieldUpdateOperationsInput | $Enums.UserRole
    deviceId?: NullableStringFieldUpdateOperationsInput | string | null
    profileImage?: NullableStringFieldUpdateOperationsInput | string | null
    status?: EnumUserStatusFieldUpdateOperationsInput | $Enums.UserStatus
    fcmToken?: NullableStringFieldUpdateOperationsInput | string | null
    isRooted?: BoolFieldUpdateOperationsInput | boolean
    presence?: EnumEmployeePresenceFieldUpdateOperationsInput | $Enums.EmployeePresence
    lastSeenAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    reportingManager?: UserUpdateOneWithoutDirectReportsNestedInput
    directReports?: UserUpdateManyWithoutReportingManagerNestedInput
    refreshTokens?: RefreshTokenUpdateManyWithoutUserNestedInput
    gpsPoints?: GpsPointUpdateManyWithoutUserNestedInput
    auditLogs?: AuditLogUpdateManyWithoutActorNestedInput
    notifications?: NotificationUpdateManyWithoutUserNestedInput
  }

  export type UserUncheckedUpdateWithoutTripsInput = {
    id?: StringFieldUpdateOperationsInput | string
    uid?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    fullName?: StringFieldUpdateOperationsInput | string
    employeeCode?: StringFieldUpdateOperationsInput | string
    mobileNumber?: NullableStringFieldUpdateOperationsInput | string | null
    sittingLocation?: NullableStringFieldUpdateOperationsInput | string | null
    reportingManagerId?: NullableStringFieldUpdateOperationsInput | string | null
    role?: EnumUserRoleFieldUpdateOperationsInput | $Enums.UserRole
    deviceId?: NullableStringFieldUpdateOperationsInput | string | null
    profileImage?: NullableStringFieldUpdateOperationsInput | string | null
    status?: EnumUserStatusFieldUpdateOperationsInput | $Enums.UserStatus
    fcmToken?: NullableStringFieldUpdateOperationsInput | string | null
    isRooted?: BoolFieldUpdateOperationsInput | boolean
    presence?: EnumEmployeePresenceFieldUpdateOperationsInput | $Enums.EmployeePresence
    lastSeenAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    directReports?: UserUncheckedUpdateManyWithoutReportingManagerNestedInput
    refreshTokens?: RefreshTokenUncheckedUpdateManyWithoutUserNestedInput
    gpsPoints?: GpsPointUncheckedUpdateManyWithoutUserNestedInput
    auditLogs?: AuditLogUncheckedUpdateManyWithoutActorNestedInput
    notifications?: NotificationUncheckedUpdateManyWithoutUserNestedInput
  }

  export type PunchUpsertWithWhereUniqueWithoutTripInput = {
    where: PunchWhereUniqueInput
    update: XOR<PunchUpdateWithoutTripInput, PunchUncheckedUpdateWithoutTripInput>
    create: XOR<PunchCreateWithoutTripInput, PunchUncheckedCreateWithoutTripInput>
  }

  export type PunchUpdateWithWhereUniqueWithoutTripInput = {
    where: PunchWhereUniqueInput
    data: XOR<PunchUpdateWithoutTripInput, PunchUncheckedUpdateWithoutTripInput>
  }

  export type PunchUpdateManyWithWhereWithoutTripInput = {
    where: PunchScalarWhereInput
    data: XOR<PunchUpdateManyMutationInput, PunchUncheckedUpdateManyWithoutTripInput>
  }

  export type PunchScalarWhereInput = {
    AND?: PunchScalarWhereInput | PunchScalarWhereInput[]
    OR?: PunchScalarWhereInput[]
    NOT?: PunchScalarWhereInput | PunchScalarWhereInput[]
    id?: StringFilter<"Punch"> | string
    tripId?: StringFilter<"Punch"> | string
    type?: EnumPunchTypeFilter<"Punch"> | $Enums.PunchType
    timestamp?: DateTimeFilter<"Punch"> | Date | string
    latitude?: FloatFilter<"Punch"> | number
    longitude?: FloatFilter<"Punch"> | number
    address?: StringNullableFilter<"Punch"> | string | null
    batteryPercent?: FloatNullableFilter<"Punch"> | number | null
    gpsAccuracy?: FloatNullableFilter<"Punch"> | number | null
    speed?: FloatNullableFilter<"Punch"> | number | null
    isMockLocation?: BoolFilter<"Punch"> | boolean
    meetingSummary?: StringNullableFilter<"Punch"> | string | null
    leadType?: EnumLeadTypeNullableFilter<"Punch"> | $Enums.LeadType | null
    customerNotes?: StringNullableFilter<"Punch"> | string | null
    createdAt?: DateTimeFilter<"Punch"> | Date | string
  }

  export type GpsPointUpsertWithWhereUniqueWithoutTripInput = {
    where: GpsPointWhereUniqueInput
    update: XOR<GpsPointUpdateWithoutTripInput, GpsPointUncheckedUpdateWithoutTripInput>
    create: XOR<GpsPointCreateWithoutTripInput, GpsPointUncheckedCreateWithoutTripInput>
  }

  export type GpsPointUpdateWithWhereUniqueWithoutTripInput = {
    where: GpsPointWhereUniqueInput
    data: XOR<GpsPointUpdateWithoutTripInput, GpsPointUncheckedUpdateWithoutTripInput>
  }

  export type GpsPointUpdateManyWithWhereWithoutTripInput = {
    where: GpsPointScalarWhereInput
    data: XOR<GpsPointUpdateManyMutationInput, GpsPointUncheckedUpdateManyWithoutTripInput>
  }

  export type GpsStopUpsertWithWhereUniqueWithoutTripInput = {
    where: GpsStopWhereUniqueInput
    update: XOR<GpsStopUpdateWithoutTripInput, GpsStopUncheckedUpdateWithoutTripInput>
    create: XOR<GpsStopCreateWithoutTripInput, GpsStopUncheckedCreateWithoutTripInput>
  }

  export type GpsStopUpdateWithWhereUniqueWithoutTripInput = {
    where: GpsStopWhereUniqueInput
    data: XOR<GpsStopUpdateWithoutTripInput, GpsStopUncheckedUpdateWithoutTripInput>
  }

  export type GpsStopUpdateManyWithWhereWithoutTripInput = {
    where: GpsStopScalarWhereInput
    data: XOR<GpsStopUpdateManyMutationInput, GpsStopUncheckedUpdateManyWithoutTripInput>
  }

  export type GpsStopScalarWhereInput = {
    AND?: GpsStopScalarWhereInput | GpsStopScalarWhereInput[]
    OR?: GpsStopScalarWhereInput[]
    NOT?: GpsStopScalarWhereInput | GpsStopScalarWhereInput[]
    id?: StringFilter<"GpsStop"> | string
    tripId?: StringFilter<"GpsStop"> | string
    latitude?: FloatFilter<"GpsStop"> | number
    longitude?: FloatFilter<"GpsStop"> | number
    startedAt?: DateTimeFilter<"GpsStop"> | Date | string
    endedAt?: DateTimeNullableFilter<"GpsStop"> | Date | string | null
    duration?: IntNullableFilter<"GpsStop"> | number | null
    address?: StringNullableFilter<"GpsStop"> | string | null
  }

  export type TripCreateWithoutPunchesInput = {
    id?: string
    tripId?: string
    city?: string | null
    fromLocation?: string | null
    toLocation?: string | null
    destinationLat?: number | null
    destinationLng?: number | null
    googlePlaceId?: string | null
    plannedDistance?: number | null
    vehicleType?: $Enums.VehicleType | null
    fuelType?: $Enums.FuelType | null
    purpose?: string | null
    notes?: string | null
    status?: $Enums.TripStatus
    totalDistance?: number
    travelDuration?: number
    idleTime?: number
    meetingDuration?: number
    productivityScore?: number | null
    tripEfficiency?: number | null
    startedAt?: Date | string | null
    arrivedAt?: Date | string | null
    completedAt?: Date | string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    user: UserCreateNestedOneWithoutTripsInput
    gpsPoints?: GpsPointCreateNestedManyWithoutTripInput
    stops?: GpsStopCreateNestedManyWithoutTripInput
  }

  export type TripUncheckedCreateWithoutPunchesInput = {
    id?: string
    tripId?: string
    userId: string
    city?: string | null
    fromLocation?: string | null
    toLocation?: string | null
    destinationLat?: number | null
    destinationLng?: number | null
    googlePlaceId?: string | null
    plannedDistance?: number | null
    vehicleType?: $Enums.VehicleType | null
    fuelType?: $Enums.FuelType | null
    purpose?: string | null
    notes?: string | null
    status?: $Enums.TripStatus
    totalDistance?: number
    travelDuration?: number
    idleTime?: number
    meetingDuration?: number
    productivityScore?: number | null
    tripEfficiency?: number | null
    startedAt?: Date | string | null
    arrivedAt?: Date | string | null
    completedAt?: Date | string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    gpsPoints?: GpsPointUncheckedCreateNestedManyWithoutTripInput
    stops?: GpsStopUncheckedCreateNestedManyWithoutTripInput
  }

  export type TripCreateOrConnectWithoutPunchesInput = {
    where: TripWhereUniqueInput
    create: XOR<TripCreateWithoutPunchesInput, TripUncheckedCreateWithoutPunchesInput>
  }

  export type TripUpsertWithoutPunchesInput = {
    update: XOR<TripUpdateWithoutPunchesInput, TripUncheckedUpdateWithoutPunchesInput>
    create: XOR<TripCreateWithoutPunchesInput, TripUncheckedCreateWithoutPunchesInput>
    where?: TripWhereInput
  }

  export type TripUpdateToOneWithWhereWithoutPunchesInput = {
    where?: TripWhereInput
    data: XOR<TripUpdateWithoutPunchesInput, TripUncheckedUpdateWithoutPunchesInput>
  }

  export type TripUpdateWithoutPunchesInput = {
    id?: StringFieldUpdateOperationsInput | string
    tripId?: StringFieldUpdateOperationsInput | string
    city?: NullableStringFieldUpdateOperationsInput | string | null
    fromLocation?: NullableStringFieldUpdateOperationsInput | string | null
    toLocation?: NullableStringFieldUpdateOperationsInput | string | null
    destinationLat?: NullableFloatFieldUpdateOperationsInput | number | null
    destinationLng?: NullableFloatFieldUpdateOperationsInput | number | null
    googlePlaceId?: NullableStringFieldUpdateOperationsInput | string | null
    plannedDistance?: NullableFloatFieldUpdateOperationsInput | number | null
    vehicleType?: NullableEnumVehicleTypeFieldUpdateOperationsInput | $Enums.VehicleType | null
    fuelType?: NullableEnumFuelTypeFieldUpdateOperationsInput | $Enums.FuelType | null
    purpose?: NullableStringFieldUpdateOperationsInput | string | null
    notes?: NullableStringFieldUpdateOperationsInput | string | null
    status?: EnumTripStatusFieldUpdateOperationsInput | $Enums.TripStatus
    totalDistance?: FloatFieldUpdateOperationsInput | number
    travelDuration?: IntFieldUpdateOperationsInput | number
    idleTime?: IntFieldUpdateOperationsInput | number
    meetingDuration?: IntFieldUpdateOperationsInput | number
    productivityScore?: NullableFloatFieldUpdateOperationsInput | number | null
    tripEfficiency?: NullableFloatFieldUpdateOperationsInput | number | null
    startedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    arrivedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    completedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    user?: UserUpdateOneRequiredWithoutTripsNestedInput
    gpsPoints?: GpsPointUpdateManyWithoutTripNestedInput
    stops?: GpsStopUpdateManyWithoutTripNestedInput
  }

  export type TripUncheckedUpdateWithoutPunchesInput = {
    id?: StringFieldUpdateOperationsInput | string
    tripId?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    city?: NullableStringFieldUpdateOperationsInput | string | null
    fromLocation?: NullableStringFieldUpdateOperationsInput | string | null
    toLocation?: NullableStringFieldUpdateOperationsInput | string | null
    destinationLat?: NullableFloatFieldUpdateOperationsInput | number | null
    destinationLng?: NullableFloatFieldUpdateOperationsInput | number | null
    googlePlaceId?: NullableStringFieldUpdateOperationsInput | string | null
    plannedDistance?: NullableFloatFieldUpdateOperationsInput | number | null
    vehicleType?: NullableEnumVehicleTypeFieldUpdateOperationsInput | $Enums.VehicleType | null
    fuelType?: NullableEnumFuelTypeFieldUpdateOperationsInput | $Enums.FuelType | null
    purpose?: NullableStringFieldUpdateOperationsInput | string | null
    notes?: NullableStringFieldUpdateOperationsInput | string | null
    status?: EnumTripStatusFieldUpdateOperationsInput | $Enums.TripStatus
    totalDistance?: FloatFieldUpdateOperationsInput | number
    travelDuration?: IntFieldUpdateOperationsInput | number
    idleTime?: IntFieldUpdateOperationsInput | number
    meetingDuration?: IntFieldUpdateOperationsInput | number
    productivityScore?: NullableFloatFieldUpdateOperationsInput | number | null
    tripEfficiency?: NullableFloatFieldUpdateOperationsInput | number | null
    startedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    arrivedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    completedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    gpsPoints?: GpsPointUncheckedUpdateManyWithoutTripNestedInput
    stops?: GpsStopUncheckedUpdateManyWithoutTripNestedInput
  }

  export type TripCreateWithoutGpsPointsInput = {
    id?: string
    tripId?: string
    city?: string | null
    fromLocation?: string | null
    toLocation?: string | null
    destinationLat?: number | null
    destinationLng?: number | null
    googlePlaceId?: string | null
    plannedDistance?: number | null
    vehicleType?: $Enums.VehicleType | null
    fuelType?: $Enums.FuelType | null
    purpose?: string | null
    notes?: string | null
    status?: $Enums.TripStatus
    totalDistance?: number
    travelDuration?: number
    idleTime?: number
    meetingDuration?: number
    productivityScore?: number | null
    tripEfficiency?: number | null
    startedAt?: Date | string | null
    arrivedAt?: Date | string | null
    completedAt?: Date | string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    user: UserCreateNestedOneWithoutTripsInput
    punches?: PunchCreateNestedManyWithoutTripInput
    stops?: GpsStopCreateNestedManyWithoutTripInput
  }

  export type TripUncheckedCreateWithoutGpsPointsInput = {
    id?: string
    tripId?: string
    userId: string
    city?: string | null
    fromLocation?: string | null
    toLocation?: string | null
    destinationLat?: number | null
    destinationLng?: number | null
    googlePlaceId?: string | null
    plannedDistance?: number | null
    vehicleType?: $Enums.VehicleType | null
    fuelType?: $Enums.FuelType | null
    purpose?: string | null
    notes?: string | null
    status?: $Enums.TripStatus
    totalDistance?: number
    travelDuration?: number
    idleTime?: number
    meetingDuration?: number
    productivityScore?: number | null
    tripEfficiency?: number | null
    startedAt?: Date | string | null
    arrivedAt?: Date | string | null
    completedAt?: Date | string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    punches?: PunchUncheckedCreateNestedManyWithoutTripInput
    stops?: GpsStopUncheckedCreateNestedManyWithoutTripInput
  }

  export type TripCreateOrConnectWithoutGpsPointsInput = {
    where: TripWhereUniqueInput
    create: XOR<TripCreateWithoutGpsPointsInput, TripUncheckedCreateWithoutGpsPointsInput>
  }

  export type UserCreateWithoutGpsPointsInput = {
    id?: string
    uid: string
    email: string
    passwordHash: string
    fullName: string
    employeeCode: string
    mobileNumber?: string | null
    sittingLocation?: string | null
    role?: $Enums.UserRole
    deviceId?: string | null
    profileImage?: string | null
    status?: $Enums.UserStatus
    fcmToken?: string | null
    isRooted?: boolean
    presence?: $Enums.EmployeePresence
    lastSeenAt?: Date | string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    reportingManager?: UserCreateNestedOneWithoutDirectReportsInput
    directReports?: UserCreateNestedManyWithoutReportingManagerInput
    refreshTokens?: RefreshTokenCreateNestedManyWithoutUserInput
    trips?: TripCreateNestedManyWithoutUserInput
    auditLogs?: AuditLogCreateNestedManyWithoutActorInput
    notifications?: NotificationCreateNestedManyWithoutUserInput
  }

  export type UserUncheckedCreateWithoutGpsPointsInput = {
    id?: string
    uid: string
    email: string
    passwordHash: string
    fullName: string
    employeeCode: string
    mobileNumber?: string | null
    sittingLocation?: string | null
    reportingManagerId?: string | null
    role?: $Enums.UserRole
    deviceId?: string | null
    profileImage?: string | null
    status?: $Enums.UserStatus
    fcmToken?: string | null
    isRooted?: boolean
    presence?: $Enums.EmployeePresence
    lastSeenAt?: Date | string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    directReports?: UserUncheckedCreateNestedManyWithoutReportingManagerInput
    refreshTokens?: RefreshTokenUncheckedCreateNestedManyWithoutUserInput
    trips?: TripUncheckedCreateNestedManyWithoutUserInput
    auditLogs?: AuditLogUncheckedCreateNestedManyWithoutActorInput
    notifications?: NotificationUncheckedCreateNestedManyWithoutUserInput
  }

  export type UserCreateOrConnectWithoutGpsPointsInput = {
    where: UserWhereUniqueInput
    create: XOR<UserCreateWithoutGpsPointsInput, UserUncheckedCreateWithoutGpsPointsInput>
  }

  export type TripUpsertWithoutGpsPointsInput = {
    update: XOR<TripUpdateWithoutGpsPointsInput, TripUncheckedUpdateWithoutGpsPointsInput>
    create: XOR<TripCreateWithoutGpsPointsInput, TripUncheckedCreateWithoutGpsPointsInput>
    where?: TripWhereInput
  }

  export type TripUpdateToOneWithWhereWithoutGpsPointsInput = {
    where?: TripWhereInput
    data: XOR<TripUpdateWithoutGpsPointsInput, TripUncheckedUpdateWithoutGpsPointsInput>
  }

  export type TripUpdateWithoutGpsPointsInput = {
    id?: StringFieldUpdateOperationsInput | string
    tripId?: StringFieldUpdateOperationsInput | string
    city?: NullableStringFieldUpdateOperationsInput | string | null
    fromLocation?: NullableStringFieldUpdateOperationsInput | string | null
    toLocation?: NullableStringFieldUpdateOperationsInput | string | null
    destinationLat?: NullableFloatFieldUpdateOperationsInput | number | null
    destinationLng?: NullableFloatFieldUpdateOperationsInput | number | null
    googlePlaceId?: NullableStringFieldUpdateOperationsInput | string | null
    plannedDistance?: NullableFloatFieldUpdateOperationsInput | number | null
    vehicleType?: NullableEnumVehicleTypeFieldUpdateOperationsInput | $Enums.VehicleType | null
    fuelType?: NullableEnumFuelTypeFieldUpdateOperationsInput | $Enums.FuelType | null
    purpose?: NullableStringFieldUpdateOperationsInput | string | null
    notes?: NullableStringFieldUpdateOperationsInput | string | null
    status?: EnumTripStatusFieldUpdateOperationsInput | $Enums.TripStatus
    totalDistance?: FloatFieldUpdateOperationsInput | number
    travelDuration?: IntFieldUpdateOperationsInput | number
    idleTime?: IntFieldUpdateOperationsInput | number
    meetingDuration?: IntFieldUpdateOperationsInput | number
    productivityScore?: NullableFloatFieldUpdateOperationsInput | number | null
    tripEfficiency?: NullableFloatFieldUpdateOperationsInput | number | null
    startedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    arrivedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    completedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    user?: UserUpdateOneRequiredWithoutTripsNestedInput
    punches?: PunchUpdateManyWithoutTripNestedInput
    stops?: GpsStopUpdateManyWithoutTripNestedInput
  }

  export type TripUncheckedUpdateWithoutGpsPointsInput = {
    id?: StringFieldUpdateOperationsInput | string
    tripId?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    city?: NullableStringFieldUpdateOperationsInput | string | null
    fromLocation?: NullableStringFieldUpdateOperationsInput | string | null
    toLocation?: NullableStringFieldUpdateOperationsInput | string | null
    destinationLat?: NullableFloatFieldUpdateOperationsInput | number | null
    destinationLng?: NullableFloatFieldUpdateOperationsInput | number | null
    googlePlaceId?: NullableStringFieldUpdateOperationsInput | string | null
    plannedDistance?: NullableFloatFieldUpdateOperationsInput | number | null
    vehicleType?: NullableEnumVehicleTypeFieldUpdateOperationsInput | $Enums.VehicleType | null
    fuelType?: NullableEnumFuelTypeFieldUpdateOperationsInput | $Enums.FuelType | null
    purpose?: NullableStringFieldUpdateOperationsInput | string | null
    notes?: NullableStringFieldUpdateOperationsInput | string | null
    status?: EnumTripStatusFieldUpdateOperationsInput | $Enums.TripStatus
    totalDistance?: FloatFieldUpdateOperationsInput | number
    travelDuration?: IntFieldUpdateOperationsInput | number
    idleTime?: IntFieldUpdateOperationsInput | number
    meetingDuration?: IntFieldUpdateOperationsInput | number
    productivityScore?: NullableFloatFieldUpdateOperationsInput | number | null
    tripEfficiency?: NullableFloatFieldUpdateOperationsInput | number | null
    startedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    arrivedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    completedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    punches?: PunchUncheckedUpdateManyWithoutTripNestedInput
    stops?: GpsStopUncheckedUpdateManyWithoutTripNestedInput
  }

  export type UserUpsertWithoutGpsPointsInput = {
    update: XOR<UserUpdateWithoutGpsPointsInput, UserUncheckedUpdateWithoutGpsPointsInput>
    create: XOR<UserCreateWithoutGpsPointsInput, UserUncheckedCreateWithoutGpsPointsInput>
    where?: UserWhereInput
  }

  export type UserUpdateToOneWithWhereWithoutGpsPointsInput = {
    where?: UserWhereInput
    data: XOR<UserUpdateWithoutGpsPointsInput, UserUncheckedUpdateWithoutGpsPointsInput>
  }

  export type UserUpdateWithoutGpsPointsInput = {
    id?: StringFieldUpdateOperationsInput | string
    uid?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    fullName?: StringFieldUpdateOperationsInput | string
    employeeCode?: StringFieldUpdateOperationsInput | string
    mobileNumber?: NullableStringFieldUpdateOperationsInput | string | null
    sittingLocation?: NullableStringFieldUpdateOperationsInput | string | null
    role?: EnumUserRoleFieldUpdateOperationsInput | $Enums.UserRole
    deviceId?: NullableStringFieldUpdateOperationsInput | string | null
    profileImage?: NullableStringFieldUpdateOperationsInput | string | null
    status?: EnumUserStatusFieldUpdateOperationsInput | $Enums.UserStatus
    fcmToken?: NullableStringFieldUpdateOperationsInput | string | null
    isRooted?: BoolFieldUpdateOperationsInput | boolean
    presence?: EnumEmployeePresenceFieldUpdateOperationsInput | $Enums.EmployeePresence
    lastSeenAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    reportingManager?: UserUpdateOneWithoutDirectReportsNestedInput
    directReports?: UserUpdateManyWithoutReportingManagerNestedInput
    refreshTokens?: RefreshTokenUpdateManyWithoutUserNestedInput
    trips?: TripUpdateManyWithoutUserNestedInput
    auditLogs?: AuditLogUpdateManyWithoutActorNestedInput
    notifications?: NotificationUpdateManyWithoutUserNestedInput
  }

  export type UserUncheckedUpdateWithoutGpsPointsInput = {
    id?: StringFieldUpdateOperationsInput | string
    uid?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    fullName?: StringFieldUpdateOperationsInput | string
    employeeCode?: StringFieldUpdateOperationsInput | string
    mobileNumber?: NullableStringFieldUpdateOperationsInput | string | null
    sittingLocation?: NullableStringFieldUpdateOperationsInput | string | null
    reportingManagerId?: NullableStringFieldUpdateOperationsInput | string | null
    role?: EnumUserRoleFieldUpdateOperationsInput | $Enums.UserRole
    deviceId?: NullableStringFieldUpdateOperationsInput | string | null
    profileImage?: NullableStringFieldUpdateOperationsInput | string | null
    status?: EnumUserStatusFieldUpdateOperationsInput | $Enums.UserStatus
    fcmToken?: NullableStringFieldUpdateOperationsInput | string | null
    isRooted?: BoolFieldUpdateOperationsInput | boolean
    presence?: EnumEmployeePresenceFieldUpdateOperationsInput | $Enums.EmployeePresence
    lastSeenAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    directReports?: UserUncheckedUpdateManyWithoutReportingManagerNestedInput
    refreshTokens?: RefreshTokenUncheckedUpdateManyWithoutUserNestedInput
    trips?: TripUncheckedUpdateManyWithoutUserNestedInput
    auditLogs?: AuditLogUncheckedUpdateManyWithoutActorNestedInput
    notifications?: NotificationUncheckedUpdateManyWithoutUserNestedInput
  }

  export type TripCreateWithoutStopsInput = {
    id?: string
    tripId?: string
    city?: string | null
    fromLocation?: string | null
    toLocation?: string | null
    destinationLat?: number | null
    destinationLng?: number | null
    googlePlaceId?: string | null
    plannedDistance?: number | null
    vehicleType?: $Enums.VehicleType | null
    fuelType?: $Enums.FuelType | null
    purpose?: string | null
    notes?: string | null
    status?: $Enums.TripStatus
    totalDistance?: number
    travelDuration?: number
    idleTime?: number
    meetingDuration?: number
    productivityScore?: number | null
    tripEfficiency?: number | null
    startedAt?: Date | string | null
    arrivedAt?: Date | string | null
    completedAt?: Date | string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    user: UserCreateNestedOneWithoutTripsInput
    punches?: PunchCreateNestedManyWithoutTripInput
    gpsPoints?: GpsPointCreateNestedManyWithoutTripInput
  }

  export type TripUncheckedCreateWithoutStopsInput = {
    id?: string
    tripId?: string
    userId: string
    city?: string | null
    fromLocation?: string | null
    toLocation?: string | null
    destinationLat?: number | null
    destinationLng?: number | null
    googlePlaceId?: string | null
    plannedDistance?: number | null
    vehicleType?: $Enums.VehicleType | null
    fuelType?: $Enums.FuelType | null
    purpose?: string | null
    notes?: string | null
    status?: $Enums.TripStatus
    totalDistance?: number
    travelDuration?: number
    idleTime?: number
    meetingDuration?: number
    productivityScore?: number | null
    tripEfficiency?: number | null
    startedAt?: Date | string | null
    arrivedAt?: Date | string | null
    completedAt?: Date | string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    punches?: PunchUncheckedCreateNestedManyWithoutTripInput
    gpsPoints?: GpsPointUncheckedCreateNestedManyWithoutTripInput
  }

  export type TripCreateOrConnectWithoutStopsInput = {
    where: TripWhereUniqueInput
    create: XOR<TripCreateWithoutStopsInput, TripUncheckedCreateWithoutStopsInput>
  }

  export type TripUpsertWithoutStopsInput = {
    update: XOR<TripUpdateWithoutStopsInput, TripUncheckedUpdateWithoutStopsInput>
    create: XOR<TripCreateWithoutStopsInput, TripUncheckedCreateWithoutStopsInput>
    where?: TripWhereInput
  }

  export type TripUpdateToOneWithWhereWithoutStopsInput = {
    where?: TripWhereInput
    data: XOR<TripUpdateWithoutStopsInput, TripUncheckedUpdateWithoutStopsInput>
  }

  export type TripUpdateWithoutStopsInput = {
    id?: StringFieldUpdateOperationsInput | string
    tripId?: StringFieldUpdateOperationsInput | string
    city?: NullableStringFieldUpdateOperationsInput | string | null
    fromLocation?: NullableStringFieldUpdateOperationsInput | string | null
    toLocation?: NullableStringFieldUpdateOperationsInput | string | null
    destinationLat?: NullableFloatFieldUpdateOperationsInput | number | null
    destinationLng?: NullableFloatFieldUpdateOperationsInput | number | null
    googlePlaceId?: NullableStringFieldUpdateOperationsInput | string | null
    plannedDistance?: NullableFloatFieldUpdateOperationsInput | number | null
    vehicleType?: NullableEnumVehicleTypeFieldUpdateOperationsInput | $Enums.VehicleType | null
    fuelType?: NullableEnumFuelTypeFieldUpdateOperationsInput | $Enums.FuelType | null
    purpose?: NullableStringFieldUpdateOperationsInput | string | null
    notes?: NullableStringFieldUpdateOperationsInput | string | null
    status?: EnumTripStatusFieldUpdateOperationsInput | $Enums.TripStatus
    totalDistance?: FloatFieldUpdateOperationsInput | number
    travelDuration?: IntFieldUpdateOperationsInput | number
    idleTime?: IntFieldUpdateOperationsInput | number
    meetingDuration?: IntFieldUpdateOperationsInput | number
    productivityScore?: NullableFloatFieldUpdateOperationsInput | number | null
    tripEfficiency?: NullableFloatFieldUpdateOperationsInput | number | null
    startedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    arrivedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    completedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    user?: UserUpdateOneRequiredWithoutTripsNestedInput
    punches?: PunchUpdateManyWithoutTripNestedInput
    gpsPoints?: GpsPointUpdateManyWithoutTripNestedInput
  }

  export type TripUncheckedUpdateWithoutStopsInput = {
    id?: StringFieldUpdateOperationsInput | string
    tripId?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    city?: NullableStringFieldUpdateOperationsInput | string | null
    fromLocation?: NullableStringFieldUpdateOperationsInput | string | null
    toLocation?: NullableStringFieldUpdateOperationsInput | string | null
    destinationLat?: NullableFloatFieldUpdateOperationsInput | number | null
    destinationLng?: NullableFloatFieldUpdateOperationsInput | number | null
    googlePlaceId?: NullableStringFieldUpdateOperationsInput | string | null
    plannedDistance?: NullableFloatFieldUpdateOperationsInput | number | null
    vehicleType?: NullableEnumVehicleTypeFieldUpdateOperationsInput | $Enums.VehicleType | null
    fuelType?: NullableEnumFuelTypeFieldUpdateOperationsInput | $Enums.FuelType | null
    purpose?: NullableStringFieldUpdateOperationsInput | string | null
    notes?: NullableStringFieldUpdateOperationsInput | string | null
    status?: EnumTripStatusFieldUpdateOperationsInput | $Enums.TripStatus
    totalDistance?: FloatFieldUpdateOperationsInput | number
    travelDuration?: IntFieldUpdateOperationsInput | number
    idleTime?: IntFieldUpdateOperationsInput | number
    meetingDuration?: IntFieldUpdateOperationsInput | number
    productivityScore?: NullableFloatFieldUpdateOperationsInput | number | null
    tripEfficiency?: NullableFloatFieldUpdateOperationsInput | number | null
    startedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    arrivedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    completedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    punches?: PunchUncheckedUpdateManyWithoutTripNestedInput
    gpsPoints?: GpsPointUncheckedUpdateManyWithoutTripNestedInput
  }

  export type UserCreateWithoutNotificationsInput = {
    id?: string
    uid: string
    email: string
    passwordHash: string
    fullName: string
    employeeCode: string
    mobileNumber?: string | null
    sittingLocation?: string | null
    role?: $Enums.UserRole
    deviceId?: string | null
    profileImage?: string | null
    status?: $Enums.UserStatus
    fcmToken?: string | null
    isRooted?: boolean
    presence?: $Enums.EmployeePresence
    lastSeenAt?: Date | string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    reportingManager?: UserCreateNestedOneWithoutDirectReportsInput
    directReports?: UserCreateNestedManyWithoutReportingManagerInput
    refreshTokens?: RefreshTokenCreateNestedManyWithoutUserInput
    trips?: TripCreateNestedManyWithoutUserInput
    gpsPoints?: GpsPointCreateNestedManyWithoutUserInput
    auditLogs?: AuditLogCreateNestedManyWithoutActorInput
  }

  export type UserUncheckedCreateWithoutNotificationsInput = {
    id?: string
    uid: string
    email: string
    passwordHash: string
    fullName: string
    employeeCode: string
    mobileNumber?: string | null
    sittingLocation?: string | null
    reportingManagerId?: string | null
    role?: $Enums.UserRole
    deviceId?: string | null
    profileImage?: string | null
    status?: $Enums.UserStatus
    fcmToken?: string | null
    isRooted?: boolean
    presence?: $Enums.EmployeePresence
    lastSeenAt?: Date | string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    directReports?: UserUncheckedCreateNestedManyWithoutReportingManagerInput
    refreshTokens?: RefreshTokenUncheckedCreateNestedManyWithoutUserInput
    trips?: TripUncheckedCreateNestedManyWithoutUserInput
    gpsPoints?: GpsPointUncheckedCreateNestedManyWithoutUserInput
    auditLogs?: AuditLogUncheckedCreateNestedManyWithoutActorInput
  }

  export type UserCreateOrConnectWithoutNotificationsInput = {
    where: UserWhereUniqueInput
    create: XOR<UserCreateWithoutNotificationsInput, UserUncheckedCreateWithoutNotificationsInput>
  }

  export type UserUpsertWithoutNotificationsInput = {
    update: XOR<UserUpdateWithoutNotificationsInput, UserUncheckedUpdateWithoutNotificationsInput>
    create: XOR<UserCreateWithoutNotificationsInput, UserUncheckedCreateWithoutNotificationsInput>
    where?: UserWhereInput
  }

  export type UserUpdateToOneWithWhereWithoutNotificationsInput = {
    where?: UserWhereInput
    data: XOR<UserUpdateWithoutNotificationsInput, UserUncheckedUpdateWithoutNotificationsInput>
  }

  export type UserUpdateWithoutNotificationsInput = {
    id?: StringFieldUpdateOperationsInput | string
    uid?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    fullName?: StringFieldUpdateOperationsInput | string
    employeeCode?: StringFieldUpdateOperationsInput | string
    mobileNumber?: NullableStringFieldUpdateOperationsInput | string | null
    sittingLocation?: NullableStringFieldUpdateOperationsInput | string | null
    role?: EnumUserRoleFieldUpdateOperationsInput | $Enums.UserRole
    deviceId?: NullableStringFieldUpdateOperationsInput | string | null
    profileImage?: NullableStringFieldUpdateOperationsInput | string | null
    status?: EnumUserStatusFieldUpdateOperationsInput | $Enums.UserStatus
    fcmToken?: NullableStringFieldUpdateOperationsInput | string | null
    isRooted?: BoolFieldUpdateOperationsInput | boolean
    presence?: EnumEmployeePresenceFieldUpdateOperationsInput | $Enums.EmployeePresence
    lastSeenAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    reportingManager?: UserUpdateOneWithoutDirectReportsNestedInput
    directReports?: UserUpdateManyWithoutReportingManagerNestedInput
    refreshTokens?: RefreshTokenUpdateManyWithoutUserNestedInput
    trips?: TripUpdateManyWithoutUserNestedInput
    gpsPoints?: GpsPointUpdateManyWithoutUserNestedInput
    auditLogs?: AuditLogUpdateManyWithoutActorNestedInput
  }

  export type UserUncheckedUpdateWithoutNotificationsInput = {
    id?: StringFieldUpdateOperationsInput | string
    uid?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    fullName?: StringFieldUpdateOperationsInput | string
    employeeCode?: StringFieldUpdateOperationsInput | string
    mobileNumber?: NullableStringFieldUpdateOperationsInput | string | null
    sittingLocation?: NullableStringFieldUpdateOperationsInput | string | null
    reportingManagerId?: NullableStringFieldUpdateOperationsInput | string | null
    role?: EnumUserRoleFieldUpdateOperationsInput | $Enums.UserRole
    deviceId?: NullableStringFieldUpdateOperationsInput | string | null
    profileImage?: NullableStringFieldUpdateOperationsInput | string | null
    status?: EnumUserStatusFieldUpdateOperationsInput | $Enums.UserStatus
    fcmToken?: NullableStringFieldUpdateOperationsInput | string | null
    isRooted?: BoolFieldUpdateOperationsInput | boolean
    presence?: EnumEmployeePresenceFieldUpdateOperationsInput | $Enums.EmployeePresence
    lastSeenAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    directReports?: UserUncheckedUpdateManyWithoutReportingManagerNestedInput
    refreshTokens?: RefreshTokenUncheckedUpdateManyWithoutUserNestedInput
    trips?: TripUncheckedUpdateManyWithoutUserNestedInput
    gpsPoints?: GpsPointUncheckedUpdateManyWithoutUserNestedInput
    auditLogs?: AuditLogUncheckedUpdateManyWithoutActorNestedInput
  }

  export type UserCreateManyReportingManagerInput = {
    id?: string
    uid: string
    email: string
    passwordHash: string
    fullName: string
    employeeCode: string
    mobileNumber?: string | null
    sittingLocation?: string | null
    role?: $Enums.UserRole
    deviceId?: string | null
    profileImage?: string | null
    status?: $Enums.UserStatus
    fcmToken?: string | null
    isRooted?: boolean
    presence?: $Enums.EmployeePresence
    lastSeenAt?: Date | string | null
    createdAt?: Date | string
    updatedAt?: Date | string
  }

  export type RefreshTokenCreateManyUserInput = {
    id?: string
    tokenHash: string
    deviceId?: string | null
    expiresAt: Date | string
    createdAt?: Date | string
  }

  export type TripCreateManyUserInput = {
    id?: string
    tripId?: string
    city?: string | null
    fromLocation?: string | null
    toLocation?: string | null
    destinationLat?: number | null
    destinationLng?: number | null
    googlePlaceId?: string | null
    plannedDistance?: number | null
    vehicleType?: $Enums.VehicleType | null
    fuelType?: $Enums.FuelType | null
    purpose?: string | null
    notes?: string | null
    status?: $Enums.TripStatus
    totalDistance?: number
    travelDuration?: number
    idleTime?: number
    meetingDuration?: number
    productivityScore?: number | null
    tripEfficiency?: number | null
    startedAt?: Date | string | null
    arrivedAt?: Date | string | null
    completedAt?: Date | string | null
    createdAt?: Date | string
    updatedAt?: Date | string
  }

  export type GpsPointCreateManyUserInput = {
    id?: string
    tripId?: string | null
    clientPointId?: string | null
    latitude: number
    longitude: number
    accuracy?: number | null
    speed?: number | null
    bearing?: number | null
    batteryLevel?: number | null
    timestamp: Date | string
    isSmoothed?: boolean
    createdAt?: Date | string
  }

  export type AuditLogCreateManyActorInput = {
    id?: string
    actorEmail?: string | null
    action: string
    targetType?: string | null
    targetId?: string | null
    metadata?: NullableJsonNullValueInput | InputJsonValue
    ipAddress?: string | null
    userAgent?: string | null
    createdAt?: Date | string
  }

  export type NotificationCreateManyUserInput = {
    id?: string
    type: $Enums.NotificationType
    title: string
    body: string
    data?: NullableJsonNullValueInput | InputJsonValue
    read?: boolean
    sentAt?: Date | string
  }

  export type UserUpdateWithoutReportingManagerInput = {
    id?: StringFieldUpdateOperationsInput | string
    uid?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    fullName?: StringFieldUpdateOperationsInput | string
    employeeCode?: StringFieldUpdateOperationsInput | string
    mobileNumber?: NullableStringFieldUpdateOperationsInput | string | null
    sittingLocation?: NullableStringFieldUpdateOperationsInput | string | null
    role?: EnumUserRoleFieldUpdateOperationsInput | $Enums.UserRole
    deviceId?: NullableStringFieldUpdateOperationsInput | string | null
    profileImage?: NullableStringFieldUpdateOperationsInput | string | null
    status?: EnumUserStatusFieldUpdateOperationsInput | $Enums.UserStatus
    fcmToken?: NullableStringFieldUpdateOperationsInput | string | null
    isRooted?: BoolFieldUpdateOperationsInput | boolean
    presence?: EnumEmployeePresenceFieldUpdateOperationsInput | $Enums.EmployeePresence
    lastSeenAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    directReports?: UserUpdateManyWithoutReportingManagerNestedInput
    refreshTokens?: RefreshTokenUpdateManyWithoutUserNestedInput
    trips?: TripUpdateManyWithoutUserNestedInput
    gpsPoints?: GpsPointUpdateManyWithoutUserNestedInput
    auditLogs?: AuditLogUpdateManyWithoutActorNestedInput
    notifications?: NotificationUpdateManyWithoutUserNestedInput
  }

  export type UserUncheckedUpdateWithoutReportingManagerInput = {
    id?: StringFieldUpdateOperationsInput | string
    uid?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    fullName?: StringFieldUpdateOperationsInput | string
    employeeCode?: StringFieldUpdateOperationsInput | string
    mobileNumber?: NullableStringFieldUpdateOperationsInput | string | null
    sittingLocation?: NullableStringFieldUpdateOperationsInput | string | null
    role?: EnumUserRoleFieldUpdateOperationsInput | $Enums.UserRole
    deviceId?: NullableStringFieldUpdateOperationsInput | string | null
    profileImage?: NullableStringFieldUpdateOperationsInput | string | null
    status?: EnumUserStatusFieldUpdateOperationsInput | $Enums.UserStatus
    fcmToken?: NullableStringFieldUpdateOperationsInput | string | null
    isRooted?: BoolFieldUpdateOperationsInput | boolean
    presence?: EnumEmployeePresenceFieldUpdateOperationsInput | $Enums.EmployeePresence
    lastSeenAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    directReports?: UserUncheckedUpdateManyWithoutReportingManagerNestedInput
    refreshTokens?: RefreshTokenUncheckedUpdateManyWithoutUserNestedInput
    trips?: TripUncheckedUpdateManyWithoutUserNestedInput
    gpsPoints?: GpsPointUncheckedUpdateManyWithoutUserNestedInput
    auditLogs?: AuditLogUncheckedUpdateManyWithoutActorNestedInput
    notifications?: NotificationUncheckedUpdateManyWithoutUserNestedInput
  }

  export type UserUncheckedUpdateManyWithoutReportingManagerInput = {
    id?: StringFieldUpdateOperationsInput | string
    uid?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    fullName?: StringFieldUpdateOperationsInput | string
    employeeCode?: StringFieldUpdateOperationsInput | string
    mobileNumber?: NullableStringFieldUpdateOperationsInput | string | null
    sittingLocation?: NullableStringFieldUpdateOperationsInput | string | null
    role?: EnumUserRoleFieldUpdateOperationsInput | $Enums.UserRole
    deviceId?: NullableStringFieldUpdateOperationsInput | string | null
    profileImage?: NullableStringFieldUpdateOperationsInput | string | null
    status?: EnumUserStatusFieldUpdateOperationsInput | $Enums.UserStatus
    fcmToken?: NullableStringFieldUpdateOperationsInput | string | null
    isRooted?: BoolFieldUpdateOperationsInput | boolean
    presence?: EnumEmployeePresenceFieldUpdateOperationsInput | $Enums.EmployeePresence
    lastSeenAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type RefreshTokenUpdateWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    tokenHash?: StringFieldUpdateOperationsInput | string
    deviceId?: NullableStringFieldUpdateOperationsInput | string | null
    expiresAt?: DateTimeFieldUpdateOperationsInput | Date | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type RefreshTokenUncheckedUpdateWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    tokenHash?: StringFieldUpdateOperationsInput | string
    deviceId?: NullableStringFieldUpdateOperationsInput | string | null
    expiresAt?: DateTimeFieldUpdateOperationsInput | Date | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type RefreshTokenUncheckedUpdateManyWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    tokenHash?: StringFieldUpdateOperationsInput | string
    deviceId?: NullableStringFieldUpdateOperationsInput | string | null
    expiresAt?: DateTimeFieldUpdateOperationsInput | Date | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type TripUpdateWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    tripId?: StringFieldUpdateOperationsInput | string
    city?: NullableStringFieldUpdateOperationsInput | string | null
    fromLocation?: NullableStringFieldUpdateOperationsInput | string | null
    toLocation?: NullableStringFieldUpdateOperationsInput | string | null
    destinationLat?: NullableFloatFieldUpdateOperationsInput | number | null
    destinationLng?: NullableFloatFieldUpdateOperationsInput | number | null
    googlePlaceId?: NullableStringFieldUpdateOperationsInput | string | null
    plannedDistance?: NullableFloatFieldUpdateOperationsInput | number | null
    vehicleType?: NullableEnumVehicleTypeFieldUpdateOperationsInput | $Enums.VehicleType | null
    fuelType?: NullableEnumFuelTypeFieldUpdateOperationsInput | $Enums.FuelType | null
    purpose?: NullableStringFieldUpdateOperationsInput | string | null
    notes?: NullableStringFieldUpdateOperationsInput | string | null
    status?: EnumTripStatusFieldUpdateOperationsInput | $Enums.TripStatus
    totalDistance?: FloatFieldUpdateOperationsInput | number
    travelDuration?: IntFieldUpdateOperationsInput | number
    idleTime?: IntFieldUpdateOperationsInput | number
    meetingDuration?: IntFieldUpdateOperationsInput | number
    productivityScore?: NullableFloatFieldUpdateOperationsInput | number | null
    tripEfficiency?: NullableFloatFieldUpdateOperationsInput | number | null
    startedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    arrivedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    completedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    punches?: PunchUpdateManyWithoutTripNestedInput
    gpsPoints?: GpsPointUpdateManyWithoutTripNestedInput
    stops?: GpsStopUpdateManyWithoutTripNestedInput
  }

  export type TripUncheckedUpdateWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    tripId?: StringFieldUpdateOperationsInput | string
    city?: NullableStringFieldUpdateOperationsInput | string | null
    fromLocation?: NullableStringFieldUpdateOperationsInput | string | null
    toLocation?: NullableStringFieldUpdateOperationsInput | string | null
    destinationLat?: NullableFloatFieldUpdateOperationsInput | number | null
    destinationLng?: NullableFloatFieldUpdateOperationsInput | number | null
    googlePlaceId?: NullableStringFieldUpdateOperationsInput | string | null
    plannedDistance?: NullableFloatFieldUpdateOperationsInput | number | null
    vehicleType?: NullableEnumVehicleTypeFieldUpdateOperationsInput | $Enums.VehicleType | null
    fuelType?: NullableEnumFuelTypeFieldUpdateOperationsInput | $Enums.FuelType | null
    purpose?: NullableStringFieldUpdateOperationsInput | string | null
    notes?: NullableStringFieldUpdateOperationsInput | string | null
    status?: EnumTripStatusFieldUpdateOperationsInput | $Enums.TripStatus
    totalDistance?: FloatFieldUpdateOperationsInput | number
    travelDuration?: IntFieldUpdateOperationsInput | number
    idleTime?: IntFieldUpdateOperationsInput | number
    meetingDuration?: IntFieldUpdateOperationsInput | number
    productivityScore?: NullableFloatFieldUpdateOperationsInput | number | null
    tripEfficiency?: NullableFloatFieldUpdateOperationsInput | number | null
    startedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    arrivedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    completedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    punches?: PunchUncheckedUpdateManyWithoutTripNestedInput
    gpsPoints?: GpsPointUncheckedUpdateManyWithoutTripNestedInput
    stops?: GpsStopUncheckedUpdateManyWithoutTripNestedInput
  }

  export type TripUncheckedUpdateManyWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    tripId?: StringFieldUpdateOperationsInput | string
    city?: NullableStringFieldUpdateOperationsInput | string | null
    fromLocation?: NullableStringFieldUpdateOperationsInput | string | null
    toLocation?: NullableStringFieldUpdateOperationsInput | string | null
    destinationLat?: NullableFloatFieldUpdateOperationsInput | number | null
    destinationLng?: NullableFloatFieldUpdateOperationsInput | number | null
    googlePlaceId?: NullableStringFieldUpdateOperationsInput | string | null
    plannedDistance?: NullableFloatFieldUpdateOperationsInput | number | null
    vehicleType?: NullableEnumVehicleTypeFieldUpdateOperationsInput | $Enums.VehicleType | null
    fuelType?: NullableEnumFuelTypeFieldUpdateOperationsInput | $Enums.FuelType | null
    purpose?: NullableStringFieldUpdateOperationsInput | string | null
    notes?: NullableStringFieldUpdateOperationsInput | string | null
    status?: EnumTripStatusFieldUpdateOperationsInput | $Enums.TripStatus
    totalDistance?: FloatFieldUpdateOperationsInput | number
    travelDuration?: IntFieldUpdateOperationsInput | number
    idleTime?: IntFieldUpdateOperationsInput | number
    meetingDuration?: IntFieldUpdateOperationsInput | number
    productivityScore?: NullableFloatFieldUpdateOperationsInput | number | null
    tripEfficiency?: NullableFloatFieldUpdateOperationsInput | number | null
    startedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    arrivedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    completedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type GpsPointUpdateWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    clientPointId?: NullableStringFieldUpdateOperationsInput | string | null
    latitude?: FloatFieldUpdateOperationsInput | number
    longitude?: FloatFieldUpdateOperationsInput | number
    accuracy?: NullableFloatFieldUpdateOperationsInput | number | null
    speed?: NullableFloatFieldUpdateOperationsInput | number | null
    bearing?: NullableFloatFieldUpdateOperationsInput | number | null
    batteryLevel?: NullableFloatFieldUpdateOperationsInput | number | null
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
    isSmoothed?: BoolFieldUpdateOperationsInput | boolean
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    trip?: TripUpdateOneWithoutGpsPointsNestedInput
  }

  export type GpsPointUncheckedUpdateWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    tripId?: NullableStringFieldUpdateOperationsInput | string | null
    clientPointId?: NullableStringFieldUpdateOperationsInput | string | null
    latitude?: FloatFieldUpdateOperationsInput | number
    longitude?: FloatFieldUpdateOperationsInput | number
    accuracy?: NullableFloatFieldUpdateOperationsInput | number | null
    speed?: NullableFloatFieldUpdateOperationsInput | number | null
    bearing?: NullableFloatFieldUpdateOperationsInput | number | null
    batteryLevel?: NullableFloatFieldUpdateOperationsInput | number | null
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
    isSmoothed?: BoolFieldUpdateOperationsInput | boolean
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type GpsPointUncheckedUpdateManyWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    tripId?: NullableStringFieldUpdateOperationsInput | string | null
    clientPointId?: NullableStringFieldUpdateOperationsInput | string | null
    latitude?: FloatFieldUpdateOperationsInput | number
    longitude?: FloatFieldUpdateOperationsInput | number
    accuracy?: NullableFloatFieldUpdateOperationsInput | number | null
    speed?: NullableFloatFieldUpdateOperationsInput | number | null
    bearing?: NullableFloatFieldUpdateOperationsInput | number | null
    batteryLevel?: NullableFloatFieldUpdateOperationsInput | number | null
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
    isSmoothed?: BoolFieldUpdateOperationsInput | boolean
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type AuditLogUpdateWithoutActorInput = {
    id?: StringFieldUpdateOperationsInput | string
    actorEmail?: NullableStringFieldUpdateOperationsInput | string | null
    action?: StringFieldUpdateOperationsInput | string
    targetType?: NullableStringFieldUpdateOperationsInput | string | null
    targetId?: NullableStringFieldUpdateOperationsInput | string | null
    metadata?: NullableJsonNullValueInput | InputJsonValue
    ipAddress?: NullableStringFieldUpdateOperationsInput | string | null
    userAgent?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type AuditLogUncheckedUpdateWithoutActorInput = {
    id?: StringFieldUpdateOperationsInput | string
    actorEmail?: NullableStringFieldUpdateOperationsInput | string | null
    action?: StringFieldUpdateOperationsInput | string
    targetType?: NullableStringFieldUpdateOperationsInput | string | null
    targetId?: NullableStringFieldUpdateOperationsInput | string | null
    metadata?: NullableJsonNullValueInput | InputJsonValue
    ipAddress?: NullableStringFieldUpdateOperationsInput | string | null
    userAgent?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type AuditLogUncheckedUpdateManyWithoutActorInput = {
    id?: StringFieldUpdateOperationsInput | string
    actorEmail?: NullableStringFieldUpdateOperationsInput | string | null
    action?: StringFieldUpdateOperationsInput | string
    targetType?: NullableStringFieldUpdateOperationsInput | string | null
    targetId?: NullableStringFieldUpdateOperationsInput | string | null
    metadata?: NullableJsonNullValueInput | InputJsonValue
    ipAddress?: NullableStringFieldUpdateOperationsInput | string | null
    userAgent?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type NotificationUpdateWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    type?: EnumNotificationTypeFieldUpdateOperationsInput | $Enums.NotificationType
    title?: StringFieldUpdateOperationsInput | string
    body?: StringFieldUpdateOperationsInput | string
    data?: NullableJsonNullValueInput | InputJsonValue
    read?: BoolFieldUpdateOperationsInput | boolean
    sentAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type NotificationUncheckedUpdateWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    type?: EnumNotificationTypeFieldUpdateOperationsInput | $Enums.NotificationType
    title?: StringFieldUpdateOperationsInput | string
    body?: StringFieldUpdateOperationsInput | string
    data?: NullableJsonNullValueInput | InputJsonValue
    read?: BoolFieldUpdateOperationsInput | boolean
    sentAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type NotificationUncheckedUpdateManyWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    type?: EnumNotificationTypeFieldUpdateOperationsInput | $Enums.NotificationType
    title?: StringFieldUpdateOperationsInput | string
    body?: StringFieldUpdateOperationsInput | string
    data?: NullableJsonNullValueInput | InputJsonValue
    read?: BoolFieldUpdateOperationsInput | boolean
    sentAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type PunchCreateManyTripInput = {
    id?: string
    type: $Enums.PunchType
    timestamp: Date | string
    latitude: number
    longitude: number
    address?: string | null
    batteryPercent?: number | null
    gpsAccuracy?: number | null
    speed?: number | null
    isMockLocation?: boolean
    meetingSummary?: string | null
    leadType?: $Enums.LeadType | null
    customerNotes?: string | null
    createdAt?: Date | string
  }

  export type GpsPointCreateManyTripInput = {
    id?: string
    userId: string
    clientPointId?: string | null
    latitude: number
    longitude: number
    accuracy?: number | null
    speed?: number | null
    bearing?: number | null
    batteryLevel?: number | null
    timestamp: Date | string
    isSmoothed?: boolean
    createdAt?: Date | string
  }

  export type GpsStopCreateManyTripInput = {
    id?: string
    latitude: number
    longitude: number
    startedAt: Date | string
    endedAt?: Date | string | null
    duration?: number | null
    address?: string | null
  }

  export type PunchUpdateWithoutTripInput = {
    id?: StringFieldUpdateOperationsInput | string
    type?: EnumPunchTypeFieldUpdateOperationsInput | $Enums.PunchType
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
    latitude?: FloatFieldUpdateOperationsInput | number
    longitude?: FloatFieldUpdateOperationsInput | number
    address?: NullableStringFieldUpdateOperationsInput | string | null
    batteryPercent?: NullableFloatFieldUpdateOperationsInput | number | null
    gpsAccuracy?: NullableFloatFieldUpdateOperationsInput | number | null
    speed?: NullableFloatFieldUpdateOperationsInput | number | null
    isMockLocation?: BoolFieldUpdateOperationsInput | boolean
    meetingSummary?: NullableStringFieldUpdateOperationsInput | string | null
    leadType?: NullableEnumLeadTypeFieldUpdateOperationsInput | $Enums.LeadType | null
    customerNotes?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type PunchUncheckedUpdateWithoutTripInput = {
    id?: StringFieldUpdateOperationsInput | string
    type?: EnumPunchTypeFieldUpdateOperationsInput | $Enums.PunchType
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
    latitude?: FloatFieldUpdateOperationsInput | number
    longitude?: FloatFieldUpdateOperationsInput | number
    address?: NullableStringFieldUpdateOperationsInput | string | null
    batteryPercent?: NullableFloatFieldUpdateOperationsInput | number | null
    gpsAccuracy?: NullableFloatFieldUpdateOperationsInput | number | null
    speed?: NullableFloatFieldUpdateOperationsInput | number | null
    isMockLocation?: BoolFieldUpdateOperationsInput | boolean
    meetingSummary?: NullableStringFieldUpdateOperationsInput | string | null
    leadType?: NullableEnumLeadTypeFieldUpdateOperationsInput | $Enums.LeadType | null
    customerNotes?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type PunchUncheckedUpdateManyWithoutTripInput = {
    id?: StringFieldUpdateOperationsInput | string
    type?: EnumPunchTypeFieldUpdateOperationsInput | $Enums.PunchType
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
    latitude?: FloatFieldUpdateOperationsInput | number
    longitude?: FloatFieldUpdateOperationsInput | number
    address?: NullableStringFieldUpdateOperationsInput | string | null
    batteryPercent?: NullableFloatFieldUpdateOperationsInput | number | null
    gpsAccuracy?: NullableFloatFieldUpdateOperationsInput | number | null
    speed?: NullableFloatFieldUpdateOperationsInput | number | null
    isMockLocation?: BoolFieldUpdateOperationsInput | boolean
    meetingSummary?: NullableStringFieldUpdateOperationsInput | string | null
    leadType?: NullableEnumLeadTypeFieldUpdateOperationsInput | $Enums.LeadType | null
    customerNotes?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type GpsPointUpdateWithoutTripInput = {
    id?: StringFieldUpdateOperationsInput | string
    clientPointId?: NullableStringFieldUpdateOperationsInput | string | null
    latitude?: FloatFieldUpdateOperationsInput | number
    longitude?: FloatFieldUpdateOperationsInput | number
    accuracy?: NullableFloatFieldUpdateOperationsInput | number | null
    speed?: NullableFloatFieldUpdateOperationsInput | number | null
    bearing?: NullableFloatFieldUpdateOperationsInput | number | null
    batteryLevel?: NullableFloatFieldUpdateOperationsInput | number | null
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
    isSmoothed?: BoolFieldUpdateOperationsInput | boolean
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    user?: UserUpdateOneRequiredWithoutGpsPointsNestedInput
  }

  export type GpsPointUncheckedUpdateWithoutTripInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    clientPointId?: NullableStringFieldUpdateOperationsInput | string | null
    latitude?: FloatFieldUpdateOperationsInput | number
    longitude?: FloatFieldUpdateOperationsInput | number
    accuracy?: NullableFloatFieldUpdateOperationsInput | number | null
    speed?: NullableFloatFieldUpdateOperationsInput | number | null
    bearing?: NullableFloatFieldUpdateOperationsInput | number | null
    batteryLevel?: NullableFloatFieldUpdateOperationsInput | number | null
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
    isSmoothed?: BoolFieldUpdateOperationsInput | boolean
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type GpsPointUncheckedUpdateManyWithoutTripInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    clientPointId?: NullableStringFieldUpdateOperationsInput | string | null
    latitude?: FloatFieldUpdateOperationsInput | number
    longitude?: FloatFieldUpdateOperationsInput | number
    accuracy?: NullableFloatFieldUpdateOperationsInput | number | null
    speed?: NullableFloatFieldUpdateOperationsInput | number | null
    bearing?: NullableFloatFieldUpdateOperationsInput | number | null
    batteryLevel?: NullableFloatFieldUpdateOperationsInput | number | null
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
    isSmoothed?: BoolFieldUpdateOperationsInput | boolean
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type GpsStopUpdateWithoutTripInput = {
    id?: StringFieldUpdateOperationsInput | string
    latitude?: FloatFieldUpdateOperationsInput | number
    longitude?: FloatFieldUpdateOperationsInput | number
    startedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    endedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    duration?: NullableIntFieldUpdateOperationsInput | number | null
    address?: NullableStringFieldUpdateOperationsInput | string | null
  }

  export type GpsStopUncheckedUpdateWithoutTripInput = {
    id?: StringFieldUpdateOperationsInput | string
    latitude?: FloatFieldUpdateOperationsInput | number
    longitude?: FloatFieldUpdateOperationsInput | number
    startedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    endedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    duration?: NullableIntFieldUpdateOperationsInput | number | null
    address?: NullableStringFieldUpdateOperationsInput | string | null
  }

  export type GpsStopUncheckedUpdateManyWithoutTripInput = {
    id?: StringFieldUpdateOperationsInput | string
    latitude?: FloatFieldUpdateOperationsInput | number
    longitude?: FloatFieldUpdateOperationsInput | number
    startedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    endedAt?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    duration?: NullableIntFieldUpdateOperationsInput | number | null
    address?: NullableStringFieldUpdateOperationsInput | string | null
  }



  /**
   * Batch Payload for updateMany & deleteMany & createMany
   */

  export type BatchPayload = {
    count: number
  }

  /**
   * DMMF
   */
  export const dmmf: runtime.BaseDMMF
}