
/* !!! This is code generated by Prisma. Do not edit directly. !!! */
/* eslint-disable */
// biome-ignore-all lint: generated file
// @ts-nocheck 
/*
 * This file exports the `Agent` model and its related types.
 *
 * 🟢 You can import this file directly.
 */
import type * as runtime from "@prisma/client/runtime/client"
import type * as $Enums from "../enums.js"
import type * as Prisma from "../internal/prismaNamespace.js"

/**
 * Model Agent
 * 
 */
export type AgentModel = runtime.Types.Result.DefaultSelection<Prisma.$AgentPayload>

export type AggregateAgent = {
  _count: AgentCountAggregateOutputType | null
  _avg: AgentAvgAggregateOutputType | null
  _sum: AgentSumAggregateOutputType | null
  _min: AgentMinAggregateOutputType | null
  _max: AgentMaxAggregateOutputType | null
}

export type AgentAvgAggregateOutputType = {
  callLogsCount: number | null
  knowledgeSourcesCount: number | null
  phoneNumbersCount: number | null
  toolsCount: number | null
}

export type AgentSumAggregateOutputType = {
  callLogsCount: number | null
  knowledgeSourcesCount: number | null
  phoneNumbersCount: number | null
  toolsCount: number | null
}

export type AgentMinAggregateOutputType = {
  agentId: string | null
  agentSlug: string | null
  organizationId: string | null
  userId: string | null
  name: string | null
  templateId: string | null
  isActive: boolean | null
  isConfigured: boolean | null
  createdAt: Date | null
  updatedAt: Date | null
  callLogsCount: number | null
  knowledgeSourcesCount: number | null
  phoneNumbersCount: number | null
  toolsCount: number | null
}

export type AgentMaxAggregateOutputType = {
  agentId: string | null
  agentSlug: string | null
  organizationId: string | null
  userId: string | null
  name: string | null
  templateId: string | null
  isActive: boolean | null
  isConfigured: boolean | null
  createdAt: Date | null
  updatedAt: Date | null
  callLogsCount: number | null
  knowledgeSourcesCount: number | null
  phoneNumbersCount: number | null
  toolsCount: number | null
}

export type AgentCountAggregateOutputType = {
  agentId: number
  agentSlug: number
  organizationId: number
  userId: number
  name: number
  templateId: number
  isActive: number
  isConfigured: number
  createdAt: number
  updatedAt: number
  callLogsCount: number
  knowledgeSourcesCount: number
  phoneNumbersCount: number
  toolsCount: number
  _all: number
}


export type AgentAvgAggregateInputType = {
  callLogsCount?: true
  knowledgeSourcesCount?: true
  phoneNumbersCount?: true
  toolsCount?: true
}

export type AgentSumAggregateInputType = {
  callLogsCount?: true
  knowledgeSourcesCount?: true
  phoneNumbersCount?: true
  toolsCount?: true
}

export type AgentMinAggregateInputType = {
  agentId?: true
  agentSlug?: true
  organizationId?: true
  userId?: true
  name?: true
  templateId?: true
  isActive?: true
  isConfigured?: true
  createdAt?: true
  updatedAt?: true
  callLogsCount?: true
  knowledgeSourcesCount?: true
  phoneNumbersCount?: true
  toolsCount?: true
}

export type AgentMaxAggregateInputType = {
  agentId?: true
  agentSlug?: true
  organizationId?: true
  userId?: true
  name?: true
  templateId?: true
  isActive?: true
  isConfigured?: true
  createdAt?: true
  updatedAt?: true
  callLogsCount?: true
  knowledgeSourcesCount?: true
  phoneNumbersCount?: true
  toolsCount?: true
}

export type AgentCountAggregateInputType = {
  agentId?: true
  agentSlug?: true
  organizationId?: true
  userId?: true
  name?: true
  templateId?: true
  isActive?: true
  isConfigured?: true
  createdAt?: true
  updatedAt?: true
  callLogsCount?: true
  knowledgeSourcesCount?: true
  phoneNumbersCount?: true
  toolsCount?: true
  _all?: true
}

