> ## Documentation Index
> Fetch the complete documentation index at: https://docs.endaoment.org/llms.txt
> Use this file to discover all available pages before exploring further.

# Create a new fund

> 
      This operation allows you to create a new fund with or without an associated deployment transaction hash.
      A deployment transaction hash is only required for integrations that handle on-chain deployments themselves.
      



## OpenAPI

````yaml https://api.endaoment.org/oas-json post /v1/funds
openapi: 3.0.0
info:
  title: Endaoment API
  description: The official Endaoment API endpoints
  version: 0.0.1
  contact: {}
servers:
  - url: https://api.endaoment.org
    description: Production
security: []
tags: []
paths:
  /v1/funds:
    post:
      tags:
        - Funds
      summary: Create a new fund
      description: |2-

              This operation allows you to create a new fund with or without an associated deployment transaction hash.
              A deployment transaction hash is only required for integrations that handle on-chain deployments themselves.
              
      operationId: FundsController_processFund
      parameters: []
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ProcessSingleFundDeploymentInputDto'
      responses:
        '200':
          description: The fund has been successfully created and processed.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/FundDetailsDto'
        '400':
          description: The request contains invalid data.
          content:
            application/json:
              schema:
                type: object
                properties:
                  statusCode:
                    type: number
                    example: 400
                  message:
                    type: array
                    items:
                      type: string
                    example:
                      - fundInput.advisor.firstName must be a non-empty string
                      - fundInput.advisor.lastName must be a non-empty string
                      - fundInput.advisor.email must be an email
                      - >-
                        fundInput.advisor.address.zip must be shorter than or
                        equal to 255 characters
                      - fundInput.advisor.address.zip must be a string
                      - '"1" is not a chain id supported by the system'
                  error:
                    type: string
                    example: Bad Request
        '401':
          description: User is not authenticated or the access token is invalid
      security:
        - bearer: []
