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

# Create Account Backtest

> Start a new backtest job for a client



## OpenAPI

````yaml POST /api/v1/custom/org/{organization_uuid}/clients/{client_uuid}/accounts/{account_uuid}/backtests/
openapi: 3.0.3
info:
  title: TILT
  version: 0.0.1
servers: []
security: []
paths:
  /api/v1/custom/org/{organization_uuid}/clients/{client_uuid}/accounts/{account_uuid}/backtests/:
    post:
      tags:
        - api
      description: Start a new backtest job for a client
      operationId: api_v1_custom_org_clients_accounts_backtests_create
      parameters:
        - in: path
          name: account_uuid
          schema:
            type: string
            format: uuid
          required: true
        - in: path
          name: client_uuid
          schema:
            type: string
            format: uuid
          required: true
        - in: path
          name: organization_uuid
          schema:
            type: string
            format: uuid
          required: true
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/StartBacktestRequest'
          application/x-www-form-urlencoded:
            schema:
              $ref: '#/components/schemas/StartBacktestRequest'
          multipart/form-data:
            schema:
              $ref: '#/components/schemas/StartBacktestRequest'
      responses:
        '202':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CustomizationBacktestJob'
          description: ''
      security:
        - ProAPIToken: []
components:
  schemas:
    StartBacktestRequest:
      type: object
      properties:
        start_date:
          type: string
          format: date
        end_date:
          type: string
          format: date
        rebalance_period:
          allOf:
            - $ref: '#/components/schemas/StartBacktestRequestRebalancePeriodEnum'
          default: MONTHLY
        tax_gamma:
          type: number
          format: double
          maximum: 100
          minimum: 0
        tax_loss_threshold_bps:
          type: number
          format: double
          maximum: 5000
          minimum: 0
        starting_nav:
          type: number
          format: double
          maximum: 1000000000
          minimum: 100
        ls_tlh_factor:
          $ref: '#/components/schemas/LsTlhFactorEnum'
    CustomizationBacktestJob:
      type: object
      properties:
        id:
          type: string
          format: uuid
          readOnly: true
        status:
          allOf:
            - $ref: '#/components/schemas/ScenarioAnalysisJobStatusEnum'
          readOnly: true
        params:
          allOf:
            - $ref: '#/components/schemas/StartBacktestRequest'
          readOnly: true
          nullable: true
        resolved_params:
          allOf:
            - $ref: '#/components/schemas/BacktestResolvedParams'
          nullable: true
          readOnly: true
        progress:
          allOf:
            - $ref: '#/components/schemas/BacktestProgress'
          nullable: true
          readOnly: true
        result:
          type: object
          additionalProperties:
            $ref: '#/components/schemas/BacktestCaseResult'
          description: Dictionary mapping case names to case results
          readOnly: true
        error_message:
          type: string
          nullable: true
          readOnly: true
        created_at:
          type: string
          format: date-time
          readOnly: true
        started_at:
          type: string
          format: date-time
          readOnly: true
          nullable: true
        finished_at:
          type: string
          format: date-time
          readOnly: true
          nullable: true
      required:
        - created_at
        - error_message
        - finished_at
        - id
        - params
        - progress
        - resolved_params
        - result
        - started_at
        - status
    StartBacktestRequestRebalancePeriodEnum:
      enum:
        - MONTHLY
      type: string
      description: '* `MONTHLY` - MONTHLY'
    LsTlhFactorEnum:
      enum:
        - quality
        - value
        - growth
      type: string
      description: |-
        * `quality` - quality
        * `value` - value
        * `growth` - growth
    ScenarioAnalysisJobStatusEnum:
      enum:
        - PENDING
        - RUNNING
        - SUCCESS
        - FAILURE
      type: string
      description: |-
        * `PENDING` - PENDING
        * `RUNNING` - RUNNING
        * `SUCCESS` - SUCCESS
        * `FAILURE` - FAILURE
    BacktestResolvedParams:
      type: object
      properties:
        start_date:
          type: string
          format: date
        end_date:
          type: string
          format: date
        rebalance_period:
          $ref: '#/components/schemas/BacktestResolvedParamsRebalancePeriodEnum'
        starting_nav:
          type: number
          format: double
        tax_gamma:
          type: number
          format: double
          nullable: true
        tax_loss_threshold_bps:
          type: number
          format: double
          nullable: true
      required:
        - end_date
        - rebalance_period
        - start_date
        - starting_nav
        - tax_gamma
        - tax_loss_threshold_bps
    BacktestProgress:
      type: object
      properties:
        planned_periods:
          type: integer
        completed_periods:
          type: integer
        last_completed_period:
          type: string
          format: date
          nullable: true
        last_progress_at:
          type: string
          format: date-time
          nullable: true
      required:
        - completed_periods
        - last_completed_period
        - last_progress_at
        - planned_periods
    BacktestCaseResult:
      type: object
      description: Serializer for a single case's backtest results.
      properties:
        run_evidence:
          type: object
          additionalProperties: {}
          description: >-
            Recorded run: schema (1), build (release, engine_version),
            initialization (kind, starting_nav), window (requested_start,
            requested_end, first_solve_date, last_solve_date, last_nav_date),
            periods (date, risk_model_snapshot, effective_tax_gamma,
            effective_tax_loss_threshold_bps, tax_budget_selected_gamma),
            tax_gamma (requested, differing_dates, not_captured_dates).
            Uncaptured values are null.
        complete:
          type: boolean
        backtest_dispositions:
          type: array
          items:
            type: object
            additionalProperties: {}
        input_provenance:
          type: array
          items:
            type: object
            additionalProperties: {}
        recovery_receipts:
          type: array
          items:
            type: object
            additionalProperties: {}
        summaries:
          type: object
          additionalProperties:
            type: object
            additionalProperties:
              type: number
              format: double
          nullable: true
          description: Dictionary mapping quantity names to date-to-value mappings
        tax_summaries:
          type: object
          additionalProperties:
            type: object
            additionalProperties:
              type: number
              format: double
          nullable: true
          description: Dictionary mapping quantity names to date-to-value mappings
        assets:
          type: array
          items:
            $ref: '#/components/schemas/BacktestAsset'
          nullable: true
        comparison_index_returns:
          type: object
          additionalProperties:
            type: string
            format: decimal
            pattern: ^-?\d{0,5}(?:\.\d{0,10})?$
          nullable: true
          description: >-
            Dictionary mapping dates (yyyy-mm-dd) to the return values of a
            reference index.
    BacktestResolvedParamsRebalancePeriodEnum:
      enum:
        - MONTHLY
        - WEEKLY
      type: string
      description: |-
        * `MONTHLY` - MONTHLY
        * `WEEKLY` - WEEKLY
    BacktestAsset:
      type: object
      description: Serializer for individual asset entries in backtest results.
      properties:
        symbol:
          type: string
        TILT_ASSET_ID:
          type: string
          nullable: true
        optimized_weight:
          type: object
          additionalProperties:
            type: number
            format: double
          nullable: true
        benchmark_weight:
          type: object
          additionalProperties:
            type: number
            format: double
          nullable: true
        unrealized_pnl_gain:
          type: object
          additionalProperties:
            type: number
            format: double
          nullable: true
        unrealized_pnl_loss:
          type: object
          additionalProperties:
            type: number
            format: double
          nullable: true
        wash_sale_aware_loss:
          type: object
          additionalProperties:
            type: number
            format: double
          nullable: true
      required:
        - symbol
  securitySchemes:
    ProAPIToken:
      type: apiKey
      in: header
      name: X-Api-Key

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.