export type AgentAggregateArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Filter which Agent to aggregate.
   */
  where?: Prisma.AgentWhereInput
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
   * 
   * Determine the order of Agents to fetch.
   */
  orderBy?: Prisma.AgentOrderByWithRelationInput | Prisma.AgentOrderByWithRelationInput[]
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
   * 
   * Sets the start position
   */
  cursor?: Prisma.AgentWhereUniqueInput
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
   * 
   * Take `±n` Agents 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` Agents.
   */
  skip?: number
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
   * 
   * Count returned Agents
  **/
  _count?: true | AgentCountAggregateInputType
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
   * 
   * Select which fields to average
  **/
  _avg?: AgentAvgAggregateInputType
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
   * 
   * Select which fields to sum
  **/
  _sum?: AgentSumAggregateInputType
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
   * 
   * Select which fields to find the minimum value
  **/
  _min?: AgentMinAggregateInputType
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
   * 
   * Select which fields to find the maximum value
  **/
  _max?: AgentMaxAggregateInputType
}

export type GetAgentAggregateType<T extends AgentAggregateArgs> = {
      [P in keyof T & keyof AggregateAgent]: P extends '_count' | 'count'
    ? T[P] extends true
      ? number
      : Prisma.GetScalarType<T[P], AggregateAgent[P]>
    : Prisma.GetScalarType<T[P], AggregateAgent[P]>
}




export type AgentGroupByArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  where?: Prisma.AgentWhereInput
  orderBy?: Prisma.AgentOrderByWithAggregationInput | Prisma.AgentOrderByWithAggregationInput[]
  by: Prisma.AgentScalarFieldEnum[] | Prisma.AgentScalarFieldEnum
  having?: Prisma.AgentScalarWhereWithAggregatesInput
  take?: number
  skip?: number
  _count?: AgentCountAggregateInputType | true
  _avg?: AgentAvgAggregateInputType
  _sum?: AgentSumAggregateInputType
  _min?: AgentMinAggregateInputType
  _max?: AgentMaxAggregateInputType
}

export type AgentGroupByOutputType = {
  agentId: string
  agentSlug: string
  organizationId: string
  userId: string | null
  name: string
  templateId: string | null
  isActive: boolean
  isConfigured: boolean
  createdAt: Date
  updatedAt: Date
  callLogsCount: number
  knowledgeSourcesCount: number
  phoneNumbersCount: number
  toolsCount: number
  _count: AgentCountAggregateOutputType | null
  _avg: AgentAvgAggregateOutputType | null
  _sum: AgentSumAggregateOutputType | null
  _min: AgentMinAggregateOutputType | null
  _max: AgentMaxAggregateOutputType | null
}

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



export type AgentWhereInput = {
  AND?: Prisma.AgentWhereInput | Prisma.AgentWhereInput[]
  OR?: Prisma.AgentWhereInput[]
  NOT?: Prisma.AgentWhereInput | Prisma.AgentWhereInput[]
  agentId?: Prisma.StringFilter<"Agent"> | string
  agentSlug?: Prisma.StringFilter<"Agent"> | string
  organizationId?: Prisma.StringFilter<"Agent"> | string
  userId?: Prisma.StringNullableFilter<"Agent"> | string | null
  name?: Prisma.StringFilter<"Agent"> | string
  templateId?: Prisma.StringNullableFilter<"Agent"> | string | null
  isActive?: Prisma.BoolFilter<"Agent"> | boolean
  isConfigured?: Prisma.BoolFilter<"Agent"> | boolean
  createdAt?: Prisma.DateTimeFilter<"Agent"> | Date | string
  updatedAt?: Prisma.DateTimeFilter<"Agent"> | Date | string
  callLogsCount?: Prisma.IntFilter<"Agent"> | number
  knowledgeSourcesCount?: Prisma.IntFilter<"Agent"> | number
  phoneNumbersCount?: Prisma.IntFilter<"Agent"> | number
  toolsCount?: Prisma.IntFilter<"Agent"> | number
  organization?: Prisma.XOR<Prisma.OrganizationScalarRelationFilter, Prisma.OrganizationWhereInput>
  user?: Prisma.XOR<Prisma.UserNullableScalarRelationFilter, Prisma.UserWhereInput> | null
  configuration?: Prisma.XOR<Prisma.AgentConfigurationNullableScalarRelationFilter, Prisma.AgentConfigurationWhereInput> | null
  callLogs?: Prisma.CallLogListRelationFilter
  phoneNumbers?: Prisma.PhoneNumberListRelationFilter
  knowledgeSources?: Prisma.KnowledgeSourceListRelationFilter
  outboundCalls?: Prisma.OutboundCallListRelationFilter
  campaigns?: Prisma.CampaignListRelationFilter
  tools?: Prisma.ToolListRelationFilter
  mcpConnections?: Prisma.AgentMcpConnectionListRelationFilter
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogListRelationFilter
}

export type AgentOrderByWithRelationInput = {
  agentId?: Prisma.SortOrder
  agentSlug?: Prisma.SortOrder
  organizationId?: Prisma.SortOrder
  userId?: Prisma.SortOrderInput | Prisma.SortOrder
  name?: Prisma.SortOrder
  templateId?: Prisma.SortOrderInput | Prisma.SortOrder
  isActive?: Prisma.SortOrder
  isConfigured?: Prisma.SortOrder
  createdAt?: Prisma.SortOrder
  updatedAt?: Prisma.SortOrder
  callLogsCount?: Prisma.SortOrder
  knowledgeSourcesCount?: Prisma.SortOrder
  phoneNumbersCount?: Prisma.SortOrder
  toolsCount?: Prisma.SortOrder
  organization?: Prisma.OrganizationOrderByWithRelationInput
  user?: Prisma.UserOrderByWithRelationInput
  configuration?: Prisma.AgentConfigurationOrderByWithRelationInput
  callLogs?: Prisma.CallLogOrderByRelationAggregateInput
  phoneNumbers?: Prisma.PhoneNumberOrderByRelationAggregateInput
  knowledgeSources?: Prisma.KnowledgeSourceOrderByRelationAggregateInput
  outboundCalls?: Prisma.OutboundCallOrderByRelationAggregateInput
  campaigns?: Prisma.CampaignOrderByRelationAggregateInput
  tools?: Prisma.ToolOrderByRelationAggregateInput
  mcpConnections?: Prisma.AgentMcpConnectionOrderByRelationAggregateInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogOrderByRelationAggregateInput
}

export type AgentWhereUniqueInput = Prisma.AtLeast<{
  agentId?: string
  organizationId_agentSlug?: Prisma.AgentOrganizationIdAgentSlugCompoundUniqueInput
  AND?: Prisma.AgentWhereInput | Prisma.AgentWhereInput[]
  OR?: Prisma.AgentWhereInput[]
  NOT?: Prisma.AgentWhereInput | Prisma.AgentWhereInput[]
  agentSlug?: Prisma.StringFilter<"Agent"> | string
  organizationId?: Prisma.StringFilter<"Agent"> | string
  userId?: Prisma.StringNullableFilter<"Agent"> | string | null
  name?: Prisma.StringFilter<"Agent"> | string
  templateId?: Prisma.StringNullableFilter<"Agent"> | string | null
  isActive?: Prisma.BoolFilter<"Agent"> | boolean
  isConfigured?: Prisma.BoolFilter<"Agent"> | boolean
  createdAt?: Prisma.DateTimeFilter<"Agent"> | Date | string
  updatedAt?: Prisma.DateTimeFilter<"Agent"> | Date | string
  callLogsCount?: Prisma.IntFilter<"Agent"> | number
  knowledgeSourcesCount?: Prisma.IntFilter<"Agent"> | number
  phoneNumbersCount?: Prisma.IntFilter<"Agent"> | number
  toolsCount?: Prisma.IntFilter<"Agent"> | number
  organization?: Prisma.XOR<Prisma.OrganizationScalarRelationFilter, Prisma.OrganizationWhereInput>
  user?: Prisma.XOR<Prisma.UserNullableScalarRelationFilter, Prisma.UserWhereInput> | null
  configuration?: Prisma.XOR<Prisma.AgentConfigurationNullableScalarRelationFilter, Prisma.AgentConfigurationWhereInput> | null
  callLogs?: Prisma.CallLogListRelationFilter
  phoneNumbers?: Prisma.PhoneNumberListRelationFilter
  knowledgeSources?: Prisma.KnowledgeSourceListRelationFilter
  outboundCalls?: Prisma.OutboundCallListRelationFilter
  campaigns?: Prisma.CampaignListRelationFilter
  tools?: Prisma.ToolListRelationFilter
  mcpConnections?: Prisma.AgentMcpConnectionListRelationFilter
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogListRelationFilter
}, "agentId" | "organizationId_agentSlug">

export type AgentOrderByWithAggregationInput = {
  agentId?: Prisma.SortOrder
  agentSlug?: Prisma.SortOrder
  organizationId?: Prisma.SortOrder
  userId?: Prisma.SortOrderInput | Prisma.SortOrder
  name?: Prisma.SortOrder
  templateId?: Prisma.SortOrderInput | Prisma.SortOrder
  isActive?: Prisma.SortOrder
  isConfigured?: Prisma.SortOrder
  createdAt?: Prisma.SortOrder
  updatedAt?: Prisma.SortOrder
  callLogsCount?: Prisma.SortOrder
  knowledgeSourcesCount?: Prisma.SortOrder
  phoneNumbersCount?: Prisma.SortOrder
  toolsCount?: Prisma.SortOrder
  _count?: Prisma.AgentCountOrderByAggregateInput
  _avg?: Prisma.AgentAvgOrderByAggregateInput
  _max?: Prisma.AgentMaxOrderByAggregateInput
  _min?: Prisma.AgentMinOrderByAggregateInput
  _sum?: Prisma.AgentSumOrderByAggregateInput
}

export type AgentScalarWhereWithAggregatesInput = {
  AND?: Prisma.AgentScalarWhereWithAggregatesInput | Prisma.AgentScalarWhereWithAggregatesInput[]
  OR?: Prisma.AgentScalarWhereWithAggregatesInput[]
  NOT?: Prisma.AgentScalarWhereWithAggregatesInput | Prisma.AgentScalarWhereWithAggregatesInput[]
  agentId?: Prisma.StringWithAggregatesFilter<"Agent"> | string
  agentSlug?: Prisma.StringWithAggregatesFilter<"Agent"> | string
  organizationId?: Prisma.StringWithAggregatesFilter<"Agent"> | string
  userId?: Prisma.StringNullableWithAggregatesFilter<"Agent"> | string | null
  name?: Prisma.StringWithAggregatesFilter<"Agent"> | string
  templateId?: Prisma.StringNullableWithAggregatesFilter<"Agent"> | string | null
  isActive?: Prisma.BoolWithAggregatesFilter<"Agent"> | boolean
  isConfigured?: Prisma.BoolWithAggregatesFilter<"Agent"> | boolean
  createdAt?: Prisma.DateTimeWithAggregatesFilter<"Agent"> | Date | string
  updatedAt?: Prisma.DateTimeWithAggregatesFilter<"Agent"> | Date | string
  callLogsCount?: Prisma.IntWithAggregatesFilter<"Agent"> | number
  knowledgeSourcesCount?: Prisma.IntWithAggregatesFilter<"Agent"> | number
  phoneNumbersCount?: Prisma.IntWithAggregatesFilter<"Agent"> | number
  toolsCount?: Prisma.IntWithAggregatesFilter<"Agent"> | number
}

export type AgentCreateInput = {
  agentId?: string
  agentSlug: string
  name: string
  templateId?: string | null
  isActive?: boolean
  isConfigured?: boolean
  createdAt?: Date | string
  updatedAt?: Date | string
  callLogsCount?: number
  knowledgeSourcesCount?: number
  phoneNumbersCount?: number
  toolsCount?: number
  organization: Prisma.OrganizationCreateNestedOneWithoutAgentsInput
  user?: Prisma.UserCreateNestedOneWithoutAgentsInput
  configuration?: Prisma.AgentConfigurationCreateNestedOneWithoutAgentInput
  callLogs?: Prisma.CallLogCreateNestedManyWithoutAgentInput
  phoneNumbers?: Prisma.PhoneNumberCreateNestedManyWithoutAgentInput
  knowledgeSources?: Prisma.KnowledgeSourceCreateNestedManyWithoutAgentInput
  outboundCalls?: Prisma.OutboundCallCreateNestedManyWithoutAgentInput
  campaigns?: Prisma.CampaignCreateNestedManyWithoutAgentInput
  tools?: Prisma.ToolCreateNestedManyWithoutAgentInput
  mcpConnections?: Prisma.AgentMcpConnectionCreateNestedManyWithoutAgentInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogCreateNestedManyWithoutAgentInput
}

export type AgentUncheckedCreateInput = {
  agentId?: string
  agentSlug: string
  organizationId: string
  userId?: string | null
  name: string
  templateId?: string | null
  isActive?: boolean
  isConfigured?: boolean
  createdAt?: Date | string
  updatedAt?: Date | string
  callLogsCount?: number
  knowledgeSourcesCount?: number
  phoneNumbersCount?: number
  toolsCount?: number
  configuration?: Prisma.AgentConfigurationUncheckedCreateNestedOneWithoutAgentInput
  callLogs?: Prisma.CallLogUncheckedCreateNestedManyWithoutAgentInput
  phoneNumbers?: Prisma.PhoneNumberUncheckedCreateNestedManyWithoutAgentInput
  knowledgeSources?: Prisma.KnowledgeSourceUncheckedCreateNestedManyWithoutAgentInput
  outboundCalls?: Prisma.OutboundCallUncheckedCreateNestedManyWithoutAgentInput
  campaigns?: Prisma.CampaignUncheckedCreateNestedManyWithoutAgentInput
  tools?: Prisma.ToolUncheckedCreateNestedManyWithoutAgentInput
  mcpConnections?: Prisma.AgentMcpConnectionUncheckedCreateNestedManyWithoutAgentInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogUncheckedCreateNestedManyWithoutAgentInput
}

export type AgentUpdateInput = {
  agentId?: Prisma.StringFieldUpdateOperationsInput | string
  agentSlug?: Prisma.StringFieldUpdateOperationsInput | string
  name?: Prisma.StringFieldUpdateOperationsInput | string
  templateId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
  isConfigured?: Prisma.BoolFieldUpdateOperationsInput | boolean
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  callLogsCount?: Prisma.IntFieldUpdateOperationsInput | number
  knowledgeSourcesCount?: Prisma.IntFieldUpdateOperationsInput | number
  phoneNumbersCount?: Prisma.IntFieldUpdateOperationsInput | number
  toolsCount?: Prisma.IntFieldUpdateOperationsInput | number
  organization?: Prisma.OrganizationUpdateOneRequiredWithoutAgentsNestedInput
  user?: Prisma.UserUpdateOneWithoutAgentsNestedInput
  configuration?: Prisma.AgentConfigurationUpdateOneWithoutAgentNestedInput
  callLogs?: Prisma.CallLogUpdateManyWithoutAgentNestedInput
  phoneNumbers?: Prisma.PhoneNumberUpdateManyWithoutAgentNestedInput
  knowledgeSources?: Prisma.KnowledgeSourceUpdateManyWithoutAgentNestedInput
  outboundCalls?: Prisma.OutboundCallUpdateManyWithoutAgentNestedInput
  campaigns?: Prisma.CampaignUpdateManyWithoutAgentNestedInput
  tools?: Prisma.ToolUpdateManyWithoutAgentNestedInput
  mcpConnections?: Prisma.AgentMcpConnectionUpdateManyWithoutAgentNestedInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogUpdateManyWithoutAgentNestedInput
}

export type AgentUncheckedUpdateInput = {
  agentId?: Prisma.StringFieldUpdateOperationsInput | string
  agentSlug?: Prisma.StringFieldUpdateOperationsInput | string
  organizationId?: Prisma.StringFieldUpdateOperationsInput | string
  userId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  name?: Prisma.StringFieldUpdateOperationsInput | string
  templateId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
  isConfigured?: Prisma.BoolFieldUpdateOperationsInput | boolean
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  callLogsCount?: Prisma.IntFieldUpdateOperationsInput | number
  knowledgeSourcesCount?: Prisma.IntFieldUpdateOperationsInput | number
  phoneNumbersCount?: Prisma.IntFieldUpdateOperationsInput | number
  toolsCount?: Prisma.IntFieldUpdateOperationsInput | number
  configuration?: Prisma.AgentConfigurationUncheckedUpdateOneWithoutAgentNestedInput
  callLogs?: Prisma.CallLogUncheckedUpdateManyWithoutAgentNestedInput
  phoneNumbers?: Prisma.PhoneNumberUncheckedUpdateManyWithoutAgentNestedInput
  knowledgeSources?: Prisma.KnowledgeSourceUncheckedUpdateManyWithoutAgentNestedInput
  outboundCalls?: Prisma.OutboundCallUncheckedUpdateManyWithoutAgentNestedInput
  campaigns?: Prisma.CampaignUncheckedUpdateManyWithoutAgentNestedInput
  tools?: Prisma.ToolUncheckedUpdateManyWithoutAgentNestedInput
  mcpConnections?: Prisma.AgentMcpConnectionUncheckedUpdateManyWithoutAgentNestedInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogUncheckedUpdateManyWithoutAgentNestedInput
}

export type AgentCreateManyInput = {
  agentId?: string
  agentSlug: string
  organizationId: string
  userId?: string | null
  name: string
  templateId?: string | null
  isActive?: boolean
  isConfigured?: boolean
  createdAt?: Date | string
  updatedAt?: Date | string
  callLogsCount?: number
  knowledgeSourcesCount?: number
  phoneNumbersCount?: number
  toolsCount?: number
}

export type AgentUpdateManyMutationInput = {
  agentId?: Prisma.StringFieldUpdateOperationsInput | string
  agentSlug?: Prisma.StringFieldUpdateOperationsInput | string
  name?: Prisma.StringFieldUpdateOperationsInput | string
  templateId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
  isConfigured?: Prisma.BoolFieldUpdateOperationsInput | boolean
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  callLogsCount?: Prisma.IntFieldUpdateOperationsInput | number
  knowledgeSourcesCount?: Prisma.IntFieldUpdateOperationsInput | number
  phoneNumbersCount?: Prisma.IntFieldUpdateOperationsInput | number
  toolsCount?: Prisma.IntFieldUpdateOperationsInput | number
}

export type AgentUncheckedUpdateManyInput = {
  agentId?: Prisma.StringFieldUpdateOperationsInput | string
  agentSlug?: Prisma.StringFieldUpdateOperationsInput | string
  organizationId?: Prisma.StringFieldUpdateOperationsInput | string
  userId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  name?: Prisma.StringFieldUpdateOperationsInput | string
  templateId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
  isConfigured?: Prisma.BoolFieldUpdateOperationsInput | boolean
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  callLogsCount?: Prisma.IntFieldUpdateOperationsInput | number
  knowledgeSourcesCount?: Prisma.IntFieldUpdateOperationsInput | number
  phoneNumbersCount?: Prisma.IntFieldUpdateOperationsInput | number
  toolsCount?: Prisma.IntFieldUpdateOperationsInput | number
}

export type AgentListRelationFilter = {
  every?: Prisma.AgentWhereInput
  some?: Prisma.AgentWhereInput
  none?: Prisma.AgentWhereInput
}

export type AgentOrderByRelationAggregateInput = {
  _count?: Prisma.SortOrder
}

export type AgentNullableScalarRelationFilter = {
  is?: Prisma.AgentWhereInput | null
  isNot?: Prisma.AgentWhereInput | null
}

export type AgentOrganizationIdAgentSlugCompoundUniqueInput = {
  organizationId: string
  agentSlug: string
}

export type AgentCountOrderByAggregateInput = {
  agentId?: Prisma.SortOrder
  agentSlug?: Prisma.SortOrder
  organizationId?: Prisma.SortOrder
  userId?: Prisma.SortOrder
  name?: Prisma.SortOrder
  templateId?: Prisma.SortOrder
  isActive?: Prisma.SortOrder
  isConfigured?: Prisma.SortOrder
  createdAt?: Prisma.SortOrder
  updatedAt?: Prisma.SortOrder
  callLogsCount?: Prisma.SortOrder
  knowledgeSourcesCount?: Prisma.SortOrder
  phoneNumbersCount?: Prisma.SortOrder
  toolsCount?: Prisma.SortOrder
}

export type AgentAvgOrderByAggregateInput = {
  callLogsCount?: Prisma.SortOrder
  knowledgeSourcesCount?: Prisma.SortOrder
  phoneNumbersCount?: Prisma.SortOrder
  toolsCount?: Prisma.SortOrder
}

export type AgentMaxOrderByAggregateInput = {
  agentId?: Prisma.SortOrder
  agentSlug?: Prisma.SortOrder
  organizationId?: Prisma.SortOrder
  userId?: Prisma.SortOrder
  name?: Prisma.SortOrder
  templateId?: Prisma.SortOrder
  isActive?: Prisma.SortOrder
  isConfigured?: Prisma.SortOrder
  createdAt?: Prisma.SortOrder
  updatedAt?: Prisma.SortOrder
  callLogsCount?: Prisma.SortOrder
  knowledgeSourcesCount?: Prisma.SortOrder
  phoneNumbersCount?: Prisma.SortOrder
  toolsCount?: Prisma.SortOrder
}

export type AgentMinOrderByAggregateInput = {
  agentId?: Prisma.SortOrder
  agentSlug?: Prisma.SortOrder
  organizationId?: Prisma.SortOrder
  userId?: Prisma.SortOrder
  name?: Prisma.SortOrder
  templateId?: Prisma.SortOrder
  isActive?: Prisma.SortOrder
  isConfigured?: Prisma.SortOrder
  createdAt?: Prisma.SortOrder
  updatedAt?: Prisma.SortOrder
  callLogsCount?: Prisma.SortOrder
  knowledgeSourcesCount?: Prisma.SortOrder
  phoneNumbersCount?: Prisma.SortOrder
  toolsCount?: Prisma.SortOrder
}

export type AgentSumOrderByAggregateInput = {
  callLogsCount?: Prisma.SortOrder
  knowledgeSourcesCount?: Prisma.SortOrder
  phoneNumbersCount?: Prisma.SortOrder
  toolsCount?: Prisma.SortOrder
}

export type AgentScalarRelationFilter = {
  is?: Prisma.AgentWhereInput
  isNot?: Prisma.AgentWhereInput
}

export type AgentCreateNestedManyWithoutUserInput = {
  create?: Prisma.XOR<Prisma.AgentCreateWithoutUserInput, Prisma.AgentUncheckedCreateWithoutUserInput> | Prisma.AgentCreateWithoutUserInput[] | Prisma.AgentUncheckedCreateWithoutUserInput[]
  connectOrCreate?: Prisma.AgentCreateOrConnectWithoutUserInput | Prisma.AgentCreateOrConnectWithoutUserInput[]
  createMany?: Prisma.AgentCreateManyUserInputEnvelope
  connect?: Prisma.AgentWhereUniqueInput | Prisma.AgentWhereUniqueInput[]
}

export type AgentUncheckedCreateNestedManyWithoutUserInput = {
  create?: Prisma.XOR<Prisma.AgentCreateWithoutUserInput, Prisma.AgentUncheckedCreateWithoutUserInput> | Prisma.AgentCreateWithoutUserInput[] | Prisma.AgentUncheckedCreateWithoutUserInput[]
  connectOrCreate?: Prisma.AgentCreateOrConnectWithoutUserInput | Prisma.AgentCreateOrConnectWithoutUserInput[]
  createMany?: Prisma.AgentCreateManyUserInputEnvelope
  connect?: Prisma.AgentWhereUniqueInput | Prisma.AgentWhereUniqueInput[]
}

export type AgentUpdateManyWithoutUserNestedInput = {
  create?: Prisma.XOR<Prisma.AgentCreateWithoutUserInput, Prisma.AgentUncheckedCreateWithoutUserInput> | Prisma.AgentCreateWithoutUserInput[] | Prisma.AgentUncheckedCreateWithoutUserInput[]
  connectOrCreate?: Prisma.AgentCreateOrConnectWithoutUserInput | Prisma.AgentCreateOrConnectWithoutUserInput[]
  upsert?: Prisma.AgentUpsertWithWhereUniqueWithoutUserInput | Prisma.AgentUpsertWithWhereUniqueWithoutUserInput[]
  createMany?: Prisma.AgentCreateManyUserInputEnvelope
  set?: Prisma.AgentWhereUniqueInput | Prisma.AgentWhereUniqueInput[]
  disconnect?: Prisma.AgentWhereUniqueInput | Prisma.AgentWhereUniqueInput[]
  delete?: Prisma.AgentWhereUniqueInput | Prisma.AgentWhereUniqueInput[]
  connect?: Prisma.AgentWhereUniqueInput | Prisma.AgentWhereUniqueInput[]
  update?: Prisma.AgentUpdateWithWhereUniqueWithoutUserInput | Prisma.AgentUpdateWithWhereUniqueWithoutUserInput[]
  updateMany?: Prisma.AgentUpdateManyWithWhereWithoutUserInput | Prisma.AgentUpdateManyWithWhereWithoutUserInput[]
  deleteMany?: Prisma.AgentScalarWhereInput | Prisma.AgentScalarWhereInput[]
}

export type AgentUncheckedUpdateManyWithoutUserNestedInput = {
  create?: Prisma.XOR<Prisma.AgentCreateWithoutUserInput, Prisma.AgentUncheckedCreateWithoutUserInput> | Prisma.AgentCreateWithoutUserInput[] | Prisma.AgentUncheckedCreateWithoutUserInput[]
  connectOrCreate?: Prisma.AgentCreateOrConnectWithoutUserInput | Prisma.AgentCreateOrConnectWithoutUserInput[]
  upsert?: Prisma.AgentUpsertWithWhereUniqueWithoutUserInput | Prisma.AgentUpsertWithWhereUniqueWithoutUserInput[]
  createMany?: Prisma.AgentCreateManyUserInputEnvelope
  set?: Prisma.AgentWhereUniqueInput | Prisma.AgentWhereUniqueInput[]
  disconnect?: Prisma.AgentWhereUniqueInput | Prisma.AgentWhereUniqueInput[]
  delete?: Prisma.AgentWhereUniqueInput | Prisma.AgentWhereUniqueInput[]
  connect?: Prisma.AgentWhereUniqueInput | Prisma.AgentWhereUniqueInput[]
  update?: Prisma.AgentUpdateWithWhereUniqueWithoutUserInput | Prisma.AgentUpdateWithWhereUniqueWithoutUserInput[]
  updateMany?: Prisma.AgentUpdateManyWithWhereWithoutUserInput | Prisma.AgentUpdateManyWithWhereWithoutUserInput[]
  deleteMany?: Prisma.AgentScalarWhereInput | Prisma.AgentScalarWhereInput[]
}

export type AgentCreateNestedManyWithoutOrganizationInput = {
  create?: Prisma.XOR<Prisma.AgentCreateWithoutOrganizationInput, Prisma.AgentUncheckedCreateWithoutOrganizationInput> | Prisma.AgentCreateWithoutOrganizationInput[] | Prisma.AgentUncheckedCreateWithoutOrganizationInput[]
  connectOrCreate?: Prisma.AgentCreateOrConnectWithoutOrganizationInput | Prisma.AgentCreateOrConnectWithoutOrganizationInput[]
  createMany?: Prisma.AgentCreateManyOrganizationInputEnvelope
  connect?: Prisma.AgentWhereUniqueInput | Prisma.AgentWhereUniqueInput[]
}

export type AgentUncheckedCreateNestedManyWithoutOrganizationInput = {
  create?: Prisma.XOR<Prisma.AgentCreateWithoutOrganizationInput, Prisma.AgentUncheckedCreateWithoutOrganizationInput> | Prisma.AgentCreateWithoutOrganizationInput[] | Prisma.AgentUncheckedCreateWithoutOrganizationInput[]
  connectOrCreate?: Prisma.AgentCreateOrConnectWithoutOrganizationInput | Prisma.AgentCreateOrConnectWithoutOrganizationInput[]
  createMany?: Prisma.AgentCreateManyOrganizationInputEnvelope
  connect?: Prisma.AgentWhereUniqueInput | Prisma.AgentWhereUniqueInput[]
}

export type AgentUpdateManyWithoutOrganizationNestedInput = {
  create?: Prisma.XOR<Prisma.AgentCreateWithoutOrganizationInput, Prisma.AgentUncheckedCreateWithoutOrganizationInput> | Prisma.AgentCreateWithoutOrganizationInput[] | Prisma.AgentUncheckedCreateWithoutOrganizationInput[]
  connectOrCreate?: Prisma.AgentCreateOrConnectWithoutOrganizationInput | Prisma.AgentCreateOrConnectWithoutOrganizationInput[]
  upsert?: Prisma.AgentUpsertWithWhereUniqueWithoutOrganizationInput | Prisma.AgentUpsertWithWhereUniqueWithoutOrganizationInput[]
  createMany?: Prisma.AgentCreateManyOrganizationInputEnvelope
  set?: Prisma.AgentWhereUniqueInput | Prisma.AgentWhereUniqueInput[]
  disconnect?: Prisma.AgentWhereUniqueInput | Prisma.AgentWhereUniqueInput[]
  delete?: Prisma.AgentWhereUniqueInput | Prisma.AgentWhereUniqueInput[]
  connect?: Prisma.AgentWhereUniqueInput | Prisma.AgentWhereUniqueInput[]
  update?: Prisma.AgentUpdateWithWhereUniqueWithoutOrganizationInput | Prisma.AgentUpdateWithWhereUniqueWithoutOrganizationInput[]
  updateMany?: Prisma.AgentUpdateManyWithWhereWithoutOrganizationInput | Prisma.AgentUpdateManyWithWhereWithoutOrganizationInput[]
  deleteMany?: Prisma.AgentScalarWhereInput | Prisma.AgentScalarWhereInput[]
}

export type AgentUncheckedUpdateManyWithoutOrganizationNestedInput = {
  create?: Prisma.XOR<Prisma.AgentCreateWithoutOrganizationInput, Prisma.AgentUncheckedCreateWithoutOrganizationInput> | Prisma.AgentCreateWithoutOrganizationInput[] | Prisma.AgentUncheckedCreateWithoutOrganizationInput[]
  connectOrCreate?: Prisma.AgentCreateOrConnectWithoutOrganizationInput | Prisma.AgentCreateOrConnectWithoutOrganizationInput[]
  upsert?: Prisma.AgentUpsertWithWhereUniqueWithoutOrganizationInput | Prisma.AgentUpsertWithWhereUniqueWithoutOrganizationInput[]
  createMany?: Prisma.AgentCreateManyOrganizationInputEnvelope
  set?: Prisma.AgentWhereUniqueInput | Prisma.AgentWhereUniqueInput[]
  disconnect?: Prisma.AgentWhereUniqueInput | Prisma.AgentWhereUniqueInput[]
  delete?: Prisma.AgentWhereUniqueInput | Prisma.AgentWhereUniqueInput[]
  connect?: Prisma.AgentWhereUniqueInput | Prisma.AgentWhereUniqueInput[]
  update?: Prisma.AgentUpdateWithWhereUniqueWithoutOrganizationInput | Prisma.AgentUpdateWithWhereUniqueWithoutOrganizationInput[]
  updateMany?: Prisma.AgentUpdateManyWithWhereWithoutOrganizationInput | Prisma.AgentUpdateManyWithWhereWithoutOrganizationInput[]
  deleteMany?: Prisma.AgentScalarWhereInput | Prisma.AgentScalarWhereInput[]
}

export type AgentCreateNestedOneWithoutPhoneNumbersInput = {
  create?: Prisma.XOR<Prisma.AgentCreateWithoutPhoneNumbersInput, Prisma.AgentUncheckedCreateWithoutPhoneNumbersInput>
  connectOrCreate?: Prisma.AgentCreateOrConnectWithoutPhoneNumbersInput
  connect?: Prisma.AgentWhereUniqueInput
}

export type AgentUpdateOneWithoutPhoneNumbersNestedInput = {
  create?: Prisma.XOR<Prisma.AgentCreateWithoutPhoneNumbersInput, Prisma.AgentUncheckedCreateWithoutPhoneNumbersInput>
  connectOrCreate?: Prisma.AgentCreateOrConnectWithoutPhoneNumbersInput
  upsert?: Prisma.AgentUpsertWithoutPhoneNumbersInput
  disconnect?: Prisma.AgentWhereInput | boolean
  delete?: Prisma.AgentWhereInput | boolean
  connect?: Prisma.AgentWhereUniqueInput
  update?: Prisma.XOR<Prisma.XOR<Prisma.AgentUpdateToOneWithWhereWithoutPhoneNumbersInput, Prisma.AgentUpdateWithoutPhoneNumbersInput>, Prisma.AgentUncheckedUpdateWithoutPhoneNumbersInput>
}

export type IntFieldUpdateOperationsInput = {
  set?: number
  increment?: number
  decrement?: number
  multiply?: number
  divide?: number
}

export type AgentCreateNestedOneWithoutConfigurationInput = {
  create?: Prisma.XOR<Prisma.AgentCreateWithoutConfigurationInput, Prisma.AgentUncheckedCreateWithoutConfigurationInput>
  connectOrCreate?: Prisma.AgentCreateOrConnectWithoutConfigurationInput
  connect?: Prisma.AgentWhereUniqueInput
}

export type AgentUpdateOneRequiredWithoutConfigurationNestedInput = {
  create?: Prisma.XOR<Prisma.AgentCreateWithoutConfigurationInput, Prisma.AgentUncheckedCreateWithoutConfigurationInput>
  connectOrCreate?: Prisma.AgentCreateOrConnectWithoutConfigurationInput
  upsert?: Prisma.AgentUpsertWithoutConfigurationInput
  connect?: Prisma.AgentWhereUniqueInput
  update?: Prisma.XOR<Prisma.XOR<Prisma.AgentUpdateToOneWithWhereWithoutConfigurationInput, Prisma.AgentUpdateWithoutConfigurationInput>, Prisma.AgentUncheckedUpdateWithoutConfigurationInput>
}

export type AgentCreateNestedOneWithoutKnowledgeSourcesInput = {
  create?: Prisma.XOR<Prisma.AgentCreateWithoutKnowledgeSourcesInput, Prisma.AgentUncheckedCreateWithoutKnowledgeSourcesInput>
  connectOrCreate?: Prisma.AgentCreateOrConnectWithoutKnowledgeSourcesInput
  connect?: Prisma.AgentWhereUniqueInput
}

export type AgentUpdateOneWithoutKnowledgeSourcesNestedInput = {
  create?: Prisma.XOR<Prisma.AgentCreateWithoutKnowledgeSourcesInput, Prisma.AgentUncheckedCreateWithoutKnowledgeSourcesInput>
  connectOrCreate?: Prisma.AgentCreateOrConnectWithoutKnowledgeSourcesInput
  upsert?: Prisma.AgentUpsertWithoutKnowledgeSourcesInput
  disconnect?: Prisma.AgentWhereInput | boolean
  delete?: Prisma.AgentWhereInput | boolean
  connect?: Prisma.AgentWhereUniqueInput
  update?: Prisma.XOR<Prisma.XOR<Prisma.AgentUpdateToOneWithWhereWithoutKnowledgeSourcesInput, Prisma.AgentUpdateWithoutKnowledgeSourcesInput>, Prisma.AgentUncheckedUpdateWithoutKnowledgeSourcesInput>
}

export type AgentCreateNestedOneWithoutCallLogsInput = {
  create?: Prisma.XOR<Prisma.AgentCreateWithoutCallLogsInput, Prisma.AgentUncheckedCreateWithoutCallLogsInput>
  connectOrCreate?: Prisma.AgentCreateOrConnectWithoutCallLogsInput
  connect?: Prisma.AgentWhereUniqueInput
}

export type AgentUpdateOneWithoutCallLogsNestedInput = {
  create?: Prisma.XOR<Prisma.AgentCreateWithoutCallLogsInput, Prisma.AgentUncheckedCreateWithoutCallLogsInput>
  connectOrCreate?: Prisma.AgentCreateOrConnectWithoutCallLogsInput
  upsert?: Prisma.AgentUpsertWithoutCallLogsInput
  disconnect?: Prisma.AgentWhereInput | boolean
  delete?: Prisma.AgentWhereInput | boolean
  connect?: Prisma.AgentWhereUniqueInput
  update?: Prisma.XOR<Prisma.XOR<Prisma.AgentUpdateToOneWithWhereWithoutCallLogsInput, Prisma.AgentUpdateWithoutCallLogsInput>, Prisma.AgentUncheckedUpdateWithoutCallLogsInput>
}

export type AgentCreateNestedOneWithoutOutboundCallsInput = {
  create?: Prisma.XOR<Prisma.AgentCreateWithoutOutboundCallsInput, Prisma.AgentUncheckedCreateWithoutOutboundCallsInput>
  connectOrCreate?: Prisma.AgentCreateOrConnectWithoutOutboundCallsInput
  connect?: Prisma.AgentWhereUniqueInput
}

export type AgentUpdateOneWithoutOutboundCallsNestedInput = {
  create?: Prisma.XOR<Prisma.AgentCreateWithoutOutboundCallsInput, Prisma.AgentUncheckedCreateWithoutOutboundCallsInput>
  connectOrCreate?: Prisma.AgentCreateOrConnectWithoutOutboundCallsInput
  upsert?: Prisma.AgentUpsertWithoutOutboundCallsInput
  disconnect?: Prisma.AgentWhereInput | boolean
  delete?: Prisma.AgentWhereInput | boolean
  connect?: Prisma.AgentWhereUniqueInput
  update?: Prisma.XOR<Prisma.XOR<Prisma.AgentUpdateToOneWithWhereWithoutOutboundCallsInput, Prisma.AgentUpdateWithoutOutboundCallsInput>, Prisma.AgentUncheckedUpdateWithoutOutboundCallsInput>
}

export type AgentCreateNestedOneWithoutCampaignsInput = {
  create?: Prisma.XOR<Prisma.AgentCreateWithoutCampaignsInput, Prisma.AgentUncheckedCreateWithoutCampaignsInput>
  connectOrCreate?: Prisma.AgentCreateOrConnectWithoutCampaignsInput
  connect?: Prisma.AgentWhereUniqueInput
}

export type AgentUpdateOneWithoutCampaignsNestedInput = {
  create?: Prisma.XOR<Prisma.AgentCreateWithoutCampaignsInput, Prisma.AgentUncheckedCreateWithoutCampaignsInput>
  connectOrCreate?: Prisma.AgentCreateOrConnectWithoutCampaignsInput
  upsert?: Prisma.AgentUpsertWithoutCampaignsInput
  disconnect?: Prisma.AgentWhereInput | boolean
  delete?: Prisma.AgentWhereInput | boolean
  connect?: Prisma.AgentWhereUniqueInput
  update?: Prisma.XOR<Prisma.XOR<Prisma.AgentUpdateToOneWithWhereWithoutCampaignsInput, Prisma.AgentUpdateWithoutCampaignsInput>, Prisma.AgentUncheckedUpdateWithoutCampaignsInput>
}

export type AgentCreateNestedManyWithoutToolsInput = {
  create?: Prisma.XOR<Prisma.AgentCreateWithoutToolsInput, Prisma.AgentUncheckedCreateWithoutToolsInput> | Prisma.AgentCreateWithoutToolsInput[] | Prisma.AgentUncheckedCreateWithoutToolsInput[]
  connectOrCreate?: Prisma.AgentCreateOrConnectWithoutToolsInput | Prisma.AgentCreateOrConnectWithoutToolsInput[]
  connect?: Prisma.AgentWhereUniqueInput | Prisma.AgentWhereUniqueInput[]
}

export type AgentUncheckedCreateNestedManyWithoutToolsInput = {
  create?: Prisma.XOR<Prisma.AgentCreateWithoutToolsInput, Prisma.AgentUncheckedCreateWithoutToolsInput> | Prisma.AgentCreateWithoutToolsInput[] | Prisma.AgentUncheckedCreateWithoutToolsInput[]
  connectOrCreate?: Prisma.AgentCreateOrConnectWithoutToolsInput | Prisma.AgentCreateOrConnectWithoutToolsInput[]
  connect?: Prisma.AgentWhereUniqueInput | Prisma.AgentWhereUniqueInput[]
}

export type AgentUpdateManyWithoutToolsNestedInput = {
  create?: Prisma.XOR<Prisma.AgentCreateWithoutToolsInput, Prisma.AgentUncheckedCreateWithoutToolsInput> | Prisma.AgentCreateWithoutToolsInput[] | Prisma.AgentUncheckedCreateWithoutToolsInput[]
  connectOrCreate?: Prisma.AgentCreateOrConnectWithoutToolsInput | Prisma.AgentCreateOrConnectWithoutToolsInput[]
  upsert?: Prisma.AgentUpsertWithWhereUniqueWithoutToolsInput | Prisma.AgentUpsertWithWhereUniqueWithoutToolsInput[]
  set?: Prisma.AgentWhereUniqueInput | Prisma.AgentWhereUniqueInput[]
  disconnect?: Prisma.AgentWhereUniqueInput | Prisma.AgentWhereUniqueInput[]
  delete?: Prisma.AgentWhereUniqueInput | Prisma.AgentWhereUniqueInput[]
  connect?: Prisma.AgentWhereUniqueInput | Prisma.AgentWhereUniqueInput[]
  update?: Prisma.AgentUpdateWithWhereUniqueWithoutToolsInput | Prisma.AgentUpdateWithWhereUniqueWithoutToolsInput[]
  updateMany?: Prisma.AgentUpdateManyWithWhereWithoutToolsInput | Prisma.AgentUpdateManyWithWhereWithoutToolsInput[]
  deleteMany?: Prisma.AgentScalarWhereInput | Prisma.AgentScalarWhereInput[]
}

export type AgentUncheckedUpdateManyWithoutToolsNestedInput = {
  create?: Prisma.XOR<Prisma.AgentCreateWithoutToolsInput, Prisma.AgentUncheckedCreateWithoutToolsInput> | Prisma.AgentCreateWithoutToolsInput[] | Prisma.AgentUncheckedCreateWithoutToolsInput[]
  connectOrCreate?: Prisma.AgentCreateOrConnectWithoutToolsInput | Prisma.AgentCreateOrConnectWithoutToolsInput[]
  upsert?: Prisma.AgentUpsertWithWhereUniqueWithoutToolsInput | Prisma.AgentUpsertWithWhereUniqueWithoutToolsInput[]
  set?: Prisma.AgentWhereUniqueInput | Prisma.AgentWhereUniqueInput[]
  disconnect?: Prisma.AgentWhereUniqueInput | Prisma.AgentWhereUniqueInput[]
  delete?: Prisma.AgentWhereUniqueInput | Prisma.AgentWhereUniqueInput[]
  connect?: Prisma.AgentWhereUniqueInput | Prisma.AgentWhereUniqueInput[]
  update?: Prisma.AgentUpdateWithWhereUniqueWithoutToolsInput | Prisma.AgentUpdateWithWhereUniqueWithoutToolsInput[]
  updateMany?: Prisma.AgentUpdateManyWithWhereWithoutToolsInput | Prisma.AgentUpdateManyWithWhereWithoutToolsInput[]
  deleteMany?: Prisma.AgentScalarWhereInput | Prisma.AgentScalarWhereInput[]
}

export type AgentCreateNestedOneWithoutMcpConnectionsInput = {
  create?: Prisma.XOR<Prisma.AgentCreateWithoutMcpConnectionsInput, Prisma.AgentUncheckedCreateWithoutMcpConnectionsInput>
  connectOrCreate?: Prisma.AgentCreateOrConnectWithoutMcpConnectionsInput
  connect?: Prisma.AgentWhereUniqueInput
}

export type AgentUpdateOneRequiredWithoutMcpConnectionsNestedInput = {
  create?: Prisma.XOR<Prisma.AgentCreateWithoutMcpConnectionsInput, Prisma.AgentUncheckedCreateWithoutMcpConnectionsInput>
  connectOrCreate?: Prisma.AgentCreateOrConnectWithoutMcpConnectionsInput
  upsert?: Prisma.AgentUpsertWithoutMcpConnectionsInput
  connect?: Prisma.AgentWhereUniqueInput
  update?: Prisma.XOR<Prisma.XOR<Prisma.AgentUpdateToOneWithWhereWithoutMcpConnectionsInput, Prisma.AgentUpdateWithoutMcpConnectionsInput>, Prisma.AgentUncheckedUpdateWithoutMcpConnectionsInput>
}

export type AgentCreateNestedOneWithoutMcpToolExecutionLogsInput = {
  create?: Prisma.XOR<Prisma.AgentCreateWithoutMcpToolExecutionLogsInput, Prisma.AgentUncheckedCreateWithoutMcpToolExecutionLogsInput>
  connectOrCreate?: Prisma.AgentCreateOrConnectWithoutMcpToolExecutionLogsInput
  connect?: Prisma.AgentWhereUniqueInput
}

export type AgentUpdateOneWithoutMcpToolExecutionLogsNestedInput = {
  create?: Prisma.XOR<Prisma.AgentCreateWithoutMcpToolExecutionLogsInput, Prisma.AgentUncheckedCreateWithoutMcpToolExecutionLogsInput>
  connectOrCreate?: Prisma.AgentCreateOrConnectWithoutMcpToolExecutionLogsInput
  upsert?: Prisma.AgentUpsertWithoutMcpToolExecutionLogsInput
  disconnect?: Prisma.AgentWhereInput | boolean
  delete?: Prisma.AgentWhereInput | boolean
  connect?: Prisma.AgentWhereUniqueInput
  update?: Prisma.XOR<Prisma.XOR<Prisma.AgentUpdateToOneWithWhereWithoutMcpToolExecutionLogsInput, Prisma.AgentUpdateWithoutMcpToolExecutionLogsInput>, Prisma.AgentUncheckedUpdateWithoutMcpToolExecutionLogsInput>
}

export type AgentCreateWithoutUserInput = {
  agentId?: string
  agentSlug: string
  name: string
  templateId?: string | null
  isActive?: boolean
  isConfigured?: boolean
  createdAt?: Date | string
  updatedAt?: Date | string
  callLogsCount?: number
  knowledgeSourcesCount?: number
  phoneNumbersCount?: number
  toolsCount?: number
  organization: Prisma.OrganizationCreateNestedOneWithoutAgentsInput
  configuration?: Prisma.AgentConfigurationCreateNestedOneWithoutAgentInput
  callLogs?: Prisma.CallLogCreateNestedManyWithoutAgentInput
  phoneNumbers?: Prisma.PhoneNumberCreateNestedManyWithoutAgentInput
  knowledgeSources?: Prisma.KnowledgeSourceCreateNestedManyWithoutAgentInput
  outboundCalls?: Prisma.OutboundCallCreateNestedManyWithoutAgentInput
  campaigns?: Prisma.CampaignCreateNestedManyWithoutAgentInput
  tools?: Prisma.ToolCreateNestedManyWithoutAgentInput
  mcpConnections?: Prisma.AgentMcpConnectionCreateNestedManyWithoutAgentInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogCreateNestedManyWithoutAgentInput
}

export type AgentUncheckedCreateWithoutUserInput = {
  agentId?: string
  agentSlug: string
  organizationId: string
  name: string
  templateId?: string | null
  isActive?: boolean
  isConfigured?: boolean
  createdAt?: Date | string
  updatedAt?: Date | string
  callLogsCount?: number
  knowledgeSourcesCount?: number
  phoneNumbersCount?: number
  toolsCount?: number
  configuration?: Prisma.AgentConfigurationUncheckedCreateNestedOneWithoutAgentInput
  callLogs?: Prisma.CallLogUncheckedCreateNestedManyWithoutAgentInput
  phoneNumbers?: Prisma.PhoneNumberUncheckedCreateNestedManyWithoutAgentInput
  knowledgeSources?: Prisma.KnowledgeSourceUncheckedCreateNestedManyWithoutAgentInput
  outboundCalls?: Prisma.OutboundCallUncheckedCreateNestedManyWithoutAgentInput
  campaigns?: Prisma.CampaignUncheckedCreateNestedManyWithoutAgentInput
  tools?: Prisma.ToolUncheckedCreateNestedManyWithoutAgentInput
  mcpConnections?: Prisma.AgentMcpConnectionUncheckedCreateNestedManyWithoutAgentInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogUncheckedCreateNestedManyWithoutAgentInput
}

export type AgentCreateOrConnectWithoutUserInput = {
  where: Prisma.AgentWhereUniqueInput
  create: Prisma.XOR<Prisma.AgentCreateWithoutUserInput, Prisma.AgentUncheckedCreateWithoutUserInput>
}

export type AgentCreateManyUserInputEnvelope = {
  data: Prisma.AgentCreateManyUserInput | Prisma.AgentCreateManyUserInput[]
  skipDuplicates?: boolean
}

export type AgentUpsertWithWhereUniqueWithoutUserInput = {
  where: Prisma.AgentWhereUniqueInput
  update: Prisma.XOR<Prisma.AgentUpdateWithoutUserInput, Prisma.AgentUncheckedUpdateWithoutUserInput>
  create: Prisma.XOR<Prisma.AgentCreateWithoutUserInput, Prisma.AgentUncheckedCreateWithoutUserInput>
}

export type AgentUpdateWithWhereUniqueWithoutUserInput = {
  where: Prisma.AgentWhereUniqueInput
  data: Prisma.XOR<Prisma.AgentUpdateWithoutUserInput, Prisma.AgentUncheckedUpdateWithoutUserInput>
}

export type AgentUpdateManyWithWhereWithoutUserInput = {
  where: Prisma.AgentScalarWhereInput
  data: Prisma.XOR<Prisma.AgentUpdateManyMutationInput, Prisma.AgentUncheckedUpdateManyWithoutUserInput>
}

export type AgentScalarWhereInput = {
  AND?: Prisma.AgentScalarWhereInput | Prisma.AgentScalarWhereInput[]
  OR?: Prisma.AgentScalarWhereInput[]
  NOT?: Prisma.AgentScalarWhereInput | Prisma.AgentScalarWhereInput[]
  agentId?: Prisma.StringFilter<"Agent"> | string
  agentSlug?: Prisma.StringFilter<"Agent"> | string
  organizationId?: Prisma.StringFilter<"Agent"> | string
  userId?: Prisma.StringNullableFilter<"Agent"> | string | null
  name?: Prisma.StringFilter<"Agent"> | string
  templateId?: Prisma.StringNullableFilter<"Agent"> | string | null
  isActive?: Prisma.BoolFilter<"Agent"> | boolean
  isConfigured?: Prisma.BoolFilter<"Agent"> | boolean
  createdAt?: Prisma.DateTimeFilter<"Agent"> | Date | string
  updatedAt?: Prisma.DateTimeFilter<"Agent"> | Date | string
  callLogsCount?: Prisma.IntFilter<"Agent"> | number
  knowledgeSourcesCount?: Prisma.IntFilter<"Agent"> | number
  phoneNumbersCount?: Prisma.IntFilter<"Agent"> | number
  toolsCount?: Prisma.IntFilter<"Agent"> | number
}

export type AgentCreateWithoutOrganizationInput = {
  agentId?: string
  agentSlug: string
  name: string
  templateId?: string | null
  isActive?: boolean
  isConfigured?: boolean
  createdAt?: Date | string
  updatedAt?: Date | string
  callLogsCount?: number
  knowledgeSourcesCount?: number
  phoneNumbersCount?: number
  toolsCount?: number
  user?: Prisma.UserCreateNestedOneWithoutAgentsInput
  configuration?: Prisma.AgentConfigurationCreateNestedOneWithoutAgentInput
  callLogs?: Prisma.CallLogCreateNestedManyWithoutAgentInput
  phoneNumbers?: Prisma.PhoneNumberCreateNestedManyWithoutAgentInput
  knowledgeSources?: Prisma.KnowledgeSourceCreateNestedManyWithoutAgentInput
  outboundCalls?: Prisma.OutboundCallCreateNestedManyWithoutAgentInput
  campaigns?: Prisma.CampaignCreateNestedManyWithoutAgentInput
  tools?: Prisma.ToolCreateNestedManyWithoutAgentInput
  mcpConnections?: Prisma.AgentMcpConnectionCreateNestedManyWithoutAgentInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogCreateNestedManyWithoutAgentInput
}

export type AgentUncheckedCreateWithoutOrganizationInput = {
  agentId?: string
  agentSlug: string
  userId?: string | null
  name: string
  templateId?: string | null
  isActive?: boolean
  isConfigured?: boolean
  createdAt?: Date | string
  updatedAt?: Date | string
  callLogsCount?: number
  knowledgeSourcesCount?: number
  phoneNumbersCount?: number
  toolsCount?: number
  configuration?: Prisma.AgentConfigurationUncheckedCreateNestedOneWithoutAgentInput
  callLogs?: Prisma.CallLogUncheckedCreateNestedManyWithoutAgentInput
  phoneNumbers?: Prisma.PhoneNumberUncheckedCreateNestedManyWithoutAgentInput
  knowledgeSources?: Prisma.KnowledgeSourceUncheckedCreateNestedManyWithoutAgentInput
  outboundCalls?: Prisma.OutboundCallUncheckedCreateNestedManyWithoutAgentInput
  campaigns?: Prisma.CampaignUncheckedCreateNestedManyWithoutAgentInput
  tools?: Prisma.ToolUncheckedCreateNestedManyWithoutAgentInput
  mcpConnections?: Prisma.AgentMcpConnectionUncheckedCreateNestedManyWithoutAgentInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogUncheckedCreateNestedManyWithoutAgentInput
}

export type AgentCreateOrConnectWithoutOrganizationInput = {
  where: Prisma.AgentWhereUniqueInput
  create: Prisma.XOR<Prisma.AgentCreateWithoutOrganizationInput, Prisma.AgentUncheckedCreateWithoutOrganizationInput>
}

export type AgentCreateManyOrganizationInputEnvelope = {
  data: Prisma.AgentCreateManyOrganizationInput | Prisma.AgentCreateManyOrganizationInput[]
  skipDuplicates?: boolean
}

export type AgentUpsertWithWhereUniqueWithoutOrganizationInput = {
  where: Prisma.AgentWhereUniqueInput
  update: Prisma.XOR<Prisma.AgentUpdateWithoutOrganizationInput, Prisma.AgentUncheckedUpdateWithoutOrganizationInput>
  create: Prisma.XOR<Prisma.AgentCreateWithoutOrganizationInput, Prisma.AgentUncheckedCreateWithoutOrganizationInput>
}

export type AgentUpdateWithWhereUniqueWithoutOrganizationInput = {
  where: Prisma.AgentWhereUniqueInput
  data: Prisma.XOR<Prisma.AgentUpdateWithoutOrganizationInput, Prisma.AgentUncheckedUpdateWithoutOrganizationInput>
}

export type AgentUpdateManyWithWhereWithoutOrganizationInput = {
  where: Prisma.AgentScalarWhereInput
  data: Prisma.XOR<Prisma.AgentUpdateManyMutationInput, Prisma.AgentUncheckedUpdateManyWithoutOrganizationInput>
}

export type AgentCreateWithoutPhoneNumbersInput = {
  agentId?: string
  agentSlug: string
  name: string
  templateId?: string | null
  isActive?: boolean
  isConfigured?: boolean
  createdAt?: Date | string
  updatedAt?: Date | string
  callLogsCount?: number
  knowledgeSourcesCount?: number
  phoneNumbersCount?: number
  toolsCount?: number
  organization: Prisma.OrganizationCreateNestedOneWithoutAgentsInput
  user?: Prisma.UserCreateNestedOneWithoutAgentsInput
  configuration?: Prisma.AgentConfigurationCreateNestedOneWithoutAgentInput
  callLogs?: Prisma.CallLogCreateNestedManyWithoutAgentInput
  knowledgeSources?: Prisma.KnowledgeSourceCreateNestedManyWithoutAgentInput
  outboundCalls?: Prisma.OutboundCallCreateNestedManyWithoutAgentInput
  campaigns?: Prisma.CampaignCreateNestedManyWithoutAgentInput
  tools?: Prisma.ToolCreateNestedManyWithoutAgentInput
  mcpConnections?: Prisma.AgentMcpConnectionCreateNestedManyWithoutAgentInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogCreateNestedManyWithoutAgentInput
}

export type AgentUncheckedCreateWithoutPhoneNumbersInput = {
  agentId?: string
  agentSlug: string
  organizationId: string
  userId?: string | null
  name: string
  templateId?: string | null
  isActive?: boolean
  isConfigured?: boolean
  createdAt?: Date | string
  updatedAt?: Date | string
  callLogsCount?: number
  knowledgeSourcesCount?: number
  phoneNumbersCount?: number
  toolsCount?: number
  configuration?: Prisma.AgentConfigurationUncheckedCreateNestedOneWithoutAgentInput
  callLogs?: Prisma.CallLogUncheckedCreateNestedManyWithoutAgentInput
  knowledgeSources?: Prisma.KnowledgeSourceUncheckedCreateNestedManyWithoutAgentInput
  outboundCalls?: Prisma.OutboundCallUncheckedCreateNestedManyWithoutAgentInput
  campaigns?: Prisma.CampaignUncheckedCreateNestedManyWithoutAgentInput
  tools?: Prisma.ToolUncheckedCreateNestedManyWithoutAgentInput
  mcpConnections?: Prisma.AgentMcpConnectionUncheckedCreateNestedManyWithoutAgentInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogUncheckedCreateNestedManyWithoutAgentInput
}

export type AgentCreateOrConnectWithoutPhoneNumbersInput = {
  where: Prisma.AgentWhereUniqueInput
  create: Prisma.XOR<Prisma.AgentCreateWithoutPhoneNumbersInput, Prisma.AgentUncheckedCreateWithoutPhoneNumbersInput>
}

export type AgentUpsertWithoutPhoneNumbersInput = {
  update: Prisma.XOR<Prisma.AgentUpdateWithoutPhoneNumbersInput, Prisma.AgentUncheckedUpdateWithoutPhoneNumbersInput>
  create: Prisma.XOR<Prisma.AgentCreateWithoutPhoneNumbersInput, Prisma.AgentUncheckedCreateWithoutPhoneNumbersInput>
  where?: Prisma.AgentWhereInput
}

export type AgentUpdateToOneWithWhereWithoutPhoneNumbersInput = {
  where?: Prisma.AgentWhereInput
  data: Prisma.XOR<Prisma.AgentUpdateWithoutPhoneNumbersInput, Prisma.AgentUncheckedUpdateWithoutPhoneNumbersInput>
}

export type AgentUpdateWithoutPhoneNumbersInput = {
  agentId?: Prisma.StringFieldUpdateOperationsInput | string
  agentSlug?: Prisma.StringFieldUpdateOperationsInput | string
  name?: Prisma.StringFieldUpdateOperationsInput | string
  templateId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
  isConfigured?: Prisma.BoolFieldUpdateOperationsInput | boolean
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  callLogsCount?: Prisma.IntFieldUpdateOperationsInput | number
  knowledgeSourcesCount?: Prisma.IntFieldUpdateOperationsInput | number
  phoneNumbersCount?: Prisma.IntFieldUpdateOperationsInput | number
  toolsCount?: Prisma.IntFieldUpdateOperationsInput | number
  organization?: Prisma.OrganizationUpdateOneRequiredWithoutAgentsNestedInput
  user?: Prisma.UserUpdateOneWithoutAgentsNestedInput
  configuration?: Prisma.AgentConfigurationUpdateOneWithoutAgentNestedInput
  callLogs?: Prisma.CallLogUpdateManyWithoutAgentNestedInput
  knowledgeSources?: Prisma.KnowledgeSourceUpdateManyWithoutAgentNestedInput
  outboundCalls?: Prisma.OutboundCallUpdateManyWithoutAgentNestedInput
  campaigns?: Prisma.CampaignUpdateManyWithoutAgentNestedInput
  tools?: Prisma.ToolUpdateManyWithoutAgentNestedInput
  mcpConnections?: Prisma.AgentMcpConnectionUpdateManyWithoutAgentNestedInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogUpdateManyWithoutAgentNestedInput
}

export type AgentUncheckedUpdateWithoutPhoneNumbersInput = {
  agentId?: Prisma.StringFieldUpdateOperationsInput | string
  agentSlug?: Prisma.StringFieldUpdateOperationsInput | string
  organizationId?: Prisma.StringFieldUpdateOperationsInput | string
  userId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  name?: Prisma.StringFieldUpdateOperationsInput | string
  templateId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
  isConfigured?: Prisma.BoolFieldUpdateOperationsInput | boolean
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  callLogsCount?: Prisma.IntFieldUpdateOperationsInput | number
  knowledgeSourcesCount?: Prisma.IntFieldUpdateOperationsInput | number
  phoneNumbersCount?: Prisma.IntFieldUpdateOperationsInput | number
  toolsCount?: Prisma.IntFieldUpdateOperationsInput | number
  configuration?: Prisma.AgentConfigurationUncheckedUpdateOneWithoutAgentNestedInput
  callLogs?: Prisma.CallLogUncheckedUpdateManyWithoutAgentNestedInput
  knowledgeSources?: Prisma.KnowledgeSourceUncheckedUpdateManyWithoutAgentNestedInput
  outboundCalls?: Prisma.OutboundCallUncheckedUpdateManyWithoutAgentNestedInput
  campaigns?: Prisma.CampaignUncheckedUpdateManyWithoutAgentNestedInput
  tools?: Prisma.ToolUncheckedUpdateManyWithoutAgentNestedInput
  mcpConnections?: Prisma.AgentMcpConnectionUncheckedUpdateManyWithoutAgentNestedInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogUncheckedUpdateManyWithoutAgentNestedInput
}

export type AgentCreateWithoutConfigurationInput = {
  agentId?: string
  agentSlug: string
  name: string
  templateId?: string | null
  isActive?: boolean
  isConfigured?: boolean
  createdAt?: Date | string
  updatedAt?: Date | string
  callLogsCount?: number
  knowledgeSourcesCount?: number
  phoneNumbersCount?: number
  toolsCount?: number
  organization: Prisma.OrganizationCreateNestedOneWithoutAgentsInput
  user?: Prisma.UserCreateNestedOneWithoutAgentsInput
  callLogs?: Prisma.CallLogCreateNestedManyWithoutAgentInput
  phoneNumbers?: Prisma.PhoneNumberCreateNestedManyWithoutAgentInput
  knowledgeSources?: Prisma.KnowledgeSourceCreateNestedManyWithoutAgentInput
  outboundCalls?: Prisma.OutboundCallCreateNestedManyWithoutAgentInput
  campaigns?: Prisma.CampaignCreateNestedManyWithoutAgentInput
  tools?: Prisma.ToolCreateNestedManyWithoutAgentInput
  mcpConnections?: Prisma.AgentMcpConnectionCreateNestedManyWithoutAgentInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogCreateNestedManyWithoutAgentInput
}

export type AgentUncheckedCreateWithoutConfigurationInput = {
  agentId?: string
  agentSlug: string
  organizationId: string
  userId?: string | null
  name: string
  templateId?: string | null
  isActive?: boolean
  isConfigured?: boolean
  createdAt?: Date | string
  updatedAt?: Date | string
  callLogsCount?: number
  knowledgeSourcesCount?: number
  phoneNumbersCount?: number
  toolsCount?: number
  callLogs?: Prisma.CallLogUncheckedCreateNestedManyWithoutAgentInput
  phoneNumbers?: Prisma.PhoneNumberUncheckedCreateNestedManyWithoutAgentInput
  knowledgeSources?: Prisma.KnowledgeSourceUncheckedCreateNestedManyWithoutAgentInput
  outboundCalls?: Prisma.OutboundCallUncheckedCreateNestedManyWithoutAgentInput
  campaigns?: Prisma.CampaignUncheckedCreateNestedManyWithoutAgentInput
  tools?: Prisma.ToolUncheckedCreateNestedManyWithoutAgentInput
  mcpConnections?: Prisma.AgentMcpConnectionUncheckedCreateNestedManyWithoutAgentInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogUncheckedCreateNestedManyWithoutAgentInput
}

export type AgentCreateOrConnectWithoutConfigurationInput = {
  where: Prisma.AgentWhereUniqueInput
  create: Prisma.XOR<Prisma.AgentCreateWithoutConfigurationInput, Prisma.AgentUncheckedCreateWithoutConfigurationInput>
}

export type AgentUpsertWithoutConfigurationInput = {
  update: Prisma.XOR<Prisma.AgentUpdateWithoutConfigurationInput, Prisma.AgentUncheckedUpdateWithoutConfigurationInput>
  create: Prisma.XOR<Prisma.AgentCreateWithoutConfigurationInput, Prisma.AgentUncheckedCreateWithoutConfigurationInput>
  where?: Prisma.AgentWhereInput
}

export type AgentUpdateToOneWithWhereWithoutConfigurationInput = {
  where?: Prisma.AgentWhereInput
  data: Prisma.XOR<Prisma.AgentUpdateWithoutConfigurationInput, Prisma.AgentUncheckedUpdateWithoutConfigurationInput>
}

export type AgentUpdateWithoutConfigurationInput = {
  agentId?: Prisma.StringFieldUpdateOperationsInput | string
  agentSlug?: Prisma.StringFieldUpdateOperationsInput | string
  name?: Prisma.StringFieldUpdateOperationsInput | string
  templateId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
  isConfigured?: Prisma.BoolFieldUpdateOperationsInput | boolean
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  callLogsCount?: Prisma.IntFieldUpdateOperationsInput | number
  knowledgeSourcesCount?: Prisma.IntFieldUpdateOperationsInput | number
  phoneNumbersCount?: Prisma.IntFieldUpdateOperationsInput | number
  toolsCount?: Prisma.IntFieldUpdateOperationsInput | number
  organization?: Prisma.OrganizationUpdateOneRequiredWithoutAgentsNestedInput
  user?: Prisma.UserUpdateOneWithoutAgentsNestedInput
  callLogs?: Prisma.CallLogUpdateManyWithoutAgentNestedInput
  phoneNumbers?: Prisma.PhoneNumberUpdateManyWithoutAgentNestedInput
  knowledgeSources?: Prisma.KnowledgeSourceUpdateManyWithoutAgentNestedInput
  outboundCalls?: Prisma.OutboundCallUpdateManyWithoutAgentNestedInput
  campaigns?: Prisma.CampaignUpdateManyWithoutAgentNestedInput
  tools?: Prisma.ToolUpdateManyWithoutAgentNestedInput
  mcpConnections?: Prisma.AgentMcpConnectionUpdateManyWithoutAgentNestedInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogUpdateManyWithoutAgentNestedInput
}

export type AgentUncheckedUpdateWithoutConfigurationInput = {
  agentId?: Prisma.StringFieldUpdateOperationsInput | string
  agentSlug?: Prisma.StringFieldUpdateOperationsInput | string
  organizationId?: Prisma.StringFieldUpdateOperationsInput | string
  userId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  name?: Prisma.StringFieldUpdateOperationsInput | string
  templateId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
  isConfigured?: Prisma.BoolFieldUpdateOperationsInput | boolean
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  callLogsCount?: Prisma.IntFieldUpdateOperationsInput | number
  knowledgeSourcesCount?: Prisma.IntFieldUpdateOperationsInput | number
  phoneNumbersCount?: Prisma.IntFieldUpdateOperationsInput | number
  toolsCount?: Prisma.IntFieldUpdateOperationsInput | number
  callLogs?: Prisma.CallLogUncheckedUpdateManyWithoutAgentNestedInput
  phoneNumbers?: Prisma.PhoneNumberUncheckedUpdateManyWithoutAgentNestedInput
  knowledgeSources?: Prisma.KnowledgeSourceUncheckedUpdateManyWithoutAgentNestedInput
  outboundCalls?: Prisma.OutboundCallUncheckedUpdateManyWithoutAgentNestedInput
  campaigns?: Prisma.CampaignUncheckedUpdateManyWithoutAgentNestedInput
  tools?: Prisma.ToolUncheckedUpdateManyWithoutAgentNestedInput
  mcpConnections?: Prisma.AgentMcpConnectionUncheckedUpdateManyWithoutAgentNestedInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogUncheckedUpdateManyWithoutAgentNestedInput
}

export type AgentCreateWithoutKnowledgeSourcesInput = {
  agentId?: string
  agentSlug: string
  name: string
  templateId?: string | null
  isActive?: boolean
  isConfigured?: boolean
  createdAt?: Date | string
  updatedAt?: Date | string
  callLogsCount?: number
  knowledgeSourcesCount?: number
  phoneNumbersCount?: number
  toolsCount?: number
  organization: Prisma.OrganizationCreateNestedOneWithoutAgentsInput
  user?: Prisma.UserCreateNestedOneWithoutAgentsInput
  configuration?: Prisma.AgentConfigurationCreateNestedOneWithoutAgentInput
  callLogs?: Prisma.CallLogCreateNestedManyWithoutAgentInput
  phoneNumbers?: Prisma.PhoneNumberCreateNestedManyWithoutAgentInput
  outboundCalls?: Prisma.OutboundCallCreateNestedManyWithoutAgentInput
  campaigns?: Prisma.CampaignCreateNestedManyWithoutAgentInput
  tools?: Prisma.ToolCreateNestedManyWithoutAgentInput
  mcpConnections?: Prisma.AgentMcpConnectionCreateNestedManyWithoutAgentInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogCreateNestedManyWithoutAgentInput
}

export type AgentUncheckedCreateWithoutKnowledgeSourcesInput = {
  agentId?: string
  agentSlug: string
  organizationId: string
  userId?: string | null
  name: string
  templateId?: string | null
  isActive?: boolean
  isConfigured?: boolean
  createdAt?: Date | string
  updatedAt?: Date | string
  callLogsCount?: number
  knowledgeSourcesCount?: number
  phoneNumbersCount?: number
  toolsCount?: number
  configuration?: Prisma.AgentConfigurationUncheckedCreateNestedOneWithoutAgentInput
  callLogs?: Prisma.CallLogUncheckedCreateNestedManyWithoutAgentInput
  phoneNumbers?: Prisma.PhoneNumberUncheckedCreateNestedManyWithoutAgentInput
  outboundCalls?: Prisma.OutboundCallUncheckedCreateNestedManyWithoutAgentInput
  campaigns?: Prisma.CampaignUncheckedCreateNestedManyWithoutAgentInput
  tools?: Prisma.ToolUncheckedCreateNestedManyWithoutAgentInput
  mcpConnections?: Prisma.AgentMcpConnectionUncheckedCreateNestedManyWithoutAgentInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogUncheckedCreateNestedManyWithoutAgentInput
}

export type AgentCreateOrConnectWithoutKnowledgeSourcesInput = {
  where: Prisma.AgentWhereUniqueInput
  create: Prisma.XOR<Prisma.AgentCreateWithoutKnowledgeSourcesInput, Prisma.AgentUncheckedCreateWithoutKnowledgeSourcesInput>
}

export type AgentUpsertWithoutKnowledgeSourcesInput = {
  update: Prisma.XOR<Prisma.AgentUpdateWithoutKnowledgeSourcesInput, Prisma.AgentUncheckedUpdateWithoutKnowledgeSourcesInput>
  create: Prisma.XOR<Prisma.AgentCreateWithoutKnowledgeSourcesInput, Prisma.AgentUncheckedCreateWithoutKnowledgeSourcesInput>
  where?: Prisma.AgentWhereInput
}

export type AgentUpdateToOneWithWhereWithoutKnowledgeSourcesInput = {
  where?: Prisma.AgentWhereInput
  data: Prisma.XOR<Prisma.AgentUpdateWithoutKnowledgeSourcesInput, Prisma.AgentUncheckedUpdateWithoutKnowledgeSourcesInput>
}

export type AgentUpdateWithoutKnowledgeSourcesInput = {
  agentId?: Prisma.StringFieldUpdateOperationsInput | string
  agentSlug?: Prisma.StringFieldUpdateOperationsInput | string
  name?: Prisma.StringFieldUpdateOperationsInput | string
  templateId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
  isConfigured?: Prisma.BoolFieldUpdateOperationsInput | boolean
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  callLogsCount?: Prisma.IntFieldUpdateOperationsInput | number
  knowledgeSourcesCount?: Prisma.IntFieldUpdateOperationsInput | number
  phoneNumbersCount?: Prisma.IntFieldUpdateOperationsInput | number
  toolsCount?: Prisma.IntFieldUpdateOperationsInput | number
  organization?: Prisma.OrganizationUpdateOneRequiredWithoutAgentsNestedInput
  user?: Prisma.UserUpdateOneWithoutAgentsNestedInput
  configuration?: Prisma.AgentConfigurationUpdateOneWithoutAgentNestedInput
  callLogs?: Prisma.CallLogUpdateManyWithoutAgentNestedInput
  phoneNumbers?: Prisma.PhoneNumberUpdateManyWithoutAgentNestedInput
  outboundCalls?: Prisma.OutboundCallUpdateManyWithoutAgentNestedInput
  campaigns?: Prisma.CampaignUpdateManyWithoutAgentNestedInput
  tools?: Prisma.ToolUpdateManyWithoutAgentNestedInput
  mcpConnections?: Prisma.AgentMcpConnectionUpdateManyWithoutAgentNestedInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogUpdateManyWithoutAgentNestedInput
}

export type AgentUncheckedUpdateWithoutKnowledgeSourcesInput = {
  agentId?: Prisma.StringFieldUpdateOperationsInput | string
  agentSlug?: Prisma.StringFieldUpdateOperationsInput | string
  organizationId?: Prisma.StringFieldUpdateOperationsInput | string
  userId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  name?: Prisma.StringFieldUpdateOperationsInput | string
  templateId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
  isConfigured?: Prisma.BoolFieldUpdateOperationsInput | boolean
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  callLogsCount?: Prisma.IntFieldUpdateOperationsInput | number
  knowledgeSourcesCount?: Prisma.IntFieldUpdateOperationsInput | number
  phoneNumbersCount?: Prisma.IntFieldUpdateOperationsInput | number
  toolsCount?: Prisma.IntFieldUpdateOperationsInput | number
  configuration?: Prisma.AgentConfigurationUncheckedUpdateOneWithoutAgentNestedInput
  callLogs?: Prisma.CallLogUncheckedUpdateManyWithoutAgentNestedInput
  phoneNumbers?: Prisma.PhoneNumberUncheckedUpdateManyWithoutAgentNestedInput
  outboundCalls?: Prisma.OutboundCallUncheckedUpdateManyWithoutAgentNestedInput
  campaigns?: Prisma.CampaignUncheckedUpdateManyWithoutAgentNestedInput
  tools?: Prisma.ToolUncheckedUpdateManyWithoutAgentNestedInput
  mcpConnections?: Prisma.AgentMcpConnectionUncheckedUpdateManyWithoutAgentNestedInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogUncheckedUpdateManyWithoutAgentNestedInput
}

export type AgentCreateWithoutCallLogsInput = {
  agentId?: string
  agentSlug: string
  name: string
  templateId?: string | null
  isActive?: boolean
  isConfigured?: boolean
  createdAt?: Date | string
  updatedAt?: Date | string
  callLogsCount?: number
  knowledgeSourcesCount?: number
  phoneNumbersCount?: number
  toolsCount?: number
  organization: Prisma.OrganizationCreateNestedOneWithoutAgentsInput
  user?: Prisma.UserCreateNestedOneWithoutAgentsInput
  configuration?: Prisma.AgentConfigurationCreateNestedOneWithoutAgentInput
  phoneNumbers?: Prisma.PhoneNumberCreateNestedManyWithoutAgentInput
  knowledgeSources?: Prisma.KnowledgeSourceCreateNestedManyWithoutAgentInput
  outboundCalls?: Prisma.OutboundCallCreateNestedManyWithoutAgentInput
  campaigns?: Prisma.CampaignCreateNestedManyWithoutAgentInput
  tools?: Prisma.ToolCreateNestedManyWithoutAgentInput
  mcpConnections?: Prisma.AgentMcpConnectionCreateNestedManyWithoutAgentInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogCreateNestedManyWithoutAgentInput
}

export type AgentUncheckedCreateWithoutCallLogsInput = {
  agentId?: string
  agentSlug: string
  organizationId: string
  userId?: string | null
  name: string
  templateId?: string | null
  isActive?: boolean
  isConfigured?: boolean
  createdAt?: Date | string
  updatedAt?: Date | string
  callLogsCount?: number
  knowledgeSourcesCount?: number
  phoneNumbersCount?: number
  toolsCount?: number
  configuration?: Prisma.AgentConfigurationUncheckedCreateNestedOneWithoutAgentInput
  phoneNumbers?: Prisma.PhoneNumberUncheckedCreateNestedManyWithoutAgentInput
  knowledgeSources?: Prisma.KnowledgeSourceUncheckedCreateNestedManyWithoutAgentInput
  outboundCalls?: Prisma.OutboundCallUncheckedCreateNestedManyWithoutAgentInput
  campaigns?: Prisma.CampaignUncheckedCreateNestedManyWithoutAgentInput
  tools?: Prisma.ToolUncheckedCreateNestedManyWithoutAgentInput
  mcpConnections?: Prisma.AgentMcpConnectionUncheckedCreateNestedManyWithoutAgentInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogUncheckedCreateNestedManyWithoutAgentInput
}

export type AgentCreateOrConnectWithoutCallLogsInput = {
  where: Prisma.AgentWhereUniqueInput
  create: Prisma.XOR<Prisma.AgentCreateWithoutCallLogsInput, Prisma.AgentUncheckedCreateWithoutCallLogsInput>
}

export type AgentUpsertWithoutCallLogsInput = {
  update: Prisma.XOR<Prisma.AgentUpdateWithoutCallLogsInput, Prisma.AgentUncheckedUpdateWithoutCallLogsInput>
  create: Prisma.XOR<Prisma.AgentCreateWithoutCallLogsInput, Prisma.AgentUncheckedCreateWithoutCallLogsInput>
  where?: Prisma.AgentWhereInput
}

export type AgentUpdateToOneWithWhereWithoutCallLogsInput = {
  where?: Prisma.AgentWhereInput
  data: Prisma.XOR<Prisma.AgentUpdateWithoutCallLogsInput, Prisma.AgentUncheckedUpdateWithoutCallLogsInput>
}

export type AgentUpdateWithoutCallLogsInput = {
  agentId?: Prisma.StringFieldUpdateOperationsInput | string
  agentSlug?: Prisma.StringFieldUpdateOperationsInput | string
  name?: Prisma.StringFieldUpdateOperationsInput | string
  templateId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
  isConfigured?: Prisma.BoolFieldUpdateOperationsInput | boolean
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  callLogsCount?: Prisma.IntFieldUpdateOperationsInput | number
  knowledgeSourcesCount?: Prisma.IntFieldUpdateOperationsInput | number
  phoneNumbersCount?: Prisma.IntFieldUpdateOperationsInput | number
  toolsCount?: Prisma.IntFieldUpdateOperationsInput | number
  organization?: Prisma.OrganizationUpdateOneRequiredWithoutAgentsNestedInput
  user?: Prisma.UserUpdateOneWithoutAgentsNestedInput
  configuration?: Prisma.AgentConfigurationUpdateOneWithoutAgentNestedInput
  phoneNumbers?: Prisma.PhoneNumberUpdateManyWithoutAgentNestedInput
  knowledgeSources?: Prisma.KnowledgeSourceUpdateManyWithoutAgentNestedInput
  outboundCalls?: Prisma.OutboundCallUpdateManyWithoutAgentNestedInput
  campaigns?: Prisma.CampaignUpdateManyWithoutAgentNestedInput
  tools?: Prisma.ToolUpdateManyWithoutAgentNestedInput
  mcpConnections?: Prisma.AgentMcpConnectionUpdateManyWithoutAgentNestedInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogUpdateManyWithoutAgentNestedInput
}

export type AgentUncheckedUpdateWithoutCallLogsInput = {
  agentId?: Prisma.StringFieldUpdateOperationsInput | string
  agentSlug?: Prisma.StringFieldUpdateOperationsInput | string
  organizationId?: Prisma.StringFieldUpdateOperationsInput | string
  userId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  name?: Prisma.StringFieldUpdateOperationsInput | string
  templateId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
  isConfigured?: Prisma.BoolFieldUpdateOperationsInput | boolean
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  callLogsCount?: Prisma.IntFieldUpdateOperationsInput | number
  knowledgeSourcesCount?: Prisma.IntFieldUpdateOperationsInput | number
  phoneNumbersCount?: Prisma.IntFieldUpdateOperationsInput | number
  toolsCount?: Prisma.IntFieldUpdateOperationsInput | number
  configuration?: Prisma.AgentConfigurationUncheckedUpdateOneWithoutAgentNestedInput
  phoneNumbers?: Prisma.PhoneNumberUncheckedUpdateManyWithoutAgentNestedInput
  knowledgeSources?: Prisma.KnowledgeSourceUncheckedUpdateManyWithoutAgentNestedInput
  outboundCalls?: Prisma.OutboundCallUncheckedUpdateManyWithoutAgentNestedInput
  campaigns?: Prisma.CampaignUncheckedUpdateManyWithoutAgentNestedInput
  tools?: Prisma.ToolUncheckedUpdateManyWithoutAgentNestedInput
  mcpConnections?: Prisma.AgentMcpConnectionUncheckedUpdateManyWithoutAgentNestedInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogUncheckedUpdateManyWithoutAgentNestedInput
}

export type AgentCreateWithoutOutboundCallsInput = {
  agentId?: string
  agentSlug: string
  name: string
  templateId?: string | null
  isActive?: boolean
  isConfigured?: boolean
  createdAt?: Date | string
  updatedAt?: Date | string
  callLogsCount?: number
  knowledgeSourcesCount?: number
  phoneNumbersCount?: number
  toolsCount?: number
  organization: Prisma.OrganizationCreateNestedOneWithoutAgentsInput
  user?: Prisma.UserCreateNestedOneWithoutAgentsInput
  configuration?: Prisma.AgentConfigurationCreateNestedOneWithoutAgentInput
  callLogs?: Prisma.CallLogCreateNestedManyWithoutAgentInput
  phoneNumbers?: Prisma.PhoneNumberCreateNestedManyWithoutAgentInput
  knowledgeSources?: Prisma.KnowledgeSourceCreateNestedManyWithoutAgentInput
  campaigns?: Prisma.CampaignCreateNestedManyWithoutAgentInput
  tools?: Prisma.ToolCreateNestedManyWithoutAgentInput
  mcpConnections?: Prisma.AgentMcpConnectionCreateNestedManyWithoutAgentInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogCreateNestedManyWithoutAgentInput
}

export type AgentUncheckedCreateWithoutOutboundCallsInput = {
  agentId?: string
  agentSlug: string
  organizationId: string
  userId?: string | null
  name: string
  templateId?: string | null
  isActive?: boolean
  isConfigured?: boolean
  createdAt?: Date | string
  updatedAt?: Date | string
  callLogsCount?: number
  knowledgeSourcesCount?: number
  phoneNumbersCount?: number
  toolsCount?: number
  configuration?: Prisma.AgentConfigurationUncheckedCreateNestedOneWithoutAgentInput
  callLogs?: Prisma.CallLogUncheckedCreateNestedManyWithoutAgentInput
  phoneNumbers?: Prisma.PhoneNumberUncheckedCreateNestedManyWithoutAgentInput
  knowledgeSources?: Prisma.KnowledgeSourceUncheckedCreateNestedManyWithoutAgentInput
  campaigns?: Prisma.CampaignUncheckedCreateNestedManyWithoutAgentInput
  tools?: Prisma.ToolUncheckedCreateNestedManyWithoutAgentInput
  mcpConnections?: Prisma.AgentMcpConnectionUncheckedCreateNestedManyWithoutAgentInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogUncheckedCreateNestedManyWithoutAgentInput
}

export type AgentCreateOrConnectWithoutOutboundCallsInput = {
  where: Prisma.AgentWhereUniqueInput
  create: Prisma.XOR<Prisma.AgentCreateWithoutOutboundCallsInput, Prisma.AgentUncheckedCreateWithoutOutboundCallsInput>
}

export type AgentUpsertWithoutOutboundCallsInput = {
  update: Prisma.XOR<Prisma.AgentUpdateWithoutOutboundCallsInput, Prisma.AgentUncheckedUpdateWithoutOutboundCallsInput>
  create: Prisma.XOR<Prisma.AgentCreateWithoutOutboundCallsInput, Prisma.AgentUncheckedCreateWithoutOutboundCallsInput>
  where?: Prisma.AgentWhereInput
}

export type AgentUpdateToOneWithWhereWithoutOutboundCallsInput = {
  where?: Prisma.AgentWhereInput
  data: Prisma.XOR<Prisma.AgentUpdateWithoutOutboundCallsInput, Prisma.AgentUncheckedUpdateWithoutOutboundCallsInput>
}

export type AgentUpdateWithoutOutboundCallsInput = {
  agentId?: Prisma.StringFieldUpdateOperationsInput | string
  agentSlug?: Prisma.StringFieldUpdateOperationsInput | string
  name?: Prisma.StringFieldUpdateOperationsInput | string
  templateId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
  isConfigured?: Prisma.BoolFieldUpdateOperationsInput | boolean
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  callLogsCount?: Prisma.IntFieldUpdateOperationsInput | number
  knowledgeSourcesCount?: Prisma.IntFieldUpdateOperationsInput | number
  phoneNumbersCount?: Prisma.IntFieldUpdateOperationsInput | number
  toolsCount?: Prisma.IntFieldUpdateOperationsInput | number
  organization?: Prisma.OrganizationUpdateOneRequiredWithoutAgentsNestedInput
  user?: Prisma.UserUpdateOneWithoutAgentsNestedInput
  configuration?: Prisma.AgentConfigurationUpdateOneWithoutAgentNestedInput
  callLogs?: Prisma.CallLogUpdateManyWithoutAgentNestedInput
  phoneNumbers?: Prisma.PhoneNumberUpdateManyWithoutAgentNestedInput
  knowledgeSources?: Prisma.KnowledgeSourceUpdateManyWithoutAgentNestedInput
  campaigns?: Prisma.CampaignUpdateManyWithoutAgentNestedInput
  tools?: Prisma.ToolUpdateManyWithoutAgentNestedInput
  mcpConnections?: Prisma.AgentMcpConnectionUpdateManyWithoutAgentNestedInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogUpdateManyWithoutAgentNestedInput
}

export type AgentUncheckedUpdateWithoutOutboundCallsInput = {
  agentId?: Prisma.StringFieldUpdateOperationsInput | string
  agentSlug?: Prisma.StringFieldUpdateOperationsInput | string
  organizationId?: Prisma.StringFieldUpdateOperationsInput | string
  userId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  name?: Prisma.StringFieldUpdateOperationsInput | string
  templateId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
  isConfigured?: Prisma.BoolFieldUpdateOperationsInput | boolean
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  callLogsCount?: Prisma.IntFieldUpdateOperationsInput | number
  knowledgeSourcesCount?: Prisma.IntFieldUpdateOperationsInput | number
  phoneNumbersCount?: Prisma.IntFieldUpdateOperationsInput | number
  toolsCount?: Prisma.IntFieldUpdateOperationsInput | number
  configuration?: Prisma.AgentConfigurationUncheckedUpdateOneWithoutAgentNestedInput
  callLogs?: Prisma.CallLogUncheckedUpdateManyWithoutAgentNestedInput
  phoneNumbers?: Prisma.PhoneNumberUncheckedUpdateManyWithoutAgentNestedInput
  knowledgeSources?: Prisma.KnowledgeSourceUncheckedUpdateManyWithoutAgentNestedInput
  campaigns?: Prisma.CampaignUncheckedUpdateManyWithoutAgentNestedInput
  tools?: Prisma.ToolUncheckedUpdateManyWithoutAgentNestedInput
  mcpConnections?: Prisma.AgentMcpConnectionUncheckedUpdateManyWithoutAgentNestedInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogUncheckedUpdateManyWithoutAgentNestedInput
}

export type AgentCreateWithoutCampaignsInput = {
  agentId?: string
  agentSlug: string
  name: string
  templateId?: string | null
  isActive?: boolean
  isConfigured?: boolean
  createdAt?: Date | string
  updatedAt?: Date | string
  callLogsCount?: number
  knowledgeSourcesCount?: number
  phoneNumbersCount?: number
  toolsCount?: number
  organization: Prisma.OrganizationCreateNestedOneWithoutAgentsInput
  user?: Prisma.UserCreateNestedOneWithoutAgentsInput
  configuration?: Prisma.AgentConfigurationCreateNestedOneWithoutAgentInput
  callLogs?: Prisma.CallLogCreateNestedManyWithoutAgentInput
  phoneNumbers?: Prisma.PhoneNumberCreateNestedManyWithoutAgentInput
  knowledgeSources?: Prisma.KnowledgeSourceCreateNestedManyWithoutAgentInput
  outboundCalls?: Prisma.OutboundCallCreateNestedManyWithoutAgentInput
  tools?: Prisma.ToolCreateNestedManyWithoutAgentInput
  mcpConnections?: Prisma.AgentMcpConnectionCreateNestedManyWithoutAgentInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogCreateNestedManyWithoutAgentInput
}

export type AgentUncheckedCreateWithoutCampaignsInput = {
  agentId?: string
  agentSlug: string
  organizationId: string
  userId?: string | null
  name: string
  templateId?: string | null
  isActive?: boolean
  isConfigured?: boolean
  createdAt?: Date | string
  updatedAt?: Date | string
  callLogsCount?: number
  knowledgeSourcesCount?: number
  phoneNumbersCount?: number
  toolsCount?: number
  configuration?: Prisma.AgentConfigurationUncheckedCreateNestedOneWithoutAgentInput
  callLogs?: Prisma.CallLogUncheckedCreateNestedManyWithoutAgentInput
  phoneNumbers?: Prisma.PhoneNumberUncheckedCreateNestedManyWithoutAgentInput
  knowledgeSources?: Prisma.KnowledgeSourceUncheckedCreateNestedManyWithoutAgentInput
  outboundCalls?: Prisma.OutboundCallUncheckedCreateNestedManyWithoutAgentInput
  tools?: Prisma.ToolUncheckedCreateNestedManyWithoutAgentInput
  mcpConnections?: Prisma.AgentMcpConnectionUncheckedCreateNestedManyWithoutAgentInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogUncheckedCreateNestedManyWithoutAgentInput
}

export type AgentCreateOrConnectWithoutCampaignsInput = {
  where: Prisma.AgentWhereUniqueInput
  create: Prisma.XOR<Prisma.AgentCreateWithoutCampaignsInput, Prisma.AgentUncheckedCreateWithoutCampaignsInput>
}

export type AgentUpsertWithoutCampaignsInput = {
  update: Prisma.XOR<Prisma.AgentUpdateWithoutCampaignsInput, Prisma.AgentUncheckedUpdateWithoutCampaignsInput>
  create: Prisma.XOR<Prisma.AgentCreateWithoutCampaignsInput, Prisma.AgentUncheckedCreateWithoutCampaignsInput>
  where?: Prisma.AgentWhereInput
}

export type AgentUpdateToOneWithWhereWithoutCampaignsInput = {
  where?: Prisma.AgentWhereInput
  data: Prisma.XOR<Prisma.AgentUpdateWithoutCampaignsInput, Prisma.AgentUncheckedUpdateWithoutCampaignsInput>
}

export type AgentUpdateWithoutCampaignsInput = {
  agentId?: Prisma.StringFieldUpdateOperationsInput | string
  agentSlug?: Prisma.StringFieldUpdateOperationsInput | string
  name?: Prisma.StringFieldUpdateOperationsInput | string
  templateId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
  isConfigured?: Prisma.BoolFieldUpdateOperationsInput | boolean
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  callLogsCount?: Prisma.IntFieldUpdateOperationsInput | number
  knowledgeSourcesCount?: Prisma.IntFieldUpdateOperationsInput | number
  phoneNumbersCount?: Prisma.IntFieldUpdateOperationsInput | number
  toolsCount?: Prisma.IntFieldUpdateOperationsInput | number
  organization?: Prisma.OrganizationUpdateOneRequiredWithoutAgentsNestedInput
  user?: Prisma.UserUpdateOneWithoutAgentsNestedInput
  configuration?: Prisma.AgentConfigurationUpdateOneWithoutAgentNestedInput
  callLogs?: Prisma.CallLogUpdateManyWithoutAgentNestedInput
  phoneNumbers?: Prisma.PhoneNumberUpdateManyWithoutAgentNestedInput
  knowledgeSources?: Prisma.KnowledgeSourceUpdateManyWithoutAgentNestedInput
  outboundCalls?: Prisma.OutboundCallUpdateManyWithoutAgentNestedInput
  tools?: Prisma.ToolUpdateManyWithoutAgentNestedInput
  mcpConnections?: Prisma.AgentMcpConnectionUpdateManyWithoutAgentNestedInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogUpdateManyWithoutAgentNestedInput
}

export type AgentUncheckedUpdateWithoutCampaignsInput = {
  agentId?: Prisma.StringFieldUpdateOperationsInput | string
  agentSlug?: Prisma.StringFieldUpdateOperationsInput | string
  organizationId?: Prisma.StringFieldUpdateOperationsInput | string
  userId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  name?: Prisma.StringFieldUpdateOperationsInput | string
  templateId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
  isConfigured?: Prisma.BoolFieldUpdateOperationsInput | boolean
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  callLogsCount?: Prisma.IntFieldUpdateOperationsInput | number
  knowledgeSourcesCount?: Prisma.IntFieldUpdateOperationsInput | number
  phoneNumbersCount?: Prisma.IntFieldUpdateOperationsInput | number
  toolsCount?: Prisma.IntFieldUpdateOperationsInput | number
  configuration?: Prisma.AgentConfigurationUncheckedUpdateOneWithoutAgentNestedInput
  callLogs?: Prisma.CallLogUncheckedUpdateManyWithoutAgentNestedInput
  phoneNumbers?: Prisma.PhoneNumberUncheckedUpdateManyWithoutAgentNestedInput
  knowledgeSources?: Prisma.KnowledgeSourceUncheckedUpdateManyWithoutAgentNestedInput
  outboundCalls?: Prisma.OutboundCallUncheckedUpdateManyWithoutAgentNestedInput
  tools?: Prisma.ToolUncheckedUpdateManyWithoutAgentNestedInput
  mcpConnections?: Prisma.AgentMcpConnectionUncheckedUpdateManyWithoutAgentNestedInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogUncheckedUpdateManyWithoutAgentNestedInput
}

export type AgentCreateWithoutToolsInput = {
  agentId?: string
  agentSlug: string
  name: string
  templateId?: string | null
  isActive?: boolean
  isConfigured?: boolean
  createdAt?: Date | string
  updatedAt?: Date | string
  callLogsCount?: number
  knowledgeSourcesCount?: number
  phoneNumbersCount?: number
  toolsCount?: number
  organization: Prisma.OrganizationCreateNestedOneWithoutAgentsInput
  user?: Prisma.UserCreateNestedOneWithoutAgentsInput
  configuration?: Prisma.AgentConfigurationCreateNestedOneWithoutAgentInput
  callLogs?: Prisma.CallLogCreateNestedManyWithoutAgentInput
  phoneNumbers?: Prisma.PhoneNumberCreateNestedManyWithoutAgentInput
  knowledgeSources?: Prisma.KnowledgeSourceCreateNestedManyWithoutAgentInput
  outboundCalls?: Prisma.OutboundCallCreateNestedManyWithoutAgentInput
  campaigns?: Prisma.CampaignCreateNestedManyWithoutAgentInput
  mcpConnections?: Prisma.AgentMcpConnectionCreateNestedManyWithoutAgentInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogCreateNestedManyWithoutAgentInput
}

export type AgentUncheckedCreateWithoutToolsInput = {
  agentId?: string
  agentSlug: string
  organizationId: string
  userId?: string | null
  name: string
  templateId?: string | null
  isActive?: boolean
  isConfigured?: boolean
  createdAt?: Date | string
  updatedAt?: Date | string
  callLogsCount?: number
  knowledgeSourcesCount?: number
  phoneNumbersCount?: number
  toolsCount?: number
  configuration?: Prisma.AgentConfigurationUncheckedCreateNestedOneWithoutAgentInput
  callLogs?: Prisma.CallLogUncheckedCreateNestedManyWithoutAgentInput
  phoneNumbers?: Prisma.PhoneNumberUncheckedCreateNestedManyWithoutAgentInput
  knowledgeSources?: Prisma.KnowledgeSourceUncheckedCreateNestedManyWithoutAgentInput
  outboundCalls?: Prisma.OutboundCallUncheckedCreateNestedManyWithoutAgentInput
  campaigns?: Prisma.CampaignUncheckedCreateNestedManyWithoutAgentInput
  mcpConnections?: Prisma.AgentMcpConnectionUncheckedCreateNestedManyWithoutAgentInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogUncheckedCreateNestedManyWithoutAgentInput
}

export type AgentCreateOrConnectWithoutToolsInput = {
  where: Prisma.AgentWhereUniqueInput
  create: Prisma.XOR<Prisma.AgentCreateWithoutToolsInput, Prisma.AgentUncheckedCreateWithoutToolsInput>
}

export type AgentUpsertWithWhereUniqueWithoutToolsInput = {
  where: Prisma.AgentWhereUniqueInput
  update: Prisma.XOR<Prisma.AgentUpdateWithoutToolsInput, Prisma.AgentUncheckedUpdateWithoutToolsInput>
  create: Prisma.XOR<Prisma.AgentCreateWithoutToolsInput, Prisma.AgentUncheckedCreateWithoutToolsInput>
}

export type AgentUpdateWithWhereUniqueWithoutToolsInput = {
  where: Prisma.AgentWhereUniqueInput
  data: Prisma.XOR<Prisma.AgentUpdateWithoutToolsInput, Prisma.AgentUncheckedUpdateWithoutToolsInput>
}

export type AgentUpdateManyWithWhereWithoutToolsInput = {
  where: Prisma.AgentScalarWhereInput
  data: Prisma.XOR<Prisma.AgentUpdateManyMutationInput, Prisma.AgentUncheckedUpdateManyWithoutToolsInput>
}

export type AgentCreateWithoutMcpConnectionsInput = {
  agentId?: string
  agentSlug: string
  name: string
  templateId?: string | null
  isActive?: boolean
  isConfigured?: boolean
  createdAt?: Date | string
  updatedAt?: Date | string
  callLogsCount?: number
  knowledgeSourcesCount?: number
  phoneNumbersCount?: number
  toolsCount?: number
  organization: Prisma.OrganizationCreateNestedOneWithoutAgentsInput
  user?: Prisma.UserCreateNestedOneWithoutAgentsInput
  configuration?: Prisma.AgentConfigurationCreateNestedOneWithoutAgentInput
  callLogs?: Prisma.CallLogCreateNestedManyWithoutAgentInput
  phoneNumbers?: Prisma.PhoneNumberCreateNestedManyWithoutAgentInput
  knowledgeSources?: Prisma.KnowledgeSourceCreateNestedManyWithoutAgentInput
  outboundCalls?: Prisma.OutboundCallCreateNestedManyWithoutAgentInput
  campaigns?: Prisma.CampaignCreateNestedManyWithoutAgentInput
  tools?: Prisma.ToolCreateNestedManyWithoutAgentInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogCreateNestedManyWithoutAgentInput
}

export type AgentUncheckedCreateWithoutMcpConnectionsInput = {
  agentId?: string
  agentSlug: string
  organizationId: string
  userId?: string | null
  name: string
  templateId?: string | null
  isActive?: boolean
  isConfigured?: boolean
  createdAt?: Date | string
  updatedAt?: Date | string
  callLogsCount?: number
  knowledgeSourcesCount?: number
  phoneNumbersCount?: number
  toolsCount?: number
  configuration?: Prisma.AgentConfigurationUncheckedCreateNestedOneWithoutAgentInput
  callLogs?: Prisma.CallLogUncheckedCreateNestedManyWithoutAgentInput
  phoneNumbers?: Prisma.PhoneNumberUncheckedCreateNestedManyWithoutAgentInput
  knowledgeSources?: Prisma.KnowledgeSourceUncheckedCreateNestedManyWithoutAgentInput
  outboundCalls?: Prisma.OutboundCallUncheckedCreateNestedManyWithoutAgentInput
  campaigns?: Prisma.CampaignUncheckedCreateNestedManyWithoutAgentInput
  tools?: Prisma.ToolUncheckedCreateNestedManyWithoutAgentInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogUncheckedCreateNestedManyWithoutAgentInput
}

export type AgentCreateOrConnectWithoutMcpConnectionsInput = {
  where: Prisma.AgentWhereUniqueInput
  create: Prisma.XOR<Prisma.AgentCreateWithoutMcpConnectionsInput, Prisma.AgentUncheckedCreateWithoutMcpConnectionsInput>
}

export type AgentUpsertWithoutMcpConnectionsInput = {
  update: Prisma.XOR<Prisma.AgentUpdateWithoutMcpConnectionsInput, Prisma.AgentUncheckedUpdateWithoutMcpConnectionsInput>
  create: Prisma.XOR<Prisma.AgentCreateWithoutMcpConnectionsInput, Prisma.AgentUncheckedCreateWithoutMcpConnectionsInput>
  where?: Prisma.AgentWhereInput
}

export type AgentUpdateToOneWithWhereWithoutMcpConnectionsInput = {
  where?: Prisma.AgentWhereInput
  data: Prisma.XOR<Prisma.AgentUpdateWithoutMcpConnectionsInput, Prisma.AgentUncheckedUpdateWithoutMcpConnectionsInput>
}

export type AgentUpdateWithoutMcpConnectionsInput = {
  agentId?: Prisma.StringFieldUpdateOperationsInput | string
  agentSlug?: Prisma.StringFieldUpdateOperationsInput | string
  name?: Prisma.StringFieldUpdateOperationsInput | string
  templateId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
  isConfigured?: Prisma.BoolFieldUpdateOperationsInput | boolean
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  callLogsCount?: Prisma.IntFieldUpdateOperationsInput | number
  knowledgeSourcesCount?: Prisma.IntFieldUpdateOperationsInput | number
  phoneNumbersCount?: Prisma.IntFieldUpdateOperationsInput | number
  toolsCount?: Prisma.IntFieldUpdateOperationsInput | number
  organization?: Prisma.OrganizationUpdateOneRequiredWithoutAgentsNestedInput
  user?: Prisma.UserUpdateOneWithoutAgentsNestedInput
  configuration?: Prisma.AgentConfigurationUpdateOneWithoutAgentNestedInput
  callLogs?: Prisma.CallLogUpdateManyWithoutAgentNestedInput
  phoneNumbers?: Prisma.PhoneNumberUpdateManyWithoutAgentNestedInput
  knowledgeSources?: Prisma.KnowledgeSourceUpdateManyWithoutAgentNestedInput
  outboundCalls?: Prisma.OutboundCallUpdateManyWithoutAgentNestedInput
  campaigns?: Prisma.CampaignUpdateManyWithoutAgentNestedInput
  tools?: Prisma.ToolUpdateManyWithoutAgentNestedInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogUpdateManyWithoutAgentNestedInput
}

export type AgentUncheckedUpdateWithoutMcpConnectionsInput = {
  agentId?: Prisma.StringFieldUpdateOperationsInput | string
  agentSlug?: Prisma.StringFieldUpdateOperationsInput | string
  organizationId?: Prisma.StringFieldUpdateOperationsInput | string
  userId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  name?: Prisma.StringFieldUpdateOperationsInput | string
  templateId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
  isConfigured?: Prisma.BoolFieldUpdateOperationsInput | boolean
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  callLogsCount?: Prisma.IntFieldUpdateOperationsInput | number
  knowledgeSourcesCount?: Prisma.IntFieldUpdateOperationsInput | number
  phoneNumbersCount?: Prisma.IntFieldUpdateOperationsInput | number
  toolsCount?: Prisma.IntFieldUpdateOperationsInput | number
  configuration?: Prisma.AgentConfigurationUncheckedUpdateOneWithoutAgentNestedInput
  callLogs?: Prisma.CallLogUncheckedUpdateManyWithoutAgentNestedInput
  phoneNumbers?: Prisma.PhoneNumberUncheckedUpdateManyWithoutAgentNestedInput
  knowledgeSources?: Prisma.KnowledgeSourceUncheckedUpdateManyWithoutAgentNestedInput
  outboundCalls?: Prisma.OutboundCallUncheckedUpdateManyWithoutAgentNestedInput
  campaigns?: Prisma.CampaignUncheckedUpdateManyWithoutAgentNestedInput
  tools?: Prisma.ToolUncheckedUpdateManyWithoutAgentNestedInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogUncheckedUpdateManyWithoutAgentNestedInput
}

export type AgentCreateWithoutMcpToolExecutionLogsInput = {
  agentId?: string
  agentSlug: string
  name: string
  templateId?: string | null
  isActive?: boolean
  isConfigured?: boolean
  createdAt?: Date | string
  updatedAt?: Date | string
  callLogsCount?: number
  knowledgeSourcesCount?: number
  phoneNumbersCount?: number
  toolsCount?: number
  organization: Prisma.OrganizationCreateNestedOneWithoutAgentsInput
  user?: Prisma.UserCreateNestedOneWithoutAgentsInput
  configuration?: Prisma.AgentConfigurationCreateNestedOneWithoutAgentInput
  callLogs?: Prisma.CallLogCreateNestedManyWithoutAgentInput
  phoneNumbers?: Prisma.PhoneNumberCreateNestedManyWithoutAgentInput
  knowledgeSources?: Prisma.KnowledgeSourceCreateNestedManyWithoutAgentInput
  outboundCalls?: Prisma.OutboundCallCreateNestedManyWithoutAgentInput
  campaigns?: Prisma.CampaignCreateNestedManyWithoutAgentInput
  tools?: Prisma.ToolCreateNestedManyWithoutAgentInput
  mcpConnections?: Prisma.AgentMcpConnectionCreateNestedManyWithoutAgentInput
}

export type AgentUncheckedCreateWithoutMcpToolExecutionLogsInput = {
  agentId?: string
  agentSlug: string
  organizationId: string
  userId?: string | null
  name: string
  templateId?: string | null
  isActive?: boolean
  isConfigured?: boolean
  createdAt?: Date | string
  updatedAt?: Date | string
  callLogsCount?: number
  knowledgeSourcesCount?: number
  phoneNumbersCount?: number
  toolsCount?: number
  configuration?: Prisma.AgentConfigurationUncheckedCreateNestedOneWithoutAgentInput
  callLogs?: Prisma.CallLogUncheckedCreateNestedManyWithoutAgentInput
  phoneNumbers?: Prisma.PhoneNumberUncheckedCreateNestedManyWithoutAgentInput
  knowledgeSources?: Prisma.KnowledgeSourceUncheckedCreateNestedManyWithoutAgentInput
  outboundCalls?: Prisma.OutboundCallUncheckedCreateNestedManyWithoutAgentInput
  campaigns?: Prisma.CampaignUncheckedCreateNestedManyWithoutAgentInput
  tools?: Prisma.ToolUncheckedCreateNestedManyWithoutAgentInput
  mcpConnections?: Prisma.AgentMcpConnectionUncheckedCreateNestedManyWithoutAgentInput
}

export type AgentCreateOrConnectWithoutMcpToolExecutionLogsInput = {
  where: Prisma.AgentWhereUniqueInput
  create: Prisma.XOR<Prisma.AgentCreateWithoutMcpToolExecutionLogsInput, Prisma.AgentUncheckedCreateWithoutMcpToolExecutionLogsInput>
}

export type AgentUpsertWithoutMcpToolExecutionLogsInput = {
  update: Prisma.XOR<Prisma.AgentUpdateWithoutMcpToolExecutionLogsInput, Prisma.AgentUncheckedUpdateWithoutMcpToolExecutionLogsInput>
  create: Prisma.XOR<Prisma.AgentCreateWithoutMcpToolExecutionLogsInput, Prisma.AgentUncheckedCreateWithoutMcpToolExecutionLogsInput>
  where?: Prisma.AgentWhereInput
}

export type AgentUpdateToOneWithWhereWithoutMcpToolExecutionLogsInput = {
  where?: Prisma.AgentWhereInput
  data: Prisma.XOR<Prisma.AgentUpdateWithoutMcpToolExecutionLogsInput, Prisma.AgentUncheckedUpdateWithoutMcpToolExecutionLogsInput>
}

export type AgentUpdateWithoutMcpToolExecutionLogsInput = {
  agentId?: Prisma.StringFieldUpdateOperationsInput | string
  agentSlug?: Prisma.StringFieldUpdateOperationsInput | string
  name?: Prisma.StringFieldUpdateOperationsInput | string
  templateId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
  isConfigured?: Prisma.BoolFieldUpdateOperationsInput | boolean
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  callLogsCount?: Prisma.IntFieldUpdateOperationsInput | number
  knowledgeSourcesCount?: Prisma.IntFieldUpdateOperationsInput | number
  phoneNumbersCount?: Prisma.IntFieldUpdateOperationsInput | number
  toolsCount?: Prisma.IntFieldUpdateOperationsInput | number
  organization?: Prisma.OrganizationUpdateOneRequiredWithoutAgentsNestedInput
  user?: Prisma.UserUpdateOneWithoutAgentsNestedInput
  configuration?: Prisma.AgentConfigurationUpdateOneWithoutAgentNestedInput
  callLogs?: Prisma.CallLogUpdateManyWithoutAgentNestedInput
  phoneNumbers?: Prisma.PhoneNumberUpdateManyWithoutAgentNestedInput
  knowledgeSources?: Prisma.KnowledgeSourceUpdateManyWithoutAgentNestedInput
  outboundCalls?: Prisma.OutboundCallUpdateManyWithoutAgentNestedInput
  campaigns?: Prisma.CampaignUpdateManyWithoutAgentNestedInput
  tools?: Prisma.ToolUpdateManyWithoutAgentNestedInput
  mcpConnections?: Prisma.AgentMcpConnectionUpdateManyWithoutAgentNestedInput
}

export type AgentUncheckedUpdateWithoutMcpToolExecutionLogsInput = {
  agentId?: Prisma.StringFieldUpdateOperationsInput | string
  agentSlug?: Prisma.StringFieldUpdateOperationsInput | string
  organizationId?: Prisma.StringFieldUpdateOperationsInput | string
  userId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  name?: Prisma.StringFieldUpdateOperationsInput | string
  templateId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
  isConfigured?: Prisma.BoolFieldUpdateOperationsInput | boolean
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  callLogsCount?: Prisma.IntFieldUpdateOperationsInput | number
  knowledgeSourcesCount?: Prisma.IntFieldUpdateOperationsInput | number
  phoneNumbersCount?: Prisma.IntFieldUpdateOperationsInput | number
  toolsCount?: Prisma.IntFieldUpdateOperationsInput | number
  configuration?: Prisma.AgentConfigurationUncheckedUpdateOneWithoutAgentNestedInput
  callLogs?: Prisma.CallLogUncheckedUpdateManyWithoutAgentNestedInput
  phoneNumbers?: Prisma.PhoneNumberUncheckedUpdateManyWithoutAgentNestedInput
  knowledgeSources?: Prisma.KnowledgeSourceUncheckedUpdateManyWithoutAgentNestedInput
  outboundCalls?: Prisma.OutboundCallUncheckedUpdateManyWithoutAgentNestedInput
  campaigns?: Prisma.CampaignUncheckedUpdateManyWithoutAgentNestedInput
  tools?: Prisma.ToolUncheckedUpdateManyWithoutAgentNestedInput
  mcpConnections?: Prisma.AgentMcpConnectionUncheckedUpdateManyWithoutAgentNestedInput
}

export type AgentCreateManyUserInput = {
  agentId?: string
  agentSlug: string
  organizationId: string
  name: string
  templateId?: string | null
  isActive?: boolean
  isConfigured?: boolean
  createdAt?: Date | string
  updatedAt?: Date | string
  callLogsCount?: number
  knowledgeSourcesCount?: number
  phoneNumbersCount?: number
  toolsCount?: number
}

export type AgentUpdateWithoutUserInput = {
  agentId?: Prisma.StringFieldUpdateOperationsInput | string
  agentSlug?: Prisma.StringFieldUpdateOperationsInput | string
  name?: Prisma.StringFieldUpdateOperationsInput | string
  templateId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
  isConfigured?: Prisma.BoolFieldUpdateOperationsInput | boolean
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  callLogsCount?: Prisma.IntFieldUpdateOperationsInput | number
  knowledgeSourcesCount?: Prisma.IntFieldUpdateOperationsInput | number
  phoneNumbersCount?: Prisma.IntFieldUpdateOperationsInput | number
  toolsCount?: Prisma.IntFieldUpdateOperationsInput | number
  organization?: Prisma.OrganizationUpdateOneRequiredWithoutAgentsNestedInput
  configuration?: Prisma.AgentConfigurationUpdateOneWithoutAgentNestedInput
  callLogs?: Prisma.CallLogUpdateManyWithoutAgentNestedInput
  phoneNumbers?: Prisma.PhoneNumberUpdateManyWithoutAgentNestedInput
  knowledgeSources?: Prisma.KnowledgeSourceUpdateManyWithoutAgentNestedInput
  outboundCalls?: Prisma.OutboundCallUpdateManyWithoutAgentNestedInput
  campaigns?: Prisma.CampaignUpdateManyWithoutAgentNestedInput
  tools?: Prisma.ToolUpdateManyWithoutAgentNestedInput
  mcpConnections?: Prisma.AgentMcpConnectionUpdateManyWithoutAgentNestedInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogUpdateManyWithoutAgentNestedInput
}

export type AgentUncheckedUpdateWithoutUserInput = {
  agentId?: Prisma.StringFieldUpdateOperationsInput | string
  agentSlug?: Prisma.StringFieldUpdateOperationsInput | string
  organizationId?: Prisma.StringFieldUpdateOperationsInput | string
  name?: Prisma.StringFieldUpdateOperationsInput | string
  templateId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
  isConfigured?: Prisma.BoolFieldUpdateOperationsInput | boolean
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  callLogsCount?: Prisma.IntFieldUpdateOperationsInput | number
  knowledgeSourcesCount?: Prisma.IntFieldUpdateOperationsInput | number
  phoneNumbersCount?: Prisma.IntFieldUpdateOperationsInput | number
  toolsCount?: Prisma.IntFieldUpdateOperationsInput | number
  configuration?: Prisma.AgentConfigurationUncheckedUpdateOneWithoutAgentNestedInput
  callLogs?: Prisma.CallLogUncheckedUpdateManyWithoutAgentNestedInput
  phoneNumbers?: Prisma.PhoneNumberUncheckedUpdateManyWithoutAgentNestedInput
  knowledgeSources?: Prisma.KnowledgeSourceUncheckedUpdateManyWithoutAgentNestedInput
  outboundCalls?: Prisma.OutboundCallUncheckedUpdateManyWithoutAgentNestedInput
  campaigns?: Prisma.CampaignUncheckedUpdateManyWithoutAgentNestedInput
  tools?: Prisma.ToolUncheckedUpdateManyWithoutAgentNestedInput
  mcpConnections?: Prisma.AgentMcpConnectionUncheckedUpdateManyWithoutAgentNestedInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogUncheckedUpdateManyWithoutAgentNestedInput
}

export type AgentUncheckedUpdateManyWithoutUserInput = {
  agentId?: Prisma.StringFieldUpdateOperationsInput | string
  agentSlug?: Prisma.StringFieldUpdateOperationsInput | string
  organizationId?: Prisma.StringFieldUpdateOperationsInput | string
  name?: Prisma.StringFieldUpdateOperationsInput | string
  templateId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
  isConfigured?: Prisma.BoolFieldUpdateOperationsInput | boolean
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  callLogsCount?: Prisma.IntFieldUpdateOperationsInput | number
  knowledgeSourcesCount?: Prisma.IntFieldUpdateOperationsInput | number
  phoneNumbersCount?: Prisma.IntFieldUpdateOperationsInput | number
  toolsCount?: Prisma.IntFieldUpdateOperationsInput | number
}

export type AgentCreateManyOrganizationInput = {
  agentId?: string
  agentSlug: string
  userId?: string | null
  name: string
  templateId?: string | null
  isActive?: boolean
  isConfigured?: boolean
  createdAt?: Date | string
  updatedAt?: Date | string
  callLogsCount?: number
  knowledgeSourcesCount?: number
  phoneNumbersCount?: number
  toolsCount?: number
}

export type AgentUpdateWithoutOrganizationInput = {
  agentId?: Prisma.StringFieldUpdateOperationsInput | string
  agentSlug?: Prisma.StringFieldUpdateOperationsInput | string
  name?: Prisma.StringFieldUpdateOperationsInput | string
  templateId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
  isConfigured?: Prisma.BoolFieldUpdateOperationsInput | boolean
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  callLogsCount?: Prisma.IntFieldUpdateOperationsInput | number
  knowledgeSourcesCount?: Prisma.IntFieldUpdateOperationsInput | number
  phoneNumbersCount?: Prisma.IntFieldUpdateOperationsInput | number
  toolsCount?: Prisma.IntFieldUpdateOperationsInput | number
  user?: Prisma.UserUpdateOneWithoutAgentsNestedInput
  configuration?: Prisma.AgentConfigurationUpdateOneWithoutAgentNestedInput
  callLogs?: Prisma.CallLogUpdateManyWithoutAgentNestedInput
  phoneNumbers?: Prisma.PhoneNumberUpdateManyWithoutAgentNestedInput
  knowledgeSources?: Prisma.KnowledgeSourceUpdateManyWithoutAgentNestedInput
  outboundCalls?: Prisma.OutboundCallUpdateManyWithoutAgentNestedInput
  campaigns?: Prisma.CampaignUpdateManyWithoutAgentNestedInput
  tools?: Prisma.ToolUpdateManyWithoutAgentNestedInput
  mcpConnections?: Prisma.AgentMcpConnectionUpdateManyWithoutAgentNestedInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogUpdateManyWithoutAgentNestedInput
}

export type AgentUncheckedUpdateWithoutOrganizationInput = {
  agentId?: Prisma.StringFieldUpdateOperationsInput | string
  agentSlug?: Prisma.StringFieldUpdateOperationsInput | string
  userId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  name?: Prisma.StringFieldUpdateOperationsInput | string
  templateId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
  isConfigured?: Prisma.BoolFieldUpdateOperationsInput | boolean
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  callLogsCount?: Prisma.IntFieldUpdateOperationsInput | number
  knowledgeSourcesCount?: Prisma.IntFieldUpdateOperationsInput | number
  phoneNumbersCount?: Prisma.IntFieldUpdateOperationsInput | number
  toolsCount?: Prisma.IntFieldUpdateOperationsInput | number
  configuration?: Prisma.AgentConfigurationUncheckedUpdateOneWithoutAgentNestedInput
  callLogs?: Prisma.CallLogUncheckedUpdateManyWithoutAgentNestedInput
  phoneNumbers?: Prisma.PhoneNumberUncheckedUpdateManyWithoutAgentNestedInput
  knowledgeSources?: Prisma.KnowledgeSourceUncheckedUpdateManyWithoutAgentNestedInput
  outboundCalls?: Prisma.OutboundCallUncheckedUpdateManyWithoutAgentNestedInput
  campaigns?: Prisma.CampaignUncheckedUpdateManyWithoutAgentNestedInput
  tools?: Prisma.ToolUncheckedUpdateManyWithoutAgentNestedInput
  mcpConnections?: Prisma.AgentMcpConnectionUncheckedUpdateManyWithoutAgentNestedInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogUncheckedUpdateManyWithoutAgentNestedInput
}

export type AgentUncheckedUpdateManyWithoutOrganizationInput = {
  agentId?: Prisma.StringFieldUpdateOperationsInput | string
  agentSlug?: Prisma.StringFieldUpdateOperationsInput | string
  userId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  name?: Prisma.StringFieldUpdateOperationsInput | string
  templateId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
  isConfigured?: Prisma.BoolFieldUpdateOperationsInput | boolean
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  callLogsCount?: Prisma.IntFieldUpdateOperationsInput | number
  knowledgeSourcesCount?: Prisma.IntFieldUpdateOperationsInput | number
  phoneNumbersCount?: Prisma.IntFieldUpdateOperationsInput | number
  toolsCount?: Prisma.IntFieldUpdateOperationsInput | number
}

export type AgentUpdateWithoutToolsInput = {
  agentId?: Prisma.StringFieldUpdateOperationsInput | string
  agentSlug?: Prisma.StringFieldUpdateOperationsInput | string
  name?: Prisma.StringFieldUpdateOperationsInput | string
  templateId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
  isConfigured?: Prisma.BoolFieldUpdateOperationsInput | boolean
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  callLogsCount?: Prisma.IntFieldUpdateOperationsInput | number
  knowledgeSourcesCount?: Prisma.IntFieldUpdateOperationsInput | number
  phoneNumbersCount?: Prisma.IntFieldUpdateOperationsInput | number
  toolsCount?: Prisma.IntFieldUpdateOperationsInput | number
  organization?: Prisma.OrganizationUpdateOneRequiredWithoutAgentsNestedInput
  user?: Prisma.UserUpdateOneWithoutAgentsNestedInput
  configuration?: Prisma.AgentConfigurationUpdateOneWithoutAgentNestedInput
  callLogs?: Prisma.CallLogUpdateManyWithoutAgentNestedInput
  phoneNumbers?: Prisma.PhoneNumberUpdateManyWithoutAgentNestedInput
  knowledgeSources?: Prisma.KnowledgeSourceUpdateManyWithoutAgentNestedInput
  outboundCalls?: Prisma.OutboundCallUpdateManyWithoutAgentNestedInput
  campaigns?: Prisma.CampaignUpdateManyWithoutAgentNestedInput
  mcpConnections?: Prisma.AgentMcpConnectionUpdateManyWithoutAgentNestedInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogUpdateManyWithoutAgentNestedInput
}

export type AgentUncheckedUpdateWithoutToolsInput = {
  agentId?: Prisma.StringFieldUpdateOperationsInput | string
  agentSlug?: Prisma.StringFieldUpdateOperationsInput | string
  organizationId?: Prisma.StringFieldUpdateOperationsInput | string
  userId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  name?: Prisma.StringFieldUpdateOperationsInput | string
  templateId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
  isConfigured?: Prisma.BoolFieldUpdateOperationsInput | boolean
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  callLogsCount?: Prisma.IntFieldUpdateOperationsInput | number
  knowledgeSourcesCount?: Prisma.IntFieldUpdateOperationsInput | number
  phoneNumbersCount?: Prisma.IntFieldUpdateOperationsInput | number
  toolsCount?: Prisma.IntFieldUpdateOperationsInput | number
  configuration?: Prisma.AgentConfigurationUncheckedUpdateOneWithoutAgentNestedInput
  callLogs?: Prisma.CallLogUncheckedUpdateManyWithoutAgentNestedInput
  phoneNumbers?: Prisma.PhoneNumberUncheckedUpdateManyWithoutAgentNestedInput
  knowledgeSources?: Prisma.KnowledgeSourceUncheckedUpdateManyWithoutAgentNestedInput
  outboundCalls?: Prisma.OutboundCallUncheckedUpdateManyWithoutAgentNestedInput
  campaigns?: Prisma.CampaignUncheckedUpdateManyWithoutAgentNestedInput
  mcpConnections?: Prisma.AgentMcpConnectionUncheckedUpdateManyWithoutAgentNestedInput
  mcpToolExecutionLogs?: Prisma.McpToolExecutionLogUncheckedUpdateManyWithoutAgentNestedInput
}

export type AgentUncheckedUpdateManyWithoutToolsInput = {
  agentId?: Prisma.StringFieldUpdateOperationsInput | string
  agentSlug?: Prisma.StringFieldUpdateOperationsInput | string
  organizationId?: Prisma.StringFieldUpdateOperationsInput | string
  userId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  name?: Prisma.StringFieldUpdateOperationsInput | string
  templateId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
  isActive?: Prisma.BoolFieldUpdateOperationsInput | boolean
  isConfigured?: Prisma.BoolFieldUpdateOperationsInput | boolean
  createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
  callLogsCount?: Prisma.IntFieldUpdateOperationsInput | number
  knowledgeSourcesCount?: Prisma.IntFieldUpdateOperationsInput | number
  phoneNumbersCount?: Prisma.IntFieldUpdateOperationsInput | number
  toolsCount?: Prisma.IntFieldUpdateOperationsInput | number
}


/**
 * Count Type AgentCountOutputType
 */

export type AgentCountOutputType = {
  callLogs: number
  phoneNumbers: number
  knowledgeSources: number
  outboundCalls: number
  campaigns: number
  tools: number
  mcpConnections: number
  mcpToolExecutionLogs: number
}

export type AgentCountOutputTypeSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  callLogs?: boolean | AgentCountOutputTypeCountCallLogsArgs
  phoneNumbers?: boolean | AgentCountOutputTypeCountPhoneNumbersArgs
  knowledgeSources?: boolean | AgentCountOutputTypeCountKnowledgeSourcesArgs
  outboundCalls?: boolean | AgentCountOutputTypeCountOutboundCallsArgs
  campaigns?: boolean | AgentCountOutputTypeCountCampaignsArgs
  tools?: boolean | AgentCountOutputTypeCountToolsArgs
  mcpConnections?: boolean | AgentCountOutputTypeCountMcpConnectionsArgs
  mcpToolExecutionLogs?: boolean | AgentCountOutputTypeCountMcpToolExecutionLogsArgs
}

/**
 * AgentCountOutputType without action
 */
export type AgentCountOutputTypeDefaultArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the AgentCountOutputType
   */
  select?: Prisma.AgentCountOutputTypeSelect<ExtArgs> | null
}

/**
 * AgentCountOutputType without action
 */
export type AgentCountOutputTypeCountCallLogsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  where?: Prisma.CallLogWhereInput
}

/**
 * AgentCountOutputType without action
 */
export type AgentCountOutputTypeCountPhoneNumbersArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  where?: Prisma.PhoneNumberWhereInput
}

/**
 * AgentCountOutputType without action
 */
export type AgentCountOutputTypeCountKnowledgeSourcesArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  where?: Prisma.KnowledgeSourceWhereInput
}

/**
 * AgentCountOutputType without action
 */
export type AgentCountOutputTypeCountOutboundCallsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  where?: Prisma.OutboundCallWhereInput
}

/**
 * AgentCountOutputType without action
 */
export type AgentCountOutputTypeCountCampaignsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  where?: Prisma.CampaignWhereInput
}

/**
 * AgentCountOutputType without action
 */
export type AgentCountOutputTypeCountToolsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  where?: Prisma.ToolWhereInput
}

/**
 * AgentCountOutputType without action
 */
export type AgentCountOutputTypeCountMcpConnectionsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  where?: Prisma.AgentMcpConnectionWhereInput
}

/**
 * AgentCountOutputType without action
 */
export type AgentCountOutputTypeCountMcpToolExecutionLogsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  where?: Prisma.McpToolExecutionLogWhereInput
}


export type AgentSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{
  agentId?: boolean
  agentSlug?: boolean
  organizationId?: boolean
  userId?: boolean
  name?: boolean
  templateId?: boolean
  isActive?: boolean
  isConfigured?: boolean
  createdAt?: boolean
  updatedAt?: boolean
  callLogsCount?: boolean
  knowledgeSourcesCount?: boolean
  phoneNumbersCount?: boolean
  toolsCount?: boolean
  organization?: boolean | Prisma.OrganizationDefaultArgs<ExtArgs>
  user?: boolean | Prisma.Agent$userArgs<ExtArgs>
  configuration?: boolean | Prisma.Agent$configurationArgs<ExtArgs>
  callLogs?: boolean | Prisma.Agent$callLogsArgs<ExtArgs>
  phoneNumbers?: boolean | Prisma.Agent$phoneNumbersArgs<ExtArgs>
  knowledgeSources?: boolean | Prisma.Agent$knowledgeSourcesArgs<ExtArgs>
  outboundCalls?: boolean | Prisma.Agent$outboundCallsArgs<ExtArgs>
  campaigns?: boolean | Prisma.Agent$campaignsArgs<ExtArgs>
  tools?: boolean | Prisma.Agent$toolsArgs<ExtArgs>
  mcpConnections?: boolean | Prisma.Agent$mcpConnectionsArgs<ExtArgs>
  mcpToolExecutionLogs?: boolean | Prisma.Agent$mcpToolExecutionLogsArgs<ExtArgs>
  _count?: boolean | Prisma.AgentCountOutputTypeDefaultArgs<ExtArgs>
}, ExtArgs["result"]["agent"]>

export type AgentSelectCreateManyAndReturn<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{
  agentId?: boolean
  agentSlug?: boolean
  organizationId?: boolean
  userId?: boolean
  name?: boolean
  templateId?: boolean
  isActive?: boolean
  isConfigured?: boolean
  createdAt?: boolean
  updatedAt?: boolean
  callLogsCount?: boolean
  knowledgeSourcesCount?: boolean
  phoneNumbersCount?: boolean
  toolsCount?: boolean
  organization?: boolean | Prisma.OrganizationDefaultArgs<ExtArgs>
  user?: boolean | Prisma.Agent$userArgs<ExtArgs>
}, ExtArgs["result"]["agent"]>

export type AgentSelectUpdateManyAndReturn<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{
  agentId?: boolean
  agentSlug?: boolean
  organizationId?: boolean
  userId?: boolean
  name?: boolean
  templateId?: boolean
  isActive?: boolean
  isConfigured?: boolean
  createdAt?: boolean
  updatedAt?: boolean
  callLogsCount?: boolean
  knowledgeSourcesCount?: boolean
  phoneNumbersCount?: boolean
  toolsCount?: boolean
  organization?: boolean | Prisma.OrganizationDefaultArgs<ExtArgs>
  user?: boolean | Prisma.Agent$userArgs<ExtArgs>
}, ExtArgs["result"]["agent"]>

export type AgentSelectScalar = {
  agentId?: boolean
  agentSlug?: boolean
  organizationId?: boolean
  userId?: boolean
  name?: boolean
  templateId?: boolean
  isActive?: boolean
  isConfigured?: boolean
  createdAt?: boolean
  updatedAt?: boolean
  callLogsCount?: boolean
  knowledgeSourcesCount?: boolean
  phoneNumbersCount?: boolean
  toolsCount?: boolean
}

export type AgentOmit<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetOmit<"agentId" | "agentSlug" | "organizationId" | "userId" | "name" | "templateId" | "isActive" | "isConfigured" | "createdAt" | "updatedAt" | "callLogsCount" | "knowledgeSourcesCount" | "phoneNumbersCount" | "toolsCount", ExtArgs["result"]["agent"]>
export type AgentInclude<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  organization?: boolean | Prisma.OrganizationDefaultArgs<ExtArgs>
  user?: boolean | Prisma.Agent$userArgs<ExtArgs>
  configuration?: boolean | Prisma.Agent$configurationArgs<ExtArgs>
  callLogs?: boolean | Prisma.Agent$callLogsArgs<ExtArgs>
  phoneNumbers?: boolean | Prisma.Agent$phoneNumbersArgs<ExtArgs>
  knowledgeSources?: boolean | Prisma.Agent$knowledgeSourcesArgs<ExtArgs>
  outboundCalls?: boolean | Prisma.Agent$outboundCallsArgs<ExtArgs>
  campaigns?: boolean | Prisma.Agent$campaignsArgs<ExtArgs>
  tools?: boolean | Prisma.Agent$toolsArgs<ExtArgs>
  mcpConnections?: boolean | Prisma.Agent$mcpConnectionsArgs<ExtArgs>
  mcpToolExecutionLogs?: boolean | Prisma.Agent$mcpToolExecutionLogsArgs<ExtArgs>
  _count?: boolean | Prisma.AgentCountOutputTypeDefaultArgs<ExtArgs>
}
export type AgentIncludeCreateManyAndReturn<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  organization?: boolean | Prisma.OrganizationDefaultArgs<ExtArgs>
  user?: boolean | Prisma.Agent$userArgs<ExtArgs>
}
export type AgentIncludeUpdateManyAndReturn<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  organization?: boolean | Prisma.OrganizationDefaultArgs<ExtArgs>
  user?: boolean | Prisma.Agent$userArgs<ExtArgs>
}

export type $AgentPayload<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  name: "Agent"
  objects: {
    organization: Prisma.$OrganizationPayload<ExtArgs>
    user: Prisma.$UserPayload<ExtArgs> | null
    configuration: Prisma.$AgentConfigurationPayload<ExtArgs> | null
    callLogs: Prisma.$CallLogPayload<ExtArgs>[]
    phoneNumbers: Prisma.$PhoneNumberPayload<ExtArgs>[]
    knowledgeSources: Prisma.$KnowledgeSourcePayload<ExtArgs>[]
    outboundCalls: Prisma.$OutboundCallPayload<ExtArgs>[]
    campaigns: Prisma.$CampaignPayload<ExtArgs>[]
    tools: Prisma.$ToolPayload<ExtArgs>[]
    mcpConnections: Prisma.$AgentMcpConnectionPayload<ExtArgs>[]
    mcpToolExecutionLogs: Prisma.$McpToolExecutionLogPayload<ExtArgs>[]
  }
  scalars: runtime.Types.Extensions.GetPayloadResult<{
    agentId: string
    agentSlug: string
    organizationId: string
    userId: string | null
    name: string
    templateId: string | null
    isActive: boolean
    isConfigured: boolean
    createdAt: Date
    updatedAt: Date
    callLogsCount: number
    knowledgeSourcesCount: number
    phoneNumbersCount: number
    toolsCount: number
  }, ExtArgs["result"]["agent"]>
  composites: {}
}

export type AgentGetPayload<S extends boolean | null | undefined | AgentDefaultArgs> = runtime.Types.Result.GetResult<Prisma.$AgentPayload, S>

export type AgentCountArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> =
  Omit<AgentFindManyArgs, 'select' | 'include' | 'distinct' | 'omit'> & {
    select?: AgentCountAggregateInputType | true
  }

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

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

  /**
   * Find the first Agent 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 {AgentFindFirstArgs} args - Arguments to find a Agent
   * @example
   * // Get one Agent
   * const agent = await prisma.agent.findFirst({
   *   where: {
   *     // ... provide filter here
   *   }
   * })
   */
  findFirst<T extends AgentFindFirstArgs>(args?: Prisma.SelectSubset<T, AgentFindFirstArgs<ExtArgs>>): Prisma.Prisma__AgentClient<runtime.Types.Result.GetResult<Prisma.$AgentPayload<ExtArgs>, T, "findFirst", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>

  /**
   * Find the first Agent 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 {AgentFindFirstOrThrowArgs} args - Arguments to find a Agent
   * @example
   * // Get one Agent
   * const agent = await prisma.agent.findFirstOrThrow({
   *   where: {
   *     // ... provide filter here
   *   }
   * })
   */
  findFirstOrThrow<T extends AgentFindFirstOrThrowArgs>(args?: Prisma.SelectSubset<T, AgentFindFirstOrThrowArgs<ExtArgs>>): Prisma.Prisma__AgentClient<runtime.Types.Result.GetResult<Prisma.$AgentPayload<ExtArgs>, T, "findFirstOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

  /**
   * Find zero or more Agents 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 {AgentFindManyArgs} args - Arguments to filter and select certain fields only.
   * @example
   * // Get all Agents
   * const agents = await prisma.agent.findMany()
   * 
   * // Get first 10 Agents
   * const agents = await prisma.agent.findMany({ take: 10 })
   * 
   * // Only select the `agentId`
   * const agentWithAgentIdOnly = await prisma.agent.findMany({ select: { agentId: true } })
   * 
   */
  findMany<T extends AgentFindManyArgs>(args?: Prisma.SelectSubset<T, AgentFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$AgentPayload<ExtArgs>, T, "findMany", GlobalOmitOptions>>

  /**
   * Create a Agent.
   * @param {AgentCreateArgs} args - Arguments to create a Agent.
   * @example
   * // Create one Agent
   * const Agent = await prisma.agent.create({
   *   data: {
   *     // ... data to create a Agent
   *   }
   * })
   * 
   */
  create<T extends AgentCreateArgs>(args: Prisma.SelectSubset<T, AgentCreateArgs<ExtArgs>>): Prisma.Prisma__AgentClient<runtime.Types.Result.GetResult<Prisma.$AgentPayload<ExtArgs>, T, "create", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

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

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

  /**
   * Delete a Agent.
   * @param {AgentDeleteArgs} args - Arguments to delete one Agent.
   * @example
   * // Delete one Agent
   * const Agent = await prisma.agent.delete({
   *   where: {
   *     // ... filter to delete one Agent
   *   }
   * })
   * 
   */
  delete<T extends AgentDeleteArgs>(args: Prisma.SelectSubset<T, AgentDeleteArgs<ExtArgs>>): Prisma.Prisma__AgentClient<runtime.Types.Result.GetResult<Prisma.$AgentPayload<ExtArgs>, T, "delete", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

  /**
   * Update one Agent.
   * @param {AgentUpdateArgs} args - Arguments to update one Agent.
   * @example
   * // Update one Agent
   * const agent = await prisma.agent.update({
   *   where: {
   *     // ... provide filter here
   *   },
   *   data: {
   *     // ... provide data here
   *   }
   * })
   * 
   */
  update<T extends AgentUpdateArgs>(args: Prisma.SelectSubset<T, AgentUpdateArgs<ExtArgs>>): Prisma.Prisma__AgentClient<runtime.Types.Result.GetResult<Prisma.$AgentPayload<ExtArgs>, T, "update", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>

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

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

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

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


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

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

  /**
   * Group by Agent.
   * Note, that providing `undefined` is treated as the value not being there.
   * Read more here: https://pris.ly/d/null-undefined
   * @param {AgentGroupByArgs} 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 AgentGroupByArgs,
    HasSelectOrTake extends Prisma.Or<
      Prisma.Extends<'skip', Prisma.Keys<T>>,
      Prisma.Extends<'take', Prisma.Keys<T>>
    >,
    OrderByArg extends Prisma.True extends HasSelectOrTake
      ? { orderBy: AgentGroupByArgs['orderBy'] }
      : { orderBy?: AgentGroupByArgs['orderBy'] },
    OrderFields extends Prisma.ExcludeUnderscoreKeys<Prisma.Keys<Prisma.MaybeTupleToUnion<T['orderBy']>>>,
    ByFields extends Prisma.MaybeTupleToUnion<T['by']>,
    ByValid extends Prisma.Has<ByFields, OrderFields>,
    HavingFields extends Prisma.GetHavingFields<T['having']>,
    HavingValid extends Prisma.Has<ByFields, HavingFields>,
    ByEmpty extends T['by'] extends never[] ? Prisma.True : Prisma.False,
    InputErrors extends ByEmpty extends Prisma.True
    ? `Error: "by" must not be empty.`
    : HavingValid extends Prisma.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 Prisma.Keys<T>
    ? 'orderBy' extends Prisma.Keys<T>
      ? ByValid extends Prisma.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 Prisma.Keys<T>
    ? 'orderBy' extends Prisma.Keys<T>
      ? ByValid extends Prisma.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 Prisma.True
    ? {}
    : {
        [P in OrderFields]: P extends ByFields
          ? never
          : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
      }[OrderFields]
  >(args: Prisma.SubsetIntersection<T, AgentGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetAgentGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
/**
 * Fields of the Agent model
 */
readonly fields: AgentFieldRefs;
}

/**
 * The delegate class that acts as a "Promise-like" for Agent.
 * 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__AgentClient<T, Null = never, ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs, GlobalOmitOptions = {}> extends Prisma.PrismaPromise<T> {
  readonly [Symbol.toStringTag]: "PrismaPromise"
  organization<T extends Prisma.OrganizationDefaultArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.OrganizationDefaultArgs<ExtArgs>>): Prisma.Prisma__OrganizationClient<runtime.Types.Result.GetResult<Prisma.$OrganizationPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | Null, Null, ExtArgs, GlobalOmitOptions>
  user<T extends Prisma.Agent$userArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Agent$userArgs<ExtArgs>>): Prisma.Prisma__UserClient<runtime.Types.Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>
  configuration<T extends Prisma.Agent$configurationArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Agent$configurationArgs<ExtArgs>>): Prisma.Prisma__AgentConfigurationClient<runtime.Types.Result.GetResult<Prisma.$AgentConfigurationPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>
  callLogs<T extends Prisma.Agent$callLogsArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Agent$callLogsArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$CallLogPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
  phoneNumbers<T extends Prisma.Agent$phoneNumbersArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Agent$phoneNumbersArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$PhoneNumberPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
  knowledgeSources<T extends Prisma.Agent$knowledgeSourcesArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Agent$knowledgeSourcesArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$KnowledgeSourcePayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
  outboundCalls<T extends Prisma.Agent$outboundCallsArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Agent$outboundCallsArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$OutboundCallPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
  campaigns<T extends Prisma.Agent$campaignsArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Agent$campaignsArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$CampaignPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
  tools<T extends Prisma.Agent$toolsArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Agent$toolsArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$ToolPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
  mcpConnections<T extends Prisma.Agent$mcpConnectionsArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Agent$mcpConnectionsArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$AgentMcpConnectionPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
  mcpToolExecutionLogs<T extends Prisma.Agent$mcpToolExecutionLogsArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.Agent$mcpToolExecutionLogsArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$McpToolExecutionLogPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
  /**
   * Attaches callbacks for the resolution and/or rejection of the Promise.
   * @param onfulfilled The callback to execute when the Promise is resolved.
   * @param onrejected The callback to execute when the Promise is rejected.
   * @returns A Promise for the completion of which ever callback is executed.
   */
  then<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): runtime.Types.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): runtime.Types.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): runtime.Types.Utils.JsPromise<T>
}




/**
 * Fields of the Agent model
 */
export interface AgentFieldRefs {
  readonly agentId: Prisma.FieldRef<"Agent", 'String'>
  readonly agentSlug: Prisma.FieldRef<"Agent", 'String'>
  readonly organizationId: Prisma.FieldRef<"Agent", 'String'>
  readonly userId: Prisma.FieldRef<"Agent", 'String'>
  readonly name: Prisma.FieldRef<"Agent", 'String'>
  readonly templateId: Prisma.FieldRef<"Agent", 'String'>
  readonly isActive: Prisma.FieldRef<"Agent", 'Boolean'>
  readonly isConfigured: Prisma.FieldRef<"Agent", 'Boolean'>
  readonly createdAt: Prisma.FieldRef<"Agent", 'DateTime'>
  readonly updatedAt: Prisma.FieldRef<"Agent", 'DateTime'>
  readonly callLogsCount: Prisma.FieldRef<"Agent", 'Int'>
  readonly knowledgeSourcesCount: Prisma.FieldRef<"Agent", 'Int'>
  readonly phoneNumbersCount: Prisma.FieldRef<"Agent", 'Int'>
  readonly toolsCount: Prisma.FieldRef<"Agent", 'Int'>
}
    

// Custom InputTypes
/**
 * Agent findUnique
 */
export type AgentFindUniqueArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the Agent
   */
  select?: Prisma.AgentSelect<ExtArgs> | null
  /**
   * Omit specific fields from the Agent
   */
  omit?: Prisma.AgentOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.AgentInclude<ExtArgs> | null
  /**
   * Filter, which Agent to fetch.
   */
  where: Prisma.AgentWhereUniqueInput
}

/**
 * Agent findUniqueOrThrow
 */
export type AgentFindUniqueOrThrowArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the Agent
   */
  select?: Prisma.AgentSelect<ExtArgs> | null
  /**
   * Omit specific fields from the Agent
   */
  omit?: Prisma.AgentOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.AgentInclude<ExtArgs> | null
  /**
   * Filter, which Agent to fetch.
   */
  where: Prisma.AgentWhereUniqueInput
}

/**
 * Agent findFirst
 */
export type AgentFindFirstArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the Agent
   */
  select?: Prisma.AgentSelect<ExtArgs> | null
  /**
   * Omit specific fields from the Agent
   */
  omit?: Prisma.AgentOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.AgentInclude<ExtArgs> | null
  /**
   * Filter, which Agent to fetch.
   */
  where?: Prisma.AgentWhereInput
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
   * 
   * Determine the order of Agents to fetch.
   */
  orderBy?: Prisma.AgentOrderByWithRelationInput | Prisma.AgentOrderByWithRelationInput[]
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
   * 
   * Sets the position for searching for Agents.
   */
  cursor?: Prisma.AgentWhereUniqueInput
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
   * 
   * Take `±n` Agents 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` Agents.
   */
  skip?: number
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
   * 
   * Filter by unique combinations of Agents.
   */
  distinct?: Prisma.AgentScalarFieldEnum | Prisma.AgentScalarFieldEnum[]
}