components:
  schemas:
    ProcessSingleFundDeploymentInputDto:
      type: object
      properties:
        deploymentTransactionHash:
          type: object
          description: |2-

                  Transaction hash of the fund contract deployment:
                  - If provided, the fund will be created using the information from the deployment transaction provided.
                  - If not provided, creates the fund and delegates the blockchain logic to Endaoment.
                  - Must be a valid Ethereum transaction hash matching pattern: 0x followed by 64 hexadecimal characters (0-9, a-f)
          example: '0xf89f7da1e5d79dcb1b8863d0926fe41204785b443ce2d1dca4bf50070c492567'
          pattern: ^0x[0-9a-f]{64}$
        fundInput:
          description: Details of the fund to be created
          allOf:
            - $ref: '#/components/schemas/FundInputDto'
        referralSource:
          type: string
          description: Referral source informed by the user for the fund creation
          example: partner_website
        fundSalt:
          type: object
          description: >-
            Random Bytes32 Hex Value used as an idempotency key for fund
            creation. If not provided, backend will generate one. **Note:
            Off-chain creation requests without salt will not have idempotency
            guarantees on retries.**
          example: '0x7189b9ff31064f2bbc98ad4e92e5562c00000000000000000000000000000000'
          minLength: 66
          maxLength: 66
        chainId:
          type: number
          description: |-
            Chain ID to process the fund deployment.

                - If not provided, the API will process the fund deployment on the default chain.
                - If provided, must be a valid Ethereum chain ID.
                - Must be provided if a transaction hash is provided so the backend can fetch the correct deployment from the selected blockchain.
          example: 1
      required:
        - fundInput
    FundDetailsDto:
      type: object
      properties:
        id:
          type: string
          description: Unique identifier of the fund
          example: 123e4567-e89b-12d3-a456-426614174000
        name:
          type: string
          description: Name of the fund
          example: Doe Family Foundation
        type:
          type: string
          description: Access type of the fund
          enum:
            - Private
            - Community
            - Transparent
            - ImpactPool
          example: Private
        manager:
          description: >-
            Basic information about the fund manager. The manager has technical
            capability to interact with the blockchain and perform programmatic
            functions.
          allOf:
            - $ref: '#/components/schemas/FundManager'
        chainId:
          type: object
          description: Chain ID where the fund is deployed
          example: 1
        deploymentTransactionHash:
          type: object
          description: Transaction hash of the deployment transaction
          example: '0xf89f7da1e5d79dcb1b8863d0926fe41204785b443ce2d1dca4bf50070c492567'
          nullable: true
        contractAddress:
          type: object
          description: Contract address of the fund
          example: '0x1234567890123456789012345678901234567890'
          nullable: true
        advisor:
          description: >-
            Fund advisor information. The advisor is tied to a real-world
            person/entity and acts as the public contact for the fund. This can
            be the same person as the manager or someone the manager acts on
            behalf of.
          allOf:
            - $ref: '#/components/schemas/FundAdvisor'
        featuredIndex:
          type: number
          description: >-
            Index determining the fund's position in featured listings. Lower
            numbers appear first
          example: 1
        usdcBalance:
          type: string
          description: >-
            Current synced USDC balance in the smallest currency unit (1000000 =
            1 USD). This does not account for asynchronous grants, asynchronous
            entity transfers, or asynchronous investments that may still be
            processing.
          example: '20500000'
        availableBalance:
          type: string
          description: >-
            Amount available to grant or transfer in the smallest currency unit
            (1000000 = 1 USD), adjusted for invested value, in-transit portfolio
            operations, and pending asynchronous transfers.
          example: '21000000'
        lastBalanceSyncUtc:
          type: object
          description: UTC timestamp of the last balance sync
          example: '2024-03-14T12:00:00Z'
          nullable: true
        description:
          type: string
          description: Detailed description of the fund
          example: A family foundation dedicated to supporting educational initiatives
        shortDescription:
          type: object
          description: Brief description of the fund
          example: Supporting education
          nullable: true
        vanityUrl:
          type: object
          description: Custom URL identifier for the fund
          example: doe-family-foundation
          nullable: true
        paypalId:
          type: object
          description: PayPal merchant ID associated with the fund
          nullable: true
          example: 123e4567-e89b-12d3-a456-426614174000
        logo:
          type: object
          description: URL of the fund's logo image
          example: https://example.com/logo.png
          nullable: true
        createdAtUtc:
          type: string
          description: UTC timestamp of fund creation
          example: '2024-01-01T00:00:00Z'
        updatedAtUtc:
          type: string
          description: UTC timestamp of last fund update
          example: '2024-03-14T12:00:00Z'
        lifetimeDonationsUsdc:
          type: string
          description: >-
            Total lifetime donations received in USDC, in the smallest currency
            unit (1000000 = 1 USD)
          example: '1000000000'
        staffNotes:
          type: string
          description: Internal notes about the fund (staff only)
          nullable: true
        category:
          type: object
          description: Category of the fund (e.g., Education, Health)
          example: Education
          nullable: true
        inboundFeeBps:
          type: number
          description: >-
            The fee charged for inbound operations in basis points (1 basis
            point = 0.01%)
          example: 25
        outboundFeeBps:
          type: number
          description: >-
            The fee charged for outbound operations in basis points (1 basis
            point = 0.01%)
          example: 50
        customFeeDetail:
          type: object
          description: >-
            Details about why this fund has custom fees. Only set if either
            inbound or outbound fee is custom
          example: Special Community Fund Agreement
          nullable: true
        grantsGiven:
          type: number
          description: Total number of grants given by this fund
          example: 10
        inTransitBuyUsdcAmount:
          type: string
          description: >-
            Amount of USDC pending purchase in the smallest currency unit
            (1000000 = 1 USD)
          example: '5000000'
        inTransitSellUsdcAmount:
          type: string
          description: >-
            Amount of USDC pending sale in the smallest currency unit (1000000 =
            1 USD)
          example: '3000000'
        investedUsdc:
          type: string
          description: >-
            Total amount invested in USDC, in the smallest currency unit
            (1000000 = 1 USD)
          example: '50000000'
        totalGrantedUsdc:
          type: string
          description: >-
            Total amount granted in USDC, in the smallest currency unit (1000000
            = 1 USD)
          example: '25000000'
        processingTransfersTotalUsdc:
          type: string
          description: >-
            Total amount in processing transfers in USDC, in the smallest
            currency unit (1000000 = 1 USD)
          example: '1000000'
        illiquidBalance:
          type: string
          description: >-
            Total balance in illiquid portfolios in USDC, in the smallest
            currency unit (1000000 = 1 USD)
          example: '10000000'
        poolDetails:
          description: >-
            Impact Pool specific details. Only available for Impact Pool type
            funds
          nullable: true
          allOf:
            - $ref: '#/components/schemas/ImpactPoolDetailsDto'
        expectedDeploymentInfo:
          description: >-
            Information needed for on-chain deployment. Only available for funds
            not yet deployed
          nullable: true
          allOf:
            - $ref: '#/components/schemas/ExpectedDeploymentInfoDto'
      required:
        - id
        - name
        - type
        - manager
        - chainId
        - advisor
        - featuredIndex
        - usdcBalance
        - availableBalance
        - description
        - createdAtUtc
        - updatedAtUtc
        - lifetimeDonationsUsdc
        - inboundFeeBps
        - outboundFeeBps
        - grantsGiven
        - inTransitBuyUsdcAmount
        - inTransitSellUsdcAmount
        - investedUsdc
        - totalGrantedUsdc
        - processingTransfersTotalUsdc
        - illiquidBalance
        - poolDetails
        - expectedDeploymentInfo
    FundInputDto:
      type: object
      properties:
        name:
          type: string
          description: Name of the fund
          maxLength: 255
          example: Doe Family Foundation
        advisor:
          description: Fund advisor information
          allOf:
            - $ref: '#/components/schemas/FundAdvisorDto'
        description:
          type: string
          description: Description of the fund
          example: A family foundation dedicated to supporting educational initiatives
        type:
          type: string
          description: |2-

                Type of the fund being created. Available options:
                - Private: The fund is private and only accessible by the manager
                - Transparent: A fund that anyone can see information about but shouldn't interact with, besides the manager.
          enum:
            - Private
            - Transparent
          example: Private
      required:
        - name
        - advisor
        - description
    FundManager:
      type: object
      properties:
        id:
          type: string
          description: Unique identifier of the fund manager
          example: 123e4567-e89b-12d3-a456-426614174000
        walletAddress:
          type: string
          description: Ethereum wallet address of the fund manager
          example: '0x742d35Cc6634C0532925a3b844Bc454e4438f44e'
      required:
        - id
        - walletAddress
    FundAdvisor:
      type: object
      properties:
        firstName:
          type: string
          description: First name of the fund advisor
          example: John
        lastName:
          type: string
          description: Last name of the fund advisor
          example: Doe
      required:
        - firstName
        - lastName
    ImpactPoolDetailsDto:
      type: object
      properties:
        eligibleEntities:
          type: string
          description: Entities that are eligible for Impact Pool distributions
          enum:
            - Organizations
          example: Organizations
        algorithmType:
          type: string
          description: Algorithm used to calculate distributions
          enum:
            - QuadraticFunding
          example: QuadraticFunding
        distributionSchedule:
          type: string
          description: Human-readable distribution schedule
          example: Quarterly
        distributionPercentage:
          type: number
          description: Percentage of fund NAV to be distributed (0.25 = 25%, 0.125 = 12.5%)
          example: 0.25
          minimum: 0
          maximum: 1
        eligibleVotes:
          type: string
          description: Types of actions that count as votes for distribution
          enum:
            - GrantsAndDonations
          example: GrantsAndDonations
        voteWeight:
          type: string
          description: Method for calculating vote weights
          enum:
            - UsdcValue
          example: UsdcValue
      required:
        - eligibleEntities
        - algorithmType
        - distributionSchedule
        - distributionPercentage
        - eligibleVotes
        - voteWeight
    ExpectedDeploymentInfoDto:
      type: object
      properties:
        expectedManagerAddress:
          type: string
          description: >-
            Ethereum address of the fund manager used to compute the on-chain
            address
          example: '0x742d35Cc6634C0532925a3b844Bc454e4438f44e'
        expectedSalt:
          type: string
          description: Encoded bytes32 salt used to compute the on-chain address
          example: '0x0000000000000000000000000000000000000000000000000000000000000123'
        expectedComputedAddress:
          type: string
          description: >-
            Expected on-chain address computed using the manager address and
            salt. Must be verified before deployment
          example: '0x1234567890123456789012345678901234567890'
        expectedChainId:
          type: object
          description: Chain ID where the fund should be deployed
          example: 1
      required:
        - expectedManagerAddress
        - expectedSalt
        - expectedComputedAddress
        - expectedChainId
    FundAdvisorDto:
      type: object
      properties:
        firstName:
          type: string
          description: First name of the fund advisor
          example: John
        lastName:
          type: string
          description: Last name of the fund advisor
          example: Doe
        email:
          type: string
          description: Email address of the fund advisor
          example: john.doe@example.com
        address:
          description: Physical address of the fund advisor
          allOf:
            - $ref: '#/components/schemas/AddressInputDto'
      required:
        - firstName
        - lastName
        - email
        - address
    AddressInputDto:
      type: object
      properties:
        line1:
          type: string
          description: First line of the address
          example: 123 Main Street
          maxLength: 255
        line2:
          type: object
          description: Second line of the address (optional)
          example: Suite 100
          maxLength: 255
          nullable: true
        city:
          type: string
          description: City name
          example: San Francisco
          maxLength: 255
        state:
          type: object
          description: State/Province/Region. Required if country is USA
          example: CA
          maxLength: 255
          nullable: true
        zip:
          type: string
          description: Postal/ZIP code. Required if country is USA
          example: '94105'
          maxLength: 255
          nullable: true
        country:
          type: string
          description: Three-letter ISO country code. Defaults to USA
          example: USA
          enum:
            - ABW
            - AFG
            - AGO
            - AIA
            - ALA
            - ALB
            - AND
            - ARE
            - ARG
            - ARM
            - ASM
            - ATA
            - ATF
            - ATG
            - AUS
            - AUT
            - AZE
            - BDI
            - BEL
            - BEN
            - BES
            - BFA
            - BGD
            - BGR
            - BHR
            - BHS
            - BIH
            - BLM
            - BLR
            - BLZ
            - BMU
            - BOL
            - BRA
            - BRB
            - BRN
            - BTN
            - BVT
            - BWA
            - CAF
            - CAN
            - CCK
            - CHE
            - CHL
            - CHN
            - CIV
            - CMR
            - COD
            - COG
            - COK
            - COL
            - COM
            - CPV
            - CRI
            - CUB
            - CUW
            - CXR
            - CYM
            - CYP
            - CZE
            - DEU
            - DJI
            - DMA
            - DNK
            - DOM
            - DZA
            - ECU
            - EGY
            - ERI
            - ESH
            - ESP
            - EST
            - ETH
            - FIN
            - FJI
            - FLK
            - FRA
            - FRO
            - FSM
            - GAB
            - GBR
            - GEO
            - GGY
            - GHA
            - GIB
            - GIN
            - GLP
            - GMB
            - GNB
            - GNQ
            - GRC
            - GRD
            - GRL
            - GTM
            - GUF
            - GUM
            - GUY
            - HKG
            - HMD
            - HND
            - HRV
            - HTI
            - HUN
            - IDN
            - IMN
            - IND
            - IOT
            - IRL
            - IRN
            - IRQ
            - ISL
            - ISR
            - ITA
            - JAM
            - JEY
            - JOR
            - JPN
            - KAZ
            - KEN
            - KGZ
            - KHM
            - KIR
            - KNA
            - KOR
            - KWT
            - LAO
            - LBN
            - LBR
            - LBY
            - LCA
            - LIE
            - LKA
            - LSO
            - LTU
            - LUX
            - LVA
            - MAC
            - MAF
            - MAR
            - MCO
            - MDA
            - MDG
            - MDV
            - MEX
            - MHL
            - MKD
            - MLI
            - MLT
            - MMR
            - MNE
            - MNG
            - MNP
            - MOZ
            - MRT
            - MSR
            - MTQ
            - MUS
            - MWI
            - MYS
            - MYT
            - NAM
            - NCL
            - NER
            - NFK
            - NGA
            - NIC
            - NIU
            - NLD
            - NOR
            - NPL
            - NRU
            - NZL
            - OMN
            - PAK
            - PAN
            - PCN
            - PER
            - PHL
            - PLW
            - PNG
            - POL
            - PRI
            - PRK
            - PRT
            - PRY
            - PSE
            - PYF
            - QAT
            - REU
            - ROU
            - RUS
            - RWA
            - SAU
            - SDN
            - SEN
            - SGP
            - SGS
            - SHN
            - SJM
            - SLB
            - SLE
            - SLV
            - SMR
            - SOM
            - SPM
            - SRB
            - SSD
            - STP
            - SUR
            - SVK
            - SVN
            - SWE
            - SWZ
            - SXM
            - SYC
            - SYR
            - TCA
            - TCD
            - TGO
            - THA
            - TJK
            - TKL
            - TKM
            - TLS
            - TON
            - TTO
            - TUN
            - TUR
            - TUV
            - TWN
            - TZA
            - UGA
            - UKR
            - UMI
            - URY
            - USA
            - UZB
            - VAT
            - VCT
            - VEN
            - VGB
            - VIR
            - VNM
            - VUT
            - WLF
            - WSM
            - XKX
            - YEM
            - ZAF
            - ZMB
            - ZWE
          default: USA
      required:
        - line1
        - city
  securitySchemes:
    bearer:
      scheme: bearer
      bearerFormat: JWT
      type: http

````