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

# 백테스트 시작 연도 하나

> 필요한 권한: `plans:read`



## OpenAPI

````yaml /openapi.json get /v1/plans/{id}/backtest/{startYear}
openapi: 3.1.0
info:
  title: OpenAPI definition
  version: v0
servers:
  - url: https://api.morrowly.app
security:
  - token: []
paths:
  /v1/plans/{id}/backtest/{startYear}:
    get:
      tags:
        - plans
      summary: 백테스트 시작 연도 하나
      description: '필요한 권한: `plans:read`'
      operationId: backtestTrial
      parameters:
        - in: path
          name: id
          required: true
          schema:
            format: uuid
            type: string
        - in: path
          name: startYear
          required: true
          schema:
            format: int32
            type: integer
        - in: query
          name: expense
          required: false
          schema:
            default: 1
            format: double
            type: number
        - in: query
          name: retireAge
          required: false
          schema:
            format: int32
            type: integer
      responses:
        '200':
          content:
            '*/*':
              schema:
                $ref: '#/components/schemas/ApiResponseTrialDetail'
          description: OK
        '401':
          description: 토큰이 없거나 틀리거나 만료됨(본문 없음)
        '403':
          description: 토큰의 권한이 모자람(본문 없음)
components:
  schemas:
    ApiResponseTrialDetail:
      properties:
        data:
          oneOf:
            - $ref: '#/components/schemas/TrialDetail'
            - type: 'null'
        error:
          oneOf:
            - $ref: '#/components/schemas/ErrorMessage'
            - type: 'null'
        result:
          $ref: '#/components/schemas/ResultType'
      required:
        - data
        - error
        - result
      type: object
    TrialDetail:
      properties:
        trial:
          $ref: '#/components/schemas/Trial'
        years:
          items:
            $ref: '#/components/schemas/TrialYear'
          type: array
      required:
        - trial
        - years
      type: object
    ErrorMessage:
      properties:
        code:
          type: string
        data: {}
        message:
          type: string
      required:
        - code
        - data
        - message
      type: object
    ResultType:
      enum:
        - SUCCESS
        - ERROR
      type: string
    Trial:
      properties:
        endNetWorth:
          format: int64
          type: integer
        outcome:
          $ref: '#/components/schemas/Outcome'
        retirementNetWorth:
          format: int64
          type:
            - integer
            - 'null'
        shortfallAge:
          format: int32
          type:
            - integer
            - 'null'
      required:
        - endNetWorth
        - outcome
        - retirementNetWorth
        - shortfallAge
      type: object
    TrialYear:
      properties:
        age:
          format: int32
          type: integer
        historicalYear:
          format: int32
          type:
            - integer
            - 'null'
        investmentReturn:
          format: double
          type: number
        netWorth:
          format: int64
          type: integer
        shortfall:
          type: boolean
        spending:
          format: int64
          type: integer
        withdrawalRate:
          format: double
          type:
            - number
            - 'null'
      required:
        - age
        - historicalYear
        - investmentReturn
        - netWorth
        - shortfall
        - spending
        - withdrawalRate
      type: object
    Outcome:
      enum:
        - LARGE_SURPLUS
        - COMFORTABLE
        - CLOSE_CALL
        - ALMOST
        - SHORTFALL
      type: string
  securitySchemes:
    token:
      scheme: bearer
      type: http

````

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