/**
 * Agent findFirstOrThrow
 */
export type AgentFindFirstOrThrowArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the Agent
   */
  select?: Prisma.AgentSelect<ExtArgs> | null
  /**
   * Omit specific fields from the Agent
   */
  omit?: Prisma.AgentOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.AgentInclude<ExtArgs> | null
  /**
   * Filter, which Agent to fetch.
   */
  where?: Prisma.AgentWhereInput
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
   * 
   * Determine the order of Agents to fetch.
   */
  orderBy?: Prisma.AgentOrderByWithRelationInput | Prisma.AgentOrderByWithRelationInput[]
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
   * 
   * Sets the position for searching for Agents.
   */
  cursor?: Prisma.AgentWhereUniqueInput
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
   * 
   * Take `±n` Agents 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` Agents.
   */
  skip?: number
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
   * 
   * Filter by unique combinations of Agents.
   */
  distinct?: Prisma.AgentScalarFieldEnum | Prisma.AgentScalarFieldEnum[]
}

/**
 * Agent findMany
 */
export type AgentFindManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the Agent
   */
  select?: Prisma.AgentSelect<ExtArgs> | null
  /**
   * Omit specific fields from the Agent
   */
  omit?: Prisma.AgentOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.AgentInclude<ExtArgs> | null
  /**
   * Filter, which Agents to fetch.
   */
  where?: Prisma.AgentWhereInput
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
   * 
   * Determine the order of Agents to fetch.
   */
  orderBy?: Prisma.AgentOrderByWithRelationInput | Prisma.AgentOrderByWithRelationInput[]
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
   * 
   * Sets the position for listing Agents.
   */
  cursor?: Prisma.AgentWhereUniqueInput
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
   * 
   * Take `±n` Agents 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` Agents.
   */
  skip?: number
  /**
   * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
   * 
   * Filter by unique combinations of Agents.
   */
  distinct?: Prisma.AgentScalarFieldEnum | Prisma.AgentScalarFieldEnum[]
}

