
/**
 * 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 Otp
 * 
 */
export type Otp = $Result.DefaultSelection<Prisma.$OtpPayload>
/**
 * Model Session
 * 
 */
export type Session = $Result.DefaultSelection<Prisma.$SessionPayload>
/**
 * Model Group
 * 
 */
export type Group = $Result.DefaultSelection<Prisma.$GroupPayload>
/**
 * Model GroupApplication
 * 
 */
export type GroupApplication = $Result.DefaultSelection<Prisma.$GroupApplicationPayload>
/**
 * Model Membership
 * 
 */
export type Membership = $Result.DefaultSelection<Prisma.$MembershipPayload>
/**
 * Model Invite
 * 
 */
export type Invite = $Result.DefaultSelection<Prisma.$InvitePayload>
/**
 * Model MonthlyCycle
 * 
 */
export type MonthlyCycle = $Result.DefaultSelection<Prisma.$MonthlyCyclePayload>
/**
 * Model Contribution
 * 
 */
export type Contribution = $Result.DefaultSelection<Prisma.$ContributionPayload>
/**
 * Model Cashout
 * 
 */
export type Cashout = $Result.DefaultSelection<Prisma.$CashoutPayload>
/**
 * Model Loan
 * 
 */
export type Loan = $Result.DefaultSelection<Prisma.$LoanPayload>
/**
 * Model CoverageDecision
 * 
 */
export type CoverageDecision = $Result.DefaultSelection<Prisma.$CoverageDecisionPayload>
/**
 * Model Reintegration
 * 
 */
export type Reintegration = $Result.DefaultSelection<Prisma.$ReintegrationPayload>
/**
 * Model FeeConfiguration
 * 
 */
export type FeeConfiguration = $Result.DefaultSelection<Prisma.$FeeConfigurationPayload>
/**
 * Model CoverageFund
 * 
 */
export type CoverageFund = $Result.DefaultSelection<Prisma.$CoverageFundPayload>
/**
 * Model Transaction
 * 
 */
export type Transaction = $Result.DefaultSelection<Prisma.$TransactionPayload>
/**
 * Model ScoreEvent
 * 
 */
export type ScoreEvent = $Result.DefaultSelection<Prisma.$ScoreEventPayload>
/**
 * Model Notification
 * 
 */
export type Notification = $Result.DefaultSelection<Prisma.$NotificationPayload>
/**
 * Model AuditLog
 * 
 */
export type AuditLog = $Result.DefaultSelection<Prisma.$AuditLogPayload>
/**
 * Model SystemClock
 * 
 */
export type SystemClock = $Result.DefaultSelection<Prisma.$SystemClockPayload>
/**
 * Model CreditApplication
 * 
 */
export type CreditApplication = $Result.DefaultSelection<Prisma.$CreditApplicationPayload>
/**
 * Model CreditInstallment
 * 
 */
export type CreditInstallment = $Result.DefaultSelection<Prisma.$CreditInstallmentPayload>
/**
 * Model SavingsAccount
 * 
 */
export type SavingsAccount = $Result.DefaultSelection<Prisma.$SavingsAccountPayload>
/**
 * Model SavingsMovement
 * 
 */
export type SavingsMovement = $Result.DefaultSelection<Prisma.$SavingsMovementPayload>
/**
 * Model Referral
 * 
 */
export type Referral = $Result.DefaultSelection<Prisma.$ReferralPayload>
/**
 * Model ContentArticle
 * 
 */
export type ContentArticle = $Result.DefaultSelection<Prisma.$ContentArticlePayload>
/**
 * Model Quiz
 * 
 */
export type Quiz = $Result.DefaultSelection<Prisma.$QuizPayload>
/**
 * Model QuizAttempt
 * 
 */
export type QuizAttempt = $Result.DefaultSelection<Prisma.$QuizAttemptPayload>
/**
 * Model Badge
 * 
 */
export type Badge = $Result.DefaultSelection<Prisma.$BadgePayload>
/**
 * Model ApiKey
 * 
 */
export type ApiKey = $Result.DefaultSelection<Prisma.$ApiKeyPayload>
/**
 * Model ApiCall
 * 
 */
export type ApiCall = $Result.DefaultSelection<Prisma.$ApiCallPayload>
/**
 * Model InsuranceProduct
 * 
 */
export type InsuranceProduct = $Result.DefaultSelection<Prisma.$InsuranceProductPayload>
/**
 * Model InsurancePolicy
 * 
 */
export type InsurancePolicy = $Result.DefaultSelection<Prisma.$InsurancePolicyPayload>
/**
 * Model Country
 * 
 */
export type Country = $Result.DefaultSelection<Prisma.$CountryPayload>
/**
 * Model AnalyticsSnapshot
 * 
 */
export type AnalyticsSnapshot = $Result.DefaultSelection<Prisma.$AnalyticsSnapshotPayload>

/**
 * ##  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,
  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): void;

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

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

  /**
   * Add a middleware
   * @deprecated since 4.16.0. For new code, prefer client extensions instead.
   * @see https://pris.ly/d/extensions
   */
  $use(cb: Prisma.Middleware): 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, 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>;

  /**
   * `prisma.otp`: Exposes CRUD operations for the **Otp** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more Otps
    * const otps = await prisma.otp.findMany()
    * ```
    */
  get otp(): Prisma.OtpDelegate<ExtArgs>;

  /**
   * `prisma.session`: Exposes CRUD operations for the **Session** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more Sessions
    * const sessions = await prisma.session.findMany()
    * ```
    */
  get session(): Prisma.SessionDelegate<ExtArgs>;

  /**
   * `prisma.group`: Exposes CRUD operations for the **Group** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more Groups
    * const groups = await prisma.group.findMany()
    * ```
    */
  get group(): Prisma.GroupDelegate<ExtArgs>;

  /**
   * `prisma.groupApplication`: Exposes CRUD operations for the **GroupApplication** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more GroupApplications
    * const groupApplications = await prisma.groupApplication.findMany()
    * ```
    */
  get groupApplication(): Prisma.GroupApplicationDelegate<ExtArgs>;

  /**
   * `prisma.membership`: Exposes CRUD operations for the **Membership** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more Memberships
    * const memberships = await prisma.membership.findMany()
    * ```
    */
  get membership(): Prisma.MembershipDelegate<ExtArgs>;

  /**
   * `prisma.invite`: Exposes CRUD operations for the **Invite** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more Invites
    * const invites = await prisma.invite.findMany()
    * ```
    */
  get invite(): Prisma.InviteDelegate<ExtArgs>;

  /**
   * `prisma.monthlyCycle`: Exposes CRUD operations for the **MonthlyCycle** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more MonthlyCycles
    * const monthlyCycles = await prisma.monthlyCycle.findMany()
    * ```
    */
  get monthlyCycle(): Prisma.MonthlyCycleDelegate<ExtArgs>;

  /**
   * `prisma.contribution`: Exposes CRUD operations for the **Contribution** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more Contributions
    * const contributions = await prisma.contribution.findMany()
    * ```
    */
  get contribution(): Prisma.ContributionDelegate<ExtArgs>;

  /**
   * `prisma.cashout`: Exposes CRUD operations for the **Cashout** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more Cashouts
    * const cashouts = await prisma.cashout.findMany()
    * ```
    */
  get cashout(): Prisma.CashoutDelegate<ExtArgs>;

  /**
   * `prisma.loan`: Exposes CRUD operations for the **Loan** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more Loans
    * const loans = await prisma.loan.findMany()
    * ```
    */
  get loan(): Prisma.LoanDelegate<ExtArgs>;

  /**
   * `prisma.coverageDecision`: Exposes CRUD operations for the **CoverageDecision** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more CoverageDecisions
    * const coverageDecisions = await prisma.coverageDecision.findMany()
    * ```
    */
  get coverageDecision(): Prisma.CoverageDecisionDelegate<ExtArgs>;

  /**
   * `prisma.reintegration`: Exposes CRUD operations for the **Reintegration** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more Reintegrations
    * const reintegrations = await prisma.reintegration.findMany()
    * ```
    */
  get reintegration(): Prisma.ReintegrationDelegate<ExtArgs>;

  /**
   * `prisma.feeConfiguration`: Exposes CRUD operations for the **FeeConfiguration** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more FeeConfigurations
    * const feeConfigurations = await prisma.feeConfiguration.findMany()
    * ```
    */
  get feeConfiguration(): Prisma.FeeConfigurationDelegate<ExtArgs>;

  /**
   * `prisma.coverageFund`: Exposes CRUD operations for the **CoverageFund** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more CoverageFunds
    * const coverageFunds = await prisma.coverageFund.findMany()
    * ```
    */
  get coverageFund(): Prisma.CoverageFundDelegate<ExtArgs>;

  /**
   * `prisma.transaction`: Exposes CRUD operations for the **Transaction** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more Transactions
    * const transactions = await prisma.transaction.findMany()
    * ```
    */
  get transaction(): Prisma.TransactionDelegate<ExtArgs>;

  /**
   * `prisma.scoreEvent`: Exposes CRUD operations for the **ScoreEvent** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more ScoreEvents
    * const scoreEvents = await prisma.scoreEvent.findMany()
    * ```
    */
  get scoreEvent(): Prisma.ScoreEventDelegate<ExtArgs>;

  /**
   * `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>;

  /**
   * `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>;

  /**
   * `prisma.systemClock`: Exposes CRUD operations for the **SystemClock** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more SystemClocks
    * const systemClocks = await prisma.systemClock.findMany()
    * ```
    */
  get systemClock(): Prisma.SystemClockDelegate<ExtArgs>;

  /**
   * `prisma.creditApplication`: Exposes CRUD operations for the **CreditApplication** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more CreditApplications
    * const creditApplications = await prisma.creditApplication.findMany()
    * ```
    */
  get creditApplication(): Prisma.CreditApplicationDelegate<ExtArgs>;

  /**
   * `prisma.creditInstallment`: Exposes CRUD operations for the **CreditInstallment** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more CreditInstallments
    * const creditInstallments = await prisma.creditInstallment.findMany()
    * ```
    */
  get creditInstallment(): Prisma.CreditInstallmentDelegate<ExtArgs>;

  /**
   * `prisma.savingsAccount`: Exposes CRUD operations for the **SavingsAccount** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more SavingsAccounts
    * const savingsAccounts = await prisma.savingsAccount.findMany()
    * ```
    */
  get savingsAccount(): Prisma.SavingsAccountDelegate<ExtArgs>;

  /**
   * `prisma.savingsMovement`: Exposes CRUD operations for the **SavingsMovement** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more SavingsMovements
    * const savingsMovements = await prisma.savingsMovement.findMany()
    * ```
    */
  get savingsMovement(): Prisma.SavingsMovementDelegate<ExtArgs>;

  /**
   * `prisma.referral`: Exposes CRUD operations for the **Referral** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more Referrals
    * const referrals = await prisma.referral.findMany()
    * ```
    */
  get referral(): Prisma.ReferralDelegate<ExtArgs>;

  /**
   * `prisma.contentArticle`: Exposes CRUD operations for the **ContentArticle** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more ContentArticles
    * const contentArticles = await prisma.contentArticle.findMany()
    * ```
    */
  get contentArticle(): Prisma.ContentArticleDelegate<ExtArgs>;

  /**
   * `prisma.quiz`: Exposes CRUD operations for the **Quiz** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more Quizzes
    * const quizzes = await prisma.quiz.findMany()
    * ```
    */
  get quiz(): Prisma.QuizDelegate<ExtArgs>;

  /**
   * `prisma.quizAttempt`: Exposes CRUD operations for the **QuizAttempt** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more QuizAttempts
    * const quizAttempts = await prisma.quizAttempt.findMany()
    * ```
    */
  get quizAttempt(): Prisma.QuizAttemptDelegate<ExtArgs>;

  /**
   * `prisma.badge`: Exposes CRUD operations for the **Badge** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more Badges
    * const badges = await prisma.badge.findMany()
    * ```
    */
  get badge(): Prisma.BadgeDelegate<ExtArgs>;

  /**
   * `prisma.apiKey`: Exposes CRUD operations for the **ApiKey** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more ApiKeys
    * const apiKeys = await prisma.apiKey.findMany()
    * ```
    */
  get apiKey(): Prisma.ApiKeyDelegate<ExtArgs>;

  /**
   * `prisma.apiCall`: Exposes CRUD operations for the **ApiCall** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more ApiCalls
    * const apiCalls = await prisma.apiCall.findMany()
    * ```
    */
  get apiCall(): Prisma.ApiCallDelegate<ExtArgs>;

  /**
   * `prisma.insuranceProduct`: Exposes CRUD operations for the **InsuranceProduct** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more InsuranceProducts
    * const insuranceProducts = await prisma.insuranceProduct.findMany()
    * ```
    */
  get insuranceProduct(): Prisma.InsuranceProductDelegate<ExtArgs>;

  /**
   * `prisma.insurancePolicy`: Exposes CRUD operations for the **InsurancePolicy** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more InsurancePolicies
    * const insurancePolicies = await prisma.insurancePolicy.findMany()
    * ```
    */
  get insurancePolicy(): Prisma.InsurancePolicyDelegate<ExtArgs>;

  /**
   * `prisma.country`: Exposes CRUD operations for the **Country** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more Countries
    * const countries = await prisma.country.findMany()
    * ```
    */
  get country(): Prisma.CountryDelegate<ExtArgs>;

  /**
   * `prisma.analyticsSnapshot`: Exposes CRUD operations for the **AnalyticsSnapshot** model.
    * Example usage:
    * ```ts
    * // Fetch zero or more AnalyticsSnapshots
    * const analyticsSnapshots = await prisma.analyticsSnapshot.findMany()
    * ```
    */
  get analyticsSnapshot(): Prisma.AnalyticsSnapshotDelegate<ExtArgs>;
}

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
  export import NotFoundError = runtime.NotFoundError

  /**
   * 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: 5.22.0
   * Query Engine version: 605197351a3c8bdd595af2d2a9bc3025bca48ea2
   */
  export type PrismaVersion = {
    client: string
  }

  export const prismaVersion: PrismaVersion 

  /**
   * Utility Types
   */


  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 ? K : 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',
    Otp: 'Otp',
    Session: 'Session',
    Group: 'Group',
    GroupApplication: 'GroupApplication',
    Membership: 'Membership',
    Invite: 'Invite',
    MonthlyCycle: 'MonthlyCycle',
    Contribution: 'Contribution',
    Cashout: 'Cashout',
    Loan: 'Loan',
    CoverageDecision: 'CoverageDecision',
    Reintegration: 'Reintegration',
    FeeConfiguration: 'FeeConfiguration',
    CoverageFund: 'CoverageFund',
    Transaction: 'Transaction',
    ScoreEvent: 'ScoreEvent',
    Notification: 'Notification',
    AuditLog: 'AuditLog',
    SystemClock: 'SystemClock',
    CreditApplication: 'CreditApplication',
    CreditInstallment: 'CreditInstallment',
    SavingsAccount: 'SavingsAccount',
    SavingsMovement: 'SavingsMovement',
    Referral: 'Referral',
    ContentArticle: 'ContentArticle',
    Quiz: 'Quiz',
    QuizAttempt: 'QuizAttempt',
    Badge: 'Badge',
    ApiKey: 'ApiKey',
    ApiCall: 'ApiCall',
    InsuranceProduct: 'InsuranceProduct',
    InsurancePolicy: 'InsurancePolicy',
    Country: 'Country',
    AnalyticsSnapshot: 'AnalyticsSnapshot'
  };

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


  export type Datasources = {
    db?: Datasource
  }

  interface TypeMapCb extends $Utils.Fn<{extArgs: $Extensions.InternalArgs, clientOptions: PrismaClientOptions }, $Utils.Record<string, any>> {
    returns: Prisma.TypeMap<this['params']['extArgs'], this['params']['clientOptions']>
  }

  export type TypeMap<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs, ClientOptions = {}> = {
    meta: {
      modelProps: "user" | "otp" | "session" | "group" | "groupApplication" | "membership" | "invite" | "monthlyCycle" | "contribution" | "cashout" | "loan" | "coverageDecision" | "reintegration" | "feeConfiguration" | "coverageFund" | "transaction" | "scoreEvent" | "notification" | "auditLog" | "systemClock" | "creditApplication" | "creditInstallment" | "savingsAccount" | "savingsMovement" | "referral" | "contentArticle" | "quiz" | "quizAttempt" | "badge" | "apiKey" | "apiCall" | "insuranceProduct" | "insurancePolicy" | "country" | "analyticsSnapshot"
      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
          }
          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
          }
          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
          }
        }
      }
      Otp: {
        payload: Prisma.$OtpPayload<ExtArgs>
        fields: Prisma.OtpFieldRefs
        operations: {
          findUnique: {
            args: Prisma.OtpFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$OtpPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.OtpFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$OtpPayload>
          }
          findFirst: {
            args: Prisma.OtpFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$OtpPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.OtpFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$OtpPayload>
          }
          findMany: {
            args: Prisma.OtpFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$OtpPayload>[]
          }
          create: {
            args: Prisma.OtpCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$OtpPayload>
          }
          createMany: {
            args: Prisma.OtpCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          delete: {
            args: Prisma.OtpDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$OtpPayload>
          }
          update: {
            args: Prisma.OtpUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$OtpPayload>
          }
          deleteMany: {
            args: Prisma.OtpDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.OtpUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          upsert: {
            args: Prisma.OtpUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$OtpPayload>
          }
          aggregate: {
            args: Prisma.OtpAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateOtp>
          }
          groupBy: {
            args: Prisma.OtpGroupByArgs<ExtArgs>
            result: $Utils.Optional<OtpGroupByOutputType>[]
          }
          count: {
            args: Prisma.OtpCountArgs<ExtArgs>
            result: $Utils.Optional<OtpCountAggregateOutputType> | number
          }
        }
      }
      Session: {
        payload: Prisma.$SessionPayload<ExtArgs>
        fields: Prisma.SessionFieldRefs
        operations: {
          findUnique: {
            args: Prisma.SessionFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SessionPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.SessionFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SessionPayload>
          }
          findFirst: {
            args: Prisma.SessionFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SessionPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.SessionFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SessionPayload>
          }
          findMany: {
            args: Prisma.SessionFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SessionPayload>[]
          }
          create: {
            args: Prisma.SessionCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SessionPayload>
          }
          createMany: {
            args: Prisma.SessionCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          delete: {
            args: Prisma.SessionDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SessionPayload>
          }
          update: {
            args: Prisma.SessionUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SessionPayload>
          }
          deleteMany: {
            args: Prisma.SessionDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.SessionUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          upsert: {
            args: Prisma.SessionUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SessionPayload>
          }
          aggregate: {
            args: Prisma.SessionAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateSession>
          }
          groupBy: {
            args: Prisma.SessionGroupByArgs<ExtArgs>
            result: $Utils.Optional<SessionGroupByOutputType>[]
          }
          count: {
            args: Prisma.SessionCountArgs<ExtArgs>
            result: $Utils.Optional<SessionCountAggregateOutputType> | number
          }
        }
      }
      Group: {
        payload: Prisma.$GroupPayload<ExtArgs>
        fields: Prisma.GroupFieldRefs
        operations: {
          findUnique: {
            args: Prisma.GroupFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GroupPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.GroupFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GroupPayload>
          }
          findFirst: {
            args: Prisma.GroupFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GroupPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.GroupFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GroupPayload>
          }
          findMany: {
            args: Prisma.GroupFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GroupPayload>[]
          }
          create: {
            args: Prisma.GroupCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GroupPayload>
          }
          createMany: {
            args: Prisma.GroupCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          delete: {
            args: Prisma.GroupDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GroupPayload>
          }
          update: {
            args: Prisma.GroupUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GroupPayload>
          }
          deleteMany: {
            args: Prisma.GroupDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.GroupUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          upsert: {
            args: Prisma.GroupUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GroupPayload>
          }
          aggregate: {
            args: Prisma.GroupAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateGroup>
          }
          groupBy: {
            args: Prisma.GroupGroupByArgs<ExtArgs>
            result: $Utils.Optional<GroupGroupByOutputType>[]
          }
          count: {
            args: Prisma.GroupCountArgs<ExtArgs>
            result: $Utils.Optional<GroupCountAggregateOutputType> | number
          }
        }
      }
      GroupApplication: {
        payload: Prisma.$GroupApplicationPayload<ExtArgs>
        fields: Prisma.GroupApplicationFieldRefs
        operations: {
          findUnique: {
            args: Prisma.GroupApplicationFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GroupApplicationPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.GroupApplicationFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GroupApplicationPayload>
          }
          findFirst: {
            args: Prisma.GroupApplicationFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GroupApplicationPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.GroupApplicationFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GroupApplicationPayload>
          }
          findMany: {
            args: Prisma.GroupApplicationFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GroupApplicationPayload>[]
          }
          create: {
            args: Prisma.GroupApplicationCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GroupApplicationPayload>
          }
          createMany: {
            args: Prisma.GroupApplicationCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          delete: {
            args: Prisma.GroupApplicationDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GroupApplicationPayload>
          }
          update: {
            args: Prisma.GroupApplicationUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GroupApplicationPayload>
          }
          deleteMany: {
            args: Prisma.GroupApplicationDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.GroupApplicationUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          upsert: {
            args: Prisma.GroupApplicationUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$GroupApplicationPayload>
          }
          aggregate: {
            args: Prisma.GroupApplicationAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateGroupApplication>
          }
          groupBy: {
            args: Prisma.GroupApplicationGroupByArgs<ExtArgs>
            result: $Utils.Optional<GroupApplicationGroupByOutputType>[]
          }
          count: {
            args: Prisma.GroupApplicationCountArgs<ExtArgs>
            result: $Utils.Optional<GroupApplicationCountAggregateOutputType> | number
          }
        }
      }
      Membership: {
        payload: Prisma.$MembershipPayload<ExtArgs>
        fields: Prisma.MembershipFieldRefs
        operations: {
          findUnique: {
            args: Prisma.MembershipFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$MembershipPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.MembershipFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$MembershipPayload>
          }
          findFirst: {
            args: Prisma.MembershipFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$MembershipPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.MembershipFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$MembershipPayload>
          }
          findMany: {
            args: Prisma.MembershipFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$MembershipPayload>[]
          }
          create: {
            args: Prisma.MembershipCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$MembershipPayload>
          }
          createMany: {
            args: Prisma.MembershipCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          delete: {
            args: Prisma.MembershipDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$MembershipPayload>
          }
          update: {
            args: Prisma.MembershipUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$MembershipPayload>
          }
          deleteMany: {
            args: Prisma.MembershipDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.MembershipUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          upsert: {
            args: Prisma.MembershipUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$MembershipPayload>
          }
          aggregate: {
            args: Prisma.MembershipAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateMembership>
          }
          groupBy: {
            args: Prisma.MembershipGroupByArgs<ExtArgs>
            result: $Utils.Optional<MembershipGroupByOutputType>[]
          }
          count: {
            args: Prisma.MembershipCountArgs<ExtArgs>
            result: $Utils.Optional<MembershipCountAggregateOutputType> | number
          }
        }
      }
      Invite: {
        payload: Prisma.$InvitePayload<ExtArgs>
        fields: Prisma.InviteFieldRefs
        operations: {
          findUnique: {
            args: Prisma.InviteFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$InvitePayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.InviteFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$InvitePayload>
          }
          findFirst: {
            args: Prisma.InviteFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$InvitePayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.InviteFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$InvitePayload>
          }
          findMany: {
            args: Prisma.InviteFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$InvitePayload>[]
          }
          create: {
            args: Prisma.InviteCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$InvitePayload>
          }
          createMany: {
            args: Prisma.InviteCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          delete: {
            args: Prisma.InviteDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$InvitePayload>
          }
          update: {
            args: Prisma.InviteUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$InvitePayload>
          }
          deleteMany: {
            args: Prisma.InviteDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.InviteUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          upsert: {
            args: Prisma.InviteUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$InvitePayload>
          }
          aggregate: {
            args: Prisma.InviteAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateInvite>
          }
          groupBy: {
            args: Prisma.InviteGroupByArgs<ExtArgs>
            result: $Utils.Optional<InviteGroupByOutputType>[]
          }
          count: {
            args: Prisma.InviteCountArgs<ExtArgs>
            result: $Utils.Optional<InviteCountAggregateOutputType> | number
          }
        }
      }
      MonthlyCycle: {
        payload: Prisma.$MonthlyCyclePayload<ExtArgs>
        fields: Prisma.MonthlyCycleFieldRefs
        operations: {
          findUnique: {
            args: Prisma.MonthlyCycleFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$MonthlyCyclePayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.MonthlyCycleFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$MonthlyCyclePayload>
          }
          findFirst: {
            args: Prisma.MonthlyCycleFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$MonthlyCyclePayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.MonthlyCycleFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$MonthlyCyclePayload>
          }
          findMany: {
            args: Prisma.MonthlyCycleFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$MonthlyCyclePayload>[]
          }
          create: {
            args: Prisma.MonthlyCycleCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$MonthlyCyclePayload>
          }
          createMany: {
            args: Prisma.MonthlyCycleCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          delete: {
            args: Prisma.MonthlyCycleDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$MonthlyCyclePayload>
          }
          update: {
            args: Prisma.MonthlyCycleUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$MonthlyCyclePayload>
          }
          deleteMany: {
            args: Prisma.MonthlyCycleDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.MonthlyCycleUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          upsert: {
            args: Prisma.MonthlyCycleUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$MonthlyCyclePayload>
          }
          aggregate: {
            args: Prisma.MonthlyCycleAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateMonthlyCycle>
          }
          groupBy: {
            args: Prisma.MonthlyCycleGroupByArgs<ExtArgs>
            result: $Utils.Optional<MonthlyCycleGroupByOutputType>[]
          }
          count: {
            args: Prisma.MonthlyCycleCountArgs<ExtArgs>
            result: $Utils.Optional<MonthlyCycleCountAggregateOutputType> | number
          }
        }
      }
      Contribution: {
        payload: Prisma.$ContributionPayload<ExtArgs>
        fields: Prisma.ContributionFieldRefs
        operations: {
          findUnique: {
            args: Prisma.ContributionFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ContributionPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.ContributionFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ContributionPayload>
          }
          findFirst: {
            args: Prisma.ContributionFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ContributionPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.ContributionFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ContributionPayload>
          }
          findMany: {
            args: Prisma.ContributionFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ContributionPayload>[]
          }
          create: {
            args: Prisma.ContributionCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ContributionPayload>
          }
          createMany: {
            args: Prisma.ContributionCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          delete: {
            args: Prisma.ContributionDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ContributionPayload>
          }
          update: {
            args: Prisma.ContributionUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ContributionPayload>
          }
          deleteMany: {
            args: Prisma.ContributionDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.ContributionUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          upsert: {
            args: Prisma.ContributionUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ContributionPayload>
          }
          aggregate: {
            args: Prisma.ContributionAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateContribution>
          }
          groupBy: {
            args: Prisma.ContributionGroupByArgs<ExtArgs>
            result: $Utils.Optional<ContributionGroupByOutputType>[]
          }
          count: {
            args: Prisma.ContributionCountArgs<ExtArgs>
            result: $Utils.Optional<ContributionCountAggregateOutputType> | number
          }
        }
      }
      Cashout: {
        payload: Prisma.$CashoutPayload<ExtArgs>
        fields: Prisma.CashoutFieldRefs
        operations: {
          findUnique: {
            args: Prisma.CashoutFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CashoutPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.CashoutFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CashoutPayload>
          }
          findFirst: {
            args: Prisma.CashoutFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CashoutPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.CashoutFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CashoutPayload>
          }
          findMany: {
            args: Prisma.CashoutFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CashoutPayload>[]
          }
          create: {
            args: Prisma.CashoutCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CashoutPayload>
          }
          createMany: {
            args: Prisma.CashoutCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          delete: {
            args: Prisma.CashoutDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CashoutPayload>
          }
          update: {
            args: Prisma.CashoutUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CashoutPayload>
          }
          deleteMany: {
            args: Prisma.CashoutDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.CashoutUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          upsert: {
            args: Prisma.CashoutUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CashoutPayload>
          }
          aggregate: {
            args: Prisma.CashoutAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateCashout>
          }
          groupBy: {
            args: Prisma.CashoutGroupByArgs<ExtArgs>
            result: $Utils.Optional<CashoutGroupByOutputType>[]
          }
          count: {
            args: Prisma.CashoutCountArgs<ExtArgs>
            result: $Utils.Optional<CashoutCountAggregateOutputType> | number
          }
        }
      }
      Loan: {
        payload: Prisma.$LoanPayload<ExtArgs>
        fields: Prisma.LoanFieldRefs
        operations: {
          findUnique: {
            args: Prisma.LoanFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$LoanPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.LoanFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$LoanPayload>
          }
          findFirst: {
            args: Prisma.LoanFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$LoanPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.LoanFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$LoanPayload>
          }
          findMany: {
            args: Prisma.LoanFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$LoanPayload>[]
          }
          create: {
            args: Prisma.LoanCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$LoanPayload>
          }
          createMany: {
            args: Prisma.LoanCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          delete: {
            args: Prisma.LoanDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$LoanPayload>
          }
          update: {
            args: Prisma.LoanUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$LoanPayload>
          }
          deleteMany: {
            args: Prisma.LoanDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.LoanUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          upsert: {
            args: Prisma.LoanUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$LoanPayload>
          }
          aggregate: {
            args: Prisma.LoanAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateLoan>
          }
          groupBy: {
            args: Prisma.LoanGroupByArgs<ExtArgs>
            result: $Utils.Optional<LoanGroupByOutputType>[]
          }
          count: {
            args: Prisma.LoanCountArgs<ExtArgs>
            result: $Utils.Optional<LoanCountAggregateOutputType> | number
          }
        }
      }
      CoverageDecision: {
        payload: Prisma.$CoverageDecisionPayload<ExtArgs>
        fields: Prisma.CoverageDecisionFieldRefs
        operations: {
          findUnique: {
            args: Prisma.CoverageDecisionFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CoverageDecisionPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.CoverageDecisionFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CoverageDecisionPayload>
          }
          findFirst: {
            args: Prisma.CoverageDecisionFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CoverageDecisionPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.CoverageDecisionFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CoverageDecisionPayload>
          }
          findMany: {
            args: Prisma.CoverageDecisionFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CoverageDecisionPayload>[]
          }
          create: {
            args: Prisma.CoverageDecisionCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CoverageDecisionPayload>
          }
          createMany: {
            args: Prisma.CoverageDecisionCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          delete: {
            args: Prisma.CoverageDecisionDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CoverageDecisionPayload>
          }
          update: {
            args: Prisma.CoverageDecisionUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CoverageDecisionPayload>
          }
          deleteMany: {
            args: Prisma.CoverageDecisionDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.CoverageDecisionUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          upsert: {
            args: Prisma.CoverageDecisionUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CoverageDecisionPayload>
          }
          aggregate: {
            args: Prisma.CoverageDecisionAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateCoverageDecision>
          }
          groupBy: {
            args: Prisma.CoverageDecisionGroupByArgs<ExtArgs>
            result: $Utils.Optional<CoverageDecisionGroupByOutputType>[]
          }
          count: {
            args: Prisma.CoverageDecisionCountArgs<ExtArgs>
            result: $Utils.Optional<CoverageDecisionCountAggregateOutputType> | number
          }
        }
      }
      Reintegration: {
        payload: Prisma.$ReintegrationPayload<ExtArgs>
        fields: Prisma.ReintegrationFieldRefs
        operations: {
          findUnique: {
            args: Prisma.ReintegrationFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ReintegrationPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.ReintegrationFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ReintegrationPayload>
          }
          findFirst: {
            args: Prisma.ReintegrationFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ReintegrationPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.ReintegrationFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ReintegrationPayload>
          }
          findMany: {
            args: Prisma.ReintegrationFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ReintegrationPayload>[]
          }
          create: {
            args: Prisma.ReintegrationCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ReintegrationPayload>
          }
          createMany: {
            args: Prisma.ReintegrationCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          delete: {
            args: Prisma.ReintegrationDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ReintegrationPayload>
          }
          update: {
            args: Prisma.ReintegrationUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ReintegrationPayload>
          }
          deleteMany: {
            args: Prisma.ReintegrationDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.ReintegrationUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          upsert: {
            args: Prisma.ReintegrationUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ReintegrationPayload>
          }
          aggregate: {
            args: Prisma.ReintegrationAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateReintegration>
          }
          groupBy: {
            args: Prisma.ReintegrationGroupByArgs<ExtArgs>
            result: $Utils.Optional<ReintegrationGroupByOutputType>[]
          }
          count: {
            args: Prisma.ReintegrationCountArgs<ExtArgs>
            result: $Utils.Optional<ReintegrationCountAggregateOutputType> | number
          }
        }
      }
      FeeConfiguration: {
        payload: Prisma.$FeeConfigurationPayload<ExtArgs>
        fields: Prisma.FeeConfigurationFieldRefs
        operations: {
          findUnique: {
            args: Prisma.FeeConfigurationFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$FeeConfigurationPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.FeeConfigurationFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$FeeConfigurationPayload>
          }
          findFirst: {
            args: Prisma.FeeConfigurationFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$FeeConfigurationPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.FeeConfigurationFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$FeeConfigurationPayload>
          }
          findMany: {
            args: Prisma.FeeConfigurationFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$FeeConfigurationPayload>[]
          }
          create: {
            args: Prisma.FeeConfigurationCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$FeeConfigurationPayload>
          }
          createMany: {
            args: Prisma.FeeConfigurationCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          delete: {
            args: Prisma.FeeConfigurationDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$FeeConfigurationPayload>
          }
          update: {
            args: Prisma.FeeConfigurationUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$FeeConfigurationPayload>
          }
          deleteMany: {
            args: Prisma.FeeConfigurationDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.FeeConfigurationUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          upsert: {
            args: Prisma.FeeConfigurationUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$FeeConfigurationPayload>
          }
          aggregate: {
            args: Prisma.FeeConfigurationAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateFeeConfiguration>
          }
          groupBy: {
            args: Prisma.FeeConfigurationGroupByArgs<ExtArgs>
            result: $Utils.Optional<FeeConfigurationGroupByOutputType>[]
          }
          count: {
            args: Prisma.FeeConfigurationCountArgs<ExtArgs>
            result: $Utils.Optional<FeeConfigurationCountAggregateOutputType> | number
          }
        }
      }
      CoverageFund: {
        payload: Prisma.$CoverageFundPayload<ExtArgs>
        fields: Prisma.CoverageFundFieldRefs
        operations: {
          findUnique: {
            args: Prisma.CoverageFundFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CoverageFundPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.CoverageFundFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CoverageFundPayload>
          }
          findFirst: {
            args: Prisma.CoverageFundFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CoverageFundPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.CoverageFundFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CoverageFundPayload>
          }
          findMany: {
            args: Prisma.CoverageFundFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CoverageFundPayload>[]
          }
          create: {
            args: Prisma.CoverageFundCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CoverageFundPayload>
          }
          createMany: {
            args: Prisma.CoverageFundCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          delete: {
            args: Prisma.CoverageFundDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CoverageFundPayload>
          }
          update: {
            args: Prisma.CoverageFundUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CoverageFundPayload>
          }
          deleteMany: {
            args: Prisma.CoverageFundDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.CoverageFundUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          upsert: {
            args: Prisma.CoverageFundUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CoverageFundPayload>
          }
          aggregate: {
            args: Prisma.CoverageFundAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateCoverageFund>
          }
          groupBy: {
            args: Prisma.CoverageFundGroupByArgs<ExtArgs>
            result: $Utils.Optional<CoverageFundGroupByOutputType>[]
          }
          count: {
            args: Prisma.CoverageFundCountArgs<ExtArgs>
            result: $Utils.Optional<CoverageFundCountAggregateOutputType> | number
          }
        }
      }
      Transaction: {
        payload: Prisma.$TransactionPayload<ExtArgs>
        fields: Prisma.TransactionFieldRefs
        operations: {
          findUnique: {
            args: Prisma.TransactionFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$TransactionPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.TransactionFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$TransactionPayload>
          }
          findFirst: {
            args: Prisma.TransactionFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$TransactionPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.TransactionFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$TransactionPayload>
          }
          findMany: {
            args: Prisma.TransactionFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$TransactionPayload>[]
          }
          create: {
            args: Prisma.TransactionCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$TransactionPayload>
          }
          createMany: {
            args: Prisma.TransactionCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          delete: {
            args: Prisma.TransactionDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$TransactionPayload>
          }
          update: {
            args: Prisma.TransactionUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$TransactionPayload>
          }
          deleteMany: {
            args: Prisma.TransactionDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.TransactionUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          upsert: {
            args: Prisma.TransactionUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$TransactionPayload>
          }
          aggregate: {
            args: Prisma.TransactionAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateTransaction>
          }
          groupBy: {
            args: Prisma.TransactionGroupByArgs<ExtArgs>
            result: $Utils.Optional<TransactionGroupByOutputType>[]
          }
          count: {
            args: Prisma.TransactionCountArgs<ExtArgs>
            result: $Utils.Optional<TransactionCountAggregateOutputType> | number
          }
        }
      }
      ScoreEvent: {
        payload: Prisma.$ScoreEventPayload<ExtArgs>
        fields: Prisma.ScoreEventFieldRefs
        operations: {
          findUnique: {
            args: Prisma.ScoreEventFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ScoreEventPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.ScoreEventFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ScoreEventPayload>
          }
          findFirst: {
            args: Prisma.ScoreEventFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ScoreEventPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.ScoreEventFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ScoreEventPayload>
          }
          findMany: {
            args: Prisma.ScoreEventFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ScoreEventPayload>[]
          }
          create: {
            args: Prisma.ScoreEventCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ScoreEventPayload>
          }
          createMany: {
            args: Prisma.ScoreEventCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          delete: {
            args: Prisma.ScoreEventDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ScoreEventPayload>
          }
          update: {
            args: Prisma.ScoreEventUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ScoreEventPayload>
          }
          deleteMany: {
            args: Prisma.ScoreEventDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.ScoreEventUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          upsert: {
            args: Prisma.ScoreEventUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ScoreEventPayload>
          }
          aggregate: {
            args: Prisma.ScoreEventAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateScoreEvent>
          }
          groupBy: {
            args: Prisma.ScoreEventGroupByArgs<ExtArgs>
            result: $Utils.Optional<ScoreEventGroupByOutputType>[]
          }
          count: {
            args: Prisma.ScoreEventCountArgs<ExtArgs>
            result: $Utils.Optional<ScoreEventCountAggregateOutputType> | 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
          }
          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
          }
          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
          }
        }
      }
      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
          }
          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
          }
          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
          }
        }
      }
      SystemClock: {
        payload: Prisma.$SystemClockPayload<ExtArgs>
        fields: Prisma.SystemClockFieldRefs
        operations: {
          findUnique: {
            args: Prisma.SystemClockFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SystemClockPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.SystemClockFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SystemClockPayload>
          }
          findFirst: {
            args: Prisma.SystemClockFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SystemClockPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.SystemClockFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SystemClockPayload>
          }
          findMany: {
            args: Prisma.SystemClockFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SystemClockPayload>[]
          }
          create: {
            args: Prisma.SystemClockCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SystemClockPayload>
          }
          createMany: {
            args: Prisma.SystemClockCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          delete: {
            args: Prisma.SystemClockDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SystemClockPayload>
          }
          update: {
            args: Prisma.SystemClockUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SystemClockPayload>
          }
          deleteMany: {
            args: Prisma.SystemClockDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.SystemClockUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          upsert: {
            args: Prisma.SystemClockUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SystemClockPayload>
          }
          aggregate: {
            args: Prisma.SystemClockAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateSystemClock>
          }
          groupBy: {
            args: Prisma.SystemClockGroupByArgs<ExtArgs>
            result: $Utils.Optional<SystemClockGroupByOutputType>[]
          }
          count: {
            args: Prisma.SystemClockCountArgs<ExtArgs>
            result: $Utils.Optional<SystemClockCountAggregateOutputType> | number
          }
        }
      }
      CreditApplication: {
        payload: Prisma.$CreditApplicationPayload<ExtArgs>
        fields: Prisma.CreditApplicationFieldRefs
        operations: {
          findUnique: {
            args: Prisma.CreditApplicationFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CreditApplicationPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.CreditApplicationFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CreditApplicationPayload>
          }
          findFirst: {
            args: Prisma.CreditApplicationFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CreditApplicationPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.CreditApplicationFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CreditApplicationPayload>
          }
          findMany: {
            args: Prisma.CreditApplicationFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CreditApplicationPayload>[]
          }
          create: {
            args: Prisma.CreditApplicationCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CreditApplicationPayload>
          }
          createMany: {
            args: Prisma.CreditApplicationCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          delete: {
            args: Prisma.CreditApplicationDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CreditApplicationPayload>
          }
          update: {
            args: Prisma.CreditApplicationUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CreditApplicationPayload>
          }
          deleteMany: {
            args: Prisma.CreditApplicationDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.CreditApplicationUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          upsert: {
            args: Prisma.CreditApplicationUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CreditApplicationPayload>
          }
          aggregate: {
            args: Prisma.CreditApplicationAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateCreditApplication>
          }
          groupBy: {
            args: Prisma.CreditApplicationGroupByArgs<ExtArgs>
            result: $Utils.Optional<CreditApplicationGroupByOutputType>[]
          }
          count: {
            args: Prisma.CreditApplicationCountArgs<ExtArgs>
            result: $Utils.Optional<CreditApplicationCountAggregateOutputType> | number
          }
        }
      }
      CreditInstallment: {
        payload: Prisma.$CreditInstallmentPayload<ExtArgs>
        fields: Prisma.CreditInstallmentFieldRefs
        operations: {
          findUnique: {
            args: Prisma.CreditInstallmentFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CreditInstallmentPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.CreditInstallmentFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CreditInstallmentPayload>
          }
          findFirst: {
            args: Prisma.CreditInstallmentFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CreditInstallmentPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.CreditInstallmentFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CreditInstallmentPayload>
          }
          findMany: {
            args: Prisma.CreditInstallmentFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CreditInstallmentPayload>[]
          }
          create: {
            args: Prisma.CreditInstallmentCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CreditInstallmentPayload>
          }
          createMany: {
            args: Prisma.CreditInstallmentCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          delete: {
            args: Prisma.CreditInstallmentDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CreditInstallmentPayload>
          }
          update: {
            args: Prisma.CreditInstallmentUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CreditInstallmentPayload>
          }
          deleteMany: {
            args: Prisma.CreditInstallmentDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.CreditInstallmentUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          upsert: {
            args: Prisma.CreditInstallmentUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CreditInstallmentPayload>
          }
          aggregate: {
            args: Prisma.CreditInstallmentAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateCreditInstallment>
          }
          groupBy: {
            args: Prisma.CreditInstallmentGroupByArgs<ExtArgs>
            result: $Utils.Optional<CreditInstallmentGroupByOutputType>[]
          }
          count: {
            args: Prisma.CreditInstallmentCountArgs<ExtArgs>
            result: $Utils.Optional<CreditInstallmentCountAggregateOutputType> | number
          }
        }
      }
      SavingsAccount: {
        payload: Prisma.$SavingsAccountPayload<ExtArgs>
        fields: Prisma.SavingsAccountFieldRefs
        operations: {
          findUnique: {
            args: Prisma.SavingsAccountFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SavingsAccountPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.SavingsAccountFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SavingsAccountPayload>
          }
          findFirst: {
            args: Prisma.SavingsAccountFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SavingsAccountPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.SavingsAccountFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SavingsAccountPayload>
          }
          findMany: {
            args: Prisma.SavingsAccountFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SavingsAccountPayload>[]
          }
          create: {
            args: Prisma.SavingsAccountCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SavingsAccountPayload>
          }
          createMany: {
            args: Prisma.SavingsAccountCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          delete: {
            args: Prisma.SavingsAccountDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SavingsAccountPayload>
          }
          update: {
            args: Prisma.SavingsAccountUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SavingsAccountPayload>
          }
          deleteMany: {
            args: Prisma.SavingsAccountDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.SavingsAccountUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          upsert: {
            args: Prisma.SavingsAccountUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SavingsAccountPayload>
          }
          aggregate: {
            args: Prisma.SavingsAccountAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateSavingsAccount>
          }
          groupBy: {
            args: Prisma.SavingsAccountGroupByArgs<ExtArgs>
            result: $Utils.Optional<SavingsAccountGroupByOutputType>[]
          }
          count: {
            args: Prisma.SavingsAccountCountArgs<ExtArgs>
            result: $Utils.Optional<SavingsAccountCountAggregateOutputType> | number
          }
        }
      }
      SavingsMovement: {
        payload: Prisma.$SavingsMovementPayload<ExtArgs>
        fields: Prisma.SavingsMovementFieldRefs
        operations: {
          findUnique: {
            args: Prisma.SavingsMovementFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SavingsMovementPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.SavingsMovementFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SavingsMovementPayload>
          }
          findFirst: {
            args: Prisma.SavingsMovementFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SavingsMovementPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.SavingsMovementFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SavingsMovementPayload>
          }
          findMany: {
            args: Prisma.SavingsMovementFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SavingsMovementPayload>[]
          }
          create: {
            args: Prisma.SavingsMovementCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SavingsMovementPayload>
          }
          createMany: {
            args: Prisma.SavingsMovementCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          delete: {
            args: Prisma.SavingsMovementDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SavingsMovementPayload>
          }
          update: {
            args: Prisma.SavingsMovementUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SavingsMovementPayload>
          }
          deleteMany: {
            args: Prisma.SavingsMovementDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.SavingsMovementUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          upsert: {
            args: Prisma.SavingsMovementUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$SavingsMovementPayload>
          }
          aggregate: {
            args: Prisma.SavingsMovementAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateSavingsMovement>
          }
          groupBy: {
            args: Prisma.SavingsMovementGroupByArgs<ExtArgs>
            result: $Utils.Optional<SavingsMovementGroupByOutputType>[]
          }
          count: {
            args: Prisma.SavingsMovementCountArgs<ExtArgs>
            result: $Utils.Optional<SavingsMovementCountAggregateOutputType> | number
          }
        }
      }
      Referral: {
        payload: Prisma.$ReferralPayload<ExtArgs>
        fields: Prisma.ReferralFieldRefs
        operations: {
          findUnique: {
            args: Prisma.ReferralFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ReferralPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.ReferralFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ReferralPayload>
          }
          findFirst: {
            args: Prisma.ReferralFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ReferralPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.ReferralFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ReferralPayload>
          }
          findMany: {
            args: Prisma.ReferralFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ReferralPayload>[]
          }
          create: {
            args: Prisma.ReferralCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ReferralPayload>
          }
          createMany: {
            args: Prisma.ReferralCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          delete: {
            args: Prisma.ReferralDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ReferralPayload>
          }
          update: {
            args: Prisma.ReferralUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ReferralPayload>
          }
          deleteMany: {
            args: Prisma.ReferralDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.ReferralUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          upsert: {
            args: Prisma.ReferralUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ReferralPayload>
          }
          aggregate: {
            args: Prisma.ReferralAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateReferral>
          }
          groupBy: {
            args: Prisma.ReferralGroupByArgs<ExtArgs>
            result: $Utils.Optional<ReferralGroupByOutputType>[]
          }
          count: {
            args: Prisma.ReferralCountArgs<ExtArgs>
            result: $Utils.Optional<ReferralCountAggregateOutputType> | number
          }
        }
      }
      ContentArticle: {
        payload: Prisma.$ContentArticlePayload<ExtArgs>
        fields: Prisma.ContentArticleFieldRefs
        operations: {
          findUnique: {
            args: Prisma.ContentArticleFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ContentArticlePayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.ContentArticleFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ContentArticlePayload>
          }
          findFirst: {
            args: Prisma.ContentArticleFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ContentArticlePayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.ContentArticleFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ContentArticlePayload>
          }
          findMany: {
            args: Prisma.ContentArticleFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ContentArticlePayload>[]
          }
          create: {
            args: Prisma.ContentArticleCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ContentArticlePayload>
          }
          createMany: {
            args: Prisma.ContentArticleCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          delete: {
            args: Prisma.ContentArticleDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ContentArticlePayload>
          }
          update: {
            args: Prisma.ContentArticleUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ContentArticlePayload>
          }
          deleteMany: {
            args: Prisma.ContentArticleDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.ContentArticleUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          upsert: {
            args: Prisma.ContentArticleUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ContentArticlePayload>
          }
          aggregate: {
            args: Prisma.ContentArticleAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateContentArticle>
          }
          groupBy: {
            args: Prisma.ContentArticleGroupByArgs<ExtArgs>
            result: $Utils.Optional<ContentArticleGroupByOutputType>[]
          }
          count: {
            args: Prisma.ContentArticleCountArgs<ExtArgs>
            result: $Utils.Optional<ContentArticleCountAggregateOutputType> | number
          }
        }
      }
      Quiz: {
        payload: Prisma.$QuizPayload<ExtArgs>
        fields: Prisma.QuizFieldRefs
        operations: {
          findUnique: {
            args: Prisma.QuizFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$QuizPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.QuizFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$QuizPayload>
          }
          findFirst: {
            args: Prisma.QuizFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$QuizPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.QuizFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$QuizPayload>
          }
          findMany: {
            args: Prisma.QuizFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$QuizPayload>[]
          }
          create: {
            args: Prisma.QuizCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$QuizPayload>
          }
          createMany: {
            args: Prisma.QuizCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          delete: {
            args: Prisma.QuizDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$QuizPayload>
          }
          update: {
            args: Prisma.QuizUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$QuizPayload>
          }
          deleteMany: {
            args: Prisma.QuizDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.QuizUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          upsert: {
            args: Prisma.QuizUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$QuizPayload>
          }
          aggregate: {
            args: Prisma.QuizAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateQuiz>
          }
          groupBy: {
            args: Prisma.QuizGroupByArgs<ExtArgs>
            result: $Utils.Optional<QuizGroupByOutputType>[]
          }
          count: {
            args: Prisma.QuizCountArgs<ExtArgs>
            result: $Utils.Optional<QuizCountAggregateOutputType> | number
          }
        }
      }
      QuizAttempt: {
        payload: Prisma.$QuizAttemptPayload<ExtArgs>
        fields: Prisma.QuizAttemptFieldRefs
        operations: {
          findUnique: {
            args: Prisma.QuizAttemptFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$QuizAttemptPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.QuizAttemptFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$QuizAttemptPayload>
          }
          findFirst: {
            args: Prisma.QuizAttemptFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$QuizAttemptPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.QuizAttemptFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$QuizAttemptPayload>
          }
          findMany: {
            args: Prisma.QuizAttemptFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$QuizAttemptPayload>[]
          }
          create: {
            args: Prisma.QuizAttemptCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$QuizAttemptPayload>
          }
          createMany: {
            args: Prisma.QuizAttemptCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          delete: {
            args: Prisma.QuizAttemptDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$QuizAttemptPayload>
          }
          update: {
            args: Prisma.QuizAttemptUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$QuizAttemptPayload>
          }
          deleteMany: {
            args: Prisma.QuizAttemptDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.QuizAttemptUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          upsert: {
            args: Prisma.QuizAttemptUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$QuizAttemptPayload>
          }
          aggregate: {
            args: Prisma.QuizAttemptAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateQuizAttempt>
          }
          groupBy: {
            args: Prisma.QuizAttemptGroupByArgs<ExtArgs>
            result: $Utils.Optional<QuizAttemptGroupByOutputType>[]
          }
          count: {
            args: Prisma.QuizAttemptCountArgs<ExtArgs>
            result: $Utils.Optional<QuizAttemptCountAggregateOutputType> | number
          }
        }
      }
      Badge: {
        payload: Prisma.$BadgePayload<ExtArgs>
        fields: Prisma.BadgeFieldRefs
        operations: {
          findUnique: {
            args: Prisma.BadgeFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$BadgePayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.BadgeFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$BadgePayload>
          }
          findFirst: {
            args: Prisma.BadgeFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$BadgePayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.BadgeFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$BadgePayload>
          }
          findMany: {
            args: Prisma.BadgeFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$BadgePayload>[]
          }
          create: {
            args: Prisma.BadgeCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$BadgePayload>
          }
          createMany: {
            args: Prisma.BadgeCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          delete: {
            args: Prisma.BadgeDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$BadgePayload>
          }
          update: {
            args: Prisma.BadgeUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$BadgePayload>
          }
          deleteMany: {
            args: Prisma.BadgeDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.BadgeUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          upsert: {
            args: Prisma.BadgeUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$BadgePayload>
          }
          aggregate: {
            args: Prisma.BadgeAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateBadge>
          }
          groupBy: {
            args: Prisma.BadgeGroupByArgs<ExtArgs>
            result: $Utils.Optional<BadgeGroupByOutputType>[]
          }
          count: {
            args: Prisma.BadgeCountArgs<ExtArgs>
            result: $Utils.Optional<BadgeCountAggregateOutputType> | number
          }
        }
      }
      ApiKey: {
        payload: Prisma.$ApiKeyPayload<ExtArgs>
        fields: Prisma.ApiKeyFieldRefs
        operations: {
          findUnique: {
            args: Prisma.ApiKeyFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ApiKeyPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.ApiKeyFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ApiKeyPayload>
          }
          findFirst: {
            args: Prisma.ApiKeyFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ApiKeyPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.ApiKeyFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ApiKeyPayload>
          }
          findMany: {
            args: Prisma.ApiKeyFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ApiKeyPayload>[]
          }
          create: {
            args: Prisma.ApiKeyCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ApiKeyPayload>
          }
          createMany: {
            args: Prisma.ApiKeyCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          delete: {
            args: Prisma.ApiKeyDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ApiKeyPayload>
          }
          update: {
            args: Prisma.ApiKeyUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ApiKeyPayload>
          }
          deleteMany: {
            args: Prisma.ApiKeyDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.ApiKeyUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          upsert: {
            args: Prisma.ApiKeyUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ApiKeyPayload>
          }
          aggregate: {
            args: Prisma.ApiKeyAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateApiKey>
          }
          groupBy: {
            args: Prisma.ApiKeyGroupByArgs<ExtArgs>
            result: $Utils.Optional<ApiKeyGroupByOutputType>[]
          }
          count: {
            args: Prisma.ApiKeyCountArgs<ExtArgs>
            result: $Utils.Optional<ApiKeyCountAggregateOutputType> | number
          }
        }
      }
      ApiCall: {
        payload: Prisma.$ApiCallPayload<ExtArgs>
        fields: Prisma.ApiCallFieldRefs
        operations: {
          findUnique: {
            args: Prisma.ApiCallFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ApiCallPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.ApiCallFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ApiCallPayload>
          }
          findFirst: {
            args: Prisma.ApiCallFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ApiCallPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.ApiCallFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ApiCallPayload>
          }
          findMany: {
            args: Prisma.ApiCallFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ApiCallPayload>[]
          }
          create: {
            args: Prisma.ApiCallCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ApiCallPayload>
          }
          createMany: {
            args: Prisma.ApiCallCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          delete: {
            args: Prisma.ApiCallDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ApiCallPayload>
          }
          update: {
            args: Prisma.ApiCallUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ApiCallPayload>
          }
          deleteMany: {
            args: Prisma.ApiCallDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.ApiCallUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          upsert: {
            args: Prisma.ApiCallUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$ApiCallPayload>
          }
          aggregate: {
            args: Prisma.ApiCallAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateApiCall>
          }
          groupBy: {
            args: Prisma.ApiCallGroupByArgs<ExtArgs>
            result: $Utils.Optional<ApiCallGroupByOutputType>[]
          }
          count: {
            args: Prisma.ApiCallCountArgs<ExtArgs>
            result: $Utils.Optional<ApiCallCountAggregateOutputType> | number
          }
        }
      }
      InsuranceProduct: {
        payload: Prisma.$InsuranceProductPayload<ExtArgs>
        fields: Prisma.InsuranceProductFieldRefs
        operations: {
          findUnique: {
            args: Prisma.InsuranceProductFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$InsuranceProductPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.InsuranceProductFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$InsuranceProductPayload>
          }
          findFirst: {
            args: Prisma.InsuranceProductFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$InsuranceProductPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.InsuranceProductFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$InsuranceProductPayload>
          }
          findMany: {
            args: Prisma.InsuranceProductFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$InsuranceProductPayload>[]
          }
          create: {
            args: Prisma.InsuranceProductCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$InsuranceProductPayload>
          }
          createMany: {
            args: Prisma.InsuranceProductCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          delete: {
            args: Prisma.InsuranceProductDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$InsuranceProductPayload>
          }
          update: {
            args: Prisma.InsuranceProductUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$InsuranceProductPayload>
          }
          deleteMany: {
            args: Prisma.InsuranceProductDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.InsuranceProductUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          upsert: {
            args: Prisma.InsuranceProductUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$InsuranceProductPayload>
          }
          aggregate: {
            args: Prisma.InsuranceProductAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateInsuranceProduct>
          }
          groupBy: {
            args: Prisma.InsuranceProductGroupByArgs<ExtArgs>
            result: $Utils.Optional<InsuranceProductGroupByOutputType>[]
          }
          count: {
            args: Prisma.InsuranceProductCountArgs<ExtArgs>
            result: $Utils.Optional<InsuranceProductCountAggregateOutputType> | number
          }
        }
      }
      InsurancePolicy: {
        payload: Prisma.$InsurancePolicyPayload<ExtArgs>
        fields: Prisma.InsurancePolicyFieldRefs
        operations: {
          findUnique: {
            args: Prisma.InsurancePolicyFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$InsurancePolicyPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.InsurancePolicyFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$InsurancePolicyPayload>
          }
          findFirst: {
            args: Prisma.InsurancePolicyFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$InsurancePolicyPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.InsurancePolicyFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$InsurancePolicyPayload>
          }
          findMany: {
            args: Prisma.InsurancePolicyFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$InsurancePolicyPayload>[]
          }
          create: {
            args: Prisma.InsurancePolicyCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$InsurancePolicyPayload>
          }
          createMany: {
            args: Prisma.InsurancePolicyCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          delete: {
            args: Prisma.InsurancePolicyDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$InsurancePolicyPayload>
          }
          update: {
            args: Prisma.InsurancePolicyUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$InsurancePolicyPayload>
          }
          deleteMany: {
            args: Prisma.InsurancePolicyDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.InsurancePolicyUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          upsert: {
            args: Prisma.InsurancePolicyUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$InsurancePolicyPayload>
          }
          aggregate: {
            args: Prisma.InsurancePolicyAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateInsurancePolicy>
          }
          groupBy: {
            args: Prisma.InsurancePolicyGroupByArgs<ExtArgs>
            result: $Utils.Optional<InsurancePolicyGroupByOutputType>[]
          }
          count: {
            args: Prisma.InsurancePolicyCountArgs<ExtArgs>
            result: $Utils.Optional<InsurancePolicyCountAggregateOutputType> | number
          }
        }
      }
      Country: {
        payload: Prisma.$CountryPayload<ExtArgs>
        fields: Prisma.CountryFieldRefs
        operations: {
          findUnique: {
            args: Prisma.CountryFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CountryPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.CountryFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CountryPayload>
          }
          findFirst: {
            args: Prisma.CountryFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CountryPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.CountryFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CountryPayload>
          }
          findMany: {
            args: Prisma.CountryFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CountryPayload>[]
          }
          create: {
            args: Prisma.CountryCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CountryPayload>
          }
          createMany: {
            args: Prisma.CountryCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          delete: {
            args: Prisma.CountryDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CountryPayload>
          }
          update: {
            args: Prisma.CountryUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CountryPayload>
          }
          deleteMany: {
            args: Prisma.CountryDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.CountryUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          upsert: {
            args: Prisma.CountryUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$CountryPayload>
          }
          aggregate: {
            args: Prisma.CountryAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateCountry>
          }
          groupBy: {
            args: Prisma.CountryGroupByArgs<ExtArgs>
            result: $Utils.Optional<CountryGroupByOutputType>[]
          }
          count: {
            args: Prisma.CountryCountArgs<ExtArgs>
            result: $Utils.Optional<CountryCountAggregateOutputType> | number
          }
        }
      }
      AnalyticsSnapshot: {
        payload: Prisma.$AnalyticsSnapshotPayload<ExtArgs>
        fields: Prisma.AnalyticsSnapshotFieldRefs
        operations: {
          findUnique: {
            args: Prisma.AnalyticsSnapshotFindUniqueArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$AnalyticsSnapshotPayload> | null
          }
          findUniqueOrThrow: {
            args: Prisma.AnalyticsSnapshotFindUniqueOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$AnalyticsSnapshotPayload>
          }
          findFirst: {
            args: Prisma.AnalyticsSnapshotFindFirstArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$AnalyticsSnapshotPayload> | null
          }
          findFirstOrThrow: {
            args: Prisma.AnalyticsSnapshotFindFirstOrThrowArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$AnalyticsSnapshotPayload>
          }
          findMany: {
            args: Prisma.AnalyticsSnapshotFindManyArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$AnalyticsSnapshotPayload>[]
          }
          create: {
            args: Prisma.AnalyticsSnapshotCreateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$AnalyticsSnapshotPayload>
          }
          createMany: {
            args: Prisma.AnalyticsSnapshotCreateManyArgs<ExtArgs>
            result: BatchPayload
          }
          delete: {
            args: Prisma.AnalyticsSnapshotDeleteArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$AnalyticsSnapshotPayload>
          }
          update: {
            args: Prisma.AnalyticsSnapshotUpdateArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$AnalyticsSnapshotPayload>
          }
          deleteMany: {
            args: Prisma.AnalyticsSnapshotDeleteManyArgs<ExtArgs>
            result: BatchPayload
          }
          updateMany: {
            args: Prisma.AnalyticsSnapshotUpdateManyArgs<ExtArgs>
            result: BatchPayload
          }
          upsert: {
            args: Prisma.AnalyticsSnapshotUpsertArgs<ExtArgs>
            result: $Utils.PayloadToResult<Prisma.$AnalyticsSnapshotPayload>
          }
          aggregate: {
            args: Prisma.AnalyticsSnapshotAggregateArgs<ExtArgs>
            result: $Utils.Optional<AggregateAnalyticsSnapshot>
          }
          groupBy: {
            args: Prisma.AnalyticsSnapshotGroupByArgs<ExtArgs>
            result: $Utils.Optional<AnalyticsSnapshotGroupByOutputType>[]
          }
          count: {
            args: Prisma.AnalyticsSnapshotCountArgs<ExtArgs>
            result: $Utils.Optional<AnalyticsSnapshotCountAggregateOutputType> | 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
     * ```
     * // Defaults to stdout
     * log: ['query', 'info', 'warn', 'error']
     * 
     * // Emit as events
     * log: [
     *   { 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
    }
  }


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

  export type GetLogType<T extends LogLevel | LogDefinition> = T extends LogDefinition ? T['emit'] extends 'event' ? T['level'] : never : never
  export type GetEvents<T extends any> = T extends Array<LogLevel | LogDefinition> ?
    GetLogType<T[0]> | GetLogType<T[1]> | GetLogType<T[2]> | GetLogType<T[3]>
    : 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'
    | 'upsert'
    | 'delete'
    | 'deleteMany'
    | 'executeRaw'
    | 'queryRaw'
    | 'aggregate'
    | 'count'
    | 'runCommandRaw'
    | 'findRaw'
    | 'groupBy'

  /**
   * These options are being passed into the middleware as "params"
   */
  export type MiddlewareParams = {
    model?: ModelName
    action: PrismaAction
    args: any
    dataPath: string[]
    runInTransaction: boolean
  }

  /**
   * The `T` type makes sure, that the `return proceed` is not forgotten in the middleware implementation
   */
  export type Middleware<T = any> = (
    params: MiddlewareParams,
    next: (params: MiddlewareParams) => $Utils.JsPromise<T>,
  ) => $Utils.JsPromise<T>

  // 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 = {
    referidos: number
    gruposCriados: number
    memberships: number
    contribuicoes: number
    cashouts: number
    loans: number
    scoreEvents: number
    reintegrations: number
    otps: number
    sessions: number
    notifications: number
    coverageDecisions: number
    invitesEnviados: number
    feeConfigsCriadas: number
    auditLogs: number
    creditApplications: number
    savingsAccounts: number
    referralsCreated: number
    referralAsReferred: number
    quizAttempts: number
    badges: number
    insurancePolicies: number
  }

  export type UserCountOutputTypeSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    referidos?: boolean | UserCountOutputTypeCountReferidosArgs
    gruposCriados?: boolean | UserCountOutputTypeCountGruposCriadosArgs
    memberships?: boolean | UserCountOutputTypeCountMembershipsArgs
    contribuicoes?: boolean | UserCountOutputTypeCountContribuicoesArgs
    cashouts?: boolean | UserCountOutputTypeCountCashoutsArgs
    loans?: boolean | UserCountOutputTypeCountLoansArgs
    scoreEvents?: boolean | UserCountOutputTypeCountScoreEventsArgs
    reintegrations?: boolean | UserCountOutputTypeCountReintegrationsArgs
    otps?: boolean | UserCountOutputTypeCountOtpsArgs
    sessions?: boolean | UserCountOutputTypeCountSessionsArgs
    notifications?: boolean | UserCountOutputTypeCountNotificationsArgs
    coverageDecisions?: boolean | UserCountOutputTypeCountCoverageDecisionsArgs
    invitesEnviados?: boolean | UserCountOutputTypeCountInvitesEnviadosArgs
    feeConfigsCriadas?: boolean | UserCountOutputTypeCountFeeConfigsCriadasArgs
    auditLogs?: boolean | UserCountOutputTypeCountAuditLogsArgs
    creditApplications?: boolean | UserCountOutputTypeCountCreditApplicationsArgs
    savingsAccounts?: boolean | UserCountOutputTypeCountSavingsAccountsArgs
    referralsCreated?: boolean | UserCountOutputTypeCountReferralsCreatedArgs
    referralAsReferred?: boolean | UserCountOutputTypeCountReferralAsReferredArgs
    quizAttempts?: boolean | UserCountOutputTypeCountQuizAttemptsArgs
    badges?: boolean | UserCountOutputTypeCountBadgesArgs
    insurancePolicies?: boolean | UserCountOutputTypeCountInsurancePoliciesArgs
  }

  // 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 UserCountOutputTypeCountReferidosArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: UserWhereInput
  }

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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


  /**
   * Count Type GroupCountOutputType
   */

  export type GroupCountOutputType = {
    memberships: number
    monthlyCycles: number
    invites: number
    candidaturas: number
  }

  export type GroupCountOutputTypeSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    memberships?: boolean | GroupCountOutputTypeCountMembershipsArgs
    monthlyCycles?: boolean | GroupCountOutputTypeCountMonthlyCyclesArgs
    invites?: boolean | GroupCountOutputTypeCountInvitesArgs
    candidaturas?: boolean | GroupCountOutputTypeCountCandidaturasArgs
  }

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

  /**
   * GroupCountOutputType without action
   */
  export type GroupCountOutputTypeCountMembershipsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: MembershipWhereInput
  }

  /**
   * GroupCountOutputType without action
   */
  export type GroupCountOutputTypeCountMonthlyCyclesArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: MonthlyCycleWhereInput
  }

  /**
   * GroupCountOutputType without action
   */
  export type GroupCountOutputTypeCountInvitesArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: InviteWhereInput
  }

  /**
   * GroupCountOutputType without action
   */
  export type GroupCountOutputTypeCountCandidaturasArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: GroupApplicationWhereInput
  }


  /**
   * Count Type MembershipCountOutputType
   */

  export type MembershipCountOutputType = {
    monthlyCyclesBeneficiario: number
    contribuicoes: number
  }

  export type MembershipCountOutputTypeSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    monthlyCyclesBeneficiario?: boolean | MembershipCountOutputTypeCountMonthlyCyclesBeneficiarioArgs
    contribuicoes?: boolean | MembershipCountOutputTypeCountContribuicoesArgs
  }

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

  /**
   * MembershipCountOutputType without action
   */
  export type MembershipCountOutputTypeCountMonthlyCyclesBeneficiarioArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: MonthlyCycleWhereInput
  }

  /**
   * MembershipCountOutputType without action
   */
  export type MembershipCountOutputTypeCountContribuicoesArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: ContributionWhereInput
  }


  /**
   * Count Type MonthlyCycleCountOutputType
   */

  export type MonthlyCycleCountOutputType = {
    contribuicoes: number
    loans: number
  }

  export type MonthlyCycleCountOutputTypeSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    contribuicoes?: boolean | MonthlyCycleCountOutputTypeCountContribuicoesArgs
    loans?: boolean | MonthlyCycleCountOutputTypeCountLoansArgs
  }

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

  /**
   * MonthlyCycleCountOutputType without action
   */
  export type MonthlyCycleCountOutputTypeCountContribuicoesArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: ContributionWhereInput
  }

  /**
   * MonthlyCycleCountOutputType without action
   */
  export type MonthlyCycleCountOutputTypeCountLoansArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: LoanWhereInput
  }


  /**
   * Count Type CreditApplicationCountOutputType
   */

  export type CreditApplicationCountOutputType = {
    prestacoes: number
  }

  export type CreditApplicationCountOutputTypeSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    prestacoes?: boolean | CreditApplicationCountOutputTypeCountPrestacoesArgs
  }

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

  /**
   * CreditApplicationCountOutputType without action
   */
  export type CreditApplicationCountOutputTypeCountPrestacoesArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: CreditInstallmentWhereInput
  }


  /**
   * Count Type SavingsAccountCountOutputType
   */

  export type SavingsAccountCountOutputType = {
    movimentos: number
  }

  export type SavingsAccountCountOutputTypeSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    movimentos?: boolean | SavingsAccountCountOutputTypeCountMovimentosArgs
  }

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

  /**
   * SavingsAccountCountOutputType without action
   */
  export type SavingsAccountCountOutputTypeCountMovimentosArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: SavingsMovementWhereInput
  }


  /**
   * Count Type QuizCountOutputType
   */

  export type QuizCountOutputType = {
    attempts: number
  }

  export type QuizCountOutputTypeSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    attempts?: boolean | QuizCountOutputTypeCountAttemptsArgs
  }

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

  /**
   * QuizCountOutputType without action
   */
  export type QuizCountOutputTypeCountAttemptsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: QuizAttemptWhereInput
  }


  /**
   * Count Type ApiKeyCountOutputType
   */

  export type ApiKeyCountOutputType = {
    chamadas: number
  }

  export type ApiKeyCountOutputTypeSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    chamadas?: boolean | ApiKeyCountOutputTypeCountChamadasArgs
  }

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

  /**
   * ApiKeyCountOutputType without action
   */
  export type ApiKeyCountOutputTypeCountChamadasArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: ApiCallWhereInput
  }


  /**
   * Count Type InsuranceProductCountOutputType
   */

  export type InsuranceProductCountOutputType = {
    policies: number
  }

  export type InsuranceProductCountOutputTypeSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    policies?: boolean | InsuranceProductCountOutputTypeCountPoliciesArgs
  }

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

  /**
   * InsuranceProductCountOutputType without action
   */
  export type InsuranceProductCountOutputTypeCountPoliciesArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: InsurancePolicyWhereInput
  }


  /**
   * Models
   */

  /**
   * Model User
   */

  export type AggregateUser = {
    _count: UserCountAggregateOutputType | null
    _avg: UserAvgAggregateOutputType | null
    _sum: UserSumAggregateOutputType | null
    _min: UserMinAggregateOutputType | null
    _max: UserMaxAggregateOutputType | null
  }

  export type UserAvgAggregateOutputType = {
    kycNivel: number | null
    scoreAtual: number | null
    pontosEducacao: number | null
  }

  export type UserSumAggregateOutputType = {
    kycNivel: number | null
    scoreAtual: number | null
    pontosEducacao: number | null
  }

  export type UserMinAggregateOutputType = {
    id: string | null
    nome: string | null
    telefone: string | null
    email: string | null
    passwordHash: string | null
    bi: string | null
    dataNascimento: Date | null
    provincia: string | null
    pais: string | null
    moedaPreferida: string | null
    fotoPerfilUrl: string | null
    kycStatus: string | null
    kycNivel: number | null
    kycDataJson: string | null
    status: string | null
    scoreAtual: number | null
    role: string | null
    referralCode: string | null
    referredById: string | null
    pontosEducacao: number | null
    createdAt: Date | null
    updatedAt: Date | null
  }

  export type UserMaxAggregateOutputType = {
    id: string | null
    nome: string | null
    telefone: string | null
    email: string | null
    passwordHash: string | null
    bi: string | null
    dataNascimento: Date | null
    provincia: string | null
    pais: string | null
    moedaPreferida: string | null
    fotoPerfilUrl: string | null
    kycStatus: string | null
    kycNivel: number | null
    kycDataJson: string | null
    status: string | null
    scoreAtual: number | null
    role: string | null
    referralCode: string | null
    referredById: string | null
    pontosEducacao: number | null
    createdAt: Date | null
    updatedAt: Date | null
  }

  export type UserCountAggregateOutputType = {
    id: number
    nome: number
    telefone: number
    email: number
    passwordHash: number
    bi: number
    dataNascimento: number
    provincia: number
    pais: number
    moedaPreferida: number
    fotoPerfilUrl: number
    kycStatus: number
    kycNivel: number
    kycDataJson: number
    status: number
    scoreAtual: number
    role: number
    referralCode: number
    referredById: number
    pontosEducacao: number
    createdAt: number
    updatedAt: number
    _all: number
  }


  export type UserAvgAggregateInputType = {
    kycNivel?: true
    scoreAtual?: true
    pontosEducacao?: true
  }

  export type UserSumAggregateInputType = {
    kycNivel?: true
    scoreAtual?: true
    pontosEducacao?: true
  }

  export type UserMinAggregateInputType = {
    id?: true
    nome?: true
    telefone?: true
    email?: true
    passwordHash?: true
    bi?: true
    dataNascimento?: true
    provincia?: true
    pais?: true
    moedaPreferida?: true
    fotoPerfilUrl?: true
    kycStatus?: true
    kycNivel?: true
    kycDataJson?: true
    status?: true
    scoreAtual?: true
    role?: true
    referralCode?: true
    referredById?: true
    pontosEducacao?: true
    createdAt?: true
    updatedAt?: true
  }

  export type UserMaxAggregateInputType = {
    id?: true
    nome?: true
    telefone?: true
    email?: true
    passwordHash?: true
    bi?: true
    dataNascimento?: true
    provincia?: true
    pais?: true
    moedaPreferida?: true
    fotoPerfilUrl?: true
    kycStatus?: true
    kycNivel?: true
    kycDataJson?: true
    status?: true
    scoreAtual?: true
    role?: true
    referralCode?: true
    referredById?: true
    pontosEducacao?: true
    createdAt?: true
    updatedAt?: true
  }

  export type UserCountAggregateInputType = {
    id?: true
    nome?: true
    telefone?: true
    email?: true
    passwordHash?: true
    bi?: true
    dataNascimento?: true
    provincia?: true
    pais?: true
    moedaPreferida?: true
    fotoPerfilUrl?: true
    kycStatus?: true
    kycNivel?: true
    kycDataJson?: true
    status?: true
    scoreAtual?: true
    role?: true
    referralCode?: true
    referredById?: true
    pontosEducacao?: 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 average
    **/
    _avg?: UserAvgAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to sum
    **/
    _sum?: UserSumAggregateInputType
    /**
     * {@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
    _avg?: UserAvgAggregateInputType
    _sum?: UserSumAggregateInputType
    _min?: UserMinAggregateInputType
    _max?: UserMaxAggregateInputType
  }

  export type UserGroupByOutputType = {
    id: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi: string | null
    dataNascimento: Date | null
    provincia: string | null
    pais: string
    moedaPreferida: string
    fotoPerfilUrl: string | null
    kycStatus: string
    kycNivel: number
    kycDataJson: string | null
    status: string
    scoreAtual: number
    role: string
    referralCode: string | null
    referredById: string | null
    pontosEducacao: number
    createdAt: Date
    updatedAt: Date
    _count: UserCountAggregateOutputType | null
    _avg: UserAvgAggregateOutputType | null
    _sum: UserSumAggregateOutputType | 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
    nome?: boolean
    telefone?: boolean
    email?: boolean
    passwordHash?: boolean
    bi?: boolean
    dataNascimento?: boolean
    provincia?: boolean
    pais?: boolean
    moedaPreferida?: boolean
    fotoPerfilUrl?: boolean
    kycStatus?: boolean
    kycNivel?: boolean
    kycDataJson?: boolean
    status?: boolean
    scoreAtual?: boolean
    role?: boolean
    referralCode?: boolean
    referredById?: boolean
    pontosEducacao?: boolean
    createdAt?: boolean
    updatedAt?: boolean
    referredBy?: boolean | User$referredByArgs<ExtArgs>
    referidos?: boolean | User$referidosArgs<ExtArgs>
    gruposCriados?: boolean | User$gruposCriadosArgs<ExtArgs>
    memberships?: boolean | User$membershipsArgs<ExtArgs>
    contribuicoes?: boolean | User$contribuicoesArgs<ExtArgs>
    cashouts?: boolean | User$cashoutsArgs<ExtArgs>
    loans?: boolean | User$loansArgs<ExtArgs>
    scoreEvents?: boolean | User$scoreEventsArgs<ExtArgs>
    reintegrations?: boolean | User$reintegrationsArgs<ExtArgs>
    otps?: boolean | User$otpsArgs<ExtArgs>
    sessions?: boolean | User$sessionsArgs<ExtArgs>
    notifications?: boolean | User$notificationsArgs<ExtArgs>
    coverageDecisions?: boolean | User$coverageDecisionsArgs<ExtArgs>
    invitesEnviados?: boolean | User$invitesEnviadosArgs<ExtArgs>
    feeConfigsCriadas?: boolean | User$feeConfigsCriadasArgs<ExtArgs>
    auditLogs?: boolean | User$auditLogsArgs<ExtArgs>
    creditApplications?: boolean | User$creditApplicationsArgs<ExtArgs>
    savingsAccounts?: boolean | User$savingsAccountsArgs<ExtArgs>
    referralsCreated?: boolean | User$referralsCreatedArgs<ExtArgs>
    referralAsReferred?: boolean | User$referralAsReferredArgs<ExtArgs>
    quizAttempts?: boolean | User$quizAttemptsArgs<ExtArgs>
    badges?: boolean | User$badgesArgs<ExtArgs>
    insurancePolicies?: boolean | User$insurancePoliciesArgs<ExtArgs>
    _count?: boolean | UserCountOutputTypeDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["user"]>


  export type UserSelectScalar = {
    id?: boolean
    nome?: boolean
    telefone?: boolean
    email?: boolean
    passwordHash?: boolean
    bi?: boolean
    dataNascimento?: boolean
    provincia?: boolean
    pais?: boolean
    moedaPreferida?: boolean
    fotoPerfilUrl?: boolean
    kycStatus?: boolean
    kycNivel?: boolean
    kycDataJson?: boolean
    status?: boolean
    scoreAtual?: boolean
    role?: boolean
    referralCode?: boolean
    referredById?: boolean
    pontosEducacao?: boolean
    createdAt?: boolean
    updatedAt?: boolean
  }

  export type UserInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    referredBy?: boolean | User$referredByArgs<ExtArgs>
    referidos?: boolean | User$referidosArgs<ExtArgs>
    gruposCriados?: boolean | User$gruposCriadosArgs<ExtArgs>
    memberships?: boolean | User$membershipsArgs<ExtArgs>
    contribuicoes?: boolean | User$contribuicoesArgs<ExtArgs>
    cashouts?: boolean | User$cashoutsArgs<ExtArgs>
    loans?: boolean | User$loansArgs<ExtArgs>
    scoreEvents?: boolean | User$scoreEventsArgs<ExtArgs>
    reintegrations?: boolean | User$reintegrationsArgs<ExtArgs>
    otps?: boolean | User$otpsArgs<ExtArgs>
    sessions?: boolean | User$sessionsArgs<ExtArgs>
    notifications?: boolean | User$notificationsArgs<ExtArgs>
    coverageDecisions?: boolean | User$coverageDecisionsArgs<ExtArgs>
    invitesEnviados?: boolean | User$invitesEnviadosArgs<ExtArgs>
    feeConfigsCriadas?: boolean | User$feeConfigsCriadasArgs<ExtArgs>
    auditLogs?: boolean | User$auditLogsArgs<ExtArgs>
    creditApplications?: boolean | User$creditApplicationsArgs<ExtArgs>
    savingsAccounts?: boolean | User$savingsAccountsArgs<ExtArgs>
    referralsCreated?: boolean | User$referralsCreatedArgs<ExtArgs>
    referralAsReferred?: boolean | User$referralAsReferredArgs<ExtArgs>
    quizAttempts?: boolean | User$quizAttemptsArgs<ExtArgs>
    badges?: boolean | User$badgesArgs<ExtArgs>
    insurancePolicies?: boolean | User$insurancePoliciesArgs<ExtArgs>
    _count?: boolean | UserCountOutputTypeDefaultArgs<ExtArgs>
  }

  export type $UserPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "User"
    objects: {
      referredBy: Prisma.$UserPayload<ExtArgs> | null
      referidos: Prisma.$UserPayload<ExtArgs>[]
      gruposCriados: Prisma.$GroupPayload<ExtArgs>[]
      memberships: Prisma.$MembershipPayload<ExtArgs>[]
      contribuicoes: Prisma.$ContributionPayload<ExtArgs>[]
      cashouts: Prisma.$CashoutPayload<ExtArgs>[]
      loans: Prisma.$LoanPayload<ExtArgs>[]
      scoreEvents: Prisma.$ScoreEventPayload<ExtArgs>[]
      reintegrations: Prisma.$ReintegrationPayload<ExtArgs>[]
      otps: Prisma.$OtpPayload<ExtArgs>[]
      sessions: Prisma.$SessionPayload<ExtArgs>[]
      notifications: Prisma.$NotificationPayload<ExtArgs>[]
      coverageDecisions: Prisma.$CoverageDecisionPayload<ExtArgs>[]
      invitesEnviados: Prisma.$InvitePayload<ExtArgs>[]
      feeConfigsCriadas: Prisma.$FeeConfigurationPayload<ExtArgs>[]
      auditLogs: Prisma.$AuditLogPayload<ExtArgs>[]
      creditApplications: Prisma.$CreditApplicationPayload<ExtArgs>[]
      savingsAccounts: Prisma.$SavingsAccountPayload<ExtArgs>[]
      referralsCreated: Prisma.$ReferralPayload<ExtArgs>[]
      referralAsReferred: Prisma.$ReferralPayload<ExtArgs>[]
      quizAttempts: Prisma.$QuizAttemptPayload<ExtArgs>[]
      badges: Prisma.$BadgePayload<ExtArgs>[]
      insurancePolicies: Prisma.$InsurancePolicyPayload<ExtArgs>[]
    }
    scalars: $Extensions.GetPayloadResult<{
      id: string
      nome: string
      telefone: string
      email: string
      passwordHash: string
      bi: string | null
      dataNascimento: Date | null
      provincia: string | null
      pais: string
      moedaPreferida: string
      fotoPerfilUrl: string | null
      kycStatus: string
      kycNivel: number
      kycDataJson: string | null
      status: string
      scoreAtual: number
      role: string
      referralCode: string | null
      referredById: string | null
      pontosEducacao: number
      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'> & {
      select?: UserCountAggregateInputType | true
    }

  export interface UserDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> {
    [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"> | null, null, ExtArgs>

    /**
     * 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">, never, ExtArgs>

    /**
     * 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"> | null, null, ExtArgs>

    /**
     * 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">, never, ExtArgs>

    /**
     * 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">>

    /**
     * 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">, never, ExtArgs>

    /**
     * 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>

    /**
     * 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">, never, ExtArgs>

    /**
     * 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">, never, ExtArgs>

    /**
     * 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>

    /**
     * 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">, never, ExtArgs>


    /**
     * 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> extends Prisma.PrismaPromise<T> {
    readonly [Symbol.toStringTag]: "PrismaPromise"
    referredBy<T extends User$referredByArgs<ExtArgs> = {}>(args?: Subset<T, User$referredByArgs<ExtArgs>>): Prisma__UserClient<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "findUniqueOrThrow"> | null, null, ExtArgs>
    referidos<T extends User$referidosArgs<ExtArgs> = {}>(args?: Subset<T, User$referidosArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "findMany"> | Null>
    gruposCriados<T extends User$gruposCriadosArgs<ExtArgs> = {}>(args?: Subset<T, User$gruposCriadosArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$GroupPayload<ExtArgs>, T, "findMany"> | Null>
    memberships<T extends User$membershipsArgs<ExtArgs> = {}>(args?: Subset<T, User$membershipsArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$MembershipPayload<ExtArgs>, T, "findMany"> | Null>
    contribuicoes<T extends User$contribuicoesArgs<ExtArgs> = {}>(args?: Subset<T, User$contribuicoesArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$ContributionPayload<ExtArgs>, T, "findMany"> | Null>
    cashouts<T extends User$cashoutsArgs<ExtArgs> = {}>(args?: Subset<T, User$cashoutsArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$CashoutPayload<ExtArgs>, T, "findMany"> | Null>
    loans<T extends User$loansArgs<ExtArgs> = {}>(args?: Subset<T, User$loansArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$LoanPayload<ExtArgs>, T, "findMany"> | Null>
    scoreEvents<T extends User$scoreEventsArgs<ExtArgs> = {}>(args?: Subset<T, User$scoreEventsArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$ScoreEventPayload<ExtArgs>, T, "findMany"> | Null>
    reintegrations<T extends User$reintegrationsArgs<ExtArgs> = {}>(args?: Subset<T, User$reintegrationsArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$ReintegrationPayload<ExtArgs>, T, "findMany"> | Null>
    otps<T extends User$otpsArgs<ExtArgs> = {}>(args?: Subset<T, User$otpsArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$OtpPayload<ExtArgs>, T, "findMany"> | Null>
    sessions<T extends User$sessionsArgs<ExtArgs> = {}>(args?: Subset<T, User$sessionsArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$SessionPayload<ExtArgs>, T, "findMany"> | Null>
    notifications<T extends User$notificationsArgs<ExtArgs> = {}>(args?: Subset<T, User$notificationsArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$NotificationPayload<ExtArgs>, T, "findMany"> | Null>
    coverageDecisions<T extends User$coverageDecisionsArgs<ExtArgs> = {}>(args?: Subset<T, User$coverageDecisionsArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$CoverageDecisionPayload<ExtArgs>, T, "findMany"> | Null>
    invitesEnviados<T extends User$invitesEnviadosArgs<ExtArgs> = {}>(args?: Subset<T, User$invitesEnviadosArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$InvitePayload<ExtArgs>, T, "findMany"> | Null>
    feeConfigsCriadas<T extends User$feeConfigsCriadasArgs<ExtArgs> = {}>(args?: Subset<T, User$feeConfigsCriadasArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$FeeConfigurationPayload<ExtArgs>, T, "findMany"> | Null>
    auditLogs<T extends User$auditLogsArgs<ExtArgs> = {}>(args?: Subset<T, User$auditLogsArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$AuditLogPayload<ExtArgs>, T, "findMany"> | Null>
    creditApplications<T extends User$creditApplicationsArgs<ExtArgs> = {}>(args?: Subset<T, User$creditApplicationsArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$CreditApplicationPayload<ExtArgs>, T, "findMany"> | Null>
    savingsAccounts<T extends User$savingsAccountsArgs<ExtArgs> = {}>(args?: Subset<T, User$savingsAccountsArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$SavingsAccountPayload<ExtArgs>, T, "findMany"> | Null>
    referralsCreated<T extends User$referralsCreatedArgs<ExtArgs> = {}>(args?: Subset<T, User$referralsCreatedArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$ReferralPayload<ExtArgs>, T, "findMany"> | Null>
    referralAsReferred<T extends User$referralAsReferredArgs<ExtArgs> = {}>(args?: Subset<T, User$referralAsReferredArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$ReferralPayload<ExtArgs>, T, "findMany"> | Null>
    quizAttempts<T extends User$quizAttemptsArgs<ExtArgs> = {}>(args?: Subset<T, User$quizAttemptsArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$QuizAttemptPayload<ExtArgs>, T, "findMany"> | Null>
    badges<T extends User$badgesArgs<ExtArgs> = {}>(args?: Subset<T, User$badgesArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$BadgePayload<ExtArgs>, T, "findMany"> | Null>
    insurancePolicies<T extends User$insurancePoliciesArgs<ExtArgs> = {}>(args?: Subset<T, User$insurancePoliciesArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$InsurancePolicyPayload<ExtArgs>, T, "findMany"> | 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 nome: FieldRef<"User", 'String'>
    readonly telefone: FieldRef<"User", 'String'>
    readonly email: FieldRef<"User", 'String'>
    readonly passwordHash: FieldRef<"User", 'String'>
    readonly bi: FieldRef<"User", 'String'>
    readonly dataNascimento: FieldRef<"User", 'DateTime'>
    readonly provincia: FieldRef<"User", 'String'>
    readonly pais: FieldRef<"User", 'String'>
    readonly moedaPreferida: FieldRef<"User", 'String'>
    readonly fotoPerfilUrl: FieldRef<"User", 'String'>
    readonly kycStatus: FieldRef<"User", 'String'>
    readonly kycNivel: FieldRef<"User", 'Int'>
    readonly kycDataJson: FieldRef<"User", 'String'>
    readonly status: FieldRef<"User", 'String'>
    readonly scoreAtual: FieldRef<"User", 'Int'>
    readonly role: FieldRef<"User", 'String'>
    readonly referralCode: FieldRef<"User", 'String'>
    readonly referredById: FieldRef<"User", 'String'>
    readonly pontosEducacao: FieldRef<"User", 'Int'>
    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
    /**
     * 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
    /**
     * 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
    /**
     * 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
    /**
     * 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
    /**
     * 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
    /**
     * 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[]
    skipDuplicates?: boolean
  }

  /**
   * User update
   */
  export type UserUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the User
     */
    select?: UserSelect<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
  }

  /**
   * User upsert
   */
  export type UserUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the User
     */
    select?: UserSelect<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
    /**
     * 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
  }

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

  /**
   * User.referidos
   */
  export type User$referidosArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the User
     */
    select?: UserSelect<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.gruposCriados
   */
  export type User$gruposCriadosArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Group
     */
    select?: GroupSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GroupInclude<ExtArgs> | null
    where?: GroupWhereInput
    orderBy?: GroupOrderByWithRelationInput | GroupOrderByWithRelationInput[]
    cursor?: GroupWhereUniqueInput
    take?: number
    skip?: number
    distinct?: GroupScalarFieldEnum | GroupScalarFieldEnum[]
  }

  /**
   * User.memberships
   */
  export type User$membershipsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Membership
     */
    select?: MembershipSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: MembershipInclude<ExtArgs> | null
    where?: MembershipWhereInput
    orderBy?: MembershipOrderByWithRelationInput | MembershipOrderByWithRelationInput[]
    cursor?: MembershipWhereUniqueInput
    take?: number
    skip?: number
    distinct?: MembershipScalarFieldEnum | MembershipScalarFieldEnum[]
  }

  /**
   * User.contribuicoes
   */
  export type User$contribuicoesArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Contribution
     */
    select?: ContributionSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ContributionInclude<ExtArgs> | null
    where?: ContributionWhereInput
    orderBy?: ContributionOrderByWithRelationInput | ContributionOrderByWithRelationInput[]
    cursor?: ContributionWhereUniqueInput
    take?: number
    skip?: number
    distinct?: ContributionScalarFieldEnum | ContributionScalarFieldEnum[]
  }

  /**
   * User.cashouts
   */
  export type User$cashoutsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Cashout
     */
    select?: CashoutSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CashoutInclude<ExtArgs> | null
    where?: CashoutWhereInput
    orderBy?: CashoutOrderByWithRelationInput | CashoutOrderByWithRelationInput[]
    cursor?: CashoutWhereUniqueInput
    take?: number
    skip?: number
    distinct?: CashoutScalarFieldEnum | CashoutScalarFieldEnum[]
  }

  /**
   * User.loans
   */
  export type User$loansArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Loan
     */
    select?: LoanSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: LoanInclude<ExtArgs> | null
    where?: LoanWhereInput
    orderBy?: LoanOrderByWithRelationInput | LoanOrderByWithRelationInput[]
    cursor?: LoanWhereUniqueInput
    take?: number
    skip?: number
    distinct?: LoanScalarFieldEnum | LoanScalarFieldEnum[]
  }

  /**
   * User.scoreEvents
   */
  export type User$scoreEventsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ScoreEvent
     */
    select?: ScoreEventSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ScoreEventInclude<ExtArgs> | null
    where?: ScoreEventWhereInput
    orderBy?: ScoreEventOrderByWithRelationInput | ScoreEventOrderByWithRelationInput[]
    cursor?: ScoreEventWhereUniqueInput
    take?: number
    skip?: number
    distinct?: ScoreEventScalarFieldEnum | ScoreEventScalarFieldEnum[]
  }

  /**
   * User.reintegrations
   */
  export type User$reintegrationsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Reintegration
     */
    select?: ReintegrationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ReintegrationInclude<ExtArgs> | null
    where?: ReintegrationWhereInput
    orderBy?: ReintegrationOrderByWithRelationInput | ReintegrationOrderByWithRelationInput[]
    cursor?: ReintegrationWhereUniqueInput
    take?: number
    skip?: number
    distinct?: ReintegrationScalarFieldEnum | ReintegrationScalarFieldEnum[]
  }

  /**
   * User.otps
   */
  export type User$otpsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Otp
     */
    select?: OtpSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: OtpInclude<ExtArgs> | null
    where?: OtpWhereInput
    orderBy?: OtpOrderByWithRelationInput | OtpOrderByWithRelationInput[]
    cursor?: OtpWhereUniqueInput
    take?: number
    skip?: number
    distinct?: OtpScalarFieldEnum | OtpScalarFieldEnum[]
  }

  /**
   * User.sessions
   */
  export type User$sessionsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Session
     */
    select?: SessionSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: SessionInclude<ExtArgs> | null
    where?: SessionWhereInput
    orderBy?: SessionOrderByWithRelationInput | SessionOrderByWithRelationInput[]
    cursor?: SessionWhereUniqueInput
    take?: number
    skip?: number
    distinct?: SessionScalarFieldEnum | SessionScalarFieldEnum[]
  }

  /**
   * User.notifications
   */
  export type User$notificationsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Notification
     */
    select?: NotificationSelect<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.coverageDecisions
   */
  export type User$coverageDecisionsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CoverageDecision
     */
    select?: CoverageDecisionSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CoverageDecisionInclude<ExtArgs> | null
    where?: CoverageDecisionWhereInput
    orderBy?: CoverageDecisionOrderByWithRelationInput | CoverageDecisionOrderByWithRelationInput[]
    cursor?: CoverageDecisionWhereUniqueInput
    take?: number
    skip?: number
    distinct?: CoverageDecisionScalarFieldEnum | CoverageDecisionScalarFieldEnum[]
  }

  /**
   * User.invitesEnviados
   */
  export type User$invitesEnviadosArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Invite
     */
    select?: InviteSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: InviteInclude<ExtArgs> | null
    where?: InviteWhereInput
    orderBy?: InviteOrderByWithRelationInput | InviteOrderByWithRelationInput[]
    cursor?: InviteWhereUniqueInput
    take?: number
    skip?: number
    distinct?: InviteScalarFieldEnum | InviteScalarFieldEnum[]
  }

  /**
   * User.feeConfigsCriadas
   */
  export type User$feeConfigsCriadasArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the FeeConfiguration
     */
    select?: FeeConfigurationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: FeeConfigurationInclude<ExtArgs> | null
    where?: FeeConfigurationWhereInput
    orderBy?: FeeConfigurationOrderByWithRelationInput | FeeConfigurationOrderByWithRelationInput[]
    cursor?: FeeConfigurationWhereUniqueInput
    take?: number
    skip?: number
    distinct?: FeeConfigurationScalarFieldEnum | FeeConfigurationScalarFieldEnum[]
  }

  /**
   * User.auditLogs
   */
  export type User$auditLogsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the AuditLog
     */
    select?: AuditLogSelect<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.creditApplications
   */
  export type User$creditApplicationsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CreditApplication
     */
    select?: CreditApplicationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CreditApplicationInclude<ExtArgs> | null
    where?: CreditApplicationWhereInput
    orderBy?: CreditApplicationOrderByWithRelationInput | CreditApplicationOrderByWithRelationInput[]
    cursor?: CreditApplicationWhereUniqueInput
    take?: number
    skip?: number
    distinct?: CreditApplicationScalarFieldEnum | CreditApplicationScalarFieldEnum[]
  }

  /**
   * User.savingsAccounts
   */
  export type User$savingsAccountsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SavingsAccount
     */
    select?: SavingsAccountSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: SavingsAccountInclude<ExtArgs> | null
    where?: SavingsAccountWhereInput
    orderBy?: SavingsAccountOrderByWithRelationInput | SavingsAccountOrderByWithRelationInput[]
    cursor?: SavingsAccountWhereUniqueInput
    take?: number
    skip?: number
    distinct?: SavingsAccountScalarFieldEnum | SavingsAccountScalarFieldEnum[]
  }

  /**
   * User.referralsCreated
   */
  export type User$referralsCreatedArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Referral
     */
    select?: ReferralSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ReferralInclude<ExtArgs> | null
    where?: ReferralWhereInput
    orderBy?: ReferralOrderByWithRelationInput | ReferralOrderByWithRelationInput[]
    cursor?: ReferralWhereUniqueInput
    take?: number
    skip?: number
    distinct?: ReferralScalarFieldEnum | ReferralScalarFieldEnum[]
  }

  /**
   * User.referralAsReferred
   */
  export type User$referralAsReferredArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Referral
     */
    select?: ReferralSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ReferralInclude<ExtArgs> | null
    where?: ReferralWhereInput
    orderBy?: ReferralOrderByWithRelationInput | ReferralOrderByWithRelationInput[]
    cursor?: ReferralWhereUniqueInput
    take?: number
    skip?: number
    distinct?: ReferralScalarFieldEnum | ReferralScalarFieldEnum[]
  }

  /**
   * User.quizAttempts
   */
  export type User$quizAttemptsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the QuizAttempt
     */
    select?: QuizAttemptSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: QuizAttemptInclude<ExtArgs> | null
    where?: QuizAttemptWhereInput
    orderBy?: QuizAttemptOrderByWithRelationInput | QuizAttemptOrderByWithRelationInput[]
    cursor?: QuizAttemptWhereUniqueInput
    take?: number
    skip?: number
    distinct?: QuizAttemptScalarFieldEnum | QuizAttemptScalarFieldEnum[]
  }

  /**
   * User.badges
   */
  export type User$badgesArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Badge
     */
    select?: BadgeSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: BadgeInclude<ExtArgs> | null
    where?: BadgeWhereInput
    orderBy?: BadgeOrderByWithRelationInput | BadgeOrderByWithRelationInput[]
    cursor?: BadgeWhereUniqueInput
    take?: number
    skip?: number
    distinct?: BadgeScalarFieldEnum | BadgeScalarFieldEnum[]
  }

  /**
   * User.insurancePolicies
   */
  export type User$insurancePoliciesArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the InsurancePolicy
     */
    select?: InsurancePolicySelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: InsurancePolicyInclude<ExtArgs> | null
    where?: InsurancePolicyWhereInput
    orderBy?: InsurancePolicyOrderByWithRelationInput | InsurancePolicyOrderByWithRelationInput[]
    cursor?: InsurancePolicyWhereUniqueInput
    take?: number
    skip?: number
    distinct?: InsurancePolicyScalarFieldEnum | InsurancePolicyScalarFieldEnum[]
  }

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


  /**
   * Model Otp
   */

  export type AggregateOtp = {
    _count: OtpCountAggregateOutputType | null
    _min: OtpMinAggregateOutputType | null
    _max: OtpMaxAggregateOutputType | null
  }

  export type OtpMinAggregateOutputType = {
    id: string | null
    userId: string | null
    telefone: string | null
    codigo: string | null
    proposito: string | null
    consumido: boolean | null
    expiraEm: Date | null
    createdAt: Date | null
  }

  export type OtpMaxAggregateOutputType = {
    id: string | null
    userId: string | null
    telefone: string | null
    codigo: string | null
    proposito: string | null
    consumido: boolean | null
    expiraEm: Date | null
    createdAt: Date | null
  }

  export type OtpCountAggregateOutputType = {
    id: number
    userId: number
    telefone: number
    codigo: number
    proposito: number
    consumido: number
    expiraEm: number
    createdAt: number
    _all: number
  }


  export type OtpMinAggregateInputType = {
    id?: true
    userId?: true
    telefone?: true
    codigo?: true
    proposito?: true
    consumido?: true
    expiraEm?: true
    createdAt?: true
  }

  export type OtpMaxAggregateInputType = {
    id?: true
    userId?: true
    telefone?: true
    codigo?: true
    proposito?: true
    consumido?: true
    expiraEm?: true
    createdAt?: true
  }

  export type OtpCountAggregateInputType = {
    id?: true
    userId?: true
    telefone?: true
    codigo?: true
    proposito?: true
    consumido?: true
    expiraEm?: true
    createdAt?: true
    _all?: true
  }

  export type OtpAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which Otp to aggregate.
     */
    where?: OtpWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Otps to fetch.
     */
    orderBy?: OtpOrderByWithRelationInput | OtpOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: OtpWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Otps 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` Otps.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned Otps
    **/
    _count?: true | OtpCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: OtpMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: OtpMaxAggregateInputType
  }

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




  export type OtpGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: OtpWhereInput
    orderBy?: OtpOrderByWithAggregationInput | OtpOrderByWithAggregationInput[]
    by: OtpScalarFieldEnum[] | OtpScalarFieldEnum
    having?: OtpScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: OtpCountAggregateInputType | true
    _min?: OtpMinAggregateInputType
    _max?: OtpMaxAggregateInputType
  }

  export type OtpGroupByOutputType = {
    id: string
    userId: string | null
    telefone: string
    codigo: string
    proposito: string
    consumido: boolean
    expiraEm: Date
    createdAt: Date
    _count: OtpCountAggregateOutputType | null
    _min: OtpMinAggregateOutputType | null
    _max: OtpMaxAggregateOutputType | null
  }

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


  export type OtpSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    userId?: boolean
    telefone?: boolean
    codigo?: boolean
    proposito?: boolean
    consumido?: boolean
    expiraEm?: boolean
    createdAt?: boolean
    user?: boolean | Otp$userArgs<ExtArgs>
  }, ExtArgs["result"]["otp"]>


  export type OtpSelectScalar = {
    id?: boolean
    userId?: boolean
    telefone?: boolean
    codigo?: boolean
    proposito?: boolean
    consumido?: boolean
    expiraEm?: boolean
    createdAt?: boolean
  }

  export type OtpInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    user?: boolean | Otp$userArgs<ExtArgs>
  }

  export type $OtpPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "Otp"
    objects: {
      user: Prisma.$UserPayload<ExtArgs> | null
    }
    scalars: $Extensions.GetPayloadResult<{
      id: string
      userId: string | null
      telefone: string
      codigo: string
      proposito: string
      consumido: boolean
      expiraEm: Date
      createdAt: Date
    }, ExtArgs["result"]["otp"]>
    composites: {}
  }

  type OtpGetPayload<S extends boolean | null | undefined | OtpDefaultArgs> = $Result.GetResult<Prisma.$OtpPayload, S>

  type OtpCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = 
    Omit<OtpFindManyArgs, 'select' | 'include' | 'distinct'> & {
      select?: OtpCountAggregateInputType | true
    }

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

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

    /**
     * Find the first Otp 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 {OtpFindFirstArgs} args - Arguments to find a Otp
     * @example
     * // Get one Otp
     * const otp = await prisma.otp.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends OtpFindFirstArgs>(args?: SelectSubset<T, OtpFindFirstArgs<ExtArgs>>): Prisma__OtpClient<$Result.GetResult<Prisma.$OtpPayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>

    /**
     * Find the first Otp 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 {OtpFindFirstOrThrowArgs} args - Arguments to find a Otp
     * @example
     * // Get one Otp
     * const otp = await prisma.otp.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends OtpFindFirstOrThrowArgs>(args?: SelectSubset<T, OtpFindFirstOrThrowArgs<ExtArgs>>): Prisma__OtpClient<$Result.GetResult<Prisma.$OtpPayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>

    /**
     * Find zero or more Otps 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 {OtpFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all Otps
     * const otps = await prisma.otp.findMany()
     * 
     * // Get first 10 Otps
     * const otps = await prisma.otp.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const otpWithIdOnly = await prisma.otp.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends OtpFindManyArgs>(args?: SelectSubset<T, OtpFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$OtpPayload<ExtArgs>, T, "findMany">>

    /**
     * Create a Otp.
     * @param {OtpCreateArgs} args - Arguments to create a Otp.
     * @example
     * // Create one Otp
     * const Otp = await prisma.otp.create({
     *   data: {
     *     // ... data to create a Otp
     *   }
     * })
     * 
     */
    create<T extends OtpCreateArgs>(args: SelectSubset<T, OtpCreateArgs<ExtArgs>>): Prisma__OtpClient<$Result.GetResult<Prisma.$OtpPayload<ExtArgs>, T, "create">, never, ExtArgs>

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

    /**
     * Delete a Otp.
     * @param {OtpDeleteArgs} args - Arguments to delete one Otp.
     * @example
     * // Delete one Otp
     * const Otp = await prisma.otp.delete({
     *   where: {
     *     // ... filter to delete one Otp
     *   }
     * })
     * 
     */
    delete<T extends OtpDeleteArgs>(args: SelectSubset<T, OtpDeleteArgs<ExtArgs>>): Prisma__OtpClient<$Result.GetResult<Prisma.$OtpPayload<ExtArgs>, T, "delete">, never, ExtArgs>

    /**
     * Update one Otp.
     * @param {OtpUpdateArgs} args - Arguments to update one Otp.
     * @example
     * // Update one Otp
     * const otp = await prisma.otp.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends OtpUpdateArgs>(args: SelectSubset<T, OtpUpdateArgs<ExtArgs>>): Prisma__OtpClient<$Result.GetResult<Prisma.$OtpPayload<ExtArgs>, T, "update">, never, ExtArgs>

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

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

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


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

    /**
     * Allows you to perform aggregations operations on a Otp.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {OtpAggregateArgs} 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 OtpAggregateArgs>(args: Subset<T, OtpAggregateArgs>): Prisma.PrismaPromise<GetOtpAggregateType<T>>

    /**
     * Group by Otp.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {OtpGroupByArgs} 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 OtpGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: OtpGroupByArgs['orderBy'] }
        : { orderBy?: OtpGroupByArgs['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, OtpGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetOtpGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the Otp model
   */
  readonly fields: OtpFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for Otp.
   * 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__OtpClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
    readonly [Symbol.toStringTag]: "PrismaPromise"
    user<T extends Otp$userArgs<ExtArgs> = {}>(args?: Subset<T, Otp$userArgs<ExtArgs>>): Prisma__UserClient<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "findUniqueOrThrow"> | null, null, ExtArgs>
    /**
     * 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 Otp model
   */ 
  interface OtpFieldRefs {
    readonly id: FieldRef<"Otp", 'String'>
    readonly userId: FieldRef<"Otp", 'String'>
    readonly telefone: FieldRef<"Otp", 'String'>
    readonly codigo: FieldRef<"Otp", 'String'>
    readonly proposito: FieldRef<"Otp", 'String'>
    readonly consumido: FieldRef<"Otp", 'Boolean'>
    readonly expiraEm: FieldRef<"Otp", 'DateTime'>
    readonly createdAt: FieldRef<"Otp", 'DateTime'>
  }
    

  // Custom InputTypes
  /**
   * Otp findUnique
   */
  export type OtpFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Otp
     */
    select?: OtpSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: OtpInclude<ExtArgs> | null
    /**
     * Filter, which Otp to fetch.
     */
    where: OtpWhereUniqueInput
  }

  /**
   * Otp findUniqueOrThrow
   */
  export type OtpFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Otp
     */
    select?: OtpSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: OtpInclude<ExtArgs> | null
    /**
     * Filter, which Otp to fetch.
     */
    where: OtpWhereUniqueInput
  }

  /**
   * Otp findFirst
   */
  export type OtpFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Otp
     */
    select?: OtpSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: OtpInclude<ExtArgs> | null
    /**
     * Filter, which Otp to fetch.
     */
    where?: OtpWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Otps to fetch.
     */
    orderBy?: OtpOrderByWithRelationInput | OtpOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for Otps.
     */
    cursor?: OtpWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Otps 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` Otps.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of Otps.
     */
    distinct?: OtpScalarFieldEnum | OtpScalarFieldEnum[]
  }

  /**
   * Otp findFirstOrThrow
   */
  export type OtpFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Otp
     */
    select?: OtpSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: OtpInclude<ExtArgs> | null
    /**
     * Filter, which Otp to fetch.
     */
    where?: OtpWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Otps to fetch.
     */
    orderBy?: OtpOrderByWithRelationInput | OtpOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for Otps.
     */
    cursor?: OtpWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Otps 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` Otps.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of Otps.
     */
    distinct?: OtpScalarFieldEnum | OtpScalarFieldEnum[]
  }

  /**
   * Otp findMany
   */
  export type OtpFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Otp
     */
    select?: OtpSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: OtpInclude<ExtArgs> | null
    /**
     * Filter, which Otps to fetch.
     */
    where?: OtpWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Otps to fetch.
     */
    orderBy?: OtpOrderByWithRelationInput | OtpOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing Otps.
     */
    cursor?: OtpWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Otps 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` Otps.
     */
    skip?: number
    distinct?: OtpScalarFieldEnum | OtpScalarFieldEnum[]
  }

  /**
   * Otp create
   */
  export type OtpCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Otp
     */
    select?: OtpSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: OtpInclude<ExtArgs> | null
    /**
     * The data needed to create a Otp.
     */
    data: XOR<OtpCreateInput, OtpUncheckedCreateInput>
  }

  /**
   * Otp createMany
   */
  export type OtpCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many Otps.
     */
    data: OtpCreateManyInput | OtpCreateManyInput[]
    skipDuplicates?: boolean
  }

  /**
   * Otp update
   */
  export type OtpUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Otp
     */
    select?: OtpSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: OtpInclude<ExtArgs> | null
    /**
     * The data needed to update a Otp.
     */
    data: XOR<OtpUpdateInput, OtpUncheckedUpdateInput>
    /**
     * Choose, which Otp to update.
     */
    where: OtpWhereUniqueInput
  }

  /**
   * Otp updateMany
   */
  export type OtpUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update Otps.
     */
    data: XOR<OtpUpdateManyMutationInput, OtpUncheckedUpdateManyInput>
    /**
     * Filter which Otps to update
     */
    where?: OtpWhereInput
  }

  /**
   * Otp upsert
   */
  export type OtpUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Otp
     */
    select?: OtpSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: OtpInclude<ExtArgs> | null
    /**
     * The filter to search for the Otp to update in case it exists.
     */
    where: OtpWhereUniqueInput
    /**
     * In case the Otp found by the `where` argument doesn't exist, create a new Otp with this data.
     */
    create: XOR<OtpCreateInput, OtpUncheckedCreateInput>
    /**
     * In case the Otp was found with the provided `where` argument, update it with this data.
     */
    update: XOR<OtpUpdateInput, OtpUncheckedUpdateInput>
  }

  /**
   * Otp delete
   */
  export type OtpDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Otp
     */
    select?: OtpSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: OtpInclude<ExtArgs> | null
    /**
     * Filter which Otp to delete.
     */
    where: OtpWhereUniqueInput
  }

  /**
   * Otp deleteMany
   */
  export type OtpDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which Otps to delete
     */
    where?: OtpWhereInput
  }

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

  /**
   * Otp without action
   */
  export type OtpDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Otp
     */
    select?: OtpSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: OtpInclude<ExtArgs> | null
  }


  /**
   * Model Session
   */

  export type AggregateSession = {
    _count: SessionCountAggregateOutputType | null
    _min: SessionMinAggregateOutputType | null
    _max: SessionMaxAggregateOutputType | null
  }

  export type SessionMinAggregateOutputType = {
    id: string | null
    userId: string | null
    token: string | null
    expiraEm: Date | null
    createdAt: Date | null
  }

  export type SessionMaxAggregateOutputType = {
    id: string | null
    userId: string | null
    token: string | null
    expiraEm: Date | null
    createdAt: Date | null
  }

  export type SessionCountAggregateOutputType = {
    id: number
    userId: number
    token: number
    expiraEm: number
    createdAt: number
    _all: number
  }


  export type SessionMinAggregateInputType = {
    id?: true
    userId?: true
    token?: true
    expiraEm?: true
    createdAt?: true
  }

  export type SessionMaxAggregateInputType = {
    id?: true
    userId?: true
    token?: true
    expiraEm?: true
    createdAt?: true
  }

  export type SessionCountAggregateInputType = {
    id?: true
    userId?: true
    token?: true
    expiraEm?: true
    createdAt?: true
    _all?: true
  }

  export type SessionAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which Session to aggregate.
     */
    where?: SessionWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Sessions to fetch.
     */
    orderBy?: SessionOrderByWithRelationInput | SessionOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: SessionWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Sessions 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` Sessions.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned Sessions
    **/
    _count?: true | SessionCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: SessionMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: SessionMaxAggregateInputType
  }

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




  export type SessionGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: SessionWhereInput
    orderBy?: SessionOrderByWithAggregationInput | SessionOrderByWithAggregationInput[]
    by: SessionScalarFieldEnum[] | SessionScalarFieldEnum
    having?: SessionScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: SessionCountAggregateInputType | true
    _min?: SessionMinAggregateInputType
    _max?: SessionMaxAggregateInputType
  }

  export type SessionGroupByOutputType = {
    id: string
    userId: string
    token: string
    expiraEm: Date
    createdAt: Date
    _count: SessionCountAggregateOutputType | null
    _min: SessionMinAggregateOutputType | null
    _max: SessionMaxAggregateOutputType | null
  }

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


  export type SessionSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    userId?: boolean
    token?: boolean
    expiraEm?: boolean
    createdAt?: boolean
    user?: boolean | UserDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["session"]>


  export type SessionSelectScalar = {
    id?: boolean
    userId?: boolean
    token?: boolean
    expiraEm?: boolean
    createdAt?: boolean
  }

  export type SessionInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    user?: boolean | UserDefaultArgs<ExtArgs>
  }

  export type $SessionPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "Session"
    objects: {
      user: Prisma.$UserPayload<ExtArgs>
    }
    scalars: $Extensions.GetPayloadResult<{
      id: string
      userId: string
      token: string
      expiraEm: Date
      createdAt: Date
    }, ExtArgs["result"]["session"]>
    composites: {}
  }

  type SessionGetPayload<S extends boolean | null | undefined | SessionDefaultArgs> = $Result.GetResult<Prisma.$SessionPayload, S>

  type SessionCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = 
    Omit<SessionFindManyArgs, 'select' | 'include' | 'distinct'> & {
      select?: SessionCountAggregateInputType | true
    }

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

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

    /**
     * Find the first Session 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 {SessionFindFirstArgs} args - Arguments to find a Session
     * @example
     * // Get one Session
     * const session = await prisma.session.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends SessionFindFirstArgs>(args?: SelectSubset<T, SessionFindFirstArgs<ExtArgs>>): Prisma__SessionClient<$Result.GetResult<Prisma.$SessionPayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>

    /**
     * Find the first Session 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 {SessionFindFirstOrThrowArgs} args - Arguments to find a Session
     * @example
     * // Get one Session
     * const session = await prisma.session.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends SessionFindFirstOrThrowArgs>(args?: SelectSubset<T, SessionFindFirstOrThrowArgs<ExtArgs>>): Prisma__SessionClient<$Result.GetResult<Prisma.$SessionPayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>

    /**
     * Find zero or more Sessions 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 {SessionFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all Sessions
     * const sessions = await prisma.session.findMany()
     * 
     * // Get first 10 Sessions
     * const sessions = await prisma.session.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const sessionWithIdOnly = await prisma.session.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends SessionFindManyArgs>(args?: SelectSubset<T, SessionFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$SessionPayload<ExtArgs>, T, "findMany">>

    /**
     * Create a Session.
     * @param {SessionCreateArgs} args - Arguments to create a Session.
     * @example
     * // Create one Session
     * const Session = await prisma.session.create({
     *   data: {
     *     // ... data to create a Session
     *   }
     * })
     * 
     */
    create<T extends SessionCreateArgs>(args: SelectSubset<T, SessionCreateArgs<ExtArgs>>): Prisma__SessionClient<$Result.GetResult<Prisma.$SessionPayload<ExtArgs>, T, "create">, never, ExtArgs>

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

    /**
     * Delete a Session.
     * @param {SessionDeleteArgs} args - Arguments to delete one Session.
     * @example
     * // Delete one Session
     * const Session = await prisma.session.delete({
     *   where: {
     *     // ... filter to delete one Session
     *   }
     * })
     * 
     */
    delete<T extends SessionDeleteArgs>(args: SelectSubset<T, SessionDeleteArgs<ExtArgs>>): Prisma__SessionClient<$Result.GetResult<Prisma.$SessionPayload<ExtArgs>, T, "delete">, never, ExtArgs>

    /**
     * Update one Session.
     * @param {SessionUpdateArgs} args - Arguments to update one Session.
     * @example
     * // Update one Session
     * const session = await prisma.session.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends SessionUpdateArgs>(args: SelectSubset<T, SessionUpdateArgs<ExtArgs>>): Prisma__SessionClient<$Result.GetResult<Prisma.$SessionPayload<ExtArgs>, T, "update">, never, ExtArgs>

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

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

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


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

    /**
     * Allows you to perform aggregations operations on a Session.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {SessionAggregateArgs} 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 SessionAggregateArgs>(args: Subset<T, SessionAggregateArgs>): Prisma.PrismaPromise<GetSessionAggregateType<T>>

    /**
     * Group by Session.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {SessionGroupByArgs} 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 SessionGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: SessionGroupByArgs['orderBy'] }
        : { orderBy?: SessionGroupByArgs['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, SessionGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetSessionGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the Session model
   */
  readonly fields: SessionFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for Session.
   * 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__SessionClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> 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"> | Null, Null, ExtArgs>
    /**
     * 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 Session model
   */ 
  interface SessionFieldRefs {
    readonly id: FieldRef<"Session", 'String'>
    readonly userId: FieldRef<"Session", 'String'>
    readonly token: FieldRef<"Session", 'String'>
    readonly expiraEm: FieldRef<"Session", 'DateTime'>
    readonly createdAt: FieldRef<"Session", 'DateTime'>
  }
    

  // Custom InputTypes
  /**
   * Session findUnique
   */
  export type SessionFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Session
     */
    select?: SessionSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: SessionInclude<ExtArgs> | null
    /**
     * Filter, which Session to fetch.
     */
    where: SessionWhereUniqueInput
  }

  /**
   * Session findUniqueOrThrow
   */
  export type SessionFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Session
     */
    select?: SessionSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: SessionInclude<ExtArgs> | null
    /**
     * Filter, which Session to fetch.
     */
    where: SessionWhereUniqueInput
  }

  /**
   * Session findFirst
   */
  export type SessionFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Session
     */
    select?: SessionSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: SessionInclude<ExtArgs> | null
    /**
     * Filter, which Session to fetch.
     */
    where?: SessionWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Sessions to fetch.
     */
    orderBy?: SessionOrderByWithRelationInput | SessionOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for Sessions.
     */
    cursor?: SessionWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Sessions 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` Sessions.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of Sessions.
     */
    distinct?: SessionScalarFieldEnum | SessionScalarFieldEnum[]
  }

  /**
   * Session findFirstOrThrow
   */
  export type SessionFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Session
     */
    select?: SessionSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: SessionInclude<ExtArgs> | null
    /**
     * Filter, which Session to fetch.
     */
    where?: SessionWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Sessions to fetch.
     */
    orderBy?: SessionOrderByWithRelationInput | SessionOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for Sessions.
     */
    cursor?: SessionWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Sessions 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` Sessions.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of Sessions.
     */
    distinct?: SessionScalarFieldEnum | SessionScalarFieldEnum[]
  }

  /**
   * Session findMany
   */
  export type SessionFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Session
     */
    select?: SessionSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: SessionInclude<ExtArgs> | null
    /**
     * Filter, which Sessions to fetch.
     */
    where?: SessionWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Sessions to fetch.
     */
    orderBy?: SessionOrderByWithRelationInput | SessionOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing Sessions.
     */
    cursor?: SessionWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Sessions 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` Sessions.
     */
    skip?: number
    distinct?: SessionScalarFieldEnum | SessionScalarFieldEnum[]
  }

  /**
   * Session create
   */
  export type SessionCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Session
     */
    select?: SessionSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: SessionInclude<ExtArgs> | null
    /**
     * The data needed to create a Session.
     */
    data: XOR<SessionCreateInput, SessionUncheckedCreateInput>
  }

  /**
   * Session createMany
   */
  export type SessionCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many Sessions.
     */
    data: SessionCreateManyInput | SessionCreateManyInput[]
    skipDuplicates?: boolean
  }

  /**
   * Session update
   */
  export type SessionUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Session
     */
    select?: SessionSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: SessionInclude<ExtArgs> | null
    /**
     * The data needed to update a Session.
     */
    data: XOR<SessionUpdateInput, SessionUncheckedUpdateInput>
    /**
     * Choose, which Session to update.
     */
    where: SessionWhereUniqueInput
  }

  /**
   * Session updateMany
   */
  export type SessionUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update Sessions.
     */
    data: XOR<SessionUpdateManyMutationInput, SessionUncheckedUpdateManyInput>
    /**
     * Filter which Sessions to update
     */
    where?: SessionWhereInput
  }

  /**
   * Session upsert
   */
  export type SessionUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Session
     */
    select?: SessionSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: SessionInclude<ExtArgs> | null
    /**
     * The filter to search for the Session to update in case it exists.
     */
    where: SessionWhereUniqueInput
    /**
     * In case the Session found by the `where` argument doesn't exist, create a new Session with this data.
     */
    create: XOR<SessionCreateInput, SessionUncheckedCreateInput>
    /**
     * In case the Session was found with the provided `where` argument, update it with this data.
     */
    update: XOR<SessionUpdateInput, SessionUncheckedUpdateInput>
  }

  /**
   * Session delete
   */
  export type SessionDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Session
     */
    select?: SessionSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: SessionInclude<ExtArgs> | null
    /**
     * Filter which Session to delete.
     */
    where: SessionWhereUniqueInput
  }

  /**
   * Session deleteMany
   */
  export type SessionDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which Sessions to delete
     */
    where?: SessionWhereInput
  }

  /**
   * Session without action
   */
  export type SessionDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Session
     */
    select?: SessionSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: SessionInclude<ExtArgs> | null
  }


  /**
   * Model Group
   */

  export type AggregateGroup = {
    _count: GroupCountAggregateOutputType | null
    _avg: GroupAvgAggregateOutputType | null
    _sum: GroupSumAggregateOutputType | null
    _min: GroupMinAggregateOutputType | null
    _max: GroupMaxAggregateOutputType | null
  }

  export type GroupAvgAggregateOutputType = {
    numMembros: number | null
    valorContribuicaoMensal: number | null
    taxaPrincipalAplicada: number | null
    reservaTecnicaAplicada: number | null
    cicloAtual: number | null
    totalCiclos: number | null
  }

  export type GroupSumAggregateOutputType = {
    numMembros: number | null
    valorContribuicaoMensal: number | null
    taxaPrincipalAplicada: number | null
    reservaTecnicaAplicada: number | null
    cicloAtual: number | null
    totalCiclos: number | null
  }

  export type GroupMinAggregateOutputType = {
    id: string | null
    nome: string | null
    descricao: string | null
    criadorId: string | null
    numMembros: number | null
    valorContribuicaoMensal: number | null
    taxaPrincipalAplicada: number | null
    reservaTecnicaAplicada: number | null
    periodicidade: string | null
    tipo: string | null
    pais: string | null
    moeda: string | null
    status: string | null
    dataInicio: Date | null
    dataFimPrevista: Date | null
    cicloAtual: number | null
    totalCiclos: number | null
    createdAt: Date | null
    updatedAt: Date | null
  }

  export type GroupMaxAggregateOutputType = {
    id: string | null
    nome: string | null
    descricao: string | null
    criadorId: string | null
    numMembros: number | null
    valorContribuicaoMensal: number | null
    taxaPrincipalAplicada: number | null
    reservaTecnicaAplicada: number | null
    periodicidade: string | null
    tipo: string | null
    pais: string | null
    moeda: string | null
    status: string | null
    dataInicio: Date | null
    dataFimPrevista: Date | null
    cicloAtual: number | null
    totalCiclos: number | null
    createdAt: Date | null
    updatedAt: Date | null
  }

  export type GroupCountAggregateOutputType = {
    id: number
    nome: number
    descricao: number
    criadorId: number
    numMembros: number
    valorContribuicaoMensal: number
    taxaPrincipalAplicada: number
    reservaTecnicaAplicada: number
    periodicidade: number
    tipo: number
    pais: number
    moeda: number
    status: number
    dataInicio: number
    dataFimPrevista: number
    cicloAtual: number
    totalCiclos: number
    createdAt: number
    updatedAt: number
    _all: number
  }


  export type GroupAvgAggregateInputType = {
    numMembros?: true
    valorContribuicaoMensal?: true
    taxaPrincipalAplicada?: true
    reservaTecnicaAplicada?: true
    cicloAtual?: true
    totalCiclos?: true
  }

  export type GroupSumAggregateInputType = {
    numMembros?: true
    valorContribuicaoMensal?: true
    taxaPrincipalAplicada?: true
    reservaTecnicaAplicada?: true
    cicloAtual?: true
    totalCiclos?: true
  }

  export type GroupMinAggregateInputType = {
    id?: true
    nome?: true
    descricao?: true
    criadorId?: true
    numMembros?: true
    valorContribuicaoMensal?: true
    taxaPrincipalAplicada?: true
    reservaTecnicaAplicada?: true
    periodicidade?: true
    tipo?: true
    pais?: true
    moeda?: true
    status?: true
    dataInicio?: true
    dataFimPrevista?: true
    cicloAtual?: true
    totalCiclos?: true
    createdAt?: true
    updatedAt?: true
  }

  export type GroupMaxAggregateInputType = {
    id?: true
    nome?: true
    descricao?: true
    criadorId?: true
    numMembros?: true
    valorContribuicaoMensal?: true
    taxaPrincipalAplicada?: true
    reservaTecnicaAplicada?: true
    periodicidade?: true
    tipo?: true
    pais?: true
    moeda?: true
    status?: true
    dataInicio?: true
    dataFimPrevista?: true
    cicloAtual?: true
    totalCiclos?: true
    createdAt?: true
    updatedAt?: true
  }

  export type GroupCountAggregateInputType = {
    id?: true
    nome?: true
    descricao?: true
    criadorId?: true
    numMembros?: true
    valorContribuicaoMensal?: true
    taxaPrincipalAplicada?: true
    reservaTecnicaAplicada?: true
    periodicidade?: true
    tipo?: true
    pais?: true
    moeda?: true
    status?: true
    dataInicio?: true
    dataFimPrevista?: true
    cicloAtual?: true
    totalCiclos?: true
    createdAt?: true
    updatedAt?: true
    _all?: true
  }

  export type GroupAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which Group to aggregate.
     */
    where?: GroupWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Groups to fetch.
     */
    orderBy?: GroupOrderByWithRelationInput | GroupOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: GroupWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Groups 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` Groups.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned Groups
    **/
    _count?: true | GroupCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to average
    **/
    _avg?: GroupAvgAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to sum
    **/
    _sum?: GroupSumAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: GroupMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: GroupMaxAggregateInputType
  }

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




  export type GroupGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: GroupWhereInput
    orderBy?: GroupOrderByWithAggregationInput | GroupOrderByWithAggregationInput[]
    by: GroupScalarFieldEnum[] | GroupScalarFieldEnum
    having?: GroupScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: GroupCountAggregateInputType | true
    _avg?: GroupAvgAggregateInputType
    _sum?: GroupSumAggregateInputType
    _min?: GroupMinAggregateInputType
    _max?: GroupMaxAggregateInputType
  }

  export type GroupGroupByOutputType = {
    id: string
    nome: string
    descricao: string | null
    criadorId: string
    numMembros: number
    valorContribuicaoMensal: number
    taxaPrincipalAplicada: number
    reservaTecnicaAplicada: number
    periodicidade: string
    tipo: string
    pais: string
    moeda: string
    status: string
    dataInicio: Date | null
    dataFimPrevista: Date | null
    cicloAtual: number
    totalCiclos: number
    createdAt: Date
    updatedAt: Date
    _count: GroupCountAggregateOutputType | null
    _avg: GroupAvgAggregateOutputType | null
    _sum: GroupSumAggregateOutputType | null
    _min: GroupMinAggregateOutputType | null
    _max: GroupMaxAggregateOutputType | null
  }

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


  export type GroupSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    nome?: boolean
    descricao?: boolean
    criadorId?: boolean
    numMembros?: boolean
    valorContribuicaoMensal?: boolean
    taxaPrincipalAplicada?: boolean
    reservaTecnicaAplicada?: boolean
    periodicidade?: boolean
    tipo?: boolean
    pais?: boolean
    moeda?: boolean
    status?: boolean
    dataInicio?: boolean
    dataFimPrevista?: boolean
    cicloAtual?: boolean
    totalCiclos?: boolean
    createdAt?: boolean
    updatedAt?: boolean
    criador?: boolean | UserDefaultArgs<ExtArgs>
    memberships?: boolean | Group$membershipsArgs<ExtArgs>
    monthlyCycles?: boolean | Group$monthlyCyclesArgs<ExtArgs>
    invites?: boolean | Group$invitesArgs<ExtArgs>
    candidaturas?: boolean | Group$candidaturasArgs<ExtArgs>
    _count?: boolean | GroupCountOutputTypeDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["group"]>


  export type GroupSelectScalar = {
    id?: boolean
    nome?: boolean
    descricao?: boolean
    criadorId?: boolean
    numMembros?: boolean
    valorContribuicaoMensal?: boolean
    taxaPrincipalAplicada?: boolean
    reservaTecnicaAplicada?: boolean
    periodicidade?: boolean
    tipo?: boolean
    pais?: boolean
    moeda?: boolean
    status?: boolean
    dataInicio?: boolean
    dataFimPrevista?: boolean
    cicloAtual?: boolean
    totalCiclos?: boolean
    createdAt?: boolean
    updatedAt?: boolean
  }

  export type GroupInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    criador?: boolean | UserDefaultArgs<ExtArgs>
    memberships?: boolean | Group$membershipsArgs<ExtArgs>
    monthlyCycles?: boolean | Group$monthlyCyclesArgs<ExtArgs>
    invites?: boolean | Group$invitesArgs<ExtArgs>
    candidaturas?: boolean | Group$candidaturasArgs<ExtArgs>
    _count?: boolean | GroupCountOutputTypeDefaultArgs<ExtArgs>
  }

  export type $GroupPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "Group"
    objects: {
      criador: Prisma.$UserPayload<ExtArgs>
      memberships: Prisma.$MembershipPayload<ExtArgs>[]
      monthlyCycles: Prisma.$MonthlyCyclePayload<ExtArgs>[]
      invites: Prisma.$InvitePayload<ExtArgs>[]
      candidaturas: Prisma.$GroupApplicationPayload<ExtArgs>[]
    }
    scalars: $Extensions.GetPayloadResult<{
      id: string
      nome: string
      descricao: string | null
      criadorId: string
      numMembros: number
      valorContribuicaoMensal: number
      taxaPrincipalAplicada: number
      reservaTecnicaAplicada: number
      periodicidade: string
      tipo: string
      pais: string
      moeda: string
      status: string
      dataInicio: Date | null
      dataFimPrevista: Date | null
      cicloAtual: number
      totalCiclos: number
      createdAt: Date
      updatedAt: Date
    }, ExtArgs["result"]["group"]>
    composites: {}
  }

  type GroupGetPayload<S extends boolean | null | undefined | GroupDefaultArgs> = $Result.GetResult<Prisma.$GroupPayload, S>

  type GroupCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = 
    Omit<GroupFindManyArgs, 'select' | 'include' | 'distinct'> & {
      select?: GroupCountAggregateInputType | true
    }

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

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

    /**
     * Find the first Group 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 {GroupFindFirstArgs} args - Arguments to find a Group
     * @example
     * // Get one Group
     * const group = await prisma.group.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends GroupFindFirstArgs>(args?: SelectSubset<T, GroupFindFirstArgs<ExtArgs>>): Prisma__GroupClient<$Result.GetResult<Prisma.$GroupPayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>

    /**
     * Find the first Group 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 {GroupFindFirstOrThrowArgs} args - Arguments to find a Group
     * @example
     * // Get one Group
     * const group = await prisma.group.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends GroupFindFirstOrThrowArgs>(args?: SelectSubset<T, GroupFindFirstOrThrowArgs<ExtArgs>>): Prisma__GroupClient<$Result.GetResult<Prisma.$GroupPayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>

    /**
     * Find zero or more Groups 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 {GroupFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all Groups
     * const groups = await prisma.group.findMany()
     * 
     * // Get first 10 Groups
     * const groups = await prisma.group.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const groupWithIdOnly = await prisma.group.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends GroupFindManyArgs>(args?: SelectSubset<T, GroupFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$GroupPayload<ExtArgs>, T, "findMany">>

    /**
     * Create a Group.
     * @param {GroupCreateArgs} args - Arguments to create a Group.
     * @example
     * // Create one Group
     * const Group = await prisma.group.create({
     *   data: {
     *     // ... data to create a Group
     *   }
     * })
     * 
     */
    create<T extends GroupCreateArgs>(args: SelectSubset<T, GroupCreateArgs<ExtArgs>>): Prisma__GroupClient<$Result.GetResult<Prisma.$GroupPayload<ExtArgs>, T, "create">, never, ExtArgs>

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

    /**
     * Delete a Group.
     * @param {GroupDeleteArgs} args - Arguments to delete one Group.
     * @example
     * // Delete one Group
     * const Group = await prisma.group.delete({
     *   where: {
     *     // ... filter to delete one Group
     *   }
     * })
     * 
     */
    delete<T extends GroupDeleteArgs>(args: SelectSubset<T, GroupDeleteArgs<ExtArgs>>): Prisma__GroupClient<$Result.GetResult<Prisma.$GroupPayload<ExtArgs>, T, "delete">, never, ExtArgs>

    /**
     * Update one Group.
     * @param {GroupUpdateArgs} args - Arguments to update one Group.
     * @example
     * // Update one Group
     * const group = await prisma.group.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends GroupUpdateArgs>(args: SelectSubset<T, GroupUpdateArgs<ExtArgs>>): Prisma__GroupClient<$Result.GetResult<Prisma.$GroupPayload<ExtArgs>, T, "update">, never, ExtArgs>

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

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

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


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

    /**
     * Allows you to perform aggregations operations on a Group.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {GroupAggregateArgs} 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 GroupAggregateArgs>(args: Subset<T, GroupAggregateArgs>): Prisma.PrismaPromise<GetGroupAggregateType<T>>

    /**
     * Group by Group.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {GroupGroupByArgs} 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 GroupGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: GroupGroupByArgs['orderBy'] }
        : { orderBy?: GroupGroupByArgs['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, GroupGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetGroupGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the Group model
   */
  readonly fields: GroupFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for Group.
   * 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__GroupClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
    readonly [Symbol.toStringTag]: "PrismaPromise"
    criador<T extends UserDefaultArgs<ExtArgs> = {}>(args?: Subset<T, UserDefaultArgs<ExtArgs>>): Prisma__UserClient<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "findUniqueOrThrow"> | Null, Null, ExtArgs>
    memberships<T extends Group$membershipsArgs<ExtArgs> = {}>(args?: Subset<T, Group$membershipsArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$MembershipPayload<ExtArgs>, T, "findMany"> | Null>
    monthlyCycles<T extends Group$monthlyCyclesArgs<ExtArgs> = {}>(args?: Subset<T, Group$monthlyCyclesArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$MonthlyCyclePayload<ExtArgs>, T, "findMany"> | Null>
    invites<T extends Group$invitesArgs<ExtArgs> = {}>(args?: Subset<T, Group$invitesArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$InvitePayload<ExtArgs>, T, "findMany"> | Null>
    candidaturas<T extends Group$candidaturasArgs<ExtArgs> = {}>(args?: Subset<T, Group$candidaturasArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$GroupApplicationPayload<ExtArgs>, T, "findMany"> | 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 Group model
   */ 
  interface GroupFieldRefs {
    readonly id: FieldRef<"Group", 'String'>
    readonly nome: FieldRef<"Group", 'String'>
    readonly descricao: FieldRef<"Group", 'String'>
    readonly criadorId: FieldRef<"Group", 'String'>
    readonly numMembros: FieldRef<"Group", 'Int'>
    readonly valorContribuicaoMensal: FieldRef<"Group", 'Float'>
    readonly taxaPrincipalAplicada: FieldRef<"Group", 'Float'>
    readonly reservaTecnicaAplicada: FieldRef<"Group", 'Float'>
    readonly periodicidade: FieldRef<"Group", 'String'>
    readonly tipo: FieldRef<"Group", 'String'>
    readonly pais: FieldRef<"Group", 'String'>
    readonly moeda: FieldRef<"Group", 'String'>
    readonly status: FieldRef<"Group", 'String'>
    readonly dataInicio: FieldRef<"Group", 'DateTime'>
    readonly dataFimPrevista: FieldRef<"Group", 'DateTime'>
    readonly cicloAtual: FieldRef<"Group", 'Int'>
    readonly totalCiclos: FieldRef<"Group", 'Int'>
    readonly createdAt: FieldRef<"Group", 'DateTime'>
    readonly updatedAt: FieldRef<"Group", 'DateTime'>
  }
    

  // Custom InputTypes
  /**
   * Group findUnique
   */
  export type GroupFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Group
     */
    select?: GroupSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GroupInclude<ExtArgs> | null
    /**
     * Filter, which Group to fetch.
     */
    where: GroupWhereUniqueInput
  }

  /**
   * Group findUniqueOrThrow
   */
  export type GroupFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Group
     */
    select?: GroupSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GroupInclude<ExtArgs> | null
    /**
     * Filter, which Group to fetch.
     */
    where: GroupWhereUniqueInput
  }

  /**
   * Group findFirst
   */
  export type GroupFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Group
     */
    select?: GroupSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GroupInclude<ExtArgs> | null
    /**
     * Filter, which Group to fetch.
     */
    where?: GroupWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Groups to fetch.
     */
    orderBy?: GroupOrderByWithRelationInput | GroupOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for Groups.
     */
    cursor?: GroupWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Groups 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` Groups.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of Groups.
     */
    distinct?: GroupScalarFieldEnum | GroupScalarFieldEnum[]
  }

  /**
   * Group findFirstOrThrow
   */
  export type GroupFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Group
     */
    select?: GroupSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GroupInclude<ExtArgs> | null
    /**
     * Filter, which Group to fetch.
     */
    where?: GroupWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Groups to fetch.
     */
    orderBy?: GroupOrderByWithRelationInput | GroupOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for Groups.
     */
    cursor?: GroupWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Groups 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` Groups.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of Groups.
     */
    distinct?: GroupScalarFieldEnum | GroupScalarFieldEnum[]
  }

  /**
   * Group findMany
   */
  export type GroupFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Group
     */
    select?: GroupSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GroupInclude<ExtArgs> | null
    /**
     * Filter, which Groups to fetch.
     */
    where?: GroupWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Groups to fetch.
     */
    orderBy?: GroupOrderByWithRelationInput | GroupOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing Groups.
     */
    cursor?: GroupWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Groups 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` Groups.
     */
    skip?: number
    distinct?: GroupScalarFieldEnum | GroupScalarFieldEnum[]
  }

  /**
   * Group create
   */
  export type GroupCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Group
     */
    select?: GroupSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GroupInclude<ExtArgs> | null
    /**
     * The data needed to create a Group.
     */
    data: XOR<GroupCreateInput, GroupUncheckedCreateInput>
  }

  /**
   * Group createMany
   */
  export type GroupCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many Groups.
     */
    data: GroupCreateManyInput | GroupCreateManyInput[]
    skipDuplicates?: boolean
  }

  /**
   * Group update
   */
  export type GroupUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Group
     */
    select?: GroupSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GroupInclude<ExtArgs> | null
    /**
     * The data needed to update a Group.
     */
    data: XOR<GroupUpdateInput, GroupUncheckedUpdateInput>
    /**
     * Choose, which Group to update.
     */
    where: GroupWhereUniqueInput
  }

  /**
   * Group updateMany
   */
  export type GroupUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update Groups.
     */
    data: XOR<GroupUpdateManyMutationInput, GroupUncheckedUpdateManyInput>
    /**
     * Filter which Groups to update
     */
    where?: GroupWhereInput
  }

  /**
   * Group upsert
   */
  export type GroupUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Group
     */
    select?: GroupSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GroupInclude<ExtArgs> | null
    /**
     * The filter to search for the Group to update in case it exists.
     */
    where: GroupWhereUniqueInput
    /**
     * In case the Group found by the `where` argument doesn't exist, create a new Group with this data.
     */
    create: XOR<GroupCreateInput, GroupUncheckedCreateInput>
    /**
     * In case the Group was found with the provided `where` argument, update it with this data.
     */
    update: XOR<GroupUpdateInput, GroupUncheckedUpdateInput>
  }

  /**
   * Group delete
   */
  export type GroupDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Group
     */
    select?: GroupSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GroupInclude<ExtArgs> | null
    /**
     * Filter which Group to delete.
     */
    where: GroupWhereUniqueInput
  }

  /**
   * Group deleteMany
   */
  export type GroupDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which Groups to delete
     */
    where?: GroupWhereInput
  }

  /**
   * Group.memberships
   */
  export type Group$membershipsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Membership
     */
    select?: MembershipSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: MembershipInclude<ExtArgs> | null
    where?: MembershipWhereInput
    orderBy?: MembershipOrderByWithRelationInput | MembershipOrderByWithRelationInput[]
    cursor?: MembershipWhereUniqueInput
    take?: number
    skip?: number
    distinct?: MembershipScalarFieldEnum | MembershipScalarFieldEnum[]
  }

  /**
   * Group.monthlyCycles
   */
  export type Group$monthlyCyclesArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the MonthlyCycle
     */
    select?: MonthlyCycleSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: MonthlyCycleInclude<ExtArgs> | null
    where?: MonthlyCycleWhereInput
    orderBy?: MonthlyCycleOrderByWithRelationInput | MonthlyCycleOrderByWithRelationInput[]
    cursor?: MonthlyCycleWhereUniqueInput
    take?: number
    skip?: number
    distinct?: MonthlyCycleScalarFieldEnum | MonthlyCycleScalarFieldEnum[]
  }

  /**
   * Group.invites
   */
  export type Group$invitesArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Invite
     */
    select?: InviteSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: InviteInclude<ExtArgs> | null
    where?: InviteWhereInput
    orderBy?: InviteOrderByWithRelationInput | InviteOrderByWithRelationInput[]
    cursor?: InviteWhereUniqueInput
    take?: number
    skip?: number
    distinct?: InviteScalarFieldEnum | InviteScalarFieldEnum[]
  }

  /**
   * Group.candidaturas
   */
  export type Group$candidaturasArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the GroupApplication
     */
    select?: GroupApplicationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GroupApplicationInclude<ExtArgs> | null
    where?: GroupApplicationWhereInput
    orderBy?: GroupApplicationOrderByWithRelationInput | GroupApplicationOrderByWithRelationInput[]
    cursor?: GroupApplicationWhereUniqueInput
    take?: number
    skip?: number
    distinct?: GroupApplicationScalarFieldEnum | GroupApplicationScalarFieldEnum[]
  }

  /**
   * Group without action
   */
  export type GroupDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Group
     */
    select?: GroupSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GroupInclude<ExtArgs> | null
  }


  /**
   * Model GroupApplication
   */

  export type AggregateGroupApplication = {
    _count: GroupApplicationCountAggregateOutputType | null
    _min: GroupApplicationMinAggregateOutputType | null
    _max: GroupApplicationMaxAggregateOutputType | null
  }

  export type GroupApplicationMinAggregateOutputType = {
    id: string | null
    groupId: string | null
    userId: string | null
    mensagem: string | null
    status: string | null
    createdAt: Date | null
  }

  export type GroupApplicationMaxAggregateOutputType = {
    id: string | null
    groupId: string | null
    userId: string | null
    mensagem: string | null
    status: string | null
    createdAt: Date | null
  }

  export type GroupApplicationCountAggregateOutputType = {
    id: number
    groupId: number
    userId: number
    mensagem: number
    status: number
    createdAt: number
    _all: number
  }


  export type GroupApplicationMinAggregateInputType = {
    id?: true
    groupId?: true
    userId?: true
    mensagem?: true
    status?: true
    createdAt?: true
  }

  export type GroupApplicationMaxAggregateInputType = {
    id?: true
    groupId?: true
    userId?: true
    mensagem?: true
    status?: true
    createdAt?: true
  }

  export type GroupApplicationCountAggregateInputType = {
    id?: true
    groupId?: true
    userId?: true
    mensagem?: true
    status?: true
    createdAt?: true
    _all?: true
  }

  export type GroupApplicationAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which GroupApplication to aggregate.
     */
    where?: GroupApplicationWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of GroupApplications to fetch.
     */
    orderBy?: GroupApplicationOrderByWithRelationInput | GroupApplicationOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: GroupApplicationWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` GroupApplications 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` GroupApplications.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned GroupApplications
    **/
    _count?: true | GroupApplicationCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: GroupApplicationMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: GroupApplicationMaxAggregateInputType
  }

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




  export type GroupApplicationGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: GroupApplicationWhereInput
    orderBy?: GroupApplicationOrderByWithAggregationInput | GroupApplicationOrderByWithAggregationInput[]
    by: GroupApplicationScalarFieldEnum[] | GroupApplicationScalarFieldEnum
    having?: GroupApplicationScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: GroupApplicationCountAggregateInputType | true
    _min?: GroupApplicationMinAggregateInputType
    _max?: GroupApplicationMaxAggregateInputType
  }

  export type GroupApplicationGroupByOutputType = {
    id: string
    groupId: string
    userId: string
    mensagem: string | null
    status: string
    createdAt: Date
    _count: GroupApplicationCountAggregateOutputType | null
    _min: GroupApplicationMinAggregateOutputType | null
    _max: GroupApplicationMaxAggregateOutputType | null
  }

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


  export type GroupApplicationSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    groupId?: boolean
    userId?: boolean
    mensagem?: boolean
    status?: boolean
    createdAt?: boolean
    group?: boolean | GroupDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["groupApplication"]>


  export type GroupApplicationSelectScalar = {
    id?: boolean
    groupId?: boolean
    userId?: boolean
    mensagem?: boolean
    status?: boolean
    createdAt?: boolean
  }

  export type GroupApplicationInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    group?: boolean | GroupDefaultArgs<ExtArgs>
  }

  export type $GroupApplicationPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "GroupApplication"
    objects: {
      group: Prisma.$GroupPayload<ExtArgs>
    }
    scalars: $Extensions.GetPayloadResult<{
      id: string
      groupId: string
      userId: string
      mensagem: string | null
      status: string
      createdAt: Date
    }, ExtArgs["result"]["groupApplication"]>
    composites: {}
  }

  type GroupApplicationGetPayload<S extends boolean | null | undefined | GroupApplicationDefaultArgs> = $Result.GetResult<Prisma.$GroupApplicationPayload, S>

  type GroupApplicationCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = 
    Omit<GroupApplicationFindManyArgs, 'select' | 'include' | 'distinct'> & {
      select?: GroupApplicationCountAggregateInputType | true
    }

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

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

    /**
     * Find the first GroupApplication 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 {GroupApplicationFindFirstArgs} args - Arguments to find a GroupApplication
     * @example
     * // Get one GroupApplication
     * const groupApplication = await prisma.groupApplication.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends GroupApplicationFindFirstArgs>(args?: SelectSubset<T, GroupApplicationFindFirstArgs<ExtArgs>>): Prisma__GroupApplicationClient<$Result.GetResult<Prisma.$GroupApplicationPayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>

    /**
     * Find the first GroupApplication 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 {GroupApplicationFindFirstOrThrowArgs} args - Arguments to find a GroupApplication
     * @example
     * // Get one GroupApplication
     * const groupApplication = await prisma.groupApplication.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends GroupApplicationFindFirstOrThrowArgs>(args?: SelectSubset<T, GroupApplicationFindFirstOrThrowArgs<ExtArgs>>): Prisma__GroupApplicationClient<$Result.GetResult<Prisma.$GroupApplicationPayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>

    /**
     * Find zero or more GroupApplications 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 {GroupApplicationFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all GroupApplications
     * const groupApplications = await prisma.groupApplication.findMany()
     * 
     * // Get first 10 GroupApplications
     * const groupApplications = await prisma.groupApplication.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const groupApplicationWithIdOnly = await prisma.groupApplication.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends GroupApplicationFindManyArgs>(args?: SelectSubset<T, GroupApplicationFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$GroupApplicationPayload<ExtArgs>, T, "findMany">>

    /**
     * Create a GroupApplication.
     * @param {GroupApplicationCreateArgs} args - Arguments to create a GroupApplication.
     * @example
     * // Create one GroupApplication
     * const GroupApplication = await prisma.groupApplication.create({
     *   data: {
     *     // ... data to create a GroupApplication
     *   }
     * })
     * 
     */
    create<T extends GroupApplicationCreateArgs>(args: SelectSubset<T, GroupApplicationCreateArgs<ExtArgs>>): Prisma__GroupApplicationClient<$Result.GetResult<Prisma.$GroupApplicationPayload<ExtArgs>, T, "create">, never, ExtArgs>

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

    /**
     * Delete a GroupApplication.
     * @param {GroupApplicationDeleteArgs} args - Arguments to delete one GroupApplication.
     * @example
     * // Delete one GroupApplication
     * const GroupApplication = await prisma.groupApplication.delete({
     *   where: {
     *     // ... filter to delete one GroupApplication
     *   }
     * })
     * 
     */
    delete<T extends GroupApplicationDeleteArgs>(args: SelectSubset<T, GroupApplicationDeleteArgs<ExtArgs>>): Prisma__GroupApplicationClient<$Result.GetResult<Prisma.$GroupApplicationPayload<ExtArgs>, T, "delete">, never, ExtArgs>

    /**
     * Update one GroupApplication.
     * @param {GroupApplicationUpdateArgs} args - Arguments to update one GroupApplication.
     * @example
     * // Update one GroupApplication
     * const groupApplication = await prisma.groupApplication.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends GroupApplicationUpdateArgs>(args: SelectSubset<T, GroupApplicationUpdateArgs<ExtArgs>>): Prisma__GroupApplicationClient<$Result.GetResult<Prisma.$GroupApplicationPayload<ExtArgs>, T, "update">, never, ExtArgs>

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

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

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


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

    /**
     * Allows you to perform aggregations operations on a GroupApplication.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {GroupApplicationAggregateArgs} 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 GroupApplicationAggregateArgs>(args: Subset<T, GroupApplicationAggregateArgs>): Prisma.PrismaPromise<GetGroupApplicationAggregateType<T>>

    /**
     * Group by GroupApplication.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {GroupApplicationGroupByArgs} 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 GroupApplicationGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: GroupApplicationGroupByArgs['orderBy'] }
        : { orderBy?: GroupApplicationGroupByArgs['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, GroupApplicationGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetGroupApplicationGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the GroupApplication model
   */
  readonly fields: GroupApplicationFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for GroupApplication.
   * 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__GroupApplicationClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
    readonly [Symbol.toStringTag]: "PrismaPromise"
    group<T extends GroupDefaultArgs<ExtArgs> = {}>(args?: Subset<T, GroupDefaultArgs<ExtArgs>>): Prisma__GroupClient<$Result.GetResult<Prisma.$GroupPayload<ExtArgs>, T, "findUniqueOrThrow"> | Null, Null, ExtArgs>
    /**
     * 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 GroupApplication model
   */ 
  interface GroupApplicationFieldRefs {
    readonly id: FieldRef<"GroupApplication", 'String'>
    readonly groupId: FieldRef<"GroupApplication", 'String'>
    readonly userId: FieldRef<"GroupApplication", 'String'>
    readonly mensagem: FieldRef<"GroupApplication", 'String'>
    readonly status: FieldRef<"GroupApplication", 'String'>
    readonly createdAt: FieldRef<"GroupApplication", 'DateTime'>
  }
    

  // Custom InputTypes
  /**
   * GroupApplication findUnique
   */
  export type GroupApplicationFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the GroupApplication
     */
    select?: GroupApplicationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GroupApplicationInclude<ExtArgs> | null
    /**
     * Filter, which GroupApplication to fetch.
     */
    where: GroupApplicationWhereUniqueInput
  }

  /**
   * GroupApplication findUniqueOrThrow
   */
  export type GroupApplicationFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the GroupApplication
     */
    select?: GroupApplicationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GroupApplicationInclude<ExtArgs> | null
    /**
     * Filter, which GroupApplication to fetch.
     */
    where: GroupApplicationWhereUniqueInput
  }

  /**
   * GroupApplication findFirst
   */
  export type GroupApplicationFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the GroupApplication
     */
    select?: GroupApplicationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GroupApplicationInclude<ExtArgs> | null
    /**
     * Filter, which GroupApplication to fetch.
     */
    where?: GroupApplicationWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of GroupApplications to fetch.
     */
    orderBy?: GroupApplicationOrderByWithRelationInput | GroupApplicationOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for GroupApplications.
     */
    cursor?: GroupApplicationWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` GroupApplications 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` GroupApplications.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of GroupApplications.
     */
    distinct?: GroupApplicationScalarFieldEnum | GroupApplicationScalarFieldEnum[]
  }

  /**
   * GroupApplication findFirstOrThrow
   */
  export type GroupApplicationFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the GroupApplication
     */
    select?: GroupApplicationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GroupApplicationInclude<ExtArgs> | null
    /**
     * Filter, which GroupApplication to fetch.
     */
    where?: GroupApplicationWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of GroupApplications to fetch.
     */
    orderBy?: GroupApplicationOrderByWithRelationInput | GroupApplicationOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for GroupApplications.
     */
    cursor?: GroupApplicationWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` GroupApplications 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` GroupApplications.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of GroupApplications.
     */
    distinct?: GroupApplicationScalarFieldEnum | GroupApplicationScalarFieldEnum[]
  }

  /**
   * GroupApplication findMany
   */
  export type GroupApplicationFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the GroupApplication
     */
    select?: GroupApplicationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GroupApplicationInclude<ExtArgs> | null
    /**
     * Filter, which GroupApplications to fetch.
     */
    where?: GroupApplicationWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of GroupApplications to fetch.
     */
    orderBy?: GroupApplicationOrderByWithRelationInput | GroupApplicationOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing GroupApplications.
     */
    cursor?: GroupApplicationWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` GroupApplications 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` GroupApplications.
     */
    skip?: number
    distinct?: GroupApplicationScalarFieldEnum | GroupApplicationScalarFieldEnum[]
  }

  /**
   * GroupApplication create
   */
  export type GroupApplicationCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the GroupApplication
     */
    select?: GroupApplicationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GroupApplicationInclude<ExtArgs> | null
    /**
     * The data needed to create a GroupApplication.
     */
    data: XOR<GroupApplicationCreateInput, GroupApplicationUncheckedCreateInput>
  }

  /**
   * GroupApplication createMany
   */
  export type GroupApplicationCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many GroupApplications.
     */
    data: GroupApplicationCreateManyInput | GroupApplicationCreateManyInput[]
    skipDuplicates?: boolean
  }

  /**
   * GroupApplication update
   */
  export type GroupApplicationUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the GroupApplication
     */
    select?: GroupApplicationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GroupApplicationInclude<ExtArgs> | null
    /**
     * The data needed to update a GroupApplication.
     */
    data: XOR<GroupApplicationUpdateInput, GroupApplicationUncheckedUpdateInput>
    /**
     * Choose, which GroupApplication to update.
     */
    where: GroupApplicationWhereUniqueInput
  }

  /**
   * GroupApplication updateMany
   */
  export type GroupApplicationUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update GroupApplications.
     */
    data: XOR<GroupApplicationUpdateManyMutationInput, GroupApplicationUncheckedUpdateManyInput>
    /**
     * Filter which GroupApplications to update
     */
    where?: GroupApplicationWhereInput
  }

  /**
   * GroupApplication upsert
   */
  export type GroupApplicationUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the GroupApplication
     */
    select?: GroupApplicationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GroupApplicationInclude<ExtArgs> | null
    /**
     * The filter to search for the GroupApplication to update in case it exists.
     */
    where: GroupApplicationWhereUniqueInput
    /**
     * In case the GroupApplication found by the `where` argument doesn't exist, create a new GroupApplication with this data.
     */
    create: XOR<GroupApplicationCreateInput, GroupApplicationUncheckedCreateInput>
    /**
     * In case the GroupApplication was found with the provided `where` argument, update it with this data.
     */
    update: XOR<GroupApplicationUpdateInput, GroupApplicationUncheckedUpdateInput>
  }

  /**
   * GroupApplication delete
   */
  export type GroupApplicationDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the GroupApplication
     */
    select?: GroupApplicationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GroupApplicationInclude<ExtArgs> | null
    /**
     * Filter which GroupApplication to delete.
     */
    where: GroupApplicationWhereUniqueInput
  }

  /**
   * GroupApplication deleteMany
   */
  export type GroupApplicationDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which GroupApplications to delete
     */
    where?: GroupApplicationWhereInput
  }

  /**
   * GroupApplication without action
   */
  export type GroupApplicationDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the GroupApplication
     */
    select?: GroupApplicationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: GroupApplicationInclude<ExtArgs> | null
  }


  /**
   * Model Membership
   */

  export type AggregateMembership = {
    _count: MembershipCountAggregateOutputType | null
    _avg: MembershipAvgAggregateOutputType | null
    _sum: MembershipSumAggregateOutputType | null
    _min: MembershipMinAggregateOutputType | null
    _max: MembershipMaxAggregateOutputType | null
  }

  export type MembershipAvgAggregateOutputType = {
    posicaoRotacao: number | null
  }

  export type MembershipSumAggregateOutputType = {
    posicaoRotacao: number | null
  }

  export type MembershipMinAggregateOutputType = {
    id: string | null
    userId: string | null
    groupId: string | null
    posicaoRotacao: number | null
    status: string | null
    necessidadeUrgente: boolean | null
    dataJuncao: Date | null
    mesRecepcaoPrevisto: string | null
  }

  export type MembershipMaxAggregateOutputType = {
    id: string | null
    userId: string | null
    groupId: string | null
    posicaoRotacao: number | null
    status: string | null
    necessidadeUrgente: boolean | null
    dataJuncao: Date | null
    mesRecepcaoPrevisto: string | null
  }

  export type MembershipCountAggregateOutputType = {
    id: number
    userId: number
    groupId: number
    posicaoRotacao: number
    status: number
    necessidadeUrgente: number
    dataJuncao: number
    mesRecepcaoPrevisto: number
    _all: number
  }


  export type MembershipAvgAggregateInputType = {
    posicaoRotacao?: true
  }

  export type MembershipSumAggregateInputType = {
    posicaoRotacao?: true
  }

  export type MembershipMinAggregateInputType = {
    id?: true
    userId?: true
    groupId?: true
    posicaoRotacao?: true
    status?: true
    necessidadeUrgente?: true
    dataJuncao?: true
    mesRecepcaoPrevisto?: true
  }

  export type MembershipMaxAggregateInputType = {
    id?: true
    userId?: true
    groupId?: true
    posicaoRotacao?: true
    status?: true
    necessidadeUrgente?: true
    dataJuncao?: true
    mesRecepcaoPrevisto?: true
  }

  export type MembershipCountAggregateInputType = {
    id?: true
    userId?: true
    groupId?: true
    posicaoRotacao?: true
    status?: true
    necessidadeUrgente?: true
    dataJuncao?: true
    mesRecepcaoPrevisto?: true
    _all?: true
  }

  export type MembershipAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which Membership to aggregate.
     */
    where?: MembershipWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Memberships to fetch.
     */
    orderBy?: MembershipOrderByWithRelationInput | MembershipOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: MembershipWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Memberships 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` Memberships.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned Memberships
    **/
    _count?: true | MembershipCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to average
    **/
    _avg?: MembershipAvgAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to sum
    **/
    _sum?: MembershipSumAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: MembershipMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: MembershipMaxAggregateInputType
  }

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




  export type MembershipGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: MembershipWhereInput
    orderBy?: MembershipOrderByWithAggregationInput | MembershipOrderByWithAggregationInput[]
    by: MembershipScalarFieldEnum[] | MembershipScalarFieldEnum
    having?: MembershipScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: MembershipCountAggregateInputType | true
    _avg?: MembershipAvgAggregateInputType
    _sum?: MembershipSumAggregateInputType
    _min?: MembershipMinAggregateInputType
    _max?: MembershipMaxAggregateInputType
  }

  export type MembershipGroupByOutputType = {
    id: string
    userId: string
    groupId: string
    posicaoRotacao: number | null
    status: string
    necessidadeUrgente: boolean
    dataJuncao: Date
    mesRecepcaoPrevisto: string | null
    _count: MembershipCountAggregateOutputType | null
    _avg: MembershipAvgAggregateOutputType | null
    _sum: MembershipSumAggregateOutputType | null
    _min: MembershipMinAggregateOutputType | null
    _max: MembershipMaxAggregateOutputType | null
  }

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


  export type MembershipSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    userId?: boolean
    groupId?: boolean
    posicaoRotacao?: boolean
    status?: boolean
    necessidadeUrgente?: boolean
    dataJuncao?: boolean
    mesRecepcaoPrevisto?: boolean
    user?: boolean | UserDefaultArgs<ExtArgs>
    group?: boolean | GroupDefaultArgs<ExtArgs>
    monthlyCyclesBeneficiario?: boolean | Membership$monthlyCyclesBeneficiarioArgs<ExtArgs>
    contribuicoes?: boolean | Membership$contribuicoesArgs<ExtArgs>
    _count?: boolean | MembershipCountOutputTypeDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["membership"]>


  export type MembershipSelectScalar = {
    id?: boolean
    userId?: boolean
    groupId?: boolean
    posicaoRotacao?: boolean
    status?: boolean
    necessidadeUrgente?: boolean
    dataJuncao?: boolean
    mesRecepcaoPrevisto?: boolean
  }

  export type MembershipInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    user?: boolean | UserDefaultArgs<ExtArgs>
    group?: boolean | GroupDefaultArgs<ExtArgs>
    monthlyCyclesBeneficiario?: boolean | Membership$monthlyCyclesBeneficiarioArgs<ExtArgs>
    contribuicoes?: boolean | Membership$contribuicoesArgs<ExtArgs>
    _count?: boolean | MembershipCountOutputTypeDefaultArgs<ExtArgs>
  }

  export type $MembershipPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "Membership"
    objects: {
      user: Prisma.$UserPayload<ExtArgs>
      group: Prisma.$GroupPayload<ExtArgs>
      monthlyCyclesBeneficiario: Prisma.$MonthlyCyclePayload<ExtArgs>[]
      contribuicoes: Prisma.$ContributionPayload<ExtArgs>[]
    }
    scalars: $Extensions.GetPayloadResult<{
      id: string
      userId: string
      groupId: string
      posicaoRotacao: number | null
      status: string
      necessidadeUrgente: boolean
      dataJuncao: Date
      mesRecepcaoPrevisto: string | null
    }, ExtArgs["result"]["membership"]>
    composites: {}
  }

  type MembershipGetPayload<S extends boolean | null | undefined | MembershipDefaultArgs> = $Result.GetResult<Prisma.$MembershipPayload, S>

  type MembershipCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = 
    Omit<MembershipFindManyArgs, 'select' | 'include' | 'distinct'> & {
      select?: MembershipCountAggregateInputType | true
    }

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

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

    /**
     * Find the first Membership 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 {MembershipFindFirstArgs} args - Arguments to find a Membership
     * @example
     * // Get one Membership
     * const membership = await prisma.membership.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends MembershipFindFirstArgs>(args?: SelectSubset<T, MembershipFindFirstArgs<ExtArgs>>): Prisma__MembershipClient<$Result.GetResult<Prisma.$MembershipPayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>

    /**
     * Find the first Membership 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 {MembershipFindFirstOrThrowArgs} args - Arguments to find a Membership
     * @example
     * // Get one Membership
     * const membership = await prisma.membership.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends MembershipFindFirstOrThrowArgs>(args?: SelectSubset<T, MembershipFindFirstOrThrowArgs<ExtArgs>>): Prisma__MembershipClient<$Result.GetResult<Prisma.$MembershipPayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>

    /**
     * Find zero or more Memberships 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 {MembershipFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all Memberships
     * const memberships = await prisma.membership.findMany()
     * 
     * // Get first 10 Memberships
     * const memberships = await prisma.membership.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const membershipWithIdOnly = await prisma.membership.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends MembershipFindManyArgs>(args?: SelectSubset<T, MembershipFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$MembershipPayload<ExtArgs>, T, "findMany">>

    /**
     * Create a Membership.
     * @param {MembershipCreateArgs} args - Arguments to create a Membership.
     * @example
     * // Create one Membership
     * const Membership = await prisma.membership.create({
     *   data: {
     *     // ... data to create a Membership
     *   }
     * })
     * 
     */
    create<T extends MembershipCreateArgs>(args: SelectSubset<T, MembershipCreateArgs<ExtArgs>>): Prisma__MembershipClient<$Result.GetResult<Prisma.$MembershipPayload<ExtArgs>, T, "create">, never, ExtArgs>

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

    /**
     * Delete a Membership.
     * @param {MembershipDeleteArgs} args - Arguments to delete one Membership.
     * @example
     * // Delete one Membership
     * const Membership = await prisma.membership.delete({
     *   where: {
     *     // ... filter to delete one Membership
     *   }
     * })
     * 
     */
    delete<T extends MembershipDeleteArgs>(args: SelectSubset<T, MembershipDeleteArgs<ExtArgs>>): Prisma__MembershipClient<$Result.GetResult<Prisma.$MembershipPayload<ExtArgs>, T, "delete">, never, ExtArgs>

    /**
     * Update one Membership.
     * @param {MembershipUpdateArgs} args - Arguments to update one Membership.
     * @example
     * // Update one Membership
     * const membership = await prisma.membership.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends MembershipUpdateArgs>(args: SelectSubset<T, MembershipUpdateArgs<ExtArgs>>): Prisma__MembershipClient<$Result.GetResult<Prisma.$MembershipPayload<ExtArgs>, T, "update">, never, ExtArgs>

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

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

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


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

    /**
     * Allows you to perform aggregations operations on a Membership.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {MembershipAggregateArgs} 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 MembershipAggregateArgs>(args: Subset<T, MembershipAggregateArgs>): Prisma.PrismaPromise<GetMembershipAggregateType<T>>

    /**
     * Group by Membership.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {MembershipGroupByArgs} 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 MembershipGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: MembershipGroupByArgs['orderBy'] }
        : { orderBy?: MembershipGroupByArgs['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, MembershipGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetMembershipGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the Membership model
   */
  readonly fields: MembershipFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for Membership.
   * 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__MembershipClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> 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"> | Null, Null, ExtArgs>
    group<T extends GroupDefaultArgs<ExtArgs> = {}>(args?: Subset<T, GroupDefaultArgs<ExtArgs>>): Prisma__GroupClient<$Result.GetResult<Prisma.$GroupPayload<ExtArgs>, T, "findUniqueOrThrow"> | Null, Null, ExtArgs>
    monthlyCyclesBeneficiario<T extends Membership$monthlyCyclesBeneficiarioArgs<ExtArgs> = {}>(args?: Subset<T, Membership$monthlyCyclesBeneficiarioArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$MonthlyCyclePayload<ExtArgs>, T, "findMany"> | Null>
    contribuicoes<T extends Membership$contribuicoesArgs<ExtArgs> = {}>(args?: Subset<T, Membership$contribuicoesArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$ContributionPayload<ExtArgs>, T, "findMany"> | 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 Membership model
   */ 
  interface MembershipFieldRefs {
    readonly id: FieldRef<"Membership", 'String'>
    readonly userId: FieldRef<"Membership", 'String'>
    readonly groupId: FieldRef<"Membership", 'String'>
    readonly posicaoRotacao: FieldRef<"Membership", 'Int'>
    readonly status: FieldRef<"Membership", 'String'>
    readonly necessidadeUrgente: FieldRef<"Membership", 'Boolean'>
    readonly dataJuncao: FieldRef<"Membership", 'DateTime'>
    readonly mesRecepcaoPrevisto: FieldRef<"Membership", 'String'>
  }
    

  // Custom InputTypes
  /**
   * Membership findUnique
   */
  export type MembershipFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Membership
     */
    select?: MembershipSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: MembershipInclude<ExtArgs> | null
    /**
     * Filter, which Membership to fetch.
     */
    where: MembershipWhereUniqueInput
  }

  /**
   * Membership findUniqueOrThrow
   */
  export type MembershipFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Membership
     */
    select?: MembershipSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: MembershipInclude<ExtArgs> | null
    /**
     * Filter, which Membership to fetch.
     */
    where: MembershipWhereUniqueInput
  }

  /**
   * Membership findFirst
   */
  export type MembershipFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Membership
     */
    select?: MembershipSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: MembershipInclude<ExtArgs> | null
    /**
     * Filter, which Membership to fetch.
     */
    where?: MembershipWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Memberships to fetch.
     */
    orderBy?: MembershipOrderByWithRelationInput | MembershipOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for Memberships.
     */
    cursor?: MembershipWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Memberships 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` Memberships.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of Memberships.
     */
    distinct?: MembershipScalarFieldEnum | MembershipScalarFieldEnum[]
  }

  /**
   * Membership findFirstOrThrow
   */
  export type MembershipFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Membership
     */
    select?: MembershipSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: MembershipInclude<ExtArgs> | null
    /**
     * Filter, which Membership to fetch.
     */
    where?: MembershipWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Memberships to fetch.
     */
    orderBy?: MembershipOrderByWithRelationInput | MembershipOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for Memberships.
     */
    cursor?: MembershipWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Memberships 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` Memberships.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of Memberships.
     */
    distinct?: MembershipScalarFieldEnum | MembershipScalarFieldEnum[]
  }

  /**
   * Membership findMany
   */
  export type MembershipFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Membership
     */
    select?: MembershipSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: MembershipInclude<ExtArgs> | null
    /**
     * Filter, which Memberships to fetch.
     */
    where?: MembershipWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Memberships to fetch.
     */
    orderBy?: MembershipOrderByWithRelationInput | MembershipOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing Memberships.
     */
    cursor?: MembershipWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Memberships 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` Memberships.
     */
    skip?: number
    distinct?: MembershipScalarFieldEnum | MembershipScalarFieldEnum[]
  }

  /**
   * Membership create
   */
  export type MembershipCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Membership
     */
    select?: MembershipSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: MembershipInclude<ExtArgs> | null
    /**
     * The data needed to create a Membership.
     */
    data: XOR<MembershipCreateInput, MembershipUncheckedCreateInput>
  }

  /**
   * Membership createMany
   */
  export type MembershipCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many Memberships.
     */
    data: MembershipCreateManyInput | MembershipCreateManyInput[]
    skipDuplicates?: boolean
  }

  /**
   * Membership update
   */
  export type MembershipUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Membership
     */
    select?: MembershipSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: MembershipInclude<ExtArgs> | null
    /**
     * The data needed to update a Membership.
     */
    data: XOR<MembershipUpdateInput, MembershipUncheckedUpdateInput>
    /**
     * Choose, which Membership to update.
     */
    where: MembershipWhereUniqueInput
  }

  /**
   * Membership updateMany
   */
  export type MembershipUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update Memberships.
     */
    data: XOR<MembershipUpdateManyMutationInput, MembershipUncheckedUpdateManyInput>
    /**
     * Filter which Memberships to update
     */
    where?: MembershipWhereInput
  }

  /**
   * Membership upsert
   */
  export type MembershipUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Membership
     */
    select?: MembershipSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: MembershipInclude<ExtArgs> | null
    /**
     * The filter to search for the Membership to update in case it exists.
     */
    where: MembershipWhereUniqueInput
    /**
     * In case the Membership found by the `where` argument doesn't exist, create a new Membership with this data.
     */
    create: XOR<MembershipCreateInput, MembershipUncheckedCreateInput>
    /**
     * In case the Membership was found with the provided `where` argument, update it with this data.
     */
    update: XOR<MembershipUpdateInput, MembershipUncheckedUpdateInput>
  }

  /**
   * Membership delete
   */
  export type MembershipDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Membership
     */
    select?: MembershipSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: MembershipInclude<ExtArgs> | null
    /**
     * Filter which Membership to delete.
     */
    where: MembershipWhereUniqueInput
  }

  /**
   * Membership deleteMany
   */
  export type MembershipDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which Memberships to delete
     */
    where?: MembershipWhereInput
  }

  /**
   * Membership.monthlyCyclesBeneficiario
   */
  export type Membership$monthlyCyclesBeneficiarioArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the MonthlyCycle
     */
    select?: MonthlyCycleSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: MonthlyCycleInclude<ExtArgs> | null
    where?: MonthlyCycleWhereInput
    orderBy?: MonthlyCycleOrderByWithRelationInput | MonthlyCycleOrderByWithRelationInput[]
    cursor?: MonthlyCycleWhereUniqueInput
    take?: number
    skip?: number
    distinct?: MonthlyCycleScalarFieldEnum | MonthlyCycleScalarFieldEnum[]
  }

  /**
   * Membership.contribuicoes
   */
  export type Membership$contribuicoesArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Contribution
     */
    select?: ContributionSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ContributionInclude<ExtArgs> | null
    where?: ContributionWhereInput
    orderBy?: ContributionOrderByWithRelationInput | ContributionOrderByWithRelationInput[]
    cursor?: ContributionWhereUniqueInput
    take?: number
    skip?: number
    distinct?: ContributionScalarFieldEnum | ContributionScalarFieldEnum[]
  }

  /**
   * Membership without action
   */
  export type MembershipDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Membership
     */
    select?: MembershipSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: MembershipInclude<ExtArgs> | null
  }


  /**
   * Model Invite
   */

  export type AggregateInvite = {
    _count: InviteCountAggregateOutputType | null
    _min: InviteMinAggregateOutputType | null
    _max: InviteMaxAggregateOutputType | null
  }

  export type InviteMinAggregateOutputType = {
    id: string | null
    groupId: string | null
    convidadoPorId: string | null
    telefone: string | null
    email: string | null
    token: string | null
    status: string | null
    createdAt: Date | null
    expiraEm: Date | null
  }

  export type InviteMaxAggregateOutputType = {
    id: string | null
    groupId: string | null
    convidadoPorId: string | null
    telefone: string | null
    email: string | null
    token: string | null
    status: string | null
    createdAt: Date | null
    expiraEm: Date | null
  }

  export type InviteCountAggregateOutputType = {
    id: number
    groupId: number
    convidadoPorId: number
    telefone: number
    email: number
    token: number
    status: number
    createdAt: number
    expiraEm: number
    _all: number
  }


  export type InviteMinAggregateInputType = {
    id?: true
    groupId?: true
    convidadoPorId?: true
    telefone?: true
    email?: true
    token?: true
    status?: true
    createdAt?: true
    expiraEm?: true
  }

  export type InviteMaxAggregateInputType = {
    id?: true
    groupId?: true
    convidadoPorId?: true
    telefone?: true
    email?: true
    token?: true
    status?: true
    createdAt?: true
    expiraEm?: true
  }

  export type InviteCountAggregateInputType = {
    id?: true
    groupId?: true
    convidadoPorId?: true
    telefone?: true
    email?: true
    token?: true
    status?: true
    createdAt?: true
    expiraEm?: true
    _all?: true
  }

  export type InviteAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which Invite to aggregate.
     */
    where?: InviteWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Invites to fetch.
     */
    orderBy?: InviteOrderByWithRelationInput | InviteOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: InviteWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Invites 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` Invites.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned Invites
    **/
    _count?: true | InviteCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: InviteMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: InviteMaxAggregateInputType
  }

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




  export type InviteGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: InviteWhereInput
    orderBy?: InviteOrderByWithAggregationInput | InviteOrderByWithAggregationInput[]
    by: InviteScalarFieldEnum[] | InviteScalarFieldEnum
    having?: InviteScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: InviteCountAggregateInputType | true
    _min?: InviteMinAggregateInputType
    _max?: InviteMaxAggregateInputType
  }

  export type InviteGroupByOutputType = {
    id: string
    groupId: string
    convidadoPorId: string
    telefone: string
    email: string | null
    token: string
    status: string
    createdAt: Date
    expiraEm: Date
    _count: InviteCountAggregateOutputType | null
    _min: InviteMinAggregateOutputType | null
    _max: InviteMaxAggregateOutputType | null
  }

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


  export type InviteSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    groupId?: boolean
    convidadoPorId?: boolean
    telefone?: boolean
    email?: boolean
    token?: boolean
    status?: boolean
    createdAt?: boolean
    expiraEm?: boolean
    group?: boolean | GroupDefaultArgs<ExtArgs>
    convidadoPor?: boolean | UserDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["invite"]>


  export type InviteSelectScalar = {
    id?: boolean
    groupId?: boolean
    convidadoPorId?: boolean
    telefone?: boolean
    email?: boolean
    token?: boolean
    status?: boolean
    createdAt?: boolean
    expiraEm?: boolean
  }

  export type InviteInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    group?: boolean | GroupDefaultArgs<ExtArgs>
    convidadoPor?: boolean | UserDefaultArgs<ExtArgs>
  }

  export type $InvitePayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "Invite"
    objects: {
      group: Prisma.$GroupPayload<ExtArgs>
      convidadoPor: Prisma.$UserPayload<ExtArgs>
    }
    scalars: $Extensions.GetPayloadResult<{
      id: string
      groupId: string
      convidadoPorId: string
      telefone: string
      email: string | null
      token: string
      status: string
      createdAt: Date
      expiraEm: Date
    }, ExtArgs["result"]["invite"]>
    composites: {}
  }

  type InviteGetPayload<S extends boolean | null | undefined | InviteDefaultArgs> = $Result.GetResult<Prisma.$InvitePayload, S>

  type InviteCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = 
    Omit<InviteFindManyArgs, 'select' | 'include' | 'distinct'> & {
      select?: InviteCountAggregateInputType | true
    }

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

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

    /**
     * Find the first Invite 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 {InviteFindFirstArgs} args - Arguments to find a Invite
     * @example
     * // Get one Invite
     * const invite = await prisma.invite.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends InviteFindFirstArgs>(args?: SelectSubset<T, InviteFindFirstArgs<ExtArgs>>): Prisma__InviteClient<$Result.GetResult<Prisma.$InvitePayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>

    /**
     * Find the first Invite 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 {InviteFindFirstOrThrowArgs} args - Arguments to find a Invite
     * @example
     * // Get one Invite
     * const invite = await prisma.invite.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends InviteFindFirstOrThrowArgs>(args?: SelectSubset<T, InviteFindFirstOrThrowArgs<ExtArgs>>): Prisma__InviteClient<$Result.GetResult<Prisma.$InvitePayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>

    /**
     * Find zero or more Invites 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 {InviteFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all Invites
     * const invites = await prisma.invite.findMany()
     * 
     * // Get first 10 Invites
     * const invites = await prisma.invite.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const inviteWithIdOnly = await prisma.invite.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends InviteFindManyArgs>(args?: SelectSubset<T, InviteFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$InvitePayload<ExtArgs>, T, "findMany">>

    /**
     * Create a Invite.
     * @param {InviteCreateArgs} args - Arguments to create a Invite.
     * @example
     * // Create one Invite
     * const Invite = await prisma.invite.create({
     *   data: {
     *     // ... data to create a Invite
     *   }
     * })
     * 
     */
    create<T extends InviteCreateArgs>(args: SelectSubset<T, InviteCreateArgs<ExtArgs>>): Prisma__InviteClient<$Result.GetResult<Prisma.$InvitePayload<ExtArgs>, T, "create">, never, ExtArgs>

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

    /**
     * Delete a Invite.
     * @param {InviteDeleteArgs} args - Arguments to delete one Invite.
     * @example
     * // Delete one Invite
     * const Invite = await prisma.invite.delete({
     *   where: {
     *     // ... filter to delete one Invite
     *   }
     * })
     * 
     */
    delete<T extends InviteDeleteArgs>(args: SelectSubset<T, InviteDeleteArgs<ExtArgs>>): Prisma__InviteClient<$Result.GetResult<Prisma.$InvitePayload<ExtArgs>, T, "delete">, never, ExtArgs>

    /**
     * Update one Invite.
     * @param {InviteUpdateArgs} args - Arguments to update one Invite.
     * @example
     * // Update one Invite
     * const invite = await prisma.invite.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends InviteUpdateArgs>(args: SelectSubset<T, InviteUpdateArgs<ExtArgs>>): Prisma__InviteClient<$Result.GetResult<Prisma.$InvitePayload<ExtArgs>, T, "update">, never, ExtArgs>

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

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

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


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

    /**
     * Allows you to perform aggregations operations on a Invite.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {InviteAggregateArgs} 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 InviteAggregateArgs>(args: Subset<T, InviteAggregateArgs>): Prisma.PrismaPromise<GetInviteAggregateType<T>>

    /**
     * Group by Invite.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {InviteGroupByArgs} 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 InviteGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: InviteGroupByArgs['orderBy'] }
        : { orderBy?: InviteGroupByArgs['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, InviteGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetInviteGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the Invite model
   */
  readonly fields: InviteFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for Invite.
   * 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__InviteClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
    readonly [Symbol.toStringTag]: "PrismaPromise"
    group<T extends GroupDefaultArgs<ExtArgs> = {}>(args?: Subset<T, GroupDefaultArgs<ExtArgs>>): Prisma__GroupClient<$Result.GetResult<Prisma.$GroupPayload<ExtArgs>, T, "findUniqueOrThrow"> | Null, Null, ExtArgs>
    convidadoPor<T extends UserDefaultArgs<ExtArgs> = {}>(args?: Subset<T, UserDefaultArgs<ExtArgs>>): Prisma__UserClient<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "findUniqueOrThrow"> | Null, Null, ExtArgs>
    /**
     * 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 Invite model
   */ 
  interface InviteFieldRefs {
    readonly id: FieldRef<"Invite", 'String'>
    readonly groupId: FieldRef<"Invite", 'String'>
    readonly convidadoPorId: FieldRef<"Invite", 'String'>
    readonly telefone: FieldRef<"Invite", 'String'>
    readonly email: FieldRef<"Invite", 'String'>
    readonly token: FieldRef<"Invite", 'String'>
    readonly status: FieldRef<"Invite", 'String'>
    readonly createdAt: FieldRef<"Invite", 'DateTime'>
    readonly expiraEm: FieldRef<"Invite", 'DateTime'>
  }
    

  // Custom InputTypes
  /**
   * Invite findUnique
   */
  export type InviteFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Invite
     */
    select?: InviteSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: InviteInclude<ExtArgs> | null
    /**
     * Filter, which Invite to fetch.
     */
    where: InviteWhereUniqueInput
  }

  /**
   * Invite findUniqueOrThrow
   */
  export type InviteFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Invite
     */
    select?: InviteSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: InviteInclude<ExtArgs> | null
    /**
     * Filter, which Invite to fetch.
     */
    where: InviteWhereUniqueInput
  }

  /**
   * Invite findFirst
   */
  export type InviteFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Invite
     */
    select?: InviteSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: InviteInclude<ExtArgs> | null
    /**
     * Filter, which Invite to fetch.
     */
    where?: InviteWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Invites to fetch.
     */
    orderBy?: InviteOrderByWithRelationInput | InviteOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for Invites.
     */
    cursor?: InviteWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Invites 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` Invites.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of Invites.
     */
    distinct?: InviteScalarFieldEnum | InviteScalarFieldEnum[]
  }

  /**
   * Invite findFirstOrThrow
   */
  export type InviteFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Invite
     */
    select?: InviteSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: InviteInclude<ExtArgs> | null
    /**
     * Filter, which Invite to fetch.
     */
    where?: InviteWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Invites to fetch.
     */
    orderBy?: InviteOrderByWithRelationInput | InviteOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for Invites.
     */
    cursor?: InviteWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Invites 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` Invites.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of Invites.
     */
    distinct?: InviteScalarFieldEnum | InviteScalarFieldEnum[]
  }

  /**
   * Invite findMany
   */
  export type InviteFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Invite
     */
    select?: InviteSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: InviteInclude<ExtArgs> | null
    /**
     * Filter, which Invites to fetch.
     */
    where?: InviteWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Invites to fetch.
     */
    orderBy?: InviteOrderByWithRelationInput | InviteOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing Invites.
     */
    cursor?: InviteWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Invites 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` Invites.
     */
    skip?: number
    distinct?: InviteScalarFieldEnum | InviteScalarFieldEnum[]
  }

  /**
   * Invite create
   */
  export type InviteCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Invite
     */
    select?: InviteSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: InviteInclude<ExtArgs> | null
    /**
     * The data needed to create a Invite.
     */
    data: XOR<InviteCreateInput, InviteUncheckedCreateInput>
  }

  /**
   * Invite createMany
   */
  export type InviteCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many Invites.
     */
    data: InviteCreateManyInput | InviteCreateManyInput[]
    skipDuplicates?: boolean
  }

  /**
   * Invite update
   */
  export type InviteUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Invite
     */
    select?: InviteSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: InviteInclude<ExtArgs> | null
    /**
     * The data needed to update a Invite.
     */
    data: XOR<InviteUpdateInput, InviteUncheckedUpdateInput>
    /**
     * Choose, which Invite to update.
     */
    where: InviteWhereUniqueInput
  }

  /**
   * Invite updateMany
   */
  export type InviteUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update Invites.
     */
    data: XOR<InviteUpdateManyMutationInput, InviteUncheckedUpdateManyInput>
    /**
     * Filter which Invites to update
     */
    where?: InviteWhereInput
  }

  /**
   * Invite upsert
   */
  export type InviteUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Invite
     */
    select?: InviteSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: InviteInclude<ExtArgs> | null
    /**
     * The filter to search for the Invite to update in case it exists.
     */
    where: InviteWhereUniqueInput
    /**
     * In case the Invite found by the `where` argument doesn't exist, create a new Invite with this data.
     */
    create: XOR<InviteCreateInput, InviteUncheckedCreateInput>
    /**
     * In case the Invite was found with the provided `where` argument, update it with this data.
     */
    update: XOR<InviteUpdateInput, InviteUncheckedUpdateInput>
  }

  /**
   * Invite delete
   */
  export type InviteDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Invite
     */
    select?: InviteSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: InviteInclude<ExtArgs> | null
    /**
     * Filter which Invite to delete.
     */
    where: InviteWhereUniqueInput
  }

  /**
   * Invite deleteMany
   */
  export type InviteDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which Invites to delete
     */
    where?: InviteWhereInput
  }

  /**
   * Invite without action
   */
  export type InviteDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Invite
     */
    select?: InviteSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: InviteInclude<ExtArgs> | null
  }


  /**
   * Model MonthlyCycle
   */

  export type AggregateMonthlyCycle = {
    _count: MonthlyCycleCountAggregateOutputType | null
    _avg: MonthlyCycleAvgAggregateOutputType | null
    _sum: MonthlyCycleSumAggregateOutputType | null
    _min: MonthlyCycleMinAggregateOutputType | null
    _max: MonthlyCycleMaxAggregateOutputType | null
  }

  export type MonthlyCycleAvgAggregateOutputType = {
    numeroCiclo: number | null
    valorPoteBruto: number | null
    valorTaxaPrincipal: number | null
    valorReservaTecnica: number | null
    valorPoteLiquido: number | null
  }

  export type MonthlyCycleSumAggregateOutputType = {
    numeroCiclo: number | null
    valorPoteBruto: number | null
    valorTaxaPrincipal: number | null
    valorReservaTecnica: number | null
    valorPoteLiquido: number | null
  }

  export type MonthlyCycleMinAggregateOutputType = {
    id: string | null
    groupId: string | null
    numeroCiclo: number | null
    mesAno: string | null
    beneficiarioMembershipId: string | null
    dataContribuicaoLimite: Date | null
    dataCashout: Date | null
    status: string | null
    valorPoteBruto: number | null
    valorTaxaPrincipal: number | null
    valorReservaTecnica: number | null
    valorPoteLiquido: number | null
    createdAt: Date | null
    updatedAt: Date | null
  }

  export type MonthlyCycleMaxAggregateOutputType = {
    id: string | null
    groupId: string | null
    numeroCiclo: number | null
    mesAno: string | null
    beneficiarioMembershipId: string | null
    dataContribuicaoLimite: Date | null
    dataCashout: Date | null
    status: string | null
    valorPoteBruto: number | null
    valorTaxaPrincipal: number | null
    valorReservaTecnica: number | null
    valorPoteLiquido: number | null
    createdAt: Date | null
    updatedAt: Date | null
  }

  export type MonthlyCycleCountAggregateOutputType = {
    id: number
    groupId: number
    numeroCiclo: number
    mesAno: number
    beneficiarioMembershipId: number
    dataContribuicaoLimite: number
    dataCashout: number
    status: number
    valorPoteBruto: number
    valorTaxaPrincipal: number
    valorReservaTecnica: number
    valorPoteLiquido: number
    createdAt: number
    updatedAt: number
    _all: number
  }


  export type MonthlyCycleAvgAggregateInputType = {
    numeroCiclo?: true
    valorPoteBruto?: true
    valorTaxaPrincipal?: true
    valorReservaTecnica?: true
    valorPoteLiquido?: true
  }

  export type MonthlyCycleSumAggregateInputType = {
    numeroCiclo?: true
    valorPoteBruto?: true
    valorTaxaPrincipal?: true
    valorReservaTecnica?: true
    valorPoteLiquido?: true
  }

  export type MonthlyCycleMinAggregateInputType = {
    id?: true
    groupId?: true
    numeroCiclo?: true
    mesAno?: true
    beneficiarioMembershipId?: true
    dataContribuicaoLimite?: true
    dataCashout?: true
    status?: true
    valorPoteBruto?: true
    valorTaxaPrincipal?: true
    valorReservaTecnica?: true
    valorPoteLiquido?: true
    createdAt?: true
    updatedAt?: true
  }

  export type MonthlyCycleMaxAggregateInputType = {
    id?: true
    groupId?: true
    numeroCiclo?: true
    mesAno?: true
    beneficiarioMembershipId?: true
    dataContribuicaoLimite?: true
    dataCashout?: true
    status?: true
    valorPoteBruto?: true
    valorTaxaPrincipal?: true
    valorReservaTecnica?: true
    valorPoteLiquido?: true
    createdAt?: true
    updatedAt?: true
  }

  export type MonthlyCycleCountAggregateInputType = {
    id?: true
    groupId?: true
    numeroCiclo?: true
    mesAno?: true
    beneficiarioMembershipId?: true
    dataContribuicaoLimite?: true
    dataCashout?: true
    status?: true
    valorPoteBruto?: true
    valorTaxaPrincipal?: true
    valorReservaTecnica?: true
    valorPoteLiquido?: true
    createdAt?: true
    updatedAt?: true
    _all?: true
  }

  export type MonthlyCycleAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which MonthlyCycle to aggregate.
     */
    where?: MonthlyCycleWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of MonthlyCycles to fetch.
     */
    orderBy?: MonthlyCycleOrderByWithRelationInput | MonthlyCycleOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: MonthlyCycleWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` MonthlyCycles 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` MonthlyCycles.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned MonthlyCycles
    **/
    _count?: true | MonthlyCycleCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to average
    **/
    _avg?: MonthlyCycleAvgAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to sum
    **/
    _sum?: MonthlyCycleSumAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: MonthlyCycleMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: MonthlyCycleMaxAggregateInputType
  }

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




  export type MonthlyCycleGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: MonthlyCycleWhereInput
    orderBy?: MonthlyCycleOrderByWithAggregationInput | MonthlyCycleOrderByWithAggregationInput[]
    by: MonthlyCycleScalarFieldEnum[] | MonthlyCycleScalarFieldEnum
    having?: MonthlyCycleScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: MonthlyCycleCountAggregateInputType | true
    _avg?: MonthlyCycleAvgAggregateInputType
    _sum?: MonthlyCycleSumAggregateInputType
    _min?: MonthlyCycleMinAggregateInputType
    _max?: MonthlyCycleMaxAggregateInputType
  }

  export type MonthlyCycleGroupByOutputType = {
    id: string
    groupId: string
    numeroCiclo: number
    mesAno: string
    beneficiarioMembershipId: string
    dataContribuicaoLimite: Date
    dataCashout: Date
    status: string
    valorPoteBruto: number
    valorTaxaPrincipal: number
    valorReservaTecnica: number
    valorPoteLiquido: number
    createdAt: Date
    updatedAt: Date
    _count: MonthlyCycleCountAggregateOutputType | null
    _avg: MonthlyCycleAvgAggregateOutputType | null
    _sum: MonthlyCycleSumAggregateOutputType | null
    _min: MonthlyCycleMinAggregateOutputType | null
    _max: MonthlyCycleMaxAggregateOutputType | null
  }

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


  export type MonthlyCycleSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    groupId?: boolean
    numeroCiclo?: boolean
    mesAno?: boolean
    beneficiarioMembershipId?: boolean
    dataContribuicaoLimite?: boolean
    dataCashout?: boolean
    status?: boolean
    valorPoteBruto?: boolean
    valorTaxaPrincipal?: boolean
    valorReservaTecnica?: boolean
    valorPoteLiquido?: boolean
    createdAt?: boolean
    updatedAt?: boolean
    group?: boolean | GroupDefaultArgs<ExtArgs>
    beneficiarioMembership?: boolean | MembershipDefaultArgs<ExtArgs>
    contribuicoes?: boolean | MonthlyCycle$contribuicoesArgs<ExtArgs>
    cashout?: boolean | MonthlyCycle$cashoutArgs<ExtArgs>
    loans?: boolean | MonthlyCycle$loansArgs<ExtArgs>
    _count?: boolean | MonthlyCycleCountOutputTypeDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["monthlyCycle"]>


  export type MonthlyCycleSelectScalar = {
    id?: boolean
    groupId?: boolean
    numeroCiclo?: boolean
    mesAno?: boolean
    beneficiarioMembershipId?: boolean
    dataContribuicaoLimite?: boolean
    dataCashout?: boolean
    status?: boolean
    valorPoteBruto?: boolean
    valorTaxaPrincipal?: boolean
    valorReservaTecnica?: boolean
    valorPoteLiquido?: boolean
    createdAt?: boolean
    updatedAt?: boolean
  }

  export type MonthlyCycleInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    group?: boolean | GroupDefaultArgs<ExtArgs>
    beneficiarioMembership?: boolean | MembershipDefaultArgs<ExtArgs>
    contribuicoes?: boolean | MonthlyCycle$contribuicoesArgs<ExtArgs>
    cashout?: boolean | MonthlyCycle$cashoutArgs<ExtArgs>
    loans?: boolean | MonthlyCycle$loansArgs<ExtArgs>
    _count?: boolean | MonthlyCycleCountOutputTypeDefaultArgs<ExtArgs>
  }

  export type $MonthlyCyclePayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "MonthlyCycle"
    objects: {
      group: Prisma.$GroupPayload<ExtArgs>
      beneficiarioMembership: Prisma.$MembershipPayload<ExtArgs>
      contribuicoes: Prisma.$ContributionPayload<ExtArgs>[]
      cashout: Prisma.$CashoutPayload<ExtArgs> | null
      loans: Prisma.$LoanPayload<ExtArgs>[]
    }
    scalars: $Extensions.GetPayloadResult<{
      id: string
      groupId: string
      numeroCiclo: number
      mesAno: string
      beneficiarioMembershipId: string
      dataContribuicaoLimite: Date
      dataCashout: Date
      status: string
      valorPoteBruto: number
      valorTaxaPrincipal: number
      valorReservaTecnica: number
      valorPoteLiquido: number
      createdAt: Date
      updatedAt: Date
    }, ExtArgs["result"]["monthlyCycle"]>
    composites: {}
  }

  type MonthlyCycleGetPayload<S extends boolean | null | undefined | MonthlyCycleDefaultArgs> = $Result.GetResult<Prisma.$MonthlyCyclePayload, S>

  type MonthlyCycleCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = 
    Omit<MonthlyCycleFindManyArgs, 'select' | 'include' | 'distinct'> & {
      select?: MonthlyCycleCountAggregateInputType | true
    }

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

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

    /**
     * Find the first MonthlyCycle 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 {MonthlyCycleFindFirstArgs} args - Arguments to find a MonthlyCycle
     * @example
     * // Get one MonthlyCycle
     * const monthlyCycle = await prisma.monthlyCycle.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends MonthlyCycleFindFirstArgs>(args?: SelectSubset<T, MonthlyCycleFindFirstArgs<ExtArgs>>): Prisma__MonthlyCycleClient<$Result.GetResult<Prisma.$MonthlyCyclePayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>

    /**
     * Find the first MonthlyCycle 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 {MonthlyCycleFindFirstOrThrowArgs} args - Arguments to find a MonthlyCycle
     * @example
     * // Get one MonthlyCycle
     * const monthlyCycle = await prisma.monthlyCycle.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends MonthlyCycleFindFirstOrThrowArgs>(args?: SelectSubset<T, MonthlyCycleFindFirstOrThrowArgs<ExtArgs>>): Prisma__MonthlyCycleClient<$Result.GetResult<Prisma.$MonthlyCyclePayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>

    /**
     * Find zero or more MonthlyCycles 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 {MonthlyCycleFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all MonthlyCycles
     * const monthlyCycles = await prisma.monthlyCycle.findMany()
     * 
     * // Get first 10 MonthlyCycles
     * const monthlyCycles = await prisma.monthlyCycle.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const monthlyCycleWithIdOnly = await prisma.monthlyCycle.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends MonthlyCycleFindManyArgs>(args?: SelectSubset<T, MonthlyCycleFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$MonthlyCyclePayload<ExtArgs>, T, "findMany">>

    /**
     * Create a MonthlyCycle.
     * @param {MonthlyCycleCreateArgs} args - Arguments to create a MonthlyCycle.
     * @example
     * // Create one MonthlyCycle
     * const MonthlyCycle = await prisma.monthlyCycle.create({
     *   data: {
     *     // ... data to create a MonthlyCycle
     *   }
     * })
     * 
     */
    create<T extends MonthlyCycleCreateArgs>(args: SelectSubset<T, MonthlyCycleCreateArgs<ExtArgs>>): Prisma__MonthlyCycleClient<$Result.GetResult<Prisma.$MonthlyCyclePayload<ExtArgs>, T, "create">, never, ExtArgs>

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

    /**
     * Delete a MonthlyCycle.
     * @param {MonthlyCycleDeleteArgs} args - Arguments to delete one MonthlyCycle.
     * @example
     * // Delete one MonthlyCycle
     * const MonthlyCycle = await prisma.monthlyCycle.delete({
     *   where: {
     *     // ... filter to delete one MonthlyCycle
     *   }
     * })
     * 
     */
    delete<T extends MonthlyCycleDeleteArgs>(args: SelectSubset<T, MonthlyCycleDeleteArgs<ExtArgs>>): Prisma__MonthlyCycleClient<$Result.GetResult<Prisma.$MonthlyCyclePayload<ExtArgs>, T, "delete">, never, ExtArgs>

    /**
     * Update one MonthlyCycle.
     * @param {MonthlyCycleUpdateArgs} args - Arguments to update one MonthlyCycle.
     * @example
     * // Update one MonthlyCycle
     * const monthlyCycle = await prisma.monthlyCycle.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends MonthlyCycleUpdateArgs>(args: SelectSubset<T, MonthlyCycleUpdateArgs<ExtArgs>>): Prisma__MonthlyCycleClient<$Result.GetResult<Prisma.$MonthlyCyclePayload<ExtArgs>, T, "update">, never, ExtArgs>

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

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

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


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

    /**
     * Allows you to perform aggregations operations on a MonthlyCycle.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {MonthlyCycleAggregateArgs} 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 MonthlyCycleAggregateArgs>(args: Subset<T, MonthlyCycleAggregateArgs>): Prisma.PrismaPromise<GetMonthlyCycleAggregateType<T>>

    /**
     * Group by MonthlyCycle.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {MonthlyCycleGroupByArgs} 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 MonthlyCycleGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: MonthlyCycleGroupByArgs['orderBy'] }
        : { orderBy?: MonthlyCycleGroupByArgs['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, MonthlyCycleGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetMonthlyCycleGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the MonthlyCycle model
   */
  readonly fields: MonthlyCycleFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for MonthlyCycle.
   * 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__MonthlyCycleClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
    readonly [Symbol.toStringTag]: "PrismaPromise"
    group<T extends GroupDefaultArgs<ExtArgs> = {}>(args?: Subset<T, GroupDefaultArgs<ExtArgs>>): Prisma__GroupClient<$Result.GetResult<Prisma.$GroupPayload<ExtArgs>, T, "findUniqueOrThrow"> | Null, Null, ExtArgs>
    beneficiarioMembership<T extends MembershipDefaultArgs<ExtArgs> = {}>(args?: Subset<T, MembershipDefaultArgs<ExtArgs>>): Prisma__MembershipClient<$Result.GetResult<Prisma.$MembershipPayload<ExtArgs>, T, "findUniqueOrThrow"> | Null, Null, ExtArgs>
    contribuicoes<T extends MonthlyCycle$contribuicoesArgs<ExtArgs> = {}>(args?: Subset<T, MonthlyCycle$contribuicoesArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$ContributionPayload<ExtArgs>, T, "findMany"> | Null>
    cashout<T extends MonthlyCycle$cashoutArgs<ExtArgs> = {}>(args?: Subset<T, MonthlyCycle$cashoutArgs<ExtArgs>>): Prisma__CashoutClient<$Result.GetResult<Prisma.$CashoutPayload<ExtArgs>, T, "findUniqueOrThrow"> | null, null, ExtArgs>
    loans<T extends MonthlyCycle$loansArgs<ExtArgs> = {}>(args?: Subset<T, MonthlyCycle$loansArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$LoanPayload<ExtArgs>, T, "findMany"> | 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 MonthlyCycle model
   */ 
  interface MonthlyCycleFieldRefs {
    readonly id: FieldRef<"MonthlyCycle", 'String'>
    readonly groupId: FieldRef<"MonthlyCycle", 'String'>
    readonly numeroCiclo: FieldRef<"MonthlyCycle", 'Int'>
    readonly mesAno: FieldRef<"MonthlyCycle", 'String'>
    readonly beneficiarioMembershipId: FieldRef<"MonthlyCycle", 'String'>
    readonly dataContribuicaoLimite: FieldRef<"MonthlyCycle", 'DateTime'>
    readonly dataCashout: FieldRef<"MonthlyCycle", 'DateTime'>
    readonly status: FieldRef<"MonthlyCycle", 'String'>
    readonly valorPoteBruto: FieldRef<"MonthlyCycle", 'Float'>
    readonly valorTaxaPrincipal: FieldRef<"MonthlyCycle", 'Float'>
    readonly valorReservaTecnica: FieldRef<"MonthlyCycle", 'Float'>
    readonly valorPoteLiquido: FieldRef<"MonthlyCycle", 'Float'>
    readonly createdAt: FieldRef<"MonthlyCycle", 'DateTime'>
    readonly updatedAt: FieldRef<"MonthlyCycle", 'DateTime'>
  }
    

  // Custom InputTypes
  /**
   * MonthlyCycle findUnique
   */
  export type MonthlyCycleFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the MonthlyCycle
     */
    select?: MonthlyCycleSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: MonthlyCycleInclude<ExtArgs> | null
    /**
     * Filter, which MonthlyCycle to fetch.
     */
    where: MonthlyCycleWhereUniqueInput
  }

  /**
   * MonthlyCycle findUniqueOrThrow
   */
  export type MonthlyCycleFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the MonthlyCycle
     */
    select?: MonthlyCycleSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: MonthlyCycleInclude<ExtArgs> | null
    /**
     * Filter, which MonthlyCycle to fetch.
     */
    where: MonthlyCycleWhereUniqueInput
  }

  /**
   * MonthlyCycle findFirst
   */
  export type MonthlyCycleFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the MonthlyCycle
     */
    select?: MonthlyCycleSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: MonthlyCycleInclude<ExtArgs> | null
    /**
     * Filter, which MonthlyCycle to fetch.
     */
    where?: MonthlyCycleWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of MonthlyCycles to fetch.
     */
    orderBy?: MonthlyCycleOrderByWithRelationInput | MonthlyCycleOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for MonthlyCycles.
     */
    cursor?: MonthlyCycleWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` MonthlyCycles 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` MonthlyCycles.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of MonthlyCycles.
     */
    distinct?: MonthlyCycleScalarFieldEnum | MonthlyCycleScalarFieldEnum[]
  }

  /**
   * MonthlyCycle findFirstOrThrow
   */
  export type MonthlyCycleFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the MonthlyCycle
     */
    select?: MonthlyCycleSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: MonthlyCycleInclude<ExtArgs> | null
    /**
     * Filter, which MonthlyCycle to fetch.
     */
    where?: MonthlyCycleWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of MonthlyCycles to fetch.
     */
    orderBy?: MonthlyCycleOrderByWithRelationInput | MonthlyCycleOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for MonthlyCycles.
     */
    cursor?: MonthlyCycleWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` MonthlyCycles 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` MonthlyCycles.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of MonthlyCycles.
     */
    distinct?: MonthlyCycleScalarFieldEnum | MonthlyCycleScalarFieldEnum[]
  }

  /**
   * MonthlyCycle findMany
   */
  export type MonthlyCycleFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the MonthlyCycle
     */
    select?: MonthlyCycleSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: MonthlyCycleInclude<ExtArgs> | null
    /**
     * Filter, which MonthlyCycles to fetch.
     */
    where?: MonthlyCycleWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of MonthlyCycles to fetch.
     */
    orderBy?: MonthlyCycleOrderByWithRelationInput | MonthlyCycleOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing MonthlyCycles.
     */
    cursor?: MonthlyCycleWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` MonthlyCycles 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` MonthlyCycles.
     */
    skip?: number
    distinct?: MonthlyCycleScalarFieldEnum | MonthlyCycleScalarFieldEnum[]
  }

  /**
   * MonthlyCycle create
   */
  export type MonthlyCycleCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the MonthlyCycle
     */
    select?: MonthlyCycleSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: MonthlyCycleInclude<ExtArgs> | null
    /**
     * The data needed to create a MonthlyCycle.
     */
    data: XOR<MonthlyCycleCreateInput, MonthlyCycleUncheckedCreateInput>
  }

  /**
   * MonthlyCycle createMany
   */
  export type MonthlyCycleCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many MonthlyCycles.
     */
    data: MonthlyCycleCreateManyInput | MonthlyCycleCreateManyInput[]
    skipDuplicates?: boolean
  }

  /**
   * MonthlyCycle update
   */
  export type MonthlyCycleUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the MonthlyCycle
     */
    select?: MonthlyCycleSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: MonthlyCycleInclude<ExtArgs> | null
    /**
     * The data needed to update a MonthlyCycle.
     */
    data: XOR<MonthlyCycleUpdateInput, MonthlyCycleUncheckedUpdateInput>
    /**
     * Choose, which MonthlyCycle to update.
     */
    where: MonthlyCycleWhereUniqueInput
  }

  /**
   * MonthlyCycle updateMany
   */
  export type MonthlyCycleUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update MonthlyCycles.
     */
    data: XOR<MonthlyCycleUpdateManyMutationInput, MonthlyCycleUncheckedUpdateManyInput>
    /**
     * Filter which MonthlyCycles to update
     */
    where?: MonthlyCycleWhereInput
  }

  /**
   * MonthlyCycle upsert
   */
  export type MonthlyCycleUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the MonthlyCycle
     */
    select?: MonthlyCycleSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: MonthlyCycleInclude<ExtArgs> | null
    /**
     * The filter to search for the MonthlyCycle to update in case it exists.
     */
    where: MonthlyCycleWhereUniqueInput
    /**
     * In case the MonthlyCycle found by the `where` argument doesn't exist, create a new MonthlyCycle with this data.
     */
    create: XOR<MonthlyCycleCreateInput, MonthlyCycleUncheckedCreateInput>
    /**
     * In case the MonthlyCycle was found with the provided `where` argument, update it with this data.
     */
    update: XOR<MonthlyCycleUpdateInput, MonthlyCycleUncheckedUpdateInput>
  }

  /**
   * MonthlyCycle delete
   */
  export type MonthlyCycleDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the MonthlyCycle
     */
    select?: MonthlyCycleSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: MonthlyCycleInclude<ExtArgs> | null
    /**
     * Filter which MonthlyCycle to delete.
     */
    where: MonthlyCycleWhereUniqueInput
  }

  /**
   * MonthlyCycle deleteMany
   */
  export type MonthlyCycleDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which MonthlyCycles to delete
     */
    where?: MonthlyCycleWhereInput
  }

  /**
   * MonthlyCycle.contribuicoes
   */
  export type MonthlyCycle$contribuicoesArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Contribution
     */
    select?: ContributionSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ContributionInclude<ExtArgs> | null
    where?: ContributionWhereInput
    orderBy?: ContributionOrderByWithRelationInput | ContributionOrderByWithRelationInput[]
    cursor?: ContributionWhereUniqueInput
    take?: number
    skip?: number
    distinct?: ContributionScalarFieldEnum | ContributionScalarFieldEnum[]
  }

  /**
   * MonthlyCycle.cashout
   */
  export type MonthlyCycle$cashoutArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Cashout
     */
    select?: CashoutSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CashoutInclude<ExtArgs> | null
    where?: CashoutWhereInput
  }

  /**
   * MonthlyCycle.loans
   */
  export type MonthlyCycle$loansArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Loan
     */
    select?: LoanSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: LoanInclude<ExtArgs> | null
    where?: LoanWhereInput
    orderBy?: LoanOrderByWithRelationInput | LoanOrderByWithRelationInput[]
    cursor?: LoanWhereUniqueInput
    take?: number
    skip?: number
    distinct?: LoanScalarFieldEnum | LoanScalarFieldEnum[]
  }

  /**
   * MonthlyCycle without action
   */
  export type MonthlyCycleDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the MonthlyCycle
     */
    select?: MonthlyCycleSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: MonthlyCycleInclude<ExtArgs> | null
  }


  /**
   * Model Contribution
   */

  export type AggregateContribution = {
    _count: ContributionCountAggregateOutputType | null
    _avg: ContributionAvgAggregateOutputType | null
    _sum: ContributionSumAggregateOutputType | null
    _min: ContributionMinAggregateOutputType | null
    _max: ContributionMaxAggregateOutputType | null
  }

  export type ContributionAvgAggregateOutputType = {
    valor: number | null
  }

  export type ContributionSumAggregateOutputType = {
    valor: number | null
  }

  export type ContributionMinAggregateOutputType = {
    id: string | null
    membershipId: string | null
    userId: string | null
    monthlyCycleId: string | null
    valor: number | null
    dataPrevista: Date | null
    dataPagamento: Date | null
    status: string | null
    metodoPagamento: string | null
    referenciaBancaria: string | null
    comprovativoUrl: string | null
    createdAt: Date | null
    updatedAt: Date | null
  }

  export type ContributionMaxAggregateOutputType = {
    id: string | null
    membershipId: string | null
    userId: string | null
    monthlyCycleId: string | null
    valor: number | null
    dataPrevista: Date | null
    dataPagamento: Date | null
    status: string | null
    metodoPagamento: string | null
    referenciaBancaria: string | null
    comprovativoUrl: string | null
    createdAt: Date | null
    updatedAt: Date | null
  }

  export type ContributionCountAggregateOutputType = {
    id: number
    membershipId: number
    userId: number
    monthlyCycleId: number
    valor: number
    dataPrevista: number
    dataPagamento: number
    status: number
    metodoPagamento: number
    referenciaBancaria: number
    comprovativoUrl: number
    createdAt: number
    updatedAt: number
    _all: number
  }


  export type ContributionAvgAggregateInputType = {
    valor?: true
  }

  export type ContributionSumAggregateInputType = {
    valor?: true
  }

  export type ContributionMinAggregateInputType = {
    id?: true
    membershipId?: true
    userId?: true
    monthlyCycleId?: true
    valor?: true
    dataPrevista?: true
    dataPagamento?: true
    status?: true
    metodoPagamento?: true
    referenciaBancaria?: true
    comprovativoUrl?: true
    createdAt?: true
    updatedAt?: true
  }

  export type ContributionMaxAggregateInputType = {
    id?: true
    membershipId?: true
    userId?: true
    monthlyCycleId?: true
    valor?: true
    dataPrevista?: true
    dataPagamento?: true
    status?: true
    metodoPagamento?: true
    referenciaBancaria?: true
    comprovativoUrl?: true
    createdAt?: true
    updatedAt?: true
  }

  export type ContributionCountAggregateInputType = {
    id?: true
    membershipId?: true
    userId?: true
    monthlyCycleId?: true
    valor?: true
    dataPrevista?: true
    dataPagamento?: true
    status?: true
    metodoPagamento?: true
    referenciaBancaria?: true
    comprovativoUrl?: true
    createdAt?: true
    updatedAt?: true
    _all?: true
  }

  export type ContributionAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which Contribution to aggregate.
     */
    where?: ContributionWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Contributions to fetch.
     */
    orderBy?: ContributionOrderByWithRelationInput | ContributionOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: ContributionWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Contributions 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` Contributions.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned Contributions
    **/
    _count?: true | ContributionCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to average
    **/
    _avg?: ContributionAvgAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to sum
    **/
    _sum?: ContributionSumAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: ContributionMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: ContributionMaxAggregateInputType
  }

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




  export type ContributionGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: ContributionWhereInput
    orderBy?: ContributionOrderByWithAggregationInput | ContributionOrderByWithAggregationInput[]
    by: ContributionScalarFieldEnum[] | ContributionScalarFieldEnum
    having?: ContributionScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: ContributionCountAggregateInputType | true
    _avg?: ContributionAvgAggregateInputType
    _sum?: ContributionSumAggregateInputType
    _min?: ContributionMinAggregateInputType
    _max?: ContributionMaxAggregateInputType
  }

  export type ContributionGroupByOutputType = {
    id: string
    membershipId: string
    userId: string
    monthlyCycleId: string
    valor: number
    dataPrevista: Date
    dataPagamento: Date | null
    status: string
    metodoPagamento: string | null
    referenciaBancaria: string | null
    comprovativoUrl: string | null
    createdAt: Date
    updatedAt: Date
    _count: ContributionCountAggregateOutputType | null
    _avg: ContributionAvgAggregateOutputType | null
    _sum: ContributionSumAggregateOutputType | null
    _min: ContributionMinAggregateOutputType | null
    _max: ContributionMaxAggregateOutputType | null
  }

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


  export type ContributionSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    membershipId?: boolean
    userId?: boolean
    monthlyCycleId?: boolean
    valor?: boolean
    dataPrevista?: boolean
    dataPagamento?: boolean
    status?: boolean
    metodoPagamento?: boolean
    referenciaBancaria?: boolean
    comprovativoUrl?: boolean
    createdAt?: boolean
    updatedAt?: boolean
    membership?: boolean | MembershipDefaultArgs<ExtArgs>
    user?: boolean | UserDefaultArgs<ExtArgs>
    monthlyCycle?: boolean | MonthlyCycleDefaultArgs<ExtArgs>
    coverageDecision?: boolean | Contribution$coverageDecisionArgs<ExtArgs>
  }, ExtArgs["result"]["contribution"]>


  export type ContributionSelectScalar = {
    id?: boolean
    membershipId?: boolean
    userId?: boolean
    monthlyCycleId?: boolean
    valor?: boolean
    dataPrevista?: boolean
    dataPagamento?: boolean
    status?: boolean
    metodoPagamento?: boolean
    referenciaBancaria?: boolean
    comprovativoUrl?: boolean
    createdAt?: boolean
    updatedAt?: boolean
  }

  export type ContributionInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    membership?: boolean | MembershipDefaultArgs<ExtArgs>
    user?: boolean | UserDefaultArgs<ExtArgs>
    monthlyCycle?: boolean | MonthlyCycleDefaultArgs<ExtArgs>
    coverageDecision?: boolean | Contribution$coverageDecisionArgs<ExtArgs>
  }

  export type $ContributionPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "Contribution"
    objects: {
      membership: Prisma.$MembershipPayload<ExtArgs>
      user: Prisma.$UserPayload<ExtArgs>
      monthlyCycle: Prisma.$MonthlyCyclePayload<ExtArgs>
      coverageDecision: Prisma.$CoverageDecisionPayload<ExtArgs> | null
    }
    scalars: $Extensions.GetPayloadResult<{
      id: string
      membershipId: string
      userId: string
      monthlyCycleId: string
      valor: number
      dataPrevista: Date
      dataPagamento: Date | null
      status: string
      metodoPagamento: string | null
      referenciaBancaria: string | null
      comprovativoUrl: string | null
      createdAt: Date
      updatedAt: Date
    }, ExtArgs["result"]["contribution"]>
    composites: {}
  }

  type ContributionGetPayload<S extends boolean | null | undefined | ContributionDefaultArgs> = $Result.GetResult<Prisma.$ContributionPayload, S>

  type ContributionCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = 
    Omit<ContributionFindManyArgs, 'select' | 'include' | 'distinct'> & {
      select?: ContributionCountAggregateInputType | true
    }

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

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

    /**
     * Find the first Contribution 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 {ContributionFindFirstArgs} args - Arguments to find a Contribution
     * @example
     * // Get one Contribution
     * const contribution = await prisma.contribution.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends ContributionFindFirstArgs>(args?: SelectSubset<T, ContributionFindFirstArgs<ExtArgs>>): Prisma__ContributionClient<$Result.GetResult<Prisma.$ContributionPayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>

    /**
     * Find the first Contribution 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 {ContributionFindFirstOrThrowArgs} args - Arguments to find a Contribution
     * @example
     * // Get one Contribution
     * const contribution = await prisma.contribution.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends ContributionFindFirstOrThrowArgs>(args?: SelectSubset<T, ContributionFindFirstOrThrowArgs<ExtArgs>>): Prisma__ContributionClient<$Result.GetResult<Prisma.$ContributionPayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>

    /**
     * Find zero or more Contributions 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 {ContributionFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all Contributions
     * const contributions = await prisma.contribution.findMany()
     * 
     * // Get first 10 Contributions
     * const contributions = await prisma.contribution.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const contributionWithIdOnly = await prisma.contribution.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends ContributionFindManyArgs>(args?: SelectSubset<T, ContributionFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$ContributionPayload<ExtArgs>, T, "findMany">>

    /**
     * Create a Contribution.
     * @param {ContributionCreateArgs} args - Arguments to create a Contribution.
     * @example
     * // Create one Contribution
     * const Contribution = await prisma.contribution.create({
     *   data: {
     *     // ... data to create a Contribution
     *   }
     * })
     * 
     */
    create<T extends ContributionCreateArgs>(args: SelectSubset<T, ContributionCreateArgs<ExtArgs>>): Prisma__ContributionClient<$Result.GetResult<Prisma.$ContributionPayload<ExtArgs>, T, "create">, never, ExtArgs>

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

    /**
     * Delete a Contribution.
     * @param {ContributionDeleteArgs} args - Arguments to delete one Contribution.
     * @example
     * // Delete one Contribution
     * const Contribution = await prisma.contribution.delete({
     *   where: {
     *     // ... filter to delete one Contribution
     *   }
     * })
     * 
     */
    delete<T extends ContributionDeleteArgs>(args: SelectSubset<T, ContributionDeleteArgs<ExtArgs>>): Prisma__ContributionClient<$Result.GetResult<Prisma.$ContributionPayload<ExtArgs>, T, "delete">, never, ExtArgs>

    /**
     * Update one Contribution.
     * @param {ContributionUpdateArgs} args - Arguments to update one Contribution.
     * @example
     * // Update one Contribution
     * const contribution = await prisma.contribution.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends ContributionUpdateArgs>(args: SelectSubset<T, ContributionUpdateArgs<ExtArgs>>): Prisma__ContributionClient<$Result.GetResult<Prisma.$ContributionPayload<ExtArgs>, T, "update">, never, ExtArgs>

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

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

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


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

    /**
     * Allows you to perform aggregations operations on a Contribution.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {ContributionAggregateArgs} 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 ContributionAggregateArgs>(args: Subset<T, ContributionAggregateArgs>): Prisma.PrismaPromise<GetContributionAggregateType<T>>

    /**
     * Group by Contribution.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {ContributionGroupByArgs} 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 ContributionGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: ContributionGroupByArgs['orderBy'] }
        : { orderBy?: ContributionGroupByArgs['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, ContributionGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetContributionGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the Contribution model
   */
  readonly fields: ContributionFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for Contribution.
   * 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__ContributionClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
    readonly [Symbol.toStringTag]: "PrismaPromise"
    membership<T extends MembershipDefaultArgs<ExtArgs> = {}>(args?: Subset<T, MembershipDefaultArgs<ExtArgs>>): Prisma__MembershipClient<$Result.GetResult<Prisma.$MembershipPayload<ExtArgs>, T, "findUniqueOrThrow"> | Null, Null, ExtArgs>
    user<T extends UserDefaultArgs<ExtArgs> = {}>(args?: Subset<T, UserDefaultArgs<ExtArgs>>): Prisma__UserClient<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "findUniqueOrThrow"> | Null, Null, ExtArgs>
    monthlyCycle<T extends MonthlyCycleDefaultArgs<ExtArgs> = {}>(args?: Subset<T, MonthlyCycleDefaultArgs<ExtArgs>>): Prisma__MonthlyCycleClient<$Result.GetResult<Prisma.$MonthlyCyclePayload<ExtArgs>, T, "findUniqueOrThrow"> | Null, Null, ExtArgs>
    coverageDecision<T extends Contribution$coverageDecisionArgs<ExtArgs> = {}>(args?: Subset<T, Contribution$coverageDecisionArgs<ExtArgs>>): Prisma__CoverageDecisionClient<$Result.GetResult<Prisma.$CoverageDecisionPayload<ExtArgs>, T, "findUniqueOrThrow"> | null, null, ExtArgs>
    /**
     * 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 Contribution model
   */ 
  interface ContributionFieldRefs {
    readonly id: FieldRef<"Contribution", 'String'>
    readonly membershipId: FieldRef<"Contribution", 'String'>
    readonly userId: FieldRef<"Contribution", 'String'>
    readonly monthlyCycleId: FieldRef<"Contribution", 'String'>
    readonly valor: FieldRef<"Contribution", 'Float'>
    readonly dataPrevista: FieldRef<"Contribution", 'DateTime'>
    readonly dataPagamento: FieldRef<"Contribution", 'DateTime'>
    readonly status: FieldRef<"Contribution", 'String'>
    readonly metodoPagamento: FieldRef<"Contribution", 'String'>
    readonly referenciaBancaria: FieldRef<"Contribution", 'String'>
    readonly comprovativoUrl: FieldRef<"Contribution", 'String'>
    readonly createdAt: FieldRef<"Contribution", 'DateTime'>
    readonly updatedAt: FieldRef<"Contribution", 'DateTime'>
  }
    

  // Custom InputTypes
  /**
   * Contribution findUnique
   */
  export type ContributionFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Contribution
     */
    select?: ContributionSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ContributionInclude<ExtArgs> | null
    /**
     * Filter, which Contribution to fetch.
     */
    where: ContributionWhereUniqueInput
  }

  /**
   * Contribution findUniqueOrThrow
   */
  export type ContributionFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Contribution
     */
    select?: ContributionSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ContributionInclude<ExtArgs> | null
    /**
     * Filter, which Contribution to fetch.
     */
    where: ContributionWhereUniqueInput
  }

  /**
   * Contribution findFirst
   */
  export type ContributionFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Contribution
     */
    select?: ContributionSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ContributionInclude<ExtArgs> | null
    /**
     * Filter, which Contribution to fetch.
     */
    where?: ContributionWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Contributions to fetch.
     */
    orderBy?: ContributionOrderByWithRelationInput | ContributionOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for Contributions.
     */
    cursor?: ContributionWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Contributions 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` Contributions.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of Contributions.
     */
    distinct?: ContributionScalarFieldEnum | ContributionScalarFieldEnum[]
  }

  /**
   * Contribution findFirstOrThrow
   */
  export type ContributionFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Contribution
     */
    select?: ContributionSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ContributionInclude<ExtArgs> | null
    /**
     * Filter, which Contribution to fetch.
     */
    where?: ContributionWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Contributions to fetch.
     */
    orderBy?: ContributionOrderByWithRelationInput | ContributionOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for Contributions.
     */
    cursor?: ContributionWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Contributions 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` Contributions.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of Contributions.
     */
    distinct?: ContributionScalarFieldEnum | ContributionScalarFieldEnum[]
  }

  /**
   * Contribution findMany
   */
  export type ContributionFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Contribution
     */
    select?: ContributionSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ContributionInclude<ExtArgs> | null
    /**
     * Filter, which Contributions to fetch.
     */
    where?: ContributionWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Contributions to fetch.
     */
    orderBy?: ContributionOrderByWithRelationInput | ContributionOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing Contributions.
     */
    cursor?: ContributionWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Contributions 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` Contributions.
     */
    skip?: number
    distinct?: ContributionScalarFieldEnum | ContributionScalarFieldEnum[]
  }

  /**
   * Contribution create
   */
  export type ContributionCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Contribution
     */
    select?: ContributionSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ContributionInclude<ExtArgs> | null
    /**
     * The data needed to create a Contribution.
     */
    data: XOR<ContributionCreateInput, ContributionUncheckedCreateInput>
  }

  /**
   * Contribution createMany
   */
  export type ContributionCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many Contributions.
     */
    data: ContributionCreateManyInput | ContributionCreateManyInput[]
    skipDuplicates?: boolean
  }

  /**
   * Contribution update
   */
  export type ContributionUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Contribution
     */
    select?: ContributionSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ContributionInclude<ExtArgs> | null
    /**
     * The data needed to update a Contribution.
     */
    data: XOR<ContributionUpdateInput, ContributionUncheckedUpdateInput>
    /**
     * Choose, which Contribution to update.
     */
    where: ContributionWhereUniqueInput
  }

  /**
   * Contribution updateMany
   */
  export type ContributionUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update Contributions.
     */
    data: XOR<ContributionUpdateManyMutationInput, ContributionUncheckedUpdateManyInput>
    /**
     * Filter which Contributions to update
     */
    where?: ContributionWhereInput
  }

  /**
   * Contribution upsert
   */
  export type ContributionUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Contribution
     */
    select?: ContributionSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ContributionInclude<ExtArgs> | null
    /**
     * The filter to search for the Contribution to update in case it exists.
     */
    where: ContributionWhereUniqueInput
    /**
     * In case the Contribution found by the `where` argument doesn't exist, create a new Contribution with this data.
     */
    create: XOR<ContributionCreateInput, ContributionUncheckedCreateInput>
    /**
     * In case the Contribution was found with the provided `where` argument, update it with this data.
     */
    update: XOR<ContributionUpdateInput, ContributionUncheckedUpdateInput>
  }

  /**
   * Contribution delete
   */
  export type ContributionDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Contribution
     */
    select?: ContributionSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ContributionInclude<ExtArgs> | null
    /**
     * Filter which Contribution to delete.
     */
    where: ContributionWhereUniqueInput
  }

  /**
   * Contribution deleteMany
   */
  export type ContributionDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which Contributions to delete
     */
    where?: ContributionWhereInput
  }

  /**
   * Contribution.coverageDecision
   */
  export type Contribution$coverageDecisionArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CoverageDecision
     */
    select?: CoverageDecisionSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CoverageDecisionInclude<ExtArgs> | null
    where?: CoverageDecisionWhereInput
  }

  /**
   * Contribution without action
   */
  export type ContributionDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Contribution
     */
    select?: ContributionSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ContributionInclude<ExtArgs> | null
  }


  /**
   * Model Cashout
   */

  export type AggregateCashout = {
    _count: CashoutCountAggregateOutputType | null
    _avg: CashoutAvgAggregateOutputType | null
    _sum: CashoutSumAggregateOutputType | null
    _min: CashoutMinAggregateOutputType | null
    _max: CashoutMaxAggregateOutputType | null
  }

  export type CashoutAvgAggregateOutputType = {
    valorBruto: number | null
    valorTaxaPrincipal: number | null
    valorReservaTecnica: number | null
    valorLiquido: number | null
  }

  export type CashoutSumAggregateOutputType = {
    valorBruto: number | null
    valorTaxaPrincipal: number | null
    valorReservaTecnica: number | null
    valorLiquido: number | null
  }

  export type CashoutMinAggregateOutputType = {
    id: string | null
    monthlyCycleId: string | null
    beneficiarioUserId: string | null
    valorBruto: number | null
    valorTaxaPrincipal: number | null
    valorReservaTecnica: number | null
    valorLiquido: number | null
    dataPrevista: Date | null
    dataExecucao: Date | null
    status: string | null
    contaDestino: string | null
    refTransferencia: string | null
    parcialMotivo: string | null
    createdAt: Date | null
    updatedAt: Date | null
  }

  export type CashoutMaxAggregateOutputType = {
    id: string | null
    monthlyCycleId: string | null
    beneficiarioUserId: string | null
    valorBruto: number | null
    valorTaxaPrincipal: number | null
    valorReservaTecnica: number | null
    valorLiquido: number | null
    dataPrevista: Date | null
    dataExecucao: Date | null
    status: string | null
    contaDestino: string | null
    refTransferencia: string | null
    parcialMotivo: string | null
    createdAt: Date | null
    updatedAt: Date | null
  }

  export type CashoutCountAggregateOutputType = {
    id: number
    monthlyCycleId: number
    beneficiarioUserId: number
    valorBruto: number
    valorTaxaPrincipal: number
    valorReservaTecnica: number
    valorLiquido: number
    dataPrevista: number
    dataExecucao: number
    status: number
    contaDestino: number
    refTransferencia: number
    parcialMotivo: number
    createdAt: number
    updatedAt: number
    _all: number
  }


  export type CashoutAvgAggregateInputType = {
    valorBruto?: true
    valorTaxaPrincipal?: true
    valorReservaTecnica?: true
    valorLiquido?: true
  }

  export type CashoutSumAggregateInputType = {
    valorBruto?: true
    valorTaxaPrincipal?: true
    valorReservaTecnica?: true
    valorLiquido?: true
  }

  export type CashoutMinAggregateInputType = {
    id?: true
    monthlyCycleId?: true
    beneficiarioUserId?: true
    valorBruto?: true
    valorTaxaPrincipal?: true
    valorReservaTecnica?: true
    valorLiquido?: true
    dataPrevista?: true
    dataExecucao?: true
    status?: true
    contaDestino?: true
    refTransferencia?: true
    parcialMotivo?: true
    createdAt?: true
    updatedAt?: true
  }

  export type CashoutMaxAggregateInputType = {
    id?: true
    monthlyCycleId?: true
    beneficiarioUserId?: true
    valorBruto?: true
    valorTaxaPrincipal?: true
    valorReservaTecnica?: true
    valorLiquido?: true
    dataPrevista?: true
    dataExecucao?: true
    status?: true
    contaDestino?: true
    refTransferencia?: true
    parcialMotivo?: true
    createdAt?: true
    updatedAt?: true
  }

  export type CashoutCountAggregateInputType = {
    id?: true
    monthlyCycleId?: true
    beneficiarioUserId?: true
    valorBruto?: true
    valorTaxaPrincipal?: true
    valorReservaTecnica?: true
    valorLiquido?: true
    dataPrevista?: true
    dataExecucao?: true
    status?: true
    contaDestino?: true
    refTransferencia?: true
    parcialMotivo?: true
    createdAt?: true
    updatedAt?: true
    _all?: true
  }

  export type CashoutAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which Cashout to aggregate.
     */
    where?: CashoutWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Cashouts to fetch.
     */
    orderBy?: CashoutOrderByWithRelationInput | CashoutOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: CashoutWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Cashouts 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` Cashouts.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned Cashouts
    **/
    _count?: true | CashoutCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to average
    **/
    _avg?: CashoutAvgAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to sum
    **/
    _sum?: CashoutSumAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: CashoutMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: CashoutMaxAggregateInputType
  }

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




  export type CashoutGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: CashoutWhereInput
    orderBy?: CashoutOrderByWithAggregationInput | CashoutOrderByWithAggregationInput[]
    by: CashoutScalarFieldEnum[] | CashoutScalarFieldEnum
    having?: CashoutScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: CashoutCountAggregateInputType | true
    _avg?: CashoutAvgAggregateInputType
    _sum?: CashoutSumAggregateInputType
    _min?: CashoutMinAggregateInputType
    _max?: CashoutMaxAggregateInputType
  }

  export type CashoutGroupByOutputType = {
    id: string
    monthlyCycleId: string
    beneficiarioUserId: string
    valorBruto: number
    valorTaxaPrincipal: number
    valorReservaTecnica: number
    valorLiquido: number
    dataPrevista: Date
    dataExecucao: Date | null
    status: string
    contaDestino: string | null
    refTransferencia: string | null
    parcialMotivo: string | null
    createdAt: Date
    updatedAt: Date
    _count: CashoutCountAggregateOutputType | null
    _avg: CashoutAvgAggregateOutputType | null
    _sum: CashoutSumAggregateOutputType | null
    _min: CashoutMinAggregateOutputType | null
    _max: CashoutMaxAggregateOutputType | null
  }

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


  export type CashoutSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    monthlyCycleId?: boolean
    beneficiarioUserId?: boolean
    valorBruto?: boolean
    valorTaxaPrincipal?: boolean
    valorReservaTecnica?: boolean
    valorLiquido?: boolean
    dataPrevista?: boolean
    dataExecucao?: boolean
    status?: boolean
    contaDestino?: boolean
    refTransferencia?: boolean
    parcialMotivo?: boolean
    createdAt?: boolean
    updatedAt?: boolean
    monthlyCycle?: boolean | MonthlyCycleDefaultArgs<ExtArgs>
    beneficiarioUser?: boolean | UserDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["cashout"]>


  export type CashoutSelectScalar = {
    id?: boolean
    monthlyCycleId?: boolean
    beneficiarioUserId?: boolean
    valorBruto?: boolean
    valorTaxaPrincipal?: boolean
    valorReservaTecnica?: boolean
    valorLiquido?: boolean
    dataPrevista?: boolean
    dataExecucao?: boolean
    status?: boolean
    contaDestino?: boolean
    refTransferencia?: boolean
    parcialMotivo?: boolean
    createdAt?: boolean
    updatedAt?: boolean
  }

  export type CashoutInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    monthlyCycle?: boolean | MonthlyCycleDefaultArgs<ExtArgs>
    beneficiarioUser?: boolean | UserDefaultArgs<ExtArgs>
  }

  export type $CashoutPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "Cashout"
    objects: {
      monthlyCycle: Prisma.$MonthlyCyclePayload<ExtArgs>
      beneficiarioUser: Prisma.$UserPayload<ExtArgs>
    }
    scalars: $Extensions.GetPayloadResult<{
      id: string
      monthlyCycleId: string
      beneficiarioUserId: string
      valorBruto: number
      valorTaxaPrincipal: number
      valorReservaTecnica: number
      valorLiquido: number
      dataPrevista: Date
      dataExecucao: Date | null
      status: string
      contaDestino: string | null
      refTransferencia: string | null
      parcialMotivo: string | null
      createdAt: Date
      updatedAt: Date
    }, ExtArgs["result"]["cashout"]>
    composites: {}
  }

  type CashoutGetPayload<S extends boolean | null | undefined | CashoutDefaultArgs> = $Result.GetResult<Prisma.$CashoutPayload, S>

  type CashoutCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = 
    Omit<CashoutFindManyArgs, 'select' | 'include' | 'distinct'> & {
      select?: CashoutCountAggregateInputType | true
    }

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

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

    /**
     * Find the first Cashout 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 {CashoutFindFirstArgs} args - Arguments to find a Cashout
     * @example
     * // Get one Cashout
     * const cashout = await prisma.cashout.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends CashoutFindFirstArgs>(args?: SelectSubset<T, CashoutFindFirstArgs<ExtArgs>>): Prisma__CashoutClient<$Result.GetResult<Prisma.$CashoutPayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>

    /**
     * Find the first Cashout 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 {CashoutFindFirstOrThrowArgs} args - Arguments to find a Cashout
     * @example
     * // Get one Cashout
     * const cashout = await prisma.cashout.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends CashoutFindFirstOrThrowArgs>(args?: SelectSubset<T, CashoutFindFirstOrThrowArgs<ExtArgs>>): Prisma__CashoutClient<$Result.GetResult<Prisma.$CashoutPayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>

    /**
     * Find zero or more Cashouts 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 {CashoutFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all Cashouts
     * const cashouts = await prisma.cashout.findMany()
     * 
     * // Get first 10 Cashouts
     * const cashouts = await prisma.cashout.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const cashoutWithIdOnly = await prisma.cashout.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends CashoutFindManyArgs>(args?: SelectSubset<T, CashoutFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$CashoutPayload<ExtArgs>, T, "findMany">>

    /**
     * Create a Cashout.
     * @param {CashoutCreateArgs} args - Arguments to create a Cashout.
     * @example
     * // Create one Cashout
     * const Cashout = await prisma.cashout.create({
     *   data: {
     *     // ... data to create a Cashout
     *   }
     * })
     * 
     */
    create<T extends CashoutCreateArgs>(args: SelectSubset<T, CashoutCreateArgs<ExtArgs>>): Prisma__CashoutClient<$Result.GetResult<Prisma.$CashoutPayload<ExtArgs>, T, "create">, never, ExtArgs>

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

    /**
     * Delete a Cashout.
     * @param {CashoutDeleteArgs} args - Arguments to delete one Cashout.
     * @example
     * // Delete one Cashout
     * const Cashout = await prisma.cashout.delete({
     *   where: {
     *     // ... filter to delete one Cashout
     *   }
     * })
     * 
     */
    delete<T extends CashoutDeleteArgs>(args: SelectSubset<T, CashoutDeleteArgs<ExtArgs>>): Prisma__CashoutClient<$Result.GetResult<Prisma.$CashoutPayload<ExtArgs>, T, "delete">, never, ExtArgs>

    /**
     * Update one Cashout.
     * @param {CashoutUpdateArgs} args - Arguments to update one Cashout.
     * @example
     * // Update one Cashout
     * const cashout = await prisma.cashout.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends CashoutUpdateArgs>(args: SelectSubset<T, CashoutUpdateArgs<ExtArgs>>): Prisma__CashoutClient<$Result.GetResult<Prisma.$CashoutPayload<ExtArgs>, T, "update">, never, ExtArgs>

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

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

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


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

    /**
     * Allows you to perform aggregations operations on a Cashout.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {CashoutAggregateArgs} 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 CashoutAggregateArgs>(args: Subset<T, CashoutAggregateArgs>): Prisma.PrismaPromise<GetCashoutAggregateType<T>>

    /**
     * Group by Cashout.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {CashoutGroupByArgs} 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 CashoutGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: CashoutGroupByArgs['orderBy'] }
        : { orderBy?: CashoutGroupByArgs['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, CashoutGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetCashoutGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the Cashout model
   */
  readonly fields: CashoutFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for Cashout.
   * 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__CashoutClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
    readonly [Symbol.toStringTag]: "PrismaPromise"
    monthlyCycle<T extends MonthlyCycleDefaultArgs<ExtArgs> = {}>(args?: Subset<T, MonthlyCycleDefaultArgs<ExtArgs>>): Prisma__MonthlyCycleClient<$Result.GetResult<Prisma.$MonthlyCyclePayload<ExtArgs>, T, "findUniqueOrThrow"> | Null, Null, ExtArgs>
    beneficiarioUser<T extends UserDefaultArgs<ExtArgs> = {}>(args?: Subset<T, UserDefaultArgs<ExtArgs>>): Prisma__UserClient<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "findUniqueOrThrow"> | Null, Null, ExtArgs>
    /**
     * 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 Cashout model
   */ 
  interface CashoutFieldRefs {
    readonly id: FieldRef<"Cashout", 'String'>
    readonly monthlyCycleId: FieldRef<"Cashout", 'String'>
    readonly beneficiarioUserId: FieldRef<"Cashout", 'String'>
    readonly valorBruto: FieldRef<"Cashout", 'Float'>
    readonly valorTaxaPrincipal: FieldRef<"Cashout", 'Float'>
    readonly valorReservaTecnica: FieldRef<"Cashout", 'Float'>
    readonly valorLiquido: FieldRef<"Cashout", 'Float'>
    readonly dataPrevista: FieldRef<"Cashout", 'DateTime'>
    readonly dataExecucao: FieldRef<"Cashout", 'DateTime'>
    readonly status: FieldRef<"Cashout", 'String'>
    readonly contaDestino: FieldRef<"Cashout", 'String'>
    readonly refTransferencia: FieldRef<"Cashout", 'String'>
    readonly parcialMotivo: FieldRef<"Cashout", 'String'>
    readonly createdAt: FieldRef<"Cashout", 'DateTime'>
    readonly updatedAt: FieldRef<"Cashout", 'DateTime'>
  }
    

  // Custom InputTypes
  /**
   * Cashout findUnique
   */
  export type CashoutFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Cashout
     */
    select?: CashoutSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CashoutInclude<ExtArgs> | null
    /**
     * Filter, which Cashout to fetch.
     */
    where: CashoutWhereUniqueInput
  }

  /**
   * Cashout findUniqueOrThrow
   */
  export type CashoutFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Cashout
     */
    select?: CashoutSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CashoutInclude<ExtArgs> | null
    /**
     * Filter, which Cashout to fetch.
     */
    where: CashoutWhereUniqueInput
  }

  /**
   * Cashout findFirst
   */
  export type CashoutFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Cashout
     */
    select?: CashoutSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CashoutInclude<ExtArgs> | null
    /**
     * Filter, which Cashout to fetch.
     */
    where?: CashoutWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Cashouts to fetch.
     */
    orderBy?: CashoutOrderByWithRelationInput | CashoutOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for Cashouts.
     */
    cursor?: CashoutWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Cashouts 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` Cashouts.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of Cashouts.
     */
    distinct?: CashoutScalarFieldEnum | CashoutScalarFieldEnum[]
  }

  /**
   * Cashout findFirstOrThrow
   */
  export type CashoutFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Cashout
     */
    select?: CashoutSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CashoutInclude<ExtArgs> | null
    /**
     * Filter, which Cashout to fetch.
     */
    where?: CashoutWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Cashouts to fetch.
     */
    orderBy?: CashoutOrderByWithRelationInput | CashoutOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for Cashouts.
     */
    cursor?: CashoutWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Cashouts 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` Cashouts.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of Cashouts.
     */
    distinct?: CashoutScalarFieldEnum | CashoutScalarFieldEnum[]
  }

  /**
   * Cashout findMany
   */
  export type CashoutFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Cashout
     */
    select?: CashoutSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CashoutInclude<ExtArgs> | null
    /**
     * Filter, which Cashouts to fetch.
     */
    where?: CashoutWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Cashouts to fetch.
     */
    orderBy?: CashoutOrderByWithRelationInput | CashoutOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing Cashouts.
     */
    cursor?: CashoutWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Cashouts 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` Cashouts.
     */
    skip?: number
    distinct?: CashoutScalarFieldEnum | CashoutScalarFieldEnum[]
  }

  /**
   * Cashout create
   */
  export type CashoutCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Cashout
     */
    select?: CashoutSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CashoutInclude<ExtArgs> | null
    /**
     * The data needed to create a Cashout.
     */
    data: XOR<CashoutCreateInput, CashoutUncheckedCreateInput>
  }

  /**
   * Cashout createMany
   */
  export type CashoutCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many Cashouts.
     */
    data: CashoutCreateManyInput | CashoutCreateManyInput[]
    skipDuplicates?: boolean
  }

  /**
   * Cashout update
   */
  export type CashoutUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Cashout
     */
    select?: CashoutSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CashoutInclude<ExtArgs> | null
    /**
     * The data needed to update a Cashout.
     */
    data: XOR<CashoutUpdateInput, CashoutUncheckedUpdateInput>
    /**
     * Choose, which Cashout to update.
     */
    where: CashoutWhereUniqueInput
  }

  /**
   * Cashout updateMany
   */
  export type CashoutUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update Cashouts.
     */
    data: XOR<CashoutUpdateManyMutationInput, CashoutUncheckedUpdateManyInput>
    /**
     * Filter which Cashouts to update
     */
    where?: CashoutWhereInput
  }

  /**
   * Cashout upsert
   */
  export type CashoutUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Cashout
     */
    select?: CashoutSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CashoutInclude<ExtArgs> | null
    /**
     * The filter to search for the Cashout to update in case it exists.
     */
    where: CashoutWhereUniqueInput
    /**
     * In case the Cashout found by the `where` argument doesn't exist, create a new Cashout with this data.
     */
    create: XOR<CashoutCreateInput, CashoutUncheckedCreateInput>
    /**
     * In case the Cashout was found with the provided `where` argument, update it with this data.
     */
    update: XOR<CashoutUpdateInput, CashoutUncheckedUpdateInput>
  }

  /**
   * Cashout delete
   */
  export type CashoutDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Cashout
     */
    select?: CashoutSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CashoutInclude<ExtArgs> | null
    /**
     * Filter which Cashout to delete.
     */
    where: CashoutWhereUniqueInput
  }

  /**
   * Cashout deleteMany
   */
  export type CashoutDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which Cashouts to delete
     */
    where?: CashoutWhereInput
  }

  /**
   * Cashout without action
   */
  export type CashoutDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Cashout
     */
    select?: CashoutSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CashoutInclude<ExtArgs> | null
  }


  /**
   * Model Loan
   */

  export type AggregateLoan = {
    _count: LoanCountAggregateOutputType | null
    _avg: LoanAvgAggregateOutputType | null
    _sum: LoanSumAggregateOutputType | null
    _min: LoanMinAggregateOutputType | null
    _max: LoanMaxAggregateOutputType | null
  }

  export type LoanAvgAggregateOutputType = {
    valorCapital: number | null
    taxaEmprestimo: number | null
    valorTotalDevido: number | null
    jurosMoraAcumulados: number | null
  }

  export type LoanSumAggregateOutputType = {
    valorCapital: number | null
    taxaEmprestimo: number | null
    valorTotalDevido: number | null
    jurosMoraAcumulados: number | null
  }

  export type LoanMinAggregateOutputType = {
    id: string | null
    userId: string | null
    monthlyCycleId: string | null
    contributionId: string | null
    valorCapital: number | null
    taxaEmprestimo: number | null
    valorTotalDevido: number | null
    jurosMoraAcumulados: number | null
    dataInicio: Date | null
    dataPagamento: Date | null
    status: string | null
    createdAt: Date | null
    updatedAt: Date | null
  }

  export type LoanMaxAggregateOutputType = {
    id: string | null
    userId: string | null
    monthlyCycleId: string | null
    contributionId: string | null
    valorCapital: number | null
    taxaEmprestimo: number | null
    valorTotalDevido: number | null
    jurosMoraAcumulados: number | null
    dataInicio: Date | null
    dataPagamento: Date | null
    status: string | null
    createdAt: Date | null
    updatedAt: Date | null
  }

  export type LoanCountAggregateOutputType = {
    id: number
    userId: number
    monthlyCycleId: number
    contributionId: number
    valorCapital: number
    taxaEmprestimo: number
    valorTotalDevido: number
    jurosMoraAcumulados: number
    dataInicio: number
    dataPagamento: number
    status: number
    createdAt: number
    updatedAt: number
    _all: number
  }


  export type LoanAvgAggregateInputType = {
    valorCapital?: true
    taxaEmprestimo?: true
    valorTotalDevido?: true
    jurosMoraAcumulados?: true
  }

  export type LoanSumAggregateInputType = {
    valorCapital?: true
    taxaEmprestimo?: true
    valorTotalDevido?: true
    jurosMoraAcumulados?: true
  }

  export type LoanMinAggregateInputType = {
    id?: true
    userId?: true
    monthlyCycleId?: true
    contributionId?: true
    valorCapital?: true
    taxaEmprestimo?: true
    valorTotalDevido?: true
    jurosMoraAcumulados?: true
    dataInicio?: true
    dataPagamento?: true
    status?: true
    createdAt?: true
    updatedAt?: true
  }

  export type LoanMaxAggregateInputType = {
    id?: true
    userId?: true
    monthlyCycleId?: true
    contributionId?: true
    valorCapital?: true
    taxaEmprestimo?: true
    valorTotalDevido?: true
    jurosMoraAcumulados?: true
    dataInicio?: true
    dataPagamento?: true
    status?: true
    createdAt?: true
    updatedAt?: true
  }

  export type LoanCountAggregateInputType = {
    id?: true
    userId?: true
    monthlyCycleId?: true
    contributionId?: true
    valorCapital?: true
    taxaEmprestimo?: true
    valorTotalDevido?: true
    jurosMoraAcumulados?: true
    dataInicio?: true
    dataPagamento?: true
    status?: true
    createdAt?: true
    updatedAt?: true
    _all?: true
  }

  export type LoanAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which Loan to aggregate.
     */
    where?: LoanWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Loans to fetch.
     */
    orderBy?: LoanOrderByWithRelationInput | LoanOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: LoanWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Loans 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` Loans.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned Loans
    **/
    _count?: true | LoanCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to average
    **/
    _avg?: LoanAvgAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to sum
    **/
    _sum?: LoanSumAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: LoanMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: LoanMaxAggregateInputType
  }

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




  export type LoanGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: LoanWhereInput
    orderBy?: LoanOrderByWithAggregationInput | LoanOrderByWithAggregationInput[]
    by: LoanScalarFieldEnum[] | LoanScalarFieldEnum
    having?: LoanScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: LoanCountAggregateInputType | true
    _avg?: LoanAvgAggregateInputType
    _sum?: LoanSumAggregateInputType
    _min?: LoanMinAggregateInputType
    _max?: LoanMaxAggregateInputType
  }

  export type LoanGroupByOutputType = {
    id: string
    userId: string
    monthlyCycleId: string
    contributionId: string | null
    valorCapital: number
    taxaEmprestimo: number
    valorTotalDevido: number
    jurosMoraAcumulados: number
    dataInicio: Date
    dataPagamento: Date | null
    status: string
    createdAt: Date
    updatedAt: Date
    _count: LoanCountAggregateOutputType | null
    _avg: LoanAvgAggregateOutputType | null
    _sum: LoanSumAggregateOutputType | null
    _min: LoanMinAggregateOutputType | null
    _max: LoanMaxAggregateOutputType | null
  }

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


  export type LoanSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    userId?: boolean
    monthlyCycleId?: boolean
    contributionId?: boolean
    valorCapital?: boolean
    taxaEmprestimo?: boolean
    valorTotalDevido?: boolean
    jurosMoraAcumulados?: boolean
    dataInicio?: boolean
    dataPagamento?: boolean
    status?: boolean
    createdAt?: boolean
    updatedAt?: boolean
    user?: boolean | UserDefaultArgs<ExtArgs>
    monthlyCycle?: boolean | MonthlyCycleDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["loan"]>


  export type LoanSelectScalar = {
    id?: boolean
    userId?: boolean
    monthlyCycleId?: boolean
    contributionId?: boolean
    valorCapital?: boolean
    taxaEmprestimo?: boolean
    valorTotalDevido?: boolean
    jurosMoraAcumulados?: boolean
    dataInicio?: boolean
    dataPagamento?: boolean
    status?: boolean
    createdAt?: boolean
    updatedAt?: boolean
  }

  export type LoanInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    user?: boolean | UserDefaultArgs<ExtArgs>
    monthlyCycle?: boolean | MonthlyCycleDefaultArgs<ExtArgs>
  }

  export type $LoanPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "Loan"
    objects: {
      user: Prisma.$UserPayload<ExtArgs>
      monthlyCycle: Prisma.$MonthlyCyclePayload<ExtArgs>
    }
    scalars: $Extensions.GetPayloadResult<{
      id: string
      userId: string
      monthlyCycleId: string
      contributionId: string | null
      valorCapital: number
      taxaEmprestimo: number
      valorTotalDevido: number
      jurosMoraAcumulados: number
      dataInicio: Date
      dataPagamento: Date | null
      status: string
      createdAt: Date
      updatedAt: Date
    }, ExtArgs["result"]["loan"]>
    composites: {}
  }

  type LoanGetPayload<S extends boolean | null | undefined | LoanDefaultArgs> = $Result.GetResult<Prisma.$LoanPayload, S>

  type LoanCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = 
    Omit<LoanFindManyArgs, 'select' | 'include' | 'distinct'> & {
      select?: LoanCountAggregateInputType | true
    }

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

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

    /**
     * Find the first Loan 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 {LoanFindFirstArgs} args - Arguments to find a Loan
     * @example
     * // Get one Loan
     * const loan = await prisma.loan.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends LoanFindFirstArgs>(args?: SelectSubset<T, LoanFindFirstArgs<ExtArgs>>): Prisma__LoanClient<$Result.GetResult<Prisma.$LoanPayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>

    /**
     * Find the first Loan 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 {LoanFindFirstOrThrowArgs} args - Arguments to find a Loan
     * @example
     * // Get one Loan
     * const loan = await prisma.loan.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends LoanFindFirstOrThrowArgs>(args?: SelectSubset<T, LoanFindFirstOrThrowArgs<ExtArgs>>): Prisma__LoanClient<$Result.GetResult<Prisma.$LoanPayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>

    /**
     * Find zero or more Loans 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 {LoanFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all Loans
     * const loans = await prisma.loan.findMany()
     * 
     * // Get first 10 Loans
     * const loans = await prisma.loan.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const loanWithIdOnly = await prisma.loan.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends LoanFindManyArgs>(args?: SelectSubset<T, LoanFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$LoanPayload<ExtArgs>, T, "findMany">>

    /**
     * Create a Loan.
     * @param {LoanCreateArgs} args - Arguments to create a Loan.
     * @example
     * // Create one Loan
     * const Loan = await prisma.loan.create({
     *   data: {
     *     // ... data to create a Loan
     *   }
     * })
     * 
     */
    create<T extends LoanCreateArgs>(args: SelectSubset<T, LoanCreateArgs<ExtArgs>>): Prisma__LoanClient<$Result.GetResult<Prisma.$LoanPayload<ExtArgs>, T, "create">, never, ExtArgs>

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

    /**
     * Delete a Loan.
     * @param {LoanDeleteArgs} args - Arguments to delete one Loan.
     * @example
     * // Delete one Loan
     * const Loan = await prisma.loan.delete({
     *   where: {
     *     // ... filter to delete one Loan
     *   }
     * })
     * 
     */
    delete<T extends LoanDeleteArgs>(args: SelectSubset<T, LoanDeleteArgs<ExtArgs>>): Prisma__LoanClient<$Result.GetResult<Prisma.$LoanPayload<ExtArgs>, T, "delete">, never, ExtArgs>

    /**
     * Update one Loan.
     * @param {LoanUpdateArgs} args - Arguments to update one Loan.
     * @example
     * // Update one Loan
     * const loan = await prisma.loan.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends LoanUpdateArgs>(args: SelectSubset<T, LoanUpdateArgs<ExtArgs>>): Prisma__LoanClient<$Result.GetResult<Prisma.$LoanPayload<ExtArgs>, T, "update">, never, ExtArgs>

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

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

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


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

    /**
     * Allows you to perform aggregations operations on a Loan.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {LoanAggregateArgs} 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 LoanAggregateArgs>(args: Subset<T, LoanAggregateArgs>): Prisma.PrismaPromise<GetLoanAggregateType<T>>

    /**
     * Group by Loan.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {LoanGroupByArgs} 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 LoanGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: LoanGroupByArgs['orderBy'] }
        : { orderBy?: LoanGroupByArgs['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, LoanGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetLoanGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the Loan model
   */
  readonly fields: LoanFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for Loan.
   * 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__LoanClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> 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"> | Null, Null, ExtArgs>
    monthlyCycle<T extends MonthlyCycleDefaultArgs<ExtArgs> = {}>(args?: Subset<T, MonthlyCycleDefaultArgs<ExtArgs>>): Prisma__MonthlyCycleClient<$Result.GetResult<Prisma.$MonthlyCyclePayload<ExtArgs>, T, "findUniqueOrThrow"> | Null, Null, ExtArgs>
    /**
     * 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 Loan model
   */ 
  interface LoanFieldRefs {
    readonly id: FieldRef<"Loan", 'String'>
    readonly userId: FieldRef<"Loan", 'String'>
    readonly monthlyCycleId: FieldRef<"Loan", 'String'>
    readonly contributionId: FieldRef<"Loan", 'String'>
    readonly valorCapital: FieldRef<"Loan", 'Float'>
    readonly taxaEmprestimo: FieldRef<"Loan", 'Float'>
    readonly valorTotalDevido: FieldRef<"Loan", 'Float'>
    readonly jurosMoraAcumulados: FieldRef<"Loan", 'Float'>
    readonly dataInicio: FieldRef<"Loan", 'DateTime'>
    readonly dataPagamento: FieldRef<"Loan", 'DateTime'>
    readonly status: FieldRef<"Loan", 'String'>
    readonly createdAt: FieldRef<"Loan", 'DateTime'>
    readonly updatedAt: FieldRef<"Loan", 'DateTime'>
  }
    

  // Custom InputTypes
  /**
   * Loan findUnique
   */
  export type LoanFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Loan
     */
    select?: LoanSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: LoanInclude<ExtArgs> | null
    /**
     * Filter, which Loan to fetch.
     */
    where: LoanWhereUniqueInput
  }

  /**
   * Loan findUniqueOrThrow
   */
  export type LoanFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Loan
     */
    select?: LoanSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: LoanInclude<ExtArgs> | null
    /**
     * Filter, which Loan to fetch.
     */
    where: LoanWhereUniqueInput
  }

  /**
   * Loan findFirst
   */
  export type LoanFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Loan
     */
    select?: LoanSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: LoanInclude<ExtArgs> | null
    /**
     * Filter, which Loan to fetch.
     */
    where?: LoanWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Loans to fetch.
     */
    orderBy?: LoanOrderByWithRelationInput | LoanOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for Loans.
     */
    cursor?: LoanWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Loans 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` Loans.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of Loans.
     */
    distinct?: LoanScalarFieldEnum | LoanScalarFieldEnum[]
  }

  /**
   * Loan findFirstOrThrow
   */
  export type LoanFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Loan
     */
    select?: LoanSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: LoanInclude<ExtArgs> | null
    /**
     * Filter, which Loan to fetch.
     */
    where?: LoanWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Loans to fetch.
     */
    orderBy?: LoanOrderByWithRelationInput | LoanOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for Loans.
     */
    cursor?: LoanWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Loans 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` Loans.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of Loans.
     */
    distinct?: LoanScalarFieldEnum | LoanScalarFieldEnum[]
  }

  /**
   * Loan findMany
   */
  export type LoanFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Loan
     */
    select?: LoanSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: LoanInclude<ExtArgs> | null
    /**
     * Filter, which Loans to fetch.
     */
    where?: LoanWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Loans to fetch.
     */
    orderBy?: LoanOrderByWithRelationInput | LoanOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing Loans.
     */
    cursor?: LoanWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Loans 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` Loans.
     */
    skip?: number
    distinct?: LoanScalarFieldEnum | LoanScalarFieldEnum[]
  }

  /**
   * Loan create
   */
  export type LoanCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Loan
     */
    select?: LoanSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: LoanInclude<ExtArgs> | null
    /**
     * The data needed to create a Loan.
     */
    data: XOR<LoanCreateInput, LoanUncheckedCreateInput>
  }

  /**
   * Loan createMany
   */
  export type LoanCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many Loans.
     */
    data: LoanCreateManyInput | LoanCreateManyInput[]
    skipDuplicates?: boolean
  }

  /**
   * Loan update
   */
  export type LoanUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Loan
     */
    select?: LoanSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: LoanInclude<ExtArgs> | null
    /**
     * The data needed to update a Loan.
     */
    data: XOR<LoanUpdateInput, LoanUncheckedUpdateInput>
    /**
     * Choose, which Loan to update.
     */
    where: LoanWhereUniqueInput
  }

  /**
   * Loan updateMany
   */
  export type LoanUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update Loans.
     */
    data: XOR<LoanUpdateManyMutationInput, LoanUncheckedUpdateManyInput>
    /**
     * Filter which Loans to update
     */
    where?: LoanWhereInput
  }

  /**
   * Loan upsert
   */
  export type LoanUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Loan
     */
    select?: LoanSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: LoanInclude<ExtArgs> | null
    /**
     * The filter to search for the Loan to update in case it exists.
     */
    where: LoanWhereUniqueInput
    /**
     * In case the Loan found by the `where` argument doesn't exist, create a new Loan with this data.
     */
    create: XOR<LoanCreateInput, LoanUncheckedCreateInput>
    /**
     * In case the Loan was found with the provided `where` argument, update it with this data.
     */
    update: XOR<LoanUpdateInput, LoanUncheckedUpdateInput>
  }

  /**
   * Loan delete
   */
  export type LoanDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Loan
     */
    select?: LoanSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: LoanInclude<ExtArgs> | null
    /**
     * Filter which Loan to delete.
     */
    where: LoanWhereUniqueInput
  }

  /**
   * Loan deleteMany
   */
  export type LoanDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which Loans to delete
     */
    where?: LoanWhereInput
  }

  /**
   * Loan without action
   */
  export type LoanDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Loan
     */
    select?: LoanSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: LoanInclude<ExtArgs> | null
  }


  /**
   * Model CoverageDecision
   */

  export type AggregateCoverageDecision = {
    _count: CoverageDecisionCountAggregateOutputType | null
    _avg: CoverageDecisionAvgAggregateOutputType | null
    _sum: CoverageDecisionSumAggregateOutputType | null
    _min: CoverageDecisionMinAggregateOutputType | null
    _max: CoverageDecisionMaxAggregateOutputType | null
  }

  export type CoverageDecisionAvgAggregateOutputType = {
    scoreNoMomento: number | null
    historicoInadimplencias: number | null
  }

  export type CoverageDecisionSumAggregateOutputType = {
    scoreNoMomento: number | null
    historicoInadimplencias: number | null
  }

  export type CoverageDecisionMinAggregateOutputType = {
    id: string | null
    contributionId: string | null
    decisao: string | null
    motivo: string | null
    scoreNoMomento: number | null
    historicoInadimplencias: number | null
    decisorUserId: string | null
    decisorSistema: boolean | null
    createdAt: Date | null
  }

  export type CoverageDecisionMaxAggregateOutputType = {
    id: string | null
    contributionId: string | null
    decisao: string | null
    motivo: string | null
    scoreNoMomento: number | null
    historicoInadimplencias: number | null
    decisorUserId: string | null
    decisorSistema: boolean | null
    createdAt: Date | null
  }

  export type CoverageDecisionCountAggregateOutputType = {
    id: number
    contributionId: number
    decisao: number
    motivo: number
    scoreNoMomento: number
    historicoInadimplencias: number
    decisorUserId: number
    decisorSistema: number
    createdAt: number
    _all: number
  }


  export type CoverageDecisionAvgAggregateInputType = {
    scoreNoMomento?: true
    historicoInadimplencias?: true
  }

  export type CoverageDecisionSumAggregateInputType = {
    scoreNoMomento?: true
    historicoInadimplencias?: true
  }

  export type CoverageDecisionMinAggregateInputType = {
    id?: true
    contributionId?: true
    decisao?: true
    motivo?: true
    scoreNoMomento?: true
    historicoInadimplencias?: true
    decisorUserId?: true
    decisorSistema?: true
    createdAt?: true
  }

  export type CoverageDecisionMaxAggregateInputType = {
    id?: true
    contributionId?: true
    decisao?: true
    motivo?: true
    scoreNoMomento?: true
    historicoInadimplencias?: true
    decisorUserId?: true
    decisorSistema?: true
    createdAt?: true
  }

  export type CoverageDecisionCountAggregateInputType = {
    id?: true
    contributionId?: true
    decisao?: true
    motivo?: true
    scoreNoMomento?: true
    historicoInadimplencias?: true
    decisorUserId?: true
    decisorSistema?: true
    createdAt?: true
    _all?: true
  }

  export type CoverageDecisionAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which CoverageDecision to aggregate.
     */
    where?: CoverageDecisionWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of CoverageDecisions to fetch.
     */
    orderBy?: CoverageDecisionOrderByWithRelationInput | CoverageDecisionOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: CoverageDecisionWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` CoverageDecisions 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` CoverageDecisions.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned CoverageDecisions
    **/
    _count?: true | CoverageDecisionCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to average
    **/
    _avg?: CoverageDecisionAvgAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to sum
    **/
    _sum?: CoverageDecisionSumAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: CoverageDecisionMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: CoverageDecisionMaxAggregateInputType
  }

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




  export type CoverageDecisionGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: CoverageDecisionWhereInput
    orderBy?: CoverageDecisionOrderByWithAggregationInput | CoverageDecisionOrderByWithAggregationInput[]
    by: CoverageDecisionScalarFieldEnum[] | CoverageDecisionScalarFieldEnum
    having?: CoverageDecisionScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: CoverageDecisionCountAggregateInputType | true
    _avg?: CoverageDecisionAvgAggregateInputType
    _sum?: CoverageDecisionSumAggregateInputType
    _min?: CoverageDecisionMinAggregateInputType
    _max?: CoverageDecisionMaxAggregateInputType
  }

  export type CoverageDecisionGroupByOutputType = {
    id: string
    contributionId: string
    decisao: string
    motivo: string
    scoreNoMomento: number
    historicoInadimplencias: number
    decisorUserId: string | null
    decisorSistema: boolean
    createdAt: Date
    _count: CoverageDecisionCountAggregateOutputType | null
    _avg: CoverageDecisionAvgAggregateOutputType | null
    _sum: CoverageDecisionSumAggregateOutputType | null
    _min: CoverageDecisionMinAggregateOutputType | null
    _max: CoverageDecisionMaxAggregateOutputType | null
  }

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


  export type CoverageDecisionSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    contributionId?: boolean
    decisao?: boolean
    motivo?: boolean
    scoreNoMomento?: boolean
    historicoInadimplencias?: boolean
    decisorUserId?: boolean
    decisorSistema?: boolean
    createdAt?: boolean
    contribution?: boolean | ContributionDefaultArgs<ExtArgs>
    decisorUser?: boolean | CoverageDecision$decisorUserArgs<ExtArgs>
  }, ExtArgs["result"]["coverageDecision"]>


  export type CoverageDecisionSelectScalar = {
    id?: boolean
    contributionId?: boolean
    decisao?: boolean
    motivo?: boolean
    scoreNoMomento?: boolean
    historicoInadimplencias?: boolean
    decisorUserId?: boolean
    decisorSistema?: boolean
    createdAt?: boolean
  }

  export type CoverageDecisionInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    contribution?: boolean | ContributionDefaultArgs<ExtArgs>
    decisorUser?: boolean | CoverageDecision$decisorUserArgs<ExtArgs>
  }

  export type $CoverageDecisionPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "CoverageDecision"
    objects: {
      contribution: Prisma.$ContributionPayload<ExtArgs>
      decisorUser: Prisma.$UserPayload<ExtArgs> | null
    }
    scalars: $Extensions.GetPayloadResult<{
      id: string
      contributionId: string
      decisao: string
      motivo: string
      scoreNoMomento: number
      historicoInadimplencias: number
      decisorUserId: string | null
      decisorSistema: boolean
      createdAt: Date
    }, ExtArgs["result"]["coverageDecision"]>
    composites: {}
  }

  type CoverageDecisionGetPayload<S extends boolean | null | undefined | CoverageDecisionDefaultArgs> = $Result.GetResult<Prisma.$CoverageDecisionPayload, S>

  type CoverageDecisionCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = 
    Omit<CoverageDecisionFindManyArgs, 'select' | 'include' | 'distinct'> & {
      select?: CoverageDecisionCountAggregateInputType | true
    }

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

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

    /**
     * Find the first CoverageDecision 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 {CoverageDecisionFindFirstArgs} args - Arguments to find a CoverageDecision
     * @example
     * // Get one CoverageDecision
     * const coverageDecision = await prisma.coverageDecision.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends CoverageDecisionFindFirstArgs>(args?: SelectSubset<T, CoverageDecisionFindFirstArgs<ExtArgs>>): Prisma__CoverageDecisionClient<$Result.GetResult<Prisma.$CoverageDecisionPayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>

    /**
     * Find the first CoverageDecision 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 {CoverageDecisionFindFirstOrThrowArgs} args - Arguments to find a CoverageDecision
     * @example
     * // Get one CoverageDecision
     * const coverageDecision = await prisma.coverageDecision.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends CoverageDecisionFindFirstOrThrowArgs>(args?: SelectSubset<T, CoverageDecisionFindFirstOrThrowArgs<ExtArgs>>): Prisma__CoverageDecisionClient<$Result.GetResult<Prisma.$CoverageDecisionPayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>

    /**
     * Find zero or more CoverageDecisions 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 {CoverageDecisionFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all CoverageDecisions
     * const coverageDecisions = await prisma.coverageDecision.findMany()
     * 
     * // Get first 10 CoverageDecisions
     * const coverageDecisions = await prisma.coverageDecision.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const coverageDecisionWithIdOnly = await prisma.coverageDecision.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends CoverageDecisionFindManyArgs>(args?: SelectSubset<T, CoverageDecisionFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$CoverageDecisionPayload<ExtArgs>, T, "findMany">>

    /**
     * Create a CoverageDecision.
     * @param {CoverageDecisionCreateArgs} args - Arguments to create a CoverageDecision.
     * @example
     * // Create one CoverageDecision
     * const CoverageDecision = await prisma.coverageDecision.create({
     *   data: {
     *     // ... data to create a CoverageDecision
     *   }
     * })
     * 
     */
    create<T extends CoverageDecisionCreateArgs>(args: SelectSubset<T, CoverageDecisionCreateArgs<ExtArgs>>): Prisma__CoverageDecisionClient<$Result.GetResult<Prisma.$CoverageDecisionPayload<ExtArgs>, T, "create">, never, ExtArgs>

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

    /**
     * Delete a CoverageDecision.
     * @param {CoverageDecisionDeleteArgs} args - Arguments to delete one CoverageDecision.
     * @example
     * // Delete one CoverageDecision
     * const CoverageDecision = await prisma.coverageDecision.delete({
     *   where: {
     *     // ... filter to delete one CoverageDecision
     *   }
     * })
     * 
     */
    delete<T extends CoverageDecisionDeleteArgs>(args: SelectSubset<T, CoverageDecisionDeleteArgs<ExtArgs>>): Prisma__CoverageDecisionClient<$Result.GetResult<Prisma.$CoverageDecisionPayload<ExtArgs>, T, "delete">, never, ExtArgs>

    /**
     * Update one CoverageDecision.
     * @param {CoverageDecisionUpdateArgs} args - Arguments to update one CoverageDecision.
     * @example
     * // Update one CoverageDecision
     * const coverageDecision = await prisma.coverageDecision.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends CoverageDecisionUpdateArgs>(args: SelectSubset<T, CoverageDecisionUpdateArgs<ExtArgs>>): Prisma__CoverageDecisionClient<$Result.GetResult<Prisma.$CoverageDecisionPayload<ExtArgs>, T, "update">, never, ExtArgs>

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

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

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


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

    /**
     * Allows you to perform aggregations operations on a CoverageDecision.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {CoverageDecisionAggregateArgs} 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 CoverageDecisionAggregateArgs>(args: Subset<T, CoverageDecisionAggregateArgs>): Prisma.PrismaPromise<GetCoverageDecisionAggregateType<T>>

    /**
     * Group by CoverageDecision.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {CoverageDecisionGroupByArgs} 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 CoverageDecisionGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: CoverageDecisionGroupByArgs['orderBy'] }
        : { orderBy?: CoverageDecisionGroupByArgs['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, CoverageDecisionGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetCoverageDecisionGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the CoverageDecision model
   */
  readonly fields: CoverageDecisionFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for CoverageDecision.
   * 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__CoverageDecisionClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
    readonly [Symbol.toStringTag]: "PrismaPromise"
    contribution<T extends ContributionDefaultArgs<ExtArgs> = {}>(args?: Subset<T, ContributionDefaultArgs<ExtArgs>>): Prisma__ContributionClient<$Result.GetResult<Prisma.$ContributionPayload<ExtArgs>, T, "findUniqueOrThrow"> | Null, Null, ExtArgs>
    decisorUser<T extends CoverageDecision$decisorUserArgs<ExtArgs> = {}>(args?: Subset<T, CoverageDecision$decisorUserArgs<ExtArgs>>): Prisma__UserClient<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "findUniqueOrThrow"> | null, null, ExtArgs>
    /**
     * 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 CoverageDecision model
   */ 
  interface CoverageDecisionFieldRefs {
    readonly id: FieldRef<"CoverageDecision", 'String'>
    readonly contributionId: FieldRef<"CoverageDecision", 'String'>
    readonly decisao: FieldRef<"CoverageDecision", 'String'>
    readonly motivo: FieldRef<"CoverageDecision", 'String'>
    readonly scoreNoMomento: FieldRef<"CoverageDecision", 'Int'>
    readonly historicoInadimplencias: FieldRef<"CoverageDecision", 'Int'>
    readonly decisorUserId: FieldRef<"CoverageDecision", 'String'>
    readonly decisorSistema: FieldRef<"CoverageDecision", 'Boolean'>
    readonly createdAt: FieldRef<"CoverageDecision", 'DateTime'>
  }
    

  // Custom InputTypes
  /**
   * CoverageDecision findUnique
   */
  export type CoverageDecisionFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CoverageDecision
     */
    select?: CoverageDecisionSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CoverageDecisionInclude<ExtArgs> | null
    /**
     * Filter, which CoverageDecision to fetch.
     */
    where: CoverageDecisionWhereUniqueInput
  }

  /**
   * CoverageDecision findUniqueOrThrow
   */
  export type CoverageDecisionFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CoverageDecision
     */
    select?: CoverageDecisionSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CoverageDecisionInclude<ExtArgs> | null
    /**
     * Filter, which CoverageDecision to fetch.
     */
    where: CoverageDecisionWhereUniqueInput
  }

  /**
   * CoverageDecision findFirst
   */
  export type CoverageDecisionFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CoverageDecision
     */
    select?: CoverageDecisionSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CoverageDecisionInclude<ExtArgs> | null
    /**
     * Filter, which CoverageDecision to fetch.
     */
    where?: CoverageDecisionWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of CoverageDecisions to fetch.
     */
    orderBy?: CoverageDecisionOrderByWithRelationInput | CoverageDecisionOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for CoverageDecisions.
     */
    cursor?: CoverageDecisionWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` CoverageDecisions 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` CoverageDecisions.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of CoverageDecisions.
     */
    distinct?: CoverageDecisionScalarFieldEnum | CoverageDecisionScalarFieldEnum[]
  }

  /**
   * CoverageDecision findFirstOrThrow
   */
  export type CoverageDecisionFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CoverageDecision
     */
    select?: CoverageDecisionSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CoverageDecisionInclude<ExtArgs> | null
    /**
     * Filter, which CoverageDecision to fetch.
     */
    where?: CoverageDecisionWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of CoverageDecisions to fetch.
     */
    orderBy?: CoverageDecisionOrderByWithRelationInput | CoverageDecisionOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for CoverageDecisions.
     */
    cursor?: CoverageDecisionWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` CoverageDecisions 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` CoverageDecisions.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of CoverageDecisions.
     */
    distinct?: CoverageDecisionScalarFieldEnum | CoverageDecisionScalarFieldEnum[]
  }

  /**
   * CoverageDecision findMany
   */
  export type CoverageDecisionFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CoverageDecision
     */
    select?: CoverageDecisionSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CoverageDecisionInclude<ExtArgs> | null
    /**
     * Filter, which CoverageDecisions to fetch.
     */
    where?: CoverageDecisionWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of CoverageDecisions to fetch.
     */
    orderBy?: CoverageDecisionOrderByWithRelationInput | CoverageDecisionOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing CoverageDecisions.
     */
    cursor?: CoverageDecisionWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` CoverageDecisions 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` CoverageDecisions.
     */
    skip?: number
    distinct?: CoverageDecisionScalarFieldEnum | CoverageDecisionScalarFieldEnum[]
  }

  /**
   * CoverageDecision create
   */
  export type CoverageDecisionCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CoverageDecision
     */
    select?: CoverageDecisionSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CoverageDecisionInclude<ExtArgs> | null
    /**
     * The data needed to create a CoverageDecision.
     */
    data: XOR<CoverageDecisionCreateInput, CoverageDecisionUncheckedCreateInput>
  }

  /**
   * CoverageDecision createMany
   */
  export type CoverageDecisionCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many CoverageDecisions.
     */
    data: CoverageDecisionCreateManyInput | CoverageDecisionCreateManyInput[]
    skipDuplicates?: boolean
  }

  /**
   * CoverageDecision update
   */
  export type CoverageDecisionUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CoverageDecision
     */
    select?: CoverageDecisionSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CoverageDecisionInclude<ExtArgs> | null
    /**
     * The data needed to update a CoverageDecision.
     */
    data: XOR<CoverageDecisionUpdateInput, CoverageDecisionUncheckedUpdateInput>
    /**
     * Choose, which CoverageDecision to update.
     */
    where: CoverageDecisionWhereUniqueInput
  }

  /**
   * CoverageDecision updateMany
   */
  export type CoverageDecisionUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update CoverageDecisions.
     */
    data: XOR<CoverageDecisionUpdateManyMutationInput, CoverageDecisionUncheckedUpdateManyInput>
    /**
     * Filter which CoverageDecisions to update
     */
    where?: CoverageDecisionWhereInput
  }

  /**
   * CoverageDecision upsert
   */
  export type CoverageDecisionUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CoverageDecision
     */
    select?: CoverageDecisionSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CoverageDecisionInclude<ExtArgs> | null
    /**
     * The filter to search for the CoverageDecision to update in case it exists.
     */
    where: CoverageDecisionWhereUniqueInput
    /**
     * In case the CoverageDecision found by the `where` argument doesn't exist, create a new CoverageDecision with this data.
     */
    create: XOR<CoverageDecisionCreateInput, CoverageDecisionUncheckedCreateInput>
    /**
     * In case the CoverageDecision was found with the provided `where` argument, update it with this data.
     */
    update: XOR<CoverageDecisionUpdateInput, CoverageDecisionUncheckedUpdateInput>
  }

  /**
   * CoverageDecision delete
   */
  export type CoverageDecisionDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CoverageDecision
     */
    select?: CoverageDecisionSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CoverageDecisionInclude<ExtArgs> | null
    /**
     * Filter which CoverageDecision to delete.
     */
    where: CoverageDecisionWhereUniqueInput
  }

  /**
   * CoverageDecision deleteMany
   */
  export type CoverageDecisionDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which CoverageDecisions to delete
     */
    where?: CoverageDecisionWhereInput
  }

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

  /**
   * CoverageDecision without action
   */
  export type CoverageDecisionDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CoverageDecision
     */
    select?: CoverageDecisionSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CoverageDecisionInclude<ExtArgs> | null
  }


  /**
   * Model Reintegration
   */

  export type AggregateReintegration = {
    _count: ReintegrationCountAggregateOutputType | null
    _avg: ReintegrationAvgAggregateOutputType | null
    _sum: ReintegrationSumAggregateOutputType | null
    _min: ReintegrationMinAggregateOutputType | null
    _max: ReintegrationMaxAggregateOutputType | null
  }

  export type ReintegrationAvgAggregateOutputType = {
    valorDividaOriginal: number | null
    taxaReintegracaoAplicada: number | null
    valorTaxaPaga: number | null
  }

  export type ReintegrationSumAggregateOutputType = {
    valorDividaOriginal: number | null
    taxaReintegracaoAplicada: number | null
    valorTaxaPaga: number | null
  }

  export type ReintegrationMinAggregateOutputType = {
    id: string | null
    userId: string | null
    valorDividaOriginal: number | null
    taxaReintegracaoAplicada: number | null
    valorTaxaPaga: number | null
    dataSolicitacao: Date | null
    dataConclusao: Date | null
    status: string | null
  }

  export type ReintegrationMaxAggregateOutputType = {
    id: string | null
    userId: string | null
    valorDividaOriginal: number | null
    taxaReintegracaoAplicada: number | null
    valorTaxaPaga: number | null
    dataSolicitacao: Date | null
    dataConclusao: Date | null
    status: string | null
  }

  export type ReintegrationCountAggregateOutputType = {
    id: number
    userId: number
    valorDividaOriginal: number
    taxaReintegracaoAplicada: number
    valorTaxaPaga: number
    dataSolicitacao: number
    dataConclusao: number
    status: number
    _all: number
  }


  export type ReintegrationAvgAggregateInputType = {
    valorDividaOriginal?: true
    taxaReintegracaoAplicada?: true
    valorTaxaPaga?: true
  }

  export type ReintegrationSumAggregateInputType = {
    valorDividaOriginal?: true
    taxaReintegracaoAplicada?: true
    valorTaxaPaga?: true
  }

  export type ReintegrationMinAggregateInputType = {
    id?: true
    userId?: true
    valorDividaOriginal?: true
    taxaReintegracaoAplicada?: true
    valorTaxaPaga?: true
    dataSolicitacao?: true
    dataConclusao?: true
    status?: true
  }

  export type ReintegrationMaxAggregateInputType = {
    id?: true
    userId?: true
    valorDividaOriginal?: true
    taxaReintegracaoAplicada?: true
    valorTaxaPaga?: true
    dataSolicitacao?: true
    dataConclusao?: true
    status?: true
  }

  export type ReintegrationCountAggregateInputType = {
    id?: true
    userId?: true
    valorDividaOriginal?: true
    taxaReintegracaoAplicada?: true
    valorTaxaPaga?: true
    dataSolicitacao?: true
    dataConclusao?: true
    status?: true
    _all?: true
  }

  export type ReintegrationAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which Reintegration to aggregate.
     */
    where?: ReintegrationWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Reintegrations to fetch.
     */
    orderBy?: ReintegrationOrderByWithRelationInput | ReintegrationOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: ReintegrationWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Reintegrations 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` Reintegrations.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned Reintegrations
    **/
    _count?: true | ReintegrationCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to average
    **/
    _avg?: ReintegrationAvgAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to sum
    **/
    _sum?: ReintegrationSumAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: ReintegrationMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: ReintegrationMaxAggregateInputType
  }

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




  export type ReintegrationGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: ReintegrationWhereInput
    orderBy?: ReintegrationOrderByWithAggregationInput | ReintegrationOrderByWithAggregationInput[]
    by: ReintegrationScalarFieldEnum[] | ReintegrationScalarFieldEnum
    having?: ReintegrationScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: ReintegrationCountAggregateInputType | true
    _avg?: ReintegrationAvgAggregateInputType
    _sum?: ReintegrationSumAggregateInputType
    _min?: ReintegrationMinAggregateInputType
    _max?: ReintegrationMaxAggregateInputType
  }

  export type ReintegrationGroupByOutputType = {
    id: string
    userId: string
    valorDividaOriginal: number
    taxaReintegracaoAplicada: number
    valorTaxaPaga: number
    dataSolicitacao: Date
    dataConclusao: Date | null
    status: string
    _count: ReintegrationCountAggregateOutputType | null
    _avg: ReintegrationAvgAggregateOutputType | null
    _sum: ReintegrationSumAggregateOutputType | null
    _min: ReintegrationMinAggregateOutputType | null
    _max: ReintegrationMaxAggregateOutputType | null
  }

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


  export type ReintegrationSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    userId?: boolean
    valorDividaOriginal?: boolean
    taxaReintegracaoAplicada?: boolean
    valorTaxaPaga?: boolean
    dataSolicitacao?: boolean
    dataConclusao?: boolean
    status?: boolean
    user?: boolean | UserDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["reintegration"]>


  export type ReintegrationSelectScalar = {
    id?: boolean
    userId?: boolean
    valorDividaOriginal?: boolean
    taxaReintegracaoAplicada?: boolean
    valorTaxaPaga?: boolean
    dataSolicitacao?: boolean
    dataConclusao?: boolean
    status?: boolean
  }

  export type ReintegrationInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    user?: boolean | UserDefaultArgs<ExtArgs>
  }

  export type $ReintegrationPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "Reintegration"
    objects: {
      user: Prisma.$UserPayload<ExtArgs>
    }
    scalars: $Extensions.GetPayloadResult<{
      id: string
      userId: string
      valorDividaOriginal: number
      taxaReintegracaoAplicada: number
      valorTaxaPaga: number
      dataSolicitacao: Date
      dataConclusao: Date | null
      status: string
    }, ExtArgs["result"]["reintegration"]>
    composites: {}
  }

  type ReintegrationGetPayload<S extends boolean | null | undefined | ReintegrationDefaultArgs> = $Result.GetResult<Prisma.$ReintegrationPayload, S>

  type ReintegrationCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = 
    Omit<ReintegrationFindManyArgs, 'select' | 'include' | 'distinct'> & {
      select?: ReintegrationCountAggregateInputType | true
    }

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

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

    /**
     * Find the first Reintegration 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 {ReintegrationFindFirstArgs} args - Arguments to find a Reintegration
     * @example
     * // Get one Reintegration
     * const reintegration = await prisma.reintegration.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends ReintegrationFindFirstArgs>(args?: SelectSubset<T, ReintegrationFindFirstArgs<ExtArgs>>): Prisma__ReintegrationClient<$Result.GetResult<Prisma.$ReintegrationPayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>

    /**
     * Find the first Reintegration 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 {ReintegrationFindFirstOrThrowArgs} args - Arguments to find a Reintegration
     * @example
     * // Get one Reintegration
     * const reintegration = await prisma.reintegration.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends ReintegrationFindFirstOrThrowArgs>(args?: SelectSubset<T, ReintegrationFindFirstOrThrowArgs<ExtArgs>>): Prisma__ReintegrationClient<$Result.GetResult<Prisma.$ReintegrationPayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>

    /**
     * Find zero or more Reintegrations 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 {ReintegrationFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all Reintegrations
     * const reintegrations = await prisma.reintegration.findMany()
     * 
     * // Get first 10 Reintegrations
     * const reintegrations = await prisma.reintegration.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const reintegrationWithIdOnly = await prisma.reintegration.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends ReintegrationFindManyArgs>(args?: SelectSubset<T, ReintegrationFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$ReintegrationPayload<ExtArgs>, T, "findMany">>

    /**
     * Create a Reintegration.
     * @param {ReintegrationCreateArgs} args - Arguments to create a Reintegration.
     * @example
     * // Create one Reintegration
     * const Reintegration = await prisma.reintegration.create({
     *   data: {
     *     // ... data to create a Reintegration
     *   }
     * })
     * 
     */
    create<T extends ReintegrationCreateArgs>(args: SelectSubset<T, ReintegrationCreateArgs<ExtArgs>>): Prisma__ReintegrationClient<$Result.GetResult<Prisma.$ReintegrationPayload<ExtArgs>, T, "create">, never, ExtArgs>

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

    /**
     * Delete a Reintegration.
     * @param {ReintegrationDeleteArgs} args - Arguments to delete one Reintegration.
     * @example
     * // Delete one Reintegration
     * const Reintegration = await prisma.reintegration.delete({
     *   where: {
     *     // ... filter to delete one Reintegration
     *   }
     * })
     * 
     */
    delete<T extends ReintegrationDeleteArgs>(args: SelectSubset<T, ReintegrationDeleteArgs<ExtArgs>>): Prisma__ReintegrationClient<$Result.GetResult<Prisma.$ReintegrationPayload<ExtArgs>, T, "delete">, never, ExtArgs>

    /**
     * Update one Reintegration.
     * @param {ReintegrationUpdateArgs} args - Arguments to update one Reintegration.
     * @example
     * // Update one Reintegration
     * const reintegration = await prisma.reintegration.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends ReintegrationUpdateArgs>(args: SelectSubset<T, ReintegrationUpdateArgs<ExtArgs>>): Prisma__ReintegrationClient<$Result.GetResult<Prisma.$ReintegrationPayload<ExtArgs>, T, "update">, never, ExtArgs>

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

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

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


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

    /**
     * Allows you to perform aggregations operations on a Reintegration.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {ReintegrationAggregateArgs} 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 ReintegrationAggregateArgs>(args: Subset<T, ReintegrationAggregateArgs>): Prisma.PrismaPromise<GetReintegrationAggregateType<T>>

    /**
     * Group by Reintegration.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {ReintegrationGroupByArgs} 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 ReintegrationGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: ReintegrationGroupByArgs['orderBy'] }
        : { orderBy?: ReintegrationGroupByArgs['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, ReintegrationGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetReintegrationGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the Reintegration model
   */
  readonly fields: ReintegrationFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for Reintegration.
   * 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__ReintegrationClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> 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"> | Null, Null, ExtArgs>
    /**
     * 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 Reintegration model
   */ 
  interface ReintegrationFieldRefs {
    readonly id: FieldRef<"Reintegration", 'String'>
    readonly userId: FieldRef<"Reintegration", 'String'>
    readonly valorDividaOriginal: FieldRef<"Reintegration", 'Float'>
    readonly taxaReintegracaoAplicada: FieldRef<"Reintegration", 'Float'>
    readonly valorTaxaPaga: FieldRef<"Reintegration", 'Float'>
    readonly dataSolicitacao: FieldRef<"Reintegration", 'DateTime'>
    readonly dataConclusao: FieldRef<"Reintegration", 'DateTime'>
    readonly status: FieldRef<"Reintegration", 'String'>
  }
    

  // Custom InputTypes
  /**
   * Reintegration findUnique
   */
  export type ReintegrationFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Reintegration
     */
    select?: ReintegrationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ReintegrationInclude<ExtArgs> | null
    /**
     * Filter, which Reintegration to fetch.
     */
    where: ReintegrationWhereUniqueInput
  }

  /**
   * Reintegration findUniqueOrThrow
   */
  export type ReintegrationFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Reintegration
     */
    select?: ReintegrationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ReintegrationInclude<ExtArgs> | null
    /**
     * Filter, which Reintegration to fetch.
     */
    where: ReintegrationWhereUniqueInput
  }

  /**
   * Reintegration findFirst
   */
  export type ReintegrationFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Reintegration
     */
    select?: ReintegrationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ReintegrationInclude<ExtArgs> | null
    /**
     * Filter, which Reintegration to fetch.
     */
    where?: ReintegrationWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Reintegrations to fetch.
     */
    orderBy?: ReintegrationOrderByWithRelationInput | ReintegrationOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for Reintegrations.
     */
    cursor?: ReintegrationWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Reintegrations 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` Reintegrations.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of Reintegrations.
     */
    distinct?: ReintegrationScalarFieldEnum | ReintegrationScalarFieldEnum[]
  }

  /**
   * Reintegration findFirstOrThrow
   */
  export type ReintegrationFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Reintegration
     */
    select?: ReintegrationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ReintegrationInclude<ExtArgs> | null
    /**
     * Filter, which Reintegration to fetch.
     */
    where?: ReintegrationWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Reintegrations to fetch.
     */
    orderBy?: ReintegrationOrderByWithRelationInput | ReintegrationOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for Reintegrations.
     */
    cursor?: ReintegrationWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Reintegrations 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` Reintegrations.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of Reintegrations.
     */
    distinct?: ReintegrationScalarFieldEnum | ReintegrationScalarFieldEnum[]
  }

  /**
   * Reintegration findMany
   */
  export type ReintegrationFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Reintegration
     */
    select?: ReintegrationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ReintegrationInclude<ExtArgs> | null
    /**
     * Filter, which Reintegrations to fetch.
     */
    where?: ReintegrationWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Reintegrations to fetch.
     */
    orderBy?: ReintegrationOrderByWithRelationInput | ReintegrationOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing Reintegrations.
     */
    cursor?: ReintegrationWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Reintegrations 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` Reintegrations.
     */
    skip?: number
    distinct?: ReintegrationScalarFieldEnum | ReintegrationScalarFieldEnum[]
  }

  /**
   * Reintegration create
   */
  export type ReintegrationCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Reintegration
     */
    select?: ReintegrationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ReintegrationInclude<ExtArgs> | null
    /**
     * The data needed to create a Reintegration.
     */
    data: XOR<ReintegrationCreateInput, ReintegrationUncheckedCreateInput>
  }

  /**
   * Reintegration createMany
   */
  export type ReintegrationCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many Reintegrations.
     */
    data: ReintegrationCreateManyInput | ReintegrationCreateManyInput[]
    skipDuplicates?: boolean
  }

  /**
   * Reintegration update
   */
  export type ReintegrationUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Reintegration
     */
    select?: ReintegrationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ReintegrationInclude<ExtArgs> | null
    /**
     * The data needed to update a Reintegration.
     */
    data: XOR<ReintegrationUpdateInput, ReintegrationUncheckedUpdateInput>
    /**
     * Choose, which Reintegration to update.
     */
    where: ReintegrationWhereUniqueInput
  }

  /**
   * Reintegration updateMany
   */
  export type ReintegrationUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update Reintegrations.
     */
    data: XOR<ReintegrationUpdateManyMutationInput, ReintegrationUncheckedUpdateManyInput>
    /**
     * Filter which Reintegrations to update
     */
    where?: ReintegrationWhereInput
  }

  /**
   * Reintegration upsert
   */
  export type ReintegrationUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Reintegration
     */
    select?: ReintegrationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ReintegrationInclude<ExtArgs> | null
    /**
     * The filter to search for the Reintegration to update in case it exists.
     */
    where: ReintegrationWhereUniqueInput
    /**
     * In case the Reintegration found by the `where` argument doesn't exist, create a new Reintegration with this data.
     */
    create: XOR<ReintegrationCreateInput, ReintegrationUncheckedCreateInput>
    /**
     * In case the Reintegration was found with the provided `where` argument, update it with this data.
     */
    update: XOR<ReintegrationUpdateInput, ReintegrationUncheckedUpdateInput>
  }

  /**
   * Reintegration delete
   */
  export type ReintegrationDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Reintegration
     */
    select?: ReintegrationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ReintegrationInclude<ExtArgs> | null
    /**
     * Filter which Reintegration to delete.
     */
    where: ReintegrationWhereUniqueInput
  }

  /**
   * Reintegration deleteMany
   */
  export type ReintegrationDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which Reintegrations to delete
     */
    where?: ReintegrationWhereInput
  }

  /**
   * Reintegration without action
   */
  export type ReintegrationDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Reintegration
     */
    select?: ReintegrationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ReintegrationInclude<ExtArgs> | null
  }


  /**
   * Model FeeConfiguration
   */

  export type AggregateFeeConfiguration = {
    _count: FeeConfigurationCountAggregateOutputType | null
    _avg: FeeConfigurationAvgAggregateOutputType | null
    _sum: FeeConfigurationSumAggregateOutputType | null
    _min: FeeConfigurationMinAggregateOutputType | null
    _max: FeeConfigurationMaxAggregateOutputType | null
  }

  export type FeeConfigurationAvgAggregateOutputType = {
    valor: number | null
    min: number | null
    max: number | null
  }

  export type FeeConfigurationSumAggregateOutputType = {
    valor: number | null
    min: number | null
    max: number | null
  }

  export type FeeConfigurationMinAggregateOutputType = {
    id: string | null
    tipoFee: string | null
    valor: number | null
    min: number | null
    max: number | null
    dataInicio: Date | null
    dataFim: Date | null
    criadoPorId: string | null
    motivoMudanca: string | null
    ativa: boolean | null
    createdAt: Date | null
  }

  export type FeeConfigurationMaxAggregateOutputType = {
    id: string | null
    tipoFee: string | null
    valor: number | null
    min: number | null
    max: number | null
    dataInicio: Date | null
    dataFim: Date | null
    criadoPorId: string | null
    motivoMudanca: string | null
    ativa: boolean | null
    createdAt: Date | null
  }

  export type FeeConfigurationCountAggregateOutputType = {
    id: number
    tipoFee: number
    valor: number
    min: number
    max: number
    dataInicio: number
    dataFim: number
    criadoPorId: number
    motivoMudanca: number
    ativa: number
    createdAt: number
    _all: number
  }


  export type FeeConfigurationAvgAggregateInputType = {
    valor?: true
    min?: true
    max?: true
  }

  export type FeeConfigurationSumAggregateInputType = {
    valor?: true
    min?: true
    max?: true
  }

  export type FeeConfigurationMinAggregateInputType = {
    id?: true
    tipoFee?: true
    valor?: true
    min?: true
    max?: true
    dataInicio?: true
    dataFim?: true
    criadoPorId?: true
    motivoMudanca?: true
    ativa?: true
    createdAt?: true
  }

  export type FeeConfigurationMaxAggregateInputType = {
    id?: true
    tipoFee?: true
    valor?: true
    min?: true
    max?: true
    dataInicio?: true
    dataFim?: true
    criadoPorId?: true
    motivoMudanca?: true
    ativa?: true
    createdAt?: true
  }

  export type FeeConfigurationCountAggregateInputType = {
    id?: true
    tipoFee?: true
    valor?: true
    min?: true
    max?: true
    dataInicio?: true
    dataFim?: true
    criadoPorId?: true
    motivoMudanca?: true
    ativa?: true
    createdAt?: true
    _all?: true
  }

  export type FeeConfigurationAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which FeeConfiguration to aggregate.
     */
    where?: FeeConfigurationWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of FeeConfigurations to fetch.
     */
    orderBy?: FeeConfigurationOrderByWithRelationInput | FeeConfigurationOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: FeeConfigurationWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` FeeConfigurations 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` FeeConfigurations.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned FeeConfigurations
    **/
    _count?: true | FeeConfigurationCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to average
    **/
    _avg?: FeeConfigurationAvgAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to sum
    **/
    _sum?: FeeConfigurationSumAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: FeeConfigurationMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: FeeConfigurationMaxAggregateInputType
  }

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




  export type FeeConfigurationGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: FeeConfigurationWhereInput
    orderBy?: FeeConfigurationOrderByWithAggregationInput | FeeConfigurationOrderByWithAggregationInput[]
    by: FeeConfigurationScalarFieldEnum[] | FeeConfigurationScalarFieldEnum
    having?: FeeConfigurationScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: FeeConfigurationCountAggregateInputType | true
    _avg?: FeeConfigurationAvgAggregateInputType
    _sum?: FeeConfigurationSumAggregateInputType
    _min?: FeeConfigurationMinAggregateInputType
    _max?: FeeConfigurationMaxAggregateInputType
  }

  export type FeeConfigurationGroupByOutputType = {
    id: string
    tipoFee: string
    valor: number
    min: number
    max: number
    dataInicio: Date
    dataFim: Date | null
    criadoPorId: string | null
    motivoMudanca: string | null
    ativa: boolean
    createdAt: Date
    _count: FeeConfigurationCountAggregateOutputType | null
    _avg: FeeConfigurationAvgAggregateOutputType | null
    _sum: FeeConfigurationSumAggregateOutputType | null
    _min: FeeConfigurationMinAggregateOutputType | null
    _max: FeeConfigurationMaxAggregateOutputType | null
  }

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


  export type FeeConfigurationSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    tipoFee?: boolean
    valor?: boolean
    min?: boolean
    max?: boolean
    dataInicio?: boolean
    dataFim?: boolean
    criadoPorId?: boolean
    motivoMudanca?: boolean
    ativa?: boolean
    createdAt?: boolean
    criadoPor?: boolean | FeeConfiguration$criadoPorArgs<ExtArgs>
  }, ExtArgs["result"]["feeConfiguration"]>


  export type FeeConfigurationSelectScalar = {
    id?: boolean
    tipoFee?: boolean
    valor?: boolean
    min?: boolean
    max?: boolean
    dataInicio?: boolean
    dataFim?: boolean
    criadoPorId?: boolean
    motivoMudanca?: boolean
    ativa?: boolean
    createdAt?: boolean
  }

  export type FeeConfigurationInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    criadoPor?: boolean | FeeConfiguration$criadoPorArgs<ExtArgs>
  }

  export type $FeeConfigurationPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "FeeConfiguration"
    objects: {
      criadoPor: Prisma.$UserPayload<ExtArgs> | null
    }
    scalars: $Extensions.GetPayloadResult<{
      id: string
      tipoFee: string
      valor: number
      min: number
      max: number
      dataInicio: Date
      dataFim: Date | null
      criadoPorId: string | null
      motivoMudanca: string | null
      ativa: boolean
      createdAt: Date
    }, ExtArgs["result"]["feeConfiguration"]>
    composites: {}
  }

  type FeeConfigurationGetPayload<S extends boolean | null | undefined | FeeConfigurationDefaultArgs> = $Result.GetResult<Prisma.$FeeConfigurationPayload, S>

  type FeeConfigurationCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = 
    Omit<FeeConfigurationFindManyArgs, 'select' | 'include' | 'distinct'> & {
      select?: FeeConfigurationCountAggregateInputType | true
    }

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

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

    /**
     * Find the first FeeConfiguration 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 {FeeConfigurationFindFirstArgs} args - Arguments to find a FeeConfiguration
     * @example
     * // Get one FeeConfiguration
     * const feeConfiguration = await prisma.feeConfiguration.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends FeeConfigurationFindFirstArgs>(args?: SelectSubset<T, FeeConfigurationFindFirstArgs<ExtArgs>>): Prisma__FeeConfigurationClient<$Result.GetResult<Prisma.$FeeConfigurationPayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>

    /**
     * Find the first FeeConfiguration 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 {FeeConfigurationFindFirstOrThrowArgs} args - Arguments to find a FeeConfiguration
     * @example
     * // Get one FeeConfiguration
     * const feeConfiguration = await prisma.feeConfiguration.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends FeeConfigurationFindFirstOrThrowArgs>(args?: SelectSubset<T, FeeConfigurationFindFirstOrThrowArgs<ExtArgs>>): Prisma__FeeConfigurationClient<$Result.GetResult<Prisma.$FeeConfigurationPayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>

    /**
     * Find zero or more FeeConfigurations 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 {FeeConfigurationFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all FeeConfigurations
     * const feeConfigurations = await prisma.feeConfiguration.findMany()
     * 
     * // Get first 10 FeeConfigurations
     * const feeConfigurations = await prisma.feeConfiguration.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const feeConfigurationWithIdOnly = await prisma.feeConfiguration.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends FeeConfigurationFindManyArgs>(args?: SelectSubset<T, FeeConfigurationFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$FeeConfigurationPayload<ExtArgs>, T, "findMany">>

    /**
     * Create a FeeConfiguration.
     * @param {FeeConfigurationCreateArgs} args - Arguments to create a FeeConfiguration.
     * @example
     * // Create one FeeConfiguration
     * const FeeConfiguration = await prisma.feeConfiguration.create({
     *   data: {
     *     // ... data to create a FeeConfiguration
     *   }
     * })
     * 
     */
    create<T extends FeeConfigurationCreateArgs>(args: SelectSubset<T, FeeConfigurationCreateArgs<ExtArgs>>): Prisma__FeeConfigurationClient<$Result.GetResult<Prisma.$FeeConfigurationPayload<ExtArgs>, T, "create">, never, ExtArgs>

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

    /**
     * Delete a FeeConfiguration.
     * @param {FeeConfigurationDeleteArgs} args - Arguments to delete one FeeConfiguration.
     * @example
     * // Delete one FeeConfiguration
     * const FeeConfiguration = await prisma.feeConfiguration.delete({
     *   where: {
     *     // ... filter to delete one FeeConfiguration
     *   }
     * })
     * 
     */
    delete<T extends FeeConfigurationDeleteArgs>(args: SelectSubset<T, FeeConfigurationDeleteArgs<ExtArgs>>): Prisma__FeeConfigurationClient<$Result.GetResult<Prisma.$FeeConfigurationPayload<ExtArgs>, T, "delete">, never, ExtArgs>

    /**
     * Update one FeeConfiguration.
     * @param {FeeConfigurationUpdateArgs} args - Arguments to update one FeeConfiguration.
     * @example
     * // Update one FeeConfiguration
     * const feeConfiguration = await prisma.feeConfiguration.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends FeeConfigurationUpdateArgs>(args: SelectSubset<T, FeeConfigurationUpdateArgs<ExtArgs>>): Prisma__FeeConfigurationClient<$Result.GetResult<Prisma.$FeeConfigurationPayload<ExtArgs>, T, "update">, never, ExtArgs>

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

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

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


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

    /**
     * Allows you to perform aggregations operations on a FeeConfiguration.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {FeeConfigurationAggregateArgs} 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 FeeConfigurationAggregateArgs>(args: Subset<T, FeeConfigurationAggregateArgs>): Prisma.PrismaPromise<GetFeeConfigurationAggregateType<T>>

    /**
     * Group by FeeConfiguration.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {FeeConfigurationGroupByArgs} 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 FeeConfigurationGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: FeeConfigurationGroupByArgs['orderBy'] }
        : { orderBy?: FeeConfigurationGroupByArgs['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, FeeConfigurationGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetFeeConfigurationGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the FeeConfiguration model
   */
  readonly fields: FeeConfigurationFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for FeeConfiguration.
   * 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__FeeConfigurationClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
    readonly [Symbol.toStringTag]: "PrismaPromise"
    criadoPor<T extends FeeConfiguration$criadoPorArgs<ExtArgs> = {}>(args?: Subset<T, FeeConfiguration$criadoPorArgs<ExtArgs>>): Prisma__UserClient<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "findUniqueOrThrow"> | null, null, ExtArgs>
    /**
     * 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 FeeConfiguration model
   */ 
  interface FeeConfigurationFieldRefs {
    readonly id: FieldRef<"FeeConfiguration", 'String'>
    readonly tipoFee: FieldRef<"FeeConfiguration", 'String'>
    readonly valor: FieldRef<"FeeConfiguration", 'Float'>
    readonly min: FieldRef<"FeeConfiguration", 'Float'>
    readonly max: FieldRef<"FeeConfiguration", 'Float'>
    readonly dataInicio: FieldRef<"FeeConfiguration", 'DateTime'>
    readonly dataFim: FieldRef<"FeeConfiguration", 'DateTime'>
    readonly criadoPorId: FieldRef<"FeeConfiguration", 'String'>
    readonly motivoMudanca: FieldRef<"FeeConfiguration", 'String'>
    readonly ativa: FieldRef<"FeeConfiguration", 'Boolean'>
    readonly createdAt: FieldRef<"FeeConfiguration", 'DateTime'>
  }
    

  // Custom InputTypes
  /**
   * FeeConfiguration findUnique
   */
  export type FeeConfigurationFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the FeeConfiguration
     */
    select?: FeeConfigurationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: FeeConfigurationInclude<ExtArgs> | null
    /**
     * Filter, which FeeConfiguration to fetch.
     */
    where: FeeConfigurationWhereUniqueInput
  }

  /**
   * FeeConfiguration findUniqueOrThrow
   */
  export type FeeConfigurationFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the FeeConfiguration
     */
    select?: FeeConfigurationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: FeeConfigurationInclude<ExtArgs> | null
    /**
     * Filter, which FeeConfiguration to fetch.
     */
    where: FeeConfigurationWhereUniqueInput
  }

  /**
   * FeeConfiguration findFirst
   */
  export type FeeConfigurationFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the FeeConfiguration
     */
    select?: FeeConfigurationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: FeeConfigurationInclude<ExtArgs> | null
    /**
     * Filter, which FeeConfiguration to fetch.
     */
    where?: FeeConfigurationWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of FeeConfigurations to fetch.
     */
    orderBy?: FeeConfigurationOrderByWithRelationInput | FeeConfigurationOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for FeeConfigurations.
     */
    cursor?: FeeConfigurationWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` FeeConfigurations 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` FeeConfigurations.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of FeeConfigurations.
     */
    distinct?: FeeConfigurationScalarFieldEnum | FeeConfigurationScalarFieldEnum[]
  }

  /**
   * FeeConfiguration findFirstOrThrow
   */
  export type FeeConfigurationFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the FeeConfiguration
     */
    select?: FeeConfigurationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: FeeConfigurationInclude<ExtArgs> | null
    /**
     * Filter, which FeeConfiguration to fetch.
     */
    where?: FeeConfigurationWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of FeeConfigurations to fetch.
     */
    orderBy?: FeeConfigurationOrderByWithRelationInput | FeeConfigurationOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for FeeConfigurations.
     */
    cursor?: FeeConfigurationWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` FeeConfigurations 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` FeeConfigurations.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of FeeConfigurations.
     */
    distinct?: FeeConfigurationScalarFieldEnum | FeeConfigurationScalarFieldEnum[]
  }

  /**
   * FeeConfiguration findMany
   */
  export type FeeConfigurationFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the FeeConfiguration
     */
    select?: FeeConfigurationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: FeeConfigurationInclude<ExtArgs> | null
    /**
     * Filter, which FeeConfigurations to fetch.
     */
    where?: FeeConfigurationWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of FeeConfigurations to fetch.
     */
    orderBy?: FeeConfigurationOrderByWithRelationInput | FeeConfigurationOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing FeeConfigurations.
     */
    cursor?: FeeConfigurationWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` FeeConfigurations 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` FeeConfigurations.
     */
    skip?: number
    distinct?: FeeConfigurationScalarFieldEnum | FeeConfigurationScalarFieldEnum[]
  }

  /**
   * FeeConfiguration create
   */
  export type FeeConfigurationCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the FeeConfiguration
     */
    select?: FeeConfigurationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: FeeConfigurationInclude<ExtArgs> | null
    /**
     * The data needed to create a FeeConfiguration.
     */
    data: XOR<FeeConfigurationCreateInput, FeeConfigurationUncheckedCreateInput>
  }

  /**
   * FeeConfiguration createMany
   */
  export type FeeConfigurationCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many FeeConfigurations.
     */
    data: FeeConfigurationCreateManyInput | FeeConfigurationCreateManyInput[]
    skipDuplicates?: boolean
  }

  /**
   * FeeConfiguration update
   */
  export type FeeConfigurationUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the FeeConfiguration
     */
    select?: FeeConfigurationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: FeeConfigurationInclude<ExtArgs> | null
    /**
     * The data needed to update a FeeConfiguration.
     */
    data: XOR<FeeConfigurationUpdateInput, FeeConfigurationUncheckedUpdateInput>
    /**
     * Choose, which FeeConfiguration to update.
     */
    where: FeeConfigurationWhereUniqueInput
  }

  /**
   * FeeConfiguration updateMany
   */
  export type FeeConfigurationUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update FeeConfigurations.
     */
    data: XOR<FeeConfigurationUpdateManyMutationInput, FeeConfigurationUncheckedUpdateManyInput>
    /**
     * Filter which FeeConfigurations to update
     */
    where?: FeeConfigurationWhereInput
  }

  /**
   * FeeConfiguration upsert
   */
  export type FeeConfigurationUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the FeeConfiguration
     */
    select?: FeeConfigurationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: FeeConfigurationInclude<ExtArgs> | null
    /**
     * The filter to search for the FeeConfiguration to update in case it exists.
     */
    where: FeeConfigurationWhereUniqueInput
    /**
     * In case the FeeConfiguration found by the `where` argument doesn't exist, create a new FeeConfiguration with this data.
     */
    create: XOR<FeeConfigurationCreateInput, FeeConfigurationUncheckedCreateInput>
    /**
     * In case the FeeConfiguration was found with the provided `where` argument, update it with this data.
     */
    update: XOR<FeeConfigurationUpdateInput, FeeConfigurationUncheckedUpdateInput>
  }

  /**
   * FeeConfiguration delete
   */
  export type FeeConfigurationDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the FeeConfiguration
     */
    select?: FeeConfigurationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: FeeConfigurationInclude<ExtArgs> | null
    /**
     * Filter which FeeConfiguration to delete.
     */
    where: FeeConfigurationWhereUniqueInput
  }

  /**
   * FeeConfiguration deleteMany
   */
  export type FeeConfigurationDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which FeeConfigurations to delete
     */
    where?: FeeConfigurationWhereInput
  }

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

  /**
   * FeeConfiguration without action
   */
  export type FeeConfigurationDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the FeeConfiguration
     */
    select?: FeeConfigurationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: FeeConfigurationInclude<ExtArgs> | null
  }


  /**
   * Model CoverageFund
   */

  export type AggregateCoverageFund = {
    _count: CoverageFundCountAggregateOutputType | null
    _avg: CoverageFundAvgAggregateOutputType | null
    _sum: CoverageFundSumAggregateOutputType | null
    _min: CoverageFundMinAggregateOutputType | null
    _max: CoverageFundMaxAggregateOutputType | null
  }

  export type CoverageFundAvgAggregateOutputType = {
    saldoDisponivel: number | null
    saldoEmEmprestimosActivos: number | null
    totalRecuperadoAno: number | null
    totalPerdidoAno: number | null
  }

  export type CoverageFundSumAggregateOutputType = {
    saldoDisponivel: number | null
    saldoEmEmprestimosActivos: number | null
    totalRecuperadoAno: number | null
    totalPerdidoAno: number | null
  }

  export type CoverageFundMinAggregateOutputType = {
    id: string | null
    saldoDisponivel: number | null
    saldoEmEmprestimosActivos: number | null
    totalRecuperadoAno: number | null
    totalPerdidoAno: number | null
    lastUpdated: Date | null
  }

  export type CoverageFundMaxAggregateOutputType = {
    id: string | null
    saldoDisponivel: number | null
    saldoEmEmprestimosActivos: number | null
    totalRecuperadoAno: number | null
    totalPerdidoAno: number | null
    lastUpdated: Date | null
  }

  export type CoverageFundCountAggregateOutputType = {
    id: number
    saldoDisponivel: number
    saldoEmEmprestimosActivos: number
    totalRecuperadoAno: number
    totalPerdidoAno: number
    lastUpdated: number
    _all: number
  }


  export type CoverageFundAvgAggregateInputType = {
    saldoDisponivel?: true
    saldoEmEmprestimosActivos?: true
    totalRecuperadoAno?: true
    totalPerdidoAno?: true
  }

  export type CoverageFundSumAggregateInputType = {
    saldoDisponivel?: true
    saldoEmEmprestimosActivos?: true
    totalRecuperadoAno?: true
    totalPerdidoAno?: true
  }

  export type CoverageFundMinAggregateInputType = {
    id?: true
    saldoDisponivel?: true
    saldoEmEmprestimosActivos?: true
    totalRecuperadoAno?: true
    totalPerdidoAno?: true
    lastUpdated?: true
  }

  export type CoverageFundMaxAggregateInputType = {
    id?: true
    saldoDisponivel?: true
    saldoEmEmprestimosActivos?: true
    totalRecuperadoAno?: true
    totalPerdidoAno?: true
    lastUpdated?: true
  }

  export type CoverageFundCountAggregateInputType = {
    id?: true
    saldoDisponivel?: true
    saldoEmEmprestimosActivos?: true
    totalRecuperadoAno?: true
    totalPerdidoAno?: true
    lastUpdated?: true
    _all?: true
  }

  export type CoverageFundAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which CoverageFund to aggregate.
     */
    where?: CoverageFundWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of CoverageFunds to fetch.
     */
    orderBy?: CoverageFundOrderByWithRelationInput | CoverageFundOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: CoverageFundWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` CoverageFunds 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` CoverageFunds.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned CoverageFunds
    **/
    _count?: true | CoverageFundCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to average
    **/
    _avg?: CoverageFundAvgAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to sum
    **/
    _sum?: CoverageFundSumAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: CoverageFundMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: CoverageFundMaxAggregateInputType
  }

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




  export type CoverageFundGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: CoverageFundWhereInput
    orderBy?: CoverageFundOrderByWithAggregationInput | CoverageFundOrderByWithAggregationInput[]
    by: CoverageFundScalarFieldEnum[] | CoverageFundScalarFieldEnum
    having?: CoverageFundScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: CoverageFundCountAggregateInputType | true
    _avg?: CoverageFundAvgAggregateInputType
    _sum?: CoverageFundSumAggregateInputType
    _min?: CoverageFundMinAggregateInputType
    _max?: CoverageFundMaxAggregateInputType
  }

  export type CoverageFundGroupByOutputType = {
    id: string
    saldoDisponivel: number
    saldoEmEmprestimosActivos: number
    totalRecuperadoAno: number
    totalPerdidoAno: number
    lastUpdated: Date
    _count: CoverageFundCountAggregateOutputType | null
    _avg: CoverageFundAvgAggregateOutputType | null
    _sum: CoverageFundSumAggregateOutputType | null
    _min: CoverageFundMinAggregateOutputType | null
    _max: CoverageFundMaxAggregateOutputType | null
  }

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


  export type CoverageFundSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    saldoDisponivel?: boolean
    saldoEmEmprestimosActivos?: boolean
    totalRecuperadoAno?: boolean
    totalPerdidoAno?: boolean
    lastUpdated?: boolean
  }, ExtArgs["result"]["coverageFund"]>


  export type CoverageFundSelectScalar = {
    id?: boolean
    saldoDisponivel?: boolean
    saldoEmEmprestimosActivos?: boolean
    totalRecuperadoAno?: boolean
    totalPerdidoAno?: boolean
    lastUpdated?: boolean
  }


  export type $CoverageFundPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "CoverageFund"
    objects: {}
    scalars: $Extensions.GetPayloadResult<{
      id: string
      saldoDisponivel: number
      saldoEmEmprestimosActivos: number
      totalRecuperadoAno: number
      totalPerdidoAno: number
      lastUpdated: Date
    }, ExtArgs["result"]["coverageFund"]>
    composites: {}
  }

  type CoverageFundGetPayload<S extends boolean | null | undefined | CoverageFundDefaultArgs> = $Result.GetResult<Prisma.$CoverageFundPayload, S>

  type CoverageFundCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = 
    Omit<CoverageFundFindManyArgs, 'select' | 'include' | 'distinct'> & {
      select?: CoverageFundCountAggregateInputType | true
    }

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

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

    /**
     * Find the first CoverageFund 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 {CoverageFundFindFirstArgs} args - Arguments to find a CoverageFund
     * @example
     * // Get one CoverageFund
     * const coverageFund = await prisma.coverageFund.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends CoverageFundFindFirstArgs>(args?: SelectSubset<T, CoverageFundFindFirstArgs<ExtArgs>>): Prisma__CoverageFundClient<$Result.GetResult<Prisma.$CoverageFundPayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>

    /**
     * Find the first CoverageFund 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 {CoverageFundFindFirstOrThrowArgs} args - Arguments to find a CoverageFund
     * @example
     * // Get one CoverageFund
     * const coverageFund = await prisma.coverageFund.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends CoverageFundFindFirstOrThrowArgs>(args?: SelectSubset<T, CoverageFundFindFirstOrThrowArgs<ExtArgs>>): Prisma__CoverageFundClient<$Result.GetResult<Prisma.$CoverageFundPayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>

    /**
     * Find zero or more CoverageFunds 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 {CoverageFundFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all CoverageFunds
     * const coverageFunds = await prisma.coverageFund.findMany()
     * 
     * // Get first 10 CoverageFunds
     * const coverageFunds = await prisma.coverageFund.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const coverageFundWithIdOnly = await prisma.coverageFund.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends CoverageFundFindManyArgs>(args?: SelectSubset<T, CoverageFundFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$CoverageFundPayload<ExtArgs>, T, "findMany">>

    /**
     * Create a CoverageFund.
     * @param {CoverageFundCreateArgs} args - Arguments to create a CoverageFund.
     * @example
     * // Create one CoverageFund
     * const CoverageFund = await prisma.coverageFund.create({
     *   data: {
     *     // ... data to create a CoverageFund
     *   }
     * })
     * 
     */
    create<T extends CoverageFundCreateArgs>(args: SelectSubset<T, CoverageFundCreateArgs<ExtArgs>>): Prisma__CoverageFundClient<$Result.GetResult<Prisma.$CoverageFundPayload<ExtArgs>, T, "create">, never, ExtArgs>

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

    /**
     * Delete a CoverageFund.
     * @param {CoverageFundDeleteArgs} args - Arguments to delete one CoverageFund.
     * @example
     * // Delete one CoverageFund
     * const CoverageFund = await prisma.coverageFund.delete({
     *   where: {
     *     // ... filter to delete one CoverageFund
     *   }
     * })
     * 
     */
    delete<T extends CoverageFundDeleteArgs>(args: SelectSubset<T, CoverageFundDeleteArgs<ExtArgs>>): Prisma__CoverageFundClient<$Result.GetResult<Prisma.$CoverageFundPayload<ExtArgs>, T, "delete">, never, ExtArgs>

    /**
     * Update one CoverageFund.
     * @param {CoverageFundUpdateArgs} args - Arguments to update one CoverageFund.
     * @example
     * // Update one CoverageFund
     * const coverageFund = await prisma.coverageFund.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends CoverageFundUpdateArgs>(args: SelectSubset<T, CoverageFundUpdateArgs<ExtArgs>>): Prisma__CoverageFundClient<$Result.GetResult<Prisma.$CoverageFundPayload<ExtArgs>, T, "update">, never, ExtArgs>

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

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

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


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

    /**
     * Allows you to perform aggregations operations on a CoverageFund.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {CoverageFundAggregateArgs} 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 CoverageFundAggregateArgs>(args: Subset<T, CoverageFundAggregateArgs>): Prisma.PrismaPromise<GetCoverageFundAggregateType<T>>

    /**
     * Group by CoverageFund.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {CoverageFundGroupByArgs} 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 CoverageFundGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: CoverageFundGroupByArgs['orderBy'] }
        : { orderBy?: CoverageFundGroupByArgs['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, CoverageFundGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetCoverageFundGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the CoverageFund model
   */
  readonly fields: CoverageFundFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for CoverageFund.
   * 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__CoverageFundClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> 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 CoverageFund model
   */ 
  interface CoverageFundFieldRefs {
    readonly id: FieldRef<"CoverageFund", 'String'>
    readonly saldoDisponivel: FieldRef<"CoverageFund", 'Float'>
    readonly saldoEmEmprestimosActivos: FieldRef<"CoverageFund", 'Float'>
    readonly totalRecuperadoAno: FieldRef<"CoverageFund", 'Float'>
    readonly totalPerdidoAno: FieldRef<"CoverageFund", 'Float'>
    readonly lastUpdated: FieldRef<"CoverageFund", 'DateTime'>
  }
    

  // Custom InputTypes
  /**
   * CoverageFund findUnique
   */
  export type CoverageFundFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CoverageFund
     */
    select?: CoverageFundSelect<ExtArgs> | null
    /**
     * Filter, which CoverageFund to fetch.
     */
    where: CoverageFundWhereUniqueInput
  }

  /**
   * CoverageFund findUniqueOrThrow
   */
  export type CoverageFundFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CoverageFund
     */
    select?: CoverageFundSelect<ExtArgs> | null
    /**
     * Filter, which CoverageFund to fetch.
     */
    where: CoverageFundWhereUniqueInput
  }

  /**
   * CoverageFund findFirst
   */
  export type CoverageFundFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CoverageFund
     */
    select?: CoverageFundSelect<ExtArgs> | null
    /**
     * Filter, which CoverageFund to fetch.
     */
    where?: CoverageFundWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of CoverageFunds to fetch.
     */
    orderBy?: CoverageFundOrderByWithRelationInput | CoverageFundOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for CoverageFunds.
     */
    cursor?: CoverageFundWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` CoverageFunds 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` CoverageFunds.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of CoverageFunds.
     */
    distinct?: CoverageFundScalarFieldEnum | CoverageFundScalarFieldEnum[]
  }

  /**
   * CoverageFund findFirstOrThrow
   */
  export type CoverageFundFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CoverageFund
     */
    select?: CoverageFundSelect<ExtArgs> | null
    /**
     * Filter, which CoverageFund to fetch.
     */
    where?: CoverageFundWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of CoverageFunds to fetch.
     */
    orderBy?: CoverageFundOrderByWithRelationInput | CoverageFundOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for CoverageFunds.
     */
    cursor?: CoverageFundWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` CoverageFunds 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` CoverageFunds.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of CoverageFunds.
     */
    distinct?: CoverageFundScalarFieldEnum | CoverageFundScalarFieldEnum[]
  }

  /**
   * CoverageFund findMany
   */
  export type CoverageFundFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CoverageFund
     */
    select?: CoverageFundSelect<ExtArgs> | null
    /**
     * Filter, which CoverageFunds to fetch.
     */
    where?: CoverageFundWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of CoverageFunds to fetch.
     */
    orderBy?: CoverageFundOrderByWithRelationInput | CoverageFundOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing CoverageFunds.
     */
    cursor?: CoverageFundWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` CoverageFunds 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` CoverageFunds.
     */
    skip?: number
    distinct?: CoverageFundScalarFieldEnum | CoverageFundScalarFieldEnum[]
  }

  /**
   * CoverageFund create
   */
  export type CoverageFundCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CoverageFund
     */
    select?: CoverageFundSelect<ExtArgs> | null
    /**
     * The data needed to create a CoverageFund.
     */
    data?: XOR<CoverageFundCreateInput, CoverageFundUncheckedCreateInput>
  }

  /**
   * CoverageFund createMany
   */
  export type CoverageFundCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many CoverageFunds.
     */
    data: CoverageFundCreateManyInput | CoverageFundCreateManyInput[]
    skipDuplicates?: boolean
  }

  /**
   * CoverageFund update
   */
  export type CoverageFundUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CoverageFund
     */
    select?: CoverageFundSelect<ExtArgs> | null
    /**
     * The data needed to update a CoverageFund.
     */
    data: XOR<CoverageFundUpdateInput, CoverageFundUncheckedUpdateInput>
    /**
     * Choose, which CoverageFund to update.
     */
    where: CoverageFundWhereUniqueInput
  }

  /**
   * CoverageFund updateMany
   */
  export type CoverageFundUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update CoverageFunds.
     */
    data: XOR<CoverageFundUpdateManyMutationInput, CoverageFundUncheckedUpdateManyInput>
    /**
     * Filter which CoverageFunds to update
     */
    where?: CoverageFundWhereInput
  }

  /**
   * CoverageFund upsert
   */
  export type CoverageFundUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CoverageFund
     */
    select?: CoverageFundSelect<ExtArgs> | null
    /**
     * The filter to search for the CoverageFund to update in case it exists.
     */
    where: CoverageFundWhereUniqueInput
    /**
     * In case the CoverageFund found by the `where` argument doesn't exist, create a new CoverageFund with this data.
     */
    create: XOR<CoverageFundCreateInput, CoverageFundUncheckedCreateInput>
    /**
     * In case the CoverageFund was found with the provided `where` argument, update it with this data.
     */
    update: XOR<CoverageFundUpdateInput, CoverageFundUncheckedUpdateInput>
  }

  /**
   * CoverageFund delete
   */
  export type CoverageFundDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CoverageFund
     */
    select?: CoverageFundSelect<ExtArgs> | null
    /**
     * Filter which CoverageFund to delete.
     */
    where: CoverageFundWhereUniqueInput
  }

  /**
   * CoverageFund deleteMany
   */
  export type CoverageFundDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which CoverageFunds to delete
     */
    where?: CoverageFundWhereInput
  }

  /**
   * CoverageFund without action
   */
  export type CoverageFundDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CoverageFund
     */
    select?: CoverageFundSelect<ExtArgs> | null
  }


  /**
   * Model Transaction
   */

  export type AggregateTransaction = {
    _count: TransactionCountAggregateOutputType | null
    _avg: TransactionAvgAggregateOutputType | null
    _sum: TransactionSumAggregateOutputType | null
    _min: TransactionMinAggregateOutputType | null
    _max: TransactionMaxAggregateOutputType | null
  }

  export type TransactionAvgAggregateOutputType = {
    valor: number | null
  }

  export type TransactionSumAggregateOutputType = {
    valor: number | null
  }

  export type TransactionMinAggregateOutputType = {
    id: string | null
    tipo: string | null
    valor: number | null
    fromAccount: string | null
    toAccount: string | null
    referencia: string | null
    status: string | null
    timestamp: Date | null
    auditJson: string | null
  }

  export type TransactionMaxAggregateOutputType = {
    id: string | null
    tipo: string | null
    valor: number | null
    fromAccount: string | null
    toAccount: string | null
    referencia: string | null
    status: string | null
    timestamp: Date | null
    auditJson: string | null
  }

  export type TransactionCountAggregateOutputType = {
    id: number
    tipo: number
    valor: number
    fromAccount: number
    toAccount: number
    referencia: number
    status: number
    timestamp: number
    auditJson: number
    _all: number
  }


  export type TransactionAvgAggregateInputType = {
    valor?: true
  }

  export type TransactionSumAggregateInputType = {
    valor?: true
  }

  export type TransactionMinAggregateInputType = {
    id?: true
    tipo?: true
    valor?: true
    fromAccount?: true
    toAccount?: true
    referencia?: true
    status?: true
    timestamp?: true
    auditJson?: true
  }

  export type TransactionMaxAggregateInputType = {
    id?: true
    tipo?: true
    valor?: true
    fromAccount?: true
    toAccount?: true
    referencia?: true
    status?: true
    timestamp?: true
    auditJson?: true
  }

  export type TransactionCountAggregateInputType = {
    id?: true
    tipo?: true
    valor?: true
    fromAccount?: true
    toAccount?: true
    referencia?: true
    status?: true
    timestamp?: true
    auditJson?: true
    _all?: true
  }

  export type TransactionAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which Transaction to aggregate.
     */
    where?: TransactionWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Transactions to fetch.
     */
    orderBy?: TransactionOrderByWithRelationInput | TransactionOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: TransactionWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Transactions 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` Transactions.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned Transactions
    **/
    _count?: true | TransactionCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to average
    **/
    _avg?: TransactionAvgAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to sum
    **/
    _sum?: TransactionSumAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: TransactionMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: TransactionMaxAggregateInputType
  }

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




  export type TransactionGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: TransactionWhereInput
    orderBy?: TransactionOrderByWithAggregationInput | TransactionOrderByWithAggregationInput[]
    by: TransactionScalarFieldEnum[] | TransactionScalarFieldEnum
    having?: TransactionScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: TransactionCountAggregateInputType | true
    _avg?: TransactionAvgAggregateInputType
    _sum?: TransactionSumAggregateInputType
    _min?: TransactionMinAggregateInputType
    _max?: TransactionMaxAggregateInputType
  }

  export type TransactionGroupByOutputType = {
    id: string
    tipo: string
    valor: number
    fromAccount: string
    toAccount: string
    referencia: string | null
    status: string
    timestamp: Date
    auditJson: string | null
    _count: TransactionCountAggregateOutputType | null
    _avg: TransactionAvgAggregateOutputType | null
    _sum: TransactionSumAggregateOutputType | null
    _min: TransactionMinAggregateOutputType | null
    _max: TransactionMaxAggregateOutputType | null
  }

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


  export type TransactionSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    tipo?: boolean
    valor?: boolean
    fromAccount?: boolean
    toAccount?: boolean
    referencia?: boolean
    status?: boolean
    timestamp?: boolean
    auditJson?: boolean
  }, ExtArgs["result"]["transaction"]>


  export type TransactionSelectScalar = {
    id?: boolean
    tipo?: boolean
    valor?: boolean
    fromAccount?: boolean
    toAccount?: boolean
    referencia?: boolean
    status?: boolean
    timestamp?: boolean
    auditJson?: boolean
  }


  export type $TransactionPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "Transaction"
    objects: {}
    scalars: $Extensions.GetPayloadResult<{
      id: string
      tipo: string
      valor: number
      fromAccount: string
      toAccount: string
      referencia: string | null
      status: string
      timestamp: Date
      auditJson: string | null
    }, ExtArgs["result"]["transaction"]>
    composites: {}
  }

  type TransactionGetPayload<S extends boolean | null | undefined | TransactionDefaultArgs> = $Result.GetResult<Prisma.$TransactionPayload, S>

  type TransactionCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = 
    Omit<TransactionFindManyArgs, 'select' | 'include' | 'distinct'> & {
      select?: TransactionCountAggregateInputType | true
    }

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

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

    /**
     * Find the first Transaction 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 {TransactionFindFirstArgs} args - Arguments to find a Transaction
     * @example
     * // Get one Transaction
     * const transaction = await prisma.transaction.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends TransactionFindFirstArgs>(args?: SelectSubset<T, TransactionFindFirstArgs<ExtArgs>>): Prisma__TransactionClient<$Result.GetResult<Prisma.$TransactionPayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>

    /**
     * Find the first Transaction 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 {TransactionFindFirstOrThrowArgs} args - Arguments to find a Transaction
     * @example
     * // Get one Transaction
     * const transaction = await prisma.transaction.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends TransactionFindFirstOrThrowArgs>(args?: SelectSubset<T, TransactionFindFirstOrThrowArgs<ExtArgs>>): Prisma__TransactionClient<$Result.GetResult<Prisma.$TransactionPayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>

    /**
     * Find zero or more Transactions 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 {TransactionFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all Transactions
     * const transactions = await prisma.transaction.findMany()
     * 
     * // Get first 10 Transactions
     * const transactions = await prisma.transaction.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const transactionWithIdOnly = await prisma.transaction.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends TransactionFindManyArgs>(args?: SelectSubset<T, TransactionFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$TransactionPayload<ExtArgs>, T, "findMany">>

    /**
     * Create a Transaction.
     * @param {TransactionCreateArgs} args - Arguments to create a Transaction.
     * @example
     * // Create one Transaction
     * const Transaction = await prisma.transaction.create({
     *   data: {
     *     // ... data to create a Transaction
     *   }
     * })
     * 
     */
    create<T extends TransactionCreateArgs>(args: SelectSubset<T, TransactionCreateArgs<ExtArgs>>): Prisma__TransactionClient<$Result.GetResult<Prisma.$TransactionPayload<ExtArgs>, T, "create">, never, ExtArgs>

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

    /**
     * Delete a Transaction.
     * @param {TransactionDeleteArgs} args - Arguments to delete one Transaction.
     * @example
     * // Delete one Transaction
     * const Transaction = await prisma.transaction.delete({
     *   where: {
     *     // ... filter to delete one Transaction
     *   }
     * })
     * 
     */
    delete<T extends TransactionDeleteArgs>(args: SelectSubset<T, TransactionDeleteArgs<ExtArgs>>): Prisma__TransactionClient<$Result.GetResult<Prisma.$TransactionPayload<ExtArgs>, T, "delete">, never, ExtArgs>

    /**
     * Update one Transaction.
     * @param {TransactionUpdateArgs} args - Arguments to update one Transaction.
     * @example
     * // Update one Transaction
     * const transaction = await prisma.transaction.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends TransactionUpdateArgs>(args: SelectSubset<T, TransactionUpdateArgs<ExtArgs>>): Prisma__TransactionClient<$Result.GetResult<Prisma.$TransactionPayload<ExtArgs>, T, "update">, never, ExtArgs>

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

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

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


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

    /**
     * Allows you to perform aggregations operations on a Transaction.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {TransactionAggregateArgs} 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 TransactionAggregateArgs>(args: Subset<T, TransactionAggregateArgs>): Prisma.PrismaPromise<GetTransactionAggregateType<T>>

    /**
     * Group by Transaction.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {TransactionGroupByArgs} 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 TransactionGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: TransactionGroupByArgs['orderBy'] }
        : { orderBy?: TransactionGroupByArgs['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, TransactionGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetTransactionGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the Transaction model
   */
  readonly fields: TransactionFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for Transaction.
   * 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__TransactionClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> 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 Transaction model
   */ 
  interface TransactionFieldRefs {
    readonly id: FieldRef<"Transaction", 'String'>
    readonly tipo: FieldRef<"Transaction", 'String'>
    readonly valor: FieldRef<"Transaction", 'Float'>
    readonly fromAccount: FieldRef<"Transaction", 'String'>
    readonly toAccount: FieldRef<"Transaction", 'String'>
    readonly referencia: FieldRef<"Transaction", 'String'>
    readonly status: FieldRef<"Transaction", 'String'>
    readonly timestamp: FieldRef<"Transaction", 'DateTime'>
    readonly auditJson: FieldRef<"Transaction", 'String'>
  }
    

  // Custom InputTypes
  /**
   * Transaction findUnique
   */
  export type TransactionFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Transaction
     */
    select?: TransactionSelect<ExtArgs> | null
    /**
     * Filter, which Transaction to fetch.
     */
    where: TransactionWhereUniqueInput
  }

  /**
   * Transaction findUniqueOrThrow
   */
  export type TransactionFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Transaction
     */
    select?: TransactionSelect<ExtArgs> | null
    /**
     * Filter, which Transaction to fetch.
     */
    where: TransactionWhereUniqueInput
  }

  /**
   * Transaction findFirst
   */
  export type TransactionFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Transaction
     */
    select?: TransactionSelect<ExtArgs> | null
    /**
     * Filter, which Transaction to fetch.
     */
    where?: TransactionWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Transactions to fetch.
     */
    orderBy?: TransactionOrderByWithRelationInput | TransactionOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for Transactions.
     */
    cursor?: TransactionWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Transactions 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` Transactions.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of Transactions.
     */
    distinct?: TransactionScalarFieldEnum | TransactionScalarFieldEnum[]
  }

  /**
   * Transaction findFirstOrThrow
   */
  export type TransactionFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Transaction
     */
    select?: TransactionSelect<ExtArgs> | null
    /**
     * Filter, which Transaction to fetch.
     */
    where?: TransactionWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Transactions to fetch.
     */
    orderBy?: TransactionOrderByWithRelationInput | TransactionOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for Transactions.
     */
    cursor?: TransactionWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Transactions 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` Transactions.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of Transactions.
     */
    distinct?: TransactionScalarFieldEnum | TransactionScalarFieldEnum[]
  }

  /**
   * Transaction findMany
   */
  export type TransactionFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Transaction
     */
    select?: TransactionSelect<ExtArgs> | null
    /**
     * Filter, which Transactions to fetch.
     */
    where?: TransactionWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Transactions to fetch.
     */
    orderBy?: TransactionOrderByWithRelationInput | TransactionOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing Transactions.
     */
    cursor?: TransactionWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Transactions 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` Transactions.
     */
    skip?: number
    distinct?: TransactionScalarFieldEnum | TransactionScalarFieldEnum[]
  }

  /**
   * Transaction create
   */
  export type TransactionCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Transaction
     */
    select?: TransactionSelect<ExtArgs> | null
    /**
     * The data needed to create a Transaction.
     */
    data: XOR<TransactionCreateInput, TransactionUncheckedCreateInput>
  }

  /**
   * Transaction createMany
   */
  export type TransactionCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many Transactions.
     */
    data: TransactionCreateManyInput | TransactionCreateManyInput[]
    skipDuplicates?: boolean
  }

  /**
   * Transaction update
   */
  export type TransactionUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Transaction
     */
    select?: TransactionSelect<ExtArgs> | null
    /**
     * The data needed to update a Transaction.
     */
    data: XOR<TransactionUpdateInput, TransactionUncheckedUpdateInput>
    /**
     * Choose, which Transaction to update.
     */
    where: TransactionWhereUniqueInput
  }

  /**
   * Transaction updateMany
   */
  export type TransactionUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update Transactions.
     */
    data: XOR<TransactionUpdateManyMutationInput, TransactionUncheckedUpdateManyInput>
    /**
     * Filter which Transactions to update
     */
    where?: TransactionWhereInput
  }

  /**
   * Transaction upsert
   */
  export type TransactionUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Transaction
     */
    select?: TransactionSelect<ExtArgs> | null
    /**
     * The filter to search for the Transaction to update in case it exists.
     */
    where: TransactionWhereUniqueInput
    /**
     * In case the Transaction found by the `where` argument doesn't exist, create a new Transaction with this data.
     */
    create: XOR<TransactionCreateInput, TransactionUncheckedCreateInput>
    /**
     * In case the Transaction was found with the provided `where` argument, update it with this data.
     */
    update: XOR<TransactionUpdateInput, TransactionUncheckedUpdateInput>
  }

  /**
   * Transaction delete
   */
  export type TransactionDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Transaction
     */
    select?: TransactionSelect<ExtArgs> | null
    /**
     * Filter which Transaction to delete.
     */
    where: TransactionWhereUniqueInput
  }

  /**
   * Transaction deleteMany
   */
  export type TransactionDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which Transactions to delete
     */
    where?: TransactionWhereInput
  }

  /**
   * Transaction without action
   */
  export type TransactionDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Transaction
     */
    select?: TransactionSelect<ExtArgs> | null
  }


  /**
   * Model ScoreEvent
   */

  export type AggregateScoreEvent = {
    _count: ScoreEventCountAggregateOutputType | null
    _avg: ScoreEventAvgAggregateOutputType | null
    _sum: ScoreEventSumAggregateOutputType | null
    _min: ScoreEventMinAggregateOutputType | null
    _max: ScoreEventMaxAggregateOutputType | null
  }

  export type ScoreEventAvgAggregateOutputType = {
    impacto: number | null
    scoreAntes: number | null
    scoreDepois: number | null
  }

  export type ScoreEventSumAggregateOutputType = {
    impacto: number | null
    scoreAntes: number | null
    scoreDepois: number | null
  }

  export type ScoreEventMinAggregateOutputType = {
    id: string | null
    userId: string | null
    tipoEvento: string | null
    impacto: number | null
    descricao: string | null
    scoreAntes: number | null
    scoreDepois: number | null
    timestamp: Date | null
  }

  export type ScoreEventMaxAggregateOutputType = {
    id: string | null
    userId: string | null
    tipoEvento: string | null
    impacto: number | null
    descricao: string | null
    scoreAntes: number | null
    scoreDepois: number | null
    timestamp: Date | null
  }

  export type ScoreEventCountAggregateOutputType = {
    id: number
    userId: number
    tipoEvento: number
    impacto: number
    descricao: number
    scoreAntes: number
    scoreDepois: number
    timestamp: number
    _all: number
  }


  export type ScoreEventAvgAggregateInputType = {
    impacto?: true
    scoreAntes?: true
    scoreDepois?: true
  }

  export type ScoreEventSumAggregateInputType = {
    impacto?: true
    scoreAntes?: true
    scoreDepois?: true
  }

  export type ScoreEventMinAggregateInputType = {
    id?: true
    userId?: true
    tipoEvento?: true
    impacto?: true
    descricao?: true
    scoreAntes?: true
    scoreDepois?: true
    timestamp?: true
  }

  export type ScoreEventMaxAggregateInputType = {
    id?: true
    userId?: true
    tipoEvento?: true
    impacto?: true
    descricao?: true
    scoreAntes?: true
    scoreDepois?: true
    timestamp?: true
  }

  export type ScoreEventCountAggregateInputType = {
    id?: true
    userId?: true
    tipoEvento?: true
    impacto?: true
    descricao?: true
    scoreAntes?: true
    scoreDepois?: true
    timestamp?: true
    _all?: true
  }

  export type ScoreEventAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which ScoreEvent to aggregate.
     */
    where?: ScoreEventWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of ScoreEvents to fetch.
     */
    orderBy?: ScoreEventOrderByWithRelationInput | ScoreEventOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: ScoreEventWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` ScoreEvents 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` ScoreEvents.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned ScoreEvents
    **/
    _count?: true | ScoreEventCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to average
    **/
    _avg?: ScoreEventAvgAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to sum
    **/
    _sum?: ScoreEventSumAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: ScoreEventMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: ScoreEventMaxAggregateInputType
  }

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




  export type ScoreEventGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: ScoreEventWhereInput
    orderBy?: ScoreEventOrderByWithAggregationInput | ScoreEventOrderByWithAggregationInput[]
    by: ScoreEventScalarFieldEnum[] | ScoreEventScalarFieldEnum
    having?: ScoreEventScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: ScoreEventCountAggregateInputType | true
    _avg?: ScoreEventAvgAggregateInputType
    _sum?: ScoreEventSumAggregateInputType
    _min?: ScoreEventMinAggregateInputType
    _max?: ScoreEventMaxAggregateInputType
  }

  export type ScoreEventGroupByOutputType = {
    id: string
    userId: string
    tipoEvento: string
    impacto: number
    descricao: string | null
    scoreAntes: number
    scoreDepois: number
    timestamp: Date
    _count: ScoreEventCountAggregateOutputType | null
    _avg: ScoreEventAvgAggregateOutputType | null
    _sum: ScoreEventSumAggregateOutputType | null
    _min: ScoreEventMinAggregateOutputType | null
    _max: ScoreEventMaxAggregateOutputType | null
  }

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


  export type ScoreEventSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    userId?: boolean
    tipoEvento?: boolean
    impacto?: boolean
    descricao?: boolean
    scoreAntes?: boolean
    scoreDepois?: boolean
    timestamp?: boolean
    user?: boolean | UserDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["scoreEvent"]>


  export type ScoreEventSelectScalar = {
    id?: boolean
    userId?: boolean
    tipoEvento?: boolean
    impacto?: boolean
    descricao?: boolean
    scoreAntes?: boolean
    scoreDepois?: boolean
    timestamp?: boolean
  }

  export type ScoreEventInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    user?: boolean | UserDefaultArgs<ExtArgs>
  }

  export type $ScoreEventPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "ScoreEvent"
    objects: {
      user: Prisma.$UserPayload<ExtArgs>
    }
    scalars: $Extensions.GetPayloadResult<{
      id: string
      userId: string
      tipoEvento: string
      impacto: number
      descricao: string | null
      scoreAntes: number
      scoreDepois: number
      timestamp: Date
    }, ExtArgs["result"]["scoreEvent"]>
    composites: {}
  }

  type ScoreEventGetPayload<S extends boolean | null | undefined | ScoreEventDefaultArgs> = $Result.GetResult<Prisma.$ScoreEventPayload, S>

  type ScoreEventCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = 
    Omit<ScoreEventFindManyArgs, 'select' | 'include' | 'distinct'> & {
      select?: ScoreEventCountAggregateInputType | true
    }

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

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

    /**
     * Find the first ScoreEvent 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 {ScoreEventFindFirstArgs} args - Arguments to find a ScoreEvent
     * @example
     * // Get one ScoreEvent
     * const scoreEvent = await prisma.scoreEvent.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends ScoreEventFindFirstArgs>(args?: SelectSubset<T, ScoreEventFindFirstArgs<ExtArgs>>): Prisma__ScoreEventClient<$Result.GetResult<Prisma.$ScoreEventPayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>

    /**
     * Find the first ScoreEvent 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 {ScoreEventFindFirstOrThrowArgs} args - Arguments to find a ScoreEvent
     * @example
     * // Get one ScoreEvent
     * const scoreEvent = await prisma.scoreEvent.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends ScoreEventFindFirstOrThrowArgs>(args?: SelectSubset<T, ScoreEventFindFirstOrThrowArgs<ExtArgs>>): Prisma__ScoreEventClient<$Result.GetResult<Prisma.$ScoreEventPayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>

    /**
     * Find zero or more ScoreEvents 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 {ScoreEventFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all ScoreEvents
     * const scoreEvents = await prisma.scoreEvent.findMany()
     * 
     * // Get first 10 ScoreEvents
     * const scoreEvents = await prisma.scoreEvent.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const scoreEventWithIdOnly = await prisma.scoreEvent.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends ScoreEventFindManyArgs>(args?: SelectSubset<T, ScoreEventFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$ScoreEventPayload<ExtArgs>, T, "findMany">>

    /**
     * Create a ScoreEvent.
     * @param {ScoreEventCreateArgs} args - Arguments to create a ScoreEvent.
     * @example
     * // Create one ScoreEvent
     * const ScoreEvent = await prisma.scoreEvent.create({
     *   data: {
     *     // ... data to create a ScoreEvent
     *   }
     * })
     * 
     */
    create<T extends ScoreEventCreateArgs>(args: SelectSubset<T, ScoreEventCreateArgs<ExtArgs>>): Prisma__ScoreEventClient<$Result.GetResult<Prisma.$ScoreEventPayload<ExtArgs>, T, "create">, never, ExtArgs>

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

    /**
     * Delete a ScoreEvent.
     * @param {ScoreEventDeleteArgs} args - Arguments to delete one ScoreEvent.
     * @example
     * // Delete one ScoreEvent
     * const ScoreEvent = await prisma.scoreEvent.delete({
     *   where: {
     *     // ... filter to delete one ScoreEvent
     *   }
     * })
     * 
     */
    delete<T extends ScoreEventDeleteArgs>(args: SelectSubset<T, ScoreEventDeleteArgs<ExtArgs>>): Prisma__ScoreEventClient<$Result.GetResult<Prisma.$ScoreEventPayload<ExtArgs>, T, "delete">, never, ExtArgs>

    /**
     * Update one ScoreEvent.
     * @param {ScoreEventUpdateArgs} args - Arguments to update one ScoreEvent.
     * @example
     * // Update one ScoreEvent
     * const scoreEvent = await prisma.scoreEvent.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends ScoreEventUpdateArgs>(args: SelectSubset<T, ScoreEventUpdateArgs<ExtArgs>>): Prisma__ScoreEventClient<$Result.GetResult<Prisma.$ScoreEventPayload<ExtArgs>, T, "update">, never, ExtArgs>

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

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

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


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

    /**
     * Allows you to perform aggregations operations on a ScoreEvent.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {ScoreEventAggregateArgs} 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 ScoreEventAggregateArgs>(args: Subset<T, ScoreEventAggregateArgs>): Prisma.PrismaPromise<GetScoreEventAggregateType<T>>

    /**
     * Group by ScoreEvent.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {ScoreEventGroupByArgs} 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 ScoreEventGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: ScoreEventGroupByArgs['orderBy'] }
        : { orderBy?: ScoreEventGroupByArgs['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, ScoreEventGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetScoreEventGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the ScoreEvent model
   */
  readonly fields: ScoreEventFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for ScoreEvent.
   * 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__ScoreEventClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> 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"> | Null, Null, ExtArgs>
    /**
     * 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 ScoreEvent model
   */ 
  interface ScoreEventFieldRefs {
    readonly id: FieldRef<"ScoreEvent", 'String'>
    readonly userId: FieldRef<"ScoreEvent", 'String'>
    readonly tipoEvento: FieldRef<"ScoreEvent", 'String'>
    readonly impacto: FieldRef<"ScoreEvent", 'Int'>
    readonly descricao: FieldRef<"ScoreEvent", 'String'>
    readonly scoreAntes: FieldRef<"ScoreEvent", 'Int'>
    readonly scoreDepois: FieldRef<"ScoreEvent", 'Int'>
    readonly timestamp: FieldRef<"ScoreEvent", 'DateTime'>
  }
    

  // Custom InputTypes
  /**
   * ScoreEvent findUnique
   */
  export type ScoreEventFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ScoreEvent
     */
    select?: ScoreEventSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ScoreEventInclude<ExtArgs> | null
    /**
     * Filter, which ScoreEvent to fetch.
     */
    where: ScoreEventWhereUniqueInput
  }

  /**
   * ScoreEvent findUniqueOrThrow
   */
  export type ScoreEventFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ScoreEvent
     */
    select?: ScoreEventSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ScoreEventInclude<ExtArgs> | null
    /**
     * Filter, which ScoreEvent to fetch.
     */
    where: ScoreEventWhereUniqueInput
  }

  /**
   * ScoreEvent findFirst
   */
  export type ScoreEventFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ScoreEvent
     */
    select?: ScoreEventSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ScoreEventInclude<ExtArgs> | null
    /**
     * Filter, which ScoreEvent to fetch.
     */
    where?: ScoreEventWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of ScoreEvents to fetch.
     */
    orderBy?: ScoreEventOrderByWithRelationInput | ScoreEventOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for ScoreEvents.
     */
    cursor?: ScoreEventWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` ScoreEvents 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` ScoreEvents.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of ScoreEvents.
     */
    distinct?: ScoreEventScalarFieldEnum | ScoreEventScalarFieldEnum[]
  }

  /**
   * ScoreEvent findFirstOrThrow
   */
  export type ScoreEventFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ScoreEvent
     */
    select?: ScoreEventSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ScoreEventInclude<ExtArgs> | null
    /**
     * Filter, which ScoreEvent to fetch.
     */
    where?: ScoreEventWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of ScoreEvents to fetch.
     */
    orderBy?: ScoreEventOrderByWithRelationInput | ScoreEventOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for ScoreEvents.
     */
    cursor?: ScoreEventWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` ScoreEvents 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` ScoreEvents.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of ScoreEvents.
     */
    distinct?: ScoreEventScalarFieldEnum | ScoreEventScalarFieldEnum[]
  }

  /**
   * ScoreEvent findMany
   */
  export type ScoreEventFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ScoreEvent
     */
    select?: ScoreEventSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ScoreEventInclude<ExtArgs> | null
    /**
     * Filter, which ScoreEvents to fetch.
     */
    where?: ScoreEventWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of ScoreEvents to fetch.
     */
    orderBy?: ScoreEventOrderByWithRelationInput | ScoreEventOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing ScoreEvents.
     */
    cursor?: ScoreEventWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` ScoreEvents 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` ScoreEvents.
     */
    skip?: number
    distinct?: ScoreEventScalarFieldEnum | ScoreEventScalarFieldEnum[]
  }

  /**
   * ScoreEvent create
   */
  export type ScoreEventCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ScoreEvent
     */
    select?: ScoreEventSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ScoreEventInclude<ExtArgs> | null
    /**
     * The data needed to create a ScoreEvent.
     */
    data: XOR<ScoreEventCreateInput, ScoreEventUncheckedCreateInput>
  }

  /**
   * ScoreEvent createMany
   */
  export type ScoreEventCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many ScoreEvents.
     */
    data: ScoreEventCreateManyInput | ScoreEventCreateManyInput[]
    skipDuplicates?: boolean
  }

  /**
   * ScoreEvent update
   */
  export type ScoreEventUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ScoreEvent
     */
    select?: ScoreEventSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ScoreEventInclude<ExtArgs> | null
    /**
     * The data needed to update a ScoreEvent.
     */
    data: XOR<ScoreEventUpdateInput, ScoreEventUncheckedUpdateInput>
    /**
     * Choose, which ScoreEvent to update.
     */
    where: ScoreEventWhereUniqueInput
  }

  /**
   * ScoreEvent updateMany
   */
  export type ScoreEventUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update ScoreEvents.
     */
    data: XOR<ScoreEventUpdateManyMutationInput, ScoreEventUncheckedUpdateManyInput>
    /**
     * Filter which ScoreEvents to update
     */
    where?: ScoreEventWhereInput
  }

  /**
   * ScoreEvent upsert
   */
  export type ScoreEventUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ScoreEvent
     */
    select?: ScoreEventSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ScoreEventInclude<ExtArgs> | null
    /**
     * The filter to search for the ScoreEvent to update in case it exists.
     */
    where: ScoreEventWhereUniqueInput
    /**
     * In case the ScoreEvent found by the `where` argument doesn't exist, create a new ScoreEvent with this data.
     */
    create: XOR<ScoreEventCreateInput, ScoreEventUncheckedCreateInput>
    /**
     * In case the ScoreEvent was found with the provided `where` argument, update it with this data.
     */
    update: XOR<ScoreEventUpdateInput, ScoreEventUncheckedUpdateInput>
  }

  /**
   * ScoreEvent delete
   */
  export type ScoreEventDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ScoreEvent
     */
    select?: ScoreEventSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ScoreEventInclude<ExtArgs> | null
    /**
     * Filter which ScoreEvent to delete.
     */
    where: ScoreEventWhereUniqueInput
  }

  /**
   * ScoreEvent deleteMany
   */
  export type ScoreEventDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which ScoreEvents to delete
     */
    where?: ScoreEventWhereInput
  }

  /**
   * ScoreEvent without action
   */
  export type ScoreEventDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ScoreEvent
     */
    select?: ScoreEventSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ScoreEventInclude<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
    canal: string | null
    titulo: string | null
    corpo: string | null
    lida: boolean | null
    metadataJson: string | null
    createdAt: Date | null
  }

  export type NotificationMaxAggregateOutputType = {
    id: string | null
    userId: string | null
    canal: string | null
    titulo: string | null
    corpo: string | null
    lida: boolean | null
    metadataJson: string | null
    createdAt: Date | null
  }

  export type NotificationCountAggregateOutputType = {
    id: number
    userId: number
    canal: number
    titulo: number
    corpo: number
    lida: number
    metadataJson: number
    createdAt: number
    _all: number
  }


  export type NotificationMinAggregateInputType = {
    id?: true
    userId?: true
    canal?: true
    titulo?: true
    corpo?: true
    lida?: true
    metadataJson?: true
    createdAt?: true
  }

  export type NotificationMaxAggregateInputType = {
    id?: true
    userId?: true
    canal?: true
    titulo?: true
    corpo?: true
    lida?: true
    metadataJson?: true
    createdAt?: true
  }

  export type NotificationCountAggregateInputType = {
    id?: true
    userId?: true
    canal?: true
    titulo?: true
    corpo?: true
    lida?: true
    metadataJson?: true
    createdAt?: 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
    canal: string
    titulo: string
    corpo: string
    lida: boolean
    metadataJson: string | null
    createdAt: 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
    canal?: boolean
    titulo?: boolean
    corpo?: boolean
    lida?: boolean
    metadataJson?: boolean
    createdAt?: boolean
    user?: boolean | UserDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["notification"]>


  export type NotificationSelectScalar = {
    id?: boolean
    userId?: boolean
    canal?: boolean
    titulo?: boolean
    corpo?: boolean
    lida?: boolean
    metadataJson?: boolean
    createdAt?: boolean
  }

  export type NotificationInclude<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
      canal: string
      titulo: string
      corpo: string
      lida: boolean
      metadataJson: string | null
      createdAt: 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'> & {
      select?: NotificationCountAggregateInputType | true
    }

  export interface NotificationDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> {
    [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"> | null, null, ExtArgs>

    /**
     * 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">, never, ExtArgs>

    /**
     * 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"> | null, null, ExtArgs>

    /**
     * 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">, never, ExtArgs>

    /**
     * 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">>

    /**
     * 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">, never, ExtArgs>

    /**
     * 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>

    /**
     * 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">, never, ExtArgs>

    /**
     * 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">, never, ExtArgs>

    /**
     * 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>

    /**
     * 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">, never, ExtArgs>


    /**
     * 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> 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"> | Null, Null, ExtArgs>
    /**
     * 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 canal: FieldRef<"Notification", 'String'>
    readonly titulo: FieldRef<"Notification", 'String'>
    readonly corpo: FieldRef<"Notification", 'String'>
    readonly lida: FieldRef<"Notification", 'Boolean'>
    readonly metadataJson: FieldRef<"Notification", 'String'>
    readonly createdAt: 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
    /**
     * 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
    /**
     * 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
    /**
     * 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
    /**
     * 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
    /**
     * 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
    /**
     * 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[]
    skipDuplicates?: boolean
  }

  /**
   * Notification update
   */
  export type NotificationUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Notification
     */
    select?: NotificationSelect<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
  }

  /**
   * Notification upsert
   */
  export type NotificationUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Notification
     */
    select?: NotificationSelect<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
    /**
     * 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
  }

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


  /**
   * Model AuditLog
   */

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

  export type AuditLogMinAggregateOutputType = {
    id: string | null
    userId: string | null
    acao: string | null
    entidade: string | null
    entidadeId: string | null
    dadosAntes: string | null
    dadosDepois: string | null
    ip: string | null
    timestamp: Date | null
  }

  export type AuditLogMaxAggregateOutputType = {
    id: string | null
    userId: string | null
    acao: string | null
    entidade: string | null
    entidadeId: string | null
    dadosAntes: string | null
    dadosDepois: string | null
    ip: string | null
    timestamp: Date | null
  }

  export type AuditLogCountAggregateOutputType = {
    id: number
    userId: number
    acao: number
    entidade: number
    entidadeId: number
    dadosAntes: number
    dadosDepois: number
    ip: number
    timestamp: number
    _all: number
  }


  export type AuditLogMinAggregateInputType = {
    id?: true
    userId?: true
    acao?: true
    entidade?: true
    entidadeId?: true
    dadosAntes?: true
    dadosDepois?: true
    ip?: true
    timestamp?: true
  }

  export type AuditLogMaxAggregateInputType = {
    id?: true
    userId?: true
    acao?: true
    entidade?: true
    entidadeId?: true
    dadosAntes?: true
    dadosDepois?: true
    ip?: true
    timestamp?: true
  }

  export type AuditLogCountAggregateInputType = {
    id?: true
    userId?: true
    acao?: true
    entidade?: true
    entidadeId?: true
    dadosAntes?: true
    dadosDepois?: true
    ip?: true
    timestamp?: 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
    userId: string | null
    acao: string
    entidade: string
    entidadeId: string | null
    dadosAntes: string | null
    dadosDepois: string | null
    ip: string | null
    timestamp: 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
    userId?: boolean
    acao?: boolean
    entidade?: boolean
    entidadeId?: boolean
    dadosAntes?: boolean
    dadosDepois?: boolean
    ip?: boolean
    timestamp?: boolean
    user?: boolean | AuditLog$userArgs<ExtArgs>
  }, ExtArgs["result"]["auditLog"]>


  export type AuditLogSelectScalar = {
    id?: boolean
    userId?: boolean
    acao?: boolean
    entidade?: boolean
    entidadeId?: boolean
    dadosAntes?: boolean
    dadosDepois?: boolean
    ip?: boolean
    timestamp?: boolean
  }

  export type AuditLogInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    user?: boolean | AuditLog$userArgs<ExtArgs>
  }

  export type $AuditLogPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "AuditLog"
    objects: {
      user: Prisma.$UserPayload<ExtArgs> | null
    }
    scalars: $Extensions.GetPayloadResult<{
      id: string
      userId: string | null
      acao: string
      entidade: string
      entidadeId: string | null
      dadosAntes: string | null
      dadosDepois: string | null
      ip: string | null
      timestamp: 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'> & {
      select?: AuditLogCountAggregateInputType | true
    }

  export interface AuditLogDelegate<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> {
    [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"> | null, null, ExtArgs>

    /**
     * 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">, never, ExtArgs>

    /**
     * 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"> | null, null, ExtArgs>

    /**
     * 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">, never, ExtArgs>

    /**
     * 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">>

    /**
     * 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">, never, ExtArgs>

    /**
     * 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>

    /**
     * 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">, never, ExtArgs>

    /**
     * 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">, never, ExtArgs>

    /**
     * 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>

    /**
     * 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">, never, ExtArgs>


    /**
     * 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> extends Prisma.PrismaPromise<T> {
    readonly [Symbol.toStringTag]: "PrismaPromise"
    user<T extends AuditLog$userArgs<ExtArgs> = {}>(args?: Subset<T, AuditLog$userArgs<ExtArgs>>): Prisma__UserClient<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "findUniqueOrThrow"> | null, null, ExtArgs>
    /**
     * 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 userId: FieldRef<"AuditLog", 'String'>
    readonly acao: FieldRef<"AuditLog", 'String'>
    readonly entidade: FieldRef<"AuditLog", 'String'>
    readonly entidadeId: FieldRef<"AuditLog", 'String'>
    readonly dadosAntes: FieldRef<"AuditLog", 'String'>
    readonly dadosDepois: FieldRef<"AuditLog", 'String'>
    readonly ip: FieldRef<"AuditLog", 'String'>
    readonly timestamp: 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
    /**
     * 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
    /**
     * 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
    /**
     * 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
    /**
     * 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
    /**
     * 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
    /**
     * 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[]
    skipDuplicates?: boolean
  }

  /**
   * AuditLog update
   */
  export type AuditLogUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the AuditLog
     */
    select?: AuditLogSelect<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
  }

  /**
   * AuditLog upsert
   */
  export type AuditLogUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the AuditLog
     */
    select?: AuditLogSelect<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
    /**
     * 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
  }

  /**
   * AuditLog.user
   */
  export type AuditLog$userArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the User
     */
    select?: UserSelect<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
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: AuditLogInclude<ExtArgs> | null
  }


  /**
   * Model SystemClock
   */

  export type AggregateSystemClock = {
    _count: SystemClockCountAggregateOutputType | null
    _avg: SystemClockAvgAggregateOutputType | null
    _sum: SystemClockSumAggregateOutputType | null
    _min: SystemClockMinAggregateOutputType | null
    _max: SystemClockMaxAggregateOutputType | null
  }

  export type SystemClockAvgAggregateOutputType = {
    id: number | null
  }

  export type SystemClockSumAggregateOutputType = {
    id: number | null
  }

  export type SystemClockMinAggregateOutputType = {
    id: number | null
    agora: Date | null
    updatedAt: Date | null
  }

  export type SystemClockMaxAggregateOutputType = {
    id: number | null
    agora: Date | null
    updatedAt: Date | null
  }

  export type SystemClockCountAggregateOutputType = {
    id: number
    agora: number
    updatedAt: number
    _all: number
  }


  export type SystemClockAvgAggregateInputType = {
    id?: true
  }

  export type SystemClockSumAggregateInputType = {
    id?: true
  }

  export type SystemClockMinAggregateInputType = {
    id?: true
    agora?: true
    updatedAt?: true
  }

  export type SystemClockMaxAggregateInputType = {
    id?: true
    agora?: true
    updatedAt?: true
  }

  export type SystemClockCountAggregateInputType = {
    id?: true
    agora?: true
    updatedAt?: true
    _all?: true
  }

  export type SystemClockAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which SystemClock to aggregate.
     */
    where?: SystemClockWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of SystemClocks to fetch.
     */
    orderBy?: SystemClockOrderByWithRelationInput | SystemClockOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: SystemClockWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` SystemClocks 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` SystemClocks.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned SystemClocks
    **/
    _count?: true | SystemClockCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to average
    **/
    _avg?: SystemClockAvgAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to sum
    **/
    _sum?: SystemClockSumAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: SystemClockMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: SystemClockMaxAggregateInputType
  }

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




  export type SystemClockGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: SystemClockWhereInput
    orderBy?: SystemClockOrderByWithAggregationInput | SystemClockOrderByWithAggregationInput[]
    by: SystemClockScalarFieldEnum[] | SystemClockScalarFieldEnum
    having?: SystemClockScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: SystemClockCountAggregateInputType | true
    _avg?: SystemClockAvgAggregateInputType
    _sum?: SystemClockSumAggregateInputType
    _min?: SystemClockMinAggregateInputType
    _max?: SystemClockMaxAggregateInputType
  }

  export type SystemClockGroupByOutputType = {
    id: number
    agora: Date
    updatedAt: Date
    _count: SystemClockCountAggregateOutputType | null
    _avg: SystemClockAvgAggregateOutputType | null
    _sum: SystemClockSumAggregateOutputType | null
    _min: SystemClockMinAggregateOutputType | null
    _max: SystemClockMaxAggregateOutputType | null
  }

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


  export type SystemClockSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    agora?: boolean
    updatedAt?: boolean
  }, ExtArgs["result"]["systemClock"]>


  export type SystemClockSelectScalar = {
    id?: boolean
    agora?: boolean
    updatedAt?: boolean
  }


  export type $SystemClockPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "SystemClock"
    objects: {}
    scalars: $Extensions.GetPayloadResult<{
      id: number
      agora: Date
      updatedAt: Date
    }, ExtArgs["result"]["systemClock"]>
    composites: {}
  }

  type SystemClockGetPayload<S extends boolean | null | undefined | SystemClockDefaultArgs> = $Result.GetResult<Prisma.$SystemClockPayload, S>

  type SystemClockCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = 
    Omit<SystemClockFindManyArgs, 'select' | 'include' | 'distinct'> & {
      select?: SystemClockCountAggregateInputType | true
    }

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

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

    /**
     * Find the first SystemClock 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 {SystemClockFindFirstArgs} args - Arguments to find a SystemClock
     * @example
     * // Get one SystemClock
     * const systemClock = await prisma.systemClock.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends SystemClockFindFirstArgs>(args?: SelectSubset<T, SystemClockFindFirstArgs<ExtArgs>>): Prisma__SystemClockClient<$Result.GetResult<Prisma.$SystemClockPayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>

    /**
     * Find the first SystemClock 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 {SystemClockFindFirstOrThrowArgs} args - Arguments to find a SystemClock
     * @example
     * // Get one SystemClock
     * const systemClock = await prisma.systemClock.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends SystemClockFindFirstOrThrowArgs>(args?: SelectSubset<T, SystemClockFindFirstOrThrowArgs<ExtArgs>>): Prisma__SystemClockClient<$Result.GetResult<Prisma.$SystemClockPayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>

    /**
     * Find zero or more SystemClocks 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 {SystemClockFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all SystemClocks
     * const systemClocks = await prisma.systemClock.findMany()
     * 
     * // Get first 10 SystemClocks
     * const systemClocks = await prisma.systemClock.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const systemClockWithIdOnly = await prisma.systemClock.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends SystemClockFindManyArgs>(args?: SelectSubset<T, SystemClockFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$SystemClockPayload<ExtArgs>, T, "findMany">>

    /**
     * Create a SystemClock.
     * @param {SystemClockCreateArgs} args - Arguments to create a SystemClock.
     * @example
     * // Create one SystemClock
     * const SystemClock = await prisma.systemClock.create({
     *   data: {
     *     // ... data to create a SystemClock
     *   }
     * })
     * 
     */
    create<T extends SystemClockCreateArgs>(args: SelectSubset<T, SystemClockCreateArgs<ExtArgs>>): Prisma__SystemClockClient<$Result.GetResult<Prisma.$SystemClockPayload<ExtArgs>, T, "create">, never, ExtArgs>

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

    /**
     * Delete a SystemClock.
     * @param {SystemClockDeleteArgs} args - Arguments to delete one SystemClock.
     * @example
     * // Delete one SystemClock
     * const SystemClock = await prisma.systemClock.delete({
     *   where: {
     *     // ... filter to delete one SystemClock
     *   }
     * })
     * 
     */
    delete<T extends SystemClockDeleteArgs>(args: SelectSubset<T, SystemClockDeleteArgs<ExtArgs>>): Prisma__SystemClockClient<$Result.GetResult<Prisma.$SystemClockPayload<ExtArgs>, T, "delete">, never, ExtArgs>

    /**
     * Update one SystemClock.
     * @param {SystemClockUpdateArgs} args - Arguments to update one SystemClock.
     * @example
     * // Update one SystemClock
     * const systemClock = await prisma.systemClock.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends SystemClockUpdateArgs>(args: SelectSubset<T, SystemClockUpdateArgs<ExtArgs>>): Prisma__SystemClockClient<$Result.GetResult<Prisma.$SystemClockPayload<ExtArgs>, T, "update">, never, ExtArgs>

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

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

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


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

    /**
     * Allows you to perform aggregations operations on a SystemClock.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {SystemClockAggregateArgs} 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 SystemClockAggregateArgs>(args: Subset<T, SystemClockAggregateArgs>): Prisma.PrismaPromise<GetSystemClockAggregateType<T>>

    /**
     * Group by SystemClock.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {SystemClockGroupByArgs} 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 SystemClockGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: SystemClockGroupByArgs['orderBy'] }
        : { orderBy?: SystemClockGroupByArgs['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, SystemClockGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetSystemClockGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the SystemClock model
   */
  readonly fields: SystemClockFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for SystemClock.
   * 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__SystemClockClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> 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 SystemClock model
   */ 
  interface SystemClockFieldRefs {
    readonly id: FieldRef<"SystemClock", 'Int'>
    readonly agora: FieldRef<"SystemClock", 'DateTime'>
    readonly updatedAt: FieldRef<"SystemClock", 'DateTime'>
  }
    

  // Custom InputTypes
  /**
   * SystemClock findUnique
   */
  export type SystemClockFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SystemClock
     */
    select?: SystemClockSelect<ExtArgs> | null
    /**
     * Filter, which SystemClock to fetch.
     */
    where: SystemClockWhereUniqueInput
  }

  /**
   * SystemClock findUniqueOrThrow
   */
  export type SystemClockFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SystemClock
     */
    select?: SystemClockSelect<ExtArgs> | null
    /**
     * Filter, which SystemClock to fetch.
     */
    where: SystemClockWhereUniqueInput
  }

  /**
   * SystemClock findFirst
   */
  export type SystemClockFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SystemClock
     */
    select?: SystemClockSelect<ExtArgs> | null
    /**
     * Filter, which SystemClock to fetch.
     */
    where?: SystemClockWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of SystemClocks to fetch.
     */
    orderBy?: SystemClockOrderByWithRelationInput | SystemClockOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for SystemClocks.
     */
    cursor?: SystemClockWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` SystemClocks 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` SystemClocks.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of SystemClocks.
     */
    distinct?: SystemClockScalarFieldEnum | SystemClockScalarFieldEnum[]
  }

  /**
   * SystemClock findFirstOrThrow
   */
  export type SystemClockFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SystemClock
     */
    select?: SystemClockSelect<ExtArgs> | null
    /**
     * Filter, which SystemClock to fetch.
     */
    where?: SystemClockWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of SystemClocks to fetch.
     */
    orderBy?: SystemClockOrderByWithRelationInput | SystemClockOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for SystemClocks.
     */
    cursor?: SystemClockWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` SystemClocks 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` SystemClocks.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of SystemClocks.
     */
    distinct?: SystemClockScalarFieldEnum | SystemClockScalarFieldEnum[]
  }

  /**
   * SystemClock findMany
   */
  export type SystemClockFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SystemClock
     */
    select?: SystemClockSelect<ExtArgs> | null
    /**
     * Filter, which SystemClocks to fetch.
     */
    where?: SystemClockWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of SystemClocks to fetch.
     */
    orderBy?: SystemClockOrderByWithRelationInput | SystemClockOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing SystemClocks.
     */
    cursor?: SystemClockWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` SystemClocks 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` SystemClocks.
     */
    skip?: number
    distinct?: SystemClockScalarFieldEnum | SystemClockScalarFieldEnum[]
  }

  /**
   * SystemClock create
   */
  export type SystemClockCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SystemClock
     */
    select?: SystemClockSelect<ExtArgs> | null
    /**
     * The data needed to create a SystemClock.
     */
    data: XOR<SystemClockCreateInput, SystemClockUncheckedCreateInput>
  }

  /**
   * SystemClock createMany
   */
  export type SystemClockCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many SystemClocks.
     */
    data: SystemClockCreateManyInput | SystemClockCreateManyInput[]
    skipDuplicates?: boolean
  }

  /**
   * SystemClock update
   */
  export type SystemClockUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SystemClock
     */
    select?: SystemClockSelect<ExtArgs> | null
    /**
     * The data needed to update a SystemClock.
     */
    data: XOR<SystemClockUpdateInput, SystemClockUncheckedUpdateInput>
    /**
     * Choose, which SystemClock to update.
     */
    where: SystemClockWhereUniqueInput
  }

  /**
   * SystemClock updateMany
   */
  export type SystemClockUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update SystemClocks.
     */
    data: XOR<SystemClockUpdateManyMutationInput, SystemClockUncheckedUpdateManyInput>
    /**
     * Filter which SystemClocks to update
     */
    where?: SystemClockWhereInput
  }

  /**
   * SystemClock upsert
   */
  export type SystemClockUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SystemClock
     */
    select?: SystemClockSelect<ExtArgs> | null
    /**
     * The filter to search for the SystemClock to update in case it exists.
     */
    where: SystemClockWhereUniqueInput
    /**
     * In case the SystemClock found by the `where` argument doesn't exist, create a new SystemClock with this data.
     */
    create: XOR<SystemClockCreateInput, SystemClockUncheckedCreateInput>
    /**
     * In case the SystemClock was found with the provided `where` argument, update it with this data.
     */
    update: XOR<SystemClockUpdateInput, SystemClockUncheckedUpdateInput>
  }

  /**
   * SystemClock delete
   */
  export type SystemClockDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SystemClock
     */
    select?: SystemClockSelect<ExtArgs> | null
    /**
     * Filter which SystemClock to delete.
     */
    where: SystemClockWhereUniqueInput
  }

  /**
   * SystemClock deleteMany
   */
  export type SystemClockDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which SystemClocks to delete
     */
    where?: SystemClockWhereInput
  }

  /**
   * SystemClock without action
   */
  export type SystemClockDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SystemClock
     */
    select?: SystemClockSelect<ExtArgs> | null
  }


  /**
   * Model CreditApplication
   */

  export type AggregateCreditApplication = {
    _count: CreditApplicationCountAggregateOutputType | null
    _avg: CreditApplicationAvgAggregateOutputType | null
    _sum: CreditApplicationSumAggregateOutputType | null
    _min: CreditApplicationMinAggregateOutputType | null
    _max: CreditApplicationMaxAggregateOutputType | null
  }

  export type CreditApplicationAvgAggregateOutputType = {
    valorSolicitado: number | null
    prazoMeses: number | null
    taxaJuroAplicada: number | null
    prestacaoMensal: number | null
    scoreNoMomento: number | null
  }

  export type CreditApplicationSumAggregateOutputType = {
    valorSolicitado: number | null
    prazoMeses: number | null
    taxaJuroAplicada: number | null
    prestacaoMensal: number | null
    scoreNoMomento: number | null
  }

  export type CreditApplicationMinAggregateOutputType = {
    id: string | null
    userId: string | null
    valorSolicitado: number | null
    prazoMeses: number | null
    taxaJuroAplicada: number | null
    prestacaoMensal: number | null
    finalidade: string | null
    status: string | null
    scoreNoMomento: number | null
    motivoDecisao: string | null
    decisaoPorId: string | null
    dataAprovacao: Date | null
    dataDesembolso: Date | null
    createdAt: Date | null
    updatedAt: Date | null
  }

  export type CreditApplicationMaxAggregateOutputType = {
    id: string | null
    userId: string | null
    valorSolicitado: number | null
    prazoMeses: number | null
    taxaJuroAplicada: number | null
    prestacaoMensal: number | null
    finalidade: string | null
    status: string | null
    scoreNoMomento: number | null
    motivoDecisao: string | null
    decisaoPorId: string | null
    dataAprovacao: Date | null
    dataDesembolso: Date | null
    createdAt: Date | null
    updatedAt: Date | null
  }

  export type CreditApplicationCountAggregateOutputType = {
    id: number
    userId: number
    valorSolicitado: number
    prazoMeses: number
    taxaJuroAplicada: number
    prestacaoMensal: number
    finalidade: number
    status: number
    scoreNoMomento: number
    motivoDecisao: number
    decisaoPorId: number
    dataAprovacao: number
    dataDesembolso: number
    createdAt: number
    updatedAt: number
    _all: number
  }


  export type CreditApplicationAvgAggregateInputType = {
    valorSolicitado?: true
    prazoMeses?: true
    taxaJuroAplicada?: true
    prestacaoMensal?: true
    scoreNoMomento?: true
  }

  export type CreditApplicationSumAggregateInputType = {
    valorSolicitado?: true
    prazoMeses?: true
    taxaJuroAplicada?: true
    prestacaoMensal?: true
    scoreNoMomento?: true
  }

  export type CreditApplicationMinAggregateInputType = {
    id?: true
    userId?: true
    valorSolicitado?: true
    prazoMeses?: true
    taxaJuroAplicada?: true
    prestacaoMensal?: true
    finalidade?: true
    status?: true
    scoreNoMomento?: true
    motivoDecisao?: true
    decisaoPorId?: true
    dataAprovacao?: true
    dataDesembolso?: true
    createdAt?: true
    updatedAt?: true
  }

  export type CreditApplicationMaxAggregateInputType = {
    id?: true
    userId?: true
    valorSolicitado?: true
    prazoMeses?: true
    taxaJuroAplicada?: true
    prestacaoMensal?: true
    finalidade?: true
    status?: true
    scoreNoMomento?: true
    motivoDecisao?: true
    decisaoPorId?: true
    dataAprovacao?: true
    dataDesembolso?: true
    createdAt?: true
    updatedAt?: true
  }

  export type CreditApplicationCountAggregateInputType = {
    id?: true
    userId?: true
    valorSolicitado?: true
    prazoMeses?: true
    taxaJuroAplicada?: true
    prestacaoMensal?: true
    finalidade?: true
    status?: true
    scoreNoMomento?: true
    motivoDecisao?: true
    decisaoPorId?: true
    dataAprovacao?: true
    dataDesembolso?: true
    createdAt?: true
    updatedAt?: true
    _all?: true
  }

  export type CreditApplicationAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which CreditApplication to aggregate.
     */
    where?: CreditApplicationWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of CreditApplications to fetch.
     */
    orderBy?: CreditApplicationOrderByWithRelationInput | CreditApplicationOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: CreditApplicationWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` CreditApplications 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` CreditApplications.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned CreditApplications
    **/
    _count?: true | CreditApplicationCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to average
    **/
    _avg?: CreditApplicationAvgAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to sum
    **/
    _sum?: CreditApplicationSumAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: CreditApplicationMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: CreditApplicationMaxAggregateInputType
  }

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




  export type CreditApplicationGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: CreditApplicationWhereInput
    orderBy?: CreditApplicationOrderByWithAggregationInput | CreditApplicationOrderByWithAggregationInput[]
    by: CreditApplicationScalarFieldEnum[] | CreditApplicationScalarFieldEnum
    having?: CreditApplicationScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: CreditApplicationCountAggregateInputType | true
    _avg?: CreditApplicationAvgAggregateInputType
    _sum?: CreditApplicationSumAggregateInputType
    _min?: CreditApplicationMinAggregateInputType
    _max?: CreditApplicationMaxAggregateInputType
  }

  export type CreditApplicationGroupByOutputType = {
    id: string
    userId: string
    valorSolicitado: number
    prazoMeses: number
    taxaJuroAplicada: number
    prestacaoMensal: number
    finalidade: string | null
    status: string
    scoreNoMomento: number
    motivoDecisao: string | null
    decisaoPorId: string | null
    dataAprovacao: Date | null
    dataDesembolso: Date | null
    createdAt: Date
    updatedAt: Date
    _count: CreditApplicationCountAggregateOutputType | null
    _avg: CreditApplicationAvgAggregateOutputType | null
    _sum: CreditApplicationSumAggregateOutputType | null
    _min: CreditApplicationMinAggregateOutputType | null
    _max: CreditApplicationMaxAggregateOutputType | null
  }

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


  export type CreditApplicationSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    userId?: boolean
    valorSolicitado?: boolean
    prazoMeses?: boolean
    taxaJuroAplicada?: boolean
    prestacaoMensal?: boolean
    finalidade?: boolean
    status?: boolean
    scoreNoMomento?: boolean
    motivoDecisao?: boolean
    decisaoPorId?: boolean
    dataAprovacao?: boolean
    dataDesembolso?: boolean
    createdAt?: boolean
    updatedAt?: boolean
    user?: boolean | UserDefaultArgs<ExtArgs>
    prestacoes?: boolean | CreditApplication$prestacoesArgs<ExtArgs>
    _count?: boolean | CreditApplicationCountOutputTypeDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["creditApplication"]>


  export type CreditApplicationSelectScalar = {
    id?: boolean
    userId?: boolean
    valorSolicitado?: boolean
    prazoMeses?: boolean
    taxaJuroAplicada?: boolean
    prestacaoMensal?: boolean
    finalidade?: boolean
    status?: boolean
    scoreNoMomento?: boolean
    motivoDecisao?: boolean
    decisaoPorId?: boolean
    dataAprovacao?: boolean
    dataDesembolso?: boolean
    createdAt?: boolean
    updatedAt?: boolean
  }

  export type CreditApplicationInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    user?: boolean | UserDefaultArgs<ExtArgs>
    prestacoes?: boolean | CreditApplication$prestacoesArgs<ExtArgs>
    _count?: boolean | CreditApplicationCountOutputTypeDefaultArgs<ExtArgs>
  }

  export type $CreditApplicationPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "CreditApplication"
    objects: {
      user: Prisma.$UserPayload<ExtArgs>
      prestacoes: Prisma.$CreditInstallmentPayload<ExtArgs>[]
    }
    scalars: $Extensions.GetPayloadResult<{
      id: string
      userId: string
      valorSolicitado: number
      prazoMeses: number
      taxaJuroAplicada: number
      prestacaoMensal: number
      finalidade: string | null
      status: string
      scoreNoMomento: number
      motivoDecisao: string | null
      decisaoPorId: string | null
      dataAprovacao: Date | null
      dataDesembolso: Date | null
      createdAt: Date
      updatedAt: Date
    }, ExtArgs["result"]["creditApplication"]>
    composites: {}
  }

  type CreditApplicationGetPayload<S extends boolean | null | undefined | CreditApplicationDefaultArgs> = $Result.GetResult<Prisma.$CreditApplicationPayload, S>

  type CreditApplicationCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = 
    Omit<CreditApplicationFindManyArgs, 'select' | 'include' | 'distinct'> & {
      select?: CreditApplicationCountAggregateInputType | true
    }

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

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

    /**
     * Find the first CreditApplication 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 {CreditApplicationFindFirstArgs} args - Arguments to find a CreditApplication
     * @example
     * // Get one CreditApplication
     * const creditApplication = await prisma.creditApplication.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends CreditApplicationFindFirstArgs>(args?: SelectSubset<T, CreditApplicationFindFirstArgs<ExtArgs>>): Prisma__CreditApplicationClient<$Result.GetResult<Prisma.$CreditApplicationPayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>

    /**
     * Find the first CreditApplication 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 {CreditApplicationFindFirstOrThrowArgs} args - Arguments to find a CreditApplication
     * @example
     * // Get one CreditApplication
     * const creditApplication = await prisma.creditApplication.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends CreditApplicationFindFirstOrThrowArgs>(args?: SelectSubset<T, CreditApplicationFindFirstOrThrowArgs<ExtArgs>>): Prisma__CreditApplicationClient<$Result.GetResult<Prisma.$CreditApplicationPayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>

    /**
     * Find zero or more CreditApplications 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 {CreditApplicationFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all CreditApplications
     * const creditApplications = await prisma.creditApplication.findMany()
     * 
     * // Get first 10 CreditApplications
     * const creditApplications = await prisma.creditApplication.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const creditApplicationWithIdOnly = await prisma.creditApplication.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends CreditApplicationFindManyArgs>(args?: SelectSubset<T, CreditApplicationFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$CreditApplicationPayload<ExtArgs>, T, "findMany">>

    /**
     * Create a CreditApplication.
     * @param {CreditApplicationCreateArgs} args - Arguments to create a CreditApplication.
     * @example
     * // Create one CreditApplication
     * const CreditApplication = await prisma.creditApplication.create({
     *   data: {
     *     // ... data to create a CreditApplication
     *   }
     * })
     * 
     */
    create<T extends CreditApplicationCreateArgs>(args: SelectSubset<T, CreditApplicationCreateArgs<ExtArgs>>): Prisma__CreditApplicationClient<$Result.GetResult<Prisma.$CreditApplicationPayload<ExtArgs>, T, "create">, never, ExtArgs>

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

    /**
     * Delete a CreditApplication.
     * @param {CreditApplicationDeleteArgs} args - Arguments to delete one CreditApplication.
     * @example
     * // Delete one CreditApplication
     * const CreditApplication = await prisma.creditApplication.delete({
     *   where: {
     *     // ... filter to delete one CreditApplication
     *   }
     * })
     * 
     */
    delete<T extends CreditApplicationDeleteArgs>(args: SelectSubset<T, CreditApplicationDeleteArgs<ExtArgs>>): Prisma__CreditApplicationClient<$Result.GetResult<Prisma.$CreditApplicationPayload<ExtArgs>, T, "delete">, never, ExtArgs>

    /**
     * Update one CreditApplication.
     * @param {CreditApplicationUpdateArgs} args - Arguments to update one CreditApplication.
     * @example
     * // Update one CreditApplication
     * const creditApplication = await prisma.creditApplication.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends CreditApplicationUpdateArgs>(args: SelectSubset<T, CreditApplicationUpdateArgs<ExtArgs>>): Prisma__CreditApplicationClient<$Result.GetResult<Prisma.$CreditApplicationPayload<ExtArgs>, T, "update">, never, ExtArgs>

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

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

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


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

    /**
     * Allows you to perform aggregations operations on a CreditApplication.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {CreditApplicationAggregateArgs} 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 CreditApplicationAggregateArgs>(args: Subset<T, CreditApplicationAggregateArgs>): Prisma.PrismaPromise<GetCreditApplicationAggregateType<T>>

    /**
     * Group by CreditApplication.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {CreditApplicationGroupByArgs} 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 CreditApplicationGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: CreditApplicationGroupByArgs['orderBy'] }
        : { orderBy?: CreditApplicationGroupByArgs['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, CreditApplicationGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetCreditApplicationGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the CreditApplication model
   */
  readonly fields: CreditApplicationFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for CreditApplication.
   * 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__CreditApplicationClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> 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"> | Null, Null, ExtArgs>
    prestacoes<T extends CreditApplication$prestacoesArgs<ExtArgs> = {}>(args?: Subset<T, CreditApplication$prestacoesArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$CreditInstallmentPayload<ExtArgs>, T, "findMany"> | 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 CreditApplication model
   */ 
  interface CreditApplicationFieldRefs {
    readonly id: FieldRef<"CreditApplication", 'String'>
    readonly userId: FieldRef<"CreditApplication", 'String'>
    readonly valorSolicitado: FieldRef<"CreditApplication", 'Float'>
    readonly prazoMeses: FieldRef<"CreditApplication", 'Int'>
    readonly taxaJuroAplicada: FieldRef<"CreditApplication", 'Float'>
    readonly prestacaoMensal: FieldRef<"CreditApplication", 'Float'>
    readonly finalidade: FieldRef<"CreditApplication", 'String'>
    readonly status: FieldRef<"CreditApplication", 'String'>
    readonly scoreNoMomento: FieldRef<"CreditApplication", 'Int'>
    readonly motivoDecisao: FieldRef<"CreditApplication", 'String'>
    readonly decisaoPorId: FieldRef<"CreditApplication", 'String'>
    readonly dataAprovacao: FieldRef<"CreditApplication", 'DateTime'>
    readonly dataDesembolso: FieldRef<"CreditApplication", 'DateTime'>
    readonly createdAt: FieldRef<"CreditApplication", 'DateTime'>
    readonly updatedAt: FieldRef<"CreditApplication", 'DateTime'>
  }
    

  // Custom InputTypes
  /**
   * CreditApplication findUnique
   */
  export type CreditApplicationFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CreditApplication
     */
    select?: CreditApplicationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CreditApplicationInclude<ExtArgs> | null
    /**
     * Filter, which CreditApplication to fetch.
     */
    where: CreditApplicationWhereUniqueInput
  }

  /**
   * CreditApplication findUniqueOrThrow
   */
  export type CreditApplicationFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CreditApplication
     */
    select?: CreditApplicationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CreditApplicationInclude<ExtArgs> | null
    /**
     * Filter, which CreditApplication to fetch.
     */
    where: CreditApplicationWhereUniqueInput
  }

  /**
   * CreditApplication findFirst
   */
  export type CreditApplicationFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CreditApplication
     */
    select?: CreditApplicationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CreditApplicationInclude<ExtArgs> | null
    /**
     * Filter, which CreditApplication to fetch.
     */
    where?: CreditApplicationWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of CreditApplications to fetch.
     */
    orderBy?: CreditApplicationOrderByWithRelationInput | CreditApplicationOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for CreditApplications.
     */
    cursor?: CreditApplicationWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` CreditApplications 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` CreditApplications.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of CreditApplications.
     */
    distinct?: CreditApplicationScalarFieldEnum | CreditApplicationScalarFieldEnum[]
  }

  /**
   * CreditApplication findFirstOrThrow
   */
  export type CreditApplicationFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CreditApplication
     */
    select?: CreditApplicationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CreditApplicationInclude<ExtArgs> | null
    /**
     * Filter, which CreditApplication to fetch.
     */
    where?: CreditApplicationWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of CreditApplications to fetch.
     */
    orderBy?: CreditApplicationOrderByWithRelationInput | CreditApplicationOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for CreditApplications.
     */
    cursor?: CreditApplicationWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` CreditApplications 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` CreditApplications.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of CreditApplications.
     */
    distinct?: CreditApplicationScalarFieldEnum | CreditApplicationScalarFieldEnum[]
  }

  /**
   * CreditApplication findMany
   */
  export type CreditApplicationFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CreditApplication
     */
    select?: CreditApplicationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CreditApplicationInclude<ExtArgs> | null
    /**
     * Filter, which CreditApplications to fetch.
     */
    where?: CreditApplicationWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of CreditApplications to fetch.
     */
    orderBy?: CreditApplicationOrderByWithRelationInput | CreditApplicationOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing CreditApplications.
     */
    cursor?: CreditApplicationWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` CreditApplications 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` CreditApplications.
     */
    skip?: number
    distinct?: CreditApplicationScalarFieldEnum | CreditApplicationScalarFieldEnum[]
  }

  /**
   * CreditApplication create
   */
  export type CreditApplicationCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CreditApplication
     */
    select?: CreditApplicationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CreditApplicationInclude<ExtArgs> | null
    /**
     * The data needed to create a CreditApplication.
     */
    data: XOR<CreditApplicationCreateInput, CreditApplicationUncheckedCreateInput>
  }

  /**
   * CreditApplication createMany
   */
  export type CreditApplicationCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many CreditApplications.
     */
    data: CreditApplicationCreateManyInput | CreditApplicationCreateManyInput[]
    skipDuplicates?: boolean
  }

  /**
   * CreditApplication update
   */
  export type CreditApplicationUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CreditApplication
     */
    select?: CreditApplicationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CreditApplicationInclude<ExtArgs> | null
    /**
     * The data needed to update a CreditApplication.
     */
    data: XOR<CreditApplicationUpdateInput, CreditApplicationUncheckedUpdateInput>
    /**
     * Choose, which CreditApplication to update.
     */
    where: CreditApplicationWhereUniqueInput
  }

  /**
   * CreditApplication updateMany
   */
  export type CreditApplicationUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update CreditApplications.
     */
    data: XOR<CreditApplicationUpdateManyMutationInput, CreditApplicationUncheckedUpdateManyInput>
    /**
     * Filter which CreditApplications to update
     */
    where?: CreditApplicationWhereInput
  }

  /**
   * CreditApplication upsert
   */
  export type CreditApplicationUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CreditApplication
     */
    select?: CreditApplicationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CreditApplicationInclude<ExtArgs> | null
    /**
     * The filter to search for the CreditApplication to update in case it exists.
     */
    where: CreditApplicationWhereUniqueInput
    /**
     * In case the CreditApplication found by the `where` argument doesn't exist, create a new CreditApplication with this data.
     */
    create: XOR<CreditApplicationCreateInput, CreditApplicationUncheckedCreateInput>
    /**
     * In case the CreditApplication was found with the provided `where` argument, update it with this data.
     */
    update: XOR<CreditApplicationUpdateInput, CreditApplicationUncheckedUpdateInput>
  }

  /**
   * CreditApplication delete
   */
  export type CreditApplicationDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CreditApplication
     */
    select?: CreditApplicationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CreditApplicationInclude<ExtArgs> | null
    /**
     * Filter which CreditApplication to delete.
     */
    where: CreditApplicationWhereUniqueInput
  }

  /**
   * CreditApplication deleteMany
   */
  export type CreditApplicationDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which CreditApplications to delete
     */
    where?: CreditApplicationWhereInput
  }

  /**
   * CreditApplication.prestacoes
   */
  export type CreditApplication$prestacoesArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CreditInstallment
     */
    select?: CreditInstallmentSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CreditInstallmentInclude<ExtArgs> | null
    where?: CreditInstallmentWhereInput
    orderBy?: CreditInstallmentOrderByWithRelationInput | CreditInstallmentOrderByWithRelationInput[]
    cursor?: CreditInstallmentWhereUniqueInput
    take?: number
    skip?: number
    distinct?: CreditInstallmentScalarFieldEnum | CreditInstallmentScalarFieldEnum[]
  }

  /**
   * CreditApplication without action
   */
  export type CreditApplicationDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CreditApplication
     */
    select?: CreditApplicationSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CreditApplicationInclude<ExtArgs> | null
  }


  /**
   * Model CreditInstallment
   */

  export type AggregateCreditInstallment = {
    _count: CreditInstallmentCountAggregateOutputType | null
    _avg: CreditInstallmentAvgAggregateOutputType | null
    _sum: CreditInstallmentSumAggregateOutputType | null
    _min: CreditInstallmentMinAggregateOutputType | null
    _max: CreditInstallmentMaxAggregateOutputType | null
  }

  export type CreditInstallmentAvgAggregateOutputType = {
    numero: number | null
    valorCapital: number | null
    valorJuros: number | null
    valorTotal: number | null
  }

  export type CreditInstallmentSumAggregateOutputType = {
    numero: number | null
    valorCapital: number | null
    valorJuros: number | null
    valorTotal: number | null
  }

  export type CreditInstallmentMinAggregateOutputType = {
    id: string | null
    applicationId: string | null
    numero: number | null
    valorCapital: number | null
    valorJuros: number | null
    valorTotal: number | null
    dataVencimento: Date | null
    dataPagamento: Date | null
    status: string | null
  }

  export type CreditInstallmentMaxAggregateOutputType = {
    id: string | null
    applicationId: string | null
    numero: number | null
    valorCapital: number | null
    valorJuros: number | null
    valorTotal: number | null
    dataVencimento: Date | null
    dataPagamento: Date | null
    status: string | null
  }

  export type CreditInstallmentCountAggregateOutputType = {
    id: number
    applicationId: number
    numero: number
    valorCapital: number
    valorJuros: number
    valorTotal: number
    dataVencimento: number
    dataPagamento: number
    status: number
    _all: number
  }


  export type CreditInstallmentAvgAggregateInputType = {
    numero?: true
    valorCapital?: true
    valorJuros?: true
    valorTotal?: true
  }

  export type CreditInstallmentSumAggregateInputType = {
    numero?: true
    valorCapital?: true
    valorJuros?: true
    valorTotal?: true
  }

  export type CreditInstallmentMinAggregateInputType = {
    id?: true
    applicationId?: true
    numero?: true
    valorCapital?: true
    valorJuros?: true
    valorTotal?: true
    dataVencimento?: true
    dataPagamento?: true
    status?: true
  }

  export type CreditInstallmentMaxAggregateInputType = {
    id?: true
    applicationId?: true
    numero?: true
    valorCapital?: true
    valorJuros?: true
    valorTotal?: true
    dataVencimento?: true
    dataPagamento?: true
    status?: true
  }

  export type CreditInstallmentCountAggregateInputType = {
    id?: true
    applicationId?: true
    numero?: true
    valorCapital?: true
    valorJuros?: true
    valorTotal?: true
    dataVencimento?: true
    dataPagamento?: true
    status?: true
    _all?: true
  }

  export type CreditInstallmentAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which CreditInstallment to aggregate.
     */
    where?: CreditInstallmentWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of CreditInstallments to fetch.
     */
    orderBy?: CreditInstallmentOrderByWithRelationInput | CreditInstallmentOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: CreditInstallmentWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` CreditInstallments 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` CreditInstallments.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned CreditInstallments
    **/
    _count?: true | CreditInstallmentCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to average
    **/
    _avg?: CreditInstallmentAvgAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to sum
    **/
    _sum?: CreditInstallmentSumAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: CreditInstallmentMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: CreditInstallmentMaxAggregateInputType
  }

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




  export type CreditInstallmentGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: CreditInstallmentWhereInput
    orderBy?: CreditInstallmentOrderByWithAggregationInput | CreditInstallmentOrderByWithAggregationInput[]
    by: CreditInstallmentScalarFieldEnum[] | CreditInstallmentScalarFieldEnum
    having?: CreditInstallmentScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: CreditInstallmentCountAggregateInputType | true
    _avg?: CreditInstallmentAvgAggregateInputType
    _sum?: CreditInstallmentSumAggregateInputType
    _min?: CreditInstallmentMinAggregateInputType
    _max?: CreditInstallmentMaxAggregateInputType
  }

  export type CreditInstallmentGroupByOutputType = {
    id: string
    applicationId: string
    numero: number
    valorCapital: number
    valorJuros: number
    valorTotal: number
    dataVencimento: Date
    dataPagamento: Date | null
    status: string
    _count: CreditInstallmentCountAggregateOutputType | null
    _avg: CreditInstallmentAvgAggregateOutputType | null
    _sum: CreditInstallmentSumAggregateOutputType | null
    _min: CreditInstallmentMinAggregateOutputType | null
    _max: CreditInstallmentMaxAggregateOutputType | null
  }

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


  export type CreditInstallmentSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    applicationId?: boolean
    numero?: boolean
    valorCapital?: boolean
    valorJuros?: boolean
    valorTotal?: boolean
    dataVencimento?: boolean
    dataPagamento?: boolean
    status?: boolean
    application?: boolean | CreditApplicationDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["creditInstallment"]>


  export type CreditInstallmentSelectScalar = {
    id?: boolean
    applicationId?: boolean
    numero?: boolean
    valorCapital?: boolean
    valorJuros?: boolean
    valorTotal?: boolean
    dataVencimento?: boolean
    dataPagamento?: boolean
    status?: boolean
  }

  export type CreditInstallmentInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    application?: boolean | CreditApplicationDefaultArgs<ExtArgs>
  }

  export type $CreditInstallmentPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "CreditInstallment"
    objects: {
      application: Prisma.$CreditApplicationPayload<ExtArgs>
    }
    scalars: $Extensions.GetPayloadResult<{
      id: string
      applicationId: string
      numero: number
      valorCapital: number
      valorJuros: number
      valorTotal: number
      dataVencimento: Date
      dataPagamento: Date | null
      status: string
    }, ExtArgs["result"]["creditInstallment"]>
    composites: {}
  }

  type CreditInstallmentGetPayload<S extends boolean | null | undefined | CreditInstallmentDefaultArgs> = $Result.GetResult<Prisma.$CreditInstallmentPayload, S>

  type CreditInstallmentCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = 
    Omit<CreditInstallmentFindManyArgs, 'select' | 'include' | 'distinct'> & {
      select?: CreditInstallmentCountAggregateInputType | true
    }

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

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

    /**
     * Find the first CreditInstallment 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 {CreditInstallmentFindFirstArgs} args - Arguments to find a CreditInstallment
     * @example
     * // Get one CreditInstallment
     * const creditInstallment = await prisma.creditInstallment.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends CreditInstallmentFindFirstArgs>(args?: SelectSubset<T, CreditInstallmentFindFirstArgs<ExtArgs>>): Prisma__CreditInstallmentClient<$Result.GetResult<Prisma.$CreditInstallmentPayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>

    /**
     * Find the first CreditInstallment 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 {CreditInstallmentFindFirstOrThrowArgs} args - Arguments to find a CreditInstallment
     * @example
     * // Get one CreditInstallment
     * const creditInstallment = await prisma.creditInstallment.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends CreditInstallmentFindFirstOrThrowArgs>(args?: SelectSubset<T, CreditInstallmentFindFirstOrThrowArgs<ExtArgs>>): Prisma__CreditInstallmentClient<$Result.GetResult<Prisma.$CreditInstallmentPayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>

    /**
     * Find zero or more CreditInstallments 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 {CreditInstallmentFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all CreditInstallments
     * const creditInstallments = await prisma.creditInstallment.findMany()
     * 
     * // Get first 10 CreditInstallments
     * const creditInstallments = await prisma.creditInstallment.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const creditInstallmentWithIdOnly = await prisma.creditInstallment.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends CreditInstallmentFindManyArgs>(args?: SelectSubset<T, CreditInstallmentFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$CreditInstallmentPayload<ExtArgs>, T, "findMany">>

    /**
     * Create a CreditInstallment.
     * @param {CreditInstallmentCreateArgs} args - Arguments to create a CreditInstallment.
     * @example
     * // Create one CreditInstallment
     * const CreditInstallment = await prisma.creditInstallment.create({
     *   data: {
     *     // ... data to create a CreditInstallment
     *   }
     * })
     * 
     */
    create<T extends CreditInstallmentCreateArgs>(args: SelectSubset<T, CreditInstallmentCreateArgs<ExtArgs>>): Prisma__CreditInstallmentClient<$Result.GetResult<Prisma.$CreditInstallmentPayload<ExtArgs>, T, "create">, never, ExtArgs>

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

    /**
     * Delete a CreditInstallment.
     * @param {CreditInstallmentDeleteArgs} args - Arguments to delete one CreditInstallment.
     * @example
     * // Delete one CreditInstallment
     * const CreditInstallment = await prisma.creditInstallment.delete({
     *   where: {
     *     // ... filter to delete one CreditInstallment
     *   }
     * })
     * 
     */
    delete<T extends CreditInstallmentDeleteArgs>(args: SelectSubset<T, CreditInstallmentDeleteArgs<ExtArgs>>): Prisma__CreditInstallmentClient<$Result.GetResult<Prisma.$CreditInstallmentPayload<ExtArgs>, T, "delete">, never, ExtArgs>

    /**
     * Update one CreditInstallment.
     * @param {CreditInstallmentUpdateArgs} args - Arguments to update one CreditInstallment.
     * @example
     * // Update one CreditInstallment
     * const creditInstallment = await prisma.creditInstallment.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends CreditInstallmentUpdateArgs>(args: SelectSubset<T, CreditInstallmentUpdateArgs<ExtArgs>>): Prisma__CreditInstallmentClient<$Result.GetResult<Prisma.$CreditInstallmentPayload<ExtArgs>, T, "update">, never, ExtArgs>

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

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

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


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

    /**
     * Allows you to perform aggregations operations on a CreditInstallment.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {CreditInstallmentAggregateArgs} 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 CreditInstallmentAggregateArgs>(args: Subset<T, CreditInstallmentAggregateArgs>): Prisma.PrismaPromise<GetCreditInstallmentAggregateType<T>>

    /**
     * Group by CreditInstallment.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {CreditInstallmentGroupByArgs} 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 CreditInstallmentGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: CreditInstallmentGroupByArgs['orderBy'] }
        : { orderBy?: CreditInstallmentGroupByArgs['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, CreditInstallmentGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetCreditInstallmentGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the CreditInstallment model
   */
  readonly fields: CreditInstallmentFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for CreditInstallment.
   * 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__CreditInstallmentClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
    readonly [Symbol.toStringTag]: "PrismaPromise"
    application<T extends CreditApplicationDefaultArgs<ExtArgs> = {}>(args?: Subset<T, CreditApplicationDefaultArgs<ExtArgs>>): Prisma__CreditApplicationClient<$Result.GetResult<Prisma.$CreditApplicationPayload<ExtArgs>, T, "findUniqueOrThrow"> | Null, Null, ExtArgs>
    /**
     * 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 CreditInstallment model
   */ 
  interface CreditInstallmentFieldRefs {
    readonly id: FieldRef<"CreditInstallment", 'String'>
    readonly applicationId: FieldRef<"CreditInstallment", 'String'>
    readonly numero: FieldRef<"CreditInstallment", 'Int'>
    readonly valorCapital: FieldRef<"CreditInstallment", 'Float'>
    readonly valorJuros: FieldRef<"CreditInstallment", 'Float'>
    readonly valorTotal: FieldRef<"CreditInstallment", 'Float'>
    readonly dataVencimento: FieldRef<"CreditInstallment", 'DateTime'>
    readonly dataPagamento: FieldRef<"CreditInstallment", 'DateTime'>
    readonly status: FieldRef<"CreditInstallment", 'String'>
  }
    

  // Custom InputTypes
  /**
   * CreditInstallment findUnique
   */
  export type CreditInstallmentFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CreditInstallment
     */
    select?: CreditInstallmentSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CreditInstallmentInclude<ExtArgs> | null
    /**
     * Filter, which CreditInstallment to fetch.
     */
    where: CreditInstallmentWhereUniqueInput
  }

  /**
   * CreditInstallment findUniqueOrThrow
   */
  export type CreditInstallmentFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CreditInstallment
     */
    select?: CreditInstallmentSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CreditInstallmentInclude<ExtArgs> | null
    /**
     * Filter, which CreditInstallment to fetch.
     */
    where: CreditInstallmentWhereUniqueInput
  }

  /**
   * CreditInstallment findFirst
   */
  export type CreditInstallmentFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CreditInstallment
     */
    select?: CreditInstallmentSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CreditInstallmentInclude<ExtArgs> | null
    /**
     * Filter, which CreditInstallment to fetch.
     */
    where?: CreditInstallmentWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of CreditInstallments to fetch.
     */
    orderBy?: CreditInstallmentOrderByWithRelationInput | CreditInstallmentOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for CreditInstallments.
     */
    cursor?: CreditInstallmentWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` CreditInstallments 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` CreditInstallments.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of CreditInstallments.
     */
    distinct?: CreditInstallmentScalarFieldEnum | CreditInstallmentScalarFieldEnum[]
  }

  /**
   * CreditInstallment findFirstOrThrow
   */
  export type CreditInstallmentFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CreditInstallment
     */
    select?: CreditInstallmentSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CreditInstallmentInclude<ExtArgs> | null
    /**
     * Filter, which CreditInstallment to fetch.
     */
    where?: CreditInstallmentWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of CreditInstallments to fetch.
     */
    orderBy?: CreditInstallmentOrderByWithRelationInput | CreditInstallmentOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for CreditInstallments.
     */
    cursor?: CreditInstallmentWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` CreditInstallments 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` CreditInstallments.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of CreditInstallments.
     */
    distinct?: CreditInstallmentScalarFieldEnum | CreditInstallmentScalarFieldEnum[]
  }

  /**
   * CreditInstallment findMany
   */
  export type CreditInstallmentFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CreditInstallment
     */
    select?: CreditInstallmentSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CreditInstallmentInclude<ExtArgs> | null
    /**
     * Filter, which CreditInstallments to fetch.
     */
    where?: CreditInstallmentWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of CreditInstallments to fetch.
     */
    orderBy?: CreditInstallmentOrderByWithRelationInput | CreditInstallmentOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing CreditInstallments.
     */
    cursor?: CreditInstallmentWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` CreditInstallments 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` CreditInstallments.
     */
    skip?: number
    distinct?: CreditInstallmentScalarFieldEnum | CreditInstallmentScalarFieldEnum[]
  }

  /**
   * CreditInstallment create
   */
  export type CreditInstallmentCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CreditInstallment
     */
    select?: CreditInstallmentSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CreditInstallmentInclude<ExtArgs> | null
    /**
     * The data needed to create a CreditInstallment.
     */
    data: XOR<CreditInstallmentCreateInput, CreditInstallmentUncheckedCreateInput>
  }

  /**
   * CreditInstallment createMany
   */
  export type CreditInstallmentCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many CreditInstallments.
     */
    data: CreditInstallmentCreateManyInput | CreditInstallmentCreateManyInput[]
    skipDuplicates?: boolean
  }

  /**
   * CreditInstallment update
   */
  export type CreditInstallmentUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CreditInstallment
     */
    select?: CreditInstallmentSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CreditInstallmentInclude<ExtArgs> | null
    /**
     * The data needed to update a CreditInstallment.
     */
    data: XOR<CreditInstallmentUpdateInput, CreditInstallmentUncheckedUpdateInput>
    /**
     * Choose, which CreditInstallment to update.
     */
    where: CreditInstallmentWhereUniqueInput
  }

  /**
   * CreditInstallment updateMany
   */
  export type CreditInstallmentUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update CreditInstallments.
     */
    data: XOR<CreditInstallmentUpdateManyMutationInput, CreditInstallmentUncheckedUpdateManyInput>
    /**
     * Filter which CreditInstallments to update
     */
    where?: CreditInstallmentWhereInput
  }

  /**
   * CreditInstallment upsert
   */
  export type CreditInstallmentUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CreditInstallment
     */
    select?: CreditInstallmentSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CreditInstallmentInclude<ExtArgs> | null
    /**
     * The filter to search for the CreditInstallment to update in case it exists.
     */
    where: CreditInstallmentWhereUniqueInput
    /**
     * In case the CreditInstallment found by the `where` argument doesn't exist, create a new CreditInstallment with this data.
     */
    create: XOR<CreditInstallmentCreateInput, CreditInstallmentUncheckedCreateInput>
    /**
     * In case the CreditInstallment was found with the provided `where` argument, update it with this data.
     */
    update: XOR<CreditInstallmentUpdateInput, CreditInstallmentUncheckedUpdateInput>
  }

  /**
   * CreditInstallment delete
   */
  export type CreditInstallmentDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CreditInstallment
     */
    select?: CreditInstallmentSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CreditInstallmentInclude<ExtArgs> | null
    /**
     * Filter which CreditInstallment to delete.
     */
    where: CreditInstallmentWhereUniqueInput
  }

  /**
   * CreditInstallment deleteMany
   */
  export type CreditInstallmentDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which CreditInstallments to delete
     */
    where?: CreditInstallmentWhereInput
  }

  /**
   * CreditInstallment without action
   */
  export type CreditInstallmentDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the CreditInstallment
     */
    select?: CreditInstallmentSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: CreditInstallmentInclude<ExtArgs> | null
  }


  /**
   * Model SavingsAccount
   */

  export type AggregateSavingsAccount = {
    _count: SavingsAccountCountAggregateOutputType | null
    _avg: SavingsAccountAvgAggregateOutputType | null
    _sum: SavingsAccountSumAggregateOutputType | null
    _min: SavingsAccountMinAggregateOutputType | null
    _max: SavingsAccountMaxAggregateOutputType | null
  }

  export type SavingsAccountAvgAggregateOutputType = {
    meta: number | null
    saldo: number | null
    taxaRemuneracaoAnual: number | null
    imobilizacaoMeses: number | null
  }

  export type SavingsAccountSumAggregateOutputType = {
    meta: number | null
    saldo: number | null
    taxaRemuneracaoAnual: number | null
    imobilizacaoMeses: number | null
  }

  export type SavingsAccountMinAggregateOutputType = {
    id: string | null
    userId: string | null
    nome: string | null
    objectivo: string | null
    meta: number | null
    saldo: number | null
    taxaRemuneracaoAnual: number | null
    imobilizacaoMeses: number | null
    status: string | null
    ultimaCapitalizacao: Date | null
    createdAt: Date | null
    updatedAt: Date | null
  }

  export type SavingsAccountMaxAggregateOutputType = {
    id: string | null
    userId: string | null
    nome: string | null
    objectivo: string | null
    meta: number | null
    saldo: number | null
    taxaRemuneracaoAnual: number | null
    imobilizacaoMeses: number | null
    status: string | null
    ultimaCapitalizacao: Date | null
    createdAt: Date | null
    updatedAt: Date | null
  }

  export type SavingsAccountCountAggregateOutputType = {
    id: number
    userId: number
    nome: number
    objectivo: number
    meta: number
    saldo: number
    taxaRemuneracaoAnual: number
    imobilizacaoMeses: number
    status: number
    ultimaCapitalizacao: number
    createdAt: number
    updatedAt: number
    _all: number
  }


  export type SavingsAccountAvgAggregateInputType = {
    meta?: true
    saldo?: true
    taxaRemuneracaoAnual?: true
    imobilizacaoMeses?: true
  }

  export type SavingsAccountSumAggregateInputType = {
    meta?: true
    saldo?: true
    taxaRemuneracaoAnual?: true
    imobilizacaoMeses?: true
  }

  export type SavingsAccountMinAggregateInputType = {
    id?: true
    userId?: true
    nome?: true
    objectivo?: true
    meta?: true
    saldo?: true
    taxaRemuneracaoAnual?: true
    imobilizacaoMeses?: true
    status?: true
    ultimaCapitalizacao?: true
    createdAt?: true
    updatedAt?: true
  }

  export type SavingsAccountMaxAggregateInputType = {
    id?: true
    userId?: true
    nome?: true
    objectivo?: true
    meta?: true
    saldo?: true
    taxaRemuneracaoAnual?: true
    imobilizacaoMeses?: true
    status?: true
    ultimaCapitalizacao?: true
    createdAt?: true
    updatedAt?: true
  }

  export type SavingsAccountCountAggregateInputType = {
    id?: true
    userId?: true
    nome?: true
    objectivo?: true
    meta?: true
    saldo?: true
    taxaRemuneracaoAnual?: true
    imobilizacaoMeses?: true
    status?: true
    ultimaCapitalizacao?: true
    createdAt?: true
    updatedAt?: true
    _all?: true
  }

  export type SavingsAccountAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which SavingsAccount to aggregate.
     */
    where?: SavingsAccountWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of SavingsAccounts to fetch.
     */
    orderBy?: SavingsAccountOrderByWithRelationInput | SavingsAccountOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: SavingsAccountWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` SavingsAccounts 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` SavingsAccounts.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned SavingsAccounts
    **/
    _count?: true | SavingsAccountCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to average
    **/
    _avg?: SavingsAccountAvgAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to sum
    **/
    _sum?: SavingsAccountSumAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: SavingsAccountMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: SavingsAccountMaxAggregateInputType
  }

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




  export type SavingsAccountGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: SavingsAccountWhereInput
    orderBy?: SavingsAccountOrderByWithAggregationInput | SavingsAccountOrderByWithAggregationInput[]
    by: SavingsAccountScalarFieldEnum[] | SavingsAccountScalarFieldEnum
    having?: SavingsAccountScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: SavingsAccountCountAggregateInputType | true
    _avg?: SavingsAccountAvgAggregateInputType
    _sum?: SavingsAccountSumAggregateInputType
    _min?: SavingsAccountMinAggregateInputType
    _max?: SavingsAccountMaxAggregateInputType
  }

  export type SavingsAccountGroupByOutputType = {
    id: string
    userId: string
    nome: string
    objectivo: string | null
    meta: number | null
    saldo: number
    taxaRemuneracaoAnual: number
    imobilizacaoMeses: number
    status: string
    ultimaCapitalizacao: Date
    createdAt: Date
    updatedAt: Date
    _count: SavingsAccountCountAggregateOutputType | null
    _avg: SavingsAccountAvgAggregateOutputType | null
    _sum: SavingsAccountSumAggregateOutputType | null
    _min: SavingsAccountMinAggregateOutputType | null
    _max: SavingsAccountMaxAggregateOutputType | null
  }

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


  export type SavingsAccountSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    userId?: boolean
    nome?: boolean
    objectivo?: boolean
    meta?: boolean
    saldo?: boolean
    taxaRemuneracaoAnual?: boolean
    imobilizacaoMeses?: boolean
    status?: boolean
    ultimaCapitalizacao?: boolean
    createdAt?: boolean
    updatedAt?: boolean
    user?: boolean | UserDefaultArgs<ExtArgs>
    movimentos?: boolean | SavingsAccount$movimentosArgs<ExtArgs>
    _count?: boolean | SavingsAccountCountOutputTypeDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["savingsAccount"]>


  export type SavingsAccountSelectScalar = {
    id?: boolean
    userId?: boolean
    nome?: boolean
    objectivo?: boolean
    meta?: boolean
    saldo?: boolean
    taxaRemuneracaoAnual?: boolean
    imobilizacaoMeses?: boolean
    status?: boolean
    ultimaCapitalizacao?: boolean
    createdAt?: boolean
    updatedAt?: boolean
  }

  export type SavingsAccountInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    user?: boolean | UserDefaultArgs<ExtArgs>
    movimentos?: boolean | SavingsAccount$movimentosArgs<ExtArgs>
    _count?: boolean | SavingsAccountCountOutputTypeDefaultArgs<ExtArgs>
  }

  export type $SavingsAccountPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "SavingsAccount"
    objects: {
      user: Prisma.$UserPayload<ExtArgs>
      movimentos: Prisma.$SavingsMovementPayload<ExtArgs>[]
    }
    scalars: $Extensions.GetPayloadResult<{
      id: string
      userId: string
      nome: string
      objectivo: string | null
      meta: number | null
      saldo: number
      taxaRemuneracaoAnual: number
      imobilizacaoMeses: number
      status: string
      ultimaCapitalizacao: Date
      createdAt: Date
      updatedAt: Date
    }, ExtArgs["result"]["savingsAccount"]>
    composites: {}
  }

  type SavingsAccountGetPayload<S extends boolean | null | undefined | SavingsAccountDefaultArgs> = $Result.GetResult<Prisma.$SavingsAccountPayload, S>

  type SavingsAccountCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = 
    Omit<SavingsAccountFindManyArgs, 'select' | 'include' | 'distinct'> & {
      select?: SavingsAccountCountAggregateInputType | true
    }

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

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

    /**
     * Find the first SavingsAccount 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 {SavingsAccountFindFirstArgs} args - Arguments to find a SavingsAccount
     * @example
     * // Get one SavingsAccount
     * const savingsAccount = await prisma.savingsAccount.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends SavingsAccountFindFirstArgs>(args?: SelectSubset<T, SavingsAccountFindFirstArgs<ExtArgs>>): Prisma__SavingsAccountClient<$Result.GetResult<Prisma.$SavingsAccountPayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>

    /**
     * Find the first SavingsAccount 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 {SavingsAccountFindFirstOrThrowArgs} args - Arguments to find a SavingsAccount
     * @example
     * // Get one SavingsAccount
     * const savingsAccount = await prisma.savingsAccount.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends SavingsAccountFindFirstOrThrowArgs>(args?: SelectSubset<T, SavingsAccountFindFirstOrThrowArgs<ExtArgs>>): Prisma__SavingsAccountClient<$Result.GetResult<Prisma.$SavingsAccountPayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>

    /**
     * Find zero or more SavingsAccounts 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 {SavingsAccountFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all SavingsAccounts
     * const savingsAccounts = await prisma.savingsAccount.findMany()
     * 
     * // Get first 10 SavingsAccounts
     * const savingsAccounts = await prisma.savingsAccount.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const savingsAccountWithIdOnly = await prisma.savingsAccount.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends SavingsAccountFindManyArgs>(args?: SelectSubset<T, SavingsAccountFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$SavingsAccountPayload<ExtArgs>, T, "findMany">>

    /**
     * Create a SavingsAccount.
     * @param {SavingsAccountCreateArgs} args - Arguments to create a SavingsAccount.
     * @example
     * // Create one SavingsAccount
     * const SavingsAccount = await prisma.savingsAccount.create({
     *   data: {
     *     // ... data to create a SavingsAccount
     *   }
     * })
     * 
     */
    create<T extends SavingsAccountCreateArgs>(args: SelectSubset<T, SavingsAccountCreateArgs<ExtArgs>>): Prisma__SavingsAccountClient<$Result.GetResult<Prisma.$SavingsAccountPayload<ExtArgs>, T, "create">, never, ExtArgs>

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

    /**
     * Delete a SavingsAccount.
     * @param {SavingsAccountDeleteArgs} args - Arguments to delete one SavingsAccount.
     * @example
     * // Delete one SavingsAccount
     * const SavingsAccount = await prisma.savingsAccount.delete({
     *   where: {
     *     // ... filter to delete one SavingsAccount
     *   }
     * })
     * 
     */
    delete<T extends SavingsAccountDeleteArgs>(args: SelectSubset<T, SavingsAccountDeleteArgs<ExtArgs>>): Prisma__SavingsAccountClient<$Result.GetResult<Prisma.$SavingsAccountPayload<ExtArgs>, T, "delete">, never, ExtArgs>

    /**
     * Update one SavingsAccount.
     * @param {SavingsAccountUpdateArgs} args - Arguments to update one SavingsAccount.
     * @example
     * // Update one SavingsAccount
     * const savingsAccount = await prisma.savingsAccount.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends SavingsAccountUpdateArgs>(args: SelectSubset<T, SavingsAccountUpdateArgs<ExtArgs>>): Prisma__SavingsAccountClient<$Result.GetResult<Prisma.$SavingsAccountPayload<ExtArgs>, T, "update">, never, ExtArgs>

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

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

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


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

    /**
     * Allows you to perform aggregations operations on a SavingsAccount.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {SavingsAccountAggregateArgs} 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 SavingsAccountAggregateArgs>(args: Subset<T, SavingsAccountAggregateArgs>): Prisma.PrismaPromise<GetSavingsAccountAggregateType<T>>

    /**
     * Group by SavingsAccount.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {SavingsAccountGroupByArgs} 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 SavingsAccountGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: SavingsAccountGroupByArgs['orderBy'] }
        : { orderBy?: SavingsAccountGroupByArgs['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, SavingsAccountGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetSavingsAccountGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the SavingsAccount model
   */
  readonly fields: SavingsAccountFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for SavingsAccount.
   * 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__SavingsAccountClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> 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"> | Null, Null, ExtArgs>
    movimentos<T extends SavingsAccount$movimentosArgs<ExtArgs> = {}>(args?: Subset<T, SavingsAccount$movimentosArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$SavingsMovementPayload<ExtArgs>, T, "findMany"> | 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 SavingsAccount model
   */ 
  interface SavingsAccountFieldRefs {
    readonly id: FieldRef<"SavingsAccount", 'String'>
    readonly userId: FieldRef<"SavingsAccount", 'String'>
    readonly nome: FieldRef<"SavingsAccount", 'String'>
    readonly objectivo: FieldRef<"SavingsAccount", 'String'>
    readonly meta: FieldRef<"SavingsAccount", 'Float'>
    readonly saldo: FieldRef<"SavingsAccount", 'Float'>
    readonly taxaRemuneracaoAnual: FieldRef<"SavingsAccount", 'Float'>
    readonly imobilizacaoMeses: FieldRef<"SavingsAccount", 'Int'>
    readonly status: FieldRef<"SavingsAccount", 'String'>
    readonly ultimaCapitalizacao: FieldRef<"SavingsAccount", 'DateTime'>
    readonly createdAt: FieldRef<"SavingsAccount", 'DateTime'>
    readonly updatedAt: FieldRef<"SavingsAccount", 'DateTime'>
  }
    

  // Custom InputTypes
  /**
   * SavingsAccount findUnique
   */
  export type SavingsAccountFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SavingsAccount
     */
    select?: SavingsAccountSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: SavingsAccountInclude<ExtArgs> | null
    /**
     * Filter, which SavingsAccount to fetch.
     */
    where: SavingsAccountWhereUniqueInput
  }

  /**
   * SavingsAccount findUniqueOrThrow
   */
  export type SavingsAccountFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SavingsAccount
     */
    select?: SavingsAccountSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: SavingsAccountInclude<ExtArgs> | null
    /**
     * Filter, which SavingsAccount to fetch.
     */
    where: SavingsAccountWhereUniqueInput
  }

  /**
   * SavingsAccount findFirst
   */
  export type SavingsAccountFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SavingsAccount
     */
    select?: SavingsAccountSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: SavingsAccountInclude<ExtArgs> | null
    /**
     * Filter, which SavingsAccount to fetch.
     */
    where?: SavingsAccountWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of SavingsAccounts to fetch.
     */
    orderBy?: SavingsAccountOrderByWithRelationInput | SavingsAccountOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for SavingsAccounts.
     */
    cursor?: SavingsAccountWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` SavingsAccounts 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` SavingsAccounts.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of SavingsAccounts.
     */
    distinct?: SavingsAccountScalarFieldEnum | SavingsAccountScalarFieldEnum[]
  }

  /**
   * SavingsAccount findFirstOrThrow
   */
  export type SavingsAccountFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SavingsAccount
     */
    select?: SavingsAccountSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: SavingsAccountInclude<ExtArgs> | null
    /**
     * Filter, which SavingsAccount to fetch.
     */
    where?: SavingsAccountWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of SavingsAccounts to fetch.
     */
    orderBy?: SavingsAccountOrderByWithRelationInput | SavingsAccountOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for SavingsAccounts.
     */
    cursor?: SavingsAccountWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` SavingsAccounts 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` SavingsAccounts.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of SavingsAccounts.
     */
    distinct?: SavingsAccountScalarFieldEnum | SavingsAccountScalarFieldEnum[]
  }

  /**
   * SavingsAccount findMany
   */
  export type SavingsAccountFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SavingsAccount
     */
    select?: SavingsAccountSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: SavingsAccountInclude<ExtArgs> | null
    /**
     * Filter, which SavingsAccounts to fetch.
     */
    where?: SavingsAccountWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of SavingsAccounts to fetch.
     */
    orderBy?: SavingsAccountOrderByWithRelationInput | SavingsAccountOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing SavingsAccounts.
     */
    cursor?: SavingsAccountWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` SavingsAccounts 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` SavingsAccounts.
     */
    skip?: number
    distinct?: SavingsAccountScalarFieldEnum | SavingsAccountScalarFieldEnum[]
  }

  /**
   * SavingsAccount create
   */
  export type SavingsAccountCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SavingsAccount
     */
    select?: SavingsAccountSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: SavingsAccountInclude<ExtArgs> | null
    /**
     * The data needed to create a SavingsAccount.
     */
    data: XOR<SavingsAccountCreateInput, SavingsAccountUncheckedCreateInput>
  }

  /**
   * SavingsAccount createMany
   */
  export type SavingsAccountCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many SavingsAccounts.
     */
    data: SavingsAccountCreateManyInput | SavingsAccountCreateManyInput[]
    skipDuplicates?: boolean
  }

  /**
   * SavingsAccount update
   */
  export type SavingsAccountUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SavingsAccount
     */
    select?: SavingsAccountSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: SavingsAccountInclude<ExtArgs> | null
    /**
     * The data needed to update a SavingsAccount.
     */
    data: XOR<SavingsAccountUpdateInput, SavingsAccountUncheckedUpdateInput>
    /**
     * Choose, which SavingsAccount to update.
     */
    where: SavingsAccountWhereUniqueInput
  }

  /**
   * SavingsAccount updateMany
   */
  export type SavingsAccountUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update SavingsAccounts.
     */
    data: XOR<SavingsAccountUpdateManyMutationInput, SavingsAccountUncheckedUpdateManyInput>
    /**
     * Filter which SavingsAccounts to update
     */
    where?: SavingsAccountWhereInput
  }

  /**
   * SavingsAccount upsert
   */
  export type SavingsAccountUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SavingsAccount
     */
    select?: SavingsAccountSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: SavingsAccountInclude<ExtArgs> | null
    /**
     * The filter to search for the SavingsAccount to update in case it exists.
     */
    where: SavingsAccountWhereUniqueInput
    /**
     * In case the SavingsAccount found by the `where` argument doesn't exist, create a new SavingsAccount with this data.
     */
    create: XOR<SavingsAccountCreateInput, SavingsAccountUncheckedCreateInput>
    /**
     * In case the SavingsAccount was found with the provided `where` argument, update it with this data.
     */
    update: XOR<SavingsAccountUpdateInput, SavingsAccountUncheckedUpdateInput>
  }

  /**
   * SavingsAccount delete
   */
  export type SavingsAccountDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SavingsAccount
     */
    select?: SavingsAccountSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: SavingsAccountInclude<ExtArgs> | null
    /**
     * Filter which SavingsAccount to delete.
     */
    where: SavingsAccountWhereUniqueInput
  }

  /**
   * SavingsAccount deleteMany
   */
  export type SavingsAccountDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which SavingsAccounts to delete
     */
    where?: SavingsAccountWhereInput
  }

  /**
   * SavingsAccount.movimentos
   */
  export type SavingsAccount$movimentosArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SavingsMovement
     */
    select?: SavingsMovementSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: SavingsMovementInclude<ExtArgs> | null
    where?: SavingsMovementWhereInput
    orderBy?: SavingsMovementOrderByWithRelationInput | SavingsMovementOrderByWithRelationInput[]
    cursor?: SavingsMovementWhereUniqueInput
    take?: number
    skip?: number
    distinct?: SavingsMovementScalarFieldEnum | SavingsMovementScalarFieldEnum[]
  }

  /**
   * SavingsAccount without action
   */
  export type SavingsAccountDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SavingsAccount
     */
    select?: SavingsAccountSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: SavingsAccountInclude<ExtArgs> | null
  }


  /**
   * Model SavingsMovement
   */

  export type AggregateSavingsMovement = {
    _count: SavingsMovementCountAggregateOutputType | null
    _avg: SavingsMovementAvgAggregateOutputType | null
    _sum: SavingsMovementSumAggregateOutputType | null
    _min: SavingsMovementMinAggregateOutputType | null
    _max: SavingsMovementMaxAggregateOutputType | null
  }

  export type SavingsMovementAvgAggregateOutputType = {
    valor: number | null
    saldoApos: number | null
  }

  export type SavingsMovementSumAggregateOutputType = {
    valor: number | null
    saldoApos: number | null
  }

  export type SavingsMovementMinAggregateOutputType = {
    id: string | null
    accountId: string | null
    tipo: string | null
    valor: number | null
    saldoApos: number | null
    descricao: string | null
    createdAt: Date | null
  }

  export type SavingsMovementMaxAggregateOutputType = {
    id: string | null
    accountId: string | null
    tipo: string | null
    valor: number | null
    saldoApos: number | null
    descricao: string | null
    createdAt: Date | null
  }

  export type SavingsMovementCountAggregateOutputType = {
    id: number
    accountId: number
    tipo: number
    valor: number
    saldoApos: number
    descricao: number
    createdAt: number
    _all: number
  }


  export type SavingsMovementAvgAggregateInputType = {
    valor?: true
    saldoApos?: true
  }

  export type SavingsMovementSumAggregateInputType = {
    valor?: true
    saldoApos?: true
  }

  export type SavingsMovementMinAggregateInputType = {
    id?: true
    accountId?: true
    tipo?: true
    valor?: true
    saldoApos?: true
    descricao?: true
    createdAt?: true
  }

  export type SavingsMovementMaxAggregateInputType = {
    id?: true
    accountId?: true
    tipo?: true
    valor?: true
    saldoApos?: true
    descricao?: true
    createdAt?: true
  }

  export type SavingsMovementCountAggregateInputType = {
    id?: true
    accountId?: true
    tipo?: true
    valor?: true
    saldoApos?: true
    descricao?: true
    createdAt?: true
    _all?: true
  }

  export type SavingsMovementAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which SavingsMovement to aggregate.
     */
    where?: SavingsMovementWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of SavingsMovements to fetch.
     */
    orderBy?: SavingsMovementOrderByWithRelationInput | SavingsMovementOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: SavingsMovementWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` SavingsMovements 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` SavingsMovements.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned SavingsMovements
    **/
    _count?: true | SavingsMovementCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to average
    **/
    _avg?: SavingsMovementAvgAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to sum
    **/
    _sum?: SavingsMovementSumAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: SavingsMovementMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: SavingsMovementMaxAggregateInputType
  }

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




  export type SavingsMovementGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: SavingsMovementWhereInput
    orderBy?: SavingsMovementOrderByWithAggregationInput | SavingsMovementOrderByWithAggregationInput[]
    by: SavingsMovementScalarFieldEnum[] | SavingsMovementScalarFieldEnum
    having?: SavingsMovementScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: SavingsMovementCountAggregateInputType | true
    _avg?: SavingsMovementAvgAggregateInputType
    _sum?: SavingsMovementSumAggregateInputType
    _min?: SavingsMovementMinAggregateInputType
    _max?: SavingsMovementMaxAggregateInputType
  }

  export type SavingsMovementGroupByOutputType = {
    id: string
    accountId: string
    tipo: string
    valor: number
    saldoApos: number
    descricao: string | null
    createdAt: Date
    _count: SavingsMovementCountAggregateOutputType | null
    _avg: SavingsMovementAvgAggregateOutputType | null
    _sum: SavingsMovementSumAggregateOutputType | null
    _min: SavingsMovementMinAggregateOutputType | null
    _max: SavingsMovementMaxAggregateOutputType | null
  }

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


  export type SavingsMovementSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    accountId?: boolean
    tipo?: boolean
    valor?: boolean
    saldoApos?: boolean
    descricao?: boolean
    createdAt?: boolean
    account?: boolean | SavingsAccountDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["savingsMovement"]>


  export type SavingsMovementSelectScalar = {
    id?: boolean
    accountId?: boolean
    tipo?: boolean
    valor?: boolean
    saldoApos?: boolean
    descricao?: boolean
    createdAt?: boolean
  }

  export type SavingsMovementInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    account?: boolean | SavingsAccountDefaultArgs<ExtArgs>
  }

  export type $SavingsMovementPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "SavingsMovement"
    objects: {
      account: Prisma.$SavingsAccountPayload<ExtArgs>
    }
    scalars: $Extensions.GetPayloadResult<{
      id: string
      accountId: string
      tipo: string
      valor: number
      saldoApos: number
      descricao: string | null
      createdAt: Date
    }, ExtArgs["result"]["savingsMovement"]>
    composites: {}
  }

  type SavingsMovementGetPayload<S extends boolean | null | undefined | SavingsMovementDefaultArgs> = $Result.GetResult<Prisma.$SavingsMovementPayload, S>

  type SavingsMovementCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = 
    Omit<SavingsMovementFindManyArgs, 'select' | 'include' | 'distinct'> & {
      select?: SavingsMovementCountAggregateInputType | true
    }

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

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

    /**
     * Find the first SavingsMovement 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 {SavingsMovementFindFirstArgs} args - Arguments to find a SavingsMovement
     * @example
     * // Get one SavingsMovement
     * const savingsMovement = await prisma.savingsMovement.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends SavingsMovementFindFirstArgs>(args?: SelectSubset<T, SavingsMovementFindFirstArgs<ExtArgs>>): Prisma__SavingsMovementClient<$Result.GetResult<Prisma.$SavingsMovementPayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>

    /**
     * Find the first SavingsMovement 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 {SavingsMovementFindFirstOrThrowArgs} args - Arguments to find a SavingsMovement
     * @example
     * // Get one SavingsMovement
     * const savingsMovement = await prisma.savingsMovement.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends SavingsMovementFindFirstOrThrowArgs>(args?: SelectSubset<T, SavingsMovementFindFirstOrThrowArgs<ExtArgs>>): Prisma__SavingsMovementClient<$Result.GetResult<Prisma.$SavingsMovementPayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>

    /**
     * Find zero or more SavingsMovements 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 {SavingsMovementFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all SavingsMovements
     * const savingsMovements = await prisma.savingsMovement.findMany()
     * 
     * // Get first 10 SavingsMovements
     * const savingsMovements = await prisma.savingsMovement.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const savingsMovementWithIdOnly = await prisma.savingsMovement.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends SavingsMovementFindManyArgs>(args?: SelectSubset<T, SavingsMovementFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$SavingsMovementPayload<ExtArgs>, T, "findMany">>

    /**
     * Create a SavingsMovement.
     * @param {SavingsMovementCreateArgs} args - Arguments to create a SavingsMovement.
     * @example
     * // Create one SavingsMovement
     * const SavingsMovement = await prisma.savingsMovement.create({
     *   data: {
     *     // ... data to create a SavingsMovement
     *   }
     * })
     * 
     */
    create<T extends SavingsMovementCreateArgs>(args: SelectSubset<T, SavingsMovementCreateArgs<ExtArgs>>): Prisma__SavingsMovementClient<$Result.GetResult<Prisma.$SavingsMovementPayload<ExtArgs>, T, "create">, never, ExtArgs>

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

    /**
     * Delete a SavingsMovement.
     * @param {SavingsMovementDeleteArgs} args - Arguments to delete one SavingsMovement.
     * @example
     * // Delete one SavingsMovement
     * const SavingsMovement = await prisma.savingsMovement.delete({
     *   where: {
     *     // ... filter to delete one SavingsMovement
     *   }
     * })
     * 
     */
    delete<T extends SavingsMovementDeleteArgs>(args: SelectSubset<T, SavingsMovementDeleteArgs<ExtArgs>>): Prisma__SavingsMovementClient<$Result.GetResult<Prisma.$SavingsMovementPayload<ExtArgs>, T, "delete">, never, ExtArgs>

    /**
     * Update one SavingsMovement.
     * @param {SavingsMovementUpdateArgs} args - Arguments to update one SavingsMovement.
     * @example
     * // Update one SavingsMovement
     * const savingsMovement = await prisma.savingsMovement.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends SavingsMovementUpdateArgs>(args: SelectSubset<T, SavingsMovementUpdateArgs<ExtArgs>>): Prisma__SavingsMovementClient<$Result.GetResult<Prisma.$SavingsMovementPayload<ExtArgs>, T, "update">, never, ExtArgs>

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

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

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


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

    /**
     * Allows you to perform aggregations operations on a SavingsMovement.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {SavingsMovementAggregateArgs} 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 SavingsMovementAggregateArgs>(args: Subset<T, SavingsMovementAggregateArgs>): Prisma.PrismaPromise<GetSavingsMovementAggregateType<T>>

    /**
     * Group by SavingsMovement.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {SavingsMovementGroupByArgs} 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 SavingsMovementGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: SavingsMovementGroupByArgs['orderBy'] }
        : { orderBy?: SavingsMovementGroupByArgs['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, SavingsMovementGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetSavingsMovementGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the SavingsMovement model
   */
  readonly fields: SavingsMovementFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for SavingsMovement.
   * 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__SavingsMovementClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
    readonly [Symbol.toStringTag]: "PrismaPromise"
    account<T extends SavingsAccountDefaultArgs<ExtArgs> = {}>(args?: Subset<T, SavingsAccountDefaultArgs<ExtArgs>>): Prisma__SavingsAccountClient<$Result.GetResult<Prisma.$SavingsAccountPayload<ExtArgs>, T, "findUniqueOrThrow"> | Null, Null, ExtArgs>
    /**
     * 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 SavingsMovement model
   */ 
  interface SavingsMovementFieldRefs {
    readonly id: FieldRef<"SavingsMovement", 'String'>
    readonly accountId: FieldRef<"SavingsMovement", 'String'>
    readonly tipo: FieldRef<"SavingsMovement", 'String'>
    readonly valor: FieldRef<"SavingsMovement", 'Float'>
    readonly saldoApos: FieldRef<"SavingsMovement", 'Float'>
    readonly descricao: FieldRef<"SavingsMovement", 'String'>
    readonly createdAt: FieldRef<"SavingsMovement", 'DateTime'>
  }
    

  // Custom InputTypes
  /**
   * SavingsMovement findUnique
   */
  export type SavingsMovementFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SavingsMovement
     */
    select?: SavingsMovementSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: SavingsMovementInclude<ExtArgs> | null
    /**
     * Filter, which SavingsMovement to fetch.
     */
    where: SavingsMovementWhereUniqueInput
  }

  /**
   * SavingsMovement findUniqueOrThrow
   */
  export type SavingsMovementFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SavingsMovement
     */
    select?: SavingsMovementSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: SavingsMovementInclude<ExtArgs> | null
    /**
     * Filter, which SavingsMovement to fetch.
     */
    where: SavingsMovementWhereUniqueInput
  }

  /**
   * SavingsMovement findFirst
   */
  export type SavingsMovementFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SavingsMovement
     */
    select?: SavingsMovementSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: SavingsMovementInclude<ExtArgs> | null
    /**
     * Filter, which SavingsMovement to fetch.
     */
    where?: SavingsMovementWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of SavingsMovements to fetch.
     */
    orderBy?: SavingsMovementOrderByWithRelationInput | SavingsMovementOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for SavingsMovements.
     */
    cursor?: SavingsMovementWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` SavingsMovements 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` SavingsMovements.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of SavingsMovements.
     */
    distinct?: SavingsMovementScalarFieldEnum | SavingsMovementScalarFieldEnum[]
  }

  /**
   * SavingsMovement findFirstOrThrow
   */
  export type SavingsMovementFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SavingsMovement
     */
    select?: SavingsMovementSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: SavingsMovementInclude<ExtArgs> | null
    /**
     * Filter, which SavingsMovement to fetch.
     */
    where?: SavingsMovementWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of SavingsMovements to fetch.
     */
    orderBy?: SavingsMovementOrderByWithRelationInput | SavingsMovementOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for SavingsMovements.
     */
    cursor?: SavingsMovementWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` SavingsMovements 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` SavingsMovements.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of SavingsMovements.
     */
    distinct?: SavingsMovementScalarFieldEnum | SavingsMovementScalarFieldEnum[]
  }

  /**
   * SavingsMovement findMany
   */
  export type SavingsMovementFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SavingsMovement
     */
    select?: SavingsMovementSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: SavingsMovementInclude<ExtArgs> | null
    /**
     * Filter, which SavingsMovements to fetch.
     */
    where?: SavingsMovementWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of SavingsMovements to fetch.
     */
    orderBy?: SavingsMovementOrderByWithRelationInput | SavingsMovementOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing SavingsMovements.
     */
    cursor?: SavingsMovementWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` SavingsMovements 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` SavingsMovements.
     */
    skip?: number
    distinct?: SavingsMovementScalarFieldEnum | SavingsMovementScalarFieldEnum[]
  }

  /**
   * SavingsMovement create
   */
  export type SavingsMovementCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SavingsMovement
     */
    select?: SavingsMovementSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: SavingsMovementInclude<ExtArgs> | null
    /**
     * The data needed to create a SavingsMovement.
     */
    data: XOR<SavingsMovementCreateInput, SavingsMovementUncheckedCreateInput>
  }

  /**
   * SavingsMovement createMany
   */
  export type SavingsMovementCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many SavingsMovements.
     */
    data: SavingsMovementCreateManyInput | SavingsMovementCreateManyInput[]
    skipDuplicates?: boolean
  }

  /**
   * SavingsMovement update
   */
  export type SavingsMovementUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SavingsMovement
     */
    select?: SavingsMovementSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: SavingsMovementInclude<ExtArgs> | null
    /**
     * The data needed to update a SavingsMovement.
     */
    data: XOR<SavingsMovementUpdateInput, SavingsMovementUncheckedUpdateInput>
    /**
     * Choose, which SavingsMovement to update.
     */
    where: SavingsMovementWhereUniqueInput
  }

  /**
   * SavingsMovement updateMany
   */
  export type SavingsMovementUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update SavingsMovements.
     */
    data: XOR<SavingsMovementUpdateManyMutationInput, SavingsMovementUncheckedUpdateManyInput>
    /**
     * Filter which SavingsMovements to update
     */
    where?: SavingsMovementWhereInput
  }

  /**
   * SavingsMovement upsert
   */
  export type SavingsMovementUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SavingsMovement
     */
    select?: SavingsMovementSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: SavingsMovementInclude<ExtArgs> | null
    /**
     * The filter to search for the SavingsMovement to update in case it exists.
     */
    where: SavingsMovementWhereUniqueInput
    /**
     * In case the SavingsMovement found by the `where` argument doesn't exist, create a new SavingsMovement with this data.
     */
    create: XOR<SavingsMovementCreateInput, SavingsMovementUncheckedCreateInput>
    /**
     * In case the SavingsMovement was found with the provided `where` argument, update it with this data.
     */
    update: XOR<SavingsMovementUpdateInput, SavingsMovementUncheckedUpdateInput>
  }

  /**
   * SavingsMovement delete
   */
  export type SavingsMovementDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SavingsMovement
     */
    select?: SavingsMovementSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: SavingsMovementInclude<ExtArgs> | null
    /**
     * Filter which SavingsMovement to delete.
     */
    where: SavingsMovementWhereUniqueInput
  }

  /**
   * SavingsMovement deleteMany
   */
  export type SavingsMovementDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which SavingsMovements to delete
     */
    where?: SavingsMovementWhereInput
  }

  /**
   * SavingsMovement without action
   */
  export type SavingsMovementDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the SavingsMovement
     */
    select?: SavingsMovementSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: SavingsMovementInclude<ExtArgs> | null
  }


  /**
   * Model Referral
   */

  export type AggregateReferral = {
    _count: ReferralCountAggregateOutputType | null
    _avg: ReferralAvgAggregateOutputType | null
    _sum: ReferralSumAggregateOutputType | null
    _min: ReferralMinAggregateOutputType | null
    _max: ReferralMaxAggregateOutputType | null
  }

  export type ReferralAvgAggregateOutputType = {
    recompensa: number | null
  }

  export type ReferralSumAggregateOutputType = {
    recompensa: number | null
  }

  export type ReferralMinAggregateOutputType = {
    id: string | null
    referrerUserId: string | null
    referredUserId: string | null
    codigo: string | null
    canal: string | null
    status: string | null
    recompensa: number | null
    recompensaPaga: boolean | null
    dataRegisto: Date | null
    dataActivacao: Date | null
    createdAt: Date | null
  }

  export type ReferralMaxAggregateOutputType = {
    id: string | null
    referrerUserId: string | null
    referredUserId: string | null
    codigo: string | null
    canal: string | null
    status: string | null
    recompensa: number | null
    recompensaPaga: boolean | null
    dataRegisto: Date | null
    dataActivacao: Date | null
    createdAt: Date | null
  }

  export type ReferralCountAggregateOutputType = {
    id: number
    referrerUserId: number
    referredUserId: number
    codigo: number
    canal: number
    status: number
    recompensa: number
    recompensaPaga: number
    dataRegisto: number
    dataActivacao: number
    createdAt: number
    _all: number
  }


  export type ReferralAvgAggregateInputType = {
    recompensa?: true
  }

  export type ReferralSumAggregateInputType = {
    recompensa?: true
  }

  export type ReferralMinAggregateInputType = {
    id?: true
    referrerUserId?: true
    referredUserId?: true
    codigo?: true
    canal?: true
    status?: true
    recompensa?: true
    recompensaPaga?: true
    dataRegisto?: true
    dataActivacao?: true
    createdAt?: true
  }

  export type ReferralMaxAggregateInputType = {
    id?: true
    referrerUserId?: true
    referredUserId?: true
    codigo?: true
    canal?: true
    status?: true
    recompensa?: true
    recompensaPaga?: true
    dataRegisto?: true
    dataActivacao?: true
    createdAt?: true
  }

  export type ReferralCountAggregateInputType = {
    id?: true
    referrerUserId?: true
    referredUserId?: true
    codigo?: true
    canal?: true
    status?: true
    recompensa?: true
    recompensaPaga?: true
    dataRegisto?: true
    dataActivacao?: true
    createdAt?: true
    _all?: true
  }

  export type ReferralAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which Referral to aggregate.
     */
    where?: ReferralWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Referrals to fetch.
     */
    orderBy?: ReferralOrderByWithRelationInput | ReferralOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: ReferralWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Referrals 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` Referrals.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned Referrals
    **/
    _count?: true | ReferralCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to average
    **/
    _avg?: ReferralAvgAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to sum
    **/
    _sum?: ReferralSumAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: ReferralMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: ReferralMaxAggregateInputType
  }

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




  export type ReferralGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: ReferralWhereInput
    orderBy?: ReferralOrderByWithAggregationInput | ReferralOrderByWithAggregationInput[]
    by: ReferralScalarFieldEnum[] | ReferralScalarFieldEnum
    having?: ReferralScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: ReferralCountAggregateInputType | true
    _avg?: ReferralAvgAggregateInputType
    _sum?: ReferralSumAggregateInputType
    _min?: ReferralMinAggregateInputType
    _max?: ReferralMaxAggregateInputType
  }

  export type ReferralGroupByOutputType = {
    id: string
    referrerUserId: string
    referredUserId: string | null
    codigo: string
    canal: string | null
    status: string
    recompensa: number
    recompensaPaga: boolean
    dataRegisto: Date | null
    dataActivacao: Date | null
    createdAt: Date
    _count: ReferralCountAggregateOutputType | null
    _avg: ReferralAvgAggregateOutputType | null
    _sum: ReferralSumAggregateOutputType | null
    _min: ReferralMinAggregateOutputType | null
    _max: ReferralMaxAggregateOutputType | null
  }

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


  export type ReferralSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    referrerUserId?: boolean
    referredUserId?: boolean
    codigo?: boolean
    canal?: boolean
    status?: boolean
    recompensa?: boolean
    recompensaPaga?: boolean
    dataRegisto?: boolean
    dataActivacao?: boolean
    createdAt?: boolean
    referrer?: boolean | UserDefaultArgs<ExtArgs>
    referredUser?: boolean | Referral$referredUserArgs<ExtArgs>
  }, ExtArgs["result"]["referral"]>


  export type ReferralSelectScalar = {
    id?: boolean
    referrerUserId?: boolean
    referredUserId?: boolean
    codigo?: boolean
    canal?: boolean
    status?: boolean
    recompensa?: boolean
    recompensaPaga?: boolean
    dataRegisto?: boolean
    dataActivacao?: boolean
    createdAt?: boolean
  }

  export type ReferralInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    referrer?: boolean | UserDefaultArgs<ExtArgs>
    referredUser?: boolean | Referral$referredUserArgs<ExtArgs>
  }

  export type $ReferralPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "Referral"
    objects: {
      referrer: Prisma.$UserPayload<ExtArgs>
      referredUser: Prisma.$UserPayload<ExtArgs> | null
    }
    scalars: $Extensions.GetPayloadResult<{
      id: string
      referrerUserId: string
      referredUserId: string | null
      codigo: string
      canal: string | null
      status: string
      recompensa: number
      recompensaPaga: boolean
      dataRegisto: Date | null
      dataActivacao: Date | null
      createdAt: Date
    }, ExtArgs["result"]["referral"]>
    composites: {}
  }

  type ReferralGetPayload<S extends boolean | null | undefined | ReferralDefaultArgs> = $Result.GetResult<Prisma.$ReferralPayload, S>

  type ReferralCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = 
    Omit<ReferralFindManyArgs, 'select' | 'include' | 'distinct'> & {
      select?: ReferralCountAggregateInputType | true
    }

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

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

    /**
     * Find the first Referral 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 {ReferralFindFirstArgs} args - Arguments to find a Referral
     * @example
     * // Get one Referral
     * const referral = await prisma.referral.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends ReferralFindFirstArgs>(args?: SelectSubset<T, ReferralFindFirstArgs<ExtArgs>>): Prisma__ReferralClient<$Result.GetResult<Prisma.$ReferralPayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>

    /**
     * Find the first Referral 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 {ReferralFindFirstOrThrowArgs} args - Arguments to find a Referral
     * @example
     * // Get one Referral
     * const referral = await prisma.referral.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends ReferralFindFirstOrThrowArgs>(args?: SelectSubset<T, ReferralFindFirstOrThrowArgs<ExtArgs>>): Prisma__ReferralClient<$Result.GetResult<Prisma.$ReferralPayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>

    /**
     * Find zero or more Referrals 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 {ReferralFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all Referrals
     * const referrals = await prisma.referral.findMany()
     * 
     * // Get first 10 Referrals
     * const referrals = await prisma.referral.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const referralWithIdOnly = await prisma.referral.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends ReferralFindManyArgs>(args?: SelectSubset<T, ReferralFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$ReferralPayload<ExtArgs>, T, "findMany">>

    /**
     * Create a Referral.
     * @param {ReferralCreateArgs} args - Arguments to create a Referral.
     * @example
     * // Create one Referral
     * const Referral = await prisma.referral.create({
     *   data: {
     *     // ... data to create a Referral
     *   }
     * })
     * 
     */
    create<T extends ReferralCreateArgs>(args: SelectSubset<T, ReferralCreateArgs<ExtArgs>>): Prisma__ReferralClient<$Result.GetResult<Prisma.$ReferralPayload<ExtArgs>, T, "create">, never, ExtArgs>

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

    /**
     * Delete a Referral.
     * @param {ReferralDeleteArgs} args - Arguments to delete one Referral.
     * @example
     * // Delete one Referral
     * const Referral = await prisma.referral.delete({
     *   where: {
     *     // ... filter to delete one Referral
     *   }
     * })
     * 
     */
    delete<T extends ReferralDeleteArgs>(args: SelectSubset<T, ReferralDeleteArgs<ExtArgs>>): Prisma__ReferralClient<$Result.GetResult<Prisma.$ReferralPayload<ExtArgs>, T, "delete">, never, ExtArgs>

    /**
     * Update one Referral.
     * @param {ReferralUpdateArgs} args - Arguments to update one Referral.
     * @example
     * // Update one Referral
     * const referral = await prisma.referral.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends ReferralUpdateArgs>(args: SelectSubset<T, ReferralUpdateArgs<ExtArgs>>): Prisma__ReferralClient<$Result.GetResult<Prisma.$ReferralPayload<ExtArgs>, T, "update">, never, ExtArgs>

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

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

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


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

    /**
     * Allows you to perform aggregations operations on a Referral.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {ReferralAggregateArgs} 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 ReferralAggregateArgs>(args: Subset<T, ReferralAggregateArgs>): Prisma.PrismaPromise<GetReferralAggregateType<T>>

    /**
     * Group by Referral.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {ReferralGroupByArgs} 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 ReferralGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: ReferralGroupByArgs['orderBy'] }
        : { orderBy?: ReferralGroupByArgs['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, ReferralGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetReferralGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the Referral model
   */
  readonly fields: ReferralFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for Referral.
   * 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__ReferralClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
    readonly [Symbol.toStringTag]: "PrismaPromise"
    referrer<T extends UserDefaultArgs<ExtArgs> = {}>(args?: Subset<T, UserDefaultArgs<ExtArgs>>): Prisma__UserClient<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "findUniqueOrThrow"> | Null, Null, ExtArgs>
    referredUser<T extends Referral$referredUserArgs<ExtArgs> = {}>(args?: Subset<T, Referral$referredUserArgs<ExtArgs>>): Prisma__UserClient<$Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "findUniqueOrThrow"> | null, null, ExtArgs>
    /**
     * 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 Referral model
   */ 
  interface ReferralFieldRefs {
    readonly id: FieldRef<"Referral", 'String'>
    readonly referrerUserId: FieldRef<"Referral", 'String'>
    readonly referredUserId: FieldRef<"Referral", 'String'>
    readonly codigo: FieldRef<"Referral", 'String'>
    readonly canal: FieldRef<"Referral", 'String'>
    readonly status: FieldRef<"Referral", 'String'>
    readonly recompensa: FieldRef<"Referral", 'Float'>
    readonly recompensaPaga: FieldRef<"Referral", 'Boolean'>
    readonly dataRegisto: FieldRef<"Referral", 'DateTime'>
    readonly dataActivacao: FieldRef<"Referral", 'DateTime'>
    readonly createdAt: FieldRef<"Referral", 'DateTime'>
  }
    

  // Custom InputTypes
  /**
   * Referral findUnique
   */
  export type ReferralFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Referral
     */
    select?: ReferralSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ReferralInclude<ExtArgs> | null
    /**
     * Filter, which Referral to fetch.
     */
    where: ReferralWhereUniqueInput
  }

  /**
   * Referral findUniqueOrThrow
   */
  export type ReferralFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Referral
     */
    select?: ReferralSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ReferralInclude<ExtArgs> | null
    /**
     * Filter, which Referral to fetch.
     */
    where: ReferralWhereUniqueInput
  }

  /**
   * Referral findFirst
   */
  export type ReferralFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Referral
     */
    select?: ReferralSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ReferralInclude<ExtArgs> | null
    /**
     * Filter, which Referral to fetch.
     */
    where?: ReferralWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Referrals to fetch.
     */
    orderBy?: ReferralOrderByWithRelationInput | ReferralOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for Referrals.
     */
    cursor?: ReferralWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Referrals 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` Referrals.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of Referrals.
     */
    distinct?: ReferralScalarFieldEnum | ReferralScalarFieldEnum[]
  }

  /**
   * Referral findFirstOrThrow
   */
  export type ReferralFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Referral
     */
    select?: ReferralSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ReferralInclude<ExtArgs> | null
    /**
     * Filter, which Referral to fetch.
     */
    where?: ReferralWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Referrals to fetch.
     */
    orderBy?: ReferralOrderByWithRelationInput | ReferralOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for Referrals.
     */
    cursor?: ReferralWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Referrals 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` Referrals.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of Referrals.
     */
    distinct?: ReferralScalarFieldEnum | ReferralScalarFieldEnum[]
  }

  /**
   * Referral findMany
   */
  export type ReferralFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Referral
     */
    select?: ReferralSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ReferralInclude<ExtArgs> | null
    /**
     * Filter, which Referrals to fetch.
     */
    where?: ReferralWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Referrals to fetch.
     */
    orderBy?: ReferralOrderByWithRelationInput | ReferralOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing Referrals.
     */
    cursor?: ReferralWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Referrals 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` Referrals.
     */
    skip?: number
    distinct?: ReferralScalarFieldEnum | ReferralScalarFieldEnum[]
  }

  /**
   * Referral create
   */
  export type ReferralCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Referral
     */
    select?: ReferralSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ReferralInclude<ExtArgs> | null
    /**
     * The data needed to create a Referral.
     */
    data: XOR<ReferralCreateInput, ReferralUncheckedCreateInput>
  }

  /**
   * Referral createMany
   */
  export type ReferralCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many Referrals.
     */
    data: ReferralCreateManyInput | ReferralCreateManyInput[]
    skipDuplicates?: boolean
  }

  /**
   * Referral update
   */
  export type ReferralUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Referral
     */
    select?: ReferralSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ReferralInclude<ExtArgs> | null
    /**
     * The data needed to update a Referral.
     */
    data: XOR<ReferralUpdateInput, ReferralUncheckedUpdateInput>
    /**
     * Choose, which Referral to update.
     */
    where: ReferralWhereUniqueInput
  }

  /**
   * Referral updateMany
   */
  export type ReferralUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update Referrals.
     */
    data: XOR<ReferralUpdateManyMutationInput, ReferralUncheckedUpdateManyInput>
    /**
     * Filter which Referrals to update
     */
    where?: ReferralWhereInput
  }

  /**
   * Referral upsert
   */
  export type ReferralUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Referral
     */
    select?: ReferralSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ReferralInclude<ExtArgs> | null
    /**
     * The filter to search for the Referral to update in case it exists.
     */
    where: ReferralWhereUniqueInput
    /**
     * In case the Referral found by the `where` argument doesn't exist, create a new Referral with this data.
     */
    create: XOR<ReferralCreateInput, ReferralUncheckedCreateInput>
    /**
     * In case the Referral was found with the provided `where` argument, update it with this data.
     */
    update: XOR<ReferralUpdateInput, ReferralUncheckedUpdateInput>
  }

  /**
   * Referral delete
   */
  export type ReferralDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Referral
     */
    select?: ReferralSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ReferralInclude<ExtArgs> | null
    /**
     * Filter which Referral to delete.
     */
    where: ReferralWhereUniqueInput
  }

  /**
   * Referral deleteMany
   */
  export type ReferralDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which Referrals to delete
     */
    where?: ReferralWhereInput
  }

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

  /**
   * Referral without action
   */
  export type ReferralDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Referral
     */
    select?: ReferralSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ReferralInclude<ExtArgs> | null
  }


  /**
   * Model ContentArticle
   */

  export type AggregateContentArticle = {
    _count: ContentArticleCountAggregateOutputType | null
    _avg: ContentArticleAvgAggregateOutputType | null
    _sum: ContentArticleSumAggregateOutputType | null
    _min: ContentArticleMinAggregateOutputType | null
    _max: ContentArticleMaxAggregateOutputType | null
  }

  export type ContentArticleAvgAggregateOutputType = {
    duracaoLeituraMin: number | null
    ordem: number | null
  }

  export type ContentArticleSumAggregateOutputType = {
    duracaoLeituraMin: number | null
    ordem: number | null
  }

  export type ContentArticleMinAggregateOutputType = {
    id: string | null
    slug: string | null
    titulo: string | null
    resumo: string | null
    corpo: string | null
    categoria: string | null
    autor: string | null
    duracaoLeituraMin: number | null
    publicado: boolean | null
    ordem: number | null
    createdAt: Date | null
  }

  export type ContentArticleMaxAggregateOutputType = {
    id: string | null
    slug: string | null
    titulo: string | null
    resumo: string | null
    corpo: string | null
    categoria: string | null
    autor: string | null
    duracaoLeituraMin: number | null
    publicado: boolean | null
    ordem: number | null
    createdAt: Date | null
  }

  export type ContentArticleCountAggregateOutputType = {
    id: number
    slug: number
    titulo: number
    resumo: number
    corpo: number
    categoria: number
    autor: number
    duracaoLeituraMin: number
    publicado: number
    ordem: number
    createdAt: number
    _all: number
  }


  export type ContentArticleAvgAggregateInputType = {
    duracaoLeituraMin?: true
    ordem?: true
  }

  export type ContentArticleSumAggregateInputType = {
    duracaoLeituraMin?: true
    ordem?: true
  }

  export type ContentArticleMinAggregateInputType = {
    id?: true
    slug?: true
    titulo?: true
    resumo?: true
    corpo?: true
    categoria?: true
    autor?: true
    duracaoLeituraMin?: true
    publicado?: true
    ordem?: true
    createdAt?: true
  }

  export type ContentArticleMaxAggregateInputType = {
    id?: true
    slug?: true
    titulo?: true
    resumo?: true
    corpo?: true
    categoria?: true
    autor?: true
    duracaoLeituraMin?: true
    publicado?: true
    ordem?: true
    createdAt?: true
  }

  export type ContentArticleCountAggregateInputType = {
    id?: true
    slug?: true
    titulo?: true
    resumo?: true
    corpo?: true
    categoria?: true
    autor?: true
    duracaoLeituraMin?: true
    publicado?: true
    ordem?: true
    createdAt?: true
    _all?: true
  }

  export type ContentArticleAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which ContentArticle to aggregate.
     */
    where?: ContentArticleWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of ContentArticles to fetch.
     */
    orderBy?: ContentArticleOrderByWithRelationInput | ContentArticleOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: ContentArticleWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` ContentArticles 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` ContentArticles.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned ContentArticles
    **/
    _count?: true | ContentArticleCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to average
    **/
    _avg?: ContentArticleAvgAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to sum
    **/
    _sum?: ContentArticleSumAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: ContentArticleMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: ContentArticleMaxAggregateInputType
  }

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




  export type ContentArticleGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: ContentArticleWhereInput
    orderBy?: ContentArticleOrderByWithAggregationInput | ContentArticleOrderByWithAggregationInput[]
    by: ContentArticleScalarFieldEnum[] | ContentArticleScalarFieldEnum
    having?: ContentArticleScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: ContentArticleCountAggregateInputType | true
    _avg?: ContentArticleAvgAggregateInputType
    _sum?: ContentArticleSumAggregateInputType
    _min?: ContentArticleMinAggregateInputType
    _max?: ContentArticleMaxAggregateInputType
  }

  export type ContentArticleGroupByOutputType = {
    id: string
    slug: string
    titulo: string
    resumo: string
    corpo: string
    categoria: string
    autor: string
    duracaoLeituraMin: number
    publicado: boolean
    ordem: number
    createdAt: Date
    _count: ContentArticleCountAggregateOutputType | null
    _avg: ContentArticleAvgAggregateOutputType | null
    _sum: ContentArticleSumAggregateOutputType | null
    _min: ContentArticleMinAggregateOutputType | null
    _max: ContentArticleMaxAggregateOutputType | null
  }

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


  export type ContentArticleSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    slug?: boolean
    titulo?: boolean
    resumo?: boolean
    corpo?: boolean
    categoria?: boolean
    autor?: boolean
    duracaoLeituraMin?: boolean
    publicado?: boolean
    ordem?: boolean
    createdAt?: boolean
  }, ExtArgs["result"]["contentArticle"]>


  export type ContentArticleSelectScalar = {
    id?: boolean
    slug?: boolean
    titulo?: boolean
    resumo?: boolean
    corpo?: boolean
    categoria?: boolean
    autor?: boolean
    duracaoLeituraMin?: boolean
    publicado?: boolean
    ordem?: boolean
    createdAt?: boolean
  }


  export type $ContentArticlePayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "ContentArticle"
    objects: {}
    scalars: $Extensions.GetPayloadResult<{
      id: string
      slug: string
      titulo: string
      resumo: string
      corpo: string
      categoria: string
      autor: string
      duracaoLeituraMin: number
      publicado: boolean
      ordem: number
      createdAt: Date
    }, ExtArgs["result"]["contentArticle"]>
    composites: {}
  }

  type ContentArticleGetPayload<S extends boolean | null | undefined | ContentArticleDefaultArgs> = $Result.GetResult<Prisma.$ContentArticlePayload, S>

  type ContentArticleCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = 
    Omit<ContentArticleFindManyArgs, 'select' | 'include' | 'distinct'> & {
      select?: ContentArticleCountAggregateInputType | true
    }

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

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

    /**
     * Find the first ContentArticle 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 {ContentArticleFindFirstArgs} args - Arguments to find a ContentArticle
     * @example
     * // Get one ContentArticle
     * const contentArticle = await prisma.contentArticle.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends ContentArticleFindFirstArgs>(args?: SelectSubset<T, ContentArticleFindFirstArgs<ExtArgs>>): Prisma__ContentArticleClient<$Result.GetResult<Prisma.$ContentArticlePayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>

    /**
     * Find the first ContentArticle 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 {ContentArticleFindFirstOrThrowArgs} args - Arguments to find a ContentArticle
     * @example
     * // Get one ContentArticle
     * const contentArticle = await prisma.contentArticle.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends ContentArticleFindFirstOrThrowArgs>(args?: SelectSubset<T, ContentArticleFindFirstOrThrowArgs<ExtArgs>>): Prisma__ContentArticleClient<$Result.GetResult<Prisma.$ContentArticlePayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>

    /**
     * Find zero or more ContentArticles 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 {ContentArticleFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all ContentArticles
     * const contentArticles = await prisma.contentArticle.findMany()
     * 
     * // Get first 10 ContentArticles
     * const contentArticles = await prisma.contentArticle.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const contentArticleWithIdOnly = await prisma.contentArticle.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends ContentArticleFindManyArgs>(args?: SelectSubset<T, ContentArticleFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$ContentArticlePayload<ExtArgs>, T, "findMany">>

    /**
     * Create a ContentArticle.
     * @param {ContentArticleCreateArgs} args - Arguments to create a ContentArticle.
     * @example
     * // Create one ContentArticle
     * const ContentArticle = await prisma.contentArticle.create({
     *   data: {
     *     // ... data to create a ContentArticle
     *   }
     * })
     * 
     */
    create<T extends ContentArticleCreateArgs>(args: SelectSubset<T, ContentArticleCreateArgs<ExtArgs>>): Prisma__ContentArticleClient<$Result.GetResult<Prisma.$ContentArticlePayload<ExtArgs>, T, "create">, never, ExtArgs>

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

    /**
     * Delete a ContentArticle.
     * @param {ContentArticleDeleteArgs} args - Arguments to delete one ContentArticle.
     * @example
     * // Delete one ContentArticle
     * const ContentArticle = await prisma.contentArticle.delete({
     *   where: {
     *     // ... filter to delete one ContentArticle
     *   }
     * })
     * 
     */
    delete<T extends ContentArticleDeleteArgs>(args: SelectSubset<T, ContentArticleDeleteArgs<ExtArgs>>): Prisma__ContentArticleClient<$Result.GetResult<Prisma.$ContentArticlePayload<ExtArgs>, T, "delete">, never, ExtArgs>

    /**
     * Update one ContentArticle.
     * @param {ContentArticleUpdateArgs} args - Arguments to update one ContentArticle.
     * @example
     * // Update one ContentArticle
     * const contentArticle = await prisma.contentArticle.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends ContentArticleUpdateArgs>(args: SelectSubset<T, ContentArticleUpdateArgs<ExtArgs>>): Prisma__ContentArticleClient<$Result.GetResult<Prisma.$ContentArticlePayload<ExtArgs>, T, "update">, never, ExtArgs>

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

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

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


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

    /**
     * Allows you to perform aggregations operations on a ContentArticle.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {ContentArticleAggregateArgs} 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 ContentArticleAggregateArgs>(args: Subset<T, ContentArticleAggregateArgs>): Prisma.PrismaPromise<GetContentArticleAggregateType<T>>

    /**
     * Group by ContentArticle.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {ContentArticleGroupByArgs} 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 ContentArticleGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: ContentArticleGroupByArgs['orderBy'] }
        : { orderBy?: ContentArticleGroupByArgs['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, ContentArticleGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetContentArticleGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the ContentArticle model
   */
  readonly fields: ContentArticleFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for ContentArticle.
   * 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__ContentArticleClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> 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 ContentArticle model
   */ 
  interface ContentArticleFieldRefs {
    readonly id: FieldRef<"ContentArticle", 'String'>
    readonly slug: FieldRef<"ContentArticle", 'String'>
    readonly titulo: FieldRef<"ContentArticle", 'String'>
    readonly resumo: FieldRef<"ContentArticle", 'String'>
    readonly corpo: FieldRef<"ContentArticle", 'String'>
    readonly categoria: FieldRef<"ContentArticle", 'String'>
    readonly autor: FieldRef<"ContentArticle", 'String'>
    readonly duracaoLeituraMin: FieldRef<"ContentArticle", 'Int'>
    readonly publicado: FieldRef<"ContentArticle", 'Boolean'>
    readonly ordem: FieldRef<"ContentArticle", 'Int'>
    readonly createdAt: FieldRef<"ContentArticle", 'DateTime'>
  }
    

  // Custom InputTypes
  /**
   * ContentArticle findUnique
   */
  export type ContentArticleFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ContentArticle
     */
    select?: ContentArticleSelect<ExtArgs> | null
    /**
     * Filter, which ContentArticle to fetch.
     */
    where: ContentArticleWhereUniqueInput
  }

  /**
   * ContentArticle findUniqueOrThrow
   */
  export type ContentArticleFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ContentArticle
     */
    select?: ContentArticleSelect<ExtArgs> | null
    /**
     * Filter, which ContentArticle to fetch.
     */
    where: ContentArticleWhereUniqueInput
  }

  /**
   * ContentArticle findFirst
   */
  export type ContentArticleFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ContentArticle
     */
    select?: ContentArticleSelect<ExtArgs> | null
    /**
     * Filter, which ContentArticle to fetch.
     */
    where?: ContentArticleWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of ContentArticles to fetch.
     */
    orderBy?: ContentArticleOrderByWithRelationInput | ContentArticleOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for ContentArticles.
     */
    cursor?: ContentArticleWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` ContentArticles 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` ContentArticles.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of ContentArticles.
     */
    distinct?: ContentArticleScalarFieldEnum | ContentArticleScalarFieldEnum[]
  }

  /**
   * ContentArticle findFirstOrThrow
   */
  export type ContentArticleFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ContentArticle
     */
    select?: ContentArticleSelect<ExtArgs> | null
    /**
     * Filter, which ContentArticle to fetch.
     */
    where?: ContentArticleWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of ContentArticles to fetch.
     */
    orderBy?: ContentArticleOrderByWithRelationInput | ContentArticleOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for ContentArticles.
     */
    cursor?: ContentArticleWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` ContentArticles 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` ContentArticles.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of ContentArticles.
     */
    distinct?: ContentArticleScalarFieldEnum | ContentArticleScalarFieldEnum[]
  }

  /**
   * ContentArticle findMany
   */
  export type ContentArticleFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ContentArticle
     */
    select?: ContentArticleSelect<ExtArgs> | null
    /**
     * Filter, which ContentArticles to fetch.
     */
    where?: ContentArticleWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of ContentArticles to fetch.
     */
    orderBy?: ContentArticleOrderByWithRelationInput | ContentArticleOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing ContentArticles.
     */
    cursor?: ContentArticleWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` ContentArticles 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` ContentArticles.
     */
    skip?: number
    distinct?: ContentArticleScalarFieldEnum | ContentArticleScalarFieldEnum[]
  }

  /**
   * ContentArticle create
   */
  export type ContentArticleCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ContentArticle
     */
    select?: ContentArticleSelect<ExtArgs> | null
    /**
     * The data needed to create a ContentArticle.
     */
    data: XOR<ContentArticleCreateInput, ContentArticleUncheckedCreateInput>
  }

  /**
   * ContentArticle createMany
   */
  export type ContentArticleCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many ContentArticles.
     */
    data: ContentArticleCreateManyInput | ContentArticleCreateManyInput[]
    skipDuplicates?: boolean
  }

  /**
   * ContentArticle update
   */
  export type ContentArticleUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ContentArticle
     */
    select?: ContentArticleSelect<ExtArgs> | null
    /**
     * The data needed to update a ContentArticle.
     */
    data: XOR<ContentArticleUpdateInput, ContentArticleUncheckedUpdateInput>
    /**
     * Choose, which ContentArticle to update.
     */
    where: ContentArticleWhereUniqueInput
  }

  /**
   * ContentArticle updateMany
   */
  export type ContentArticleUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update ContentArticles.
     */
    data: XOR<ContentArticleUpdateManyMutationInput, ContentArticleUncheckedUpdateManyInput>
    /**
     * Filter which ContentArticles to update
     */
    where?: ContentArticleWhereInput
  }

  /**
   * ContentArticle upsert
   */
  export type ContentArticleUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ContentArticle
     */
    select?: ContentArticleSelect<ExtArgs> | null
    /**
     * The filter to search for the ContentArticle to update in case it exists.
     */
    where: ContentArticleWhereUniqueInput
    /**
     * In case the ContentArticle found by the `where` argument doesn't exist, create a new ContentArticle with this data.
     */
    create: XOR<ContentArticleCreateInput, ContentArticleUncheckedCreateInput>
    /**
     * In case the ContentArticle was found with the provided `where` argument, update it with this data.
     */
    update: XOR<ContentArticleUpdateInput, ContentArticleUncheckedUpdateInput>
  }

  /**
   * ContentArticle delete
   */
  export type ContentArticleDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ContentArticle
     */
    select?: ContentArticleSelect<ExtArgs> | null
    /**
     * Filter which ContentArticle to delete.
     */
    where: ContentArticleWhereUniqueInput
  }

  /**
   * ContentArticle deleteMany
   */
  export type ContentArticleDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which ContentArticles to delete
     */
    where?: ContentArticleWhereInput
  }

  /**
   * ContentArticle without action
   */
  export type ContentArticleDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ContentArticle
     */
    select?: ContentArticleSelect<ExtArgs> | null
  }


  /**
   * Model Quiz
   */

  export type AggregateQuiz = {
    _count: QuizCountAggregateOutputType | null
    _avg: QuizAvgAggregateOutputType | null
    _sum: QuizSumAggregateOutputType | null
    _min: QuizMinAggregateOutputType | null
    _max: QuizMaxAggregateOutputType | null
  }

  export type QuizAvgAggregateOutputType = {
    pontos: number | null
  }

  export type QuizSumAggregateOutputType = {
    pontos: number | null
  }

  export type QuizMinAggregateOutputType = {
    id: string | null
    titulo: string | null
    descricao: string | null
    perguntasJson: string | null
    pontos: number | null
    publicado: boolean | null
    createdAt: Date | null
  }

  export type QuizMaxAggregateOutputType = {
    id: string | null
    titulo: string | null
    descricao: string | null
    perguntasJson: string | null
    pontos: number | null
    publicado: boolean | null
    createdAt: Date | null
  }

  export type QuizCountAggregateOutputType = {
    id: number
    titulo: number
    descricao: number
    perguntasJson: number
    pontos: number
    publicado: number
    createdAt: number
    _all: number
  }


  export type QuizAvgAggregateInputType = {
    pontos?: true
  }

  export type QuizSumAggregateInputType = {
    pontos?: true
  }

  export type QuizMinAggregateInputType = {
    id?: true
    titulo?: true
    descricao?: true
    perguntasJson?: true
    pontos?: true
    publicado?: true
    createdAt?: true
  }

  export type QuizMaxAggregateInputType = {
    id?: true
    titulo?: true
    descricao?: true
    perguntasJson?: true
    pontos?: true
    publicado?: true
    createdAt?: true
  }

  export type QuizCountAggregateInputType = {
    id?: true
    titulo?: true
    descricao?: true
    perguntasJson?: true
    pontos?: true
    publicado?: true
    createdAt?: true
    _all?: true
  }

  export type QuizAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which Quiz to aggregate.
     */
    where?: QuizWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Quizzes to fetch.
     */
    orderBy?: QuizOrderByWithRelationInput | QuizOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: QuizWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Quizzes 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` Quizzes.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned Quizzes
    **/
    _count?: true | QuizCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to average
    **/
    _avg?: QuizAvgAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to sum
    **/
    _sum?: QuizSumAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: QuizMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: QuizMaxAggregateInputType
  }

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




  export type QuizGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: QuizWhereInput
    orderBy?: QuizOrderByWithAggregationInput | QuizOrderByWithAggregationInput[]
    by: QuizScalarFieldEnum[] | QuizScalarFieldEnum
    having?: QuizScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: QuizCountAggregateInputType | true
    _avg?: QuizAvgAggregateInputType
    _sum?: QuizSumAggregateInputType
    _min?: QuizMinAggregateInputType
    _max?: QuizMaxAggregateInputType
  }

  export type QuizGroupByOutputType = {
    id: string
    titulo: string
    descricao: string | null
    perguntasJson: string
    pontos: number
    publicado: boolean
    createdAt: Date
    _count: QuizCountAggregateOutputType | null
    _avg: QuizAvgAggregateOutputType | null
    _sum: QuizSumAggregateOutputType | null
    _min: QuizMinAggregateOutputType | null
    _max: QuizMaxAggregateOutputType | null
  }

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


  export type QuizSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    titulo?: boolean
    descricao?: boolean
    perguntasJson?: boolean
    pontos?: boolean
    publicado?: boolean
    createdAt?: boolean
    attempts?: boolean | Quiz$attemptsArgs<ExtArgs>
    _count?: boolean | QuizCountOutputTypeDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["quiz"]>


  export type QuizSelectScalar = {
    id?: boolean
    titulo?: boolean
    descricao?: boolean
    perguntasJson?: boolean
    pontos?: boolean
    publicado?: boolean
    createdAt?: boolean
  }

  export type QuizInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    attempts?: boolean | Quiz$attemptsArgs<ExtArgs>
    _count?: boolean | QuizCountOutputTypeDefaultArgs<ExtArgs>
  }

  export type $QuizPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "Quiz"
    objects: {
      attempts: Prisma.$QuizAttemptPayload<ExtArgs>[]
    }
    scalars: $Extensions.GetPayloadResult<{
      id: string
      titulo: string
      descricao: string | null
      perguntasJson: string
      pontos: number
      publicado: boolean
      createdAt: Date
    }, ExtArgs["result"]["quiz"]>
    composites: {}
  }

  type QuizGetPayload<S extends boolean | null | undefined | QuizDefaultArgs> = $Result.GetResult<Prisma.$QuizPayload, S>

  type QuizCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = 
    Omit<QuizFindManyArgs, 'select' | 'include' | 'distinct'> & {
      select?: QuizCountAggregateInputType | true
    }

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

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

    /**
     * Find the first Quiz 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 {QuizFindFirstArgs} args - Arguments to find a Quiz
     * @example
     * // Get one Quiz
     * const quiz = await prisma.quiz.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends QuizFindFirstArgs>(args?: SelectSubset<T, QuizFindFirstArgs<ExtArgs>>): Prisma__QuizClient<$Result.GetResult<Prisma.$QuizPayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>

    /**
     * Find the first Quiz 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 {QuizFindFirstOrThrowArgs} args - Arguments to find a Quiz
     * @example
     * // Get one Quiz
     * const quiz = await prisma.quiz.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends QuizFindFirstOrThrowArgs>(args?: SelectSubset<T, QuizFindFirstOrThrowArgs<ExtArgs>>): Prisma__QuizClient<$Result.GetResult<Prisma.$QuizPayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>

    /**
     * Find zero or more Quizzes 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 {QuizFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all Quizzes
     * const quizzes = await prisma.quiz.findMany()
     * 
     * // Get first 10 Quizzes
     * const quizzes = await prisma.quiz.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const quizWithIdOnly = await prisma.quiz.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends QuizFindManyArgs>(args?: SelectSubset<T, QuizFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$QuizPayload<ExtArgs>, T, "findMany">>

    /**
     * Create a Quiz.
     * @param {QuizCreateArgs} args - Arguments to create a Quiz.
     * @example
     * // Create one Quiz
     * const Quiz = await prisma.quiz.create({
     *   data: {
     *     // ... data to create a Quiz
     *   }
     * })
     * 
     */
    create<T extends QuizCreateArgs>(args: SelectSubset<T, QuizCreateArgs<ExtArgs>>): Prisma__QuizClient<$Result.GetResult<Prisma.$QuizPayload<ExtArgs>, T, "create">, never, ExtArgs>

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

    /**
     * Delete a Quiz.
     * @param {QuizDeleteArgs} args - Arguments to delete one Quiz.
     * @example
     * // Delete one Quiz
     * const Quiz = await prisma.quiz.delete({
     *   where: {
     *     // ... filter to delete one Quiz
     *   }
     * })
     * 
     */
    delete<T extends QuizDeleteArgs>(args: SelectSubset<T, QuizDeleteArgs<ExtArgs>>): Prisma__QuizClient<$Result.GetResult<Prisma.$QuizPayload<ExtArgs>, T, "delete">, never, ExtArgs>

    /**
     * Update one Quiz.
     * @param {QuizUpdateArgs} args - Arguments to update one Quiz.
     * @example
     * // Update one Quiz
     * const quiz = await prisma.quiz.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends QuizUpdateArgs>(args: SelectSubset<T, QuizUpdateArgs<ExtArgs>>): Prisma__QuizClient<$Result.GetResult<Prisma.$QuizPayload<ExtArgs>, T, "update">, never, ExtArgs>

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

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

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


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

    /**
     * Allows you to perform aggregations operations on a Quiz.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {QuizAggregateArgs} 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 QuizAggregateArgs>(args: Subset<T, QuizAggregateArgs>): Prisma.PrismaPromise<GetQuizAggregateType<T>>

    /**
     * Group by Quiz.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {QuizGroupByArgs} 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 QuizGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: QuizGroupByArgs['orderBy'] }
        : { orderBy?: QuizGroupByArgs['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, QuizGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetQuizGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the Quiz model
   */
  readonly fields: QuizFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for Quiz.
   * 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__QuizClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
    readonly [Symbol.toStringTag]: "PrismaPromise"
    attempts<T extends Quiz$attemptsArgs<ExtArgs> = {}>(args?: Subset<T, Quiz$attemptsArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$QuizAttemptPayload<ExtArgs>, T, "findMany"> | 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 Quiz model
   */ 
  interface QuizFieldRefs {
    readonly id: FieldRef<"Quiz", 'String'>
    readonly titulo: FieldRef<"Quiz", 'String'>
    readonly descricao: FieldRef<"Quiz", 'String'>
    readonly perguntasJson: FieldRef<"Quiz", 'String'>
    readonly pontos: FieldRef<"Quiz", 'Int'>
    readonly publicado: FieldRef<"Quiz", 'Boolean'>
    readonly createdAt: FieldRef<"Quiz", 'DateTime'>
  }
    

  // Custom InputTypes
  /**
   * Quiz findUnique
   */
  export type QuizFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Quiz
     */
    select?: QuizSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: QuizInclude<ExtArgs> | null
    /**
     * Filter, which Quiz to fetch.
     */
    where: QuizWhereUniqueInput
  }

  /**
   * Quiz findUniqueOrThrow
   */
  export type QuizFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Quiz
     */
    select?: QuizSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: QuizInclude<ExtArgs> | null
    /**
     * Filter, which Quiz to fetch.
     */
    where: QuizWhereUniqueInput
  }

  /**
   * Quiz findFirst
   */
  export type QuizFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Quiz
     */
    select?: QuizSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: QuizInclude<ExtArgs> | null
    /**
     * Filter, which Quiz to fetch.
     */
    where?: QuizWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Quizzes to fetch.
     */
    orderBy?: QuizOrderByWithRelationInput | QuizOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for Quizzes.
     */
    cursor?: QuizWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Quizzes 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` Quizzes.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of Quizzes.
     */
    distinct?: QuizScalarFieldEnum | QuizScalarFieldEnum[]
  }

  /**
   * Quiz findFirstOrThrow
   */
  export type QuizFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Quiz
     */
    select?: QuizSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: QuizInclude<ExtArgs> | null
    /**
     * Filter, which Quiz to fetch.
     */
    where?: QuizWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Quizzes to fetch.
     */
    orderBy?: QuizOrderByWithRelationInput | QuizOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for Quizzes.
     */
    cursor?: QuizWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Quizzes 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` Quizzes.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of Quizzes.
     */
    distinct?: QuizScalarFieldEnum | QuizScalarFieldEnum[]
  }

  /**
   * Quiz findMany
   */
  export type QuizFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Quiz
     */
    select?: QuizSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: QuizInclude<ExtArgs> | null
    /**
     * Filter, which Quizzes to fetch.
     */
    where?: QuizWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Quizzes to fetch.
     */
    orderBy?: QuizOrderByWithRelationInput | QuizOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing Quizzes.
     */
    cursor?: QuizWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Quizzes 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` Quizzes.
     */
    skip?: number
    distinct?: QuizScalarFieldEnum | QuizScalarFieldEnum[]
  }

  /**
   * Quiz create
   */
  export type QuizCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Quiz
     */
    select?: QuizSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: QuizInclude<ExtArgs> | null
    /**
     * The data needed to create a Quiz.
     */
    data: XOR<QuizCreateInput, QuizUncheckedCreateInput>
  }

  /**
   * Quiz createMany
   */
  export type QuizCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many Quizzes.
     */
    data: QuizCreateManyInput | QuizCreateManyInput[]
    skipDuplicates?: boolean
  }

  /**
   * Quiz update
   */
  export type QuizUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Quiz
     */
    select?: QuizSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: QuizInclude<ExtArgs> | null
    /**
     * The data needed to update a Quiz.
     */
    data: XOR<QuizUpdateInput, QuizUncheckedUpdateInput>
    /**
     * Choose, which Quiz to update.
     */
    where: QuizWhereUniqueInput
  }

  /**
   * Quiz updateMany
   */
  export type QuizUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update Quizzes.
     */
    data: XOR<QuizUpdateManyMutationInput, QuizUncheckedUpdateManyInput>
    /**
     * Filter which Quizzes to update
     */
    where?: QuizWhereInput
  }

  /**
   * Quiz upsert
   */
  export type QuizUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Quiz
     */
    select?: QuizSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: QuizInclude<ExtArgs> | null
    /**
     * The filter to search for the Quiz to update in case it exists.
     */
    where: QuizWhereUniqueInput
    /**
     * In case the Quiz found by the `where` argument doesn't exist, create a new Quiz with this data.
     */
    create: XOR<QuizCreateInput, QuizUncheckedCreateInput>
    /**
     * In case the Quiz was found with the provided `where` argument, update it with this data.
     */
    update: XOR<QuizUpdateInput, QuizUncheckedUpdateInput>
  }

  /**
   * Quiz delete
   */
  export type QuizDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Quiz
     */
    select?: QuizSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: QuizInclude<ExtArgs> | null
    /**
     * Filter which Quiz to delete.
     */
    where: QuizWhereUniqueInput
  }

  /**
   * Quiz deleteMany
   */
  export type QuizDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which Quizzes to delete
     */
    where?: QuizWhereInput
  }

  /**
   * Quiz.attempts
   */
  export type Quiz$attemptsArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the QuizAttempt
     */
    select?: QuizAttemptSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: QuizAttemptInclude<ExtArgs> | null
    where?: QuizAttemptWhereInput
    orderBy?: QuizAttemptOrderByWithRelationInput | QuizAttemptOrderByWithRelationInput[]
    cursor?: QuizAttemptWhereUniqueInput
    take?: number
    skip?: number
    distinct?: QuizAttemptScalarFieldEnum | QuizAttemptScalarFieldEnum[]
  }

  /**
   * Quiz without action
   */
  export type QuizDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Quiz
     */
    select?: QuizSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: QuizInclude<ExtArgs> | null
  }


  /**
   * Model QuizAttempt
   */

  export type AggregateQuizAttempt = {
    _count: QuizAttemptCountAggregateOutputType | null
    _avg: QuizAttemptAvgAggregateOutputType | null
    _sum: QuizAttemptSumAggregateOutputType | null
    _min: QuizAttemptMinAggregateOutputType | null
    _max: QuizAttemptMaxAggregateOutputType | null
  }

  export type QuizAttemptAvgAggregateOutputType = {
    acertos: number | null
    total: number | null
    pontosGanhos: number | null
  }

  export type QuizAttemptSumAggregateOutputType = {
    acertos: number | null
    total: number | null
    pontosGanhos: number | null
  }

  export type QuizAttemptMinAggregateOutputType = {
    id: string | null
    userId: string | null
    quizId: string | null
    acertos: number | null
    total: number | null
    pontosGanhos: number | null
    respostasJson: string | null
    createdAt: Date | null
  }

  export type QuizAttemptMaxAggregateOutputType = {
    id: string | null
    userId: string | null
    quizId: string | null
    acertos: number | null
    total: number | null
    pontosGanhos: number | null
    respostasJson: string | null
    createdAt: Date | null
  }

  export type QuizAttemptCountAggregateOutputType = {
    id: number
    userId: number
    quizId: number
    acertos: number
    total: number
    pontosGanhos: number
    respostasJson: number
    createdAt: number
    _all: number
  }


  export type QuizAttemptAvgAggregateInputType = {
    acertos?: true
    total?: true
    pontosGanhos?: true
  }

  export type QuizAttemptSumAggregateInputType = {
    acertos?: true
    total?: true
    pontosGanhos?: true
  }

  export type QuizAttemptMinAggregateInputType = {
    id?: true
    userId?: true
    quizId?: true
    acertos?: true
    total?: true
    pontosGanhos?: true
    respostasJson?: true
    createdAt?: true
  }

  export type QuizAttemptMaxAggregateInputType = {
    id?: true
    userId?: true
    quizId?: true
    acertos?: true
    total?: true
    pontosGanhos?: true
    respostasJson?: true
    createdAt?: true
  }

  export type QuizAttemptCountAggregateInputType = {
    id?: true
    userId?: true
    quizId?: true
    acertos?: true
    total?: true
    pontosGanhos?: true
    respostasJson?: true
    createdAt?: true
    _all?: true
  }

  export type QuizAttemptAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which QuizAttempt to aggregate.
     */
    where?: QuizAttemptWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of QuizAttempts to fetch.
     */
    orderBy?: QuizAttemptOrderByWithRelationInput | QuizAttemptOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: QuizAttemptWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` QuizAttempts 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` QuizAttempts.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned QuizAttempts
    **/
    _count?: true | QuizAttemptCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to average
    **/
    _avg?: QuizAttemptAvgAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to sum
    **/
    _sum?: QuizAttemptSumAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: QuizAttemptMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: QuizAttemptMaxAggregateInputType
  }

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




  export type QuizAttemptGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: QuizAttemptWhereInput
    orderBy?: QuizAttemptOrderByWithAggregationInput | QuizAttemptOrderByWithAggregationInput[]
    by: QuizAttemptScalarFieldEnum[] | QuizAttemptScalarFieldEnum
    having?: QuizAttemptScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: QuizAttemptCountAggregateInputType | true
    _avg?: QuizAttemptAvgAggregateInputType
    _sum?: QuizAttemptSumAggregateInputType
    _min?: QuizAttemptMinAggregateInputType
    _max?: QuizAttemptMaxAggregateInputType
  }

  export type QuizAttemptGroupByOutputType = {
    id: string
    userId: string
    quizId: string
    acertos: number
    total: number
    pontosGanhos: number
    respostasJson: string | null
    createdAt: Date
    _count: QuizAttemptCountAggregateOutputType | null
    _avg: QuizAttemptAvgAggregateOutputType | null
    _sum: QuizAttemptSumAggregateOutputType | null
    _min: QuizAttemptMinAggregateOutputType | null
    _max: QuizAttemptMaxAggregateOutputType | null
  }

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


  export type QuizAttemptSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    userId?: boolean
    quizId?: boolean
    acertos?: boolean
    total?: boolean
    pontosGanhos?: boolean
    respostasJson?: boolean
    createdAt?: boolean
    user?: boolean | UserDefaultArgs<ExtArgs>
    quiz?: boolean | QuizDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["quizAttempt"]>


  export type QuizAttemptSelectScalar = {
    id?: boolean
    userId?: boolean
    quizId?: boolean
    acertos?: boolean
    total?: boolean
    pontosGanhos?: boolean
    respostasJson?: boolean
    createdAt?: boolean
  }

  export type QuizAttemptInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    user?: boolean | UserDefaultArgs<ExtArgs>
    quiz?: boolean | QuizDefaultArgs<ExtArgs>
  }

  export type $QuizAttemptPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "QuizAttempt"
    objects: {
      user: Prisma.$UserPayload<ExtArgs>
      quiz: Prisma.$QuizPayload<ExtArgs>
    }
    scalars: $Extensions.GetPayloadResult<{
      id: string
      userId: string
      quizId: string
      acertos: number
      total: number
      pontosGanhos: number
      respostasJson: string | null
      createdAt: Date
    }, ExtArgs["result"]["quizAttempt"]>
    composites: {}
  }

  type QuizAttemptGetPayload<S extends boolean | null | undefined | QuizAttemptDefaultArgs> = $Result.GetResult<Prisma.$QuizAttemptPayload, S>

  type QuizAttemptCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = 
    Omit<QuizAttemptFindManyArgs, 'select' | 'include' | 'distinct'> & {
      select?: QuizAttemptCountAggregateInputType | true
    }

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

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

    /**
     * Find the first QuizAttempt 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 {QuizAttemptFindFirstArgs} args - Arguments to find a QuizAttempt
     * @example
     * // Get one QuizAttempt
     * const quizAttempt = await prisma.quizAttempt.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends QuizAttemptFindFirstArgs>(args?: SelectSubset<T, QuizAttemptFindFirstArgs<ExtArgs>>): Prisma__QuizAttemptClient<$Result.GetResult<Prisma.$QuizAttemptPayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>

    /**
     * Find the first QuizAttempt 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 {QuizAttemptFindFirstOrThrowArgs} args - Arguments to find a QuizAttempt
     * @example
     * // Get one QuizAttempt
     * const quizAttempt = await prisma.quizAttempt.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends QuizAttemptFindFirstOrThrowArgs>(args?: SelectSubset<T, QuizAttemptFindFirstOrThrowArgs<ExtArgs>>): Prisma__QuizAttemptClient<$Result.GetResult<Prisma.$QuizAttemptPayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>

    /**
     * Find zero or more QuizAttempts 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 {QuizAttemptFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all QuizAttempts
     * const quizAttempts = await prisma.quizAttempt.findMany()
     * 
     * // Get first 10 QuizAttempts
     * const quizAttempts = await prisma.quizAttempt.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const quizAttemptWithIdOnly = await prisma.quizAttempt.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends QuizAttemptFindManyArgs>(args?: SelectSubset<T, QuizAttemptFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$QuizAttemptPayload<ExtArgs>, T, "findMany">>

    /**
     * Create a QuizAttempt.
     * @param {QuizAttemptCreateArgs} args - Arguments to create a QuizAttempt.
     * @example
     * // Create one QuizAttempt
     * const QuizAttempt = await prisma.quizAttempt.create({
     *   data: {
     *     // ... data to create a QuizAttempt
     *   }
     * })
     * 
     */
    create<T extends QuizAttemptCreateArgs>(args: SelectSubset<T, QuizAttemptCreateArgs<ExtArgs>>): Prisma__QuizAttemptClient<$Result.GetResult<Prisma.$QuizAttemptPayload<ExtArgs>, T, "create">, never, ExtArgs>

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

    /**
     * Delete a QuizAttempt.
     * @param {QuizAttemptDeleteArgs} args - Arguments to delete one QuizAttempt.
     * @example
     * // Delete one QuizAttempt
     * const QuizAttempt = await prisma.quizAttempt.delete({
     *   where: {
     *     // ... filter to delete one QuizAttempt
     *   }
     * })
     * 
     */
    delete<T extends QuizAttemptDeleteArgs>(args: SelectSubset<T, QuizAttemptDeleteArgs<ExtArgs>>): Prisma__QuizAttemptClient<$Result.GetResult<Prisma.$QuizAttemptPayload<ExtArgs>, T, "delete">, never, ExtArgs>

    /**
     * Update one QuizAttempt.
     * @param {QuizAttemptUpdateArgs} args - Arguments to update one QuizAttempt.
     * @example
     * // Update one QuizAttempt
     * const quizAttempt = await prisma.quizAttempt.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends QuizAttemptUpdateArgs>(args: SelectSubset<T, QuizAttemptUpdateArgs<ExtArgs>>): Prisma__QuizAttemptClient<$Result.GetResult<Prisma.$QuizAttemptPayload<ExtArgs>, T, "update">, never, ExtArgs>

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

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

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


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

    /**
     * Allows you to perform aggregations operations on a QuizAttempt.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {QuizAttemptAggregateArgs} 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 QuizAttemptAggregateArgs>(args: Subset<T, QuizAttemptAggregateArgs>): Prisma.PrismaPromise<GetQuizAttemptAggregateType<T>>

    /**
     * Group by QuizAttempt.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {QuizAttemptGroupByArgs} 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 QuizAttemptGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: QuizAttemptGroupByArgs['orderBy'] }
        : { orderBy?: QuizAttemptGroupByArgs['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, QuizAttemptGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetQuizAttemptGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the QuizAttempt model
   */
  readonly fields: QuizAttemptFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for QuizAttempt.
   * 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__QuizAttemptClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> 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"> | Null, Null, ExtArgs>
    quiz<T extends QuizDefaultArgs<ExtArgs> = {}>(args?: Subset<T, QuizDefaultArgs<ExtArgs>>): Prisma__QuizClient<$Result.GetResult<Prisma.$QuizPayload<ExtArgs>, T, "findUniqueOrThrow"> | Null, Null, ExtArgs>
    /**
     * 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 QuizAttempt model
   */ 
  interface QuizAttemptFieldRefs {
    readonly id: FieldRef<"QuizAttempt", 'String'>
    readonly userId: FieldRef<"QuizAttempt", 'String'>
    readonly quizId: FieldRef<"QuizAttempt", 'String'>
    readonly acertos: FieldRef<"QuizAttempt", 'Int'>
    readonly total: FieldRef<"QuizAttempt", 'Int'>
    readonly pontosGanhos: FieldRef<"QuizAttempt", 'Int'>
    readonly respostasJson: FieldRef<"QuizAttempt", 'String'>
    readonly createdAt: FieldRef<"QuizAttempt", 'DateTime'>
  }
    

  // Custom InputTypes
  /**
   * QuizAttempt findUnique
   */
  export type QuizAttemptFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the QuizAttempt
     */
    select?: QuizAttemptSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: QuizAttemptInclude<ExtArgs> | null
    /**
     * Filter, which QuizAttempt to fetch.
     */
    where: QuizAttemptWhereUniqueInput
  }

  /**
   * QuizAttempt findUniqueOrThrow
   */
  export type QuizAttemptFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the QuizAttempt
     */
    select?: QuizAttemptSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: QuizAttemptInclude<ExtArgs> | null
    /**
     * Filter, which QuizAttempt to fetch.
     */
    where: QuizAttemptWhereUniqueInput
  }

  /**
   * QuizAttempt findFirst
   */
  export type QuizAttemptFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the QuizAttempt
     */
    select?: QuizAttemptSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: QuizAttemptInclude<ExtArgs> | null
    /**
     * Filter, which QuizAttempt to fetch.
     */
    where?: QuizAttemptWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of QuizAttempts to fetch.
     */
    orderBy?: QuizAttemptOrderByWithRelationInput | QuizAttemptOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for QuizAttempts.
     */
    cursor?: QuizAttemptWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` QuizAttempts 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` QuizAttempts.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of QuizAttempts.
     */
    distinct?: QuizAttemptScalarFieldEnum | QuizAttemptScalarFieldEnum[]
  }

  /**
   * QuizAttempt findFirstOrThrow
   */
  export type QuizAttemptFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the QuizAttempt
     */
    select?: QuizAttemptSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: QuizAttemptInclude<ExtArgs> | null
    /**
     * Filter, which QuizAttempt to fetch.
     */
    where?: QuizAttemptWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of QuizAttempts to fetch.
     */
    orderBy?: QuizAttemptOrderByWithRelationInput | QuizAttemptOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for QuizAttempts.
     */
    cursor?: QuizAttemptWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` QuizAttempts 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` QuizAttempts.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of QuizAttempts.
     */
    distinct?: QuizAttemptScalarFieldEnum | QuizAttemptScalarFieldEnum[]
  }

  /**
   * QuizAttempt findMany
   */
  export type QuizAttemptFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the QuizAttempt
     */
    select?: QuizAttemptSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: QuizAttemptInclude<ExtArgs> | null
    /**
     * Filter, which QuizAttempts to fetch.
     */
    where?: QuizAttemptWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of QuizAttempts to fetch.
     */
    orderBy?: QuizAttemptOrderByWithRelationInput | QuizAttemptOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing QuizAttempts.
     */
    cursor?: QuizAttemptWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` QuizAttempts 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` QuizAttempts.
     */
    skip?: number
    distinct?: QuizAttemptScalarFieldEnum | QuizAttemptScalarFieldEnum[]
  }

  /**
   * QuizAttempt create
   */
  export type QuizAttemptCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the QuizAttempt
     */
    select?: QuizAttemptSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: QuizAttemptInclude<ExtArgs> | null
    /**
     * The data needed to create a QuizAttempt.
     */
    data: XOR<QuizAttemptCreateInput, QuizAttemptUncheckedCreateInput>
  }

  /**
   * QuizAttempt createMany
   */
  export type QuizAttemptCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many QuizAttempts.
     */
    data: QuizAttemptCreateManyInput | QuizAttemptCreateManyInput[]
    skipDuplicates?: boolean
  }

  /**
   * QuizAttempt update
   */
  export type QuizAttemptUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the QuizAttempt
     */
    select?: QuizAttemptSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: QuizAttemptInclude<ExtArgs> | null
    /**
     * The data needed to update a QuizAttempt.
     */
    data: XOR<QuizAttemptUpdateInput, QuizAttemptUncheckedUpdateInput>
    /**
     * Choose, which QuizAttempt to update.
     */
    where: QuizAttemptWhereUniqueInput
  }

  /**
   * QuizAttempt updateMany
   */
  export type QuizAttemptUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update QuizAttempts.
     */
    data: XOR<QuizAttemptUpdateManyMutationInput, QuizAttemptUncheckedUpdateManyInput>
    /**
     * Filter which QuizAttempts to update
     */
    where?: QuizAttemptWhereInput
  }

  /**
   * QuizAttempt upsert
   */
  export type QuizAttemptUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the QuizAttempt
     */
    select?: QuizAttemptSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: QuizAttemptInclude<ExtArgs> | null
    /**
     * The filter to search for the QuizAttempt to update in case it exists.
     */
    where: QuizAttemptWhereUniqueInput
    /**
     * In case the QuizAttempt found by the `where` argument doesn't exist, create a new QuizAttempt with this data.
     */
    create: XOR<QuizAttemptCreateInput, QuizAttemptUncheckedCreateInput>
    /**
     * In case the QuizAttempt was found with the provided `where` argument, update it with this data.
     */
    update: XOR<QuizAttemptUpdateInput, QuizAttemptUncheckedUpdateInput>
  }

  /**
   * QuizAttempt delete
   */
  export type QuizAttemptDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the QuizAttempt
     */
    select?: QuizAttemptSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: QuizAttemptInclude<ExtArgs> | null
    /**
     * Filter which QuizAttempt to delete.
     */
    where: QuizAttemptWhereUniqueInput
  }

  /**
   * QuizAttempt deleteMany
   */
  export type QuizAttemptDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which QuizAttempts to delete
     */
    where?: QuizAttemptWhereInput
  }

  /**
   * QuizAttempt without action
   */
  export type QuizAttemptDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the QuizAttempt
     */
    select?: QuizAttemptSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: QuizAttemptInclude<ExtArgs> | null
  }


  /**
   * Model Badge
   */

  export type AggregateBadge = {
    _count: BadgeCountAggregateOutputType | null
    _min: BadgeMinAggregateOutputType | null
    _max: BadgeMaxAggregateOutputType | null
  }

  export type BadgeMinAggregateOutputType = {
    id: string | null
    userId: string | null
    tipo: string | null
    titulo: string | null
    descricao: string | null
    createdAt: Date | null
  }

  export type BadgeMaxAggregateOutputType = {
    id: string | null
    userId: string | null
    tipo: string | null
    titulo: string | null
    descricao: string | null
    createdAt: Date | null
  }

  export type BadgeCountAggregateOutputType = {
    id: number
    userId: number
    tipo: number
    titulo: number
    descricao: number
    createdAt: number
    _all: number
  }


  export type BadgeMinAggregateInputType = {
    id?: true
    userId?: true
    tipo?: true
    titulo?: true
    descricao?: true
    createdAt?: true
  }

  export type BadgeMaxAggregateInputType = {
    id?: true
    userId?: true
    tipo?: true
    titulo?: true
    descricao?: true
    createdAt?: true
  }

  export type BadgeCountAggregateInputType = {
    id?: true
    userId?: true
    tipo?: true
    titulo?: true
    descricao?: true
    createdAt?: true
    _all?: true
  }

  export type BadgeAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which Badge to aggregate.
     */
    where?: BadgeWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Badges to fetch.
     */
    orderBy?: BadgeOrderByWithRelationInput | BadgeOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: BadgeWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Badges 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` Badges.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned Badges
    **/
    _count?: true | BadgeCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: BadgeMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: BadgeMaxAggregateInputType
  }

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




  export type BadgeGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: BadgeWhereInput
    orderBy?: BadgeOrderByWithAggregationInput | BadgeOrderByWithAggregationInput[]
    by: BadgeScalarFieldEnum[] | BadgeScalarFieldEnum
    having?: BadgeScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: BadgeCountAggregateInputType | true
    _min?: BadgeMinAggregateInputType
    _max?: BadgeMaxAggregateInputType
  }

  export type BadgeGroupByOutputType = {
    id: string
    userId: string
    tipo: string
    titulo: string
    descricao: string | null
    createdAt: Date
    _count: BadgeCountAggregateOutputType | null
    _min: BadgeMinAggregateOutputType | null
    _max: BadgeMaxAggregateOutputType | null
  }

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


  export type BadgeSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    userId?: boolean
    tipo?: boolean
    titulo?: boolean
    descricao?: boolean
    createdAt?: boolean
    user?: boolean | UserDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["badge"]>


  export type BadgeSelectScalar = {
    id?: boolean
    userId?: boolean
    tipo?: boolean
    titulo?: boolean
    descricao?: boolean
    createdAt?: boolean
  }

  export type BadgeInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    user?: boolean | UserDefaultArgs<ExtArgs>
  }

  export type $BadgePayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "Badge"
    objects: {
      user: Prisma.$UserPayload<ExtArgs>
    }
    scalars: $Extensions.GetPayloadResult<{
      id: string
      userId: string
      tipo: string
      titulo: string
      descricao: string | null
      createdAt: Date
    }, ExtArgs["result"]["badge"]>
    composites: {}
  }

  type BadgeGetPayload<S extends boolean | null | undefined | BadgeDefaultArgs> = $Result.GetResult<Prisma.$BadgePayload, S>

  type BadgeCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = 
    Omit<BadgeFindManyArgs, 'select' | 'include' | 'distinct'> & {
      select?: BadgeCountAggregateInputType | true
    }

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

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

    /**
     * Find the first Badge 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 {BadgeFindFirstArgs} args - Arguments to find a Badge
     * @example
     * // Get one Badge
     * const badge = await prisma.badge.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends BadgeFindFirstArgs>(args?: SelectSubset<T, BadgeFindFirstArgs<ExtArgs>>): Prisma__BadgeClient<$Result.GetResult<Prisma.$BadgePayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>

    /**
     * Find the first Badge 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 {BadgeFindFirstOrThrowArgs} args - Arguments to find a Badge
     * @example
     * // Get one Badge
     * const badge = await prisma.badge.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends BadgeFindFirstOrThrowArgs>(args?: SelectSubset<T, BadgeFindFirstOrThrowArgs<ExtArgs>>): Prisma__BadgeClient<$Result.GetResult<Prisma.$BadgePayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>

    /**
     * Find zero or more Badges 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 {BadgeFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all Badges
     * const badges = await prisma.badge.findMany()
     * 
     * // Get first 10 Badges
     * const badges = await prisma.badge.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const badgeWithIdOnly = await prisma.badge.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends BadgeFindManyArgs>(args?: SelectSubset<T, BadgeFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$BadgePayload<ExtArgs>, T, "findMany">>

    /**
     * Create a Badge.
     * @param {BadgeCreateArgs} args - Arguments to create a Badge.
     * @example
     * // Create one Badge
     * const Badge = await prisma.badge.create({
     *   data: {
     *     // ... data to create a Badge
     *   }
     * })
     * 
     */
    create<T extends BadgeCreateArgs>(args: SelectSubset<T, BadgeCreateArgs<ExtArgs>>): Prisma__BadgeClient<$Result.GetResult<Prisma.$BadgePayload<ExtArgs>, T, "create">, never, ExtArgs>

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

    /**
     * Delete a Badge.
     * @param {BadgeDeleteArgs} args - Arguments to delete one Badge.
     * @example
     * // Delete one Badge
     * const Badge = await prisma.badge.delete({
     *   where: {
     *     // ... filter to delete one Badge
     *   }
     * })
     * 
     */
    delete<T extends BadgeDeleteArgs>(args: SelectSubset<T, BadgeDeleteArgs<ExtArgs>>): Prisma__BadgeClient<$Result.GetResult<Prisma.$BadgePayload<ExtArgs>, T, "delete">, never, ExtArgs>

    /**
     * Update one Badge.
     * @param {BadgeUpdateArgs} args - Arguments to update one Badge.
     * @example
     * // Update one Badge
     * const badge = await prisma.badge.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends BadgeUpdateArgs>(args: SelectSubset<T, BadgeUpdateArgs<ExtArgs>>): Prisma__BadgeClient<$Result.GetResult<Prisma.$BadgePayload<ExtArgs>, T, "update">, never, ExtArgs>

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

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

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


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

    /**
     * Allows you to perform aggregations operations on a Badge.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {BadgeAggregateArgs} 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 BadgeAggregateArgs>(args: Subset<T, BadgeAggregateArgs>): Prisma.PrismaPromise<GetBadgeAggregateType<T>>

    /**
     * Group by Badge.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {BadgeGroupByArgs} 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 BadgeGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: BadgeGroupByArgs['orderBy'] }
        : { orderBy?: BadgeGroupByArgs['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, BadgeGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetBadgeGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the Badge model
   */
  readonly fields: BadgeFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for Badge.
   * 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__BadgeClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> 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"> | Null, Null, ExtArgs>
    /**
     * 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 Badge model
   */ 
  interface BadgeFieldRefs {
    readonly id: FieldRef<"Badge", 'String'>
    readonly userId: FieldRef<"Badge", 'String'>
    readonly tipo: FieldRef<"Badge", 'String'>
    readonly titulo: FieldRef<"Badge", 'String'>
    readonly descricao: FieldRef<"Badge", 'String'>
    readonly createdAt: FieldRef<"Badge", 'DateTime'>
  }
    

  // Custom InputTypes
  /**
   * Badge findUnique
   */
  export type BadgeFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Badge
     */
    select?: BadgeSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: BadgeInclude<ExtArgs> | null
    /**
     * Filter, which Badge to fetch.
     */
    where: BadgeWhereUniqueInput
  }

  /**
   * Badge findUniqueOrThrow
   */
  export type BadgeFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Badge
     */
    select?: BadgeSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: BadgeInclude<ExtArgs> | null
    /**
     * Filter, which Badge to fetch.
     */
    where: BadgeWhereUniqueInput
  }

  /**
   * Badge findFirst
   */
  export type BadgeFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Badge
     */
    select?: BadgeSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: BadgeInclude<ExtArgs> | null
    /**
     * Filter, which Badge to fetch.
     */
    where?: BadgeWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Badges to fetch.
     */
    orderBy?: BadgeOrderByWithRelationInput | BadgeOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for Badges.
     */
    cursor?: BadgeWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Badges 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` Badges.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of Badges.
     */
    distinct?: BadgeScalarFieldEnum | BadgeScalarFieldEnum[]
  }

  /**
   * Badge findFirstOrThrow
   */
  export type BadgeFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Badge
     */
    select?: BadgeSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: BadgeInclude<ExtArgs> | null
    /**
     * Filter, which Badge to fetch.
     */
    where?: BadgeWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Badges to fetch.
     */
    orderBy?: BadgeOrderByWithRelationInput | BadgeOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for Badges.
     */
    cursor?: BadgeWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Badges 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` Badges.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of Badges.
     */
    distinct?: BadgeScalarFieldEnum | BadgeScalarFieldEnum[]
  }

  /**
   * Badge findMany
   */
  export type BadgeFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Badge
     */
    select?: BadgeSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: BadgeInclude<ExtArgs> | null
    /**
     * Filter, which Badges to fetch.
     */
    where?: BadgeWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Badges to fetch.
     */
    orderBy?: BadgeOrderByWithRelationInput | BadgeOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing Badges.
     */
    cursor?: BadgeWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Badges 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` Badges.
     */
    skip?: number
    distinct?: BadgeScalarFieldEnum | BadgeScalarFieldEnum[]
  }

  /**
   * Badge create
   */
  export type BadgeCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Badge
     */
    select?: BadgeSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: BadgeInclude<ExtArgs> | null
    /**
     * The data needed to create a Badge.
     */
    data: XOR<BadgeCreateInput, BadgeUncheckedCreateInput>
  }

  /**
   * Badge createMany
   */
  export type BadgeCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many Badges.
     */
    data: BadgeCreateManyInput | BadgeCreateManyInput[]
    skipDuplicates?: boolean
  }

  /**
   * Badge update
   */
  export type BadgeUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Badge
     */
    select?: BadgeSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: BadgeInclude<ExtArgs> | null
    /**
     * The data needed to update a Badge.
     */
    data: XOR<BadgeUpdateInput, BadgeUncheckedUpdateInput>
    /**
     * Choose, which Badge to update.
     */
    where: BadgeWhereUniqueInput
  }

  /**
   * Badge updateMany
   */
  export type BadgeUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update Badges.
     */
    data: XOR<BadgeUpdateManyMutationInput, BadgeUncheckedUpdateManyInput>
    /**
     * Filter which Badges to update
     */
    where?: BadgeWhereInput
  }

  /**
   * Badge upsert
   */
  export type BadgeUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Badge
     */
    select?: BadgeSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: BadgeInclude<ExtArgs> | null
    /**
     * The filter to search for the Badge to update in case it exists.
     */
    where: BadgeWhereUniqueInput
    /**
     * In case the Badge found by the `where` argument doesn't exist, create a new Badge with this data.
     */
    create: XOR<BadgeCreateInput, BadgeUncheckedCreateInput>
    /**
     * In case the Badge was found with the provided `where` argument, update it with this data.
     */
    update: XOR<BadgeUpdateInput, BadgeUncheckedUpdateInput>
  }

  /**
   * Badge delete
   */
  export type BadgeDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Badge
     */
    select?: BadgeSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: BadgeInclude<ExtArgs> | null
    /**
     * Filter which Badge to delete.
     */
    where: BadgeWhereUniqueInput
  }

  /**
   * Badge deleteMany
   */
  export type BadgeDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which Badges to delete
     */
    where?: BadgeWhereInput
  }

  /**
   * Badge without action
   */
  export type BadgeDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Badge
     */
    select?: BadgeSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: BadgeInclude<ExtArgs> | null
  }


  /**
   * Model ApiKey
   */

  export type AggregateApiKey = {
    _count: ApiKeyCountAggregateOutputType | null
    _avg: ApiKeyAvgAggregateOutputType | null
    _sum: ApiKeySumAggregateOutputType | null
    _min: ApiKeyMinAggregateOutputType | null
    _max: ApiKeyMaxAggregateOutputType | null
  }

  export type ApiKeyAvgAggregateOutputType = {
    rateLimit: number | null
    usos: number | null
  }

  export type ApiKeySumAggregateOutputType = {
    rateLimit: number | null
    usos: number | null
  }

  export type ApiKeyMinAggregateOutputType = {
    id: string | null
    nome: string | null
    partnerNome: string | null
    chave: string | null
    scopes: string | null
    status: string | null
    rateLimit: number | null
    createdAt: Date | null
    ultimoUso: Date | null
    usos: number | null
  }

  export type ApiKeyMaxAggregateOutputType = {
    id: string | null
    nome: string | null
    partnerNome: string | null
    chave: string | null
    scopes: string | null
    status: string | null
    rateLimit: number | null
    createdAt: Date | null
    ultimoUso: Date | null
    usos: number | null
  }

  export type ApiKeyCountAggregateOutputType = {
    id: number
    nome: number
    partnerNome: number
    chave: number
    scopes: number
    status: number
    rateLimit: number
    createdAt: number
    ultimoUso: number
    usos: number
    _all: number
  }


  export type ApiKeyAvgAggregateInputType = {
    rateLimit?: true
    usos?: true
  }

  export type ApiKeySumAggregateInputType = {
    rateLimit?: true
    usos?: true
  }

  export type ApiKeyMinAggregateInputType = {
    id?: true
    nome?: true
    partnerNome?: true
    chave?: true
    scopes?: true
    status?: true
    rateLimit?: true
    createdAt?: true
    ultimoUso?: true
    usos?: true
  }

  export type ApiKeyMaxAggregateInputType = {
    id?: true
    nome?: true
    partnerNome?: true
    chave?: true
    scopes?: true
    status?: true
    rateLimit?: true
    createdAt?: true
    ultimoUso?: true
    usos?: true
  }

  export type ApiKeyCountAggregateInputType = {
    id?: true
    nome?: true
    partnerNome?: true
    chave?: true
    scopes?: true
    status?: true
    rateLimit?: true
    createdAt?: true
    ultimoUso?: true
    usos?: true
    _all?: true
  }

  export type ApiKeyAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which ApiKey to aggregate.
     */
    where?: ApiKeyWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of ApiKeys to fetch.
     */
    orderBy?: ApiKeyOrderByWithRelationInput | ApiKeyOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: ApiKeyWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` ApiKeys 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` ApiKeys.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned ApiKeys
    **/
    _count?: true | ApiKeyCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to average
    **/
    _avg?: ApiKeyAvgAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to sum
    **/
    _sum?: ApiKeySumAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: ApiKeyMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: ApiKeyMaxAggregateInputType
  }

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




  export type ApiKeyGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: ApiKeyWhereInput
    orderBy?: ApiKeyOrderByWithAggregationInput | ApiKeyOrderByWithAggregationInput[]
    by: ApiKeyScalarFieldEnum[] | ApiKeyScalarFieldEnum
    having?: ApiKeyScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: ApiKeyCountAggregateInputType | true
    _avg?: ApiKeyAvgAggregateInputType
    _sum?: ApiKeySumAggregateInputType
    _min?: ApiKeyMinAggregateInputType
    _max?: ApiKeyMaxAggregateInputType
  }

  export type ApiKeyGroupByOutputType = {
    id: string
    nome: string
    partnerNome: string
    chave: string
    scopes: string
    status: string
    rateLimit: number
    createdAt: Date
    ultimoUso: Date | null
    usos: number
    _count: ApiKeyCountAggregateOutputType | null
    _avg: ApiKeyAvgAggregateOutputType | null
    _sum: ApiKeySumAggregateOutputType | null
    _min: ApiKeyMinAggregateOutputType | null
    _max: ApiKeyMaxAggregateOutputType | null
  }

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


  export type ApiKeySelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    nome?: boolean
    partnerNome?: boolean
    chave?: boolean
    scopes?: boolean
    status?: boolean
    rateLimit?: boolean
    createdAt?: boolean
    ultimoUso?: boolean
    usos?: boolean
    chamadas?: boolean | ApiKey$chamadasArgs<ExtArgs>
    _count?: boolean | ApiKeyCountOutputTypeDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["apiKey"]>


  export type ApiKeySelectScalar = {
    id?: boolean
    nome?: boolean
    partnerNome?: boolean
    chave?: boolean
    scopes?: boolean
    status?: boolean
    rateLimit?: boolean
    createdAt?: boolean
    ultimoUso?: boolean
    usos?: boolean
  }

  export type ApiKeyInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    chamadas?: boolean | ApiKey$chamadasArgs<ExtArgs>
    _count?: boolean | ApiKeyCountOutputTypeDefaultArgs<ExtArgs>
  }

  export type $ApiKeyPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "ApiKey"
    objects: {
      chamadas: Prisma.$ApiCallPayload<ExtArgs>[]
    }
    scalars: $Extensions.GetPayloadResult<{
      id: string
      nome: string
      partnerNome: string
      chave: string
      scopes: string
      status: string
      rateLimit: number
      createdAt: Date
      ultimoUso: Date | null
      usos: number
    }, ExtArgs["result"]["apiKey"]>
    composites: {}
  }

  type ApiKeyGetPayload<S extends boolean | null | undefined | ApiKeyDefaultArgs> = $Result.GetResult<Prisma.$ApiKeyPayload, S>

  type ApiKeyCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = 
    Omit<ApiKeyFindManyArgs, 'select' | 'include' | 'distinct'> & {
      select?: ApiKeyCountAggregateInputType | true
    }

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

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

    /**
     * Find the first ApiKey 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 {ApiKeyFindFirstArgs} args - Arguments to find a ApiKey
     * @example
     * // Get one ApiKey
     * const apiKey = await prisma.apiKey.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends ApiKeyFindFirstArgs>(args?: SelectSubset<T, ApiKeyFindFirstArgs<ExtArgs>>): Prisma__ApiKeyClient<$Result.GetResult<Prisma.$ApiKeyPayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>

    /**
     * Find the first ApiKey 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 {ApiKeyFindFirstOrThrowArgs} args - Arguments to find a ApiKey
     * @example
     * // Get one ApiKey
     * const apiKey = await prisma.apiKey.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends ApiKeyFindFirstOrThrowArgs>(args?: SelectSubset<T, ApiKeyFindFirstOrThrowArgs<ExtArgs>>): Prisma__ApiKeyClient<$Result.GetResult<Prisma.$ApiKeyPayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>

    /**
     * Find zero or more ApiKeys 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 {ApiKeyFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all ApiKeys
     * const apiKeys = await prisma.apiKey.findMany()
     * 
     * // Get first 10 ApiKeys
     * const apiKeys = await prisma.apiKey.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const apiKeyWithIdOnly = await prisma.apiKey.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends ApiKeyFindManyArgs>(args?: SelectSubset<T, ApiKeyFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$ApiKeyPayload<ExtArgs>, T, "findMany">>

    /**
     * Create a ApiKey.
     * @param {ApiKeyCreateArgs} args - Arguments to create a ApiKey.
     * @example
     * // Create one ApiKey
     * const ApiKey = await prisma.apiKey.create({
     *   data: {
     *     // ... data to create a ApiKey
     *   }
     * })
     * 
     */
    create<T extends ApiKeyCreateArgs>(args: SelectSubset<T, ApiKeyCreateArgs<ExtArgs>>): Prisma__ApiKeyClient<$Result.GetResult<Prisma.$ApiKeyPayload<ExtArgs>, T, "create">, never, ExtArgs>

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

    /**
     * Delete a ApiKey.
     * @param {ApiKeyDeleteArgs} args - Arguments to delete one ApiKey.
     * @example
     * // Delete one ApiKey
     * const ApiKey = await prisma.apiKey.delete({
     *   where: {
     *     // ... filter to delete one ApiKey
     *   }
     * })
     * 
     */
    delete<T extends ApiKeyDeleteArgs>(args: SelectSubset<T, ApiKeyDeleteArgs<ExtArgs>>): Prisma__ApiKeyClient<$Result.GetResult<Prisma.$ApiKeyPayload<ExtArgs>, T, "delete">, never, ExtArgs>

    /**
     * Update one ApiKey.
     * @param {ApiKeyUpdateArgs} args - Arguments to update one ApiKey.
     * @example
     * // Update one ApiKey
     * const apiKey = await prisma.apiKey.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends ApiKeyUpdateArgs>(args: SelectSubset<T, ApiKeyUpdateArgs<ExtArgs>>): Prisma__ApiKeyClient<$Result.GetResult<Prisma.$ApiKeyPayload<ExtArgs>, T, "update">, never, ExtArgs>

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

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

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


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

    /**
     * Allows you to perform aggregations operations on a ApiKey.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {ApiKeyAggregateArgs} 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 ApiKeyAggregateArgs>(args: Subset<T, ApiKeyAggregateArgs>): Prisma.PrismaPromise<GetApiKeyAggregateType<T>>

    /**
     * Group by ApiKey.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {ApiKeyGroupByArgs} 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 ApiKeyGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: ApiKeyGroupByArgs['orderBy'] }
        : { orderBy?: ApiKeyGroupByArgs['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, ApiKeyGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetApiKeyGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the ApiKey model
   */
  readonly fields: ApiKeyFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for ApiKey.
   * 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__ApiKeyClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
    readonly [Symbol.toStringTag]: "PrismaPromise"
    chamadas<T extends ApiKey$chamadasArgs<ExtArgs> = {}>(args?: Subset<T, ApiKey$chamadasArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$ApiCallPayload<ExtArgs>, T, "findMany"> | 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 ApiKey model
   */ 
  interface ApiKeyFieldRefs {
    readonly id: FieldRef<"ApiKey", 'String'>
    readonly nome: FieldRef<"ApiKey", 'String'>
    readonly partnerNome: FieldRef<"ApiKey", 'String'>
    readonly chave: FieldRef<"ApiKey", 'String'>
    readonly scopes: FieldRef<"ApiKey", 'String'>
    readonly status: FieldRef<"ApiKey", 'String'>
    readonly rateLimit: FieldRef<"ApiKey", 'Int'>
    readonly createdAt: FieldRef<"ApiKey", 'DateTime'>
    readonly ultimoUso: FieldRef<"ApiKey", 'DateTime'>
    readonly usos: FieldRef<"ApiKey", 'Int'>
  }
    

  // Custom InputTypes
  /**
   * ApiKey findUnique
   */
  export type ApiKeyFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ApiKey
     */
    select?: ApiKeySelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ApiKeyInclude<ExtArgs> | null
    /**
     * Filter, which ApiKey to fetch.
     */
    where: ApiKeyWhereUniqueInput
  }

  /**
   * ApiKey findUniqueOrThrow
   */
  export type ApiKeyFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ApiKey
     */
    select?: ApiKeySelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ApiKeyInclude<ExtArgs> | null
    /**
     * Filter, which ApiKey to fetch.
     */
    where: ApiKeyWhereUniqueInput
  }

  /**
   * ApiKey findFirst
   */
  export type ApiKeyFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ApiKey
     */
    select?: ApiKeySelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ApiKeyInclude<ExtArgs> | null
    /**
     * Filter, which ApiKey to fetch.
     */
    where?: ApiKeyWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of ApiKeys to fetch.
     */
    orderBy?: ApiKeyOrderByWithRelationInput | ApiKeyOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for ApiKeys.
     */
    cursor?: ApiKeyWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` ApiKeys 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` ApiKeys.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of ApiKeys.
     */
    distinct?: ApiKeyScalarFieldEnum | ApiKeyScalarFieldEnum[]
  }

  /**
   * ApiKey findFirstOrThrow
   */
  export type ApiKeyFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ApiKey
     */
    select?: ApiKeySelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ApiKeyInclude<ExtArgs> | null
    /**
     * Filter, which ApiKey to fetch.
     */
    where?: ApiKeyWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of ApiKeys to fetch.
     */
    orderBy?: ApiKeyOrderByWithRelationInput | ApiKeyOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for ApiKeys.
     */
    cursor?: ApiKeyWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` ApiKeys 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` ApiKeys.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of ApiKeys.
     */
    distinct?: ApiKeyScalarFieldEnum | ApiKeyScalarFieldEnum[]
  }

  /**
   * ApiKey findMany
   */
  export type ApiKeyFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ApiKey
     */
    select?: ApiKeySelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ApiKeyInclude<ExtArgs> | null
    /**
     * Filter, which ApiKeys to fetch.
     */
    where?: ApiKeyWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of ApiKeys to fetch.
     */
    orderBy?: ApiKeyOrderByWithRelationInput | ApiKeyOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing ApiKeys.
     */
    cursor?: ApiKeyWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` ApiKeys 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` ApiKeys.
     */
    skip?: number
    distinct?: ApiKeyScalarFieldEnum | ApiKeyScalarFieldEnum[]
  }

  /**
   * ApiKey create
   */
  export type ApiKeyCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ApiKey
     */
    select?: ApiKeySelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ApiKeyInclude<ExtArgs> | null
    /**
     * The data needed to create a ApiKey.
     */
    data: XOR<ApiKeyCreateInput, ApiKeyUncheckedCreateInput>
  }

  /**
   * ApiKey createMany
   */
  export type ApiKeyCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many ApiKeys.
     */
    data: ApiKeyCreateManyInput | ApiKeyCreateManyInput[]
    skipDuplicates?: boolean
  }

  /**
   * ApiKey update
   */
  export type ApiKeyUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ApiKey
     */
    select?: ApiKeySelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ApiKeyInclude<ExtArgs> | null
    /**
     * The data needed to update a ApiKey.
     */
    data: XOR<ApiKeyUpdateInput, ApiKeyUncheckedUpdateInput>
    /**
     * Choose, which ApiKey to update.
     */
    where: ApiKeyWhereUniqueInput
  }

  /**
   * ApiKey updateMany
   */
  export type ApiKeyUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update ApiKeys.
     */
    data: XOR<ApiKeyUpdateManyMutationInput, ApiKeyUncheckedUpdateManyInput>
    /**
     * Filter which ApiKeys to update
     */
    where?: ApiKeyWhereInput
  }

  /**
   * ApiKey upsert
   */
  export type ApiKeyUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ApiKey
     */
    select?: ApiKeySelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ApiKeyInclude<ExtArgs> | null
    /**
     * The filter to search for the ApiKey to update in case it exists.
     */
    where: ApiKeyWhereUniqueInput
    /**
     * In case the ApiKey found by the `where` argument doesn't exist, create a new ApiKey with this data.
     */
    create: XOR<ApiKeyCreateInput, ApiKeyUncheckedCreateInput>
    /**
     * In case the ApiKey was found with the provided `where` argument, update it with this data.
     */
    update: XOR<ApiKeyUpdateInput, ApiKeyUncheckedUpdateInput>
  }

  /**
   * ApiKey delete
   */
  export type ApiKeyDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ApiKey
     */
    select?: ApiKeySelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ApiKeyInclude<ExtArgs> | null
    /**
     * Filter which ApiKey to delete.
     */
    where: ApiKeyWhereUniqueInput
  }

  /**
   * ApiKey deleteMany
   */
  export type ApiKeyDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which ApiKeys to delete
     */
    where?: ApiKeyWhereInput
  }

  /**
   * ApiKey.chamadas
   */
  export type ApiKey$chamadasArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ApiCall
     */
    select?: ApiCallSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ApiCallInclude<ExtArgs> | null
    where?: ApiCallWhereInput
    orderBy?: ApiCallOrderByWithRelationInput | ApiCallOrderByWithRelationInput[]
    cursor?: ApiCallWhereUniqueInput
    take?: number
    skip?: number
    distinct?: ApiCallScalarFieldEnum | ApiCallScalarFieldEnum[]
  }

  /**
   * ApiKey without action
   */
  export type ApiKeyDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ApiKey
     */
    select?: ApiKeySelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ApiKeyInclude<ExtArgs> | null
  }


  /**
   * Model ApiCall
   */

  export type AggregateApiCall = {
    _count: ApiCallCountAggregateOutputType | null
    _avg: ApiCallAvgAggregateOutputType | null
    _sum: ApiCallSumAggregateOutputType | null
    _min: ApiCallMinAggregateOutputType | null
    _max: ApiCallMaxAggregateOutputType | null
  }

  export type ApiCallAvgAggregateOutputType = {
    status: number | null
    duracaoMs: number | null
  }

  export type ApiCallSumAggregateOutputType = {
    status: number | null
    duracaoMs: number | null
  }

  export type ApiCallMinAggregateOutputType = {
    id: string | null
    apiKeyId: string | null
    endpoint: string | null
    metodo: string | null
    status: number | null
    duracaoMs: number | null
    ip: string | null
    timestamp: Date | null
  }

  export type ApiCallMaxAggregateOutputType = {
    id: string | null
    apiKeyId: string | null
    endpoint: string | null
    metodo: string | null
    status: number | null
    duracaoMs: number | null
    ip: string | null
    timestamp: Date | null
  }

  export type ApiCallCountAggregateOutputType = {
    id: number
    apiKeyId: number
    endpoint: number
    metodo: number
    status: number
    duracaoMs: number
    ip: number
    timestamp: number
    _all: number
  }


  export type ApiCallAvgAggregateInputType = {
    status?: true
    duracaoMs?: true
  }

  export type ApiCallSumAggregateInputType = {
    status?: true
    duracaoMs?: true
  }

  export type ApiCallMinAggregateInputType = {
    id?: true
    apiKeyId?: true
    endpoint?: true
    metodo?: true
    status?: true
    duracaoMs?: true
    ip?: true
    timestamp?: true
  }

  export type ApiCallMaxAggregateInputType = {
    id?: true
    apiKeyId?: true
    endpoint?: true
    metodo?: true
    status?: true
    duracaoMs?: true
    ip?: true
    timestamp?: true
  }

  export type ApiCallCountAggregateInputType = {
    id?: true
    apiKeyId?: true
    endpoint?: true
    metodo?: true
    status?: true
    duracaoMs?: true
    ip?: true
    timestamp?: true
    _all?: true
  }

  export type ApiCallAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which ApiCall to aggregate.
     */
    where?: ApiCallWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of ApiCalls to fetch.
     */
    orderBy?: ApiCallOrderByWithRelationInput | ApiCallOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: ApiCallWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` ApiCalls 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` ApiCalls.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned ApiCalls
    **/
    _count?: true | ApiCallCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to average
    **/
    _avg?: ApiCallAvgAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to sum
    **/
    _sum?: ApiCallSumAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: ApiCallMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: ApiCallMaxAggregateInputType
  }

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




  export type ApiCallGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: ApiCallWhereInput
    orderBy?: ApiCallOrderByWithAggregationInput | ApiCallOrderByWithAggregationInput[]
    by: ApiCallScalarFieldEnum[] | ApiCallScalarFieldEnum
    having?: ApiCallScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: ApiCallCountAggregateInputType | true
    _avg?: ApiCallAvgAggregateInputType
    _sum?: ApiCallSumAggregateInputType
    _min?: ApiCallMinAggregateInputType
    _max?: ApiCallMaxAggregateInputType
  }

  export type ApiCallGroupByOutputType = {
    id: string
    apiKeyId: string
    endpoint: string
    metodo: string
    status: number
    duracaoMs: number
    ip: string | null
    timestamp: Date
    _count: ApiCallCountAggregateOutputType | null
    _avg: ApiCallAvgAggregateOutputType | null
    _sum: ApiCallSumAggregateOutputType | null
    _min: ApiCallMinAggregateOutputType | null
    _max: ApiCallMaxAggregateOutputType | null
  }

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


  export type ApiCallSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    apiKeyId?: boolean
    endpoint?: boolean
    metodo?: boolean
    status?: boolean
    duracaoMs?: boolean
    ip?: boolean
    timestamp?: boolean
    apiKey?: boolean | ApiKeyDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["apiCall"]>


  export type ApiCallSelectScalar = {
    id?: boolean
    apiKeyId?: boolean
    endpoint?: boolean
    metodo?: boolean
    status?: boolean
    duracaoMs?: boolean
    ip?: boolean
    timestamp?: boolean
  }

  export type ApiCallInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    apiKey?: boolean | ApiKeyDefaultArgs<ExtArgs>
  }

  export type $ApiCallPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "ApiCall"
    objects: {
      apiKey: Prisma.$ApiKeyPayload<ExtArgs>
    }
    scalars: $Extensions.GetPayloadResult<{
      id: string
      apiKeyId: string
      endpoint: string
      metodo: string
      status: number
      duracaoMs: number
      ip: string | null
      timestamp: Date
    }, ExtArgs["result"]["apiCall"]>
    composites: {}
  }

  type ApiCallGetPayload<S extends boolean | null | undefined | ApiCallDefaultArgs> = $Result.GetResult<Prisma.$ApiCallPayload, S>

  type ApiCallCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = 
    Omit<ApiCallFindManyArgs, 'select' | 'include' | 'distinct'> & {
      select?: ApiCallCountAggregateInputType | true
    }

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

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

    /**
     * Find the first ApiCall 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 {ApiCallFindFirstArgs} args - Arguments to find a ApiCall
     * @example
     * // Get one ApiCall
     * const apiCall = await prisma.apiCall.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends ApiCallFindFirstArgs>(args?: SelectSubset<T, ApiCallFindFirstArgs<ExtArgs>>): Prisma__ApiCallClient<$Result.GetResult<Prisma.$ApiCallPayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>

    /**
     * Find the first ApiCall 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 {ApiCallFindFirstOrThrowArgs} args - Arguments to find a ApiCall
     * @example
     * // Get one ApiCall
     * const apiCall = await prisma.apiCall.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends ApiCallFindFirstOrThrowArgs>(args?: SelectSubset<T, ApiCallFindFirstOrThrowArgs<ExtArgs>>): Prisma__ApiCallClient<$Result.GetResult<Prisma.$ApiCallPayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>

    /**
     * Find zero or more ApiCalls 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 {ApiCallFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all ApiCalls
     * const apiCalls = await prisma.apiCall.findMany()
     * 
     * // Get first 10 ApiCalls
     * const apiCalls = await prisma.apiCall.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const apiCallWithIdOnly = await prisma.apiCall.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends ApiCallFindManyArgs>(args?: SelectSubset<T, ApiCallFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$ApiCallPayload<ExtArgs>, T, "findMany">>

    /**
     * Create a ApiCall.
     * @param {ApiCallCreateArgs} args - Arguments to create a ApiCall.
     * @example
     * // Create one ApiCall
     * const ApiCall = await prisma.apiCall.create({
     *   data: {
     *     // ... data to create a ApiCall
     *   }
     * })
     * 
     */
    create<T extends ApiCallCreateArgs>(args: SelectSubset<T, ApiCallCreateArgs<ExtArgs>>): Prisma__ApiCallClient<$Result.GetResult<Prisma.$ApiCallPayload<ExtArgs>, T, "create">, never, ExtArgs>

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

    /**
     * Delete a ApiCall.
     * @param {ApiCallDeleteArgs} args - Arguments to delete one ApiCall.
     * @example
     * // Delete one ApiCall
     * const ApiCall = await prisma.apiCall.delete({
     *   where: {
     *     // ... filter to delete one ApiCall
     *   }
     * })
     * 
     */
    delete<T extends ApiCallDeleteArgs>(args: SelectSubset<T, ApiCallDeleteArgs<ExtArgs>>): Prisma__ApiCallClient<$Result.GetResult<Prisma.$ApiCallPayload<ExtArgs>, T, "delete">, never, ExtArgs>

    /**
     * Update one ApiCall.
     * @param {ApiCallUpdateArgs} args - Arguments to update one ApiCall.
     * @example
     * // Update one ApiCall
     * const apiCall = await prisma.apiCall.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends ApiCallUpdateArgs>(args: SelectSubset<T, ApiCallUpdateArgs<ExtArgs>>): Prisma__ApiCallClient<$Result.GetResult<Prisma.$ApiCallPayload<ExtArgs>, T, "update">, never, ExtArgs>

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

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

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


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

    /**
     * Allows you to perform aggregations operations on a ApiCall.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {ApiCallAggregateArgs} 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 ApiCallAggregateArgs>(args: Subset<T, ApiCallAggregateArgs>): Prisma.PrismaPromise<GetApiCallAggregateType<T>>

    /**
     * Group by ApiCall.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {ApiCallGroupByArgs} 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 ApiCallGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: ApiCallGroupByArgs['orderBy'] }
        : { orderBy?: ApiCallGroupByArgs['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, ApiCallGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetApiCallGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the ApiCall model
   */
  readonly fields: ApiCallFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for ApiCall.
   * 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__ApiCallClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
    readonly [Symbol.toStringTag]: "PrismaPromise"
    apiKey<T extends ApiKeyDefaultArgs<ExtArgs> = {}>(args?: Subset<T, ApiKeyDefaultArgs<ExtArgs>>): Prisma__ApiKeyClient<$Result.GetResult<Prisma.$ApiKeyPayload<ExtArgs>, T, "findUniqueOrThrow"> | Null, Null, ExtArgs>
    /**
     * 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 ApiCall model
   */ 
  interface ApiCallFieldRefs {
    readonly id: FieldRef<"ApiCall", 'String'>
    readonly apiKeyId: FieldRef<"ApiCall", 'String'>
    readonly endpoint: FieldRef<"ApiCall", 'String'>
    readonly metodo: FieldRef<"ApiCall", 'String'>
    readonly status: FieldRef<"ApiCall", 'Int'>
    readonly duracaoMs: FieldRef<"ApiCall", 'Int'>
    readonly ip: FieldRef<"ApiCall", 'String'>
    readonly timestamp: FieldRef<"ApiCall", 'DateTime'>
  }
    

  // Custom InputTypes
  /**
   * ApiCall findUnique
   */
  export type ApiCallFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ApiCall
     */
    select?: ApiCallSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ApiCallInclude<ExtArgs> | null
    /**
     * Filter, which ApiCall to fetch.
     */
    where: ApiCallWhereUniqueInput
  }

  /**
   * ApiCall findUniqueOrThrow
   */
  export type ApiCallFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ApiCall
     */
    select?: ApiCallSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ApiCallInclude<ExtArgs> | null
    /**
     * Filter, which ApiCall to fetch.
     */
    where: ApiCallWhereUniqueInput
  }

  /**
   * ApiCall findFirst
   */
  export type ApiCallFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ApiCall
     */
    select?: ApiCallSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ApiCallInclude<ExtArgs> | null
    /**
     * Filter, which ApiCall to fetch.
     */
    where?: ApiCallWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of ApiCalls to fetch.
     */
    orderBy?: ApiCallOrderByWithRelationInput | ApiCallOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for ApiCalls.
     */
    cursor?: ApiCallWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` ApiCalls 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` ApiCalls.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of ApiCalls.
     */
    distinct?: ApiCallScalarFieldEnum | ApiCallScalarFieldEnum[]
  }

  /**
   * ApiCall findFirstOrThrow
   */
  export type ApiCallFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ApiCall
     */
    select?: ApiCallSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ApiCallInclude<ExtArgs> | null
    /**
     * Filter, which ApiCall to fetch.
     */
    where?: ApiCallWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of ApiCalls to fetch.
     */
    orderBy?: ApiCallOrderByWithRelationInput | ApiCallOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for ApiCalls.
     */
    cursor?: ApiCallWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` ApiCalls 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` ApiCalls.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of ApiCalls.
     */
    distinct?: ApiCallScalarFieldEnum | ApiCallScalarFieldEnum[]
  }

  /**
   * ApiCall findMany
   */
  export type ApiCallFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ApiCall
     */
    select?: ApiCallSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ApiCallInclude<ExtArgs> | null
    /**
     * Filter, which ApiCalls to fetch.
     */
    where?: ApiCallWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of ApiCalls to fetch.
     */
    orderBy?: ApiCallOrderByWithRelationInput | ApiCallOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing ApiCalls.
     */
    cursor?: ApiCallWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` ApiCalls 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` ApiCalls.
     */
    skip?: number
    distinct?: ApiCallScalarFieldEnum | ApiCallScalarFieldEnum[]
  }

  /**
   * ApiCall create
   */
  export type ApiCallCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ApiCall
     */
    select?: ApiCallSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ApiCallInclude<ExtArgs> | null
    /**
     * The data needed to create a ApiCall.
     */
    data: XOR<ApiCallCreateInput, ApiCallUncheckedCreateInput>
  }

  /**
   * ApiCall createMany
   */
  export type ApiCallCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many ApiCalls.
     */
    data: ApiCallCreateManyInput | ApiCallCreateManyInput[]
    skipDuplicates?: boolean
  }

  /**
   * ApiCall update
   */
  export type ApiCallUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ApiCall
     */
    select?: ApiCallSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ApiCallInclude<ExtArgs> | null
    /**
     * The data needed to update a ApiCall.
     */
    data: XOR<ApiCallUpdateInput, ApiCallUncheckedUpdateInput>
    /**
     * Choose, which ApiCall to update.
     */
    where: ApiCallWhereUniqueInput
  }

  /**
   * ApiCall updateMany
   */
  export type ApiCallUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update ApiCalls.
     */
    data: XOR<ApiCallUpdateManyMutationInput, ApiCallUncheckedUpdateManyInput>
    /**
     * Filter which ApiCalls to update
     */
    where?: ApiCallWhereInput
  }

  /**
   * ApiCall upsert
   */
  export type ApiCallUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ApiCall
     */
    select?: ApiCallSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ApiCallInclude<ExtArgs> | null
    /**
     * The filter to search for the ApiCall to update in case it exists.
     */
    where: ApiCallWhereUniqueInput
    /**
     * In case the ApiCall found by the `where` argument doesn't exist, create a new ApiCall with this data.
     */
    create: XOR<ApiCallCreateInput, ApiCallUncheckedCreateInput>
    /**
     * In case the ApiCall was found with the provided `where` argument, update it with this data.
     */
    update: XOR<ApiCallUpdateInput, ApiCallUncheckedUpdateInput>
  }

  /**
   * ApiCall delete
   */
  export type ApiCallDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ApiCall
     */
    select?: ApiCallSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ApiCallInclude<ExtArgs> | null
    /**
     * Filter which ApiCall to delete.
     */
    where: ApiCallWhereUniqueInput
  }

  /**
   * ApiCall deleteMany
   */
  export type ApiCallDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which ApiCalls to delete
     */
    where?: ApiCallWhereInput
  }

  /**
   * ApiCall without action
   */
  export type ApiCallDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the ApiCall
     */
    select?: ApiCallSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: ApiCallInclude<ExtArgs> | null
  }


  /**
   * Model InsuranceProduct
   */

  export type AggregateInsuranceProduct = {
    _count: InsuranceProductCountAggregateOutputType | null
    _avg: InsuranceProductAvgAggregateOutputType | null
    _sum: InsuranceProductSumAggregateOutputType | null
    _min: InsuranceProductMinAggregateOutputType | null
    _max: InsuranceProductMaxAggregateOutputType | null
  }

  export type InsuranceProductAvgAggregateOutputType = {
    premiumMensal: number | null
    coberturaMax: number | null
  }

  export type InsuranceProductSumAggregateOutputType = {
    premiumMensal: number | null
    coberturaMax: number | null
  }

  export type InsuranceProductMinAggregateOutputType = {
    id: string | null
    nome: string | null
    tipo: string | null
    premiumMensal: number | null
    coberturaMax: number | null
    descricao: string | null
    activo: boolean | null
  }

  export type InsuranceProductMaxAggregateOutputType = {
    id: string | null
    nome: string | null
    tipo: string | null
    premiumMensal: number | null
    coberturaMax: number | null
    descricao: string | null
    activo: boolean | null
  }

  export type InsuranceProductCountAggregateOutputType = {
    id: number
    nome: number
    tipo: number
    premiumMensal: number
    coberturaMax: number
    descricao: number
    activo: number
    _all: number
  }


  export type InsuranceProductAvgAggregateInputType = {
    premiumMensal?: true
    coberturaMax?: true
  }

  export type InsuranceProductSumAggregateInputType = {
    premiumMensal?: true
    coberturaMax?: true
  }

  export type InsuranceProductMinAggregateInputType = {
    id?: true
    nome?: true
    tipo?: true
    premiumMensal?: true
    coberturaMax?: true
    descricao?: true
    activo?: true
  }

  export type InsuranceProductMaxAggregateInputType = {
    id?: true
    nome?: true
    tipo?: true
    premiumMensal?: true
    coberturaMax?: true
    descricao?: true
    activo?: true
  }

  export type InsuranceProductCountAggregateInputType = {
    id?: true
    nome?: true
    tipo?: true
    premiumMensal?: true
    coberturaMax?: true
    descricao?: true
    activo?: true
    _all?: true
  }

  export type InsuranceProductAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which InsuranceProduct to aggregate.
     */
    where?: InsuranceProductWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of InsuranceProducts to fetch.
     */
    orderBy?: InsuranceProductOrderByWithRelationInput | InsuranceProductOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: InsuranceProductWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` InsuranceProducts 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` InsuranceProducts.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned InsuranceProducts
    **/
    _count?: true | InsuranceProductCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to average
    **/
    _avg?: InsuranceProductAvgAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to sum
    **/
    _sum?: InsuranceProductSumAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: InsuranceProductMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: InsuranceProductMaxAggregateInputType
  }

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




  export type InsuranceProductGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: InsuranceProductWhereInput
    orderBy?: InsuranceProductOrderByWithAggregationInput | InsuranceProductOrderByWithAggregationInput[]
    by: InsuranceProductScalarFieldEnum[] | InsuranceProductScalarFieldEnum
    having?: InsuranceProductScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: InsuranceProductCountAggregateInputType | true
    _avg?: InsuranceProductAvgAggregateInputType
    _sum?: InsuranceProductSumAggregateInputType
    _min?: InsuranceProductMinAggregateInputType
    _max?: InsuranceProductMaxAggregateInputType
  }

  export type InsuranceProductGroupByOutputType = {
    id: string
    nome: string
    tipo: string
    premiumMensal: number
    coberturaMax: number
    descricao: string | null
    activo: boolean
    _count: InsuranceProductCountAggregateOutputType | null
    _avg: InsuranceProductAvgAggregateOutputType | null
    _sum: InsuranceProductSumAggregateOutputType | null
    _min: InsuranceProductMinAggregateOutputType | null
    _max: InsuranceProductMaxAggregateOutputType | null
  }

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


  export type InsuranceProductSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    nome?: boolean
    tipo?: boolean
    premiumMensal?: boolean
    coberturaMax?: boolean
    descricao?: boolean
    activo?: boolean
    policies?: boolean | InsuranceProduct$policiesArgs<ExtArgs>
    _count?: boolean | InsuranceProductCountOutputTypeDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["insuranceProduct"]>


  export type InsuranceProductSelectScalar = {
    id?: boolean
    nome?: boolean
    tipo?: boolean
    premiumMensal?: boolean
    coberturaMax?: boolean
    descricao?: boolean
    activo?: boolean
  }

  export type InsuranceProductInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    policies?: boolean | InsuranceProduct$policiesArgs<ExtArgs>
    _count?: boolean | InsuranceProductCountOutputTypeDefaultArgs<ExtArgs>
  }

  export type $InsuranceProductPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "InsuranceProduct"
    objects: {
      policies: Prisma.$InsurancePolicyPayload<ExtArgs>[]
    }
    scalars: $Extensions.GetPayloadResult<{
      id: string
      nome: string
      tipo: string
      premiumMensal: number
      coberturaMax: number
      descricao: string | null
      activo: boolean
    }, ExtArgs["result"]["insuranceProduct"]>
    composites: {}
  }

  type InsuranceProductGetPayload<S extends boolean | null | undefined | InsuranceProductDefaultArgs> = $Result.GetResult<Prisma.$InsuranceProductPayload, S>

  type InsuranceProductCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = 
    Omit<InsuranceProductFindManyArgs, 'select' | 'include' | 'distinct'> & {
      select?: InsuranceProductCountAggregateInputType | true
    }

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

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

    /**
     * Find the first InsuranceProduct 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 {InsuranceProductFindFirstArgs} args - Arguments to find a InsuranceProduct
     * @example
     * // Get one InsuranceProduct
     * const insuranceProduct = await prisma.insuranceProduct.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends InsuranceProductFindFirstArgs>(args?: SelectSubset<T, InsuranceProductFindFirstArgs<ExtArgs>>): Prisma__InsuranceProductClient<$Result.GetResult<Prisma.$InsuranceProductPayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>

    /**
     * Find the first InsuranceProduct 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 {InsuranceProductFindFirstOrThrowArgs} args - Arguments to find a InsuranceProduct
     * @example
     * // Get one InsuranceProduct
     * const insuranceProduct = await prisma.insuranceProduct.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends InsuranceProductFindFirstOrThrowArgs>(args?: SelectSubset<T, InsuranceProductFindFirstOrThrowArgs<ExtArgs>>): Prisma__InsuranceProductClient<$Result.GetResult<Prisma.$InsuranceProductPayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>

    /**
     * Find zero or more InsuranceProducts 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 {InsuranceProductFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all InsuranceProducts
     * const insuranceProducts = await prisma.insuranceProduct.findMany()
     * 
     * // Get first 10 InsuranceProducts
     * const insuranceProducts = await prisma.insuranceProduct.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const insuranceProductWithIdOnly = await prisma.insuranceProduct.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends InsuranceProductFindManyArgs>(args?: SelectSubset<T, InsuranceProductFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$InsuranceProductPayload<ExtArgs>, T, "findMany">>

    /**
     * Create a InsuranceProduct.
     * @param {InsuranceProductCreateArgs} args - Arguments to create a InsuranceProduct.
     * @example
     * // Create one InsuranceProduct
     * const InsuranceProduct = await prisma.insuranceProduct.create({
     *   data: {
     *     // ... data to create a InsuranceProduct
     *   }
     * })
     * 
     */
    create<T extends InsuranceProductCreateArgs>(args: SelectSubset<T, InsuranceProductCreateArgs<ExtArgs>>): Prisma__InsuranceProductClient<$Result.GetResult<Prisma.$InsuranceProductPayload<ExtArgs>, T, "create">, never, ExtArgs>

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

    /**
     * Delete a InsuranceProduct.
     * @param {InsuranceProductDeleteArgs} args - Arguments to delete one InsuranceProduct.
     * @example
     * // Delete one InsuranceProduct
     * const InsuranceProduct = await prisma.insuranceProduct.delete({
     *   where: {
     *     // ... filter to delete one InsuranceProduct
     *   }
     * })
     * 
     */
    delete<T extends InsuranceProductDeleteArgs>(args: SelectSubset<T, InsuranceProductDeleteArgs<ExtArgs>>): Prisma__InsuranceProductClient<$Result.GetResult<Prisma.$InsuranceProductPayload<ExtArgs>, T, "delete">, never, ExtArgs>

    /**
     * Update one InsuranceProduct.
     * @param {InsuranceProductUpdateArgs} args - Arguments to update one InsuranceProduct.
     * @example
     * // Update one InsuranceProduct
     * const insuranceProduct = await prisma.insuranceProduct.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends InsuranceProductUpdateArgs>(args: SelectSubset<T, InsuranceProductUpdateArgs<ExtArgs>>): Prisma__InsuranceProductClient<$Result.GetResult<Prisma.$InsuranceProductPayload<ExtArgs>, T, "update">, never, ExtArgs>

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

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

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


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

    /**
     * Allows you to perform aggregations operations on a InsuranceProduct.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {InsuranceProductAggregateArgs} 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 InsuranceProductAggregateArgs>(args: Subset<T, InsuranceProductAggregateArgs>): Prisma.PrismaPromise<GetInsuranceProductAggregateType<T>>

    /**
     * Group by InsuranceProduct.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {InsuranceProductGroupByArgs} 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 InsuranceProductGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: InsuranceProductGroupByArgs['orderBy'] }
        : { orderBy?: InsuranceProductGroupByArgs['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, InsuranceProductGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetInsuranceProductGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the InsuranceProduct model
   */
  readonly fields: InsuranceProductFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for InsuranceProduct.
   * 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__InsuranceProductClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> extends Prisma.PrismaPromise<T> {
    readonly [Symbol.toStringTag]: "PrismaPromise"
    policies<T extends InsuranceProduct$policiesArgs<ExtArgs> = {}>(args?: Subset<T, InsuranceProduct$policiesArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$InsurancePolicyPayload<ExtArgs>, T, "findMany"> | 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 InsuranceProduct model
   */ 
  interface InsuranceProductFieldRefs {
    readonly id: FieldRef<"InsuranceProduct", 'String'>
    readonly nome: FieldRef<"InsuranceProduct", 'String'>
    readonly tipo: FieldRef<"InsuranceProduct", 'String'>
    readonly premiumMensal: FieldRef<"InsuranceProduct", 'Float'>
    readonly coberturaMax: FieldRef<"InsuranceProduct", 'Float'>
    readonly descricao: FieldRef<"InsuranceProduct", 'String'>
    readonly activo: FieldRef<"InsuranceProduct", 'Boolean'>
  }
    

  // Custom InputTypes
  /**
   * InsuranceProduct findUnique
   */
  export type InsuranceProductFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the InsuranceProduct
     */
    select?: InsuranceProductSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: InsuranceProductInclude<ExtArgs> | null
    /**
     * Filter, which InsuranceProduct to fetch.
     */
    where: InsuranceProductWhereUniqueInput
  }

  /**
   * InsuranceProduct findUniqueOrThrow
   */
  export type InsuranceProductFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the InsuranceProduct
     */
    select?: InsuranceProductSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: InsuranceProductInclude<ExtArgs> | null
    /**
     * Filter, which InsuranceProduct to fetch.
     */
    where: InsuranceProductWhereUniqueInput
  }

  /**
   * InsuranceProduct findFirst
   */
  export type InsuranceProductFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the InsuranceProduct
     */
    select?: InsuranceProductSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: InsuranceProductInclude<ExtArgs> | null
    /**
     * Filter, which InsuranceProduct to fetch.
     */
    where?: InsuranceProductWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of InsuranceProducts to fetch.
     */
    orderBy?: InsuranceProductOrderByWithRelationInput | InsuranceProductOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for InsuranceProducts.
     */
    cursor?: InsuranceProductWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` InsuranceProducts 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` InsuranceProducts.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of InsuranceProducts.
     */
    distinct?: InsuranceProductScalarFieldEnum | InsuranceProductScalarFieldEnum[]
  }

  /**
   * InsuranceProduct findFirstOrThrow
   */
  export type InsuranceProductFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the InsuranceProduct
     */
    select?: InsuranceProductSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: InsuranceProductInclude<ExtArgs> | null
    /**
     * Filter, which InsuranceProduct to fetch.
     */
    where?: InsuranceProductWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of InsuranceProducts to fetch.
     */
    orderBy?: InsuranceProductOrderByWithRelationInput | InsuranceProductOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for InsuranceProducts.
     */
    cursor?: InsuranceProductWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` InsuranceProducts 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` InsuranceProducts.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of InsuranceProducts.
     */
    distinct?: InsuranceProductScalarFieldEnum | InsuranceProductScalarFieldEnum[]
  }

  /**
   * InsuranceProduct findMany
   */
  export type InsuranceProductFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the InsuranceProduct
     */
    select?: InsuranceProductSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: InsuranceProductInclude<ExtArgs> | null
    /**
     * Filter, which InsuranceProducts to fetch.
     */
    where?: InsuranceProductWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of InsuranceProducts to fetch.
     */
    orderBy?: InsuranceProductOrderByWithRelationInput | InsuranceProductOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing InsuranceProducts.
     */
    cursor?: InsuranceProductWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` InsuranceProducts 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` InsuranceProducts.
     */
    skip?: number
    distinct?: InsuranceProductScalarFieldEnum | InsuranceProductScalarFieldEnum[]
  }

  /**
   * InsuranceProduct create
   */
  export type InsuranceProductCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the InsuranceProduct
     */
    select?: InsuranceProductSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: InsuranceProductInclude<ExtArgs> | null
    /**
     * The data needed to create a InsuranceProduct.
     */
    data: XOR<InsuranceProductCreateInput, InsuranceProductUncheckedCreateInput>
  }

  /**
   * InsuranceProduct createMany
   */
  export type InsuranceProductCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many InsuranceProducts.
     */
    data: InsuranceProductCreateManyInput | InsuranceProductCreateManyInput[]
    skipDuplicates?: boolean
  }

  /**
   * InsuranceProduct update
   */
  export type InsuranceProductUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the InsuranceProduct
     */
    select?: InsuranceProductSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: InsuranceProductInclude<ExtArgs> | null
    /**
     * The data needed to update a InsuranceProduct.
     */
    data: XOR<InsuranceProductUpdateInput, InsuranceProductUncheckedUpdateInput>
    /**
     * Choose, which InsuranceProduct to update.
     */
    where: InsuranceProductWhereUniqueInput
  }

  /**
   * InsuranceProduct updateMany
   */
  export type InsuranceProductUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update InsuranceProducts.
     */
    data: XOR<InsuranceProductUpdateManyMutationInput, InsuranceProductUncheckedUpdateManyInput>
    /**
     * Filter which InsuranceProducts to update
     */
    where?: InsuranceProductWhereInput
  }

  /**
   * InsuranceProduct upsert
   */
  export type InsuranceProductUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the InsuranceProduct
     */
    select?: InsuranceProductSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: InsuranceProductInclude<ExtArgs> | null
    /**
     * The filter to search for the InsuranceProduct to update in case it exists.
     */
    where: InsuranceProductWhereUniqueInput
    /**
     * In case the InsuranceProduct found by the `where` argument doesn't exist, create a new InsuranceProduct with this data.
     */
    create: XOR<InsuranceProductCreateInput, InsuranceProductUncheckedCreateInput>
    /**
     * In case the InsuranceProduct was found with the provided `where` argument, update it with this data.
     */
    update: XOR<InsuranceProductUpdateInput, InsuranceProductUncheckedUpdateInput>
  }

  /**
   * InsuranceProduct delete
   */
  export type InsuranceProductDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the InsuranceProduct
     */
    select?: InsuranceProductSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: InsuranceProductInclude<ExtArgs> | null
    /**
     * Filter which InsuranceProduct to delete.
     */
    where: InsuranceProductWhereUniqueInput
  }

  /**
   * InsuranceProduct deleteMany
   */
  export type InsuranceProductDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which InsuranceProducts to delete
     */
    where?: InsuranceProductWhereInput
  }

  /**
   * InsuranceProduct.policies
   */
  export type InsuranceProduct$policiesArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the InsurancePolicy
     */
    select?: InsurancePolicySelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: InsurancePolicyInclude<ExtArgs> | null
    where?: InsurancePolicyWhereInput
    orderBy?: InsurancePolicyOrderByWithRelationInput | InsurancePolicyOrderByWithRelationInput[]
    cursor?: InsurancePolicyWhereUniqueInput
    take?: number
    skip?: number
    distinct?: InsurancePolicyScalarFieldEnum | InsurancePolicyScalarFieldEnum[]
  }

  /**
   * InsuranceProduct without action
   */
  export type InsuranceProductDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the InsuranceProduct
     */
    select?: InsuranceProductSelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: InsuranceProductInclude<ExtArgs> | null
  }


  /**
   * Model InsurancePolicy
   */

  export type AggregateInsurancePolicy = {
    _count: InsurancePolicyCountAggregateOutputType | null
    _avg: InsurancePolicyAvgAggregateOutputType | null
    _sum: InsurancePolicySumAggregateOutputType | null
    _min: InsurancePolicyMinAggregateOutputType | null
    _max: InsurancePolicyMaxAggregateOutputType | null
  }

  export type InsurancePolicyAvgAggregateOutputType = {
    premiumPago: number | null
  }

  export type InsurancePolicySumAggregateOutputType = {
    premiumPago: number | null
  }

  export type InsurancePolicyMinAggregateOutputType = {
    id: string | null
    userId: string | null
    productId: string | null
    status: string | null
    dataInicio: Date | null
    premiumPago: number | null
    proximaCobranca: Date | null
  }

  export type InsurancePolicyMaxAggregateOutputType = {
    id: string | null
    userId: string | null
    productId: string | null
    status: string | null
    dataInicio: Date | null
    premiumPago: number | null
    proximaCobranca: Date | null
  }

  export type InsurancePolicyCountAggregateOutputType = {
    id: number
    userId: number
    productId: number
    status: number
    dataInicio: number
    premiumPago: number
    proximaCobranca: number
    _all: number
  }


  export type InsurancePolicyAvgAggregateInputType = {
    premiumPago?: true
  }

  export type InsurancePolicySumAggregateInputType = {
    premiumPago?: true
  }

  export type InsurancePolicyMinAggregateInputType = {
    id?: true
    userId?: true
    productId?: true
    status?: true
    dataInicio?: true
    premiumPago?: true
    proximaCobranca?: true
  }

  export type InsurancePolicyMaxAggregateInputType = {
    id?: true
    userId?: true
    productId?: true
    status?: true
    dataInicio?: true
    premiumPago?: true
    proximaCobranca?: true
  }

  export type InsurancePolicyCountAggregateInputType = {
    id?: true
    userId?: true
    productId?: true
    status?: true
    dataInicio?: true
    premiumPago?: true
    proximaCobranca?: true
    _all?: true
  }

  export type InsurancePolicyAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which InsurancePolicy to aggregate.
     */
    where?: InsurancePolicyWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of InsurancePolicies to fetch.
     */
    orderBy?: InsurancePolicyOrderByWithRelationInput | InsurancePolicyOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: InsurancePolicyWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` InsurancePolicies 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` InsurancePolicies.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned InsurancePolicies
    **/
    _count?: true | InsurancePolicyCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to average
    **/
    _avg?: InsurancePolicyAvgAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to sum
    **/
    _sum?: InsurancePolicySumAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: InsurancePolicyMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: InsurancePolicyMaxAggregateInputType
  }

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




  export type InsurancePolicyGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: InsurancePolicyWhereInput
    orderBy?: InsurancePolicyOrderByWithAggregationInput | InsurancePolicyOrderByWithAggregationInput[]
    by: InsurancePolicyScalarFieldEnum[] | InsurancePolicyScalarFieldEnum
    having?: InsurancePolicyScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: InsurancePolicyCountAggregateInputType | true
    _avg?: InsurancePolicyAvgAggregateInputType
    _sum?: InsurancePolicySumAggregateInputType
    _min?: InsurancePolicyMinAggregateInputType
    _max?: InsurancePolicyMaxAggregateInputType
  }

  export type InsurancePolicyGroupByOutputType = {
    id: string
    userId: string
    productId: string
    status: string
    dataInicio: Date
    premiumPago: number
    proximaCobranca: Date | null
    _count: InsurancePolicyCountAggregateOutputType | null
    _avg: InsurancePolicyAvgAggregateOutputType | null
    _sum: InsurancePolicySumAggregateOutputType | null
    _min: InsurancePolicyMinAggregateOutputType | null
    _max: InsurancePolicyMaxAggregateOutputType | null
  }

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


  export type InsurancePolicySelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    userId?: boolean
    productId?: boolean
    status?: boolean
    dataInicio?: boolean
    premiumPago?: boolean
    proximaCobranca?: boolean
    user?: boolean | UserDefaultArgs<ExtArgs>
    product?: boolean | InsuranceProductDefaultArgs<ExtArgs>
  }, ExtArgs["result"]["insurancePolicy"]>


  export type InsurancePolicySelectScalar = {
    id?: boolean
    userId?: boolean
    productId?: boolean
    status?: boolean
    dataInicio?: boolean
    premiumPago?: boolean
    proximaCobranca?: boolean
  }

  export type InsurancePolicyInclude<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    user?: boolean | UserDefaultArgs<ExtArgs>
    product?: boolean | InsuranceProductDefaultArgs<ExtArgs>
  }

  export type $InsurancePolicyPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "InsurancePolicy"
    objects: {
      user: Prisma.$UserPayload<ExtArgs>
      product: Prisma.$InsuranceProductPayload<ExtArgs>
    }
    scalars: $Extensions.GetPayloadResult<{
      id: string
      userId: string
      productId: string
      status: string
      dataInicio: Date
      premiumPago: number
      proximaCobranca: Date | null
    }, ExtArgs["result"]["insurancePolicy"]>
    composites: {}
  }

  type InsurancePolicyGetPayload<S extends boolean | null | undefined | InsurancePolicyDefaultArgs> = $Result.GetResult<Prisma.$InsurancePolicyPayload, S>

  type InsurancePolicyCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = 
    Omit<InsurancePolicyFindManyArgs, 'select' | 'include' | 'distinct'> & {
      select?: InsurancePolicyCountAggregateInputType | true
    }

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

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

    /**
     * Find the first InsurancePolicy 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 {InsurancePolicyFindFirstArgs} args - Arguments to find a InsurancePolicy
     * @example
     * // Get one InsurancePolicy
     * const insurancePolicy = await prisma.insurancePolicy.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends InsurancePolicyFindFirstArgs>(args?: SelectSubset<T, InsurancePolicyFindFirstArgs<ExtArgs>>): Prisma__InsurancePolicyClient<$Result.GetResult<Prisma.$InsurancePolicyPayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>

    /**
     * Find the first InsurancePolicy 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 {InsurancePolicyFindFirstOrThrowArgs} args - Arguments to find a InsurancePolicy
     * @example
     * // Get one InsurancePolicy
     * const insurancePolicy = await prisma.insurancePolicy.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends InsurancePolicyFindFirstOrThrowArgs>(args?: SelectSubset<T, InsurancePolicyFindFirstOrThrowArgs<ExtArgs>>): Prisma__InsurancePolicyClient<$Result.GetResult<Prisma.$InsurancePolicyPayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>

    /**
     * Find zero or more InsurancePolicies 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 {InsurancePolicyFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all InsurancePolicies
     * const insurancePolicies = await prisma.insurancePolicy.findMany()
     * 
     * // Get first 10 InsurancePolicies
     * const insurancePolicies = await prisma.insurancePolicy.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const insurancePolicyWithIdOnly = await prisma.insurancePolicy.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends InsurancePolicyFindManyArgs>(args?: SelectSubset<T, InsurancePolicyFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$InsurancePolicyPayload<ExtArgs>, T, "findMany">>

    /**
     * Create a InsurancePolicy.
     * @param {InsurancePolicyCreateArgs} args - Arguments to create a InsurancePolicy.
     * @example
     * // Create one InsurancePolicy
     * const InsurancePolicy = await prisma.insurancePolicy.create({
     *   data: {
     *     // ... data to create a InsurancePolicy
     *   }
     * })
     * 
     */
    create<T extends InsurancePolicyCreateArgs>(args: SelectSubset<T, InsurancePolicyCreateArgs<ExtArgs>>): Prisma__InsurancePolicyClient<$Result.GetResult<Prisma.$InsurancePolicyPayload<ExtArgs>, T, "create">, never, ExtArgs>

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

    /**
     * Delete a InsurancePolicy.
     * @param {InsurancePolicyDeleteArgs} args - Arguments to delete one InsurancePolicy.
     * @example
     * // Delete one InsurancePolicy
     * const InsurancePolicy = await prisma.insurancePolicy.delete({
     *   where: {
     *     // ... filter to delete one InsurancePolicy
     *   }
     * })
     * 
     */
    delete<T extends InsurancePolicyDeleteArgs>(args: SelectSubset<T, InsurancePolicyDeleteArgs<ExtArgs>>): Prisma__InsurancePolicyClient<$Result.GetResult<Prisma.$InsurancePolicyPayload<ExtArgs>, T, "delete">, never, ExtArgs>

    /**
     * Update one InsurancePolicy.
     * @param {InsurancePolicyUpdateArgs} args - Arguments to update one InsurancePolicy.
     * @example
     * // Update one InsurancePolicy
     * const insurancePolicy = await prisma.insurancePolicy.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends InsurancePolicyUpdateArgs>(args: SelectSubset<T, InsurancePolicyUpdateArgs<ExtArgs>>): Prisma__InsurancePolicyClient<$Result.GetResult<Prisma.$InsurancePolicyPayload<ExtArgs>, T, "update">, never, ExtArgs>

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

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

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


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

    /**
     * Allows you to perform aggregations operations on a InsurancePolicy.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {InsurancePolicyAggregateArgs} 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 InsurancePolicyAggregateArgs>(args: Subset<T, InsurancePolicyAggregateArgs>): Prisma.PrismaPromise<GetInsurancePolicyAggregateType<T>>

    /**
     * Group by InsurancePolicy.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {InsurancePolicyGroupByArgs} 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 InsurancePolicyGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: InsurancePolicyGroupByArgs['orderBy'] }
        : { orderBy?: InsurancePolicyGroupByArgs['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, InsurancePolicyGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetInsurancePolicyGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the InsurancePolicy model
   */
  readonly fields: InsurancePolicyFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for InsurancePolicy.
   * 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__InsurancePolicyClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> 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"> | Null, Null, ExtArgs>
    product<T extends InsuranceProductDefaultArgs<ExtArgs> = {}>(args?: Subset<T, InsuranceProductDefaultArgs<ExtArgs>>): Prisma__InsuranceProductClient<$Result.GetResult<Prisma.$InsuranceProductPayload<ExtArgs>, T, "findUniqueOrThrow"> | Null, Null, ExtArgs>
    /**
     * 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 InsurancePolicy model
   */ 
  interface InsurancePolicyFieldRefs {
    readonly id: FieldRef<"InsurancePolicy", 'String'>
    readonly userId: FieldRef<"InsurancePolicy", 'String'>
    readonly productId: FieldRef<"InsurancePolicy", 'String'>
    readonly status: FieldRef<"InsurancePolicy", 'String'>
    readonly dataInicio: FieldRef<"InsurancePolicy", 'DateTime'>
    readonly premiumPago: FieldRef<"InsurancePolicy", 'Float'>
    readonly proximaCobranca: FieldRef<"InsurancePolicy", 'DateTime'>
  }
    

  // Custom InputTypes
  /**
   * InsurancePolicy findUnique
   */
  export type InsurancePolicyFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the InsurancePolicy
     */
    select?: InsurancePolicySelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: InsurancePolicyInclude<ExtArgs> | null
    /**
     * Filter, which InsurancePolicy to fetch.
     */
    where: InsurancePolicyWhereUniqueInput
  }

  /**
   * InsurancePolicy findUniqueOrThrow
   */
  export type InsurancePolicyFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the InsurancePolicy
     */
    select?: InsurancePolicySelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: InsurancePolicyInclude<ExtArgs> | null
    /**
     * Filter, which InsurancePolicy to fetch.
     */
    where: InsurancePolicyWhereUniqueInput
  }

  /**
   * InsurancePolicy findFirst
   */
  export type InsurancePolicyFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the InsurancePolicy
     */
    select?: InsurancePolicySelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: InsurancePolicyInclude<ExtArgs> | null
    /**
     * Filter, which InsurancePolicy to fetch.
     */
    where?: InsurancePolicyWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of InsurancePolicies to fetch.
     */
    orderBy?: InsurancePolicyOrderByWithRelationInput | InsurancePolicyOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for InsurancePolicies.
     */
    cursor?: InsurancePolicyWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` InsurancePolicies 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` InsurancePolicies.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of InsurancePolicies.
     */
    distinct?: InsurancePolicyScalarFieldEnum | InsurancePolicyScalarFieldEnum[]
  }

  /**
   * InsurancePolicy findFirstOrThrow
   */
  export type InsurancePolicyFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the InsurancePolicy
     */
    select?: InsurancePolicySelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: InsurancePolicyInclude<ExtArgs> | null
    /**
     * Filter, which InsurancePolicy to fetch.
     */
    where?: InsurancePolicyWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of InsurancePolicies to fetch.
     */
    orderBy?: InsurancePolicyOrderByWithRelationInput | InsurancePolicyOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for InsurancePolicies.
     */
    cursor?: InsurancePolicyWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` InsurancePolicies 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` InsurancePolicies.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of InsurancePolicies.
     */
    distinct?: InsurancePolicyScalarFieldEnum | InsurancePolicyScalarFieldEnum[]
  }

  /**
   * InsurancePolicy findMany
   */
  export type InsurancePolicyFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the InsurancePolicy
     */
    select?: InsurancePolicySelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: InsurancePolicyInclude<ExtArgs> | null
    /**
     * Filter, which InsurancePolicies to fetch.
     */
    where?: InsurancePolicyWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of InsurancePolicies to fetch.
     */
    orderBy?: InsurancePolicyOrderByWithRelationInput | InsurancePolicyOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing InsurancePolicies.
     */
    cursor?: InsurancePolicyWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` InsurancePolicies 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` InsurancePolicies.
     */
    skip?: number
    distinct?: InsurancePolicyScalarFieldEnum | InsurancePolicyScalarFieldEnum[]
  }

  /**
   * InsurancePolicy create
   */
  export type InsurancePolicyCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the InsurancePolicy
     */
    select?: InsurancePolicySelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: InsurancePolicyInclude<ExtArgs> | null
    /**
     * The data needed to create a InsurancePolicy.
     */
    data: XOR<InsurancePolicyCreateInput, InsurancePolicyUncheckedCreateInput>
  }

  /**
   * InsurancePolicy createMany
   */
  export type InsurancePolicyCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many InsurancePolicies.
     */
    data: InsurancePolicyCreateManyInput | InsurancePolicyCreateManyInput[]
    skipDuplicates?: boolean
  }

  /**
   * InsurancePolicy update
   */
  export type InsurancePolicyUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the InsurancePolicy
     */
    select?: InsurancePolicySelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: InsurancePolicyInclude<ExtArgs> | null
    /**
     * The data needed to update a InsurancePolicy.
     */
    data: XOR<InsurancePolicyUpdateInput, InsurancePolicyUncheckedUpdateInput>
    /**
     * Choose, which InsurancePolicy to update.
     */
    where: InsurancePolicyWhereUniqueInput
  }

  /**
   * InsurancePolicy updateMany
   */
  export type InsurancePolicyUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update InsurancePolicies.
     */
    data: XOR<InsurancePolicyUpdateManyMutationInput, InsurancePolicyUncheckedUpdateManyInput>
    /**
     * Filter which InsurancePolicies to update
     */
    where?: InsurancePolicyWhereInput
  }

  /**
   * InsurancePolicy upsert
   */
  export type InsurancePolicyUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the InsurancePolicy
     */
    select?: InsurancePolicySelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: InsurancePolicyInclude<ExtArgs> | null
    /**
     * The filter to search for the InsurancePolicy to update in case it exists.
     */
    where: InsurancePolicyWhereUniqueInput
    /**
     * In case the InsurancePolicy found by the `where` argument doesn't exist, create a new InsurancePolicy with this data.
     */
    create: XOR<InsurancePolicyCreateInput, InsurancePolicyUncheckedCreateInput>
    /**
     * In case the InsurancePolicy was found with the provided `where` argument, update it with this data.
     */
    update: XOR<InsurancePolicyUpdateInput, InsurancePolicyUncheckedUpdateInput>
  }

  /**
   * InsurancePolicy delete
   */
  export type InsurancePolicyDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the InsurancePolicy
     */
    select?: InsurancePolicySelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: InsurancePolicyInclude<ExtArgs> | null
    /**
     * Filter which InsurancePolicy to delete.
     */
    where: InsurancePolicyWhereUniqueInput
  }

  /**
   * InsurancePolicy deleteMany
   */
  export type InsurancePolicyDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which InsurancePolicies to delete
     */
    where?: InsurancePolicyWhereInput
  }

  /**
   * InsurancePolicy without action
   */
  export type InsurancePolicyDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the InsurancePolicy
     */
    select?: InsurancePolicySelect<ExtArgs> | null
    /**
     * Choose, which related nodes to fetch as well
     */
    include?: InsurancePolicyInclude<ExtArgs> | null
  }


  /**
   * Model Country
   */

  export type AggregateCountry = {
    _count: CountryCountAggregateOutputType | null
    _min: CountryMinAggregateOutputType | null
    _max: CountryMaxAggregateOutputType | null
  }

  export type CountryMinAggregateOutputType = {
    codigo: string | null
    nome: string | null
    moedaPadrao: string | null
    regulador: string | null
    estrutura: string | null
    activo: boolean | null
  }

  export type CountryMaxAggregateOutputType = {
    codigo: string | null
    nome: string | null
    moedaPadrao: string | null
    regulador: string | null
    estrutura: string | null
    activo: boolean | null
  }

  export type CountryCountAggregateOutputType = {
    codigo: number
    nome: number
    moedaPadrao: number
    regulador: number
    estrutura: number
    activo: number
    _all: number
  }


  export type CountryMinAggregateInputType = {
    codigo?: true
    nome?: true
    moedaPadrao?: true
    regulador?: true
    estrutura?: true
    activo?: true
  }

  export type CountryMaxAggregateInputType = {
    codigo?: true
    nome?: true
    moedaPadrao?: true
    regulador?: true
    estrutura?: true
    activo?: true
  }

  export type CountryCountAggregateInputType = {
    codigo?: true
    nome?: true
    moedaPadrao?: true
    regulador?: true
    estrutura?: true
    activo?: true
    _all?: true
  }

  export type CountryAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which Country to aggregate.
     */
    where?: CountryWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Countries to fetch.
     */
    orderBy?: CountryOrderByWithRelationInput | CountryOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: CountryWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Countries 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` Countries.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned Countries
    **/
    _count?: true | CountryCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: CountryMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: CountryMaxAggregateInputType
  }

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




  export type CountryGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: CountryWhereInput
    orderBy?: CountryOrderByWithAggregationInput | CountryOrderByWithAggregationInput[]
    by: CountryScalarFieldEnum[] | CountryScalarFieldEnum
    having?: CountryScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: CountryCountAggregateInputType | true
    _min?: CountryMinAggregateInputType
    _max?: CountryMaxAggregateInputType
  }

  export type CountryGroupByOutputType = {
    codigo: string
    nome: string
    moedaPadrao: string
    regulador: string
    estrutura: string | null
    activo: boolean
    _count: CountryCountAggregateOutputType | null
    _min: CountryMinAggregateOutputType | null
    _max: CountryMaxAggregateOutputType | null
  }

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


  export type CountrySelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    codigo?: boolean
    nome?: boolean
    moedaPadrao?: boolean
    regulador?: boolean
    estrutura?: boolean
    activo?: boolean
  }, ExtArgs["result"]["country"]>


  export type CountrySelectScalar = {
    codigo?: boolean
    nome?: boolean
    moedaPadrao?: boolean
    regulador?: boolean
    estrutura?: boolean
    activo?: boolean
  }


  export type $CountryPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "Country"
    objects: {}
    scalars: $Extensions.GetPayloadResult<{
      codigo: string
      nome: string
      moedaPadrao: string
      regulador: string
      estrutura: string | null
      activo: boolean
    }, ExtArgs["result"]["country"]>
    composites: {}
  }

  type CountryGetPayload<S extends boolean | null | undefined | CountryDefaultArgs> = $Result.GetResult<Prisma.$CountryPayload, S>

  type CountryCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = 
    Omit<CountryFindManyArgs, 'select' | 'include' | 'distinct'> & {
      select?: CountryCountAggregateInputType | true
    }

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

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

    /**
     * Find the first Country 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 {CountryFindFirstArgs} args - Arguments to find a Country
     * @example
     * // Get one Country
     * const country = await prisma.country.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends CountryFindFirstArgs>(args?: SelectSubset<T, CountryFindFirstArgs<ExtArgs>>): Prisma__CountryClient<$Result.GetResult<Prisma.$CountryPayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>

    /**
     * Find the first Country 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 {CountryFindFirstOrThrowArgs} args - Arguments to find a Country
     * @example
     * // Get one Country
     * const country = await prisma.country.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends CountryFindFirstOrThrowArgs>(args?: SelectSubset<T, CountryFindFirstOrThrowArgs<ExtArgs>>): Prisma__CountryClient<$Result.GetResult<Prisma.$CountryPayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>

    /**
     * Find zero or more Countries 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 {CountryFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all Countries
     * const countries = await prisma.country.findMany()
     * 
     * // Get first 10 Countries
     * const countries = await prisma.country.findMany({ take: 10 })
     * 
     * // Only select the `codigo`
     * const countryWithCodigoOnly = await prisma.country.findMany({ select: { codigo: true } })
     * 
     */
    findMany<T extends CountryFindManyArgs>(args?: SelectSubset<T, CountryFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$CountryPayload<ExtArgs>, T, "findMany">>

    /**
     * Create a Country.
     * @param {CountryCreateArgs} args - Arguments to create a Country.
     * @example
     * // Create one Country
     * const Country = await prisma.country.create({
     *   data: {
     *     // ... data to create a Country
     *   }
     * })
     * 
     */
    create<T extends CountryCreateArgs>(args: SelectSubset<T, CountryCreateArgs<ExtArgs>>): Prisma__CountryClient<$Result.GetResult<Prisma.$CountryPayload<ExtArgs>, T, "create">, never, ExtArgs>

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

    /**
     * Delete a Country.
     * @param {CountryDeleteArgs} args - Arguments to delete one Country.
     * @example
     * // Delete one Country
     * const Country = await prisma.country.delete({
     *   where: {
     *     // ... filter to delete one Country
     *   }
     * })
     * 
     */
    delete<T extends CountryDeleteArgs>(args: SelectSubset<T, CountryDeleteArgs<ExtArgs>>): Prisma__CountryClient<$Result.GetResult<Prisma.$CountryPayload<ExtArgs>, T, "delete">, never, ExtArgs>

    /**
     * Update one Country.
     * @param {CountryUpdateArgs} args - Arguments to update one Country.
     * @example
     * // Update one Country
     * const country = await prisma.country.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends CountryUpdateArgs>(args: SelectSubset<T, CountryUpdateArgs<ExtArgs>>): Prisma__CountryClient<$Result.GetResult<Prisma.$CountryPayload<ExtArgs>, T, "update">, never, ExtArgs>

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

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

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


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

    /**
     * Allows you to perform aggregations operations on a Country.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {CountryAggregateArgs} 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 CountryAggregateArgs>(args: Subset<T, CountryAggregateArgs>): Prisma.PrismaPromise<GetCountryAggregateType<T>>

    /**
     * Group by Country.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {CountryGroupByArgs} 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 CountryGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: CountryGroupByArgs['orderBy'] }
        : { orderBy?: CountryGroupByArgs['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, CountryGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetCountryGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the Country model
   */
  readonly fields: CountryFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for Country.
   * 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__CountryClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> 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 Country model
   */ 
  interface CountryFieldRefs {
    readonly codigo: FieldRef<"Country", 'String'>
    readonly nome: FieldRef<"Country", 'String'>
    readonly moedaPadrao: FieldRef<"Country", 'String'>
    readonly regulador: FieldRef<"Country", 'String'>
    readonly estrutura: FieldRef<"Country", 'String'>
    readonly activo: FieldRef<"Country", 'Boolean'>
  }
    

  // Custom InputTypes
  /**
   * Country findUnique
   */
  export type CountryFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Country
     */
    select?: CountrySelect<ExtArgs> | null
    /**
     * Filter, which Country to fetch.
     */
    where: CountryWhereUniqueInput
  }

  /**
   * Country findUniqueOrThrow
   */
  export type CountryFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Country
     */
    select?: CountrySelect<ExtArgs> | null
    /**
     * Filter, which Country to fetch.
     */
    where: CountryWhereUniqueInput
  }

  /**
   * Country findFirst
   */
  export type CountryFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Country
     */
    select?: CountrySelect<ExtArgs> | null
    /**
     * Filter, which Country to fetch.
     */
    where?: CountryWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Countries to fetch.
     */
    orderBy?: CountryOrderByWithRelationInput | CountryOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for Countries.
     */
    cursor?: CountryWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Countries 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` Countries.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of Countries.
     */
    distinct?: CountryScalarFieldEnum | CountryScalarFieldEnum[]
  }

  /**
   * Country findFirstOrThrow
   */
  export type CountryFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Country
     */
    select?: CountrySelect<ExtArgs> | null
    /**
     * Filter, which Country to fetch.
     */
    where?: CountryWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Countries to fetch.
     */
    orderBy?: CountryOrderByWithRelationInput | CountryOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for Countries.
     */
    cursor?: CountryWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Countries 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` Countries.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of Countries.
     */
    distinct?: CountryScalarFieldEnum | CountryScalarFieldEnum[]
  }

  /**
   * Country findMany
   */
  export type CountryFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Country
     */
    select?: CountrySelect<ExtArgs> | null
    /**
     * Filter, which Countries to fetch.
     */
    where?: CountryWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of Countries to fetch.
     */
    orderBy?: CountryOrderByWithRelationInput | CountryOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing Countries.
     */
    cursor?: CountryWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` Countries 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` Countries.
     */
    skip?: number
    distinct?: CountryScalarFieldEnum | CountryScalarFieldEnum[]
  }

  /**
   * Country create
   */
  export type CountryCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Country
     */
    select?: CountrySelect<ExtArgs> | null
    /**
     * The data needed to create a Country.
     */
    data: XOR<CountryCreateInput, CountryUncheckedCreateInput>
  }

  /**
   * Country createMany
   */
  export type CountryCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many Countries.
     */
    data: CountryCreateManyInput | CountryCreateManyInput[]
    skipDuplicates?: boolean
  }

  /**
   * Country update
   */
  export type CountryUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Country
     */
    select?: CountrySelect<ExtArgs> | null
    /**
     * The data needed to update a Country.
     */
    data: XOR<CountryUpdateInput, CountryUncheckedUpdateInput>
    /**
     * Choose, which Country to update.
     */
    where: CountryWhereUniqueInput
  }

  /**
   * Country updateMany
   */
  export type CountryUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update Countries.
     */
    data: XOR<CountryUpdateManyMutationInput, CountryUncheckedUpdateManyInput>
    /**
     * Filter which Countries to update
     */
    where?: CountryWhereInput
  }

  /**
   * Country upsert
   */
  export type CountryUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Country
     */
    select?: CountrySelect<ExtArgs> | null
    /**
     * The filter to search for the Country to update in case it exists.
     */
    where: CountryWhereUniqueInput
    /**
     * In case the Country found by the `where` argument doesn't exist, create a new Country with this data.
     */
    create: XOR<CountryCreateInput, CountryUncheckedCreateInput>
    /**
     * In case the Country was found with the provided `where` argument, update it with this data.
     */
    update: XOR<CountryUpdateInput, CountryUncheckedUpdateInput>
  }

  /**
   * Country delete
   */
  export type CountryDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Country
     */
    select?: CountrySelect<ExtArgs> | null
    /**
     * Filter which Country to delete.
     */
    where: CountryWhereUniqueInput
  }

  /**
   * Country deleteMany
   */
  export type CountryDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which Countries to delete
     */
    where?: CountryWhereInput
  }

  /**
   * Country without action
   */
  export type CountryDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the Country
     */
    select?: CountrySelect<ExtArgs> | null
  }


  /**
   * Model AnalyticsSnapshot
   */

  export type AggregateAnalyticsSnapshot = {
    _count: AnalyticsSnapshotCountAggregateOutputType | null
    _avg: AnalyticsSnapshotAvgAggregateOutputType | null
    _sum: AnalyticsSnapshotSumAggregateOutputType | null
    _min: AnalyticsSnapshotMinAggregateOutputType | null
    _max: AnalyticsSnapshotMaxAggregateOutputType | null
  }

  export type AnalyticsSnapshotAvgAggregateOutputType = {
    utilizadoresActivos: number | null
    gruposActivos: number | null
    contribuicoesPagas: number | null
    volumeMensal: number | null
    defaultsAbertos: number | null
    fundoCobertura: number | null
  }

  export type AnalyticsSnapshotSumAggregateOutputType = {
    utilizadoresActivos: number | null
    gruposActivos: number | null
    contribuicoesPagas: number | null
    volumeMensal: number | null
    defaultsAbertos: number | null
    fundoCobertura: number | null
  }

  export type AnalyticsSnapshotMinAggregateOutputType = {
    id: string | null
    data: Date | null
    utilizadoresActivos: number | null
    gruposActivos: number | null
    contribuicoesPagas: number | null
    volumeMensal: number | null
    defaultsAbertos: number | null
    fundoCobertura: number | null
    createdAt: Date | null
  }

  export type AnalyticsSnapshotMaxAggregateOutputType = {
    id: string | null
    data: Date | null
    utilizadoresActivos: number | null
    gruposActivos: number | null
    contribuicoesPagas: number | null
    volumeMensal: number | null
    defaultsAbertos: number | null
    fundoCobertura: number | null
    createdAt: Date | null
  }

  export type AnalyticsSnapshotCountAggregateOutputType = {
    id: number
    data: number
    utilizadoresActivos: number
    gruposActivos: number
    contribuicoesPagas: number
    volumeMensal: number
    defaultsAbertos: number
    fundoCobertura: number
    createdAt: number
    _all: number
  }


  export type AnalyticsSnapshotAvgAggregateInputType = {
    utilizadoresActivos?: true
    gruposActivos?: true
    contribuicoesPagas?: true
    volumeMensal?: true
    defaultsAbertos?: true
    fundoCobertura?: true
  }

  export type AnalyticsSnapshotSumAggregateInputType = {
    utilizadoresActivos?: true
    gruposActivos?: true
    contribuicoesPagas?: true
    volumeMensal?: true
    defaultsAbertos?: true
    fundoCobertura?: true
  }

  export type AnalyticsSnapshotMinAggregateInputType = {
    id?: true
    data?: true
    utilizadoresActivos?: true
    gruposActivos?: true
    contribuicoesPagas?: true
    volumeMensal?: true
    defaultsAbertos?: true
    fundoCobertura?: true
    createdAt?: true
  }

  export type AnalyticsSnapshotMaxAggregateInputType = {
    id?: true
    data?: true
    utilizadoresActivos?: true
    gruposActivos?: true
    contribuicoesPagas?: true
    volumeMensal?: true
    defaultsAbertos?: true
    fundoCobertura?: true
    createdAt?: true
  }

  export type AnalyticsSnapshotCountAggregateInputType = {
    id?: true
    data?: true
    utilizadoresActivos?: true
    gruposActivos?: true
    contribuicoesPagas?: true
    volumeMensal?: true
    defaultsAbertos?: true
    fundoCobertura?: true
    createdAt?: true
    _all?: true
  }

  export type AnalyticsSnapshotAggregateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which AnalyticsSnapshot to aggregate.
     */
    where?: AnalyticsSnapshotWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of AnalyticsSnapshots to fetch.
     */
    orderBy?: AnalyticsSnapshotOrderByWithRelationInput | AnalyticsSnapshotOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the start position
     */
    cursor?: AnalyticsSnapshotWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` AnalyticsSnapshots 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` AnalyticsSnapshots.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Count returned AnalyticsSnapshots
    **/
    _count?: true | AnalyticsSnapshotCountAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to average
    **/
    _avg?: AnalyticsSnapshotAvgAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to sum
    **/
    _sum?: AnalyticsSnapshotSumAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the minimum value
    **/
    _min?: AnalyticsSnapshotMinAggregateInputType
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
     * 
     * Select which fields to find the maximum value
    **/
    _max?: AnalyticsSnapshotMaxAggregateInputType
  }

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




  export type AnalyticsSnapshotGroupByArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    where?: AnalyticsSnapshotWhereInput
    orderBy?: AnalyticsSnapshotOrderByWithAggregationInput | AnalyticsSnapshotOrderByWithAggregationInput[]
    by: AnalyticsSnapshotScalarFieldEnum[] | AnalyticsSnapshotScalarFieldEnum
    having?: AnalyticsSnapshotScalarWhereWithAggregatesInput
    take?: number
    skip?: number
    _count?: AnalyticsSnapshotCountAggregateInputType | true
    _avg?: AnalyticsSnapshotAvgAggregateInputType
    _sum?: AnalyticsSnapshotSumAggregateInputType
    _min?: AnalyticsSnapshotMinAggregateInputType
    _max?: AnalyticsSnapshotMaxAggregateInputType
  }

  export type AnalyticsSnapshotGroupByOutputType = {
    id: string
    data: Date
    utilizadoresActivos: number
    gruposActivos: number
    contribuicoesPagas: number
    volumeMensal: number
    defaultsAbertos: number
    fundoCobertura: number
    createdAt: Date
    _count: AnalyticsSnapshotCountAggregateOutputType | null
    _avg: AnalyticsSnapshotAvgAggregateOutputType | null
    _sum: AnalyticsSnapshotSumAggregateOutputType | null
    _min: AnalyticsSnapshotMinAggregateOutputType | null
    _max: AnalyticsSnapshotMaxAggregateOutputType | null
  }

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


  export type AnalyticsSnapshotSelect<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = $Extensions.GetSelect<{
    id?: boolean
    data?: boolean
    utilizadoresActivos?: boolean
    gruposActivos?: boolean
    contribuicoesPagas?: boolean
    volumeMensal?: boolean
    defaultsAbertos?: boolean
    fundoCobertura?: boolean
    createdAt?: boolean
  }, ExtArgs["result"]["analyticsSnapshot"]>


  export type AnalyticsSnapshotSelectScalar = {
    id?: boolean
    data?: boolean
    utilizadoresActivos?: boolean
    gruposActivos?: boolean
    contribuicoesPagas?: boolean
    volumeMensal?: boolean
    defaultsAbertos?: boolean
    fundoCobertura?: boolean
    createdAt?: boolean
  }


  export type $AnalyticsSnapshotPayload<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    name: "AnalyticsSnapshot"
    objects: {}
    scalars: $Extensions.GetPayloadResult<{
      id: string
      data: Date
      utilizadoresActivos: number
      gruposActivos: number
      contribuicoesPagas: number
      volumeMensal: number
      defaultsAbertos: number
      fundoCobertura: number
      createdAt: Date
    }, ExtArgs["result"]["analyticsSnapshot"]>
    composites: {}
  }

  type AnalyticsSnapshotGetPayload<S extends boolean | null | undefined | AnalyticsSnapshotDefaultArgs> = $Result.GetResult<Prisma.$AnalyticsSnapshotPayload, S>

  type AnalyticsSnapshotCountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = 
    Omit<AnalyticsSnapshotFindManyArgs, 'select' | 'include' | 'distinct'> & {
      select?: AnalyticsSnapshotCountAggregateInputType | true
    }

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

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

    /**
     * Find the first AnalyticsSnapshot 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 {AnalyticsSnapshotFindFirstArgs} args - Arguments to find a AnalyticsSnapshot
     * @example
     * // Get one AnalyticsSnapshot
     * const analyticsSnapshot = await prisma.analyticsSnapshot.findFirst({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirst<T extends AnalyticsSnapshotFindFirstArgs>(args?: SelectSubset<T, AnalyticsSnapshotFindFirstArgs<ExtArgs>>): Prisma__AnalyticsSnapshotClient<$Result.GetResult<Prisma.$AnalyticsSnapshotPayload<ExtArgs>, T, "findFirst"> | null, null, ExtArgs>

    /**
     * Find the first AnalyticsSnapshot 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 {AnalyticsSnapshotFindFirstOrThrowArgs} args - Arguments to find a AnalyticsSnapshot
     * @example
     * // Get one AnalyticsSnapshot
     * const analyticsSnapshot = await prisma.analyticsSnapshot.findFirstOrThrow({
     *   where: {
     *     // ... provide filter here
     *   }
     * })
     */
    findFirstOrThrow<T extends AnalyticsSnapshotFindFirstOrThrowArgs>(args?: SelectSubset<T, AnalyticsSnapshotFindFirstOrThrowArgs<ExtArgs>>): Prisma__AnalyticsSnapshotClient<$Result.GetResult<Prisma.$AnalyticsSnapshotPayload<ExtArgs>, T, "findFirstOrThrow">, never, ExtArgs>

    /**
     * Find zero or more AnalyticsSnapshots 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 {AnalyticsSnapshotFindManyArgs} args - Arguments to filter and select certain fields only.
     * @example
     * // Get all AnalyticsSnapshots
     * const analyticsSnapshots = await prisma.analyticsSnapshot.findMany()
     * 
     * // Get first 10 AnalyticsSnapshots
     * const analyticsSnapshots = await prisma.analyticsSnapshot.findMany({ take: 10 })
     * 
     * // Only select the `id`
     * const analyticsSnapshotWithIdOnly = await prisma.analyticsSnapshot.findMany({ select: { id: true } })
     * 
     */
    findMany<T extends AnalyticsSnapshotFindManyArgs>(args?: SelectSubset<T, AnalyticsSnapshotFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<$Result.GetResult<Prisma.$AnalyticsSnapshotPayload<ExtArgs>, T, "findMany">>

    /**
     * Create a AnalyticsSnapshot.
     * @param {AnalyticsSnapshotCreateArgs} args - Arguments to create a AnalyticsSnapshot.
     * @example
     * // Create one AnalyticsSnapshot
     * const AnalyticsSnapshot = await prisma.analyticsSnapshot.create({
     *   data: {
     *     // ... data to create a AnalyticsSnapshot
     *   }
     * })
     * 
     */
    create<T extends AnalyticsSnapshotCreateArgs>(args: SelectSubset<T, AnalyticsSnapshotCreateArgs<ExtArgs>>): Prisma__AnalyticsSnapshotClient<$Result.GetResult<Prisma.$AnalyticsSnapshotPayload<ExtArgs>, T, "create">, never, ExtArgs>

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

    /**
     * Delete a AnalyticsSnapshot.
     * @param {AnalyticsSnapshotDeleteArgs} args - Arguments to delete one AnalyticsSnapshot.
     * @example
     * // Delete one AnalyticsSnapshot
     * const AnalyticsSnapshot = await prisma.analyticsSnapshot.delete({
     *   where: {
     *     // ... filter to delete one AnalyticsSnapshot
     *   }
     * })
     * 
     */
    delete<T extends AnalyticsSnapshotDeleteArgs>(args: SelectSubset<T, AnalyticsSnapshotDeleteArgs<ExtArgs>>): Prisma__AnalyticsSnapshotClient<$Result.GetResult<Prisma.$AnalyticsSnapshotPayload<ExtArgs>, T, "delete">, never, ExtArgs>

    /**
     * Update one AnalyticsSnapshot.
     * @param {AnalyticsSnapshotUpdateArgs} args - Arguments to update one AnalyticsSnapshot.
     * @example
     * // Update one AnalyticsSnapshot
     * const analyticsSnapshot = await prisma.analyticsSnapshot.update({
     *   where: {
     *     // ... provide filter here
     *   },
     *   data: {
     *     // ... provide data here
     *   }
     * })
     * 
     */
    update<T extends AnalyticsSnapshotUpdateArgs>(args: SelectSubset<T, AnalyticsSnapshotUpdateArgs<ExtArgs>>): Prisma__AnalyticsSnapshotClient<$Result.GetResult<Prisma.$AnalyticsSnapshotPayload<ExtArgs>, T, "update">, never, ExtArgs>

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

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

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


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

    /**
     * Allows you to perform aggregations operations on a AnalyticsSnapshot.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {AnalyticsSnapshotAggregateArgs} 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 AnalyticsSnapshotAggregateArgs>(args: Subset<T, AnalyticsSnapshotAggregateArgs>): Prisma.PrismaPromise<GetAnalyticsSnapshotAggregateType<T>>

    /**
     * Group by AnalyticsSnapshot.
     * Note, that providing `undefined` is treated as the value not being there.
     * Read more here: https://pris.ly/d/null-undefined
     * @param {AnalyticsSnapshotGroupByArgs} 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 AnalyticsSnapshotGroupByArgs,
      HasSelectOrTake extends Or<
        Extends<'skip', Keys<T>>,
        Extends<'take', Keys<T>>
      >,
      OrderByArg extends True extends HasSelectOrTake
        ? { orderBy: AnalyticsSnapshotGroupByArgs['orderBy'] }
        : { orderBy?: AnalyticsSnapshotGroupByArgs['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, AnalyticsSnapshotGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetAnalyticsSnapshotGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
  /**
   * Fields of the AnalyticsSnapshot model
   */
  readonly fields: AnalyticsSnapshotFieldRefs;
  }

  /**
   * The delegate class that acts as a "Promise-like" for AnalyticsSnapshot.
   * 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__AnalyticsSnapshotClient<T, Null = never, ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> 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 AnalyticsSnapshot model
   */ 
  interface AnalyticsSnapshotFieldRefs {
    readonly id: FieldRef<"AnalyticsSnapshot", 'String'>
    readonly data: FieldRef<"AnalyticsSnapshot", 'DateTime'>
    readonly utilizadoresActivos: FieldRef<"AnalyticsSnapshot", 'Int'>
    readonly gruposActivos: FieldRef<"AnalyticsSnapshot", 'Int'>
    readonly contribuicoesPagas: FieldRef<"AnalyticsSnapshot", 'Int'>
    readonly volumeMensal: FieldRef<"AnalyticsSnapshot", 'Float'>
    readonly defaultsAbertos: FieldRef<"AnalyticsSnapshot", 'Int'>
    readonly fundoCobertura: FieldRef<"AnalyticsSnapshot", 'Float'>
    readonly createdAt: FieldRef<"AnalyticsSnapshot", 'DateTime'>
  }
    

  // Custom InputTypes
  /**
   * AnalyticsSnapshot findUnique
   */
  export type AnalyticsSnapshotFindUniqueArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the AnalyticsSnapshot
     */
    select?: AnalyticsSnapshotSelect<ExtArgs> | null
    /**
     * Filter, which AnalyticsSnapshot to fetch.
     */
    where: AnalyticsSnapshotWhereUniqueInput
  }

  /**
   * AnalyticsSnapshot findUniqueOrThrow
   */
  export type AnalyticsSnapshotFindUniqueOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the AnalyticsSnapshot
     */
    select?: AnalyticsSnapshotSelect<ExtArgs> | null
    /**
     * Filter, which AnalyticsSnapshot to fetch.
     */
    where: AnalyticsSnapshotWhereUniqueInput
  }

  /**
   * AnalyticsSnapshot findFirst
   */
  export type AnalyticsSnapshotFindFirstArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the AnalyticsSnapshot
     */
    select?: AnalyticsSnapshotSelect<ExtArgs> | null
    /**
     * Filter, which AnalyticsSnapshot to fetch.
     */
    where?: AnalyticsSnapshotWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of AnalyticsSnapshots to fetch.
     */
    orderBy?: AnalyticsSnapshotOrderByWithRelationInput | AnalyticsSnapshotOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for AnalyticsSnapshots.
     */
    cursor?: AnalyticsSnapshotWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` AnalyticsSnapshots 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` AnalyticsSnapshots.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of AnalyticsSnapshots.
     */
    distinct?: AnalyticsSnapshotScalarFieldEnum | AnalyticsSnapshotScalarFieldEnum[]
  }

  /**
   * AnalyticsSnapshot findFirstOrThrow
   */
  export type AnalyticsSnapshotFindFirstOrThrowArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the AnalyticsSnapshot
     */
    select?: AnalyticsSnapshotSelect<ExtArgs> | null
    /**
     * Filter, which AnalyticsSnapshot to fetch.
     */
    where?: AnalyticsSnapshotWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of AnalyticsSnapshots to fetch.
     */
    orderBy?: AnalyticsSnapshotOrderByWithRelationInput | AnalyticsSnapshotOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for searching for AnalyticsSnapshots.
     */
    cursor?: AnalyticsSnapshotWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` AnalyticsSnapshots 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` AnalyticsSnapshots.
     */
    skip?: number
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
     * 
     * Filter by unique combinations of AnalyticsSnapshots.
     */
    distinct?: AnalyticsSnapshotScalarFieldEnum | AnalyticsSnapshotScalarFieldEnum[]
  }

  /**
   * AnalyticsSnapshot findMany
   */
  export type AnalyticsSnapshotFindManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the AnalyticsSnapshot
     */
    select?: AnalyticsSnapshotSelect<ExtArgs> | null
    /**
     * Filter, which AnalyticsSnapshots to fetch.
     */
    where?: AnalyticsSnapshotWhereInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
     * 
     * Determine the order of AnalyticsSnapshots to fetch.
     */
    orderBy?: AnalyticsSnapshotOrderByWithRelationInput | AnalyticsSnapshotOrderByWithRelationInput[]
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
     * 
     * Sets the position for listing AnalyticsSnapshots.
     */
    cursor?: AnalyticsSnapshotWhereUniqueInput
    /**
     * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
     * 
     * Take `±n` AnalyticsSnapshots 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` AnalyticsSnapshots.
     */
    skip?: number
    distinct?: AnalyticsSnapshotScalarFieldEnum | AnalyticsSnapshotScalarFieldEnum[]
  }

  /**
   * AnalyticsSnapshot create
   */
  export type AnalyticsSnapshotCreateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the AnalyticsSnapshot
     */
    select?: AnalyticsSnapshotSelect<ExtArgs> | null
    /**
     * The data needed to create a AnalyticsSnapshot.
     */
    data: XOR<AnalyticsSnapshotCreateInput, AnalyticsSnapshotUncheckedCreateInput>
  }

  /**
   * AnalyticsSnapshot createMany
   */
  export type AnalyticsSnapshotCreateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to create many AnalyticsSnapshots.
     */
    data: AnalyticsSnapshotCreateManyInput | AnalyticsSnapshotCreateManyInput[]
    skipDuplicates?: boolean
  }

  /**
   * AnalyticsSnapshot update
   */
  export type AnalyticsSnapshotUpdateArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the AnalyticsSnapshot
     */
    select?: AnalyticsSnapshotSelect<ExtArgs> | null
    /**
     * The data needed to update a AnalyticsSnapshot.
     */
    data: XOR<AnalyticsSnapshotUpdateInput, AnalyticsSnapshotUncheckedUpdateInput>
    /**
     * Choose, which AnalyticsSnapshot to update.
     */
    where: AnalyticsSnapshotWhereUniqueInput
  }

  /**
   * AnalyticsSnapshot updateMany
   */
  export type AnalyticsSnapshotUpdateManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * The data used to update AnalyticsSnapshots.
     */
    data: XOR<AnalyticsSnapshotUpdateManyMutationInput, AnalyticsSnapshotUncheckedUpdateManyInput>
    /**
     * Filter which AnalyticsSnapshots to update
     */
    where?: AnalyticsSnapshotWhereInput
  }

  /**
   * AnalyticsSnapshot upsert
   */
  export type AnalyticsSnapshotUpsertArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the AnalyticsSnapshot
     */
    select?: AnalyticsSnapshotSelect<ExtArgs> | null
    /**
     * The filter to search for the AnalyticsSnapshot to update in case it exists.
     */
    where: AnalyticsSnapshotWhereUniqueInput
    /**
     * In case the AnalyticsSnapshot found by the `where` argument doesn't exist, create a new AnalyticsSnapshot with this data.
     */
    create: XOR<AnalyticsSnapshotCreateInput, AnalyticsSnapshotUncheckedCreateInput>
    /**
     * In case the AnalyticsSnapshot was found with the provided `where` argument, update it with this data.
     */
    update: XOR<AnalyticsSnapshotUpdateInput, AnalyticsSnapshotUncheckedUpdateInput>
  }

  /**
   * AnalyticsSnapshot delete
   */
  export type AnalyticsSnapshotDeleteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the AnalyticsSnapshot
     */
    select?: AnalyticsSnapshotSelect<ExtArgs> | null
    /**
     * Filter which AnalyticsSnapshot to delete.
     */
    where: AnalyticsSnapshotWhereUniqueInput
  }

  /**
   * AnalyticsSnapshot deleteMany
   */
  export type AnalyticsSnapshotDeleteManyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Filter which AnalyticsSnapshots to delete
     */
    where?: AnalyticsSnapshotWhereInput
  }

  /**
   * AnalyticsSnapshot without action
   */
  export type AnalyticsSnapshotDefaultArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = {
    /**
     * Select specific fields to fetch from the AnalyticsSnapshot
     */
    select?: AnalyticsSnapshotSelect<ExtArgs> | null
  }


  /**
   * Enums
   */

  export const TransactionIsolationLevel: {
    ReadUncommitted: 'ReadUncommitted',
    ReadCommitted: 'ReadCommitted',
    RepeatableRead: 'RepeatableRead',
    Serializable: 'Serializable'
  };

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


  export const UserScalarFieldEnum: {
    id: 'id',
    nome: 'nome',
    telefone: 'telefone',
    email: 'email',
    passwordHash: 'passwordHash',
    bi: 'bi',
    dataNascimento: 'dataNascimento',
    provincia: 'provincia',
    pais: 'pais',
    moedaPreferida: 'moedaPreferida',
    fotoPerfilUrl: 'fotoPerfilUrl',
    kycStatus: 'kycStatus',
    kycNivel: 'kycNivel',
    kycDataJson: 'kycDataJson',
    status: 'status',
    scoreAtual: 'scoreAtual',
    role: 'role',
    referralCode: 'referralCode',
    referredById: 'referredById',
    pontosEducacao: 'pontosEducacao',
    createdAt: 'createdAt',
    updatedAt: 'updatedAt'
  };

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


  export const OtpScalarFieldEnum: {
    id: 'id',
    userId: 'userId',
    telefone: 'telefone',
    codigo: 'codigo',
    proposito: 'proposito',
    consumido: 'consumido',
    expiraEm: 'expiraEm',
    createdAt: 'createdAt'
  };

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


  export const SessionScalarFieldEnum: {
    id: 'id',
    userId: 'userId',
    token: 'token',
    expiraEm: 'expiraEm',
    createdAt: 'createdAt'
  };

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


  export const GroupScalarFieldEnum: {
    id: 'id',
    nome: 'nome',
    descricao: 'descricao',
    criadorId: 'criadorId',
    numMembros: 'numMembros',
    valorContribuicaoMensal: 'valorContribuicaoMensal',
    taxaPrincipalAplicada: 'taxaPrincipalAplicada',
    reservaTecnicaAplicada: 'reservaTecnicaAplicada',
    periodicidade: 'periodicidade',
    tipo: 'tipo',
    pais: 'pais',
    moeda: 'moeda',
    status: 'status',
    dataInicio: 'dataInicio',
    dataFimPrevista: 'dataFimPrevista',
    cicloAtual: 'cicloAtual',
    totalCiclos: 'totalCiclos',
    createdAt: 'createdAt',
    updatedAt: 'updatedAt'
  };

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


  export const GroupApplicationScalarFieldEnum: {
    id: 'id',
    groupId: 'groupId',
    userId: 'userId',
    mensagem: 'mensagem',
    status: 'status',
    createdAt: 'createdAt'
  };

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


  export const MembershipScalarFieldEnum: {
    id: 'id',
    userId: 'userId',
    groupId: 'groupId',
    posicaoRotacao: 'posicaoRotacao',
    status: 'status',
    necessidadeUrgente: 'necessidadeUrgente',
    dataJuncao: 'dataJuncao',
    mesRecepcaoPrevisto: 'mesRecepcaoPrevisto'
  };

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


  export const InviteScalarFieldEnum: {
    id: 'id',
    groupId: 'groupId',
    convidadoPorId: 'convidadoPorId',
    telefone: 'telefone',
    email: 'email',
    token: 'token',
    status: 'status',
    createdAt: 'createdAt',
    expiraEm: 'expiraEm'
  };

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


  export const MonthlyCycleScalarFieldEnum: {
    id: 'id',
    groupId: 'groupId',
    numeroCiclo: 'numeroCiclo',
    mesAno: 'mesAno',
    beneficiarioMembershipId: 'beneficiarioMembershipId',
    dataContribuicaoLimite: 'dataContribuicaoLimite',
    dataCashout: 'dataCashout',
    status: 'status',
    valorPoteBruto: 'valorPoteBruto',
    valorTaxaPrincipal: 'valorTaxaPrincipal',
    valorReservaTecnica: 'valorReservaTecnica',
    valorPoteLiquido: 'valorPoteLiquido',
    createdAt: 'createdAt',
    updatedAt: 'updatedAt'
  };

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


  export const ContributionScalarFieldEnum: {
    id: 'id',
    membershipId: 'membershipId',
    userId: 'userId',
    monthlyCycleId: 'monthlyCycleId',
    valor: 'valor',
    dataPrevista: 'dataPrevista',
    dataPagamento: 'dataPagamento',
    status: 'status',
    metodoPagamento: 'metodoPagamento',
    referenciaBancaria: 'referenciaBancaria',
    comprovativoUrl: 'comprovativoUrl',
    createdAt: 'createdAt',
    updatedAt: 'updatedAt'
  };

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


  export const CashoutScalarFieldEnum: {
    id: 'id',
    monthlyCycleId: 'monthlyCycleId',
    beneficiarioUserId: 'beneficiarioUserId',
    valorBruto: 'valorBruto',
    valorTaxaPrincipal: 'valorTaxaPrincipal',
    valorReservaTecnica: 'valorReservaTecnica',
    valorLiquido: 'valorLiquido',
    dataPrevista: 'dataPrevista',
    dataExecucao: 'dataExecucao',
    status: 'status',
    contaDestino: 'contaDestino',
    refTransferencia: 'refTransferencia',
    parcialMotivo: 'parcialMotivo',
    createdAt: 'createdAt',
    updatedAt: 'updatedAt'
  };

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


  export const LoanScalarFieldEnum: {
    id: 'id',
    userId: 'userId',
    monthlyCycleId: 'monthlyCycleId',
    contributionId: 'contributionId',
    valorCapital: 'valorCapital',
    taxaEmprestimo: 'taxaEmprestimo',
    valorTotalDevido: 'valorTotalDevido',
    jurosMoraAcumulados: 'jurosMoraAcumulados',
    dataInicio: 'dataInicio',
    dataPagamento: 'dataPagamento',
    status: 'status',
    createdAt: 'createdAt',
    updatedAt: 'updatedAt'
  };

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


  export const CoverageDecisionScalarFieldEnum: {
    id: 'id',
    contributionId: 'contributionId',
    decisao: 'decisao',
    motivo: 'motivo',
    scoreNoMomento: 'scoreNoMomento',
    historicoInadimplencias: 'historicoInadimplencias',
    decisorUserId: 'decisorUserId',
    decisorSistema: 'decisorSistema',
    createdAt: 'createdAt'
  };

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


  export const ReintegrationScalarFieldEnum: {
    id: 'id',
    userId: 'userId',
    valorDividaOriginal: 'valorDividaOriginal',
    taxaReintegracaoAplicada: 'taxaReintegracaoAplicada',
    valorTaxaPaga: 'valorTaxaPaga',
    dataSolicitacao: 'dataSolicitacao',
    dataConclusao: 'dataConclusao',
    status: 'status'
  };

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


  export const FeeConfigurationScalarFieldEnum: {
    id: 'id',
    tipoFee: 'tipoFee',
    valor: 'valor',
    min: 'min',
    max: 'max',
    dataInicio: 'dataInicio',
    dataFim: 'dataFim',
    criadoPorId: 'criadoPorId',
    motivoMudanca: 'motivoMudanca',
    ativa: 'ativa',
    createdAt: 'createdAt'
  };

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


  export const CoverageFundScalarFieldEnum: {
    id: 'id',
    saldoDisponivel: 'saldoDisponivel',
    saldoEmEmprestimosActivos: 'saldoEmEmprestimosActivos',
    totalRecuperadoAno: 'totalRecuperadoAno',
    totalPerdidoAno: 'totalPerdidoAno',
    lastUpdated: 'lastUpdated'
  };

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


  export const TransactionScalarFieldEnum: {
    id: 'id',
    tipo: 'tipo',
    valor: 'valor',
    fromAccount: 'fromAccount',
    toAccount: 'toAccount',
    referencia: 'referencia',
    status: 'status',
    timestamp: 'timestamp',
    auditJson: 'auditJson'
  };

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


  export const ScoreEventScalarFieldEnum: {
    id: 'id',
    userId: 'userId',
    tipoEvento: 'tipoEvento',
    impacto: 'impacto',
    descricao: 'descricao',
    scoreAntes: 'scoreAntes',
    scoreDepois: 'scoreDepois',
    timestamp: 'timestamp'
  };

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


  export const NotificationScalarFieldEnum: {
    id: 'id',
    userId: 'userId',
    canal: 'canal',
    titulo: 'titulo',
    corpo: 'corpo',
    lida: 'lida',
    metadataJson: 'metadataJson',
    createdAt: 'createdAt'
  };

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


  export const AuditLogScalarFieldEnum: {
    id: 'id',
    userId: 'userId',
    acao: 'acao',
    entidade: 'entidade',
    entidadeId: 'entidadeId',
    dadosAntes: 'dadosAntes',
    dadosDepois: 'dadosDepois',
    ip: 'ip',
    timestamp: 'timestamp'
  };

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


  export const SystemClockScalarFieldEnum: {
    id: 'id',
    agora: 'agora',
    updatedAt: 'updatedAt'
  };

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


  export const CreditApplicationScalarFieldEnum: {
    id: 'id',
    userId: 'userId',
    valorSolicitado: 'valorSolicitado',
    prazoMeses: 'prazoMeses',
    taxaJuroAplicada: 'taxaJuroAplicada',
    prestacaoMensal: 'prestacaoMensal',
    finalidade: 'finalidade',
    status: 'status',
    scoreNoMomento: 'scoreNoMomento',
    motivoDecisao: 'motivoDecisao',
    decisaoPorId: 'decisaoPorId',
    dataAprovacao: 'dataAprovacao',
    dataDesembolso: 'dataDesembolso',
    createdAt: 'createdAt',
    updatedAt: 'updatedAt'
  };

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


  export const CreditInstallmentScalarFieldEnum: {
    id: 'id',
    applicationId: 'applicationId',
    numero: 'numero',
    valorCapital: 'valorCapital',
    valorJuros: 'valorJuros',
    valorTotal: 'valorTotal',
    dataVencimento: 'dataVencimento',
    dataPagamento: 'dataPagamento',
    status: 'status'
  };

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


  export const SavingsAccountScalarFieldEnum: {
    id: 'id',
    userId: 'userId',
    nome: 'nome',
    objectivo: 'objectivo',
    meta: 'meta',
    saldo: 'saldo',
    taxaRemuneracaoAnual: 'taxaRemuneracaoAnual',
    imobilizacaoMeses: 'imobilizacaoMeses',
    status: 'status',
    ultimaCapitalizacao: 'ultimaCapitalizacao',
    createdAt: 'createdAt',
    updatedAt: 'updatedAt'
  };

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


  export const SavingsMovementScalarFieldEnum: {
    id: 'id',
    accountId: 'accountId',
    tipo: 'tipo',
    valor: 'valor',
    saldoApos: 'saldoApos',
    descricao: 'descricao',
    createdAt: 'createdAt'
  };

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


  export const ReferralScalarFieldEnum: {
    id: 'id',
    referrerUserId: 'referrerUserId',
    referredUserId: 'referredUserId',
    codigo: 'codigo',
    canal: 'canal',
    status: 'status',
    recompensa: 'recompensa',
    recompensaPaga: 'recompensaPaga',
    dataRegisto: 'dataRegisto',
    dataActivacao: 'dataActivacao',
    createdAt: 'createdAt'
  };

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


  export const ContentArticleScalarFieldEnum: {
    id: 'id',
    slug: 'slug',
    titulo: 'titulo',
    resumo: 'resumo',
    corpo: 'corpo',
    categoria: 'categoria',
    autor: 'autor',
    duracaoLeituraMin: 'duracaoLeituraMin',
    publicado: 'publicado',
    ordem: 'ordem',
    createdAt: 'createdAt'
  };

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


  export const QuizScalarFieldEnum: {
    id: 'id',
    titulo: 'titulo',
    descricao: 'descricao',
    perguntasJson: 'perguntasJson',
    pontos: 'pontos',
    publicado: 'publicado',
    createdAt: 'createdAt'
  };

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


  export const QuizAttemptScalarFieldEnum: {
    id: 'id',
    userId: 'userId',
    quizId: 'quizId',
    acertos: 'acertos',
    total: 'total',
    pontosGanhos: 'pontosGanhos',
    respostasJson: 'respostasJson',
    createdAt: 'createdAt'
  };

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


  export const BadgeScalarFieldEnum: {
    id: 'id',
    userId: 'userId',
    tipo: 'tipo',
    titulo: 'titulo',
    descricao: 'descricao',
    createdAt: 'createdAt'
  };

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


  export const ApiKeyScalarFieldEnum: {
    id: 'id',
    nome: 'nome',
    partnerNome: 'partnerNome',
    chave: 'chave',
    scopes: 'scopes',
    status: 'status',
    rateLimit: 'rateLimit',
    createdAt: 'createdAt',
    ultimoUso: 'ultimoUso',
    usos: 'usos'
  };

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


  export const ApiCallScalarFieldEnum: {
    id: 'id',
    apiKeyId: 'apiKeyId',
    endpoint: 'endpoint',
    metodo: 'metodo',
    status: 'status',
    duracaoMs: 'duracaoMs',
    ip: 'ip',
    timestamp: 'timestamp'
  };

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


  export const InsuranceProductScalarFieldEnum: {
    id: 'id',
    nome: 'nome',
    tipo: 'tipo',
    premiumMensal: 'premiumMensal',
    coberturaMax: 'coberturaMax',
    descricao: 'descricao',
    activo: 'activo'
  };

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


  export const InsurancePolicyScalarFieldEnum: {
    id: 'id',
    userId: 'userId',
    productId: 'productId',
    status: 'status',
    dataInicio: 'dataInicio',
    premiumPago: 'premiumPago',
    proximaCobranca: 'proximaCobranca'
  };

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


  export const CountryScalarFieldEnum: {
    codigo: 'codigo',
    nome: 'nome',
    moedaPadrao: 'moedaPadrao',
    regulador: 'regulador',
    estrutura: 'estrutura',
    activo: 'activo'
  };

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


  export const AnalyticsSnapshotScalarFieldEnum: {
    id: 'id',
    data: 'data',
    utilizadoresActivos: 'utilizadoresActivos',
    gruposActivos: 'gruposActivos',
    contribuicoesPagas: 'contribuicoesPagas',
    volumeMensal: 'volumeMensal',
    defaultsAbertos: 'defaultsAbertos',
    fundoCobertura: 'fundoCobertura',
    createdAt: 'createdAt'
  };

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


  export const SortOrder: {
    asc: 'asc',
    desc: 'desc'
  };

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


  export const NullsOrder: {
    first: 'first',
    last: 'last'
  };

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


  /**
   * Field references 
   */


  /**
   * Reference to a field of type 'String'
   */
  export type StringFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'String'>
    


  /**
   * Reference to a field of type 'DateTime'
   */
  export type DateTimeFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'DateTime'>
    


  /**
   * Reference to a field of type 'Int'
   */
  export type IntFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'Int'>
    


  /**
   * Reference to a field of type 'Boolean'
   */
  export type BooleanFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'Boolean'>
    


  /**
   * Reference to a field of type 'Float'
   */
  export type FloatFieldRefInput<$PrismaModel> = FieldRefInputType<$PrismaModel, 'Float'>
    
  /**
   * Deep Input Types
   */


  export type UserWhereInput = {
    AND?: UserWhereInput | UserWhereInput[]
    OR?: UserWhereInput[]
    NOT?: UserWhereInput | UserWhereInput[]
    id?: StringFilter<"User"> | string
    nome?: StringFilter<"User"> | string
    telefone?: StringFilter<"User"> | string
    email?: StringFilter<"User"> | string
    passwordHash?: StringFilter<"User"> | string
    bi?: StringNullableFilter<"User"> | string | null
    dataNascimento?: DateTimeNullableFilter<"User"> | Date | string | null
    provincia?: StringNullableFilter<"User"> | string | null
    pais?: StringFilter<"User"> | string
    moedaPreferida?: StringFilter<"User"> | string
    fotoPerfilUrl?: StringNullableFilter<"User"> | string | null
    kycStatus?: StringFilter<"User"> | string
    kycNivel?: IntFilter<"User"> | number
    kycDataJson?: StringNullableFilter<"User"> | string | null
    status?: StringFilter<"User"> | string
    scoreAtual?: IntFilter<"User"> | number
    role?: StringFilter<"User"> | string
    referralCode?: StringNullableFilter<"User"> | string | null
    referredById?: StringNullableFilter<"User"> | string | null
    pontosEducacao?: IntFilter<"User"> | number
    createdAt?: DateTimeFilter<"User"> | Date | string
    updatedAt?: DateTimeFilter<"User"> | Date | string
    referredBy?: XOR<UserNullableRelationFilter, UserWhereInput> | null
    referidos?: UserListRelationFilter
    gruposCriados?: GroupListRelationFilter
    memberships?: MembershipListRelationFilter
    contribuicoes?: ContributionListRelationFilter
    cashouts?: CashoutListRelationFilter
    loans?: LoanListRelationFilter
    scoreEvents?: ScoreEventListRelationFilter
    reintegrations?: ReintegrationListRelationFilter
    otps?: OtpListRelationFilter
    sessions?: SessionListRelationFilter
    notifications?: NotificationListRelationFilter
    coverageDecisions?: CoverageDecisionListRelationFilter
    invitesEnviados?: InviteListRelationFilter
    feeConfigsCriadas?: FeeConfigurationListRelationFilter
    auditLogs?: AuditLogListRelationFilter
    creditApplications?: CreditApplicationListRelationFilter
    savingsAccounts?: SavingsAccountListRelationFilter
    referralsCreated?: ReferralListRelationFilter
    referralAsReferred?: ReferralListRelationFilter
    quizAttempts?: QuizAttemptListRelationFilter
    badges?: BadgeListRelationFilter
    insurancePolicies?: InsurancePolicyListRelationFilter
  }

  export type UserOrderByWithRelationInput = {
    id?: SortOrder
    nome?: SortOrder
    telefone?: SortOrder
    email?: SortOrder
    passwordHash?: SortOrder
    bi?: SortOrderInput | SortOrder
    dataNascimento?: SortOrderInput | SortOrder
    provincia?: SortOrderInput | SortOrder
    pais?: SortOrder
    moedaPreferida?: SortOrder
    fotoPerfilUrl?: SortOrderInput | SortOrder
    kycStatus?: SortOrder
    kycNivel?: SortOrder
    kycDataJson?: SortOrderInput | SortOrder
    status?: SortOrder
    scoreAtual?: SortOrder
    role?: SortOrder
    referralCode?: SortOrderInput | SortOrder
    referredById?: SortOrderInput | SortOrder
    pontosEducacao?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
    referredBy?: UserOrderByWithRelationInput
    referidos?: UserOrderByRelationAggregateInput
    gruposCriados?: GroupOrderByRelationAggregateInput
    memberships?: MembershipOrderByRelationAggregateInput
    contribuicoes?: ContributionOrderByRelationAggregateInput
    cashouts?: CashoutOrderByRelationAggregateInput
    loans?: LoanOrderByRelationAggregateInput
    scoreEvents?: ScoreEventOrderByRelationAggregateInput
    reintegrations?: ReintegrationOrderByRelationAggregateInput
    otps?: OtpOrderByRelationAggregateInput
    sessions?: SessionOrderByRelationAggregateInput
    notifications?: NotificationOrderByRelationAggregateInput
    coverageDecisions?: CoverageDecisionOrderByRelationAggregateInput
    invitesEnviados?: InviteOrderByRelationAggregateInput
    feeConfigsCriadas?: FeeConfigurationOrderByRelationAggregateInput
    auditLogs?: AuditLogOrderByRelationAggregateInput
    creditApplications?: CreditApplicationOrderByRelationAggregateInput
    savingsAccounts?: SavingsAccountOrderByRelationAggregateInput
    referralsCreated?: ReferralOrderByRelationAggregateInput
    referralAsReferred?: ReferralOrderByRelationAggregateInput
    quizAttempts?: QuizAttemptOrderByRelationAggregateInput
    badges?: BadgeOrderByRelationAggregateInput
    insurancePolicies?: InsurancePolicyOrderByRelationAggregateInput
  }

  export type UserWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    telefone?: string
    email?: string
    referralCode?: string
    AND?: UserWhereInput | UserWhereInput[]
    OR?: UserWhereInput[]
    NOT?: UserWhereInput | UserWhereInput[]
    nome?: StringFilter<"User"> | string
    passwordHash?: StringFilter<"User"> | string
    bi?: StringNullableFilter<"User"> | string | null
    dataNascimento?: DateTimeNullableFilter<"User"> | Date | string | null
    provincia?: StringNullableFilter<"User"> | string | null
    pais?: StringFilter<"User"> | string
    moedaPreferida?: StringFilter<"User"> | string
    fotoPerfilUrl?: StringNullableFilter<"User"> | string | null
    kycStatus?: StringFilter<"User"> | string
    kycNivel?: IntFilter<"User"> | number
    kycDataJson?: StringNullableFilter<"User"> | string | null
    status?: StringFilter<"User"> | string
    scoreAtual?: IntFilter<"User"> | number
    role?: StringFilter<"User"> | string
    referredById?: StringNullableFilter<"User"> | string | null
    pontosEducacao?: IntFilter<"User"> | number
    createdAt?: DateTimeFilter<"User"> | Date | string
    updatedAt?: DateTimeFilter<"User"> | Date | string
    referredBy?: XOR<UserNullableRelationFilter, UserWhereInput> | null
    referidos?: UserListRelationFilter
    gruposCriados?: GroupListRelationFilter
    memberships?: MembershipListRelationFilter
    contribuicoes?: ContributionListRelationFilter
    cashouts?: CashoutListRelationFilter
    loans?: LoanListRelationFilter
    scoreEvents?: ScoreEventListRelationFilter
    reintegrations?: ReintegrationListRelationFilter
    otps?: OtpListRelationFilter
    sessions?: SessionListRelationFilter
    notifications?: NotificationListRelationFilter
    coverageDecisions?: CoverageDecisionListRelationFilter
    invitesEnviados?: InviteListRelationFilter
    feeConfigsCriadas?: FeeConfigurationListRelationFilter
    auditLogs?: AuditLogListRelationFilter
    creditApplications?: CreditApplicationListRelationFilter
    savingsAccounts?: SavingsAccountListRelationFilter
    referralsCreated?: ReferralListRelationFilter
    referralAsReferred?: ReferralListRelationFilter
    quizAttempts?: QuizAttemptListRelationFilter
    badges?: BadgeListRelationFilter
    insurancePolicies?: InsurancePolicyListRelationFilter
  }, "id" | "telefone" | "email" | "referralCode">

  export type UserOrderByWithAggregationInput = {
    id?: SortOrder
    nome?: SortOrder
    telefone?: SortOrder
    email?: SortOrder
    passwordHash?: SortOrder
    bi?: SortOrderInput | SortOrder
    dataNascimento?: SortOrderInput | SortOrder
    provincia?: SortOrderInput | SortOrder
    pais?: SortOrder
    moedaPreferida?: SortOrder
    fotoPerfilUrl?: SortOrderInput | SortOrder
    kycStatus?: SortOrder
    kycNivel?: SortOrder
    kycDataJson?: SortOrderInput | SortOrder
    status?: SortOrder
    scoreAtual?: SortOrder
    role?: SortOrder
    referralCode?: SortOrderInput | SortOrder
    referredById?: SortOrderInput | SortOrder
    pontosEducacao?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
    _count?: UserCountOrderByAggregateInput
    _avg?: UserAvgOrderByAggregateInput
    _max?: UserMaxOrderByAggregateInput
    _min?: UserMinOrderByAggregateInput
    _sum?: UserSumOrderByAggregateInput
  }

  export type UserScalarWhereWithAggregatesInput = {
    AND?: UserScalarWhereWithAggregatesInput | UserScalarWhereWithAggregatesInput[]
    OR?: UserScalarWhereWithAggregatesInput[]
    NOT?: UserScalarWhereWithAggregatesInput | UserScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"User"> | string
    nome?: StringWithAggregatesFilter<"User"> | string
    telefone?: StringWithAggregatesFilter<"User"> | string
    email?: StringWithAggregatesFilter<"User"> | string
    passwordHash?: StringWithAggregatesFilter<"User"> | string
    bi?: StringNullableWithAggregatesFilter<"User"> | string | null
    dataNascimento?: DateTimeNullableWithAggregatesFilter<"User"> | Date | string | null
    provincia?: StringNullableWithAggregatesFilter<"User"> | string | null
    pais?: StringWithAggregatesFilter<"User"> | string
    moedaPreferida?: StringWithAggregatesFilter<"User"> | string
    fotoPerfilUrl?: StringNullableWithAggregatesFilter<"User"> | string | null
    kycStatus?: StringWithAggregatesFilter<"User"> | string
    kycNivel?: IntWithAggregatesFilter<"User"> | number
    kycDataJson?: StringNullableWithAggregatesFilter<"User"> | string | null
    status?: StringWithAggregatesFilter<"User"> | string
    scoreAtual?: IntWithAggregatesFilter<"User"> | number
    role?: StringWithAggregatesFilter<"User"> | string
    referralCode?: StringNullableWithAggregatesFilter<"User"> | string | null
    referredById?: StringNullableWithAggregatesFilter<"User"> | string | null
    pontosEducacao?: IntWithAggregatesFilter<"User"> | number
    createdAt?: DateTimeWithAggregatesFilter<"User"> | Date | string
    updatedAt?: DateTimeWithAggregatesFilter<"User"> | Date | string
  }

  export type OtpWhereInput = {
    AND?: OtpWhereInput | OtpWhereInput[]
    OR?: OtpWhereInput[]
    NOT?: OtpWhereInput | OtpWhereInput[]
    id?: StringFilter<"Otp"> | string
    userId?: StringNullableFilter<"Otp"> | string | null
    telefone?: StringFilter<"Otp"> | string
    codigo?: StringFilter<"Otp"> | string
    proposito?: StringFilter<"Otp"> | string
    consumido?: BoolFilter<"Otp"> | boolean
    expiraEm?: DateTimeFilter<"Otp"> | Date | string
    createdAt?: DateTimeFilter<"Otp"> | Date | string
    user?: XOR<UserNullableRelationFilter, UserWhereInput> | null
  }

  export type OtpOrderByWithRelationInput = {
    id?: SortOrder
    userId?: SortOrderInput | SortOrder
    telefone?: SortOrder
    codigo?: SortOrder
    proposito?: SortOrder
    consumido?: SortOrder
    expiraEm?: SortOrder
    createdAt?: SortOrder
    user?: UserOrderByWithRelationInput
  }

  export type OtpWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    AND?: OtpWhereInput | OtpWhereInput[]
    OR?: OtpWhereInput[]
    NOT?: OtpWhereInput | OtpWhereInput[]
    userId?: StringNullableFilter<"Otp"> | string | null
    telefone?: StringFilter<"Otp"> | string
    codigo?: StringFilter<"Otp"> | string
    proposito?: StringFilter<"Otp"> | string
    consumido?: BoolFilter<"Otp"> | boolean
    expiraEm?: DateTimeFilter<"Otp"> | Date | string
    createdAt?: DateTimeFilter<"Otp"> | Date | string
    user?: XOR<UserNullableRelationFilter, UserWhereInput> | null
  }, "id">

  export type OtpOrderByWithAggregationInput = {
    id?: SortOrder
    userId?: SortOrderInput | SortOrder
    telefone?: SortOrder
    codigo?: SortOrder
    proposito?: SortOrder
    consumido?: SortOrder
    expiraEm?: SortOrder
    createdAt?: SortOrder
    _count?: OtpCountOrderByAggregateInput
    _max?: OtpMaxOrderByAggregateInput
    _min?: OtpMinOrderByAggregateInput
  }

  export type OtpScalarWhereWithAggregatesInput = {
    AND?: OtpScalarWhereWithAggregatesInput | OtpScalarWhereWithAggregatesInput[]
    OR?: OtpScalarWhereWithAggregatesInput[]
    NOT?: OtpScalarWhereWithAggregatesInput | OtpScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"Otp"> | string
    userId?: StringNullableWithAggregatesFilter<"Otp"> | string | null
    telefone?: StringWithAggregatesFilter<"Otp"> | string
    codigo?: StringWithAggregatesFilter<"Otp"> | string
    proposito?: StringWithAggregatesFilter<"Otp"> | string
    consumido?: BoolWithAggregatesFilter<"Otp"> | boolean
    expiraEm?: DateTimeWithAggregatesFilter<"Otp"> | Date | string
    createdAt?: DateTimeWithAggregatesFilter<"Otp"> | Date | string
  }

  export type SessionWhereInput = {
    AND?: SessionWhereInput | SessionWhereInput[]
    OR?: SessionWhereInput[]
    NOT?: SessionWhereInput | SessionWhereInput[]
    id?: StringFilter<"Session"> | string
    userId?: StringFilter<"Session"> | string
    token?: StringFilter<"Session"> | string
    expiraEm?: DateTimeFilter<"Session"> | Date | string
    createdAt?: DateTimeFilter<"Session"> | Date | string
    user?: XOR<UserRelationFilter, UserWhereInput>
  }

  export type SessionOrderByWithRelationInput = {
    id?: SortOrder
    userId?: SortOrder
    token?: SortOrder
    expiraEm?: SortOrder
    createdAt?: SortOrder
    user?: UserOrderByWithRelationInput
  }

  export type SessionWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    token?: string
    AND?: SessionWhereInput | SessionWhereInput[]
    OR?: SessionWhereInput[]
    NOT?: SessionWhereInput | SessionWhereInput[]
    userId?: StringFilter<"Session"> | string
    expiraEm?: DateTimeFilter<"Session"> | Date | string
    createdAt?: DateTimeFilter<"Session"> | Date | string
    user?: XOR<UserRelationFilter, UserWhereInput>
  }, "id" | "token">

  export type SessionOrderByWithAggregationInput = {
    id?: SortOrder
    userId?: SortOrder
    token?: SortOrder
    expiraEm?: SortOrder
    createdAt?: SortOrder
    _count?: SessionCountOrderByAggregateInput
    _max?: SessionMaxOrderByAggregateInput
    _min?: SessionMinOrderByAggregateInput
  }

  export type SessionScalarWhereWithAggregatesInput = {
    AND?: SessionScalarWhereWithAggregatesInput | SessionScalarWhereWithAggregatesInput[]
    OR?: SessionScalarWhereWithAggregatesInput[]
    NOT?: SessionScalarWhereWithAggregatesInput | SessionScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"Session"> | string
    userId?: StringWithAggregatesFilter<"Session"> | string
    token?: StringWithAggregatesFilter<"Session"> | string
    expiraEm?: DateTimeWithAggregatesFilter<"Session"> | Date | string
    createdAt?: DateTimeWithAggregatesFilter<"Session"> | Date | string
  }

  export type GroupWhereInput = {
    AND?: GroupWhereInput | GroupWhereInput[]
    OR?: GroupWhereInput[]
    NOT?: GroupWhereInput | GroupWhereInput[]
    id?: StringFilter<"Group"> | string
    nome?: StringFilter<"Group"> | string
    descricao?: StringNullableFilter<"Group"> | string | null
    criadorId?: StringFilter<"Group"> | string
    numMembros?: IntFilter<"Group"> | number
    valorContribuicaoMensal?: FloatFilter<"Group"> | number
    taxaPrincipalAplicada?: FloatFilter<"Group"> | number
    reservaTecnicaAplicada?: FloatFilter<"Group"> | number
    periodicidade?: StringFilter<"Group"> | string
    tipo?: StringFilter<"Group"> | string
    pais?: StringFilter<"Group"> | string
    moeda?: StringFilter<"Group"> | string
    status?: StringFilter<"Group"> | string
    dataInicio?: DateTimeNullableFilter<"Group"> | Date | string | null
    dataFimPrevista?: DateTimeNullableFilter<"Group"> | Date | string | null
    cicloAtual?: IntFilter<"Group"> | number
    totalCiclos?: IntFilter<"Group"> | number
    createdAt?: DateTimeFilter<"Group"> | Date | string
    updatedAt?: DateTimeFilter<"Group"> | Date | string
    criador?: XOR<UserRelationFilter, UserWhereInput>
    memberships?: MembershipListRelationFilter
    monthlyCycles?: MonthlyCycleListRelationFilter
    invites?: InviteListRelationFilter
    candidaturas?: GroupApplicationListRelationFilter
  }

  export type GroupOrderByWithRelationInput = {
    id?: SortOrder
    nome?: SortOrder
    descricao?: SortOrderInput | SortOrder
    criadorId?: SortOrder
    numMembros?: SortOrder
    valorContribuicaoMensal?: SortOrder
    taxaPrincipalAplicada?: SortOrder
    reservaTecnicaAplicada?: SortOrder
    periodicidade?: SortOrder
    tipo?: SortOrder
    pais?: SortOrder
    moeda?: SortOrder
    status?: SortOrder
    dataInicio?: SortOrderInput | SortOrder
    dataFimPrevista?: SortOrderInput | SortOrder
    cicloAtual?: SortOrder
    totalCiclos?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
    criador?: UserOrderByWithRelationInput
    memberships?: MembershipOrderByRelationAggregateInput
    monthlyCycles?: MonthlyCycleOrderByRelationAggregateInput
    invites?: InviteOrderByRelationAggregateInput
    candidaturas?: GroupApplicationOrderByRelationAggregateInput
  }

  export type GroupWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    AND?: GroupWhereInput | GroupWhereInput[]
    OR?: GroupWhereInput[]
    NOT?: GroupWhereInput | GroupWhereInput[]
    nome?: StringFilter<"Group"> | string
    descricao?: StringNullableFilter<"Group"> | string | null
    criadorId?: StringFilter<"Group"> | string
    numMembros?: IntFilter<"Group"> | number
    valorContribuicaoMensal?: FloatFilter<"Group"> | number
    taxaPrincipalAplicada?: FloatFilter<"Group"> | number
    reservaTecnicaAplicada?: FloatFilter<"Group"> | number
    periodicidade?: StringFilter<"Group"> | string
    tipo?: StringFilter<"Group"> | string
    pais?: StringFilter<"Group"> | string
    moeda?: StringFilter<"Group"> | string
    status?: StringFilter<"Group"> | string
    dataInicio?: DateTimeNullableFilter<"Group"> | Date | string | null
    dataFimPrevista?: DateTimeNullableFilter<"Group"> | Date | string | null
    cicloAtual?: IntFilter<"Group"> | number
    totalCiclos?: IntFilter<"Group"> | number
    createdAt?: DateTimeFilter<"Group"> | Date | string
    updatedAt?: DateTimeFilter<"Group"> | Date | string
    criador?: XOR<UserRelationFilter, UserWhereInput>
    memberships?: MembershipListRelationFilter
    monthlyCycles?: MonthlyCycleListRelationFilter
    invites?: InviteListRelationFilter
    candidaturas?: GroupApplicationListRelationFilter
  }, "id">

  export type GroupOrderByWithAggregationInput = {
    id?: SortOrder
    nome?: SortOrder
    descricao?: SortOrderInput | SortOrder
    criadorId?: SortOrder
    numMembros?: SortOrder
    valorContribuicaoMensal?: SortOrder
    taxaPrincipalAplicada?: SortOrder
    reservaTecnicaAplicada?: SortOrder
    periodicidade?: SortOrder
    tipo?: SortOrder
    pais?: SortOrder
    moeda?: SortOrder
    status?: SortOrder
    dataInicio?: SortOrderInput | SortOrder
    dataFimPrevista?: SortOrderInput | SortOrder
    cicloAtual?: SortOrder
    totalCiclos?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
    _count?: GroupCountOrderByAggregateInput
    _avg?: GroupAvgOrderByAggregateInput
    _max?: GroupMaxOrderByAggregateInput
    _min?: GroupMinOrderByAggregateInput
    _sum?: GroupSumOrderByAggregateInput
  }

  export type GroupScalarWhereWithAggregatesInput = {
    AND?: GroupScalarWhereWithAggregatesInput | GroupScalarWhereWithAggregatesInput[]
    OR?: GroupScalarWhereWithAggregatesInput[]
    NOT?: GroupScalarWhereWithAggregatesInput | GroupScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"Group"> | string
    nome?: StringWithAggregatesFilter<"Group"> | string
    descricao?: StringNullableWithAggregatesFilter<"Group"> | string | null
    criadorId?: StringWithAggregatesFilter<"Group"> | string
    numMembros?: IntWithAggregatesFilter<"Group"> | number
    valorContribuicaoMensal?: FloatWithAggregatesFilter<"Group"> | number
    taxaPrincipalAplicada?: FloatWithAggregatesFilter<"Group"> | number
    reservaTecnicaAplicada?: FloatWithAggregatesFilter<"Group"> | number
    periodicidade?: StringWithAggregatesFilter<"Group"> | string
    tipo?: StringWithAggregatesFilter<"Group"> | string
    pais?: StringWithAggregatesFilter<"Group"> | string
    moeda?: StringWithAggregatesFilter<"Group"> | string
    status?: StringWithAggregatesFilter<"Group"> | string
    dataInicio?: DateTimeNullableWithAggregatesFilter<"Group"> | Date | string | null
    dataFimPrevista?: DateTimeNullableWithAggregatesFilter<"Group"> | Date | string | null
    cicloAtual?: IntWithAggregatesFilter<"Group"> | number
    totalCiclos?: IntWithAggregatesFilter<"Group"> | number
    createdAt?: DateTimeWithAggregatesFilter<"Group"> | Date | string
    updatedAt?: DateTimeWithAggregatesFilter<"Group"> | Date | string
  }

  export type GroupApplicationWhereInput = {
    AND?: GroupApplicationWhereInput | GroupApplicationWhereInput[]
    OR?: GroupApplicationWhereInput[]
    NOT?: GroupApplicationWhereInput | GroupApplicationWhereInput[]
    id?: StringFilter<"GroupApplication"> | string
    groupId?: StringFilter<"GroupApplication"> | string
    userId?: StringFilter<"GroupApplication"> | string
    mensagem?: StringNullableFilter<"GroupApplication"> | string | null
    status?: StringFilter<"GroupApplication"> | string
    createdAt?: DateTimeFilter<"GroupApplication"> | Date | string
    group?: XOR<GroupRelationFilter, GroupWhereInput>
  }

  export type GroupApplicationOrderByWithRelationInput = {
    id?: SortOrder
    groupId?: SortOrder
    userId?: SortOrder
    mensagem?: SortOrderInput | SortOrder
    status?: SortOrder
    createdAt?: SortOrder
    group?: GroupOrderByWithRelationInput
  }

  export type GroupApplicationWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    groupId_userId?: GroupApplicationGroupIdUserIdCompoundUniqueInput
    AND?: GroupApplicationWhereInput | GroupApplicationWhereInput[]
    OR?: GroupApplicationWhereInput[]
    NOT?: GroupApplicationWhereInput | GroupApplicationWhereInput[]
    groupId?: StringFilter<"GroupApplication"> | string
    userId?: StringFilter<"GroupApplication"> | string
    mensagem?: StringNullableFilter<"GroupApplication"> | string | null
    status?: StringFilter<"GroupApplication"> | string
    createdAt?: DateTimeFilter<"GroupApplication"> | Date | string
    group?: XOR<GroupRelationFilter, GroupWhereInput>
  }, "id" | "groupId_userId">

  export type GroupApplicationOrderByWithAggregationInput = {
    id?: SortOrder
    groupId?: SortOrder
    userId?: SortOrder
    mensagem?: SortOrderInput | SortOrder
    status?: SortOrder
    createdAt?: SortOrder
    _count?: GroupApplicationCountOrderByAggregateInput
    _max?: GroupApplicationMaxOrderByAggregateInput
    _min?: GroupApplicationMinOrderByAggregateInput
  }

  export type GroupApplicationScalarWhereWithAggregatesInput = {
    AND?: GroupApplicationScalarWhereWithAggregatesInput | GroupApplicationScalarWhereWithAggregatesInput[]
    OR?: GroupApplicationScalarWhereWithAggregatesInput[]
    NOT?: GroupApplicationScalarWhereWithAggregatesInput | GroupApplicationScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"GroupApplication"> | string
    groupId?: StringWithAggregatesFilter<"GroupApplication"> | string
    userId?: StringWithAggregatesFilter<"GroupApplication"> | string
    mensagem?: StringNullableWithAggregatesFilter<"GroupApplication"> | string | null
    status?: StringWithAggregatesFilter<"GroupApplication"> | string
    createdAt?: DateTimeWithAggregatesFilter<"GroupApplication"> | Date | string
  }

  export type MembershipWhereInput = {
    AND?: MembershipWhereInput | MembershipWhereInput[]
    OR?: MembershipWhereInput[]
    NOT?: MembershipWhereInput | MembershipWhereInput[]
    id?: StringFilter<"Membership"> | string
    userId?: StringFilter<"Membership"> | string
    groupId?: StringFilter<"Membership"> | string
    posicaoRotacao?: IntNullableFilter<"Membership"> | number | null
    status?: StringFilter<"Membership"> | string
    necessidadeUrgente?: BoolFilter<"Membership"> | boolean
    dataJuncao?: DateTimeFilter<"Membership"> | Date | string
    mesRecepcaoPrevisto?: StringNullableFilter<"Membership"> | string | null
    user?: XOR<UserRelationFilter, UserWhereInput>
    group?: XOR<GroupRelationFilter, GroupWhereInput>
    monthlyCyclesBeneficiario?: MonthlyCycleListRelationFilter
    contribuicoes?: ContributionListRelationFilter
  }

  export type MembershipOrderByWithRelationInput = {
    id?: SortOrder
    userId?: SortOrder
    groupId?: SortOrder
    posicaoRotacao?: SortOrderInput | SortOrder
    status?: SortOrder
    necessidadeUrgente?: SortOrder
    dataJuncao?: SortOrder
    mesRecepcaoPrevisto?: SortOrderInput | SortOrder
    user?: UserOrderByWithRelationInput
    group?: GroupOrderByWithRelationInput
    monthlyCyclesBeneficiario?: MonthlyCycleOrderByRelationAggregateInput
    contribuicoes?: ContributionOrderByRelationAggregateInput
  }

  export type MembershipWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    userId_groupId?: MembershipUserIdGroupIdCompoundUniqueInput
    AND?: MembershipWhereInput | MembershipWhereInput[]
    OR?: MembershipWhereInput[]
    NOT?: MembershipWhereInput | MembershipWhereInput[]
    userId?: StringFilter<"Membership"> | string
    groupId?: StringFilter<"Membership"> | string
    posicaoRotacao?: IntNullableFilter<"Membership"> | number | null
    status?: StringFilter<"Membership"> | string
    necessidadeUrgente?: BoolFilter<"Membership"> | boolean
    dataJuncao?: DateTimeFilter<"Membership"> | Date | string
    mesRecepcaoPrevisto?: StringNullableFilter<"Membership"> | string | null
    user?: XOR<UserRelationFilter, UserWhereInput>
    group?: XOR<GroupRelationFilter, GroupWhereInput>
    monthlyCyclesBeneficiario?: MonthlyCycleListRelationFilter
    contribuicoes?: ContributionListRelationFilter
  }, "id" | "userId_groupId">

  export type MembershipOrderByWithAggregationInput = {
    id?: SortOrder
    userId?: SortOrder
    groupId?: SortOrder
    posicaoRotacao?: SortOrderInput | SortOrder
    status?: SortOrder
    necessidadeUrgente?: SortOrder
    dataJuncao?: SortOrder
    mesRecepcaoPrevisto?: SortOrderInput | SortOrder
    _count?: MembershipCountOrderByAggregateInput
    _avg?: MembershipAvgOrderByAggregateInput
    _max?: MembershipMaxOrderByAggregateInput
    _min?: MembershipMinOrderByAggregateInput
    _sum?: MembershipSumOrderByAggregateInput
  }

  export type MembershipScalarWhereWithAggregatesInput = {
    AND?: MembershipScalarWhereWithAggregatesInput | MembershipScalarWhereWithAggregatesInput[]
    OR?: MembershipScalarWhereWithAggregatesInput[]
    NOT?: MembershipScalarWhereWithAggregatesInput | MembershipScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"Membership"> | string
    userId?: StringWithAggregatesFilter<"Membership"> | string
    groupId?: StringWithAggregatesFilter<"Membership"> | string
    posicaoRotacao?: IntNullableWithAggregatesFilter<"Membership"> | number | null
    status?: StringWithAggregatesFilter<"Membership"> | string
    necessidadeUrgente?: BoolWithAggregatesFilter<"Membership"> | boolean
    dataJuncao?: DateTimeWithAggregatesFilter<"Membership"> | Date | string
    mesRecepcaoPrevisto?: StringNullableWithAggregatesFilter<"Membership"> | string | null
  }

  export type InviteWhereInput = {
    AND?: InviteWhereInput | InviteWhereInput[]
    OR?: InviteWhereInput[]
    NOT?: InviteWhereInput | InviteWhereInput[]
    id?: StringFilter<"Invite"> | string
    groupId?: StringFilter<"Invite"> | string
    convidadoPorId?: StringFilter<"Invite"> | string
    telefone?: StringFilter<"Invite"> | string
    email?: StringNullableFilter<"Invite"> | string | null
    token?: StringFilter<"Invite"> | string
    status?: StringFilter<"Invite"> | string
    createdAt?: DateTimeFilter<"Invite"> | Date | string
    expiraEm?: DateTimeFilter<"Invite"> | Date | string
    group?: XOR<GroupRelationFilter, GroupWhereInput>
    convidadoPor?: XOR<UserRelationFilter, UserWhereInput>
  }

  export type InviteOrderByWithRelationInput = {
    id?: SortOrder
    groupId?: SortOrder
    convidadoPorId?: SortOrder
    telefone?: SortOrder
    email?: SortOrderInput | SortOrder
    token?: SortOrder
    status?: SortOrder
    createdAt?: SortOrder
    expiraEm?: SortOrder
    group?: GroupOrderByWithRelationInput
    convidadoPor?: UserOrderByWithRelationInput
  }

  export type InviteWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    token?: string
    AND?: InviteWhereInput | InviteWhereInput[]
    OR?: InviteWhereInput[]
    NOT?: InviteWhereInput | InviteWhereInput[]
    groupId?: StringFilter<"Invite"> | string
    convidadoPorId?: StringFilter<"Invite"> | string
    telefone?: StringFilter<"Invite"> | string
    email?: StringNullableFilter<"Invite"> | string | null
    status?: StringFilter<"Invite"> | string
    createdAt?: DateTimeFilter<"Invite"> | Date | string
    expiraEm?: DateTimeFilter<"Invite"> | Date | string
    group?: XOR<GroupRelationFilter, GroupWhereInput>
    convidadoPor?: XOR<UserRelationFilter, UserWhereInput>
  }, "id" | "token">

  export type InviteOrderByWithAggregationInput = {
    id?: SortOrder
    groupId?: SortOrder
    convidadoPorId?: SortOrder
    telefone?: SortOrder
    email?: SortOrderInput | SortOrder
    token?: SortOrder
    status?: SortOrder
    createdAt?: SortOrder
    expiraEm?: SortOrder
    _count?: InviteCountOrderByAggregateInput
    _max?: InviteMaxOrderByAggregateInput
    _min?: InviteMinOrderByAggregateInput
  }

  export type InviteScalarWhereWithAggregatesInput = {
    AND?: InviteScalarWhereWithAggregatesInput | InviteScalarWhereWithAggregatesInput[]
    OR?: InviteScalarWhereWithAggregatesInput[]
    NOT?: InviteScalarWhereWithAggregatesInput | InviteScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"Invite"> | string
    groupId?: StringWithAggregatesFilter<"Invite"> | string
    convidadoPorId?: StringWithAggregatesFilter<"Invite"> | string
    telefone?: StringWithAggregatesFilter<"Invite"> | string
    email?: StringNullableWithAggregatesFilter<"Invite"> | string | null
    token?: StringWithAggregatesFilter<"Invite"> | string
    status?: StringWithAggregatesFilter<"Invite"> | string
    createdAt?: DateTimeWithAggregatesFilter<"Invite"> | Date | string
    expiraEm?: DateTimeWithAggregatesFilter<"Invite"> | Date | string
  }

  export type MonthlyCycleWhereInput = {
    AND?: MonthlyCycleWhereInput | MonthlyCycleWhereInput[]
    OR?: MonthlyCycleWhereInput[]
    NOT?: MonthlyCycleWhereInput | MonthlyCycleWhereInput[]
    id?: StringFilter<"MonthlyCycle"> | string
    groupId?: StringFilter<"MonthlyCycle"> | string
    numeroCiclo?: IntFilter<"MonthlyCycle"> | number
    mesAno?: StringFilter<"MonthlyCycle"> | string
    beneficiarioMembershipId?: StringFilter<"MonthlyCycle"> | string
    dataContribuicaoLimite?: DateTimeFilter<"MonthlyCycle"> | Date | string
    dataCashout?: DateTimeFilter<"MonthlyCycle"> | Date | string
    status?: StringFilter<"MonthlyCycle"> | string
    valorPoteBruto?: FloatFilter<"MonthlyCycle"> | number
    valorTaxaPrincipal?: FloatFilter<"MonthlyCycle"> | number
    valorReservaTecnica?: FloatFilter<"MonthlyCycle"> | number
    valorPoteLiquido?: FloatFilter<"MonthlyCycle"> | number
    createdAt?: DateTimeFilter<"MonthlyCycle"> | Date | string
    updatedAt?: DateTimeFilter<"MonthlyCycle"> | Date | string
    group?: XOR<GroupRelationFilter, GroupWhereInput>
    beneficiarioMembership?: XOR<MembershipRelationFilter, MembershipWhereInput>
    contribuicoes?: ContributionListRelationFilter
    cashout?: XOR<CashoutNullableRelationFilter, CashoutWhereInput> | null
    loans?: LoanListRelationFilter
  }

  export type MonthlyCycleOrderByWithRelationInput = {
    id?: SortOrder
    groupId?: SortOrder
    numeroCiclo?: SortOrder
    mesAno?: SortOrder
    beneficiarioMembershipId?: SortOrder
    dataContribuicaoLimite?: SortOrder
    dataCashout?: SortOrder
    status?: SortOrder
    valorPoteBruto?: SortOrder
    valorTaxaPrincipal?: SortOrder
    valorReservaTecnica?: SortOrder
    valorPoteLiquido?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
    group?: GroupOrderByWithRelationInput
    beneficiarioMembership?: MembershipOrderByWithRelationInput
    contribuicoes?: ContributionOrderByRelationAggregateInput
    cashout?: CashoutOrderByWithRelationInput
    loans?: LoanOrderByRelationAggregateInput
  }

  export type MonthlyCycleWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    groupId_numeroCiclo?: MonthlyCycleGroupIdNumeroCicloCompoundUniqueInput
    AND?: MonthlyCycleWhereInput | MonthlyCycleWhereInput[]
    OR?: MonthlyCycleWhereInput[]
    NOT?: MonthlyCycleWhereInput | MonthlyCycleWhereInput[]
    groupId?: StringFilter<"MonthlyCycle"> | string
    numeroCiclo?: IntFilter<"MonthlyCycle"> | number
    mesAno?: StringFilter<"MonthlyCycle"> | string
    beneficiarioMembershipId?: StringFilter<"MonthlyCycle"> | string
    dataContribuicaoLimite?: DateTimeFilter<"MonthlyCycle"> | Date | string
    dataCashout?: DateTimeFilter<"MonthlyCycle"> | Date | string
    status?: StringFilter<"MonthlyCycle"> | string
    valorPoteBruto?: FloatFilter<"MonthlyCycle"> | number
    valorTaxaPrincipal?: FloatFilter<"MonthlyCycle"> | number
    valorReservaTecnica?: FloatFilter<"MonthlyCycle"> | number
    valorPoteLiquido?: FloatFilter<"MonthlyCycle"> | number
    createdAt?: DateTimeFilter<"MonthlyCycle"> | Date | string
    updatedAt?: DateTimeFilter<"MonthlyCycle"> | Date | string
    group?: XOR<GroupRelationFilter, GroupWhereInput>
    beneficiarioMembership?: XOR<MembershipRelationFilter, MembershipWhereInput>
    contribuicoes?: ContributionListRelationFilter
    cashout?: XOR<CashoutNullableRelationFilter, CashoutWhereInput> | null
    loans?: LoanListRelationFilter
  }, "id" | "groupId_numeroCiclo">

  export type MonthlyCycleOrderByWithAggregationInput = {
    id?: SortOrder
    groupId?: SortOrder
    numeroCiclo?: SortOrder
    mesAno?: SortOrder
    beneficiarioMembershipId?: SortOrder
    dataContribuicaoLimite?: SortOrder
    dataCashout?: SortOrder
    status?: SortOrder
    valorPoteBruto?: SortOrder
    valorTaxaPrincipal?: SortOrder
    valorReservaTecnica?: SortOrder
    valorPoteLiquido?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
    _count?: MonthlyCycleCountOrderByAggregateInput
    _avg?: MonthlyCycleAvgOrderByAggregateInput
    _max?: MonthlyCycleMaxOrderByAggregateInput
    _min?: MonthlyCycleMinOrderByAggregateInput
    _sum?: MonthlyCycleSumOrderByAggregateInput
  }

  export type MonthlyCycleScalarWhereWithAggregatesInput = {
    AND?: MonthlyCycleScalarWhereWithAggregatesInput | MonthlyCycleScalarWhereWithAggregatesInput[]
    OR?: MonthlyCycleScalarWhereWithAggregatesInput[]
    NOT?: MonthlyCycleScalarWhereWithAggregatesInput | MonthlyCycleScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"MonthlyCycle"> | string
    groupId?: StringWithAggregatesFilter<"MonthlyCycle"> | string
    numeroCiclo?: IntWithAggregatesFilter<"MonthlyCycle"> | number
    mesAno?: StringWithAggregatesFilter<"MonthlyCycle"> | string
    beneficiarioMembershipId?: StringWithAggregatesFilter<"MonthlyCycle"> | string
    dataContribuicaoLimite?: DateTimeWithAggregatesFilter<"MonthlyCycle"> | Date | string
    dataCashout?: DateTimeWithAggregatesFilter<"MonthlyCycle"> | Date | string
    status?: StringWithAggregatesFilter<"MonthlyCycle"> | string
    valorPoteBruto?: FloatWithAggregatesFilter<"MonthlyCycle"> | number
    valorTaxaPrincipal?: FloatWithAggregatesFilter<"MonthlyCycle"> | number
    valorReservaTecnica?: FloatWithAggregatesFilter<"MonthlyCycle"> | number
    valorPoteLiquido?: FloatWithAggregatesFilter<"MonthlyCycle"> | number
    createdAt?: DateTimeWithAggregatesFilter<"MonthlyCycle"> | Date | string
    updatedAt?: DateTimeWithAggregatesFilter<"MonthlyCycle"> | Date | string
  }

  export type ContributionWhereInput = {
    AND?: ContributionWhereInput | ContributionWhereInput[]
    OR?: ContributionWhereInput[]
    NOT?: ContributionWhereInput | ContributionWhereInput[]
    id?: StringFilter<"Contribution"> | string
    membershipId?: StringFilter<"Contribution"> | string
    userId?: StringFilter<"Contribution"> | string
    monthlyCycleId?: StringFilter<"Contribution"> | string
    valor?: FloatFilter<"Contribution"> | number
    dataPrevista?: DateTimeFilter<"Contribution"> | Date | string
    dataPagamento?: DateTimeNullableFilter<"Contribution"> | Date | string | null
    status?: StringFilter<"Contribution"> | string
    metodoPagamento?: StringNullableFilter<"Contribution"> | string | null
    referenciaBancaria?: StringNullableFilter<"Contribution"> | string | null
    comprovativoUrl?: StringNullableFilter<"Contribution"> | string | null
    createdAt?: DateTimeFilter<"Contribution"> | Date | string
    updatedAt?: DateTimeFilter<"Contribution"> | Date | string
    membership?: XOR<MembershipRelationFilter, MembershipWhereInput>
    user?: XOR<UserRelationFilter, UserWhereInput>
    monthlyCycle?: XOR<MonthlyCycleRelationFilter, MonthlyCycleWhereInput>
    coverageDecision?: XOR<CoverageDecisionNullableRelationFilter, CoverageDecisionWhereInput> | null
  }

  export type ContributionOrderByWithRelationInput = {
    id?: SortOrder
    membershipId?: SortOrder
    userId?: SortOrder
    monthlyCycleId?: SortOrder
    valor?: SortOrder
    dataPrevista?: SortOrder
    dataPagamento?: SortOrderInput | SortOrder
    status?: SortOrder
    metodoPagamento?: SortOrderInput | SortOrder
    referenciaBancaria?: SortOrderInput | SortOrder
    comprovativoUrl?: SortOrderInput | SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
    membership?: MembershipOrderByWithRelationInput
    user?: UserOrderByWithRelationInput
    monthlyCycle?: MonthlyCycleOrderByWithRelationInput
    coverageDecision?: CoverageDecisionOrderByWithRelationInput
  }

  export type ContributionWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    AND?: ContributionWhereInput | ContributionWhereInput[]
    OR?: ContributionWhereInput[]
    NOT?: ContributionWhereInput | ContributionWhereInput[]
    membershipId?: StringFilter<"Contribution"> | string
    userId?: StringFilter<"Contribution"> | string
    monthlyCycleId?: StringFilter<"Contribution"> | string
    valor?: FloatFilter<"Contribution"> | number
    dataPrevista?: DateTimeFilter<"Contribution"> | Date | string
    dataPagamento?: DateTimeNullableFilter<"Contribution"> | Date | string | null
    status?: StringFilter<"Contribution"> | string
    metodoPagamento?: StringNullableFilter<"Contribution"> | string | null
    referenciaBancaria?: StringNullableFilter<"Contribution"> | string | null
    comprovativoUrl?: StringNullableFilter<"Contribution"> | string | null
    createdAt?: DateTimeFilter<"Contribution"> | Date | string
    updatedAt?: DateTimeFilter<"Contribution"> | Date | string
    membership?: XOR<MembershipRelationFilter, MembershipWhereInput>
    user?: XOR<UserRelationFilter, UserWhereInput>
    monthlyCycle?: XOR<MonthlyCycleRelationFilter, MonthlyCycleWhereInput>
    coverageDecision?: XOR<CoverageDecisionNullableRelationFilter, CoverageDecisionWhereInput> | null
  }, "id">

  export type ContributionOrderByWithAggregationInput = {
    id?: SortOrder
    membershipId?: SortOrder
    userId?: SortOrder
    monthlyCycleId?: SortOrder
    valor?: SortOrder
    dataPrevista?: SortOrder
    dataPagamento?: SortOrderInput | SortOrder
    status?: SortOrder
    metodoPagamento?: SortOrderInput | SortOrder
    referenciaBancaria?: SortOrderInput | SortOrder
    comprovativoUrl?: SortOrderInput | SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
    _count?: ContributionCountOrderByAggregateInput
    _avg?: ContributionAvgOrderByAggregateInput
    _max?: ContributionMaxOrderByAggregateInput
    _min?: ContributionMinOrderByAggregateInput
    _sum?: ContributionSumOrderByAggregateInput
  }

  export type ContributionScalarWhereWithAggregatesInput = {
    AND?: ContributionScalarWhereWithAggregatesInput | ContributionScalarWhereWithAggregatesInput[]
    OR?: ContributionScalarWhereWithAggregatesInput[]
    NOT?: ContributionScalarWhereWithAggregatesInput | ContributionScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"Contribution"> | string
    membershipId?: StringWithAggregatesFilter<"Contribution"> | string
    userId?: StringWithAggregatesFilter<"Contribution"> | string
    monthlyCycleId?: StringWithAggregatesFilter<"Contribution"> | string
    valor?: FloatWithAggregatesFilter<"Contribution"> | number
    dataPrevista?: DateTimeWithAggregatesFilter<"Contribution"> | Date | string
    dataPagamento?: DateTimeNullableWithAggregatesFilter<"Contribution"> | Date | string | null
    status?: StringWithAggregatesFilter<"Contribution"> | string
    metodoPagamento?: StringNullableWithAggregatesFilter<"Contribution"> | string | null
    referenciaBancaria?: StringNullableWithAggregatesFilter<"Contribution"> | string | null
    comprovativoUrl?: StringNullableWithAggregatesFilter<"Contribution"> | string | null
    createdAt?: DateTimeWithAggregatesFilter<"Contribution"> | Date | string
    updatedAt?: DateTimeWithAggregatesFilter<"Contribution"> | Date | string
  }

  export type CashoutWhereInput = {
    AND?: CashoutWhereInput | CashoutWhereInput[]
    OR?: CashoutWhereInput[]
    NOT?: CashoutWhereInput | CashoutWhereInput[]
    id?: StringFilter<"Cashout"> | string
    monthlyCycleId?: StringFilter<"Cashout"> | string
    beneficiarioUserId?: StringFilter<"Cashout"> | string
    valorBruto?: FloatFilter<"Cashout"> | number
    valorTaxaPrincipal?: FloatFilter<"Cashout"> | number
    valorReservaTecnica?: FloatFilter<"Cashout"> | number
    valorLiquido?: FloatFilter<"Cashout"> | number
    dataPrevista?: DateTimeFilter<"Cashout"> | Date | string
    dataExecucao?: DateTimeNullableFilter<"Cashout"> | Date | string | null
    status?: StringFilter<"Cashout"> | string
    contaDestino?: StringNullableFilter<"Cashout"> | string | null
    refTransferencia?: StringNullableFilter<"Cashout"> | string | null
    parcialMotivo?: StringNullableFilter<"Cashout"> | string | null
    createdAt?: DateTimeFilter<"Cashout"> | Date | string
    updatedAt?: DateTimeFilter<"Cashout"> | Date | string
    monthlyCycle?: XOR<MonthlyCycleRelationFilter, MonthlyCycleWhereInput>
    beneficiarioUser?: XOR<UserRelationFilter, UserWhereInput>
  }

  export type CashoutOrderByWithRelationInput = {
    id?: SortOrder
    monthlyCycleId?: SortOrder
    beneficiarioUserId?: SortOrder
    valorBruto?: SortOrder
    valorTaxaPrincipal?: SortOrder
    valorReservaTecnica?: SortOrder
    valorLiquido?: SortOrder
    dataPrevista?: SortOrder
    dataExecucao?: SortOrderInput | SortOrder
    status?: SortOrder
    contaDestino?: SortOrderInput | SortOrder
    refTransferencia?: SortOrderInput | SortOrder
    parcialMotivo?: SortOrderInput | SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
    monthlyCycle?: MonthlyCycleOrderByWithRelationInput
    beneficiarioUser?: UserOrderByWithRelationInput
  }

  export type CashoutWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    monthlyCycleId?: string
    AND?: CashoutWhereInput | CashoutWhereInput[]
    OR?: CashoutWhereInput[]
    NOT?: CashoutWhereInput | CashoutWhereInput[]
    beneficiarioUserId?: StringFilter<"Cashout"> | string
    valorBruto?: FloatFilter<"Cashout"> | number
    valorTaxaPrincipal?: FloatFilter<"Cashout"> | number
    valorReservaTecnica?: FloatFilter<"Cashout"> | number
    valorLiquido?: FloatFilter<"Cashout"> | number
    dataPrevista?: DateTimeFilter<"Cashout"> | Date | string
    dataExecucao?: DateTimeNullableFilter<"Cashout"> | Date | string | null
    status?: StringFilter<"Cashout"> | string
    contaDestino?: StringNullableFilter<"Cashout"> | string | null
    refTransferencia?: StringNullableFilter<"Cashout"> | string | null
    parcialMotivo?: StringNullableFilter<"Cashout"> | string | null
    createdAt?: DateTimeFilter<"Cashout"> | Date | string
    updatedAt?: DateTimeFilter<"Cashout"> | Date | string
    monthlyCycle?: XOR<MonthlyCycleRelationFilter, MonthlyCycleWhereInput>
    beneficiarioUser?: XOR<UserRelationFilter, UserWhereInput>
  }, "id" | "monthlyCycleId">

  export type CashoutOrderByWithAggregationInput = {
    id?: SortOrder
    monthlyCycleId?: SortOrder
    beneficiarioUserId?: SortOrder
    valorBruto?: SortOrder
    valorTaxaPrincipal?: SortOrder
    valorReservaTecnica?: SortOrder
    valorLiquido?: SortOrder
    dataPrevista?: SortOrder
    dataExecucao?: SortOrderInput | SortOrder
    status?: SortOrder
    contaDestino?: SortOrderInput | SortOrder
    refTransferencia?: SortOrderInput | SortOrder
    parcialMotivo?: SortOrderInput | SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
    _count?: CashoutCountOrderByAggregateInput
    _avg?: CashoutAvgOrderByAggregateInput
    _max?: CashoutMaxOrderByAggregateInput
    _min?: CashoutMinOrderByAggregateInput
    _sum?: CashoutSumOrderByAggregateInput
  }

  export type CashoutScalarWhereWithAggregatesInput = {
    AND?: CashoutScalarWhereWithAggregatesInput | CashoutScalarWhereWithAggregatesInput[]
    OR?: CashoutScalarWhereWithAggregatesInput[]
    NOT?: CashoutScalarWhereWithAggregatesInput | CashoutScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"Cashout"> | string
    monthlyCycleId?: StringWithAggregatesFilter<"Cashout"> | string
    beneficiarioUserId?: StringWithAggregatesFilter<"Cashout"> | string
    valorBruto?: FloatWithAggregatesFilter<"Cashout"> | number
    valorTaxaPrincipal?: FloatWithAggregatesFilter<"Cashout"> | number
    valorReservaTecnica?: FloatWithAggregatesFilter<"Cashout"> | number
    valorLiquido?: FloatWithAggregatesFilter<"Cashout"> | number
    dataPrevista?: DateTimeWithAggregatesFilter<"Cashout"> | Date | string
    dataExecucao?: DateTimeNullableWithAggregatesFilter<"Cashout"> | Date | string | null
    status?: StringWithAggregatesFilter<"Cashout"> | string
    contaDestino?: StringNullableWithAggregatesFilter<"Cashout"> | string | null
    refTransferencia?: StringNullableWithAggregatesFilter<"Cashout"> | string | null
    parcialMotivo?: StringNullableWithAggregatesFilter<"Cashout"> | string | null
    createdAt?: DateTimeWithAggregatesFilter<"Cashout"> | Date | string
    updatedAt?: DateTimeWithAggregatesFilter<"Cashout"> | Date | string
  }

  export type LoanWhereInput = {
    AND?: LoanWhereInput | LoanWhereInput[]
    OR?: LoanWhereInput[]
    NOT?: LoanWhereInput | LoanWhereInput[]
    id?: StringFilter<"Loan"> | string
    userId?: StringFilter<"Loan"> | string
    monthlyCycleId?: StringFilter<"Loan"> | string
    contributionId?: StringNullableFilter<"Loan"> | string | null
    valorCapital?: FloatFilter<"Loan"> | number
    taxaEmprestimo?: FloatFilter<"Loan"> | number
    valorTotalDevido?: FloatFilter<"Loan"> | number
    jurosMoraAcumulados?: FloatFilter<"Loan"> | number
    dataInicio?: DateTimeFilter<"Loan"> | Date | string
    dataPagamento?: DateTimeNullableFilter<"Loan"> | Date | string | null
    status?: StringFilter<"Loan"> | string
    createdAt?: DateTimeFilter<"Loan"> | Date | string
    updatedAt?: DateTimeFilter<"Loan"> | Date | string
    user?: XOR<UserRelationFilter, UserWhereInput>
    monthlyCycle?: XOR<MonthlyCycleRelationFilter, MonthlyCycleWhereInput>
  }

  export type LoanOrderByWithRelationInput = {
    id?: SortOrder
    userId?: SortOrder
    monthlyCycleId?: SortOrder
    contributionId?: SortOrderInput | SortOrder
    valorCapital?: SortOrder
    taxaEmprestimo?: SortOrder
    valorTotalDevido?: SortOrder
    jurosMoraAcumulados?: SortOrder
    dataInicio?: SortOrder
    dataPagamento?: SortOrderInput | SortOrder
    status?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
    user?: UserOrderByWithRelationInput
    monthlyCycle?: MonthlyCycleOrderByWithRelationInput
  }

  export type LoanWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    contributionId?: string
    AND?: LoanWhereInput | LoanWhereInput[]
    OR?: LoanWhereInput[]
    NOT?: LoanWhereInput | LoanWhereInput[]
    userId?: StringFilter<"Loan"> | string
    monthlyCycleId?: StringFilter<"Loan"> | string
    valorCapital?: FloatFilter<"Loan"> | number
    taxaEmprestimo?: FloatFilter<"Loan"> | number
    valorTotalDevido?: FloatFilter<"Loan"> | number
    jurosMoraAcumulados?: FloatFilter<"Loan"> | number
    dataInicio?: DateTimeFilter<"Loan"> | Date | string
    dataPagamento?: DateTimeNullableFilter<"Loan"> | Date | string | null
    status?: StringFilter<"Loan"> | string
    createdAt?: DateTimeFilter<"Loan"> | Date | string
    updatedAt?: DateTimeFilter<"Loan"> | Date | string
    user?: XOR<UserRelationFilter, UserWhereInput>
    monthlyCycle?: XOR<MonthlyCycleRelationFilter, MonthlyCycleWhereInput>
  }, "id" | "contributionId">

  export type LoanOrderByWithAggregationInput = {
    id?: SortOrder
    userId?: SortOrder
    monthlyCycleId?: SortOrder
    contributionId?: SortOrderInput | SortOrder
    valorCapital?: SortOrder
    taxaEmprestimo?: SortOrder
    valorTotalDevido?: SortOrder
    jurosMoraAcumulados?: SortOrder
    dataInicio?: SortOrder
    dataPagamento?: SortOrderInput | SortOrder
    status?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
    _count?: LoanCountOrderByAggregateInput
    _avg?: LoanAvgOrderByAggregateInput
    _max?: LoanMaxOrderByAggregateInput
    _min?: LoanMinOrderByAggregateInput
    _sum?: LoanSumOrderByAggregateInput
  }

  export type LoanScalarWhereWithAggregatesInput = {
    AND?: LoanScalarWhereWithAggregatesInput | LoanScalarWhereWithAggregatesInput[]
    OR?: LoanScalarWhereWithAggregatesInput[]
    NOT?: LoanScalarWhereWithAggregatesInput | LoanScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"Loan"> | string
    userId?: StringWithAggregatesFilter<"Loan"> | string
    monthlyCycleId?: StringWithAggregatesFilter<"Loan"> | string
    contributionId?: StringNullableWithAggregatesFilter<"Loan"> | string | null
    valorCapital?: FloatWithAggregatesFilter<"Loan"> | number
    taxaEmprestimo?: FloatWithAggregatesFilter<"Loan"> | number
    valorTotalDevido?: FloatWithAggregatesFilter<"Loan"> | number
    jurosMoraAcumulados?: FloatWithAggregatesFilter<"Loan"> | number
    dataInicio?: DateTimeWithAggregatesFilter<"Loan"> | Date | string
    dataPagamento?: DateTimeNullableWithAggregatesFilter<"Loan"> | Date | string | null
    status?: StringWithAggregatesFilter<"Loan"> | string
    createdAt?: DateTimeWithAggregatesFilter<"Loan"> | Date | string
    updatedAt?: DateTimeWithAggregatesFilter<"Loan"> | Date | string
  }

  export type CoverageDecisionWhereInput = {
    AND?: CoverageDecisionWhereInput | CoverageDecisionWhereInput[]
    OR?: CoverageDecisionWhereInput[]
    NOT?: CoverageDecisionWhereInput | CoverageDecisionWhereInput[]
    id?: StringFilter<"CoverageDecision"> | string
    contributionId?: StringFilter<"CoverageDecision"> | string
    decisao?: StringFilter<"CoverageDecision"> | string
    motivo?: StringFilter<"CoverageDecision"> | string
    scoreNoMomento?: IntFilter<"CoverageDecision"> | number
    historicoInadimplencias?: IntFilter<"CoverageDecision"> | number
    decisorUserId?: StringNullableFilter<"CoverageDecision"> | string | null
    decisorSistema?: BoolFilter<"CoverageDecision"> | boolean
    createdAt?: DateTimeFilter<"CoverageDecision"> | Date | string
    contribution?: XOR<ContributionRelationFilter, ContributionWhereInput>
    decisorUser?: XOR<UserNullableRelationFilter, UserWhereInput> | null
  }

  export type CoverageDecisionOrderByWithRelationInput = {
    id?: SortOrder
    contributionId?: SortOrder
    decisao?: SortOrder
    motivo?: SortOrder
    scoreNoMomento?: SortOrder
    historicoInadimplencias?: SortOrder
    decisorUserId?: SortOrderInput | SortOrder
    decisorSistema?: SortOrder
    createdAt?: SortOrder
    contribution?: ContributionOrderByWithRelationInput
    decisorUser?: UserOrderByWithRelationInput
  }

  export type CoverageDecisionWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    contributionId?: string
    AND?: CoverageDecisionWhereInput | CoverageDecisionWhereInput[]
    OR?: CoverageDecisionWhereInput[]
    NOT?: CoverageDecisionWhereInput | CoverageDecisionWhereInput[]
    decisao?: StringFilter<"CoverageDecision"> | string
    motivo?: StringFilter<"CoverageDecision"> | string
    scoreNoMomento?: IntFilter<"CoverageDecision"> | number
    historicoInadimplencias?: IntFilter<"CoverageDecision"> | number
    decisorUserId?: StringNullableFilter<"CoverageDecision"> | string | null
    decisorSistema?: BoolFilter<"CoverageDecision"> | boolean
    createdAt?: DateTimeFilter<"CoverageDecision"> | Date | string
    contribution?: XOR<ContributionRelationFilter, ContributionWhereInput>
    decisorUser?: XOR<UserNullableRelationFilter, UserWhereInput> | null
  }, "id" | "contributionId">

  export type CoverageDecisionOrderByWithAggregationInput = {
    id?: SortOrder
    contributionId?: SortOrder
    decisao?: SortOrder
    motivo?: SortOrder
    scoreNoMomento?: SortOrder
    historicoInadimplencias?: SortOrder
    decisorUserId?: SortOrderInput | SortOrder
    decisorSistema?: SortOrder
    createdAt?: SortOrder
    _count?: CoverageDecisionCountOrderByAggregateInput
    _avg?: CoverageDecisionAvgOrderByAggregateInput
    _max?: CoverageDecisionMaxOrderByAggregateInput
    _min?: CoverageDecisionMinOrderByAggregateInput
    _sum?: CoverageDecisionSumOrderByAggregateInput
  }

  export type CoverageDecisionScalarWhereWithAggregatesInput = {
    AND?: CoverageDecisionScalarWhereWithAggregatesInput | CoverageDecisionScalarWhereWithAggregatesInput[]
    OR?: CoverageDecisionScalarWhereWithAggregatesInput[]
    NOT?: CoverageDecisionScalarWhereWithAggregatesInput | CoverageDecisionScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"CoverageDecision"> | string
    contributionId?: StringWithAggregatesFilter<"CoverageDecision"> | string
    decisao?: StringWithAggregatesFilter<"CoverageDecision"> | string
    motivo?: StringWithAggregatesFilter<"CoverageDecision"> | string
    scoreNoMomento?: IntWithAggregatesFilter<"CoverageDecision"> | number
    historicoInadimplencias?: IntWithAggregatesFilter<"CoverageDecision"> | number
    decisorUserId?: StringNullableWithAggregatesFilter<"CoverageDecision"> | string | null
    decisorSistema?: BoolWithAggregatesFilter<"CoverageDecision"> | boolean
    createdAt?: DateTimeWithAggregatesFilter<"CoverageDecision"> | Date | string
  }

  export type ReintegrationWhereInput = {
    AND?: ReintegrationWhereInput | ReintegrationWhereInput[]
    OR?: ReintegrationWhereInput[]
    NOT?: ReintegrationWhereInput | ReintegrationWhereInput[]
    id?: StringFilter<"Reintegration"> | string
    userId?: StringFilter<"Reintegration"> | string
    valorDividaOriginal?: FloatFilter<"Reintegration"> | number
    taxaReintegracaoAplicada?: FloatFilter<"Reintegration"> | number
    valorTaxaPaga?: FloatFilter<"Reintegration"> | number
    dataSolicitacao?: DateTimeFilter<"Reintegration"> | Date | string
    dataConclusao?: DateTimeNullableFilter<"Reintegration"> | Date | string | null
    status?: StringFilter<"Reintegration"> | string
    user?: XOR<UserRelationFilter, UserWhereInput>
  }

  export type ReintegrationOrderByWithRelationInput = {
    id?: SortOrder
    userId?: SortOrder
    valorDividaOriginal?: SortOrder
    taxaReintegracaoAplicada?: SortOrder
    valorTaxaPaga?: SortOrder
    dataSolicitacao?: SortOrder
    dataConclusao?: SortOrderInput | SortOrder
    status?: SortOrder
    user?: UserOrderByWithRelationInput
  }

  export type ReintegrationWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    AND?: ReintegrationWhereInput | ReintegrationWhereInput[]
    OR?: ReintegrationWhereInput[]
    NOT?: ReintegrationWhereInput | ReintegrationWhereInput[]
    userId?: StringFilter<"Reintegration"> | string
    valorDividaOriginal?: FloatFilter<"Reintegration"> | number
    taxaReintegracaoAplicada?: FloatFilter<"Reintegration"> | number
    valorTaxaPaga?: FloatFilter<"Reintegration"> | number
    dataSolicitacao?: DateTimeFilter<"Reintegration"> | Date | string
    dataConclusao?: DateTimeNullableFilter<"Reintegration"> | Date | string | null
    status?: StringFilter<"Reintegration"> | string
    user?: XOR<UserRelationFilter, UserWhereInput>
  }, "id">

  export type ReintegrationOrderByWithAggregationInput = {
    id?: SortOrder
    userId?: SortOrder
    valorDividaOriginal?: SortOrder
    taxaReintegracaoAplicada?: SortOrder
    valorTaxaPaga?: SortOrder
    dataSolicitacao?: SortOrder
    dataConclusao?: SortOrderInput | SortOrder
    status?: SortOrder
    _count?: ReintegrationCountOrderByAggregateInput
    _avg?: ReintegrationAvgOrderByAggregateInput
    _max?: ReintegrationMaxOrderByAggregateInput
    _min?: ReintegrationMinOrderByAggregateInput
    _sum?: ReintegrationSumOrderByAggregateInput
  }

  export type ReintegrationScalarWhereWithAggregatesInput = {
    AND?: ReintegrationScalarWhereWithAggregatesInput | ReintegrationScalarWhereWithAggregatesInput[]
    OR?: ReintegrationScalarWhereWithAggregatesInput[]
    NOT?: ReintegrationScalarWhereWithAggregatesInput | ReintegrationScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"Reintegration"> | string
    userId?: StringWithAggregatesFilter<"Reintegration"> | string
    valorDividaOriginal?: FloatWithAggregatesFilter<"Reintegration"> | number
    taxaReintegracaoAplicada?: FloatWithAggregatesFilter<"Reintegration"> | number
    valorTaxaPaga?: FloatWithAggregatesFilter<"Reintegration"> | number
    dataSolicitacao?: DateTimeWithAggregatesFilter<"Reintegration"> | Date | string
    dataConclusao?: DateTimeNullableWithAggregatesFilter<"Reintegration"> | Date | string | null
    status?: StringWithAggregatesFilter<"Reintegration"> | string
  }

  export type FeeConfigurationWhereInput = {
    AND?: FeeConfigurationWhereInput | FeeConfigurationWhereInput[]
    OR?: FeeConfigurationWhereInput[]
    NOT?: FeeConfigurationWhereInput | FeeConfigurationWhereInput[]
    id?: StringFilter<"FeeConfiguration"> | string
    tipoFee?: StringFilter<"FeeConfiguration"> | string
    valor?: FloatFilter<"FeeConfiguration"> | number
    min?: FloatFilter<"FeeConfiguration"> | number
    max?: FloatFilter<"FeeConfiguration"> | number
    dataInicio?: DateTimeFilter<"FeeConfiguration"> | Date | string
    dataFim?: DateTimeNullableFilter<"FeeConfiguration"> | Date | string | null
    criadoPorId?: StringNullableFilter<"FeeConfiguration"> | string | null
    motivoMudanca?: StringNullableFilter<"FeeConfiguration"> | string | null
    ativa?: BoolFilter<"FeeConfiguration"> | boolean
    createdAt?: DateTimeFilter<"FeeConfiguration"> | Date | string
    criadoPor?: XOR<UserNullableRelationFilter, UserWhereInput> | null
  }

  export type FeeConfigurationOrderByWithRelationInput = {
    id?: SortOrder
    tipoFee?: SortOrder
    valor?: SortOrder
    min?: SortOrder
    max?: SortOrder
    dataInicio?: SortOrder
    dataFim?: SortOrderInput | SortOrder
    criadoPorId?: SortOrderInput | SortOrder
    motivoMudanca?: SortOrderInput | SortOrder
    ativa?: SortOrder
    createdAt?: SortOrder
    criadoPor?: UserOrderByWithRelationInput
  }

  export type FeeConfigurationWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    AND?: FeeConfigurationWhereInput | FeeConfigurationWhereInput[]
    OR?: FeeConfigurationWhereInput[]
    NOT?: FeeConfigurationWhereInput | FeeConfigurationWhereInput[]
    tipoFee?: StringFilter<"FeeConfiguration"> | string
    valor?: FloatFilter<"FeeConfiguration"> | number
    min?: FloatFilter<"FeeConfiguration"> | number
    max?: FloatFilter<"FeeConfiguration"> | number
    dataInicio?: DateTimeFilter<"FeeConfiguration"> | Date | string
    dataFim?: DateTimeNullableFilter<"FeeConfiguration"> | Date | string | null
    criadoPorId?: StringNullableFilter<"FeeConfiguration"> | string | null
    motivoMudanca?: StringNullableFilter<"FeeConfiguration"> | string | null
    ativa?: BoolFilter<"FeeConfiguration"> | boolean
    createdAt?: DateTimeFilter<"FeeConfiguration"> | Date | string
    criadoPor?: XOR<UserNullableRelationFilter, UserWhereInput> | null
  }, "id">

  export type FeeConfigurationOrderByWithAggregationInput = {
    id?: SortOrder
    tipoFee?: SortOrder
    valor?: SortOrder
    min?: SortOrder
    max?: SortOrder
    dataInicio?: SortOrder
    dataFim?: SortOrderInput | SortOrder
    criadoPorId?: SortOrderInput | SortOrder
    motivoMudanca?: SortOrderInput | SortOrder
    ativa?: SortOrder
    createdAt?: SortOrder
    _count?: FeeConfigurationCountOrderByAggregateInput
    _avg?: FeeConfigurationAvgOrderByAggregateInput
    _max?: FeeConfigurationMaxOrderByAggregateInput
    _min?: FeeConfigurationMinOrderByAggregateInput
    _sum?: FeeConfigurationSumOrderByAggregateInput
  }

  export type FeeConfigurationScalarWhereWithAggregatesInput = {
    AND?: FeeConfigurationScalarWhereWithAggregatesInput | FeeConfigurationScalarWhereWithAggregatesInput[]
    OR?: FeeConfigurationScalarWhereWithAggregatesInput[]
    NOT?: FeeConfigurationScalarWhereWithAggregatesInput | FeeConfigurationScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"FeeConfiguration"> | string
    tipoFee?: StringWithAggregatesFilter<"FeeConfiguration"> | string
    valor?: FloatWithAggregatesFilter<"FeeConfiguration"> | number
    min?: FloatWithAggregatesFilter<"FeeConfiguration"> | number
    max?: FloatWithAggregatesFilter<"FeeConfiguration"> | number
    dataInicio?: DateTimeWithAggregatesFilter<"FeeConfiguration"> | Date | string
    dataFim?: DateTimeNullableWithAggregatesFilter<"FeeConfiguration"> | Date | string | null
    criadoPorId?: StringNullableWithAggregatesFilter<"FeeConfiguration"> | string | null
    motivoMudanca?: StringNullableWithAggregatesFilter<"FeeConfiguration"> | string | null
    ativa?: BoolWithAggregatesFilter<"FeeConfiguration"> | boolean
    createdAt?: DateTimeWithAggregatesFilter<"FeeConfiguration"> | Date | string
  }

  export type CoverageFundWhereInput = {
    AND?: CoverageFundWhereInput | CoverageFundWhereInput[]
    OR?: CoverageFundWhereInput[]
    NOT?: CoverageFundWhereInput | CoverageFundWhereInput[]
    id?: StringFilter<"CoverageFund"> | string
    saldoDisponivel?: FloatFilter<"CoverageFund"> | number
    saldoEmEmprestimosActivos?: FloatFilter<"CoverageFund"> | number
    totalRecuperadoAno?: FloatFilter<"CoverageFund"> | number
    totalPerdidoAno?: FloatFilter<"CoverageFund"> | number
    lastUpdated?: DateTimeFilter<"CoverageFund"> | Date | string
  }

  export type CoverageFundOrderByWithRelationInput = {
    id?: SortOrder
    saldoDisponivel?: SortOrder
    saldoEmEmprestimosActivos?: SortOrder
    totalRecuperadoAno?: SortOrder
    totalPerdidoAno?: SortOrder
    lastUpdated?: SortOrder
  }

  export type CoverageFundWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    AND?: CoverageFundWhereInput | CoverageFundWhereInput[]
    OR?: CoverageFundWhereInput[]
    NOT?: CoverageFundWhereInput | CoverageFundWhereInput[]
    saldoDisponivel?: FloatFilter<"CoverageFund"> | number
    saldoEmEmprestimosActivos?: FloatFilter<"CoverageFund"> | number
    totalRecuperadoAno?: FloatFilter<"CoverageFund"> | number
    totalPerdidoAno?: FloatFilter<"CoverageFund"> | number
    lastUpdated?: DateTimeFilter<"CoverageFund"> | Date | string
  }, "id">

  export type CoverageFundOrderByWithAggregationInput = {
    id?: SortOrder
    saldoDisponivel?: SortOrder
    saldoEmEmprestimosActivos?: SortOrder
    totalRecuperadoAno?: SortOrder
    totalPerdidoAno?: SortOrder
    lastUpdated?: SortOrder
    _count?: CoverageFundCountOrderByAggregateInput
    _avg?: CoverageFundAvgOrderByAggregateInput
    _max?: CoverageFundMaxOrderByAggregateInput
    _min?: CoverageFundMinOrderByAggregateInput
    _sum?: CoverageFundSumOrderByAggregateInput
  }

  export type CoverageFundScalarWhereWithAggregatesInput = {
    AND?: CoverageFundScalarWhereWithAggregatesInput | CoverageFundScalarWhereWithAggregatesInput[]
    OR?: CoverageFundScalarWhereWithAggregatesInput[]
    NOT?: CoverageFundScalarWhereWithAggregatesInput | CoverageFundScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"CoverageFund"> | string
    saldoDisponivel?: FloatWithAggregatesFilter<"CoverageFund"> | number
    saldoEmEmprestimosActivos?: FloatWithAggregatesFilter<"CoverageFund"> | number
    totalRecuperadoAno?: FloatWithAggregatesFilter<"CoverageFund"> | number
    totalPerdidoAno?: FloatWithAggregatesFilter<"CoverageFund"> | number
    lastUpdated?: DateTimeWithAggregatesFilter<"CoverageFund"> | Date | string
  }

  export type TransactionWhereInput = {
    AND?: TransactionWhereInput | TransactionWhereInput[]
    OR?: TransactionWhereInput[]
    NOT?: TransactionWhereInput | TransactionWhereInput[]
    id?: StringFilter<"Transaction"> | string
    tipo?: StringFilter<"Transaction"> | string
    valor?: FloatFilter<"Transaction"> | number
    fromAccount?: StringFilter<"Transaction"> | string
    toAccount?: StringFilter<"Transaction"> | string
    referencia?: StringNullableFilter<"Transaction"> | string | null
    status?: StringFilter<"Transaction"> | string
    timestamp?: DateTimeFilter<"Transaction"> | Date | string
    auditJson?: StringNullableFilter<"Transaction"> | string | null
  }

  export type TransactionOrderByWithRelationInput = {
    id?: SortOrder
    tipo?: SortOrder
    valor?: SortOrder
    fromAccount?: SortOrder
    toAccount?: SortOrder
    referencia?: SortOrderInput | SortOrder
    status?: SortOrder
    timestamp?: SortOrder
    auditJson?: SortOrderInput | SortOrder
  }

  export type TransactionWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    AND?: TransactionWhereInput | TransactionWhereInput[]
    OR?: TransactionWhereInput[]
    NOT?: TransactionWhereInput | TransactionWhereInput[]
    tipo?: StringFilter<"Transaction"> | string
    valor?: FloatFilter<"Transaction"> | number
    fromAccount?: StringFilter<"Transaction"> | string
    toAccount?: StringFilter<"Transaction"> | string
    referencia?: StringNullableFilter<"Transaction"> | string | null
    status?: StringFilter<"Transaction"> | string
    timestamp?: DateTimeFilter<"Transaction"> | Date | string
    auditJson?: StringNullableFilter<"Transaction"> | string | null
  }, "id">

  export type TransactionOrderByWithAggregationInput = {
    id?: SortOrder
    tipo?: SortOrder
    valor?: SortOrder
    fromAccount?: SortOrder
    toAccount?: SortOrder
    referencia?: SortOrderInput | SortOrder
    status?: SortOrder
    timestamp?: SortOrder
    auditJson?: SortOrderInput | SortOrder
    _count?: TransactionCountOrderByAggregateInput
    _avg?: TransactionAvgOrderByAggregateInput
    _max?: TransactionMaxOrderByAggregateInput
    _min?: TransactionMinOrderByAggregateInput
    _sum?: TransactionSumOrderByAggregateInput
  }

  export type TransactionScalarWhereWithAggregatesInput = {
    AND?: TransactionScalarWhereWithAggregatesInput | TransactionScalarWhereWithAggregatesInput[]
    OR?: TransactionScalarWhereWithAggregatesInput[]
    NOT?: TransactionScalarWhereWithAggregatesInput | TransactionScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"Transaction"> | string
    tipo?: StringWithAggregatesFilter<"Transaction"> | string
    valor?: FloatWithAggregatesFilter<"Transaction"> | number
    fromAccount?: StringWithAggregatesFilter<"Transaction"> | string
    toAccount?: StringWithAggregatesFilter<"Transaction"> | string
    referencia?: StringNullableWithAggregatesFilter<"Transaction"> | string | null
    status?: StringWithAggregatesFilter<"Transaction"> | string
    timestamp?: DateTimeWithAggregatesFilter<"Transaction"> | Date | string
    auditJson?: StringNullableWithAggregatesFilter<"Transaction"> | string | null
  }

  export type ScoreEventWhereInput = {
    AND?: ScoreEventWhereInput | ScoreEventWhereInput[]
    OR?: ScoreEventWhereInput[]
    NOT?: ScoreEventWhereInput | ScoreEventWhereInput[]
    id?: StringFilter<"ScoreEvent"> | string
    userId?: StringFilter<"ScoreEvent"> | string
    tipoEvento?: StringFilter<"ScoreEvent"> | string
    impacto?: IntFilter<"ScoreEvent"> | number
    descricao?: StringNullableFilter<"ScoreEvent"> | string | null
    scoreAntes?: IntFilter<"ScoreEvent"> | number
    scoreDepois?: IntFilter<"ScoreEvent"> | number
    timestamp?: DateTimeFilter<"ScoreEvent"> | Date | string
    user?: XOR<UserRelationFilter, UserWhereInput>
  }

  export type ScoreEventOrderByWithRelationInput = {
    id?: SortOrder
    userId?: SortOrder
    tipoEvento?: SortOrder
    impacto?: SortOrder
    descricao?: SortOrderInput | SortOrder
    scoreAntes?: SortOrder
    scoreDepois?: SortOrder
    timestamp?: SortOrder
    user?: UserOrderByWithRelationInput
  }

  export type ScoreEventWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    AND?: ScoreEventWhereInput | ScoreEventWhereInput[]
    OR?: ScoreEventWhereInput[]
    NOT?: ScoreEventWhereInput | ScoreEventWhereInput[]
    userId?: StringFilter<"ScoreEvent"> | string
    tipoEvento?: StringFilter<"ScoreEvent"> | string
    impacto?: IntFilter<"ScoreEvent"> | number
    descricao?: StringNullableFilter<"ScoreEvent"> | string | null
    scoreAntes?: IntFilter<"ScoreEvent"> | number
    scoreDepois?: IntFilter<"ScoreEvent"> | number
    timestamp?: DateTimeFilter<"ScoreEvent"> | Date | string
    user?: XOR<UserRelationFilter, UserWhereInput>
  }, "id">

  export type ScoreEventOrderByWithAggregationInput = {
    id?: SortOrder
    userId?: SortOrder
    tipoEvento?: SortOrder
    impacto?: SortOrder
    descricao?: SortOrderInput | SortOrder
    scoreAntes?: SortOrder
    scoreDepois?: SortOrder
    timestamp?: SortOrder
    _count?: ScoreEventCountOrderByAggregateInput
    _avg?: ScoreEventAvgOrderByAggregateInput
    _max?: ScoreEventMaxOrderByAggregateInput
    _min?: ScoreEventMinOrderByAggregateInput
    _sum?: ScoreEventSumOrderByAggregateInput
  }

  export type ScoreEventScalarWhereWithAggregatesInput = {
    AND?: ScoreEventScalarWhereWithAggregatesInput | ScoreEventScalarWhereWithAggregatesInput[]
    OR?: ScoreEventScalarWhereWithAggregatesInput[]
    NOT?: ScoreEventScalarWhereWithAggregatesInput | ScoreEventScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"ScoreEvent"> | string
    userId?: StringWithAggregatesFilter<"ScoreEvent"> | string
    tipoEvento?: StringWithAggregatesFilter<"ScoreEvent"> | string
    impacto?: IntWithAggregatesFilter<"ScoreEvent"> | number
    descricao?: StringNullableWithAggregatesFilter<"ScoreEvent"> | string | null
    scoreAntes?: IntWithAggregatesFilter<"ScoreEvent"> | number
    scoreDepois?: IntWithAggregatesFilter<"ScoreEvent"> | number
    timestamp?: DateTimeWithAggregatesFilter<"ScoreEvent"> | Date | string
  }

  export type NotificationWhereInput = {
    AND?: NotificationWhereInput | NotificationWhereInput[]
    OR?: NotificationWhereInput[]
    NOT?: NotificationWhereInput | NotificationWhereInput[]
    id?: StringFilter<"Notification"> | string
    userId?: StringFilter<"Notification"> | string
    canal?: StringFilter<"Notification"> | string
    titulo?: StringFilter<"Notification"> | string
    corpo?: StringFilter<"Notification"> | string
    lida?: BoolFilter<"Notification"> | boolean
    metadataJson?: StringNullableFilter<"Notification"> | string | null
    createdAt?: DateTimeFilter<"Notification"> | Date | string
    user?: XOR<UserRelationFilter, UserWhereInput>
  }

  export type NotificationOrderByWithRelationInput = {
    id?: SortOrder
    userId?: SortOrder
    canal?: SortOrder
    titulo?: SortOrder
    corpo?: SortOrder
    lida?: SortOrder
    metadataJson?: SortOrderInput | SortOrder
    createdAt?: SortOrder
    user?: UserOrderByWithRelationInput
  }

  export type NotificationWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    AND?: NotificationWhereInput | NotificationWhereInput[]
    OR?: NotificationWhereInput[]
    NOT?: NotificationWhereInput | NotificationWhereInput[]
    userId?: StringFilter<"Notification"> | string
    canal?: StringFilter<"Notification"> | string
    titulo?: StringFilter<"Notification"> | string
    corpo?: StringFilter<"Notification"> | string
    lida?: BoolFilter<"Notification"> | boolean
    metadataJson?: StringNullableFilter<"Notification"> | string | null
    createdAt?: DateTimeFilter<"Notification"> | Date | string
    user?: XOR<UserRelationFilter, UserWhereInput>
  }, "id">

  export type NotificationOrderByWithAggregationInput = {
    id?: SortOrder
    userId?: SortOrder
    canal?: SortOrder
    titulo?: SortOrder
    corpo?: SortOrder
    lida?: SortOrder
    metadataJson?: SortOrderInput | SortOrder
    createdAt?: 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
    canal?: StringWithAggregatesFilter<"Notification"> | string
    titulo?: StringWithAggregatesFilter<"Notification"> | string
    corpo?: StringWithAggregatesFilter<"Notification"> | string
    lida?: BoolWithAggregatesFilter<"Notification"> | boolean
    metadataJson?: StringNullableWithAggregatesFilter<"Notification"> | string | null
    createdAt?: DateTimeWithAggregatesFilter<"Notification"> | Date | string
  }

  export type AuditLogWhereInput = {
    AND?: AuditLogWhereInput | AuditLogWhereInput[]
    OR?: AuditLogWhereInput[]
    NOT?: AuditLogWhereInput | AuditLogWhereInput[]
    id?: StringFilter<"AuditLog"> | string
    userId?: StringNullableFilter<"AuditLog"> | string | null
    acao?: StringFilter<"AuditLog"> | string
    entidade?: StringFilter<"AuditLog"> | string
    entidadeId?: StringNullableFilter<"AuditLog"> | string | null
    dadosAntes?: StringNullableFilter<"AuditLog"> | string | null
    dadosDepois?: StringNullableFilter<"AuditLog"> | string | null
    ip?: StringNullableFilter<"AuditLog"> | string | null
    timestamp?: DateTimeFilter<"AuditLog"> | Date | string
    user?: XOR<UserNullableRelationFilter, UserWhereInput> | null
  }

  export type AuditLogOrderByWithRelationInput = {
    id?: SortOrder
    userId?: SortOrderInput | SortOrder
    acao?: SortOrder
    entidade?: SortOrder
    entidadeId?: SortOrderInput | SortOrder
    dadosAntes?: SortOrderInput | SortOrder
    dadosDepois?: SortOrderInput | SortOrder
    ip?: SortOrderInput | SortOrder
    timestamp?: SortOrder
    user?: UserOrderByWithRelationInput
  }

  export type AuditLogWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    AND?: AuditLogWhereInput | AuditLogWhereInput[]
    OR?: AuditLogWhereInput[]
    NOT?: AuditLogWhereInput | AuditLogWhereInput[]
    userId?: StringNullableFilter<"AuditLog"> | string | null
    acao?: StringFilter<"AuditLog"> | string
    entidade?: StringFilter<"AuditLog"> | string
    entidadeId?: StringNullableFilter<"AuditLog"> | string | null
    dadosAntes?: StringNullableFilter<"AuditLog"> | string | null
    dadosDepois?: StringNullableFilter<"AuditLog"> | string | null
    ip?: StringNullableFilter<"AuditLog"> | string | null
    timestamp?: DateTimeFilter<"AuditLog"> | Date | string
    user?: XOR<UserNullableRelationFilter, UserWhereInput> | null
  }, "id">

  export type AuditLogOrderByWithAggregationInput = {
    id?: SortOrder
    userId?: SortOrderInput | SortOrder
    acao?: SortOrder
    entidade?: SortOrder
    entidadeId?: SortOrderInput | SortOrder
    dadosAntes?: SortOrderInput | SortOrder
    dadosDepois?: SortOrderInput | SortOrder
    ip?: SortOrderInput | SortOrder
    timestamp?: SortOrder
    _count?: AuditLogCountOrderByAggregateInput
    _max?: AuditLogMaxOrderByAggregateInput
    _min?: AuditLogMinOrderByAggregateInput
  }

  export type AuditLogScalarWhereWithAggregatesInput = {
    AND?: AuditLogScalarWhereWithAggregatesInput | AuditLogScalarWhereWithAggregatesInput[]
    OR?: AuditLogScalarWhereWithAggregatesInput[]
    NOT?: AuditLogScalarWhereWithAggregatesInput | AuditLogScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"AuditLog"> | string
    userId?: StringNullableWithAggregatesFilter<"AuditLog"> | string | null
    acao?: StringWithAggregatesFilter<"AuditLog"> | string
    entidade?: StringWithAggregatesFilter<"AuditLog"> | string
    entidadeId?: StringNullableWithAggregatesFilter<"AuditLog"> | string | null
    dadosAntes?: StringNullableWithAggregatesFilter<"AuditLog"> | string | null
    dadosDepois?: StringNullableWithAggregatesFilter<"AuditLog"> | string | null
    ip?: StringNullableWithAggregatesFilter<"AuditLog"> | string | null
    timestamp?: DateTimeWithAggregatesFilter<"AuditLog"> | Date | string
  }

  export type SystemClockWhereInput = {
    AND?: SystemClockWhereInput | SystemClockWhereInput[]
    OR?: SystemClockWhereInput[]
    NOT?: SystemClockWhereInput | SystemClockWhereInput[]
    id?: IntFilter<"SystemClock"> | number
    agora?: DateTimeFilter<"SystemClock"> | Date | string
    updatedAt?: DateTimeFilter<"SystemClock"> | Date | string
  }

  export type SystemClockOrderByWithRelationInput = {
    id?: SortOrder
    agora?: SortOrder
    updatedAt?: SortOrder
  }

  export type SystemClockWhereUniqueInput = Prisma.AtLeast<{
    id?: number
    AND?: SystemClockWhereInput | SystemClockWhereInput[]
    OR?: SystemClockWhereInput[]
    NOT?: SystemClockWhereInput | SystemClockWhereInput[]
    agora?: DateTimeFilter<"SystemClock"> | Date | string
    updatedAt?: DateTimeFilter<"SystemClock"> | Date | string
  }, "id">

  export type SystemClockOrderByWithAggregationInput = {
    id?: SortOrder
    agora?: SortOrder
    updatedAt?: SortOrder
    _count?: SystemClockCountOrderByAggregateInput
    _avg?: SystemClockAvgOrderByAggregateInput
    _max?: SystemClockMaxOrderByAggregateInput
    _min?: SystemClockMinOrderByAggregateInput
    _sum?: SystemClockSumOrderByAggregateInput
  }

  export type SystemClockScalarWhereWithAggregatesInput = {
    AND?: SystemClockScalarWhereWithAggregatesInput | SystemClockScalarWhereWithAggregatesInput[]
    OR?: SystemClockScalarWhereWithAggregatesInput[]
    NOT?: SystemClockScalarWhereWithAggregatesInput | SystemClockScalarWhereWithAggregatesInput[]
    id?: IntWithAggregatesFilter<"SystemClock"> | number
    agora?: DateTimeWithAggregatesFilter<"SystemClock"> | Date | string
    updatedAt?: DateTimeWithAggregatesFilter<"SystemClock"> | Date | string
  }

  export type CreditApplicationWhereInput = {
    AND?: CreditApplicationWhereInput | CreditApplicationWhereInput[]
    OR?: CreditApplicationWhereInput[]
    NOT?: CreditApplicationWhereInput | CreditApplicationWhereInput[]
    id?: StringFilter<"CreditApplication"> | string
    userId?: StringFilter<"CreditApplication"> | string
    valorSolicitado?: FloatFilter<"CreditApplication"> | number
    prazoMeses?: IntFilter<"CreditApplication"> | number
    taxaJuroAplicada?: FloatFilter<"CreditApplication"> | number
    prestacaoMensal?: FloatFilter<"CreditApplication"> | number
    finalidade?: StringNullableFilter<"CreditApplication"> | string | null
    status?: StringFilter<"CreditApplication"> | string
    scoreNoMomento?: IntFilter<"CreditApplication"> | number
    motivoDecisao?: StringNullableFilter<"CreditApplication"> | string | null
    decisaoPorId?: StringNullableFilter<"CreditApplication"> | string | null
    dataAprovacao?: DateTimeNullableFilter<"CreditApplication"> | Date | string | null
    dataDesembolso?: DateTimeNullableFilter<"CreditApplication"> | Date | string | null
    createdAt?: DateTimeFilter<"CreditApplication"> | Date | string
    updatedAt?: DateTimeFilter<"CreditApplication"> | Date | string
    user?: XOR<UserRelationFilter, UserWhereInput>
    prestacoes?: CreditInstallmentListRelationFilter
  }

  export type CreditApplicationOrderByWithRelationInput = {
    id?: SortOrder
    userId?: SortOrder
    valorSolicitado?: SortOrder
    prazoMeses?: SortOrder
    taxaJuroAplicada?: SortOrder
    prestacaoMensal?: SortOrder
    finalidade?: SortOrderInput | SortOrder
    status?: SortOrder
    scoreNoMomento?: SortOrder
    motivoDecisao?: SortOrderInput | SortOrder
    decisaoPorId?: SortOrderInput | SortOrder
    dataAprovacao?: SortOrderInput | SortOrder
    dataDesembolso?: SortOrderInput | SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
    user?: UserOrderByWithRelationInput
    prestacoes?: CreditInstallmentOrderByRelationAggregateInput
  }

  export type CreditApplicationWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    AND?: CreditApplicationWhereInput | CreditApplicationWhereInput[]
    OR?: CreditApplicationWhereInput[]
    NOT?: CreditApplicationWhereInput | CreditApplicationWhereInput[]
    userId?: StringFilter<"CreditApplication"> | string
    valorSolicitado?: FloatFilter<"CreditApplication"> | number
    prazoMeses?: IntFilter<"CreditApplication"> | number
    taxaJuroAplicada?: FloatFilter<"CreditApplication"> | number
    prestacaoMensal?: FloatFilter<"CreditApplication"> | number
    finalidade?: StringNullableFilter<"CreditApplication"> | string | null
    status?: StringFilter<"CreditApplication"> | string
    scoreNoMomento?: IntFilter<"CreditApplication"> | number
    motivoDecisao?: StringNullableFilter<"CreditApplication"> | string | null
    decisaoPorId?: StringNullableFilter<"CreditApplication"> | string | null
    dataAprovacao?: DateTimeNullableFilter<"CreditApplication"> | Date | string | null
    dataDesembolso?: DateTimeNullableFilter<"CreditApplication"> | Date | string | null
    createdAt?: DateTimeFilter<"CreditApplication"> | Date | string
    updatedAt?: DateTimeFilter<"CreditApplication"> | Date | string
    user?: XOR<UserRelationFilter, UserWhereInput>
    prestacoes?: CreditInstallmentListRelationFilter
  }, "id">

  export type CreditApplicationOrderByWithAggregationInput = {
    id?: SortOrder
    userId?: SortOrder
    valorSolicitado?: SortOrder
    prazoMeses?: SortOrder
    taxaJuroAplicada?: SortOrder
    prestacaoMensal?: SortOrder
    finalidade?: SortOrderInput | SortOrder
    status?: SortOrder
    scoreNoMomento?: SortOrder
    motivoDecisao?: SortOrderInput | SortOrder
    decisaoPorId?: SortOrderInput | SortOrder
    dataAprovacao?: SortOrderInput | SortOrder
    dataDesembolso?: SortOrderInput | SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
    _count?: CreditApplicationCountOrderByAggregateInput
    _avg?: CreditApplicationAvgOrderByAggregateInput
    _max?: CreditApplicationMaxOrderByAggregateInput
    _min?: CreditApplicationMinOrderByAggregateInput
    _sum?: CreditApplicationSumOrderByAggregateInput
  }

  export type CreditApplicationScalarWhereWithAggregatesInput = {
    AND?: CreditApplicationScalarWhereWithAggregatesInput | CreditApplicationScalarWhereWithAggregatesInput[]
    OR?: CreditApplicationScalarWhereWithAggregatesInput[]
    NOT?: CreditApplicationScalarWhereWithAggregatesInput | CreditApplicationScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"CreditApplication"> | string
    userId?: StringWithAggregatesFilter<"CreditApplication"> | string
    valorSolicitado?: FloatWithAggregatesFilter<"CreditApplication"> | number
    prazoMeses?: IntWithAggregatesFilter<"CreditApplication"> | number
    taxaJuroAplicada?: FloatWithAggregatesFilter<"CreditApplication"> | number
    prestacaoMensal?: FloatWithAggregatesFilter<"CreditApplication"> | number
    finalidade?: StringNullableWithAggregatesFilter<"CreditApplication"> | string | null
    status?: StringWithAggregatesFilter<"CreditApplication"> | string
    scoreNoMomento?: IntWithAggregatesFilter<"CreditApplication"> | number
    motivoDecisao?: StringNullableWithAggregatesFilter<"CreditApplication"> | string | null
    decisaoPorId?: StringNullableWithAggregatesFilter<"CreditApplication"> | string | null
    dataAprovacao?: DateTimeNullableWithAggregatesFilter<"CreditApplication"> | Date | string | null
    dataDesembolso?: DateTimeNullableWithAggregatesFilter<"CreditApplication"> | Date | string | null
    createdAt?: DateTimeWithAggregatesFilter<"CreditApplication"> | Date | string
    updatedAt?: DateTimeWithAggregatesFilter<"CreditApplication"> | Date | string
  }

  export type CreditInstallmentWhereInput = {
    AND?: CreditInstallmentWhereInput | CreditInstallmentWhereInput[]
    OR?: CreditInstallmentWhereInput[]
    NOT?: CreditInstallmentWhereInput | CreditInstallmentWhereInput[]
    id?: StringFilter<"CreditInstallment"> | string
    applicationId?: StringFilter<"CreditInstallment"> | string
    numero?: IntFilter<"CreditInstallment"> | number
    valorCapital?: FloatFilter<"CreditInstallment"> | number
    valorJuros?: FloatFilter<"CreditInstallment"> | number
    valorTotal?: FloatFilter<"CreditInstallment"> | number
    dataVencimento?: DateTimeFilter<"CreditInstallment"> | Date | string
    dataPagamento?: DateTimeNullableFilter<"CreditInstallment"> | Date | string | null
    status?: StringFilter<"CreditInstallment"> | string
    application?: XOR<CreditApplicationRelationFilter, CreditApplicationWhereInput>
  }

  export type CreditInstallmentOrderByWithRelationInput = {
    id?: SortOrder
    applicationId?: SortOrder
    numero?: SortOrder
    valorCapital?: SortOrder
    valorJuros?: SortOrder
    valorTotal?: SortOrder
    dataVencimento?: SortOrder
    dataPagamento?: SortOrderInput | SortOrder
    status?: SortOrder
    application?: CreditApplicationOrderByWithRelationInput
  }

  export type CreditInstallmentWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    applicationId_numero?: CreditInstallmentApplicationIdNumeroCompoundUniqueInput
    AND?: CreditInstallmentWhereInput | CreditInstallmentWhereInput[]
    OR?: CreditInstallmentWhereInput[]
    NOT?: CreditInstallmentWhereInput | CreditInstallmentWhereInput[]
    applicationId?: StringFilter<"CreditInstallment"> | string
    numero?: IntFilter<"CreditInstallment"> | number
    valorCapital?: FloatFilter<"CreditInstallment"> | number
    valorJuros?: FloatFilter<"CreditInstallment"> | number
    valorTotal?: FloatFilter<"CreditInstallment"> | number
    dataVencimento?: DateTimeFilter<"CreditInstallment"> | Date | string
    dataPagamento?: DateTimeNullableFilter<"CreditInstallment"> | Date | string | null
    status?: StringFilter<"CreditInstallment"> | string
    application?: XOR<CreditApplicationRelationFilter, CreditApplicationWhereInput>
  }, "id" | "applicationId_numero">

  export type CreditInstallmentOrderByWithAggregationInput = {
    id?: SortOrder
    applicationId?: SortOrder
    numero?: SortOrder
    valorCapital?: SortOrder
    valorJuros?: SortOrder
    valorTotal?: SortOrder
    dataVencimento?: SortOrder
    dataPagamento?: SortOrderInput | SortOrder
    status?: SortOrder
    _count?: CreditInstallmentCountOrderByAggregateInput
    _avg?: CreditInstallmentAvgOrderByAggregateInput
    _max?: CreditInstallmentMaxOrderByAggregateInput
    _min?: CreditInstallmentMinOrderByAggregateInput
    _sum?: CreditInstallmentSumOrderByAggregateInput
  }

  export type CreditInstallmentScalarWhereWithAggregatesInput = {
    AND?: CreditInstallmentScalarWhereWithAggregatesInput | CreditInstallmentScalarWhereWithAggregatesInput[]
    OR?: CreditInstallmentScalarWhereWithAggregatesInput[]
    NOT?: CreditInstallmentScalarWhereWithAggregatesInput | CreditInstallmentScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"CreditInstallment"> | string
    applicationId?: StringWithAggregatesFilter<"CreditInstallment"> | string
    numero?: IntWithAggregatesFilter<"CreditInstallment"> | number
    valorCapital?: FloatWithAggregatesFilter<"CreditInstallment"> | number
    valorJuros?: FloatWithAggregatesFilter<"CreditInstallment"> | number
    valorTotal?: FloatWithAggregatesFilter<"CreditInstallment"> | number
    dataVencimento?: DateTimeWithAggregatesFilter<"CreditInstallment"> | Date | string
    dataPagamento?: DateTimeNullableWithAggregatesFilter<"CreditInstallment"> | Date | string | null
    status?: StringWithAggregatesFilter<"CreditInstallment"> | string
  }

  export type SavingsAccountWhereInput = {
    AND?: SavingsAccountWhereInput | SavingsAccountWhereInput[]
    OR?: SavingsAccountWhereInput[]
    NOT?: SavingsAccountWhereInput | SavingsAccountWhereInput[]
    id?: StringFilter<"SavingsAccount"> | string
    userId?: StringFilter<"SavingsAccount"> | string
    nome?: StringFilter<"SavingsAccount"> | string
    objectivo?: StringNullableFilter<"SavingsAccount"> | string | null
    meta?: FloatNullableFilter<"SavingsAccount"> | number | null
    saldo?: FloatFilter<"SavingsAccount"> | number
    taxaRemuneracaoAnual?: FloatFilter<"SavingsAccount"> | number
    imobilizacaoMeses?: IntFilter<"SavingsAccount"> | number
    status?: StringFilter<"SavingsAccount"> | string
    ultimaCapitalizacao?: DateTimeFilter<"SavingsAccount"> | Date | string
    createdAt?: DateTimeFilter<"SavingsAccount"> | Date | string
    updatedAt?: DateTimeFilter<"SavingsAccount"> | Date | string
    user?: XOR<UserRelationFilter, UserWhereInput>
    movimentos?: SavingsMovementListRelationFilter
  }

  export type SavingsAccountOrderByWithRelationInput = {
    id?: SortOrder
    userId?: SortOrder
    nome?: SortOrder
    objectivo?: SortOrderInput | SortOrder
    meta?: SortOrderInput | SortOrder
    saldo?: SortOrder
    taxaRemuneracaoAnual?: SortOrder
    imobilizacaoMeses?: SortOrder
    status?: SortOrder
    ultimaCapitalizacao?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
    user?: UserOrderByWithRelationInput
    movimentos?: SavingsMovementOrderByRelationAggregateInput
  }

  export type SavingsAccountWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    AND?: SavingsAccountWhereInput | SavingsAccountWhereInput[]
    OR?: SavingsAccountWhereInput[]
    NOT?: SavingsAccountWhereInput | SavingsAccountWhereInput[]
    userId?: StringFilter<"SavingsAccount"> | string
    nome?: StringFilter<"SavingsAccount"> | string
    objectivo?: StringNullableFilter<"SavingsAccount"> | string | null
    meta?: FloatNullableFilter<"SavingsAccount"> | number | null
    saldo?: FloatFilter<"SavingsAccount"> | number
    taxaRemuneracaoAnual?: FloatFilter<"SavingsAccount"> | number
    imobilizacaoMeses?: IntFilter<"SavingsAccount"> | number
    status?: StringFilter<"SavingsAccount"> | string
    ultimaCapitalizacao?: DateTimeFilter<"SavingsAccount"> | Date | string
    createdAt?: DateTimeFilter<"SavingsAccount"> | Date | string
    updatedAt?: DateTimeFilter<"SavingsAccount"> | Date | string
    user?: XOR<UserRelationFilter, UserWhereInput>
    movimentos?: SavingsMovementListRelationFilter
  }, "id">

  export type SavingsAccountOrderByWithAggregationInput = {
    id?: SortOrder
    userId?: SortOrder
    nome?: SortOrder
    objectivo?: SortOrderInput | SortOrder
    meta?: SortOrderInput | SortOrder
    saldo?: SortOrder
    taxaRemuneracaoAnual?: SortOrder
    imobilizacaoMeses?: SortOrder
    status?: SortOrder
    ultimaCapitalizacao?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
    _count?: SavingsAccountCountOrderByAggregateInput
    _avg?: SavingsAccountAvgOrderByAggregateInput
    _max?: SavingsAccountMaxOrderByAggregateInput
    _min?: SavingsAccountMinOrderByAggregateInput
    _sum?: SavingsAccountSumOrderByAggregateInput
  }

  export type SavingsAccountScalarWhereWithAggregatesInput = {
    AND?: SavingsAccountScalarWhereWithAggregatesInput | SavingsAccountScalarWhereWithAggregatesInput[]
    OR?: SavingsAccountScalarWhereWithAggregatesInput[]
    NOT?: SavingsAccountScalarWhereWithAggregatesInput | SavingsAccountScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"SavingsAccount"> | string
    userId?: StringWithAggregatesFilter<"SavingsAccount"> | string
    nome?: StringWithAggregatesFilter<"SavingsAccount"> | string
    objectivo?: StringNullableWithAggregatesFilter<"SavingsAccount"> | string | null
    meta?: FloatNullableWithAggregatesFilter<"SavingsAccount"> | number | null
    saldo?: FloatWithAggregatesFilter<"SavingsAccount"> | number
    taxaRemuneracaoAnual?: FloatWithAggregatesFilter<"SavingsAccount"> | number
    imobilizacaoMeses?: IntWithAggregatesFilter<"SavingsAccount"> | number
    status?: StringWithAggregatesFilter<"SavingsAccount"> | string
    ultimaCapitalizacao?: DateTimeWithAggregatesFilter<"SavingsAccount"> | Date | string
    createdAt?: DateTimeWithAggregatesFilter<"SavingsAccount"> | Date | string
    updatedAt?: DateTimeWithAggregatesFilter<"SavingsAccount"> | Date | string
  }

  export type SavingsMovementWhereInput = {
    AND?: SavingsMovementWhereInput | SavingsMovementWhereInput[]
    OR?: SavingsMovementWhereInput[]
    NOT?: SavingsMovementWhereInput | SavingsMovementWhereInput[]
    id?: StringFilter<"SavingsMovement"> | string
    accountId?: StringFilter<"SavingsMovement"> | string
    tipo?: StringFilter<"SavingsMovement"> | string
    valor?: FloatFilter<"SavingsMovement"> | number
    saldoApos?: FloatFilter<"SavingsMovement"> | number
    descricao?: StringNullableFilter<"SavingsMovement"> | string | null
    createdAt?: DateTimeFilter<"SavingsMovement"> | Date | string
    account?: XOR<SavingsAccountRelationFilter, SavingsAccountWhereInput>
  }

  export type SavingsMovementOrderByWithRelationInput = {
    id?: SortOrder
    accountId?: SortOrder
    tipo?: SortOrder
    valor?: SortOrder
    saldoApos?: SortOrder
    descricao?: SortOrderInput | SortOrder
    createdAt?: SortOrder
    account?: SavingsAccountOrderByWithRelationInput
  }

  export type SavingsMovementWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    AND?: SavingsMovementWhereInput | SavingsMovementWhereInput[]
    OR?: SavingsMovementWhereInput[]
    NOT?: SavingsMovementWhereInput | SavingsMovementWhereInput[]
    accountId?: StringFilter<"SavingsMovement"> | string
    tipo?: StringFilter<"SavingsMovement"> | string
    valor?: FloatFilter<"SavingsMovement"> | number
    saldoApos?: FloatFilter<"SavingsMovement"> | number
    descricao?: StringNullableFilter<"SavingsMovement"> | string | null
    createdAt?: DateTimeFilter<"SavingsMovement"> | Date | string
    account?: XOR<SavingsAccountRelationFilter, SavingsAccountWhereInput>
  }, "id">

  export type SavingsMovementOrderByWithAggregationInput = {
    id?: SortOrder
    accountId?: SortOrder
    tipo?: SortOrder
    valor?: SortOrder
    saldoApos?: SortOrder
    descricao?: SortOrderInput | SortOrder
    createdAt?: SortOrder
    _count?: SavingsMovementCountOrderByAggregateInput
    _avg?: SavingsMovementAvgOrderByAggregateInput
    _max?: SavingsMovementMaxOrderByAggregateInput
    _min?: SavingsMovementMinOrderByAggregateInput
    _sum?: SavingsMovementSumOrderByAggregateInput
  }

  export type SavingsMovementScalarWhereWithAggregatesInput = {
    AND?: SavingsMovementScalarWhereWithAggregatesInput | SavingsMovementScalarWhereWithAggregatesInput[]
    OR?: SavingsMovementScalarWhereWithAggregatesInput[]
    NOT?: SavingsMovementScalarWhereWithAggregatesInput | SavingsMovementScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"SavingsMovement"> | string
    accountId?: StringWithAggregatesFilter<"SavingsMovement"> | string
    tipo?: StringWithAggregatesFilter<"SavingsMovement"> | string
    valor?: FloatWithAggregatesFilter<"SavingsMovement"> | number
    saldoApos?: FloatWithAggregatesFilter<"SavingsMovement"> | number
    descricao?: StringNullableWithAggregatesFilter<"SavingsMovement"> | string | null
    createdAt?: DateTimeWithAggregatesFilter<"SavingsMovement"> | Date | string
  }

  export type ReferralWhereInput = {
    AND?: ReferralWhereInput | ReferralWhereInput[]
    OR?: ReferralWhereInput[]
    NOT?: ReferralWhereInput | ReferralWhereInput[]
    id?: StringFilter<"Referral"> | string
    referrerUserId?: StringFilter<"Referral"> | string
    referredUserId?: StringNullableFilter<"Referral"> | string | null
    codigo?: StringFilter<"Referral"> | string
    canal?: StringNullableFilter<"Referral"> | string | null
    status?: StringFilter<"Referral"> | string
    recompensa?: FloatFilter<"Referral"> | number
    recompensaPaga?: BoolFilter<"Referral"> | boolean
    dataRegisto?: DateTimeNullableFilter<"Referral"> | Date | string | null
    dataActivacao?: DateTimeNullableFilter<"Referral"> | Date | string | null
    createdAt?: DateTimeFilter<"Referral"> | Date | string
    referrer?: XOR<UserRelationFilter, UserWhereInput>
    referredUser?: XOR<UserNullableRelationFilter, UserWhereInput> | null
  }

  export type ReferralOrderByWithRelationInput = {
    id?: SortOrder
    referrerUserId?: SortOrder
    referredUserId?: SortOrderInput | SortOrder
    codigo?: SortOrder
    canal?: SortOrderInput | SortOrder
    status?: SortOrder
    recompensa?: SortOrder
    recompensaPaga?: SortOrder
    dataRegisto?: SortOrderInput | SortOrder
    dataActivacao?: SortOrderInput | SortOrder
    createdAt?: SortOrder
    referrer?: UserOrderByWithRelationInput
    referredUser?: UserOrderByWithRelationInput
  }

  export type ReferralWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    AND?: ReferralWhereInput | ReferralWhereInput[]
    OR?: ReferralWhereInput[]
    NOT?: ReferralWhereInput | ReferralWhereInput[]
    referrerUserId?: StringFilter<"Referral"> | string
    referredUserId?: StringNullableFilter<"Referral"> | string | null
    codigo?: StringFilter<"Referral"> | string
    canal?: StringNullableFilter<"Referral"> | string | null
    status?: StringFilter<"Referral"> | string
    recompensa?: FloatFilter<"Referral"> | number
    recompensaPaga?: BoolFilter<"Referral"> | boolean
    dataRegisto?: DateTimeNullableFilter<"Referral"> | Date | string | null
    dataActivacao?: DateTimeNullableFilter<"Referral"> | Date | string | null
    createdAt?: DateTimeFilter<"Referral"> | Date | string
    referrer?: XOR<UserRelationFilter, UserWhereInput>
    referredUser?: XOR<UserNullableRelationFilter, UserWhereInput> | null
  }, "id">

  export type ReferralOrderByWithAggregationInput = {
    id?: SortOrder
    referrerUserId?: SortOrder
    referredUserId?: SortOrderInput | SortOrder
    codigo?: SortOrder
    canal?: SortOrderInput | SortOrder
    status?: SortOrder
    recompensa?: SortOrder
    recompensaPaga?: SortOrder
    dataRegisto?: SortOrderInput | SortOrder
    dataActivacao?: SortOrderInput | SortOrder
    createdAt?: SortOrder
    _count?: ReferralCountOrderByAggregateInput
    _avg?: ReferralAvgOrderByAggregateInput
    _max?: ReferralMaxOrderByAggregateInput
    _min?: ReferralMinOrderByAggregateInput
    _sum?: ReferralSumOrderByAggregateInput
  }

  export type ReferralScalarWhereWithAggregatesInput = {
    AND?: ReferralScalarWhereWithAggregatesInput | ReferralScalarWhereWithAggregatesInput[]
    OR?: ReferralScalarWhereWithAggregatesInput[]
    NOT?: ReferralScalarWhereWithAggregatesInput | ReferralScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"Referral"> | string
    referrerUserId?: StringWithAggregatesFilter<"Referral"> | string
    referredUserId?: StringNullableWithAggregatesFilter<"Referral"> | string | null
    codigo?: StringWithAggregatesFilter<"Referral"> | string
    canal?: StringNullableWithAggregatesFilter<"Referral"> | string | null
    status?: StringWithAggregatesFilter<"Referral"> | string
    recompensa?: FloatWithAggregatesFilter<"Referral"> | number
    recompensaPaga?: BoolWithAggregatesFilter<"Referral"> | boolean
    dataRegisto?: DateTimeNullableWithAggregatesFilter<"Referral"> | Date | string | null
    dataActivacao?: DateTimeNullableWithAggregatesFilter<"Referral"> | Date | string | null
    createdAt?: DateTimeWithAggregatesFilter<"Referral"> | Date | string
  }

  export type ContentArticleWhereInput = {
    AND?: ContentArticleWhereInput | ContentArticleWhereInput[]
    OR?: ContentArticleWhereInput[]
    NOT?: ContentArticleWhereInput | ContentArticleWhereInput[]
    id?: StringFilter<"ContentArticle"> | string
    slug?: StringFilter<"ContentArticle"> | string
    titulo?: StringFilter<"ContentArticle"> | string
    resumo?: StringFilter<"ContentArticle"> | string
    corpo?: StringFilter<"ContentArticle"> | string
    categoria?: StringFilter<"ContentArticle"> | string
    autor?: StringFilter<"ContentArticle"> | string
    duracaoLeituraMin?: IntFilter<"ContentArticle"> | number
    publicado?: BoolFilter<"ContentArticle"> | boolean
    ordem?: IntFilter<"ContentArticle"> | number
    createdAt?: DateTimeFilter<"ContentArticle"> | Date | string
  }

  export type ContentArticleOrderByWithRelationInput = {
    id?: SortOrder
    slug?: SortOrder
    titulo?: SortOrder
    resumo?: SortOrder
    corpo?: SortOrder
    categoria?: SortOrder
    autor?: SortOrder
    duracaoLeituraMin?: SortOrder
    publicado?: SortOrder
    ordem?: SortOrder
    createdAt?: SortOrder
  }

  export type ContentArticleWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    slug?: string
    AND?: ContentArticleWhereInput | ContentArticleWhereInput[]
    OR?: ContentArticleWhereInput[]
    NOT?: ContentArticleWhereInput | ContentArticleWhereInput[]
    titulo?: StringFilter<"ContentArticle"> | string
    resumo?: StringFilter<"ContentArticle"> | string
    corpo?: StringFilter<"ContentArticle"> | string
    categoria?: StringFilter<"ContentArticle"> | string
    autor?: StringFilter<"ContentArticle"> | string
    duracaoLeituraMin?: IntFilter<"ContentArticle"> | number
    publicado?: BoolFilter<"ContentArticle"> | boolean
    ordem?: IntFilter<"ContentArticle"> | number
    createdAt?: DateTimeFilter<"ContentArticle"> | Date | string
  }, "id" | "slug">

  export type ContentArticleOrderByWithAggregationInput = {
    id?: SortOrder
    slug?: SortOrder
    titulo?: SortOrder
    resumo?: SortOrder
    corpo?: SortOrder
    categoria?: SortOrder
    autor?: SortOrder
    duracaoLeituraMin?: SortOrder
    publicado?: SortOrder
    ordem?: SortOrder
    createdAt?: SortOrder
    _count?: ContentArticleCountOrderByAggregateInput
    _avg?: ContentArticleAvgOrderByAggregateInput
    _max?: ContentArticleMaxOrderByAggregateInput
    _min?: ContentArticleMinOrderByAggregateInput
    _sum?: ContentArticleSumOrderByAggregateInput
  }

  export type ContentArticleScalarWhereWithAggregatesInput = {
    AND?: ContentArticleScalarWhereWithAggregatesInput | ContentArticleScalarWhereWithAggregatesInput[]
    OR?: ContentArticleScalarWhereWithAggregatesInput[]
    NOT?: ContentArticleScalarWhereWithAggregatesInput | ContentArticleScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"ContentArticle"> | string
    slug?: StringWithAggregatesFilter<"ContentArticle"> | string
    titulo?: StringWithAggregatesFilter<"ContentArticle"> | string
    resumo?: StringWithAggregatesFilter<"ContentArticle"> | string
    corpo?: StringWithAggregatesFilter<"ContentArticle"> | string
    categoria?: StringWithAggregatesFilter<"ContentArticle"> | string
    autor?: StringWithAggregatesFilter<"ContentArticle"> | string
    duracaoLeituraMin?: IntWithAggregatesFilter<"ContentArticle"> | number
    publicado?: BoolWithAggregatesFilter<"ContentArticle"> | boolean
    ordem?: IntWithAggregatesFilter<"ContentArticle"> | number
    createdAt?: DateTimeWithAggregatesFilter<"ContentArticle"> | Date | string
  }

  export type QuizWhereInput = {
    AND?: QuizWhereInput | QuizWhereInput[]
    OR?: QuizWhereInput[]
    NOT?: QuizWhereInput | QuizWhereInput[]
    id?: StringFilter<"Quiz"> | string
    titulo?: StringFilter<"Quiz"> | string
    descricao?: StringNullableFilter<"Quiz"> | string | null
    perguntasJson?: StringFilter<"Quiz"> | string
    pontos?: IntFilter<"Quiz"> | number
    publicado?: BoolFilter<"Quiz"> | boolean
    createdAt?: DateTimeFilter<"Quiz"> | Date | string
    attempts?: QuizAttemptListRelationFilter
  }

  export type QuizOrderByWithRelationInput = {
    id?: SortOrder
    titulo?: SortOrder
    descricao?: SortOrderInput | SortOrder
    perguntasJson?: SortOrder
    pontos?: SortOrder
    publicado?: SortOrder
    createdAt?: SortOrder
    attempts?: QuizAttemptOrderByRelationAggregateInput
  }

  export type QuizWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    AND?: QuizWhereInput | QuizWhereInput[]
    OR?: QuizWhereInput[]
    NOT?: QuizWhereInput | QuizWhereInput[]
    titulo?: StringFilter<"Quiz"> | string
    descricao?: StringNullableFilter<"Quiz"> | string | null
    perguntasJson?: StringFilter<"Quiz"> | string
    pontos?: IntFilter<"Quiz"> | number
    publicado?: BoolFilter<"Quiz"> | boolean
    createdAt?: DateTimeFilter<"Quiz"> | Date | string
    attempts?: QuizAttemptListRelationFilter
  }, "id">

  export type QuizOrderByWithAggregationInput = {
    id?: SortOrder
    titulo?: SortOrder
    descricao?: SortOrderInput | SortOrder
    perguntasJson?: SortOrder
    pontos?: SortOrder
    publicado?: SortOrder
    createdAt?: SortOrder
    _count?: QuizCountOrderByAggregateInput
    _avg?: QuizAvgOrderByAggregateInput
    _max?: QuizMaxOrderByAggregateInput
    _min?: QuizMinOrderByAggregateInput
    _sum?: QuizSumOrderByAggregateInput
  }

  export type QuizScalarWhereWithAggregatesInput = {
    AND?: QuizScalarWhereWithAggregatesInput | QuizScalarWhereWithAggregatesInput[]
    OR?: QuizScalarWhereWithAggregatesInput[]
    NOT?: QuizScalarWhereWithAggregatesInput | QuizScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"Quiz"> | string
    titulo?: StringWithAggregatesFilter<"Quiz"> | string
    descricao?: StringNullableWithAggregatesFilter<"Quiz"> | string | null
    perguntasJson?: StringWithAggregatesFilter<"Quiz"> | string
    pontos?: IntWithAggregatesFilter<"Quiz"> | number
    publicado?: BoolWithAggregatesFilter<"Quiz"> | boolean
    createdAt?: DateTimeWithAggregatesFilter<"Quiz"> | Date | string
  }

  export type QuizAttemptWhereInput = {
    AND?: QuizAttemptWhereInput | QuizAttemptWhereInput[]
    OR?: QuizAttemptWhereInput[]
    NOT?: QuizAttemptWhereInput | QuizAttemptWhereInput[]
    id?: StringFilter<"QuizAttempt"> | string
    userId?: StringFilter<"QuizAttempt"> | string
    quizId?: StringFilter<"QuizAttempt"> | string
    acertos?: IntFilter<"QuizAttempt"> | number
    total?: IntFilter<"QuizAttempt"> | number
    pontosGanhos?: IntFilter<"QuizAttempt"> | number
    respostasJson?: StringNullableFilter<"QuizAttempt"> | string | null
    createdAt?: DateTimeFilter<"QuizAttempt"> | Date | string
    user?: XOR<UserRelationFilter, UserWhereInput>
    quiz?: XOR<QuizRelationFilter, QuizWhereInput>
  }

  export type QuizAttemptOrderByWithRelationInput = {
    id?: SortOrder
    userId?: SortOrder
    quizId?: SortOrder
    acertos?: SortOrder
    total?: SortOrder
    pontosGanhos?: SortOrder
    respostasJson?: SortOrderInput | SortOrder
    createdAt?: SortOrder
    user?: UserOrderByWithRelationInput
    quiz?: QuizOrderByWithRelationInput
  }

  export type QuizAttemptWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    AND?: QuizAttemptWhereInput | QuizAttemptWhereInput[]
    OR?: QuizAttemptWhereInput[]
    NOT?: QuizAttemptWhereInput | QuizAttemptWhereInput[]
    userId?: StringFilter<"QuizAttempt"> | string
    quizId?: StringFilter<"QuizAttempt"> | string
    acertos?: IntFilter<"QuizAttempt"> | number
    total?: IntFilter<"QuizAttempt"> | number
    pontosGanhos?: IntFilter<"QuizAttempt"> | number
    respostasJson?: StringNullableFilter<"QuizAttempt"> | string | null
    createdAt?: DateTimeFilter<"QuizAttempt"> | Date | string
    user?: XOR<UserRelationFilter, UserWhereInput>
    quiz?: XOR<QuizRelationFilter, QuizWhereInput>
  }, "id">

  export type QuizAttemptOrderByWithAggregationInput = {
    id?: SortOrder
    userId?: SortOrder
    quizId?: SortOrder
    acertos?: SortOrder
    total?: SortOrder
    pontosGanhos?: SortOrder
    respostasJson?: SortOrderInput | SortOrder
    createdAt?: SortOrder
    _count?: QuizAttemptCountOrderByAggregateInput
    _avg?: QuizAttemptAvgOrderByAggregateInput
    _max?: QuizAttemptMaxOrderByAggregateInput
    _min?: QuizAttemptMinOrderByAggregateInput
    _sum?: QuizAttemptSumOrderByAggregateInput
  }

  export type QuizAttemptScalarWhereWithAggregatesInput = {
    AND?: QuizAttemptScalarWhereWithAggregatesInput | QuizAttemptScalarWhereWithAggregatesInput[]
    OR?: QuizAttemptScalarWhereWithAggregatesInput[]
    NOT?: QuizAttemptScalarWhereWithAggregatesInput | QuizAttemptScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"QuizAttempt"> | string
    userId?: StringWithAggregatesFilter<"QuizAttempt"> | string
    quizId?: StringWithAggregatesFilter<"QuizAttempt"> | string
    acertos?: IntWithAggregatesFilter<"QuizAttempt"> | number
    total?: IntWithAggregatesFilter<"QuizAttempt"> | number
    pontosGanhos?: IntWithAggregatesFilter<"QuizAttempt"> | number
    respostasJson?: StringNullableWithAggregatesFilter<"QuizAttempt"> | string | null
    createdAt?: DateTimeWithAggregatesFilter<"QuizAttempt"> | Date | string
  }

  export type BadgeWhereInput = {
    AND?: BadgeWhereInput | BadgeWhereInput[]
    OR?: BadgeWhereInput[]
    NOT?: BadgeWhereInput | BadgeWhereInput[]
    id?: StringFilter<"Badge"> | string
    userId?: StringFilter<"Badge"> | string
    tipo?: StringFilter<"Badge"> | string
    titulo?: StringFilter<"Badge"> | string
    descricao?: StringNullableFilter<"Badge"> | string | null
    createdAt?: DateTimeFilter<"Badge"> | Date | string
    user?: XOR<UserRelationFilter, UserWhereInput>
  }

  export type BadgeOrderByWithRelationInput = {
    id?: SortOrder
    userId?: SortOrder
    tipo?: SortOrder
    titulo?: SortOrder
    descricao?: SortOrderInput | SortOrder
    createdAt?: SortOrder
    user?: UserOrderByWithRelationInput
  }

  export type BadgeWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    userId_tipo?: BadgeUserIdTipoCompoundUniqueInput
    AND?: BadgeWhereInput | BadgeWhereInput[]
    OR?: BadgeWhereInput[]
    NOT?: BadgeWhereInput | BadgeWhereInput[]
    userId?: StringFilter<"Badge"> | string
    tipo?: StringFilter<"Badge"> | string
    titulo?: StringFilter<"Badge"> | string
    descricao?: StringNullableFilter<"Badge"> | string | null
    createdAt?: DateTimeFilter<"Badge"> | Date | string
    user?: XOR<UserRelationFilter, UserWhereInput>
  }, "id" | "userId_tipo">

  export type BadgeOrderByWithAggregationInput = {
    id?: SortOrder
    userId?: SortOrder
    tipo?: SortOrder
    titulo?: SortOrder
    descricao?: SortOrderInput | SortOrder
    createdAt?: SortOrder
    _count?: BadgeCountOrderByAggregateInput
    _max?: BadgeMaxOrderByAggregateInput
    _min?: BadgeMinOrderByAggregateInput
  }

  export type BadgeScalarWhereWithAggregatesInput = {
    AND?: BadgeScalarWhereWithAggregatesInput | BadgeScalarWhereWithAggregatesInput[]
    OR?: BadgeScalarWhereWithAggregatesInput[]
    NOT?: BadgeScalarWhereWithAggregatesInput | BadgeScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"Badge"> | string
    userId?: StringWithAggregatesFilter<"Badge"> | string
    tipo?: StringWithAggregatesFilter<"Badge"> | string
    titulo?: StringWithAggregatesFilter<"Badge"> | string
    descricao?: StringNullableWithAggregatesFilter<"Badge"> | string | null
    createdAt?: DateTimeWithAggregatesFilter<"Badge"> | Date | string
  }

  export type ApiKeyWhereInput = {
    AND?: ApiKeyWhereInput | ApiKeyWhereInput[]
    OR?: ApiKeyWhereInput[]
    NOT?: ApiKeyWhereInput | ApiKeyWhereInput[]
    id?: StringFilter<"ApiKey"> | string
    nome?: StringFilter<"ApiKey"> | string
    partnerNome?: StringFilter<"ApiKey"> | string
    chave?: StringFilter<"ApiKey"> | string
    scopes?: StringFilter<"ApiKey"> | string
    status?: StringFilter<"ApiKey"> | string
    rateLimit?: IntFilter<"ApiKey"> | number
    createdAt?: DateTimeFilter<"ApiKey"> | Date | string
    ultimoUso?: DateTimeNullableFilter<"ApiKey"> | Date | string | null
    usos?: IntFilter<"ApiKey"> | number
    chamadas?: ApiCallListRelationFilter
  }

  export type ApiKeyOrderByWithRelationInput = {
    id?: SortOrder
    nome?: SortOrder
    partnerNome?: SortOrder
    chave?: SortOrder
    scopes?: SortOrder
    status?: SortOrder
    rateLimit?: SortOrder
    createdAt?: SortOrder
    ultimoUso?: SortOrderInput | SortOrder
    usos?: SortOrder
    chamadas?: ApiCallOrderByRelationAggregateInput
  }

  export type ApiKeyWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    chave?: string
    AND?: ApiKeyWhereInput | ApiKeyWhereInput[]
    OR?: ApiKeyWhereInput[]
    NOT?: ApiKeyWhereInput | ApiKeyWhereInput[]
    nome?: StringFilter<"ApiKey"> | string
    partnerNome?: StringFilter<"ApiKey"> | string
    scopes?: StringFilter<"ApiKey"> | string
    status?: StringFilter<"ApiKey"> | string
    rateLimit?: IntFilter<"ApiKey"> | number
    createdAt?: DateTimeFilter<"ApiKey"> | Date | string
    ultimoUso?: DateTimeNullableFilter<"ApiKey"> | Date | string | null
    usos?: IntFilter<"ApiKey"> | number
    chamadas?: ApiCallListRelationFilter
  }, "id" | "chave">

  export type ApiKeyOrderByWithAggregationInput = {
    id?: SortOrder
    nome?: SortOrder
    partnerNome?: SortOrder
    chave?: SortOrder
    scopes?: SortOrder
    status?: SortOrder
    rateLimit?: SortOrder
    createdAt?: SortOrder
    ultimoUso?: SortOrderInput | SortOrder
    usos?: SortOrder
    _count?: ApiKeyCountOrderByAggregateInput
    _avg?: ApiKeyAvgOrderByAggregateInput
    _max?: ApiKeyMaxOrderByAggregateInput
    _min?: ApiKeyMinOrderByAggregateInput
    _sum?: ApiKeySumOrderByAggregateInput
  }

  export type ApiKeyScalarWhereWithAggregatesInput = {
    AND?: ApiKeyScalarWhereWithAggregatesInput | ApiKeyScalarWhereWithAggregatesInput[]
    OR?: ApiKeyScalarWhereWithAggregatesInput[]
    NOT?: ApiKeyScalarWhereWithAggregatesInput | ApiKeyScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"ApiKey"> | string
    nome?: StringWithAggregatesFilter<"ApiKey"> | string
    partnerNome?: StringWithAggregatesFilter<"ApiKey"> | string
    chave?: StringWithAggregatesFilter<"ApiKey"> | string
    scopes?: StringWithAggregatesFilter<"ApiKey"> | string
    status?: StringWithAggregatesFilter<"ApiKey"> | string
    rateLimit?: IntWithAggregatesFilter<"ApiKey"> | number
    createdAt?: DateTimeWithAggregatesFilter<"ApiKey"> | Date | string
    ultimoUso?: DateTimeNullableWithAggregatesFilter<"ApiKey"> | Date | string | null
    usos?: IntWithAggregatesFilter<"ApiKey"> | number
  }

  export type ApiCallWhereInput = {
    AND?: ApiCallWhereInput | ApiCallWhereInput[]
    OR?: ApiCallWhereInput[]
    NOT?: ApiCallWhereInput | ApiCallWhereInput[]
    id?: StringFilter<"ApiCall"> | string
    apiKeyId?: StringFilter<"ApiCall"> | string
    endpoint?: StringFilter<"ApiCall"> | string
    metodo?: StringFilter<"ApiCall"> | string
    status?: IntFilter<"ApiCall"> | number
    duracaoMs?: IntFilter<"ApiCall"> | number
    ip?: StringNullableFilter<"ApiCall"> | string | null
    timestamp?: DateTimeFilter<"ApiCall"> | Date | string
    apiKey?: XOR<ApiKeyRelationFilter, ApiKeyWhereInput>
  }

  export type ApiCallOrderByWithRelationInput = {
    id?: SortOrder
    apiKeyId?: SortOrder
    endpoint?: SortOrder
    metodo?: SortOrder
    status?: SortOrder
    duracaoMs?: SortOrder
    ip?: SortOrderInput | SortOrder
    timestamp?: SortOrder
    apiKey?: ApiKeyOrderByWithRelationInput
  }

  export type ApiCallWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    AND?: ApiCallWhereInput | ApiCallWhereInput[]
    OR?: ApiCallWhereInput[]
    NOT?: ApiCallWhereInput | ApiCallWhereInput[]
    apiKeyId?: StringFilter<"ApiCall"> | string
    endpoint?: StringFilter<"ApiCall"> | string
    metodo?: StringFilter<"ApiCall"> | string
    status?: IntFilter<"ApiCall"> | number
    duracaoMs?: IntFilter<"ApiCall"> | number
    ip?: StringNullableFilter<"ApiCall"> | string | null
    timestamp?: DateTimeFilter<"ApiCall"> | Date | string
    apiKey?: XOR<ApiKeyRelationFilter, ApiKeyWhereInput>
  }, "id">

  export type ApiCallOrderByWithAggregationInput = {
    id?: SortOrder
    apiKeyId?: SortOrder
    endpoint?: SortOrder
    metodo?: SortOrder
    status?: SortOrder
    duracaoMs?: SortOrder
    ip?: SortOrderInput | SortOrder
    timestamp?: SortOrder
    _count?: ApiCallCountOrderByAggregateInput
    _avg?: ApiCallAvgOrderByAggregateInput
    _max?: ApiCallMaxOrderByAggregateInput
    _min?: ApiCallMinOrderByAggregateInput
    _sum?: ApiCallSumOrderByAggregateInput
  }

  export type ApiCallScalarWhereWithAggregatesInput = {
    AND?: ApiCallScalarWhereWithAggregatesInput | ApiCallScalarWhereWithAggregatesInput[]
    OR?: ApiCallScalarWhereWithAggregatesInput[]
    NOT?: ApiCallScalarWhereWithAggregatesInput | ApiCallScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"ApiCall"> | string
    apiKeyId?: StringWithAggregatesFilter<"ApiCall"> | string
    endpoint?: StringWithAggregatesFilter<"ApiCall"> | string
    metodo?: StringWithAggregatesFilter<"ApiCall"> | string
    status?: IntWithAggregatesFilter<"ApiCall"> | number
    duracaoMs?: IntWithAggregatesFilter<"ApiCall"> | number
    ip?: StringNullableWithAggregatesFilter<"ApiCall"> | string | null
    timestamp?: DateTimeWithAggregatesFilter<"ApiCall"> | Date | string
  }

  export type InsuranceProductWhereInput = {
    AND?: InsuranceProductWhereInput | InsuranceProductWhereInput[]
    OR?: InsuranceProductWhereInput[]
    NOT?: InsuranceProductWhereInput | InsuranceProductWhereInput[]
    id?: StringFilter<"InsuranceProduct"> | string
    nome?: StringFilter<"InsuranceProduct"> | string
    tipo?: StringFilter<"InsuranceProduct"> | string
    premiumMensal?: FloatFilter<"InsuranceProduct"> | number
    coberturaMax?: FloatFilter<"InsuranceProduct"> | number
    descricao?: StringNullableFilter<"InsuranceProduct"> | string | null
    activo?: BoolFilter<"InsuranceProduct"> | boolean
    policies?: InsurancePolicyListRelationFilter
  }

  export type InsuranceProductOrderByWithRelationInput = {
    id?: SortOrder
    nome?: SortOrder
    tipo?: SortOrder
    premiumMensal?: SortOrder
    coberturaMax?: SortOrder
    descricao?: SortOrderInput | SortOrder
    activo?: SortOrder
    policies?: InsurancePolicyOrderByRelationAggregateInput
  }

  export type InsuranceProductWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    AND?: InsuranceProductWhereInput | InsuranceProductWhereInput[]
    OR?: InsuranceProductWhereInput[]
    NOT?: InsuranceProductWhereInput | InsuranceProductWhereInput[]
    nome?: StringFilter<"InsuranceProduct"> | string
    tipo?: StringFilter<"InsuranceProduct"> | string
    premiumMensal?: FloatFilter<"InsuranceProduct"> | number
    coberturaMax?: FloatFilter<"InsuranceProduct"> | number
    descricao?: StringNullableFilter<"InsuranceProduct"> | string | null
    activo?: BoolFilter<"InsuranceProduct"> | boolean
    policies?: InsurancePolicyListRelationFilter
  }, "id">

  export type InsuranceProductOrderByWithAggregationInput = {
    id?: SortOrder
    nome?: SortOrder
    tipo?: SortOrder
    premiumMensal?: SortOrder
    coberturaMax?: SortOrder
    descricao?: SortOrderInput | SortOrder
    activo?: SortOrder
    _count?: InsuranceProductCountOrderByAggregateInput
    _avg?: InsuranceProductAvgOrderByAggregateInput
    _max?: InsuranceProductMaxOrderByAggregateInput
    _min?: InsuranceProductMinOrderByAggregateInput
    _sum?: InsuranceProductSumOrderByAggregateInput
  }

  export type InsuranceProductScalarWhereWithAggregatesInput = {
    AND?: InsuranceProductScalarWhereWithAggregatesInput | InsuranceProductScalarWhereWithAggregatesInput[]
    OR?: InsuranceProductScalarWhereWithAggregatesInput[]
    NOT?: InsuranceProductScalarWhereWithAggregatesInput | InsuranceProductScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"InsuranceProduct"> | string
    nome?: StringWithAggregatesFilter<"InsuranceProduct"> | string
    tipo?: StringWithAggregatesFilter<"InsuranceProduct"> | string
    premiumMensal?: FloatWithAggregatesFilter<"InsuranceProduct"> | number
    coberturaMax?: FloatWithAggregatesFilter<"InsuranceProduct"> | number
    descricao?: StringNullableWithAggregatesFilter<"InsuranceProduct"> | string | null
    activo?: BoolWithAggregatesFilter<"InsuranceProduct"> | boolean
  }

  export type InsurancePolicyWhereInput = {
    AND?: InsurancePolicyWhereInput | InsurancePolicyWhereInput[]
    OR?: InsurancePolicyWhereInput[]
    NOT?: InsurancePolicyWhereInput | InsurancePolicyWhereInput[]
    id?: StringFilter<"InsurancePolicy"> | string
    userId?: StringFilter<"InsurancePolicy"> | string
    productId?: StringFilter<"InsurancePolicy"> | string
    status?: StringFilter<"InsurancePolicy"> | string
    dataInicio?: DateTimeFilter<"InsurancePolicy"> | Date | string
    premiumPago?: FloatFilter<"InsurancePolicy"> | number
    proximaCobranca?: DateTimeNullableFilter<"InsurancePolicy"> | Date | string | null
    user?: XOR<UserRelationFilter, UserWhereInput>
    product?: XOR<InsuranceProductRelationFilter, InsuranceProductWhereInput>
  }

  export type InsurancePolicyOrderByWithRelationInput = {
    id?: SortOrder
    userId?: SortOrder
    productId?: SortOrder
    status?: SortOrder
    dataInicio?: SortOrder
    premiumPago?: SortOrder
    proximaCobranca?: SortOrderInput | SortOrder
    user?: UserOrderByWithRelationInput
    product?: InsuranceProductOrderByWithRelationInput
  }

  export type InsurancePolicyWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    AND?: InsurancePolicyWhereInput | InsurancePolicyWhereInput[]
    OR?: InsurancePolicyWhereInput[]
    NOT?: InsurancePolicyWhereInput | InsurancePolicyWhereInput[]
    userId?: StringFilter<"InsurancePolicy"> | string
    productId?: StringFilter<"InsurancePolicy"> | string
    status?: StringFilter<"InsurancePolicy"> | string
    dataInicio?: DateTimeFilter<"InsurancePolicy"> | Date | string
    premiumPago?: FloatFilter<"InsurancePolicy"> | number
    proximaCobranca?: DateTimeNullableFilter<"InsurancePolicy"> | Date | string | null
    user?: XOR<UserRelationFilter, UserWhereInput>
    product?: XOR<InsuranceProductRelationFilter, InsuranceProductWhereInput>
  }, "id">

  export type InsurancePolicyOrderByWithAggregationInput = {
    id?: SortOrder
    userId?: SortOrder
    productId?: SortOrder
    status?: SortOrder
    dataInicio?: SortOrder
    premiumPago?: SortOrder
    proximaCobranca?: SortOrderInput | SortOrder
    _count?: InsurancePolicyCountOrderByAggregateInput
    _avg?: InsurancePolicyAvgOrderByAggregateInput
    _max?: InsurancePolicyMaxOrderByAggregateInput
    _min?: InsurancePolicyMinOrderByAggregateInput
    _sum?: InsurancePolicySumOrderByAggregateInput
  }

  export type InsurancePolicyScalarWhereWithAggregatesInput = {
    AND?: InsurancePolicyScalarWhereWithAggregatesInput | InsurancePolicyScalarWhereWithAggregatesInput[]
    OR?: InsurancePolicyScalarWhereWithAggregatesInput[]
    NOT?: InsurancePolicyScalarWhereWithAggregatesInput | InsurancePolicyScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"InsurancePolicy"> | string
    userId?: StringWithAggregatesFilter<"InsurancePolicy"> | string
    productId?: StringWithAggregatesFilter<"InsurancePolicy"> | string
    status?: StringWithAggregatesFilter<"InsurancePolicy"> | string
    dataInicio?: DateTimeWithAggregatesFilter<"InsurancePolicy"> | Date | string
    premiumPago?: FloatWithAggregatesFilter<"InsurancePolicy"> | number
    proximaCobranca?: DateTimeNullableWithAggregatesFilter<"InsurancePolicy"> | Date | string | null
  }

  export type CountryWhereInput = {
    AND?: CountryWhereInput | CountryWhereInput[]
    OR?: CountryWhereInput[]
    NOT?: CountryWhereInput | CountryWhereInput[]
    codigo?: StringFilter<"Country"> | string
    nome?: StringFilter<"Country"> | string
    moedaPadrao?: StringFilter<"Country"> | string
    regulador?: StringFilter<"Country"> | string
    estrutura?: StringNullableFilter<"Country"> | string | null
    activo?: BoolFilter<"Country"> | boolean
  }

  export type CountryOrderByWithRelationInput = {
    codigo?: SortOrder
    nome?: SortOrder
    moedaPadrao?: SortOrder
    regulador?: SortOrder
    estrutura?: SortOrderInput | SortOrder
    activo?: SortOrder
  }

  export type CountryWhereUniqueInput = Prisma.AtLeast<{
    codigo?: string
    AND?: CountryWhereInput | CountryWhereInput[]
    OR?: CountryWhereInput[]
    NOT?: CountryWhereInput | CountryWhereInput[]
    nome?: StringFilter<"Country"> | string
    moedaPadrao?: StringFilter<"Country"> | string
    regulador?: StringFilter<"Country"> | string
    estrutura?: StringNullableFilter<"Country"> | string | null
    activo?: BoolFilter<"Country"> | boolean
  }, "codigo">

  export type CountryOrderByWithAggregationInput = {
    codigo?: SortOrder
    nome?: SortOrder
    moedaPadrao?: SortOrder
    regulador?: SortOrder
    estrutura?: SortOrderInput | SortOrder
    activo?: SortOrder
    _count?: CountryCountOrderByAggregateInput
    _max?: CountryMaxOrderByAggregateInput
    _min?: CountryMinOrderByAggregateInput
  }

  export type CountryScalarWhereWithAggregatesInput = {
    AND?: CountryScalarWhereWithAggregatesInput | CountryScalarWhereWithAggregatesInput[]
    OR?: CountryScalarWhereWithAggregatesInput[]
    NOT?: CountryScalarWhereWithAggregatesInput | CountryScalarWhereWithAggregatesInput[]
    codigo?: StringWithAggregatesFilter<"Country"> | string
    nome?: StringWithAggregatesFilter<"Country"> | string
    moedaPadrao?: StringWithAggregatesFilter<"Country"> | string
    regulador?: StringWithAggregatesFilter<"Country"> | string
    estrutura?: StringNullableWithAggregatesFilter<"Country"> | string | null
    activo?: BoolWithAggregatesFilter<"Country"> | boolean
  }

  export type AnalyticsSnapshotWhereInput = {
    AND?: AnalyticsSnapshotWhereInput | AnalyticsSnapshotWhereInput[]
    OR?: AnalyticsSnapshotWhereInput[]
    NOT?: AnalyticsSnapshotWhereInput | AnalyticsSnapshotWhereInput[]
    id?: StringFilter<"AnalyticsSnapshot"> | string
    data?: DateTimeFilter<"AnalyticsSnapshot"> | Date | string
    utilizadoresActivos?: IntFilter<"AnalyticsSnapshot"> | number
    gruposActivos?: IntFilter<"AnalyticsSnapshot"> | number
    contribuicoesPagas?: IntFilter<"AnalyticsSnapshot"> | number
    volumeMensal?: FloatFilter<"AnalyticsSnapshot"> | number
    defaultsAbertos?: IntFilter<"AnalyticsSnapshot"> | number
    fundoCobertura?: FloatFilter<"AnalyticsSnapshot"> | number
    createdAt?: DateTimeFilter<"AnalyticsSnapshot"> | Date | string
  }

  export type AnalyticsSnapshotOrderByWithRelationInput = {
    id?: SortOrder
    data?: SortOrder
    utilizadoresActivos?: SortOrder
    gruposActivos?: SortOrder
    contribuicoesPagas?: SortOrder
    volumeMensal?: SortOrder
    defaultsAbertos?: SortOrder
    fundoCobertura?: SortOrder
    createdAt?: SortOrder
  }

  export type AnalyticsSnapshotWhereUniqueInput = Prisma.AtLeast<{
    id?: string
    data?: Date | string
    AND?: AnalyticsSnapshotWhereInput | AnalyticsSnapshotWhereInput[]
    OR?: AnalyticsSnapshotWhereInput[]
    NOT?: AnalyticsSnapshotWhereInput | AnalyticsSnapshotWhereInput[]
    utilizadoresActivos?: IntFilter<"AnalyticsSnapshot"> | number
    gruposActivos?: IntFilter<"AnalyticsSnapshot"> | number
    contribuicoesPagas?: IntFilter<"AnalyticsSnapshot"> | number
    volumeMensal?: FloatFilter<"AnalyticsSnapshot"> | number
    defaultsAbertos?: IntFilter<"AnalyticsSnapshot"> | number
    fundoCobertura?: FloatFilter<"AnalyticsSnapshot"> | number
    createdAt?: DateTimeFilter<"AnalyticsSnapshot"> | Date | string
  }, "id" | "data">

  export type AnalyticsSnapshotOrderByWithAggregationInput = {
    id?: SortOrder
    data?: SortOrder
    utilizadoresActivos?: SortOrder
    gruposActivos?: SortOrder
    contribuicoesPagas?: SortOrder
    volumeMensal?: SortOrder
    defaultsAbertos?: SortOrder
    fundoCobertura?: SortOrder
    createdAt?: SortOrder
    _count?: AnalyticsSnapshotCountOrderByAggregateInput
    _avg?: AnalyticsSnapshotAvgOrderByAggregateInput
    _max?: AnalyticsSnapshotMaxOrderByAggregateInput
    _min?: AnalyticsSnapshotMinOrderByAggregateInput
    _sum?: AnalyticsSnapshotSumOrderByAggregateInput
  }

  export type AnalyticsSnapshotScalarWhereWithAggregatesInput = {
    AND?: AnalyticsSnapshotScalarWhereWithAggregatesInput | AnalyticsSnapshotScalarWhereWithAggregatesInput[]
    OR?: AnalyticsSnapshotScalarWhereWithAggregatesInput[]
    NOT?: AnalyticsSnapshotScalarWhereWithAggregatesInput | AnalyticsSnapshotScalarWhereWithAggregatesInput[]
    id?: StringWithAggregatesFilter<"AnalyticsSnapshot"> | string
    data?: DateTimeWithAggregatesFilter<"AnalyticsSnapshot"> | Date | string
    utilizadoresActivos?: IntWithAggregatesFilter<"AnalyticsSnapshot"> | number
    gruposActivos?: IntWithAggregatesFilter<"AnalyticsSnapshot"> | number
    contribuicoesPagas?: IntWithAggregatesFilter<"AnalyticsSnapshot"> | number
    volumeMensal?: FloatWithAggregatesFilter<"AnalyticsSnapshot"> | number
    defaultsAbertos?: IntWithAggregatesFilter<"AnalyticsSnapshot"> | number
    fundoCobertura?: FloatWithAggregatesFilter<"AnalyticsSnapshot"> | number
    createdAt?: DateTimeWithAggregatesFilter<"AnalyticsSnapshot"> | Date | string
  }

  export type UserCreateInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referredBy?: UserCreateNestedOneWithoutReferidosInput
    referidos?: UserCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupCreateNestedManyWithoutCriadorInput
    memberships?: MembershipCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionCreateNestedManyWithoutUserInput
    cashouts?: CashoutCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationCreateNestedManyWithoutUserInput
    otps?: OtpCreateNestedManyWithoutUserInput
    sessions?: SessionCreateNestedManyWithoutUserInput
    notifications?: NotificationCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptCreateNestedManyWithoutUserInput
    badges?: BadgeCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyCreateNestedManyWithoutUserInput
  }

  export type UserUncheckedCreateInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    referredById?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referidos?: UserUncheckedCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupUncheckedCreateNestedManyWithoutCriadorInput
    memberships?: MembershipUncheckedCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionUncheckedCreateNestedManyWithoutUserInput
    cashouts?: CashoutUncheckedCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanUncheckedCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventUncheckedCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationUncheckedCreateNestedManyWithoutUserInput
    otps?: OtpUncheckedCreateNestedManyWithoutUserInput
    sessions?: SessionUncheckedCreateNestedManyWithoutUserInput
    notifications?: NotificationUncheckedCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionUncheckedCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteUncheckedCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationUncheckedCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogUncheckedCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationUncheckedCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountUncheckedCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralUncheckedCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralUncheckedCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptUncheckedCreateNestedManyWithoutUserInput
    badges?: BadgeUncheckedCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyUncheckedCreateNestedManyWithoutUserInput
  }

  export type UserUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referredBy?: UserUpdateOneWithoutReferidosNestedInput
    referidos?: UserUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUpdateManyWithoutUserNestedInput
    otps?: OtpUpdateManyWithoutUserNestedInput
    sessions?: SessionUpdateManyWithoutUserNestedInput
    notifications?: NotificationUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUpdateManyWithoutUserNestedInput
    badges?: BadgeUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUpdateManyWithoutUserNestedInput
  }

  export type UserUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    referredById?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referidos?: UserUncheckedUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUncheckedUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUncheckedUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUncheckedUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUncheckedUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUncheckedUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUncheckedUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUncheckedUpdateManyWithoutUserNestedInput
    otps?: OtpUncheckedUpdateManyWithoutUserNestedInput
    sessions?: SessionUncheckedUpdateManyWithoutUserNestedInput
    notifications?: NotificationUncheckedUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUncheckedUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUncheckedUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUncheckedUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUncheckedUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUncheckedUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUncheckedUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUncheckedUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUncheckedUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUncheckedUpdateManyWithoutUserNestedInput
    badges?: BadgeUncheckedUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUncheckedUpdateManyWithoutUserNestedInput
  }

  export type UserCreateManyInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    referredById?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
  }

  export type UserUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type UserUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    referredById?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type OtpCreateInput = {
    id?: string
    telefone: string
    codigo: string
    proposito: string
    consumido?: boolean
    expiraEm: Date | string
    createdAt?: Date | string
    user?: UserCreateNestedOneWithoutOtpsInput
  }

  export type OtpUncheckedCreateInput = {
    id?: string
    userId?: string | null
    telefone: string
    codigo: string
    proposito: string
    consumido?: boolean
    expiraEm: Date | string
    createdAt?: Date | string
  }

  export type OtpUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    codigo?: StringFieldUpdateOperationsInput | string
    proposito?: StringFieldUpdateOperationsInput | string
    consumido?: BoolFieldUpdateOperationsInput | boolean
    expiraEm?: DateTimeFieldUpdateOperationsInput | Date | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    user?: UserUpdateOneWithoutOtpsNestedInput
  }

  export type OtpUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: NullableStringFieldUpdateOperationsInput | string | null
    telefone?: StringFieldUpdateOperationsInput | string
    codigo?: StringFieldUpdateOperationsInput | string
    proposito?: StringFieldUpdateOperationsInput | string
    consumido?: BoolFieldUpdateOperationsInput | boolean
    expiraEm?: DateTimeFieldUpdateOperationsInput | Date | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type OtpCreateManyInput = {
    id?: string
    userId?: string | null
    telefone: string
    codigo: string
    proposito: string
    consumido?: boolean
    expiraEm: Date | string
    createdAt?: Date | string
  }

  export type OtpUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    codigo?: StringFieldUpdateOperationsInput | string
    proposito?: StringFieldUpdateOperationsInput | string
    consumido?: BoolFieldUpdateOperationsInput | boolean
    expiraEm?: DateTimeFieldUpdateOperationsInput | Date | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type OtpUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: NullableStringFieldUpdateOperationsInput | string | null
    telefone?: StringFieldUpdateOperationsInput | string
    codigo?: StringFieldUpdateOperationsInput | string
    proposito?: StringFieldUpdateOperationsInput | string
    consumido?: BoolFieldUpdateOperationsInput | boolean
    expiraEm?: DateTimeFieldUpdateOperationsInput | Date | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type SessionCreateInput = {
    id?: string
    token: string
    expiraEm: Date | string
    createdAt?: Date | string
    user: UserCreateNestedOneWithoutSessionsInput
  }

  export type SessionUncheckedCreateInput = {
    id?: string
    userId: string
    token: string
    expiraEm: Date | string
    createdAt?: Date | string
  }

  export type SessionUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    token?: StringFieldUpdateOperationsInput | string
    expiraEm?: DateTimeFieldUpdateOperationsInput | Date | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    user?: UserUpdateOneRequiredWithoutSessionsNestedInput
  }

  export type SessionUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    token?: StringFieldUpdateOperationsInput | string
    expiraEm?: DateTimeFieldUpdateOperationsInput | Date | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type SessionCreateManyInput = {
    id?: string
    userId: string
    token: string
    expiraEm: Date | string
    createdAt?: Date | string
  }

  export type SessionUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    token?: StringFieldUpdateOperationsInput | string
    expiraEm?: DateTimeFieldUpdateOperationsInput | Date | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type SessionUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    token?: StringFieldUpdateOperationsInput | string
    expiraEm?: DateTimeFieldUpdateOperationsInput | Date | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type GroupCreateInput = {
    id?: string
    nome: string
    descricao?: string | null
    numMembros: number
    valorContribuicaoMensal: number
    taxaPrincipalAplicada: number
    reservaTecnicaAplicada: number
    periodicidade?: string
    tipo?: string
    pais?: string
    moeda?: string
    status?: string
    dataInicio?: Date | string | null
    dataFimPrevista?: Date | string | null
    cicloAtual?: number
    totalCiclos: number
    createdAt?: Date | string
    updatedAt?: Date | string
    criador: UserCreateNestedOneWithoutGruposCriadosInput
    memberships?: MembershipCreateNestedManyWithoutGroupInput
    monthlyCycles?: MonthlyCycleCreateNestedManyWithoutGroupInput
    invites?: InviteCreateNestedManyWithoutGroupInput
    candidaturas?: GroupApplicationCreateNestedManyWithoutGroupInput
  }

  export type GroupUncheckedCreateInput = {
    id?: string
    nome: string
    descricao?: string | null
    criadorId: string
    numMembros: number
    valorContribuicaoMensal: number
    taxaPrincipalAplicada: number
    reservaTecnicaAplicada: number
    periodicidade?: string
    tipo?: string
    pais?: string
    moeda?: string
    status?: string
    dataInicio?: Date | string | null
    dataFimPrevista?: Date | string | null
    cicloAtual?: number
    totalCiclos: number
    createdAt?: Date | string
    updatedAt?: Date | string
    memberships?: MembershipUncheckedCreateNestedManyWithoutGroupInput
    monthlyCycles?: MonthlyCycleUncheckedCreateNestedManyWithoutGroupInput
    invites?: InviteUncheckedCreateNestedManyWithoutGroupInput
    candidaturas?: GroupApplicationUncheckedCreateNestedManyWithoutGroupInput
  }

  export type GroupUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    numMembros?: IntFieldUpdateOperationsInput | number
    valorContribuicaoMensal?: FloatFieldUpdateOperationsInput | number
    taxaPrincipalAplicada?: FloatFieldUpdateOperationsInput | number
    reservaTecnicaAplicada?: FloatFieldUpdateOperationsInput | number
    periodicidade?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    pais?: StringFieldUpdateOperationsInput | string
    moeda?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    dataInicio?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    dataFimPrevista?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    cicloAtual?: IntFieldUpdateOperationsInput | number
    totalCiclos?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    criador?: UserUpdateOneRequiredWithoutGruposCriadosNestedInput
    memberships?: MembershipUpdateManyWithoutGroupNestedInput
    monthlyCycles?: MonthlyCycleUpdateManyWithoutGroupNestedInput
    invites?: InviteUpdateManyWithoutGroupNestedInput
    candidaturas?: GroupApplicationUpdateManyWithoutGroupNestedInput
  }

  export type GroupUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    criadorId?: StringFieldUpdateOperationsInput | string
    numMembros?: IntFieldUpdateOperationsInput | number
    valorContribuicaoMensal?: FloatFieldUpdateOperationsInput | number
    taxaPrincipalAplicada?: FloatFieldUpdateOperationsInput | number
    reservaTecnicaAplicada?: FloatFieldUpdateOperationsInput | number
    periodicidade?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    pais?: StringFieldUpdateOperationsInput | string
    moeda?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    dataInicio?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    dataFimPrevista?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    cicloAtual?: IntFieldUpdateOperationsInput | number
    totalCiclos?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    memberships?: MembershipUncheckedUpdateManyWithoutGroupNestedInput
    monthlyCycles?: MonthlyCycleUncheckedUpdateManyWithoutGroupNestedInput
    invites?: InviteUncheckedUpdateManyWithoutGroupNestedInput
    candidaturas?: GroupApplicationUncheckedUpdateManyWithoutGroupNestedInput
  }

  export type GroupCreateManyInput = {
    id?: string
    nome: string
    descricao?: string | null
    criadorId: string
    numMembros: number
    valorContribuicaoMensal: number
    taxaPrincipalAplicada: number
    reservaTecnicaAplicada: number
    periodicidade?: string
    tipo?: string
    pais?: string
    moeda?: string
    status?: string
    dataInicio?: Date | string | null
    dataFimPrevista?: Date | string | null
    cicloAtual?: number
    totalCiclos: number
    createdAt?: Date | string
    updatedAt?: Date | string
  }

  export type GroupUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    numMembros?: IntFieldUpdateOperationsInput | number
    valorContribuicaoMensal?: FloatFieldUpdateOperationsInput | number
    taxaPrincipalAplicada?: FloatFieldUpdateOperationsInput | number
    reservaTecnicaAplicada?: FloatFieldUpdateOperationsInput | number
    periodicidade?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    pais?: StringFieldUpdateOperationsInput | string
    moeda?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    dataInicio?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    dataFimPrevista?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    cicloAtual?: IntFieldUpdateOperationsInput | number
    totalCiclos?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type GroupUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    criadorId?: StringFieldUpdateOperationsInput | string
    numMembros?: IntFieldUpdateOperationsInput | number
    valorContribuicaoMensal?: FloatFieldUpdateOperationsInput | number
    taxaPrincipalAplicada?: FloatFieldUpdateOperationsInput | number
    reservaTecnicaAplicada?: FloatFieldUpdateOperationsInput | number
    periodicidade?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    pais?: StringFieldUpdateOperationsInput | string
    moeda?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    dataInicio?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    dataFimPrevista?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    cicloAtual?: IntFieldUpdateOperationsInput | number
    totalCiclos?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type GroupApplicationCreateInput = {
    id?: string
    userId: string
    mensagem?: string | null
    status?: string
    createdAt?: Date | string
    group: GroupCreateNestedOneWithoutCandidaturasInput
  }

  export type GroupApplicationUncheckedCreateInput = {
    id?: string
    groupId: string
    userId: string
    mensagem?: string | null
    status?: string
    createdAt?: Date | string
  }

  export type GroupApplicationUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    mensagem?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    group?: GroupUpdateOneRequiredWithoutCandidaturasNestedInput
  }

  export type GroupApplicationUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    groupId?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    mensagem?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type GroupApplicationCreateManyInput = {
    id?: string
    groupId: string
    userId: string
    mensagem?: string | null
    status?: string
    createdAt?: Date | string
  }

  export type GroupApplicationUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    mensagem?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type GroupApplicationUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    groupId?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    mensagem?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type MembershipCreateInput = {
    id?: string
    posicaoRotacao?: number | null
    status?: string
    necessidadeUrgente?: boolean
    dataJuncao?: Date | string
    mesRecepcaoPrevisto?: string | null
    user: UserCreateNestedOneWithoutMembershipsInput
    group: GroupCreateNestedOneWithoutMembershipsInput
    monthlyCyclesBeneficiario?: MonthlyCycleCreateNestedManyWithoutBeneficiarioMembershipInput
    contribuicoes?: ContributionCreateNestedManyWithoutMembershipInput
  }

  export type MembershipUncheckedCreateInput = {
    id?: string
    userId: string
    groupId: string
    posicaoRotacao?: number | null
    status?: string
    necessidadeUrgente?: boolean
    dataJuncao?: Date | string
    mesRecepcaoPrevisto?: string | null
    monthlyCyclesBeneficiario?: MonthlyCycleUncheckedCreateNestedManyWithoutBeneficiarioMembershipInput
    contribuicoes?: ContributionUncheckedCreateNestedManyWithoutMembershipInput
  }

  export type MembershipUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    posicaoRotacao?: NullableIntFieldUpdateOperationsInput | number | null
    status?: StringFieldUpdateOperationsInput | string
    necessidadeUrgente?: BoolFieldUpdateOperationsInput | boolean
    dataJuncao?: DateTimeFieldUpdateOperationsInput | Date | string
    mesRecepcaoPrevisto?: NullableStringFieldUpdateOperationsInput | string | null
    user?: UserUpdateOneRequiredWithoutMembershipsNestedInput
    group?: GroupUpdateOneRequiredWithoutMembershipsNestedInput
    monthlyCyclesBeneficiario?: MonthlyCycleUpdateManyWithoutBeneficiarioMembershipNestedInput
    contribuicoes?: ContributionUpdateManyWithoutMembershipNestedInput
  }

  export type MembershipUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    groupId?: StringFieldUpdateOperationsInput | string
    posicaoRotacao?: NullableIntFieldUpdateOperationsInput | number | null
    status?: StringFieldUpdateOperationsInput | string
    necessidadeUrgente?: BoolFieldUpdateOperationsInput | boolean
    dataJuncao?: DateTimeFieldUpdateOperationsInput | Date | string
    mesRecepcaoPrevisto?: NullableStringFieldUpdateOperationsInput | string | null
    monthlyCyclesBeneficiario?: MonthlyCycleUncheckedUpdateManyWithoutBeneficiarioMembershipNestedInput
    contribuicoes?: ContributionUncheckedUpdateManyWithoutMembershipNestedInput
  }

  export type MembershipCreateManyInput = {
    id?: string
    userId: string
    groupId: string
    posicaoRotacao?: number | null
    status?: string
    necessidadeUrgente?: boolean
    dataJuncao?: Date | string
    mesRecepcaoPrevisto?: string | null
  }

  export type MembershipUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    posicaoRotacao?: NullableIntFieldUpdateOperationsInput | number | null
    status?: StringFieldUpdateOperationsInput | string
    necessidadeUrgente?: BoolFieldUpdateOperationsInput | boolean
    dataJuncao?: DateTimeFieldUpdateOperationsInput | Date | string
    mesRecepcaoPrevisto?: NullableStringFieldUpdateOperationsInput | string | null
  }

  export type MembershipUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    groupId?: StringFieldUpdateOperationsInput | string
    posicaoRotacao?: NullableIntFieldUpdateOperationsInput | number | null
    status?: StringFieldUpdateOperationsInput | string
    necessidadeUrgente?: BoolFieldUpdateOperationsInput | boolean
    dataJuncao?: DateTimeFieldUpdateOperationsInput | Date | string
    mesRecepcaoPrevisto?: NullableStringFieldUpdateOperationsInput | string | null
  }

  export type InviteCreateInput = {
    id?: string
    telefone: string
    email?: string | null
    token: string
    status?: string
    createdAt?: Date | string
    expiraEm: Date | string
    group: GroupCreateNestedOneWithoutInvitesInput
    convidadoPor: UserCreateNestedOneWithoutInvitesEnviadosInput
  }

  export type InviteUncheckedCreateInput = {
    id?: string
    groupId: string
    convidadoPorId: string
    telefone: string
    email?: string | null
    token: string
    status?: string
    createdAt?: Date | string
    expiraEm: Date | string
  }

  export type InviteUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: NullableStringFieldUpdateOperationsInput | string | null
    token?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    expiraEm?: DateTimeFieldUpdateOperationsInput | Date | string
    group?: GroupUpdateOneRequiredWithoutInvitesNestedInput
    convidadoPor?: UserUpdateOneRequiredWithoutInvitesEnviadosNestedInput
  }

  export type InviteUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    groupId?: StringFieldUpdateOperationsInput | string
    convidadoPorId?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: NullableStringFieldUpdateOperationsInput | string | null
    token?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    expiraEm?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type InviteCreateManyInput = {
    id?: string
    groupId: string
    convidadoPorId: string
    telefone: string
    email?: string | null
    token: string
    status?: string
    createdAt?: Date | string
    expiraEm: Date | string
  }

  export type InviteUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: NullableStringFieldUpdateOperationsInput | string | null
    token?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    expiraEm?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type InviteUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    groupId?: StringFieldUpdateOperationsInput | string
    convidadoPorId?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: NullableStringFieldUpdateOperationsInput | string | null
    token?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    expiraEm?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type MonthlyCycleCreateInput = {
    id?: string
    numeroCiclo: number
    mesAno: string
    dataContribuicaoLimite: Date | string
    dataCashout: Date | string
    status?: string
    valorPoteBruto: number
    valorTaxaPrincipal: number
    valorReservaTecnica: number
    valorPoteLiquido: number
    createdAt?: Date | string
    updatedAt?: Date | string
    group: GroupCreateNestedOneWithoutMonthlyCyclesInput
    beneficiarioMembership: MembershipCreateNestedOneWithoutMonthlyCyclesBeneficiarioInput
    contribuicoes?: ContributionCreateNestedManyWithoutMonthlyCycleInput
    cashout?: CashoutCreateNestedOneWithoutMonthlyCycleInput
    loans?: LoanCreateNestedManyWithoutMonthlyCycleInput
  }

  export type MonthlyCycleUncheckedCreateInput = {
    id?: string
    groupId: string
    numeroCiclo: number
    mesAno: string
    beneficiarioMembershipId: string
    dataContribuicaoLimite: Date | string
    dataCashout: Date | string
    status?: string
    valorPoteBruto: number
    valorTaxaPrincipal: number
    valorReservaTecnica: number
    valorPoteLiquido: number
    createdAt?: Date | string
    updatedAt?: Date | string
    contribuicoes?: ContributionUncheckedCreateNestedManyWithoutMonthlyCycleInput
    cashout?: CashoutUncheckedCreateNestedOneWithoutMonthlyCycleInput
    loans?: LoanUncheckedCreateNestedManyWithoutMonthlyCycleInput
  }

  export type MonthlyCycleUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    numeroCiclo?: IntFieldUpdateOperationsInput | number
    mesAno?: StringFieldUpdateOperationsInput | string
    dataContribuicaoLimite?: DateTimeFieldUpdateOperationsInput | Date | string
    dataCashout?: DateTimeFieldUpdateOperationsInput | Date | string
    status?: StringFieldUpdateOperationsInput | string
    valorPoteBruto?: FloatFieldUpdateOperationsInput | number
    valorTaxaPrincipal?: FloatFieldUpdateOperationsInput | number
    valorReservaTecnica?: FloatFieldUpdateOperationsInput | number
    valorPoteLiquido?: FloatFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    group?: GroupUpdateOneRequiredWithoutMonthlyCyclesNestedInput
    beneficiarioMembership?: MembershipUpdateOneRequiredWithoutMonthlyCyclesBeneficiarioNestedInput
    contribuicoes?: ContributionUpdateManyWithoutMonthlyCycleNestedInput
    cashout?: CashoutUpdateOneWithoutMonthlyCycleNestedInput
    loans?: LoanUpdateManyWithoutMonthlyCycleNestedInput
  }

  export type MonthlyCycleUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    groupId?: StringFieldUpdateOperationsInput | string
    numeroCiclo?: IntFieldUpdateOperationsInput | number
    mesAno?: StringFieldUpdateOperationsInput | string
    beneficiarioMembershipId?: StringFieldUpdateOperationsInput | string
    dataContribuicaoLimite?: DateTimeFieldUpdateOperationsInput | Date | string
    dataCashout?: DateTimeFieldUpdateOperationsInput | Date | string
    status?: StringFieldUpdateOperationsInput | string
    valorPoteBruto?: FloatFieldUpdateOperationsInput | number
    valorTaxaPrincipal?: FloatFieldUpdateOperationsInput | number
    valorReservaTecnica?: FloatFieldUpdateOperationsInput | number
    valorPoteLiquido?: FloatFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    contribuicoes?: ContributionUncheckedUpdateManyWithoutMonthlyCycleNestedInput
    cashout?: CashoutUncheckedUpdateOneWithoutMonthlyCycleNestedInput
    loans?: LoanUncheckedUpdateManyWithoutMonthlyCycleNestedInput
  }

  export type MonthlyCycleCreateManyInput = {
    id?: string
    groupId: string
    numeroCiclo: number
    mesAno: string
    beneficiarioMembershipId: string
    dataContribuicaoLimite: Date | string
    dataCashout: Date | string
    status?: string
    valorPoteBruto: number
    valorTaxaPrincipal: number
    valorReservaTecnica: number
    valorPoteLiquido: number
    createdAt?: Date | string
    updatedAt?: Date | string
  }

  export type MonthlyCycleUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    numeroCiclo?: IntFieldUpdateOperationsInput | number
    mesAno?: StringFieldUpdateOperationsInput | string
    dataContribuicaoLimite?: DateTimeFieldUpdateOperationsInput | Date | string
    dataCashout?: DateTimeFieldUpdateOperationsInput | Date | string
    status?: StringFieldUpdateOperationsInput | string
    valorPoteBruto?: FloatFieldUpdateOperationsInput | number
    valorTaxaPrincipal?: FloatFieldUpdateOperationsInput | number
    valorReservaTecnica?: FloatFieldUpdateOperationsInput | number
    valorPoteLiquido?: FloatFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type MonthlyCycleUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    groupId?: StringFieldUpdateOperationsInput | string
    numeroCiclo?: IntFieldUpdateOperationsInput | number
    mesAno?: StringFieldUpdateOperationsInput | string
    beneficiarioMembershipId?: StringFieldUpdateOperationsInput | string
    dataContribuicaoLimite?: DateTimeFieldUpdateOperationsInput | Date | string
    dataCashout?: DateTimeFieldUpdateOperationsInput | Date | string
    status?: StringFieldUpdateOperationsInput | string
    valorPoteBruto?: FloatFieldUpdateOperationsInput | number
    valorTaxaPrincipal?: FloatFieldUpdateOperationsInput | number
    valorReservaTecnica?: FloatFieldUpdateOperationsInput | number
    valorPoteLiquido?: FloatFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type ContributionCreateInput = {
    id?: string
    valor: number
    dataPrevista: Date | string
    dataPagamento?: Date | string | null
    status?: string
    metodoPagamento?: string | null
    referenciaBancaria?: string | null
    comprovativoUrl?: string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    membership: MembershipCreateNestedOneWithoutContribuicoesInput
    user: UserCreateNestedOneWithoutContribuicoesInput
    monthlyCycle: MonthlyCycleCreateNestedOneWithoutContribuicoesInput
    coverageDecision?: CoverageDecisionCreateNestedOneWithoutContributionInput
  }

  export type ContributionUncheckedCreateInput = {
    id?: string
    membershipId: string
    userId: string
    monthlyCycleId: string
    valor: number
    dataPrevista: Date | string
    dataPagamento?: Date | string | null
    status?: string
    metodoPagamento?: string | null
    referenciaBancaria?: string | null
    comprovativoUrl?: string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    coverageDecision?: CoverageDecisionUncheckedCreateNestedOneWithoutContributionInput
  }

  export type ContributionUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    valor?: FloatFieldUpdateOperationsInput | number
    dataPrevista?: DateTimeFieldUpdateOperationsInput | Date | string
    dataPagamento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
    metodoPagamento?: NullableStringFieldUpdateOperationsInput | string | null
    referenciaBancaria?: NullableStringFieldUpdateOperationsInput | string | null
    comprovativoUrl?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    membership?: MembershipUpdateOneRequiredWithoutContribuicoesNestedInput
    user?: UserUpdateOneRequiredWithoutContribuicoesNestedInput
    monthlyCycle?: MonthlyCycleUpdateOneRequiredWithoutContribuicoesNestedInput
    coverageDecision?: CoverageDecisionUpdateOneWithoutContributionNestedInput
  }

  export type ContributionUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    membershipId?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    monthlyCycleId?: StringFieldUpdateOperationsInput | string
    valor?: FloatFieldUpdateOperationsInput | number
    dataPrevista?: DateTimeFieldUpdateOperationsInput | Date | string
    dataPagamento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
    metodoPagamento?: NullableStringFieldUpdateOperationsInput | string | null
    referenciaBancaria?: NullableStringFieldUpdateOperationsInput | string | null
    comprovativoUrl?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    coverageDecision?: CoverageDecisionUncheckedUpdateOneWithoutContributionNestedInput
  }

  export type ContributionCreateManyInput = {
    id?: string
    membershipId: string
    userId: string
    monthlyCycleId: string
    valor: number
    dataPrevista: Date | string
    dataPagamento?: Date | string | null
    status?: string
    metodoPagamento?: string | null
    referenciaBancaria?: string | null
    comprovativoUrl?: string | null
    createdAt?: Date | string
    updatedAt?: Date | string
  }

  export type ContributionUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    valor?: FloatFieldUpdateOperationsInput | number
    dataPrevista?: DateTimeFieldUpdateOperationsInput | Date | string
    dataPagamento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
    metodoPagamento?: NullableStringFieldUpdateOperationsInput | string | null
    referenciaBancaria?: NullableStringFieldUpdateOperationsInput | string | null
    comprovativoUrl?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type ContributionUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    membershipId?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    monthlyCycleId?: StringFieldUpdateOperationsInput | string
    valor?: FloatFieldUpdateOperationsInput | number
    dataPrevista?: DateTimeFieldUpdateOperationsInput | Date | string
    dataPagamento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
    metodoPagamento?: NullableStringFieldUpdateOperationsInput | string | null
    referenciaBancaria?: NullableStringFieldUpdateOperationsInput | string | null
    comprovativoUrl?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type CashoutCreateInput = {
    id?: string
    valorBruto: number
    valorTaxaPrincipal: number
    valorReservaTecnica: number
    valorLiquido: number
    dataPrevista: Date | string
    dataExecucao?: Date | string | null
    status?: string
    contaDestino?: string | null
    refTransferencia?: string | null
    parcialMotivo?: string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    monthlyCycle: MonthlyCycleCreateNestedOneWithoutCashoutInput
    beneficiarioUser: UserCreateNestedOneWithoutCashoutsInput
  }

  export type CashoutUncheckedCreateInput = {
    id?: string
    monthlyCycleId: string
    beneficiarioUserId: string
    valorBruto: number
    valorTaxaPrincipal: number
    valorReservaTecnica: number
    valorLiquido: number
    dataPrevista: Date | string
    dataExecucao?: Date | string | null
    status?: string
    contaDestino?: string | null
    refTransferencia?: string | null
    parcialMotivo?: string | null
    createdAt?: Date | string
    updatedAt?: Date | string
  }

  export type CashoutUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    valorBruto?: FloatFieldUpdateOperationsInput | number
    valorTaxaPrincipal?: FloatFieldUpdateOperationsInput | number
    valorReservaTecnica?: FloatFieldUpdateOperationsInput | number
    valorLiquido?: FloatFieldUpdateOperationsInput | number
    dataPrevista?: DateTimeFieldUpdateOperationsInput | Date | string
    dataExecucao?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
    contaDestino?: NullableStringFieldUpdateOperationsInput | string | null
    refTransferencia?: NullableStringFieldUpdateOperationsInput | string | null
    parcialMotivo?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    monthlyCycle?: MonthlyCycleUpdateOneRequiredWithoutCashoutNestedInput
    beneficiarioUser?: UserUpdateOneRequiredWithoutCashoutsNestedInput
  }

  export type CashoutUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    monthlyCycleId?: StringFieldUpdateOperationsInput | string
    beneficiarioUserId?: StringFieldUpdateOperationsInput | string
    valorBruto?: FloatFieldUpdateOperationsInput | number
    valorTaxaPrincipal?: FloatFieldUpdateOperationsInput | number
    valorReservaTecnica?: FloatFieldUpdateOperationsInput | number
    valorLiquido?: FloatFieldUpdateOperationsInput | number
    dataPrevista?: DateTimeFieldUpdateOperationsInput | Date | string
    dataExecucao?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
    contaDestino?: NullableStringFieldUpdateOperationsInput | string | null
    refTransferencia?: NullableStringFieldUpdateOperationsInput | string | null
    parcialMotivo?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type CashoutCreateManyInput = {
    id?: string
    monthlyCycleId: string
    beneficiarioUserId: string
    valorBruto: number
    valorTaxaPrincipal: number
    valorReservaTecnica: number
    valorLiquido: number
    dataPrevista: Date | string
    dataExecucao?: Date | string | null
    status?: string
    contaDestino?: string | null
    refTransferencia?: string | null
    parcialMotivo?: string | null
    createdAt?: Date | string
    updatedAt?: Date | string
  }

  export type CashoutUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    valorBruto?: FloatFieldUpdateOperationsInput | number
    valorTaxaPrincipal?: FloatFieldUpdateOperationsInput | number
    valorReservaTecnica?: FloatFieldUpdateOperationsInput | number
    valorLiquido?: FloatFieldUpdateOperationsInput | number
    dataPrevista?: DateTimeFieldUpdateOperationsInput | Date | string
    dataExecucao?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
    contaDestino?: NullableStringFieldUpdateOperationsInput | string | null
    refTransferencia?: NullableStringFieldUpdateOperationsInput | string | null
    parcialMotivo?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type CashoutUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    monthlyCycleId?: StringFieldUpdateOperationsInput | string
    beneficiarioUserId?: StringFieldUpdateOperationsInput | string
    valorBruto?: FloatFieldUpdateOperationsInput | number
    valorTaxaPrincipal?: FloatFieldUpdateOperationsInput | number
    valorReservaTecnica?: FloatFieldUpdateOperationsInput | number
    valorLiquido?: FloatFieldUpdateOperationsInput | number
    dataPrevista?: DateTimeFieldUpdateOperationsInput | Date | string
    dataExecucao?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
    contaDestino?: NullableStringFieldUpdateOperationsInput | string | null
    refTransferencia?: NullableStringFieldUpdateOperationsInput | string | null
    parcialMotivo?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type LoanCreateInput = {
    id?: string
    contributionId?: string | null
    valorCapital: number
    taxaEmprestimo: number
    valorTotalDevido: number
    jurosMoraAcumulados?: number
    dataInicio: Date | string
    dataPagamento?: Date | string | null
    status?: string
    createdAt?: Date | string
    updatedAt?: Date | string
    user: UserCreateNestedOneWithoutLoansInput
    monthlyCycle: MonthlyCycleCreateNestedOneWithoutLoansInput
  }

  export type LoanUncheckedCreateInput = {
    id?: string
    userId: string
    monthlyCycleId: string
    contributionId?: string | null
    valorCapital: number
    taxaEmprestimo: number
    valorTotalDevido: number
    jurosMoraAcumulados?: number
    dataInicio: Date | string
    dataPagamento?: Date | string | null
    status?: string
    createdAt?: Date | string
    updatedAt?: Date | string
  }

  export type LoanUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    contributionId?: NullableStringFieldUpdateOperationsInput | string | null
    valorCapital?: FloatFieldUpdateOperationsInput | number
    taxaEmprestimo?: FloatFieldUpdateOperationsInput | number
    valorTotalDevido?: FloatFieldUpdateOperationsInput | number
    jurosMoraAcumulados?: FloatFieldUpdateOperationsInput | number
    dataInicio?: DateTimeFieldUpdateOperationsInput | Date | string
    dataPagamento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    user?: UserUpdateOneRequiredWithoutLoansNestedInput
    monthlyCycle?: MonthlyCycleUpdateOneRequiredWithoutLoansNestedInput
  }

  export type LoanUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    monthlyCycleId?: StringFieldUpdateOperationsInput | string
    contributionId?: NullableStringFieldUpdateOperationsInput | string | null
    valorCapital?: FloatFieldUpdateOperationsInput | number
    taxaEmprestimo?: FloatFieldUpdateOperationsInput | number
    valorTotalDevido?: FloatFieldUpdateOperationsInput | number
    jurosMoraAcumulados?: FloatFieldUpdateOperationsInput | number
    dataInicio?: DateTimeFieldUpdateOperationsInput | Date | string
    dataPagamento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type LoanCreateManyInput = {
    id?: string
    userId: string
    monthlyCycleId: string
    contributionId?: string | null
    valorCapital: number
    taxaEmprestimo: number
    valorTotalDevido: number
    jurosMoraAcumulados?: number
    dataInicio: Date | string
    dataPagamento?: Date | string | null
    status?: string
    createdAt?: Date | string
    updatedAt?: Date | string
  }

  export type LoanUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    contributionId?: NullableStringFieldUpdateOperationsInput | string | null
    valorCapital?: FloatFieldUpdateOperationsInput | number
    taxaEmprestimo?: FloatFieldUpdateOperationsInput | number
    valorTotalDevido?: FloatFieldUpdateOperationsInput | number
    jurosMoraAcumulados?: FloatFieldUpdateOperationsInput | number
    dataInicio?: DateTimeFieldUpdateOperationsInput | Date | string
    dataPagamento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type LoanUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    monthlyCycleId?: StringFieldUpdateOperationsInput | string
    contributionId?: NullableStringFieldUpdateOperationsInput | string | null
    valorCapital?: FloatFieldUpdateOperationsInput | number
    taxaEmprestimo?: FloatFieldUpdateOperationsInput | number
    valorTotalDevido?: FloatFieldUpdateOperationsInput | number
    jurosMoraAcumulados?: FloatFieldUpdateOperationsInput | number
    dataInicio?: DateTimeFieldUpdateOperationsInput | Date | string
    dataPagamento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type CoverageDecisionCreateInput = {
    id?: string
    decisao: string
    motivo: string
    scoreNoMomento: number
    historicoInadimplencias: number
    decisorSistema?: boolean
    createdAt?: Date | string
    contribution: ContributionCreateNestedOneWithoutCoverageDecisionInput
    decisorUser?: UserCreateNestedOneWithoutCoverageDecisionsInput
  }

  export type CoverageDecisionUncheckedCreateInput = {
    id?: string
    contributionId: string
    decisao: string
    motivo: string
    scoreNoMomento: number
    historicoInadimplencias: number
    decisorUserId?: string | null
    decisorSistema?: boolean
    createdAt?: Date | string
  }

  export type CoverageDecisionUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    decisao?: StringFieldUpdateOperationsInput | string
    motivo?: StringFieldUpdateOperationsInput | string
    scoreNoMomento?: IntFieldUpdateOperationsInput | number
    historicoInadimplencias?: IntFieldUpdateOperationsInput | number
    decisorSistema?: BoolFieldUpdateOperationsInput | boolean
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    contribution?: ContributionUpdateOneRequiredWithoutCoverageDecisionNestedInput
    decisorUser?: UserUpdateOneWithoutCoverageDecisionsNestedInput
  }

  export type CoverageDecisionUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    contributionId?: StringFieldUpdateOperationsInput | string
    decisao?: StringFieldUpdateOperationsInput | string
    motivo?: StringFieldUpdateOperationsInput | string
    scoreNoMomento?: IntFieldUpdateOperationsInput | number
    historicoInadimplencias?: IntFieldUpdateOperationsInput | number
    decisorUserId?: NullableStringFieldUpdateOperationsInput | string | null
    decisorSistema?: BoolFieldUpdateOperationsInput | boolean
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type CoverageDecisionCreateManyInput = {
    id?: string
    contributionId: string
    decisao: string
    motivo: string
    scoreNoMomento: number
    historicoInadimplencias: number
    decisorUserId?: string | null
    decisorSistema?: boolean
    createdAt?: Date | string
  }

  export type CoverageDecisionUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    decisao?: StringFieldUpdateOperationsInput | string
    motivo?: StringFieldUpdateOperationsInput | string
    scoreNoMomento?: IntFieldUpdateOperationsInput | number
    historicoInadimplencias?: IntFieldUpdateOperationsInput | number
    decisorSistema?: BoolFieldUpdateOperationsInput | boolean
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type CoverageDecisionUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    contributionId?: StringFieldUpdateOperationsInput | string
    decisao?: StringFieldUpdateOperationsInput | string
    motivo?: StringFieldUpdateOperationsInput | string
    scoreNoMomento?: IntFieldUpdateOperationsInput | number
    historicoInadimplencias?: IntFieldUpdateOperationsInput | number
    decisorUserId?: NullableStringFieldUpdateOperationsInput | string | null
    decisorSistema?: BoolFieldUpdateOperationsInput | boolean
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type ReintegrationCreateInput = {
    id?: string
    valorDividaOriginal: number
    taxaReintegracaoAplicada: number
    valorTaxaPaga: number
    dataSolicitacao?: Date | string
    dataConclusao?: Date | string | null
    status?: string
    user: UserCreateNestedOneWithoutReintegrationsInput
  }

  export type ReintegrationUncheckedCreateInput = {
    id?: string
    userId: string
    valorDividaOriginal: number
    taxaReintegracaoAplicada: number
    valorTaxaPaga: number
    dataSolicitacao?: Date | string
    dataConclusao?: Date | string | null
    status?: string
  }

  export type ReintegrationUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    valorDividaOriginal?: FloatFieldUpdateOperationsInput | number
    taxaReintegracaoAplicada?: FloatFieldUpdateOperationsInput | number
    valorTaxaPaga?: FloatFieldUpdateOperationsInput | number
    dataSolicitacao?: DateTimeFieldUpdateOperationsInput | Date | string
    dataConclusao?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
    user?: UserUpdateOneRequiredWithoutReintegrationsNestedInput
  }

  export type ReintegrationUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    valorDividaOriginal?: FloatFieldUpdateOperationsInput | number
    taxaReintegracaoAplicada?: FloatFieldUpdateOperationsInput | number
    valorTaxaPaga?: FloatFieldUpdateOperationsInput | number
    dataSolicitacao?: DateTimeFieldUpdateOperationsInput | Date | string
    dataConclusao?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
  }

  export type ReintegrationCreateManyInput = {
    id?: string
    userId: string
    valorDividaOriginal: number
    taxaReintegracaoAplicada: number
    valorTaxaPaga: number
    dataSolicitacao?: Date | string
    dataConclusao?: Date | string | null
    status?: string
  }

  export type ReintegrationUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    valorDividaOriginal?: FloatFieldUpdateOperationsInput | number
    taxaReintegracaoAplicada?: FloatFieldUpdateOperationsInput | number
    valorTaxaPaga?: FloatFieldUpdateOperationsInput | number
    dataSolicitacao?: DateTimeFieldUpdateOperationsInput | Date | string
    dataConclusao?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
  }

  export type ReintegrationUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    valorDividaOriginal?: FloatFieldUpdateOperationsInput | number
    taxaReintegracaoAplicada?: FloatFieldUpdateOperationsInput | number
    valorTaxaPaga?: FloatFieldUpdateOperationsInput | number
    dataSolicitacao?: DateTimeFieldUpdateOperationsInput | Date | string
    dataConclusao?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
  }

  export type FeeConfigurationCreateInput = {
    id?: string
    tipoFee: string
    valor: number
    min: number
    max: number
    dataInicio: Date | string
    dataFim?: Date | string | null
    motivoMudanca?: string | null
    ativa?: boolean
    createdAt?: Date | string
    criadoPor?: UserCreateNestedOneWithoutFeeConfigsCriadasInput
  }

  export type FeeConfigurationUncheckedCreateInput = {
    id?: string
    tipoFee: string
    valor: number
    min: number
    max: number
    dataInicio: Date | string
    dataFim?: Date | string | null
    criadoPorId?: string | null
    motivoMudanca?: string | null
    ativa?: boolean
    createdAt?: Date | string
  }

  export type FeeConfigurationUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    tipoFee?: StringFieldUpdateOperationsInput | string
    valor?: FloatFieldUpdateOperationsInput | number
    min?: FloatFieldUpdateOperationsInput | number
    max?: FloatFieldUpdateOperationsInput | number
    dataInicio?: DateTimeFieldUpdateOperationsInput | Date | string
    dataFim?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    motivoMudanca?: NullableStringFieldUpdateOperationsInput | string | null
    ativa?: BoolFieldUpdateOperationsInput | boolean
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    criadoPor?: UserUpdateOneWithoutFeeConfigsCriadasNestedInput
  }

  export type FeeConfigurationUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    tipoFee?: StringFieldUpdateOperationsInput | string
    valor?: FloatFieldUpdateOperationsInput | number
    min?: FloatFieldUpdateOperationsInput | number
    max?: FloatFieldUpdateOperationsInput | number
    dataInicio?: DateTimeFieldUpdateOperationsInput | Date | string
    dataFim?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    criadoPorId?: NullableStringFieldUpdateOperationsInput | string | null
    motivoMudanca?: NullableStringFieldUpdateOperationsInput | string | null
    ativa?: BoolFieldUpdateOperationsInput | boolean
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type FeeConfigurationCreateManyInput = {
    id?: string
    tipoFee: string
    valor: number
    min: number
    max: number
    dataInicio: Date | string
    dataFim?: Date | string | null
    criadoPorId?: string | null
    motivoMudanca?: string | null
    ativa?: boolean
    createdAt?: Date | string
  }

  export type FeeConfigurationUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    tipoFee?: StringFieldUpdateOperationsInput | string
    valor?: FloatFieldUpdateOperationsInput | number
    min?: FloatFieldUpdateOperationsInput | number
    max?: FloatFieldUpdateOperationsInput | number
    dataInicio?: DateTimeFieldUpdateOperationsInput | Date | string
    dataFim?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    motivoMudanca?: NullableStringFieldUpdateOperationsInput | string | null
    ativa?: BoolFieldUpdateOperationsInput | boolean
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type FeeConfigurationUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    tipoFee?: StringFieldUpdateOperationsInput | string
    valor?: FloatFieldUpdateOperationsInput | number
    min?: FloatFieldUpdateOperationsInput | number
    max?: FloatFieldUpdateOperationsInput | number
    dataInicio?: DateTimeFieldUpdateOperationsInput | Date | string
    dataFim?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    criadoPorId?: NullableStringFieldUpdateOperationsInput | string | null
    motivoMudanca?: NullableStringFieldUpdateOperationsInput | string | null
    ativa?: BoolFieldUpdateOperationsInput | boolean
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type CoverageFundCreateInput = {
    id?: string
    saldoDisponivel?: number
    saldoEmEmprestimosActivos?: number
    totalRecuperadoAno?: number
    totalPerdidoAno?: number
    lastUpdated?: Date | string
  }

  export type CoverageFundUncheckedCreateInput = {
    id?: string
    saldoDisponivel?: number
    saldoEmEmprestimosActivos?: number
    totalRecuperadoAno?: number
    totalPerdidoAno?: number
    lastUpdated?: Date | string
  }

  export type CoverageFundUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    saldoDisponivel?: FloatFieldUpdateOperationsInput | number
    saldoEmEmprestimosActivos?: FloatFieldUpdateOperationsInput | number
    totalRecuperadoAno?: FloatFieldUpdateOperationsInput | number
    totalPerdidoAno?: FloatFieldUpdateOperationsInput | number
    lastUpdated?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type CoverageFundUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    saldoDisponivel?: FloatFieldUpdateOperationsInput | number
    saldoEmEmprestimosActivos?: FloatFieldUpdateOperationsInput | number
    totalRecuperadoAno?: FloatFieldUpdateOperationsInput | number
    totalPerdidoAno?: FloatFieldUpdateOperationsInput | number
    lastUpdated?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type CoverageFundCreateManyInput = {
    id?: string
    saldoDisponivel?: number
    saldoEmEmprestimosActivos?: number
    totalRecuperadoAno?: number
    totalPerdidoAno?: number
    lastUpdated?: Date | string
  }

  export type CoverageFundUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    saldoDisponivel?: FloatFieldUpdateOperationsInput | number
    saldoEmEmprestimosActivos?: FloatFieldUpdateOperationsInput | number
    totalRecuperadoAno?: FloatFieldUpdateOperationsInput | number
    totalPerdidoAno?: FloatFieldUpdateOperationsInput | number
    lastUpdated?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type CoverageFundUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    saldoDisponivel?: FloatFieldUpdateOperationsInput | number
    saldoEmEmprestimosActivos?: FloatFieldUpdateOperationsInput | number
    totalRecuperadoAno?: FloatFieldUpdateOperationsInput | number
    totalPerdidoAno?: FloatFieldUpdateOperationsInput | number
    lastUpdated?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type TransactionCreateInput = {
    id?: string
    tipo: string
    valor: number
    fromAccount: string
    toAccount: string
    referencia?: string | null
    status?: string
    timestamp?: Date | string
    auditJson?: string | null
  }

  export type TransactionUncheckedCreateInput = {
    id?: string
    tipo: string
    valor: number
    fromAccount: string
    toAccount: string
    referencia?: string | null
    status?: string
    timestamp?: Date | string
    auditJson?: string | null
  }

  export type TransactionUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    valor?: FloatFieldUpdateOperationsInput | number
    fromAccount?: StringFieldUpdateOperationsInput | string
    toAccount?: StringFieldUpdateOperationsInput | string
    referencia?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
    auditJson?: NullableStringFieldUpdateOperationsInput | string | null
  }

  export type TransactionUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    valor?: FloatFieldUpdateOperationsInput | number
    fromAccount?: StringFieldUpdateOperationsInput | string
    toAccount?: StringFieldUpdateOperationsInput | string
    referencia?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
    auditJson?: NullableStringFieldUpdateOperationsInput | string | null
  }

  export type TransactionCreateManyInput = {
    id?: string
    tipo: string
    valor: number
    fromAccount: string
    toAccount: string
    referencia?: string | null
    status?: string
    timestamp?: Date | string
    auditJson?: string | null
  }

  export type TransactionUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    valor?: FloatFieldUpdateOperationsInput | number
    fromAccount?: StringFieldUpdateOperationsInput | string
    toAccount?: StringFieldUpdateOperationsInput | string
    referencia?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
    auditJson?: NullableStringFieldUpdateOperationsInput | string | null
  }

  export type TransactionUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    valor?: FloatFieldUpdateOperationsInput | number
    fromAccount?: StringFieldUpdateOperationsInput | string
    toAccount?: StringFieldUpdateOperationsInput | string
    referencia?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
    auditJson?: NullableStringFieldUpdateOperationsInput | string | null
  }

  export type ScoreEventCreateInput = {
    id?: string
    tipoEvento: string
    impacto: number
    descricao?: string | null
    scoreAntes: number
    scoreDepois: number
    timestamp?: Date | string
    user: UserCreateNestedOneWithoutScoreEventsInput
  }

  export type ScoreEventUncheckedCreateInput = {
    id?: string
    userId: string
    tipoEvento: string
    impacto: number
    descricao?: string | null
    scoreAntes: number
    scoreDepois: number
    timestamp?: Date | string
  }

  export type ScoreEventUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    tipoEvento?: StringFieldUpdateOperationsInput | string
    impacto?: IntFieldUpdateOperationsInput | number
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    scoreAntes?: IntFieldUpdateOperationsInput | number
    scoreDepois?: IntFieldUpdateOperationsInput | number
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
    user?: UserUpdateOneRequiredWithoutScoreEventsNestedInput
  }

  export type ScoreEventUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    tipoEvento?: StringFieldUpdateOperationsInput | string
    impacto?: IntFieldUpdateOperationsInput | number
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    scoreAntes?: IntFieldUpdateOperationsInput | number
    scoreDepois?: IntFieldUpdateOperationsInput | number
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type ScoreEventCreateManyInput = {
    id?: string
    userId: string
    tipoEvento: string
    impacto: number
    descricao?: string | null
    scoreAntes: number
    scoreDepois: number
    timestamp?: Date | string
  }

  export type ScoreEventUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    tipoEvento?: StringFieldUpdateOperationsInput | string
    impacto?: IntFieldUpdateOperationsInput | number
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    scoreAntes?: IntFieldUpdateOperationsInput | number
    scoreDepois?: IntFieldUpdateOperationsInput | number
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type ScoreEventUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    tipoEvento?: StringFieldUpdateOperationsInput | string
    impacto?: IntFieldUpdateOperationsInput | number
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    scoreAntes?: IntFieldUpdateOperationsInput | number
    scoreDepois?: IntFieldUpdateOperationsInput | number
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type NotificationCreateInput = {
    id?: string
    canal: string
    titulo: string
    corpo: string
    lida?: boolean
    metadataJson?: string | null
    createdAt?: Date | string
    user: UserCreateNestedOneWithoutNotificationsInput
  }

  export type NotificationUncheckedCreateInput = {
    id?: string
    userId: string
    canal: string
    titulo: string
    corpo: string
    lida?: boolean
    metadataJson?: string | null
    createdAt?: Date | string
  }

  export type NotificationUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    canal?: StringFieldUpdateOperationsInput | string
    titulo?: StringFieldUpdateOperationsInput | string
    corpo?: StringFieldUpdateOperationsInput | string
    lida?: BoolFieldUpdateOperationsInput | boolean
    metadataJson?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    user?: UserUpdateOneRequiredWithoutNotificationsNestedInput
  }

  export type NotificationUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    canal?: StringFieldUpdateOperationsInput | string
    titulo?: StringFieldUpdateOperationsInput | string
    corpo?: StringFieldUpdateOperationsInput | string
    lida?: BoolFieldUpdateOperationsInput | boolean
    metadataJson?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type NotificationCreateManyInput = {
    id?: string
    userId: string
    canal: string
    titulo: string
    corpo: string
    lida?: boolean
    metadataJson?: string | null
    createdAt?: Date | string
  }

  export type NotificationUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    canal?: StringFieldUpdateOperationsInput | string
    titulo?: StringFieldUpdateOperationsInput | string
    corpo?: StringFieldUpdateOperationsInput | string
    lida?: BoolFieldUpdateOperationsInput | boolean
    metadataJson?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type NotificationUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    canal?: StringFieldUpdateOperationsInput | string
    titulo?: StringFieldUpdateOperationsInput | string
    corpo?: StringFieldUpdateOperationsInput | string
    lida?: BoolFieldUpdateOperationsInput | boolean
    metadataJson?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type AuditLogCreateInput = {
    id?: string
    acao: string
    entidade: string
    entidadeId?: string | null
    dadosAntes?: string | null
    dadosDepois?: string | null
    ip?: string | null
    timestamp?: Date | string
    user?: UserCreateNestedOneWithoutAuditLogsInput
  }

  export type AuditLogUncheckedCreateInput = {
    id?: string
    userId?: string | null
    acao: string
    entidade: string
    entidadeId?: string | null
    dadosAntes?: string | null
    dadosDepois?: string | null
    ip?: string | null
    timestamp?: Date | string
  }

  export type AuditLogUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    acao?: StringFieldUpdateOperationsInput | string
    entidade?: StringFieldUpdateOperationsInput | string
    entidadeId?: NullableStringFieldUpdateOperationsInput | string | null
    dadosAntes?: NullableStringFieldUpdateOperationsInput | string | null
    dadosDepois?: NullableStringFieldUpdateOperationsInput | string | null
    ip?: NullableStringFieldUpdateOperationsInput | string | null
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
    user?: UserUpdateOneWithoutAuditLogsNestedInput
  }

  export type AuditLogUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: NullableStringFieldUpdateOperationsInput | string | null
    acao?: StringFieldUpdateOperationsInput | string
    entidade?: StringFieldUpdateOperationsInput | string
    entidadeId?: NullableStringFieldUpdateOperationsInput | string | null
    dadosAntes?: NullableStringFieldUpdateOperationsInput | string | null
    dadosDepois?: NullableStringFieldUpdateOperationsInput | string | null
    ip?: NullableStringFieldUpdateOperationsInput | string | null
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type AuditLogCreateManyInput = {
    id?: string
    userId?: string | null
    acao: string
    entidade: string
    entidadeId?: string | null
    dadosAntes?: string | null
    dadosDepois?: string | null
    ip?: string | null
    timestamp?: Date | string
  }

  export type AuditLogUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    acao?: StringFieldUpdateOperationsInput | string
    entidade?: StringFieldUpdateOperationsInput | string
    entidadeId?: NullableStringFieldUpdateOperationsInput | string | null
    dadosAntes?: NullableStringFieldUpdateOperationsInput | string | null
    dadosDepois?: NullableStringFieldUpdateOperationsInput | string | null
    ip?: NullableStringFieldUpdateOperationsInput | string | null
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type AuditLogUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: NullableStringFieldUpdateOperationsInput | string | null
    acao?: StringFieldUpdateOperationsInput | string
    entidade?: StringFieldUpdateOperationsInput | string
    entidadeId?: NullableStringFieldUpdateOperationsInput | string | null
    dadosAntes?: NullableStringFieldUpdateOperationsInput | string | null
    dadosDepois?: NullableStringFieldUpdateOperationsInput | string | null
    ip?: NullableStringFieldUpdateOperationsInput | string | null
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type SystemClockCreateInput = {
    id?: number
    agora?: Date | string
    updatedAt?: Date | string
  }

  export type SystemClockUncheckedCreateInput = {
    id?: number
    agora?: Date | string
    updatedAt?: Date | string
  }

  export type SystemClockUpdateInput = {
    id?: IntFieldUpdateOperationsInput | number
    agora?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type SystemClockUncheckedUpdateInput = {
    id?: IntFieldUpdateOperationsInput | number
    agora?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type SystemClockCreateManyInput = {
    id?: number
    agora?: Date | string
    updatedAt?: Date | string
  }

  export type SystemClockUpdateManyMutationInput = {
    id?: IntFieldUpdateOperationsInput | number
    agora?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type SystemClockUncheckedUpdateManyInput = {
    id?: IntFieldUpdateOperationsInput | number
    agora?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type CreditApplicationCreateInput = {
    id?: string
    valorSolicitado: number
    prazoMeses: number
    taxaJuroAplicada: number
    prestacaoMensal: number
    finalidade?: string | null
    status?: string
    scoreNoMomento: number
    motivoDecisao?: string | null
    decisaoPorId?: string | null
    dataAprovacao?: Date | string | null
    dataDesembolso?: Date | string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    user: UserCreateNestedOneWithoutCreditApplicationsInput
    prestacoes?: CreditInstallmentCreateNestedManyWithoutApplicationInput
  }

  export type CreditApplicationUncheckedCreateInput = {
    id?: string
    userId: string
    valorSolicitado: number
    prazoMeses: number
    taxaJuroAplicada: number
    prestacaoMensal: number
    finalidade?: string | null
    status?: string
    scoreNoMomento: number
    motivoDecisao?: string | null
    decisaoPorId?: string | null
    dataAprovacao?: Date | string | null
    dataDesembolso?: Date | string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    prestacoes?: CreditInstallmentUncheckedCreateNestedManyWithoutApplicationInput
  }

  export type CreditApplicationUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    valorSolicitado?: FloatFieldUpdateOperationsInput | number
    prazoMeses?: IntFieldUpdateOperationsInput | number
    taxaJuroAplicada?: FloatFieldUpdateOperationsInput | number
    prestacaoMensal?: FloatFieldUpdateOperationsInput | number
    finalidade?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreNoMomento?: IntFieldUpdateOperationsInput | number
    motivoDecisao?: NullableStringFieldUpdateOperationsInput | string | null
    decisaoPorId?: NullableStringFieldUpdateOperationsInput | string | null
    dataAprovacao?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    dataDesembolso?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    user?: UserUpdateOneRequiredWithoutCreditApplicationsNestedInput
    prestacoes?: CreditInstallmentUpdateManyWithoutApplicationNestedInput
  }

  export type CreditApplicationUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    valorSolicitado?: FloatFieldUpdateOperationsInput | number
    prazoMeses?: IntFieldUpdateOperationsInput | number
    taxaJuroAplicada?: FloatFieldUpdateOperationsInput | number
    prestacaoMensal?: FloatFieldUpdateOperationsInput | number
    finalidade?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreNoMomento?: IntFieldUpdateOperationsInput | number
    motivoDecisao?: NullableStringFieldUpdateOperationsInput | string | null
    decisaoPorId?: NullableStringFieldUpdateOperationsInput | string | null
    dataAprovacao?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    dataDesembolso?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    prestacoes?: CreditInstallmentUncheckedUpdateManyWithoutApplicationNestedInput
  }

  export type CreditApplicationCreateManyInput = {
    id?: string
    userId: string
    valorSolicitado: number
    prazoMeses: number
    taxaJuroAplicada: number
    prestacaoMensal: number
    finalidade?: string | null
    status?: string
    scoreNoMomento: number
    motivoDecisao?: string | null
    decisaoPorId?: string | null
    dataAprovacao?: Date | string | null
    dataDesembolso?: Date | string | null
    createdAt?: Date | string
    updatedAt?: Date | string
  }

  export type CreditApplicationUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    valorSolicitado?: FloatFieldUpdateOperationsInput | number
    prazoMeses?: IntFieldUpdateOperationsInput | number
    taxaJuroAplicada?: FloatFieldUpdateOperationsInput | number
    prestacaoMensal?: FloatFieldUpdateOperationsInput | number
    finalidade?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreNoMomento?: IntFieldUpdateOperationsInput | number
    motivoDecisao?: NullableStringFieldUpdateOperationsInput | string | null
    decisaoPorId?: NullableStringFieldUpdateOperationsInput | string | null
    dataAprovacao?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    dataDesembolso?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type CreditApplicationUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    valorSolicitado?: FloatFieldUpdateOperationsInput | number
    prazoMeses?: IntFieldUpdateOperationsInput | number
    taxaJuroAplicada?: FloatFieldUpdateOperationsInput | number
    prestacaoMensal?: FloatFieldUpdateOperationsInput | number
    finalidade?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreNoMomento?: IntFieldUpdateOperationsInput | number
    motivoDecisao?: NullableStringFieldUpdateOperationsInput | string | null
    decisaoPorId?: NullableStringFieldUpdateOperationsInput | string | null
    dataAprovacao?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    dataDesembolso?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type CreditInstallmentCreateInput = {
    id?: string
    numero: number
    valorCapital: number
    valorJuros: number
    valorTotal: number
    dataVencimento: Date | string
    dataPagamento?: Date | string | null
    status?: string
    application: CreditApplicationCreateNestedOneWithoutPrestacoesInput
  }

  export type CreditInstallmentUncheckedCreateInput = {
    id?: string
    applicationId: string
    numero: number
    valorCapital: number
    valorJuros: number
    valorTotal: number
    dataVencimento: Date | string
    dataPagamento?: Date | string | null
    status?: string
  }

  export type CreditInstallmentUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    numero?: IntFieldUpdateOperationsInput | number
    valorCapital?: FloatFieldUpdateOperationsInput | number
    valorJuros?: FloatFieldUpdateOperationsInput | number
    valorTotal?: FloatFieldUpdateOperationsInput | number
    dataVencimento?: DateTimeFieldUpdateOperationsInput | Date | string
    dataPagamento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
    application?: CreditApplicationUpdateOneRequiredWithoutPrestacoesNestedInput
  }

  export type CreditInstallmentUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    applicationId?: StringFieldUpdateOperationsInput | string
    numero?: IntFieldUpdateOperationsInput | number
    valorCapital?: FloatFieldUpdateOperationsInput | number
    valorJuros?: FloatFieldUpdateOperationsInput | number
    valorTotal?: FloatFieldUpdateOperationsInput | number
    dataVencimento?: DateTimeFieldUpdateOperationsInput | Date | string
    dataPagamento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
  }

  export type CreditInstallmentCreateManyInput = {
    id?: string
    applicationId: string
    numero: number
    valorCapital: number
    valorJuros: number
    valorTotal: number
    dataVencimento: Date | string
    dataPagamento?: Date | string | null
    status?: string
  }

  export type CreditInstallmentUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    numero?: IntFieldUpdateOperationsInput | number
    valorCapital?: FloatFieldUpdateOperationsInput | number
    valorJuros?: FloatFieldUpdateOperationsInput | number
    valorTotal?: FloatFieldUpdateOperationsInput | number
    dataVencimento?: DateTimeFieldUpdateOperationsInput | Date | string
    dataPagamento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
  }

  export type CreditInstallmentUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    applicationId?: StringFieldUpdateOperationsInput | string
    numero?: IntFieldUpdateOperationsInput | number
    valorCapital?: FloatFieldUpdateOperationsInput | number
    valorJuros?: FloatFieldUpdateOperationsInput | number
    valorTotal?: FloatFieldUpdateOperationsInput | number
    dataVencimento?: DateTimeFieldUpdateOperationsInput | Date | string
    dataPagamento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
  }

  export type SavingsAccountCreateInput = {
    id?: string
    nome: string
    objectivo?: string | null
    meta?: number | null
    saldo?: number
    taxaRemuneracaoAnual?: number
    imobilizacaoMeses?: number
    status?: string
    ultimaCapitalizacao?: Date | string
    createdAt?: Date | string
    updatedAt?: Date | string
    user: UserCreateNestedOneWithoutSavingsAccountsInput
    movimentos?: SavingsMovementCreateNestedManyWithoutAccountInput
  }

  export type SavingsAccountUncheckedCreateInput = {
    id?: string
    userId: string
    nome: string
    objectivo?: string | null
    meta?: number | null
    saldo?: number
    taxaRemuneracaoAnual?: number
    imobilizacaoMeses?: number
    status?: string
    ultimaCapitalizacao?: Date | string
    createdAt?: Date | string
    updatedAt?: Date | string
    movimentos?: SavingsMovementUncheckedCreateNestedManyWithoutAccountInput
  }

  export type SavingsAccountUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    objectivo?: NullableStringFieldUpdateOperationsInput | string | null
    meta?: NullableFloatFieldUpdateOperationsInput | number | null
    saldo?: FloatFieldUpdateOperationsInput | number
    taxaRemuneracaoAnual?: FloatFieldUpdateOperationsInput | number
    imobilizacaoMeses?: IntFieldUpdateOperationsInput | number
    status?: StringFieldUpdateOperationsInput | string
    ultimaCapitalizacao?: DateTimeFieldUpdateOperationsInput | Date | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    user?: UserUpdateOneRequiredWithoutSavingsAccountsNestedInput
    movimentos?: SavingsMovementUpdateManyWithoutAccountNestedInput
  }

  export type SavingsAccountUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    objectivo?: NullableStringFieldUpdateOperationsInput | string | null
    meta?: NullableFloatFieldUpdateOperationsInput | number | null
    saldo?: FloatFieldUpdateOperationsInput | number
    taxaRemuneracaoAnual?: FloatFieldUpdateOperationsInput | number
    imobilizacaoMeses?: IntFieldUpdateOperationsInput | number
    status?: StringFieldUpdateOperationsInput | string
    ultimaCapitalizacao?: DateTimeFieldUpdateOperationsInput | Date | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    movimentos?: SavingsMovementUncheckedUpdateManyWithoutAccountNestedInput
  }

  export type SavingsAccountCreateManyInput = {
    id?: string
    userId: string
    nome: string
    objectivo?: string | null
    meta?: number | null
    saldo?: number
    taxaRemuneracaoAnual?: number
    imobilizacaoMeses?: number
    status?: string
    ultimaCapitalizacao?: Date | string
    createdAt?: Date | string
    updatedAt?: Date | string
  }

  export type SavingsAccountUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    objectivo?: NullableStringFieldUpdateOperationsInput | string | null
    meta?: NullableFloatFieldUpdateOperationsInput | number | null
    saldo?: FloatFieldUpdateOperationsInput | number
    taxaRemuneracaoAnual?: FloatFieldUpdateOperationsInput | number
    imobilizacaoMeses?: IntFieldUpdateOperationsInput | number
    status?: StringFieldUpdateOperationsInput | string
    ultimaCapitalizacao?: DateTimeFieldUpdateOperationsInput | Date | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type SavingsAccountUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    objectivo?: NullableStringFieldUpdateOperationsInput | string | null
    meta?: NullableFloatFieldUpdateOperationsInput | number | null
    saldo?: FloatFieldUpdateOperationsInput | number
    taxaRemuneracaoAnual?: FloatFieldUpdateOperationsInput | number
    imobilizacaoMeses?: IntFieldUpdateOperationsInput | number
    status?: StringFieldUpdateOperationsInput | string
    ultimaCapitalizacao?: DateTimeFieldUpdateOperationsInput | Date | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type SavingsMovementCreateInput = {
    id?: string
    tipo: string
    valor: number
    saldoApos: number
    descricao?: string | null
    createdAt?: Date | string
    account: SavingsAccountCreateNestedOneWithoutMovimentosInput
  }

  export type SavingsMovementUncheckedCreateInput = {
    id?: string
    accountId: string
    tipo: string
    valor: number
    saldoApos: number
    descricao?: string | null
    createdAt?: Date | string
  }

  export type SavingsMovementUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    valor?: FloatFieldUpdateOperationsInput | number
    saldoApos?: FloatFieldUpdateOperationsInput | number
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    account?: SavingsAccountUpdateOneRequiredWithoutMovimentosNestedInput
  }

  export type SavingsMovementUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    accountId?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    valor?: FloatFieldUpdateOperationsInput | number
    saldoApos?: FloatFieldUpdateOperationsInput | number
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type SavingsMovementCreateManyInput = {
    id?: string
    accountId: string
    tipo: string
    valor: number
    saldoApos: number
    descricao?: string | null
    createdAt?: Date | string
  }

  export type SavingsMovementUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    valor?: FloatFieldUpdateOperationsInput | number
    saldoApos?: FloatFieldUpdateOperationsInput | number
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type SavingsMovementUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    accountId?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    valor?: FloatFieldUpdateOperationsInput | number
    saldoApos?: FloatFieldUpdateOperationsInput | number
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type ReferralCreateInput = {
    id?: string
    codigo: string
    canal?: string | null
    status?: string
    recompensa?: number
    recompensaPaga?: boolean
    dataRegisto?: Date | string | null
    dataActivacao?: Date | string | null
    createdAt?: Date | string
    referrer: UserCreateNestedOneWithoutReferralsCreatedInput
    referredUser?: UserCreateNestedOneWithoutReferralAsReferredInput
  }

  export type ReferralUncheckedCreateInput = {
    id?: string
    referrerUserId: string
    referredUserId?: string | null
    codigo: string
    canal?: string | null
    status?: string
    recompensa?: number
    recompensaPaga?: boolean
    dataRegisto?: Date | string | null
    dataActivacao?: Date | string | null
    createdAt?: Date | string
  }

  export type ReferralUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    codigo?: StringFieldUpdateOperationsInput | string
    canal?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    recompensa?: FloatFieldUpdateOperationsInput | number
    recompensaPaga?: BoolFieldUpdateOperationsInput | boolean
    dataRegisto?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    dataActivacao?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referrer?: UserUpdateOneRequiredWithoutReferralsCreatedNestedInput
    referredUser?: UserUpdateOneWithoutReferralAsReferredNestedInput
  }

  export type ReferralUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    referrerUserId?: StringFieldUpdateOperationsInput | string
    referredUserId?: NullableStringFieldUpdateOperationsInput | string | null
    codigo?: StringFieldUpdateOperationsInput | string
    canal?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    recompensa?: FloatFieldUpdateOperationsInput | number
    recompensaPaga?: BoolFieldUpdateOperationsInput | boolean
    dataRegisto?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    dataActivacao?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type ReferralCreateManyInput = {
    id?: string
    referrerUserId: string
    referredUserId?: string | null
    codigo: string
    canal?: string | null
    status?: string
    recompensa?: number
    recompensaPaga?: boolean
    dataRegisto?: Date | string | null
    dataActivacao?: Date | string | null
    createdAt?: Date | string
  }

  export type ReferralUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    codigo?: StringFieldUpdateOperationsInput | string
    canal?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    recompensa?: FloatFieldUpdateOperationsInput | number
    recompensaPaga?: BoolFieldUpdateOperationsInput | boolean
    dataRegisto?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    dataActivacao?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type ReferralUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    referrerUserId?: StringFieldUpdateOperationsInput | string
    referredUserId?: NullableStringFieldUpdateOperationsInput | string | null
    codigo?: StringFieldUpdateOperationsInput | string
    canal?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    recompensa?: FloatFieldUpdateOperationsInput | number
    recompensaPaga?: BoolFieldUpdateOperationsInput | boolean
    dataRegisto?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    dataActivacao?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type ContentArticleCreateInput = {
    id?: string
    slug: string
    titulo: string
    resumo: string
    corpo: string
    categoria: string
    autor?: string
    duracaoLeituraMin?: number
    publicado?: boolean
    ordem?: number
    createdAt?: Date | string
  }

  export type ContentArticleUncheckedCreateInput = {
    id?: string
    slug: string
    titulo: string
    resumo: string
    corpo: string
    categoria: string
    autor?: string
    duracaoLeituraMin?: number
    publicado?: boolean
    ordem?: number
    createdAt?: Date | string
  }

  export type ContentArticleUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    slug?: StringFieldUpdateOperationsInput | string
    titulo?: StringFieldUpdateOperationsInput | string
    resumo?: StringFieldUpdateOperationsInput | string
    corpo?: StringFieldUpdateOperationsInput | string
    categoria?: StringFieldUpdateOperationsInput | string
    autor?: StringFieldUpdateOperationsInput | string
    duracaoLeituraMin?: IntFieldUpdateOperationsInput | number
    publicado?: BoolFieldUpdateOperationsInput | boolean
    ordem?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type ContentArticleUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    slug?: StringFieldUpdateOperationsInput | string
    titulo?: StringFieldUpdateOperationsInput | string
    resumo?: StringFieldUpdateOperationsInput | string
    corpo?: StringFieldUpdateOperationsInput | string
    categoria?: StringFieldUpdateOperationsInput | string
    autor?: StringFieldUpdateOperationsInput | string
    duracaoLeituraMin?: IntFieldUpdateOperationsInput | number
    publicado?: BoolFieldUpdateOperationsInput | boolean
    ordem?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type ContentArticleCreateManyInput = {
    id?: string
    slug: string
    titulo: string
    resumo: string
    corpo: string
    categoria: string
    autor?: string
    duracaoLeituraMin?: number
    publicado?: boolean
    ordem?: number
    createdAt?: Date | string
  }

  export type ContentArticleUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    slug?: StringFieldUpdateOperationsInput | string
    titulo?: StringFieldUpdateOperationsInput | string
    resumo?: StringFieldUpdateOperationsInput | string
    corpo?: StringFieldUpdateOperationsInput | string
    categoria?: StringFieldUpdateOperationsInput | string
    autor?: StringFieldUpdateOperationsInput | string
    duracaoLeituraMin?: IntFieldUpdateOperationsInput | number
    publicado?: BoolFieldUpdateOperationsInput | boolean
    ordem?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type ContentArticleUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    slug?: StringFieldUpdateOperationsInput | string
    titulo?: StringFieldUpdateOperationsInput | string
    resumo?: StringFieldUpdateOperationsInput | string
    corpo?: StringFieldUpdateOperationsInput | string
    categoria?: StringFieldUpdateOperationsInput | string
    autor?: StringFieldUpdateOperationsInput | string
    duracaoLeituraMin?: IntFieldUpdateOperationsInput | number
    publicado?: BoolFieldUpdateOperationsInput | boolean
    ordem?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type QuizCreateInput = {
    id?: string
    titulo: string
    descricao?: string | null
    perguntasJson: string
    pontos?: number
    publicado?: boolean
    createdAt?: Date | string
    attempts?: QuizAttemptCreateNestedManyWithoutQuizInput
  }

  export type QuizUncheckedCreateInput = {
    id?: string
    titulo: string
    descricao?: string | null
    perguntasJson: string
    pontos?: number
    publicado?: boolean
    createdAt?: Date | string
    attempts?: QuizAttemptUncheckedCreateNestedManyWithoutQuizInput
  }

  export type QuizUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    titulo?: StringFieldUpdateOperationsInput | string
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    perguntasJson?: StringFieldUpdateOperationsInput | string
    pontos?: IntFieldUpdateOperationsInput | number
    publicado?: BoolFieldUpdateOperationsInput | boolean
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    attempts?: QuizAttemptUpdateManyWithoutQuizNestedInput
  }

  export type QuizUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    titulo?: StringFieldUpdateOperationsInput | string
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    perguntasJson?: StringFieldUpdateOperationsInput | string
    pontos?: IntFieldUpdateOperationsInput | number
    publicado?: BoolFieldUpdateOperationsInput | boolean
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    attempts?: QuizAttemptUncheckedUpdateManyWithoutQuizNestedInput
  }

  export type QuizCreateManyInput = {
    id?: string
    titulo: string
    descricao?: string | null
    perguntasJson: string
    pontos?: number
    publicado?: boolean
    createdAt?: Date | string
  }

  export type QuizUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    titulo?: StringFieldUpdateOperationsInput | string
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    perguntasJson?: StringFieldUpdateOperationsInput | string
    pontos?: IntFieldUpdateOperationsInput | number
    publicado?: BoolFieldUpdateOperationsInput | boolean
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type QuizUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    titulo?: StringFieldUpdateOperationsInput | string
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    perguntasJson?: StringFieldUpdateOperationsInput | string
    pontos?: IntFieldUpdateOperationsInput | number
    publicado?: BoolFieldUpdateOperationsInput | boolean
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type QuizAttemptCreateInput = {
    id?: string
    acertos: number
    total: number
    pontosGanhos: number
    respostasJson?: string | null
    createdAt?: Date | string
    user: UserCreateNestedOneWithoutQuizAttemptsInput
    quiz: QuizCreateNestedOneWithoutAttemptsInput
  }

  export type QuizAttemptUncheckedCreateInput = {
    id?: string
    userId: string
    quizId: string
    acertos: number
    total: number
    pontosGanhos: number
    respostasJson?: string | null
    createdAt?: Date | string
  }

  export type QuizAttemptUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    acertos?: IntFieldUpdateOperationsInput | number
    total?: IntFieldUpdateOperationsInput | number
    pontosGanhos?: IntFieldUpdateOperationsInput | number
    respostasJson?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    user?: UserUpdateOneRequiredWithoutQuizAttemptsNestedInput
    quiz?: QuizUpdateOneRequiredWithoutAttemptsNestedInput
  }

  export type QuizAttemptUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    quizId?: StringFieldUpdateOperationsInput | string
    acertos?: IntFieldUpdateOperationsInput | number
    total?: IntFieldUpdateOperationsInput | number
    pontosGanhos?: IntFieldUpdateOperationsInput | number
    respostasJson?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type QuizAttemptCreateManyInput = {
    id?: string
    userId: string
    quizId: string
    acertos: number
    total: number
    pontosGanhos: number
    respostasJson?: string | null
    createdAt?: Date | string
  }

  export type QuizAttemptUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    acertos?: IntFieldUpdateOperationsInput | number
    total?: IntFieldUpdateOperationsInput | number
    pontosGanhos?: IntFieldUpdateOperationsInput | number
    respostasJson?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type QuizAttemptUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    quizId?: StringFieldUpdateOperationsInput | string
    acertos?: IntFieldUpdateOperationsInput | number
    total?: IntFieldUpdateOperationsInput | number
    pontosGanhos?: IntFieldUpdateOperationsInput | number
    respostasJson?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type BadgeCreateInput = {
    id?: string
    tipo: string
    titulo: string
    descricao?: string | null
    createdAt?: Date | string
    user: UserCreateNestedOneWithoutBadgesInput
  }

  export type BadgeUncheckedCreateInput = {
    id?: string
    userId: string
    tipo: string
    titulo: string
    descricao?: string | null
    createdAt?: Date | string
  }

  export type BadgeUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    titulo?: StringFieldUpdateOperationsInput | string
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    user?: UserUpdateOneRequiredWithoutBadgesNestedInput
  }

  export type BadgeUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    titulo?: StringFieldUpdateOperationsInput | string
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type BadgeCreateManyInput = {
    id?: string
    userId: string
    tipo: string
    titulo: string
    descricao?: string | null
    createdAt?: Date | string
  }

  export type BadgeUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    titulo?: StringFieldUpdateOperationsInput | string
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type BadgeUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    titulo?: StringFieldUpdateOperationsInput | string
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type ApiKeyCreateInput = {
    id?: string
    nome: string
    partnerNome: string
    chave: string
    scopes: string
    status?: string
    rateLimit?: number
    createdAt?: Date | string
    ultimoUso?: Date | string | null
    usos?: number
    chamadas?: ApiCallCreateNestedManyWithoutApiKeyInput
  }

  export type ApiKeyUncheckedCreateInput = {
    id?: string
    nome: string
    partnerNome: string
    chave: string
    scopes: string
    status?: string
    rateLimit?: number
    createdAt?: Date | string
    ultimoUso?: Date | string | null
    usos?: number
    chamadas?: ApiCallUncheckedCreateNestedManyWithoutApiKeyInput
  }

  export type ApiKeyUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    partnerNome?: StringFieldUpdateOperationsInput | string
    chave?: StringFieldUpdateOperationsInput | string
    scopes?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    rateLimit?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    ultimoUso?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    usos?: IntFieldUpdateOperationsInput | number
    chamadas?: ApiCallUpdateManyWithoutApiKeyNestedInput
  }

  export type ApiKeyUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    partnerNome?: StringFieldUpdateOperationsInput | string
    chave?: StringFieldUpdateOperationsInput | string
    scopes?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    rateLimit?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    ultimoUso?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    usos?: IntFieldUpdateOperationsInput | number
    chamadas?: ApiCallUncheckedUpdateManyWithoutApiKeyNestedInput
  }

  export type ApiKeyCreateManyInput = {
    id?: string
    nome: string
    partnerNome: string
    chave: string
    scopes: string
    status?: string
    rateLimit?: number
    createdAt?: Date | string
    ultimoUso?: Date | string | null
    usos?: number
  }

  export type ApiKeyUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    partnerNome?: StringFieldUpdateOperationsInput | string
    chave?: StringFieldUpdateOperationsInput | string
    scopes?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    rateLimit?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    ultimoUso?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    usos?: IntFieldUpdateOperationsInput | number
  }

  export type ApiKeyUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    partnerNome?: StringFieldUpdateOperationsInput | string
    chave?: StringFieldUpdateOperationsInput | string
    scopes?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    rateLimit?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    ultimoUso?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    usos?: IntFieldUpdateOperationsInput | number
  }

  export type ApiCallCreateInput = {
    id?: string
    endpoint: string
    metodo?: string
    status: number
    duracaoMs: number
    ip?: string | null
    timestamp?: Date | string
    apiKey: ApiKeyCreateNestedOneWithoutChamadasInput
  }

  export type ApiCallUncheckedCreateInput = {
    id?: string
    apiKeyId: string
    endpoint: string
    metodo?: string
    status: number
    duracaoMs: number
    ip?: string | null
    timestamp?: Date | string
  }

  export type ApiCallUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    endpoint?: StringFieldUpdateOperationsInput | string
    metodo?: StringFieldUpdateOperationsInput | string
    status?: IntFieldUpdateOperationsInput | number
    duracaoMs?: IntFieldUpdateOperationsInput | number
    ip?: NullableStringFieldUpdateOperationsInput | string | null
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
    apiKey?: ApiKeyUpdateOneRequiredWithoutChamadasNestedInput
  }

  export type ApiCallUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    apiKeyId?: StringFieldUpdateOperationsInput | string
    endpoint?: StringFieldUpdateOperationsInput | string
    metodo?: StringFieldUpdateOperationsInput | string
    status?: IntFieldUpdateOperationsInput | number
    duracaoMs?: IntFieldUpdateOperationsInput | number
    ip?: NullableStringFieldUpdateOperationsInput | string | null
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type ApiCallCreateManyInput = {
    id?: string
    apiKeyId: string
    endpoint: string
    metodo?: string
    status: number
    duracaoMs: number
    ip?: string | null
    timestamp?: Date | string
  }

  export type ApiCallUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    endpoint?: StringFieldUpdateOperationsInput | string
    metodo?: StringFieldUpdateOperationsInput | string
    status?: IntFieldUpdateOperationsInput | number
    duracaoMs?: IntFieldUpdateOperationsInput | number
    ip?: NullableStringFieldUpdateOperationsInput | string | null
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type ApiCallUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    apiKeyId?: StringFieldUpdateOperationsInput | string
    endpoint?: StringFieldUpdateOperationsInput | string
    metodo?: StringFieldUpdateOperationsInput | string
    status?: IntFieldUpdateOperationsInput | number
    duracaoMs?: IntFieldUpdateOperationsInput | number
    ip?: NullableStringFieldUpdateOperationsInput | string | null
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type InsuranceProductCreateInput = {
    id?: string
    nome: string
    tipo: string
    premiumMensal: number
    coberturaMax: number
    descricao?: string | null
    activo?: boolean
    policies?: InsurancePolicyCreateNestedManyWithoutProductInput
  }

  export type InsuranceProductUncheckedCreateInput = {
    id?: string
    nome: string
    tipo: string
    premiumMensal: number
    coberturaMax: number
    descricao?: string | null
    activo?: boolean
    policies?: InsurancePolicyUncheckedCreateNestedManyWithoutProductInput
  }

  export type InsuranceProductUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    premiumMensal?: FloatFieldUpdateOperationsInput | number
    coberturaMax?: FloatFieldUpdateOperationsInput | number
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    activo?: BoolFieldUpdateOperationsInput | boolean
    policies?: InsurancePolicyUpdateManyWithoutProductNestedInput
  }

  export type InsuranceProductUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    premiumMensal?: FloatFieldUpdateOperationsInput | number
    coberturaMax?: FloatFieldUpdateOperationsInput | number
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    activo?: BoolFieldUpdateOperationsInput | boolean
    policies?: InsurancePolicyUncheckedUpdateManyWithoutProductNestedInput
  }

  export type InsuranceProductCreateManyInput = {
    id?: string
    nome: string
    tipo: string
    premiumMensal: number
    coberturaMax: number
    descricao?: string | null
    activo?: boolean
  }

  export type InsuranceProductUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    premiumMensal?: FloatFieldUpdateOperationsInput | number
    coberturaMax?: FloatFieldUpdateOperationsInput | number
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    activo?: BoolFieldUpdateOperationsInput | boolean
  }

  export type InsuranceProductUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    premiumMensal?: FloatFieldUpdateOperationsInput | number
    coberturaMax?: FloatFieldUpdateOperationsInput | number
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    activo?: BoolFieldUpdateOperationsInput | boolean
  }

  export type InsurancePolicyCreateInput = {
    id?: string
    status?: string
    dataInicio?: Date | string
    premiumPago?: number
    proximaCobranca?: Date | string | null
    user: UserCreateNestedOneWithoutInsurancePoliciesInput
    product: InsuranceProductCreateNestedOneWithoutPoliciesInput
  }

  export type InsurancePolicyUncheckedCreateInput = {
    id?: string
    userId: string
    productId: string
    status?: string
    dataInicio?: Date | string
    premiumPago?: number
    proximaCobranca?: Date | string | null
  }

  export type InsurancePolicyUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    dataInicio?: DateTimeFieldUpdateOperationsInput | Date | string
    premiumPago?: FloatFieldUpdateOperationsInput | number
    proximaCobranca?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    user?: UserUpdateOneRequiredWithoutInsurancePoliciesNestedInput
    product?: InsuranceProductUpdateOneRequiredWithoutPoliciesNestedInput
  }

  export type InsurancePolicyUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    productId?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    dataInicio?: DateTimeFieldUpdateOperationsInput | Date | string
    premiumPago?: FloatFieldUpdateOperationsInput | number
    proximaCobranca?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  }

  export type InsurancePolicyCreateManyInput = {
    id?: string
    userId: string
    productId: string
    status?: string
    dataInicio?: Date | string
    premiumPago?: number
    proximaCobranca?: Date | string | null
  }

  export type InsurancePolicyUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    dataInicio?: DateTimeFieldUpdateOperationsInput | Date | string
    premiumPago?: FloatFieldUpdateOperationsInput | number
    proximaCobranca?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  }

  export type InsurancePolicyUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    productId?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    dataInicio?: DateTimeFieldUpdateOperationsInput | Date | string
    premiumPago?: FloatFieldUpdateOperationsInput | number
    proximaCobranca?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  }

  export type CountryCreateInput = {
    codigo: string
    nome: string
    moedaPadrao: string
    regulador: string
    estrutura?: string | null
    activo?: boolean
  }

  export type CountryUncheckedCreateInput = {
    codigo: string
    nome: string
    moedaPadrao: string
    regulador: string
    estrutura?: string | null
    activo?: boolean
  }

  export type CountryUpdateInput = {
    codigo?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    moedaPadrao?: StringFieldUpdateOperationsInput | string
    regulador?: StringFieldUpdateOperationsInput | string
    estrutura?: NullableStringFieldUpdateOperationsInput | string | null
    activo?: BoolFieldUpdateOperationsInput | boolean
  }

  export type CountryUncheckedUpdateInput = {
    codigo?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    moedaPadrao?: StringFieldUpdateOperationsInput | string
    regulador?: StringFieldUpdateOperationsInput | string
    estrutura?: NullableStringFieldUpdateOperationsInput | string | null
    activo?: BoolFieldUpdateOperationsInput | boolean
  }

  export type CountryCreateManyInput = {
    codigo: string
    nome: string
    moedaPadrao: string
    regulador: string
    estrutura?: string | null
    activo?: boolean
  }

  export type CountryUpdateManyMutationInput = {
    codigo?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    moedaPadrao?: StringFieldUpdateOperationsInput | string
    regulador?: StringFieldUpdateOperationsInput | string
    estrutura?: NullableStringFieldUpdateOperationsInput | string | null
    activo?: BoolFieldUpdateOperationsInput | boolean
  }

  export type CountryUncheckedUpdateManyInput = {
    codigo?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    moedaPadrao?: StringFieldUpdateOperationsInput | string
    regulador?: StringFieldUpdateOperationsInput | string
    estrutura?: NullableStringFieldUpdateOperationsInput | string | null
    activo?: BoolFieldUpdateOperationsInput | boolean
  }

  export type AnalyticsSnapshotCreateInput = {
    id?: string
    data: Date | string
    utilizadoresActivos: number
    gruposActivos: number
    contribuicoesPagas: number
    volumeMensal: number
    defaultsAbertos: number
    fundoCobertura: number
    createdAt?: Date | string
  }

  export type AnalyticsSnapshotUncheckedCreateInput = {
    id?: string
    data: Date | string
    utilizadoresActivos: number
    gruposActivos: number
    contribuicoesPagas: number
    volumeMensal: number
    defaultsAbertos: number
    fundoCobertura: number
    createdAt?: Date | string
  }

  export type AnalyticsSnapshotUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    data?: DateTimeFieldUpdateOperationsInput | Date | string
    utilizadoresActivos?: IntFieldUpdateOperationsInput | number
    gruposActivos?: IntFieldUpdateOperationsInput | number
    contribuicoesPagas?: IntFieldUpdateOperationsInput | number
    volumeMensal?: FloatFieldUpdateOperationsInput | number
    defaultsAbertos?: IntFieldUpdateOperationsInput | number
    fundoCobertura?: FloatFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type AnalyticsSnapshotUncheckedUpdateInput = {
    id?: StringFieldUpdateOperationsInput | string
    data?: DateTimeFieldUpdateOperationsInput | Date | string
    utilizadoresActivos?: IntFieldUpdateOperationsInput | number
    gruposActivos?: IntFieldUpdateOperationsInput | number
    contribuicoesPagas?: IntFieldUpdateOperationsInput | number
    volumeMensal?: FloatFieldUpdateOperationsInput | number
    defaultsAbertos?: IntFieldUpdateOperationsInput | number
    fundoCobertura?: FloatFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type AnalyticsSnapshotCreateManyInput = {
    id?: string
    data: Date | string
    utilizadoresActivos: number
    gruposActivos: number
    contribuicoesPagas: number
    volumeMensal: number
    defaultsAbertos: number
    fundoCobertura: number
    createdAt?: Date | string
  }

  export type AnalyticsSnapshotUpdateManyMutationInput = {
    id?: StringFieldUpdateOperationsInput | string
    data?: DateTimeFieldUpdateOperationsInput | Date | string
    utilizadoresActivos?: IntFieldUpdateOperationsInput | number
    gruposActivos?: IntFieldUpdateOperationsInput | number
    contribuicoesPagas?: IntFieldUpdateOperationsInput | number
    volumeMensal?: FloatFieldUpdateOperationsInput | number
    defaultsAbertos?: IntFieldUpdateOperationsInput | number
    fundoCobertura?: FloatFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type AnalyticsSnapshotUncheckedUpdateManyInput = {
    id?: StringFieldUpdateOperationsInput | string
    data?: DateTimeFieldUpdateOperationsInput | Date | string
    utilizadoresActivos?: IntFieldUpdateOperationsInput | number
    gruposActivos?: IntFieldUpdateOperationsInput | number
    contribuicoesPagas?: IntFieldUpdateOperationsInput | number
    volumeMensal?: FloatFieldUpdateOperationsInput | number
    defaultsAbertos?: IntFieldUpdateOperationsInput | number
    fundoCobertura?: FloatFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  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 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 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 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 UserNullableRelationFilter = {
    is?: UserWhereInput | null
    isNot?: UserWhereInput | null
  }

  export type UserListRelationFilter = {
    every?: UserWhereInput
    some?: UserWhereInput
    none?: UserWhereInput
  }

  export type GroupListRelationFilter = {
    every?: GroupWhereInput
    some?: GroupWhereInput
    none?: GroupWhereInput
  }

  export type MembershipListRelationFilter = {
    every?: MembershipWhereInput
    some?: MembershipWhereInput
    none?: MembershipWhereInput
  }

  export type ContributionListRelationFilter = {
    every?: ContributionWhereInput
    some?: ContributionWhereInput
    none?: ContributionWhereInput
  }

  export type CashoutListRelationFilter = {
    every?: CashoutWhereInput
    some?: CashoutWhereInput
    none?: CashoutWhereInput
  }

  export type LoanListRelationFilter = {
    every?: LoanWhereInput
    some?: LoanWhereInput
    none?: LoanWhereInput
  }

  export type ScoreEventListRelationFilter = {
    every?: ScoreEventWhereInput
    some?: ScoreEventWhereInput
    none?: ScoreEventWhereInput
  }

  export type ReintegrationListRelationFilter = {
    every?: ReintegrationWhereInput
    some?: ReintegrationWhereInput
    none?: ReintegrationWhereInput
  }

  export type OtpListRelationFilter = {
    every?: OtpWhereInput
    some?: OtpWhereInput
    none?: OtpWhereInput
  }

  export type SessionListRelationFilter = {
    every?: SessionWhereInput
    some?: SessionWhereInput
    none?: SessionWhereInput
  }

  export type NotificationListRelationFilter = {
    every?: NotificationWhereInput
    some?: NotificationWhereInput
    none?: NotificationWhereInput
  }

  export type CoverageDecisionListRelationFilter = {
    every?: CoverageDecisionWhereInput
    some?: CoverageDecisionWhereInput
    none?: CoverageDecisionWhereInput
  }

  export type InviteListRelationFilter = {
    every?: InviteWhereInput
    some?: InviteWhereInput
    none?: InviteWhereInput
  }

  export type FeeConfigurationListRelationFilter = {
    every?: FeeConfigurationWhereInput
    some?: FeeConfigurationWhereInput
    none?: FeeConfigurationWhereInput
  }

  export type AuditLogListRelationFilter = {
    every?: AuditLogWhereInput
    some?: AuditLogWhereInput
    none?: AuditLogWhereInput
  }

  export type CreditApplicationListRelationFilter = {
    every?: CreditApplicationWhereInput
    some?: CreditApplicationWhereInput
    none?: CreditApplicationWhereInput
  }

  export type SavingsAccountListRelationFilter = {
    every?: SavingsAccountWhereInput
    some?: SavingsAccountWhereInput
    none?: SavingsAccountWhereInput
  }

  export type ReferralListRelationFilter = {
    every?: ReferralWhereInput
    some?: ReferralWhereInput
    none?: ReferralWhereInput
  }

  export type QuizAttemptListRelationFilter = {
    every?: QuizAttemptWhereInput
    some?: QuizAttemptWhereInput
    none?: QuizAttemptWhereInput
  }

  export type BadgeListRelationFilter = {
    every?: BadgeWhereInput
    some?: BadgeWhereInput
    none?: BadgeWhereInput
  }

  export type InsurancePolicyListRelationFilter = {
    every?: InsurancePolicyWhereInput
    some?: InsurancePolicyWhereInput
    none?: InsurancePolicyWhereInput
  }

  export type SortOrderInput = {
    sort: SortOrder
    nulls?: NullsOrder
  }

  export type UserOrderByRelationAggregateInput = {
    _count?: SortOrder
  }

  export type GroupOrderByRelationAggregateInput = {
    _count?: SortOrder
  }

  export type MembershipOrderByRelationAggregateInput = {
    _count?: SortOrder
  }

  export type ContributionOrderByRelationAggregateInput = {
    _count?: SortOrder
  }

  export type CashoutOrderByRelationAggregateInput = {
    _count?: SortOrder
  }

  export type LoanOrderByRelationAggregateInput = {
    _count?: SortOrder
  }

  export type ScoreEventOrderByRelationAggregateInput = {
    _count?: SortOrder
  }

  export type ReintegrationOrderByRelationAggregateInput = {
    _count?: SortOrder
  }

  export type OtpOrderByRelationAggregateInput = {
    _count?: SortOrder
  }

  export type SessionOrderByRelationAggregateInput = {
    _count?: SortOrder
  }

  export type NotificationOrderByRelationAggregateInput = {
    _count?: SortOrder
  }

  export type CoverageDecisionOrderByRelationAggregateInput = {
    _count?: SortOrder
  }

  export type InviteOrderByRelationAggregateInput = {
    _count?: SortOrder
  }

  export type FeeConfigurationOrderByRelationAggregateInput = {
    _count?: SortOrder
  }

  export type AuditLogOrderByRelationAggregateInput = {
    _count?: SortOrder
  }

  export type CreditApplicationOrderByRelationAggregateInput = {
    _count?: SortOrder
  }

  export type SavingsAccountOrderByRelationAggregateInput = {
    _count?: SortOrder
  }

  export type ReferralOrderByRelationAggregateInput = {
    _count?: SortOrder
  }

  export type QuizAttemptOrderByRelationAggregateInput = {
    _count?: SortOrder
  }

  export type BadgeOrderByRelationAggregateInput = {
    _count?: SortOrder
  }

  export type InsurancePolicyOrderByRelationAggregateInput = {
    _count?: SortOrder
  }

  export type UserCountOrderByAggregateInput = {
    id?: SortOrder
    nome?: SortOrder
    telefone?: SortOrder
    email?: SortOrder
    passwordHash?: SortOrder
    bi?: SortOrder
    dataNascimento?: SortOrder
    provincia?: SortOrder
    pais?: SortOrder
    moedaPreferida?: SortOrder
    fotoPerfilUrl?: SortOrder
    kycStatus?: SortOrder
    kycNivel?: SortOrder
    kycDataJson?: SortOrder
    status?: SortOrder
    scoreAtual?: SortOrder
    role?: SortOrder
    referralCode?: SortOrder
    referredById?: SortOrder
    pontosEducacao?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
  }

  export type UserAvgOrderByAggregateInput = {
    kycNivel?: SortOrder
    scoreAtual?: SortOrder
    pontosEducacao?: SortOrder
  }

  export type UserMaxOrderByAggregateInput = {
    id?: SortOrder
    nome?: SortOrder
    telefone?: SortOrder
    email?: SortOrder
    passwordHash?: SortOrder
    bi?: SortOrder
    dataNascimento?: SortOrder
    provincia?: SortOrder
    pais?: SortOrder
    moedaPreferida?: SortOrder
    fotoPerfilUrl?: SortOrder
    kycStatus?: SortOrder
    kycNivel?: SortOrder
    kycDataJson?: SortOrder
    status?: SortOrder
    scoreAtual?: SortOrder
    role?: SortOrder
    referralCode?: SortOrder
    referredById?: SortOrder
    pontosEducacao?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
  }

  export type UserMinOrderByAggregateInput = {
    id?: SortOrder
    nome?: SortOrder
    telefone?: SortOrder
    email?: SortOrder
    passwordHash?: SortOrder
    bi?: SortOrder
    dataNascimento?: SortOrder
    provincia?: SortOrder
    pais?: SortOrder
    moedaPreferida?: SortOrder
    fotoPerfilUrl?: SortOrder
    kycStatus?: SortOrder
    kycNivel?: SortOrder
    kycDataJson?: SortOrder
    status?: SortOrder
    scoreAtual?: SortOrder
    role?: SortOrder
    referralCode?: SortOrder
    referredById?: SortOrder
    pontosEducacao?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
  }

  export type UserSumOrderByAggregateInput = {
    kycNivel?: SortOrder
    scoreAtual?: SortOrder
    pontosEducacao?: 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 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 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 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 BoolFilter<$PrismaModel = never> = {
    equals?: boolean | BooleanFieldRefInput<$PrismaModel>
    not?: NestedBoolFilter<$PrismaModel> | boolean
  }

  export type OtpCountOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    telefone?: SortOrder
    codigo?: SortOrder
    proposito?: SortOrder
    consumido?: SortOrder
    expiraEm?: SortOrder
    createdAt?: SortOrder
  }

  export type OtpMaxOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    telefone?: SortOrder
    codigo?: SortOrder
    proposito?: SortOrder
    consumido?: SortOrder
    expiraEm?: SortOrder
    createdAt?: SortOrder
  }

  export type OtpMinOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    telefone?: SortOrder
    codigo?: SortOrder
    proposito?: SortOrder
    consumido?: SortOrder
    expiraEm?: SortOrder
    createdAt?: SortOrder
  }

  export type BoolWithAggregatesFilter<$PrismaModel = never> = {
    equals?: boolean | BooleanFieldRefInput<$PrismaModel>
    not?: NestedBoolWithAggregatesFilter<$PrismaModel> | boolean
    _count?: NestedIntFilter<$PrismaModel>
    _min?: NestedBoolFilter<$PrismaModel>
    _max?: NestedBoolFilter<$PrismaModel>
  }

  export type UserRelationFilter = {
    is?: UserWhereInput
    isNot?: UserWhereInput
  }

  export type SessionCountOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    token?: SortOrder
    expiraEm?: SortOrder
    createdAt?: SortOrder
  }

  export type SessionMaxOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    token?: SortOrder
    expiraEm?: SortOrder
    createdAt?: SortOrder
  }

  export type SessionMinOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    token?: SortOrder
    expiraEm?: SortOrder
    createdAt?: SortOrder
  }

  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 MonthlyCycleListRelationFilter = {
    every?: MonthlyCycleWhereInput
    some?: MonthlyCycleWhereInput
    none?: MonthlyCycleWhereInput
  }

  export type GroupApplicationListRelationFilter = {
    every?: GroupApplicationWhereInput
    some?: GroupApplicationWhereInput
    none?: GroupApplicationWhereInput
  }

  export type MonthlyCycleOrderByRelationAggregateInput = {
    _count?: SortOrder
  }

  export type GroupApplicationOrderByRelationAggregateInput = {
    _count?: SortOrder
  }

  export type GroupCountOrderByAggregateInput = {
    id?: SortOrder
    nome?: SortOrder
    descricao?: SortOrder
    criadorId?: SortOrder
    numMembros?: SortOrder
    valorContribuicaoMensal?: SortOrder
    taxaPrincipalAplicada?: SortOrder
    reservaTecnicaAplicada?: SortOrder
    periodicidade?: SortOrder
    tipo?: SortOrder
    pais?: SortOrder
    moeda?: SortOrder
    status?: SortOrder
    dataInicio?: SortOrder
    dataFimPrevista?: SortOrder
    cicloAtual?: SortOrder
    totalCiclos?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
  }

  export type GroupAvgOrderByAggregateInput = {
    numMembros?: SortOrder
    valorContribuicaoMensal?: SortOrder
    taxaPrincipalAplicada?: SortOrder
    reservaTecnicaAplicada?: SortOrder
    cicloAtual?: SortOrder
    totalCiclos?: SortOrder
  }

  export type GroupMaxOrderByAggregateInput = {
    id?: SortOrder
    nome?: SortOrder
    descricao?: SortOrder
    criadorId?: SortOrder
    numMembros?: SortOrder
    valorContribuicaoMensal?: SortOrder
    taxaPrincipalAplicada?: SortOrder
    reservaTecnicaAplicada?: SortOrder
    periodicidade?: SortOrder
    tipo?: SortOrder
    pais?: SortOrder
    moeda?: SortOrder
    status?: SortOrder
    dataInicio?: SortOrder
    dataFimPrevista?: SortOrder
    cicloAtual?: SortOrder
    totalCiclos?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
  }

  export type GroupMinOrderByAggregateInput = {
    id?: SortOrder
    nome?: SortOrder
    descricao?: SortOrder
    criadorId?: SortOrder
    numMembros?: SortOrder
    valorContribuicaoMensal?: SortOrder
    taxaPrincipalAplicada?: SortOrder
    reservaTecnicaAplicada?: SortOrder
    periodicidade?: SortOrder
    tipo?: SortOrder
    pais?: SortOrder
    moeda?: SortOrder
    status?: SortOrder
    dataInicio?: SortOrder
    dataFimPrevista?: SortOrder
    cicloAtual?: SortOrder
    totalCiclos?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
  }

  export type GroupSumOrderByAggregateInput = {
    numMembros?: SortOrder
    valorContribuicaoMensal?: SortOrder
    taxaPrincipalAplicada?: SortOrder
    reservaTecnicaAplicada?: SortOrder
    cicloAtual?: SortOrder
    totalCiclos?: SortOrder
  }

  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 GroupRelationFilter = {
    is?: GroupWhereInput
    isNot?: GroupWhereInput
  }

  export type GroupApplicationGroupIdUserIdCompoundUniqueInput = {
    groupId: string
    userId: string
  }

  export type GroupApplicationCountOrderByAggregateInput = {
    id?: SortOrder
    groupId?: SortOrder
    userId?: SortOrder
    mensagem?: SortOrder
    status?: SortOrder
    createdAt?: SortOrder
  }

  export type GroupApplicationMaxOrderByAggregateInput = {
    id?: SortOrder
    groupId?: SortOrder
    userId?: SortOrder
    mensagem?: SortOrder
    status?: SortOrder
    createdAt?: SortOrder
  }

  export type GroupApplicationMinOrderByAggregateInput = {
    id?: SortOrder
    groupId?: SortOrder
    userId?: SortOrder
    mensagem?: SortOrder
    status?: SortOrder
    createdAt?: 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 MembershipUserIdGroupIdCompoundUniqueInput = {
    userId: string
    groupId: string
  }

  export type MembershipCountOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    groupId?: SortOrder
    posicaoRotacao?: SortOrder
    status?: SortOrder
    necessidadeUrgente?: SortOrder
    dataJuncao?: SortOrder
    mesRecepcaoPrevisto?: SortOrder
  }

  export type MembershipAvgOrderByAggregateInput = {
    posicaoRotacao?: SortOrder
  }

  export type MembershipMaxOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    groupId?: SortOrder
    posicaoRotacao?: SortOrder
    status?: SortOrder
    necessidadeUrgente?: SortOrder
    dataJuncao?: SortOrder
    mesRecepcaoPrevisto?: SortOrder
  }

  export type MembershipMinOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    groupId?: SortOrder
    posicaoRotacao?: SortOrder
    status?: SortOrder
    necessidadeUrgente?: SortOrder
    dataJuncao?: SortOrder
    mesRecepcaoPrevisto?: SortOrder
  }

  export type MembershipSumOrderByAggregateInput = {
    posicaoRotacao?: 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 InviteCountOrderByAggregateInput = {
    id?: SortOrder
    groupId?: SortOrder
    convidadoPorId?: SortOrder
    telefone?: SortOrder
    email?: SortOrder
    token?: SortOrder
    status?: SortOrder
    createdAt?: SortOrder
    expiraEm?: SortOrder
  }

  export type InviteMaxOrderByAggregateInput = {
    id?: SortOrder
    groupId?: SortOrder
    convidadoPorId?: SortOrder
    telefone?: SortOrder
    email?: SortOrder
    token?: SortOrder
    status?: SortOrder
    createdAt?: SortOrder
    expiraEm?: SortOrder
  }

  export type InviteMinOrderByAggregateInput = {
    id?: SortOrder
    groupId?: SortOrder
    convidadoPorId?: SortOrder
    telefone?: SortOrder
    email?: SortOrder
    token?: SortOrder
    status?: SortOrder
    createdAt?: SortOrder
    expiraEm?: SortOrder
  }

  export type MembershipRelationFilter = {
    is?: MembershipWhereInput
    isNot?: MembershipWhereInput
  }

  export type CashoutNullableRelationFilter = {
    is?: CashoutWhereInput | null
    isNot?: CashoutWhereInput | null
  }

  export type MonthlyCycleGroupIdNumeroCicloCompoundUniqueInput = {
    groupId: string
    numeroCiclo: number
  }

  export type MonthlyCycleCountOrderByAggregateInput = {
    id?: SortOrder
    groupId?: SortOrder
    numeroCiclo?: SortOrder
    mesAno?: SortOrder
    beneficiarioMembershipId?: SortOrder
    dataContribuicaoLimite?: SortOrder
    dataCashout?: SortOrder
    status?: SortOrder
    valorPoteBruto?: SortOrder
    valorTaxaPrincipal?: SortOrder
    valorReservaTecnica?: SortOrder
    valorPoteLiquido?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
  }

  export type MonthlyCycleAvgOrderByAggregateInput = {
    numeroCiclo?: SortOrder
    valorPoteBruto?: SortOrder
    valorTaxaPrincipal?: SortOrder
    valorReservaTecnica?: SortOrder
    valorPoteLiquido?: SortOrder
  }

  export type MonthlyCycleMaxOrderByAggregateInput = {
    id?: SortOrder
    groupId?: SortOrder
    numeroCiclo?: SortOrder
    mesAno?: SortOrder
    beneficiarioMembershipId?: SortOrder
    dataContribuicaoLimite?: SortOrder
    dataCashout?: SortOrder
    status?: SortOrder
    valorPoteBruto?: SortOrder
    valorTaxaPrincipal?: SortOrder
    valorReservaTecnica?: SortOrder
    valorPoteLiquido?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
  }

  export type MonthlyCycleMinOrderByAggregateInput = {
    id?: SortOrder
    groupId?: SortOrder
    numeroCiclo?: SortOrder
    mesAno?: SortOrder
    beneficiarioMembershipId?: SortOrder
    dataContribuicaoLimite?: SortOrder
    dataCashout?: SortOrder
    status?: SortOrder
    valorPoteBruto?: SortOrder
    valorTaxaPrincipal?: SortOrder
    valorReservaTecnica?: SortOrder
    valorPoteLiquido?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
  }

  export type MonthlyCycleSumOrderByAggregateInput = {
    numeroCiclo?: SortOrder
    valorPoteBruto?: SortOrder
    valorTaxaPrincipal?: SortOrder
    valorReservaTecnica?: SortOrder
    valorPoteLiquido?: SortOrder
  }

  export type MonthlyCycleRelationFilter = {
    is?: MonthlyCycleWhereInput
    isNot?: MonthlyCycleWhereInput
  }

  export type CoverageDecisionNullableRelationFilter = {
    is?: CoverageDecisionWhereInput | null
    isNot?: CoverageDecisionWhereInput | null
  }

  export type ContributionCountOrderByAggregateInput = {
    id?: SortOrder
    membershipId?: SortOrder
    userId?: SortOrder
    monthlyCycleId?: SortOrder
    valor?: SortOrder
    dataPrevista?: SortOrder
    dataPagamento?: SortOrder
    status?: SortOrder
    metodoPagamento?: SortOrder
    referenciaBancaria?: SortOrder
    comprovativoUrl?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
  }

  export type ContributionAvgOrderByAggregateInput = {
    valor?: SortOrder
  }

  export type ContributionMaxOrderByAggregateInput = {
    id?: SortOrder
    membershipId?: SortOrder
    userId?: SortOrder
    monthlyCycleId?: SortOrder
    valor?: SortOrder
    dataPrevista?: SortOrder
    dataPagamento?: SortOrder
    status?: SortOrder
    metodoPagamento?: SortOrder
    referenciaBancaria?: SortOrder
    comprovativoUrl?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
  }

  export type ContributionMinOrderByAggregateInput = {
    id?: SortOrder
    membershipId?: SortOrder
    userId?: SortOrder
    monthlyCycleId?: SortOrder
    valor?: SortOrder
    dataPrevista?: SortOrder
    dataPagamento?: SortOrder
    status?: SortOrder
    metodoPagamento?: SortOrder
    referenciaBancaria?: SortOrder
    comprovativoUrl?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
  }

  export type ContributionSumOrderByAggregateInput = {
    valor?: SortOrder
  }

  export type CashoutCountOrderByAggregateInput = {
    id?: SortOrder
    monthlyCycleId?: SortOrder
    beneficiarioUserId?: SortOrder
    valorBruto?: SortOrder
    valorTaxaPrincipal?: SortOrder
    valorReservaTecnica?: SortOrder
    valorLiquido?: SortOrder
    dataPrevista?: SortOrder
    dataExecucao?: SortOrder
    status?: SortOrder
    contaDestino?: SortOrder
    refTransferencia?: SortOrder
    parcialMotivo?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
  }

  export type CashoutAvgOrderByAggregateInput = {
    valorBruto?: SortOrder
    valorTaxaPrincipal?: SortOrder
    valorReservaTecnica?: SortOrder
    valorLiquido?: SortOrder
  }

  export type CashoutMaxOrderByAggregateInput = {
    id?: SortOrder
    monthlyCycleId?: SortOrder
    beneficiarioUserId?: SortOrder
    valorBruto?: SortOrder
    valorTaxaPrincipal?: SortOrder
    valorReservaTecnica?: SortOrder
    valorLiquido?: SortOrder
    dataPrevista?: SortOrder
    dataExecucao?: SortOrder
    status?: SortOrder
    contaDestino?: SortOrder
    refTransferencia?: SortOrder
    parcialMotivo?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
  }

  export type CashoutMinOrderByAggregateInput = {
    id?: SortOrder
    monthlyCycleId?: SortOrder
    beneficiarioUserId?: SortOrder
    valorBruto?: SortOrder
    valorTaxaPrincipal?: SortOrder
    valorReservaTecnica?: SortOrder
    valorLiquido?: SortOrder
    dataPrevista?: SortOrder
    dataExecucao?: SortOrder
    status?: SortOrder
    contaDestino?: SortOrder
    refTransferencia?: SortOrder
    parcialMotivo?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
  }

  export type CashoutSumOrderByAggregateInput = {
    valorBruto?: SortOrder
    valorTaxaPrincipal?: SortOrder
    valorReservaTecnica?: SortOrder
    valorLiquido?: SortOrder
  }

  export type LoanCountOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    monthlyCycleId?: SortOrder
    contributionId?: SortOrder
    valorCapital?: SortOrder
    taxaEmprestimo?: SortOrder
    valorTotalDevido?: SortOrder
    jurosMoraAcumulados?: SortOrder
    dataInicio?: SortOrder
    dataPagamento?: SortOrder
    status?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
  }

  export type LoanAvgOrderByAggregateInput = {
    valorCapital?: SortOrder
    taxaEmprestimo?: SortOrder
    valorTotalDevido?: SortOrder
    jurosMoraAcumulados?: SortOrder
  }

  export type LoanMaxOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    monthlyCycleId?: SortOrder
    contributionId?: SortOrder
    valorCapital?: SortOrder
    taxaEmprestimo?: SortOrder
    valorTotalDevido?: SortOrder
    jurosMoraAcumulados?: SortOrder
    dataInicio?: SortOrder
    dataPagamento?: SortOrder
    status?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
  }

  export type LoanMinOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    monthlyCycleId?: SortOrder
    contributionId?: SortOrder
    valorCapital?: SortOrder
    taxaEmprestimo?: SortOrder
    valorTotalDevido?: SortOrder
    jurosMoraAcumulados?: SortOrder
    dataInicio?: SortOrder
    dataPagamento?: SortOrder
    status?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
  }

  export type LoanSumOrderByAggregateInput = {
    valorCapital?: SortOrder
    taxaEmprestimo?: SortOrder
    valorTotalDevido?: SortOrder
    jurosMoraAcumulados?: SortOrder
  }

  export type ContributionRelationFilter = {
    is?: ContributionWhereInput
    isNot?: ContributionWhereInput
  }

  export type CoverageDecisionCountOrderByAggregateInput = {
    id?: SortOrder
    contributionId?: SortOrder
    decisao?: SortOrder
    motivo?: SortOrder
    scoreNoMomento?: SortOrder
    historicoInadimplencias?: SortOrder
    decisorUserId?: SortOrder
    decisorSistema?: SortOrder
    createdAt?: SortOrder
  }

  export type CoverageDecisionAvgOrderByAggregateInput = {
    scoreNoMomento?: SortOrder
    historicoInadimplencias?: SortOrder
  }

  export type CoverageDecisionMaxOrderByAggregateInput = {
    id?: SortOrder
    contributionId?: SortOrder
    decisao?: SortOrder
    motivo?: SortOrder
    scoreNoMomento?: SortOrder
    historicoInadimplencias?: SortOrder
    decisorUserId?: SortOrder
    decisorSistema?: SortOrder
    createdAt?: SortOrder
  }

  export type CoverageDecisionMinOrderByAggregateInput = {
    id?: SortOrder
    contributionId?: SortOrder
    decisao?: SortOrder
    motivo?: SortOrder
    scoreNoMomento?: SortOrder
    historicoInadimplencias?: SortOrder
    decisorUserId?: SortOrder
    decisorSistema?: SortOrder
    createdAt?: SortOrder
  }

  export type CoverageDecisionSumOrderByAggregateInput = {
    scoreNoMomento?: SortOrder
    historicoInadimplencias?: SortOrder
  }

  export type ReintegrationCountOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    valorDividaOriginal?: SortOrder
    taxaReintegracaoAplicada?: SortOrder
    valorTaxaPaga?: SortOrder
    dataSolicitacao?: SortOrder
    dataConclusao?: SortOrder
    status?: SortOrder
  }

  export type ReintegrationAvgOrderByAggregateInput = {
    valorDividaOriginal?: SortOrder
    taxaReintegracaoAplicada?: SortOrder
    valorTaxaPaga?: SortOrder
  }

  export type ReintegrationMaxOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    valorDividaOriginal?: SortOrder
    taxaReintegracaoAplicada?: SortOrder
    valorTaxaPaga?: SortOrder
    dataSolicitacao?: SortOrder
    dataConclusao?: SortOrder
    status?: SortOrder
  }

  export type ReintegrationMinOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    valorDividaOriginal?: SortOrder
    taxaReintegracaoAplicada?: SortOrder
    valorTaxaPaga?: SortOrder
    dataSolicitacao?: SortOrder
    dataConclusao?: SortOrder
    status?: SortOrder
  }

  export type ReintegrationSumOrderByAggregateInput = {
    valorDividaOriginal?: SortOrder
    taxaReintegracaoAplicada?: SortOrder
    valorTaxaPaga?: SortOrder
  }

  export type FeeConfigurationCountOrderByAggregateInput = {
    id?: SortOrder
    tipoFee?: SortOrder
    valor?: SortOrder
    min?: SortOrder
    max?: SortOrder
    dataInicio?: SortOrder
    dataFim?: SortOrder
    criadoPorId?: SortOrder
    motivoMudanca?: SortOrder
    ativa?: SortOrder
    createdAt?: SortOrder
  }

  export type FeeConfigurationAvgOrderByAggregateInput = {
    valor?: SortOrder
    min?: SortOrder
    max?: SortOrder
  }

  export type FeeConfigurationMaxOrderByAggregateInput = {
    id?: SortOrder
    tipoFee?: SortOrder
    valor?: SortOrder
    min?: SortOrder
    max?: SortOrder
    dataInicio?: SortOrder
    dataFim?: SortOrder
    criadoPorId?: SortOrder
    motivoMudanca?: SortOrder
    ativa?: SortOrder
    createdAt?: SortOrder
  }

  export type FeeConfigurationMinOrderByAggregateInput = {
    id?: SortOrder
    tipoFee?: SortOrder
    valor?: SortOrder
    min?: SortOrder
    max?: SortOrder
    dataInicio?: SortOrder
    dataFim?: SortOrder
    criadoPorId?: SortOrder
    motivoMudanca?: SortOrder
    ativa?: SortOrder
    createdAt?: SortOrder
  }

  export type FeeConfigurationSumOrderByAggregateInput = {
    valor?: SortOrder
    min?: SortOrder
    max?: SortOrder
  }

  export type CoverageFundCountOrderByAggregateInput = {
    id?: SortOrder
    saldoDisponivel?: SortOrder
    saldoEmEmprestimosActivos?: SortOrder
    totalRecuperadoAno?: SortOrder
    totalPerdidoAno?: SortOrder
    lastUpdated?: SortOrder
  }

  export type CoverageFundAvgOrderByAggregateInput = {
    saldoDisponivel?: SortOrder
    saldoEmEmprestimosActivos?: SortOrder
    totalRecuperadoAno?: SortOrder
    totalPerdidoAno?: SortOrder
  }

  export type CoverageFundMaxOrderByAggregateInput = {
    id?: SortOrder
    saldoDisponivel?: SortOrder
    saldoEmEmprestimosActivos?: SortOrder
    totalRecuperadoAno?: SortOrder
    totalPerdidoAno?: SortOrder
    lastUpdated?: SortOrder
  }

  export type CoverageFundMinOrderByAggregateInput = {
    id?: SortOrder
    saldoDisponivel?: SortOrder
    saldoEmEmprestimosActivos?: SortOrder
    totalRecuperadoAno?: SortOrder
    totalPerdidoAno?: SortOrder
    lastUpdated?: SortOrder
  }

  export type CoverageFundSumOrderByAggregateInput = {
    saldoDisponivel?: SortOrder
    saldoEmEmprestimosActivos?: SortOrder
    totalRecuperadoAno?: SortOrder
    totalPerdidoAno?: SortOrder
  }

  export type TransactionCountOrderByAggregateInput = {
    id?: SortOrder
    tipo?: SortOrder
    valor?: SortOrder
    fromAccount?: SortOrder
    toAccount?: SortOrder
    referencia?: SortOrder
    status?: SortOrder
    timestamp?: SortOrder
    auditJson?: SortOrder
  }

  export type TransactionAvgOrderByAggregateInput = {
    valor?: SortOrder
  }

  export type TransactionMaxOrderByAggregateInput = {
    id?: SortOrder
    tipo?: SortOrder
    valor?: SortOrder
    fromAccount?: SortOrder
    toAccount?: SortOrder
    referencia?: SortOrder
    status?: SortOrder
    timestamp?: SortOrder
    auditJson?: SortOrder
  }

  export type TransactionMinOrderByAggregateInput = {
    id?: SortOrder
    tipo?: SortOrder
    valor?: SortOrder
    fromAccount?: SortOrder
    toAccount?: SortOrder
    referencia?: SortOrder
    status?: SortOrder
    timestamp?: SortOrder
    auditJson?: SortOrder
  }

  export type TransactionSumOrderByAggregateInput = {
    valor?: SortOrder
  }

  export type ScoreEventCountOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    tipoEvento?: SortOrder
    impacto?: SortOrder
    descricao?: SortOrder
    scoreAntes?: SortOrder
    scoreDepois?: SortOrder
    timestamp?: SortOrder
  }

  export type ScoreEventAvgOrderByAggregateInput = {
    impacto?: SortOrder
    scoreAntes?: SortOrder
    scoreDepois?: SortOrder
  }

  export type ScoreEventMaxOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    tipoEvento?: SortOrder
    impacto?: SortOrder
    descricao?: SortOrder
    scoreAntes?: SortOrder
    scoreDepois?: SortOrder
    timestamp?: SortOrder
  }

  export type ScoreEventMinOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    tipoEvento?: SortOrder
    impacto?: SortOrder
    descricao?: SortOrder
    scoreAntes?: SortOrder
    scoreDepois?: SortOrder
    timestamp?: SortOrder
  }

  export type ScoreEventSumOrderByAggregateInput = {
    impacto?: SortOrder
    scoreAntes?: SortOrder
    scoreDepois?: SortOrder
  }

  export type NotificationCountOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    canal?: SortOrder
    titulo?: SortOrder
    corpo?: SortOrder
    lida?: SortOrder
    metadataJson?: SortOrder
    createdAt?: SortOrder
  }

  export type NotificationMaxOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    canal?: SortOrder
    titulo?: SortOrder
    corpo?: SortOrder
    lida?: SortOrder
    metadataJson?: SortOrder
    createdAt?: SortOrder
  }

  export type NotificationMinOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    canal?: SortOrder
    titulo?: SortOrder
    corpo?: SortOrder
    lida?: SortOrder
    metadataJson?: SortOrder
    createdAt?: SortOrder
  }

  export type AuditLogCountOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    acao?: SortOrder
    entidade?: SortOrder
    entidadeId?: SortOrder
    dadosAntes?: SortOrder
    dadosDepois?: SortOrder
    ip?: SortOrder
    timestamp?: SortOrder
  }

  export type AuditLogMaxOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    acao?: SortOrder
    entidade?: SortOrder
    entidadeId?: SortOrder
    dadosAntes?: SortOrder
    dadosDepois?: SortOrder
    ip?: SortOrder
    timestamp?: SortOrder
  }

  export type AuditLogMinOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    acao?: SortOrder
    entidade?: SortOrder
    entidadeId?: SortOrder
    dadosAntes?: SortOrder
    dadosDepois?: SortOrder
    ip?: SortOrder
    timestamp?: SortOrder
  }

  export type SystemClockCountOrderByAggregateInput = {
    id?: SortOrder
    agora?: SortOrder
    updatedAt?: SortOrder
  }

  export type SystemClockAvgOrderByAggregateInput = {
    id?: SortOrder
  }

  export type SystemClockMaxOrderByAggregateInput = {
    id?: SortOrder
    agora?: SortOrder
    updatedAt?: SortOrder
  }

  export type SystemClockMinOrderByAggregateInput = {
    id?: SortOrder
    agora?: SortOrder
    updatedAt?: SortOrder
  }

  export type SystemClockSumOrderByAggregateInput = {
    id?: SortOrder
  }

  export type CreditInstallmentListRelationFilter = {
    every?: CreditInstallmentWhereInput
    some?: CreditInstallmentWhereInput
    none?: CreditInstallmentWhereInput
  }

  export type CreditInstallmentOrderByRelationAggregateInput = {
    _count?: SortOrder
  }

  export type CreditApplicationCountOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    valorSolicitado?: SortOrder
    prazoMeses?: SortOrder
    taxaJuroAplicada?: SortOrder
    prestacaoMensal?: SortOrder
    finalidade?: SortOrder
    status?: SortOrder
    scoreNoMomento?: SortOrder
    motivoDecisao?: SortOrder
    decisaoPorId?: SortOrder
    dataAprovacao?: SortOrder
    dataDesembolso?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
  }

  export type CreditApplicationAvgOrderByAggregateInput = {
    valorSolicitado?: SortOrder
    prazoMeses?: SortOrder
    taxaJuroAplicada?: SortOrder
    prestacaoMensal?: SortOrder
    scoreNoMomento?: SortOrder
  }

  export type CreditApplicationMaxOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    valorSolicitado?: SortOrder
    prazoMeses?: SortOrder
    taxaJuroAplicada?: SortOrder
    prestacaoMensal?: SortOrder
    finalidade?: SortOrder
    status?: SortOrder
    scoreNoMomento?: SortOrder
    motivoDecisao?: SortOrder
    decisaoPorId?: SortOrder
    dataAprovacao?: SortOrder
    dataDesembolso?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
  }

  export type CreditApplicationMinOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    valorSolicitado?: SortOrder
    prazoMeses?: SortOrder
    taxaJuroAplicada?: SortOrder
    prestacaoMensal?: SortOrder
    finalidade?: SortOrder
    status?: SortOrder
    scoreNoMomento?: SortOrder
    motivoDecisao?: SortOrder
    decisaoPorId?: SortOrder
    dataAprovacao?: SortOrder
    dataDesembolso?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
  }

  export type CreditApplicationSumOrderByAggregateInput = {
    valorSolicitado?: SortOrder
    prazoMeses?: SortOrder
    taxaJuroAplicada?: SortOrder
    prestacaoMensal?: SortOrder
    scoreNoMomento?: SortOrder
  }

  export type CreditApplicationRelationFilter = {
    is?: CreditApplicationWhereInput
    isNot?: CreditApplicationWhereInput
  }

  export type CreditInstallmentApplicationIdNumeroCompoundUniqueInput = {
    applicationId: string
    numero: number
  }

  export type CreditInstallmentCountOrderByAggregateInput = {
    id?: SortOrder
    applicationId?: SortOrder
    numero?: SortOrder
    valorCapital?: SortOrder
    valorJuros?: SortOrder
    valorTotal?: SortOrder
    dataVencimento?: SortOrder
    dataPagamento?: SortOrder
    status?: SortOrder
  }

  export type CreditInstallmentAvgOrderByAggregateInput = {
    numero?: SortOrder
    valorCapital?: SortOrder
    valorJuros?: SortOrder
    valorTotal?: SortOrder
  }

  export type CreditInstallmentMaxOrderByAggregateInput = {
    id?: SortOrder
    applicationId?: SortOrder
    numero?: SortOrder
    valorCapital?: SortOrder
    valorJuros?: SortOrder
    valorTotal?: SortOrder
    dataVencimento?: SortOrder
    dataPagamento?: SortOrder
    status?: SortOrder
  }

  export type CreditInstallmentMinOrderByAggregateInput = {
    id?: SortOrder
    applicationId?: SortOrder
    numero?: SortOrder
    valorCapital?: SortOrder
    valorJuros?: SortOrder
    valorTotal?: SortOrder
    dataVencimento?: SortOrder
    dataPagamento?: SortOrder
    status?: SortOrder
  }

  export type CreditInstallmentSumOrderByAggregateInput = {
    numero?: SortOrder
    valorCapital?: SortOrder
    valorJuros?: SortOrder
    valorTotal?: SortOrder
  }

  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 SavingsMovementListRelationFilter = {
    every?: SavingsMovementWhereInput
    some?: SavingsMovementWhereInput
    none?: SavingsMovementWhereInput
  }

  export type SavingsMovementOrderByRelationAggregateInput = {
    _count?: SortOrder
  }

  export type SavingsAccountCountOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    nome?: SortOrder
    objectivo?: SortOrder
    meta?: SortOrder
    saldo?: SortOrder
    taxaRemuneracaoAnual?: SortOrder
    imobilizacaoMeses?: SortOrder
    status?: SortOrder
    ultimaCapitalizacao?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
  }

  export type SavingsAccountAvgOrderByAggregateInput = {
    meta?: SortOrder
    saldo?: SortOrder
    taxaRemuneracaoAnual?: SortOrder
    imobilizacaoMeses?: SortOrder
  }

  export type SavingsAccountMaxOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    nome?: SortOrder
    objectivo?: SortOrder
    meta?: SortOrder
    saldo?: SortOrder
    taxaRemuneracaoAnual?: SortOrder
    imobilizacaoMeses?: SortOrder
    status?: SortOrder
    ultimaCapitalizacao?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
  }

  export type SavingsAccountMinOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    nome?: SortOrder
    objectivo?: SortOrder
    meta?: SortOrder
    saldo?: SortOrder
    taxaRemuneracaoAnual?: SortOrder
    imobilizacaoMeses?: SortOrder
    status?: SortOrder
    ultimaCapitalizacao?: SortOrder
    createdAt?: SortOrder
    updatedAt?: SortOrder
  }

  export type SavingsAccountSumOrderByAggregateInput = {
    meta?: SortOrder
    saldo?: SortOrder
    taxaRemuneracaoAnual?: SortOrder
    imobilizacaoMeses?: 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 SavingsAccountRelationFilter = {
    is?: SavingsAccountWhereInput
    isNot?: SavingsAccountWhereInput
  }

  export type SavingsMovementCountOrderByAggregateInput = {
    id?: SortOrder
    accountId?: SortOrder
    tipo?: SortOrder
    valor?: SortOrder
    saldoApos?: SortOrder
    descricao?: SortOrder
    createdAt?: SortOrder
  }

  export type SavingsMovementAvgOrderByAggregateInput = {
    valor?: SortOrder
    saldoApos?: SortOrder
  }

  export type SavingsMovementMaxOrderByAggregateInput = {
    id?: SortOrder
    accountId?: SortOrder
    tipo?: SortOrder
    valor?: SortOrder
    saldoApos?: SortOrder
    descricao?: SortOrder
    createdAt?: SortOrder
  }

  export type SavingsMovementMinOrderByAggregateInput = {
    id?: SortOrder
    accountId?: SortOrder
    tipo?: SortOrder
    valor?: SortOrder
    saldoApos?: SortOrder
    descricao?: SortOrder
    createdAt?: SortOrder
  }

  export type SavingsMovementSumOrderByAggregateInput = {
    valor?: SortOrder
    saldoApos?: SortOrder
  }

  export type ReferralCountOrderByAggregateInput = {
    id?: SortOrder
    referrerUserId?: SortOrder
    referredUserId?: SortOrder
    codigo?: SortOrder
    canal?: SortOrder
    status?: SortOrder
    recompensa?: SortOrder
    recompensaPaga?: SortOrder
    dataRegisto?: SortOrder
    dataActivacao?: SortOrder
    createdAt?: SortOrder
  }

  export type ReferralAvgOrderByAggregateInput = {
    recompensa?: SortOrder
  }

  export type ReferralMaxOrderByAggregateInput = {
    id?: SortOrder
    referrerUserId?: SortOrder
    referredUserId?: SortOrder
    codigo?: SortOrder
    canal?: SortOrder
    status?: SortOrder
    recompensa?: SortOrder
    recompensaPaga?: SortOrder
    dataRegisto?: SortOrder
    dataActivacao?: SortOrder
    createdAt?: SortOrder
  }

  export type ReferralMinOrderByAggregateInput = {
    id?: SortOrder
    referrerUserId?: SortOrder
    referredUserId?: SortOrder
    codigo?: SortOrder
    canal?: SortOrder
    status?: SortOrder
    recompensa?: SortOrder
    recompensaPaga?: SortOrder
    dataRegisto?: SortOrder
    dataActivacao?: SortOrder
    createdAt?: SortOrder
  }

  export type ReferralSumOrderByAggregateInput = {
    recompensa?: SortOrder
  }

  export type ContentArticleCountOrderByAggregateInput = {
    id?: SortOrder
    slug?: SortOrder
    titulo?: SortOrder
    resumo?: SortOrder
    corpo?: SortOrder
    categoria?: SortOrder
    autor?: SortOrder
    duracaoLeituraMin?: SortOrder
    publicado?: SortOrder
    ordem?: SortOrder
    createdAt?: SortOrder
  }

  export type ContentArticleAvgOrderByAggregateInput = {
    duracaoLeituraMin?: SortOrder
    ordem?: SortOrder
  }

  export type ContentArticleMaxOrderByAggregateInput = {
    id?: SortOrder
    slug?: SortOrder
    titulo?: SortOrder
    resumo?: SortOrder
    corpo?: SortOrder
    categoria?: SortOrder
    autor?: SortOrder
    duracaoLeituraMin?: SortOrder
    publicado?: SortOrder
    ordem?: SortOrder
    createdAt?: SortOrder
  }

  export type ContentArticleMinOrderByAggregateInput = {
    id?: SortOrder
    slug?: SortOrder
    titulo?: SortOrder
    resumo?: SortOrder
    corpo?: SortOrder
    categoria?: SortOrder
    autor?: SortOrder
    duracaoLeituraMin?: SortOrder
    publicado?: SortOrder
    ordem?: SortOrder
    createdAt?: SortOrder
  }

  export type ContentArticleSumOrderByAggregateInput = {
    duracaoLeituraMin?: SortOrder
    ordem?: SortOrder
  }

  export type QuizCountOrderByAggregateInput = {
    id?: SortOrder
    titulo?: SortOrder
    descricao?: SortOrder
    perguntasJson?: SortOrder
    pontos?: SortOrder
    publicado?: SortOrder
    createdAt?: SortOrder
  }

  export type QuizAvgOrderByAggregateInput = {
    pontos?: SortOrder
  }

  export type QuizMaxOrderByAggregateInput = {
    id?: SortOrder
    titulo?: SortOrder
    descricao?: SortOrder
    perguntasJson?: SortOrder
    pontos?: SortOrder
    publicado?: SortOrder
    createdAt?: SortOrder
  }

  export type QuizMinOrderByAggregateInput = {
    id?: SortOrder
    titulo?: SortOrder
    descricao?: SortOrder
    perguntasJson?: SortOrder
    pontos?: SortOrder
    publicado?: SortOrder
    createdAt?: SortOrder
  }

  export type QuizSumOrderByAggregateInput = {
    pontos?: SortOrder
  }

  export type QuizRelationFilter = {
    is?: QuizWhereInput
    isNot?: QuizWhereInput
  }

  export type QuizAttemptCountOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    quizId?: SortOrder
    acertos?: SortOrder
    total?: SortOrder
    pontosGanhos?: SortOrder
    respostasJson?: SortOrder
    createdAt?: SortOrder
  }

  export type QuizAttemptAvgOrderByAggregateInput = {
    acertos?: SortOrder
    total?: SortOrder
    pontosGanhos?: SortOrder
  }

  export type QuizAttemptMaxOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    quizId?: SortOrder
    acertos?: SortOrder
    total?: SortOrder
    pontosGanhos?: SortOrder
    respostasJson?: SortOrder
    createdAt?: SortOrder
  }

  export type QuizAttemptMinOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    quizId?: SortOrder
    acertos?: SortOrder
    total?: SortOrder
    pontosGanhos?: SortOrder
    respostasJson?: SortOrder
    createdAt?: SortOrder
  }

  export type QuizAttemptSumOrderByAggregateInput = {
    acertos?: SortOrder
    total?: SortOrder
    pontosGanhos?: SortOrder
  }

  export type BadgeUserIdTipoCompoundUniqueInput = {
    userId: string
    tipo: string
  }

  export type BadgeCountOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    tipo?: SortOrder
    titulo?: SortOrder
    descricao?: SortOrder
    createdAt?: SortOrder
  }

  export type BadgeMaxOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    tipo?: SortOrder
    titulo?: SortOrder
    descricao?: SortOrder
    createdAt?: SortOrder
  }

  export type BadgeMinOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    tipo?: SortOrder
    titulo?: SortOrder
    descricao?: SortOrder
    createdAt?: SortOrder
  }

  export type ApiCallListRelationFilter = {
    every?: ApiCallWhereInput
    some?: ApiCallWhereInput
    none?: ApiCallWhereInput
  }

  export type ApiCallOrderByRelationAggregateInput = {
    _count?: SortOrder
  }

  export type ApiKeyCountOrderByAggregateInput = {
    id?: SortOrder
    nome?: SortOrder
    partnerNome?: SortOrder
    chave?: SortOrder
    scopes?: SortOrder
    status?: SortOrder
    rateLimit?: SortOrder
    createdAt?: SortOrder
    ultimoUso?: SortOrder
    usos?: SortOrder
  }

  export type ApiKeyAvgOrderByAggregateInput = {
    rateLimit?: SortOrder
    usos?: SortOrder
  }

  export type ApiKeyMaxOrderByAggregateInput = {
    id?: SortOrder
    nome?: SortOrder
    partnerNome?: SortOrder
    chave?: SortOrder
    scopes?: SortOrder
    status?: SortOrder
    rateLimit?: SortOrder
    createdAt?: SortOrder
    ultimoUso?: SortOrder
    usos?: SortOrder
  }

  export type ApiKeyMinOrderByAggregateInput = {
    id?: SortOrder
    nome?: SortOrder
    partnerNome?: SortOrder
    chave?: SortOrder
    scopes?: SortOrder
    status?: SortOrder
    rateLimit?: SortOrder
    createdAt?: SortOrder
    ultimoUso?: SortOrder
    usos?: SortOrder
  }

  export type ApiKeySumOrderByAggregateInput = {
    rateLimit?: SortOrder
    usos?: SortOrder
  }

  export type ApiKeyRelationFilter = {
    is?: ApiKeyWhereInput
    isNot?: ApiKeyWhereInput
  }

  export type ApiCallCountOrderByAggregateInput = {
    id?: SortOrder
    apiKeyId?: SortOrder
    endpoint?: SortOrder
    metodo?: SortOrder
    status?: SortOrder
    duracaoMs?: SortOrder
    ip?: SortOrder
    timestamp?: SortOrder
  }

  export type ApiCallAvgOrderByAggregateInput = {
    status?: SortOrder
    duracaoMs?: SortOrder
  }

  export type ApiCallMaxOrderByAggregateInput = {
    id?: SortOrder
    apiKeyId?: SortOrder
    endpoint?: SortOrder
    metodo?: SortOrder
    status?: SortOrder
    duracaoMs?: SortOrder
    ip?: SortOrder
    timestamp?: SortOrder
  }

  export type ApiCallMinOrderByAggregateInput = {
    id?: SortOrder
    apiKeyId?: SortOrder
    endpoint?: SortOrder
    metodo?: SortOrder
    status?: SortOrder
    duracaoMs?: SortOrder
    ip?: SortOrder
    timestamp?: SortOrder
  }

  export type ApiCallSumOrderByAggregateInput = {
    status?: SortOrder
    duracaoMs?: SortOrder
  }

  export type InsuranceProductCountOrderByAggregateInput = {
    id?: SortOrder
    nome?: SortOrder
    tipo?: SortOrder
    premiumMensal?: SortOrder
    coberturaMax?: SortOrder
    descricao?: SortOrder
    activo?: SortOrder
  }

  export type InsuranceProductAvgOrderByAggregateInput = {
    premiumMensal?: SortOrder
    coberturaMax?: SortOrder
  }

  export type InsuranceProductMaxOrderByAggregateInput = {
    id?: SortOrder
    nome?: SortOrder
    tipo?: SortOrder
    premiumMensal?: SortOrder
    coberturaMax?: SortOrder
    descricao?: SortOrder
    activo?: SortOrder
  }

  export type InsuranceProductMinOrderByAggregateInput = {
    id?: SortOrder
    nome?: SortOrder
    tipo?: SortOrder
    premiumMensal?: SortOrder
    coberturaMax?: SortOrder
    descricao?: SortOrder
    activo?: SortOrder
  }

  export type InsuranceProductSumOrderByAggregateInput = {
    premiumMensal?: SortOrder
    coberturaMax?: SortOrder
  }

  export type InsuranceProductRelationFilter = {
    is?: InsuranceProductWhereInput
    isNot?: InsuranceProductWhereInput
  }

  export type InsurancePolicyCountOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    productId?: SortOrder
    status?: SortOrder
    dataInicio?: SortOrder
    premiumPago?: SortOrder
    proximaCobranca?: SortOrder
  }

  export type InsurancePolicyAvgOrderByAggregateInput = {
    premiumPago?: SortOrder
  }

  export type InsurancePolicyMaxOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    productId?: SortOrder
    status?: SortOrder
    dataInicio?: SortOrder
    premiumPago?: SortOrder
    proximaCobranca?: SortOrder
  }

  export type InsurancePolicyMinOrderByAggregateInput = {
    id?: SortOrder
    userId?: SortOrder
    productId?: SortOrder
    status?: SortOrder
    dataInicio?: SortOrder
    premiumPago?: SortOrder
    proximaCobranca?: SortOrder
  }

  export type InsurancePolicySumOrderByAggregateInput = {
    premiumPago?: SortOrder
  }

  export type CountryCountOrderByAggregateInput = {
    codigo?: SortOrder
    nome?: SortOrder
    moedaPadrao?: SortOrder
    regulador?: SortOrder
    estrutura?: SortOrder
    activo?: SortOrder
  }

  export type CountryMaxOrderByAggregateInput = {
    codigo?: SortOrder
    nome?: SortOrder
    moedaPadrao?: SortOrder
    regulador?: SortOrder
    estrutura?: SortOrder
    activo?: SortOrder
  }

  export type CountryMinOrderByAggregateInput = {
    codigo?: SortOrder
    nome?: SortOrder
    moedaPadrao?: SortOrder
    regulador?: SortOrder
    estrutura?: SortOrder
    activo?: SortOrder
  }

  export type AnalyticsSnapshotCountOrderByAggregateInput = {
    id?: SortOrder
    data?: SortOrder
    utilizadoresActivos?: SortOrder
    gruposActivos?: SortOrder
    contribuicoesPagas?: SortOrder
    volumeMensal?: SortOrder
    defaultsAbertos?: SortOrder
    fundoCobertura?: SortOrder
    createdAt?: SortOrder
  }

  export type AnalyticsSnapshotAvgOrderByAggregateInput = {
    utilizadoresActivos?: SortOrder
    gruposActivos?: SortOrder
    contribuicoesPagas?: SortOrder
    volumeMensal?: SortOrder
    defaultsAbertos?: SortOrder
    fundoCobertura?: SortOrder
  }

  export type AnalyticsSnapshotMaxOrderByAggregateInput = {
    id?: SortOrder
    data?: SortOrder
    utilizadoresActivos?: SortOrder
    gruposActivos?: SortOrder
    contribuicoesPagas?: SortOrder
    volumeMensal?: SortOrder
    defaultsAbertos?: SortOrder
    fundoCobertura?: SortOrder
    createdAt?: SortOrder
  }

  export type AnalyticsSnapshotMinOrderByAggregateInput = {
    id?: SortOrder
    data?: SortOrder
    utilizadoresActivos?: SortOrder
    gruposActivos?: SortOrder
    contribuicoesPagas?: SortOrder
    volumeMensal?: SortOrder
    defaultsAbertos?: SortOrder
    fundoCobertura?: SortOrder
    createdAt?: SortOrder
  }

  export type AnalyticsSnapshotSumOrderByAggregateInput = {
    utilizadoresActivos?: SortOrder
    gruposActivos?: SortOrder
    contribuicoesPagas?: SortOrder
    volumeMensal?: SortOrder
    defaultsAbertos?: SortOrder
    fundoCobertura?: SortOrder
  }

  export type UserCreateNestedOneWithoutReferidosInput = {
    create?: XOR<UserCreateWithoutReferidosInput, UserUncheckedCreateWithoutReferidosInput>
    connectOrCreate?: UserCreateOrConnectWithoutReferidosInput
    connect?: UserWhereUniqueInput
  }

  export type UserCreateNestedManyWithoutReferredByInput = {
    create?: XOR<UserCreateWithoutReferredByInput, UserUncheckedCreateWithoutReferredByInput> | UserCreateWithoutReferredByInput[] | UserUncheckedCreateWithoutReferredByInput[]
    connectOrCreate?: UserCreateOrConnectWithoutReferredByInput | UserCreateOrConnectWithoutReferredByInput[]
    createMany?: UserCreateManyReferredByInputEnvelope
    connect?: UserWhereUniqueInput | UserWhereUniqueInput[]
  }

  export type GroupCreateNestedManyWithoutCriadorInput = {
    create?: XOR<GroupCreateWithoutCriadorInput, GroupUncheckedCreateWithoutCriadorInput> | GroupCreateWithoutCriadorInput[] | GroupUncheckedCreateWithoutCriadorInput[]
    connectOrCreate?: GroupCreateOrConnectWithoutCriadorInput | GroupCreateOrConnectWithoutCriadorInput[]
    createMany?: GroupCreateManyCriadorInputEnvelope
    connect?: GroupWhereUniqueInput | GroupWhereUniqueInput[]
  }

  export type MembershipCreateNestedManyWithoutUserInput = {
    create?: XOR<MembershipCreateWithoutUserInput, MembershipUncheckedCreateWithoutUserInput> | MembershipCreateWithoutUserInput[] | MembershipUncheckedCreateWithoutUserInput[]
    connectOrCreate?: MembershipCreateOrConnectWithoutUserInput | MembershipCreateOrConnectWithoutUserInput[]
    createMany?: MembershipCreateManyUserInputEnvelope
    connect?: MembershipWhereUniqueInput | MembershipWhereUniqueInput[]
  }

  export type ContributionCreateNestedManyWithoutUserInput = {
    create?: XOR<ContributionCreateWithoutUserInput, ContributionUncheckedCreateWithoutUserInput> | ContributionCreateWithoutUserInput[] | ContributionUncheckedCreateWithoutUserInput[]
    connectOrCreate?: ContributionCreateOrConnectWithoutUserInput | ContributionCreateOrConnectWithoutUserInput[]
    createMany?: ContributionCreateManyUserInputEnvelope
    connect?: ContributionWhereUniqueInput | ContributionWhereUniqueInput[]
  }

  export type CashoutCreateNestedManyWithoutBeneficiarioUserInput = {
    create?: XOR<CashoutCreateWithoutBeneficiarioUserInput, CashoutUncheckedCreateWithoutBeneficiarioUserInput> | CashoutCreateWithoutBeneficiarioUserInput[] | CashoutUncheckedCreateWithoutBeneficiarioUserInput[]
    connectOrCreate?: CashoutCreateOrConnectWithoutBeneficiarioUserInput | CashoutCreateOrConnectWithoutBeneficiarioUserInput[]
    createMany?: CashoutCreateManyBeneficiarioUserInputEnvelope
    connect?: CashoutWhereUniqueInput | CashoutWhereUniqueInput[]
  }

  export type LoanCreateNestedManyWithoutUserInput = {
    create?: XOR<LoanCreateWithoutUserInput, LoanUncheckedCreateWithoutUserInput> | LoanCreateWithoutUserInput[] | LoanUncheckedCreateWithoutUserInput[]
    connectOrCreate?: LoanCreateOrConnectWithoutUserInput | LoanCreateOrConnectWithoutUserInput[]
    createMany?: LoanCreateManyUserInputEnvelope
    connect?: LoanWhereUniqueInput | LoanWhereUniqueInput[]
  }

  export type ScoreEventCreateNestedManyWithoutUserInput = {
    create?: XOR<ScoreEventCreateWithoutUserInput, ScoreEventUncheckedCreateWithoutUserInput> | ScoreEventCreateWithoutUserInput[] | ScoreEventUncheckedCreateWithoutUserInput[]
    connectOrCreate?: ScoreEventCreateOrConnectWithoutUserInput | ScoreEventCreateOrConnectWithoutUserInput[]
    createMany?: ScoreEventCreateManyUserInputEnvelope
    connect?: ScoreEventWhereUniqueInput | ScoreEventWhereUniqueInput[]
  }

  export type ReintegrationCreateNestedManyWithoutUserInput = {
    create?: XOR<ReintegrationCreateWithoutUserInput, ReintegrationUncheckedCreateWithoutUserInput> | ReintegrationCreateWithoutUserInput[] | ReintegrationUncheckedCreateWithoutUserInput[]
    connectOrCreate?: ReintegrationCreateOrConnectWithoutUserInput | ReintegrationCreateOrConnectWithoutUserInput[]
    createMany?: ReintegrationCreateManyUserInputEnvelope
    connect?: ReintegrationWhereUniqueInput | ReintegrationWhereUniqueInput[]
  }

  export type OtpCreateNestedManyWithoutUserInput = {
    create?: XOR<OtpCreateWithoutUserInput, OtpUncheckedCreateWithoutUserInput> | OtpCreateWithoutUserInput[] | OtpUncheckedCreateWithoutUserInput[]
    connectOrCreate?: OtpCreateOrConnectWithoutUserInput | OtpCreateOrConnectWithoutUserInput[]
    createMany?: OtpCreateManyUserInputEnvelope
    connect?: OtpWhereUniqueInput | OtpWhereUniqueInput[]
  }

  export type SessionCreateNestedManyWithoutUserInput = {
    create?: XOR<SessionCreateWithoutUserInput, SessionUncheckedCreateWithoutUserInput> | SessionCreateWithoutUserInput[] | SessionUncheckedCreateWithoutUserInput[]
    connectOrCreate?: SessionCreateOrConnectWithoutUserInput | SessionCreateOrConnectWithoutUserInput[]
    createMany?: SessionCreateManyUserInputEnvelope
    connect?: SessionWhereUniqueInput | SessionWhereUniqueInput[]
  }

  export type NotificationCreateNestedManyWithoutUserInput = {
    create?: XOR<NotificationCreateWithoutUserInput, NotificationUncheckedCreateWithoutUserInput> | NotificationCreateWithoutUserInput[] | NotificationUncheckedCreateWithoutUserInput[]
    connectOrCreate?: NotificationCreateOrConnectWithoutUserInput | NotificationCreateOrConnectWithoutUserInput[]
    createMany?: NotificationCreateManyUserInputEnvelope
    connect?: NotificationWhereUniqueInput | NotificationWhereUniqueInput[]
  }

  export type CoverageDecisionCreateNestedManyWithoutDecisorUserInput = {
    create?: XOR<CoverageDecisionCreateWithoutDecisorUserInput, CoverageDecisionUncheckedCreateWithoutDecisorUserInput> | CoverageDecisionCreateWithoutDecisorUserInput[] | CoverageDecisionUncheckedCreateWithoutDecisorUserInput[]
    connectOrCreate?: CoverageDecisionCreateOrConnectWithoutDecisorUserInput | CoverageDecisionCreateOrConnectWithoutDecisorUserInput[]
    createMany?: CoverageDecisionCreateManyDecisorUserInputEnvelope
    connect?: CoverageDecisionWhereUniqueInput | CoverageDecisionWhereUniqueInput[]
  }

  export type InviteCreateNestedManyWithoutConvidadoPorInput = {
    create?: XOR<InviteCreateWithoutConvidadoPorInput, InviteUncheckedCreateWithoutConvidadoPorInput> | InviteCreateWithoutConvidadoPorInput[] | InviteUncheckedCreateWithoutConvidadoPorInput[]
    connectOrCreate?: InviteCreateOrConnectWithoutConvidadoPorInput | InviteCreateOrConnectWithoutConvidadoPorInput[]
    createMany?: InviteCreateManyConvidadoPorInputEnvelope
    connect?: InviteWhereUniqueInput | InviteWhereUniqueInput[]
  }

  export type FeeConfigurationCreateNestedManyWithoutCriadoPorInput = {
    create?: XOR<FeeConfigurationCreateWithoutCriadoPorInput, FeeConfigurationUncheckedCreateWithoutCriadoPorInput> | FeeConfigurationCreateWithoutCriadoPorInput[] | FeeConfigurationUncheckedCreateWithoutCriadoPorInput[]
    connectOrCreate?: FeeConfigurationCreateOrConnectWithoutCriadoPorInput | FeeConfigurationCreateOrConnectWithoutCriadoPorInput[]
    createMany?: FeeConfigurationCreateManyCriadoPorInputEnvelope
    connect?: FeeConfigurationWhereUniqueInput | FeeConfigurationWhereUniqueInput[]
  }

  export type AuditLogCreateNestedManyWithoutUserInput = {
    create?: XOR<AuditLogCreateWithoutUserInput, AuditLogUncheckedCreateWithoutUserInput> | AuditLogCreateWithoutUserInput[] | AuditLogUncheckedCreateWithoutUserInput[]
    connectOrCreate?: AuditLogCreateOrConnectWithoutUserInput | AuditLogCreateOrConnectWithoutUserInput[]
    createMany?: AuditLogCreateManyUserInputEnvelope
    connect?: AuditLogWhereUniqueInput | AuditLogWhereUniqueInput[]
  }

  export type CreditApplicationCreateNestedManyWithoutUserInput = {
    create?: XOR<CreditApplicationCreateWithoutUserInput, CreditApplicationUncheckedCreateWithoutUserInput> | CreditApplicationCreateWithoutUserInput[] | CreditApplicationUncheckedCreateWithoutUserInput[]
    connectOrCreate?: CreditApplicationCreateOrConnectWithoutUserInput | CreditApplicationCreateOrConnectWithoutUserInput[]
    createMany?: CreditApplicationCreateManyUserInputEnvelope
    connect?: CreditApplicationWhereUniqueInput | CreditApplicationWhereUniqueInput[]
  }

  export type SavingsAccountCreateNestedManyWithoutUserInput = {
    create?: XOR<SavingsAccountCreateWithoutUserInput, SavingsAccountUncheckedCreateWithoutUserInput> | SavingsAccountCreateWithoutUserInput[] | SavingsAccountUncheckedCreateWithoutUserInput[]
    connectOrCreate?: SavingsAccountCreateOrConnectWithoutUserInput | SavingsAccountCreateOrConnectWithoutUserInput[]
    createMany?: SavingsAccountCreateManyUserInputEnvelope
    connect?: SavingsAccountWhereUniqueInput | SavingsAccountWhereUniqueInput[]
  }

  export type ReferralCreateNestedManyWithoutReferrerInput = {
    create?: XOR<ReferralCreateWithoutReferrerInput, ReferralUncheckedCreateWithoutReferrerInput> | ReferralCreateWithoutReferrerInput[] | ReferralUncheckedCreateWithoutReferrerInput[]
    connectOrCreate?: ReferralCreateOrConnectWithoutReferrerInput | ReferralCreateOrConnectWithoutReferrerInput[]
    createMany?: ReferralCreateManyReferrerInputEnvelope
    connect?: ReferralWhereUniqueInput | ReferralWhereUniqueInput[]
  }

  export type ReferralCreateNestedManyWithoutReferredUserInput = {
    create?: XOR<ReferralCreateWithoutReferredUserInput, ReferralUncheckedCreateWithoutReferredUserInput> | ReferralCreateWithoutReferredUserInput[] | ReferralUncheckedCreateWithoutReferredUserInput[]
    connectOrCreate?: ReferralCreateOrConnectWithoutReferredUserInput | ReferralCreateOrConnectWithoutReferredUserInput[]
    createMany?: ReferralCreateManyReferredUserInputEnvelope
    connect?: ReferralWhereUniqueInput | ReferralWhereUniqueInput[]
  }

  export type QuizAttemptCreateNestedManyWithoutUserInput = {
    create?: XOR<QuizAttemptCreateWithoutUserInput, QuizAttemptUncheckedCreateWithoutUserInput> | QuizAttemptCreateWithoutUserInput[] | QuizAttemptUncheckedCreateWithoutUserInput[]
    connectOrCreate?: QuizAttemptCreateOrConnectWithoutUserInput | QuizAttemptCreateOrConnectWithoutUserInput[]
    createMany?: QuizAttemptCreateManyUserInputEnvelope
    connect?: QuizAttemptWhereUniqueInput | QuizAttemptWhereUniqueInput[]
  }

  export type BadgeCreateNestedManyWithoutUserInput = {
    create?: XOR<BadgeCreateWithoutUserInput, BadgeUncheckedCreateWithoutUserInput> | BadgeCreateWithoutUserInput[] | BadgeUncheckedCreateWithoutUserInput[]
    connectOrCreate?: BadgeCreateOrConnectWithoutUserInput | BadgeCreateOrConnectWithoutUserInput[]
    createMany?: BadgeCreateManyUserInputEnvelope
    connect?: BadgeWhereUniqueInput | BadgeWhereUniqueInput[]
  }

  export type InsurancePolicyCreateNestedManyWithoutUserInput = {
    create?: XOR<InsurancePolicyCreateWithoutUserInput, InsurancePolicyUncheckedCreateWithoutUserInput> | InsurancePolicyCreateWithoutUserInput[] | InsurancePolicyUncheckedCreateWithoutUserInput[]
    connectOrCreate?: InsurancePolicyCreateOrConnectWithoutUserInput | InsurancePolicyCreateOrConnectWithoutUserInput[]
    createMany?: InsurancePolicyCreateManyUserInputEnvelope
    connect?: InsurancePolicyWhereUniqueInput | InsurancePolicyWhereUniqueInput[]
  }

  export type UserUncheckedCreateNestedManyWithoutReferredByInput = {
    create?: XOR<UserCreateWithoutReferredByInput, UserUncheckedCreateWithoutReferredByInput> | UserCreateWithoutReferredByInput[] | UserUncheckedCreateWithoutReferredByInput[]
    connectOrCreate?: UserCreateOrConnectWithoutReferredByInput | UserCreateOrConnectWithoutReferredByInput[]
    createMany?: UserCreateManyReferredByInputEnvelope
    connect?: UserWhereUniqueInput | UserWhereUniqueInput[]
  }

  export type GroupUncheckedCreateNestedManyWithoutCriadorInput = {
    create?: XOR<GroupCreateWithoutCriadorInput, GroupUncheckedCreateWithoutCriadorInput> | GroupCreateWithoutCriadorInput[] | GroupUncheckedCreateWithoutCriadorInput[]
    connectOrCreate?: GroupCreateOrConnectWithoutCriadorInput | GroupCreateOrConnectWithoutCriadorInput[]
    createMany?: GroupCreateManyCriadorInputEnvelope
    connect?: GroupWhereUniqueInput | GroupWhereUniqueInput[]
  }

  export type MembershipUncheckedCreateNestedManyWithoutUserInput = {
    create?: XOR<MembershipCreateWithoutUserInput, MembershipUncheckedCreateWithoutUserInput> | MembershipCreateWithoutUserInput[] | MembershipUncheckedCreateWithoutUserInput[]
    connectOrCreate?: MembershipCreateOrConnectWithoutUserInput | MembershipCreateOrConnectWithoutUserInput[]
    createMany?: MembershipCreateManyUserInputEnvelope
    connect?: MembershipWhereUniqueInput | MembershipWhereUniqueInput[]
  }

  export type ContributionUncheckedCreateNestedManyWithoutUserInput = {
    create?: XOR<ContributionCreateWithoutUserInput, ContributionUncheckedCreateWithoutUserInput> | ContributionCreateWithoutUserInput[] | ContributionUncheckedCreateWithoutUserInput[]
    connectOrCreate?: ContributionCreateOrConnectWithoutUserInput | ContributionCreateOrConnectWithoutUserInput[]
    createMany?: ContributionCreateManyUserInputEnvelope
    connect?: ContributionWhereUniqueInput | ContributionWhereUniqueInput[]
  }

  export type CashoutUncheckedCreateNestedManyWithoutBeneficiarioUserInput = {
    create?: XOR<CashoutCreateWithoutBeneficiarioUserInput, CashoutUncheckedCreateWithoutBeneficiarioUserInput> | CashoutCreateWithoutBeneficiarioUserInput[] | CashoutUncheckedCreateWithoutBeneficiarioUserInput[]
    connectOrCreate?: CashoutCreateOrConnectWithoutBeneficiarioUserInput | CashoutCreateOrConnectWithoutBeneficiarioUserInput[]
    createMany?: CashoutCreateManyBeneficiarioUserInputEnvelope
    connect?: CashoutWhereUniqueInput | CashoutWhereUniqueInput[]
  }

  export type LoanUncheckedCreateNestedManyWithoutUserInput = {
    create?: XOR<LoanCreateWithoutUserInput, LoanUncheckedCreateWithoutUserInput> | LoanCreateWithoutUserInput[] | LoanUncheckedCreateWithoutUserInput[]
    connectOrCreate?: LoanCreateOrConnectWithoutUserInput | LoanCreateOrConnectWithoutUserInput[]
    createMany?: LoanCreateManyUserInputEnvelope
    connect?: LoanWhereUniqueInput | LoanWhereUniqueInput[]
  }

  export type ScoreEventUncheckedCreateNestedManyWithoutUserInput = {
    create?: XOR<ScoreEventCreateWithoutUserInput, ScoreEventUncheckedCreateWithoutUserInput> | ScoreEventCreateWithoutUserInput[] | ScoreEventUncheckedCreateWithoutUserInput[]
    connectOrCreate?: ScoreEventCreateOrConnectWithoutUserInput | ScoreEventCreateOrConnectWithoutUserInput[]
    createMany?: ScoreEventCreateManyUserInputEnvelope
    connect?: ScoreEventWhereUniqueInput | ScoreEventWhereUniqueInput[]
  }

  export type ReintegrationUncheckedCreateNestedManyWithoutUserInput = {
    create?: XOR<ReintegrationCreateWithoutUserInput, ReintegrationUncheckedCreateWithoutUserInput> | ReintegrationCreateWithoutUserInput[] | ReintegrationUncheckedCreateWithoutUserInput[]
    connectOrCreate?: ReintegrationCreateOrConnectWithoutUserInput | ReintegrationCreateOrConnectWithoutUserInput[]
    createMany?: ReintegrationCreateManyUserInputEnvelope
    connect?: ReintegrationWhereUniqueInput | ReintegrationWhereUniqueInput[]
  }

  export type OtpUncheckedCreateNestedManyWithoutUserInput = {
    create?: XOR<OtpCreateWithoutUserInput, OtpUncheckedCreateWithoutUserInput> | OtpCreateWithoutUserInput[] | OtpUncheckedCreateWithoutUserInput[]
    connectOrCreate?: OtpCreateOrConnectWithoutUserInput | OtpCreateOrConnectWithoutUserInput[]
    createMany?: OtpCreateManyUserInputEnvelope
    connect?: OtpWhereUniqueInput | OtpWhereUniqueInput[]
  }

  export type SessionUncheckedCreateNestedManyWithoutUserInput = {
    create?: XOR<SessionCreateWithoutUserInput, SessionUncheckedCreateWithoutUserInput> | SessionCreateWithoutUserInput[] | SessionUncheckedCreateWithoutUserInput[]
    connectOrCreate?: SessionCreateOrConnectWithoutUserInput | SessionCreateOrConnectWithoutUserInput[]
    createMany?: SessionCreateManyUserInputEnvelope
    connect?: SessionWhereUniqueInput | SessionWhereUniqueInput[]
  }

  export type NotificationUncheckedCreateNestedManyWithoutUserInput = {
    create?: XOR<NotificationCreateWithoutUserInput, NotificationUncheckedCreateWithoutUserInput> | NotificationCreateWithoutUserInput[] | NotificationUncheckedCreateWithoutUserInput[]
    connectOrCreate?: NotificationCreateOrConnectWithoutUserInput | NotificationCreateOrConnectWithoutUserInput[]
    createMany?: NotificationCreateManyUserInputEnvelope
    connect?: NotificationWhereUniqueInput | NotificationWhereUniqueInput[]
  }

  export type CoverageDecisionUncheckedCreateNestedManyWithoutDecisorUserInput = {
    create?: XOR<CoverageDecisionCreateWithoutDecisorUserInput, CoverageDecisionUncheckedCreateWithoutDecisorUserInput> | CoverageDecisionCreateWithoutDecisorUserInput[] | CoverageDecisionUncheckedCreateWithoutDecisorUserInput[]
    connectOrCreate?: CoverageDecisionCreateOrConnectWithoutDecisorUserInput | CoverageDecisionCreateOrConnectWithoutDecisorUserInput[]
    createMany?: CoverageDecisionCreateManyDecisorUserInputEnvelope
    connect?: CoverageDecisionWhereUniqueInput | CoverageDecisionWhereUniqueInput[]
  }

  export type InviteUncheckedCreateNestedManyWithoutConvidadoPorInput = {
    create?: XOR<InviteCreateWithoutConvidadoPorInput, InviteUncheckedCreateWithoutConvidadoPorInput> | InviteCreateWithoutConvidadoPorInput[] | InviteUncheckedCreateWithoutConvidadoPorInput[]
    connectOrCreate?: InviteCreateOrConnectWithoutConvidadoPorInput | InviteCreateOrConnectWithoutConvidadoPorInput[]
    createMany?: InviteCreateManyConvidadoPorInputEnvelope
    connect?: InviteWhereUniqueInput | InviteWhereUniqueInput[]
  }

  export type FeeConfigurationUncheckedCreateNestedManyWithoutCriadoPorInput = {
    create?: XOR<FeeConfigurationCreateWithoutCriadoPorInput, FeeConfigurationUncheckedCreateWithoutCriadoPorInput> | FeeConfigurationCreateWithoutCriadoPorInput[] | FeeConfigurationUncheckedCreateWithoutCriadoPorInput[]
    connectOrCreate?: FeeConfigurationCreateOrConnectWithoutCriadoPorInput | FeeConfigurationCreateOrConnectWithoutCriadoPorInput[]
    createMany?: FeeConfigurationCreateManyCriadoPorInputEnvelope
    connect?: FeeConfigurationWhereUniqueInput | FeeConfigurationWhereUniqueInput[]
  }

  export type AuditLogUncheckedCreateNestedManyWithoutUserInput = {
    create?: XOR<AuditLogCreateWithoutUserInput, AuditLogUncheckedCreateWithoutUserInput> | AuditLogCreateWithoutUserInput[] | AuditLogUncheckedCreateWithoutUserInput[]
    connectOrCreate?: AuditLogCreateOrConnectWithoutUserInput | AuditLogCreateOrConnectWithoutUserInput[]
    createMany?: AuditLogCreateManyUserInputEnvelope
    connect?: AuditLogWhereUniqueInput | AuditLogWhereUniqueInput[]
  }

  export type CreditApplicationUncheckedCreateNestedManyWithoutUserInput = {
    create?: XOR<CreditApplicationCreateWithoutUserInput, CreditApplicationUncheckedCreateWithoutUserInput> | CreditApplicationCreateWithoutUserInput[] | CreditApplicationUncheckedCreateWithoutUserInput[]
    connectOrCreate?: CreditApplicationCreateOrConnectWithoutUserInput | CreditApplicationCreateOrConnectWithoutUserInput[]
    createMany?: CreditApplicationCreateManyUserInputEnvelope
    connect?: CreditApplicationWhereUniqueInput | CreditApplicationWhereUniqueInput[]
  }

  export type SavingsAccountUncheckedCreateNestedManyWithoutUserInput = {
    create?: XOR<SavingsAccountCreateWithoutUserInput, SavingsAccountUncheckedCreateWithoutUserInput> | SavingsAccountCreateWithoutUserInput[] | SavingsAccountUncheckedCreateWithoutUserInput[]
    connectOrCreate?: SavingsAccountCreateOrConnectWithoutUserInput | SavingsAccountCreateOrConnectWithoutUserInput[]
    createMany?: SavingsAccountCreateManyUserInputEnvelope
    connect?: SavingsAccountWhereUniqueInput | SavingsAccountWhereUniqueInput[]
  }

  export type ReferralUncheckedCreateNestedManyWithoutReferrerInput = {
    create?: XOR<ReferralCreateWithoutReferrerInput, ReferralUncheckedCreateWithoutReferrerInput> | ReferralCreateWithoutReferrerInput[] | ReferralUncheckedCreateWithoutReferrerInput[]
    connectOrCreate?: ReferralCreateOrConnectWithoutReferrerInput | ReferralCreateOrConnectWithoutReferrerInput[]
    createMany?: ReferralCreateManyReferrerInputEnvelope
    connect?: ReferralWhereUniqueInput | ReferralWhereUniqueInput[]
  }

  export type ReferralUncheckedCreateNestedManyWithoutReferredUserInput = {
    create?: XOR<ReferralCreateWithoutReferredUserInput, ReferralUncheckedCreateWithoutReferredUserInput> | ReferralCreateWithoutReferredUserInput[] | ReferralUncheckedCreateWithoutReferredUserInput[]
    connectOrCreate?: ReferralCreateOrConnectWithoutReferredUserInput | ReferralCreateOrConnectWithoutReferredUserInput[]
    createMany?: ReferralCreateManyReferredUserInputEnvelope
    connect?: ReferralWhereUniqueInput | ReferralWhereUniqueInput[]
  }

  export type QuizAttemptUncheckedCreateNestedManyWithoutUserInput = {
    create?: XOR<QuizAttemptCreateWithoutUserInput, QuizAttemptUncheckedCreateWithoutUserInput> | QuizAttemptCreateWithoutUserInput[] | QuizAttemptUncheckedCreateWithoutUserInput[]
    connectOrCreate?: QuizAttemptCreateOrConnectWithoutUserInput | QuizAttemptCreateOrConnectWithoutUserInput[]
    createMany?: QuizAttemptCreateManyUserInputEnvelope
    connect?: QuizAttemptWhereUniqueInput | QuizAttemptWhereUniqueInput[]
  }

  export type BadgeUncheckedCreateNestedManyWithoutUserInput = {
    create?: XOR<BadgeCreateWithoutUserInput, BadgeUncheckedCreateWithoutUserInput> | BadgeCreateWithoutUserInput[] | BadgeUncheckedCreateWithoutUserInput[]
    connectOrCreate?: BadgeCreateOrConnectWithoutUserInput | BadgeCreateOrConnectWithoutUserInput[]
    createMany?: BadgeCreateManyUserInputEnvelope
    connect?: BadgeWhereUniqueInput | BadgeWhereUniqueInput[]
  }

  export type InsurancePolicyUncheckedCreateNestedManyWithoutUserInput = {
    create?: XOR<InsurancePolicyCreateWithoutUserInput, InsurancePolicyUncheckedCreateWithoutUserInput> | InsurancePolicyCreateWithoutUserInput[] | InsurancePolicyUncheckedCreateWithoutUserInput[]
    connectOrCreate?: InsurancePolicyCreateOrConnectWithoutUserInput | InsurancePolicyCreateOrConnectWithoutUserInput[]
    createMany?: InsurancePolicyCreateManyUserInputEnvelope
    connect?: InsurancePolicyWhereUniqueInput | InsurancePolicyWhereUniqueInput[]
  }

  export type StringFieldUpdateOperationsInput = {
    set?: string
  }

  export type NullableStringFieldUpdateOperationsInput = {
    set?: string | null
  }

  export type NullableDateTimeFieldUpdateOperationsInput = {
    set?: Date | string | null
  }

  export type IntFieldUpdateOperationsInput = {
    set?: number
    increment?: number
    decrement?: number
    multiply?: number
    divide?: number
  }

  export type DateTimeFieldUpdateOperationsInput = {
    set?: Date | string
  }

  export type UserUpdateOneWithoutReferidosNestedInput = {
    create?: XOR<UserCreateWithoutReferidosInput, UserUncheckedCreateWithoutReferidosInput>
    connectOrCreate?: UserCreateOrConnectWithoutReferidosInput
    upsert?: UserUpsertWithoutReferidosInput
    disconnect?: UserWhereInput | boolean
    delete?: UserWhereInput | boolean
    connect?: UserWhereUniqueInput
    update?: XOR<XOR<UserUpdateToOneWithWhereWithoutReferidosInput, UserUpdateWithoutReferidosInput>, UserUncheckedUpdateWithoutReferidosInput>
  }

  export type UserUpdateManyWithoutReferredByNestedInput = {
    create?: XOR<UserCreateWithoutReferredByInput, UserUncheckedCreateWithoutReferredByInput> | UserCreateWithoutReferredByInput[] | UserUncheckedCreateWithoutReferredByInput[]
    connectOrCreate?: UserCreateOrConnectWithoutReferredByInput | UserCreateOrConnectWithoutReferredByInput[]
    upsert?: UserUpsertWithWhereUniqueWithoutReferredByInput | UserUpsertWithWhereUniqueWithoutReferredByInput[]
    createMany?: UserCreateManyReferredByInputEnvelope
    set?: UserWhereUniqueInput | UserWhereUniqueInput[]
    disconnect?: UserWhereUniqueInput | UserWhereUniqueInput[]
    delete?: UserWhereUniqueInput | UserWhereUniqueInput[]
    connect?: UserWhereUniqueInput | UserWhereUniqueInput[]
    update?: UserUpdateWithWhereUniqueWithoutReferredByInput | UserUpdateWithWhereUniqueWithoutReferredByInput[]
    updateMany?: UserUpdateManyWithWhereWithoutReferredByInput | UserUpdateManyWithWhereWithoutReferredByInput[]
    deleteMany?: UserScalarWhereInput | UserScalarWhereInput[]
  }

  export type GroupUpdateManyWithoutCriadorNestedInput = {
    create?: XOR<GroupCreateWithoutCriadorInput, GroupUncheckedCreateWithoutCriadorInput> | GroupCreateWithoutCriadorInput[] | GroupUncheckedCreateWithoutCriadorInput[]
    connectOrCreate?: GroupCreateOrConnectWithoutCriadorInput | GroupCreateOrConnectWithoutCriadorInput[]
    upsert?: GroupUpsertWithWhereUniqueWithoutCriadorInput | GroupUpsertWithWhereUniqueWithoutCriadorInput[]
    createMany?: GroupCreateManyCriadorInputEnvelope
    set?: GroupWhereUniqueInput | GroupWhereUniqueInput[]
    disconnect?: GroupWhereUniqueInput | GroupWhereUniqueInput[]
    delete?: GroupWhereUniqueInput | GroupWhereUniqueInput[]
    connect?: GroupWhereUniqueInput | GroupWhereUniqueInput[]
    update?: GroupUpdateWithWhereUniqueWithoutCriadorInput | GroupUpdateWithWhereUniqueWithoutCriadorInput[]
    updateMany?: GroupUpdateManyWithWhereWithoutCriadorInput | GroupUpdateManyWithWhereWithoutCriadorInput[]
    deleteMany?: GroupScalarWhereInput | GroupScalarWhereInput[]
  }

  export type MembershipUpdateManyWithoutUserNestedInput = {
    create?: XOR<MembershipCreateWithoutUserInput, MembershipUncheckedCreateWithoutUserInput> | MembershipCreateWithoutUserInput[] | MembershipUncheckedCreateWithoutUserInput[]
    connectOrCreate?: MembershipCreateOrConnectWithoutUserInput | MembershipCreateOrConnectWithoutUserInput[]
    upsert?: MembershipUpsertWithWhereUniqueWithoutUserInput | MembershipUpsertWithWhereUniqueWithoutUserInput[]
    createMany?: MembershipCreateManyUserInputEnvelope
    set?: MembershipWhereUniqueInput | MembershipWhereUniqueInput[]
    disconnect?: MembershipWhereUniqueInput | MembershipWhereUniqueInput[]
    delete?: MembershipWhereUniqueInput | MembershipWhereUniqueInput[]
    connect?: MembershipWhereUniqueInput | MembershipWhereUniqueInput[]
    update?: MembershipUpdateWithWhereUniqueWithoutUserInput | MembershipUpdateWithWhereUniqueWithoutUserInput[]
    updateMany?: MembershipUpdateManyWithWhereWithoutUserInput | MembershipUpdateManyWithWhereWithoutUserInput[]
    deleteMany?: MembershipScalarWhereInput | MembershipScalarWhereInput[]
  }

  export type ContributionUpdateManyWithoutUserNestedInput = {
    create?: XOR<ContributionCreateWithoutUserInput, ContributionUncheckedCreateWithoutUserInput> | ContributionCreateWithoutUserInput[] | ContributionUncheckedCreateWithoutUserInput[]
    connectOrCreate?: ContributionCreateOrConnectWithoutUserInput | ContributionCreateOrConnectWithoutUserInput[]
    upsert?: ContributionUpsertWithWhereUniqueWithoutUserInput | ContributionUpsertWithWhereUniqueWithoutUserInput[]
    createMany?: ContributionCreateManyUserInputEnvelope
    set?: ContributionWhereUniqueInput | ContributionWhereUniqueInput[]
    disconnect?: ContributionWhereUniqueInput | ContributionWhereUniqueInput[]
    delete?: ContributionWhereUniqueInput | ContributionWhereUniqueInput[]
    connect?: ContributionWhereUniqueInput | ContributionWhereUniqueInput[]
    update?: ContributionUpdateWithWhereUniqueWithoutUserInput | ContributionUpdateWithWhereUniqueWithoutUserInput[]
    updateMany?: ContributionUpdateManyWithWhereWithoutUserInput | ContributionUpdateManyWithWhereWithoutUserInput[]
    deleteMany?: ContributionScalarWhereInput | ContributionScalarWhereInput[]
  }

  export type CashoutUpdateManyWithoutBeneficiarioUserNestedInput = {
    create?: XOR<CashoutCreateWithoutBeneficiarioUserInput, CashoutUncheckedCreateWithoutBeneficiarioUserInput> | CashoutCreateWithoutBeneficiarioUserInput[] | CashoutUncheckedCreateWithoutBeneficiarioUserInput[]
    connectOrCreate?: CashoutCreateOrConnectWithoutBeneficiarioUserInput | CashoutCreateOrConnectWithoutBeneficiarioUserInput[]
    upsert?: CashoutUpsertWithWhereUniqueWithoutBeneficiarioUserInput | CashoutUpsertWithWhereUniqueWithoutBeneficiarioUserInput[]
    createMany?: CashoutCreateManyBeneficiarioUserInputEnvelope
    set?: CashoutWhereUniqueInput | CashoutWhereUniqueInput[]
    disconnect?: CashoutWhereUniqueInput | CashoutWhereUniqueInput[]
    delete?: CashoutWhereUniqueInput | CashoutWhereUniqueInput[]
    connect?: CashoutWhereUniqueInput | CashoutWhereUniqueInput[]
    update?: CashoutUpdateWithWhereUniqueWithoutBeneficiarioUserInput | CashoutUpdateWithWhereUniqueWithoutBeneficiarioUserInput[]
    updateMany?: CashoutUpdateManyWithWhereWithoutBeneficiarioUserInput | CashoutUpdateManyWithWhereWithoutBeneficiarioUserInput[]
    deleteMany?: CashoutScalarWhereInput | CashoutScalarWhereInput[]
  }

  export type LoanUpdateManyWithoutUserNestedInput = {
    create?: XOR<LoanCreateWithoutUserInput, LoanUncheckedCreateWithoutUserInput> | LoanCreateWithoutUserInput[] | LoanUncheckedCreateWithoutUserInput[]
    connectOrCreate?: LoanCreateOrConnectWithoutUserInput | LoanCreateOrConnectWithoutUserInput[]
    upsert?: LoanUpsertWithWhereUniqueWithoutUserInput | LoanUpsertWithWhereUniqueWithoutUserInput[]
    createMany?: LoanCreateManyUserInputEnvelope
    set?: LoanWhereUniqueInput | LoanWhereUniqueInput[]
    disconnect?: LoanWhereUniqueInput | LoanWhereUniqueInput[]
    delete?: LoanWhereUniqueInput | LoanWhereUniqueInput[]
    connect?: LoanWhereUniqueInput | LoanWhereUniqueInput[]
    update?: LoanUpdateWithWhereUniqueWithoutUserInput | LoanUpdateWithWhereUniqueWithoutUserInput[]
    updateMany?: LoanUpdateManyWithWhereWithoutUserInput | LoanUpdateManyWithWhereWithoutUserInput[]
    deleteMany?: LoanScalarWhereInput | LoanScalarWhereInput[]
  }

  export type ScoreEventUpdateManyWithoutUserNestedInput = {
    create?: XOR<ScoreEventCreateWithoutUserInput, ScoreEventUncheckedCreateWithoutUserInput> | ScoreEventCreateWithoutUserInput[] | ScoreEventUncheckedCreateWithoutUserInput[]
    connectOrCreate?: ScoreEventCreateOrConnectWithoutUserInput | ScoreEventCreateOrConnectWithoutUserInput[]
    upsert?: ScoreEventUpsertWithWhereUniqueWithoutUserInput | ScoreEventUpsertWithWhereUniqueWithoutUserInput[]
    createMany?: ScoreEventCreateManyUserInputEnvelope
    set?: ScoreEventWhereUniqueInput | ScoreEventWhereUniqueInput[]
    disconnect?: ScoreEventWhereUniqueInput | ScoreEventWhereUniqueInput[]
    delete?: ScoreEventWhereUniqueInput | ScoreEventWhereUniqueInput[]
    connect?: ScoreEventWhereUniqueInput | ScoreEventWhereUniqueInput[]
    update?: ScoreEventUpdateWithWhereUniqueWithoutUserInput | ScoreEventUpdateWithWhereUniqueWithoutUserInput[]
    updateMany?: ScoreEventUpdateManyWithWhereWithoutUserInput | ScoreEventUpdateManyWithWhereWithoutUserInput[]
    deleteMany?: ScoreEventScalarWhereInput | ScoreEventScalarWhereInput[]
  }

  export type ReintegrationUpdateManyWithoutUserNestedInput = {
    create?: XOR<ReintegrationCreateWithoutUserInput, ReintegrationUncheckedCreateWithoutUserInput> | ReintegrationCreateWithoutUserInput[] | ReintegrationUncheckedCreateWithoutUserInput[]
    connectOrCreate?: ReintegrationCreateOrConnectWithoutUserInput | ReintegrationCreateOrConnectWithoutUserInput[]
    upsert?: ReintegrationUpsertWithWhereUniqueWithoutUserInput | ReintegrationUpsertWithWhereUniqueWithoutUserInput[]
    createMany?: ReintegrationCreateManyUserInputEnvelope
    set?: ReintegrationWhereUniqueInput | ReintegrationWhereUniqueInput[]
    disconnect?: ReintegrationWhereUniqueInput | ReintegrationWhereUniqueInput[]
    delete?: ReintegrationWhereUniqueInput | ReintegrationWhereUniqueInput[]
    connect?: ReintegrationWhereUniqueInput | ReintegrationWhereUniqueInput[]
    update?: ReintegrationUpdateWithWhereUniqueWithoutUserInput | ReintegrationUpdateWithWhereUniqueWithoutUserInput[]
    updateMany?: ReintegrationUpdateManyWithWhereWithoutUserInput | ReintegrationUpdateManyWithWhereWithoutUserInput[]
    deleteMany?: ReintegrationScalarWhereInput | ReintegrationScalarWhereInput[]
  }

  export type OtpUpdateManyWithoutUserNestedInput = {
    create?: XOR<OtpCreateWithoutUserInput, OtpUncheckedCreateWithoutUserInput> | OtpCreateWithoutUserInput[] | OtpUncheckedCreateWithoutUserInput[]
    connectOrCreate?: OtpCreateOrConnectWithoutUserInput | OtpCreateOrConnectWithoutUserInput[]
    upsert?: OtpUpsertWithWhereUniqueWithoutUserInput | OtpUpsertWithWhereUniqueWithoutUserInput[]
    createMany?: OtpCreateManyUserInputEnvelope
    set?: OtpWhereUniqueInput | OtpWhereUniqueInput[]
    disconnect?: OtpWhereUniqueInput | OtpWhereUniqueInput[]
    delete?: OtpWhereUniqueInput | OtpWhereUniqueInput[]
    connect?: OtpWhereUniqueInput | OtpWhereUniqueInput[]
    update?: OtpUpdateWithWhereUniqueWithoutUserInput | OtpUpdateWithWhereUniqueWithoutUserInput[]
    updateMany?: OtpUpdateManyWithWhereWithoutUserInput | OtpUpdateManyWithWhereWithoutUserInput[]
    deleteMany?: OtpScalarWhereInput | OtpScalarWhereInput[]
  }

  export type SessionUpdateManyWithoutUserNestedInput = {
    create?: XOR<SessionCreateWithoutUserInput, SessionUncheckedCreateWithoutUserInput> | SessionCreateWithoutUserInput[] | SessionUncheckedCreateWithoutUserInput[]
    connectOrCreate?: SessionCreateOrConnectWithoutUserInput | SessionCreateOrConnectWithoutUserInput[]
    upsert?: SessionUpsertWithWhereUniqueWithoutUserInput | SessionUpsertWithWhereUniqueWithoutUserInput[]
    createMany?: SessionCreateManyUserInputEnvelope
    set?: SessionWhereUniqueInput | SessionWhereUniqueInput[]
    disconnect?: SessionWhereUniqueInput | SessionWhereUniqueInput[]
    delete?: SessionWhereUniqueInput | SessionWhereUniqueInput[]
    connect?: SessionWhereUniqueInput | SessionWhereUniqueInput[]
    update?: SessionUpdateWithWhereUniqueWithoutUserInput | SessionUpdateWithWhereUniqueWithoutUserInput[]
    updateMany?: SessionUpdateManyWithWhereWithoutUserInput | SessionUpdateManyWithWhereWithoutUserInput[]
    deleteMany?: SessionScalarWhereInput | SessionScalarWhereInput[]
  }

  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 CoverageDecisionUpdateManyWithoutDecisorUserNestedInput = {
    create?: XOR<CoverageDecisionCreateWithoutDecisorUserInput, CoverageDecisionUncheckedCreateWithoutDecisorUserInput> | CoverageDecisionCreateWithoutDecisorUserInput[] | CoverageDecisionUncheckedCreateWithoutDecisorUserInput[]
    connectOrCreate?: CoverageDecisionCreateOrConnectWithoutDecisorUserInput | CoverageDecisionCreateOrConnectWithoutDecisorUserInput[]
    upsert?: CoverageDecisionUpsertWithWhereUniqueWithoutDecisorUserInput | CoverageDecisionUpsertWithWhereUniqueWithoutDecisorUserInput[]
    createMany?: CoverageDecisionCreateManyDecisorUserInputEnvelope
    set?: CoverageDecisionWhereUniqueInput | CoverageDecisionWhereUniqueInput[]
    disconnect?: CoverageDecisionWhereUniqueInput | CoverageDecisionWhereUniqueInput[]
    delete?: CoverageDecisionWhereUniqueInput | CoverageDecisionWhereUniqueInput[]
    connect?: CoverageDecisionWhereUniqueInput | CoverageDecisionWhereUniqueInput[]
    update?: CoverageDecisionUpdateWithWhereUniqueWithoutDecisorUserInput | CoverageDecisionUpdateWithWhereUniqueWithoutDecisorUserInput[]
    updateMany?: CoverageDecisionUpdateManyWithWhereWithoutDecisorUserInput | CoverageDecisionUpdateManyWithWhereWithoutDecisorUserInput[]
    deleteMany?: CoverageDecisionScalarWhereInput | CoverageDecisionScalarWhereInput[]
  }

  export type InviteUpdateManyWithoutConvidadoPorNestedInput = {
    create?: XOR<InviteCreateWithoutConvidadoPorInput, InviteUncheckedCreateWithoutConvidadoPorInput> | InviteCreateWithoutConvidadoPorInput[] | InviteUncheckedCreateWithoutConvidadoPorInput[]
    connectOrCreate?: InviteCreateOrConnectWithoutConvidadoPorInput | InviteCreateOrConnectWithoutConvidadoPorInput[]
    upsert?: InviteUpsertWithWhereUniqueWithoutConvidadoPorInput | InviteUpsertWithWhereUniqueWithoutConvidadoPorInput[]
    createMany?: InviteCreateManyConvidadoPorInputEnvelope
    set?: InviteWhereUniqueInput | InviteWhereUniqueInput[]
    disconnect?: InviteWhereUniqueInput | InviteWhereUniqueInput[]
    delete?: InviteWhereUniqueInput | InviteWhereUniqueInput[]
    connect?: InviteWhereUniqueInput | InviteWhereUniqueInput[]
    update?: InviteUpdateWithWhereUniqueWithoutConvidadoPorInput | InviteUpdateWithWhereUniqueWithoutConvidadoPorInput[]
    updateMany?: InviteUpdateManyWithWhereWithoutConvidadoPorInput | InviteUpdateManyWithWhereWithoutConvidadoPorInput[]
    deleteMany?: InviteScalarWhereInput | InviteScalarWhereInput[]
  }

  export type FeeConfigurationUpdateManyWithoutCriadoPorNestedInput = {
    create?: XOR<FeeConfigurationCreateWithoutCriadoPorInput, FeeConfigurationUncheckedCreateWithoutCriadoPorInput> | FeeConfigurationCreateWithoutCriadoPorInput[] | FeeConfigurationUncheckedCreateWithoutCriadoPorInput[]
    connectOrCreate?: FeeConfigurationCreateOrConnectWithoutCriadoPorInput | FeeConfigurationCreateOrConnectWithoutCriadoPorInput[]
    upsert?: FeeConfigurationUpsertWithWhereUniqueWithoutCriadoPorInput | FeeConfigurationUpsertWithWhereUniqueWithoutCriadoPorInput[]
    createMany?: FeeConfigurationCreateManyCriadoPorInputEnvelope
    set?: FeeConfigurationWhereUniqueInput | FeeConfigurationWhereUniqueInput[]
    disconnect?: FeeConfigurationWhereUniqueInput | FeeConfigurationWhereUniqueInput[]
    delete?: FeeConfigurationWhereUniqueInput | FeeConfigurationWhereUniqueInput[]
    connect?: FeeConfigurationWhereUniqueInput | FeeConfigurationWhereUniqueInput[]
    update?: FeeConfigurationUpdateWithWhereUniqueWithoutCriadoPorInput | FeeConfigurationUpdateWithWhereUniqueWithoutCriadoPorInput[]
    updateMany?: FeeConfigurationUpdateManyWithWhereWithoutCriadoPorInput | FeeConfigurationUpdateManyWithWhereWithoutCriadoPorInput[]
    deleteMany?: FeeConfigurationScalarWhereInput | FeeConfigurationScalarWhereInput[]
  }

  export type AuditLogUpdateManyWithoutUserNestedInput = {
    create?: XOR<AuditLogCreateWithoutUserInput, AuditLogUncheckedCreateWithoutUserInput> | AuditLogCreateWithoutUserInput[] | AuditLogUncheckedCreateWithoutUserInput[]
    connectOrCreate?: AuditLogCreateOrConnectWithoutUserInput | AuditLogCreateOrConnectWithoutUserInput[]
    upsert?: AuditLogUpsertWithWhereUniqueWithoutUserInput | AuditLogUpsertWithWhereUniqueWithoutUserInput[]
    createMany?: AuditLogCreateManyUserInputEnvelope
    set?: AuditLogWhereUniqueInput | AuditLogWhereUniqueInput[]
    disconnect?: AuditLogWhereUniqueInput | AuditLogWhereUniqueInput[]
    delete?: AuditLogWhereUniqueInput | AuditLogWhereUniqueInput[]
    connect?: AuditLogWhereUniqueInput | AuditLogWhereUniqueInput[]
    update?: AuditLogUpdateWithWhereUniqueWithoutUserInput | AuditLogUpdateWithWhereUniqueWithoutUserInput[]
    updateMany?: AuditLogUpdateManyWithWhereWithoutUserInput | AuditLogUpdateManyWithWhereWithoutUserInput[]
    deleteMany?: AuditLogScalarWhereInput | AuditLogScalarWhereInput[]
  }

  export type CreditApplicationUpdateManyWithoutUserNestedInput = {
    create?: XOR<CreditApplicationCreateWithoutUserInput, CreditApplicationUncheckedCreateWithoutUserInput> | CreditApplicationCreateWithoutUserInput[] | CreditApplicationUncheckedCreateWithoutUserInput[]
    connectOrCreate?: CreditApplicationCreateOrConnectWithoutUserInput | CreditApplicationCreateOrConnectWithoutUserInput[]
    upsert?: CreditApplicationUpsertWithWhereUniqueWithoutUserInput | CreditApplicationUpsertWithWhereUniqueWithoutUserInput[]
    createMany?: CreditApplicationCreateManyUserInputEnvelope
    set?: CreditApplicationWhereUniqueInput | CreditApplicationWhereUniqueInput[]
    disconnect?: CreditApplicationWhereUniqueInput | CreditApplicationWhereUniqueInput[]
    delete?: CreditApplicationWhereUniqueInput | CreditApplicationWhereUniqueInput[]
    connect?: CreditApplicationWhereUniqueInput | CreditApplicationWhereUniqueInput[]
    update?: CreditApplicationUpdateWithWhereUniqueWithoutUserInput | CreditApplicationUpdateWithWhereUniqueWithoutUserInput[]
    updateMany?: CreditApplicationUpdateManyWithWhereWithoutUserInput | CreditApplicationUpdateManyWithWhereWithoutUserInput[]
    deleteMany?: CreditApplicationScalarWhereInput | CreditApplicationScalarWhereInput[]
  }

  export type SavingsAccountUpdateManyWithoutUserNestedInput = {
    create?: XOR<SavingsAccountCreateWithoutUserInput, SavingsAccountUncheckedCreateWithoutUserInput> | SavingsAccountCreateWithoutUserInput[] | SavingsAccountUncheckedCreateWithoutUserInput[]
    connectOrCreate?: SavingsAccountCreateOrConnectWithoutUserInput | SavingsAccountCreateOrConnectWithoutUserInput[]
    upsert?: SavingsAccountUpsertWithWhereUniqueWithoutUserInput | SavingsAccountUpsertWithWhereUniqueWithoutUserInput[]
    createMany?: SavingsAccountCreateManyUserInputEnvelope
    set?: SavingsAccountWhereUniqueInput | SavingsAccountWhereUniqueInput[]
    disconnect?: SavingsAccountWhereUniqueInput | SavingsAccountWhereUniqueInput[]
    delete?: SavingsAccountWhereUniqueInput | SavingsAccountWhereUniqueInput[]
    connect?: SavingsAccountWhereUniqueInput | SavingsAccountWhereUniqueInput[]
    update?: SavingsAccountUpdateWithWhereUniqueWithoutUserInput | SavingsAccountUpdateWithWhereUniqueWithoutUserInput[]
    updateMany?: SavingsAccountUpdateManyWithWhereWithoutUserInput | SavingsAccountUpdateManyWithWhereWithoutUserInput[]
    deleteMany?: SavingsAccountScalarWhereInput | SavingsAccountScalarWhereInput[]
  }

  export type ReferralUpdateManyWithoutReferrerNestedInput = {
    create?: XOR<ReferralCreateWithoutReferrerInput, ReferralUncheckedCreateWithoutReferrerInput> | ReferralCreateWithoutReferrerInput[] | ReferralUncheckedCreateWithoutReferrerInput[]
    connectOrCreate?: ReferralCreateOrConnectWithoutReferrerInput | ReferralCreateOrConnectWithoutReferrerInput[]
    upsert?: ReferralUpsertWithWhereUniqueWithoutReferrerInput | ReferralUpsertWithWhereUniqueWithoutReferrerInput[]
    createMany?: ReferralCreateManyReferrerInputEnvelope
    set?: ReferralWhereUniqueInput | ReferralWhereUniqueInput[]
    disconnect?: ReferralWhereUniqueInput | ReferralWhereUniqueInput[]
    delete?: ReferralWhereUniqueInput | ReferralWhereUniqueInput[]
    connect?: ReferralWhereUniqueInput | ReferralWhereUniqueInput[]
    update?: ReferralUpdateWithWhereUniqueWithoutReferrerInput | ReferralUpdateWithWhereUniqueWithoutReferrerInput[]
    updateMany?: ReferralUpdateManyWithWhereWithoutReferrerInput | ReferralUpdateManyWithWhereWithoutReferrerInput[]
    deleteMany?: ReferralScalarWhereInput | ReferralScalarWhereInput[]
  }

  export type ReferralUpdateManyWithoutReferredUserNestedInput = {
    create?: XOR<ReferralCreateWithoutReferredUserInput, ReferralUncheckedCreateWithoutReferredUserInput> | ReferralCreateWithoutReferredUserInput[] | ReferralUncheckedCreateWithoutReferredUserInput[]
    connectOrCreate?: ReferralCreateOrConnectWithoutReferredUserInput | ReferralCreateOrConnectWithoutReferredUserInput[]
    upsert?: ReferralUpsertWithWhereUniqueWithoutReferredUserInput | ReferralUpsertWithWhereUniqueWithoutReferredUserInput[]
    createMany?: ReferralCreateManyReferredUserInputEnvelope
    set?: ReferralWhereUniqueInput | ReferralWhereUniqueInput[]
    disconnect?: ReferralWhereUniqueInput | ReferralWhereUniqueInput[]
    delete?: ReferralWhereUniqueInput | ReferralWhereUniqueInput[]
    connect?: ReferralWhereUniqueInput | ReferralWhereUniqueInput[]
    update?: ReferralUpdateWithWhereUniqueWithoutReferredUserInput | ReferralUpdateWithWhereUniqueWithoutReferredUserInput[]
    updateMany?: ReferralUpdateManyWithWhereWithoutReferredUserInput | ReferralUpdateManyWithWhereWithoutReferredUserInput[]
    deleteMany?: ReferralScalarWhereInput | ReferralScalarWhereInput[]
  }

  export type QuizAttemptUpdateManyWithoutUserNestedInput = {
    create?: XOR<QuizAttemptCreateWithoutUserInput, QuizAttemptUncheckedCreateWithoutUserInput> | QuizAttemptCreateWithoutUserInput[] | QuizAttemptUncheckedCreateWithoutUserInput[]
    connectOrCreate?: QuizAttemptCreateOrConnectWithoutUserInput | QuizAttemptCreateOrConnectWithoutUserInput[]
    upsert?: QuizAttemptUpsertWithWhereUniqueWithoutUserInput | QuizAttemptUpsertWithWhereUniqueWithoutUserInput[]
    createMany?: QuizAttemptCreateManyUserInputEnvelope
    set?: QuizAttemptWhereUniqueInput | QuizAttemptWhereUniqueInput[]
    disconnect?: QuizAttemptWhereUniqueInput | QuizAttemptWhereUniqueInput[]
    delete?: QuizAttemptWhereUniqueInput | QuizAttemptWhereUniqueInput[]
    connect?: QuizAttemptWhereUniqueInput | QuizAttemptWhereUniqueInput[]
    update?: QuizAttemptUpdateWithWhereUniqueWithoutUserInput | QuizAttemptUpdateWithWhereUniqueWithoutUserInput[]
    updateMany?: QuizAttemptUpdateManyWithWhereWithoutUserInput | QuizAttemptUpdateManyWithWhereWithoutUserInput[]
    deleteMany?: QuizAttemptScalarWhereInput | QuizAttemptScalarWhereInput[]
  }

  export type BadgeUpdateManyWithoutUserNestedInput = {
    create?: XOR<BadgeCreateWithoutUserInput, BadgeUncheckedCreateWithoutUserInput> | BadgeCreateWithoutUserInput[] | BadgeUncheckedCreateWithoutUserInput[]
    connectOrCreate?: BadgeCreateOrConnectWithoutUserInput | BadgeCreateOrConnectWithoutUserInput[]
    upsert?: BadgeUpsertWithWhereUniqueWithoutUserInput | BadgeUpsertWithWhereUniqueWithoutUserInput[]
    createMany?: BadgeCreateManyUserInputEnvelope
    set?: BadgeWhereUniqueInput | BadgeWhereUniqueInput[]
    disconnect?: BadgeWhereUniqueInput | BadgeWhereUniqueInput[]
    delete?: BadgeWhereUniqueInput | BadgeWhereUniqueInput[]
    connect?: BadgeWhereUniqueInput | BadgeWhereUniqueInput[]
    update?: BadgeUpdateWithWhereUniqueWithoutUserInput | BadgeUpdateWithWhereUniqueWithoutUserInput[]
    updateMany?: BadgeUpdateManyWithWhereWithoutUserInput | BadgeUpdateManyWithWhereWithoutUserInput[]
    deleteMany?: BadgeScalarWhereInput | BadgeScalarWhereInput[]
  }

  export type InsurancePolicyUpdateManyWithoutUserNestedInput = {
    create?: XOR<InsurancePolicyCreateWithoutUserInput, InsurancePolicyUncheckedCreateWithoutUserInput> | InsurancePolicyCreateWithoutUserInput[] | InsurancePolicyUncheckedCreateWithoutUserInput[]
    connectOrCreate?: InsurancePolicyCreateOrConnectWithoutUserInput | InsurancePolicyCreateOrConnectWithoutUserInput[]
    upsert?: InsurancePolicyUpsertWithWhereUniqueWithoutUserInput | InsurancePolicyUpsertWithWhereUniqueWithoutUserInput[]
    createMany?: InsurancePolicyCreateManyUserInputEnvelope
    set?: InsurancePolicyWhereUniqueInput | InsurancePolicyWhereUniqueInput[]
    disconnect?: InsurancePolicyWhereUniqueInput | InsurancePolicyWhereUniqueInput[]
    delete?: InsurancePolicyWhereUniqueInput | InsurancePolicyWhereUniqueInput[]
    connect?: InsurancePolicyWhereUniqueInput | InsurancePolicyWhereUniqueInput[]
    update?: InsurancePolicyUpdateWithWhereUniqueWithoutUserInput | InsurancePolicyUpdateWithWhereUniqueWithoutUserInput[]
    updateMany?: InsurancePolicyUpdateManyWithWhereWithoutUserInput | InsurancePolicyUpdateManyWithWhereWithoutUserInput[]
    deleteMany?: InsurancePolicyScalarWhereInput | InsurancePolicyScalarWhereInput[]
  }

  export type UserUncheckedUpdateManyWithoutReferredByNestedInput = {
    create?: XOR<UserCreateWithoutReferredByInput, UserUncheckedCreateWithoutReferredByInput> | UserCreateWithoutReferredByInput[] | UserUncheckedCreateWithoutReferredByInput[]
    connectOrCreate?: UserCreateOrConnectWithoutReferredByInput | UserCreateOrConnectWithoutReferredByInput[]
    upsert?: UserUpsertWithWhereUniqueWithoutReferredByInput | UserUpsertWithWhereUniqueWithoutReferredByInput[]
    createMany?: UserCreateManyReferredByInputEnvelope
    set?: UserWhereUniqueInput | UserWhereUniqueInput[]
    disconnect?: UserWhereUniqueInput | UserWhereUniqueInput[]
    delete?: UserWhereUniqueInput | UserWhereUniqueInput[]
    connect?: UserWhereUniqueInput | UserWhereUniqueInput[]
    update?: UserUpdateWithWhereUniqueWithoutReferredByInput | UserUpdateWithWhereUniqueWithoutReferredByInput[]
    updateMany?: UserUpdateManyWithWhereWithoutReferredByInput | UserUpdateManyWithWhereWithoutReferredByInput[]
    deleteMany?: UserScalarWhereInput | UserScalarWhereInput[]
  }

  export type GroupUncheckedUpdateManyWithoutCriadorNestedInput = {
    create?: XOR<GroupCreateWithoutCriadorInput, GroupUncheckedCreateWithoutCriadorInput> | GroupCreateWithoutCriadorInput[] | GroupUncheckedCreateWithoutCriadorInput[]
    connectOrCreate?: GroupCreateOrConnectWithoutCriadorInput | GroupCreateOrConnectWithoutCriadorInput[]
    upsert?: GroupUpsertWithWhereUniqueWithoutCriadorInput | GroupUpsertWithWhereUniqueWithoutCriadorInput[]
    createMany?: GroupCreateManyCriadorInputEnvelope
    set?: GroupWhereUniqueInput | GroupWhereUniqueInput[]
    disconnect?: GroupWhereUniqueInput | GroupWhereUniqueInput[]
    delete?: GroupWhereUniqueInput | GroupWhereUniqueInput[]
    connect?: GroupWhereUniqueInput | GroupWhereUniqueInput[]
    update?: GroupUpdateWithWhereUniqueWithoutCriadorInput | GroupUpdateWithWhereUniqueWithoutCriadorInput[]
    updateMany?: GroupUpdateManyWithWhereWithoutCriadorInput | GroupUpdateManyWithWhereWithoutCriadorInput[]
    deleteMany?: GroupScalarWhereInput | GroupScalarWhereInput[]
  }

  export type MembershipUncheckedUpdateManyWithoutUserNestedInput = {
    create?: XOR<MembershipCreateWithoutUserInput, MembershipUncheckedCreateWithoutUserInput> | MembershipCreateWithoutUserInput[] | MembershipUncheckedCreateWithoutUserInput[]
    connectOrCreate?: MembershipCreateOrConnectWithoutUserInput | MembershipCreateOrConnectWithoutUserInput[]
    upsert?: MembershipUpsertWithWhereUniqueWithoutUserInput | MembershipUpsertWithWhereUniqueWithoutUserInput[]
    createMany?: MembershipCreateManyUserInputEnvelope
    set?: MembershipWhereUniqueInput | MembershipWhereUniqueInput[]
    disconnect?: MembershipWhereUniqueInput | MembershipWhereUniqueInput[]
    delete?: MembershipWhereUniqueInput | MembershipWhereUniqueInput[]
    connect?: MembershipWhereUniqueInput | MembershipWhereUniqueInput[]
    update?: MembershipUpdateWithWhereUniqueWithoutUserInput | MembershipUpdateWithWhereUniqueWithoutUserInput[]
    updateMany?: MembershipUpdateManyWithWhereWithoutUserInput | MembershipUpdateManyWithWhereWithoutUserInput[]
    deleteMany?: MembershipScalarWhereInput | MembershipScalarWhereInput[]
  }

  export type ContributionUncheckedUpdateManyWithoutUserNestedInput = {
    create?: XOR<ContributionCreateWithoutUserInput, ContributionUncheckedCreateWithoutUserInput> | ContributionCreateWithoutUserInput[] | ContributionUncheckedCreateWithoutUserInput[]
    connectOrCreate?: ContributionCreateOrConnectWithoutUserInput | ContributionCreateOrConnectWithoutUserInput[]
    upsert?: ContributionUpsertWithWhereUniqueWithoutUserInput | ContributionUpsertWithWhereUniqueWithoutUserInput[]
    createMany?: ContributionCreateManyUserInputEnvelope
    set?: ContributionWhereUniqueInput | ContributionWhereUniqueInput[]
    disconnect?: ContributionWhereUniqueInput | ContributionWhereUniqueInput[]
    delete?: ContributionWhereUniqueInput | ContributionWhereUniqueInput[]
    connect?: ContributionWhereUniqueInput | ContributionWhereUniqueInput[]
    update?: ContributionUpdateWithWhereUniqueWithoutUserInput | ContributionUpdateWithWhereUniqueWithoutUserInput[]
    updateMany?: ContributionUpdateManyWithWhereWithoutUserInput | ContributionUpdateManyWithWhereWithoutUserInput[]
    deleteMany?: ContributionScalarWhereInput | ContributionScalarWhereInput[]
  }

  export type CashoutUncheckedUpdateManyWithoutBeneficiarioUserNestedInput = {
    create?: XOR<CashoutCreateWithoutBeneficiarioUserInput, CashoutUncheckedCreateWithoutBeneficiarioUserInput> | CashoutCreateWithoutBeneficiarioUserInput[] | CashoutUncheckedCreateWithoutBeneficiarioUserInput[]
    connectOrCreate?: CashoutCreateOrConnectWithoutBeneficiarioUserInput | CashoutCreateOrConnectWithoutBeneficiarioUserInput[]
    upsert?: CashoutUpsertWithWhereUniqueWithoutBeneficiarioUserInput | CashoutUpsertWithWhereUniqueWithoutBeneficiarioUserInput[]
    createMany?: CashoutCreateManyBeneficiarioUserInputEnvelope
    set?: CashoutWhereUniqueInput | CashoutWhereUniqueInput[]
    disconnect?: CashoutWhereUniqueInput | CashoutWhereUniqueInput[]
    delete?: CashoutWhereUniqueInput | CashoutWhereUniqueInput[]
    connect?: CashoutWhereUniqueInput | CashoutWhereUniqueInput[]
    update?: CashoutUpdateWithWhereUniqueWithoutBeneficiarioUserInput | CashoutUpdateWithWhereUniqueWithoutBeneficiarioUserInput[]
    updateMany?: CashoutUpdateManyWithWhereWithoutBeneficiarioUserInput | CashoutUpdateManyWithWhereWithoutBeneficiarioUserInput[]
    deleteMany?: CashoutScalarWhereInput | CashoutScalarWhereInput[]
  }

  export type LoanUncheckedUpdateManyWithoutUserNestedInput = {
    create?: XOR<LoanCreateWithoutUserInput, LoanUncheckedCreateWithoutUserInput> | LoanCreateWithoutUserInput[] | LoanUncheckedCreateWithoutUserInput[]
    connectOrCreate?: LoanCreateOrConnectWithoutUserInput | LoanCreateOrConnectWithoutUserInput[]
    upsert?: LoanUpsertWithWhereUniqueWithoutUserInput | LoanUpsertWithWhereUniqueWithoutUserInput[]
    createMany?: LoanCreateManyUserInputEnvelope
    set?: LoanWhereUniqueInput | LoanWhereUniqueInput[]
    disconnect?: LoanWhereUniqueInput | LoanWhereUniqueInput[]
    delete?: LoanWhereUniqueInput | LoanWhereUniqueInput[]
    connect?: LoanWhereUniqueInput | LoanWhereUniqueInput[]
    update?: LoanUpdateWithWhereUniqueWithoutUserInput | LoanUpdateWithWhereUniqueWithoutUserInput[]
    updateMany?: LoanUpdateManyWithWhereWithoutUserInput | LoanUpdateManyWithWhereWithoutUserInput[]
    deleteMany?: LoanScalarWhereInput | LoanScalarWhereInput[]
  }

  export type ScoreEventUncheckedUpdateManyWithoutUserNestedInput = {
    create?: XOR<ScoreEventCreateWithoutUserInput, ScoreEventUncheckedCreateWithoutUserInput> | ScoreEventCreateWithoutUserInput[] | ScoreEventUncheckedCreateWithoutUserInput[]
    connectOrCreate?: ScoreEventCreateOrConnectWithoutUserInput | ScoreEventCreateOrConnectWithoutUserInput[]
    upsert?: ScoreEventUpsertWithWhereUniqueWithoutUserInput | ScoreEventUpsertWithWhereUniqueWithoutUserInput[]
    createMany?: ScoreEventCreateManyUserInputEnvelope
    set?: ScoreEventWhereUniqueInput | ScoreEventWhereUniqueInput[]
    disconnect?: ScoreEventWhereUniqueInput | ScoreEventWhereUniqueInput[]
    delete?: ScoreEventWhereUniqueInput | ScoreEventWhereUniqueInput[]
    connect?: ScoreEventWhereUniqueInput | ScoreEventWhereUniqueInput[]
    update?: ScoreEventUpdateWithWhereUniqueWithoutUserInput | ScoreEventUpdateWithWhereUniqueWithoutUserInput[]
    updateMany?: ScoreEventUpdateManyWithWhereWithoutUserInput | ScoreEventUpdateManyWithWhereWithoutUserInput[]
    deleteMany?: ScoreEventScalarWhereInput | ScoreEventScalarWhereInput[]
  }

  export type ReintegrationUncheckedUpdateManyWithoutUserNestedInput = {
    create?: XOR<ReintegrationCreateWithoutUserInput, ReintegrationUncheckedCreateWithoutUserInput> | ReintegrationCreateWithoutUserInput[] | ReintegrationUncheckedCreateWithoutUserInput[]
    connectOrCreate?: ReintegrationCreateOrConnectWithoutUserInput | ReintegrationCreateOrConnectWithoutUserInput[]
    upsert?: ReintegrationUpsertWithWhereUniqueWithoutUserInput | ReintegrationUpsertWithWhereUniqueWithoutUserInput[]
    createMany?: ReintegrationCreateManyUserInputEnvelope
    set?: ReintegrationWhereUniqueInput | ReintegrationWhereUniqueInput[]
    disconnect?: ReintegrationWhereUniqueInput | ReintegrationWhereUniqueInput[]
    delete?: ReintegrationWhereUniqueInput | ReintegrationWhereUniqueInput[]
    connect?: ReintegrationWhereUniqueInput | ReintegrationWhereUniqueInput[]
    update?: ReintegrationUpdateWithWhereUniqueWithoutUserInput | ReintegrationUpdateWithWhereUniqueWithoutUserInput[]
    updateMany?: ReintegrationUpdateManyWithWhereWithoutUserInput | ReintegrationUpdateManyWithWhereWithoutUserInput[]
    deleteMany?: ReintegrationScalarWhereInput | ReintegrationScalarWhereInput[]
  }

  export type OtpUncheckedUpdateManyWithoutUserNestedInput = {
    create?: XOR<OtpCreateWithoutUserInput, OtpUncheckedCreateWithoutUserInput> | OtpCreateWithoutUserInput[] | OtpUncheckedCreateWithoutUserInput[]
    connectOrCreate?: OtpCreateOrConnectWithoutUserInput | OtpCreateOrConnectWithoutUserInput[]
    upsert?: OtpUpsertWithWhereUniqueWithoutUserInput | OtpUpsertWithWhereUniqueWithoutUserInput[]
    createMany?: OtpCreateManyUserInputEnvelope
    set?: OtpWhereUniqueInput | OtpWhereUniqueInput[]
    disconnect?: OtpWhereUniqueInput | OtpWhereUniqueInput[]
    delete?: OtpWhereUniqueInput | OtpWhereUniqueInput[]
    connect?: OtpWhereUniqueInput | OtpWhereUniqueInput[]
    update?: OtpUpdateWithWhereUniqueWithoutUserInput | OtpUpdateWithWhereUniqueWithoutUserInput[]
    updateMany?: OtpUpdateManyWithWhereWithoutUserInput | OtpUpdateManyWithWhereWithoutUserInput[]
    deleteMany?: OtpScalarWhereInput | OtpScalarWhereInput[]
  }

  export type SessionUncheckedUpdateManyWithoutUserNestedInput = {
    create?: XOR<SessionCreateWithoutUserInput, SessionUncheckedCreateWithoutUserInput> | SessionCreateWithoutUserInput[] | SessionUncheckedCreateWithoutUserInput[]
    connectOrCreate?: SessionCreateOrConnectWithoutUserInput | SessionCreateOrConnectWithoutUserInput[]
    upsert?: SessionUpsertWithWhereUniqueWithoutUserInput | SessionUpsertWithWhereUniqueWithoutUserInput[]
    createMany?: SessionCreateManyUserInputEnvelope
    set?: SessionWhereUniqueInput | SessionWhereUniqueInput[]
    disconnect?: SessionWhereUniqueInput | SessionWhereUniqueInput[]
    delete?: SessionWhereUniqueInput | SessionWhereUniqueInput[]
    connect?: SessionWhereUniqueInput | SessionWhereUniqueInput[]
    update?: SessionUpdateWithWhereUniqueWithoutUserInput | SessionUpdateWithWhereUniqueWithoutUserInput[]
    updateMany?: SessionUpdateManyWithWhereWithoutUserInput | SessionUpdateManyWithWhereWithoutUserInput[]
    deleteMany?: SessionScalarWhereInput | SessionScalarWhereInput[]
  }

  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 CoverageDecisionUncheckedUpdateManyWithoutDecisorUserNestedInput = {
    create?: XOR<CoverageDecisionCreateWithoutDecisorUserInput, CoverageDecisionUncheckedCreateWithoutDecisorUserInput> | CoverageDecisionCreateWithoutDecisorUserInput[] | CoverageDecisionUncheckedCreateWithoutDecisorUserInput[]
    connectOrCreate?: CoverageDecisionCreateOrConnectWithoutDecisorUserInput | CoverageDecisionCreateOrConnectWithoutDecisorUserInput[]
    upsert?: CoverageDecisionUpsertWithWhereUniqueWithoutDecisorUserInput | CoverageDecisionUpsertWithWhereUniqueWithoutDecisorUserInput[]
    createMany?: CoverageDecisionCreateManyDecisorUserInputEnvelope
    set?: CoverageDecisionWhereUniqueInput | CoverageDecisionWhereUniqueInput[]
    disconnect?: CoverageDecisionWhereUniqueInput | CoverageDecisionWhereUniqueInput[]
    delete?: CoverageDecisionWhereUniqueInput | CoverageDecisionWhereUniqueInput[]
    connect?: CoverageDecisionWhereUniqueInput | CoverageDecisionWhereUniqueInput[]
    update?: CoverageDecisionUpdateWithWhereUniqueWithoutDecisorUserInput | CoverageDecisionUpdateWithWhereUniqueWithoutDecisorUserInput[]
    updateMany?: CoverageDecisionUpdateManyWithWhereWithoutDecisorUserInput | CoverageDecisionUpdateManyWithWhereWithoutDecisorUserInput[]
    deleteMany?: CoverageDecisionScalarWhereInput | CoverageDecisionScalarWhereInput[]
  }

  export type InviteUncheckedUpdateManyWithoutConvidadoPorNestedInput = {
    create?: XOR<InviteCreateWithoutConvidadoPorInput, InviteUncheckedCreateWithoutConvidadoPorInput> | InviteCreateWithoutConvidadoPorInput[] | InviteUncheckedCreateWithoutConvidadoPorInput[]
    connectOrCreate?: InviteCreateOrConnectWithoutConvidadoPorInput | InviteCreateOrConnectWithoutConvidadoPorInput[]
    upsert?: InviteUpsertWithWhereUniqueWithoutConvidadoPorInput | InviteUpsertWithWhereUniqueWithoutConvidadoPorInput[]
    createMany?: InviteCreateManyConvidadoPorInputEnvelope
    set?: InviteWhereUniqueInput | InviteWhereUniqueInput[]
    disconnect?: InviteWhereUniqueInput | InviteWhereUniqueInput[]
    delete?: InviteWhereUniqueInput | InviteWhereUniqueInput[]
    connect?: InviteWhereUniqueInput | InviteWhereUniqueInput[]
    update?: InviteUpdateWithWhereUniqueWithoutConvidadoPorInput | InviteUpdateWithWhereUniqueWithoutConvidadoPorInput[]
    updateMany?: InviteUpdateManyWithWhereWithoutConvidadoPorInput | InviteUpdateManyWithWhereWithoutConvidadoPorInput[]
    deleteMany?: InviteScalarWhereInput | InviteScalarWhereInput[]
  }

  export type FeeConfigurationUncheckedUpdateManyWithoutCriadoPorNestedInput = {
    create?: XOR<FeeConfigurationCreateWithoutCriadoPorInput, FeeConfigurationUncheckedCreateWithoutCriadoPorInput> | FeeConfigurationCreateWithoutCriadoPorInput[] | FeeConfigurationUncheckedCreateWithoutCriadoPorInput[]
    connectOrCreate?: FeeConfigurationCreateOrConnectWithoutCriadoPorInput | FeeConfigurationCreateOrConnectWithoutCriadoPorInput[]
    upsert?: FeeConfigurationUpsertWithWhereUniqueWithoutCriadoPorInput | FeeConfigurationUpsertWithWhereUniqueWithoutCriadoPorInput[]
    createMany?: FeeConfigurationCreateManyCriadoPorInputEnvelope
    set?: FeeConfigurationWhereUniqueInput | FeeConfigurationWhereUniqueInput[]
    disconnect?: FeeConfigurationWhereUniqueInput | FeeConfigurationWhereUniqueInput[]
    delete?: FeeConfigurationWhereUniqueInput | FeeConfigurationWhereUniqueInput[]
    connect?: FeeConfigurationWhereUniqueInput | FeeConfigurationWhereUniqueInput[]
    update?: FeeConfigurationUpdateWithWhereUniqueWithoutCriadoPorInput | FeeConfigurationUpdateWithWhereUniqueWithoutCriadoPorInput[]
    updateMany?: FeeConfigurationUpdateManyWithWhereWithoutCriadoPorInput | FeeConfigurationUpdateManyWithWhereWithoutCriadoPorInput[]
    deleteMany?: FeeConfigurationScalarWhereInput | FeeConfigurationScalarWhereInput[]
  }

  export type AuditLogUncheckedUpdateManyWithoutUserNestedInput = {
    create?: XOR<AuditLogCreateWithoutUserInput, AuditLogUncheckedCreateWithoutUserInput> | AuditLogCreateWithoutUserInput[] | AuditLogUncheckedCreateWithoutUserInput[]
    connectOrCreate?: AuditLogCreateOrConnectWithoutUserInput | AuditLogCreateOrConnectWithoutUserInput[]
    upsert?: AuditLogUpsertWithWhereUniqueWithoutUserInput | AuditLogUpsertWithWhereUniqueWithoutUserInput[]
    createMany?: AuditLogCreateManyUserInputEnvelope
    set?: AuditLogWhereUniqueInput | AuditLogWhereUniqueInput[]
    disconnect?: AuditLogWhereUniqueInput | AuditLogWhereUniqueInput[]
    delete?: AuditLogWhereUniqueInput | AuditLogWhereUniqueInput[]
    connect?: AuditLogWhereUniqueInput | AuditLogWhereUniqueInput[]
    update?: AuditLogUpdateWithWhereUniqueWithoutUserInput | AuditLogUpdateWithWhereUniqueWithoutUserInput[]
    updateMany?: AuditLogUpdateManyWithWhereWithoutUserInput | AuditLogUpdateManyWithWhereWithoutUserInput[]
    deleteMany?: AuditLogScalarWhereInput | AuditLogScalarWhereInput[]
  }

  export type CreditApplicationUncheckedUpdateManyWithoutUserNestedInput = {
    create?: XOR<CreditApplicationCreateWithoutUserInput, CreditApplicationUncheckedCreateWithoutUserInput> | CreditApplicationCreateWithoutUserInput[] | CreditApplicationUncheckedCreateWithoutUserInput[]
    connectOrCreate?: CreditApplicationCreateOrConnectWithoutUserInput | CreditApplicationCreateOrConnectWithoutUserInput[]
    upsert?: CreditApplicationUpsertWithWhereUniqueWithoutUserInput | CreditApplicationUpsertWithWhereUniqueWithoutUserInput[]
    createMany?: CreditApplicationCreateManyUserInputEnvelope
    set?: CreditApplicationWhereUniqueInput | CreditApplicationWhereUniqueInput[]
    disconnect?: CreditApplicationWhereUniqueInput | CreditApplicationWhereUniqueInput[]
    delete?: CreditApplicationWhereUniqueInput | CreditApplicationWhereUniqueInput[]
    connect?: CreditApplicationWhereUniqueInput | CreditApplicationWhereUniqueInput[]
    update?: CreditApplicationUpdateWithWhereUniqueWithoutUserInput | CreditApplicationUpdateWithWhereUniqueWithoutUserInput[]
    updateMany?: CreditApplicationUpdateManyWithWhereWithoutUserInput | CreditApplicationUpdateManyWithWhereWithoutUserInput[]
    deleteMany?: CreditApplicationScalarWhereInput | CreditApplicationScalarWhereInput[]
  }

  export type SavingsAccountUncheckedUpdateManyWithoutUserNestedInput = {
    create?: XOR<SavingsAccountCreateWithoutUserInput, SavingsAccountUncheckedCreateWithoutUserInput> | SavingsAccountCreateWithoutUserInput[] | SavingsAccountUncheckedCreateWithoutUserInput[]
    connectOrCreate?: SavingsAccountCreateOrConnectWithoutUserInput | SavingsAccountCreateOrConnectWithoutUserInput[]
    upsert?: SavingsAccountUpsertWithWhereUniqueWithoutUserInput | SavingsAccountUpsertWithWhereUniqueWithoutUserInput[]
    createMany?: SavingsAccountCreateManyUserInputEnvelope
    set?: SavingsAccountWhereUniqueInput | SavingsAccountWhereUniqueInput[]
    disconnect?: SavingsAccountWhereUniqueInput | SavingsAccountWhereUniqueInput[]
    delete?: SavingsAccountWhereUniqueInput | SavingsAccountWhereUniqueInput[]
    connect?: SavingsAccountWhereUniqueInput | SavingsAccountWhereUniqueInput[]
    update?: SavingsAccountUpdateWithWhereUniqueWithoutUserInput | SavingsAccountUpdateWithWhereUniqueWithoutUserInput[]
    updateMany?: SavingsAccountUpdateManyWithWhereWithoutUserInput | SavingsAccountUpdateManyWithWhereWithoutUserInput[]
    deleteMany?: SavingsAccountScalarWhereInput | SavingsAccountScalarWhereInput[]
  }

  export type ReferralUncheckedUpdateManyWithoutReferrerNestedInput = {
    create?: XOR<ReferralCreateWithoutReferrerInput, ReferralUncheckedCreateWithoutReferrerInput> | ReferralCreateWithoutReferrerInput[] | ReferralUncheckedCreateWithoutReferrerInput[]
    connectOrCreate?: ReferralCreateOrConnectWithoutReferrerInput | ReferralCreateOrConnectWithoutReferrerInput[]
    upsert?: ReferralUpsertWithWhereUniqueWithoutReferrerInput | ReferralUpsertWithWhereUniqueWithoutReferrerInput[]
    createMany?: ReferralCreateManyReferrerInputEnvelope
    set?: ReferralWhereUniqueInput | ReferralWhereUniqueInput[]
    disconnect?: ReferralWhereUniqueInput | ReferralWhereUniqueInput[]
    delete?: ReferralWhereUniqueInput | ReferralWhereUniqueInput[]
    connect?: ReferralWhereUniqueInput | ReferralWhereUniqueInput[]
    update?: ReferralUpdateWithWhereUniqueWithoutReferrerInput | ReferralUpdateWithWhereUniqueWithoutReferrerInput[]
    updateMany?: ReferralUpdateManyWithWhereWithoutReferrerInput | ReferralUpdateManyWithWhereWithoutReferrerInput[]
    deleteMany?: ReferralScalarWhereInput | ReferralScalarWhereInput[]
  }

  export type ReferralUncheckedUpdateManyWithoutReferredUserNestedInput = {
    create?: XOR<ReferralCreateWithoutReferredUserInput, ReferralUncheckedCreateWithoutReferredUserInput> | ReferralCreateWithoutReferredUserInput[] | ReferralUncheckedCreateWithoutReferredUserInput[]
    connectOrCreate?: ReferralCreateOrConnectWithoutReferredUserInput | ReferralCreateOrConnectWithoutReferredUserInput[]
    upsert?: ReferralUpsertWithWhereUniqueWithoutReferredUserInput | ReferralUpsertWithWhereUniqueWithoutReferredUserInput[]
    createMany?: ReferralCreateManyReferredUserInputEnvelope
    set?: ReferralWhereUniqueInput | ReferralWhereUniqueInput[]
    disconnect?: ReferralWhereUniqueInput | ReferralWhereUniqueInput[]
    delete?: ReferralWhereUniqueInput | ReferralWhereUniqueInput[]
    connect?: ReferralWhereUniqueInput | ReferralWhereUniqueInput[]
    update?: ReferralUpdateWithWhereUniqueWithoutReferredUserInput | ReferralUpdateWithWhereUniqueWithoutReferredUserInput[]
    updateMany?: ReferralUpdateManyWithWhereWithoutReferredUserInput | ReferralUpdateManyWithWhereWithoutReferredUserInput[]
    deleteMany?: ReferralScalarWhereInput | ReferralScalarWhereInput[]
  }

  export type QuizAttemptUncheckedUpdateManyWithoutUserNestedInput = {
    create?: XOR<QuizAttemptCreateWithoutUserInput, QuizAttemptUncheckedCreateWithoutUserInput> | QuizAttemptCreateWithoutUserInput[] | QuizAttemptUncheckedCreateWithoutUserInput[]
    connectOrCreate?: QuizAttemptCreateOrConnectWithoutUserInput | QuizAttemptCreateOrConnectWithoutUserInput[]
    upsert?: QuizAttemptUpsertWithWhereUniqueWithoutUserInput | QuizAttemptUpsertWithWhereUniqueWithoutUserInput[]
    createMany?: QuizAttemptCreateManyUserInputEnvelope
    set?: QuizAttemptWhereUniqueInput | QuizAttemptWhereUniqueInput[]
    disconnect?: QuizAttemptWhereUniqueInput | QuizAttemptWhereUniqueInput[]
    delete?: QuizAttemptWhereUniqueInput | QuizAttemptWhereUniqueInput[]
    connect?: QuizAttemptWhereUniqueInput | QuizAttemptWhereUniqueInput[]
    update?: QuizAttemptUpdateWithWhereUniqueWithoutUserInput | QuizAttemptUpdateWithWhereUniqueWithoutUserInput[]
    updateMany?: QuizAttemptUpdateManyWithWhereWithoutUserInput | QuizAttemptUpdateManyWithWhereWithoutUserInput[]
    deleteMany?: QuizAttemptScalarWhereInput | QuizAttemptScalarWhereInput[]
  }

  export type BadgeUncheckedUpdateManyWithoutUserNestedInput = {
    create?: XOR<BadgeCreateWithoutUserInput, BadgeUncheckedCreateWithoutUserInput> | BadgeCreateWithoutUserInput[] | BadgeUncheckedCreateWithoutUserInput[]
    connectOrCreate?: BadgeCreateOrConnectWithoutUserInput | BadgeCreateOrConnectWithoutUserInput[]
    upsert?: BadgeUpsertWithWhereUniqueWithoutUserInput | BadgeUpsertWithWhereUniqueWithoutUserInput[]
    createMany?: BadgeCreateManyUserInputEnvelope
    set?: BadgeWhereUniqueInput | BadgeWhereUniqueInput[]
    disconnect?: BadgeWhereUniqueInput | BadgeWhereUniqueInput[]
    delete?: BadgeWhereUniqueInput | BadgeWhereUniqueInput[]
    connect?: BadgeWhereUniqueInput | BadgeWhereUniqueInput[]
    update?: BadgeUpdateWithWhereUniqueWithoutUserInput | BadgeUpdateWithWhereUniqueWithoutUserInput[]
    updateMany?: BadgeUpdateManyWithWhereWithoutUserInput | BadgeUpdateManyWithWhereWithoutUserInput[]
    deleteMany?: BadgeScalarWhereInput | BadgeScalarWhereInput[]
  }

  export type InsurancePolicyUncheckedUpdateManyWithoutUserNestedInput = {
    create?: XOR<InsurancePolicyCreateWithoutUserInput, InsurancePolicyUncheckedCreateWithoutUserInput> | InsurancePolicyCreateWithoutUserInput[] | InsurancePolicyUncheckedCreateWithoutUserInput[]
    connectOrCreate?: InsurancePolicyCreateOrConnectWithoutUserInput | InsurancePolicyCreateOrConnectWithoutUserInput[]
    upsert?: InsurancePolicyUpsertWithWhereUniqueWithoutUserInput | InsurancePolicyUpsertWithWhereUniqueWithoutUserInput[]
    createMany?: InsurancePolicyCreateManyUserInputEnvelope
    set?: InsurancePolicyWhereUniqueInput | InsurancePolicyWhereUniqueInput[]
    disconnect?: InsurancePolicyWhereUniqueInput | InsurancePolicyWhereUniqueInput[]
    delete?: InsurancePolicyWhereUniqueInput | InsurancePolicyWhereUniqueInput[]
    connect?: InsurancePolicyWhereUniqueInput | InsurancePolicyWhereUniqueInput[]
    update?: InsurancePolicyUpdateWithWhereUniqueWithoutUserInput | InsurancePolicyUpdateWithWhereUniqueWithoutUserInput[]
    updateMany?: InsurancePolicyUpdateManyWithWhereWithoutUserInput | InsurancePolicyUpdateManyWithWhereWithoutUserInput[]
    deleteMany?: InsurancePolicyScalarWhereInput | InsurancePolicyScalarWhereInput[]
  }

  export type UserCreateNestedOneWithoutOtpsInput = {
    create?: XOR<UserCreateWithoutOtpsInput, UserUncheckedCreateWithoutOtpsInput>
    connectOrCreate?: UserCreateOrConnectWithoutOtpsInput
    connect?: UserWhereUniqueInput
  }

  export type BoolFieldUpdateOperationsInput = {
    set?: boolean
  }

  export type UserUpdateOneWithoutOtpsNestedInput = {
    create?: XOR<UserCreateWithoutOtpsInput, UserUncheckedCreateWithoutOtpsInput>
    connectOrCreate?: UserCreateOrConnectWithoutOtpsInput
    upsert?: UserUpsertWithoutOtpsInput
    disconnect?: UserWhereInput | boolean
    delete?: UserWhereInput | boolean
    connect?: UserWhereUniqueInput
    update?: XOR<XOR<UserUpdateToOneWithWhereWithoutOtpsInput, UserUpdateWithoutOtpsInput>, UserUncheckedUpdateWithoutOtpsInput>
  }

  export type UserCreateNestedOneWithoutSessionsInput = {
    create?: XOR<UserCreateWithoutSessionsInput, UserUncheckedCreateWithoutSessionsInput>
    connectOrCreate?: UserCreateOrConnectWithoutSessionsInput
    connect?: UserWhereUniqueInput
  }

  export type UserUpdateOneRequiredWithoutSessionsNestedInput = {
    create?: XOR<UserCreateWithoutSessionsInput, UserUncheckedCreateWithoutSessionsInput>
    connectOrCreate?: UserCreateOrConnectWithoutSessionsInput
    upsert?: UserUpsertWithoutSessionsInput
    connect?: UserWhereUniqueInput
    update?: XOR<XOR<UserUpdateToOneWithWhereWithoutSessionsInput, UserUpdateWithoutSessionsInput>, UserUncheckedUpdateWithoutSessionsInput>
  }

  export type UserCreateNestedOneWithoutGruposCriadosInput = {
    create?: XOR<UserCreateWithoutGruposCriadosInput, UserUncheckedCreateWithoutGruposCriadosInput>
    connectOrCreate?: UserCreateOrConnectWithoutGruposCriadosInput
    connect?: UserWhereUniqueInput
  }

  export type MembershipCreateNestedManyWithoutGroupInput = {
    create?: XOR<MembershipCreateWithoutGroupInput, MembershipUncheckedCreateWithoutGroupInput> | MembershipCreateWithoutGroupInput[] | MembershipUncheckedCreateWithoutGroupInput[]
    connectOrCreate?: MembershipCreateOrConnectWithoutGroupInput | MembershipCreateOrConnectWithoutGroupInput[]
    createMany?: MembershipCreateManyGroupInputEnvelope
    connect?: MembershipWhereUniqueInput | MembershipWhereUniqueInput[]
  }

  export type MonthlyCycleCreateNestedManyWithoutGroupInput = {
    create?: XOR<MonthlyCycleCreateWithoutGroupInput, MonthlyCycleUncheckedCreateWithoutGroupInput> | MonthlyCycleCreateWithoutGroupInput[] | MonthlyCycleUncheckedCreateWithoutGroupInput[]
    connectOrCreate?: MonthlyCycleCreateOrConnectWithoutGroupInput | MonthlyCycleCreateOrConnectWithoutGroupInput[]
    createMany?: MonthlyCycleCreateManyGroupInputEnvelope
    connect?: MonthlyCycleWhereUniqueInput | MonthlyCycleWhereUniqueInput[]
  }

  export type InviteCreateNestedManyWithoutGroupInput = {
    create?: XOR<InviteCreateWithoutGroupInput, InviteUncheckedCreateWithoutGroupInput> | InviteCreateWithoutGroupInput[] | InviteUncheckedCreateWithoutGroupInput[]
    connectOrCreate?: InviteCreateOrConnectWithoutGroupInput | InviteCreateOrConnectWithoutGroupInput[]
    createMany?: InviteCreateManyGroupInputEnvelope
    connect?: InviteWhereUniqueInput | InviteWhereUniqueInput[]
  }

  export type GroupApplicationCreateNestedManyWithoutGroupInput = {
    create?: XOR<GroupApplicationCreateWithoutGroupInput, GroupApplicationUncheckedCreateWithoutGroupInput> | GroupApplicationCreateWithoutGroupInput[] | GroupApplicationUncheckedCreateWithoutGroupInput[]
    connectOrCreate?: GroupApplicationCreateOrConnectWithoutGroupInput | GroupApplicationCreateOrConnectWithoutGroupInput[]
    createMany?: GroupApplicationCreateManyGroupInputEnvelope
    connect?: GroupApplicationWhereUniqueInput | GroupApplicationWhereUniqueInput[]
  }

  export type MembershipUncheckedCreateNestedManyWithoutGroupInput = {
    create?: XOR<MembershipCreateWithoutGroupInput, MembershipUncheckedCreateWithoutGroupInput> | MembershipCreateWithoutGroupInput[] | MembershipUncheckedCreateWithoutGroupInput[]
    connectOrCreate?: MembershipCreateOrConnectWithoutGroupInput | MembershipCreateOrConnectWithoutGroupInput[]
    createMany?: MembershipCreateManyGroupInputEnvelope
    connect?: MembershipWhereUniqueInput | MembershipWhereUniqueInput[]
  }

  export type MonthlyCycleUncheckedCreateNestedManyWithoutGroupInput = {
    create?: XOR<MonthlyCycleCreateWithoutGroupInput, MonthlyCycleUncheckedCreateWithoutGroupInput> | MonthlyCycleCreateWithoutGroupInput[] | MonthlyCycleUncheckedCreateWithoutGroupInput[]
    connectOrCreate?: MonthlyCycleCreateOrConnectWithoutGroupInput | MonthlyCycleCreateOrConnectWithoutGroupInput[]
    createMany?: MonthlyCycleCreateManyGroupInputEnvelope
    connect?: MonthlyCycleWhereUniqueInput | MonthlyCycleWhereUniqueInput[]
  }

  export type InviteUncheckedCreateNestedManyWithoutGroupInput = {
    create?: XOR<InviteCreateWithoutGroupInput, InviteUncheckedCreateWithoutGroupInput> | InviteCreateWithoutGroupInput[] | InviteUncheckedCreateWithoutGroupInput[]
    connectOrCreate?: InviteCreateOrConnectWithoutGroupInput | InviteCreateOrConnectWithoutGroupInput[]
    createMany?: InviteCreateManyGroupInputEnvelope
    connect?: InviteWhereUniqueInput | InviteWhereUniqueInput[]
  }

  export type GroupApplicationUncheckedCreateNestedManyWithoutGroupInput = {
    create?: XOR<GroupApplicationCreateWithoutGroupInput, GroupApplicationUncheckedCreateWithoutGroupInput> | GroupApplicationCreateWithoutGroupInput[] | GroupApplicationUncheckedCreateWithoutGroupInput[]
    connectOrCreate?: GroupApplicationCreateOrConnectWithoutGroupInput | GroupApplicationCreateOrConnectWithoutGroupInput[]
    createMany?: GroupApplicationCreateManyGroupInputEnvelope
    connect?: GroupApplicationWhereUniqueInput | GroupApplicationWhereUniqueInput[]
  }

  export type FloatFieldUpdateOperationsInput = {
    set?: number
    increment?: number
    decrement?: number
    multiply?: number
    divide?: number
  }

  export type UserUpdateOneRequiredWithoutGruposCriadosNestedInput = {
    create?: XOR<UserCreateWithoutGruposCriadosInput, UserUncheckedCreateWithoutGruposCriadosInput>
    connectOrCreate?: UserCreateOrConnectWithoutGruposCriadosInput
    upsert?: UserUpsertWithoutGruposCriadosInput
    connect?: UserWhereUniqueInput
    update?: XOR<XOR<UserUpdateToOneWithWhereWithoutGruposCriadosInput, UserUpdateWithoutGruposCriadosInput>, UserUncheckedUpdateWithoutGruposCriadosInput>
  }

  export type MembershipUpdateManyWithoutGroupNestedInput = {
    create?: XOR<MembershipCreateWithoutGroupInput, MembershipUncheckedCreateWithoutGroupInput> | MembershipCreateWithoutGroupInput[] | MembershipUncheckedCreateWithoutGroupInput[]
    connectOrCreate?: MembershipCreateOrConnectWithoutGroupInput | MembershipCreateOrConnectWithoutGroupInput[]
    upsert?: MembershipUpsertWithWhereUniqueWithoutGroupInput | MembershipUpsertWithWhereUniqueWithoutGroupInput[]
    createMany?: MembershipCreateManyGroupInputEnvelope
    set?: MembershipWhereUniqueInput | MembershipWhereUniqueInput[]
    disconnect?: MembershipWhereUniqueInput | MembershipWhereUniqueInput[]
    delete?: MembershipWhereUniqueInput | MembershipWhereUniqueInput[]
    connect?: MembershipWhereUniqueInput | MembershipWhereUniqueInput[]
    update?: MembershipUpdateWithWhereUniqueWithoutGroupInput | MembershipUpdateWithWhereUniqueWithoutGroupInput[]
    updateMany?: MembershipUpdateManyWithWhereWithoutGroupInput | MembershipUpdateManyWithWhereWithoutGroupInput[]
    deleteMany?: MembershipScalarWhereInput | MembershipScalarWhereInput[]
  }

  export type MonthlyCycleUpdateManyWithoutGroupNestedInput = {
    create?: XOR<MonthlyCycleCreateWithoutGroupInput, MonthlyCycleUncheckedCreateWithoutGroupInput> | MonthlyCycleCreateWithoutGroupInput[] | MonthlyCycleUncheckedCreateWithoutGroupInput[]
    connectOrCreate?: MonthlyCycleCreateOrConnectWithoutGroupInput | MonthlyCycleCreateOrConnectWithoutGroupInput[]
    upsert?: MonthlyCycleUpsertWithWhereUniqueWithoutGroupInput | MonthlyCycleUpsertWithWhereUniqueWithoutGroupInput[]
    createMany?: MonthlyCycleCreateManyGroupInputEnvelope
    set?: MonthlyCycleWhereUniqueInput | MonthlyCycleWhereUniqueInput[]
    disconnect?: MonthlyCycleWhereUniqueInput | MonthlyCycleWhereUniqueInput[]
    delete?: MonthlyCycleWhereUniqueInput | MonthlyCycleWhereUniqueInput[]
    connect?: MonthlyCycleWhereUniqueInput | MonthlyCycleWhereUniqueInput[]
    update?: MonthlyCycleUpdateWithWhereUniqueWithoutGroupInput | MonthlyCycleUpdateWithWhereUniqueWithoutGroupInput[]
    updateMany?: MonthlyCycleUpdateManyWithWhereWithoutGroupInput | MonthlyCycleUpdateManyWithWhereWithoutGroupInput[]
    deleteMany?: MonthlyCycleScalarWhereInput | MonthlyCycleScalarWhereInput[]
  }

  export type InviteUpdateManyWithoutGroupNestedInput = {
    create?: XOR<InviteCreateWithoutGroupInput, InviteUncheckedCreateWithoutGroupInput> | InviteCreateWithoutGroupInput[] | InviteUncheckedCreateWithoutGroupInput[]
    connectOrCreate?: InviteCreateOrConnectWithoutGroupInput | InviteCreateOrConnectWithoutGroupInput[]
    upsert?: InviteUpsertWithWhereUniqueWithoutGroupInput | InviteUpsertWithWhereUniqueWithoutGroupInput[]
    createMany?: InviteCreateManyGroupInputEnvelope
    set?: InviteWhereUniqueInput | InviteWhereUniqueInput[]
    disconnect?: InviteWhereUniqueInput | InviteWhereUniqueInput[]
    delete?: InviteWhereUniqueInput | InviteWhereUniqueInput[]
    connect?: InviteWhereUniqueInput | InviteWhereUniqueInput[]
    update?: InviteUpdateWithWhereUniqueWithoutGroupInput | InviteUpdateWithWhereUniqueWithoutGroupInput[]
    updateMany?: InviteUpdateManyWithWhereWithoutGroupInput | InviteUpdateManyWithWhereWithoutGroupInput[]
    deleteMany?: InviteScalarWhereInput | InviteScalarWhereInput[]
  }

  export type GroupApplicationUpdateManyWithoutGroupNestedInput = {
    create?: XOR<GroupApplicationCreateWithoutGroupInput, GroupApplicationUncheckedCreateWithoutGroupInput> | GroupApplicationCreateWithoutGroupInput[] | GroupApplicationUncheckedCreateWithoutGroupInput[]
    connectOrCreate?: GroupApplicationCreateOrConnectWithoutGroupInput | GroupApplicationCreateOrConnectWithoutGroupInput[]
    upsert?: GroupApplicationUpsertWithWhereUniqueWithoutGroupInput | GroupApplicationUpsertWithWhereUniqueWithoutGroupInput[]
    createMany?: GroupApplicationCreateManyGroupInputEnvelope
    set?: GroupApplicationWhereUniqueInput | GroupApplicationWhereUniqueInput[]
    disconnect?: GroupApplicationWhereUniqueInput | GroupApplicationWhereUniqueInput[]
    delete?: GroupApplicationWhereUniqueInput | GroupApplicationWhereUniqueInput[]
    connect?: GroupApplicationWhereUniqueInput | GroupApplicationWhereUniqueInput[]
    update?: GroupApplicationUpdateWithWhereUniqueWithoutGroupInput | GroupApplicationUpdateWithWhereUniqueWithoutGroupInput[]
    updateMany?: GroupApplicationUpdateManyWithWhereWithoutGroupInput | GroupApplicationUpdateManyWithWhereWithoutGroupInput[]
    deleteMany?: GroupApplicationScalarWhereInput | GroupApplicationScalarWhereInput[]
  }

  export type MembershipUncheckedUpdateManyWithoutGroupNestedInput = {
    create?: XOR<MembershipCreateWithoutGroupInput, MembershipUncheckedCreateWithoutGroupInput> | MembershipCreateWithoutGroupInput[] | MembershipUncheckedCreateWithoutGroupInput[]
    connectOrCreate?: MembershipCreateOrConnectWithoutGroupInput | MembershipCreateOrConnectWithoutGroupInput[]
    upsert?: MembershipUpsertWithWhereUniqueWithoutGroupInput | MembershipUpsertWithWhereUniqueWithoutGroupInput[]
    createMany?: MembershipCreateManyGroupInputEnvelope
    set?: MembershipWhereUniqueInput | MembershipWhereUniqueInput[]
    disconnect?: MembershipWhereUniqueInput | MembershipWhereUniqueInput[]
    delete?: MembershipWhereUniqueInput | MembershipWhereUniqueInput[]
    connect?: MembershipWhereUniqueInput | MembershipWhereUniqueInput[]
    update?: MembershipUpdateWithWhereUniqueWithoutGroupInput | MembershipUpdateWithWhereUniqueWithoutGroupInput[]
    updateMany?: MembershipUpdateManyWithWhereWithoutGroupInput | MembershipUpdateManyWithWhereWithoutGroupInput[]
    deleteMany?: MembershipScalarWhereInput | MembershipScalarWhereInput[]
  }

  export type MonthlyCycleUncheckedUpdateManyWithoutGroupNestedInput = {
    create?: XOR<MonthlyCycleCreateWithoutGroupInput, MonthlyCycleUncheckedCreateWithoutGroupInput> | MonthlyCycleCreateWithoutGroupInput[] | MonthlyCycleUncheckedCreateWithoutGroupInput[]
    connectOrCreate?: MonthlyCycleCreateOrConnectWithoutGroupInput | MonthlyCycleCreateOrConnectWithoutGroupInput[]
    upsert?: MonthlyCycleUpsertWithWhereUniqueWithoutGroupInput | MonthlyCycleUpsertWithWhereUniqueWithoutGroupInput[]
    createMany?: MonthlyCycleCreateManyGroupInputEnvelope
    set?: MonthlyCycleWhereUniqueInput | MonthlyCycleWhereUniqueInput[]
    disconnect?: MonthlyCycleWhereUniqueInput | MonthlyCycleWhereUniqueInput[]
    delete?: MonthlyCycleWhereUniqueInput | MonthlyCycleWhereUniqueInput[]
    connect?: MonthlyCycleWhereUniqueInput | MonthlyCycleWhereUniqueInput[]
    update?: MonthlyCycleUpdateWithWhereUniqueWithoutGroupInput | MonthlyCycleUpdateWithWhereUniqueWithoutGroupInput[]
    updateMany?: MonthlyCycleUpdateManyWithWhereWithoutGroupInput | MonthlyCycleUpdateManyWithWhereWithoutGroupInput[]
    deleteMany?: MonthlyCycleScalarWhereInput | MonthlyCycleScalarWhereInput[]
  }

  export type InviteUncheckedUpdateManyWithoutGroupNestedInput = {
    create?: XOR<InviteCreateWithoutGroupInput, InviteUncheckedCreateWithoutGroupInput> | InviteCreateWithoutGroupInput[] | InviteUncheckedCreateWithoutGroupInput[]
    connectOrCreate?: InviteCreateOrConnectWithoutGroupInput | InviteCreateOrConnectWithoutGroupInput[]
    upsert?: InviteUpsertWithWhereUniqueWithoutGroupInput | InviteUpsertWithWhereUniqueWithoutGroupInput[]
    createMany?: InviteCreateManyGroupInputEnvelope
    set?: InviteWhereUniqueInput | InviteWhereUniqueInput[]
    disconnect?: InviteWhereUniqueInput | InviteWhereUniqueInput[]
    delete?: InviteWhereUniqueInput | InviteWhereUniqueInput[]
    connect?: InviteWhereUniqueInput | InviteWhereUniqueInput[]
    update?: InviteUpdateWithWhereUniqueWithoutGroupInput | InviteUpdateWithWhereUniqueWithoutGroupInput[]
    updateMany?: InviteUpdateManyWithWhereWithoutGroupInput | InviteUpdateManyWithWhereWithoutGroupInput[]
    deleteMany?: InviteScalarWhereInput | InviteScalarWhereInput[]
  }

  export type GroupApplicationUncheckedUpdateManyWithoutGroupNestedInput = {
    create?: XOR<GroupApplicationCreateWithoutGroupInput, GroupApplicationUncheckedCreateWithoutGroupInput> | GroupApplicationCreateWithoutGroupInput[] | GroupApplicationUncheckedCreateWithoutGroupInput[]
    connectOrCreate?: GroupApplicationCreateOrConnectWithoutGroupInput | GroupApplicationCreateOrConnectWithoutGroupInput[]
    upsert?: GroupApplicationUpsertWithWhereUniqueWithoutGroupInput | GroupApplicationUpsertWithWhereUniqueWithoutGroupInput[]
    createMany?: GroupApplicationCreateManyGroupInputEnvelope
    set?: GroupApplicationWhereUniqueInput | GroupApplicationWhereUniqueInput[]
    disconnect?: GroupApplicationWhereUniqueInput | GroupApplicationWhereUniqueInput[]
    delete?: GroupApplicationWhereUniqueInput | GroupApplicationWhereUniqueInput[]
    connect?: GroupApplicationWhereUniqueInput | GroupApplicationWhereUniqueInput[]
    update?: GroupApplicationUpdateWithWhereUniqueWithoutGroupInput | GroupApplicationUpdateWithWhereUniqueWithoutGroupInput[]
    updateMany?: GroupApplicationUpdateManyWithWhereWithoutGroupInput | GroupApplicationUpdateManyWithWhereWithoutGroupInput[]
    deleteMany?: GroupApplicationScalarWhereInput | GroupApplicationScalarWhereInput[]
  }

  export type GroupCreateNestedOneWithoutCandidaturasInput = {
    create?: XOR<GroupCreateWithoutCandidaturasInput, GroupUncheckedCreateWithoutCandidaturasInput>
    connectOrCreate?: GroupCreateOrConnectWithoutCandidaturasInput
    connect?: GroupWhereUniqueInput
  }

  export type GroupUpdateOneRequiredWithoutCandidaturasNestedInput = {
    create?: XOR<GroupCreateWithoutCandidaturasInput, GroupUncheckedCreateWithoutCandidaturasInput>
    connectOrCreate?: GroupCreateOrConnectWithoutCandidaturasInput
    upsert?: GroupUpsertWithoutCandidaturasInput
    connect?: GroupWhereUniqueInput
    update?: XOR<XOR<GroupUpdateToOneWithWhereWithoutCandidaturasInput, GroupUpdateWithoutCandidaturasInput>, GroupUncheckedUpdateWithoutCandidaturasInput>
  }

  export type UserCreateNestedOneWithoutMembershipsInput = {
    create?: XOR<UserCreateWithoutMembershipsInput, UserUncheckedCreateWithoutMembershipsInput>
    connectOrCreate?: UserCreateOrConnectWithoutMembershipsInput
    connect?: UserWhereUniqueInput
  }

  export type GroupCreateNestedOneWithoutMembershipsInput = {
    create?: XOR<GroupCreateWithoutMembershipsInput, GroupUncheckedCreateWithoutMembershipsInput>
    connectOrCreate?: GroupCreateOrConnectWithoutMembershipsInput
    connect?: GroupWhereUniqueInput
  }

  export type MonthlyCycleCreateNestedManyWithoutBeneficiarioMembershipInput = {
    create?: XOR<MonthlyCycleCreateWithoutBeneficiarioMembershipInput, MonthlyCycleUncheckedCreateWithoutBeneficiarioMembershipInput> | MonthlyCycleCreateWithoutBeneficiarioMembershipInput[] | MonthlyCycleUncheckedCreateWithoutBeneficiarioMembershipInput[]
    connectOrCreate?: MonthlyCycleCreateOrConnectWithoutBeneficiarioMembershipInput | MonthlyCycleCreateOrConnectWithoutBeneficiarioMembershipInput[]
    createMany?: MonthlyCycleCreateManyBeneficiarioMembershipInputEnvelope
    connect?: MonthlyCycleWhereUniqueInput | MonthlyCycleWhereUniqueInput[]
  }

  export type ContributionCreateNestedManyWithoutMembershipInput = {
    create?: XOR<ContributionCreateWithoutMembershipInput, ContributionUncheckedCreateWithoutMembershipInput> | ContributionCreateWithoutMembershipInput[] | ContributionUncheckedCreateWithoutMembershipInput[]
    connectOrCreate?: ContributionCreateOrConnectWithoutMembershipInput | ContributionCreateOrConnectWithoutMembershipInput[]
    createMany?: ContributionCreateManyMembershipInputEnvelope
    connect?: ContributionWhereUniqueInput | ContributionWhereUniqueInput[]
  }

  export type MonthlyCycleUncheckedCreateNestedManyWithoutBeneficiarioMembershipInput = {
    create?: XOR<MonthlyCycleCreateWithoutBeneficiarioMembershipInput, MonthlyCycleUncheckedCreateWithoutBeneficiarioMembershipInput> | MonthlyCycleCreateWithoutBeneficiarioMembershipInput[] | MonthlyCycleUncheckedCreateWithoutBeneficiarioMembershipInput[]
    connectOrCreate?: MonthlyCycleCreateOrConnectWithoutBeneficiarioMembershipInput | MonthlyCycleCreateOrConnectWithoutBeneficiarioMembershipInput[]
    createMany?: MonthlyCycleCreateManyBeneficiarioMembershipInputEnvelope
    connect?: MonthlyCycleWhereUniqueInput | MonthlyCycleWhereUniqueInput[]
  }

  export type ContributionUncheckedCreateNestedManyWithoutMembershipInput = {
    create?: XOR<ContributionCreateWithoutMembershipInput, ContributionUncheckedCreateWithoutMembershipInput> | ContributionCreateWithoutMembershipInput[] | ContributionUncheckedCreateWithoutMembershipInput[]
    connectOrCreate?: ContributionCreateOrConnectWithoutMembershipInput | ContributionCreateOrConnectWithoutMembershipInput[]
    createMany?: ContributionCreateManyMembershipInputEnvelope
    connect?: ContributionWhereUniqueInput | ContributionWhereUniqueInput[]
  }

  export type NullableIntFieldUpdateOperationsInput = {
    set?: number | null
    increment?: number
    decrement?: number
    multiply?: number
    divide?: number
  }

  export type UserUpdateOneRequiredWithoutMembershipsNestedInput = {
    create?: XOR<UserCreateWithoutMembershipsInput, UserUncheckedCreateWithoutMembershipsInput>
    connectOrCreate?: UserCreateOrConnectWithoutMembershipsInput
    upsert?: UserUpsertWithoutMembershipsInput
    connect?: UserWhereUniqueInput
    update?: XOR<XOR<UserUpdateToOneWithWhereWithoutMembershipsInput, UserUpdateWithoutMembershipsInput>, UserUncheckedUpdateWithoutMembershipsInput>
  }

  export type GroupUpdateOneRequiredWithoutMembershipsNestedInput = {
    create?: XOR<GroupCreateWithoutMembershipsInput, GroupUncheckedCreateWithoutMembershipsInput>
    connectOrCreate?: GroupCreateOrConnectWithoutMembershipsInput
    upsert?: GroupUpsertWithoutMembershipsInput
    connect?: GroupWhereUniqueInput
    update?: XOR<XOR<GroupUpdateToOneWithWhereWithoutMembershipsInput, GroupUpdateWithoutMembershipsInput>, GroupUncheckedUpdateWithoutMembershipsInput>
  }

  export type MonthlyCycleUpdateManyWithoutBeneficiarioMembershipNestedInput = {
    create?: XOR<MonthlyCycleCreateWithoutBeneficiarioMembershipInput, MonthlyCycleUncheckedCreateWithoutBeneficiarioMembershipInput> | MonthlyCycleCreateWithoutBeneficiarioMembershipInput[] | MonthlyCycleUncheckedCreateWithoutBeneficiarioMembershipInput[]
    connectOrCreate?: MonthlyCycleCreateOrConnectWithoutBeneficiarioMembershipInput | MonthlyCycleCreateOrConnectWithoutBeneficiarioMembershipInput[]
    upsert?: MonthlyCycleUpsertWithWhereUniqueWithoutBeneficiarioMembershipInput | MonthlyCycleUpsertWithWhereUniqueWithoutBeneficiarioMembershipInput[]
    createMany?: MonthlyCycleCreateManyBeneficiarioMembershipInputEnvelope
    set?: MonthlyCycleWhereUniqueInput | MonthlyCycleWhereUniqueInput[]
    disconnect?: MonthlyCycleWhereUniqueInput | MonthlyCycleWhereUniqueInput[]
    delete?: MonthlyCycleWhereUniqueInput | MonthlyCycleWhereUniqueInput[]
    connect?: MonthlyCycleWhereUniqueInput | MonthlyCycleWhereUniqueInput[]
    update?: MonthlyCycleUpdateWithWhereUniqueWithoutBeneficiarioMembershipInput | MonthlyCycleUpdateWithWhereUniqueWithoutBeneficiarioMembershipInput[]
    updateMany?: MonthlyCycleUpdateManyWithWhereWithoutBeneficiarioMembershipInput | MonthlyCycleUpdateManyWithWhereWithoutBeneficiarioMembershipInput[]
    deleteMany?: MonthlyCycleScalarWhereInput | MonthlyCycleScalarWhereInput[]
  }

  export type ContributionUpdateManyWithoutMembershipNestedInput = {
    create?: XOR<ContributionCreateWithoutMembershipInput, ContributionUncheckedCreateWithoutMembershipInput> | ContributionCreateWithoutMembershipInput[] | ContributionUncheckedCreateWithoutMembershipInput[]
    connectOrCreate?: ContributionCreateOrConnectWithoutMembershipInput | ContributionCreateOrConnectWithoutMembershipInput[]
    upsert?: ContributionUpsertWithWhereUniqueWithoutMembershipInput | ContributionUpsertWithWhereUniqueWithoutMembershipInput[]
    createMany?: ContributionCreateManyMembershipInputEnvelope
    set?: ContributionWhereUniqueInput | ContributionWhereUniqueInput[]
    disconnect?: ContributionWhereUniqueInput | ContributionWhereUniqueInput[]
    delete?: ContributionWhereUniqueInput | ContributionWhereUniqueInput[]
    connect?: ContributionWhereUniqueInput | ContributionWhereUniqueInput[]
    update?: ContributionUpdateWithWhereUniqueWithoutMembershipInput | ContributionUpdateWithWhereUniqueWithoutMembershipInput[]
    updateMany?: ContributionUpdateManyWithWhereWithoutMembershipInput | ContributionUpdateManyWithWhereWithoutMembershipInput[]
    deleteMany?: ContributionScalarWhereInput | ContributionScalarWhereInput[]
  }

  export type MonthlyCycleUncheckedUpdateManyWithoutBeneficiarioMembershipNestedInput = {
    create?: XOR<MonthlyCycleCreateWithoutBeneficiarioMembershipInput, MonthlyCycleUncheckedCreateWithoutBeneficiarioMembershipInput> | MonthlyCycleCreateWithoutBeneficiarioMembershipInput[] | MonthlyCycleUncheckedCreateWithoutBeneficiarioMembershipInput[]
    connectOrCreate?: MonthlyCycleCreateOrConnectWithoutBeneficiarioMembershipInput | MonthlyCycleCreateOrConnectWithoutBeneficiarioMembershipInput[]
    upsert?: MonthlyCycleUpsertWithWhereUniqueWithoutBeneficiarioMembershipInput | MonthlyCycleUpsertWithWhereUniqueWithoutBeneficiarioMembershipInput[]
    createMany?: MonthlyCycleCreateManyBeneficiarioMembershipInputEnvelope
    set?: MonthlyCycleWhereUniqueInput | MonthlyCycleWhereUniqueInput[]
    disconnect?: MonthlyCycleWhereUniqueInput | MonthlyCycleWhereUniqueInput[]
    delete?: MonthlyCycleWhereUniqueInput | MonthlyCycleWhereUniqueInput[]
    connect?: MonthlyCycleWhereUniqueInput | MonthlyCycleWhereUniqueInput[]
    update?: MonthlyCycleUpdateWithWhereUniqueWithoutBeneficiarioMembershipInput | MonthlyCycleUpdateWithWhereUniqueWithoutBeneficiarioMembershipInput[]
    updateMany?: MonthlyCycleUpdateManyWithWhereWithoutBeneficiarioMembershipInput | MonthlyCycleUpdateManyWithWhereWithoutBeneficiarioMembershipInput[]
    deleteMany?: MonthlyCycleScalarWhereInput | MonthlyCycleScalarWhereInput[]
  }

  export type ContributionUncheckedUpdateManyWithoutMembershipNestedInput = {
    create?: XOR<ContributionCreateWithoutMembershipInput, ContributionUncheckedCreateWithoutMembershipInput> | ContributionCreateWithoutMembershipInput[] | ContributionUncheckedCreateWithoutMembershipInput[]
    connectOrCreate?: ContributionCreateOrConnectWithoutMembershipInput | ContributionCreateOrConnectWithoutMembershipInput[]
    upsert?: ContributionUpsertWithWhereUniqueWithoutMembershipInput | ContributionUpsertWithWhereUniqueWithoutMembershipInput[]
    createMany?: ContributionCreateManyMembershipInputEnvelope
    set?: ContributionWhereUniqueInput | ContributionWhereUniqueInput[]
    disconnect?: ContributionWhereUniqueInput | ContributionWhereUniqueInput[]
    delete?: ContributionWhereUniqueInput | ContributionWhereUniqueInput[]
    connect?: ContributionWhereUniqueInput | ContributionWhereUniqueInput[]
    update?: ContributionUpdateWithWhereUniqueWithoutMembershipInput | ContributionUpdateWithWhereUniqueWithoutMembershipInput[]
    updateMany?: ContributionUpdateManyWithWhereWithoutMembershipInput | ContributionUpdateManyWithWhereWithoutMembershipInput[]
    deleteMany?: ContributionScalarWhereInput | ContributionScalarWhereInput[]
  }

  export type GroupCreateNestedOneWithoutInvitesInput = {
    create?: XOR<GroupCreateWithoutInvitesInput, GroupUncheckedCreateWithoutInvitesInput>
    connectOrCreate?: GroupCreateOrConnectWithoutInvitesInput
    connect?: GroupWhereUniqueInput
  }

  export type UserCreateNestedOneWithoutInvitesEnviadosInput = {
    create?: XOR<UserCreateWithoutInvitesEnviadosInput, UserUncheckedCreateWithoutInvitesEnviadosInput>
    connectOrCreate?: UserCreateOrConnectWithoutInvitesEnviadosInput
    connect?: UserWhereUniqueInput
  }

  export type GroupUpdateOneRequiredWithoutInvitesNestedInput = {
    create?: XOR<GroupCreateWithoutInvitesInput, GroupUncheckedCreateWithoutInvitesInput>
    connectOrCreate?: GroupCreateOrConnectWithoutInvitesInput
    upsert?: GroupUpsertWithoutInvitesInput
    connect?: GroupWhereUniqueInput
    update?: XOR<XOR<GroupUpdateToOneWithWhereWithoutInvitesInput, GroupUpdateWithoutInvitesInput>, GroupUncheckedUpdateWithoutInvitesInput>
  }

  export type UserUpdateOneRequiredWithoutInvitesEnviadosNestedInput = {
    create?: XOR<UserCreateWithoutInvitesEnviadosInput, UserUncheckedCreateWithoutInvitesEnviadosInput>
    connectOrCreate?: UserCreateOrConnectWithoutInvitesEnviadosInput
    upsert?: UserUpsertWithoutInvitesEnviadosInput
    connect?: UserWhereUniqueInput
    update?: XOR<XOR<UserUpdateToOneWithWhereWithoutInvitesEnviadosInput, UserUpdateWithoutInvitesEnviadosInput>, UserUncheckedUpdateWithoutInvitesEnviadosInput>
  }

  export type GroupCreateNestedOneWithoutMonthlyCyclesInput = {
    create?: XOR<GroupCreateWithoutMonthlyCyclesInput, GroupUncheckedCreateWithoutMonthlyCyclesInput>
    connectOrCreate?: GroupCreateOrConnectWithoutMonthlyCyclesInput
    connect?: GroupWhereUniqueInput
  }

  export type MembershipCreateNestedOneWithoutMonthlyCyclesBeneficiarioInput = {
    create?: XOR<MembershipCreateWithoutMonthlyCyclesBeneficiarioInput, MembershipUncheckedCreateWithoutMonthlyCyclesBeneficiarioInput>
    connectOrCreate?: MembershipCreateOrConnectWithoutMonthlyCyclesBeneficiarioInput
    connect?: MembershipWhereUniqueInput
  }

  export type ContributionCreateNestedManyWithoutMonthlyCycleInput = {
    create?: XOR<ContributionCreateWithoutMonthlyCycleInput, ContributionUncheckedCreateWithoutMonthlyCycleInput> | ContributionCreateWithoutMonthlyCycleInput[] | ContributionUncheckedCreateWithoutMonthlyCycleInput[]
    connectOrCreate?: ContributionCreateOrConnectWithoutMonthlyCycleInput | ContributionCreateOrConnectWithoutMonthlyCycleInput[]
    createMany?: ContributionCreateManyMonthlyCycleInputEnvelope
    connect?: ContributionWhereUniqueInput | ContributionWhereUniqueInput[]
  }

  export type CashoutCreateNestedOneWithoutMonthlyCycleInput = {
    create?: XOR<CashoutCreateWithoutMonthlyCycleInput, CashoutUncheckedCreateWithoutMonthlyCycleInput>
    connectOrCreate?: CashoutCreateOrConnectWithoutMonthlyCycleInput
    connect?: CashoutWhereUniqueInput
  }

  export type LoanCreateNestedManyWithoutMonthlyCycleInput = {
    create?: XOR<LoanCreateWithoutMonthlyCycleInput, LoanUncheckedCreateWithoutMonthlyCycleInput> | LoanCreateWithoutMonthlyCycleInput[] | LoanUncheckedCreateWithoutMonthlyCycleInput[]
    connectOrCreate?: LoanCreateOrConnectWithoutMonthlyCycleInput | LoanCreateOrConnectWithoutMonthlyCycleInput[]
    createMany?: LoanCreateManyMonthlyCycleInputEnvelope
    connect?: LoanWhereUniqueInput | LoanWhereUniqueInput[]
  }

  export type ContributionUncheckedCreateNestedManyWithoutMonthlyCycleInput = {
    create?: XOR<ContributionCreateWithoutMonthlyCycleInput, ContributionUncheckedCreateWithoutMonthlyCycleInput> | ContributionCreateWithoutMonthlyCycleInput[] | ContributionUncheckedCreateWithoutMonthlyCycleInput[]
    connectOrCreate?: ContributionCreateOrConnectWithoutMonthlyCycleInput | ContributionCreateOrConnectWithoutMonthlyCycleInput[]
    createMany?: ContributionCreateManyMonthlyCycleInputEnvelope
    connect?: ContributionWhereUniqueInput | ContributionWhereUniqueInput[]
  }

  export type CashoutUncheckedCreateNestedOneWithoutMonthlyCycleInput = {
    create?: XOR<CashoutCreateWithoutMonthlyCycleInput, CashoutUncheckedCreateWithoutMonthlyCycleInput>
    connectOrCreate?: CashoutCreateOrConnectWithoutMonthlyCycleInput
    connect?: CashoutWhereUniqueInput
  }

  export type LoanUncheckedCreateNestedManyWithoutMonthlyCycleInput = {
    create?: XOR<LoanCreateWithoutMonthlyCycleInput, LoanUncheckedCreateWithoutMonthlyCycleInput> | LoanCreateWithoutMonthlyCycleInput[] | LoanUncheckedCreateWithoutMonthlyCycleInput[]
    connectOrCreate?: LoanCreateOrConnectWithoutMonthlyCycleInput | LoanCreateOrConnectWithoutMonthlyCycleInput[]
    createMany?: LoanCreateManyMonthlyCycleInputEnvelope
    connect?: LoanWhereUniqueInput | LoanWhereUniqueInput[]
  }

  export type GroupUpdateOneRequiredWithoutMonthlyCyclesNestedInput = {
    create?: XOR<GroupCreateWithoutMonthlyCyclesInput, GroupUncheckedCreateWithoutMonthlyCyclesInput>
    connectOrCreate?: GroupCreateOrConnectWithoutMonthlyCyclesInput
    upsert?: GroupUpsertWithoutMonthlyCyclesInput
    connect?: GroupWhereUniqueInput
    update?: XOR<XOR<GroupUpdateToOneWithWhereWithoutMonthlyCyclesInput, GroupUpdateWithoutMonthlyCyclesInput>, GroupUncheckedUpdateWithoutMonthlyCyclesInput>
  }

  export type MembershipUpdateOneRequiredWithoutMonthlyCyclesBeneficiarioNestedInput = {
    create?: XOR<MembershipCreateWithoutMonthlyCyclesBeneficiarioInput, MembershipUncheckedCreateWithoutMonthlyCyclesBeneficiarioInput>
    connectOrCreate?: MembershipCreateOrConnectWithoutMonthlyCyclesBeneficiarioInput
    upsert?: MembershipUpsertWithoutMonthlyCyclesBeneficiarioInput
    connect?: MembershipWhereUniqueInput
    update?: XOR<XOR<MembershipUpdateToOneWithWhereWithoutMonthlyCyclesBeneficiarioInput, MembershipUpdateWithoutMonthlyCyclesBeneficiarioInput>, MembershipUncheckedUpdateWithoutMonthlyCyclesBeneficiarioInput>
  }

  export type ContributionUpdateManyWithoutMonthlyCycleNestedInput = {
    create?: XOR<ContributionCreateWithoutMonthlyCycleInput, ContributionUncheckedCreateWithoutMonthlyCycleInput> | ContributionCreateWithoutMonthlyCycleInput[] | ContributionUncheckedCreateWithoutMonthlyCycleInput[]
    connectOrCreate?: ContributionCreateOrConnectWithoutMonthlyCycleInput | ContributionCreateOrConnectWithoutMonthlyCycleInput[]
    upsert?: ContributionUpsertWithWhereUniqueWithoutMonthlyCycleInput | ContributionUpsertWithWhereUniqueWithoutMonthlyCycleInput[]
    createMany?: ContributionCreateManyMonthlyCycleInputEnvelope
    set?: ContributionWhereUniqueInput | ContributionWhereUniqueInput[]
    disconnect?: ContributionWhereUniqueInput | ContributionWhereUniqueInput[]
    delete?: ContributionWhereUniqueInput | ContributionWhereUniqueInput[]
    connect?: ContributionWhereUniqueInput | ContributionWhereUniqueInput[]
    update?: ContributionUpdateWithWhereUniqueWithoutMonthlyCycleInput | ContributionUpdateWithWhereUniqueWithoutMonthlyCycleInput[]
    updateMany?: ContributionUpdateManyWithWhereWithoutMonthlyCycleInput | ContributionUpdateManyWithWhereWithoutMonthlyCycleInput[]
    deleteMany?: ContributionScalarWhereInput | ContributionScalarWhereInput[]
  }

  export type CashoutUpdateOneWithoutMonthlyCycleNestedInput = {
    create?: XOR<CashoutCreateWithoutMonthlyCycleInput, CashoutUncheckedCreateWithoutMonthlyCycleInput>
    connectOrCreate?: CashoutCreateOrConnectWithoutMonthlyCycleInput
    upsert?: CashoutUpsertWithoutMonthlyCycleInput
    disconnect?: CashoutWhereInput | boolean
    delete?: CashoutWhereInput | boolean
    connect?: CashoutWhereUniqueInput
    update?: XOR<XOR<CashoutUpdateToOneWithWhereWithoutMonthlyCycleInput, CashoutUpdateWithoutMonthlyCycleInput>, CashoutUncheckedUpdateWithoutMonthlyCycleInput>
  }

  export type LoanUpdateManyWithoutMonthlyCycleNestedInput = {
    create?: XOR<LoanCreateWithoutMonthlyCycleInput, LoanUncheckedCreateWithoutMonthlyCycleInput> | LoanCreateWithoutMonthlyCycleInput[] | LoanUncheckedCreateWithoutMonthlyCycleInput[]
    connectOrCreate?: LoanCreateOrConnectWithoutMonthlyCycleInput | LoanCreateOrConnectWithoutMonthlyCycleInput[]
    upsert?: LoanUpsertWithWhereUniqueWithoutMonthlyCycleInput | LoanUpsertWithWhereUniqueWithoutMonthlyCycleInput[]
    createMany?: LoanCreateManyMonthlyCycleInputEnvelope
    set?: LoanWhereUniqueInput | LoanWhereUniqueInput[]
    disconnect?: LoanWhereUniqueInput | LoanWhereUniqueInput[]
    delete?: LoanWhereUniqueInput | LoanWhereUniqueInput[]
    connect?: LoanWhereUniqueInput | LoanWhereUniqueInput[]
    update?: LoanUpdateWithWhereUniqueWithoutMonthlyCycleInput | LoanUpdateWithWhereUniqueWithoutMonthlyCycleInput[]
    updateMany?: LoanUpdateManyWithWhereWithoutMonthlyCycleInput | LoanUpdateManyWithWhereWithoutMonthlyCycleInput[]
    deleteMany?: LoanScalarWhereInput | LoanScalarWhereInput[]
  }

  export type ContributionUncheckedUpdateManyWithoutMonthlyCycleNestedInput = {
    create?: XOR<ContributionCreateWithoutMonthlyCycleInput, ContributionUncheckedCreateWithoutMonthlyCycleInput> | ContributionCreateWithoutMonthlyCycleInput[] | ContributionUncheckedCreateWithoutMonthlyCycleInput[]
    connectOrCreate?: ContributionCreateOrConnectWithoutMonthlyCycleInput | ContributionCreateOrConnectWithoutMonthlyCycleInput[]
    upsert?: ContributionUpsertWithWhereUniqueWithoutMonthlyCycleInput | ContributionUpsertWithWhereUniqueWithoutMonthlyCycleInput[]
    createMany?: ContributionCreateManyMonthlyCycleInputEnvelope
    set?: ContributionWhereUniqueInput | ContributionWhereUniqueInput[]
    disconnect?: ContributionWhereUniqueInput | ContributionWhereUniqueInput[]
    delete?: ContributionWhereUniqueInput | ContributionWhereUniqueInput[]
    connect?: ContributionWhereUniqueInput | ContributionWhereUniqueInput[]
    update?: ContributionUpdateWithWhereUniqueWithoutMonthlyCycleInput | ContributionUpdateWithWhereUniqueWithoutMonthlyCycleInput[]
    updateMany?: ContributionUpdateManyWithWhereWithoutMonthlyCycleInput | ContributionUpdateManyWithWhereWithoutMonthlyCycleInput[]
    deleteMany?: ContributionScalarWhereInput | ContributionScalarWhereInput[]
  }

  export type CashoutUncheckedUpdateOneWithoutMonthlyCycleNestedInput = {
    create?: XOR<CashoutCreateWithoutMonthlyCycleInput, CashoutUncheckedCreateWithoutMonthlyCycleInput>
    connectOrCreate?: CashoutCreateOrConnectWithoutMonthlyCycleInput
    upsert?: CashoutUpsertWithoutMonthlyCycleInput
    disconnect?: CashoutWhereInput | boolean
    delete?: CashoutWhereInput | boolean
    connect?: CashoutWhereUniqueInput
    update?: XOR<XOR<CashoutUpdateToOneWithWhereWithoutMonthlyCycleInput, CashoutUpdateWithoutMonthlyCycleInput>, CashoutUncheckedUpdateWithoutMonthlyCycleInput>
  }

  export type LoanUncheckedUpdateManyWithoutMonthlyCycleNestedInput = {
    create?: XOR<LoanCreateWithoutMonthlyCycleInput, LoanUncheckedCreateWithoutMonthlyCycleInput> | LoanCreateWithoutMonthlyCycleInput[] | LoanUncheckedCreateWithoutMonthlyCycleInput[]
    connectOrCreate?: LoanCreateOrConnectWithoutMonthlyCycleInput | LoanCreateOrConnectWithoutMonthlyCycleInput[]
    upsert?: LoanUpsertWithWhereUniqueWithoutMonthlyCycleInput | LoanUpsertWithWhereUniqueWithoutMonthlyCycleInput[]
    createMany?: LoanCreateManyMonthlyCycleInputEnvelope
    set?: LoanWhereUniqueInput | LoanWhereUniqueInput[]
    disconnect?: LoanWhereUniqueInput | LoanWhereUniqueInput[]
    delete?: LoanWhereUniqueInput | LoanWhereUniqueInput[]
    connect?: LoanWhereUniqueInput | LoanWhereUniqueInput[]
    update?: LoanUpdateWithWhereUniqueWithoutMonthlyCycleInput | LoanUpdateWithWhereUniqueWithoutMonthlyCycleInput[]
    updateMany?: LoanUpdateManyWithWhereWithoutMonthlyCycleInput | LoanUpdateManyWithWhereWithoutMonthlyCycleInput[]
    deleteMany?: LoanScalarWhereInput | LoanScalarWhereInput[]
  }

  export type MembershipCreateNestedOneWithoutContribuicoesInput = {
    create?: XOR<MembershipCreateWithoutContribuicoesInput, MembershipUncheckedCreateWithoutContribuicoesInput>
    connectOrCreate?: MembershipCreateOrConnectWithoutContribuicoesInput
    connect?: MembershipWhereUniqueInput
  }

  export type UserCreateNestedOneWithoutContribuicoesInput = {
    create?: XOR<UserCreateWithoutContribuicoesInput, UserUncheckedCreateWithoutContribuicoesInput>
    connectOrCreate?: UserCreateOrConnectWithoutContribuicoesInput
    connect?: UserWhereUniqueInput
  }

  export type MonthlyCycleCreateNestedOneWithoutContribuicoesInput = {
    create?: XOR<MonthlyCycleCreateWithoutContribuicoesInput, MonthlyCycleUncheckedCreateWithoutContribuicoesInput>
    connectOrCreate?: MonthlyCycleCreateOrConnectWithoutContribuicoesInput
    connect?: MonthlyCycleWhereUniqueInput
  }

  export type CoverageDecisionCreateNestedOneWithoutContributionInput = {
    create?: XOR<CoverageDecisionCreateWithoutContributionInput, CoverageDecisionUncheckedCreateWithoutContributionInput>
    connectOrCreate?: CoverageDecisionCreateOrConnectWithoutContributionInput
    connect?: CoverageDecisionWhereUniqueInput
  }

  export type CoverageDecisionUncheckedCreateNestedOneWithoutContributionInput = {
    create?: XOR<CoverageDecisionCreateWithoutContributionInput, CoverageDecisionUncheckedCreateWithoutContributionInput>
    connectOrCreate?: CoverageDecisionCreateOrConnectWithoutContributionInput
    connect?: CoverageDecisionWhereUniqueInput
  }

  export type MembershipUpdateOneRequiredWithoutContribuicoesNestedInput = {
    create?: XOR<MembershipCreateWithoutContribuicoesInput, MembershipUncheckedCreateWithoutContribuicoesInput>
    connectOrCreate?: MembershipCreateOrConnectWithoutContribuicoesInput
    upsert?: MembershipUpsertWithoutContribuicoesInput
    connect?: MembershipWhereUniqueInput
    update?: XOR<XOR<MembershipUpdateToOneWithWhereWithoutContribuicoesInput, MembershipUpdateWithoutContribuicoesInput>, MembershipUncheckedUpdateWithoutContribuicoesInput>
  }

  export type UserUpdateOneRequiredWithoutContribuicoesNestedInput = {
    create?: XOR<UserCreateWithoutContribuicoesInput, UserUncheckedCreateWithoutContribuicoesInput>
    connectOrCreate?: UserCreateOrConnectWithoutContribuicoesInput
    upsert?: UserUpsertWithoutContribuicoesInput
    connect?: UserWhereUniqueInput
    update?: XOR<XOR<UserUpdateToOneWithWhereWithoutContribuicoesInput, UserUpdateWithoutContribuicoesInput>, UserUncheckedUpdateWithoutContribuicoesInput>
  }

  export type MonthlyCycleUpdateOneRequiredWithoutContribuicoesNestedInput = {
    create?: XOR<MonthlyCycleCreateWithoutContribuicoesInput, MonthlyCycleUncheckedCreateWithoutContribuicoesInput>
    connectOrCreate?: MonthlyCycleCreateOrConnectWithoutContribuicoesInput
    upsert?: MonthlyCycleUpsertWithoutContribuicoesInput
    connect?: MonthlyCycleWhereUniqueInput
    update?: XOR<XOR<MonthlyCycleUpdateToOneWithWhereWithoutContribuicoesInput, MonthlyCycleUpdateWithoutContribuicoesInput>, MonthlyCycleUncheckedUpdateWithoutContribuicoesInput>
  }

  export type CoverageDecisionUpdateOneWithoutContributionNestedInput = {
    create?: XOR<CoverageDecisionCreateWithoutContributionInput, CoverageDecisionUncheckedCreateWithoutContributionInput>
    connectOrCreate?: CoverageDecisionCreateOrConnectWithoutContributionInput
    upsert?: CoverageDecisionUpsertWithoutContributionInput
    disconnect?: CoverageDecisionWhereInput | boolean
    delete?: CoverageDecisionWhereInput | boolean
    connect?: CoverageDecisionWhereUniqueInput
    update?: XOR<XOR<CoverageDecisionUpdateToOneWithWhereWithoutContributionInput, CoverageDecisionUpdateWithoutContributionInput>, CoverageDecisionUncheckedUpdateWithoutContributionInput>
  }

  export type CoverageDecisionUncheckedUpdateOneWithoutContributionNestedInput = {
    create?: XOR<CoverageDecisionCreateWithoutContributionInput, CoverageDecisionUncheckedCreateWithoutContributionInput>
    connectOrCreate?: CoverageDecisionCreateOrConnectWithoutContributionInput
    upsert?: CoverageDecisionUpsertWithoutContributionInput
    disconnect?: CoverageDecisionWhereInput | boolean
    delete?: CoverageDecisionWhereInput | boolean
    connect?: CoverageDecisionWhereUniqueInput
    update?: XOR<XOR<CoverageDecisionUpdateToOneWithWhereWithoutContributionInput, CoverageDecisionUpdateWithoutContributionInput>, CoverageDecisionUncheckedUpdateWithoutContributionInput>
  }

  export type MonthlyCycleCreateNestedOneWithoutCashoutInput = {
    create?: XOR<MonthlyCycleCreateWithoutCashoutInput, MonthlyCycleUncheckedCreateWithoutCashoutInput>
    connectOrCreate?: MonthlyCycleCreateOrConnectWithoutCashoutInput
    connect?: MonthlyCycleWhereUniqueInput
  }

  export type UserCreateNestedOneWithoutCashoutsInput = {
    create?: XOR<UserCreateWithoutCashoutsInput, UserUncheckedCreateWithoutCashoutsInput>
    connectOrCreate?: UserCreateOrConnectWithoutCashoutsInput
    connect?: UserWhereUniqueInput
  }

  export type MonthlyCycleUpdateOneRequiredWithoutCashoutNestedInput = {
    create?: XOR<MonthlyCycleCreateWithoutCashoutInput, MonthlyCycleUncheckedCreateWithoutCashoutInput>
    connectOrCreate?: MonthlyCycleCreateOrConnectWithoutCashoutInput
    upsert?: MonthlyCycleUpsertWithoutCashoutInput
    connect?: MonthlyCycleWhereUniqueInput
    update?: XOR<XOR<MonthlyCycleUpdateToOneWithWhereWithoutCashoutInput, MonthlyCycleUpdateWithoutCashoutInput>, MonthlyCycleUncheckedUpdateWithoutCashoutInput>
  }

  export type UserUpdateOneRequiredWithoutCashoutsNestedInput = {
    create?: XOR<UserCreateWithoutCashoutsInput, UserUncheckedCreateWithoutCashoutsInput>
    connectOrCreate?: UserCreateOrConnectWithoutCashoutsInput
    upsert?: UserUpsertWithoutCashoutsInput
    connect?: UserWhereUniqueInput
    update?: XOR<XOR<UserUpdateToOneWithWhereWithoutCashoutsInput, UserUpdateWithoutCashoutsInput>, UserUncheckedUpdateWithoutCashoutsInput>
  }

  export type UserCreateNestedOneWithoutLoansInput = {
    create?: XOR<UserCreateWithoutLoansInput, UserUncheckedCreateWithoutLoansInput>
    connectOrCreate?: UserCreateOrConnectWithoutLoansInput
    connect?: UserWhereUniqueInput
  }

  export type MonthlyCycleCreateNestedOneWithoutLoansInput = {
    create?: XOR<MonthlyCycleCreateWithoutLoansInput, MonthlyCycleUncheckedCreateWithoutLoansInput>
    connectOrCreate?: MonthlyCycleCreateOrConnectWithoutLoansInput
    connect?: MonthlyCycleWhereUniqueInput
  }

  export type UserUpdateOneRequiredWithoutLoansNestedInput = {
    create?: XOR<UserCreateWithoutLoansInput, UserUncheckedCreateWithoutLoansInput>
    connectOrCreate?: UserCreateOrConnectWithoutLoansInput
    upsert?: UserUpsertWithoutLoansInput
    connect?: UserWhereUniqueInput
    update?: XOR<XOR<UserUpdateToOneWithWhereWithoutLoansInput, UserUpdateWithoutLoansInput>, UserUncheckedUpdateWithoutLoansInput>
  }

  export type MonthlyCycleUpdateOneRequiredWithoutLoansNestedInput = {
    create?: XOR<MonthlyCycleCreateWithoutLoansInput, MonthlyCycleUncheckedCreateWithoutLoansInput>
    connectOrCreate?: MonthlyCycleCreateOrConnectWithoutLoansInput
    upsert?: MonthlyCycleUpsertWithoutLoansInput
    connect?: MonthlyCycleWhereUniqueInput
    update?: XOR<XOR<MonthlyCycleUpdateToOneWithWhereWithoutLoansInput, MonthlyCycleUpdateWithoutLoansInput>, MonthlyCycleUncheckedUpdateWithoutLoansInput>
  }

  export type ContributionCreateNestedOneWithoutCoverageDecisionInput = {
    create?: XOR<ContributionCreateWithoutCoverageDecisionInput, ContributionUncheckedCreateWithoutCoverageDecisionInput>
    connectOrCreate?: ContributionCreateOrConnectWithoutCoverageDecisionInput
    connect?: ContributionWhereUniqueInput
  }

  export type UserCreateNestedOneWithoutCoverageDecisionsInput = {
    create?: XOR<UserCreateWithoutCoverageDecisionsInput, UserUncheckedCreateWithoutCoverageDecisionsInput>
    connectOrCreate?: UserCreateOrConnectWithoutCoverageDecisionsInput
    connect?: UserWhereUniqueInput
  }

  export type ContributionUpdateOneRequiredWithoutCoverageDecisionNestedInput = {
    create?: XOR<ContributionCreateWithoutCoverageDecisionInput, ContributionUncheckedCreateWithoutCoverageDecisionInput>
    connectOrCreate?: ContributionCreateOrConnectWithoutCoverageDecisionInput
    upsert?: ContributionUpsertWithoutCoverageDecisionInput
    connect?: ContributionWhereUniqueInput
    update?: XOR<XOR<ContributionUpdateToOneWithWhereWithoutCoverageDecisionInput, ContributionUpdateWithoutCoverageDecisionInput>, ContributionUncheckedUpdateWithoutCoverageDecisionInput>
  }

  export type UserUpdateOneWithoutCoverageDecisionsNestedInput = {
    create?: XOR<UserCreateWithoutCoverageDecisionsInput, UserUncheckedCreateWithoutCoverageDecisionsInput>
    connectOrCreate?: UserCreateOrConnectWithoutCoverageDecisionsInput
    upsert?: UserUpsertWithoutCoverageDecisionsInput
    disconnect?: UserWhereInput | boolean
    delete?: UserWhereInput | boolean
    connect?: UserWhereUniqueInput
    update?: XOR<XOR<UserUpdateToOneWithWhereWithoutCoverageDecisionsInput, UserUpdateWithoutCoverageDecisionsInput>, UserUncheckedUpdateWithoutCoverageDecisionsInput>
  }

  export type UserCreateNestedOneWithoutReintegrationsInput = {
    create?: XOR<UserCreateWithoutReintegrationsInput, UserUncheckedCreateWithoutReintegrationsInput>
    connectOrCreate?: UserCreateOrConnectWithoutReintegrationsInput
    connect?: UserWhereUniqueInput
  }

  export type UserUpdateOneRequiredWithoutReintegrationsNestedInput = {
    create?: XOR<UserCreateWithoutReintegrationsInput, UserUncheckedCreateWithoutReintegrationsInput>
    connectOrCreate?: UserCreateOrConnectWithoutReintegrationsInput
    upsert?: UserUpsertWithoutReintegrationsInput
    connect?: UserWhereUniqueInput
    update?: XOR<XOR<UserUpdateToOneWithWhereWithoutReintegrationsInput, UserUpdateWithoutReintegrationsInput>, UserUncheckedUpdateWithoutReintegrationsInput>
  }

  export type UserCreateNestedOneWithoutFeeConfigsCriadasInput = {
    create?: XOR<UserCreateWithoutFeeConfigsCriadasInput, UserUncheckedCreateWithoutFeeConfigsCriadasInput>
    connectOrCreate?: UserCreateOrConnectWithoutFeeConfigsCriadasInput
    connect?: UserWhereUniqueInput
  }

  export type UserUpdateOneWithoutFeeConfigsCriadasNestedInput = {
    create?: XOR<UserCreateWithoutFeeConfigsCriadasInput, UserUncheckedCreateWithoutFeeConfigsCriadasInput>
    connectOrCreate?: UserCreateOrConnectWithoutFeeConfigsCriadasInput
    upsert?: UserUpsertWithoutFeeConfigsCriadasInput
    disconnect?: UserWhereInput | boolean
    delete?: UserWhereInput | boolean
    connect?: UserWhereUniqueInput
    update?: XOR<XOR<UserUpdateToOneWithWhereWithoutFeeConfigsCriadasInput, UserUpdateWithoutFeeConfigsCriadasInput>, UserUncheckedUpdateWithoutFeeConfigsCriadasInput>
  }

  export type UserCreateNestedOneWithoutScoreEventsInput = {
    create?: XOR<UserCreateWithoutScoreEventsInput, UserUncheckedCreateWithoutScoreEventsInput>
    connectOrCreate?: UserCreateOrConnectWithoutScoreEventsInput
    connect?: UserWhereUniqueInput
  }

  export type UserUpdateOneRequiredWithoutScoreEventsNestedInput = {
    create?: XOR<UserCreateWithoutScoreEventsInput, UserUncheckedCreateWithoutScoreEventsInput>
    connectOrCreate?: UserCreateOrConnectWithoutScoreEventsInput
    upsert?: UserUpsertWithoutScoreEventsInput
    connect?: UserWhereUniqueInput
    update?: XOR<XOR<UserUpdateToOneWithWhereWithoutScoreEventsInput, UserUpdateWithoutScoreEventsInput>, UserUncheckedUpdateWithoutScoreEventsInput>
  }

  export type UserCreateNestedOneWithoutNotificationsInput = {
    create?: XOR<UserCreateWithoutNotificationsInput, UserUncheckedCreateWithoutNotificationsInput>
    connectOrCreate?: UserCreateOrConnectWithoutNotificationsInput
    connect?: UserWhereUniqueInput
  }

  export type UserUpdateOneRequiredWithoutNotificationsNestedInput = {
    create?: XOR<UserCreateWithoutNotificationsInput, UserUncheckedCreateWithoutNotificationsInput>
    connectOrCreate?: UserCreateOrConnectWithoutNotificationsInput
    upsert?: UserUpsertWithoutNotificationsInput
    connect?: UserWhereUniqueInput
    update?: XOR<XOR<UserUpdateToOneWithWhereWithoutNotificationsInput, UserUpdateWithoutNotificationsInput>, UserUncheckedUpdateWithoutNotificationsInput>
  }

  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 UserCreateNestedOneWithoutCreditApplicationsInput = {
    create?: XOR<UserCreateWithoutCreditApplicationsInput, UserUncheckedCreateWithoutCreditApplicationsInput>
    connectOrCreate?: UserCreateOrConnectWithoutCreditApplicationsInput
    connect?: UserWhereUniqueInput
  }

  export type CreditInstallmentCreateNestedManyWithoutApplicationInput = {
    create?: XOR<CreditInstallmentCreateWithoutApplicationInput, CreditInstallmentUncheckedCreateWithoutApplicationInput> | CreditInstallmentCreateWithoutApplicationInput[] | CreditInstallmentUncheckedCreateWithoutApplicationInput[]
    connectOrCreate?: CreditInstallmentCreateOrConnectWithoutApplicationInput | CreditInstallmentCreateOrConnectWithoutApplicationInput[]
    createMany?: CreditInstallmentCreateManyApplicationInputEnvelope
    connect?: CreditInstallmentWhereUniqueInput | CreditInstallmentWhereUniqueInput[]
  }

  export type CreditInstallmentUncheckedCreateNestedManyWithoutApplicationInput = {
    create?: XOR<CreditInstallmentCreateWithoutApplicationInput, CreditInstallmentUncheckedCreateWithoutApplicationInput> | CreditInstallmentCreateWithoutApplicationInput[] | CreditInstallmentUncheckedCreateWithoutApplicationInput[]
    connectOrCreate?: CreditInstallmentCreateOrConnectWithoutApplicationInput | CreditInstallmentCreateOrConnectWithoutApplicationInput[]
    createMany?: CreditInstallmentCreateManyApplicationInputEnvelope
    connect?: CreditInstallmentWhereUniqueInput | CreditInstallmentWhereUniqueInput[]
  }

  export type UserUpdateOneRequiredWithoutCreditApplicationsNestedInput = {
    create?: XOR<UserCreateWithoutCreditApplicationsInput, UserUncheckedCreateWithoutCreditApplicationsInput>
    connectOrCreate?: UserCreateOrConnectWithoutCreditApplicationsInput
    upsert?: UserUpsertWithoutCreditApplicationsInput
    connect?: UserWhereUniqueInput
    update?: XOR<XOR<UserUpdateToOneWithWhereWithoutCreditApplicationsInput, UserUpdateWithoutCreditApplicationsInput>, UserUncheckedUpdateWithoutCreditApplicationsInput>
  }

  export type CreditInstallmentUpdateManyWithoutApplicationNestedInput = {
    create?: XOR<CreditInstallmentCreateWithoutApplicationInput, CreditInstallmentUncheckedCreateWithoutApplicationInput> | CreditInstallmentCreateWithoutApplicationInput[] | CreditInstallmentUncheckedCreateWithoutApplicationInput[]
    connectOrCreate?: CreditInstallmentCreateOrConnectWithoutApplicationInput | CreditInstallmentCreateOrConnectWithoutApplicationInput[]
    upsert?: CreditInstallmentUpsertWithWhereUniqueWithoutApplicationInput | CreditInstallmentUpsertWithWhereUniqueWithoutApplicationInput[]
    createMany?: CreditInstallmentCreateManyApplicationInputEnvelope
    set?: CreditInstallmentWhereUniqueInput | CreditInstallmentWhereUniqueInput[]
    disconnect?: CreditInstallmentWhereUniqueInput | CreditInstallmentWhereUniqueInput[]
    delete?: CreditInstallmentWhereUniqueInput | CreditInstallmentWhereUniqueInput[]
    connect?: CreditInstallmentWhereUniqueInput | CreditInstallmentWhereUniqueInput[]
    update?: CreditInstallmentUpdateWithWhereUniqueWithoutApplicationInput | CreditInstallmentUpdateWithWhereUniqueWithoutApplicationInput[]
    updateMany?: CreditInstallmentUpdateManyWithWhereWithoutApplicationInput | CreditInstallmentUpdateManyWithWhereWithoutApplicationInput[]
    deleteMany?: CreditInstallmentScalarWhereInput | CreditInstallmentScalarWhereInput[]
  }

  export type CreditInstallmentUncheckedUpdateManyWithoutApplicationNestedInput = {
    create?: XOR<CreditInstallmentCreateWithoutApplicationInput, CreditInstallmentUncheckedCreateWithoutApplicationInput> | CreditInstallmentCreateWithoutApplicationInput[] | CreditInstallmentUncheckedCreateWithoutApplicationInput[]
    connectOrCreate?: CreditInstallmentCreateOrConnectWithoutApplicationInput | CreditInstallmentCreateOrConnectWithoutApplicationInput[]
    upsert?: CreditInstallmentUpsertWithWhereUniqueWithoutApplicationInput | CreditInstallmentUpsertWithWhereUniqueWithoutApplicationInput[]
    createMany?: CreditInstallmentCreateManyApplicationInputEnvelope
    set?: CreditInstallmentWhereUniqueInput | CreditInstallmentWhereUniqueInput[]
    disconnect?: CreditInstallmentWhereUniqueInput | CreditInstallmentWhereUniqueInput[]
    delete?: CreditInstallmentWhereUniqueInput | CreditInstallmentWhereUniqueInput[]
    connect?: CreditInstallmentWhereUniqueInput | CreditInstallmentWhereUniqueInput[]
    update?: CreditInstallmentUpdateWithWhereUniqueWithoutApplicationInput | CreditInstallmentUpdateWithWhereUniqueWithoutApplicationInput[]
    updateMany?: CreditInstallmentUpdateManyWithWhereWithoutApplicationInput | CreditInstallmentUpdateManyWithWhereWithoutApplicationInput[]
    deleteMany?: CreditInstallmentScalarWhereInput | CreditInstallmentScalarWhereInput[]
  }

  export type CreditApplicationCreateNestedOneWithoutPrestacoesInput = {
    create?: XOR<CreditApplicationCreateWithoutPrestacoesInput, CreditApplicationUncheckedCreateWithoutPrestacoesInput>
    connectOrCreate?: CreditApplicationCreateOrConnectWithoutPrestacoesInput
    connect?: CreditApplicationWhereUniqueInput
  }

  export type CreditApplicationUpdateOneRequiredWithoutPrestacoesNestedInput = {
    create?: XOR<CreditApplicationCreateWithoutPrestacoesInput, CreditApplicationUncheckedCreateWithoutPrestacoesInput>
    connectOrCreate?: CreditApplicationCreateOrConnectWithoutPrestacoesInput
    upsert?: CreditApplicationUpsertWithoutPrestacoesInput
    connect?: CreditApplicationWhereUniqueInput
    update?: XOR<XOR<CreditApplicationUpdateToOneWithWhereWithoutPrestacoesInput, CreditApplicationUpdateWithoutPrestacoesInput>, CreditApplicationUncheckedUpdateWithoutPrestacoesInput>
  }

  export type UserCreateNestedOneWithoutSavingsAccountsInput = {
    create?: XOR<UserCreateWithoutSavingsAccountsInput, UserUncheckedCreateWithoutSavingsAccountsInput>
    connectOrCreate?: UserCreateOrConnectWithoutSavingsAccountsInput
    connect?: UserWhereUniqueInput
  }

  export type SavingsMovementCreateNestedManyWithoutAccountInput = {
    create?: XOR<SavingsMovementCreateWithoutAccountInput, SavingsMovementUncheckedCreateWithoutAccountInput> | SavingsMovementCreateWithoutAccountInput[] | SavingsMovementUncheckedCreateWithoutAccountInput[]
    connectOrCreate?: SavingsMovementCreateOrConnectWithoutAccountInput | SavingsMovementCreateOrConnectWithoutAccountInput[]
    createMany?: SavingsMovementCreateManyAccountInputEnvelope
    connect?: SavingsMovementWhereUniqueInput | SavingsMovementWhereUniqueInput[]
  }

  export type SavingsMovementUncheckedCreateNestedManyWithoutAccountInput = {
    create?: XOR<SavingsMovementCreateWithoutAccountInput, SavingsMovementUncheckedCreateWithoutAccountInput> | SavingsMovementCreateWithoutAccountInput[] | SavingsMovementUncheckedCreateWithoutAccountInput[]
    connectOrCreate?: SavingsMovementCreateOrConnectWithoutAccountInput | SavingsMovementCreateOrConnectWithoutAccountInput[]
    createMany?: SavingsMovementCreateManyAccountInputEnvelope
    connect?: SavingsMovementWhereUniqueInput | SavingsMovementWhereUniqueInput[]
  }

  export type NullableFloatFieldUpdateOperationsInput = {
    set?: number | null
    increment?: number
    decrement?: number
    multiply?: number
    divide?: number
  }

  export type UserUpdateOneRequiredWithoutSavingsAccountsNestedInput = {
    create?: XOR<UserCreateWithoutSavingsAccountsInput, UserUncheckedCreateWithoutSavingsAccountsInput>
    connectOrCreate?: UserCreateOrConnectWithoutSavingsAccountsInput
    upsert?: UserUpsertWithoutSavingsAccountsInput
    connect?: UserWhereUniqueInput
    update?: XOR<XOR<UserUpdateToOneWithWhereWithoutSavingsAccountsInput, UserUpdateWithoutSavingsAccountsInput>, UserUncheckedUpdateWithoutSavingsAccountsInput>
  }

  export type SavingsMovementUpdateManyWithoutAccountNestedInput = {
    create?: XOR<SavingsMovementCreateWithoutAccountInput, SavingsMovementUncheckedCreateWithoutAccountInput> | SavingsMovementCreateWithoutAccountInput[] | SavingsMovementUncheckedCreateWithoutAccountInput[]
    connectOrCreate?: SavingsMovementCreateOrConnectWithoutAccountInput | SavingsMovementCreateOrConnectWithoutAccountInput[]
    upsert?: SavingsMovementUpsertWithWhereUniqueWithoutAccountInput | SavingsMovementUpsertWithWhereUniqueWithoutAccountInput[]
    createMany?: SavingsMovementCreateManyAccountInputEnvelope
    set?: SavingsMovementWhereUniqueInput | SavingsMovementWhereUniqueInput[]
    disconnect?: SavingsMovementWhereUniqueInput | SavingsMovementWhereUniqueInput[]
    delete?: SavingsMovementWhereUniqueInput | SavingsMovementWhereUniqueInput[]
    connect?: SavingsMovementWhereUniqueInput | SavingsMovementWhereUniqueInput[]
    update?: SavingsMovementUpdateWithWhereUniqueWithoutAccountInput | SavingsMovementUpdateWithWhereUniqueWithoutAccountInput[]
    updateMany?: SavingsMovementUpdateManyWithWhereWithoutAccountInput | SavingsMovementUpdateManyWithWhereWithoutAccountInput[]
    deleteMany?: SavingsMovementScalarWhereInput | SavingsMovementScalarWhereInput[]
  }

  export type SavingsMovementUncheckedUpdateManyWithoutAccountNestedInput = {
    create?: XOR<SavingsMovementCreateWithoutAccountInput, SavingsMovementUncheckedCreateWithoutAccountInput> | SavingsMovementCreateWithoutAccountInput[] | SavingsMovementUncheckedCreateWithoutAccountInput[]
    connectOrCreate?: SavingsMovementCreateOrConnectWithoutAccountInput | SavingsMovementCreateOrConnectWithoutAccountInput[]
    upsert?: SavingsMovementUpsertWithWhereUniqueWithoutAccountInput | SavingsMovementUpsertWithWhereUniqueWithoutAccountInput[]
    createMany?: SavingsMovementCreateManyAccountInputEnvelope
    set?: SavingsMovementWhereUniqueInput | SavingsMovementWhereUniqueInput[]
    disconnect?: SavingsMovementWhereUniqueInput | SavingsMovementWhereUniqueInput[]
    delete?: SavingsMovementWhereUniqueInput | SavingsMovementWhereUniqueInput[]
    connect?: SavingsMovementWhereUniqueInput | SavingsMovementWhereUniqueInput[]
    update?: SavingsMovementUpdateWithWhereUniqueWithoutAccountInput | SavingsMovementUpdateWithWhereUniqueWithoutAccountInput[]
    updateMany?: SavingsMovementUpdateManyWithWhereWithoutAccountInput | SavingsMovementUpdateManyWithWhereWithoutAccountInput[]
    deleteMany?: SavingsMovementScalarWhereInput | SavingsMovementScalarWhereInput[]
  }

  export type SavingsAccountCreateNestedOneWithoutMovimentosInput = {
    create?: XOR<SavingsAccountCreateWithoutMovimentosInput, SavingsAccountUncheckedCreateWithoutMovimentosInput>
    connectOrCreate?: SavingsAccountCreateOrConnectWithoutMovimentosInput
    connect?: SavingsAccountWhereUniqueInput
  }

  export type SavingsAccountUpdateOneRequiredWithoutMovimentosNestedInput = {
    create?: XOR<SavingsAccountCreateWithoutMovimentosInput, SavingsAccountUncheckedCreateWithoutMovimentosInput>
    connectOrCreate?: SavingsAccountCreateOrConnectWithoutMovimentosInput
    upsert?: SavingsAccountUpsertWithoutMovimentosInput
    connect?: SavingsAccountWhereUniqueInput
    update?: XOR<XOR<SavingsAccountUpdateToOneWithWhereWithoutMovimentosInput, SavingsAccountUpdateWithoutMovimentosInput>, SavingsAccountUncheckedUpdateWithoutMovimentosInput>
  }

  export type UserCreateNestedOneWithoutReferralsCreatedInput = {
    create?: XOR<UserCreateWithoutReferralsCreatedInput, UserUncheckedCreateWithoutReferralsCreatedInput>
    connectOrCreate?: UserCreateOrConnectWithoutReferralsCreatedInput
    connect?: UserWhereUniqueInput
  }

  export type UserCreateNestedOneWithoutReferralAsReferredInput = {
    create?: XOR<UserCreateWithoutReferralAsReferredInput, UserUncheckedCreateWithoutReferralAsReferredInput>
    connectOrCreate?: UserCreateOrConnectWithoutReferralAsReferredInput
    connect?: UserWhereUniqueInput
  }

  export type UserUpdateOneRequiredWithoutReferralsCreatedNestedInput = {
    create?: XOR<UserCreateWithoutReferralsCreatedInput, UserUncheckedCreateWithoutReferralsCreatedInput>
    connectOrCreate?: UserCreateOrConnectWithoutReferralsCreatedInput
    upsert?: UserUpsertWithoutReferralsCreatedInput
    connect?: UserWhereUniqueInput
    update?: XOR<XOR<UserUpdateToOneWithWhereWithoutReferralsCreatedInput, UserUpdateWithoutReferralsCreatedInput>, UserUncheckedUpdateWithoutReferralsCreatedInput>
  }

  export type UserUpdateOneWithoutReferralAsReferredNestedInput = {
    create?: XOR<UserCreateWithoutReferralAsReferredInput, UserUncheckedCreateWithoutReferralAsReferredInput>
    connectOrCreate?: UserCreateOrConnectWithoutReferralAsReferredInput
    upsert?: UserUpsertWithoutReferralAsReferredInput
    disconnect?: UserWhereInput | boolean
    delete?: UserWhereInput | boolean
    connect?: UserWhereUniqueInput
    update?: XOR<XOR<UserUpdateToOneWithWhereWithoutReferralAsReferredInput, UserUpdateWithoutReferralAsReferredInput>, UserUncheckedUpdateWithoutReferralAsReferredInput>
  }

  export type QuizAttemptCreateNestedManyWithoutQuizInput = {
    create?: XOR<QuizAttemptCreateWithoutQuizInput, QuizAttemptUncheckedCreateWithoutQuizInput> | QuizAttemptCreateWithoutQuizInput[] | QuizAttemptUncheckedCreateWithoutQuizInput[]
    connectOrCreate?: QuizAttemptCreateOrConnectWithoutQuizInput | QuizAttemptCreateOrConnectWithoutQuizInput[]
    createMany?: QuizAttemptCreateManyQuizInputEnvelope
    connect?: QuizAttemptWhereUniqueInput | QuizAttemptWhereUniqueInput[]
  }

  export type QuizAttemptUncheckedCreateNestedManyWithoutQuizInput = {
    create?: XOR<QuizAttemptCreateWithoutQuizInput, QuizAttemptUncheckedCreateWithoutQuizInput> | QuizAttemptCreateWithoutQuizInput[] | QuizAttemptUncheckedCreateWithoutQuizInput[]
    connectOrCreate?: QuizAttemptCreateOrConnectWithoutQuizInput | QuizAttemptCreateOrConnectWithoutQuizInput[]
    createMany?: QuizAttemptCreateManyQuizInputEnvelope
    connect?: QuizAttemptWhereUniqueInput | QuizAttemptWhereUniqueInput[]
  }

  export type QuizAttemptUpdateManyWithoutQuizNestedInput = {
    create?: XOR<QuizAttemptCreateWithoutQuizInput, QuizAttemptUncheckedCreateWithoutQuizInput> | QuizAttemptCreateWithoutQuizInput[] | QuizAttemptUncheckedCreateWithoutQuizInput[]
    connectOrCreate?: QuizAttemptCreateOrConnectWithoutQuizInput | QuizAttemptCreateOrConnectWithoutQuizInput[]
    upsert?: QuizAttemptUpsertWithWhereUniqueWithoutQuizInput | QuizAttemptUpsertWithWhereUniqueWithoutQuizInput[]
    createMany?: QuizAttemptCreateManyQuizInputEnvelope
    set?: QuizAttemptWhereUniqueInput | QuizAttemptWhereUniqueInput[]
    disconnect?: QuizAttemptWhereUniqueInput | QuizAttemptWhereUniqueInput[]
    delete?: QuizAttemptWhereUniqueInput | QuizAttemptWhereUniqueInput[]
    connect?: QuizAttemptWhereUniqueInput | QuizAttemptWhereUniqueInput[]
    update?: QuizAttemptUpdateWithWhereUniqueWithoutQuizInput | QuizAttemptUpdateWithWhereUniqueWithoutQuizInput[]
    updateMany?: QuizAttemptUpdateManyWithWhereWithoutQuizInput | QuizAttemptUpdateManyWithWhereWithoutQuizInput[]
    deleteMany?: QuizAttemptScalarWhereInput | QuizAttemptScalarWhereInput[]
  }

  export type QuizAttemptUncheckedUpdateManyWithoutQuizNestedInput = {
    create?: XOR<QuizAttemptCreateWithoutQuizInput, QuizAttemptUncheckedCreateWithoutQuizInput> | QuizAttemptCreateWithoutQuizInput[] | QuizAttemptUncheckedCreateWithoutQuizInput[]
    connectOrCreate?: QuizAttemptCreateOrConnectWithoutQuizInput | QuizAttemptCreateOrConnectWithoutQuizInput[]
    upsert?: QuizAttemptUpsertWithWhereUniqueWithoutQuizInput | QuizAttemptUpsertWithWhereUniqueWithoutQuizInput[]
    createMany?: QuizAttemptCreateManyQuizInputEnvelope
    set?: QuizAttemptWhereUniqueInput | QuizAttemptWhereUniqueInput[]
    disconnect?: QuizAttemptWhereUniqueInput | QuizAttemptWhereUniqueInput[]
    delete?: QuizAttemptWhereUniqueInput | QuizAttemptWhereUniqueInput[]
    connect?: QuizAttemptWhereUniqueInput | QuizAttemptWhereUniqueInput[]
    update?: QuizAttemptUpdateWithWhereUniqueWithoutQuizInput | QuizAttemptUpdateWithWhereUniqueWithoutQuizInput[]
    updateMany?: QuizAttemptUpdateManyWithWhereWithoutQuizInput | QuizAttemptUpdateManyWithWhereWithoutQuizInput[]
    deleteMany?: QuizAttemptScalarWhereInput | QuizAttemptScalarWhereInput[]
  }

  export type UserCreateNestedOneWithoutQuizAttemptsInput = {
    create?: XOR<UserCreateWithoutQuizAttemptsInput, UserUncheckedCreateWithoutQuizAttemptsInput>
    connectOrCreate?: UserCreateOrConnectWithoutQuizAttemptsInput
    connect?: UserWhereUniqueInput
  }

  export type QuizCreateNestedOneWithoutAttemptsInput = {
    create?: XOR<QuizCreateWithoutAttemptsInput, QuizUncheckedCreateWithoutAttemptsInput>
    connectOrCreate?: QuizCreateOrConnectWithoutAttemptsInput
    connect?: QuizWhereUniqueInput
  }

  export type UserUpdateOneRequiredWithoutQuizAttemptsNestedInput = {
    create?: XOR<UserCreateWithoutQuizAttemptsInput, UserUncheckedCreateWithoutQuizAttemptsInput>
    connectOrCreate?: UserCreateOrConnectWithoutQuizAttemptsInput
    upsert?: UserUpsertWithoutQuizAttemptsInput
    connect?: UserWhereUniqueInput
    update?: XOR<XOR<UserUpdateToOneWithWhereWithoutQuizAttemptsInput, UserUpdateWithoutQuizAttemptsInput>, UserUncheckedUpdateWithoutQuizAttemptsInput>
  }

  export type QuizUpdateOneRequiredWithoutAttemptsNestedInput = {
    create?: XOR<QuizCreateWithoutAttemptsInput, QuizUncheckedCreateWithoutAttemptsInput>
    connectOrCreate?: QuizCreateOrConnectWithoutAttemptsInput
    upsert?: QuizUpsertWithoutAttemptsInput
    connect?: QuizWhereUniqueInput
    update?: XOR<XOR<QuizUpdateToOneWithWhereWithoutAttemptsInput, QuizUpdateWithoutAttemptsInput>, QuizUncheckedUpdateWithoutAttemptsInput>
  }

  export type UserCreateNestedOneWithoutBadgesInput = {
    create?: XOR<UserCreateWithoutBadgesInput, UserUncheckedCreateWithoutBadgesInput>
    connectOrCreate?: UserCreateOrConnectWithoutBadgesInput
    connect?: UserWhereUniqueInput
  }

  export type UserUpdateOneRequiredWithoutBadgesNestedInput = {
    create?: XOR<UserCreateWithoutBadgesInput, UserUncheckedCreateWithoutBadgesInput>
    connectOrCreate?: UserCreateOrConnectWithoutBadgesInput
    upsert?: UserUpsertWithoutBadgesInput
    connect?: UserWhereUniqueInput
    update?: XOR<XOR<UserUpdateToOneWithWhereWithoutBadgesInput, UserUpdateWithoutBadgesInput>, UserUncheckedUpdateWithoutBadgesInput>
  }

  export type ApiCallCreateNestedManyWithoutApiKeyInput = {
    create?: XOR<ApiCallCreateWithoutApiKeyInput, ApiCallUncheckedCreateWithoutApiKeyInput> | ApiCallCreateWithoutApiKeyInput[] | ApiCallUncheckedCreateWithoutApiKeyInput[]
    connectOrCreate?: ApiCallCreateOrConnectWithoutApiKeyInput | ApiCallCreateOrConnectWithoutApiKeyInput[]
    createMany?: ApiCallCreateManyApiKeyInputEnvelope
    connect?: ApiCallWhereUniqueInput | ApiCallWhereUniqueInput[]
  }

  export type ApiCallUncheckedCreateNestedManyWithoutApiKeyInput = {
    create?: XOR<ApiCallCreateWithoutApiKeyInput, ApiCallUncheckedCreateWithoutApiKeyInput> | ApiCallCreateWithoutApiKeyInput[] | ApiCallUncheckedCreateWithoutApiKeyInput[]
    connectOrCreate?: ApiCallCreateOrConnectWithoutApiKeyInput | ApiCallCreateOrConnectWithoutApiKeyInput[]
    createMany?: ApiCallCreateManyApiKeyInputEnvelope
    connect?: ApiCallWhereUniqueInput | ApiCallWhereUniqueInput[]
  }

  export type ApiCallUpdateManyWithoutApiKeyNestedInput = {
    create?: XOR<ApiCallCreateWithoutApiKeyInput, ApiCallUncheckedCreateWithoutApiKeyInput> | ApiCallCreateWithoutApiKeyInput[] | ApiCallUncheckedCreateWithoutApiKeyInput[]
    connectOrCreate?: ApiCallCreateOrConnectWithoutApiKeyInput | ApiCallCreateOrConnectWithoutApiKeyInput[]
    upsert?: ApiCallUpsertWithWhereUniqueWithoutApiKeyInput | ApiCallUpsertWithWhereUniqueWithoutApiKeyInput[]
    createMany?: ApiCallCreateManyApiKeyInputEnvelope
    set?: ApiCallWhereUniqueInput | ApiCallWhereUniqueInput[]
    disconnect?: ApiCallWhereUniqueInput | ApiCallWhereUniqueInput[]
    delete?: ApiCallWhereUniqueInput | ApiCallWhereUniqueInput[]
    connect?: ApiCallWhereUniqueInput | ApiCallWhereUniqueInput[]
    update?: ApiCallUpdateWithWhereUniqueWithoutApiKeyInput | ApiCallUpdateWithWhereUniqueWithoutApiKeyInput[]
    updateMany?: ApiCallUpdateManyWithWhereWithoutApiKeyInput | ApiCallUpdateManyWithWhereWithoutApiKeyInput[]
    deleteMany?: ApiCallScalarWhereInput | ApiCallScalarWhereInput[]
  }

  export type ApiCallUncheckedUpdateManyWithoutApiKeyNestedInput = {
    create?: XOR<ApiCallCreateWithoutApiKeyInput, ApiCallUncheckedCreateWithoutApiKeyInput> | ApiCallCreateWithoutApiKeyInput[] | ApiCallUncheckedCreateWithoutApiKeyInput[]
    connectOrCreate?: ApiCallCreateOrConnectWithoutApiKeyInput | ApiCallCreateOrConnectWithoutApiKeyInput[]
    upsert?: ApiCallUpsertWithWhereUniqueWithoutApiKeyInput | ApiCallUpsertWithWhereUniqueWithoutApiKeyInput[]
    createMany?: ApiCallCreateManyApiKeyInputEnvelope
    set?: ApiCallWhereUniqueInput | ApiCallWhereUniqueInput[]
    disconnect?: ApiCallWhereUniqueInput | ApiCallWhereUniqueInput[]
    delete?: ApiCallWhereUniqueInput | ApiCallWhereUniqueInput[]
    connect?: ApiCallWhereUniqueInput | ApiCallWhereUniqueInput[]
    update?: ApiCallUpdateWithWhereUniqueWithoutApiKeyInput | ApiCallUpdateWithWhereUniqueWithoutApiKeyInput[]
    updateMany?: ApiCallUpdateManyWithWhereWithoutApiKeyInput | ApiCallUpdateManyWithWhereWithoutApiKeyInput[]
    deleteMany?: ApiCallScalarWhereInput | ApiCallScalarWhereInput[]
  }

  export type ApiKeyCreateNestedOneWithoutChamadasInput = {
    create?: XOR<ApiKeyCreateWithoutChamadasInput, ApiKeyUncheckedCreateWithoutChamadasInput>
    connectOrCreate?: ApiKeyCreateOrConnectWithoutChamadasInput
    connect?: ApiKeyWhereUniqueInput
  }

  export type ApiKeyUpdateOneRequiredWithoutChamadasNestedInput = {
    create?: XOR<ApiKeyCreateWithoutChamadasInput, ApiKeyUncheckedCreateWithoutChamadasInput>
    connectOrCreate?: ApiKeyCreateOrConnectWithoutChamadasInput
    upsert?: ApiKeyUpsertWithoutChamadasInput
    connect?: ApiKeyWhereUniqueInput
    update?: XOR<XOR<ApiKeyUpdateToOneWithWhereWithoutChamadasInput, ApiKeyUpdateWithoutChamadasInput>, ApiKeyUncheckedUpdateWithoutChamadasInput>
  }

  export type InsurancePolicyCreateNestedManyWithoutProductInput = {
    create?: XOR<InsurancePolicyCreateWithoutProductInput, InsurancePolicyUncheckedCreateWithoutProductInput> | InsurancePolicyCreateWithoutProductInput[] | InsurancePolicyUncheckedCreateWithoutProductInput[]
    connectOrCreate?: InsurancePolicyCreateOrConnectWithoutProductInput | InsurancePolicyCreateOrConnectWithoutProductInput[]
    createMany?: InsurancePolicyCreateManyProductInputEnvelope
    connect?: InsurancePolicyWhereUniqueInput | InsurancePolicyWhereUniqueInput[]
  }

  export type InsurancePolicyUncheckedCreateNestedManyWithoutProductInput = {
    create?: XOR<InsurancePolicyCreateWithoutProductInput, InsurancePolicyUncheckedCreateWithoutProductInput> | InsurancePolicyCreateWithoutProductInput[] | InsurancePolicyUncheckedCreateWithoutProductInput[]
    connectOrCreate?: InsurancePolicyCreateOrConnectWithoutProductInput | InsurancePolicyCreateOrConnectWithoutProductInput[]
    createMany?: InsurancePolicyCreateManyProductInputEnvelope
    connect?: InsurancePolicyWhereUniqueInput | InsurancePolicyWhereUniqueInput[]
  }

  export type InsurancePolicyUpdateManyWithoutProductNestedInput = {
    create?: XOR<InsurancePolicyCreateWithoutProductInput, InsurancePolicyUncheckedCreateWithoutProductInput> | InsurancePolicyCreateWithoutProductInput[] | InsurancePolicyUncheckedCreateWithoutProductInput[]
    connectOrCreate?: InsurancePolicyCreateOrConnectWithoutProductInput | InsurancePolicyCreateOrConnectWithoutProductInput[]
    upsert?: InsurancePolicyUpsertWithWhereUniqueWithoutProductInput | InsurancePolicyUpsertWithWhereUniqueWithoutProductInput[]
    createMany?: InsurancePolicyCreateManyProductInputEnvelope
    set?: InsurancePolicyWhereUniqueInput | InsurancePolicyWhereUniqueInput[]
    disconnect?: InsurancePolicyWhereUniqueInput | InsurancePolicyWhereUniqueInput[]
    delete?: InsurancePolicyWhereUniqueInput | InsurancePolicyWhereUniqueInput[]
    connect?: InsurancePolicyWhereUniqueInput | InsurancePolicyWhereUniqueInput[]
    update?: InsurancePolicyUpdateWithWhereUniqueWithoutProductInput | InsurancePolicyUpdateWithWhereUniqueWithoutProductInput[]
    updateMany?: InsurancePolicyUpdateManyWithWhereWithoutProductInput | InsurancePolicyUpdateManyWithWhereWithoutProductInput[]
    deleteMany?: InsurancePolicyScalarWhereInput | InsurancePolicyScalarWhereInput[]
  }

  export type InsurancePolicyUncheckedUpdateManyWithoutProductNestedInput = {
    create?: XOR<InsurancePolicyCreateWithoutProductInput, InsurancePolicyUncheckedCreateWithoutProductInput> | InsurancePolicyCreateWithoutProductInput[] | InsurancePolicyUncheckedCreateWithoutProductInput[]
    connectOrCreate?: InsurancePolicyCreateOrConnectWithoutProductInput | InsurancePolicyCreateOrConnectWithoutProductInput[]
    upsert?: InsurancePolicyUpsertWithWhereUniqueWithoutProductInput | InsurancePolicyUpsertWithWhereUniqueWithoutProductInput[]
    createMany?: InsurancePolicyCreateManyProductInputEnvelope
    set?: InsurancePolicyWhereUniqueInput | InsurancePolicyWhereUniqueInput[]
    disconnect?: InsurancePolicyWhereUniqueInput | InsurancePolicyWhereUniqueInput[]
    delete?: InsurancePolicyWhereUniqueInput | InsurancePolicyWhereUniqueInput[]
    connect?: InsurancePolicyWhereUniqueInput | InsurancePolicyWhereUniqueInput[]
    update?: InsurancePolicyUpdateWithWhereUniqueWithoutProductInput | InsurancePolicyUpdateWithWhereUniqueWithoutProductInput[]
    updateMany?: InsurancePolicyUpdateManyWithWhereWithoutProductInput | InsurancePolicyUpdateManyWithWhereWithoutProductInput[]
    deleteMany?: InsurancePolicyScalarWhereInput | InsurancePolicyScalarWhereInput[]
  }

  export type UserCreateNestedOneWithoutInsurancePoliciesInput = {
    create?: XOR<UserCreateWithoutInsurancePoliciesInput, UserUncheckedCreateWithoutInsurancePoliciesInput>
    connectOrCreate?: UserCreateOrConnectWithoutInsurancePoliciesInput
    connect?: UserWhereUniqueInput
  }

  export type InsuranceProductCreateNestedOneWithoutPoliciesInput = {
    create?: XOR<InsuranceProductCreateWithoutPoliciesInput, InsuranceProductUncheckedCreateWithoutPoliciesInput>
    connectOrCreate?: InsuranceProductCreateOrConnectWithoutPoliciesInput
    connect?: InsuranceProductWhereUniqueInput
  }

  export type UserUpdateOneRequiredWithoutInsurancePoliciesNestedInput = {
    create?: XOR<UserCreateWithoutInsurancePoliciesInput, UserUncheckedCreateWithoutInsurancePoliciesInput>
    connectOrCreate?: UserCreateOrConnectWithoutInsurancePoliciesInput
    upsert?: UserUpsertWithoutInsurancePoliciesInput
    connect?: UserWhereUniqueInput
    update?: XOR<XOR<UserUpdateToOneWithWhereWithoutInsurancePoliciesInput, UserUpdateWithoutInsurancePoliciesInput>, UserUncheckedUpdateWithoutInsurancePoliciesInput>
  }

  export type InsuranceProductUpdateOneRequiredWithoutPoliciesNestedInput = {
    create?: XOR<InsuranceProductCreateWithoutPoliciesInput, InsuranceProductUncheckedCreateWithoutPoliciesInput>
    connectOrCreate?: InsuranceProductCreateOrConnectWithoutPoliciesInput
    upsert?: InsuranceProductUpsertWithoutPoliciesInput
    connect?: InsuranceProductWhereUniqueInput
    update?: XOR<XOR<InsuranceProductUpdateToOneWithWhereWithoutPoliciesInput, InsuranceProductUpdateWithoutPoliciesInput>, InsuranceProductUncheckedUpdateWithoutPoliciesInput>
  }

  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 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 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 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 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 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 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 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 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 NestedBoolFilter<$PrismaModel = never> = {
    equals?: boolean | BooleanFieldRefInput<$PrismaModel>
    not?: NestedBoolFilter<$PrismaModel> | boolean
  }

  export type NestedBoolWithAggregatesFilter<$PrismaModel = never> = {
    equals?: boolean | BooleanFieldRefInput<$PrismaModel>
    not?: NestedBoolWithAggregatesFilter<$PrismaModel> | boolean
    _count?: NestedIntFilter<$PrismaModel>
    _min?: NestedBoolFilter<$PrismaModel>
    _max?: NestedBoolFilter<$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 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 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 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 UserCreateWithoutReferidosInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referredBy?: UserCreateNestedOneWithoutReferidosInput
    gruposCriados?: GroupCreateNestedManyWithoutCriadorInput
    memberships?: MembershipCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionCreateNestedManyWithoutUserInput
    cashouts?: CashoutCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationCreateNestedManyWithoutUserInput
    otps?: OtpCreateNestedManyWithoutUserInput
    sessions?: SessionCreateNestedManyWithoutUserInput
    notifications?: NotificationCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptCreateNestedManyWithoutUserInput
    badges?: BadgeCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyCreateNestedManyWithoutUserInput
  }

  export type UserUncheckedCreateWithoutReferidosInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    referredById?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    gruposCriados?: GroupUncheckedCreateNestedManyWithoutCriadorInput
    memberships?: MembershipUncheckedCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionUncheckedCreateNestedManyWithoutUserInput
    cashouts?: CashoutUncheckedCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanUncheckedCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventUncheckedCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationUncheckedCreateNestedManyWithoutUserInput
    otps?: OtpUncheckedCreateNestedManyWithoutUserInput
    sessions?: SessionUncheckedCreateNestedManyWithoutUserInput
    notifications?: NotificationUncheckedCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionUncheckedCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteUncheckedCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationUncheckedCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogUncheckedCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationUncheckedCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountUncheckedCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralUncheckedCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralUncheckedCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptUncheckedCreateNestedManyWithoutUserInput
    badges?: BadgeUncheckedCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyUncheckedCreateNestedManyWithoutUserInput
  }

  export type UserCreateOrConnectWithoutReferidosInput = {
    where: UserWhereUniqueInput
    create: XOR<UserCreateWithoutReferidosInput, UserUncheckedCreateWithoutReferidosInput>
  }

  export type UserCreateWithoutReferredByInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referidos?: UserCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupCreateNestedManyWithoutCriadorInput
    memberships?: MembershipCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionCreateNestedManyWithoutUserInput
    cashouts?: CashoutCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationCreateNestedManyWithoutUserInput
    otps?: OtpCreateNestedManyWithoutUserInput
    sessions?: SessionCreateNestedManyWithoutUserInput
    notifications?: NotificationCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptCreateNestedManyWithoutUserInput
    badges?: BadgeCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyCreateNestedManyWithoutUserInput
  }

  export type UserUncheckedCreateWithoutReferredByInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referidos?: UserUncheckedCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupUncheckedCreateNestedManyWithoutCriadorInput
    memberships?: MembershipUncheckedCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionUncheckedCreateNestedManyWithoutUserInput
    cashouts?: CashoutUncheckedCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanUncheckedCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventUncheckedCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationUncheckedCreateNestedManyWithoutUserInput
    otps?: OtpUncheckedCreateNestedManyWithoutUserInput
    sessions?: SessionUncheckedCreateNestedManyWithoutUserInput
    notifications?: NotificationUncheckedCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionUncheckedCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteUncheckedCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationUncheckedCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogUncheckedCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationUncheckedCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountUncheckedCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralUncheckedCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralUncheckedCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptUncheckedCreateNestedManyWithoutUserInput
    badges?: BadgeUncheckedCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyUncheckedCreateNestedManyWithoutUserInput
  }

  export type UserCreateOrConnectWithoutReferredByInput = {
    where: UserWhereUniqueInput
    create: XOR<UserCreateWithoutReferredByInput, UserUncheckedCreateWithoutReferredByInput>
  }

  export type UserCreateManyReferredByInputEnvelope = {
    data: UserCreateManyReferredByInput | UserCreateManyReferredByInput[]
    skipDuplicates?: boolean
  }

  export type GroupCreateWithoutCriadorInput = {
    id?: string
    nome: string
    descricao?: string | null
    numMembros: number
    valorContribuicaoMensal: number
    taxaPrincipalAplicada: number
    reservaTecnicaAplicada: number
    periodicidade?: string
    tipo?: string
    pais?: string
    moeda?: string
    status?: string
    dataInicio?: Date | string | null
    dataFimPrevista?: Date | string | null
    cicloAtual?: number
    totalCiclos: number
    createdAt?: Date | string
    updatedAt?: Date | string
    memberships?: MembershipCreateNestedManyWithoutGroupInput
    monthlyCycles?: MonthlyCycleCreateNestedManyWithoutGroupInput
    invites?: InviteCreateNestedManyWithoutGroupInput
    candidaturas?: GroupApplicationCreateNestedManyWithoutGroupInput
  }

  export type GroupUncheckedCreateWithoutCriadorInput = {
    id?: string
    nome: string
    descricao?: string | null
    numMembros: number
    valorContribuicaoMensal: number
    taxaPrincipalAplicada: number
    reservaTecnicaAplicada: number
    periodicidade?: string
    tipo?: string
    pais?: string
    moeda?: string
    status?: string
    dataInicio?: Date | string | null
    dataFimPrevista?: Date | string | null
    cicloAtual?: number
    totalCiclos: number
    createdAt?: Date | string
    updatedAt?: Date | string
    memberships?: MembershipUncheckedCreateNestedManyWithoutGroupInput
    monthlyCycles?: MonthlyCycleUncheckedCreateNestedManyWithoutGroupInput
    invites?: InviteUncheckedCreateNestedManyWithoutGroupInput
    candidaturas?: GroupApplicationUncheckedCreateNestedManyWithoutGroupInput
  }

  export type GroupCreateOrConnectWithoutCriadorInput = {
    where: GroupWhereUniqueInput
    create: XOR<GroupCreateWithoutCriadorInput, GroupUncheckedCreateWithoutCriadorInput>
  }

  export type GroupCreateManyCriadorInputEnvelope = {
    data: GroupCreateManyCriadorInput | GroupCreateManyCriadorInput[]
    skipDuplicates?: boolean
  }

  export type MembershipCreateWithoutUserInput = {
    id?: string
    posicaoRotacao?: number | null
    status?: string
    necessidadeUrgente?: boolean
    dataJuncao?: Date | string
    mesRecepcaoPrevisto?: string | null
    group: GroupCreateNestedOneWithoutMembershipsInput
    monthlyCyclesBeneficiario?: MonthlyCycleCreateNestedManyWithoutBeneficiarioMembershipInput
    contribuicoes?: ContributionCreateNestedManyWithoutMembershipInput
  }

  export type MembershipUncheckedCreateWithoutUserInput = {
    id?: string
    groupId: string
    posicaoRotacao?: number | null
    status?: string
    necessidadeUrgente?: boolean
    dataJuncao?: Date | string
    mesRecepcaoPrevisto?: string | null
    monthlyCyclesBeneficiario?: MonthlyCycleUncheckedCreateNestedManyWithoutBeneficiarioMembershipInput
    contribuicoes?: ContributionUncheckedCreateNestedManyWithoutMembershipInput
  }

  export type MembershipCreateOrConnectWithoutUserInput = {
    where: MembershipWhereUniqueInput
    create: XOR<MembershipCreateWithoutUserInput, MembershipUncheckedCreateWithoutUserInput>
  }

  export type MembershipCreateManyUserInputEnvelope = {
    data: MembershipCreateManyUserInput | MembershipCreateManyUserInput[]
    skipDuplicates?: boolean
  }

  export type ContributionCreateWithoutUserInput = {
    id?: string
    valor: number
    dataPrevista: Date | string
    dataPagamento?: Date | string | null
    status?: string
    metodoPagamento?: string | null
    referenciaBancaria?: string | null
    comprovativoUrl?: string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    membership: MembershipCreateNestedOneWithoutContribuicoesInput
    monthlyCycle: MonthlyCycleCreateNestedOneWithoutContribuicoesInput
    coverageDecision?: CoverageDecisionCreateNestedOneWithoutContributionInput
  }

  export type ContributionUncheckedCreateWithoutUserInput = {
    id?: string
    membershipId: string
    monthlyCycleId: string
    valor: number
    dataPrevista: Date | string
    dataPagamento?: Date | string | null
    status?: string
    metodoPagamento?: string | null
    referenciaBancaria?: string | null
    comprovativoUrl?: string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    coverageDecision?: CoverageDecisionUncheckedCreateNestedOneWithoutContributionInput
  }

  export type ContributionCreateOrConnectWithoutUserInput = {
    where: ContributionWhereUniqueInput
    create: XOR<ContributionCreateWithoutUserInput, ContributionUncheckedCreateWithoutUserInput>
  }

  export type ContributionCreateManyUserInputEnvelope = {
    data: ContributionCreateManyUserInput | ContributionCreateManyUserInput[]
    skipDuplicates?: boolean
  }

  export type CashoutCreateWithoutBeneficiarioUserInput = {
    id?: string
    valorBruto: number
    valorTaxaPrincipal: number
    valorReservaTecnica: number
    valorLiquido: number
    dataPrevista: Date | string
    dataExecucao?: Date | string | null
    status?: string
    contaDestino?: string | null
    refTransferencia?: string | null
    parcialMotivo?: string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    monthlyCycle: MonthlyCycleCreateNestedOneWithoutCashoutInput
  }

  export type CashoutUncheckedCreateWithoutBeneficiarioUserInput = {
    id?: string
    monthlyCycleId: string
    valorBruto: number
    valorTaxaPrincipal: number
    valorReservaTecnica: number
    valorLiquido: number
    dataPrevista: Date | string
    dataExecucao?: Date | string | null
    status?: string
    contaDestino?: string | null
    refTransferencia?: string | null
    parcialMotivo?: string | null
    createdAt?: Date | string
    updatedAt?: Date | string
  }

  export type CashoutCreateOrConnectWithoutBeneficiarioUserInput = {
    where: CashoutWhereUniqueInput
    create: XOR<CashoutCreateWithoutBeneficiarioUserInput, CashoutUncheckedCreateWithoutBeneficiarioUserInput>
  }

  export type CashoutCreateManyBeneficiarioUserInputEnvelope = {
    data: CashoutCreateManyBeneficiarioUserInput | CashoutCreateManyBeneficiarioUserInput[]
    skipDuplicates?: boolean
  }

  export type LoanCreateWithoutUserInput = {
    id?: string
    contributionId?: string | null
    valorCapital: number
    taxaEmprestimo: number
    valorTotalDevido: number
    jurosMoraAcumulados?: number
    dataInicio: Date | string
    dataPagamento?: Date | string | null
    status?: string
    createdAt?: Date | string
    updatedAt?: Date | string
    monthlyCycle: MonthlyCycleCreateNestedOneWithoutLoansInput
  }

  export type LoanUncheckedCreateWithoutUserInput = {
    id?: string
    monthlyCycleId: string
    contributionId?: string | null
    valorCapital: number
    taxaEmprestimo: number
    valorTotalDevido: number
    jurosMoraAcumulados?: number
    dataInicio: Date | string
    dataPagamento?: Date | string | null
    status?: string
    createdAt?: Date | string
    updatedAt?: Date | string
  }

  export type LoanCreateOrConnectWithoutUserInput = {
    where: LoanWhereUniqueInput
    create: XOR<LoanCreateWithoutUserInput, LoanUncheckedCreateWithoutUserInput>
  }

  export type LoanCreateManyUserInputEnvelope = {
    data: LoanCreateManyUserInput | LoanCreateManyUserInput[]
    skipDuplicates?: boolean
  }

  export type ScoreEventCreateWithoutUserInput = {
    id?: string
    tipoEvento: string
    impacto: number
    descricao?: string | null
    scoreAntes: number
    scoreDepois: number
    timestamp?: Date | string
  }

  export type ScoreEventUncheckedCreateWithoutUserInput = {
    id?: string
    tipoEvento: string
    impacto: number
    descricao?: string | null
    scoreAntes: number
    scoreDepois: number
    timestamp?: Date | string
  }

  export type ScoreEventCreateOrConnectWithoutUserInput = {
    where: ScoreEventWhereUniqueInput
    create: XOR<ScoreEventCreateWithoutUserInput, ScoreEventUncheckedCreateWithoutUserInput>
  }

  export type ScoreEventCreateManyUserInputEnvelope = {
    data: ScoreEventCreateManyUserInput | ScoreEventCreateManyUserInput[]
    skipDuplicates?: boolean
  }

  export type ReintegrationCreateWithoutUserInput = {
    id?: string
    valorDividaOriginal: number
    taxaReintegracaoAplicada: number
    valorTaxaPaga: number
    dataSolicitacao?: Date | string
    dataConclusao?: Date | string | null
    status?: string
  }

  export type ReintegrationUncheckedCreateWithoutUserInput = {
    id?: string
    valorDividaOriginal: number
    taxaReintegracaoAplicada: number
    valorTaxaPaga: number
    dataSolicitacao?: Date | string
    dataConclusao?: Date | string | null
    status?: string
  }

  export type ReintegrationCreateOrConnectWithoutUserInput = {
    where: ReintegrationWhereUniqueInput
    create: XOR<ReintegrationCreateWithoutUserInput, ReintegrationUncheckedCreateWithoutUserInput>
  }

  export type ReintegrationCreateManyUserInputEnvelope = {
    data: ReintegrationCreateManyUserInput | ReintegrationCreateManyUserInput[]
    skipDuplicates?: boolean
  }

  export type OtpCreateWithoutUserInput = {
    id?: string
    telefone: string
    codigo: string
    proposito: string
    consumido?: boolean
    expiraEm: Date | string
    createdAt?: Date | string
  }

  export type OtpUncheckedCreateWithoutUserInput = {
    id?: string
    telefone: string
    codigo: string
    proposito: string
    consumido?: boolean
    expiraEm: Date | string
    createdAt?: Date | string
  }

  export type OtpCreateOrConnectWithoutUserInput = {
    where: OtpWhereUniqueInput
    create: XOR<OtpCreateWithoutUserInput, OtpUncheckedCreateWithoutUserInput>
  }

  export type OtpCreateManyUserInputEnvelope = {
    data: OtpCreateManyUserInput | OtpCreateManyUserInput[]
    skipDuplicates?: boolean
  }

  export type SessionCreateWithoutUserInput = {
    id?: string
    token: string
    expiraEm: Date | string
    createdAt?: Date | string
  }

  export type SessionUncheckedCreateWithoutUserInput = {
    id?: string
    token: string
    expiraEm: Date | string
    createdAt?: Date | string
  }

  export type SessionCreateOrConnectWithoutUserInput = {
    where: SessionWhereUniqueInput
    create: XOR<SessionCreateWithoutUserInput, SessionUncheckedCreateWithoutUserInput>
  }

  export type SessionCreateManyUserInputEnvelope = {
    data: SessionCreateManyUserInput | SessionCreateManyUserInput[]
    skipDuplicates?: boolean
  }

  export type NotificationCreateWithoutUserInput = {
    id?: string
    canal: string
    titulo: string
    corpo: string
    lida?: boolean
    metadataJson?: string | null
    createdAt?: Date | string
  }

  export type NotificationUncheckedCreateWithoutUserInput = {
    id?: string
    canal: string
    titulo: string
    corpo: string
    lida?: boolean
    metadataJson?: string | null
    createdAt?: Date | string
  }

  export type NotificationCreateOrConnectWithoutUserInput = {
    where: NotificationWhereUniqueInput
    create: XOR<NotificationCreateWithoutUserInput, NotificationUncheckedCreateWithoutUserInput>
  }

  export type NotificationCreateManyUserInputEnvelope = {
    data: NotificationCreateManyUserInput | NotificationCreateManyUserInput[]
    skipDuplicates?: boolean
  }

  export type CoverageDecisionCreateWithoutDecisorUserInput = {
    id?: string
    decisao: string
    motivo: string
    scoreNoMomento: number
    historicoInadimplencias: number
    decisorSistema?: boolean
    createdAt?: Date | string
    contribution: ContributionCreateNestedOneWithoutCoverageDecisionInput
  }

  export type CoverageDecisionUncheckedCreateWithoutDecisorUserInput = {
    id?: string
    contributionId: string
    decisao: string
    motivo: string
    scoreNoMomento: number
    historicoInadimplencias: number
    decisorSistema?: boolean
    createdAt?: Date | string
  }

  export type CoverageDecisionCreateOrConnectWithoutDecisorUserInput = {
    where: CoverageDecisionWhereUniqueInput
    create: XOR<CoverageDecisionCreateWithoutDecisorUserInput, CoverageDecisionUncheckedCreateWithoutDecisorUserInput>
  }

  export type CoverageDecisionCreateManyDecisorUserInputEnvelope = {
    data: CoverageDecisionCreateManyDecisorUserInput | CoverageDecisionCreateManyDecisorUserInput[]
    skipDuplicates?: boolean
  }

  export type InviteCreateWithoutConvidadoPorInput = {
    id?: string
    telefone: string
    email?: string | null
    token: string
    status?: string
    createdAt?: Date | string
    expiraEm: Date | string
    group: GroupCreateNestedOneWithoutInvitesInput
  }

  export type InviteUncheckedCreateWithoutConvidadoPorInput = {
    id?: string
    groupId: string
    telefone: string
    email?: string | null
    token: string
    status?: string
    createdAt?: Date | string
    expiraEm: Date | string
  }

  export type InviteCreateOrConnectWithoutConvidadoPorInput = {
    where: InviteWhereUniqueInput
    create: XOR<InviteCreateWithoutConvidadoPorInput, InviteUncheckedCreateWithoutConvidadoPorInput>
  }

  export type InviteCreateManyConvidadoPorInputEnvelope = {
    data: InviteCreateManyConvidadoPorInput | InviteCreateManyConvidadoPorInput[]
    skipDuplicates?: boolean
  }

  export type FeeConfigurationCreateWithoutCriadoPorInput = {
    id?: string
    tipoFee: string
    valor: number
    min: number
    max: number
    dataInicio: Date | string
    dataFim?: Date | string | null
    motivoMudanca?: string | null
    ativa?: boolean
    createdAt?: Date | string
  }

  export type FeeConfigurationUncheckedCreateWithoutCriadoPorInput = {
    id?: string
    tipoFee: string
    valor: number
    min: number
    max: number
    dataInicio: Date | string
    dataFim?: Date | string | null
    motivoMudanca?: string | null
    ativa?: boolean
    createdAt?: Date | string
  }

  export type FeeConfigurationCreateOrConnectWithoutCriadoPorInput = {
    where: FeeConfigurationWhereUniqueInput
    create: XOR<FeeConfigurationCreateWithoutCriadoPorInput, FeeConfigurationUncheckedCreateWithoutCriadoPorInput>
  }

  export type FeeConfigurationCreateManyCriadoPorInputEnvelope = {
    data: FeeConfigurationCreateManyCriadoPorInput | FeeConfigurationCreateManyCriadoPorInput[]
    skipDuplicates?: boolean
  }

  export type AuditLogCreateWithoutUserInput = {
    id?: string
    acao: string
    entidade: string
    entidadeId?: string | null
    dadosAntes?: string | null
    dadosDepois?: string | null
    ip?: string | null
    timestamp?: Date | string
  }

  export type AuditLogUncheckedCreateWithoutUserInput = {
    id?: string
    acao: string
    entidade: string
    entidadeId?: string | null
    dadosAntes?: string | null
    dadosDepois?: string | null
    ip?: string | null
    timestamp?: Date | string
  }

  export type AuditLogCreateOrConnectWithoutUserInput = {
    where: AuditLogWhereUniqueInput
    create: XOR<AuditLogCreateWithoutUserInput, AuditLogUncheckedCreateWithoutUserInput>
  }

  export type AuditLogCreateManyUserInputEnvelope = {
    data: AuditLogCreateManyUserInput | AuditLogCreateManyUserInput[]
    skipDuplicates?: boolean
  }

  export type CreditApplicationCreateWithoutUserInput = {
    id?: string
    valorSolicitado: number
    prazoMeses: number
    taxaJuroAplicada: number
    prestacaoMensal: number
    finalidade?: string | null
    status?: string
    scoreNoMomento: number
    motivoDecisao?: string | null
    decisaoPorId?: string | null
    dataAprovacao?: Date | string | null
    dataDesembolso?: Date | string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    prestacoes?: CreditInstallmentCreateNestedManyWithoutApplicationInput
  }

  export type CreditApplicationUncheckedCreateWithoutUserInput = {
    id?: string
    valorSolicitado: number
    prazoMeses: number
    taxaJuroAplicada: number
    prestacaoMensal: number
    finalidade?: string | null
    status?: string
    scoreNoMomento: number
    motivoDecisao?: string | null
    decisaoPorId?: string | null
    dataAprovacao?: Date | string | null
    dataDesembolso?: Date | string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    prestacoes?: CreditInstallmentUncheckedCreateNestedManyWithoutApplicationInput
  }

  export type CreditApplicationCreateOrConnectWithoutUserInput = {
    where: CreditApplicationWhereUniqueInput
    create: XOR<CreditApplicationCreateWithoutUserInput, CreditApplicationUncheckedCreateWithoutUserInput>
  }

  export type CreditApplicationCreateManyUserInputEnvelope = {
    data: CreditApplicationCreateManyUserInput | CreditApplicationCreateManyUserInput[]
    skipDuplicates?: boolean
  }

  export type SavingsAccountCreateWithoutUserInput = {
    id?: string
    nome: string
    objectivo?: string | null
    meta?: number | null
    saldo?: number
    taxaRemuneracaoAnual?: number
    imobilizacaoMeses?: number
    status?: string
    ultimaCapitalizacao?: Date | string
    createdAt?: Date | string
    updatedAt?: Date | string
    movimentos?: SavingsMovementCreateNestedManyWithoutAccountInput
  }

  export type SavingsAccountUncheckedCreateWithoutUserInput = {
    id?: string
    nome: string
    objectivo?: string | null
    meta?: number | null
    saldo?: number
    taxaRemuneracaoAnual?: number
    imobilizacaoMeses?: number
    status?: string
    ultimaCapitalizacao?: Date | string
    createdAt?: Date | string
    updatedAt?: Date | string
    movimentos?: SavingsMovementUncheckedCreateNestedManyWithoutAccountInput
  }

  export type SavingsAccountCreateOrConnectWithoutUserInput = {
    where: SavingsAccountWhereUniqueInput
    create: XOR<SavingsAccountCreateWithoutUserInput, SavingsAccountUncheckedCreateWithoutUserInput>
  }

  export type SavingsAccountCreateManyUserInputEnvelope = {
    data: SavingsAccountCreateManyUserInput | SavingsAccountCreateManyUserInput[]
    skipDuplicates?: boolean
  }

  export type ReferralCreateWithoutReferrerInput = {
    id?: string
    codigo: string
    canal?: string | null
    status?: string
    recompensa?: number
    recompensaPaga?: boolean
    dataRegisto?: Date | string | null
    dataActivacao?: Date | string | null
    createdAt?: Date | string
    referredUser?: UserCreateNestedOneWithoutReferralAsReferredInput
  }

  export type ReferralUncheckedCreateWithoutReferrerInput = {
    id?: string
    referredUserId?: string | null
    codigo: string
    canal?: string | null
    status?: string
    recompensa?: number
    recompensaPaga?: boolean
    dataRegisto?: Date | string | null
    dataActivacao?: Date | string | null
    createdAt?: Date | string
  }

  export type ReferralCreateOrConnectWithoutReferrerInput = {
    where: ReferralWhereUniqueInput
    create: XOR<ReferralCreateWithoutReferrerInput, ReferralUncheckedCreateWithoutReferrerInput>
  }

  export type ReferralCreateManyReferrerInputEnvelope = {
    data: ReferralCreateManyReferrerInput | ReferralCreateManyReferrerInput[]
    skipDuplicates?: boolean
  }

  export type ReferralCreateWithoutReferredUserInput = {
    id?: string
    codigo: string
    canal?: string | null
    status?: string
    recompensa?: number
    recompensaPaga?: boolean
    dataRegisto?: Date | string | null
    dataActivacao?: Date | string | null
    createdAt?: Date | string
    referrer: UserCreateNestedOneWithoutReferralsCreatedInput
  }

  export type ReferralUncheckedCreateWithoutReferredUserInput = {
    id?: string
    referrerUserId: string
    codigo: string
    canal?: string | null
    status?: string
    recompensa?: number
    recompensaPaga?: boolean
    dataRegisto?: Date | string | null
    dataActivacao?: Date | string | null
    createdAt?: Date | string
  }

  export type ReferralCreateOrConnectWithoutReferredUserInput = {
    where: ReferralWhereUniqueInput
    create: XOR<ReferralCreateWithoutReferredUserInput, ReferralUncheckedCreateWithoutReferredUserInput>
  }

  export type ReferralCreateManyReferredUserInputEnvelope = {
    data: ReferralCreateManyReferredUserInput | ReferralCreateManyReferredUserInput[]
    skipDuplicates?: boolean
  }

  export type QuizAttemptCreateWithoutUserInput = {
    id?: string
    acertos: number
    total: number
    pontosGanhos: number
    respostasJson?: string | null
    createdAt?: Date | string
    quiz: QuizCreateNestedOneWithoutAttemptsInput
  }

  export type QuizAttemptUncheckedCreateWithoutUserInput = {
    id?: string
    quizId: string
    acertos: number
    total: number
    pontosGanhos: number
    respostasJson?: string | null
    createdAt?: Date | string
  }

  export type QuizAttemptCreateOrConnectWithoutUserInput = {
    where: QuizAttemptWhereUniqueInput
    create: XOR<QuizAttemptCreateWithoutUserInput, QuizAttemptUncheckedCreateWithoutUserInput>
  }

  export type QuizAttemptCreateManyUserInputEnvelope = {
    data: QuizAttemptCreateManyUserInput | QuizAttemptCreateManyUserInput[]
    skipDuplicates?: boolean
  }

  export type BadgeCreateWithoutUserInput = {
    id?: string
    tipo: string
    titulo: string
    descricao?: string | null
    createdAt?: Date | string
  }

  export type BadgeUncheckedCreateWithoutUserInput = {
    id?: string
    tipo: string
    titulo: string
    descricao?: string | null
    createdAt?: Date | string
  }

  export type BadgeCreateOrConnectWithoutUserInput = {
    where: BadgeWhereUniqueInput
    create: XOR<BadgeCreateWithoutUserInput, BadgeUncheckedCreateWithoutUserInput>
  }

  export type BadgeCreateManyUserInputEnvelope = {
    data: BadgeCreateManyUserInput | BadgeCreateManyUserInput[]
    skipDuplicates?: boolean
  }

  export type InsurancePolicyCreateWithoutUserInput = {
    id?: string
    status?: string
    dataInicio?: Date | string
    premiumPago?: number
    proximaCobranca?: Date | string | null
    product: InsuranceProductCreateNestedOneWithoutPoliciesInput
  }

  export type InsurancePolicyUncheckedCreateWithoutUserInput = {
    id?: string
    productId: string
    status?: string
    dataInicio?: Date | string
    premiumPago?: number
    proximaCobranca?: Date | string | null
  }

  export type InsurancePolicyCreateOrConnectWithoutUserInput = {
    where: InsurancePolicyWhereUniqueInput
    create: XOR<InsurancePolicyCreateWithoutUserInput, InsurancePolicyUncheckedCreateWithoutUserInput>
  }

  export type InsurancePolicyCreateManyUserInputEnvelope = {
    data: InsurancePolicyCreateManyUserInput | InsurancePolicyCreateManyUserInput[]
    skipDuplicates?: boolean
  }

  export type UserUpsertWithoutReferidosInput = {
    update: XOR<UserUpdateWithoutReferidosInput, UserUncheckedUpdateWithoutReferidosInput>
    create: XOR<UserCreateWithoutReferidosInput, UserUncheckedCreateWithoutReferidosInput>
    where?: UserWhereInput
  }

  export type UserUpdateToOneWithWhereWithoutReferidosInput = {
    where?: UserWhereInput
    data: XOR<UserUpdateWithoutReferidosInput, UserUncheckedUpdateWithoutReferidosInput>
  }

  export type UserUpdateWithoutReferidosInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referredBy?: UserUpdateOneWithoutReferidosNestedInput
    gruposCriados?: GroupUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUpdateManyWithoutUserNestedInput
    otps?: OtpUpdateManyWithoutUserNestedInput
    sessions?: SessionUpdateManyWithoutUserNestedInput
    notifications?: NotificationUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUpdateManyWithoutUserNestedInput
    badges?: BadgeUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUpdateManyWithoutUserNestedInput
  }

  export type UserUncheckedUpdateWithoutReferidosInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    referredById?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    gruposCriados?: GroupUncheckedUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUncheckedUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUncheckedUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUncheckedUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUncheckedUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUncheckedUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUncheckedUpdateManyWithoutUserNestedInput
    otps?: OtpUncheckedUpdateManyWithoutUserNestedInput
    sessions?: SessionUncheckedUpdateManyWithoutUserNestedInput
    notifications?: NotificationUncheckedUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUncheckedUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUncheckedUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUncheckedUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUncheckedUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUncheckedUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUncheckedUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUncheckedUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUncheckedUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUncheckedUpdateManyWithoutUserNestedInput
    badges?: BadgeUncheckedUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUncheckedUpdateManyWithoutUserNestedInput
  }

  export type UserUpsertWithWhereUniqueWithoutReferredByInput = {
    where: UserWhereUniqueInput
    update: XOR<UserUpdateWithoutReferredByInput, UserUncheckedUpdateWithoutReferredByInput>
    create: XOR<UserCreateWithoutReferredByInput, UserUncheckedCreateWithoutReferredByInput>
  }

  export type UserUpdateWithWhereUniqueWithoutReferredByInput = {
    where: UserWhereUniqueInput
    data: XOR<UserUpdateWithoutReferredByInput, UserUncheckedUpdateWithoutReferredByInput>
  }

  export type UserUpdateManyWithWhereWithoutReferredByInput = {
    where: UserScalarWhereInput
    data: XOR<UserUpdateManyMutationInput, UserUncheckedUpdateManyWithoutReferredByInput>
  }

  export type UserScalarWhereInput = {
    AND?: UserScalarWhereInput | UserScalarWhereInput[]
    OR?: UserScalarWhereInput[]
    NOT?: UserScalarWhereInput | UserScalarWhereInput[]
    id?: StringFilter<"User"> | string
    nome?: StringFilter<"User"> | string
    telefone?: StringFilter<"User"> | string
    email?: StringFilter<"User"> | string
    passwordHash?: StringFilter<"User"> | string
    bi?: StringNullableFilter<"User"> | string | null
    dataNascimento?: DateTimeNullableFilter<"User"> | Date | string | null
    provincia?: StringNullableFilter<"User"> | string | null
    pais?: StringFilter<"User"> | string
    moedaPreferida?: StringFilter<"User"> | string
    fotoPerfilUrl?: StringNullableFilter<"User"> | string | null
    kycStatus?: StringFilter<"User"> | string
    kycNivel?: IntFilter<"User"> | number
    kycDataJson?: StringNullableFilter<"User"> | string | null
    status?: StringFilter<"User"> | string
    scoreAtual?: IntFilter<"User"> | number
    role?: StringFilter<"User"> | string
    referralCode?: StringNullableFilter<"User"> | string | null
    referredById?: StringNullableFilter<"User"> | string | null
    pontosEducacao?: IntFilter<"User"> | number
    createdAt?: DateTimeFilter<"User"> | Date | string
    updatedAt?: DateTimeFilter<"User"> | Date | string
  }

  export type GroupUpsertWithWhereUniqueWithoutCriadorInput = {
    where: GroupWhereUniqueInput
    update: XOR<GroupUpdateWithoutCriadorInput, GroupUncheckedUpdateWithoutCriadorInput>
    create: XOR<GroupCreateWithoutCriadorInput, GroupUncheckedCreateWithoutCriadorInput>
  }

  export type GroupUpdateWithWhereUniqueWithoutCriadorInput = {
    where: GroupWhereUniqueInput
    data: XOR<GroupUpdateWithoutCriadorInput, GroupUncheckedUpdateWithoutCriadorInput>
  }

  export type GroupUpdateManyWithWhereWithoutCriadorInput = {
    where: GroupScalarWhereInput
    data: XOR<GroupUpdateManyMutationInput, GroupUncheckedUpdateManyWithoutCriadorInput>
  }

  export type GroupScalarWhereInput = {
    AND?: GroupScalarWhereInput | GroupScalarWhereInput[]
    OR?: GroupScalarWhereInput[]
    NOT?: GroupScalarWhereInput | GroupScalarWhereInput[]
    id?: StringFilter<"Group"> | string
    nome?: StringFilter<"Group"> | string
    descricao?: StringNullableFilter<"Group"> | string | null
    criadorId?: StringFilter<"Group"> | string
    numMembros?: IntFilter<"Group"> | number
    valorContribuicaoMensal?: FloatFilter<"Group"> | number
    taxaPrincipalAplicada?: FloatFilter<"Group"> | number
    reservaTecnicaAplicada?: FloatFilter<"Group"> | number
    periodicidade?: StringFilter<"Group"> | string
    tipo?: StringFilter<"Group"> | string
    pais?: StringFilter<"Group"> | string
    moeda?: StringFilter<"Group"> | string
    status?: StringFilter<"Group"> | string
    dataInicio?: DateTimeNullableFilter<"Group"> | Date | string | null
    dataFimPrevista?: DateTimeNullableFilter<"Group"> | Date | string | null
    cicloAtual?: IntFilter<"Group"> | number
    totalCiclos?: IntFilter<"Group"> | number
    createdAt?: DateTimeFilter<"Group"> | Date | string
    updatedAt?: DateTimeFilter<"Group"> | Date | string
  }

  export type MembershipUpsertWithWhereUniqueWithoutUserInput = {
    where: MembershipWhereUniqueInput
    update: XOR<MembershipUpdateWithoutUserInput, MembershipUncheckedUpdateWithoutUserInput>
    create: XOR<MembershipCreateWithoutUserInput, MembershipUncheckedCreateWithoutUserInput>
  }

  export type MembershipUpdateWithWhereUniqueWithoutUserInput = {
    where: MembershipWhereUniqueInput
    data: XOR<MembershipUpdateWithoutUserInput, MembershipUncheckedUpdateWithoutUserInput>
  }

  export type MembershipUpdateManyWithWhereWithoutUserInput = {
    where: MembershipScalarWhereInput
    data: XOR<MembershipUpdateManyMutationInput, MembershipUncheckedUpdateManyWithoutUserInput>
  }

  export type MembershipScalarWhereInput = {
    AND?: MembershipScalarWhereInput | MembershipScalarWhereInput[]
    OR?: MembershipScalarWhereInput[]
    NOT?: MembershipScalarWhereInput | MembershipScalarWhereInput[]
    id?: StringFilter<"Membership"> | string
    userId?: StringFilter<"Membership"> | string
    groupId?: StringFilter<"Membership"> | string
    posicaoRotacao?: IntNullableFilter<"Membership"> | number | null
    status?: StringFilter<"Membership"> | string
    necessidadeUrgente?: BoolFilter<"Membership"> | boolean
    dataJuncao?: DateTimeFilter<"Membership"> | Date | string
    mesRecepcaoPrevisto?: StringNullableFilter<"Membership"> | string | null
  }

  export type ContributionUpsertWithWhereUniqueWithoutUserInput = {
    where: ContributionWhereUniqueInput
    update: XOR<ContributionUpdateWithoutUserInput, ContributionUncheckedUpdateWithoutUserInput>
    create: XOR<ContributionCreateWithoutUserInput, ContributionUncheckedCreateWithoutUserInput>
  }

  export type ContributionUpdateWithWhereUniqueWithoutUserInput = {
    where: ContributionWhereUniqueInput
    data: XOR<ContributionUpdateWithoutUserInput, ContributionUncheckedUpdateWithoutUserInput>
  }

  export type ContributionUpdateManyWithWhereWithoutUserInput = {
    where: ContributionScalarWhereInput
    data: XOR<ContributionUpdateManyMutationInput, ContributionUncheckedUpdateManyWithoutUserInput>
  }

  export type ContributionScalarWhereInput = {
    AND?: ContributionScalarWhereInput | ContributionScalarWhereInput[]
    OR?: ContributionScalarWhereInput[]
    NOT?: ContributionScalarWhereInput | ContributionScalarWhereInput[]
    id?: StringFilter<"Contribution"> | string
    membershipId?: StringFilter<"Contribution"> | string
    userId?: StringFilter<"Contribution"> | string
    monthlyCycleId?: StringFilter<"Contribution"> | string
    valor?: FloatFilter<"Contribution"> | number
    dataPrevista?: DateTimeFilter<"Contribution"> | Date | string
    dataPagamento?: DateTimeNullableFilter<"Contribution"> | Date | string | null
    status?: StringFilter<"Contribution"> | string
    metodoPagamento?: StringNullableFilter<"Contribution"> | string | null
    referenciaBancaria?: StringNullableFilter<"Contribution"> | string | null
    comprovativoUrl?: StringNullableFilter<"Contribution"> | string | null
    createdAt?: DateTimeFilter<"Contribution"> | Date | string
    updatedAt?: DateTimeFilter<"Contribution"> | Date | string
  }

  export type CashoutUpsertWithWhereUniqueWithoutBeneficiarioUserInput = {
    where: CashoutWhereUniqueInput
    update: XOR<CashoutUpdateWithoutBeneficiarioUserInput, CashoutUncheckedUpdateWithoutBeneficiarioUserInput>
    create: XOR<CashoutCreateWithoutBeneficiarioUserInput, CashoutUncheckedCreateWithoutBeneficiarioUserInput>
  }

  export type CashoutUpdateWithWhereUniqueWithoutBeneficiarioUserInput = {
    where: CashoutWhereUniqueInput
    data: XOR<CashoutUpdateWithoutBeneficiarioUserInput, CashoutUncheckedUpdateWithoutBeneficiarioUserInput>
  }

  export type CashoutUpdateManyWithWhereWithoutBeneficiarioUserInput = {
    where: CashoutScalarWhereInput
    data: XOR<CashoutUpdateManyMutationInput, CashoutUncheckedUpdateManyWithoutBeneficiarioUserInput>
  }

  export type CashoutScalarWhereInput = {
    AND?: CashoutScalarWhereInput | CashoutScalarWhereInput[]
    OR?: CashoutScalarWhereInput[]
    NOT?: CashoutScalarWhereInput | CashoutScalarWhereInput[]
    id?: StringFilter<"Cashout"> | string
    monthlyCycleId?: StringFilter<"Cashout"> | string
    beneficiarioUserId?: StringFilter<"Cashout"> | string
    valorBruto?: FloatFilter<"Cashout"> | number
    valorTaxaPrincipal?: FloatFilter<"Cashout"> | number
    valorReservaTecnica?: FloatFilter<"Cashout"> | number
    valorLiquido?: FloatFilter<"Cashout"> | number
    dataPrevista?: DateTimeFilter<"Cashout"> | Date | string
    dataExecucao?: DateTimeNullableFilter<"Cashout"> | Date | string | null
    status?: StringFilter<"Cashout"> | string
    contaDestino?: StringNullableFilter<"Cashout"> | string | null
    refTransferencia?: StringNullableFilter<"Cashout"> | string | null
    parcialMotivo?: StringNullableFilter<"Cashout"> | string | null
    createdAt?: DateTimeFilter<"Cashout"> | Date | string
    updatedAt?: DateTimeFilter<"Cashout"> | Date | string
  }

  export type LoanUpsertWithWhereUniqueWithoutUserInput = {
    where: LoanWhereUniqueInput
    update: XOR<LoanUpdateWithoutUserInput, LoanUncheckedUpdateWithoutUserInput>
    create: XOR<LoanCreateWithoutUserInput, LoanUncheckedCreateWithoutUserInput>
  }

  export type LoanUpdateWithWhereUniqueWithoutUserInput = {
    where: LoanWhereUniqueInput
    data: XOR<LoanUpdateWithoutUserInput, LoanUncheckedUpdateWithoutUserInput>
  }

  export type LoanUpdateManyWithWhereWithoutUserInput = {
    where: LoanScalarWhereInput
    data: XOR<LoanUpdateManyMutationInput, LoanUncheckedUpdateManyWithoutUserInput>
  }

  export type LoanScalarWhereInput = {
    AND?: LoanScalarWhereInput | LoanScalarWhereInput[]
    OR?: LoanScalarWhereInput[]
    NOT?: LoanScalarWhereInput | LoanScalarWhereInput[]
    id?: StringFilter<"Loan"> | string
    userId?: StringFilter<"Loan"> | string
    monthlyCycleId?: StringFilter<"Loan"> | string
    contributionId?: StringNullableFilter<"Loan"> | string | null
    valorCapital?: FloatFilter<"Loan"> | number
    taxaEmprestimo?: FloatFilter<"Loan"> | number
    valorTotalDevido?: FloatFilter<"Loan"> | number
    jurosMoraAcumulados?: FloatFilter<"Loan"> | number
    dataInicio?: DateTimeFilter<"Loan"> | Date | string
    dataPagamento?: DateTimeNullableFilter<"Loan"> | Date | string | null
    status?: StringFilter<"Loan"> | string
    createdAt?: DateTimeFilter<"Loan"> | Date | string
    updatedAt?: DateTimeFilter<"Loan"> | Date | string
  }

  export type ScoreEventUpsertWithWhereUniqueWithoutUserInput = {
    where: ScoreEventWhereUniqueInput
    update: XOR<ScoreEventUpdateWithoutUserInput, ScoreEventUncheckedUpdateWithoutUserInput>
    create: XOR<ScoreEventCreateWithoutUserInput, ScoreEventUncheckedCreateWithoutUserInput>
  }

  export type ScoreEventUpdateWithWhereUniqueWithoutUserInput = {
    where: ScoreEventWhereUniqueInput
    data: XOR<ScoreEventUpdateWithoutUserInput, ScoreEventUncheckedUpdateWithoutUserInput>
  }

  export type ScoreEventUpdateManyWithWhereWithoutUserInput = {
    where: ScoreEventScalarWhereInput
    data: XOR<ScoreEventUpdateManyMutationInput, ScoreEventUncheckedUpdateManyWithoutUserInput>
  }

  export type ScoreEventScalarWhereInput = {
    AND?: ScoreEventScalarWhereInput | ScoreEventScalarWhereInput[]
    OR?: ScoreEventScalarWhereInput[]
    NOT?: ScoreEventScalarWhereInput | ScoreEventScalarWhereInput[]
    id?: StringFilter<"ScoreEvent"> | string
    userId?: StringFilter<"ScoreEvent"> | string
    tipoEvento?: StringFilter<"ScoreEvent"> | string
    impacto?: IntFilter<"ScoreEvent"> | number
    descricao?: StringNullableFilter<"ScoreEvent"> | string | null
    scoreAntes?: IntFilter<"ScoreEvent"> | number
    scoreDepois?: IntFilter<"ScoreEvent"> | number
    timestamp?: DateTimeFilter<"ScoreEvent"> | Date | string
  }

  export type ReintegrationUpsertWithWhereUniqueWithoutUserInput = {
    where: ReintegrationWhereUniqueInput
    update: XOR<ReintegrationUpdateWithoutUserInput, ReintegrationUncheckedUpdateWithoutUserInput>
    create: XOR<ReintegrationCreateWithoutUserInput, ReintegrationUncheckedCreateWithoutUserInput>
  }

  export type ReintegrationUpdateWithWhereUniqueWithoutUserInput = {
    where: ReintegrationWhereUniqueInput
    data: XOR<ReintegrationUpdateWithoutUserInput, ReintegrationUncheckedUpdateWithoutUserInput>
  }

  export type ReintegrationUpdateManyWithWhereWithoutUserInput = {
    where: ReintegrationScalarWhereInput
    data: XOR<ReintegrationUpdateManyMutationInput, ReintegrationUncheckedUpdateManyWithoutUserInput>
  }

  export type ReintegrationScalarWhereInput = {
    AND?: ReintegrationScalarWhereInput | ReintegrationScalarWhereInput[]
    OR?: ReintegrationScalarWhereInput[]
    NOT?: ReintegrationScalarWhereInput | ReintegrationScalarWhereInput[]
    id?: StringFilter<"Reintegration"> | string
    userId?: StringFilter<"Reintegration"> | string
    valorDividaOriginal?: FloatFilter<"Reintegration"> | number
    taxaReintegracaoAplicada?: FloatFilter<"Reintegration"> | number
    valorTaxaPaga?: FloatFilter<"Reintegration"> | number
    dataSolicitacao?: DateTimeFilter<"Reintegration"> | Date | string
    dataConclusao?: DateTimeNullableFilter<"Reintegration"> | Date | string | null
    status?: StringFilter<"Reintegration"> | string
  }

  export type OtpUpsertWithWhereUniqueWithoutUserInput = {
    where: OtpWhereUniqueInput
    update: XOR<OtpUpdateWithoutUserInput, OtpUncheckedUpdateWithoutUserInput>
    create: XOR<OtpCreateWithoutUserInput, OtpUncheckedCreateWithoutUserInput>
  }

  export type OtpUpdateWithWhereUniqueWithoutUserInput = {
    where: OtpWhereUniqueInput
    data: XOR<OtpUpdateWithoutUserInput, OtpUncheckedUpdateWithoutUserInput>
  }

  export type OtpUpdateManyWithWhereWithoutUserInput = {
    where: OtpScalarWhereInput
    data: XOR<OtpUpdateManyMutationInput, OtpUncheckedUpdateManyWithoutUserInput>
  }

  export type OtpScalarWhereInput = {
    AND?: OtpScalarWhereInput | OtpScalarWhereInput[]
    OR?: OtpScalarWhereInput[]
    NOT?: OtpScalarWhereInput | OtpScalarWhereInput[]
    id?: StringFilter<"Otp"> | string
    userId?: StringNullableFilter<"Otp"> | string | null
    telefone?: StringFilter<"Otp"> | string
    codigo?: StringFilter<"Otp"> | string
    proposito?: StringFilter<"Otp"> | string
    consumido?: BoolFilter<"Otp"> | boolean
    expiraEm?: DateTimeFilter<"Otp"> | Date | string
    createdAt?: DateTimeFilter<"Otp"> | Date | string
  }

  export type SessionUpsertWithWhereUniqueWithoutUserInput = {
    where: SessionWhereUniqueInput
    update: XOR<SessionUpdateWithoutUserInput, SessionUncheckedUpdateWithoutUserInput>
    create: XOR<SessionCreateWithoutUserInput, SessionUncheckedCreateWithoutUserInput>
  }

  export type SessionUpdateWithWhereUniqueWithoutUserInput = {
    where: SessionWhereUniqueInput
    data: XOR<SessionUpdateWithoutUserInput, SessionUncheckedUpdateWithoutUserInput>
  }

  export type SessionUpdateManyWithWhereWithoutUserInput = {
    where: SessionScalarWhereInput
    data: XOR<SessionUpdateManyMutationInput, SessionUncheckedUpdateManyWithoutUserInput>
  }

  export type SessionScalarWhereInput = {
    AND?: SessionScalarWhereInput | SessionScalarWhereInput[]
    OR?: SessionScalarWhereInput[]
    NOT?: SessionScalarWhereInput | SessionScalarWhereInput[]
    id?: StringFilter<"Session"> | string
    userId?: StringFilter<"Session"> | string
    token?: StringFilter<"Session"> | string
    expiraEm?: DateTimeFilter<"Session"> | Date | string
    createdAt?: DateTimeFilter<"Session"> | 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
    canal?: StringFilter<"Notification"> | string
    titulo?: StringFilter<"Notification"> | string
    corpo?: StringFilter<"Notification"> | string
    lida?: BoolFilter<"Notification"> | boolean
    metadataJson?: StringNullableFilter<"Notification"> | string | null
    createdAt?: DateTimeFilter<"Notification"> | Date | string
  }

  export type CoverageDecisionUpsertWithWhereUniqueWithoutDecisorUserInput = {
    where: CoverageDecisionWhereUniqueInput
    update: XOR<CoverageDecisionUpdateWithoutDecisorUserInput, CoverageDecisionUncheckedUpdateWithoutDecisorUserInput>
    create: XOR<CoverageDecisionCreateWithoutDecisorUserInput, CoverageDecisionUncheckedCreateWithoutDecisorUserInput>
  }

  export type CoverageDecisionUpdateWithWhereUniqueWithoutDecisorUserInput = {
    where: CoverageDecisionWhereUniqueInput
    data: XOR<CoverageDecisionUpdateWithoutDecisorUserInput, CoverageDecisionUncheckedUpdateWithoutDecisorUserInput>
  }

  export type CoverageDecisionUpdateManyWithWhereWithoutDecisorUserInput = {
    where: CoverageDecisionScalarWhereInput
    data: XOR<CoverageDecisionUpdateManyMutationInput, CoverageDecisionUncheckedUpdateManyWithoutDecisorUserInput>
  }

  export type CoverageDecisionScalarWhereInput = {
    AND?: CoverageDecisionScalarWhereInput | CoverageDecisionScalarWhereInput[]
    OR?: CoverageDecisionScalarWhereInput[]
    NOT?: CoverageDecisionScalarWhereInput | CoverageDecisionScalarWhereInput[]
    id?: StringFilter<"CoverageDecision"> | string
    contributionId?: StringFilter<"CoverageDecision"> | string
    decisao?: StringFilter<"CoverageDecision"> | string
    motivo?: StringFilter<"CoverageDecision"> | string
    scoreNoMomento?: IntFilter<"CoverageDecision"> | number
    historicoInadimplencias?: IntFilter<"CoverageDecision"> | number
    decisorUserId?: StringNullableFilter<"CoverageDecision"> | string | null
    decisorSistema?: BoolFilter<"CoverageDecision"> | boolean
    createdAt?: DateTimeFilter<"CoverageDecision"> | Date | string
  }

  export type InviteUpsertWithWhereUniqueWithoutConvidadoPorInput = {
    where: InviteWhereUniqueInput
    update: XOR<InviteUpdateWithoutConvidadoPorInput, InviteUncheckedUpdateWithoutConvidadoPorInput>
    create: XOR<InviteCreateWithoutConvidadoPorInput, InviteUncheckedCreateWithoutConvidadoPorInput>
  }

  export type InviteUpdateWithWhereUniqueWithoutConvidadoPorInput = {
    where: InviteWhereUniqueInput
    data: XOR<InviteUpdateWithoutConvidadoPorInput, InviteUncheckedUpdateWithoutConvidadoPorInput>
  }

  export type InviteUpdateManyWithWhereWithoutConvidadoPorInput = {
    where: InviteScalarWhereInput
    data: XOR<InviteUpdateManyMutationInput, InviteUncheckedUpdateManyWithoutConvidadoPorInput>
  }

  export type InviteScalarWhereInput = {
    AND?: InviteScalarWhereInput | InviteScalarWhereInput[]
    OR?: InviteScalarWhereInput[]
    NOT?: InviteScalarWhereInput | InviteScalarWhereInput[]
    id?: StringFilter<"Invite"> | string
    groupId?: StringFilter<"Invite"> | string
    convidadoPorId?: StringFilter<"Invite"> | string
    telefone?: StringFilter<"Invite"> | string
    email?: StringNullableFilter<"Invite"> | string | null
    token?: StringFilter<"Invite"> | string
    status?: StringFilter<"Invite"> | string
    createdAt?: DateTimeFilter<"Invite"> | Date | string
    expiraEm?: DateTimeFilter<"Invite"> | Date | string
  }

  export type FeeConfigurationUpsertWithWhereUniqueWithoutCriadoPorInput = {
    where: FeeConfigurationWhereUniqueInput
    update: XOR<FeeConfigurationUpdateWithoutCriadoPorInput, FeeConfigurationUncheckedUpdateWithoutCriadoPorInput>
    create: XOR<FeeConfigurationCreateWithoutCriadoPorInput, FeeConfigurationUncheckedCreateWithoutCriadoPorInput>
  }

  export type FeeConfigurationUpdateWithWhereUniqueWithoutCriadoPorInput = {
    where: FeeConfigurationWhereUniqueInput
    data: XOR<FeeConfigurationUpdateWithoutCriadoPorInput, FeeConfigurationUncheckedUpdateWithoutCriadoPorInput>
  }

  export type FeeConfigurationUpdateManyWithWhereWithoutCriadoPorInput = {
    where: FeeConfigurationScalarWhereInput
    data: XOR<FeeConfigurationUpdateManyMutationInput, FeeConfigurationUncheckedUpdateManyWithoutCriadoPorInput>
  }

  export type FeeConfigurationScalarWhereInput = {
    AND?: FeeConfigurationScalarWhereInput | FeeConfigurationScalarWhereInput[]
    OR?: FeeConfigurationScalarWhereInput[]
    NOT?: FeeConfigurationScalarWhereInput | FeeConfigurationScalarWhereInput[]
    id?: StringFilter<"FeeConfiguration"> | string
    tipoFee?: StringFilter<"FeeConfiguration"> | string
    valor?: FloatFilter<"FeeConfiguration"> | number
    min?: FloatFilter<"FeeConfiguration"> | number
    max?: FloatFilter<"FeeConfiguration"> | number
    dataInicio?: DateTimeFilter<"FeeConfiguration"> | Date | string
    dataFim?: DateTimeNullableFilter<"FeeConfiguration"> | Date | string | null
    criadoPorId?: StringNullableFilter<"FeeConfiguration"> | string | null
    motivoMudanca?: StringNullableFilter<"FeeConfiguration"> | string | null
    ativa?: BoolFilter<"FeeConfiguration"> | boolean
    createdAt?: DateTimeFilter<"FeeConfiguration"> | Date | string
  }

  export type AuditLogUpsertWithWhereUniqueWithoutUserInput = {
    where: AuditLogWhereUniqueInput
    update: XOR<AuditLogUpdateWithoutUserInput, AuditLogUncheckedUpdateWithoutUserInput>
    create: XOR<AuditLogCreateWithoutUserInput, AuditLogUncheckedCreateWithoutUserInput>
  }

  export type AuditLogUpdateWithWhereUniqueWithoutUserInput = {
    where: AuditLogWhereUniqueInput
    data: XOR<AuditLogUpdateWithoutUserInput, AuditLogUncheckedUpdateWithoutUserInput>
  }

  export type AuditLogUpdateManyWithWhereWithoutUserInput = {
    where: AuditLogScalarWhereInput
    data: XOR<AuditLogUpdateManyMutationInput, AuditLogUncheckedUpdateManyWithoutUserInput>
  }

  export type AuditLogScalarWhereInput = {
    AND?: AuditLogScalarWhereInput | AuditLogScalarWhereInput[]
    OR?: AuditLogScalarWhereInput[]
    NOT?: AuditLogScalarWhereInput | AuditLogScalarWhereInput[]
    id?: StringFilter<"AuditLog"> | string
    userId?: StringNullableFilter<"AuditLog"> | string | null
    acao?: StringFilter<"AuditLog"> | string
    entidade?: StringFilter<"AuditLog"> | string
    entidadeId?: StringNullableFilter<"AuditLog"> | string | null
    dadosAntes?: StringNullableFilter<"AuditLog"> | string | null
    dadosDepois?: StringNullableFilter<"AuditLog"> | string | null
    ip?: StringNullableFilter<"AuditLog"> | string | null
    timestamp?: DateTimeFilter<"AuditLog"> | Date | string
  }

  export type CreditApplicationUpsertWithWhereUniqueWithoutUserInput = {
    where: CreditApplicationWhereUniqueInput
    update: XOR<CreditApplicationUpdateWithoutUserInput, CreditApplicationUncheckedUpdateWithoutUserInput>
    create: XOR<CreditApplicationCreateWithoutUserInput, CreditApplicationUncheckedCreateWithoutUserInput>
  }

  export type CreditApplicationUpdateWithWhereUniqueWithoutUserInput = {
    where: CreditApplicationWhereUniqueInput
    data: XOR<CreditApplicationUpdateWithoutUserInput, CreditApplicationUncheckedUpdateWithoutUserInput>
  }

  export type CreditApplicationUpdateManyWithWhereWithoutUserInput = {
    where: CreditApplicationScalarWhereInput
    data: XOR<CreditApplicationUpdateManyMutationInput, CreditApplicationUncheckedUpdateManyWithoutUserInput>
  }

  export type CreditApplicationScalarWhereInput = {
    AND?: CreditApplicationScalarWhereInput | CreditApplicationScalarWhereInput[]
    OR?: CreditApplicationScalarWhereInput[]
    NOT?: CreditApplicationScalarWhereInput | CreditApplicationScalarWhereInput[]
    id?: StringFilter<"CreditApplication"> | string
    userId?: StringFilter<"CreditApplication"> | string
    valorSolicitado?: FloatFilter<"CreditApplication"> | number
    prazoMeses?: IntFilter<"CreditApplication"> | number
    taxaJuroAplicada?: FloatFilter<"CreditApplication"> | number
    prestacaoMensal?: FloatFilter<"CreditApplication"> | number
    finalidade?: StringNullableFilter<"CreditApplication"> | string | null
    status?: StringFilter<"CreditApplication"> | string
    scoreNoMomento?: IntFilter<"CreditApplication"> | number
    motivoDecisao?: StringNullableFilter<"CreditApplication"> | string | null
    decisaoPorId?: StringNullableFilter<"CreditApplication"> | string | null
    dataAprovacao?: DateTimeNullableFilter<"CreditApplication"> | Date | string | null
    dataDesembolso?: DateTimeNullableFilter<"CreditApplication"> | Date | string | null
    createdAt?: DateTimeFilter<"CreditApplication"> | Date | string
    updatedAt?: DateTimeFilter<"CreditApplication"> | Date | string
  }

  export type SavingsAccountUpsertWithWhereUniqueWithoutUserInput = {
    where: SavingsAccountWhereUniqueInput
    update: XOR<SavingsAccountUpdateWithoutUserInput, SavingsAccountUncheckedUpdateWithoutUserInput>
    create: XOR<SavingsAccountCreateWithoutUserInput, SavingsAccountUncheckedCreateWithoutUserInput>
  }

  export type SavingsAccountUpdateWithWhereUniqueWithoutUserInput = {
    where: SavingsAccountWhereUniqueInput
    data: XOR<SavingsAccountUpdateWithoutUserInput, SavingsAccountUncheckedUpdateWithoutUserInput>
  }

  export type SavingsAccountUpdateManyWithWhereWithoutUserInput = {
    where: SavingsAccountScalarWhereInput
    data: XOR<SavingsAccountUpdateManyMutationInput, SavingsAccountUncheckedUpdateManyWithoutUserInput>
  }

  export type SavingsAccountScalarWhereInput = {
    AND?: SavingsAccountScalarWhereInput | SavingsAccountScalarWhereInput[]
    OR?: SavingsAccountScalarWhereInput[]
    NOT?: SavingsAccountScalarWhereInput | SavingsAccountScalarWhereInput[]
    id?: StringFilter<"SavingsAccount"> | string
    userId?: StringFilter<"SavingsAccount"> | string
    nome?: StringFilter<"SavingsAccount"> | string
    objectivo?: StringNullableFilter<"SavingsAccount"> | string | null
    meta?: FloatNullableFilter<"SavingsAccount"> | number | null
    saldo?: FloatFilter<"SavingsAccount"> | number
    taxaRemuneracaoAnual?: FloatFilter<"SavingsAccount"> | number
    imobilizacaoMeses?: IntFilter<"SavingsAccount"> | number
    status?: StringFilter<"SavingsAccount"> | string
    ultimaCapitalizacao?: DateTimeFilter<"SavingsAccount"> | Date | string
    createdAt?: DateTimeFilter<"SavingsAccount"> | Date | string
    updatedAt?: DateTimeFilter<"SavingsAccount"> | Date | string
  }

  export type ReferralUpsertWithWhereUniqueWithoutReferrerInput = {
    where: ReferralWhereUniqueInput
    update: XOR<ReferralUpdateWithoutReferrerInput, ReferralUncheckedUpdateWithoutReferrerInput>
    create: XOR<ReferralCreateWithoutReferrerInput, ReferralUncheckedCreateWithoutReferrerInput>
  }

  export type ReferralUpdateWithWhereUniqueWithoutReferrerInput = {
    where: ReferralWhereUniqueInput
    data: XOR<ReferralUpdateWithoutReferrerInput, ReferralUncheckedUpdateWithoutReferrerInput>
  }

  export type ReferralUpdateManyWithWhereWithoutReferrerInput = {
    where: ReferralScalarWhereInput
    data: XOR<ReferralUpdateManyMutationInput, ReferralUncheckedUpdateManyWithoutReferrerInput>
  }

  export type ReferralScalarWhereInput = {
    AND?: ReferralScalarWhereInput | ReferralScalarWhereInput[]
    OR?: ReferralScalarWhereInput[]
    NOT?: ReferralScalarWhereInput | ReferralScalarWhereInput[]
    id?: StringFilter<"Referral"> | string
    referrerUserId?: StringFilter<"Referral"> | string
    referredUserId?: StringNullableFilter<"Referral"> | string | null
    codigo?: StringFilter<"Referral"> | string
    canal?: StringNullableFilter<"Referral"> | string | null
    status?: StringFilter<"Referral"> | string
    recompensa?: FloatFilter<"Referral"> | number
    recompensaPaga?: BoolFilter<"Referral"> | boolean
    dataRegisto?: DateTimeNullableFilter<"Referral"> | Date | string | null
    dataActivacao?: DateTimeNullableFilter<"Referral"> | Date | string | null
    createdAt?: DateTimeFilter<"Referral"> | Date | string
  }

  export type ReferralUpsertWithWhereUniqueWithoutReferredUserInput = {
    where: ReferralWhereUniqueInput
    update: XOR<ReferralUpdateWithoutReferredUserInput, ReferralUncheckedUpdateWithoutReferredUserInput>
    create: XOR<ReferralCreateWithoutReferredUserInput, ReferralUncheckedCreateWithoutReferredUserInput>
  }

  export type ReferralUpdateWithWhereUniqueWithoutReferredUserInput = {
    where: ReferralWhereUniqueInput
    data: XOR<ReferralUpdateWithoutReferredUserInput, ReferralUncheckedUpdateWithoutReferredUserInput>
  }

  export type ReferralUpdateManyWithWhereWithoutReferredUserInput = {
    where: ReferralScalarWhereInput
    data: XOR<ReferralUpdateManyMutationInput, ReferralUncheckedUpdateManyWithoutReferredUserInput>
  }

  export type QuizAttemptUpsertWithWhereUniqueWithoutUserInput = {
    where: QuizAttemptWhereUniqueInput
    update: XOR<QuizAttemptUpdateWithoutUserInput, QuizAttemptUncheckedUpdateWithoutUserInput>
    create: XOR<QuizAttemptCreateWithoutUserInput, QuizAttemptUncheckedCreateWithoutUserInput>
  }

  export type QuizAttemptUpdateWithWhereUniqueWithoutUserInput = {
    where: QuizAttemptWhereUniqueInput
    data: XOR<QuizAttemptUpdateWithoutUserInput, QuizAttemptUncheckedUpdateWithoutUserInput>
  }

  export type QuizAttemptUpdateManyWithWhereWithoutUserInput = {
    where: QuizAttemptScalarWhereInput
    data: XOR<QuizAttemptUpdateManyMutationInput, QuizAttemptUncheckedUpdateManyWithoutUserInput>
  }

  export type QuizAttemptScalarWhereInput = {
    AND?: QuizAttemptScalarWhereInput | QuizAttemptScalarWhereInput[]
    OR?: QuizAttemptScalarWhereInput[]
    NOT?: QuizAttemptScalarWhereInput | QuizAttemptScalarWhereInput[]
    id?: StringFilter<"QuizAttempt"> | string
    userId?: StringFilter<"QuizAttempt"> | string
    quizId?: StringFilter<"QuizAttempt"> | string
    acertos?: IntFilter<"QuizAttempt"> | number
    total?: IntFilter<"QuizAttempt"> | number
    pontosGanhos?: IntFilter<"QuizAttempt"> | number
    respostasJson?: StringNullableFilter<"QuizAttempt"> | string | null
    createdAt?: DateTimeFilter<"QuizAttempt"> | Date | string
  }

  export type BadgeUpsertWithWhereUniqueWithoutUserInput = {
    where: BadgeWhereUniqueInput
    update: XOR<BadgeUpdateWithoutUserInput, BadgeUncheckedUpdateWithoutUserInput>
    create: XOR<BadgeCreateWithoutUserInput, BadgeUncheckedCreateWithoutUserInput>
  }

  export type BadgeUpdateWithWhereUniqueWithoutUserInput = {
    where: BadgeWhereUniqueInput
    data: XOR<BadgeUpdateWithoutUserInput, BadgeUncheckedUpdateWithoutUserInput>
  }

  export type BadgeUpdateManyWithWhereWithoutUserInput = {
    where: BadgeScalarWhereInput
    data: XOR<BadgeUpdateManyMutationInput, BadgeUncheckedUpdateManyWithoutUserInput>
  }

  export type BadgeScalarWhereInput = {
    AND?: BadgeScalarWhereInput | BadgeScalarWhereInput[]
    OR?: BadgeScalarWhereInput[]
    NOT?: BadgeScalarWhereInput | BadgeScalarWhereInput[]
    id?: StringFilter<"Badge"> | string
    userId?: StringFilter<"Badge"> | string
    tipo?: StringFilter<"Badge"> | string
    titulo?: StringFilter<"Badge"> | string
    descricao?: StringNullableFilter<"Badge"> | string | null
    createdAt?: DateTimeFilter<"Badge"> | Date | string
  }

  export type InsurancePolicyUpsertWithWhereUniqueWithoutUserInput = {
    where: InsurancePolicyWhereUniqueInput
    update: XOR<InsurancePolicyUpdateWithoutUserInput, InsurancePolicyUncheckedUpdateWithoutUserInput>
    create: XOR<InsurancePolicyCreateWithoutUserInput, InsurancePolicyUncheckedCreateWithoutUserInput>
  }

  export type InsurancePolicyUpdateWithWhereUniqueWithoutUserInput = {
    where: InsurancePolicyWhereUniqueInput
    data: XOR<InsurancePolicyUpdateWithoutUserInput, InsurancePolicyUncheckedUpdateWithoutUserInput>
  }

  export type InsurancePolicyUpdateManyWithWhereWithoutUserInput = {
    where: InsurancePolicyScalarWhereInput
    data: XOR<InsurancePolicyUpdateManyMutationInput, InsurancePolicyUncheckedUpdateManyWithoutUserInput>
  }

  export type InsurancePolicyScalarWhereInput = {
    AND?: InsurancePolicyScalarWhereInput | InsurancePolicyScalarWhereInput[]
    OR?: InsurancePolicyScalarWhereInput[]
    NOT?: InsurancePolicyScalarWhereInput | InsurancePolicyScalarWhereInput[]
    id?: StringFilter<"InsurancePolicy"> | string
    userId?: StringFilter<"InsurancePolicy"> | string
    productId?: StringFilter<"InsurancePolicy"> | string
    status?: StringFilter<"InsurancePolicy"> | string
    dataInicio?: DateTimeFilter<"InsurancePolicy"> | Date | string
    premiumPago?: FloatFilter<"InsurancePolicy"> | number
    proximaCobranca?: DateTimeNullableFilter<"InsurancePolicy"> | Date | string | null
  }

  export type UserCreateWithoutOtpsInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referredBy?: UserCreateNestedOneWithoutReferidosInput
    referidos?: UserCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupCreateNestedManyWithoutCriadorInput
    memberships?: MembershipCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionCreateNestedManyWithoutUserInput
    cashouts?: CashoutCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationCreateNestedManyWithoutUserInput
    sessions?: SessionCreateNestedManyWithoutUserInput
    notifications?: NotificationCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptCreateNestedManyWithoutUserInput
    badges?: BadgeCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyCreateNestedManyWithoutUserInput
  }

  export type UserUncheckedCreateWithoutOtpsInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    referredById?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referidos?: UserUncheckedCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupUncheckedCreateNestedManyWithoutCriadorInput
    memberships?: MembershipUncheckedCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionUncheckedCreateNestedManyWithoutUserInput
    cashouts?: CashoutUncheckedCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanUncheckedCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventUncheckedCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationUncheckedCreateNestedManyWithoutUserInput
    sessions?: SessionUncheckedCreateNestedManyWithoutUserInput
    notifications?: NotificationUncheckedCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionUncheckedCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteUncheckedCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationUncheckedCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogUncheckedCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationUncheckedCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountUncheckedCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralUncheckedCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralUncheckedCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptUncheckedCreateNestedManyWithoutUserInput
    badges?: BadgeUncheckedCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyUncheckedCreateNestedManyWithoutUserInput
  }

  export type UserCreateOrConnectWithoutOtpsInput = {
    where: UserWhereUniqueInput
    create: XOR<UserCreateWithoutOtpsInput, UserUncheckedCreateWithoutOtpsInput>
  }

  export type UserUpsertWithoutOtpsInput = {
    update: XOR<UserUpdateWithoutOtpsInput, UserUncheckedUpdateWithoutOtpsInput>
    create: XOR<UserCreateWithoutOtpsInput, UserUncheckedCreateWithoutOtpsInput>
    where?: UserWhereInput
  }

  export type UserUpdateToOneWithWhereWithoutOtpsInput = {
    where?: UserWhereInput
    data: XOR<UserUpdateWithoutOtpsInput, UserUncheckedUpdateWithoutOtpsInput>
  }

  export type UserUpdateWithoutOtpsInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referredBy?: UserUpdateOneWithoutReferidosNestedInput
    referidos?: UserUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUpdateManyWithoutUserNestedInput
    sessions?: SessionUpdateManyWithoutUserNestedInput
    notifications?: NotificationUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUpdateManyWithoutUserNestedInput
    badges?: BadgeUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUpdateManyWithoutUserNestedInput
  }

  export type UserUncheckedUpdateWithoutOtpsInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    referredById?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referidos?: UserUncheckedUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUncheckedUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUncheckedUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUncheckedUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUncheckedUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUncheckedUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUncheckedUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUncheckedUpdateManyWithoutUserNestedInput
    sessions?: SessionUncheckedUpdateManyWithoutUserNestedInput
    notifications?: NotificationUncheckedUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUncheckedUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUncheckedUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUncheckedUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUncheckedUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUncheckedUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUncheckedUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUncheckedUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUncheckedUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUncheckedUpdateManyWithoutUserNestedInput
    badges?: BadgeUncheckedUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUncheckedUpdateManyWithoutUserNestedInput
  }

  export type UserCreateWithoutSessionsInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referredBy?: UserCreateNestedOneWithoutReferidosInput
    referidos?: UserCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupCreateNestedManyWithoutCriadorInput
    memberships?: MembershipCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionCreateNestedManyWithoutUserInput
    cashouts?: CashoutCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationCreateNestedManyWithoutUserInput
    otps?: OtpCreateNestedManyWithoutUserInput
    notifications?: NotificationCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptCreateNestedManyWithoutUserInput
    badges?: BadgeCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyCreateNestedManyWithoutUserInput
  }

  export type UserUncheckedCreateWithoutSessionsInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    referredById?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referidos?: UserUncheckedCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupUncheckedCreateNestedManyWithoutCriadorInput
    memberships?: MembershipUncheckedCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionUncheckedCreateNestedManyWithoutUserInput
    cashouts?: CashoutUncheckedCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanUncheckedCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventUncheckedCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationUncheckedCreateNestedManyWithoutUserInput
    otps?: OtpUncheckedCreateNestedManyWithoutUserInput
    notifications?: NotificationUncheckedCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionUncheckedCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteUncheckedCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationUncheckedCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogUncheckedCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationUncheckedCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountUncheckedCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralUncheckedCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralUncheckedCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptUncheckedCreateNestedManyWithoutUserInput
    badges?: BadgeUncheckedCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyUncheckedCreateNestedManyWithoutUserInput
  }

  export type UserCreateOrConnectWithoutSessionsInput = {
    where: UserWhereUniqueInput
    create: XOR<UserCreateWithoutSessionsInput, UserUncheckedCreateWithoutSessionsInput>
  }

  export type UserUpsertWithoutSessionsInput = {
    update: XOR<UserUpdateWithoutSessionsInput, UserUncheckedUpdateWithoutSessionsInput>
    create: XOR<UserCreateWithoutSessionsInput, UserUncheckedCreateWithoutSessionsInput>
    where?: UserWhereInput
  }

  export type UserUpdateToOneWithWhereWithoutSessionsInput = {
    where?: UserWhereInput
    data: XOR<UserUpdateWithoutSessionsInput, UserUncheckedUpdateWithoutSessionsInput>
  }

  export type UserUpdateWithoutSessionsInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referredBy?: UserUpdateOneWithoutReferidosNestedInput
    referidos?: UserUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUpdateManyWithoutUserNestedInput
    otps?: OtpUpdateManyWithoutUserNestedInput
    notifications?: NotificationUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUpdateManyWithoutUserNestedInput
    badges?: BadgeUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUpdateManyWithoutUserNestedInput
  }

  export type UserUncheckedUpdateWithoutSessionsInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    referredById?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referidos?: UserUncheckedUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUncheckedUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUncheckedUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUncheckedUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUncheckedUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUncheckedUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUncheckedUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUncheckedUpdateManyWithoutUserNestedInput
    otps?: OtpUncheckedUpdateManyWithoutUserNestedInput
    notifications?: NotificationUncheckedUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUncheckedUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUncheckedUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUncheckedUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUncheckedUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUncheckedUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUncheckedUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUncheckedUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUncheckedUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUncheckedUpdateManyWithoutUserNestedInput
    badges?: BadgeUncheckedUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUncheckedUpdateManyWithoutUserNestedInput
  }

  export type UserCreateWithoutGruposCriadosInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referredBy?: UserCreateNestedOneWithoutReferidosInput
    referidos?: UserCreateNestedManyWithoutReferredByInput
    memberships?: MembershipCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionCreateNestedManyWithoutUserInput
    cashouts?: CashoutCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationCreateNestedManyWithoutUserInput
    otps?: OtpCreateNestedManyWithoutUserInput
    sessions?: SessionCreateNestedManyWithoutUserInput
    notifications?: NotificationCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptCreateNestedManyWithoutUserInput
    badges?: BadgeCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyCreateNestedManyWithoutUserInput
  }

  export type UserUncheckedCreateWithoutGruposCriadosInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    referredById?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referidos?: UserUncheckedCreateNestedManyWithoutReferredByInput
    memberships?: MembershipUncheckedCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionUncheckedCreateNestedManyWithoutUserInput
    cashouts?: CashoutUncheckedCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanUncheckedCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventUncheckedCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationUncheckedCreateNestedManyWithoutUserInput
    otps?: OtpUncheckedCreateNestedManyWithoutUserInput
    sessions?: SessionUncheckedCreateNestedManyWithoutUserInput
    notifications?: NotificationUncheckedCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionUncheckedCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteUncheckedCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationUncheckedCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogUncheckedCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationUncheckedCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountUncheckedCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralUncheckedCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralUncheckedCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptUncheckedCreateNestedManyWithoutUserInput
    badges?: BadgeUncheckedCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyUncheckedCreateNestedManyWithoutUserInput
  }

  export type UserCreateOrConnectWithoutGruposCriadosInput = {
    where: UserWhereUniqueInput
    create: XOR<UserCreateWithoutGruposCriadosInput, UserUncheckedCreateWithoutGruposCriadosInput>
  }

  export type MembershipCreateWithoutGroupInput = {
    id?: string
    posicaoRotacao?: number | null
    status?: string
    necessidadeUrgente?: boolean
    dataJuncao?: Date | string
    mesRecepcaoPrevisto?: string | null
    user: UserCreateNestedOneWithoutMembershipsInput
    monthlyCyclesBeneficiario?: MonthlyCycleCreateNestedManyWithoutBeneficiarioMembershipInput
    contribuicoes?: ContributionCreateNestedManyWithoutMembershipInput
  }

  export type MembershipUncheckedCreateWithoutGroupInput = {
    id?: string
    userId: string
    posicaoRotacao?: number | null
    status?: string
    necessidadeUrgente?: boolean
    dataJuncao?: Date | string
    mesRecepcaoPrevisto?: string | null
    monthlyCyclesBeneficiario?: MonthlyCycleUncheckedCreateNestedManyWithoutBeneficiarioMembershipInput
    contribuicoes?: ContributionUncheckedCreateNestedManyWithoutMembershipInput
  }

  export type MembershipCreateOrConnectWithoutGroupInput = {
    where: MembershipWhereUniqueInput
    create: XOR<MembershipCreateWithoutGroupInput, MembershipUncheckedCreateWithoutGroupInput>
  }

  export type MembershipCreateManyGroupInputEnvelope = {
    data: MembershipCreateManyGroupInput | MembershipCreateManyGroupInput[]
    skipDuplicates?: boolean
  }

  export type MonthlyCycleCreateWithoutGroupInput = {
    id?: string
    numeroCiclo: number
    mesAno: string
    dataContribuicaoLimite: Date | string
    dataCashout: Date | string
    status?: string
    valorPoteBruto: number
    valorTaxaPrincipal: number
    valorReservaTecnica: number
    valorPoteLiquido: number
    createdAt?: Date | string
    updatedAt?: Date | string
    beneficiarioMembership: MembershipCreateNestedOneWithoutMonthlyCyclesBeneficiarioInput
    contribuicoes?: ContributionCreateNestedManyWithoutMonthlyCycleInput
    cashout?: CashoutCreateNestedOneWithoutMonthlyCycleInput
    loans?: LoanCreateNestedManyWithoutMonthlyCycleInput
  }

  export type MonthlyCycleUncheckedCreateWithoutGroupInput = {
    id?: string
    numeroCiclo: number
    mesAno: string
    beneficiarioMembershipId: string
    dataContribuicaoLimite: Date | string
    dataCashout: Date | string
    status?: string
    valorPoteBruto: number
    valorTaxaPrincipal: number
    valorReservaTecnica: number
    valorPoteLiquido: number
    createdAt?: Date | string
    updatedAt?: Date | string
    contribuicoes?: ContributionUncheckedCreateNestedManyWithoutMonthlyCycleInput
    cashout?: CashoutUncheckedCreateNestedOneWithoutMonthlyCycleInput
    loans?: LoanUncheckedCreateNestedManyWithoutMonthlyCycleInput
  }

  export type MonthlyCycleCreateOrConnectWithoutGroupInput = {
    where: MonthlyCycleWhereUniqueInput
    create: XOR<MonthlyCycleCreateWithoutGroupInput, MonthlyCycleUncheckedCreateWithoutGroupInput>
  }

  export type MonthlyCycleCreateManyGroupInputEnvelope = {
    data: MonthlyCycleCreateManyGroupInput | MonthlyCycleCreateManyGroupInput[]
    skipDuplicates?: boolean
  }

  export type InviteCreateWithoutGroupInput = {
    id?: string
    telefone: string
    email?: string | null
    token: string
    status?: string
    createdAt?: Date | string
    expiraEm: Date | string
    convidadoPor: UserCreateNestedOneWithoutInvitesEnviadosInput
  }

  export type InviteUncheckedCreateWithoutGroupInput = {
    id?: string
    convidadoPorId: string
    telefone: string
    email?: string | null
    token: string
    status?: string
    createdAt?: Date | string
    expiraEm: Date | string
  }

  export type InviteCreateOrConnectWithoutGroupInput = {
    where: InviteWhereUniqueInput
    create: XOR<InviteCreateWithoutGroupInput, InviteUncheckedCreateWithoutGroupInput>
  }

  export type InviteCreateManyGroupInputEnvelope = {
    data: InviteCreateManyGroupInput | InviteCreateManyGroupInput[]
    skipDuplicates?: boolean
  }

  export type GroupApplicationCreateWithoutGroupInput = {
    id?: string
    userId: string
    mensagem?: string | null
    status?: string
    createdAt?: Date | string
  }

  export type GroupApplicationUncheckedCreateWithoutGroupInput = {
    id?: string
    userId: string
    mensagem?: string | null
    status?: string
    createdAt?: Date | string
  }

  export type GroupApplicationCreateOrConnectWithoutGroupInput = {
    where: GroupApplicationWhereUniqueInput
    create: XOR<GroupApplicationCreateWithoutGroupInput, GroupApplicationUncheckedCreateWithoutGroupInput>
  }

  export type GroupApplicationCreateManyGroupInputEnvelope = {
    data: GroupApplicationCreateManyGroupInput | GroupApplicationCreateManyGroupInput[]
    skipDuplicates?: boolean
  }

  export type UserUpsertWithoutGruposCriadosInput = {
    update: XOR<UserUpdateWithoutGruposCriadosInput, UserUncheckedUpdateWithoutGruposCriadosInput>
    create: XOR<UserCreateWithoutGruposCriadosInput, UserUncheckedCreateWithoutGruposCriadosInput>
    where?: UserWhereInput
  }

  export type UserUpdateToOneWithWhereWithoutGruposCriadosInput = {
    where?: UserWhereInput
    data: XOR<UserUpdateWithoutGruposCriadosInput, UserUncheckedUpdateWithoutGruposCriadosInput>
  }

  export type UserUpdateWithoutGruposCriadosInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referredBy?: UserUpdateOneWithoutReferidosNestedInput
    referidos?: UserUpdateManyWithoutReferredByNestedInput
    memberships?: MembershipUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUpdateManyWithoutUserNestedInput
    otps?: OtpUpdateManyWithoutUserNestedInput
    sessions?: SessionUpdateManyWithoutUserNestedInput
    notifications?: NotificationUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUpdateManyWithoutUserNestedInput
    badges?: BadgeUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUpdateManyWithoutUserNestedInput
  }

  export type UserUncheckedUpdateWithoutGruposCriadosInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    referredById?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referidos?: UserUncheckedUpdateManyWithoutReferredByNestedInput
    memberships?: MembershipUncheckedUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUncheckedUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUncheckedUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUncheckedUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUncheckedUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUncheckedUpdateManyWithoutUserNestedInput
    otps?: OtpUncheckedUpdateManyWithoutUserNestedInput
    sessions?: SessionUncheckedUpdateManyWithoutUserNestedInput
    notifications?: NotificationUncheckedUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUncheckedUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUncheckedUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUncheckedUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUncheckedUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUncheckedUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUncheckedUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUncheckedUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUncheckedUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUncheckedUpdateManyWithoutUserNestedInput
    badges?: BadgeUncheckedUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUncheckedUpdateManyWithoutUserNestedInput
  }

  export type MembershipUpsertWithWhereUniqueWithoutGroupInput = {
    where: MembershipWhereUniqueInput
    update: XOR<MembershipUpdateWithoutGroupInput, MembershipUncheckedUpdateWithoutGroupInput>
    create: XOR<MembershipCreateWithoutGroupInput, MembershipUncheckedCreateWithoutGroupInput>
  }

  export type MembershipUpdateWithWhereUniqueWithoutGroupInput = {
    where: MembershipWhereUniqueInput
    data: XOR<MembershipUpdateWithoutGroupInput, MembershipUncheckedUpdateWithoutGroupInput>
  }

  export type MembershipUpdateManyWithWhereWithoutGroupInput = {
    where: MembershipScalarWhereInput
    data: XOR<MembershipUpdateManyMutationInput, MembershipUncheckedUpdateManyWithoutGroupInput>
  }

  export type MonthlyCycleUpsertWithWhereUniqueWithoutGroupInput = {
    where: MonthlyCycleWhereUniqueInput
    update: XOR<MonthlyCycleUpdateWithoutGroupInput, MonthlyCycleUncheckedUpdateWithoutGroupInput>
    create: XOR<MonthlyCycleCreateWithoutGroupInput, MonthlyCycleUncheckedCreateWithoutGroupInput>
  }

  export type MonthlyCycleUpdateWithWhereUniqueWithoutGroupInput = {
    where: MonthlyCycleWhereUniqueInput
    data: XOR<MonthlyCycleUpdateWithoutGroupInput, MonthlyCycleUncheckedUpdateWithoutGroupInput>
  }

  export type MonthlyCycleUpdateManyWithWhereWithoutGroupInput = {
    where: MonthlyCycleScalarWhereInput
    data: XOR<MonthlyCycleUpdateManyMutationInput, MonthlyCycleUncheckedUpdateManyWithoutGroupInput>
  }

  export type MonthlyCycleScalarWhereInput = {
    AND?: MonthlyCycleScalarWhereInput | MonthlyCycleScalarWhereInput[]
    OR?: MonthlyCycleScalarWhereInput[]
    NOT?: MonthlyCycleScalarWhereInput | MonthlyCycleScalarWhereInput[]
    id?: StringFilter<"MonthlyCycle"> | string
    groupId?: StringFilter<"MonthlyCycle"> | string
    numeroCiclo?: IntFilter<"MonthlyCycle"> | number
    mesAno?: StringFilter<"MonthlyCycle"> | string
    beneficiarioMembershipId?: StringFilter<"MonthlyCycle"> | string
    dataContribuicaoLimite?: DateTimeFilter<"MonthlyCycle"> | Date | string
    dataCashout?: DateTimeFilter<"MonthlyCycle"> | Date | string
    status?: StringFilter<"MonthlyCycle"> | string
    valorPoteBruto?: FloatFilter<"MonthlyCycle"> | number
    valorTaxaPrincipal?: FloatFilter<"MonthlyCycle"> | number
    valorReservaTecnica?: FloatFilter<"MonthlyCycle"> | number
    valorPoteLiquido?: FloatFilter<"MonthlyCycle"> | number
    createdAt?: DateTimeFilter<"MonthlyCycle"> | Date | string
    updatedAt?: DateTimeFilter<"MonthlyCycle"> | Date | string
  }

  export type InviteUpsertWithWhereUniqueWithoutGroupInput = {
    where: InviteWhereUniqueInput
    update: XOR<InviteUpdateWithoutGroupInput, InviteUncheckedUpdateWithoutGroupInput>
    create: XOR<InviteCreateWithoutGroupInput, InviteUncheckedCreateWithoutGroupInput>
  }

  export type InviteUpdateWithWhereUniqueWithoutGroupInput = {
    where: InviteWhereUniqueInput
    data: XOR<InviteUpdateWithoutGroupInput, InviteUncheckedUpdateWithoutGroupInput>
  }

  export type InviteUpdateManyWithWhereWithoutGroupInput = {
    where: InviteScalarWhereInput
    data: XOR<InviteUpdateManyMutationInput, InviteUncheckedUpdateManyWithoutGroupInput>
  }

  export type GroupApplicationUpsertWithWhereUniqueWithoutGroupInput = {
    where: GroupApplicationWhereUniqueInput
    update: XOR<GroupApplicationUpdateWithoutGroupInput, GroupApplicationUncheckedUpdateWithoutGroupInput>
    create: XOR<GroupApplicationCreateWithoutGroupInput, GroupApplicationUncheckedCreateWithoutGroupInput>
  }

  export type GroupApplicationUpdateWithWhereUniqueWithoutGroupInput = {
    where: GroupApplicationWhereUniqueInput
    data: XOR<GroupApplicationUpdateWithoutGroupInput, GroupApplicationUncheckedUpdateWithoutGroupInput>
  }

  export type GroupApplicationUpdateManyWithWhereWithoutGroupInput = {
    where: GroupApplicationScalarWhereInput
    data: XOR<GroupApplicationUpdateManyMutationInput, GroupApplicationUncheckedUpdateManyWithoutGroupInput>
  }

  export type GroupApplicationScalarWhereInput = {
    AND?: GroupApplicationScalarWhereInput | GroupApplicationScalarWhereInput[]
    OR?: GroupApplicationScalarWhereInput[]
    NOT?: GroupApplicationScalarWhereInput | GroupApplicationScalarWhereInput[]
    id?: StringFilter<"GroupApplication"> | string
    groupId?: StringFilter<"GroupApplication"> | string
    userId?: StringFilter<"GroupApplication"> | string
    mensagem?: StringNullableFilter<"GroupApplication"> | string | null
    status?: StringFilter<"GroupApplication"> | string
    createdAt?: DateTimeFilter<"GroupApplication"> | Date | string
  }

  export type GroupCreateWithoutCandidaturasInput = {
    id?: string
    nome: string
    descricao?: string | null
    numMembros: number
    valorContribuicaoMensal: number
    taxaPrincipalAplicada: number
    reservaTecnicaAplicada: number
    periodicidade?: string
    tipo?: string
    pais?: string
    moeda?: string
    status?: string
    dataInicio?: Date | string | null
    dataFimPrevista?: Date | string | null
    cicloAtual?: number
    totalCiclos: number
    createdAt?: Date | string
    updatedAt?: Date | string
    criador: UserCreateNestedOneWithoutGruposCriadosInput
    memberships?: MembershipCreateNestedManyWithoutGroupInput
    monthlyCycles?: MonthlyCycleCreateNestedManyWithoutGroupInput
    invites?: InviteCreateNestedManyWithoutGroupInput
  }

  export type GroupUncheckedCreateWithoutCandidaturasInput = {
    id?: string
    nome: string
    descricao?: string | null
    criadorId: string
    numMembros: number
    valorContribuicaoMensal: number
    taxaPrincipalAplicada: number
    reservaTecnicaAplicada: number
    periodicidade?: string
    tipo?: string
    pais?: string
    moeda?: string
    status?: string
    dataInicio?: Date | string | null
    dataFimPrevista?: Date | string | null
    cicloAtual?: number
    totalCiclos: number
    createdAt?: Date | string
    updatedAt?: Date | string
    memberships?: MembershipUncheckedCreateNestedManyWithoutGroupInput
    monthlyCycles?: MonthlyCycleUncheckedCreateNestedManyWithoutGroupInput
    invites?: InviteUncheckedCreateNestedManyWithoutGroupInput
  }

  export type GroupCreateOrConnectWithoutCandidaturasInput = {
    where: GroupWhereUniqueInput
    create: XOR<GroupCreateWithoutCandidaturasInput, GroupUncheckedCreateWithoutCandidaturasInput>
  }

  export type GroupUpsertWithoutCandidaturasInput = {
    update: XOR<GroupUpdateWithoutCandidaturasInput, GroupUncheckedUpdateWithoutCandidaturasInput>
    create: XOR<GroupCreateWithoutCandidaturasInput, GroupUncheckedCreateWithoutCandidaturasInput>
    where?: GroupWhereInput
  }

  export type GroupUpdateToOneWithWhereWithoutCandidaturasInput = {
    where?: GroupWhereInput
    data: XOR<GroupUpdateWithoutCandidaturasInput, GroupUncheckedUpdateWithoutCandidaturasInput>
  }

  export type GroupUpdateWithoutCandidaturasInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    numMembros?: IntFieldUpdateOperationsInput | number
    valorContribuicaoMensal?: FloatFieldUpdateOperationsInput | number
    taxaPrincipalAplicada?: FloatFieldUpdateOperationsInput | number
    reservaTecnicaAplicada?: FloatFieldUpdateOperationsInput | number
    periodicidade?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    pais?: StringFieldUpdateOperationsInput | string
    moeda?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    dataInicio?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    dataFimPrevista?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    cicloAtual?: IntFieldUpdateOperationsInput | number
    totalCiclos?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    criador?: UserUpdateOneRequiredWithoutGruposCriadosNestedInput
    memberships?: MembershipUpdateManyWithoutGroupNestedInput
    monthlyCycles?: MonthlyCycleUpdateManyWithoutGroupNestedInput
    invites?: InviteUpdateManyWithoutGroupNestedInput
  }

  export type GroupUncheckedUpdateWithoutCandidaturasInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    criadorId?: StringFieldUpdateOperationsInput | string
    numMembros?: IntFieldUpdateOperationsInput | number
    valorContribuicaoMensal?: FloatFieldUpdateOperationsInput | number
    taxaPrincipalAplicada?: FloatFieldUpdateOperationsInput | number
    reservaTecnicaAplicada?: FloatFieldUpdateOperationsInput | number
    periodicidade?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    pais?: StringFieldUpdateOperationsInput | string
    moeda?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    dataInicio?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    dataFimPrevista?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    cicloAtual?: IntFieldUpdateOperationsInput | number
    totalCiclos?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    memberships?: MembershipUncheckedUpdateManyWithoutGroupNestedInput
    monthlyCycles?: MonthlyCycleUncheckedUpdateManyWithoutGroupNestedInput
    invites?: InviteUncheckedUpdateManyWithoutGroupNestedInput
  }

  export type UserCreateWithoutMembershipsInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referredBy?: UserCreateNestedOneWithoutReferidosInput
    referidos?: UserCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupCreateNestedManyWithoutCriadorInput
    contribuicoes?: ContributionCreateNestedManyWithoutUserInput
    cashouts?: CashoutCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationCreateNestedManyWithoutUserInput
    otps?: OtpCreateNestedManyWithoutUserInput
    sessions?: SessionCreateNestedManyWithoutUserInput
    notifications?: NotificationCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptCreateNestedManyWithoutUserInput
    badges?: BadgeCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyCreateNestedManyWithoutUserInput
  }

  export type UserUncheckedCreateWithoutMembershipsInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    referredById?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referidos?: UserUncheckedCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupUncheckedCreateNestedManyWithoutCriadorInput
    contribuicoes?: ContributionUncheckedCreateNestedManyWithoutUserInput
    cashouts?: CashoutUncheckedCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanUncheckedCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventUncheckedCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationUncheckedCreateNestedManyWithoutUserInput
    otps?: OtpUncheckedCreateNestedManyWithoutUserInput
    sessions?: SessionUncheckedCreateNestedManyWithoutUserInput
    notifications?: NotificationUncheckedCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionUncheckedCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteUncheckedCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationUncheckedCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogUncheckedCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationUncheckedCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountUncheckedCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralUncheckedCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralUncheckedCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptUncheckedCreateNestedManyWithoutUserInput
    badges?: BadgeUncheckedCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyUncheckedCreateNestedManyWithoutUserInput
  }

  export type UserCreateOrConnectWithoutMembershipsInput = {
    where: UserWhereUniqueInput
    create: XOR<UserCreateWithoutMembershipsInput, UserUncheckedCreateWithoutMembershipsInput>
  }

  export type GroupCreateWithoutMembershipsInput = {
    id?: string
    nome: string
    descricao?: string | null
    numMembros: number
    valorContribuicaoMensal: number
    taxaPrincipalAplicada: number
    reservaTecnicaAplicada: number
    periodicidade?: string
    tipo?: string
    pais?: string
    moeda?: string
    status?: string
    dataInicio?: Date | string | null
    dataFimPrevista?: Date | string | null
    cicloAtual?: number
    totalCiclos: number
    createdAt?: Date | string
    updatedAt?: Date | string
    criador: UserCreateNestedOneWithoutGruposCriadosInput
    monthlyCycles?: MonthlyCycleCreateNestedManyWithoutGroupInput
    invites?: InviteCreateNestedManyWithoutGroupInput
    candidaturas?: GroupApplicationCreateNestedManyWithoutGroupInput
  }

  export type GroupUncheckedCreateWithoutMembershipsInput = {
    id?: string
    nome: string
    descricao?: string | null
    criadorId: string
    numMembros: number
    valorContribuicaoMensal: number
    taxaPrincipalAplicada: number
    reservaTecnicaAplicada: number
    periodicidade?: string
    tipo?: string
    pais?: string
    moeda?: string
    status?: string
    dataInicio?: Date | string | null
    dataFimPrevista?: Date | string | null
    cicloAtual?: number
    totalCiclos: number
    createdAt?: Date | string
    updatedAt?: Date | string
    monthlyCycles?: MonthlyCycleUncheckedCreateNestedManyWithoutGroupInput
    invites?: InviteUncheckedCreateNestedManyWithoutGroupInput
    candidaturas?: GroupApplicationUncheckedCreateNestedManyWithoutGroupInput
  }

  export type GroupCreateOrConnectWithoutMembershipsInput = {
    where: GroupWhereUniqueInput
    create: XOR<GroupCreateWithoutMembershipsInput, GroupUncheckedCreateWithoutMembershipsInput>
  }

  export type MonthlyCycleCreateWithoutBeneficiarioMembershipInput = {
    id?: string
    numeroCiclo: number
    mesAno: string
    dataContribuicaoLimite: Date | string
    dataCashout: Date | string
    status?: string
    valorPoteBruto: number
    valorTaxaPrincipal: number
    valorReservaTecnica: number
    valorPoteLiquido: number
    createdAt?: Date | string
    updatedAt?: Date | string
    group: GroupCreateNestedOneWithoutMonthlyCyclesInput
    contribuicoes?: ContributionCreateNestedManyWithoutMonthlyCycleInput
    cashout?: CashoutCreateNestedOneWithoutMonthlyCycleInput
    loans?: LoanCreateNestedManyWithoutMonthlyCycleInput
  }

  export type MonthlyCycleUncheckedCreateWithoutBeneficiarioMembershipInput = {
    id?: string
    groupId: string
    numeroCiclo: number
    mesAno: string
    dataContribuicaoLimite: Date | string
    dataCashout: Date | string
    status?: string
    valorPoteBruto: number
    valorTaxaPrincipal: number
    valorReservaTecnica: number
    valorPoteLiquido: number
    createdAt?: Date | string
    updatedAt?: Date | string
    contribuicoes?: ContributionUncheckedCreateNestedManyWithoutMonthlyCycleInput
    cashout?: CashoutUncheckedCreateNestedOneWithoutMonthlyCycleInput
    loans?: LoanUncheckedCreateNestedManyWithoutMonthlyCycleInput
  }

  export type MonthlyCycleCreateOrConnectWithoutBeneficiarioMembershipInput = {
    where: MonthlyCycleWhereUniqueInput
    create: XOR<MonthlyCycleCreateWithoutBeneficiarioMembershipInput, MonthlyCycleUncheckedCreateWithoutBeneficiarioMembershipInput>
  }

  export type MonthlyCycleCreateManyBeneficiarioMembershipInputEnvelope = {
    data: MonthlyCycleCreateManyBeneficiarioMembershipInput | MonthlyCycleCreateManyBeneficiarioMembershipInput[]
    skipDuplicates?: boolean
  }

  export type ContributionCreateWithoutMembershipInput = {
    id?: string
    valor: number
    dataPrevista: Date | string
    dataPagamento?: Date | string | null
    status?: string
    metodoPagamento?: string | null
    referenciaBancaria?: string | null
    comprovativoUrl?: string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    user: UserCreateNestedOneWithoutContribuicoesInput
    monthlyCycle: MonthlyCycleCreateNestedOneWithoutContribuicoesInput
    coverageDecision?: CoverageDecisionCreateNestedOneWithoutContributionInput
  }

  export type ContributionUncheckedCreateWithoutMembershipInput = {
    id?: string
    userId: string
    monthlyCycleId: string
    valor: number
    dataPrevista: Date | string
    dataPagamento?: Date | string | null
    status?: string
    metodoPagamento?: string | null
    referenciaBancaria?: string | null
    comprovativoUrl?: string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    coverageDecision?: CoverageDecisionUncheckedCreateNestedOneWithoutContributionInput
  }

  export type ContributionCreateOrConnectWithoutMembershipInput = {
    where: ContributionWhereUniqueInput
    create: XOR<ContributionCreateWithoutMembershipInput, ContributionUncheckedCreateWithoutMembershipInput>
  }

  export type ContributionCreateManyMembershipInputEnvelope = {
    data: ContributionCreateManyMembershipInput | ContributionCreateManyMembershipInput[]
    skipDuplicates?: boolean
  }

  export type UserUpsertWithoutMembershipsInput = {
    update: XOR<UserUpdateWithoutMembershipsInput, UserUncheckedUpdateWithoutMembershipsInput>
    create: XOR<UserCreateWithoutMembershipsInput, UserUncheckedCreateWithoutMembershipsInput>
    where?: UserWhereInput
  }

  export type UserUpdateToOneWithWhereWithoutMembershipsInput = {
    where?: UserWhereInput
    data: XOR<UserUpdateWithoutMembershipsInput, UserUncheckedUpdateWithoutMembershipsInput>
  }

  export type UserUpdateWithoutMembershipsInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referredBy?: UserUpdateOneWithoutReferidosNestedInput
    referidos?: UserUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUpdateManyWithoutCriadorNestedInput
    contribuicoes?: ContributionUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUpdateManyWithoutUserNestedInput
    otps?: OtpUpdateManyWithoutUserNestedInput
    sessions?: SessionUpdateManyWithoutUserNestedInput
    notifications?: NotificationUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUpdateManyWithoutUserNestedInput
    badges?: BadgeUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUpdateManyWithoutUserNestedInput
  }

  export type UserUncheckedUpdateWithoutMembershipsInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    referredById?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referidos?: UserUncheckedUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUncheckedUpdateManyWithoutCriadorNestedInput
    contribuicoes?: ContributionUncheckedUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUncheckedUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUncheckedUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUncheckedUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUncheckedUpdateManyWithoutUserNestedInput
    otps?: OtpUncheckedUpdateManyWithoutUserNestedInput
    sessions?: SessionUncheckedUpdateManyWithoutUserNestedInput
    notifications?: NotificationUncheckedUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUncheckedUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUncheckedUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUncheckedUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUncheckedUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUncheckedUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUncheckedUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUncheckedUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUncheckedUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUncheckedUpdateManyWithoutUserNestedInput
    badges?: BadgeUncheckedUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUncheckedUpdateManyWithoutUserNestedInput
  }

  export type GroupUpsertWithoutMembershipsInput = {
    update: XOR<GroupUpdateWithoutMembershipsInput, GroupUncheckedUpdateWithoutMembershipsInput>
    create: XOR<GroupCreateWithoutMembershipsInput, GroupUncheckedCreateWithoutMembershipsInput>
    where?: GroupWhereInput
  }

  export type GroupUpdateToOneWithWhereWithoutMembershipsInput = {
    where?: GroupWhereInput
    data: XOR<GroupUpdateWithoutMembershipsInput, GroupUncheckedUpdateWithoutMembershipsInput>
  }

  export type GroupUpdateWithoutMembershipsInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    numMembros?: IntFieldUpdateOperationsInput | number
    valorContribuicaoMensal?: FloatFieldUpdateOperationsInput | number
    taxaPrincipalAplicada?: FloatFieldUpdateOperationsInput | number
    reservaTecnicaAplicada?: FloatFieldUpdateOperationsInput | number
    periodicidade?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    pais?: StringFieldUpdateOperationsInput | string
    moeda?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    dataInicio?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    dataFimPrevista?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    cicloAtual?: IntFieldUpdateOperationsInput | number
    totalCiclos?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    criador?: UserUpdateOneRequiredWithoutGruposCriadosNestedInput
    monthlyCycles?: MonthlyCycleUpdateManyWithoutGroupNestedInput
    invites?: InviteUpdateManyWithoutGroupNestedInput
    candidaturas?: GroupApplicationUpdateManyWithoutGroupNestedInput
  }

  export type GroupUncheckedUpdateWithoutMembershipsInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    criadorId?: StringFieldUpdateOperationsInput | string
    numMembros?: IntFieldUpdateOperationsInput | number
    valorContribuicaoMensal?: FloatFieldUpdateOperationsInput | number
    taxaPrincipalAplicada?: FloatFieldUpdateOperationsInput | number
    reservaTecnicaAplicada?: FloatFieldUpdateOperationsInput | number
    periodicidade?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    pais?: StringFieldUpdateOperationsInput | string
    moeda?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    dataInicio?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    dataFimPrevista?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    cicloAtual?: IntFieldUpdateOperationsInput | number
    totalCiclos?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    monthlyCycles?: MonthlyCycleUncheckedUpdateManyWithoutGroupNestedInput
    invites?: InviteUncheckedUpdateManyWithoutGroupNestedInput
    candidaturas?: GroupApplicationUncheckedUpdateManyWithoutGroupNestedInput
  }

  export type MonthlyCycleUpsertWithWhereUniqueWithoutBeneficiarioMembershipInput = {
    where: MonthlyCycleWhereUniqueInput
    update: XOR<MonthlyCycleUpdateWithoutBeneficiarioMembershipInput, MonthlyCycleUncheckedUpdateWithoutBeneficiarioMembershipInput>
    create: XOR<MonthlyCycleCreateWithoutBeneficiarioMembershipInput, MonthlyCycleUncheckedCreateWithoutBeneficiarioMembershipInput>
  }

  export type MonthlyCycleUpdateWithWhereUniqueWithoutBeneficiarioMembershipInput = {
    where: MonthlyCycleWhereUniqueInput
    data: XOR<MonthlyCycleUpdateWithoutBeneficiarioMembershipInput, MonthlyCycleUncheckedUpdateWithoutBeneficiarioMembershipInput>
  }

  export type MonthlyCycleUpdateManyWithWhereWithoutBeneficiarioMembershipInput = {
    where: MonthlyCycleScalarWhereInput
    data: XOR<MonthlyCycleUpdateManyMutationInput, MonthlyCycleUncheckedUpdateManyWithoutBeneficiarioMembershipInput>
  }

  export type ContributionUpsertWithWhereUniqueWithoutMembershipInput = {
    where: ContributionWhereUniqueInput
    update: XOR<ContributionUpdateWithoutMembershipInput, ContributionUncheckedUpdateWithoutMembershipInput>
    create: XOR<ContributionCreateWithoutMembershipInput, ContributionUncheckedCreateWithoutMembershipInput>
  }

  export type ContributionUpdateWithWhereUniqueWithoutMembershipInput = {
    where: ContributionWhereUniqueInput
    data: XOR<ContributionUpdateWithoutMembershipInput, ContributionUncheckedUpdateWithoutMembershipInput>
  }

  export type ContributionUpdateManyWithWhereWithoutMembershipInput = {
    where: ContributionScalarWhereInput
    data: XOR<ContributionUpdateManyMutationInput, ContributionUncheckedUpdateManyWithoutMembershipInput>
  }

  export type GroupCreateWithoutInvitesInput = {
    id?: string
    nome: string
    descricao?: string | null
    numMembros: number
    valorContribuicaoMensal: number
    taxaPrincipalAplicada: number
    reservaTecnicaAplicada: number
    periodicidade?: string
    tipo?: string
    pais?: string
    moeda?: string
    status?: string
    dataInicio?: Date | string | null
    dataFimPrevista?: Date | string | null
    cicloAtual?: number
    totalCiclos: number
    createdAt?: Date | string
    updatedAt?: Date | string
    criador: UserCreateNestedOneWithoutGruposCriadosInput
    memberships?: MembershipCreateNestedManyWithoutGroupInput
    monthlyCycles?: MonthlyCycleCreateNestedManyWithoutGroupInput
    candidaturas?: GroupApplicationCreateNestedManyWithoutGroupInput
  }

  export type GroupUncheckedCreateWithoutInvitesInput = {
    id?: string
    nome: string
    descricao?: string | null
    criadorId: string
    numMembros: number
    valorContribuicaoMensal: number
    taxaPrincipalAplicada: number
    reservaTecnicaAplicada: number
    periodicidade?: string
    tipo?: string
    pais?: string
    moeda?: string
    status?: string
    dataInicio?: Date | string | null
    dataFimPrevista?: Date | string | null
    cicloAtual?: number
    totalCiclos: number
    createdAt?: Date | string
    updatedAt?: Date | string
    memberships?: MembershipUncheckedCreateNestedManyWithoutGroupInput
    monthlyCycles?: MonthlyCycleUncheckedCreateNestedManyWithoutGroupInput
    candidaturas?: GroupApplicationUncheckedCreateNestedManyWithoutGroupInput
  }

  export type GroupCreateOrConnectWithoutInvitesInput = {
    where: GroupWhereUniqueInput
    create: XOR<GroupCreateWithoutInvitesInput, GroupUncheckedCreateWithoutInvitesInput>
  }

  export type UserCreateWithoutInvitesEnviadosInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referredBy?: UserCreateNestedOneWithoutReferidosInput
    referidos?: UserCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupCreateNestedManyWithoutCriadorInput
    memberships?: MembershipCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionCreateNestedManyWithoutUserInput
    cashouts?: CashoutCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationCreateNestedManyWithoutUserInput
    otps?: OtpCreateNestedManyWithoutUserInput
    sessions?: SessionCreateNestedManyWithoutUserInput
    notifications?: NotificationCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionCreateNestedManyWithoutDecisorUserInput
    feeConfigsCriadas?: FeeConfigurationCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptCreateNestedManyWithoutUserInput
    badges?: BadgeCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyCreateNestedManyWithoutUserInput
  }

  export type UserUncheckedCreateWithoutInvitesEnviadosInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    referredById?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referidos?: UserUncheckedCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupUncheckedCreateNestedManyWithoutCriadorInput
    memberships?: MembershipUncheckedCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionUncheckedCreateNestedManyWithoutUserInput
    cashouts?: CashoutUncheckedCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanUncheckedCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventUncheckedCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationUncheckedCreateNestedManyWithoutUserInput
    otps?: OtpUncheckedCreateNestedManyWithoutUserInput
    sessions?: SessionUncheckedCreateNestedManyWithoutUserInput
    notifications?: NotificationUncheckedCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionUncheckedCreateNestedManyWithoutDecisorUserInput
    feeConfigsCriadas?: FeeConfigurationUncheckedCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogUncheckedCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationUncheckedCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountUncheckedCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralUncheckedCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralUncheckedCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptUncheckedCreateNestedManyWithoutUserInput
    badges?: BadgeUncheckedCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyUncheckedCreateNestedManyWithoutUserInput
  }

  export type UserCreateOrConnectWithoutInvitesEnviadosInput = {
    where: UserWhereUniqueInput
    create: XOR<UserCreateWithoutInvitesEnviadosInput, UserUncheckedCreateWithoutInvitesEnviadosInput>
  }

  export type GroupUpsertWithoutInvitesInput = {
    update: XOR<GroupUpdateWithoutInvitesInput, GroupUncheckedUpdateWithoutInvitesInput>
    create: XOR<GroupCreateWithoutInvitesInput, GroupUncheckedCreateWithoutInvitesInput>
    where?: GroupWhereInput
  }

  export type GroupUpdateToOneWithWhereWithoutInvitesInput = {
    where?: GroupWhereInput
    data: XOR<GroupUpdateWithoutInvitesInput, GroupUncheckedUpdateWithoutInvitesInput>
  }

  export type GroupUpdateWithoutInvitesInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    numMembros?: IntFieldUpdateOperationsInput | number
    valorContribuicaoMensal?: FloatFieldUpdateOperationsInput | number
    taxaPrincipalAplicada?: FloatFieldUpdateOperationsInput | number
    reservaTecnicaAplicada?: FloatFieldUpdateOperationsInput | number
    periodicidade?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    pais?: StringFieldUpdateOperationsInput | string
    moeda?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    dataInicio?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    dataFimPrevista?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    cicloAtual?: IntFieldUpdateOperationsInput | number
    totalCiclos?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    criador?: UserUpdateOneRequiredWithoutGruposCriadosNestedInput
    memberships?: MembershipUpdateManyWithoutGroupNestedInput
    monthlyCycles?: MonthlyCycleUpdateManyWithoutGroupNestedInput
    candidaturas?: GroupApplicationUpdateManyWithoutGroupNestedInput
  }

  export type GroupUncheckedUpdateWithoutInvitesInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    criadorId?: StringFieldUpdateOperationsInput | string
    numMembros?: IntFieldUpdateOperationsInput | number
    valorContribuicaoMensal?: FloatFieldUpdateOperationsInput | number
    taxaPrincipalAplicada?: FloatFieldUpdateOperationsInput | number
    reservaTecnicaAplicada?: FloatFieldUpdateOperationsInput | number
    periodicidade?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    pais?: StringFieldUpdateOperationsInput | string
    moeda?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    dataInicio?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    dataFimPrevista?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    cicloAtual?: IntFieldUpdateOperationsInput | number
    totalCiclos?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    memberships?: MembershipUncheckedUpdateManyWithoutGroupNestedInput
    monthlyCycles?: MonthlyCycleUncheckedUpdateManyWithoutGroupNestedInput
    candidaturas?: GroupApplicationUncheckedUpdateManyWithoutGroupNestedInput
  }

  export type UserUpsertWithoutInvitesEnviadosInput = {
    update: XOR<UserUpdateWithoutInvitesEnviadosInput, UserUncheckedUpdateWithoutInvitesEnviadosInput>
    create: XOR<UserCreateWithoutInvitesEnviadosInput, UserUncheckedCreateWithoutInvitesEnviadosInput>
    where?: UserWhereInput
  }

  export type UserUpdateToOneWithWhereWithoutInvitesEnviadosInput = {
    where?: UserWhereInput
    data: XOR<UserUpdateWithoutInvitesEnviadosInput, UserUncheckedUpdateWithoutInvitesEnviadosInput>
  }

  export type UserUpdateWithoutInvitesEnviadosInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referredBy?: UserUpdateOneWithoutReferidosNestedInput
    referidos?: UserUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUpdateManyWithoutUserNestedInput
    otps?: OtpUpdateManyWithoutUserNestedInput
    sessions?: SessionUpdateManyWithoutUserNestedInput
    notifications?: NotificationUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUpdateManyWithoutDecisorUserNestedInput
    feeConfigsCriadas?: FeeConfigurationUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUpdateManyWithoutUserNestedInput
    badges?: BadgeUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUpdateManyWithoutUserNestedInput
  }

  export type UserUncheckedUpdateWithoutInvitesEnviadosInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    referredById?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referidos?: UserUncheckedUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUncheckedUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUncheckedUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUncheckedUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUncheckedUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUncheckedUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUncheckedUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUncheckedUpdateManyWithoutUserNestedInput
    otps?: OtpUncheckedUpdateManyWithoutUserNestedInput
    sessions?: SessionUncheckedUpdateManyWithoutUserNestedInput
    notifications?: NotificationUncheckedUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUncheckedUpdateManyWithoutDecisorUserNestedInput
    feeConfigsCriadas?: FeeConfigurationUncheckedUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUncheckedUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUncheckedUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUncheckedUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUncheckedUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUncheckedUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUncheckedUpdateManyWithoutUserNestedInput
    badges?: BadgeUncheckedUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUncheckedUpdateManyWithoutUserNestedInput
  }

  export type GroupCreateWithoutMonthlyCyclesInput = {
    id?: string
    nome: string
    descricao?: string | null
    numMembros: number
    valorContribuicaoMensal: number
    taxaPrincipalAplicada: number
    reservaTecnicaAplicada: number
    periodicidade?: string
    tipo?: string
    pais?: string
    moeda?: string
    status?: string
    dataInicio?: Date | string | null
    dataFimPrevista?: Date | string | null
    cicloAtual?: number
    totalCiclos: number
    createdAt?: Date | string
    updatedAt?: Date | string
    criador: UserCreateNestedOneWithoutGruposCriadosInput
    memberships?: MembershipCreateNestedManyWithoutGroupInput
    invites?: InviteCreateNestedManyWithoutGroupInput
    candidaturas?: GroupApplicationCreateNestedManyWithoutGroupInput
  }

  export type GroupUncheckedCreateWithoutMonthlyCyclesInput = {
    id?: string
    nome: string
    descricao?: string | null
    criadorId: string
    numMembros: number
    valorContribuicaoMensal: number
    taxaPrincipalAplicada: number
    reservaTecnicaAplicada: number
    periodicidade?: string
    tipo?: string
    pais?: string
    moeda?: string
    status?: string
    dataInicio?: Date | string | null
    dataFimPrevista?: Date | string | null
    cicloAtual?: number
    totalCiclos: number
    createdAt?: Date | string
    updatedAt?: Date | string
    memberships?: MembershipUncheckedCreateNestedManyWithoutGroupInput
    invites?: InviteUncheckedCreateNestedManyWithoutGroupInput
    candidaturas?: GroupApplicationUncheckedCreateNestedManyWithoutGroupInput
  }

  export type GroupCreateOrConnectWithoutMonthlyCyclesInput = {
    where: GroupWhereUniqueInput
    create: XOR<GroupCreateWithoutMonthlyCyclesInput, GroupUncheckedCreateWithoutMonthlyCyclesInput>
  }

  export type MembershipCreateWithoutMonthlyCyclesBeneficiarioInput = {
    id?: string
    posicaoRotacao?: number | null
    status?: string
    necessidadeUrgente?: boolean
    dataJuncao?: Date | string
    mesRecepcaoPrevisto?: string | null
    user: UserCreateNestedOneWithoutMembershipsInput
    group: GroupCreateNestedOneWithoutMembershipsInput
    contribuicoes?: ContributionCreateNestedManyWithoutMembershipInput
  }

  export type MembershipUncheckedCreateWithoutMonthlyCyclesBeneficiarioInput = {
    id?: string
    userId: string
    groupId: string
    posicaoRotacao?: number | null
    status?: string
    necessidadeUrgente?: boolean
    dataJuncao?: Date | string
    mesRecepcaoPrevisto?: string | null
    contribuicoes?: ContributionUncheckedCreateNestedManyWithoutMembershipInput
  }

  export type MembershipCreateOrConnectWithoutMonthlyCyclesBeneficiarioInput = {
    where: MembershipWhereUniqueInput
    create: XOR<MembershipCreateWithoutMonthlyCyclesBeneficiarioInput, MembershipUncheckedCreateWithoutMonthlyCyclesBeneficiarioInput>
  }

  export type ContributionCreateWithoutMonthlyCycleInput = {
    id?: string
    valor: number
    dataPrevista: Date | string
    dataPagamento?: Date | string | null
    status?: string
    metodoPagamento?: string | null
    referenciaBancaria?: string | null
    comprovativoUrl?: string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    membership: MembershipCreateNestedOneWithoutContribuicoesInput
    user: UserCreateNestedOneWithoutContribuicoesInput
    coverageDecision?: CoverageDecisionCreateNestedOneWithoutContributionInput
  }

  export type ContributionUncheckedCreateWithoutMonthlyCycleInput = {
    id?: string
    membershipId: string
    userId: string
    valor: number
    dataPrevista: Date | string
    dataPagamento?: Date | string | null
    status?: string
    metodoPagamento?: string | null
    referenciaBancaria?: string | null
    comprovativoUrl?: string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    coverageDecision?: CoverageDecisionUncheckedCreateNestedOneWithoutContributionInput
  }

  export type ContributionCreateOrConnectWithoutMonthlyCycleInput = {
    where: ContributionWhereUniqueInput
    create: XOR<ContributionCreateWithoutMonthlyCycleInput, ContributionUncheckedCreateWithoutMonthlyCycleInput>
  }

  export type ContributionCreateManyMonthlyCycleInputEnvelope = {
    data: ContributionCreateManyMonthlyCycleInput | ContributionCreateManyMonthlyCycleInput[]
    skipDuplicates?: boolean
  }

  export type CashoutCreateWithoutMonthlyCycleInput = {
    id?: string
    valorBruto: number
    valorTaxaPrincipal: number
    valorReservaTecnica: number
    valorLiquido: number
    dataPrevista: Date | string
    dataExecucao?: Date | string | null
    status?: string
    contaDestino?: string | null
    refTransferencia?: string | null
    parcialMotivo?: string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    beneficiarioUser: UserCreateNestedOneWithoutCashoutsInput
  }

  export type CashoutUncheckedCreateWithoutMonthlyCycleInput = {
    id?: string
    beneficiarioUserId: string
    valorBruto: number
    valorTaxaPrincipal: number
    valorReservaTecnica: number
    valorLiquido: number
    dataPrevista: Date | string
    dataExecucao?: Date | string | null
    status?: string
    contaDestino?: string | null
    refTransferencia?: string | null
    parcialMotivo?: string | null
    createdAt?: Date | string
    updatedAt?: Date | string
  }

  export type CashoutCreateOrConnectWithoutMonthlyCycleInput = {
    where: CashoutWhereUniqueInput
    create: XOR<CashoutCreateWithoutMonthlyCycleInput, CashoutUncheckedCreateWithoutMonthlyCycleInput>
  }

  export type LoanCreateWithoutMonthlyCycleInput = {
    id?: string
    contributionId?: string | null
    valorCapital: number
    taxaEmprestimo: number
    valorTotalDevido: number
    jurosMoraAcumulados?: number
    dataInicio: Date | string
    dataPagamento?: Date | string | null
    status?: string
    createdAt?: Date | string
    updatedAt?: Date | string
    user: UserCreateNestedOneWithoutLoansInput
  }

  export type LoanUncheckedCreateWithoutMonthlyCycleInput = {
    id?: string
    userId: string
    contributionId?: string | null
    valorCapital: number
    taxaEmprestimo: number
    valorTotalDevido: number
    jurosMoraAcumulados?: number
    dataInicio: Date | string
    dataPagamento?: Date | string | null
    status?: string
    createdAt?: Date | string
    updatedAt?: Date | string
  }

  export type LoanCreateOrConnectWithoutMonthlyCycleInput = {
    where: LoanWhereUniqueInput
    create: XOR<LoanCreateWithoutMonthlyCycleInput, LoanUncheckedCreateWithoutMonthlyCycleInput>
  }

  export type LoanCreateManyMonthlyCycleInputEnvelope = {
    data: LoanCreateManyMonthlyCycleInput | LoanCreateManyMonthlyCycleInput[]
    skipDuplicates?: boolean
  }

  export type GroupUpsertWithoutMonthlyCyclesInput = {
    update: XOR<GroupUpdateWithoutMonthlyCyclesInput, GroupUncheckedUpdateWithoutMonthlyCyclesInput>
    create: XOR<GroupCreateWithoutMonthlyCyclesInput, GroupUncheckedCreateWithoutMonthlyCyclesInput>
    where?: GroupWhereInput
  }

  export type GroupUpdateToOneWithWhereWithoutMonthlyCyclesInput = {
    where?: GroupWhereInput
    data: XOR<GroupUpdateWithoutMonthlyCyclesInput, GroupUncheckedUpdateWithoutMonthlyCyclesInput>
  }

  export type GroupUpdateWithoutMonthlyCyclesInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    numMembros?: IntFieldUpdateOperationsInput | number
    valorContribuicaoMensal?: FloatFieldUpdateOperationsInput | number
    taxaPrincipalAplicada?: FloatFieldUpdateOperationsInput | number
    reservaTecnicaAplicada?: FloatFieldUpdateOperationsInput | number
    periodicidade?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    pais?: StringFieldUpdateOperationsInput | string
    moeda?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    dataInicio?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    dataFimPrevista?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    cicloAtual?: IntFieldUpdateOperationsInput | number
    totalCiclos?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    criador?: UserUpdateOneRequiredWithoutGruposCriadosNestedInput
    memberships?: MembershipUpdateManyWithoutGroupNestedInput
    invites?: InviteUpdateManyWithoutGroupNestedInput
    candidaturas?: GroupApplicationUpdateManyWithoutGroupNestedInput
  }

  export type GroupUncheckedUpdateWithoutMonthlyCyclesInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    criadorId?: StringFieldUpdateOperationsInput | string
    numMembros?: IntFieldUpdateOperationsInput | number
    valorContribuicaoMensal?: FloatFieldUpdateOperationsInput | number
    taxaPrincipalAplicada?: FloatFieldUpdateOperationsInput | number
    reservaTecnicaAplicada?: FloatFieldUpdateOperationsInput | number
    periodicidade?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    pais?: StringFieldUpdateOperationsInput | string
    moeda?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    dataInicio?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    dataFimPrevista?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    cicloAtual?: IntFieldUpdateOperationsInput | number
    totalCiclos?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    memberships?: MembershipUncheckedUpdateManyWithoutGroupNestedInput
    invites?: InviteUncheckedUpdateManyWithoutGroupNestedInput
    candidaturas?: GroupApplicationUncheckedUpdateManyWithoutGroupNestedInput
  }

  export type MembershipUpsertWithoutMonthlyCyclesBeneficiarioInput = {
    update: XOR<MembershipUpdateWithoutMonthlyCyclesBeneficiarioInput, MembershipUncheckedUpdateWithoutMonthlyCyclesBeneficiarioInput>
    create: XOR<MembershipCreateWithoutMonthlyCyclesBeneficiarioInput, MembershipUncheckedCreateWithoutMonthlyCyclesBeneficiarioInput>
    where?: MembershipWhereInput
  }

  export type MembershipUpdateToOneWithWhereWithoutMonthlyCyclesBeneficiarioInput = {
    where?: MembershipWhereInput
    data: XOR<MembershipUpdateWithoutMonthlyCyclesBeneficiarioInput, MembershipUncheckedUpdateWithoutMonthlyCyclesBeneficiarioInput>
  }

  export type MembershipUpdateWithoutMonthlyCyclesBeneficiarioInput = {
    id?: StringFieldUpdateOperationsInput | string
    posicaoRotacao?: NullableIntFieldUpdateOperationsInput | number | null
    status?: StringFieldUpdateOperationsInput | string
    necessidadeUrgente?: BoolFieldUpdateOperationsInput | boolean
    dataJuncao?: DateTimeFieldUpdateOperationsInput | Date | string
    mesRecepcaoPrevisto?: NullableStringFieldUpdateOperationsInput | string | null
    user?: UserUpdateOneRequiredWithoutMembershipsNestedInput
    group?: GroupUpdateOneRequiredWithoutMembershipsNestedInput
    contribuicoes?: ContributionUpdateManyWithoutMembershipNestedInput
  }

  export type MembershipUncheckedUpdateWithoutMonthlyCyclesBeneficiarioInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    groupId?: StringFieldUpdateOperationsInput | string
    posicaoRotacao?: NullableIntFieldUpdateOperationsInput | number | null
    status?: StringFieldUpdateOperationsInput | string
    necessidadeUrgente?: BoolFieldUpdateOperationsInput | boolean
    dataJuncao?: DateTimeFieldUpdateOperationsInput | Date | string
    mesRecepcaoPrevisto?: NullableStringFieldUpdateOperationsInput | string | null
    contribuicoes?: ContributionUncheckedUpdateManyWithoutMembershipNestedInput
  }

  export type ContributionUpsertWithWhereUniqueWithoutMonthlyCycleInput = {
    where: ContributionWhereUniqueInput
    update: XOR<ContributionUpdateWithoutMonthlyCycleInput, ContributionUncheckedUpdateWithoutMonthlyCycleInput>
    create: XOR<ContributionCreateWithoutMonthlyCycleInput, ContributionUncheckedCreateWithoutMonthlyCycleInput>
  }

  export type ContributionUpdateWithWhereUniqueWithoutMonthlyCycleInput = {
    where: ContributionWhereUniqueInput
    data: XOR<ContributionUpdateWithoutMonthlyCycleInput, ContributionUncheckedUpdateWithoutMonthlyCycleInput>
  }

  export type ContributionUpdateManyWithWhereWithoutMonthlyCycleInput = {
    where: ContributionScalarWhereInput
    data: XOR<ContributionUpdateManyMutationInput, ContributionUncheckedUpdateManyWithoutMonthlyCycleInput>
  }

  export type CashoutUpsertWithoutMonthlyCycleInput = {
    update: XOR<CashoutUpdateWithoutMonthlyCycleInput, CashoutUncheckedUpdateWithoutMonthlyCycleInput>
    create: XOR<CashoutCreateWithoutMonthlyCycleInput, CashoutUncheckedCreateWithoutMonthlyCycleInput>
    where?: CashoutWhereInput
  }

  export type CashoutUpdateToOneWithWhereWithoutMonthlyCycleInput = {
    where?: CashoutWhereInput
    data: XOR<CashoutUpdateWithoutMonthlyCycleInput, CashoutUncheckedUpdateWithoutMonthlyCycleInput>
  }

  export type CashoutUpdateWithoutMonthlyCycleInput = {
    id?: StringFieldUpdateOperationsInput | string
    valorBruto?: FloatFieldUpdateOperationsInput | number
    valorTaxaPrincipal?: FloatFieldUpdateOperationsInput | number
    valorReservaTecnica?: FloatFieldUpdateOperationsInput | number
    valorLiquido?: FloatFieldUpdateOperationsInput | number
    dataPrevista?: DateTimeFieldUpdateOperationsInput | Date | string
    dataExecucao?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
    contaDestino?: NullableStringFieldUpdateOperationsInput | string | null
    refTransferencia?: NullableStringFieldUpdateOperationsInput | string | null
    parcialMotivo?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    beneficiarioUser?: UserUpdateOneRequiredWithoutCashoutsNestedInput
  }

  export type CashoutUncheckedUpdateWithoutMonthlyCycleInput = {
    id?: StringFieldUpdateOperationsInput | string
    beneficiarioUserId?: StringFieldUpdateOperationsInput | string
    valorBruto?: FloatFieldUpdateOperationsInput | number
    valorTaxaPrincipal?: FloatFieldUpdateOperationsInput | number
    valorReservaTecnica?: FloatFieldUpdateOperationsInput | number
    valorLiquido?: FloatFieldUpdateOperationsInput | number
    dataPrevista?: DateTimeFieldUpdateOperationsInput | Date | string
    dataExecucao?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
    contaDestino?: NullableStringFieldUpdateOperationsInput | string | null
    refTransferencia?: NullableStringFieldUpdateOperationsInput | string | null
    parcialMotivo?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type LoanUpsertWithWhereUniqueWithoutMonthlyCycleInput = {
    where: LoanWhereUniqueInput
    update: XOR<LoanUpdateWithoutMonthlyCycleInput, LoanUncheckedUpdateWithoutMonthlyCycleInput>
    create: XOR<LoanCreateWithoutMonthlyCycleInput, LoanUncheckedCreateWithoutMonthlyCycleInput>
  }

  export type LoanUpdateWithWhereUniqueWithoutMonthlyCycleInput = {
    where: LoanWhereUniqueInput
    data: XOR<LoanUpdateWithoutMonthlyCycleInput, LoanUncheckedUpdateWithoutMonthlyCycleInput>
  }

  export type LoanUpdateManyWithWhereWithoutMonthlyCycleInput = {
    where: LoanScalarWhereInput
    data: XOR<LoanUpdateManyMutationInput, LoanUncheckedUpdateManyWithoutMonthlyCycleInput>
  }

  export type MembershipCreateWithoutContribuicoesInput = {
    id?: string
    posicaoRotacao?: number | null
    status?: string
    necessidadeUrgente?: boolean
    dataJuncao?: Date | string
    mesRecepcaoPrevisto?: string | null
    user: UserCreateNestedOneWithoutMembershipsInput
    group: GroupCreateNestedOneWithoutMembershipsInput
    monthlyCyclesBeneficiario?: MonthlyCycleCreateNestedManyWithoutBeneficiarioMembershipInput
  }

  export type MembershipUncheckedCreateWithoutContribuicoesInput = {
    id?: string
    userId: string
    groupId: string
    posicaoRotacao?: number | null
    status?: string
    necessidadeUrgente?: boolean
    dataJuncao?: Date | string
    mesRecepcaoPrevisto?: string | null
    monthlyCyclesBeneficiario?: MonthlyCycleUncheckedCreateNestedManyWithoutBeneficiarioMembershipInput
  }

  export type MembershipCreateOrConnectWithoutContribuicoesInput = {
    where: MembershipWhereUniqueInput
    create: XOR<MembershipCreateWithoutContribuicoesInput, MembershipUncheckedCreateWithoutContribuicoesInput>
  }

  export type UserCreateWithoutContribuicoesInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referredBy?: UserCreateNestedOneWithoutReferidosInput
    referidos?: UserCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupCreateNestedManyWithoutCriadorInput
    memberships?: MembershipCreateNestedManyWithoutUserInput
    cashouts?: CashoutCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationCreateNestedManyWithoutUserInput
    otps?: OtpCreateNestedManyWithoutUserInput
    sessions?: SessionCreateNestedManyWithoutUserInput
    notifications?: NotificationCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptCreateNestedManyWithoutUserInput
    badges?: BadgeCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyCreateNestedManyWithoutUserInput
  }

  export type UserUncheckedCreateWithoutContribuicoesInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    referredById?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referidos?: UserUncheckedCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupUncheckedCreateNestedManyWithoutCriadorInput
    memberships?: MembershipUncheckedCreateNestedManyWithoutUserInput
    cashouts?: CashoutUncheckedCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanUncheckedCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventUncheckedCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationUncheckedCreateNestedManyWithoutUserInput
    otps?: OtpUncheckedCreateNestedManyWithoutUserInput
    sessions?: SessionUncheckedCreateNestedManyWithoutUserInput
    notifications?: NotificationUncheckedCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionUncheckedCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteUncheckedCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationUncheckedCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogUncheckedCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationUncheckedCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountUncheckedCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralUncheckedCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralUncheckedCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptUncheckedCreateNestedManyWithoutUserInput
    badges?: BadgeUncheckedCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyUncheckedCreateNestedManyWithoutUserInput
  }

  export type UserCreateOrConnectWithoutContribuicoesInput = {
    where: UserWhereUniqueInput
    create: XOR<UserCreateWithoutContribuicoesInput, UserUncheckedCreateWithoutContribuicoesInput>
  }

  export type MonthlyCycleCreateWithoutContribuicoesInput = {
    id?: string
    numeroCiclo: number
    mesAno: string
    dataContribuicaoLimite: Date | string
    dataCashout: Date | string
    status?: string
    valorPoteBruto: number
    valorTaxaPrincipal: number
    valorReservaTecnica: number
    valorPoteLiquido: number
    createdAt?: Date | string
    updatedAt?: Date | string
    group: GroupCreateNestedOneWithoutMonthlyCyclesInput
    beneficiarioMembership: MembershipCreateNestedOneWithoutMonthlyCyclesBeneficiarioInput
    cashout?: CashoutCreateNestedOneWithoutMonthlyCycleInput
    loans?: LoanCreateNestedManyWithoutMonthlyCycleInput
  }

  export type MonthlyCycleUncheckedCreateWithoutContribuicoesInput = {
    id?: string
    groupId: string
    numeroCiclo: number
    mesAno: string
    beneficiarioMembershipId: string
    dataContribuicaoLimite: Date | string
    dataCashout: Date | string
    status?: string
    valorPoteBruto: number
    valorTaxaPrincipal: number
    valorReservaTecnica: number
    valorPoteLiquido: number
    createdAt?: Date | string
    updatedAt?: Date | string
    cashout?: CashoutUncheckedCreateNestedOneWithoutMonthlyCycleInput
    loans?: LoanUncheckedCreateNestedManyWithoutMonthlyCycleInput
  }

  export type MonthlyCycleCreateOrConnectWithoutContribuicoesInput = {
    where: MonthlyCycleWhereUniqueInput
    create: XOR<MonthlyCycleCreateWithoutContribuicoesInput, MonthlyCycleUncheckedCreateWithoutContribuicoesInput>
  }

  export type CoverageDecisionCreateWithoutContributionInput = {
    id?: string
    decisao: string
    motivo: string
    scoreNoMomento: number
    historicoInadimplencias: number
    decisorSistema?: boolean
    createdAt?: Date | string
    decisorUser?: UserCreateNestedOneWithoutCoverageDecisionsInput
  }

  export type CoverageDecisionUncheckedCreateWithoutContributionInput = {
    id?: string
    decisao: string
    motivo: string
    scoreNoMomento: number
    historicoInadimplencias: number
    decisorUserId?: string | null
    decisorSistema?: boolean
    createdAt?: Date | string
  }

  export type CoverageDecisionCreateOrConnectWithoutContributionInput = {
    where: CoverageDecisionWhereUniqueInput
    create: XOR<CoverageDecisionCreateWithoutContributionInput, CoverageDecisionUncheckedCreateWithoutContributionInput>
  }

  export type MembershipUpsertWithoutContribuicoesInput = {
    update: XOR<MembershipUpdateWithoutContribuicoesInput, MembershipUncheckedUpdateWithoutContribuicoesInput>
    create: XOR<MembershipCreateWithoutContribuicoesInput, MembershipUncheckedCreateWithoutContribuicoesInput>
    where?: MembershipWhereInput
  }

  export type MembershipUpdateToOneWithWhereWithoutContribuicoesInput = {
    where?: MembershipWhereInput
    data: XOR<MembershipUpdateWithoutContribuicoesInput, MembershipUncheckedUpdateWithoutContribuicoesInput>
  }

  export type MembershipUpdateWithoutContribuicoesInput = {
    id?: StringFieldUpdateOperationsInput | string
    posicaoRotacao?: NullableIntFieldUpdateOperationsInput | number | null
    status?: StringFieldUpdateOperationsInput | string
    necessidadeUrgente?: BoolFieldUpdateOperationsInput | boolean
    dataJuncao?: DateTimeFieldUpdateOperationsInput | Date | string
    mesRecepcaoPrevisto?: NullableStringFieldUpdateOperationsInput | string | null
    user?: UserUpdateOneRequiredWithoutMembershipsNestedInput
    group?: GroupUpdateOneRequiredWithoutMembershipsNestedInput
    monthlyCyclesBeneficiario?: MonthlyCycleUpdateManyWithoutBeneficiarioMembershipNestedInput
  }

  export type MembershipUncheckedUpdateWithoutContribuicoesInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    groupId?: StringFieldUpdateOperationsInput | string
    posicaoRotacao?: NullableIntFieldUpdateOperationsInput | number | null
    status?: StringFieldUpdateOperationsInput | string
    necessidadeUrgente?: BoolFieldUpdateOperationsInput | boolean
    dataJuncao?: DateTimeFieldUpdateOperationsInput | Date | string
    mesRecepcaoPrevisto?: NullableStringFieldUpdateOperationsInput | string | null
    monthlyCyclesBeneficiario?: MonthlyCycleUncheckedUpdateManyWithoutBeneficiarioMembershipNestedInput
  }

  export type UserUpsertWithoutContribuicoesInput = {
    update: XOR<UserUpdateWithoutContribuicoesInput, UserUncheckedUpdateWithoutContribuicoesInput>
    create: XOR<UserCreateWithoutContribuicoesInput, UserUncheckedCreateWithoutContribuicoesInput>
    where?: UserWhereInput
  }

  export type UserUpdateToOneWithWhereWithoutContribuicoesInput = {
    where?: UserWhereInput
    data: XOR<UserUpdateWithoutContribuicoesInput, UserUncheckedUpdateWithoutContribuicoesInput>
  }

  export type UserUpdateWithoutContribuicoesInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referredBy?: UserUpdateOneWithoutReferidosNestedInput
    referidos?: UserUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUpdateManyWithoutUserNestedInput
    otps?: OtpUpdateManyWithoutUserNestedInput
    sessions?: SessionUpdateManyWithoutUserNestedInput
    notifications?: NotificationUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUpdateManyWithoutUserNestedInput
    badges?: BadgeUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUpdateManyWithoutUserNestedInput
  }

  export type UserUncheckedUpdateWithoutContribuicoesInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    referredById?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referidos?: UserUncheckedUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUncheckedUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUncheckedUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUncheckedUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUncheckedUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUncheckedUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUncheckedUpdateManyWithoutUserNestedInput
    otps?: OtpUncheckedUpdateManyWithoutUserNestedInput
    sessions?: SessionUncheckedUpdateManyWithoutUserNestedInput
    notifications?: NotificationUncheckedUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUncheckedUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUncheckedUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUncheckedUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUncheckedUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUncheckedUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUncheckedUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUncheckedUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUncheckedUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUncheckedUpdateManyWithoutUserNestedInput
    badges?: BadgeUncheckedUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUncheckedUpdateManyWithoutUserNestedInput
  }

  export type MonthlyCycleUpsertWithoutContribuicoesInput = {
    update: XOR<MonthlyCycleUpdateWithoutContribuicoesInput, MonthlyCycleUncheckedUpdateWithoutContribuicoesInput>
    create: XOR<MonthlyCycleCreateWithoutContribuicoesInput, MonthlyCycleUncheckedCreateWithoutContribuicoesInput>
    where?: MonthlyCycleWhereInput
  }

  export type MonthlyCycleUpdateToOneWithWhereWithoutContribuicoesInput = {
    where?: MonthlyCycleWhereInput
    data: XOR<MonthlyCycleUpdateWithoutContribuicoesInput, MonthlyCycleUncheckedUpdateWithoutContribuicoesInput>
  }

  export type MonthlyCycleUpdateWithoutContribuicoesInput = {
    id?: StringFieldUpdateOperationsInput | string
    numeroCiclo?: IntFieldUpdateOperationsInput | number
    mesAno?: StringFieldUpdateOperationsInput | string
    dataContribuicaoLimite?: DateTimeFieldUpdateOperationsInput | Date | string
    dataCashout?: DateTimeFieldUpdateOperationsInput | Date | string
    status?: StringFieldUpdateOperationsInput | string
    valorPoteBruto?: FloatFieldUpdateOperationsInput | number
    valorTaxaPrincipal?: FloatFieldUpdateOperationsInput | number
    valorReservaTecnica?: FloatFieldUpdateOperationsInput | number
    valorPoteLiquido?: FloatFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    group?: GroupUpdateOneRequiredWithoutMonthlyCyclesNestedInput
    beneficiarioMembership?: MembershipUpdateOneRequiredWithoutMonthlyCyclesBeneficiarioNestedInput
    cashout?: CashoutUpdateOneWithoutMonthlyCycleNestedInput
    loans?: LoanUpdateManyWithoutMonthlyCycleNestedInput
  }

  export type MonthlyCycleUncheckedUpdateWithoutContribuicoesInput = {
    id?: StringFieldUpdateOperationsInput | string
    groupId?: StringFieldUpdateOperationsInput | string
    numeroCiclo?: IntFieldUpdateOperationsInput | number
    mesAno?: StringFieldUpdateOperationsInput | string
    beneficiarioMembershipId?: StringFieldUpdateOperationsInput | string
    dataContribuicaoLimite?: DateTimeFieldUpdateOperationsInput | Date | string
    dataCashout?: DateTimeFieldUpdateOperationsInput | Date | string
    status?: StringFieldUpdateOperationsInput | string
    valorPoteBruto?: FloatFieldUpdateOperationsInput | number
    valorTaxaPrincipal?: FloatFieldUpdateOperationsInput | number
    valorReservaTecnica?: FloatFieldUpdateOperationsInput | number
    valorPoteLiquido?: FloatFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    cashout?: CashoutUncheckedUpdateOneWithoutMonthlyCycleNestedInput
    loans?: LoanUncheckedUpdateManyWithoutMonthlyCycleNestedInput
  }

  export type CoverageDecisionUpsertWithoutContributionInput = {
    update: XOR<CoverageDecisionUpdateWithoutContributionInput, CoverageDecisionUncheckedUpdateWithoutContributionInput>
    create: XOR<CoverageDecisionCreateWithoutContributionInput, CoverageDecisionUncheckedCreateWithoutContributionInput>
    where?: CoverageDecisionWhereInput
  }

  export type CoverageDecisionUpdateToOneWithWhereWithoutContributionInput = {
    where?: CoverageDecisionWhereInput
    data: XOR<CoverageDecisionUpdateWithoutContributionInput, CoverageDecisionUncheckedUpdateWithoutContributionInput>
  }

  export type CoverageDecisionUpdateWithoutContributionInput = {
    id?: StringFieldUpdateOperationsInput | string
    decisao?: StringFieldUpdateOperationsInput | string
    motivo?: StringFieldUpdateOperationsInput | string
    scoreNoMomento?: IntFieldUpdateOperationsInput | number
    historicoInadimplencias?: IntFieldUpdateOperationsInput | number
    decisorSistema?: BoolFieldUpdateOperationsInput | boolean
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    decisorUser?: UserUpdateOneWithoutCoverageDecisionsNestedInput
  }

  export type CoverageDecisionUncheckedUpdateWithoutContributionInput = {
    id?: StringFieldUpdateOperationsInput | string
    decisao?: StringFieldUpdateOperationsInput | string
    motivo?: StringFieldUpdateOperationsInput | string
    scoreNoMomento?: IntFieldUpdateOperationsInput | number
    historicoInadimplencias?: IntFieldUpdateOperationsInput | number
    decisorUserId?: NullableStringFieldUpdateOperationsInput | string | null
    decisorSistema?: BoolFieldUpdateOperationsInput | boolean
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type MonthlyCycleCreateWithoutCashoutInput = {
    id?: string
    numeroCiclo: number
    mesAno: string
    dataContribuicaoLimite: Date | string
    dataCashout: Date | string
    status?: string
    valorPoteBruto: number
    valorTaxaPrincipal: number
    valorReservaTecnica: number
    valorPoteLiquido: number
    createdAt?: Date | string
    updatedAt?: Date | string
    group: GroupCreateNestedOneWithoutMonthlyCyclesInput
    beneficiarioMembership: MembershipCreateNestedOneWithoutMonthlyCyclesBeneficiarioInput
    contribuicoes?: ContributionCreateNestedManyWithoutMonthlyCycleInput
    loans?: LoanCreateNestedManyWithoutMonthlyCycleInput
  }

  export type MonthlyCycleUncheckedCreateWithoutCashoutInput = {
    id?: string
    groupId: string
    numeroCiclo: number
    mesAno: string
    beneficiarioMembershipId: string
    dataContribuicaoLimite: Date | string
    dataCashout: Date | string
    status?: string
    valorPoteBruto: number
    valorTaxaPrincipal: number
    valorReservaTecnica: number
    valorPoteLiquido: number
    createdAt?: Date | string
    updatedAt?: Date | string
    contribuicoes?: ContributionUncheckedCreateNestedManyWithoutMonthlyCycleInput
    loans?: LoanUncheckedCreateNestedManyWithoutMonthlyCycleInput
  }

  export type MonthlyCycleCreateOrConnectWithoutCashoutInput = {
    where: MonthlyCycleWhereUniqueInput
    create: XOR<MonthlyCycleCreateWithoutCashoutInput, MonthlyCycleUncheckedCreateWithoutCashoutInput>
  }

  export type UserCreateWithoutCashoutsInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referredBy?: UserCreateNestedOneWithoutReferidosInput
    referidos?: UserCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupCreateNestedManyWithoutCriadorInput
    memberships?: MembershipCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionCreateNestedManyWithoutUserInput
    loans?: LoanCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationCreateNestedManyWithoutUserInput
    otps?: OtpCreateNestedManyWithoutUserInput
    sessions?: SessionCreateNestedManyWithoutUserInput
    notifications?: NotificationCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptCreateNestedManyWithoutUserInput
    badges?: BadgeCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyCreateNestedManyWithoutUserInput
  }

  export type UserUncheckedCreateWithoutCashoutsInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    referredById?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referidos?: UserUncheckedCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupUncheckedCreateNestedManyWithoutCriadorInput
    memberships?: MembershipUncheckedCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionUncheckedCreateNestedManyWithoutUserInput
    loans?: LoanUncheckedCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventUncheckedCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationUncheckedCreateNestedManyWithoutUserInput
    otps?: OtpUncheckedCreateNestedManyWithoutUserInput
    sessions?: SessionUncheckedCreateNestedManyWithoutUserInput
    notifications?: NotificationUncheckedCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionUncheckedCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteUncheckedCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationUncheckedCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogUncheckedCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationUncheckedCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountUncheckedCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralUncheckedCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralUncheckedCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptUncheckedCreateNestedManyWithoutUserInput
    badges?: BadgeUncheckedCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyUncheckedCreateNestedManyWithoutUserInput
  }

  export type UserCreateOrConnectWithoutCashoutsInput = {
    where: UserWhereUniqueInput
    create: XOR<UserCreateWithoutCashoutsInput, UserUncheckedCreateWithoutCashoutsInput>
  }

  export type MonthlyCycleUpsertWithoutCashoutInput = {
    update: XOR<MonthlyCycleUpdateWithoutCashoutInput, MonthlyCycleUncheckedUpdateWithoutCashoutInput>
    create: XOR<MonthlyCycleCreateWithoutCashoutInput, MonthlyCycleUncheckedCreateWithoutCashoutInput>
    where?: MonthlyCycleWhereInput
  }

  export type MonthlyCycleUpdateToOneWithWhereWithoutCashoutInput = {
    where?: MonthlyCycleWhereInput
    data: XOR<MonthlyCycleUpdateWithoutCashoutInput, MonthlyCycleUncheckedUpdateWithoutCashoutInput>
  }

  export type MonthlyCycleUpdateWithoutCashoutInput = {
    id?: StringFieldUpdateOperationsInput | string
    numeroCiclo?: IntFieldUpdateOperationsInput | number
    mesAno?: StringFieldUpdateOperationsInput | string
    dataContribuicaoLimite?: DateTimeFieldUpdateOperationsInput | Date | string
    dataCashout?: DateTimeFieldUpdateOperationsInput | Date | string
    status?: StringFieldUpdateOperationsInput | string
    valorPoteBruto?: FloatFieldUpdateOperationsInput | number
    valorTaxaPrincipal?: FloatFieldUpdateOperationsInput | number
    valorReservaTecnica?: FloatFieldUpdateOperationsInput | number
    valorPoteLiquido?: FloatFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    group?: GroupUpdateOneRequiredWithoutMonthlyCyclesNestedInput
    beneficiarioMembership?: MembershipUpdateOneRequiredWithoutMonthlyCyclesBeneficiarioNestedInput
    contribuicoes?: ContributionUpdateManyWithoutMonthlyCycleNestedInput
    loans?: LoanUpdateManyWithoutMonthlyCycleNestedInput
  }

  export type MonthlyCycleUncheckedUpdateWithoutCashoutInput = {
    id?: StringFieldUpdateOperationsInput | string
    groupId?: StringFieldUpdateOperationsInput | string
    numeroCiclo?: IntFieldUpdateOperationsInput | number
    mesAno?: StringFieldUpdateOperationsInput | string
    beneficiarioMembershipId?: StringFieldUpdateOperationsInput | string
    dataContribuicaoLimite?: DateTimeFieldUpdateOperationsInput | Date | string
    dataCashout?: DateTimeFieldUpdateOperationsInput | Date | string
    status?: StringFieldUpdateOperationsInput | string
    valorPoteBruto?: FloatFieldUpdateOperationsInput | number
    valorTaxaPrincipal?: FloatFieldUpdateOperationsInput | number
    valorReservaTecnica?: FloatFieldUpdateOperationsInput | number
    valorPoteLiquido?: FloatFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    contribuicoes?: ContributionUncheckedUpdateManyWithoutMonthlyCycleNestedInput
    loans?: LoanUncheckedUpdateManyWithoutMonthlyCycleNestedInput
  }

  export type UserUpsertWithoutCashoutsInput = {
    update: XOR<UserUpdateWithoutCashoutsInput, UserUncheckedUpdateWithoutCashoutsInput>
    create: XOR<UserCreateWithoutCashoutsInput, UserUncheckedCreateWithoutCashoutsInput>
    where?: UserWhereInput
  }

  export type UserUpdateToOneWithWhereWithoutCashoutsInput = {
    where?: UserWhereInput
    data: XOR<UserUpdateWithoutCashoutsInput, UserUncheckedUpdateWithoutCashoutsInput>
  }

  export type UserUpdateWithoutCashoutsInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referredBy?: UserUpdateOneWithoutReferidosNestedInput
    referidos?: UserUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUpdateManyWithoutUserNestedInput
    loans?: LoanUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUpdateManyWithoutUserNestedInput
    otps?: OtpUpdateManyWithoutUserNestedInput
    sessions?: SessionUpdateManyWithoutUserNestedInput
    notifications?: NotificationUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUpdateManyWithoutUserNestedInput
    badges?: BadgeUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUpdateManyWithoutUserNestedInput
  }

  export type UserUncheckedUpdateWithoutCashoutsInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    referredById?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referidos?: UserUncheckedUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUncheckedUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUncheckedUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUncheckedUpdateManyWithoutUserNestedInput
    loans?: LoanUncheckedUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUncheckedUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUncheckedUpdateManyWithoutUserNestedInput
    otps?: OtpUncheckedUpdateManyWithoutUserNestedInput
    sessions?: SessionUncheckedUpdateManyWithoutUserNestedInput
    notifications?: NotificationUncheckedUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUncheckedUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUncheckedUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUncheckedUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUncheckedUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUncheckedUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUncheckedUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUncheckedUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUncheckedUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUncheckedUpdateManyWithoutUserNestedInput
    badges?: BadgeUncheckedUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUncheckedUpdateManyWithoutUserNestedInput
  }

  export type UserCreateWithoutLoansInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referredBy?: UserCreateNestedOneWithoutReferidosInput
    referidos?: UserCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupCreateNestedManyWithoutCriadorInput
    memberships?: MembershipCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionCreateNestedManyWithoutUserInput
    cashouts?: CashoutCreateNestedManyWithoutBeneficiarioUserInput
    scoreEvents?: ScoreEventCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationCreateNestedManyWithoutUserInput
    otps?: OtpCreateNestedManyWithoutUserInput
    sessions?: SessionCreateNestedManyWithoutUserInput
    notifications?: NotificationCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptCreateNestedManyWithoutUserInput
    badges?: BadgeCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyCreateNestedManyWithoutUserInput
  }

  export type UserUncheckedCreateWithoutLoansInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    referredById?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referidos?: UserUncheckedCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupUncheckedCreateNestedManyWithoutCriadorInput
    memberships?: MembershipUncheckedCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionUncheckedCreateNestedManyWithoutUserInput
    cashouts?: CashoutUncheckedCreateNestedManyWithoutBeneficiarioUserInput
    scoreEvents?: ScoreEventUncheckedCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationUncheckedCreateNestedManyWithoutUserInput
    otps?: OtpUncheckedCreateNestedManyWithoutUserInput
    sessions?: SessionUncheckedCreateNestedManyWithoutUserInput
    notifications?: NotificationUncheckedCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionUncheckedCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteUncheckedCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationUncheckedCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogUncheckedCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationUncheckedCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountUncheckedCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralUncheckedCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralUncheckedCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptUncheckedCreateNestedManyWithoutUserInput
    badges?: BadgeUncheckedCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyUncheckedCreateNestedManyWithoutUserInput
  }

  export type UserCreateOrConnectWithoutLoansInput = {
    where: UserWhereUniqueInput
    create: XOR<UserCreateWithoutLoansInput, UserUncheckedCreateWithoutLoansInput>
  }

  export type MonthlyCycleCreateWithoutLoansInput = {
    id?: string
    numeroCiclo: number
    mesAno: string
    dataContribuicaoLimite: Date | string
    dataCashout: Date | string
    status?: string
    valorPoteBruto: number
    valorTaxaPrincipal: number
    valorReservaTecnica: number
    valorPoteLiquido: number
    createdAt?: Date | string
    updatedAt?: Date | string
    group: GroupCreateNestedOneWithoutMonthlyCyclesInput
    beneficiarioMembership: MembershipCreateNestedOneWithoutMonthlyCyclesBeneficiarioInput
    contribuicoes?: ContributionCreateNestedManyWithoutMonthlyCycleInput
    cashout?: CashoutCreateNestedOneWithoutMonthlyCycleInput
  }

  export type MonthlyCycleUncheckedCreateWithoutLoansInput = {
    id?: string
    groupId: string
    numeroCiclo: number
    mesAno: string
    beneficiarioMembershipId: string
    dataContribuicaoLimite: Date | string
    dataCashout: Date | string
    status?: string
    valorPoteBruto: number
    valorTaxaPrincipal: number
    valorReservaTecnica: number
    valorPoteLiquido: number
    createdAt?: Date | string
    updatedAt?: Date | string
    contribuicoes?: ContributionUncheckedCreateNestedManyWithoutMonthlyCycleInput
    cashout?: CashoutUncheckedCreateNestedOneWithoutMonthlyCycleInput
  }

  export type MonthlyCycleCreateOrConnectWithoutLoansInput = {
    where: MonthlyCycleWhereUniqueInput
    create: XOR<MonthlyCycleCreateWithoutLoansInput, MonthlyCycleUncheckedCreateWithoutLoansInput>
  }

  export type UserUpsertWithoutLoansInput = {
    update: XOR<UserUpdateWithoutLoansInput, UserUncheckedUpdateWithoutLoansInput>
    create: XOR<UserCreateWithoutLoansInput, UserUncheckedCreateWithoutLoansInput>
    where?: UserWhereInput
  }

  export type UserUpdateToOneWithWhereWithoutLoansInput = {
    where?: UserWhereInput
    data: XOR<UserUpdateWithoutLoansInput, UserUncheckedUpdateWithoutLoansInput>
  }

  export type UserUpdateWithoutLoansInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referredBy?: UserUpdateOneWithoutReferidosNestedInput
    referidos?: UserUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUpdateManyWithoutBeneficiarioUserNestedInput
    scoreEvents?: ScoreEventUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUpdateManyWithoutUserNestedInput
    otps?: OtpUpdateManyWithoutUserNestedInput
    sessions?: SessionUpdateManyWithoutUserNestedInput
    notifications?: NotificationUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUpdateManyWithoutUserNestedInput
    badges?: BadgeUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUpdateManyWithoutUserNestedInput
  }

  export type UserUncheckedUpdateWithoutLoansInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    referredById?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referidos?: UserUncheckedUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUncheckedUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUncheckedUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUncheckedUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUncheckedUpdateManyWithoutBeneficiarioUserNestedInput
    scoreEvents?: ScoreEventUncheckedUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUncheckedUpdateManyWithoutUserNestedInput
    otps?: OtpUncheckedUpdateManyWithoutUserNestedInput
    sessions?: SessionUncheckedUpdateManyWithoutUserNestedInput
    notifications?: NotificationUncheckedUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUncheckedUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUncheckedUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUncheckedUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUncheckedUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUncheckedUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUncheckedUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUncheckedUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUncheckedUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUncheckedUpdateManyWithoutUserNestedInput
    badges?: BadgeUncheckedUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUncheckedUpdateManyWithoutUserNestedInput
  }

  export type MonthlyCycleUpsertWithoutLoansInput = {
    update: XOR<MonthlyCycleUpdateWithoutLoansInput, MonthlyCycleUncheckedUpdateWithoutLoansInput>
    create: XOR<MonthlyCycleCreateWithoutLoansInput, MonthlyCycleUncheckedCreateWithoutLoansInput>
    where?: MonthlyCycleWhereInput
  }

  export type MonthlyCycleUpdateToOneWithWhereWithoutLoansInput = {
    where?: MonthlyCycleWhereInput
    data: XOR<MonthlyCycleUpdateWithoutLoansInput, MonthlyCycleUncheckedUpdateWithoutLoansInput>
  }

  export type MonthlyCycleUpdateWithoutLoansInput = {
    id?: StringFieldUpdateOperationsInput | string
    numeroCiclo?: IntFieldUpdateOperationsInput | number
    mesAno?: StringFieldUpdateOperationsInput | string
    dataContribuicaoLimite?: DateTimeFieldUpdateOperationsInput | Date | string
    dataCashout?: DateTimeFieldUpdateOperationsInput | Date | string
    status?: StringFieldUpdateOperationsInput | string
    valorPoteBruto?: FloatFieldUpdateOperationsInput | number
    valorTaxaPrincipal?: FloatFieldUpdateOperationsInput | number
    valorReservaTecnica?: FloatFieldUpdateOperationsInput | number
    valorPoteLiquido?: FloatFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    group?: GroupUpdateOneRequiredWithoutMonthlyCyclesNestedInput
    beneficiarioMembership?: MembershipUpdateOneRequiredWithoutMonthlyCyclesBeneficiarioNestedInput
    contribuicoes?: ContributionUpdateManyWithoutMonthlyCycleNestedInput
    cashout?: CashoutUpdateOneWithoutMonthlyCycleNestedInput
  }

  export type MonthlyCycleUncheckedUpdateWithoutLoansInput = {
    id?: StringFieldUpdateOperationsInput | string
    groupId?: StringFieldUpdateOperationsInput | string
    numeroCiclo?: IntFieldUpdateOperationsInput | number
    mesAno?: StringFieldUpdateOperationsInput | string
    beneficiarioMembershipId?: StringFieldUpdateOperationsInput | string
    dataContribuicaoLimite?: DateTimeFieldUpdateOperationsInput | Date | string
    dataCashout?: DateTimeFieldUpdateOperationsInput | Date | string
    status?: StringFieldUpdateOperationsInput | string
    valorPoteBruto?: FloatFieldUpdateOperationsInput | number
    valorTaxaPrincipal?: FloatFieldUpdateOperationsInput | number
    valorReservaTecnica?: FloatFieldUpdateOperationsInput | number
    valorPoteLiquido?: FloatFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    contribuicoes?: ContributionUncheckedUpdateManyWithoutMonthlyCycleNestedInput
    cashout?: CashoutUncheckedUpdateOneWithoutMonthlyCycleNestedInput
  }

  export type ContributionCreateWithoutCoverageDecisionInput = {
    id?: string
    valor: number
    dataPrevista: Date | string
    dataPagamento?: Date | string | null
    status?: string
    metodoPagamento?: string | null
    referenciaBancaria?: string | null
    comprovativoUrl?: string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    membership: MembershipCreateNestedOneWithoutContribuicoesInput
    user: UserCreateNestedOneWithoutContribuicoesInput
    monthlyCycle: MonthlyCycleCreateNestedOneWithoutContribuicoesInput
  }

  export type ContributionUncheckedCreateWithoutCoverageDecisionInput = {
    id?: string
    membershipId: string
    userId: string
    monthlyCycleId: string
    valor: number
    dataPrevista: Date | string
    dataPagamento?: Date | string | null
    status?: string
    metodoPagamento?: string | null
    referenciaBancaria?: string | null
    comprovativoUrl?: string | null
    createdAt?: Date | string
    updatedAt?: Date | string
  }

  export type ContributionCreateOrConnectWithoutCoverageDecisionInput = {
    where: ContributionWhereUniqueInput
    create: XOR<ContributionCreateWithoutCoverageDecisionInput, ContributionUncheckedCreateWithoutCoverageDecisionInput>
  }

  export type UserCreateWithoutCoverageDecisionsInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referredBy?: UserCreateNestedOneWithoutReferidosInput
    referidos?: UserCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupCreateNestedManyWithoutCriadorInput
    memberships?: MembershipCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionCreateNestedManyWithoutUserInput
    cashouts?: CashoutCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationCreateNestedManyWithoutUserInput
    otps?: OtpCreateNestedManyWithoutUserInput
    sessions?: SessionCreateNestedManyWithoutUserInput
    notifications?: NotificationCreateNestedManyWithoutUserInput
    invitesEnviados?: InviteCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptCreateNestedManyWithoutUserInput
    badges?: BadgeCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyCreateNestedManyWithoutUserInput
  }

  export type UserUncheckedCreateWithoutCoverageDecisionsInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    referredById?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referidos?: UserUncheckedCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupUncheckedCreateNestedManyWithoutCriadorInput
    memberships?: MembershipUncheckedCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionUncheckedCreateNestedManyWithoutUserInput
    cashouts?: CashoutUncheckedCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanUncheckedCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventUncheckedCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationUncheckedCreateNestedManyWithoutUserInput
    otps?: OtpUncheckedCreateNestedManyWithoutUserInput
    sessions?: SessionUncheckedCreateNestedManyWithoutUserInput
    notifications?: NotificationUncheckedCreateNestedManyWithoutUserInput
    invitesEnviados?: InviteUncheckedCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationUncheckedCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogUncheckedCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationUncheckedCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountUncheckedCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralUncheckedCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralUncheckedCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptUncheckedCreateNestedManyWithoutUserInput
    badges?: BadgeUncheckedCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyUncheckedCreateNestedManyWithoutUserInput
  }

  export type UserCreateOrConnectWithoutCoverageDecisionsInput = {
    where: UserWhereUniqueInput
    create: XOR<UserCreateWithoutCoverageDecisionsInput, UserUncheckedCreateWithoutCoverageDecisionsInput>
  }

  export type ContributionUpsertWithoutCoverageDecisionInput = {
    update: XOR<ContributionUpdateWithoutCoverageDecisionInput, ContributionUncheckedUpdateWithoutCoverageDecisionInput>
    create: XOR<ContributionCreateWithoutCoverageDecisionInput, ContributionUncheckedCreateWithoutCoverageDecisionInput>
    where?: ContributionWhereInput
  }

  export type ContributionUpdateToOneWithWhereWithoutCoverageDecisionInput = {
    where?: ContributionWhereInput
    data: XOR<ContributionUpdateWithoutCoverageDecisionInput, ContributionUncheckedUpdateWithoutCoverageDecisionInput>
  }

  export type ContributionUpdateWithoutCoverageDecisionInput = {
    id?: StringFieldUpdateOperationsInput | string
    valor?: FloatFieldUpdateOperationsInput | number
    dataPrevista?: DateTimeFieldUpdateOperationsInput | Date | string
    dataPagamento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
    metodoPagamento?: NullableStringFieldUpdateOperationsInput | string | null
    referenciaBancaria?: NullableStringFieldUpdateOperationsInput | string | null
    comprovativoUrl?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    membership?: MembershipUpdateOneRequiredWithoutContribuicoesNestedInput
    user?: UserUpdateOneRequiredWithoutContribuicoesNestedInput
    monthlyCycle?: MonthlyCycleUpdateOneRequiredWithoutContribuicoesNestedInput
  }

  export type ContributionUncheckedUpdateWithoutCoverageDecisionInput = {
    id?: StringFieldUpdateOperationsInput | string
    membershipId?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    monthlyCycleId?: StringFieldUpdateOperationsInput | string
    valor?: FloatFieldUpdateOperationsInput | number
    dataPrevista?: DateTimeFieldUpdateOperationsInput | Date | string
    dataPagamento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
    metodoPagamento?: NullableStringFieldUpdateOperationsInput | string | null
    referenciaBancaria?: NullableStringFieldUpdateOperationsInput | string | null
    comprovativoUrl?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type UserUpsertWithoutCoverageDecisionsInput = {
    update: XOR<UserUpdateWithoutCoverageDecisionsInput, UserUncheckedUpdateWithoutCoverageDecisionsInput>
    create: XOR<UserCreateWithoutCoverageDecisionsInput, UserUncheckedCreateWithoutCoverageDecisionsInput>
    where?: UserWhereInput
  }

  export type UserUpdateToOneWithWhereWithoutCoverageDecisionsInput = {
    where?: UserWhereInput
    data: XOR<UserUpdateWithoutCoverageDecisionsInput, UserUncheckedUpdateWithoutCoverageDecisionsInput>
  }

  export type UserUpdateWithoutCoverageDecisionsInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referredBy?: UserUpdateOneWithoutReferidosNestedInput
    referidos?: UserUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUpdateManyWithoutUserNestedInput
    otps?: OtpUpdateManyWithoutUserNestedInput
    sessions?: SessionUpdateManyWithoutUserNestedInput
    notifications?: NotificationUpdateManyWithoutUserNestedInput
    invitesEnviados?: InviteUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUpdateManyWithoutUserNestedInput
    badges?: BadgeUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUpdateManyWithoutUserNestedInput
  }

  export type UserUncheckedUpdateWithoutCoverageDecisionsInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    referredById?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referidos?: UserUncheckedUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUncheckedUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUncheckedUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUncheckedUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUncheckedUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUncheckedUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUncheckedUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUncheckedUpdateManyWithoutUserNestedInput
    otps?: OtpUncheckedUpdateManyWithoutUserNestedInput
    sessions?: SessionUncheckedUpdateManyWithoutUserNestedInput
    notifications?: NotificationUncheckedUpdateManyWithoutUserNestedInput
    invitesEnviados?: InviteUncheckedUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUncheckedUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUncheckedUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUncheckedUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUncheckedUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUncheckedUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUncheckedUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUncheckedUpdateManyWithoutUserNestedInput
    badges?: BadgeUncheckedUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUncheckedUpdateManyWithoutUserNestedInput
  }

  export type UserCreateWithoutReintegrationsInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referredBy?: UserCreateNestedOneWithoutReferidosInput
    referidos?: UserCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupCreateNestedManyWithoutCriadorInput
    memberships?: MembershipCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionCreateNestedManyWithoutUserInput
    cashouts?: CashoutCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventCreateNestedManyWithoutUserInput
    otps?: OtpCreateNestedManyWithoutUserInput
    sessions?: SessionCreateNestedManyWithoutUserInput
    notifications?: NotificationCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptCreateNestedManyWithoutUserInput
    badges?: BadgeCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyCreateNestedManyWithoutUserInput
  }

  export type UserUncheckedCreateWithoutReintegrationsInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    referredById?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referidos?: UserUncheckedCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupUncheckedCreateNestedManyWithoutCriadorInput
    memberships?: MembershipUncheckedCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionUncheckedCreateNestedManyWithoutUserInput
    cashouts?: CashoutUncheckedCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanUncheckedCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventUncheckedCreateNestedManyWithoutUserInput
    otps?: OtpUncheckedCreateNestedManyWithoutUserInput
    sessions?: SessionUncheckedCreateNestedManyWithoutUserInput
    notifications?: NotificationUncheckedCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionUncheckedCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteUncheckedCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationUncheckedCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogUncheckedCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationUncheckedCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountUncheckedCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralUncheckedCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralUncheckedCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptUncheckedCreateNestedManyWithoutUserInput
    badges?: BadgeUncheckedCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyUncheckedCreateNestedManyWithoutUserInput
  }

  export type UserCreateOrConnectWithoutReintegrationsInput = {
    where: UserWhereUniqueInput
    create: XOR<UserCreateWithoutReintegrationsInput, UserUncheckedCreateWithoutReintegrationsInput>
  }

  export type UserUpsertWithoutReintegrationsInput = {
    update: XOR<UserUpdateWithoutReintegrationsInput, UserUncheckedUpdateWithoutReintegrationsInput>
    create: XOR<UserCreateWithoutReintegrationsInput, UserUncheckedCreateWithoutReintegrationsInput>
    where?: UserWhereInput
  }

  export type UserUpdateToOneWithWhereWithoutReintegrationsInput = {
    where?: UserWhereInput
    data: XOR<UserUpdateWithoutReintegrationsInput, UserUncheckedUpdateWithoutReintegrationsInput>
  }

  export type UserUpdateWithoutReintegrationsInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referredBy?: UserUpdateOneWithoutReferidosNestedInput
    referidos?: UserUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUpdateManyWithoutUserNestedInput
    otps?: OtpUpdateManyWithoutUserNestedInput
    sessions?: SessionUpdateManyWithoutUserNestedInput
    notifications?: NotificationUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUpdateManyWithoutUserNestedInput
    badges?: BadgeUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUpdateManyWithoutUserNestedInput
  }

  export type UserUncheckedUpdateWithoutReintegrationsInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    referredById?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referidos?: UserUncheckedUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUncheckedUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUncheckedUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUncheckedUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUncheckedUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUncheckedUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUncheckedUpdateManyWithoutUserNestedInput
    otps?: OtpUncheckedUpdateManyWithoutUserNestedInput
    sessions?: SessionUncheckedUpdateManyWithoutUserNestedInput
    notifications?: NotificationUncheckedUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUncheckedUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUncheckedUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUncheckedUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUncheckedUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUncheckedUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUncheckedUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUncheckedUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUncheckedUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUncheckedUpdateManyWithoutUserNestedInput
    badges?: BadgeUncheckedUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUncheckedUpdateManyWithoutUserNestedInput
  }

  export type UserCreateWithoutFeeConfigsCriadasInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referredBy?: UserCreateNestedOneWithoutReferidosInput
    referidos?: UserCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupCreateNestedManyWithoutCriadorInput
    memberships?: MembershipCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionCreateNestedManyWithoutUserInput
    cashouts?: CashoutCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationCreateNestedManyWithoutUserInput
    otps?: OtpCreateNestedManyWithoutUserInput
    sessions?: SessionCreateNestedManyWithoutUserInput
    notifications?: NotificationCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteCreateNestedManyWithoutConvidadoPorInput
    auditLogs?: AuditLogCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptCreateNestedManyWithoutUserInput
    badges?: BadgeCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyCreateNestedManyWithoutUserInput
  }

  export type UserUncheckedCreateWithoutFeeConfigsCriadasInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    referredById?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referidos?: UserUncheckedCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupUncheckedCreateNestedManyWithoutCriadorInput
    memberships?: MembershipUncheckedCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionUncheckedCreateNestedManyWithoutUserInput
    cashouts?: CashoutUncheckedCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanUncheckedCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventUncheckedCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationUncheckedCreateNestedManyWithoutUserInput
    otps?: OtpUncheckedCreateNestedManyWithoutUserInput
    sessions?: SessionUncheckedCreateNestedManyWithoutUserInput
    notifications?: NotificationUncheckedCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionUncheckedCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteUncheckedCreateNestedManyWithoutConvidadoPorInput
    auditLogs?: AuditLogUncheckedCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationUncheckedCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountUncheckedCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralUncheckedCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralUncheckedCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptUncheckedCreateNestedManyWithoutUserInput
    badges?: BadgeUncheckedCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyUncheckedCreateNestedManyWithoutUserInput
  }

  export type UserCreateOrConnectWithoutFeeConfigsCriadasInput = {
    where: UserWhereUniqueInput
    create: XOR<UserCreateWithoutFeeConfigsCriadasInput, UserUncheckedCreateWithoutFeeConfigsCriadasInput>
  }

  export type UserUpsertWithoutFeeConfigsCriadasInput = {
    update: XOR<UserUpdateWithoutFeeConfigsCriadasInput, UserUncheckedUpdateWithoutFeeConfigsCriadasInput>
    create: XOR<UserCreateWithoutFeeConfigsCriadasInput, UserUncheckedCreateWithoutFeeConfigsCriadasInput>
    where?: UserWhereInput
  }

  export type UserUpdateToOneWithWhereWithoutFeeConfigsCriadasInput = {
    where?: UserWhereInput
    data: XOR<UserUpdateWithoutFeeConfigsCriadasInput, UserUncheckedUpdateWithoutFeeConfigsCriadasInput>
  }

  export type UserUpdateWithoutFeeConfigsCriadasInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referredBy?: UserUpdateOneWithoutReferidosNestedInput
    referidos?: UserUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUpdateManyWithoutUserNestedInput
    otps?: OtpUpdateManyWithoutUserNestedInput
    sessions?: SessionUpdateManyWithoutUserNestedInput
    notifications?: NotificationUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUpdateManyWithoutConvidadoPorNestedInput
    auditLogs?: AuditLogUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUpdateManyWithoutUserNestedInput
    badges?: BadgeUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUpdateManyWithoutUserNestedInput
  }

  export type UserUncheckedUpdateWithoutFeeConfigsCriadasInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    referredById?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referidos?: UserUncheckedUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUncheckedUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUncheckedUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUncheckedUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUncheckedUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUncheckedUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUncheckedUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUncheckedUpdateManyWithoutUserNestedInput
    otps?: OtpUncheckedUpdateManyWithoutUserNestedInput
    sessions?: SessionUncheckedUpdateManyWithoutUserNestedInput
    notifications?: NotificationUncheckedUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUncheckedUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUncheckedUpdateManyWithoutConvidadoPorNestedInput
    auditLogs?: AuditLogUncheckedUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUncheckedUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUncheckedUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUncheckedUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUncheckedUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUncheckedUpdateManyWithoutUserNestedInput
    badges?: BadgeUncheckedUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUncheckedUpdateManyWithoutUserNestedInput
  }

  export type UserCreateWithoutScoreEventsInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referredBy?: UserCreateNestedOneWithoutReferidosInput
    referidos?: UserCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupCreateNestedManyWithoutCriadorInput
    memberships?: MembershipCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionCreateNestedManyWithoutUserInput
    cashouts?: CashoutCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationCreateNestedManyWithoutUserInput
    otps?: OtpCreateNestedManyWithoutUserInput
    sessions?: SessionCreateNestedManyWithoutUserInput
    notifications?: NotificationCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptCreateNestedManyWithoutUserInput
    badges?: BadgeCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyCreateNestedManyWithoutUserInput
  }

  export type UserUncheckedCreateWithoutScoreEventsInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    referredById?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referidos?: UserUncheckedCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupUncheckedCreateNestedManyWithoutCriadorInput
    memberships?: MembershipUncheckedCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionUncheckedCreateNestedManyWithoutUserInput
    cashouts?: CashoutUncheckedCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanUncheckedCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationUncheckedCreateNestedManyWithoutUserInput
    otps?: OtpUncheckedCreateNestedManyWithoutUserInput
    sessions?: SessionUncheckedCreateNestedManyWithoutUserInput
    notifications?: NotificationUncheckedCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionUncheckedCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteUncheckedCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationUncheckedCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogUncheckedCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationUncheckedCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountUncheckedCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralUncheckedCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralUncheckedCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptUncheckedCreateNestedManyWithoutUserInput
    badges?: BadgeUncheckedCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyUncheckedCreateNestedManyWithoutUserInput
  }

  export type UserCreateOrConnectWithoutScoreEventsInput = {
    where: UserWhereUniqueInput
    create: XOR<UserCreateWithoutScoreEventsInput, UserUncheckedCreateWithoutScoreEventsInput>
  }

  export type UserUpsertWithoutScoreEventsInput = {
    update: XOR<UserUpdateWithoutScoreEventsInput, UserUncheckedUpdateWithoutScoreEventsInput>
    create: XOR<UserCreateWithoutScoreEventsInput, UserUncheckedCreateWithoutScoreEventsInput>
    where?: UserWhereInput
  }

  export type UserUpdateToOneWithWhereWithoutScoreEventsInput = {
    where?: UserWhereInput
    data: XOR<UserUpdateWithoutScoreEventsInput, UserUncheckedUpdateWithoutScoreEventsInput>
  }

  export type UserUpdateWithoutScoreEventsInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referredBy?: UserUpdateOneWithoutReferidosNestedInput
    referidos?: UserUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUpdateManyWithoutUserNestedInput
    otps?: OtpUpdateManyWithoutUserNestedInput
    sessions?: SessionUpdateManyWithoutUserNestedInput
    notifications?: NotificationUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUpdateManyWithoutUserNestedInput
    badges?: BadgeUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUpdateManyWithoutUserNestedInput
  }

  export type UserUncheckedUpdateWithoutScoreEventsInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    referredById?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referidos?: UserUncheckedUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUncheckedUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUncheckedUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUncheckedUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUncheckedUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUncheckedUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUncheckedUpdateManyWithoutUserNestedInput
    otps?: OtpUncheckedUpdateManyWithoutUserNestedInput
    sessions?: SessionUncheckedUpdateManyWithoutUserNestedInput
    notifications?: NotificationUncheckedUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUncheckedUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUncheckedUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUncheckedUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUncheckedUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUncheckedUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUncheckedUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUncheckedUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUncheckedUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUncheckedUpdateManyWithoutUserNestedInput
    badges?: BadgeUncheckedUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUncheckedUpdateManyWithoutUserNestedInput
  }

  export type UserCreateWithoutNotificationsInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referredBy?: UserCreateNestedOneWithoutReferidosInput
    referidos?: UserCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupCreateNestedManyWithoutCriadorInput
    memberships?: MembershipCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionCreateNestedManyWithoutUserInput
    cashouts?: CashoutCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationCreateNestedManyWithoutUserInput
    otps?: OtpCreateNestedManyWithoutUserInput
    sessions?: SessionCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptCreateNestedManyWithoutUserInput
    badges?: BadgeCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyCreateNestedManyWithoutUserInput
  }

  export type UserUncheckedCreateWithoutNotificationsInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    referredById?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referidos?: UserUncheckedCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupUncheckedCreateNestedManyWithoutCriadorInput
    memberships?: MembershipUncheckedCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionUncheckedCreateNestedManyWithoutUserInput
    cashouts?: CashoutUncheckedCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanUncheckedCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventUncheckedCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationUncheckedCreateNestedManyWithoutUserInput
    otps?: OtpUncheckedCreateNestedManyWithoutUserInput
    sessions?: SessionUncheckedCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionUncheckedCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteUncheckedCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationUncheckedCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogUncheckedCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationUncheckedCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountUncheckedCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralUncheckedCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralUncheckedCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptUncheckedCreateNestedManyWithoutUserInput
    badges?: BadgeUncheckedCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyUncheckedCreateNestedManyWithoutUserInput
  }

  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
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referredBy?: UserUpdateOneWithoutReferidosNestedInput
    referidos?: UserUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUpdateManyWithoutUserNestedInput
    otps?: OtpUpdateManyWithoutUserNestedInput
    sessions?: SessionUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUpdateManyWithoutUserNestedInput
    badges?: BadgeUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUpdateManyWithoutUserNestedInput
  }

  export type UserUncheckedUpdateWithoutNotificationsInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    referredById?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referidos?: UserUncheckedUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUncheckedUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUncheckedUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUncheckedUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUncheckedUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUncheckedUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUncheckedUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUncheckedUpdateManyWithoutUserNestedInput
    otps?: OtpUncheckedUpdateManyWithoutUserNestedInput
    sessions?: SessionUncheckedUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUncheckedUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUncheckedUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUncheckedUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUncheckedUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUncheckedUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUncheckedUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUncheckedUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUncheckedUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUncheckedUpdateManyWithoutUserNestedInput
    badges?: BadgeUncheckedUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUncheckedUpdateManyWithoutUserNestedInput
  }

  export type UserCreateWithoutAuditLogsInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referredBy?: UserCreateNestedOneWithoutReferidosInput
    referidos?: UserCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupCreateNestedManyWithoutCriadorInput
    memberships?: MembershipCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionCreateNestedManyWithoutUserInput
    cashouts?: CashoutCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationCreateNestedManyWithoutUserInput
    otps?: OtpCreateNestedManyWithoutUserInput
    sessions?: SessionCreateNestedManyWithoutUserInput
    notifications?: NotificationCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationCreateNestedManyWithoutCriadoPorInput
    creditApplications?: CreditApplicationCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptCreateNestedManyWithoutUserInput
    badges?: BadgeCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyCreateNestedManyWithoutUserInput
  }

  export type UserUncheckedCreateWithoutAuditLogsInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    referredById?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referidos?: UserUncheckedCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupUncheckedCreateNestedManyWithoutCriadorInput
    memberships?: MembershipUncheckedCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionUncheckedCreateNestedManyWithoutUserInput
    cashouts?: CashoutUncheckedCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanUncheckedCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventUncheckedCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationUncheckedCreateNestedManyWithoutUserInput
    otps?: OtpUncheckedCreateNestedManyWithoutUserInput
    sessions?: SessionUncheckedCreateNestedManyWithoutUserInput
    notifications?: NotificationUncheckedCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionUncheckedCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteUncheckedCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationUncheckedCreateNestedManyWithoutCriadoPorInput
    creditApplications?: CreditApplicationUncheckedCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountUncheckedCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralUncheckedCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralUncheckedCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptUncheckedCreateNestedManyWithoutUserInput
    badges?: BadgeUncheckedCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyUncheckedCreateNestedManyWithoutUserInput
  }

  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
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referredBy?: UserUpdateOneWithoutReferidosNestedInput
    referidos?: UserUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUpdateManyWithoutUserNestedInput
    otps?: OtpUpdateManyWithoutUserNestedInput
    sessions?: SessionUpdateManyWithoutUserNestedInput
    notifications?: NotificationUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUpdateManyWithoutCriadoPorNestedInput
    creditApplications?: CreditApplicationUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUpdateManyWithoutUserNestedInput
    badges?: BadgeUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUpdateManyWithoutUserNestedInput
  }

  export type UserUncheckedUpdateWithoutAuditLogsInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    referredById?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referidos?: UserUncheckedUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUncheckedUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUncheckedUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUncheckedUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUncheckedUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUncheckedUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUncheckedUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUncheckedUpdateManyWithoutUserNestedInput
    otps?: OtpUncheckedUpdateManyWithoutUserNestedInput
    sessions?: SessionUncheckedUpdateManyWithoutUserNestedInput
    notifications?: NotificationUncheckedUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUncheckedUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUncheckedUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUncheckedUpdateManyWithoutCriadoPorNestedInput
    creditApplications?: CreditApplicationUncheckedUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUncheckedUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUncheckedUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUncheckedUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUncheckedUpdateManyWithoutUserNestedInput
    badges?: BadgeUncheckedUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUncheckedUpdateManyWithoutUserNestedInput
  }

  export type UserCreateWithoutCreditApplicationsInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referredBy?: UserCreateNestedOneWithoutReferidosInput
    referidos?: UserCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupCreateNestedManyWithoutCriadorInput
    memberships?: MembershipCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionCreateNestedManyWithoutUserInput
    cashouts?: CashoutCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationCreateNestedManyWithoutUserInput
    otps?: OtpCreateNestedManyWithoutUserInput
    sessions?: SessionCreateNestedManyWithoutUserInput
    notifications?: NotificationCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptCreateNestedManyWithoutUserInput
    badges?: BadgeCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyCreateNestedManyWithoutUserInput
  }

  export type UserUncheckedCreateWithoutCreditApplicationsInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    referredById?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referidos?: UserUncheckedCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupUncheckedCreateNestedManyWithoutCriadorInput
    memberships?: MembershipUncheckedCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionUncheckedCreateNestedManyWithoutUserInput
    cashouts?: CashoutUncheckedCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanUncheckedCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventUncheckedCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationUncheckedCreateNestedManyWithoutUserInput
    otps?: OtpUncheckedCreateNestedManyWithoutUserInput
    sessions?: SessionUncheckedCreateNestedManyWithoutUserInput
    notifications?: NotificationUncheckedCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionUncheckedCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteUncheckedCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationUncheckedCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogUncheckedCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountUncheckedCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralUncheckedCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralUncheckedCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptUncheckedCreateNestedManyWithoutUserInput
    badges?: BadgeUncheckedCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyUncheckedCreateNestedManyWithoutUserInput
  }

  export type UserCreateOrConnectWithoutCreditApplicationsInput = {
    where: UserWhereUniqueInput
    create: XOR<UserCreateWithoutCreditApplicationsInput, UserUncheckedCreateWithoutCreditApplicationsInput>
  }

  export type CreditInstallmentCreateWithoutApplicationInput = {
    id?: string
    numero: number
    valorCapital: number
    valorJuros: number
    valorTotal: number
    dataVencimento: Date | string
    dataPagamento?: Date | string | null
    status?: string
  }

  export type CreditInstallmentUncheckedCreateWithoutApplicationInput = {
    id?: string
    numero: number
    valorCapital: number
    valorJuros: number
    valorTotal: number
    dataVencimento: Date | string
    dataPagamento?: Date | string | null
    status?: string
  }

  export type CreditInstallmentCreateOrConnectWithoutApplicationInput = {
    where: CreditInstallmentWhereUniqueInput
    create: XOR<CreditInstallmentCreateWithoutApplicationInput, CreditInstallmentUncheckedCreateWithoutApplicationInput>
  }

  export type CreditInstallmentCreateManyApplicationInputEnvelope = {
    data: CreditInstallmentCreateManyApplicationInput | CreditInstallmentCreateManyApplicationInput[]
    skipDuplicates?: boolean
  }

  export type UserUpsertWithoutCreditApplicationsInput = {
    update: XOR<UserUpdateWithoutCreditApplicationsInput, UserUncheckedUpdateWithoutCreditApplicationsInput>
    create: XOR<UserCreateWithoutCreditApplicationsInput, UserUncheckedCreateWithoutCreditApplicationsInput>
    where?: UserWhereInput
  }

  export type UserUpdateToOneWithWhereWithoutCreditApplicationsInput = {
    where?: UserWhereInput
    data: XOR<UserUpdateWithoutCreditApplicationsInput, UserUncheckedUpdateWithoutCreditApplicationsInput>
  }

  export type UserUpdateWithoutCreditApplicationsInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referredBy?: UserUpdateOneWithoutReferidosNestedInput
    referidos?: UserUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUpdateManyWithoutUserNestedInput
    otps?: OtpUpdateManyWithoutUserNestedInput
    sessions?: SessionUpdateManyWithoutUserNestedInput
    notifications?: NotificationUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUpdateManyWithoutUserNestedInput
    badges?: BadgeUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUpdateManyWithoutUserNestedInput
  }

  export type UserUncheckedUpdateWithoutCreditApplicationsInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    referredById?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referidos?: UserUncheckedUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUncheckedUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUncheckedUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUncheckedUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUncheckedUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUncheckedUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUncheckedUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUncheckedUpdateManyWithoutUserNestedInput
    otps?: OtpUncheckedUpdateManyWithoutUserNestedInput
    sessions?: SessionUncheckedUpdateManyWithoutUserNestedInput
    notifications?: NotificationUncheckedUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUncheckedUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUncheckedUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUncheckedUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUncheckedUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUncheckedUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUncheckedUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUncheckedUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUncheckedUpdateManyWithoutUserNestedInput
    badges?: BadgeUncheckedUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUncheckedUpdateManyWithoutUserNestedInput
  }

  export type CreditInstallmentUpsertWithWhereUniqueWithoutApplicationInput = {
    where: CreditInstallmentWhereUniqueInput
    update: XOR<CreditInstallmentUpdateWithoutApplicationInput, CreditInstallmentUncheckedUpdateWithoutApplicationInput>
    create: XOR<CreditInstallmentCreateWithoutApplicationInput, CreditInstallmentUncheckedCreateWithoutApplicationInput>
  }

  export type CreditInstallmentUpdateWithWhereUniqueWithoutApplicationInput = {
    where: CreditInstallmentWhereUniqueInput
    data: XOR<CreditInstallmentUpdateWithoutApplicationInput, CreditInstallmentUncheckedUpdateWithoutApplicationInput>
  }

  export type CreditInstallmentUpdateManyWithWhereWithoutApplicationInput = {
    where: CreditInstallmentScalarWhereInput
    data: XOR<CreditInstallmentUpdateManyMutationInput, CreditInstallmentUncheckedUpdateManyWithoutApplicationInput>
  }

  export type CreditInstallmentScalarWhereInput = {
    AND?: CreditInstallmentScalarWhereInput | CreditInstallmentScalarWhereInput[]
    OR?: CreditInstallmentScalarWhereInput[]
    NOT?: CreditInstallmentScalarWhereInput | CreditInstallmentScalarWhereInput[]
    id?: StringFilter<"CreditInstallment"> | string
    applicationId?: StringFilter<"CreditInstallment"> | string
    numero?: IntFilter<"CreditInstallment"> | number
    valorCapital?: FloatFilter<"CreditInstallment"> | number
    valorJuros?: FloatFilter<"CreditInstallment"> | number
    valorTotal?: FloatFilter<"CreditInstallment"> | number
    dataVencimento?: DateTimeFilter<"CreditInstallment"> | Date | string
    dataPagamento?: DateTimeNullableFilter<"CreditInstallment"> | Date | string | null
    status?: StringFilter<"CreditInstallment"> | string
  }

  export type CreditApplicationCreateWithoutPrestacoesInput = {
    id?: string
    valorSolicitado: number
    prazoMeses: number
    taxaJuroAplicada: number
    prestacaoMensal: number
    finalidade?: string | null
    status?: string
    scoreNoMomento: number
    motivoDecisao?: string | null
    decisaoPorId?: string | null
    dataAprovacao?: Date | string | null
    dataDesembolso?: Date | string | null
    createdAt?: Date | string
    updatedAt?: Date | string
    user: UserCreateNestedOneWithoutCreditApplicationsInput
  }

  export type CreditApplicationUncheckedCreateWithoutPrestacoesInput = {
    id?: string
    userId: string
    valorSolicitado: number
    prazoMeses: number
    taxaJuroAplicada: number
    prestacaoMensal: number
    finalidade?: string | null
    status?: string
    scoreNoMomento: number
    motivoDecisao?: string | null
    decisaoPorId?: string | null
    dataAprovacao?: Date | string | null
    dataDesembolso?: Date | string | null
    createdAt?: Date | string
    updatedAt?: Date | string
  }

  export type CreditApplicationCreateOrConnectWithoutPrestacoesInput = {
    where: CreditApplicationWhereUniqueInput
    create: XOR<CreditApplicationCreateWithoutPrestacoesInput, CreditApplicationUncheckedCreateWithoutPrestacoesInput>
  }

  export type CreditApplicationUpsertWithoutPrestacoesInput = {
    update: XOR<CreditApplicationUpdateWithoutPrestacoesInput, CreditApplicationUncheckedUpdateWithoutPrestacoesInput>
    create: XOR<CreditApplicationCreateWithoutPrestacoesInput, CreditApplicationUncheckedCreateWithoutPrestacoesInput>
    where?: CreditApplicationWhereInput
  }

  export type CreditApplicationUpdateToOneWithWhereWithoutPrestacoesInput = {
    where?: CreditApplicationWhereInput
    data: XOR<CreditApplicationUpdateWithoutPrestacoesInput, CreditApplicationUncheckedUpdateWithoutPrestacoesInput>
  }

  export type CreditApplicationUpdateWithoutPrestacoesInput = {
    id?: StringFieldUpdateOperationsInput | string
    valorSolicitado?: FloatFieldUpdateOperationsInput | number
    prazoMeses?: IntFieldUpdateOperationsInput | number
    taxaJuroAplicada?: FloatFieldUpdateOperationsInput | number
    prestacaoMensal?: FloatFieldUpdateOperationsInput | number
    finalidade?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreNoMomento?: IntFieldUpdateOperationsInput | number
    motivoDecisao?: NullableStringFieldUpdateOperationsInput | string | null
    decisaoPorId?: NullableStringFieldUpdateOperationsInput | string | null
    dataAprovacao?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    dataDesembolso?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    user?: UserUpdateOneRequiredWithoutCreditApplicationsNestedInput
  }

  export type CreditApplicationUncheckedUpdateWithoutPrestacoesInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    valorSolicitado?: FloatFieldUpdateOperationsInput | number
    prazoMeses?: IntFieldUpdateOperationsInput | number
    taxaJuroAplicada?: FloatFieldUpdateOperationsInput | number
    prestacaoMensal?: FloatFieldUpdateOperationsInput | number
    finalidade?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreNoMomento?: IntFieldUpdateOperationsInput | number
    motivoDecisao?: NullableStringFieldUpdateOperationsInput | string | null
    decisaoPorId?: NullableStringFieldUpdateOperationsInput | string | null
    dataAprovacao?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    dataDesembolso?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type UserCreateWithoutSavingsAccountsInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referredBy?: UserCreateNestedOneWithoutReferidosInput
    referidos?: UserCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupCreateNestedManyWithoutCriadorInput
    memberships?: MembershipCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionCreateNestedManyWithoutUserInput
    cashouts?: CashoutCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationCreateNestedManyWithoutUserInput
    otps?: OtpCreateNestedManyWithoutUserInput
    sessions?: SessionCreateNestedManyWithoutUserInput
    notifications?: NotificationCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptCreateNestedManyWithoutUserInput
    badges?: BadgeCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyCreateNestedManyWithoutUserInput
  }

  export type UserUncheckedCreateWithoutSavingsAccountsInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    referredById?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referidos?: UserUncheckedCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupUncheckedCreateNestedManyWithoutCriadorInput
    memberships?: MembershipUncheckedCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionUncheckedCreateNestedManyWithoutUserInput
    cashouts?: CashoutUncheckedCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanUncheckedCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventUncheckedCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationUncheckedCreateNestedManyWithoutUserInput
    otps?: OtpUncheckedCreateNestedManyWithoutUserInput
    sessions?: SessionUncheckedCreateNestedManyWithoutUserInput
    notifications?: NotificationUncheckedCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionUncheckedCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteUncheckedCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationUncheckedCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogUncheckedCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationUncheckedCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralUncheckedCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralUncheckedCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptUncheckedCreateNestedManyWithoutUserInput
    badges?: BadgeUncheckedCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyUncheckedCreateNestedManyWithoutUserInput
  }

  export type UserCreateOrConnectWithoutSavingsAccountsInput = {
    where: UserWhereUniqueInput
    create: XOR<UserCreateWithoutSavingsAccountsInput, UserUncheckedCreateWithoutSavingsAccountsInput>
  }

  export type SavingsMovementCreateWithoutAccountInput = {
    id?: string
    tipo: string
    valor: number
    saldoApos: number
    descricao?: string | null
    createdAt?: Date | string
  }

  export type SavingsMovementUncheckedCreateWithoutAccountInput = {
    id?: string
    tipo: string
    valor: number
    saldoApos: number
    descricao?: string | null
    createdAt?: Date | string
  }

  export type SavingsMovementCreateOrConnectWithoutAccountInput = {
    where: SavingsMovementWhereUniqueInput
    create: XOR<SavingsMovementCreateWithoutAccountInput, SavingsMovementUncheckedCreateWithoutAccountInput>
  }

  export type SavingsMovementCreateManyAccountInputEnvelope = {
    data: SavingsMovementCreateManyAccountInput | SavingsMovementCreateManyAccountInput[]
    skipDuplicates?: boolean
  }

  export type UserUpsertWithoutSavingsAccountsInput = {
    update: XOR<UserUpdateWithoutSavingsAccountsInput, UserUncheckedUpdateWithoutSavingsAccountsInput>
    create: XOR<UserCreateWithoutSavingsAccountsInput, UserUncheckedCreateWithoutSavingsAccountsInput>
    where?: UserWhereInput
  }

  export type UserUpdateToOneWithWhereWithoutSavingsAccountsInput = {
    where?: UserWhereInput
    data: XOR<UserUpdateWithoutSavingsAccountsInput, UserUncheckedUpdateWithoutSavingsAccountsInput>
  }

  export type UserUpdateWithoutSavingsAccountsInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referredBy?: UserUpdateOneWithoutReferidosNestedInput
    referidos?: UserUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUpdateManyWithoutUserNestedInput
    otps?: OtpUpdateManyWithoutUserNestedInput
    sessions?: SessionUpdateManyWithoutUserNestedInput
    notifications?: NotificationUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUpdateManyWithoutUserNestedInput
    badges?: BadgeUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUpdateManyWithoutUserNestedInput
  }

  export type UserUncheckedUpdateWithoutSavingsAccountsInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    referredById?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referidos?: UserUncheckedUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUncheckedUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUncheckedUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUncheckedUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUncheckedUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUncheckedUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUncheckedUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUncheckedUpdateManyWithoutUserNestedInput
    otps?: OtpUncheckedUpdateManyWithoutUserNestedInput
    sessions?: SessionUncheckedUpdateManyWithoutUserNestedInput
    notifications?: NotificationUncheckedUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUncheckedUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUncheckedUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUncheckedUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUncheckedUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUncheckedUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUncheckedUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUncheckedUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUncheckedUpdateManyWithoutUserNestedInput
    badges?: BadgeUncheckedUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUncheckedUpdateManyWithoutUserNestedInput
  }

  export type SavingsMovementUpsertWithWhereUniqueWithoutAccountInput = {
    where: SavingsMovementWhereUniqueInput
    update: XOR<SavingsMovementUpdateWithoutAccountInput, SavingsMovementUncheckedUpdateWithoutAccountInput>
    create: XOR<SavingsMovementCreateWithoutAccountInput, SavingsMovementUncheckedCreateWithoutAccountInput>
  }

  export type SavingsMovementUpdateWithWhereUniqueWithoutAccountInput = {
    where: SavingsMovementWhereUniqueInput
    data: XOR<SavingsMovementUpdateWithoutAccountInput, SavingsMovementUncheckedUpdateWithoutAccountInput>
  }

  export type SavingsMovementUpdateManyWithWhereWithoutAccountInput = {
    where: SavingsMovementScalarWhereInput
    data: XOR<SavingsMovementUpdateManyMutationInput, SavingsMovementUncheckedUpdateManyWithoutAccountInput>
  }

  export type SavingsMovementScalarWhereInput = {
    AND?: SavingsMovementScalarWhereInput | SavingsMovementScalarWhereInput[]
    OR?: SavingsMovementScalarWhereInput[]
    NOT?: SavingsMovementScalarWhereInput | SavingsMovementScalarWhereInput[]
    id?: StringFilter<"SavingsMovement"> | string
    accountId?: StringFilter<"SavingsMovement"> | string
    tipo?: StringFilter<"SavingsMovement"> | string
    valor?: FloatFilter<"SavingsMovement"> | number
    saldoApos?: FloatFilter<"SavingsMovement"> | number
    descricao?: StringNullableFilter<"SavingsMovement"> | string | null
    createdAt?: DateTimeFilter<"SavingsMovement"> | Date | string
  }

  export type SavingsAccountCreateWithoutMovimentosInput = {
    id?: string
    nome: string
    objectivo?: string | null
    meta?: number | null
    saldo?: number
    taxaRemuneracaoAnual?: number
    imobilizacaoMeses?: number
    status?: string
    ultimaCapitalizacao?: Date | string
    createdAt?: Date | string
    updatedAt?: Date | string
    user: UserCreateNestedOneWithoutSavingsAccountsInput
  }

  export type SavingsAccountUncheckedCreateWithoutMovimentosInput = {
    id?: string
    userId: string
    nome: string
    objectivo?: string | null
    meta?: number | null
    saldo?: number
    taxaRemuneracaoAnual?: number
    imobilizacaoMeses?: number
    status?: string
    ultimaCapitalizacao?: Date | string
    createdAt?: Date | string
    updatedAt?: Date | string
  }

  export type SavingsAccountCreateOrConnectWithoutMovimentosInput = {
    where: SavingsAccountWhereUniqueInput
    create: XOR<SavingsAccountCreateWithoutMovimentosInput, SavingsAccountUncheckedCreateWithoutMovimentosInput>
  }

  export type SavingsAccountUpsertWithoutMovimentosInput = {
    update: XOR<SavingsAccountUpdateWithoutMovimentosInput, SavingsAccountUncheckedUpdateWithoutMovimentosInput>
    create: XOR<SavingsAccountCreateWithoutMovimentosInput, SavingsAccountUncheckedCreateWithoutMovimentosInput>
    where?: SavingsAccountWhereInput
  }

  export type SavingsAccountUpdateToOneWithWhereWithoutMovimentosInput = {
    where?: SavingsAccountWhereInput
    data: XOR<SavingsAccountUpdateWithoutMovimentosInput, SavingsAccountUncheckedUpdateWithoutMovimentosInput>
  }

  export type SavingsAccountUpdateWithoutMovimentosInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    objectivo?: NullableStringFieldUpdateOperationsInput | string | null
    meta?: NullableFloatFieldUpdateOperationsInput | number | null
    saldo?: FloatFieldUpdateOperationsInput | number
    taxaRemuneracaoAnual?: FloatFieldUpdateOperationsInput | number
    imobilizacaoMeses?: IntFieldUpdateOperationsInput | number
    status?: StringFieldUpdateOperationsInput | string
    ultimaCapitalizacao?: DateTimeFieldUpdateOperationsInput | Date | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    user?: UserUpdateOneRequiredWithoutSavingsAccountsNestedInput
  }

  export type SavingsAccountUncheckedUpdateWithoutMovimentosInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    objectivo?: NullableStringFieldUpdateOperationsInput | string | null
    meta?: NullableFloatFieldUpdateOperationsInput | number | null
    saldo?: FloatFieldUpdateOperationsInput | number
    taxaRemuneracaoAnual?: FloatFieldUpdateOperationsInput | number
    imobilizacaoMeses?: IntFieldUpdateOperationsInput | number
    status?: StringFieldUpdateOperationsInput | string
    ultimaCapitalizacao?: DateTimeFieldUpdateOperationsInput | Date | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type UserCreateWithoutReferralsCreatedInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referredBy?: UserCreateNestedOneWithoutReferidosInput
    referidos?: UserCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupCreateNestedManyWithoutCriadorInput
    memberships?: MembershipCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionCreateNestedManyWithoutUserInput
    cashouts?: CashoutCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationCreateNestedManyWithoutUserInput
    otps?: OtpCreateNestedManyWithoutUserInput
    sessions?: SessionCreateNestedManyWithoutUserInput
    notifications?: NotificationCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountCreateNestedManyWithoutUserInput
    referralAsReferred?: ReferralCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptCreateNestedManyWithoutUserInput
    badges?: BadgeCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyCreateNestedManyWithoutUserInput
  }

  export type UserUncheckedCreateWithoutReferralsCreatedInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    referredById?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referidos?: UserUncheckedCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupUncheckedCreateNestedManyWithoutCriadorInput
    memberships?: MembershipUncheckedCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionUncheckedCreateNestedManyWithoutUserInput
    cashouts?: CashoutUncheckedCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanUncheckedCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventUncheckedCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationUncheckedCreateNestedManyWithoutUserInput
    otps?: OtpUncheckedCreateNestedManyWithoutUserInput
    sessions?: SessionUncheckedCreateNestedManyWithoutUserInput
    notifications?: NotificationUncheckedCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionUncheckedCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteUncheckedCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationUncheckedCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogUncheckedCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationUncheckedCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountUncheckedCreateNestedManyWithoutUserInput
    referralAsReferred?: ReferralUncheckedCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptUncheckedCreateNestedManyWithoutUserInput
    badges?: BadgeUncheckedCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyUncheckedCreateNestedManyWithoutUserInput
  }

  export type UserCreateOrConnectWithoutReferralsCreatedInput = {
    where: UserWhereUniqueInput
    create: XOR<UserCreateWithoutReferralsCreatedInput, UserUncheckedCreateWithoutReferralsCreatedInput>
  }

  export type UserCreateWithoutReferralAsReferredInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referredBy?: UserCreateNestedOneWithoutReferidosInput
    referidos?: UserCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupCreateNestedManyWithoutCriadorInput
    memberships?: MembershipCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionCreateNestedManyWithoutUserInput
    cashouts?: CashoutCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationCreateNestedManyWithoutUserInput
    otps?: OtpCreateNestedManyWithoutUserInput
    sessions?: SessionCreateNestedManyWithoutUserInput
    notifications?: NotificationCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralCreateNestedManyWithoutReferrerInput
    quizAttempts?: QuizAttemptCreateNestedManyWithoutUserInput
    badges?: BadgeCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyCreateNestedManyWithoutUserInput
  }

  export type UserUncheckedCreateWithoutReferralAsReferredInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    referredById?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referidos?: UserUncheckedCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupUncheckedCreateNestedManyWithoutCriadorInput
    memberships?: MembershipUncheckedCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionUncheckedCreateNestedManyWithoutUserInput
    cashouts?: CashoutUncheckedCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanUncheckedCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventUncheckedCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationUncheckedCreateNestedManyWithoutUserInput
    otps?: OtpUncheckedCreateNestedManyWithoutUserInput
    sessions?: SessionUncheckedCreateNestedManyWithoutUserInput
    notifications?: NotificationUncheckedCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionUncheckedCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteUncheckedCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationUncheckedCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogUncheckedCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationUncheckedCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountUncheckedCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralUncheckedCreateNestedManyWithoutReferrerInput
    quizAttempts?: QuizAttemptUncheckedCreateNestedManyWithoutUserInput
    badges?: BadgeUncheckedCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyUncheckedCreateNestedManyWithoutUserInput
  }

  export type UserCreateOrConnectWithoutReferralAsReferredInput = {
    where: UserWhereUniqueInput
    create: XOR<UserCreateWithoutReferralAsReferredInput, UserUncheckedCreateWithoutReferralAsReferredInput>
  }

  export type UserUpsertWithoutReferralsCreatedInput = {
    update: XOR<UserUpdateWithoutReferralsCreatedInput, UserUncheckedUpdateWithoutReferralsCreatedInput>
    create: XOR<UserCreateWithoutReferralsCreatedInput, UserUncheckedCreateWithoutReferralsCreatedInput>
    where?: UserWhereInput
  }

  export type UserUpdateToOneWithWhereWithoutReferralsCreatedInput = {
    where?: UserWhereInput
    data: XOR<UserUpdateWithoutReferralsCreatedInput, UserUncheckedUpdateWithoutReferralsCreatedInput>
  }

  export type UserUpdateWithoutReferralsCreatedInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referredBy?: UserUpdateOneWithoutReferidosNestedInput
    referidos?: UserUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUpdateManyWithoutUserNestedInput
    otps?: OtpUpdateManyWithoutUserNestedInput
    sessions?: SessionUpdateManyWithoutUserNestedInput
    notifications?: NotificationUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUpdateManyWithoutUserNestedInput
    referralAsReferred?: ReferralUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUpdateManyWithoutUserNestedInput
    badges?: BadgeUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUpdateManyWithoutUserNestedInput
  }

  export type UserUncheckedUpdateWithoutReferralsCreatedInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    referredById?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referidos?: UserUncheckedUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUncheckedUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUncheckedUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUncheckedUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUncheckedUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUncheckedUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUncheckedUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUncheckedUpdateManyWithoutUserNestedInput
    otps?: OtpUncheckedUpdateManyWithoutUserNestedInput
    sessions?: SessionUncheckedUpdateManyWithoutUserNestedInput
    notifications?: NotificationUncheckedUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUncheckedUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUncheckedUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUncheckedUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUncheckedUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUncheckedUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUncheckedUpdateManyWithoutUserNestedInput
    referralAsReferred?: ReferralUncheckedUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUncheckedUpdateManyWithoutUserNestedInput
    badges?: BadgeUncheckedUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUncheckedUpdateManyWithoutUserNestedInput
  }

  export type UserUpsertWithoutReferralAsReferredInput = {
    update: XOR<UserUpdateWithoutReferralAsReferredInput, UserUncheckedUpdateWithoutReferralAsReferredInput>
    create: XOR<UserCreateWithoutReferralAsReferredInput, UserUncheckedCreateWithoutReferralAsReferredInput>
    where?: UserWhereInput
  }

  export type UserUpdateToOneWithWhereWithoutReferralAsReferredInput = {
    where?: UserWhereInput
    data: XOR<UserUpdateWithoutReferralAsReferredInput, UserUncheckedUpdateWithoutReferralAsReferredInput>
  }

  export type UserUpdateWithoutReferralAsReferredInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referredBy?: UserUpdateOneWithoutReferidosNestedInput
    referidos?: UserUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUpdateManyWithoutUserNestedInput
    otps?: OtpUpdateManyWithoutUserNestedInput
    sessions?: SessionUpdateManyWithoutUserNestedInput
    notifications?: NotificationUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUpdateManyWithoutReferrerNestedInput
    quizAttempts?: QuizAttemptUpdateManyWithoutUserNestedInput
    badges?: BadgeUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUpdateManyWithoutUserNestedInput
  }

  export type UserUncheckedUpdateWithoutReferralAsReferredInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    referredById?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referidos?: UserUncheckedUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUncheckedUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUncheckedUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUncheckedUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUncheckedUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUncheckedUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUncheckedUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUncheckedUpdateManyWithoutUserNestedInput
    otps?: OtpUncheckedUpdateManyWithoutUserNestedInput
    sessions?: SessionUncheckedUpdateManyWithoutUserNestedInput
    notifications?: NotificationUncheckedUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUncheckedUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUncheckedUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUncheckedUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUncheckedUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUncheckedUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUncheckedUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUncheckedUpdateManyWithoutReferrerNestedInput
    quizAttempts?: QuizAttemptUncheckedUpdateManyWithoutUserNestedInput
    badges?: BadgeUncheckedUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUncheckedUpdateManyWithoutUserNestedInput
  }

  export type QuizAttemptCreateWithoutQuizInput = {
    id?: string
    acertos: number
    total: number
    pontosGanhos: number
    respostasJson?: string | null
    createdAt?: Date | string
    user: UserCreateNestedOneWithoutQuizAttemptsInput
  }

  export type QuizAttemptUncheckedCreateWithoutQuizInput = {
    id?: string
    userId: string
    acertos: number
    total: number
    pontosGanhos: number
    respostasJson?: string | null
    createdAt?: Date | string
  }

  export type QuizAttemptCreateOrConnectWithoutQuizInput = {
    where: QuizAttemptWhereUniqueInput
    create: XOR<QuizAttemptCreateWithoutQuizInput, QuizAttemptUncheckedCreateWithoutQuizInput>
  }

  export type QuizAttemptCreateManyQuizInputEnvelope = {
    data: QuizAttemptCreateManyQuizInput | QuizAttemptCreateManyQuizInput[]
    skipDuplicates?: boolean
  }

  export type QuizAttemptUpsertWithWhereUniqueWithoutQuizInput = {
    where: QuizAttemptWhereUniqueInput
    update: XOR<QuizAttemptUpdateWithoutQuizInput, QuizAttemptUncheckedUpdateWithoutQuizInput>
    create: XOR<QuizAttemptCreateWithoutQuizInput, QuizAttemptUncheckedCreateWithoutQuizInput>
  }

  export type QuizAttemptUpdateWithWhereUniqueWithoutQuizInput = {
    where: QuizAttemptWhereUniqueInput
    data: XOR<QuizAttemptUpdateWithoutQuizInput, QuizAttemptUncheckedUpdateWithoutQuizInput>
  }

  export type QuizAttemptUpdateManyWithWhereWithoutQuizInput = {
    where: QuizAttemptScalarWhereInput
    data: XOR<QuizAttemptUpdateManyMutationInput, QuizAttemptUncheckedUpdateManyWithoutQuizInput>
  }

  export type UserCreateWithoutQuizAttemptsInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referredBy?: UserCreateNestedOneWithoutReferidosInput
    referidos?: UserCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupCreateNestedManyWithoutCriadorInput
    memberships?: MembershipCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionCreateNestedManyWithoutUserInput
    cashouts?: CashoutCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationCreateNestedManyWithoutUserInput
    otps?: OtpCreateNestedManyWithoutUserInput
    sessions?: SessionCreateNestedManyWithoutUserInput
    notifications?: NotificationCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralCreateNestedManyWithoutReferredUserInput
    badges?: BadgeCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyCreateNestedManyWithoutUserInput
  }

  export type UserUncheckedCreateWithoutQuizAttemptsInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    referredById?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referidos?: UserUncheckedCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupUncheckedCreateNestedManyWithoutCriadorInput
    memberships?: MembershipUncheckedCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionUncheckedCreateNestedManyWithoutUserInput
    cashouts?: CashoutUncheckedCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanUncheckedCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventUncheckedCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationUncheckedCreateNestedManyWithoutUserInput
    otps?: OtpUncheckedCreateNestedManyWithoutUserInput
    sessions?: SessionUncheckedCreateNestedManyWithoutUserInput
    notifications?: NotificationUncheckedCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionUncheckedCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteUncheckedCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationUncheckedCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogUncheckedCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationUncheckedCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountUncheckedCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralUncheckedCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralUncheckedCreateNestedManyWithoutReferredUserInput
    badges?: BadgeUncheckedCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyUncheckedCreateNestedManyWithoutUserInput
  }

  export type UserCreateOrConnectWithoutQuizAttemptsInput = {
    where: UserWhereUniqueInput
    create: XOR<UserCreateWithoutQuizAttemptsInput, UserUncheckedCreateWithoutQuizAttemptsInput>
  }

  export type QuizCreateWithoutAttemptsInput = {
    id?: string
    titulo: string
    descricao?: string | null
    perguntasJson: string
    pontos?: number
    publicado?: boolean
    createdAt?: Date | string
  }

  export type QuizUncheckedCreateWithoutAttemptsInput = {
    id?: string
    titulo: string
    descricao?: string | null
    perguntasJson: string
    pontos?: number
    publicado?: boolean
    createdAt?: Date | string
  }

  export type QuizCreateOrConnectWithoutAttemptsInput = {
    where: QuizWhereUniqueInput
    create: XOR<QuizCreateWithoutAttemptsInput, QuizUncheckedCreateWithoutAttemptsInput>
  }

  export type UserUpsertWithoutQuizAttemptsInput = {
    update: XOR<UserUpdateWithoutQuizAttemptsInput, UserUncheckedUpdateWithoutQuizAttemptsInput>
    create: XOR<UserCreateWithoutQuizAttemptsInput, UserUncheckedCreateWithoutQuizAttemptsInput>
    where?: UserWhereInput
  }

  export type UserUpdateToOneWithWhereWithoutQuizAttemptsInput = {
    where?: UserWhereInput
    data: XOR<UserUpdateWithoutQuizAttemptsInput, UserUncheckedUpdateWithoutQuizAttemptsInput>
  }

  export type UserUpdateWithoutQuizAttemptsInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referredBy?: UserUpdateOneWithoutReferidosNestedInput
    referidos?: UserUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUpdateManyWithoutUserNestedInput
    otps?: OtpUpdateManyWithoutUserNestedInput
    sessions?: SessionUpdateManyWithoutUserNestedInput
    notifications?: NotificationUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUpdateManyWithoutReferredUserNestedInput
    badges?: BadgeUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUpdateManyWithoutUserNestedInput
  }

  export type UserUncheckedUpdateWithoutQuizAttemptsInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    referredById?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referidos?: UserUncheckedUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUncheckedUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUncheckedUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUncheckedUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUncheckedUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUncheckedUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUncheckedUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUncheckedUpdateManyWithoutUserNestedInput
    otps?: OtpUncheckedUpdateManyWithoutUserNestedInput
    sessions?: SessionUncheckedUpdateManyWithoutUserNestedInput
    notifications?: NotificationUncheckedUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUncheckedUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUncheckedUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUncheckedUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUncheckedUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUncheckedUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUncheckedUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUncheckedUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUncheckedUpdateManyWithoutReferredUserNestedInput
    badges?: BadgeUncheckedUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUncheckedUpdateManyWithoutUserNestedInput
  }

  export type QuizUpsertWithoutAttemptsInput = {
    update: XOR<QuizUpdateWithoutAttemptsInput, QuizUncheckedUpdateWithoutAttemptsInput>
    create: XOR<QuizCreateWithoutAttemptsInput, QuizUncheckedCreateWithoutAttemptsInput>
    where?: QuizWhereInput
  }

  export type QuizUpdateToOneWithWhereWithoutAttemptsInput = {
    where?: QuizWhereInput
    data: XOR<QuizUpdateWithoutAttemptsInput, QuizUncheckedUpdateWithoutAttemptsInput>
  }

  export type QuizUpdateWithoutAttemptsInput = {
    id?: StringFieldUpdateOperationsInput | string
    titulo?: StringFieldUpdateOperationsInput | string
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    perguntasJson?: StringFieldUpdateOperationsInput | string
    pontos?: IntFieldUpdateOperationsInput | number
    publicado?: BoolFieldUpdateOperationsInput | boolean
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type QuizUncheckedUpdateWithoutAttemptsInput = {
    id?: StringFieldUpdateOperationsInput | string
    titulo?: StringFieldUpdateOperationsInput | string
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    perguntasJson?: StringFieldUpdateOperationsInput | string
    pontos?: IntFieldUpdateOperationsInput | number
    publicado?: BoolFieldUpdateOperationsInput | boolean
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type UserCreateWithoutBadgesInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referredBy?: UserCreateNestedOneWithoutReferidosInput
    referidos?: UserCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupCreateNestedManyWithoutCriadorInput
    memberships?: MembershipCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionCreateNestedManyWithoutUserInput
    cashouts?: CashoutCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationCreateNestedManyWithoutUserInput
    otps?: OtpCreateNestedManyWithoutUserInput
    sessions?: SessionCreateNestedManyWithoutUserInput
    notifications?: NotificationCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyCreateNestedManyWithoutUserInput
  }

  export type UserUncheckedCreateWithoutBadgesInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    referredById?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referidos?: UserUncheckedCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupUncheckedCreateNestedManyWithoutCriadorInput
    memberships?: MembershipUncheckedCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionUncheckedCreateNestedManyWithoutUserInput
    cashouts?: CashoutUncheckedCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanUncheckedCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventUncheckedCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationUncheckedCreateNestedManyWithoutUserInput
    otps?: OtpUncheckedCreateNestedManyWithoutUserInput
    sessions?: SessionUncheckedCreateNestedManyWithoutUserInput
    notifications?: NotificationUncheckedCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionUncheckedCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteUncheckedCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationUncheckedCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogUncheckedCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationUncheckedCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountUncheckedCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralUncheckedCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralUncheckedCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptUncheckedCreateNestedManyWithoutUserInput
    insurancePolicies?: InsurancePolicyUncheckedCreateNestedManyWithoutUserInput
  }

  export type UserCreateOrConnectWithoutBadgesInput = {
    where: UserWhereUniqueInput
    create: XOR<UserCreateWithoutBadgesInput, UserUncheckedCreateWithoutBadgesInput>
  }

  export type UserUpsertWithoutBadgesInput = {
    update: XOR<UserUpdateWithoutBadgesInput, UserUncheckedUpdateWithoutBadgesInput>
    create: XOR<UserCreateWithoutBadgesInput, UserUncheckedCreateWithoutBadgesInput>
    where?: UserWhereInput
  }

  export type UserUpdateToOneWithWhereWithoutBadgesInput = {
    where?: UserWhereInput
    data: XOR<UserUpdateWithoutBadgesInput, UserUncheckedUpdateWithoutBadgesInput>
  }

  export type UserUpdateWithoutBadgesInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referredBy?: UserUpdateOneWithoutReferidosNestedInput
    referidos?: UserUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUpdateManyWithoutUserNestedInput
    otps?: OtpUpdateManyWithoutUserNestedInput
    sessions?: SessionUpdateManyWithoutUserNestedInput
    notifications?: NotificationUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUpdateManyWithoutUserNestedInput
  }

  export type UserUncheckedUpdateWithoutBadgesInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    referredById?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referidos?: UserUncheckedUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUncheckedUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUncheckedUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUncheckedUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUncheckedUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUncheckedUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUncheckedUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUncheckedUpdateManyWithoutUserNestedInput
    otps?: OtpUncheckedUpdateManyWithoutUserNestedInput
    sessions?: SessionUncheckedUpdateManyWithoutUserNestedInput
    notifications?: NotificationUncheckedUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUncheckedUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUncheckedUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUncheckedUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUncheckedUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUncheckedUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUncheckedUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUncheckedUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUncheckedUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUncheckedUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUncheckedUpdateManyWithoutUserNestedInput
  }

  export type ApiCallCreateWithoutApiKeyInput = {
    id?: string
    endpoint: string
    metodo?: string
    status: number
    duracaoMs: number
    ip?: string | null
    timestamp?: Date | string
  }

  export type ApiCallUncheckedCreateWithoutApiKeyInput = {
    id?: string
    endpoint: string
    metodo?: string
    status: number
    duracaoMs: number
    ip?: string | null
    timestamp?: Date | string
  }

  export type ApiCallCreateOrConnectWithoutApiKeyInput = {
    where: ApiCallWhereUniqueInput
    create: XOR<ApiCallCreateWithoutApiKeyInput, ApiCallUncheckedCreateWithoutApiKeyInput>
  }

  export type ApiCallCreateManyApiKeyInputEnvelope = {
    data: ApiCallCreateManyApiKeyInput | ApiCallCreateManyApiKeyInput[]
    skipDuplicates?: boolean
  }

  export type ApiCallUpsertWithWhereUniqueWithoutApiKeyInput = {
    where: ApiCallWhereUniqueInput
    update: XOR<ApiCallUpdateWithoutApiKeyInput, ApiCallUncheckedUpdateWithoutApiKeyInput>
    create: XOR<ApiCallCreateWithoutApiKeyInput, ApiCallUncheckedCreateWithoutApiKeyInput>
  }

  export type ApiCallUpdateWithWhereUniqueWithoutApiKeyInput = {
    where: ApiCallWhereUniqueInput
    data: XOR<ApiCallUpdateWithoutApiKeyInput, ApiCallUncheckedUpdateWithoutApiKeyInput>
  }

  export type ApiCallUpdateManyWithWhereWithoutApiKeyInput = {
    where: ApiCallScalarWhereInput
    data: XOR<ApiCallUpdateManyMutationInput, ApiCallUncheckedUpdateManyWithoutApiKeyInput>
  }

  export type ApiCallScalarWhereInput = {
    AND?: ApiCallScalarWhereInput | ApiCallScalarWhereInput[]
    OR?: ApiCallScalarWhereInput[]
    NOT?: ApiCallScalarWhereInput | ApiCallScalarWhereInput[]
    id?: StringFilter<"ApiCall"> | string
    apiKeyId?: StringFilter<"ApiCall"> | string
    endpoint?: StringFilter<"ApiCall"> | string
    metodo?: StringFilter<"ApiCall"> | string
    status?: IntFilter<"ApiCall"> | number
    duracaoMs?: IntFilter<"ApiCall"> | number
    ip?: StringNullableFilter<"ApiCall"> | string | null
    timestamp?: DateTimeFilter<"ApiCall"> | Date | string
  }

  export type ApiKeyCreateWithoutChamadasInput = {
    id?: string
    nome: string
    partnerNome: string
    chave: string
    scopes: string
    status?: string
    rateLimit?: number
    createdAt?: Date | string
    ultimoUso?: Date | string | null
    usos?: number
  }

  export type ApiKeyUncheckedCreateWithoutChamadasInput = {
    id?: string
    nome: string
    partnerNome: string
    chave: string
    scopes: string
    status?: string
    rateLimit?: number
    createdAt?: Date | string
    ultimoUso?: Date | string | null
    usos?: number
  }

  export type ApiKeyCreateOrConnectWithoutChamadasInput = {
    where: ApiKeyWhereUniqueInput
    create: XOR<ApiKeyCreateWithoutChamadasInput, ApiKeyUncheckedCreateWithoutChamadasInput>
  }

  export type ApiKeyUpsertWithoutChamadasInput = {
    update: XOR<ApiKeyUpdateWithoutChamadasInput, ApiKeyUncheckedUpdateWithoutChamadasInput>
    create: XOR<ApiKeyCreateWithoutChamadasInput, ApiKeyUncheckedCreateWithoutChamadasInput>
    where?: ApiKeyWhereInput
  }

  export type ApiKeyUpdateToOneWithWhereWithoutChamadasInput = {
    where?: ApiKeyWhereInput
    data: XOR<ApiKeyUpdateWithoutChamadasInput, ApiKeyUncheckedUpdateWithoutChamadasInput>
  }

  export type ApiKeyUpdateWithoutChamadasInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    partnerNome?: StringFieldUpdateOperationsInput | string
    chave?: StringFieldUpdateOperationsInput | string
    scopes?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    rateLimit?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    ultimoUso?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    usos?: IntFieldUpdateOperationsInput | number
  }

  export type ApiKeyUncheckedUpdateWithoutChamadasInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    partnerNome?: StringFieldUpdateOperationsInput | string
    chave?: StringFieldUpdateOperationsInput | string
    scopes?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    rateLimit?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    ultimoUso?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    usos?: IntFieldUpdateOperationsInput | number
  }

  export type InsurancePolicyCreateWithoutProductInput = {
    id?: string
    status?: string
    dataInicio?: Date | string
    premiumPago?: number
    proximaCobranca?: Date | string | null
    user: UserCreateNestedOneWithoutInsurancePoliciesInput
  }

  export type InsurancePolicyUncheckedCreateWithoutProductInput = {
    id?: string
    userId: string
    status?: string
    dataInicio?: Date | string
    premiumPago?: number
    proximaCobranca?: Date | string | null
  }

  export type InsurancePolicyCreateOrConnectWithoutProductInput = {
    where: InsurancePolicyWhereUniqueInput
    create: XOR<InsurancePolicyCreateWithoutProductInput, InsurancePolicyUncheckedCreateWithoutProductInput>
  }

  export type InsurancePolicyCreateManyProductInputEnvelope = {
    data: InsurancePolicyCreateManyProductInput | InsurancePolicyCreateManyProductInput[]
    skipDuplicates?: boolean
  }

  export type InsurancePolicyUpsertWithWhereUniqueWithoutProductInput = {
    where: InsurancePolicyWhereUniqueInput
    update: XOR<InsurancePolicyUpdateWithoutProductInput, InsurancePolicyUncheckedUpdateWithoutProductInput>
    create: XOR<InsurancePolicyCreateWithoutProductInput, InsurancePolicyUncheckedCreateWithoutProductInput>
  }

  export type InsurancePolicyUpdateWithWhereUniqueWithoutProductInput = {
    where: InsurancePolicyWhereUniqueInput
    data: XOR<InsurancePolicyUpdateWithoutProductInput, InsurancePolicyUncheckedUpdateWithoutProductInput>
  }

  export type InsurancePolicyUpdateManyWithWhereWithoutProductInput = {
    where: InsurancePolicyScalarWhereInput
    data: XOR<InsurancePolicyUpdateManyMutationInput, InsurancePolicyUncheckedUpdateManyWithoutProductInput>
  }

  export type UserCreateWithoutInsurancePoliciesInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referredBy?: UserCreateNestedOneWithoutReferidosInput
    referidos?: UserCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupCreateNestedManyWithoutCriadorInput
    memberships?: MembershipCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionCreateNestedManyWithoutUserInput
    cashouts?: CashoutCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationCreateNestedManyWithoutUserInput
    otps?: OtpCreateNestedManyWithoutUserInput
    sessions?: SessionCreateNestedManyWithoutUserInput
    notifications?: NotificationCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptCreateNestedManyWithoutUserInput
    badges?: BadgeCreateNestedManyWithoutUserInput
  }

  export type UserUncheckedCreateWithoutInsurancePoliciesInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    referredById?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
    referidos?: UserUncheckedCreateNestedManyWithoutReferredByInput
    gruposCriados?: GroupUncheckedCreateNestedManyWithoutCriadorInput
    memberships?: MembershipUncheckedCreateNestedManyWithoutUserInput
    contribuicoes?: ContributionUncheckedCreateNestedManyWithoutUserInput
    cashouts?: CashoutUncheckedCreateNestedManyWithoutBeneficiarioUserInput
    loans?: LoanUncheckedCreateNestedManyWithoutUserInput
    scoreEvents?: ScoreEventUncheckedCreateNestedManyWithoutUserInput
    reintegrations?: ReintegrationUncheckedCreateNestedManyWithoutUserInput
    otps?: OtpUncheckedCreateNestedManyWithoutUserInput
    sessions?: SessionUncheckedCreateNestedManyWithoutUserInput
    notifications?: NotificationUncheckedCreateNestedManyWithoutUserInput
    coverageDecisions?: CoverageDecisionUncheckedCreateNestedManyWithoutDecisorUserInput
    invitesEnviados?: InviteUncheckedCreateNestedManyWithoutConvidadoPorInput
    feeConfigsCriadas?: FeeConfigurationUncheckedCreateNestedManyWithoutCriadoPorInput
    auditLogs?: AuditLogUncheckedCreateNestedManyWithoutUserInput
    creditApplications?: CreditApplicationUncheckedCreateNestedManyWithoutUserInput
    savingsAccounts?: SavingsAccountUncheckedCreateNestedManyWithoutUserInput
    referralsCreated?: ReferralUncheckedCreateNestedManyWithoutReferrerInput
    referralAsReferred?: ReferralUncheckedCreateNestedManyWithoutReferredUserInput
    quizAttempts?: QuizAttemptUncheckedCreateNestedManyWithoutUserInput
    badges?: BadgeUncheckedCreateNestedManyWithoutUserInput
  }

  export type UserCreateOrConnectWithoutInsurancePoliciesInput = {
    where: UserWhereUniqueInput
    create: XOR<UserCreateWithoutInsurancePoliciesInput, UserUncheckedCreateWithoutInsurancePoliciesInput>
  }

  export type InsuranceProductCreateWithoutPoliciesInput = {
    id?: string
    nome: string
    tipo: string
    premiumMensal: number
    coberturaMax: number
    descricao?: string | null
    activo?: boolean
  }

  export type InsuranceProductUncheckedCreateWithoutPoliciesInput = {
    id?: string
    nome: string
    tipo: string
    premiumMensal: number
    coberturaMax: number
    descricao?: string | null
    activo?: boolean
  }

  export type InsuranceProductCreateOrConnectWithoutPoliciesInput = {
    where: InsuranceProductWhereUniqueInput
    create: XOR<InsuranceProductCreateWithoutPoliciesInput, InsuranceProductUncheckedCreateWithoutPoliciesInput>
  }

  export type UserUpsertWithoutInsurancePoliciesInput = {
    update: XOR<UserUpdateWithoutInsurancePoliciesInput, UserUncheckedUpdateWithoutInsurancePoliciesInput>
    create: XOR<UserCreateWithoutInsurancePoliciesInput, UserUncheckedCreateWithoutInsurancePoliciesInput>
    where?: UserWhereInput
  }

  export type UserUpdateToOneWithWhereWithoutInsurancePoliciesInput = {
    where?: UserWhereInput
    data: XOR<UserUpdateWithoutInsurancePoliciesInput, UserUncheckedUpdateWithoutInsurancePoliciesInput>
  }

  export type UserUpdateWithoutInsurancePoliciesInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referredBy?: UserUpdateOneWithoutReferidosNestedInput
    referidos?: UserUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUpdateManyWithoutUserNestedInput
    otps?: OtpUpdateManyWithoutUserNestedInput
    sessions?: SessionUpdateManyWithoutUserNestedInput
    notifications?: NotificationUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUpdateManyWithoutUserNestedInput
    badges?: BadgeUpdateManyWithoutUserNestedInput
  }

  export type UserUncheckedUpdateWithoutInsurancePoliciesInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    referredById?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referidos?: UserUncheckedUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUncheckedUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUncheckedUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUncheckedUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUncheckedUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUncheckedUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUncheckedUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUncheckedUpdateManyWithoutUserNestedInput
    otps?: OtpUncheckedUpdateManyWithoutUserNestedInput
    sessions?: SessionUncheckedUpdateManyWithoutUserNestedInput
    notifications?: NotificationUncheckedUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUncheckedUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUncheckedUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUncheckedUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUncheckedUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUncheckedUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUncheckedUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUncheckedUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUncheckedUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUncheckedUpdateManyWithoutUserNestedInput
    badges?: BadgeUncheckedUpdateManyWithoutUserNestedInput
  }

  export type InsuranceProductUpsertWithoutPoliciesInput = {
    update: XOR<InsuranceProductUpdateWithoutPoliciesInput, InsuranceProductUncheckedUpdateWithoutPoliciesInput>
    create: XOR<InsuranceProductCreateWithoutPoliciesInput, InsuranceProductUncheckedCreateWithoutPoliciesInput>
    where?: InsuranceProductWhereInput
  }

  export type InsuranceProductUpdateToOneWithWhereWithoutPoliciesInput = {
    where?: InsuranceProductWhereInput
    data: XOR<InsuranceProductUpdateWithoutPoliciesInput, InsuranceProductUncheckedUpdateWithoutPoliciesInput>
  }

  export type InsuranceProductUpdateWithoutPoliciesInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    premiumMensal?: FloatFieldUpdateOperationsInput | number
    coberturaMax?: FloatFieldUpdateOperationsInput | number
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    activo?: BoolFieldUpdateOperationsInput | boolean
  }

  export type InsuranceProductUncheckedUpdateWithoutPoliciesInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    premiumMensal?: FloatFieldUpdateOperationsInput | number
    coberturaMax?: FloatFieldUpdateOperationsInput | number
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    activo?: BoolFieldUpdateOperationsInput | boolean
  }

  export type UserCreateManyReferredByInput = {
    id?: string
    nome: string
    telefone: string
    email: string
    passwordHash: string
    bi?: string | null
    dataNascimento?: Date | string | null
    provincia?: string | null
    pais?: string
    moedaPreferida?: string
    fotoPerfilUrl?: string | null
    kycStatus?: string
    kycNivel?: number
    kycDataJson?: string | null
    status?: string
    scoreAtual?: number
    role?: string
    referralCode?: string | null
    pontosEducacao?: number
    createdAt?: Date | string
    updatedAt?: Date | string
  }

  export type GroupCreateManyCriadorInput = {
    id?: string
    nome: string
    descricao?: string | null
    numMembros: number
    valorContribuicaoMensal: number
    taxaPrincipalAplicada: number
    reservaTecnicaAplicada: number
    periodicidade?: string
    tipo?: string
    pais?: string
    moeda?: string
    status?: string
    dataInicio?: Date | string | null
    dataFimPrevista?: Date | string | null
    cicloAtual?: number
    totalCiclos: number
    createdAt?: Date | string
    updatedAt?: Date | string
  }

  export type MembershipCreateManyUserInput = {
    id?: string
    groupId: string
    posicaoRotacao?: number | null
    status?: string
    necessidadeUrgente?: boolean
    dataJuncao?: Date | string
    mesRecepcaoPrevisto?: string | null
  }

  export type ContributionCreateManyUserInput = {
    id?: string
    membershipId: string
    monthlyCycleId: string
    valor: number
    dataPrevista: Date | string
    dataPagamento?: Date | string | null
    status?: string
    metodoPagamento?: string | null
    referenciaBancaria?: string | null
    comprovativoUrl?: string | null
    createdAt?: Date | string
    updatedAt?: Date | string
  }

  export type CashoutCreateManyBeneficiarioUserInput = {
    id?: string
    monthlyCycleId: string
    valorBruto: number
    valorTaxaPrincipal: number
    valorReservaTecnica: number
    valorLiquido: number
    dataPrevista: Date | string
    dataExecucao?: Date | string | null
    status?: string
    contaDestino?: string | null
    refTransferencia?: string | null
    parcialMotivo?: string | null
    createdAt?: Date | string
    updatedAt?: Date | string
  }

  export type LoanCreateManyUserInput = {
    id?: string
    monthlyCycleId: string
    contributionId?: string | null
    valorCapital: number
    taxaEmprestimo: number
    valorTotalDevido: number
    jurosMoraAcumulados?: number
    dataInicio: Date | string
    dataPagamento?: Date | string | null
    status?: string
    createdAt?: Date | string
    updatedAt?: Date | string
  }

  export type ScoreEventCreateManyUserInput = {
    id?: string
    tipoEvento: string
    impacto: number
    descricao?: string | null
    scoreAntes: number
    scoreDepois: number
    timestamp?: Date | string
  }

  export type ReintegrationCreateManyUserInput = {
    id?: string
    valorDividaOriginal: number
    taxaReintegracaoAplicada: number
    valorTaxaPaga: number
    dataSolicitacao?: Date | string
    dataConclusao?: Date | string | null
    status?: string
  }

  export type OtpCreateManyUserInput = {
    id?: string
    telefone: string
    codigo: string
    proposito: string
    consumido?: boolean
    expiraEm: Date | string
    createdAt?: Date | string
  }

  export type SessionCreateManyUserInput = {
    id?: string
    token: string
    expiraEm: Date | string
    createdAt?: Date | string
  }

  export type NotificationCreateManyUserInput = {
    id?: string
    canal: string
    titulo: string
    corpo: string
    lida?: boolean
    metadataJson?: string | null
    createdAt?: Date | string
  }

  export type CoverageDecisionCreateManyDecisorUserInput = {
    id?: string
    contributionId: string
    decisao: string
    motivo: string
    scoreNoMomento: number
    historicoInadimplencias: number
    decisorSistema?: boolean
    createdAt?: Date | string
  }

  export type InviteCreateManyConvidadoPorInput = {
    id?: string
    groupId: string
    telefone: string
    email?: string | null
    token: string
    status?: string
    createdAt?: Date | string
    expiraEm: Date | string
  }

  export type FeeConfigurationCreateManyCriadoPorInput = {
    id?: string
    tipoFee: string
    valor: number
    min: number
    max: number
    dataInicio: Date | string
    dataFim?: Date | string | null
    motivoMudanca?: string | null
    ativa?: boolean
    createdAt?: Date | string
  }

  export type AuditLogCreateManyUserInput = {
    id?: string
    acao: string
    entidade: string
    entidadeId?: string | null
    dadosAntes?: string | null
    dadosDepois?: string | null
    ip?: string | null
    timestamp?: Date | string
  }

  export type CreditApplicationCreateManyUserInput = {
    id?: string
    valorSolicitado: number
    prazoMeses: number
    taxaJuroAplicada: number
    prestacaoMensal: number
    finalidade?: string | null
    status?: string
    scoreNoMomento: number
    motivoDecisao?: string | null
    decisaoPorId?: string | null
    dataAprovacao?: Date | string | null
    dataDesembolso?: Date | string | null
    createdAt?: Date | string
    updatedAt?: Date | string
  }

  export type SavingsAccountCreateManyUserInput = {
    id?: string
    nome: string
    objectivo?: string | null
    meta?: number | null
    saldo?: number
    taxaRemuneracaoAnual?: number
    imobilizacaoMeses?: number
    status?: string
    ultimaCapitalizacao?: Date | string
    createdAt?: Date | string
    updatedAt?: Date | string
  }

  export type ReferralCreateManyReferrerInput = {
    id?: string
    referredUserId?: string | null
    codigo: string
    canal?: string | null
    status?: string
    recompensa?: number
    recompensaPaga?: boolean
    dataRegisto?: Date | string | null
    dataActivacao?: Date | string | null
    createdAt?: Date | string
  }

  export type ReferralCreateManyReferredUserInput = {
    id?: string
    referrerUserId: string
    codigo: string
    canal?: string | null
    status?: string
    recompensa?: number
    recompensaPaga?: boolean
    dataRegisto?: Date | string | null
    dataActivacao?: Date | string | null
    createdAt?: Date | string
  }

  export type QuizAttemptCreateManyUserInput = {
    id?: string
    quizId: string
    acertos: number
    total: number
    pontosGanhos: number
    respostasJson?: string | null
    createdAt?: Date | string
  }

  export type BadgeCreateManyUserInput = {
    id?: string
    tipo: string
    titulo: string
    descricao?: string | null
    createdAt?: Date | string
  }

  export type InsurancePolicyCreateManyUserInput = {
    id?: string
    productId: string
    status?: string
    dataInicio?: Date | string
    premiumPago?: number
    proximaCobranca?: Date | string | null
  }

  export type UserUpdateWithoutReferredByInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referidos?: UserUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUpdateManyWithoutUserNestedInput
    otps?: OtpUpdateManyWithoutUserNestedInput
    sessions?: SessionUpdateManyWithoutUserNestedInput
    notifications?: NotificationUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUpdateManyWithoutUserNestedInput
    badges?: BadgeUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUpdateManyWithoutUserNestedInput
  }

  export type UserUncheckedUpdateWithoutReferredByInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referidos?: UserUncheckedUpdateManyWithoutReferredByNestedInput
    gruposCriados?: GroupUncheckedUpdateManyWithoutCriadorNestedInput
    memberships?: MembershipUncheckedUpdateManyWithoutUserNestedInput
    contribuicoes?: ContributionUncheckedUpdateManyWithoutUserNestedInput
    cashouts?: CashoutUncheckedUpdateManyWithoutBeneficiarioUserNestedInput
    loans?: LoanUncheckedUpdateManyWithoutUserNestedInput
    scoreEvents?: ScoreEventUncheckedUpdateManyWithoutUserNestedInput
    reintegrations?: ReintegrationUncheckedUpdateManyWithoutUserNestedInput
    otps?: OtpUncheckedUpdateManyWithoutUserNestedInput
    sessions?: SessionUncheckedUpdateManyWithoutUserNestedInput
    notifications?: NotificationUncheckedUpdateManyWithoutUserNestedInput
    coverageDecisions?: CoverageDecisionUncheckedUpdateManyWithoutDecisorUserNestedInput
    invitesEnviados?: InviteUncheckedUpdateManyWithoutConvidadoPorNestedInput
    feeConfigsCriadas?: FeeConfigurationUncheckedUpdateManyWithoutCriadoPorNestedInput
    auditLogs?: AuditLogUncheckedUpdateManyWithoutUserNestedInput
    creditApplications?: CreditApplicationUncheckedUpdateManyWithoutUserNestedInput
    savingsAccounts?: SavingsAccountUncheckedUpdateManyWithoutUserNestedInput
    referralsCreated?: ReferralUncheckedUpdateManyWithoutReferrerNestedInput
    referralAsReferred?: ReferralUncheckedUpdateManyWithoutReferredUserNestedInput
    quizAttempts?: QuizAttemptUncheckedUpdateManyWithoutUserNestedInput
    badges?: BadgeUncheckedUpdateManyWithoutUserNestedInput
    insurancePolicies?: InsurancePolicyUncheckedUpdateManyWithoutUserNestedInput
  }

  export type UserUncheckedUpdateManyWithoutReferredByInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: StringFieldUpdateOperationsInput | string
    passwordHash?: StringFieldUpdateOperationsInput | string
    bi?: NullableStringFieldUpdateOperationsInput | string | null
    dataNascimento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    provincia?: NullableStringFieldUpdateOperationsInput | string | null
    pais?: StringFieldUpdateOperationsInput | string
    moedaPreferida?: StringFieldUpdateOperationsInput | string
    fotoPerfilUrl?: NullableStringFieldUpdateOperationsInput | string | null
    kycStatus?: StringFieldUpdateOperationsInput | string
    kycNivel?: IntFieldUpdateOperationsInput | number
    kycDataJson?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreAtual?: IntFieldUpdateOperationsInput | number
    role?: StringFieldUpdateOperationsInput | string
    referralCode?: NullableStringFieldUpdateOperationsInput | string | null
    pontosEducacao?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type GroupUpdateWithoutCriadorInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    numMembros?: IntFieldUpdateOperationsInput | number
    valorContribuicaoMensal?: FloatFieldUpdateOperationsInput | number
    taxaPrincipalAplicada?: FloatFieldUpdateOperationsInput | number
    reservaTecnicaAplicada?: FloatFieldUpdateOperationsInput | number
    periodicidade?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    pais?: StringFieldUpdateOperationsInput | string
    moeda?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    dataInicio?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    dataFimPrevista?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    cicloAtual?: IntFieldUpdateOperationsInput | number
    totalCiclos?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    memberships?: MembershipUpdateManyWithoutGroupNestedInput
    monthlyCycles?: MonthlyCycleUpdateManyWithoutGroupNestedInput
    invites?: InviteUpdateManyWithoutGroupNestedInput
    candidaturas?: GroupApplicationUpdateManyWithoutGroupNestedInput
  }

  export type GroupUncheckedUpdateWithoutCriadorInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    numMembros?: IntFieldUpdateOperationsInput | number
    valorContribuicaoMensal?: FloatFieldUpdateOperationsInput | number
    taxaPrincipalAplicada?: FloatFieldUpdateOperationsInput | number
    reservaTecnicaAplicada?: FloatFieldUpdateOperationsInput | number
    periodicidade?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    pais?: StringFieldUpdateOperationsInput | string
    moeda?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    dataInicio?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    dataFimPrevista?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    cicloAtual?: IntFieldUpdateOperationsInput | number
    totalCiclos?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    memberships?: MembershipUncheckedUpdateManyWithoutGroupNestedInput
    monthlyCycles?: MonthlyCycleUncheckedUpdateManyWithoutGroupNestedInput
    invites?: InviteUncheckedUpdateManyWithoutGroupNestedInput
    candidaturas?: GroupApplicationUncheckedUpdateManyWithoutGroupNestedInput
  }

  export type GroupUncheckedUpdateManyWithoutCriadorInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    numMembros?: IntFieldUpdateOperationsInput | number
    valorContribuicaoMensal?: FloatFieldUpdateOperationsInput | number
    taxaPrincipalAplicada?: FloatFieldUpdateOperationsInput | number
    reservaTecnicaAplicada?: FloatFieldUpdateOperationsInput | number
    periodicidade?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    pais?: StringFieldUpdateOperationsInput | string
    moeda?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    dataInicio?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    dataFimPrevista?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    cicloAtual?: IntFieldUpdateOperationsInput | number
    totalCiclos?: IntFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type MembershipUpdateWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    posicaoRotacao?: NullableIntFieldUpdateOperationsInput | number | null
    status?: StringFieldUpdateOperationsInput | string
    necessidadeUrgente?: BoolFieldUpdateOperationsInput | boolean
    dataJuncao?: DateTimeFieldUpdateOperationsInput | Date | string
    mesRecepcaoPrevisto?: NullableStringFieldUpdateOperationsInput | string | null
    group?: GroupUpdateOneRequiredWithoutMembershipsNestedInput
    monthlyCyclesBeneficiario?: MonthlyCycleUpdateManyWithoutBeneficiarioMembershipNestedInput
    contribuicoes?: ContributionUpdateManyWithoutMembershipNestedInput
  }

  export type MembershipUncheckedUpdateWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    groupId?: StringFieldUpdateOperationsInput | string
    posicaoRotacao?: NullableIntFieldUpdateOperationsInput | number | null
    status?: StringFieldUpdateOperationsInput | string
    necessidadeUrgente?: BoolFieldUpdateOperationsInput | boolean
    dataJuncao?: DateTimeFieldUpdateOperationsInput | Date | string
    mesRecepcaoPrevisto?: NullableStringFieldUpdateOperationsInput | string | null
    monthlyCyclesBeneficiario?: MonthlyCycleUncheckedUpdateManyWithoutBeneficiarioMembershipNestedInput
    contribuicoes?: ContributionUncheckedUpdateManyWithoutMembershipNestedInput
  }

  export type MembershipUncheckedUpdateManyWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    groupId?: StringFieldUpdateOperationsInput | string
    posicaoRotacao?: NullableIntFieldUpdateOperationsInput | number | null
    status?: StringFieldUpdateOperationsInput | string
    necessidadeUrgente?: BoolFieldUpdateOperationsInput | boolean
    dataJuncao?: DateTimeFieldUpdateOperationsInput | Date | string
    mesRecepcaoPrevisto?: NullableStringFieldUpdateOperationsInput | string | null
  }

  export type ContributionUpdateWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    valor?: FloatFieldUpdateOperationsInput | number
    dataPrevista?: DateTimeFieldUpdateOperationsInput | Date | string
    dataPagamento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
    metodoPagamento?: NullableStringFieldUpdateOperationsInput | string | null
    referenciaBancaria?: NullableStringFieldUpdateOperationsInput | string | null
    comprovativoUrl?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    membership?: MembershipUpdateOneRequiredWithoutContribuicoesNestedInput
    monthlyCycle?: MonthlyCycleUpdateOneRequiredWithoutContribuicoesNestedInput
    coverageDecision?: CoverageDecisionUpdateOneWithoutContributionNestedInput
  }

  export type ContributionUncheckedUpdateWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    membershipId?: StringFieldUpdateOperationsInput | string
    monthlyCycleId?: StringFieldUpdateOperationsInput | string
    valor?: FloatFieldUpdateOperationsInput | number
    dataPrevista?: DateTimeFieldUpdateOperationsInput | Date | string
    dataPagamento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
    metodoPagamento?: NullableStringFieldUpdateOperationsInput | string | null
    referenciaBancaria?: NullableStringFieldUpdateOperationsInput | string | null
    comprovativoUrl?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    coverageDecision?: CoverageDecisionUncheckedUpdateOneWithoutContributionNestedInput
  }

  export type ContributionUncheckedUpdateManyWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    membershipId?: StringFieldUpdateOperationsInput | string
    monthlyCycleId?: StringFieldUpdateOperationsInput | string
    valor?: FloatFieldUpdateOperationsInput | number
    dataPrevista?: DateTimeFieldUpdateOperationsInput | Date | string
    dataPagamento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
    metodoPagamento?: NullableStringFieldUpdateOperationsInput | string | null
    referenciaBancaria?: NullableStringFieldUpdateOperationsInput | string | null
    comprovativoUrl?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type CashoutUpdateWithoutBeneficiarioUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    valorBruto?: FloatFieldUpdateOperationsInput | number
    valorTaxaPrincipal?: FloatFieldUpdateOperationsInput | number
    valorReservaTecnica?: FloatFieldUpdateOperationsInput | number
    valorLiquido?: FloatFieldUpdateOperationsInput | number
    dataPrevista?: DateTimeFieldUpdateOperationsInput | Date | string
    dataExecucao?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
    contaDestino?: NullableStringFieldUpdateOperationsInput | string | null
    refTransferencia?: NullableStringFieldUpdateOperationsInput | string | null
    parcialMotivo?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    monthlyCycle?: MonthlyCycleUpdateOneRequiredWithoutCashoutNestedInput
  }

  export type CashoutUncheckedUpdateWithoutBeneficiarioUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    monthlyCycleId?: StringFieldUpdateOperationsInput | string
    valorBruto?: FloatFieldUpdateOperationsInput | number
    valorTaxaPrincipal?: FloatFieldUpdateOperationsInput | number
    valorReservaTecnica?: FloatFieldUpdateOperationsInput | number
    valorLiquido?: FloatFieldUpdateOperationsInput | number
    dataPrevista?: DateTimeFieldUpdateOperationsInput | Date | string
    dataExecucao?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
    contaDestino?: NullableStringFieldUpdateOperationsInput | string | null
    refTransferencia?: NullableStringFieldUpdateOperationsInput | string | null
    parcialMotivo?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type CashoutUncheckedUpdateManyWithoutBeneficiarioUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    monthlyCycleId?: StringFieldUpdateOperationsInput | string
    valorBruto?: FloatFieldUpdateOperationsInput | number
    valorTaxaPrincipal?: FloatFieldUpdateOperationsInput | number
    valorReservaTecnica?: FloatFieldUpdateOperationsInput | number
    valorLiquido?: FloatFieldUpdateOperationsInput | number
    dataPrevista?: DateTimeFieldUpdateOperationsInput | Date | string
    dataExecucao?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
    contaDestino?: NullableStringFieldUpdateOperationsInput | string | null
    refTransferencia?: NullableStringFieldUpdateOperationsInput | string | null
    parcialMotivo?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type LoanUpdateWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    contributionId?: NullableStringFieldUpdateOperationsInput | string | null
    valorCapital?: FloatFieldUpdateOperationsInput | number
    taxaEmprestimo?: FloatFieldUpdateOperationsInput | number
    valorTotalDevido?: FloatFieldUpdateOperationsInput | number
    jurosMoraAcumulados?: FloatFieldUpdateOperationsInput | number
    dataInicio?: DateTimeFieldUpdateOperationsInput | Date | string
    dataPagamento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    monthlyCycle?: MonthlyCycleUpdateOneRequiredWithoutLoansNestedInput
  }

  export type LoanUncheckedUpdateWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    monthlyCycleId?: StringFieldUpdateOperationsInput | string
    contributionId?: NullableStringFieldUpdateOperationsInput | string | null
    valorCapital?: FloatFieldUpdateOperationsInput | number
    taxaEmprestimo?: FloatFieldUpdateOperationsInput | number
    valorTotalDevido?: FloatFieldUpdateOperationsInput | number
    jurosMoraAcumulados?: FloatFieldUpdateOperationsInput | number
    dataInicio?: DateTimeFieldUpdateOperationsInput | Date | string
    dataPagamento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type LoanUncheckedUpdateManyWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    monthlyCycleId?: StringFieldUpdateOperationsInput | string
    contributionId?: NullableStringFieldUpdateOperationsInput | string | null
    valorCapital?: FloatFieldUpdateOperationsInput | number
    taxaEmprestimo?: FloatFieldUpdateOperationsInput | number
    valorTotalDevido?: FloatFieldUpdateOperationsInput | number
    jurosMoraAcumulados?: FloatFieldUpdateOperationsInput | number
    dataInicio?: DateTimeFieldUpdateOperationsInput | Date | string
    dataPagamento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type ScoreEventUpdateWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    tipoEvento?: StringFieldUpdateOperationsInput | string
    impacto?: IntFieldUpdateOperationsInput | number
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    scoreAntes?: IntFieldUpdateOperationsInput | number
    scoreDepois?: IntFieldUpdateOperationsInput | number
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type ScoreEventUncheckedUpdateWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    tipoEvento?: StringFieldUpdateOperationsInput | string
    impacto?: IntFieldUpdateOperationsInput | number
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    scoreAntes?: IntFieldUpdateOperationsInput | number
    scoreDepois?: IntFieldUpdateOperationsInput | number
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type ScoreEventUncheckedUpdateManyWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    tipoEvento?: StringFieldUpdateOperationsInput | string
    impacto?: IntFieldUpdateOperationsInput | number
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    scoreAntes?: IntFieldUpdateOperationsInput | number
    scoreDepois?: IntFieldUpdateOperationsInput | number
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type ReintegrationUpdateWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    valorDividaOriginal?: FloatFieldUpdateOperationsInput | number
    taxaReintegracaoAplicada?: FloatFieldUpdateOperationsInput | number
    valorTaxaPaga?: FloatFieldUpdateOperationsInput | number
    dataSolicitacao?: DateTimeFieldUpdateOperationsInput | Date | string
    dataConclusao?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
  }

  export type ReintegrationUncheckedUpdateWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    valorDividaOriginal?: FloatFieldUpdateOperationsInput | number
    taxaReintegracaoAplicada?: FloatFieldUpdateOperationsInput | number
    valorTaxaPaga?: FloatFieldUpdateOperationsInput | number
    dataSolicitacao?: DateTimeFieldUpdateOperationsInput | Date | string
    dataConclusao?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
  }

  export type ReintegrationUncheckedUpdateManyWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    valorDividaOriginal?: FloatFieldUpdateOperationsInput | number
    taxaReintegracaoAplicada?: FloatFieldUpdateOperationsInput | number
    valorTaxaPaga?: FloatFieldUpdateOperationsInput | number
    dataSolicitacao?: DateTimeFieldUpdateOperationsInput | Date | string
    dataConclusao?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
  }

  export type OtpUpdateWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    codigo?: StringFieldUpdateOperationsInput | string
    proposito?: StringFieldUpdateOperationsInput | string
    consumido?: BoolFieldUpdateOperationsInput | boolean
    expiraEm?: DateTimeFieldUpdateOperationsInput | Date | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type OtpUncheckedUpdateWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    codigo?: StringFieldUpdateOperationsInput | string
    proposito?: StringFieldUpdateOperationsInput | string
    consumido?: BoolFieldUpdateOperationsInput | boolean
    expiraEm?: DateTimeFieldUpdateOperationsInput | Date | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type OtpUncheckedUpdateManyWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    codigo?: StringFieldUpdateOperationsInput | string
    proposito?: StringFieldUpdateOperationsInput | string
    consumido?: BoolFieldUpdateOperationsInput | boolean
    expiraEm?: DateTimeFieldUpdateOperationsInput | Date | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type SessionUpdateWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    token?: StringFieldUpdateOperationsInput | string
    expiraEm?: DateTimeFieldUpdateOperationsInput | Date | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type SessionUncheckedUpdateWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    token?: StringFieldUpdateOperationsInput | string
    expiraEm?: DateTimeFieldUpdateOperationsInput | Date | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type SessionUncheckedUpdateManyWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    token?: StringFieldUpdateOperationsInput | string
    expiraEm?: DateTimeFieldUpdateOperationsInput | Date | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type NotificationUpdateWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    canal?: StringFieldUpdateOperationsInput | string
    titulo?: StringFieldUpdateOperationsInput | string
    corpo?: StringFieldUpdateOperationsInput | string
    lida?: BoolFieldUpdateOperationsInput | boolean
    metadataJson?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type NotificationUncheckedUpdateWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    canal?: StringFieldUpdateOperationsInput | string
    titulo?: StringFieldUpdateOperationsInput | string
    corpo?: StringFieldUpdateOperationsInput | string
    lida?: BoolFieldUpdateOperationsInput | boolean
    metadataJson?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type NotificationUncheckedUpdateManyWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    canal?: StringFieldUpdateOperationsInput | string
    titulo?: StringFieldUpdateOperationsInput | string
    corpo?: StringFieldUpdateOperationsInput | string
    lida?: BoolFieldUpdateOperationsInput | boolean
    metadataJson?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type CoverageDecisionUpdateWithoutDecisorUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    decisao?: StringFieldUpdateOperationsInput | string
    motivo?: StringFieldUpdateOperationsInput | string
    scoreNoMomento?: IntFieldUpdateOperationsInput | number
    historicoInadimplencias?: IntFieldUpdateOperationsInput | number
    decisorSistema?: BoolFieldUpdateOperationsInput | boolean
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    contribution?: ContributionUpdateOneRequiredWithoutCoverageDecisionNestedInput
  }

  export type CoverageDecisionUncheckedUpdateWithoutDecisorUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    contributionId?: StringFieldUpdateOperationsInput | string
    decisao?: StringFieldUpdateOperationsInput | string
    motivo?: StringFieldUpdateOperationsInput | string
    scoreNoMomento?: IntFieldUpdateOperationsInput | number
    historicoInadimplencias?: IntFieldUpdateOperationsInput | number
    decisorSistema?: BoolFieldUpdateOperationsInput | boolean
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type CoverageDecisionUncheckedUpdateManyWithoutDecisorUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    contributionId?: StringFieldUpdateOperationsInput | string
    decisao?: StringFieldUpdateOperationsInput | string
    motivo?: StringFieldUpdateOperationsInput | string
    scoreNoMomento?: IntFieldUpdateOperationsInput | number
    historicoInadimplencias?: IntFieldUpdateOperationsInput | number
    decisorSistema?: BoolFieldUpdateOperationsInput | boolean
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type InviteUpdateWithoutConvidadoPorInput = {
    id?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: NullableStringFieldUpdateOperationsInput | string | null
    token?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    expiraEm?: DateTimeFieldUpdateOperationsInput | Date | string
    group?: GroupUpdateOneRequiredWithoutInvitesNestedInput
  }

  export type InviteUncheckedUpdateWithoutConvidadoPorInput = {
    id?: StringFieldUpdateOperationsInput | string
    groupId?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: NullableStringFieldUpdateOperationsInput | string | null
    token?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    expiraEm?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type InviteUncheckedUpdateManyWithoutConvidadoPorInput = {
    id?: StringFieldUpdateOperationsInput | string
    groupId?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: NullableStringFieldUpdateOperationsInput | string | null
    token?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    expiraEm?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type FeeConfigurationUpdateWithoutCriadoPorInput = {
    id?: StringFieldUpdateOperationsInput | string
    tipoFee?: StringFieldUpdateOperationsInput | string
    valor?: FloatFieldUpdateOperationsInput | number
    min?: FloatFieldUpdateOperationsInput | number
    max?: FloatFieldUpdateOperationsInput | number
    dataInicio?: DateTimeFieldUpdateOperationsInput | Date | string
    dataFim?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    motivoMudanca?: NullableStringFieldUpdateOperationsInput | string | null
    ativa?: BoolFieldUpdateOperationsInput | boolean
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type FeeConfigurationUncheckedUpdateWithoutCriadoPorInput = {
    id?: StringFieldUpdateOperationsInput | string
    tipoFee?: StringFieldUpdateOperationsInput | string
    valor?: FloatFieldUpdateOperationsInput | number
    min?: FloatFieldUpdateOperationsInput | number
    max?: FloatFieldUpdateOperationsInput | number
    dataInicio?: DateTimeFieldUpdateOperationsInput | Date | string
    dataFim?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    motivoMudanca?: NullableStringFieldUpdateOperationsInput | string | null
    ativa?: BoolFieldUpdateOperationsInput | boolean
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type FeeConfigurationUncheckedUpdateManyWithoutCriadoPorInput = {
    id?: StringFieldUpdateOperationsInput | string
    tipoFee?: StringFieldUpdateOperationsInput | string
    valor?: FloatFieldUpdateOperationsInput | number
    min?: FloatFieldUpdateOperationsInput | number
    max?: FloatFieldUpdateOperationsInput | number
    dataInicio?: DateTimeFieldUpdateOperationsInput | Date | string
    dataFim?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    motivoMudanca?: NullableStringFieldUpdateOperationsInput | string | null
    ativa?: BoolFieldUpdateOperationsInput | boolean
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type AuditLogUpdateWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    acao?: StringFieldUpdateOperationsInput | string
    entidade?: StringFieldUpdateOperationsInput | string
    entidadeId?: NullableStringFieldUpdateOperationsInput | string | null
    dadosAntes?: NullableStringFieldUpdateOperationsInput | string | null
    dadosDepois?: NullableStringFieldUpdateOperationsInput | string | null
    ip?: NullableStringFieldUpdateOperationsInput | string | null
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type AuditLogUncheckedUpdateWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    acao?: StringFieldUpdateOperationsInput | string
    entidade?: StringFieldUpdateOperationsInput | string
    entidadeId?: NullableStringFieldUpdateOperationsInput | string | null
    dadosAntes?: NullableStringFieldUpdateOperationsInput | string | null
    dadosDepois?: NullableStringFieldUpdateOperationsInput | string | null
    ip?: NullableStringFieldUpdateOperationsInput | string | null
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type AuditLogUncheckedUpdateManyWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    acao?: StringFieldUpdateOperationsInput | string
    entidade?: StringFieldUpdateOperationsInput | string
    entidadeId?: NullableStringFieldUpdateOperationsInput | string | null
    dadosAntes?: NullableStringFieldUpdateOperationsInput | string | null
    dadosDepois?: NullableStringFieldUpdateOperationsInput | string | null
    ip?: NullableStringFieldUpdateOperationsInput | string | null
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type CreditApplicationUpdateWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    valorSolicitado?: FloatFieldUpdateOperationsInput | number
    prazoMeses?: IntFieldUpdateOperationsInput | number
    taxaJuroAplicada?: FloatFieldUpdateOperationsInput | number
    prestacaoMensal?: FloatFieldUpdateOperationsInput | number
    finalidade?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreNoMomento?: IntFieldUpdateOperationsInput | number
    motivoDecisao?: NullableStringFieldUpdateOperationsInput | string | null
    decisaoPorId?: NullableStringFieldUpdateOperationsInput | string | null
    dataAprovacao?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    dataDesembolso?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    prestacoes?: CreditInstallmentUpdateManyWithoutApplicationNestedInput
  }

  export type CreditApplicationUncheckedUpdateWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    valorSolicitado?: FloatFieldUpdateOperationsInput | number
    prazoMeses?: IntFieldUpdateOperationsInput | number
    taxaJuroAplicada?: FloatFieldUpdateOperationsInput | number
    prestacaoMensal?: FloatFieldUpdateOperationsInput | number
    finalidade?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreNoMomento?: IntFieldUpdateOperationsInput | number
    motivoDecisao?: NullableStringFieldUpdateOperationsInput | string | null
    decisaoPorId?: NullableStringFieldUpdateOperationsInput | string | null
    dataAprovacao?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    dataDesembolso?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    prestacoes?: CreditInstallmentUncheckedUpdateManyWithoutApplicationNestedInput
  }

  export type CreditApplicationUncheckedUpdateManyWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    valorSolicitado?: FloatFieldUpdateOperationsInput | number
    prazoMeses?: IntFieldUpdateOperationsInput | number
    taxaJuroAplicada?: FloatFieldUpdateOperationsInput | number
    prestacaoMensal?: FloatFieldUpdateOperationsInput | number
    finalidade?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    scoreNoMomento?: IntFieldUpdateOperationsInput | number
    motivoDecisao?: NullableStringFieldUpdateOperationsInput | string | null
    decisaoPorId?: NullableStringFieldUpdateOperationsInput | string | null
    dataAprovacao?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    dataDesembolso?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type SavingsAccountUpdateWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    objectivo?: NullableStringFieldUpdateOperationsInput | string | null
    meta?: NullableFloatFieldUpdateOperationsInput | number | null
    saldo?: FloatFieldUpdateOperationsInput | number
    taxaRemuneracaoAnual?: FloatFieldUpdateOperationsInput | number
    imobilizacaoMeses?: IntFieldUpdateOperationsInput | number
    status?: StringFieldUpdateOperationsInput | string
    ultimaCapitalizacao?: DateTimeFieldUpdateOperationsInput | Date | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    movimentos?: SavingsMovementUpdateManyWithoutAccountNestedInput
  }

  export type SavingsAccountUncheckedUpdateWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    objectivo?: NullableStringFieldUpdateOperationsInput | string | null
    meta?: NullableFloatFieldUpdateOperationsInput | number | null
    saldo?: FloatFieldUpdateOperationsInput | number
    taxaRemuneracaoAnual?: FloatFieldUpdateOperationsInput | number
    imobilizacaoMeses?: IntFieldUpdateOperationsInput | number
    status?: StringFieldUpdateOperationsInput | string
    ultimaCapitalizacao?: DateTimeFieldUpdateOperationsInput | Date | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    movimentos?: SavingsMovementUncheckedUpdateManyWithoutAccountNestedInput
  }

  export type SavingsAccountUncheckedUpdateManyWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    nome?: StringFieldUpdateOperationsInput | string
    objectivo?: NullableStringFieldUpdateOperationsInput | string | null
    meta?: NullableFloatFieldUpdateOperationsInput | number | null
    saldo?: FloatFieldUpdateOperationsInput | number
    taxaRemuneracaoAnual?: FloatFieldUpdateOperationsInput | number
    imobilizacaoMeses?: IntFieldUpdateOperationsInput | number
    status?: StringFieldUpdateOperationsInput | string
    ultimaCapitalizacao?: DateTimeFieldUpdateOperationsInput | Date | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type ReferralUpdateWithoutReferrerInput = {
    id?: StringFieldUpdateOperationsInput | string
    codigo?: StringFieldUpdateOperationsInput | string
    canal?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    recompensa?: FloatFieldUpdateOperationsInput | number
    recompensaPaga?: BoolFieldUpdateOperationsInput | boolean
    dataRegisto?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    dataActivacao?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referredUser?: UserUpdateOneWithoutReferralAsReferredNestedInput
  }

  export type ReferralUncheckedUpdateWithoutReferrerInput = {
    id?: StringFieldUpdateOperationsInput | string
    referredUserId?: NullableStringFieldUpdateOperationsInput | string | null
    codigo?: StringFieldUpdateOperationsInput | string
    canal?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    recompensa?: FloatFieldUpdateOperationsInput | number
    recompensaPaga?: BoolFieldUpdateOperationsInput | boolean
    dataRegisto?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    dataActivacao?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type ReferralUncheckedUpdateManyWithoutReferrerInput = {
    id?: StringFieldUpdateOperationsInput | string
    referredUserId?: NullableStringFieldUpdateOperationsInput | string | null
    codigo?: StringFieldUpdateOperationsInput | string
    canal?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    recompensa?: FloatFieldUpdateOperationsInput | number
    recompensaPaga?: BoolFieldUpdateOperationsInput | boolean
    dataRegisto?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    dataActivacao?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type ReferralUpdateWithoutReferredUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    codigo?: StringFieldUpdateOperationsInput | string
    canal?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    recompensa?: FloatFieldUpdateOperationsInput | number
    recompensaPaga?: BoolFieldUpdateOperationsInput | boolean
    dataRegisto?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    dataActivacao?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    referrer?: UserUpdateOneRequiredWithoutReferralsCreatedNestedInput
  }

  export type ReferralUncheckedUpdateWithoutReferredUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    referrerUserId?: StringFieldUpdateOperationsInput | string
    codigo?: StringFieldUpdateOperationsInput | string
    canal?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    recompensa?: FloatFieldUpdateOperationsInput | number
    recompensaPaga?: BoolFieldUpdateOperationsInput | boolean
    dataRegisto?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    dataActivacao?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type ReferralUncheckedUpdateManyWithoutReferredUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    referrerUserId?: StringFieldUpdateOperationsInput | string
    codigo?: StringFieldUpdateOperationsInput | string
    canal?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    recompensa?: FloatFieldUpdateOperationsInput | number
    recompensaPaga?: BoolFieldUpdateOperationsInput | boolean
    dataRegisto?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    dataActivacao?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type QuizAttemptUpdateWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    acertos?: IntFieldUpdateOperationsInput | number
    total?: IntFieldUpdateOperationsInput | number
    pontosGanhos?: IntFieldUpdateOperationsInput | number
    respostasJson?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    quiz?: QuizUpdateOneRequiredWithoutAttemptsNestedInput
  }

  export type QuizAttemptUncheckedUpdateWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    quizId?: StringFieldUpdateOperationsInput | string
    acertos?: IntFieldUpdateOperationsInput | number
    total?: IntFieldUpdateOperationsInput | number
    pontosGanhos?: IntFieldUpdateOperationsInput | number
    respostasJson?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type QuizAttemptUncheckedUpdateManyWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    quizId?: StringFieldUpdateOperationsInput | string
    acertos?: IntFieldUpdateOperationsInput | number
    total?: IntFieldUpdateOperationsInput | number
    pontosGanhos?: IntFieldUpdateOperationsInput | number
    respostasJson?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type BadgeUpdateWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    titulo?: StringFieldUpdateOperationsInput | string
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type BadgeUncheckedUpdateWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    titulo?: StringFieldUpdateOperationsInput | string
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type BadgeUncheckedUpdateManyWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    titulo?: StringFieldUpdateOperationsInput | string
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type InsurancePolicyUpdateWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    dataInicio?: DateTimeFieldUpdateOperationsInput | Date | string
    premiumPago?: FloatFieldUpdateOperationsInput | number
    proximaCobranca?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    product?: InsuranceProductUpdateOneRequiredWithoutPoliciesNestedInput
  }

  export type InsurancePolicyUncheckedUpdateWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    productId?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    dataInicio?: DateTimeFieldUpdateOperationsInput | Date | string
    premiumPago?: FloatFieldUpdateOperationsInput | number
    proximaCobranca?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  }

  export type InsurancePolicyUncheckedUpdateManyWithoutUserInput = {
    id?: StringFieldUpdateOperationsInput | string
    productId?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    dataInicio?: DateTimeFieldUpdateOperationsInput | Date | string
    premiumPago?: FloatFieldUpdateOperationsInput | number
    proximaCobranca?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  }

  export type MembershipCreateManyGroupInput = {
    id?: string
    userId: string
    posicaoRotacao?: number | null
    status?: string
    necessidadeUrgente?: boolean
    dataJuncao?: Date | string
    mesRecepcaoPrevisto?: string | null
  }

  export type MonthlyCycleCreateManyGroupInput = {
    id?: string
    numeroCiclo: number
    mesAno: string
    beneficiarioMembershipId: string
    dataContribuicaoLimite: Date | string
    dataCashout: Date | string
    status?: string
    valorPoteBruto: number
    valorTaxaPrincipal: number
    valorReservaTecnica: number
    valorPoteLiquido: number
    createdAt?: Date | string
    updatedAt?: Date | string
  }

  export type InviteCreateManyGroupInput = {
    id?: string
    convidadoPorId: string
    telefone: string
    email?: string | null
    token: string
    status?: string
    createdAt?: Date | string
    expiraEm: Date | string
  }

  export type GroupApplicationCreateManyGroupInput = {
    id?: string
    userId: string
    mensagem?: string | null
    status?: string
    createdAt?: Date | string
  }

  export type MembershipUpdateWithoutGroupInput = {
    id?: StringFieldUpdateOperationsInput | string
    posicaoRotacao?: NullableIntFieldUpdateOperationsInput | number | null
    status?: StringFieldUpdateOperationsInput | string
    necessidadeUrgente?: BoolFieldUpdateOperationsInput | boolean
    dataJuncao?: DateTimeFieldUpdateOperationsInput | Date | string
    mesRecepcaoPrevisto?: NullableStringFieldUpdateOperationsInput | string | null
    user?: UserUpdateOneRequiredWithoutMembershipsNestedInput
    monthlyCyclesBeneficiario?: MonthlyCycleUpdateManyWithoutBeneficiarioMembershipNestedInput
    contribuicoes?: ContributionUpdateManyWithoutMembershipNestedInput
  }

  export type MembershipUncheckedUpdateWithoutGroupInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    posicaoRotacao?: NullableIntFieldUpdateOperationsInput | number | null
    status?: StringFieldUpdateOperationsInput | string
    necessidadeUrgente?: BoolFieldUpdateOperationsInput | boolean
    dataJuncao?: DateTimeFieldUpdateOperationsInput | Date | string
    mesRecepcaoPrevisto?: NullableStringFieldUpdateOperationsInput | string | null
    monthlyCyclesBeneficiario?: MonthlyCycleUncheckedUpdateManyWithoutBeneficiarioMembershipNestedInput
    contribuicoes?: ContributionUncheckedUpdateManyWithoutMembershipNestedInput
  }

  export type MembershipUncheckedUpdateManyWithoutGroupInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    posicaoRotacao?: NullableIntFieldUpdateOperationsInput | number | null
    status?: StringFieldUpdateOperationsInput | string
    necessidadeUrgente?: BoolFieldUpdateOperationsInput | boolean
    dataJuncao?: DateTimeFieldUpdateOperationsInput | Date | string
    mesRecepcaoPrevisto?: NullableStringFieldUpdateOperationsInput | string | null
  }

  export type MonthlyCycleUpdateWithoutGroupInput = {
    id?: StringFieldUpdateOperationsInput | string
    numeroCiclo?: IntFieldUpdateOperationsInput | number
    mesAno?: StringFieldUpdateOperationsInput | string
    dataContribuicaoLimite?: DateTimeFieldUpdateOperationsInput | Date | string
    dataCashout?: DateTimeFieldUpdateOperationsInput | Date | string
    status?: StringFieldUpdateOperationsInput | string
    valorPoteBruto?: FloatFieldUpdateOperationsInput | number
    valorTaxaPrincipal?: FloatFieldUpdateOperationsInput | number
    valorReservaTecnica?: FloatFieldUpdateOperationsInput | number
    valorPoteLiquido?: FloatFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    beneficiarioMembership?: MembershipUpdateOneRequiredWithoutMonthlyCyclesBeneficiarioNestedInput
    contribuicoes?: ContributionUpdateManyWithoutMonthlyCycleNestedInput
    cashout?: CashoutUpdateOneWithoutMonthlyCycleNestedInput
    loans?: LoanUpdateManyWithoutMonthlyCycleNestedInput
  }

  export type MonthlyCycleUncheckedUpdateWithoutGroupInput = {
    id?: StringFieldUpdateOperationsInput | string
    numeroCiclo?: IntFieldUpdateOperationsInput | number
    mesAno?: StringFieldUpdateOperationsInput | string
    beneficiarioMembershipId?: StringFieldUpdateOperationsInput | string
    dataContribuicaoLimite?: DateTimeFieldUpdateOperationsInput | Date | string
    dataCashout?: DateTimeFieldUpdateOperationsInput | Date | string
    status?: StringFieldUpdateOperationsInput | string
    valorPoteBruto?: FloatFieldUpdateOperationsInput | number
    valorTaxaPrincipal?: FloatFieldUpdateOperationsInput | number
    valorReservaTecnica?: FloatFieldUpdateOperationsInput | number
    valorPoteLiquido?: FloatFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    contribuicoes?: ContributionUncheckedUpdateManyWithoutMonthlyCycleNestedInput
    cashout?: CashoutUncheckedUpdateOneWithoutMonthlyCycleNestedInput
    loans?: LoanUncheckedUpdateManyWithoutMonthlyCycleNestedInput
  }

  export type MonthlyCycleUncheckedUpdateManyWithoutGroupInput = {
    id?: StringFieldUpdateOperationsInput | string
    numeroCiclo?: IntFieldUpdateOperationsInput | number
    mesAno?: StringFieldUpdateOperationsInput | string
    beneficiarioMembershipId?: StringFieldUpdateOperationsInput | string
    dataContribuicaoLimite?: DateTimeFieldUpdateOperationsInput | Date | string
    dataCashout?: DateTimeFieldUpdateOperationsInput | Date | string
    status?: StringFieldUpdateOperationsInput | string
    valorPoteBruto?: FloatFieldUpdateOperationsInput | number
    valorTaxaPrincipal?: FloatFieldUpdateOperationsInput | number
    valorReservaTecnica?: FloatFieldUpdateOperationsInput | number
    valorPoteLiquido?: FloatFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type InviteUpdateWithoutGroupInput = {
    id?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: NullableStringFieldUpdateOperationsInput | string | null
    token?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    expiraEm?: DateTimeFieldUpdateOperationsInput | Date | string
    convidadoPor?: UserUpdateOneRequiredWithoutInvitesEnviadosNestedInput
  }

  export type InviteUncheckedUpdateWithoutGroupInput = {
    id?: StringFieldUpdateOperationsInput | string
    convidadoPorId?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: NullableStringFieldUpdateOperationsInput | string | null
    token?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    expiraEm?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type InviteUncheckedUpdateManyWithoutGroupInput = {
    id?: StringFieldUpdateOperationsInput | string
    convidadoPorId?: StringFieldUpdateOperationsInput | string
    telefone?: StringFieldUpdateOperationsInput | string
    email?: NullableStringFieldUpdateOperationsInput | string | null
    token?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    expiraEm?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type GroupApplicationUpdateWithoutGroupInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    mensagem?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type GroupApplicationUncheckedUpdateWithoutGroupInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    mensagem?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type GroupApplicationUncheckedUpdateManyWithoutGroupInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    mensagem?: NullableStringFieldUpdateOperationsInput | string | null
    status?: StringFieldUpdateOperationsInput | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type MonthlyCycleCreateManyBeneficiarioMembershipInput = {
    id?: string
    groupId: string
    numeroCiclo: number
    mesAno: string
    dataContribuicaoLimite: Date | string
    dataCashout: Date | string
    status?: string
    valorPoteBruto: number
    valorTaxaPrincipal: number
    valorReservaTecnica: number
    valorPoteLiquido: number
    createdAt?: Date | string
    updatedAt?: Date | string
  }

  export type ContributionCreateManyMembershipInput = {
    id?: string
    userId: string
    monthlyCycleId: string
    valor: number
    dataPrevista: Date | string
    dataPagamento?: Date | string | null
    status?: string
    metodoPagamento?: string | null
    referenciaBancaria?: string | null
    comprovativoUrl?: string | null
    createdAt?: Date | string
    updatedAt?: Date | string
  }

  export type MonthlyCycleUpdateWithoutBeneficiarioMembershipInput = {
    id?: StringFieldUpdateOperationsInput | string
    numeroCiclo?: IntFieldUpdateOperationsInput | number
    mesAno?: StringFieldUpdateOperationsInput | string
    dataContribuicaoLimite?: DateTimeFieldUpdateOperationsInput | Date | string
    dataCashout?: DateTimeFieldUpdateOperationsInput | Date | string
    status?: StringFieldUpdateOperationsInput | string
    valorPoteBruto?: FloatFieldUpdateOperationsInput | number
    valorTaxaPrincipal?: FloatFieldUpdateOperationsInput | number
    valorReservaTecnica?: FloatFieldUpdateOperationsInput | number
    valorPoteLiquido?: FloatFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    group?: GroupUpdateOneRequiredWithoutMonthlyCyclesNestedInput
    contribuicoes?: ContributionUpdateManyWithoutMonthlyCycleNestedInput
    cashout?: CashoutUpdateOneWithoutMonthlyCycleNestedInput
    loans?: LoanUpdateManyWithoutMonthlyCycleNestedInput
  }

  export type MonthlyCycleUncheckedUpdateWithoutBeneficiarioMembershipInput = {
    id?: StringFieldUpdateOperationsInput | string
    groupId?: StringFieldUpdateOperationsInput | string
    numeroCiclo?: IntFieldUpdateOperationsInput | number
    mesAno?: StringFieldUpdateOperationsInput | string
    dataContribuicaoLimite?: DateTimeFieldUpdateOperationsInput | Date | string
    dataCashout?: DateTimeFieldUpdateOperationsInput | Date | string
    status?: StringFieldUpdateOperationsInput | string
    valorPoteBruto?: FloatFieldUpdateOperationsInput | number
    valorTaxaPrincipal?: FloatFieldUpdateOperationsInput | number
    valorReservaTecnica?: FloatFieldUpdateOperationsInput | number
    valorPoteLiquido?: FloatFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    contribuicoes?: ContributionUncheckedUpdateManyWithoutMonthlyCycleNestedInput
    cashout?: CashoutUncheckedUpdateOneWithoutMonthlyCycleNestedInput
    loans?: LoanUncheckedUpdateManyWithoutMonthlyCycleNestedInput
  }

  export type MonthlyCycleUncheckedUpdateManyWithoutBeneficiarioMembershipInput = {
    id?: StringFieldUpdateOperationsInput | string
    groupId?: StringFieldUpdateOperationsInput | string
    numeroCiclo?: IntFieldUpdateOperationsInput | number
    mesAno?: StringFieldUpdateOperationsInput | string
    dataContribuicaoLimite?: DateTimeFieldUpdateOperationsInput | Date | string
    dataCashout?: DateTimeFieldUpdateOperationsInput | Date | string
    status?: StringFieldUpdateOperationsInput | string
    valorPoteBruto?: FloatFieldUpdateOperationsInput | number
    valorTaxaPrincipal?: FloatFieldUpdateOperationsInput | number
    valorReservaTecnica?: FloatFieldUpdateOperationsInput | number
    valorPoteLiquido?: FloatFieldUpdateOperationsInput | number
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type ContributionUpdateWithoutMembershipInput = {
    id?: StringFieldUpdateOperationsInput | string
    valor?: FloatFieldUpdateOperationsInput | number
    dataPrevista?: DateTimeFieldUpdateOperationsInput | Date | string
    dataPagamento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
    metodoPagamento?: NullableStringFieldUpdateOperationsInput | string | null
    referenciaBancaria?: NullableStringFieldUpdateOperationsInput | string | null
    comprovativoUrl?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    user?: UserUpdateOneRequiredWithoutContribuicoesNestedInput
    monthlyCycle?: MonthlyCycleUpdateOneRequiredWithoutContribuicoesNestedInput
    coverageDecision?: CoverageDecisionUpdateOneWithoutContributionNestedInput
  }

  export type ContributionUncheckedUpdateWithoutMembershipInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    monthlyCycleId?: StringFieldUpdateOperationsInput | string
    valor?: FloatFieldUpdateOperationsInput | number
    dataPrevista?: DateTimeFieldUpdateOperationsInput | Date | string
    dataPagamento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
    metodoPagamento?: NullableStringFieldUpdateOperationsInput | string | null
    referenciaBancaria?: NullableStringFieldUpdateOperationsInput | string | null
    comprovativoUrl?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    coverageDecision?: CoverageDecisionUncheckedUpdateOneWithoutContributionNestedInput
  }

  export type ContributionUncheckedUpdateManyWithoutMembershipInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    monthlyCycleId?: StringFieldUpdateOperationsInput | string
    valor?: FloatFieldUpdateOperationsInput | number
    dataPrevista?: DateTimeFieldUpdateOperationsInput | Date | string
    dataPagamento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
    metodoPagamento?: NullableStringFieldUpdateOperationsInput | string | null
    referenciaBancaria?: NullableStringFieldUpdateOperationsInput | string | null
    comprovativoUrl?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type ContributionCreateManyMonthlyCycleInput = {
    id?: string
    membershipId: string
    userId: string
    valor: number
    dataPrevista: Date | string
    dataPagamento?: Date | string | null
    status?: string
    metodoPagamento?: string | null
    referenciaBancaria?: string | null
    comprovativoUrl?: string | null
    createdAt?: Date | string
    updatedAt?: Date | string
  }

  export type LoanCreateManyMonthlyCycleInput = {
    id?: string
    userId: string
    contributionId?: string | null
    valorCapital: number
    taxaEmprestimo: number
    valorTotalDevido: number
    jurosMoraAcumulados?: number
    dataInicio: Date | string
    dataPagamento?: Date | string | null
    status?: string
    createdAt?: Date | string
    updatedAt?: Date | string
  }

  export type ContributionUpdateWithoutMonthlyCycleInput = {
    id?: StringFieldUpdateOperationsInput | string
    valor?: FloatFieldUpdateOperationsInput | number
    dataPrevista?: DateTimeFieldUpdateOperationsInput | Date | string
    dataPagamento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
    metodoPagamento?: NullableStringFieldUpdateOperationsInput | string | null
    referenciaBancaria?: NullableStringFieldUpdateOperationsInput | string | null
    comprovativoUrl?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    membership?: MembershipUpdateOneRequiredWithoutContribuicoesNestedInput
    user?: UserUpdateOneRequiredWithoutContribuicoesNestedInput
    coverageDecision?: CoverageDecisionUpdateOneWithoutContributionNestedInput
  }

  export type ContributionUncheckedUpdateWithoutMonthlyCycleInput = {
    id?: StringFieldUpdateOperationsInput | string
    membershipId?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    valor?: FloatFieldUpdateOperationsInput | number
    dataPrevista?: DateTimeFieldUpdateOperationsInput | Date | string
    dataPagamento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
    metodoPagamento?: NullableStringFieldUpdateOperationsInput | string | null
    referenciaBancaria?: NullableStringFieldUpdateOperationsInput | string | null
    comprovativoUrl?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    coverageDecision?: CoverageDecisionUncheckedUpdateOneWithoutContributionNestedInput
  }

  export type ContributionUncheckedUpdateManyWithoutMonthlyCycleInput = {
    id?: StringFieldUpdateOperationsInput | string
    membershipId?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    valor?: FloatFieldUpdateOperationsInput | number
    dataPrevista?: DateTimeFieldUpdateOperationsInput | Date | string
    dataPagamento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
    metodoPagamento?: NullableStringFieldUpdateOperationsInput | string | null
    referenciaBancaria?: NullableStringFieldUpdateOperationsInput | string | null
    comprovativoUrl?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type LoanUpdateWithoutMonthlyCycleInput = {
    id?: StringFieldUpdateOperationsInput | string
    contributionId?: NullableStringFieldUpdateOperationsInput | string | null
    valorCapital?: FloatFieldUpdateOperationsInput | number
    taxaEmprestimo?: FloatFieldUpdateOperationsInput | number
    valorTotalDevido?: FloatFieldUpdateOperationsInput | number
    jurosMoraAcumulados?: FloatFieldUpdateOperationsInput | number
    dataInicio?: DateTimeFieldUpdateOperationsInput | Date | string
    dataPagamento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
    user?: UserUpdateOneRequiredWithoutLoansNestedInput
  }

  export type LoanUncheckedUpdateWithoutMonthlyCycleInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    contributionId?: NullableStringFieldUpdateOperationsInput | string | null
    valorCapital?: FloatFieldUpdateOperationsInput | number
    taxaEmprestimo?: FloatFieldUpdateOperationsInput | number
    valorTotalDevido?: FloatFieldUpdateOperationsInput | number
    jurosMoraAcumulados?: FloatFieldUpdateOperationsInput | number
    dataInicio?: DateTimeFieldUpdateOperationsInput | Date | string
    dataPagamento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type LoanUncheckedUpdateManyWithoutMonthlyCycleInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    contributionId?: NullableStringFieldUpdateOperationsInput | string | null
    valorCapital?: FloatFieldUpdateOperationsInput | number
    taxaEmprestimo?: FloatFieldUpdateOperationsInput | number
    valorTotalDevido?: FloatFieldUpdateOperationsInput | number
    jurosMoraAcumulados?: FloatFieldUpdateOperationsInput | number
    dataInicio?: DateTimeFieldUpdateOperationsInput | Date | string
    dataPagamento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    updatedAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type CreditInstallmentCreateManyApplicationInput = {
    id?: string
    numero: number
    valorCapital: number
    valorJuros: number
    valorTotal: number
    dataVencimento: Date | string
    dataPagamento?: Date | string | null
    status?: string
  }

  export type CreditInstallmentUpdateWithoutApplicationInput = {
    id?: StringFieldUpdateOperationsInput | string
    numero?: IntFieldUpdateOperationsInput | number
    valorCapital?: FloatFieldUpdateOperationsInput | number
    valorJuros?: FloatFieldUpdateOperationsInput | number
    valorTotal?: FloatFieldUpdateOperationsInput | number
    dataVencimento?: DateTimeFieldUpdateOperationsInput | Date | string
    dataPagamento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
  }

  export type CreditInstallmentUncheckedUpdateWithoutApplicationInput = {
    id?: StringFieldUpdateOperationsInput | string
    numero?: IntFieldUpdateOperationsInput | number
    valorCapital?: FloatFieldUpdateOperationsInput | number
    valorJuros?: FloatFieldUpdateOperationsInput | number
    valorTotal?: FloatFieldUpdateOperationsInput | number
    dataVencimento?: DateTimeFieldUpdateOperationsInput | Date | string
    dataPagamento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
  }

  export type CreditInstallmentUncheckedUpdateManyWithoutApplicationInput = {
    id?: StringFieldUpdateOperationsInput | string
    numero?: IntFieldUpdateOperationsInput | number
    valorCapital?: FloatFieldUpdateOperationsInput | number
    valorJuros?: FloatFieldUpdateOperationsInput | number
    valorTotal?: FloatFieldUpdateOperationsInput | number
    dataVencimento?: DateTimeFieldUpdateOperationsInput | Date | string
    dataPagamento?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    status?: StringFieldUpdateOperationsInput | string
  }

  export type SavingsMovementCreateManyAccountInput = {
    id?: string
    tipo: string
    valor: number
    saldoApos: number
    descricao?: string | null
    createdAt?: Date | string
  }

  export type SavingsMovementUpdateWithoutAccountInput = {
    id?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    valor?: FloatFieldUpdateOperationsInput | number
    saldoApos?: FloatFieldUpdateOperationsInput | number
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type SavingsMovementUncheckedUpdateWithoutAccountInput = {
    id?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    valor?: FloatFieldUpdateOperationsInput | number
    saldoApos?: FloatFieldUpdateOperationsInput | number
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type SavingsMovementUncheckedUpdateManyWithoutAccountInput = {
    id?: StringFieldUpdateOperationsInput | string
    tipo?: StringFieldUpdateOperationsInput | string
    valor?: FloatFieldUpdateOperationsInput | number
    saldoApos?: FloatFieldUpdateOperationsInput | number
    descricao?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type QuizAttemptCreateManyQuizInput = {
    id?: string
    userId: string
    acertos: number
    total: number
    pontosGanhos: number
    respostasJson?: string | null
    createdAt?: Date | string
  }

  export type QuizAttemptUpdateWithoutQuizInput = {
    id?: StringFieldUpdateOperationsInput | string
    acertos?: IntFieldUpdateOperationsInput | number
    total?: IntFieldUpdateOperationsInput | number
    pontosGanhos?: IntFieldUpdateOperationsInput | number
    respostasJson?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
    user?: UserUpdateOneRequiredWithoutQuizAttemptsNestedInput
  }

  export type QuizAttemptUncheckedUpdateWithoutQuizInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    acertos?: IntFieldUpdateOperationsInput | number
    total?: IntFieldUpdateOperationsInput | number
    pontosGanhos?: IntFieldUpdateOperationsInput | number
    respostasJson?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type QuizAttemptUncheckedUpdateManyWithoutQuizInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    acertos?: IntFieldUpdateOperationsInput | number
    total?: IntFieldUpdateOperationsInput | number
    pontosGanhos?: IntFieldUpdateOperationsInput | number
    respostasJson?: NullableStringFieldUpdateOperationsInput | string | null
    createdAt?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type ApiCallCreateManyApiKeyInput = {
    id?: string
    endpoint: string
    metodo?: string
    status: number
    duracaoMs: number
    ip?: string | null
    timestamp?: Date | string
  }

  export type ApiCallUpdateWithoutApiKeyInput = {
    id?: StringFieldUpdateOperationsInput | string
    endpoint?: StringFieldUpdateOperationsInput | string
    metodo?: StringFieldUpdateOperationsInput | string
    status?: IntFieldUpdateOperationsInput | number
    duracaoMs?: IntFieldUpdateOperationsInput | number
    ip?: NullableStringFieldUpdateOperationsInput | string | null
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type ApiCallUncheckedUpdateWithoutApiKeyInput = {
    id?: StringFieldUpdateOperationsInput | string
    endpoint?: StringFieldUpdateOperationsInput | string
    metodo?: StringFieldUpdateOperationsInput | string
    status?: IntFieldUpdateOperationsInput | number
    duracaoMs?: IntFieldUpdateOperationsInput | number
    ip?: NullableStringFieldUpdateOperationsInput | string | null
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type ApiCallUncheckedUpdateManyWithoutApiKeyInput = {
    id?: StringFieldUpdateOperationsInput | string
    endpoint?: StringFieldUpdateOperationsInput | string
    metodo?: StringFieldUpdateOperationsInput | string
    status?: IntFieldUpdateOperationsInput | number
    duracaoMs?: IntFieldUpdateOperationsInput | number
    ip?: NullableStringFieldUpdateOperationsInput | string | null
    timestamp?: DateTimeFieldUpdateOperationsInput | Date | string
  }

  export type InsurancePolicyCreateManyProductInput = {
    id?: string
    userId: string
    status?: string
    dataInicio?: Date | string
    premiumPago?: number
    proximaCobranca?: Date | string | null
  }

  export type InsurancePolicyUpdateWithoutProductInput = {
    id?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    dataInicio?: DateTimeFieldUpdateOperationsInput | Date | string
    premiumPago?: FloatFieldUpdateOperationsInput | number
    proximaCobranca?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
    user?: UserUpdateOneRequiredWithoutInsurancePoliciesNestedInput
  }

  export type InsurancePolicyUncheckedUpdateWithoutProductInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    dataInicio?: DateTimeFieldUpdateOperationsInput | Date | string
    premiumPago?: FloatFieldUpdateOperationsInput | number
    proximaCobranca?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  }

  export type InsurancePolicyUncheckedUpdateManyWithoutProductInput = {
    id?: StringFieldUpdateOperationsInput | string
    userId?: StringFieldUpdateOperationsInput | string
    status?: StringFieldUpdateOperationsInput | string
    dataInicio?: DateTimeFieldUpdateOperationsInput | Date | string
    premiumPago?: FloatFieldUpdateOperationsInput | number
    proximaCobranca?: NullableDateTimeFieldUpdateOperationsInput | Date | string | null
  }



  /**
   * Aliases for legacy arg types
   */
    /**
     * @deprecated Use UserCountOutputTypeDefaultArgs instead
     */
    export type UserCountOutputTypeArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = UserCountOutputTypeDefaultArgs<ExtArgs>
    /**
     * @deprecated Use GroupCountOutputTypeDefaultArgs instead
     */
    export type GroupCountOutputTypeArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = GroupCountOutputTypeDefaultArgs<ExtArgs>
    /**
     * @deprecated Use MembershipCountOutputTypeDefaultArgs instead
     */
    export type MembershipCountOutputTypeArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = MembershipCountOutputTypeDefaultArgs<ExtArgs>
    /**
     * @deprecated Use MonthlyCycleCountOutputTypeDefaultArgs instead
     */
    export type MonthlyCycleCountOutputTypeArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = MonthlyCycleCountOutputTypeDefaultArgs<ExtArgs>
    /**
     * @deprecated Use CreditApplicationCountOutputTypeDefaultArgs instead
     */
    export type CreditApplicationCountOutputTypeArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = CreditApplicationCountOutputTypeDefaultArgs<ExtArgs>
    /**
     * @deprecated Use SavingsAccountCountOutputTypeDefaultArgs instead
     */
    export type SavingsAccountCountOutputTypeArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = SavingsAccountCountOutputTypeDefaultArgs<ExtArgs>
    /**
     * @deprecated Use QuizCountOutputTypeDefaultArgs instead
     */
    export type QuizCountOutputTypeArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = QuizCountOutputTypeDefaultArgs<ExtArgs>
    /**
     * @deprecated Use ApiKeyCountOutputTypeDefaultArgs instead
     */
    export type ApiKeyCountOutputTypeArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = ApiKeyCountOutputTypeDefaultArgs<ExtArgs>
    /**
     * @deprecated Use InsuranceProductCountOutputTypeDefaultArgs instead
     */
    export type InsuranceProductCountOutputTypeArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = InsuranceProductCountOutputTypeDefaultArgs<ExtArgs>
    /**
     * @deprecated Use UserDefaultArgs instead
     */
    export type UserArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = UserDefaultArgs<ExtArgs>
    /**
     * @deprecated Use OtpDefaultArgs instead
     */
    export type OtpArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = OtpDefaultArgs<ExtArgs>
    /**
     * @deprecated Use SessionDefaultArgs instead
     */
    export type SessionArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = SessionDefaultArgs<ExtArgs>
    /**
     * @deprecated Use GroupDefaultArgs instead
     */
    export type GroupArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = GroupDefaultArgs<ExtArgs>
    /**
     * @deprecated Use GroupApplicationDefaultArgs instead
     */
    export type GroupApplicationArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = GroupApplicationDefaultArgs<ExtArgs>
    /**
     * @deprecated Use MembershipDefaultArgs instead
     */
    export type MembershipArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = MembershipDefaultArgs<ExtArgs>
    /**
     * @deprecated Use InviteDefaultArgs instead
     */
    export type InviteArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = InviteDefaultArgs<ExtArgs>
    /**
     * @deprecated Use MonthlyCycleDefaultArgs instead
     */
    export type MonthlyCycleArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = MonthlyCycleDefaultArgs<ExtArgs>
    /**
     * @deprecated Use ContributionDefaultArgs instead
     */
    export type ContributionArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = ContributionDefaultArgs<ExtArgs>
    /**
     * @deprecated Use CashoutDefaultArgs instead
     */
    export type CashoutArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = CashoutDefaultArgs<ExtArgs>
    /**
     * @deprecated Use LoanDefaultArgs instead
     */
    export type LoanArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = LoanDefaultArgs<ExtArgs>
    /**
     * @deprecated Use CoverageDecisionDefaultArgs instead
     */
    export type CoverageDecisionArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = CoverageDecisionDefaultArgs<ExtArgs>
    /**
     * @deprecated Use ReintegrationDefaultArgs instead
     */
    export type ReintegrationArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = ReintegrationDefaultArgs<ExtArgs>
    /**
     * @deprecated Use FeeConfigurationDefaultArgs instead
     */
    export type FeeConfigurationArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = FeeConfigurationDefaultArgs<ExtArgs>
    /**
     * @deprecated Use CoverageFundDefaultArgs instead
     */
    export type CoverageFundArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = CoverageFundDefaultArgs<ExtArgs>
    /**
     * @deprecated Use TransactionDefaultArgs instead
     */
    export type TransactionArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = TransactionDefaultArgs<ExtArgs>
    /**
     * @deprecated Use ScoreEventDefaultArgs instead
     */
    export type ScoreEventArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = ScoreEventDefaultArgs<ExtArgs>
    /**
     * @deprecated Use NotificationDefaultArgs instead
     */
    export type NotificationArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = NotificationDefaultArgs<ExtArgs>
    /**
     * @deprecated Use AuditLogDefaultArgs instead
     */
    export type AuditLogArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = AuditLogDefaultArgs<ExtArgs>
    /**
     * @deprecated Use SystemClockDefaultArgs instead
     */
    export type SystemClockArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = SystemClockDefaultArgs<ExtArgs>
    /**
     * @deprecated Use CreditApplicationDefaultArgs instead
     */
    export type CreditApplicationArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = CreditApplicationDefaultArgs<ExtArgs>
    /**
     * @deprecated Use CreditInstallmentDefaultArgs instead
     */
    export type CreditInstallmentArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = CreditInstallmentDefaultArgs<ExtArgs>
    /**
     * @deprecated Use SavingsAccountDefaultArgs instead
     */
    export type SavingsAccountArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = SavingsAccountDefaultArgs<ExtArgs>
    /**
     * @deprecated Use SavingsMovementDefaultArgs instead
     */
    export type SavingsMovementArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = SavingsMovementDefaultArgs<ExtArgs>
    /**
     * @deprecated Use ReferralDefaultArgs instead
     */
    export type ReferralArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = ReferralDefaultArgs<ExtArgs>
    /**
     * @deprecated Use ContentArticleDefaultArgs instead
     */
    export type ContentArticleArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = ContentArticleDefaultArgs<ExtArgs>
    /**
     * @deprecated Use QuizDefaultArgs instead
     */
    export type QuizArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = QuizDefaultArgs<ExtArgs>
    /**
     * @deprecated Use QuizAttemptDefaultArgs instead
     */
    export type QuizAttemptArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = QuizAttemptDefaultArgs<ExtArgs>
    /**
     * @deprecated Use BadgeDefaultArgs instead
     */
    export type BadgeArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = BadgeDefaultArgs<ExtArgs>
    /**
     * @deprecated Use ApiKeyDefaultArgs instead
     */
    export type ApiKeyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = ApiKeyDefaultArgs<ExtArgs>
    /**
     * @deprecated Use ApiCallDefaultArgs instead
     */
    export type ApiCallArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = ApiCallDefaultArgs<ExtArgs>
    /**
     * @deprecated Use InsuranceProductDefaultArgs instead
     */
    export type InsuranceProductArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = InsuranceProductDefaultArgs<ExtArgs>
    /**
     * @deprecated Use InsurancePolicyDefaultArgs instead
     */
    export type InsurancePolicyArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = InsurancePolicyDefaultArgs<ExtArgs>
    /**
     * @deprecated Use CountryDefaultArgs instead
     */
    export type CountryArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = CountryDefaultArgs<ExtArgs>
    /**
     * @deprecated Use AnalyticsSnapshotDefaultArgs instead
     */
    export type AnalyticsSnapshotArgs<ExtArgs extends $Extensions.InternalArgs = $Extensions.DefaultArgs> = AnalyticsSnapshotDefaultArgs<ExtArgs>

  /**
   * Batch Payload for updateMany & deleteMany & createMany
   */

  export type BatchPayload = {
    count: number
  }

  /**
   * DMMF
   */
  export const dmmf: runtime.BaseDMMF
}