/**
 * Agent create
 */
export type AgentCreateArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the Agent
   */
  select?: Prisma.AgentSelect<ExtArgs> | null
  /**
   * Omit specific fields from the Agent
   */
  omit?: Prisma.AgentOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.AgentInclude<ExtArgs> | null
  /**
   * The data needed to create a Agent.
   */
  data: Prisma.XOR<Prisma.AgentCreateInput, Prisma.AgentUncheckedCreateInput>
}

/**
 * Agent createMany
 */
export type AgentCreateManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * The data used to create many Agents.
   */
  data: Prisma.AgentCreateManyInput | Prisma.AgentCreateManyInput[]
  skipDuplicates?: boolean
}

/**
 * Agent createManyAndReturn
 */
export type AgentCreateManyAndReturnArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the Agent
   */
  select?: Prisma.AgentSelectCreateManyAndReturn<ExtArgs> | null
  /**
   * Omit specific fields from the Agent
   */
  omit?: Prisma.AgentOmit<ExtArgs> | null
  /**
   * The data used to create many Agents.
   */
  data: Prisma.AgentCreateManyInput | Prisma.AgentCreateManyInput[]
  skipDuplicates?: boolean
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.AgentIncludeCreateManyAndReturn<ExtArgs> | null
}

/**
 * Agent update
 */
export type AgentUpdateArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the Agent
   */
  select?: Prisma.AgentSelect<ExtArgs> | null
  /**
   * Omit specific fields from the Agent
   */
  omit?: Prisma.AgentOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.AgentInclude<ExtArgs> | null
  /**
   * The data needed to update a Agent.
   */
  data: Prisma.XOR<Prisma.AgentUpdateInput, Prisma.AgentUncheckedUpdateInput>
  /**
   * Choose, which Agent to update.
   */
  where: Prisma.AgentWhereUniqueInput
}

/**
 * Agent updateMany
 */
export type AgentUpdateManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * The data used to update Agents.
   */
  data: Prisma.XOR<Prisma.AgentUpdateManyMutationInput, Prisma.AgentUncheckedUpdateManyInput>
  /**
   * Filter which Agents to update
   */
  where?: Prisma.AgentWhereInput
  /**
   * Limit how many Agents to update.
   */
  limit?: number
}

/**
 * Agent updateManyAndReturn
 */
export type AgentUpdateManyAndReturnArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the Agent
   */
  select?: Prisma.AgentSelectUpdateManyAndReturn<ExtArgs> | null
  /**
   * Omit specific fields from the Agent
   */
  omit?: Prisma.AgentOmit<ExtArgs> | null
  /**
   * The data used to update Agents.
   */
  data: Prisma.XOR<Prisma.AgentUpdateManyMutationInput, Prisma.AgentUncheckedUpdateManyInput>
  /**
   * Filter which Agents to update
   */
  where?: Prisma.AgentWhereInput
  /**
   * Limit how many Agents to update.
   */
  limit?: number
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.AgentIncludeUpdateManyAndReturn<ExtArgs> | null
}

/**
 * Agent upsert
 */
export type AgentUpsertArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the Agent
   */
  select?: Prisma.AgentSelect<ExtArgs> | null
  /**
   * Omit specific fields from the Agent
   */
  omit?: Prisma.AgentOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.AgentInclude<ExtArgs> | null
  /**
   * The filter to search for the Agent to update in case it exists.
   */
  where: Prisma.AgentWhereUniqueInput
  /**
   * In case the Agent found by the `where` argument doesn't exist, create a new Agent with this data.
   */
  create: Prisma.XOR<Prisma.AgentCreateInput, Prisma.AgentUncheckedCreateInput>
  /**
   * In case the Agent was found with the provided `where` argument, update it with this data.
   */
  update: Prisma.XOR<Prisma.AgentUpdateInput, Prisma.AgentUncheckedUpdateInput>
}

/**
 * Agent delete
 */
export type AgentDeleteArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the Agent
   */
  select?: Prisma.AgentSelect<ExtArgs> | null
  /**
   * Omit specific fields from the Agent
   */
  omit?: Prisma.AgentOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.AgentInclude<ExtArgs> | null
  /**
   * Filter which Agent to delete.
   */
  where: Prisma.AgentWhereUniqueInput
}

/**
 * Agent deleteMany
 */
export type AgentDeleteManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Filter which Agents to delete
   */
  where?: Prisma.AgentWhereInput
  /**
   * Limit how many Agents to delete.
   */
  limit?: number
}

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

/**
 * Agent.configuration
 */
export type Agent$configurationArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the AgentConfiguration
   */
  select?: Prisma.AgentConfigurationSelect<ExtArgs> | null
  /**
   * Omit specific fields from the AgentConfiguration
   */
  omit?: Prisma.AgentConfigurationOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.AgentConfigurationInclude<ExtArgs> | null
  where?: Prisma.AgentConfigurationWhereInput
}

/**
 * Agent.callLogs
 */
export type Agent$callLogsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the CallLog
   */
  select?: Prisma.CallLogSelect<ExtArgs> | null
  /**
   * Omit specific fields from the CallLog
   */
  omit?: Prisma.CallLogOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.CallLogInclude<ExtArgs> | null
  where?: Prisma.CallLogWhereInput
  orderBy?: Prisma.CallLogOrderByWithRelationInput | Prisma.CallLogOrderByWithRelationInput[]
  cursor?: Prisma.CallLogWhereUniqueInput
  take?: number
  skip?: number
  distinct?: Prisma.CallLogScalarFieldEnum | Prisma.CallLogScalarFieldEnum[]
}

/**
 * Agent.phoneNumbers
 */
export type Agent$phoneNumbersArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the PhoneNumber
   */
  select?: Prisma.PhoneNumberSelect<ExtArgs> | null
  /**
   * Omit specific fields from the PhoneNumber
   */
  omit?: Prisma.PhoneNumberOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.PhoneNumberInclude<ExtArgs> | null
  where?: Prisma.PhoneNumberWhereInput
  orderBy?: Prisma.PhoneNumberOrderByWithRelationInput | Prisma.PhoneNumberOrderByWithRelationInput[]
  cursor?: Prisma.PhoneNumberWhereUniqueInput
  take?: number
  skip?: number
  distinct?: Prisma.PhoneNumberScalarFieldEnum | Prisma.PhoneNumberScalarFieldEnum[]
}

/**
 * Agent.knowledgeSources
 */
export type Agent$knowledgeSourcesArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the KnowledgeSource
   */
  select?: Prisma.KnowledgeSourceSelect<ExtArgs> | null
  /**
   * Omit specific fields from the KnowledgeSource
   */
  omit?: Prisma.KnowledgeSourceOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.KnowledgeSourceInclude<ExtArgs> | null
  where?: Prisma.KnowledgeSourceWhereInput
  orderBy?: Prisma.KnowledgeSourceOrderByWithRelationInput | Prisma.KnowledgeSourceOrderByWithRelationInput[]
  cursor?: Prisma.KnowledgeSourceWhereUniqueInput
  take?: number
  skip?: number
  distinct?: Prisma.KnowledgeSourceScalarFieldEnum | Prisma.KnowledgeSourceScalarFieldEnum[]
}

/**
 * Agent.outboundCalls
 */
export type Agent$outboundCallsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the OutboundCall
   */
  select?: Prisma.OutboundCallSelect<ExtArgs> | null
  /**
   * Omit specific fields from the OutboundCall
   */
  omit?: Prisma.OutboundCallOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.OutboundCallInclude<ExtArgs> | null
  where?: Prisma.OutboundCallWhereInput
  orderBy?: Prisma.OutboundCallOrderByWithRelationInput | Prisma.OutboundCallOrderByWithRelationInput[]
  cursor?: Prisma.OutboundCallWhereUniqueInput
  take?: number
  skip?: number
  distinct?: Prisma.OutboundCallScalarFieldEnum | Prisma.OutboundCallScalarFieldEnum[]
}

/**
 * Agent.campaigns
 */
export type Agent$campaignsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the Campaign
   */
  select?: Prisma.CampaignSelect<ExtArgs> | null
  /**
   * Omit specific fields from the Campaign
   */
  omit?: Prisma.CampaignOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.CampaignInclude<ExtArgs> | null
  where?: Prisma.CampaignWhereInput
  orderBy?: Prisma.CampaignOrderByWithRelationInput | Prisma.CampaignOrderByWithRelationInput[]
  cursor?: Prisma.CampaignWhereUniqueInput
  take?: number
  skip?: number
  distinct?: Prisma.CampaignScalarFieldEnum | Prisma.CampaignScalarFieldEnum[]
}

/**
 * Agent.tools
 */
export type Agent$toolsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the Tool
   */
  select?: Prisma.ToolSelect<ExtArgs> | null
  /**
   * Omit specific fields from the Tool
   */
  omit?: Prisma.ToolOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.ToolInclude<ExtArgs> | null
  where?: Prisma.ToolWhereInput
  orderBy?: Prisma.ToolOrderByWithRelationInput | Prisma.ToolOrderByWithRelationInput[]
  cursor?: Prisma.ToolWhereUniqueInput
  take?: number
  skip?: number
  distinct?: Prisma.ToolScalarFieldEnum | Prisma.ToolScalarFieldEnum[]
}

/**
 * Agent.mcpConnections
 */
export type Agent$mcpConnectionsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the AgentMcpConnection
   */
  select?: Prisma.AgentMcpConnectionSelect<ExtArgs> | null
  /**
   * Omit specific fields from the AgentMcpConnection
   */
  omit?: Prisma.AgentMcpConnectionOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.AgentMcpConnectionInclude<ExtArgs> | null
  where?: Prisma.AgentMcpConnectionWhereInput
  orderBy?: Prisma.AgentMcpConnectionOrderByWithRelationInput | Prisma.AgentMcpConnectionOrderByWithRelationInput[]
  cursor?: Prisma.AgentMcpConnectionWhereUniqueInput
  take?: number
  skip?: number
  distinct?: Prisma.AgentMcpConnectionScalarFieldEnum | Prisma.AgentMcpConnectionScalarFieldEnum[]
}

/**
 * Agent.mcpToolExecutionLogs
 */
export type Agent$mcpToolExecutionLogsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the McpToolExecutionLog
   */
  select?: Prisma.McpToolExecutionLogSelect<ExtArgs> | null
  /**
   * Omit specific fields from the McpToolExecutionLog
   */
  omit?: Prisma.McpToolExecutionLogOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.McpToolExecutionLogInclude<ExtArgs> | null
  where?: Prisma.McpToolExecutionLogWhereInput
  orderBy?: Prisma.McpToolExecutionLogOrderByWithRelationInput | Prisma.McpToolExecutionLogOrderByWithRelationInput[]
  cursor?: Prisma.McpToolExecutionLogWhereUniqueInput
  take?: number
  skip?: number
  distinct?: Prisma.McpToolExecutionLogScalarFieldEnum | Prisma.McpToolExecutionLogScalarFieldEnum[]
}

/**
 * Agent without action
 */
export type AgentDefaultArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
  /**
   * Select specific fields to fetch from the Agent
   */
  select?: Prisma.AgentSelect<ExtArgs> | null
  /**
   * Omit specific fields from the Agent
   */
  omit?: Prisma.AgentOmit<ExtArgs> | null
  /**
   * Choose, which related nodes to fetch as well
   */
  include?: Prisma.AgentInclude<ExtArgs> | null
}
