{
  "swagger": "2.0",
  "x-id": [
    "composer.stagehand.routes.services/api"
  ],
  "info": {
    "title": "Welcome to the Composer API!",
    "description": "This documentation provides information on how to integrate with the Composer API to build automated trading strategies.\n\nThe Composer API enables programmatic access to Symphonies (automated trading strategies), portfolio management, market data, and direct trading capabilities.\n\n### Key Features\n\n- **Symphony**: An automated trading strategy that executes based on predefined rules\n- **Deploy**: Investing capital into a Symphony to begin automated trading\n- **Backtest**: Simulate a Symphony's historical performance before deploying\n- **Direct Trading**: Manual buy/sell orders outside of Symphony automation\n\n### Before you start\n\nBefore you begin integration, you'll need:\n\n- A Composer account, go ahead and [login](https://app.composer.trade/login) or [sign up](https://app.composer.trade/register)\n- Composer API access credentials (Key ID and Secret)\n- Basic familiarity with REST APIs and HTTP requests\n\n### Getting Your API Credentials\n\nTo access the API, you'll need both a Key ID and a Secret:\n\n1. [Log in](https://app.composer.trade/login) to your Composer account\n2. Navigate to the **Settings** section\n3. Select the **API Access** tab\n4. Click on **Generate New API Key**\n5. Your Key ID will be displayed immediately\n6. Your Secret will be shown only once - make sure to copy and store it securely\n\n> **Important Notes on API Keys**\n>\n> - Never expose your API Secret in client-side code or public repositories. It should be securely stored with a proven secret management system.\n> - There is only one active key. *Generating a new key pair* will revoke access to your existing key.\n> - Keys are tied to your Composer account. They will have the same access as the user creating the key.\n\n## Quickstart\n\n### Authentication\n\nAll API requests require authentication using your Key ID and Secret. Include these in your request headers:\n\n```\nx-api-key-id: <key-id>\nauthorization: Bearer <key-secret>\n```\n\nReplace `<key-id>` with your actual Key ID and `<key-secret>` with your actual Secret.\n\n### Base URL\n\nAll API endpoints are relative to the base URL: `https://api.composer.trade/`\n\n### Examples\n\nThis example shows how to list the user's accounts:\n\n```bash\ncurl -X GET \"https://api.composer.trade/api/v0.1/accounts/list\" \\\n  -H \"x-api-key-id: <key-id-value>\" \\\n  -H \"authorization: Bearer <key-secret>\"\n```\n\nThis example demonstrates how to retrieve a CSV activity report for a specific account:\n\n```bash\ncurl -X GET \"https://api.composer.trade/api/v0.1/reports/550e8400-e29b-41d4-a716-446655440000?since=2023-01-01T00:00:00Z&until=2023-01-01T23:59:59.999Z&report-type=trade-activity\" \\\n  -H \"accept: text/csv\" \\\n  -H \"x-api-key-id: <key-id-value>\" \\\n  -H \"authorization: Bearer <key-secret>\"\n```\n\n### Rate Limits\n\nRate limits are applied per API key, on a per-endpoint, per-minute basis. Most endpoints allow **25 requests per minute**. When a limit is exceeded, the request fails with a status code of `429`.\n\nThe following endpoints have higher limits:\n\n| Endpoint | Requests per minute |\n| --- | --- |\n| `GET /api/v0.1/portfolio/accounts/{account-id}/symphonies/{symphony-id}` | 500 |\n| `GET /api/v0.1/user/symphonies` | 250 |\n| `POST /api/v0.1/symphonies` | 250 |\n| `PUT` / `DELETE /api/v0.1/symphonies/{symphony-id}` | 250 |\n| `POST /api/v0.1/symphonies/{symphony-id}/copy` | 250 |\n| `GET /api/v0.1/symphonies/{symphony-id}/score` | 250 |\n| `GET /api/v0.1/symphonies/{symphony-id}/versions` | 250 |\n| `GET /api/v0.1/symphonies/{symphony-id}/versions/{version-id}/score` | 250 |\n| `PATCH /api/v0.1/symphonies/{symphony-id}/versions/{version-id}/score/nodes` | 250 |\n| `POST /api/v0.1/dry-run/trade-preview/{symphony-id}` | 100 |\n\n### Questions?\n\nFor any questions or assistance, contact the Composer support team at help@composer.trade\n",
    "version": "1.0.0"
  },
  "tags": [
    {
      "name": "Accounts",
      "description": "Manage user accounts and view account information including holdings and balances"
    },
    {
      "name": "Portfolio",
      "description": "Access portfolio statistics, holding details, and performance history"
    },
    {
      "name": "Reports",
      "description": "Generate and retrieve account activity reports and statements"
    },
    {
      "name": "Market Data",
      "description": "Real-time and historical market data for equities, options"
    },
    {
      "name": "Symphony",
      "description": "Create, manage, and configure automated trading strategies (Symphonies)"
    },
    {
      "name": "Backtest",
      "description": "Simulate Symphony performance using historical market data"
    },
    {
      "name": "Deploy",
      "description": "Invest capital into Symphonies and manage active deployments including rebalancing and withdrawals"
    },
    {
      "name": "Dry Run",
      "description": "Preview trades and rebalancing actions before execution"
    },
    {
      "name": "Direct Trading",
      "description": "Place manual buy/sell orders outside of Symphony automation"
    }
  ],
  "paths": {
    "/api/v0.1/accounts/list": {
      "get": {
        "responses": {
          "200": {
            "description": "Returns a list of all accounts associated with the authenticated user, including account status, supported asset classes, and key dates",
            "schema": {
              "type": "object",
              "properties": {
                "accounts": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "account_uuid": {
                        "type": "string",
                        "format": "uuid"
                      },
                      "account_foreign_id": {
                        "type": "string",
                        "x-nullable": true
                      },
                      "account_type": {
                        "type": "string"
                      },
                      "asset_classes": {
                        "type": "array",
                        "items": {
                          "type": "string",
                          "enum": [
                            "CRYPTO",
                            "EQUITIES",
                            "OPTIONS"
                          ]
                        }
                      },
                      "direct_tradable_asset_classes": {
                        "type": "object",
                        "properties": {
                          "buy": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "enum": [
                                "CRYPTO",
                                "EQUITIES",
                                "OPTIONS"
                              ]
                            }
                          },
                          "sell": {
                            "type": "array",
                            "items": {
                              "type": "string",
                              "enum": [
                                "CRYPTO",
                                "EQUITIES",
                                "OPTIONS"
                              ]
                            }
                          }
                        },
                        "required": [
                          "buy",
                          "sell"
                        ],
                        "additionalProperties": false
                      },
                      "symphony_tradable_asset_classes": {
                        "type": "array",
                        "items": {
                          "type": "string",
                          "enum": [
                            "CRYPTO",
                            "EQUITIES",
                            "OPTIONS"
                          ]
                        }
                      },
                      "account_number": {
                        "type": "string",
                        "x-nullable": true
                      },
                      "status": {
                        "type": "string"
                      },
                      "broker": {
                        "type": "string"
                      },
                      "created_at": {},
                      "first_deposit_at": {
                        "x-nullable": true
                      },
                      "first_incoming_acats_transfer_at": {
                        "x-nullable": true
                      },
                      "first_deploy_at": {
                        "x-nullable": true
                      },
                      "first_position_created_at": {
                        "x-nullable": true
                      },
                      "first_direct_trade_at": {
                        "x-nullable": true
                      },
                      "is_legacy_crypto_only_account": {
                        "type": "boolean"
                      },
                      "has_queued_deploy": {
                        "type": "boolean"
                      },
                      "has_active_position": {
                        "type": "boolean"
                      }
                    },
                    "required": [
                      "account_uuid",
                      "account_foreign_id",
                      "account_type",
                      "asset_classes",
                      "direct_tradable_asset_classes",
                      "symphony_tradable_asset_classes",
                      "account_number",
                      "status",
                      "broker",
                      "created_at",
                      "first_deposit_at",
                      "first_incoming_acats_transfer_at",
                      "first_deploy_at",
                      "first_position_created_at",
                      "first_direct_trade_at",
                      "is_legacy_crypto_only_account",
                      "has_queued_deploy",
                      "has_active_position"
                    ],
                    "additionalProperties": false
                  }
                }
              },
              "required": [
                "accounts"
              ],
              "additionalProperties": false
            }
          }
        },
        "produces": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "consumes": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "parameters": [],
        "summary": "List all accounts",
        "description": "Retrieve all brokerage accounts owned by the authenticated user. Each account includes information about supported asset classes for direct trading and Symphony automation.",
        "tags": [
          "Accounts"
        ]
      }
    },
    "/api/v0.1/accounts/{account-id}/holdings": {
      "get": {
        "responses": {
          "200": {
            "description": "Returns an array of all current holdings in the account including equities, and options positions",
            "schema": {
              "type": "array",
              "items": {
                "type": "object",
                "properties": {
                  "ticker": {
                    "type": "string"
                  },
                  "quantity": {
                    "type": "number",
                    "format": "double"
                  },
                  "asset_class": {
                    "type": "string",
                    "enum": [
                      "CRYPTO",
                      "EQUITIES",
                      "OPTIONS"
                    ]
                  },
                  "options_details": {
                    "description": "Details of the options contract (only for OPTIONS assets)",
                    "type": "object",
                    "properties": {
                      "underlying_asset_symbol": {
                        "description": "Underlying asset symbol.",
                        "type": "string"
                      },
                      "strike_price": {
                        "description": "Strike price of the option contract.",
                        "type": "number",
                        "format": "double"
                      },
                      "expiry": {
                        "description": "Expiry date of the option contract.",
                        "type": "string",
                        "pattern": "[0-9]{4}-[0-9]{2}-[0-9]{2}"
                      },
                      "contract_type": {
                        "description": "Type of option contract, CALL or PUT.",
                        "type": "string",
                        "enum": [
                          "PUT",
                          "CALL"
                        ]
                      }
                    },
                    "required": [
                      "underlying_asset_symbol",
                      "strike_price",
                      "expiry",
                      "contract_type"
                    ],
                    "additionalProperties": false
                  }
                },
                "required": [
                  "ticker",
                  "quantity",
                  "asset_class"
                ],
                "additionalProperties": false
              },
              "example": [
                {
                  "asset_class": "EQUITIES",
                  "ticker": "AAPL",
                  "quantity": 10
                },
                {
                  "asset_class": "CRYPTO",
                  "ticker": "CRYPTO::BTC//USD",
                  "quantity": 0.43252
                },
                {
                  "asset_class": "OPTIONS",
                  "ticker": "OPTIONS::AAPL250718C00210000//USD",
                  "quantity": 5,
                  "options_details": {
                    "underlying_asset_symbol": "AAPL",
                    "strike_price": 210,
                    "expiry": "2025-07-18",
                    "delta_dollars": 93.27,
                    "contract_type": "CALL"
                  }
                }
              ]
            }
          }
        },
        "produces": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "consumes": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "parameters": [
          {
            "in": "path",
            "name": "account-id",
            "description": "Unique identifier (UUID) of the account",
            "type": "string",
            "required": true,
            "format": "uuid"
          },
          {
            "in": "query",
            "name": "position_type",
            "description": "Filter holdings by position type. DEFAULT_DIRECT returns only direct trades, SYMPHONY returns only Symphony positions, ALL returns both.",
            "type": "string",
            "required": false,
            "enum": [
              "DEFAULT_DIRECT",
              "SYMPHONY",
              "ALL"
            ]
          }
        ],
        "summary": "Get account holdings",
        "description": "Retrieve all current positions held in the specified account. Supports filtering by position type to distinguish between direct trades and Symphony-managed positions.",
        "tags": [
          "Accounts"
        ]
      }
    },
    "/api/v0.1/portfolio/accounts/{account-id}/holding-stats": {
      "get": {
        "responses": {
          "200": {
            "description": "Returns detailed statistics for each holding including price, daily change, and allocation breakdown between direct and Symphony positions",
            "schema": {
              "type": "object",
              "properties": {
                "holdings": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "symbol": {
                        "description": "A special symbol '$USD' represents the unallocated symphony cash remainder.",
                        "type": "string"
                      },
                      "name": {
                        "type": "string",
                        "x-nullable": true
                      },
                      "asset_class": {
                        "type": "string",
                        "enum": [
                          "CRYPTO",
                          "EQUITIES",
                          "OPTIONS"
                        ]
                      },
                      "options_details": {
                        "description": "Details of the options contract (only for OPTIONS assets)",
                        "type": "object",
                        "properties": {
                          "underlying_asset_symbol": {
                            "description": "Underlying asset symbol.",
                            "type": "string"
                          },
                          "strike_price": {
                            "description": "Strike price of the option contract.",
                            "type": "number",
                            "format": "double"
                          },
                          "expiry": {
                            "description": "Expiry date of the option contract.",
                            "type": "string",
                            "pattern": "[0-9]{4}-[0-9]{2}-[0-9]{2}"
                          },
                          "contract_type": {
                            "description": "Type of option contract, CALL or PUT.",
                            "type": "string",
                            "enum": [
                              "PUT",
                              "CALL"
                            ]
                          },
                          "underlying_price": {
                            "description": "The current price of the underlying asset.",
                            "type": "number",
                            "format": "double"
                          },
                          "underlying_price_todays_change": {
                            "description": "The $ change in the price of the underlying asset today.",
                            "type": "number",
                            "format": "double"
                          },
                          "underlying_price_todays_change_percent": {
                            "description": "The % change in the price of the underlying asset today.",
                            "type": "number",
                            "format": "double"
                          }
                        },
                        "required": [
                          "underlying_asset_symbol",
                          "strike_price",
                          "expiry",
                          "contract_type"
                        ],
                        "additionalProperties": false
                      },
                      "price": {
                        "description": "The current price of this asset.",
                        "type": "number",
                        "format": "double"
                      },
                      "price_todays_change": {
                        "description": "The $ change in the price of this asset today.",
                        "type": "number",
                        "format": "double"
                      },
                      "price_todays_change_percent": {
                        "description": "The % change in the price of this asset today.",
                        "type": "number",
                        "format": "double"
                      },
                      "direct": {
                        "description": "The allocation of this holding held directly by the account.",
                        "type": "object",
                        "properties": {
                          "allocation": {
                            "description": "Percentage of portfolio total value.",
                            "type": "number",
                            "format": "double"
                          },
                          "amount": {
                            "type": "number",
                            "format": "double"
                          },
                          "value": {
                            "type": "number",
                            "format": "double"
                          },
                          "direction": {
                            "type": "string",
                            "enum": [
                              "LONG",
                              "SHORT"
                            ],
                            "x-nullable": true
                          }
                        },
                        "required": [
                          "allocation",
                          "amount",
                          "value",
                          "direction"
                        ],
                        "additionalProperties": false
                      },
                      "symphony": {
                        "description": "The aggregate allocation of this holding across all symphonies.",
                        "type": "object",
                        "properties": {
                          "allocation": {
                            "description": "Percentage of portfolio total value.",
                            "type": "number",
                            "format": "double"
                          },
                          "amount": {
                            "type": "number",
                            "format": "double"
                          },
                          "value": {
                            "type": "number",
                            "format": "double"
                          },
                          "direction": {
                            "type": "string",
                            "enum": [
                              "LONG",
                              "SHORT"
                            ],
                            "x-nullable": true
                          },
                          "symphonies": {
                            "description": "The allocation of this holding within each symphony.",
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "symphony_id": {
                                  "type": "string"
                                },
                                "allocation": {
                                  "description": "The percentage of the symphony's total value that is allocated to this holding.",
                                  "type": "number",
                                  "format": "double"
                                },
                                "value": {
                                  "description": "The current market value of this holding in the symphony.",
                                  "type": "number",
                                  "format": "double"
                                }
                              },
                              "required": [
                                "symphony_id",
                                "allocation",
                                "value"
                              ],
                              "additionalProperties": false
                            }
                          }
                        },
                        "required": [
                          "allocation",
                          "amount",
                          "value",
                          "direction",
                          "symphonies"
                        ],
                        "additionalProperties": false
                      },
                      "notional_value": {
                        "description": "For options, the value of underlying assets controlled by the contract. For other assets, the value of the asset.",
                        "type": "number",
                        "format": "double"
                      },
                      "delta_dollars": {
                        "type": "number",
                        "format": "double"
                      },
                      "todays_change_percent": {
                        "description": "Today's gain/loss in % for this asset.",
                        "type": "number",
                        "format": "double"
                      },
                      "todays_change": {
                        "description": "Today's gain/loss in $ for this asset.",
                        "type": "number",
                        "format": "double"
                      },
                      "total_change_percent": {
                        "description": "Total gain/loss in % for this asset. Only provided for Alpaca accounts.",
                        "type": "number",
                        "format": "double"
                      },
                      "total_change": {
                        "description": "Total gain/loss in $ for this asset. Only provided for Alpaca accounts.",
                        "type": "number",
                        "format": "double"
                      },
                      "cost_basis": {
                        "description": "Total cost basis for this asset. Only provided for Alpaca accounts.",
                        "type": "number",
                        "format": "double"
                      },
                      "average_cost_basis": {
                        "description": "Per-share cost basis for this asset. Only provided for Alpaca accounts.",
                        "type": "number",
                        "format": "double"
                      }
                    },
                    "required": [
                      "symbol",
                      "name",
                      "price",
                      "price_todays_change",
                      "price_todays_change_percent",
                      "direct",
                      "symphony",
                      "todays_change_percent",
                      "todays_change"
                    ],
                    "additionalProperties": false
                  }
                }
              },
              "required": [
                "holdings"
              ],
              "additionalProperties": false
            }
          },
          "404": {
            "description": "Account not found",
            "schema": {
              "type": "string"
            }
          },
          "500": {
            "description": "Internal server error",
            "schema": null
          }
        },
        "produces": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "consumes": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "parameters": [
          {
            "in": "path",
            "name": "account-id",
            "description": "",
            "type": "string",
            "required": true,
            "format": "uuid"
          }
        ],
        "summary": "Get holding statistics",
        "description": "Returns the direct and symphony allocations, amounts, and values by holding for an account. Includes current prices, daily change percentages, and notional values.",
        "tags": [
          "Portfolio"
        ]
      }
    },
    "/api/v0.1/portfolio/accounts/{account-id}/symphony-historical-holdings": {
      "get": {
        "responses": {
          "200": {
            "schema": {
              "type": "object",
              "properties": {
                "by_symphony": {
                  "description": "Holdings keyed first by symphony id, then by day (ISO-8601 date).",
                  "type": "object",
                  "additionalProperties": {
                    "description": "Keyed by ISO-8601 date (yyyy-MM-dd).",
                    "type": "object",
                    "additionalProperties": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "symbol": {
                            "type": "string"
                          },
                          "quantity": {
                            "description": "Total quantity of the symbol held on that day.",
                            "type": "number",
                            "format": "double"
                          },
                          "value": {
                            "description": "Total market value of the symbol held on that day.",
                            "type": "number",
                            "format": "double"
                          }
                        },
                        "required": [
                          "symbol",
                          "quantity",
                          "value"
                        ],
                        "additionalProperties": false
                      }
                    }
                  }
                },
                "total_symphony_holdings": {
                  "description": "Account-level holdings across all held symphonies keyed by day (ISO-8601 date), summing each symbol's quantity and value across all symphonies. Present only when `include_aggregate_account_holdings` is true.",
                  "type": "object",
                  "additionalProperties": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "symbol": {
                          "type": "string"
                        },
                        "quantity": {
                          "description": "Total quantity of the symbol held on that day.",
                          "type": "number",
                          "format": "double"
                        },
                        "value": {
                          "description": "Total market value of the symbol held on that day.",
                          "type": "number",
                          "format": "double"
                        }
                      },
                      "required": [
                        "symbol",
                        "quantity",
                        "value"
                      ],
                      "additionalProperties": false
                    }
                  }
                }
              },
              "required": [
                "by_symphony"
              ],
              "additionalProperties": false
            },
            "description": ""
          }
        },
        "produces": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "consumes": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "parameters": [
          {
            "in": "path",
            "name": "account-id",
            "description": "Unique identifier (UUID) of the account",
            "type": "string",
            "required": true,
            "format": "uuid"
          },
          {
            "in": "query",
            "name": "start_date",
            "description": "The inclusive start date of the historical data set. Defaults to 30 days ago.",
            "type": null,
            "required": false,
            "allowEmptyValue": true
          },
          {
            "in": "query",
            "name": "end_date",
            "description": "The inclusive end date of the historical data set. Defaults to 30 days after the start date.",
            "type": null,
            "required": false,
            "allowEmptyValue": true
          },
          {
            "in": "query",
            "name": "include_aggregate_account_holdings",
            "description": "When true, also return `total_symphony_holdings`: an account-level aggregate of symphony holdings per day, summing each symbol's quantity and value across all symphonies.",
            "type": "boolean",
            "required": true,
            "default": false
          }
        ],
        "summary": "Get historical holdings by symphony",
        "description": "Returns the daily quantity and value of each holding of each symphony for the account, grouped first by symphony id and then by day, over the given date range.",
        "tags": [
          "Portfolio"
        ]
      }
    },
    "/api/v0.1/reports/{account-id}": {
      "get": {
        "responses": {
          "200": {
            "description": "Activity report data for the specified date range",
            "schema": {}
          },
          "400": {
            "description": "Invalid request parameters (e.g., invalid date format)",
            "schema": {
              "type": "string"
            }
          },
          "404": {
            "description": "Account not found",
            "schema": {
              "type": "string"
            }
          },
          "415": {
            "description": "Unsupported media type",
            "schema": {
              "type": "string"
            }
          }
        },
        "produces": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "consumes": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "parameters": [
          {
            "in": "path",
            "name": "account-id",
            "description": "Unique identifier (UUID) of the account",
            "type": "string",
            "required": true,
            "format": "uuid"
          },
          {
            "in": "query",
            "name": "since",
            "description": "Start date for the report period (ISO 8601 format)",
            "type": "string",
            "required": true,
            "format": "date-time"
          },
          {
            "in": "query",
            "name": "until",
            "description": "End date for the report period (ISO 8601 format)",
            "type": "string",
            "required": true,
            "format": "date-time"
          },
          {
            "in": "query",
            "name": "report-type",
            "description": "Type of report to generate (e.g., trade-activity)",
            "type": "string",
            "required": true,
            "enum": [
              "trade-activity",
              "non-trade-activity"
            ]
          }
        ],
        "summary": "Return a report for the given account.",
        "tags": [
          "Reports"
        ]
      }
    },
    "/api/v0.1/portfolio/accounts/{account-id}/total-stats": {
      "get": {
        "responses": {
          "200": {
            "schema": {
              "type": "object",
              "properties": {
                "portfolio_value": {
                  "type": "number",
                  "format": "double"
                },
                "simple_return": {
                  "type": "number",
                  "format": "double"
                },
                "time_weighted_return": {
                  "type": "number",
                  "format": "double"
                },
                "net_deposits": {
                  "type": "number",
                  "format": "double"
                },
                "todays_dollar_change": {
                  "type": "number",
                  "format": "double"
                },
                "todays_percent_change": {
                  "type": "number",
                  "format": "double"
                },
                "total_cash": {
                  "type": "number",
                  "format": "double"
                },
                "total_unallocated_cash": {
                  "type": "number",
                  "format": "double"
                },
                "pending_withdrawals": {
                  "description": "Deprecated. Use `pending_net_deposits` instead.",
                  "type": "number",
                  "format": "double",
                  "x-nullable": true
                },
                "pending_net_deposits": {
                  "type": "number",
                  "format": "double",
                  "x-nullable": true
                },
                "pending_deploys_cash": {
                  "type": "number",
                  "format": "double"
                },
                "metrics": {
                  "type": "object",
                  "properties": {
                    "annualized_rate_of_return": {
                      "type": "number",
                      "format": "double",
                      "x-nullable": true
                    },
                    "max_drawdown": {
                      "type": "number",
                      "format": "double",
                      "x-nullable": true
                    },
                    "sharpe_ratio": {
                      "type": "number",
                      "format": "double",
                      "x-nullable": true
                    },
                    "standard_deviation": {
                      "type": "number",
                      "format": "double",
                      "x-nullable": true
                    }
                  },
                  "required": [
                    "annualized_rate_of_return",
                    "max_drawdown",
                    "sharpe_ratio",
                    "standard_deviation"
                  ],
                  "additionalProperties": false
                }
              },
              "required": [
                "portfolio_value",
                "simple_return",
                "time_weighted_return",
                "net_deposits",
                "todays_dollar_change",
                "todays_percent_change",
                "total_cash",
                "total_unallocated_cash",
                "pending_deploys_cash"
              ],
              "additionalProperties": false
            },
            "description": ""
          }
        },
        "produces": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "consumes": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "parameters": [
          {
            "in": "path",
            "name": "account-id",
            "description": "Unique identifier (UUID) of the account",
            "type": "string",
            "required": true,
            "format": "uuid"
          }
        ],
        "summary": "Get aggregate portfolio statistics",
        "tags": [
          "Portfolio"
        ]
      }
    },
    "/api/v0.1/portfolio/accounts/{account-id}/symphony-stats-meta": {
      "get": {
        "responses": {
          "200": {
            "schema": {
              "type": "object",
              "properties": {
                "symphonies": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "id": {
                        "type": "string"
                      },
                      "position_id": {
                        "type": "string"
                      },
                      "as_of": {
                        "x-nullable": true
                      },
                      "holdings": {
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "ticker": {
                              "type": "string"
                            },
                            "price": {
                              "type": "number",
                              "format": "double"
                            },
                            "allocation": {
                              "type": "number",
                              "format": "double"
                            },
                            "amount": {
                              "type": "number",
                              "format": "double"
                            },
                            "value": {
                              "type": "number",
                              "format": "double"
                            },
                            "last_percent_change": {
                              "type": "number",
                              "format": "double"
                            }
                          },
                          "required": [
                            "ticker",
                            "price",
                            "allocation",
                            "amount",
                            "value"
                          ],
                          "additionalProperties": false
                        }
                      },
                      "simple_return": {
                        "type": "number",
                        "format": "double"
                      },
                      "time_weighted_return": {
                        "type": "number",
                        "format": "double"
                      },
                      "net_deposits": {
                        "type": "number",
                        "format": "double"
                      },
                      "last_dollar_change": {
                        "type": "number",
                        "format": "double"
                      },
                      "cash": {
                        "type": "number",
                        "format": "double"
                      },
                      "value": {
                        "type": "number",
                        "format": "double"
                      },
                      "deposit_adjusted_value": {
                        "type": "number",
                        "format": "double"
                      },
                      "annualized_rate_of_return": {
                        "type": "number",
                        "format": "double"
                      },
                      "sharpe_ratio": {
                        "type": "number",
                        "format": "double"
                      },
                      "max_drawdown": {
                        "type": "number",
                        "format": "double"
                      },
                      "standard_deviation": {
                        "type": "number",
                        "format": "double"
                      },
                      "calmar_ratio": {
                        "type": "number",
                        "format": "double"
                      },
                      "trailing_1m_return": {
                        "type": "number",
                        "format": "double"
                      },
                      "trailing_3m_return": {
                        "type": "number",
                        "format": "double"
                      },
                      "last_percent_change": {
                        "type": "number",
                        "format": "double"
                      },
                      "invested_since": {
                        "type": "string",
                        "format": "date"
                      },
                      "last_rebalance_on": {
                        "type": "string",
                        "x-nullable": true,
                        "format": "date-time"
                      },
                      "last_rebalance_attempted_on": {
                        "type": "string",
                        "x-nullable": true,
                        "format": "date-time"
                      },
                      "name": {
                        "type": "string"
                      },
                      "asset_class": {
                        "type": "string",
                        "enum": [
                          "CRYPTO",
                          "EQUITIES",
                          "OPTIONS"
                        ]
                      },
                      "asset_classes": {
                        "type": "array",
                        "items": {
                          "type": "string",
                          "enum": [
                            "CRYPTO",
                            "EQUITIES",
                            "OPTIONS"
                          ]
                        }
                      },
                      "color": {
                        "type": "string"
                      },
                      "community_review_status": {
                        "type": "string",
                        "x-nullable": true
                      },
                      "description": {
                        "type": "string"
                      },
                      "last_semantic_update_at": {
                        "type": "string",
                        "format": "date-time"
                      },
                      "tags": {
                        "type": "array",
                        "items": {
                          "type": "string"
                        }
                      },
                      "rebalance_frequency": {
                        "type": "string"
                      },
                      "is_shared": {
                        "type": "boolean"
                      },
                      "tickers": {
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "name": {
                              "type": "string",
                              "x-nullable": true
                            },
                            "symbol": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "symbol"
                          ],
                          "additionalProperties": false
                        }
                      },
                      "rebalance_corridor_width": {
                        "type": "number",
                        "format": "double"
                      },
                      "next_rebalance_on": {
                        "type": "string",
                        "x-nullable": true,
                        "format": "date"
                      },
                      "may_rebalance_today": {
                        "type": "boolean"
                      },
                      "skip_rebalance_today": {
                        "type": "boolean"
                      },
                      "is_paused": {
                        "type": "boolean"
                      },
                      "paused_by": {
                        "type": "string",
                        "x-nullable": true
                      },
                      "paused_reason": {
                        "type": "string",
                        "enum": [
                          "count_limit",
                          "size_limit",
                          "delinquency",
                          "direct_trading_conversion",
                          "cancellation"
                        ],
                        "x-nullable": true
                      },
                      "node_count": {
                        "description": "Number of user-facing nodes in the symphony's logic tree.",
                        "type": "integer",
                        "format": "int64",
                        "x-nullable": true
                      }
                    },
                    "required": [
                      "id",
                      "position_id",
                      "as_of",
                      "holdings",
                      "simple_return",
                      "time_weighted_return",
                      "net_deposits",
                      "last_dollar_change",
                      "cash",
                      "value",
                      "deposit_adjusted_value",
                      "invested_since",
                      "last_rebalance_on",
                      "last_rebalance_attempted_on",
                      "name",
                      "asset_class",
                      "asset_classes",
                      "color",
                      "community_review_status",
                      "description",
                      "last_semantic_update_at",
                      "tags",
                      "rebalance_frequency",
                      "is_shared",
                      "tickers",
                      "may_rebalance_today",
                      "skip_rebalance_today",
                      "is_paused",
                      "paused_by",
                      "paused_reason",
                      "node_count"
                    ],
                    "additionalProperties": false
                  }
                }
              },
              "required": [
                "symphonies"
              ],
              "additionalProperties": false
            },
            "description": ""
          }
        },
        "produces": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "consumes": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "parameters": [
          {
            "in": "path",
            "name": "account-id",
            "description": "Unique identifier (UUID) of the account",
            "type": "string",
            "required": true,
            "format": "uuid"
          }
        ],
        "summary": "Get aggregate stats per symphony",
        "tags": [
          "Portfolio"
        ]
      }
    },
    "/api/v0.1/portfolio/accounts/{account-id}/symphonies/{symphony-id}": {
      "get": {
        "responses": {
          "200": {
            "schema": {
              "type": "object",
              "properties": {
                "epoch_ms": {
                  "type": "array",
                  "items": {
                    "type": "integer",
                    "format": "int64"
                  }
                },
                "series": {
                  "type": "array",
                  "items": {
                    "type": "number",
                    "format": "double"
                  }
                },
                "deposit_adjusted_series": {
                  "type": "array",
                  "items": {
                    "type": "number",
                    "format": "double"
                  }
                }
              },
              "required": [
                "epoch_ms",
                "series",
                "deposit_adjusted_series"
              ],
              "additionalProperties": false
            },
            "description": ""
          }
        },
        "produces": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "consumes": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "parameters": [
          {
            "in": "path",
            "name": "account-id",
            "description": "",
            "type": "string",
            "required": true,
            "format": "uuid"
          },
          {
            "in": "path",
            "name": "symphony-id",
            "description": "",
            "type": "string",
            "required": true
          }
        ],
        "summary": "Gets the value of a position over time",
        "tags": [
          "Portfolio"
        ]
      }
    },
    "/api/v0.1/portfolio/accounts/{account-id}/portfolio-history": {
      "get": {
        "responses": {
          "200": {
            "schema": {
              "type": "object",
              "properties": {
                "epoch_ms": {
                  "type": "array",
                  "items": {
                    "type": "integer",
                    "format": "int64"
                  }
                },
                "series": {
                  "type": "array",
                  "items": {
                    "type": "number",
                    "format": "double"
                  }
                },
                "cumulative_twr_series": {
                  "type": "array",
                  "items": {
                    "type": "number",
                    "format": "double"
                  }
                }
              },
              "required": [
                "epoch_ms",
                "series"
              ],
              "additionalProperties": false
            },
            "description": ""
          }
        },
        "produces": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "consumes": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "parameters": [
          {
            "in": "path",
            "name": "account-id",
            "description": "Unique identifier (UUID) of the account",
            "type": "string",
            "required": true,
            "format": "uuid"
          }
        ],
        "summary": "Gets the value of the account portfolio over time",
        "tags": [
          "Portfolio"
        ]
      }
    },
    "/api/v1/market-data/options/chain": {
      "get": {
        "responses": {
          "200": {
            "description": "Successful response",
            "schema": {
              "type": "object",
              "properties": {
                "results": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "symbol": {
                        "type": "string",
                        "pattern": "OPTIONS::[A-Z]{1,5}[1-9]?[0-9]{6}[PC][0-9]{8}(?://(?:USD))?(?:@[A-Z]{4,})?"
                      },
                      "name": {
                        "type": "string"
                      },
                      "underlying_asset_symbol": {
                        "type": "string"
                      },
                      "contract_details": {
                        "type": "object",
                        "properties": {
                          "contract_type": {
                            "type": "string",
                            "enum": [
                              "PUT",
                              "CALL"
                            ]
                          },
                          "shares_per_contract": {
                            "type": "number",
                            "format": "double"
                          },
                          "expiry": {},
                          "strike_price": {
                            "type": "number",
                            "format": "double"
                          }
                        },
                        "required": [
                          "contract_type",
                          "shares_per_contract",
                          "expiry",
                          "strike_price"
                        ],
                        "additionalProperties": false
                      },
                      "underlying_asset_price": {
                        "type": "number",
                        "format": "double"
                      },
                      "change_to_break_even": {
                        "type": "number",
                        "format": "double",
                        "x-nullable": true
                      },
                      "payoff_status": {
                        "type": "string",
                        "enum": [
                          "IN_THE_MONEY",
                          "OUT_OF_THE_MONEY",
                          "AT_THE_MONEY"
                        ],
                        "x-nullable": true
                      },
                      "ask": {
                        "type": "object",
                        "properties": {
                          "price": {
                            "type": "number",
                            "format": "double",
                            "x-nullable": true
                          },
                          "size": {
                            "type": "number",
                            "format": "double",
                            "x-nullable": true
                          }
                        },
                        "required": [
                          "price",
                          "size"
                        ],
                        "additionalProperties": false
                      },
                      "bid": {
                        "type": "object",
                        "properties": {
                          "price": {
                            "type": "number",
                            "format": "double",
                            "x-nullable": true
                          },
                          "size": {
                            "type": "number",
                            "format": "double",
                            "x-nullable": true
                          }
                        },
                        "required": [
                          "price",
                          "size"
                        ],
                        "additionalProperties": false
                      },
                      "last_trade": {
                        "type": "object",
                        "properties": {
                          "price": {
                            "type": "number",
                            "format": "double",
                            "x-nullable": true
                          },
                          "size": {
                            "type": "number",
                            "format": "double",
                            "x-nullable": true
                          }
                        },
                        "required": [
                          "price",
                          "size"
                        ],
                        "additionalProperties": false
                      },
                      "todays_change": {
                        "type": "number",
                        "format": "double",
                        "x-nullable": true
                      },
                      "todays_change_percent": {
                        "type": "number",
                        "format": "double",
                        "x-nullable": true
                      },
                      "open_interest": {
                        "type": "number",
                        "format": "double"
                      },
                      "implied_volatility": {
                        "type": "number",
                        "format": "double",
                        "x-nullable": true
                      },
                      "delta_dollars": {
                        "type": "number",
                        "format": "double",
                        "x-nullable": true
                      },
                      "notional_value": {
                        "type": "number",
                        "format": "double",
                        "x-nullable": true
                      },
                      "greeks": {
                        "type": "object",
                        "properties": {
                          "delta": {
                            "type": "number",
                            "format": "double",
                            "x-nullable": true
                          },
                          "gamma": {
                            "type": "number",
                            "format": "double",
                            "x-nullable": true
                          },
                          "theta": {
                            "type": "number",
                            "format": "double",
                            "x-nullable": true
                          },
                          "vega": {
                            "type": "number",
                            "format": "double",
                            "x-nullable": true
                          }
                        },
                        "required": [
                          "delta",
                          "gamma",
                          "theta",
                          "vega"
                        ],
                        "additionalProperties": false
                      },
                      "day": {
                        "type": "object",
                        "properties": {
                          "close": {
                            "type": "number",
                            "format": "double",
                            "x-nullable": true
                          },
                          "high": {
                            "type": "number",
                            "format": "double",
                            "x-nullable": true
                          },
                          "low": {
                            "type": "number",
                            "format": "double",
                            "x-nullable": true
                          },
                          "open": {
                            "type": "number",
                            "format": "double",
                            "x-nullable": true
                          },
                          "last_updated": {
                            "type": "number",
                            "format": "double"
                          },
                          "previous_close": {
                            "type": "number",
                            "format": "double",
                            "x-nullable": true
                          },
                          "volume": {
                            "type": "number",
                            "format": "double",
                            "x-nullable": true
                          },
                          "volume_weighted_average_price": {
                            "description": "Not included for crypto symbols.",
                            "type": "number",
                            "format": "double",
                            "x-nullable": true
                          }
                        },
                        "required": [
                          "close",
                          "high",
                          "low",
                          "open",
                          "previous_close",
                          "volume"
                        ],
                        "additionalProperties": false
                      }
                    },
                    "required": [
                      "symbol",
                      "name",
                      "underlying_asset_symbol",
                      "contract_details",
                      "underlying_asset_price",
                      "change_to_break_even",
                      "payoff_status",
                      "ask",
                      "bid",
                      "last_trade",
                      "todays_change",
                      "todays_change_percent",
                      "open_interest",
                      "implied_volatility",
                      "delta_dollars",
                      "notional_value",
                      "greeks",
                      "day"
                    ],
                    "additionalProperties": false
                  }
                },
                "next_cursor": {
                  "type": "string",
                  "x-nullable": true
                }
              },
              "required": [
                "results",
                "next_cursor"
              ],
              "additionalProperties": false
            }
          }
        },
        "produces": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "consumes": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "parameters": [
          {
            "in": "query",
            "name": "next_cursor",
            "description": "Pagination cursor for fetching the next page of results",
            "type": "string",
            "required": false
          },
          {
            "in": "query",
            "name": "underlying_asset_symbol",
            "description": "Ticker symbol of the underlying asset (e.g., AAPL)",
            "type": "string",
            "required": true
          },
          {
            "in": "query",
            "name": "strike_price",
            "description": "Filter by specific strike price",
            "type": "number",
            "required": false,
            "format": "double"
          },
          {
            "in": "query",
            "name": "expiry",
            "description": "Filter by expiration date (YYYY-MM-DD format)",
            "type": null,
            "required": false
          },
          {
            "in": "query",
            "name": "contract_type",
            "description": "Filter by option type (CALL or PUT)",
            "type": "string",
            "required": false,
            "enum": [
              "CALL",
              "PUT"
            ]
          },
          {
            "in": "query",
            "name": "order",
            "description": "Sort order for results (ascending or descending)",
            "type": "string",
            "required": false,
            "enum": [
              "ASC",
              "DESC"
            ]
          },
          {
            "in": "query",
            "name": "limit",
            "description": "Maximum number of results to return. Default is 10, maximum is 250.",
            "type": "integer",
            "required": false,
            "format": "int64"
          },
          {
            "in": "query",
            "name": "sort_by",
            "description": "Field to sort results by",
            "type": "string",
            "required": false,
            "enum": [
              "symbol",
              "expiry",
              "strike_price"
            ]
          }
        ],
        "summary": "Get options chain",
        "description": "Retrieve the options chain for a specific underlying asset. Returns available contracts with bid/ask prices, greeks, and contract details. Requires authorization to view market data.",
        "tags": [
          "Market Data"
        ]
      }
    },
    "/api/v1/market-data/options/contract": {
      "get": {
        "responses": {
          "200": {
            "schema": {
              "type": "object",
              "properties": {
                "symbol": {
                  "type": "string",
                  "pattern": "OPTIONS::[A-Z]{1,5}[1-9]?[0-9]{6}[PC][0-9]{8}(?://(?:USD))?(?:@[A-Z]{4,})?"
                },
                "name": {
                  "type": "string"
                },
                "underlying_asset_symbol": {
                  "type": "string"
                },
                "contract_details": {
                  "type": "object",
                  "properties": {
                    "contract_type": {
                      "type": "string",
                      "enum": [
                        "PUT",
                        "CALL"
                      ]
                    },
                    "shares_per_contract": {
                      "type": "number",
                      "format": "double"
                    },
                    "expiry": {},
                    "strike_price": {
                      "type": "number",
                      "format": "double"
                    }
                  },
                  "required": [
                    "contract_type",
                    "shares_per_contract",
                    "expiry",
                    "strike_price"
                  ],
                  "additionalProperties": false
                },
                "underlying_asset_price": {
                  "type": "number",
                  "format": "double"
                },
                "change_to_break_even": {
                  "type": "number",
                  "format": "double",
                  "x-nullable": true
                },
                "payoff_status": {
                  "type": "string",
                  "enum": [
                    "IN_THE_MONEY",
                    "OUT_OF_THE_MONEY",
                    "AT_THE_MONEY"
                  ],
                  "x-nullable": true
                },
                "ask": {
                  "type": "object",
                  "properties": {
                    "price": {
                      "type": "number",
                      "format": "double",
                      "x-nullable": true
                    },
                    "size": {
                      "type": "number",
                      "format": "double",
                      "x-nullable": true
                    }
                  },
                  "required": [
                    "price",
                    "size"
                  ],
                  "additionalProperties": false
                },
                "bid": {
                  "type": "object",
                  "properties": {
                    "price": {
                      "type": "number",
                      "format": "double",
                      "x-nullable": true
                    },
                    "size": {
                      "type": "number",
                      "format": "double",
                      "x-nullable": true
                    }
                  },
                  "required": [
                    "price",
                    "size"
                  ],
                  "additionalProperties": false
                },
                "last_trade": {
                  "type": "object",
                  "properties": {
                    "price": {
                      "type": "number",
                      "format": "double",
                      "x-nullable": true
                    },
                    "size": {
                      "type": "number",
                      "format": "double",
                      "x-nullable": true
                    }
                  },
                  "required": [
                    "price",
                    "size"
                  ],
                  "additionalProperties": false
                },
                "todays_change": {
                  "type": "number",
                  "format": "double",
                  "x-nullable": true
                },
                "todays_change_percent": {
                  "type": "number",
                  "format": "double",
                  "x-nullable": true
                },
                "open_interest": {
                  "type": "number",
                  "format": "double"
                },
                "implied_volatility": {
                  "type": "number",
                  "format": "double",
                  "x-nullable": true
                },
                "delta_dollars": {
                  "type": "number",
                  "format": "double",
                  "x-nullable": true
                },
                "notional_value": {
                  "type": "number",
                  "format": "double",
                  "x-nullable": true
                },
                "greeks": {
                  "type": "object",
                  "properties": {
                    "delta": {
                      "type": "number",
                      "format": "double",
                      "x-nullable": true
                    },
                    "gamma": {
                      "type": "number",
                      "format": "double",
                      "x-nullable": true
                    },
                    "theta": {
                      "type": "number",
                      "format": "double",
                      "x-nullable": true
                    },
                    "vega": {
                      "type": "number",
                      "format": "double",
                      "x-nullable": true
                    }
                  },
                  "required": [
                    "delta",
                    "gamma",
                    "theta",
                    "vega"
                  ],
                  "additionalProperties": false
                },
                "day": {
                  "type": "object",
                  "properties": {
                    "close": {
                      "type": "number",
                      "format": "double",
                      "x-nullable": true
                    },
                    "high": {
                      "type": "number",
                      "format": "double",
                      "x-nullable": true
                    },
                    "low": {
                      "type": "number",
                      "format": "double",
                      "x-nullable": true
                    },
                    "open": {
                      "type": "number",
                      "format": "double",
                      "x-nullable": true
                    },
                    "last_updated": {
                      "type": "number",
                      "format": "double"
                    },
                    "previous_close": {
                      "type": "number",
                      "format": "double",
                      "x-nullable": true
                    },
                    "volume": {
                      "type": "number",
                      "format": "double",
                      "x-nullable": true
                    },
                    "volume_weighted_average_price": {
                      "description": "Not included for crypto symbols.",
                      "type": "number",
                      "format": "double",
                      "x-nullable": true
                    }
                  },
                  "required": [
                    "close",
                    "high",
                    "low",
                    "open",
                    "previous_close",
                    "volume"
                  ],
                  "additionalProperties": false
                }
              },
              "required": [
                "symbol",
                "name",
                "underlying_asset_symbol",
                "contract_details",
                "underlying_asset_price",
                "change_to_break_even",
                "payoff_status",
                "ask",
                "bid",
                "last_trade",
                "todays_change",
                "todays_change_percent",
                "open_interest",
                "implied_volatility",
                "delta_dollars",
                "notional_value",
                "greeks",
                "day"
              ],
              "additionalProperties": false
            },
            "description": ""
          }
        },
        "produces": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "consumes": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "parameters": [
          {
            "in": "query",
            "name": "underlying_asset_symbol",
            "description": "",
            "type": "string",
            "required": false,
            "allowEmptyValue": true
          },
          {
            "in": "query",
            "name": "symbol",
            "description": "",
            "type": "string",
            "required": true,
            "pattern": "OPTIONS::[A-Z]{1,5}[1-9]?[0-9]{6}[PC][0-9]{8}(?://(?:USD))?(?:@[A-Z]{4,})?"
          }
        ],
        "summary": "Get options contract market data.",
        "description": "If the user is not authorized to view the market data, a 403 error will be returned.",
        "tags": [
          "Market Data"
        ]
      }
    },
    "/api/v1/market-data/options/overview": {
      "get": {
        "responses": {
          "200": {
            "schema": {
              "type": "object",
              "properties": {
                "symbol": {
                  "type": "string"
                },
                "calendar": {
                  "description": "The list of distinct contract expiration dates available for this symbol.",
                  "type": "array",
                  "items": {
                    "type": "string"
                  }
                }
              },
              "required": [
                "symbol",
                "calendar"
              ],
              "additionalProperties": false
            },
            "description": ""
          }
        },
        "produces": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "consumes": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "parameters": [
          {
            "in": "query",
            "name": "symbol",
            "description": "",
            "type": "string",
            "required": true
          }
        ],
        "summary": "Get an overview of options data.",
        "description": "Returns an overview of options data available for a given ticker.",
        "tags": [
          "Market Data"
        ]
      }
    },
    "/api/v0.1/accounts/{account-id}/info/investor-documents": {
      "get": {
        "responses": {
          "200": {
            "schema": {
              "type": "array",
              "items": {
                "type": "object",
                "properties": {
                  "category": {
                    "type": "string",
                    "enum": [
                      "STATEMENT",
                      "CRYPTO_ACCOUNT_STATEMENT",
                      "TRADE_CONFIRMATION",
                      "FPSL_CONFIRMATION"
                    ]
                  },
                  "date": {
                    "type": "string"
                  },
                  "id": {
                    "type": "string"
                  },
                  "type": {
                    "type": "string"
                  },
                  "url": {
                    "type": "string"
                  },
                  "file_name": {
                    "type": "string"
                  }
                },
                "required": [
                  "category",
                  "date",
                  "id",
                  "type",
                  "url",
                  "file_name"
                ],
                "additionalProperties": false
              }
            },
            "description": ""
          },
          "404": {
            "schema": null,
            "description": ""
          }
        },
        "produces": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "consumes": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "parameters": [
          {
            "in": "path",
            "name": "account-id",
            "description": "Unique identifier (UUID) of the account",
            "type": "string",
            "required": true,
            "format": "uuid"
          },
          {
            "in": "query",
            "name": "category",
            "description": "",
            "type": "string",
            "required": true,
            "enum": [
              "STATEMENT",
              "CRYPTO_ACCOUNT_STATEMENT",
              "TRADE_CONFIRMATION",
              "FPSL_CONFIRMATION"
            ]
          },
          {
            "in": "query",
            "name": "year",
            "description": "",
            "type": "integer",
            "required": true,
            "format": "int64"
          }
        ],
        "summary": "Get investor documents (restricted document categories) — backs the public API.",
        "tags": [
          "Accounts"
        ]
      }
    },
    "/api/v0.1/user/symphonies": {
      "get": {
        "description": "Paginated list of every symphony owned by the authenticated user, including deployed/draft state and the most recent successful rebalance date.",
        "tags": [
          "Symphony"
        ],
        "produces": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "consumes": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "summary": "List the user's symphonies with metadata",
        "responses": {
          "200": {
            "schema": {
              "type": "object",
              "properties": {
                "symphonies": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "id": {
                        "type": "string"
                      },
                      "name": {
                        "type": "string",
                        "x-nullable": true
                      },
                      "description": {
                        "type": "string",
                        "x-nullable": true
                      },
                      "is_shared": {
                        "type": "boolean",
                        "description": "True when the owner has shared this symphony (may or may not also be searchable/public)."
                      },
                      "is_public": {
                        "type": "boolean",
                        "description": "True when the symphony is shared and searchable."
                      },
                      "is_draft": {
                        "type": "boolean",
                        "description": "True when the symphony is not actively deployed (has no live positions)."
                      },
                      "account_id": {
                        "type": "string",
                        "x-nullable": true,
                        "description": "Broker account currently running this symphony; null for drafts with no live position."
                      },
                      "last_rebalance_on": {
                        "type": "string",
                        "x-nullable": true,
                        "format": "date",
                        "description": "Date of the most recent successful rebalance across the user's live positions for this symphony; null when it has never rebalanced (e.g. a draft)."
                      },
                      "created_at": {
                        "type": "string",
                        "format": "date-time"
                      }
                    },
                    "required": [
                      "id",
                      "name",
                      "description",
                      "is_shared",
                      "is_public",
                      "is_draft",
                      "account_id",
                      "last_rebalance_on",
                      "created_at"
                    ],
                    "additionalProperties": false
                  }
                },
                "pagination": {
                  "type": "object",
                  "properties": {
                    "page": {
                      "type": "integer",
                      "format": "int64"
                    },
                    "page_size": {
                      "type": "integer",
                      "format": "int64"
                    },
                    "total": {
                      "type": "integer",
                      "format": "int64",
                      "description": "Total number of rows across all pages, ignoring paging."
                    }
                  },
                  "required": [
                    "page",
                    "page_size",
                    "total"
                  ],
                  "additionalProperties": false
                }
              },
              "required": [
                "symphonies",
                "pagination"
              ],
              "additionalProperties": false
            },
            "description": ""
          }
        },
        "parameters": [
          {
            "in": "query",
            "name": "page",
            "description": "1-indexed page number.",
            "type": "integer",
            "required": false,
            "default": 1,
            "format": "int64",
            "minimum": 1
          },
          {
            "description": "",
            "format": "int64",
            "default": 50,
            "name": "page_size",
            "maximum": 1000,
            "type": "integer",
            "minimum": 1,
            "required": false,
            "in": "query"
          }
        ]
      }
    },
    "/api/v0.1/symphonies/{symphony-id}/backtest": {
      "post": {
        "responses": {
          "200": {
            "schema": {
              "type": "object",
              "properties": {
                "last_semantic_update_at": {
                  "type": "string",
                  "format": "date-time"
                },
                "sparkgraph_url": {
                  "type": "string"
                },
                "dvm_capital": {
                  "type": "object",
                  "additionalProperties": {
                    "type": "object",
                    "additionalProperties": {
                      "type": "number",
                      "format": "double"
                    }
                  },
                  "example": {
                    "a_symphony_id": {
                      "15121": 0.1234,
                      "15122": 0.1235,
                      "15123": 0.1312
                    }
                  }
                },
                "tdvm_weights": {
                  "type": "object",
                  "additionalProperties": {
                    "type": "object",
                    "additionalProperties": {
                      "type": "number",
                      "format": "double"
                    }
                  },
                  "example": {
                    "SPY": {
                      "19000": 0.123,
                      "19001": 0.124
                    }
                  }
                },
                "rebalance_days": {
                  "type": "array",
                  "items": {
                    "type": "integer",
                    "format": "int64"
                  }
                },
                "active_asset_nodes": {
                  "type": "object",
                  "additionalProperties": {
                    "type": "number",
                    "format": "double"
                  }
                },
                "costs": {
                  "type": "object",
                  "properties": {
                    "reg_fee": {
                      "type": "number",
                      "format": "double"
                    },
                    "taf_fee": {
                      "type": "number",
                      "format": "double"
                    },
                    "cat_fee": {
                      "type": "number",
                      "format": "double"
                    },
                    "slippage": {
                      "type": "number",
                      "format": "double"
                    },
                    "spread_markup": {
                      "type": "number",
                      "format": "double"
                    },
                    "subscription": {
                      "type": "number",
                      "format": "double"
                    }
                  },
                  "required": [
                    "reg_fee",
                    "taf_fee",
                    "cat_fee",
                    "slippage",
                    "spread_markup",
                    "subscription"
                  ],
                  "additionalProperties": false
                },
                "last_market_days_value": {
                  "type": "number",
                  "format": "double"
                },
                "last_market_days_holdings": {
                  "type": "object",
                  "additionalProperties": {
                    "type": "number",
                    "format": "double"
                  },
                  "example": {
                    "$USD": 0.3,
                    "SPY": 1.5,
                    "UPRO": 44.4
                  }
                },
                "last_market_day": {
                  "type": "integer",
                  "format": "int64"
                },
                "first_day": {
                  "type": "integer",
                  "format": "int64"
                },
                "legend": {
                  "type": "object",
                  "additionalProperties": {
                    "type": "object",
                    "properties": {
                      "name": {
                        "type": "string"
                      }
                    },
                    "required": [
                      "name"
                    ],
                    "additionalProperties": false
                  }
                },
                "data_warnings": {
                  "type": "object",
                  "additionalProperties": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "message": {
                          "type": "string"
                        },
                        "recommended_start_date": {
                          "type": "string"
                        },
                        "recommended_end_date": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "message"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "example": {
                    "SPY": [
                      {
                        "message": "Cannot compute 14-day RSI until Jun 1 2023",
                        "recommended_start_date": "2023-06-01"
                      }
                    ]
                  }
                },
                "benchmark_errors": {
                  "type": "array",
                  "items": {
                    "type": "string"
                  }
                },
                "stats": {
                  "type": "object",
                  "properties": {
                    "calmar_ratio": {
                      "type": "number",
                      "format": "double"
                    },
                    "cumulative_return": {
                      "type": "number",
                      "format": "double"
                    },
                    "max": {
                      "type": "number",
                      "format": "double"
                    },
                    "max_drawdown": {
                      "type": "number",
                      "format": "double"
                    },
                    "mean": {
                      "type": "number",
                      "format": "double"
                    },
                    "median": {
                      "type": "number",
                      "format": "double"
                    },
                    "min": {
                      "type": "number",
                      "format": "double"
                    },
                    "skewness": {
                      "type": "number",
                      "format": "double"
                    },
                    "kurtosis": {
                      "type": "number",
                      "format": "double"
                    },
                    "sharpe_ratio": {
                      "type": "number",
                      "format": "double"
                    },
                    "sortino_ratio": {
                      "type": "number",
                      "format": "double"
                    },
                    "size": {
                      "type": "integer",
                      "format": "int64"
                    },
                    "standard_deviation": {
                      "type": "number",
                      "format": "double"
                    },
                    "annualized_rate_of_return": {
                      "type": "number",
                      "format": "double"
                    },
                    "annualized_turnover": {
                      "type": "number",
                      "format": "double"
                    },
                    "trailing_one_day_return": {
                      "type": "number",
                      "format": "double"
                    },
                    "trailing_one_week_return": {
                      "type": "number",
                      "format": "double"
                    },
                    "trailing_two_week_return": {
                      "type": "number",
                      "format": "double"
                    },
                    "trailing_one_month_return": {
                      "type": "number",
                      "format": "double"
                    },
                    "trailing_three_month_return": {
                      "type": "number",
                      "format": "double"
                    },
                    "trailing_one_year_return": {
                      "type": "number",
                      "format": "double"
                    },
                    "top_one_day_contribution": {
                      "type": "number",
                      "format": "double"
                    },
                    "top_five_percent_day_contribution": {
                      "type": "number",
                      "format": "double"
                    },
                    "top_ten_percent_day_contribution": {
                      "type": "number",
                      "format": "double"
                    },
                    "herfindahl_index": {
                      "type": "number",
                      "format": "double"
                    },
                    "win_rate": {
                      "type": "number",
                      "format": "double"
                    },
                    "tail_ratio": {
                      "type": "number",
                      "format": "double"
                    },
                    "benchmarks": {
                      "type": "object",
                      "additionalProperties": {
                        "type": "object",
                        "properties": {
                          "calmar_ratio": {
                            "type": "number",
                            "format": "double"
                          },
                          "cumulative_return": {
                            "type": "number",
                            "format": "double"
                          },
                          "max": {
                            "type": "number",
                            "format": "double"
                          },
                          "max_drawdown": {
                            "type": "number",
                            "format": "double"
                          },
                          "mean": {
                            "type": "number",
                            "format": "double"
                          },
                          "median": {
                            "type": "number",
                            "format": "double"
                          },
                          "min": {
                            "type": "number",
                            "format": "double"
                          },
                          "skewness": {
                            "type": "number",
                            "format": "double"
                          },
                          "kurtosis": {
                            "type": "number",
                            "format": "double"
                          },
                          "sharpe_ratio": {
                            "type": "number",
                            "format": "double"
                          },
                          "sortino_ratio": {
                            "type": "number",
                            "format": "double"
                          },
                          "size": {
                            "type": "integer",
                            "format": "int64"
                          },
                          "standard_deviation": {
                            "type": "number",
                            "format": "double"
                          },
                          "annualized_rate_of_return": {
                            "type": "number",
                            "format": "double"
                          },
                          "annualized_turnover": {
                            "type": "number",
                            "format": "double"
                          },
                          "trailing_one_day_return": {
                            "type": "number",
                            "format": "double"
                          },
                          "trailing_one_week_return": {
                            "type": "number",
                            "format": "double"
                          },
                          "trailing_two_week_return": {
                            "type": "number",
                            "format": "double"
                          },
                          "trailing_one_month_return": {
                            "type": "number",
                            "format": "double"
                          },
                          "trailing_three_month_return": {
                            "type": "number",
                            "format": "double"
                          },
                          "trailing_one_year_return": {
                            "type": "number",
                            "format": "double"
                          },
                          "top_one_day_contribution": {
                            "type": "number",
                            "format": "double"
                          },
                          "top_five_percent_day_contribution": {
                            "type": "number",
                            "format": "double"
                          },
                          "top_ten_percent_day_contribution": {
                            "type": "number",
                            "format": "double"
                          },
                          "herfindahl_index": {
                            "type": "number",
                            "format": "double"
                          },
                          "win_rate": {
                            "type": "number",
                            "format": "double"
                          },
                          "tail_ratio": {
                            "type": "number",
                            "format": "double"
                          },
                          "percent": {
                            "type": "object",
                            "properties": {
                              "alpha": {
                                "type": "number",
                                "format": "double"
                              },
                              "beta": {
                                "type": "number",
                                "format": "double"
                              },
                              "r_square": {
                                "type": "number",
                                "format": "double"
                              },
                              "pearson_r": {
                                "type": "number",
                                "format": "double"
                              }
                            },
                            "additionalProperties": false
                          },
                          "log": {
                            "type": "object",
                            "properties": {
                              "alpha": {
                                "type": "number",
                                "format": "double"
                              },
                              "beta": {
                                "type": "number",
                                "format": "double"
                              },
                              "r_square": {
                                "type": "number",
                                "format": "double"
                              },
                              "pearson_r": {
                                "type": "number",
                                "format": "double"
                              }
                            },
                            "additionalProperties": false
                          }
                        },
                        "additionalProperties": false
                      }
                    }
                  },
                  "additionalProperties": false
                }
              },
              "required": [
                "dvm_capital",
                "tdvm_weights",
                "rebalance_days",
                "active_asset_nodes",
                "costs",
                "last_market_days_value",
                "last_market_days_holdings",
                "last_market_day",
                "first_day",
                "data_warnings",
                "stats"
              ],
              "additionalProperties": false
            },
            "description": ""
          },
          "400": {
            "schema": {
              "type": "object",
              "properties": {
                "errors": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "status": {
                        "type": "integer",
                        "format": "int64"
                      },
                      "code": {
                        "type": "string"
                      },
                      "title": {
                        "type": "string"
                      },
                      "meta": {
                        "type": "object",
                        "properties": {}
                      }
                    },
                    "required": [
                      "status",
                      "code",
                      "title",
                      "meta"
                    ],
                    "additionalProperties": false
                  }
                }
              },
              "required": [
                "errors"
              ],
              "additionalProperties": false
            },
            "description": ""
          },
          "500": {
            "schema": {
              "type": "object",
              "properties": {
                "errors": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "status": {
                        "type": "integer",
                        "format": "int64"
                      },
                      "code": {
                        "type": "string"
                      },
                      "title": {
                        "type": "string"
                      }
                    },
                    "required": [
                      "status",
                      "code",
                      "title"
                    ],
                    "additionalProperties": false
                  }
                }
              },
              "required": [
                "errors"
              ],
              "additionalProperties": false
            },
            "description": ""
          }
        },
        "produces": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "consumes": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "parameters": [
          {
            "in": "path",
            "name": "symphony-id",
            "description": "",
            "type": "string",
            "required": true
          },
          {
            "in": "body",
            "name": "body",
            "description": "",
            "required": true,
            "schema": {
              "type": "object",
              "properties": {
                "capital": {
                  "type": "number",
                  "format": "double"
                },
                "abbreviate_days": {
                  "type": "integer",
                  "format": "int64"
                },
                "apply_reg_fee": {
                  "type": "boolean"
                },
                "apply_taf_fee": {
                  "type": "boolean"
                },
                "apply_cat_fee": {
                  "type": "boolean"
                },
                "apply_subscription": {
                  "type": "string",
                  "enum": [
                    "none",
                    "monthly",
                    "yearly"
                  ]
                },
                "backtest_version": {
                  "type": "string",
                  "enum": [
                    "v1",
                    "v2"
                  ]
                },
                "slippage_percent": {
                  "description": "Despite the name this is not in %. 1% is indicated with 0.01, not 1.0.",
                  "type": "number",
                  "format": "double"
                },
                "spread_markup": {
                  "description": "10bps would be 0.001 (0.1%)",
                  "type": "number",
                  "format": "double"
                },
                "start_date": {
                  "type": "string"
                },
                "end_date": {
                  "type": "string"
                },
                "broker": {
                  "default": "ALPACA_WHITE_LABEL",
                  "type": "string",
                  "enum": [
                    "ALPACA_OAUTH",
                    "ALPACA_WHITE_LABEL",
                    "APEX_LEGACY",
                    "alpaca",
                    "apex"
                  ]
                },
                "benchmark_symphonies": {
                  "type": "array",
                  "items": {
                    "type": "string"
                  }
                },
                "benchmark_tickers": {
                  "type": "array",
                  "items": {
                    "type": "string"
                  }
                }
              },
              "required": [
                "capital",
                "apply_reg_fee",
                "apply_taf_fee",
                "slippage_percent",
                "broker"
              ],
              "additionalProperties": false
            }
          }
        ],
        "tags": [
          "Backtest"
        ]
      }
    },
    "/api/v0.1/backtest": {
      "post": {
        "responses": {
          "200": {
            "schema": {
              "type": "object",
              "properties": {
                "last_semantic_update_at": {
                  "type": "string",
                  "format": "date-time"
                },
                "sparkgraph_url": {
                  "type": "string"
                },
                "dvm_capital": {
                  "type": "object",
                  "additionalProperties": {
                    "type": "object",
                    "additionalProperties": {
                      "type": "number",
                      "format": "double"
                    }
                  },
                  "example": {
                    "a_symphony_id": {
                      "15121": 0.1234,
                      "15122": 0.1235,
                      "15123": 0.1312
                    }
                  }
                },
                "tdvm_weights": {
                  "type": "object",
                  "additionalProperties": {
                    "type": "object",
                    "additionalProperties": {
                      "type": "number",
                      "format": "double"
                    }
                  },
                  "example": {
                    "SPY": {
                      "19000": 0.123,
                      "19001": 0.124
                    }
                  }
                },
                "rebalance_days": {
                  "type": "array",
                  "items": {
                    "type": "integer",
                    "format": "int64"
                  }
                },
                "active_asset_nodes": {
                  "type": "object",
                  "additionalProperties": {
                    "type": "number",
                    "format": "double"
                  }
                },
                "costs": {
                  "type": "object",
                  "properties": {
                    "reg_fee": {
                      "type": "number",
                      "format": "double"
                    },
                    "taf_fee": {
                      "type": "number",
                      "format": "double"
                    },
                    "cat_fee": {
                      "type": "number",
                      "format": "double"
                    },
                    "slippage": {
                      "type": "number",
                      "format": "double"
                    },
                    "spread_markup": {
                      "type": "number",
                      "format": "double"
                    },
                    "subscription": {
                      "type": "number",
                      "format": "double"
                    }
                  },
                  "required": [
                    "reg_fee",
                    "taf_fee",
                    "cat_fee",
                    "slippage",
                    "spread_markup",
                    "subscription"
                  ],
                  "additionalProperties": false
                },
                "last_market_days_value": {
                  "type": "number",
                  "format": "double"
                },
                "last_market_days_holdings": {
                  "type": "object",
                  "additionalProperties": {
                    "type": "number",
                    "format": "double"
                  },
                  "example": {
                    "$USD": 0.3,
                    "SPY": 1.5,
                    "UPRO": 44.4
                  }
                },
                "last_market_day": {
                  "type": "integer",
                  "format": "int64"
                },
                "first_day": {
                  "type": "integer",
                  "format": "int64"
                },
                "legend": {
                  "type": "object",
                  "additionalProperties": {
                    "type": "object",
                    "properties": {
                      "name": {
                        "type": "string"
                      }
                    },
                    "required": [
                      "name"
                    ],
                    "additionalProperties": false
                  }
                },
                "data_warnings": {
                  "type": "object",
                  "additionalProperties": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "message": {
                          "type": "string"
                        },
                        "recommended_start_date": {
                          "type": "string"
                        },
                        "recommended_end_date": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "message"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "example": {
                    "SPY": [
                      {
                        "message": "Cannot compute 14-day RSI until Jun 1 2023",
                        "recommended_start_date": "2023-06-01"
                      }
                    ]
                  }
                },
                "benchmark_errors": {
                  "type": "array",
                  "items": {
                    "type": "string"
                  }
                },
                "stats": {
                  "type": "object",
                  "properties": {
                    "calmar_ratio": {
                      "type": "number",
                      "format": "double"
                    },
                    "cumulative_return": {
                      "type": "number",
                      "format": "double"
                    },
                    "max": {
                      "type": "number",
                      "format": "double"
                    },
                    "max_drawdown": {
                      "type": "number",
                      "format": "double"
                    },
                    "mean": {
                      "type": "number",
                      "format": "double"
                    },
                    "median": {
                      "type": "number",
                      "format": "double"
                    },
                    "min": {
                      "type": "number",
                      "format": "double"
                    },
                    "skewness": {
                      "type": "number",
                      "format": "double"
                    },
                    "kurtosis": {
                      "type": "number",
                      "format": "double"
                    },
                    "sharpe_ratio": {
                      "type": "number",
                      "format": "double"
                    },
                    "sortino_ratio": {
                      "type": "number",
                      "format": "double"
                    },
                    "size": {
                      "type": "integer",
                      "format": "int64"
                    },
                    "standard_deviation": {
                      "type": "number",
                      "format": "double"
                    },
                    "annualized_rate_of_return": {
                      "type": "number",
                      "format": "double"
                    },
                    "annualized_turnover": {
                      "type": "number",
                      "format": "double"
                    },
                    "trailing_one_day_return": {
                      "type": "number",
                      "format": "double"
                    },
                    "trailing_one_week_return": {
                      "type": "number",
                      "format": "double"
                    },
                    "trailing_two_week_return": {
                      "type": "number",
                      "format": "double"
                    },
                    "trailing_one_month_return": {
                      "type": "number",
                      "format": "double"
                    },
                    "trailing_three_month_return": {
                      "type": "number",
                      "format": "double"
                    },
                    "trailing_one_year_return": {
                      "type": "number",
                      "format": "double"
                    },
                    "top_one_day_contribution": {
                      "type": "number",
                      "format": "double"
                    },
                    "top_five_percent_day_contribution": {
                      "type": "number",
                      "format": "double"
                    },
                    "top_ten_percent_day_contribution": {
                      "type": "number",
                      "format": "double"
                    },
                    "herfindahl_index": {
                      "type": "number",
                      "format": "double"
                    },
                    "win_rate": {
                      "type": "number",
                      "format": "double"
                    },
                    "tail_ratio": {
                      "type": "number",
                      "format": "double"
                    },
                    "benchmarks": {
                      "type": "object",
                      "additionalProperties": {
                        "type": "object",
                        "properties": {
                          "calmar_ratio": {
                            "type": "number",
                            "format": "double"
                          },
                          "cumulative_return": {
                            "type": "number",
                            "format": "double"
                          },
                          "max": {
                            "type": "number",
                            "format": "double"
                          },
                          "max_drawdown": {
                            "type": "number",
                            "format": "double"
                          },
                          "mean": {
                            "type": "number",
                            "format": "double"
                          },
                          "median": {
                            "type": "number",
                            "format": "double"
                          },
                          "min": {
                            "type": "number",
                            "format": "double"
                          },
                          "skewness": {
                            "type": "number",
                            "format": "double"
                          },
                          "kurtosis": {
                            "type": "number",
                            "format": "double"
                          },
                          "sharpe_ratio": {
                            "type": "number",
                            "format": "double"
                          },
                          "sortino_ratio": {
                            "type": "number",
                            "format": "double"
                          },
                          "size": {
                            "type": "integer",
                            "format": "int64"
                          },
                          "standard_deviation": {
                            "type": "number",
                            "format": "double"
                          },
                          "annualized_rate_of_return": {
                            "type": "number",
                            "format": "double"
                          },
                          "annualized_turnover": {
                            "type": "number",
                            "format": "double"
                          },
                          "trailing_one_day_return": {
                            "type": "number",
                            "format": "double"
                          },
                          "trailing_one_week_return": {
                            "type": "number",
                            "format": "double"
                          },
                          "trailing_two_week_return": {
                            "type": "number",
                            "format": "double"
                          },
                          "trailing_one_month_return": {
                            "type": "number",
                            "format": "double"
                          },
                          "trailing_three_month_return": {
                            "type": "number",
                            "format": "double"
                          },
                          "trailing_one_year_return": {
                            "type": "number",
                            "format": "double"
                          },
                          "top_one_day_contribution": {
                            "type": "number",
                            "format": "double"
                          },
                          "top_five_percent_day_contribution": {
                            "type": "number",
                            "format": "double"
                          },
                          "top_ten_percent_day_contribution": {
                            "type": "number",
                            "format": "double"
                          },
                          "herfindahl_index": {
                            "type": "number",
                            "format": "double"
                          },
                          "win_rate": {
                            "type": "number",
                            "format": "double"
                          },
                          "tail_ratio": {
                            "type": "number",
                            "format": "double"
                          },
                          "percent": {
                            "type": "object",
                            "properties": {
                              "alpha": {
                                "type": "number",
                                "format": "double"
                              },
                              "beta": {
                                "type": "number",
                                "format": "double"
                              },
                              "r_square": {
                                "type": "number",
                                "format": "double"
                              },
                              "pearson_r": {
                                "type": "number",
                                "format": "double"
                              }
                            },
                            "additionalProperties": false
                          },
                          "log": {
                            "type": "object",
                            "properties": {
                              "alpha": {
                                "type": "number",
                                "format": "double"
                              },
                              "beta": {
                                "type": "number",
                                "format": "double"
                              },
                              "r_square": {
                                "type": "number",
                                "format": "double"
                              },
                              "pearson_r": {
                                "type": "number",
                                "format": "double"
                              }
                            },
                            "additionalProperties": false
                          }
                        },
                        "additionalProperties": false
                      }
                    }
                  },
                  "additionalProperties": false
                }
              },
              "required": [
                "dvm_capital",
                "tdvm_weights",
                "rebalance_days",
                "active_asset_nodes",
                "costs",
                "last_market_days_value",
                "last_market_days_holdings",
                "last_market_day",
                "first_day",
                "data_warnings",
                "stats"
              ],
              "additionalProperties": false
            },
            "description": ""
          },
          "400": {
            "schema": {
              "type": "object",
              "properties": {
                "errors": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "status": {
                        "type": "integer",
                        "format": "int64"
                      },
                      "code": {
                        "type": "string"
                      },
                      "title": {
                        "type": "string"
                      },
                      "meta": {
                        "type": "object",
                        "properties": {}
                      }
                    },
                    "required": [
                      "status",
                      "code",
                      "title",
                      "meta"
                    ],
                    "additionalProperties": false
                  }
                }
              },
              "required": [
                "errors"
              ],
              "additionalProperties": false
            },
            "description": ""
          },
          "500": {
            "schema": {
              "type": "object",
              "properties": {
                "errors": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "status": {
                        "type": "integer",
                        "format": "int64"
                      },
                      "code": {
                        "type": "string"
                      },
                      "title": {
                        "type": "string"
                      }
                    },
                    "required": [
                      "status",
                      "code",
                      "title"
                    ],
                    "additionalProperties": false
                  }
                }
              },
              "required": [
                "errors"
              ],
              "additionalProperties": false
            },
            "description": ""
          }
        },
        "produces": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "consumes": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "parameters": [
          {
            "in": "body",
            "name": "body",
            "description": "",
            "required": true,
            "schema": {
              "type": "object",
              "properties": {
                "capital": {
                  "type": "number",
                  "format": "double"
                },
                "abbreviate_days": {
                  "type": "integer",
                  "format": "int64"
                },
                "apply_reg_fee": {
                  "type": "boolean"
                },
                "apply_taf_fee": {
                  "type": "boolean"
                },
                "apply_cat_fee": {
                  "type": "boolean"
                },
                "apply_subscription": {
                  "type": "string",
                  "enum": [
                    "none",
                    "monthly",
                    "yearly"
                  ]
                },
                "backtest_version": {
                  "type": "string",
                  "enum": [
                    "v1",
                    "v2"
                  ]
                },
                "slippage_percent": {
                  "description": "Despite the name this is not in %. 1% is indicated with 0.01, not 1.0.",
                  "type": "number",
                  "format": "double"
                },
                "spread_markup": {
                  "description": "10bps would be 0.001 (0.1%)",
                  "type": "number",
                  "format": "double"
                },
                "start_date": {
                  "type": "string"
                },
                "end_date": {
                  "type": "string"
                },
                "broker": {
                  "default": "ALPACA_WHITE_LABEL",
                  "type": "string",
                  "enum": [
                    "ALPACA_OAUTH",
                    "ALPACA_WHITE_LABEL",
                    "APEX_LEGACY",
                    "alpaca",
                    "apex"
                  ]
                },
                "benchmark_symphonies": {
                  "type": "array",
                  "items": {
                    "type": "string"
                  }
                },
                "benchmark_tickers": {
                  "type": "array",
                  "items": {
                    "type": "string"
                  }
                },
                "sparkgraph_color": {
                  "type": "string"
                },
                "symphony": {
                  "type": "object",
                  "properties": {
                    "raw_value": {
                      "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1root",
                      "x-anyOf": [
                        {
                          "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1root"
                        },
                        {
                          "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1root"
                        },
                        {
                          "$ref": "#/definitions/node~1root"
                        }
                      ]
                    }
                  },
                  "required": [
                    "raw_value"
                  ],
                  "additionalProperties": false,
                  "x-anyOf": [
                    {
                      "type": "object",
                      "properties": {
                        "raw_value": {
                          "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1root",
                          "x-anyOf": [
                            {
                              "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1root"
                            },
                            {
                              "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1root"
                            },
                            {
                              "$ref": "#/definitions/node~1root"
                            }
                          ]
                        }
                      },
                      "required": [
                        "raw_value"
                      ],
                      "additionalProperties": false
                    },
                    {
                      "type": "object",
                      "properties": {
                        "encoded_value": {
                          "type": "string"
                        },
                        "encoding_type": {
                          "type": "string",
                          "enum": [
                            "transit_json"
                          ]
                        }
                      },
                      "required": [
                        "encoded_value",
                        "encoding_type"
                      ],
                      "additionalProperties": false
                    }
                  ]
                }
              },
              "required": [
                "capital",
                "apply_reg_fee",
                "apply_taf_fee",
                "slippage_percent",
                "broker",
                "symphony"
              ],
              "additionalProperties": false
            }
          }
        ],
        "tags": [
          "Backtest"
        ]
      }
    },
    "/api/v0.1/symphonies": {
      "post": {
        "description": "Create a new automated trading strategy (Symphony). Define the logic tree, asset class, display settings, and optional benchmarks for performance comparison.",
        "tags": [
          "Symphony"
        ],
        "produces": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "consumes": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "summary": "Create a new Symphony",
        "responses": {
          "201": {
            "description": "Successfully created",
            "schema": {
              "type": "object",
              "properties": {
                "symphony_id": {
                  "type": "string"
                },
                "version_id": {
                  "type": "string"
                }
              },
              "required": [
                "symphony_id",
                "version_id"
              ],
              "additionalProperties": false
            }
          }
        },
        "parameters": [
          {
            "in": "body",
            "name": "body",
            "description": "",
            "required": true,
            "schema": {
              "type": "object",
              "properties": {
                "name": {
                  "description": "Required on write. Optional/nullable on read due to old data.",
                  "type": "string"
                },
                "asset_class": {
                  "default": "EQUITIES",
                  "type": "string",
                  "enum": [
                    "EQUITIES",
                    "CRYPTO"
                  ]
                },
                "description": {
                  "type": "string"
                },
                "color": {
                  "type": "string",
                  "example": "#FFBB38"
                },
                "hashtag": {
                  "type": "string",
                  "example": "#BTD"
                },
                "tags": {
                  "type": "array",
                  "items": {
                    "type": "string"
                  },
                  "example": [
                    "Paired Switching",
                    "Momentum"
                  ]
                },
                "symphony": {
                  "type": "object",
                  "properties": {
                    "raw_value": {
                      "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1root",
                      "x-anyOf": [
                        {
                          "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1root"
                        },
                        {
                          "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1root"
                        },
                        {
                          "$ref": "#/definitions/node~1root"
                        }
                      ]
                    }
                  },
                  "required": [
                    "raw_value"
                  ],
                  "additionalProperties": false,
                  "x-anyOf": [
                    {
                      "type": "object",
                      "properties": {
                        "raw_value": {
                          "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1root",
                          "x-anyOf": [
                            {
                              "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1root"
                            },
                            {
                              "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1root"
                            },
                            {
                              "$ref": "#/definitions/node~1root"
                            }
                          ]
                        }
                      },
                      "required": [
                        "raw_value"
                      ],
                      "additionalProperties": false
                    },
                    {
                      "type": "object",
                      "properties": {
                        "encoded_value": {
                          "type": "string"
                        },
                        "encoding_type": {
                          "type": "string",
                          "enum": [
                            "transit_json"
                          ]
                        }
                      },
                      "required": [
                        "encoded_value",
                        "encoding_type"
                      ],
                      "additionalProperties": false
                    }
                  ]
                },
                "benchmarks": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "is_checked": {
                        "type": "boolean"
                      },
                      "color": {
                        "type": "string",
                        "example": "#17BAFF"
                      },
                      "id": {
                        "type": "string",
                        "example": "SPY"
                      },
                      "type": {
                        "type": "string",
                        "enum": [
                          "symphony",
                          "ticker"
                        ],
                        "example": "ticker"
                      }
                    },
                    "required": [
                      "is_checked",
                      "color",
                      "id",
                      "type"
                    ],
                    "additionalProperties": false
                  }
                },
                "share_with_everyone": {
                  "type": "boolean"
                }
              },
              "required": [
                "name",
                "asset_class",
                "hashtag",
                "symphony"
              ],
              "additionalProperties": false
            }
          }
        ]
      }
    },
    "/api/v0.1/symphonies/{symphony-id}": {
      "put": {
        "responses": {
          "200": {
            "schema": {
              "type": "object",
              "properties": {
                "existing_version_id": {
                  "type": "string"
                },
                "version_id": {
                  "type": "string"
                }
              },
              "required": [
                "existing_version_id"
              ],
              "additionalProperties": false
            },
            "description": ""
          }
        },
        "produces": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "consumes": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "parameters": [
          {
            "in": "body",
            "name": "body",
            "description": "",
            "required": true,
            "schema": {
              "type": "object",
              "properties": {
                "name": {
                  "type": "string"
                },
                "description": {
                  "type": "string"
                },
                "color": {
                  "type": "string",
                  "example": "#FFBB38"
                },
                "hashtag": {
                  "type": "string",
                  "example": "#BTD"
                },
                "tags": {
                  "type": "array",
                  "items": {
                    "type": "string"
                  },
                  "example": [
                    "Paired Switching",
                    "Momentum"
                  ]
                },
                "symphony": {
                  "type": "object",
                  "properties": {
                    "raw_value": {
                      "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1root",
                      "x-anyOf": [
                        {
                          "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1root"
                        },
                        {
                          "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1root"
                        },
                        {
                          "$ref": "#/definitions/node~1root"
                        }
                      ]
                    }
                  },
                  "required": [
                    "raw_value"
                  ],
                  "additionalProperties": false,
                  "x-anyOf": [
                    {
                      "type": "object",
                      "properties": {
                        "raw_value": {
                          "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1root",
                          "x-anyOf": [
                            {
                              "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1root"
                            },
                            {
                              "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1root"
                            },
                            {
                              "$ref": "#/definitions/node~1root"
                            }
                          ]
                        }
                      },
                      "required": [
                        "raw_value"
                      ],
                      "additionalProperties": false
                    },
                    {
                      "type": "object",
                      "properties": {
                        "encoded_value": {
                          "type": "string"
                        },
                        "encoding_type": {
                          "type": "string",
                          "enum": [
                            "transit_json"
                          ]
                        }
                      },
                      "required": [
                        "encoded_value",
                        "encoding_type"
                      ],
                      "additionalProperties": false
                    }
                  ]
                },
                "benchmarks": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "is_checked": {
                        "type": "boolean"
                      },
                      "color": {
                        "type": "string",
                        "example": "#17BAFF"
                      },
                      "id": {
                        "type": "string",
                        "example": "SPY"
                      },
                      "type": {
                        "type": "string",
                        "enum": [
                          "symphony",
                          "ticker"
                        ],
                        "example": "ticker"
                      }
                    },
                    "required": [
                      "is_checked",
                      "color",
                      "id",
                      "type"
                    ],
                    "additionalProperties": false
                  }
                },
                "share_with_everyone": {
                  "type": "boolean"
                }
              },
              "additionalProperties": false
            }
          },
          {
            "in": "path",
            "name": "symphony-id",
            "description": "Unique identifier for the Symphony",
            "type": "string",
            "required": true
          }
        ],
        "summary": "Update an existing symphony",
        "tags": [
          "Symphony"
        ]
      },
      "delete": {
        "responses": {
          "204": {
            "description": ""
          }
        },
        "produces": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "consumes": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "parameters": [
          {
            "in": "path",
            "name": "symphony-id",
            "description": "Unique identifier for the Symphony",
            "type": "string",
            "required": true
          }
        ],
        "summary": "Delete an existing symphony",
        "tags": [
          "Symphony"
        ]
      }
    },
    "/api/v0.1/search/symphonies": {
      "post": {
        "responses": {
          "200": {
            "description": "Returns matching Symphonies with performance statistics and metadata",
            "schema": {
              "type": "array",
              "items": {
                "type": "object",
                "properties": {
                  "symphony_sid": {
                    "type": "string"
                  },
                  "name": {
                    "type": "string",
                    "x-nullable": true
                  },
                  "description": {
                    "type": "string",
                    "x-nullable": true
                  },
                  "asset_classes": {
                    "type": "array",
                    "items": {
                      "type": "string",
                      "enum": [
                        "EQUITIES",
                        "CRYPTO"
                      ]
                    }
                  },
                  "rebalance_frequency": {
                    "type": "string"
                  },
                  "rebalance_corridor_width": {
                    "type": "number",
                    "format": "double",
                    "x-nullable": true
                  },
                  "sparkgraph_gcs_url": {
                    "type": "string",
                    "x-nullable": true
                  },
                  "color": {
                    "type": "string",
                    "x-nullable": true
                  },
                  "num_node_asset": {
                    "type": "integer",
                    "format": "int64"
                  },
                  "num_node_filter": {
                    "type": "integer",
                    "format": "int64"
                  },
                  "num_node_group": {
                    "type": "integer",
                    "format": "int64"
                  },
                  "num_node_if": {
                    "type": "integer",
                    "format": "int64"
                  },
                  "num_node_if_child": {
                    "type": "integer",
                    "format": "int64"
                  },
                  "num_node_wt_cash_equal": {
                    "type": "integer",
                    "format": "int64"
                  },
                  "num_node_wt_cash_specified": {
                    "type": "integer",
                    "format": "int64"
                  },
                  "num_node_wt_inverse_vol": {
                    "type": "integer",
                    "format": "int64"
                  },
                  "oos_annualized_rate_of_return": {
                    "type": "number",
                    "format": "double",
                    "x-nullable": true
                  },
                  "oos_annualized_turnover": {
                    "type": "number",
                    "format": "double",
                    "x-nullable": true
                  },
                  "oos_calmar_ratio": {
                    "type": "number",
                    "format": "double",
                    "x-nullable": true
                  },
                  "oos_cumulative_return": {
                    "type": "number",
                    "format": "double",
                    "x-nullable": true
                  },
                  "oos_herfindahl_index": {
                    "type": "number",
                    "format": "double",
                    "x-nullable": true
                  },
                  "oos_kurtosis": {
                    "type": "number",
                    "format": "double",
                    "x-nullable": true
                  },
                  "oos_max_drawdown": {
                    "type": "number",
                    "format": "double",
                    "x-nullable": true
                  },
                  "oos_num_backtest_days": {
                    "type": "integer",
                    "format": "int64",
                    "x-nullable": true
                  },
                  "oos_sharpe_ratio": {
                    "type": "number",
                    "format": "double",
                    "x-nullable": true
                  },
                  "oos_skewness": {
                    "type": "number",
                    "format": "double",
                    "x-nullable": true
                  },
                  "oos_sortino_ratio": {
                    "type": "number",
                    "format": "double",
                    "x-nullable": true
                  },
                  "oos_spy_alpha": {
                    "type": "number",
                    "format": "double",
                    "x-nullable": true
                  },
                  "oos_spy_annualized_rate_of_return": {
                    "type": "number",
                    "format": "double",
                    "x-nullable": true
                  },
                  "oos_spy_beta": {
                    "type": "number",
                    "format": "double",
                    "x-nullable": true
                  },
                  "oos_spy_calmar_ratio": {
                    "type": "number",
                    "format": "double",
                    "x-nullable": true
                  },
                  "oos_spy_cumulative_return": {
                    "type": "number",
                    "format": "double",
                    "x-nullable": true
                  },
                  "oos_spy_max_drawdown": {
                    "type": "number",
                    "format": "double",
                    "x-nullable": true
                  },
                  "oos_spy_pearson_r": {
                    "type": "number",
                    "format": "double",
                    "x-nullable": true
                  },
                  "oos_spy_r_square": {
                    "type": "number",
                    "format": "double",
                    "x-nullable": true
                  },
                  "oos_spy_sharpe_ratio": {
                    "type": "number",
                    "format": "double",
                    "x-nullable": true
                  },
                  "oos_spy_standard_deviation": {
                    "type": "number",
                    "format": "double",
                    "x-nullable": true
                  },
                  "oos_spy_trailing_one_month_return": {
                    "type": "number",
                    "format": "double",
                    "x-nullable": true
                  },
                  "oos_spy_trailing_one_year_return": {
                    "type": "number",
                    "format": "double",
                    "x-nullable": true
                  },
                  "oos_spy_trailing_three_month_return": {
                    "type": "number",
                    "format": "double",
                    "x-nullable": true
                  },
                  "oos_standard_deviation": {
                    "type": "number",
                    "format": "double",
                    "x-nullable": true
                  },
                  "oos_tail_ratio": {
                    "type": "number",
                    "format": "double",
                    "x-nullable": true
                  },
                  "oos_top_five_percent_day_contribution": {
                    "type": "number",
                    "format": "double",
                    "x-nullable": true
                  },
                  "oos_top_one_day_contribution": {
                    "type": "number",
                    "format": "double",
                    "x-nullable": true
                  },
                  "oos_top_ten_percent_day_contribution": {
                    "type": "number",
                    "format": "double",
                    "x-nullable": true
                  },
                  "oos_trailing_one_day_return": {
                    "type": "number",
                    "format": "double",
                    "x-nullable": true
                  },
                  "oos_trailing_one_month_return": {
                    "type": "number",
                    "format": "double",
                    "x-nullable": true
                  },
                  "oos_trailing_one_week_return": {
                    "type": "number",
                    "format": "double",
                    "x-nullable": true
                  },
                  "oos_trailing_one_year_return": {
                    "type": "number",
                    "format": "double",
                    "x-nullable": true
                  },
                  "oos_trailing_three_month_return": {
                    "type": "number",
                    "format": "double",
                    "x-nullable": true
                  },
                  "oos_trailing_two_week_return": {
                    "type": "number",
                    "format": "double",
                    "x-nullable": true
                  },
                  "oos_win_rate": {
                    "type": "number",
                    "format": "double",
                    "x-nullable": true
                  },
                  "ai_description": {
                    "type": "object",
                    "properties": {
                      "summary": {
                        "type": "string"
                      },
                      "categories": {
                        "type": "string"
                      },
                      "how_it_works": {
                        "type": "string"
                      },
                      "value_proposition": {
                        "type": "string"
                      }
                    },
                    "additionalProperties": false,
                    "x-nullable": true
                  }
                },
                "required": [
                  "symphony_sid",
                  "name",
                  "description",
                  "asset_classes",
                  "rebalance_frequency",
                  "rebalance_corridor_width",
                  "sparkgraph_gcs_url",
                  "num_node_asset",
                  "num_node_filter",
                  "num_node_group",
                  "num_node_if",
                  "num_node_if_child",
                  "num_node_wt_cash_equal",
                  "num_node_wt_cash_specified",
                  "num_node_wt_inverse_vol",
                  "oos_annualized_rate_of_return",
                  "oos_calmar_ratio",
                  "oos_cumulative_return",
                  "oos_max_drawdown",
                  "oos_num_backtest_days",
                  "oos_sharpe_ratio",
                  "oos_spy_alpha",
                  "oos_spy_annualized_rate_of_return",
                  "oos_spy_beta",
                  "oos_spy_calmar_ratio",
                  "oos_spy_cumulative_return",
                  "oos_spy_max_drawdown",
                  "oos_spy_pearson_r",
                  "oos_spy_r_square",
                  "oos_spy_sharpe_ratio",
                  "oos_spy_standard_deviation",
                  "oos_spy_trailing_one_month_return",
                  "oos_spy_trailing_one_year_return",
                  "oos_spy_trailing_three_month_return",
                  "oos_standard_deviation",
                  "oos_trailing_one_month_return",
                  "oos_trailing_one_year_return",
                  "oos_trailing_three_month_return"
                ],
                "additionalProperties": false
              }
            }
          },
          "400": {
            "description": "Bad request - invalid search parameters",
            "schema": {
              "type": "object",
              "properties": {
                "error": {
                  "type": "string"
                },
                "details": {
                  "type": "object",
                  "properties": {},
                  "additionalProperties": false
                }
              },
              "required": [
                "error",
                "details"
              ],
              "additionalProperties": false
            }
          }
        },
        "produces": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "consumes": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "parameters": [
          {
            "in": "body",
            "name": "body",
            "description": "",
            "required": true,
            "schema": {
              "type": "object",
              "properties": {
                "where": {
                  "type": "array",
                  "items": {}
                },
                "order_by": {
                  "type": "array",
                  "items": {
                    "type": "array",
                    "items": {
                      "type": "string"
                    }
                  }
                },
                "offset": {
                  "default": 0,
                  "type": "integer",
                  "format": "int64"
                }
              },
              "required": [
                "offset"
              ],
              "additionalProperties": false
            }
          }
        ],
        "summary": "Search our database of publicly shared symphonies"
      }
    },
    "/api/v0.1/symphonies/{symphony-id}/score": {
      "get": {
        "responses": {
          "200": {
            "schema": {
              "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1root",
              "x-anyOf": [
                {
                  "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1root"
                },
                {
                  "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1root"
                },
                {
                  "$ref": "#/definitions/node~1root"
                }
              ]
            },
            "description": ""
          }
        },
        "produces": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "consumes": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "parameters": [
          {
            "in": "path",
            "name": "symphony-id",
            "description": "Unique identifier for the Symphony",
            "type": "string",
            "required": true
          },
          {
            "in": "query",
            "name": "score_version",
            "description": "",
            "type": "string",
            "required": true,
            "default": "v1",
            "enum": [
              "v1",
              "v2"
            ]
          }
        ],
        "summary": "Get an existing symphony's EDN",
        "tags": [
          "Symphony"
        ]
      }
    },
    "/api/v0.1/symphonies/{symphony-id}/versions": {
      "get": {
        "responses": {
          "200": {
            "schema": {
              "type": "array",
              "items": {
                "type": "object",
                "properties": {
                  "version_id": {
                    "type": "string"
                  },
                  "created_at": {
                    "type": "string",
                    "format": "date-time"
                  }
                },
                "required": [
                  "version_id",
                  "created_at"
                ],
                "additionalProperties": false
              }
            },
            "description": ""
          }
        },
        "produces": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "consumes": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "parameters": [
          {
            "in": "path",
            "name": "symphony-id",
            "description": "Unique identifier for the Symphony",
            "type": "string",
            "required": true
          }
        ],
        "summary": "Get all versions for a symphony",
        "tags": [
          "Symphony"
        ]
      }
    },
    "/api/v0.1/symphonies/{symphony-id}/versions/{version-id}/score": {
      "get": {
        "responses": {
          "200": {
            "schema": {
              "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1root",
              "x-anyOf": [
                {
                  "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1root"
                },
                {
                  "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1root"
                },
                {
                  "$ref": "#/definitions/node~1root"
                }
              ]
            },
            "description": ""
          }
        },
        "produces": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "consumes": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "parameters": [
          {
            "in": "path",
            "name": "symphony-id",
            "description": "Unique identifier for the Symphony",
            "type": "string",
            "required": true
          },
          {
            "in": "path",
            "name": "version-id",
            "description": "Unique identifier for the Symphony version",
            "type": "string",
            "required": true
          },
          {
            "in": "query",
            "name": "score_version",
            "description": "",
            "type": "string",
            "required": true,
            "default": "v1",
            "enum": [
              "v1",
              "v2"
            ]
          }
        ],
        "summary": "Get an existing symphony version's EDN",
        "tags": [
          "Symphony"
        ]
      }
    },
    "/api/v0.1/symphonies/{symphony-id}/versions/{version-id}/score/nodes": {
      "patch": {
        "description": "Update specific nodes of an existing symphony logic tree. Only the latest version of the symphony can be updated.",
        "tags": [
          "Symphony"
        ],
        "produces": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "consumes": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "summary": "Partially update latest version of a symphony EDN",
        "responses": {
          "200": {
            "schema": {
              "type": "object",
              "properties": {
                "symphony_id": {
                  "type": "string"
                },
                "version_id": {
                  "type": "string"
                }
              },
              "required": [
                "symphony_id",
                "version_id"
              ],
              "additionalProperties": false
            },
            "description": ""
          }
        },
        "parameters": [
          {
            "in": "path",
            "name": "symphony-id",
            "description": "Unique identifier for the Symphony",
            "type": "string",
            "required": true
          },
          {
            "in": "path",
            "name": "version-id",
            "description": "Unique identifier for the Symphony version",
            "type": "string",
            "required": true
          },
          {
            "in": "body",
            "name": "body",
            "description": "",
            "required": true,
            "schema": {
              "type": "object",
              "properties": {
                "updates": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "lhs-fn-params": {
                        "type": "object",
                        "additionalProperties": {
                          "type": "integer",
                          "format": "int64",
                          "x-anyOf": [
                            {
                              "type": "integer",
                              "format": "int64"
                            },
                            {
                              "type": "number",
                              "format": "double"
                            }
                          ]
                        }
                      },
                      "select-fn": {
                        "type": "string",
                        "enum": [
                          "top",
                          "bottom"
                        ]
                      },
                      "select-n": {
                        "type": "integer",
                        "format": "int64",
                        "x-anyOf": [
                          {
                            "type": "integer",
                            "format": "int64"
                          },
                          {
                            "type": "string"
                          }
                        ]
                      },
                      "rhs-fn": {
                        "type": "string",
                        "enum": [
                          "cumulative-return",
                          "current-price",
                          "exponential-moving-average-price",
                          "max-drawdown",
                          "moving-average-price",
                          "moving-average-return",
                          "relative-strength-index",
                          "standard-deviation-price",
                          "standard-deviation-return",
                          "percentage-price-oscillator",
                          "percentage-price-oscillator-signal",
                          "moving-average-convergence-divergence",
                          "moving-average-convergence-divergence-signal",
                          "lower-bollinger",
                          "upper-bollinger"
                        ]
                      },
                      "fn": {
                        "type": "string",
                        "enum": [
                          "cumulative-return",
                          "current-price",
                          "exponential-moving-average-price",
                          "max-drawdown",
                          "moving-average-price",
                          "moving-average-return",
                          "relative-strength-index",
                          "standard-deviation-price",
                          "standard-deviation-return",
                          "percentage-price-oscillator",
                          "percentage-price-oscillator-signal",
                          "moving-average-convergence-divergence",
                          "moving-average-convergence-divergence-signal",
                          "lower-bollinger",
                          "upper-bollinger"
                        ]
                      },
                      "is-else-condition?": {
                        "enum": [
                          true,
                          false
                        ]
                      },
                      "rhs-fixed-value?": {
                        "type": "boolean"
                      },
                      "suppress-incomplete-warnings?": {
                        "type": "boolean"
                      },
                      "window-days": {
                        "type": "string",
                        "x-anyOf": [
                          {
                            "type": "string"
                          },
                          {
                            "type": "integer",
                            "format": "int64"
                          }
                        ]
                      },
                      "name": {
                        "type": "string",
                        "x-anyOf": [
                          {
                            "type": "string"
                          },
                          {
                            "type": "string",
                            "x-nullable": true
                          }
                        ]
                      },
                      "sort-by-fn": {
                        "type": "string",
                        "enum": [
                          "cumulative-return",
                          "current-price",
                          "exponential-moving-average-price",
                          "max-drawdown",
                          "moving-average-price",
                          "moving-average-return",
                          "relative-strength-index",
                          "standard-deviation-price",
                          "standard-deviation-return",
                          "percentage-price-oscillator",
                          "percentage-price-oscillator-signal",
                          "moving-average-convergence-divergence",
                          "moving-average-convergence-divergence-signal",
                          "lower-bollinger",
                          "upper-bollinger"
                        ]
                      },
                      "constant": {
                        "type": "number",
                        "format": "double"
                      },
                      "ticker": {
                        "type": "string",
                        "x-anyOf": [
                          {
                            "type": "string"
                          },
                          {
                            "const": "%"
                          }
                        ]
                      },
                      "lhs-fn": {
                        "type": "string",
                        "enum": [
                          "cumulative-return",
                          "current-price",
                          "exponential-moving-average-price",
                          "max-drawdown",
                          "moving-average-price",
                          "moving-average-return",
                          "relative-strength-index",
                          "standard-deviation-price",
                          "standard-deviation-return",
                          "percentage-price-oscillator",
                          "percentage-price-oscillator-signal",
                          "moving-average-convergence-divergence",
                          "moving-average-convergence-divergence-signal",
                          "lower-bollinger",
                          "upper-bollinger"
                        ]
                      },
                      "params": {
                        "type": "object",
                        "additionalProperties": {
                          "type": "integer",
                          "format": "int64",
                          "x-anyOf": [
                            {
                              "type": "integer",
                              "format": "int64"
                            },
                            {
                              "type": "number",
                              "format": "double"
                            }
                          ]
                        }
                      },
                      "sort-by-window-days": {
                        "type": "integer",
                        "format": "int64",
                        "x-anyOf": [
                          {
                            "type": "integer",
                            "format": "int64"
                          },
                          {
                            "type": "string"
                          }
                        ]
                      },
                      "rhs-window-days": {
                        "type": "integer",
                        "format": "int64",
                        "x-anyOf": [
                          {
                            "type": "integer",
                            "format": "int64"
                          },
                          {
                            "type": "string"
                          }
                        ]
                      },
                      "has_marketcap": {
                        "type": "boolean"
                      },
                      "lhs-window-days": {
                        "type": "integer",
                        "format": "int64",
                        "x-anyOf": [
                          {
                            "type": "integer",
                            "format": "int64"
                          },
                          {
                            "type": "string"
                          }
                        ]
                      },
                      "lhs-val": {
                        "type": "string"
                      },
                      "weight": {
                        "type": "object",
                        "properties": {
                          "num": {
                            "type": "string",
                            "x-anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "integer",
                                "format": "int64"
                              },
                              {
                                "type": "number",
                                "format": "double"
                              }
                            ]
                          },
                          "den": {
                            "type": "string",
                            "x-anyOf": [
                              {
                                "type": "string"
                              },
                              {
                                "type": "integer",
                                "format": "int64"
                              },
                              {
                                "type": "number",
                                "format": "double"
                              }
                            ]
                          }
                        },
                        "required": [
                          "num",
                          "den"
                        ],
                        "additionalProperties": false
                      },
                      "id": {
                        "type": "string"
                      },
                      "condition": {
                        "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1condition",
                        "x-allOf": [
                          {
                            "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1condition"
                          },
                          {}
                        ]
                      },
                      "rhs-fn-params": {
                        "type": "object",
                        "additionalProperties": {
                          "type": "integer",
                          "format": "int64",
                          "x-anyOf": [
                            {
                              "type": "integer",
                              "format": "int64"
                            },
                            {
                              "type": "number",
                              "format": "double"
                            }
                          ]
                        }
                      },
                      "comparator": {
                        "type": "string",
                        "enum": [
                          "gt",
                          "gte",
                          "eq",
                          "lt",
                          "lte"
                        ]
                      },
                      "collapsed-specified-weight?": {
                        "type": "boolean"
                      },
                      "exchange": {
                        "type": "string"
                      },
                      "rhs-val": {
                        "type": "string",
                        "x-anyOf": [
                          {
                            "type": "string"
                          },
                          {
                            "type": "integer",
                            "format": "int64"
                          },
                          {
                            "type": "number",
                            "format": "double"
                          }
                        ]
                      },
                      "step": {
                        "type": "string",
                        "enum": [
                          "empty",
                          "wt-cash-specified",
                          "if-child",
                          "filter",
                          "wt-inverse-vol",
                          "if",
                          "wt-marketcap",
                          "group",
                          "asset",
                          "wt-cash-equal"
                        ]
                      },
                      "sort-by-fn-params": {
                        "type": "object",
                        "additionalProperties": {
                          "type": "integer",
                          "format": "int64",
                          "x-anyOf": [
                            {
                              "type": "integer",
                              "format": "int64"
                            },
                            {
                              "type": "number",
                              "format": "double"
                            }
                          ]
                        }
                      },
                      "collapsed?": {
                        "type": "boolean"
                      }
                    },
                    "required": [
                      "id"
                    ],
                    "additionalProperties": false
                  }
                }
              },
              "required": [
                "updates"
              ],
              "additionalProperties": false
            }
          }
        ]
      }
    },
    "/api/v0.1/symphonies/{symphony-id}/copy": {
      "post": {
        "description": "Create a copy of an existing Symphony. The new Symphony will have the same trading logic but will be undeployed and can be modified independently.",
        "tags": [
          "Symphony"
        ],
        "produces": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "consumes": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "summary": "Copy an existing Symphony",
        "responses": {
          "201": {
            "description": "Successfully created",
            "schema": {
              "type": "object",
              "properties": {
                "symphony_id": {
                  "type": "string"
                },
                "version_id": {
                  "type": "string"
                }
              },
              "required": [
                "symphony_id",
                "version_id"
              ],
              "additionalProperties": false
            }
          }
        },
        "parameters": [
          {
            "in": "path",
            "name": "symphony-id",
            "description": "Unique identifier for the Symphony",
            "type": "string",
            "required": true
          },
          {
            "in": "body",
            "name": "body",
            "description": "",
            "required": false,
            "schema": {
              "type": "object",
              "properties": {
                "is_public": {
                  "description": "DEPRECATED - This field is deprecated and will be removed in a future version",
                  "type": "boolean"
                },
                "hashtag": {
                  "type": "string",
                  "example": "#BTD"
                },
                "color": {
                  "type": "string",
                  "example": "#FFBB38"
                },
                "name": {
                  "type": "string"
                },
                "benchmarks": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "is_checked": {
                        "type": "boolean"
                      },
                      "color": {
                        "type": "string",
                        "example": "#17BAFF"
                      },
                      "id": {
                        "type": "string",
                        "example": "SPY"
                      },
                      "type": {
                        "type": "string",
                        "enum": [
                          "symphony",
                          "ticker"
                        ],
                        "example": "ticker"
                      }
                    },
                    "required": [
                      "is_checked",
                      "color",
                      "id",
                      "type"
                    ],
                    "additionalProperties": false
                  }
                },
                "share_with_everyone": {
                  "type": "boolean"
                }
              },
              "additionalProperties": false,
              "x-nullable": true
            }
          }
        ]
      }
    },
    "/api/v0.1/deploy/market-hours": {
      "get": {
        "responses": {
          "200": {
            "description": "Returns market hours schedule for the upcoming week",
            "schema": {
              "type": "object",
              "properties": {
                "market_hours": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "is_market_open": {
                        "type": "boolean"
                      },
                      "nyse_market_date": {
                        "type": "string",
                        "format": "date"
                      },
                      "market_open": {
                        "type": "string",
                        "format": "date-time"
                      },
                      "market_close": {
                        "type": "string",
                        "format": "date-time"
                      }
                    },
                    "required": [
                      "is_market_open",
                      "nyse_market_date"
                    ],
                    "additionalProperties": false
                  }
                }
              },
              "required": [
                "market_hours"
              ],
              "additionalProperties": false
            }
          }
        },
        "produces": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "consumes": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "parameters": [],
        "summary": "Get market hours",
        "description": "Returns trading hours for the current day and the next week. Includes regular market hours, extended hours, and holidays.",
        "tags": [
          "Deploy"
        ]
      }
    },
    "/api/v0.1/deploy/accounts/{account-id}/symphonies/{symphony-id}/invest": {
      "post": {
        "responses": {
          "201": {
            "description": "Successfully queued investment",
            "schema": {
              "type": "object",
              "properties": {
                "deploy_id": {
                  "type": "string"
                },
                "deploy_time": {
                  "description": "The auto rebalance deploy's scheduled time, if creating one was necessary.",
                  "type": "string",
                  "x-nullable": true,
                  "format": "date-time"
                }
              },
              "required": [
                "deploy_id",
                "deploy_time"
              ],
              "additionalProperties": false
            }
          }
        },
        "produces": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "consumes": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "parameters": [
          {
            "in": "path",
            "name": "symphony-id",
            "description": "Unique identifier for the Symphony",
            "type": "string",
            "required": true
          },
          {
            "in": "path",
            "name": "account-id",
            "description": "Unique identifier (UUID) of the account",
            "type": "string",
            "required": true,
            "format": "uuid"
          },
          {
            "in": "body",
            "name": "body",
            "description": "",
            "required": true,
            "schema": {
              "type": "object",
              "properties": {
                "amount": {
                  "description": "Amount of cash to invest or withdraw (in USD)",
                  "type": "number",
                  "format": "double"
                }
              },
              "required": [
                "amount"
              ],
              "additionalProperties": false
            }
          }
        ],
        "summary": "Invest cash into a Symphony",
        "description": "Add additional capital to a Symphony position. The investment will be queued and executed during the next rebalancing window.",
        "tags": [
          "Deploy"
        ]
      }
    },
    "/api/v0.1/deploy/accounts/{account-id}/symphonies/{symphony-id}/withdraw": {
      "post": {
        "responses": {
          "201": {
            "description": "Successfully queued withdrawal",
            "schema": {
              "type": "object",
              "properties": {
                "deploy_id": {
                  "type": "string"
                },
                "deploy_time": {
                  "description": "The auto rebalance deploy's scheduled time, if creating one was necessary.",
                  "type": "string",
                  "x-nullable": true,
                  "format": "date-time"
                }
              },
              "required": [
                "deploy_id",
                "deploy_time"
              ],
              "additionalProperties": false
            }
          }
        },
        "produces": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "consumes": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "parameters": [
          {
            "in": "path",
            "name": "symphony-id",
            "description": "Unique identifier for the Symphony",
            "type": "string",
            "required": true
          },
          {
            "in": "path",
            "name": "account-id",
            "description": "Unique identifier (UUID) of the account",
            "type": "string",
            "required": true,
            "format": "uuid"
          },
          {
            "in": "body",
            "name": "body",
            "description": "",
            "required": true,
            "schema": {
              "type": "object",
              "properties": {
                "amount": {
                  "description": "Amount of cash to invest or withdraw (in USD)",
                  "type": "number",
                  "format": "double"
                }
              },
              "required": [
                "amount"
              ],
              "additionalProperties": false
            }
          }
        ],
        "summary": "Withdraw cash from a Symphony",
        "description": "Withdraw capital from a Symphony position. The withdrawal will be queued and executed during the next rebalancing window.",
        "tags": [
          "Deploy"
        ]
      }
    },
    "/api/v0.1/deploy/accounts/{account-id}/symphonies/{symphony-id}/skip-automated-rebalance": {
      "post": {
        "responses": {
          "204": {
            "description": "Successfully updated skip rebalance setting",
            "schema": null
          },
          "404": {
            "description": "Symphony or account not found",
            "schema": {
              "type": "object",
              "properties": {},
              "additionalProperties": false
            }
          }
        },
        "produces": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "consumes": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "parameters": [
          {
            "in": "path",
            "name": "symphony-id",
            "description": "Unique identifier for the Symphony",
            "type": "string",
            "required": true
          },
          {
            "in": "path",
            "name": "account-id",
            "description": "Unique identifier (UUID) of the account",
            "type": "string",
            "required": true,
            "format": "uuid"
          },
          {
            "in": "body",
            "name": "body",
            "description": "",
            "required": true,
            "schema": {
              "type": "object",
              "properties": {
                "skip": {
                  "type": "boolean"
                }
              },
              "required": [
                "skip"
              ],
              "additionalProperties": false
            }
          }
        ],
        "summary": "Skip automated rebalancing",
        "description": "Toggle whether the Symphony should skip its next automated rebalancing cycle. Useful for temporarily pausing automated trading.",
        "tags": [
          "Deploy"
        ]
      }
    },
    "/api/v0.1/deploy/accounts/{account-id}/symphonies/{symphony-id}/go-to-cash": {
      "post": {
        "responses": {
          "201": {
            "schema": {
              "type": "object",
              "properties": {
                "deploy_id": {
                  "type": "string"
                },
                "deploy_time": {
                  "type": "string"
                },
                "deploy_on_market_open": {
                  "type": "boolean"
                }
              },
              "required": [
                "deploy_id",
                "deploy_time"
              ],
              "additionalProperties": false
            },
            "description": ""
          }
        },
        "produces": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "consumes": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "parameters": [
          {
            "in": "path",
            "name": "symphony-id",
            "description": "Unique identifier for the Symphony",
            "type": "string",
            "required": true
          },
          {
            "in": "path",
            "name": "account-id",
            "description": "Unique identifier (UUID) of the account",
            "type": "string",
            "required": true,
            "format": "uuid"
          }
        ],
        "summary": "Sell all assets in a symphony, leaving proceeds in cash. Cancels any existing queued invest/withdraw deploys for the symphony.",
        "tags": [
          "Deploy"
        ]
      }
    },
    "/api/v0.1/deploy/accounts/{account-id}/symphonies/{symphony-id}/rebalance": {
      "post": {
        "responses": {
          "201": {
            "schema": {
              "type": "object",
              "properties": {
                "deploy_id": {
                  "type": "string"
                },
                "deploy_time": {
                  "type": "string"
                },
                "deploy_on_market_open": {
                  "type": "boolean"
                },
                "symphony_id": {
                  "type": "string"
                }
              },
              "required": [
                "deploy_id",
                "deploy_time",
                "symphony_id"
              ],
              "additionalProperties": false
            },
            "description": ""
          }
        },
        "produces": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "consumes": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "parameters": [
          {
            "in": "path",
            "name": "symphony-id",
            "description": "Unique identifier for the Symphony",
            "type": "string",
            "required": true
          },
          {
            "in": "path",
            "name": "account-id",
            "description": "Unique identifier (UUID) of the account",
            "type": "string",
            "required": true,
            "format": "uuid"
          },
          {
            "in": "body",
            "name": "body",
            "description": "",
            "required": true,
            "schema": {
              "type": "object",
              "properties": {
                "rebalance_request_uuid": {
                  "type": "string",
                  "format": "uuid"
                }
              },
              "required": [
                "rebalance_request_uuid"
              ],
              "additionalProperties": false
            }
          }
        ],
        "summary": "Rebalance a symphony NOW.",
        "tags": [
          "Deploy"
        ]
      }
    },
    "/api/v0.1/deploy/accounts/{account-id}/symphonies/{symphony-id}/liquidate": {
      "post": {
        "responses": {
          "201": {
            "schema": {
              "type": "object",
              "properties": {
                "deploy_id": {
                  "type": "string"
                },
                "deploy_time": {
                  "type": "string"
                },
                "deploy_on_market_open": {
                  "type": "boolean"
                }
              },
              "required": [
                "deploy_id",
                "deploy_time"
              ],
              "additionalProperties": false
            },
            "description": ""
          }
        },
        "produces": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "consumes": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "parameters": [
          {
            "in": "path",
            "name": "symphony-id",
            "description": "Unique identifier for the Symphony",
            "type": "string",
            "required": true
          },
          {
            "in": "path",
            "name": "account-id",
            "description": "Unique identifier (UUID) of the account",
            "type": "string",
            "required": true,
            "format": "uuid"
          }
        ],
        "summary": "Liquidate a symphony entirely. Cancels any existing queued invest/withdraw deploys for the symphony.",
        "tags": [
          "Deploy"
        ]
      }
    },
    "/api/v0.1/dry-run": {
      "post": {
        "responses": {
          "200": {
            "schema": {
              "type": "array",
              "items": {
                "type": "object",
                "properties": {
                  "broker_account_uuid": {
                    "type": "string",
                    "format": "uuid"
                  },
                  "account_type": {
                    "type": "string"
                  },
                  "account_name": {
                    "type": "string"
                  },
                  "broker": {
                    "type": "string"
                  },
                  "dry_run_result": {
                    "type": "object",
                    "additionalProperties": {
                      "type": "object",
                      "properties": {
                        "rebalanced": {
                          "type": "boolean"
                        },
                        "next_rebalance_after": {
                          "type": "string"
                        },
                        "recommended_trades": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "ticker": {
                                "type": "string"
                              },
                              "notional": {
                                "type": "number",
                                "format": "double"
                              },
                              "quantity": {
                                "type": "number",
                                "format": "double"
                              },
                              "prev_value": {
                                "type": "number",
                                "format": "double"
                              },
                              "prev_weight": {
                                "type": "number",
                                "format": "double"
                              },
                              "next_weight": {
                                "type": "number",
                                "format": "double"
                              }
                            },
                            "required": [
                              "ticker",
                              "notional",
                              "quantity",
                              "prev_value",
                              "prev_weight",
                              "next_weight"
                            ],
                            "additionalProperties": false
                          }
                        },
                        "queued_cash_change": {
                          "type": "number",
                          "format": "double"
                        },
                        "symphony_value": {
                          "type": "number",
                          "format": "double"
                        },
                        "symphony_name": {
                          "type": "string"
                        },
                        "next_rebalance_date": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "rebalanced",
                        "next_rebalance_after",
                        "recommended_trades",
                        "queued_cash_change",
                        "symphony_value",
                        "symphony_name"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "dry_run_missing_symphonies": {
                    "type": "object",
                    "additionalProperties": {
                      "type": "string"
                    },
                    "x-nullable": true
                  },
                  "dry_run_total_symphonies": {
                    "type": "integer",
                    "format": "int64"
                  }
                },
                "required": [
                  "broker_account_uuid",
                  "account_type",
                  "account_name",
                  "broker",
                  "dry_run_result",
                  "dry_run_missing_symphonies",
                  "dry_run_total_symphonies"
                ],
                "additionalProperties": false
              }
            },
            "description": ""
          }
        },
        "produces": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "consumes": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "parameters": [
          {
            "in": "body",
            "name": "body",
            "description": "",
            "required": true,
            "schema": {
              "type": "object",
              "properties": {
                "account_uuids": {
                  "type": "array",
                  "items": {
                    "type": "string",
                    "format": "uuid"
                  }
                }
              },
              "additionalProperties": false
            }
          }
        ],
        "summary": "Dry run rebalances for a specific user (all accounts, unless otherwise specified)",
        "tags": [
          "Dry Run"
        ]
      }
    },
    "/api/v0.1/dry-run/trade-preview/{symphony-id}": {
      "post": {
        "responses": {
          "200": {
            "schema": {
              "type": "object",
              "properties": {
                "rebalanced": {
                  "type": "boolean"
                },
                "next_rebalance_after": {
                  "type": "string"
                },
                "recommended_trades": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "at": {
                        "type": "string"
                      },
                      "average_price": {
                        "type": "number",
                        "format": "double"
                      },
                      "cash_change": {
                        "type": "number",
                        "format": "double"
                      },
                      "share_change": {
                        "type": "number",
                        "format": "double"
                      },
                      "symbol": {
                        "type": "string"
                      },
                      "name": {
                        "type": "string",
                        "x-nullable": true
                      },
                      "side": {
                        "type": "string",
                        "enum": [
                          "BUY",
                          "SELL"
                        ]
                      },
                      "type": {
                        "type": "string",
                        "enum": [
                          "symphony_preview"
                        ]
                      },
                      "prev_value": {
                        "type": "number",
                        "format": "double"
                      },
                      "prev_weight": {
                        "type": "number",
                        "format": "double"
                      },
                      "next_weight": {
                        "type": "number",
                        "format": "double"
                      }
                    },
                    "required": [
                      "at",
                      "average_price",
                      "cash_change",
                      "share_change",
                      "symbol",
                      "name",
                      "side",
                      "type",
                      "prev_value",
                      "prev_weight",
                      "next_weight"
                    ],
                    "additionalProperties": false
                  }
                },
                "queued_cash_change": {
                  "type": "number",
                  "format": "double"
                },
                "rebalance_frequency_override": {
                  "type": "boolean"
                },
                "rebalance_request_uuid": {
                  "description": "Present whenever the request included `broker_account_uuid`.",
                  "type": "string",
                  "format": "uuid",
                  "x-nullable": true
                },
                "adjusted_for_dtbp": {
                  "description": "Whether buys in the preview were constrained by DTBP.",
                  "type": "boolean"
                },
                "symphony_value": {
                  "type": "number",
                  "format": "double"
                },
                "symphony_name": {
                  "type": "string"
                }
              },
              "required": [
                "rebalanced",
                "next_rebalance_after",
                "recommended_trades",
                "queued_cash_change",
                "rebalance_frequency_override",
                "rebalance_request_uuid",
                "adjusted_for_dtbp",
                "symphony_value",
                "symphony_name"
              ],
              "additionalProperties": false
            },
            "description": ""
          }
        },
        "produces": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "consumes": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "parameters": [
          {
            "in": "path",
            "name": "symphony-id",
            "description": "Unique identifier for the Symphony",
            "type": "string",
            "required": true
          },
          {
            "in": "body",
            "name": "body",
            "description": "",
            "required": true,
            "schema": {
              "type": "object",
              "properties": {
                "amount": {
                  "type": "number",
                  "format": "double"
                },
                "broker_account_uuid": {
                  "type": "string",
                  "format": "uuid"
                }
              },
              "additionalProperties": false
            }
          }
        ],
        "summary": "Generate trade preview for a single symphony",
        "tags": [
          "Dry Run"
        ]
      }
    },
    "/api/v0.1/trading/accounts/{account-id}/order-requests": {
      "get": {
        "responses": {
          "200": {
            "description": "Returns a list of order requests for the account",
            "schema": {
              "type": "object",
              "properties": {
                "order_requests": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "order_request_id": {
                        "type": "string",
                        "format": "uuid"
                      },
                      "name": {
                        "type": "string",
                        "x-nullable": true
                      },
                      "position_id": {
                        "type": "string"
                      },
                      "status": {
                        "type": "string",
                        "enum": [
                          "QUEUED",
                          "IN_PROGRESS",
                          "OPEN",
                          "FILLED",
                          "EXPIRED",
                          "FAILED",
                          "CANCELED",
                          "REJECTED"
                        ]
                      },
                      "client_order_ids": {
                        "description": "IDs of broker orders that have been submitted for this order request.",
                        "type": "array",
                        "items": {
                          "type": "string"
                        },
                        "x-nullable": true
                      },
                      "asset_class": {
                        "type": "string",
                        "enum": [
                          "EQUITIES",
                          "CRYPTO",
                          "OPTIONS"
                        ]
                      },
                      "side": {
                        "type": "string",
                        "enum": [
                          "BUY",
                          "SELL"
                        ]
                      },
                      "type": {
                        "type": "string",
                        "enum": [
                          "MARKET",
                          "LIMIT",
                          "STOP",
                          "STOP_LIMIT",
                          "TRAILING_STOP"
                        ]
                      },
                      "symbol": {
                        "type": "string"
                      },
                      "time_in_force": {
                        "type": "string",
                        "enum": [
                          "GTC",
                          "DAY",
                          "IOC",
                          "FOK",
                          "OPG",
                          "CLS"
                        ]
                      },
                      "notional": {
                        "description": "Null if quantity is provided.",
                        "type": "number",
                        "format": "double",
                        "x-nullable": true
                      },
                      "quantity": {
                        "description": "Null if notional is provided.",
                        "type": "number",
                        "format": "double",
                        "x-nullable": true
                      },
                      "position_intent": {
                        "description": "The intent of the order request, only for options contracts.",
                        "type": "string",
                        "enum": [
                          "BUY_TO_OPEN",
                          "SELL_TO_OPEN",
                          "BUY_TO_CLOSE",
                          "SELL_TO_CLOSE"
                        ],
                        "x-nullable": true
                      },
                      "limit_price": {
                        "type": "number",
                        "format": "double",
                        "x-allOf": [
                          {
                            "type": "number",
                            "format": "double"
                          },
                          {
                            "type": "number",
                            "exclusiveMinimum": 0
                          }
                        ],
                        "x-nullable": true
                      },
                      "stop_price": {
                        "type": "number",
                        "format": "double",
                        "x-allOf": [
                          {
                            "type": "number",
                            "format": "double"
                          },
                          {
                            "type": "number",
                            "exclusiveMinimum": 0
                          }
                        ],
                        "x-nullable": true
                      },
                      "options_details": {
                        "description": "Details of the options contract (only for OPTIONS assets)",
                        "type": "object",
                        "properties": {
                          "underlying_asset_symbol": {
                            "description": "Underlying asset symbol.",
                            "type": "string"
                          },
                          "strike_price": {
                            "description": "Strike price of the option contract.",
                            "type": "number",
                            "format": "double"
                          },
                          "expiry": {
                            "description": "Expiry date of the option contract.",
                            "type": "string",
                            "pattern": "[0-9]{4}-[0-9]{2}-[0-9]{2}"
                          },
                          "contract_type": {
                            "description": "Type of option contract, CALL or PUT.",
                            "type": "string",
                            "enum": [
                              "PUT",
                              "CALL"
                            ]
                          }
                        },
                        "required": [
                          "underlying_asset_symbol",
                          "strike_price",
                          "expiry",
                          "contract_type"
                        ],
                        "additionalProperties": false
                      },
                      "source": {
                        "type": "string",
                        "enum": [
                          "USER_DIRECT_TRADE",
                          "COMPOSER_ADMIN"
                        ]
                      },
                      "created_at": {
                        "type": "string",
                        "format": "date-time"
                      },
                      "updated_at": {
                        "type": "string",
                        "format": "date-time"
                      },
                      "outcome_reason": {
                        "type": "string",
                        "x-nullable": true
                      }
                    },
                    "required": [
                      "order_request_id",
                      "name",
                      "position_id",
                      "status",
                      "client_order_ids",
                      "asset_class",
                      "side",
                      "type",
                      "symbol",
                      "time_in_force",
                      "notional",
                      "quantity",
                      "limit_price",
                      "stop_price",
                      "source",
                      "created_at",
                      "updated_at",
                      "outcome_reason"
                    ],
                    "additionalProperties": false
                  }
                }
              },
              "required": [
                "order_requests"
              ],
              "additionalProperties": false
            }
          }
        },
        "produces": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "consumes": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "parameters": [
          {
            "in": "path",
            "name": "account-id",
            "description": "Unique identifier (UUID) of the account",
            "type": "string",
            "required": true,
            "format": "uuid"
          },
          {
            "in": "query",
            "name": "limit",
            "description": "",
            "type": "integer",
            "required": false,
            "format": "int64"
          },
          {
            "in": "query",
            "name": "status",
            "description": "Single status or comma-separated list of statuses (e.g., 'QUEUED,OPEN,IN_PROGRESS')",
            "type": "string",
            "required": false
          }
        ],
        "summary": "Get order requests",
        "description": "Retrieve all order requests for a brokerage account. Returns both pending and completed orders with their current status.",
        "tags": [
          "Direct Trading"
        ]
      },
      "post": {
        "responses": {
          "200": {
            "description": "Successfully created order request",
            "schema": {
              "type": "object",
              "properties": {
                "order_request_id": {
                  "type": "string",
                  "format": "uuid"
                },
                "order_time": {
                  "type": "string",
                  "format": "date-time"
                },
                "commission": {
                  "description": "Commission for the order.",
                  "type": "number"
                }
              },
              "required": [
                "order_request_id",
                "order_time",
                "commission"
              ],
              "additionalProperties": false
            }
          }
        },
        "produces": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "consumes": [
          "application/json",
          "application/transit+msgpack",
          "application/transit+json",
          "application/edn"
        ],
        "parameters": [
          {
            "in": "path",
            "name": "account-id",
            "description": "Unique identifier (UUID) of the account",
            "type": "string",
            "required": true,
            "format": "uuid"
          },
          {
            "in": "body",
            "name": "body",
            "description": "",
            "required": true,
            "schema": {
              "type": "object",
              "properties": {
                "type": {
                  "type": "string",
                  "enum": [
                    "MARKET",
                    "LIMIT",
                    "STOP",
                    "STOP_LIMIT",
                    "TRAILING_STOP"
                  ]
                },
                "symbol": {
                  "type": "string"
                },
                "time_in_force": {
                  "type": "string",
                  "enum": [
                    "GTC",
                    "DAY",
                    "IOC",
                    "FOK",
                    "OPG",
                    "CLS"
                  ]
                },
                "notional": {
                  "description": "Required if quantity is not provided.",
                  "type": "number",
                  "format": "double",
                  "x-allOf": [
                    {
                      "type": "number",
                      "format": "double"
                    },
                    {
                      "type": "number",
                      "exclusiveMaximum": 0,
                      "x-anyOf": [
                        {
                          "type": "number",
                          "exclusiveMaximum": 0
                        },
                        {
                          "type": "number",
                          "exclusiveMinimum": 0
                        }
                      ]
                    }
                  ],
                  "x-nullable": true
                },
                "quantity": {
                  "description": "Required if notional is not provided.",
                  "type": "number",
                  "format": "double",
                  "x-allOf": [
                    {
                      "type": "number",
                      "format": "double"
                    },
                    {
                      "type": "number",
                      "exclusiveMaximum": 0,
                      "x-anyOf": [
                        {
                          "type": "number",
                          "exclusiveMaximum": 0
                        },
                        {
                          "type": "number",
                          "exclusiveMinimum": 0
                        }
                      ]
                    }
                  ],
                  "x-nullable": true
                },
                "position_intent": {
                  "description": "Required if the symbol is an option contract.",
                  "type": "string",
                  "enum": [
                    "BUY_TO_OPEN",
                    "SELL_TO_OPEN",
                    "BUY_TO_CLOSE",
                    "SELL_TO_CLOSE"
                  ]
                },
                "limit_price": {
                  "type": "number",
                  "format": "double",
                  "x-allOf": [
                    {
                      "type": "number",
                      "format": "double"
                    },
                    {
                      "type": "number",
                      "exclusiveMinimum": 0
                    }
                  ],
                  "x-nullable": true
                },
                "stop_price": {
                  "type": "number",
                  "format": "double",
                  "x-allOf": [
                    {
                      "type": "number",
                      "format": "double"
                    },
                    {
                      "type": "number",
                      "exclusiveMinimum": 0
                    }
                  ],
                  "x-nullable": true
                },
                "client_order_id": {
                  "description": "Optional client-generated order ID, for order tracking and idempotency.",
                  "type": "string",
                  "x-nullable": true
                }
              },
              "required": [
                "type",
                "symbol",
                "time_in_force"
              ],
              "additionalProperties": false
            }
          }
        ],
        "summary": "Create order request",
        "description": "Submit a new buy or sell order for equities or options. If the request is made outside of market hours, it will be queued and executed at the next market open.",
        "tags": [
          "Direct Trading"
        ]
      }
    },
    "/api/v0.1/trading/accounts/{account-id}/order-requests/": {}
  },
  "definitions": {
    "composer.cloud.domain.symphony-score-v1/if-child-false": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string"
        },
        "suppress-incomplete-warnings?": {
          "type": "boolean"
        },
        "collapsed?": {
          "type": "boolean"
        },
        "collapsed-specified-weight?": {
          "type": "boolean"
        },
        "weight": {
          "type": "object",
          "properties": {
            "num": {
              "type": "string",
              "x-anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "integer",
                  "format": "int64"
                },
                {
                  "type": "number",
                  "format": "double"
                }
              ]
            },
            "den": {
              "type": "string",
              "x-anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "integer",
                  "format": "int64"
                },
                {
                  "type": "number",
                  "format": "double"
                }
              ]
            }
          },
          "required": [
            "num",
            "den"
          ],
          "additionalProperties": false
        },
        "step": {
          "type": "string",
          "enum": [
            "if-child"
          ]
        },
        "is-else-condition?": {
          "enum": [
            true
          ]
        },
        "children": {
          "default": [],
          "type": "array",
          "items": {
            "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1if",
            "x-anyOf": [
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1if"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1group"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1wt-cash-equal"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1wt-cash-specified"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1asset"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1empty"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1wt-inverse-vol"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1wt-marketcap"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1filter"
              }
            ]
          }
        }
      },
      "required": [
        "id",
        "step",
        "is-else-condition?"
      ]
    },
    "composer.cloud.domain.symphony-score-v1/root": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string"
        },
        "suppress-incomplete-warnings?": {
          "type": "boolean"
        },
        "collapsed?": {
          "type": "boolean"
        },
        "collapsed-specified-weight?": {
          "type": "boolean"
        },
        "weight": {
          "type": "object",
          "properties": {
            "num": {
              "type": "string",
              "x-anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "integer",
                  "format": "int64"
                },
                {
                  "type": "number",
                  "format": "double"
                }
              ]
            },
            "den": {
              "type": "string",
              "x-anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "integer",
                  "format": "int64"
                },
                {
                  "type": "number",
                  "format": "double"
                }
              ]
            }
          },
          "required": [
            "num",
            "den"
          ],
          "additionalProperties": false
        },
        "step": {
          "type": "string",
          "enum": [
            "root"
          ]
        },
        "name": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "rebalance": {
          "type": "string",
          "enum": [
            "none",
            "daily",
            "weekly",
            "monthly",
            "quarterly",
            "yearly"
          ]
        },
        "rebalance-corridor-width": {
          "type": "number",
          "format": "double"
        },
        "children": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1if",
            "x-anyOf": [
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1if"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1group"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1wt-cash-equal"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1wt-cash-specified"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1asset"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1empty"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1wt-inverse-vol"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1wt-marketcap"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1filter"
              }
            ]
          }
        }
      },
      "required": [
        "id",
        "step",
        "name",
        "description",
        "rebalance",
        "children"
      ]
    },
    "composer.cloud.domain.symphony-score-v1/wt-cash-equal": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string"
        },
        "suppress-incomplete-warnings?": {
          "type": "boolean"
        },
        "collapsed?": {
          "type": "boolean"
        },
        "collapsed-specified-weight?": {
          "type": "boolean"
        },
        "weight": {
          "type": "object",
          "properties": {
            "num": {
              "type": "string",
              "x-anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "integer",
                  "format": "int64"
                },
                {
                  "type": "number",
                  "format": "double"
                }
              ]
            },
            "den": {
              "type": "string",
              "x-anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "integer",
                  "format": "int64"
                },
                {
                  "type": "number",
                  "format": "double"
                }
              ]
            }
          },
          "required": [
            "num",
            "den"
          ],
          "additionalProperties": false
        },
        "step": {
          "type": "string",
          "enum": [
            "wt-cash-equal"
          ]
        },
        "children": {
          "default": [],
          "type": "array",
          "items": {
            "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1if",
            "x-anyOf": [
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1if"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1group"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1wt-cash-equal"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1wt-cash-specified"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1asset"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1empty"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1wt-inverse-vol"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1wt-marketcap"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1filter"
              }
            ]
          }
        }
      },
      "required": [
        "id",
        "step"
      ]
    },
    "composer.cloud.domain.symphony-score-v1/group": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string"
        },
        "suppress-incomplete-warnings?": {
          "type": "boolean"
        },
        "collapsed?": {
          "type": "boolean"
        },
        "collapsed-specified-weight?": {
          "type": "boolean"
        },
        "weight": {
          "type": "object",
          "properties": {
            "num": {
              "type": "string",
              "x-anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "integer",
                  "format": "int64"
                },
                {
                  "type": "number",
                  "format": "double"
                }
              ]
            },
            "den": {
              "type": "string",
              "x-anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "integer",
                  "format": "int64"
                },
                {
                  "type": "number",
                  "format": "double"
                }
              ]
            }
          },
          "required": [
            "num",
            "den"
          ],
          "additionalProperties": false
        },
        "step": {
          "type": "string",
          "enum": [
            "group"
          ]
        },
        "name": {
          "type": "string"
        },
        "children": {
          "default": [],
          "type": "array",
          "items": {
            "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1if",
            "x-anyOf": [
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1if"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1group"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1wt-cash-equal"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1wt-cash-specified"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1asset"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1empty"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1wt-inverse-vol"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1wt-marketcap"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1filter"
              }
            ]
          }
        }
      },
      "required": [
        "id",
        "step"
      ]
    },
    "node/if": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string",
          "format": "uuid"
        },
        "meta": {
          "type": "object",
          "properties": {
            "name": {
              "type": "string",
              "x-nullable": true
            }
          }
        },
        "type": {
          "const": "node_if"
        },
        "condition": {
          "$ref": "#/definitions/function~1comparison"
        },
        "then_children": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/node~1if",
            "x-anyOf": [
              {
                "$ref": "#/definitions/node~1if"
              },
              {
                "$ref": "#/definitions/node~1weight"
              },
              {
                "$ref": "#/definitions/node~1asset"
              },
              {
                "$ref": "#/definitions/node~1filter"
              }
            ]
          }
        },
        "else_children": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/node~1if",
            "x-anyOf": [
              {
                "$ref": "#/definitions/node~1if"
              },
              {
                "$ref": "#/definitions/node~1weight"
              },
              {
                "$ref": "#/definitions/node~1asset"
              },
              {
                "$ref": "#/definitions/node~1filter"
              }
            ]
          }
        }
      },
      "required": [
        "id",
        "type",
        "condition",
        "then_children",
        "else_children"
      ]
    },
    "composer.cloud.domain.symphony-score-v1/constant": {
      "type": "object",
      "properties": {
        "constant": {
          "type": "number",
          "format": "double"
        }
      },
      "required": [
        "constant"
      ],
      "additionalProperties": false
    },
    "composer.cloud.domain.symphony-score-v1/empty": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string"
        },
        "suppress-incomplete-warnings?": {
          "type": "boolean"
        },
        "collapsed?": {
          "type": "boolean"
        },
        "collapsed-specified-weight?": {
          "type": "boolean"
        },
        "weight": {
          "type": "object",
          "properties": {
            "num": {
              "type": "string",
              "x-anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "integer",
                  "format": "int64"
                },
                {
                  "type": "number",
                  "format": "double"
                }
              ]
            },
            "den": {
              "type": "string",
              "x-anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "integer",
                  "format": "int64"
                },
                {
                  "type": "number",
                  "format": "double"
                }
              ]
            }
          },
          "required": [
            "num",
            "den"
          ],
          "additionalProperties": false
        },
        "step": {
          "type": "string",
          "enum": [
            "empty"
          ]
        }
      },
      "required": [
        "id",
        "step"
      ]
    },
    "composer.cloud.domain.symphony-score-v1/if": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string"
        },
        "suppress-incomplete-warnings?": {
          "type": "boolean"
        },
        "collapsed?": {
          "type": "boolean"
        },
        "collapsed-specified-weight?": {
          "type": "boolean"
        },
        "weight": {
          "type": "object",
          "properties": {
            "num": {
              "type": "string",
              "x-anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "integer",
                  "format": "int64"
                },
                {
                  "type": "number",
                  "format": "double"
                }
              ]
            },
            "den": {
              "type": "string",
              "x-anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "integer",
                  "format": "int64"
                },
                {
                  "type": "number",
                  "format": "double"
                }
              ]
            }
          },
          "required": [
            "num",
            "den"
          ],
          "additionalProperties": false
        },
        "step": {
          "type": "string",
          "enum": [
            "if"
          ]
        },
        "children": {
          "type": "array",
          "items": {},
          "x-items": [
            {
              "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1if-child-true"
            },
            {
              "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1if-child-false"
            }
          ]
        }
      },
      "required": [
        "id",
        "step",
        "children"
      ]
    },
    "composer.cloud.domain.symphony-score-v1/filter": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string"
        },
        "suppress-incomplete-warnings?": {
          "type": "boolean"
        },
        "collapsed?": {
          "type": "boolean"
        },
        "collapsed-specified-weight?": {
          "type": "boolean"
        },
        "weight": {
          "type": "object",
          "properties": {
            "num": {
              "type": "string",
              "x-anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "integer",
                  "format": "int64"
                },
                {
                  "type": "number",
                  "format": "double"
                }
              ]
            },
            "den": {
              "type": "string",
              "x-anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "integer",
                  "format": "int64"
                },
                {
                  "type": "number",
                  "format": "double"
                }
              ]
            }
          },
          "required": [
            "num",
            "den"
          ],
          "additionalProperties": false
        },
        "step": {
          "type": "string",
          "enum": [
            "filter"
          ]
        },
        "sort-by-window-days": {
          "type": "integer",
          "format": "int64",
          "x-anyOf": [
            {
              "type": "integer",
              "format": "int64"
            },
            {
              "type": "string"
            }
          ]
        },
        "sort-by-fn-params": {
          "type": "object",
          "additionalProperties": {
            "type": "integer",
            "format": "int64",
            "x-anyOf": [
              {
                "type": "integer",
                "format": "int64"
              },
              {
                "type": "number",
                "format": "double"
              }
            ]
          }
        },
        "sort-by-fn": {
          "type": "string",
          "enum": [
            "cumulative-return",
            "current-price",
            "exponential-moving-average-price",
            "max-drawdown",
            "moving-average-price",
            "moving-average-return",
            "relative-strength-index",
            "standard-deviation-price",
            "standard-deviation-return",
            "percentage-price-oscillator",
            "percentage-price-oscillator-signal",
            "moving-average-convergence-divergence",
            "moving-average-convergence-divergence-signal",
            "lower-bollinger",
            "upper-bollinger"
          ]
        },
        "select-n": {
          "type": "integer",
          "format": "int64",
          "x-anyOf": [
            {
              "type": "integer",
              "format": "int64"
            },
            {
              "type": "string"
            }
          ]
        },
        "select-fn": {
          "type": "string",
          "enum": [
            "top",
            "bottom"
          ]
        },
        "children": {
          "default": [],
          "type": "array",
          "items": {
            "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1if",
            "x-anyOf": [
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1if"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1group"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1wt-cash-equal"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1wt-cash-specified"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1asset"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1empty"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1wt-inverse-vol"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1wt-marketcap"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1filter"
              }
            ]
          }
        }
      },
      "required": [
        "id",
        "step"
      ],
      "x-allOf": [
        {
          "type": "object",
          "properties": {
            "id": {
              "type": "string"
            },
            "suppress-incomplete-warnings?": {
              "type": "boolean"
            },
            "collapsed?": {
              "type": "boolean"
            },
            "collapsed-specified-weight?": {
              "type": "boolean"
            },
            "weight": {
              "type": "object",
              "properties": {
                "num": {
                  "type": "string",
                  "x-anyOf": [
                    {
                      "type": "string"
                    },
                    {
                      "type": "integer",
                      "format": "int64"
                    },
                    {
                      "type": "number",
                      "format": "double"
                    }
                  ]
                },
                "den": {
                  "type": "string",
                  "x-anyOf": [
                    {
                      "type": "string"
                    },
                    {
                      "type": "integer",
                      "format": "int64"
                    },
                    {
                      "type": "number",
                      "format": "double"
                    }
                  ]
                }
              },
              "required": [
                "num",
                "den"
              ],
              "additionalProperties": false
            },
            "step": {
              "type": "string",
              "enum": [
                "filter"
              ]
            },
            "sort-by-window-days": {
              "type": "integer",
              "format": "int64",
              "x-anyOf": [
                {
                  "type": "integer",
                  "format": "int64"
                },
                {
                  "type": "string"
                }
              ]
            },
            "sort-by-fn-params": {
              "type": "object",
              "additionalProperties": {
                "type": "integer",
                "format": "int64",
                "x-anyOf": [
                  {
                    "type": "integer",
                    "format": "int64"
                  },
                  {
                    "type": "number",
                    "format": "double"
                  }
                ]
              }
            },
            "sort-by-fn": {
              "type": "string",
              "enum": [
                "cumulative-return",
                "current-price",
                "exponential-moving-average-price",
                "max-drawdown",
                "moving-average-price",
                "moving-average-return",
                "relative-strength-index",
                "standard-deviation-price",
                "standard-deviation-return",
                "percentage-price-oscillator",
                "percentage-price-oscillator-signal",
                "moving-average-convergence-divergence",
                "moving-average-convergence-divergence-signal",
                "lower-bollinger",
                "upper-bollinger"
              ]
            },
            "select-n": {
              "type": "integer",
              "format": "int64",
              "x-anyOf": [
                {
                  "type": "integer",
                  "format": "int64"
                },
                {
                  "type": "string"
                }
              ]
            },
            "select-fn": {
              "type": "string",
              "enum": [
                "top",
                "bottom"
              ]
            },
            "children": {
              "default": [],
              "type": "array",
              "items": {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1if",
                "x-anyOf": [
                  {
                    "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1if"
                  },
                  {
                    "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1group"
                  },
                  {
                    "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1wt-cash-equal"
                  },
                  {
                    "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1wt-cash-specified"
                  },
                  {
                    "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1asset"
                  },
                  {
                    "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1empty"
                  },
                  {
                    "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1wt-inverse-vol"
                  },
                  {
                    "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1wt-marketcap"
                  },
                  {
                    "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1filter"
                  }
                ]
              }
            }
          },
          "required": [
            "id",
            "step"
          ]
        },
        {}
      ]
    },
    "composer.cloud.domain.symphony-score-v1/indicator-pattern": {
      "type": "object",
      "properties": {
        "fn": {
          "type": "string",
          "enum": [
            "cumulative-return",
            "current-price",
            "exponential-moving-average-price",
            "max-drawdown",
            "moving-average-price",
            "moving-average-return",
            "relative-strength-index",
            "standard-deviation-price",
            "standard-deviation-return",
            "percentage-price-oscillator",
            "percentage-price-oscillator-signal",
            "moving-average-convergence-divergence",
            "moving-average-convergence-divergence-signal",
            "lower-bollinger",
            "upper-bollinger"
          ]
        },
        "params": {
          "type": "object",
          "additionalProperties": {
            "type": "integer",
            "format": "int64",
            "x-anyOf": [
              {
                "type": "integer",
                "format": "int64"
              },
              {
                "type": "number",
                "format": "double"
              }
            ]
          }
        },
        "ticker": {
          "const": "%"
        }
      },
      "required": [
        "fn",
        "ticker"
      ],
      "additionalProperties": false
    },
    "function/call": {
      "type": "array",
      "items": {},
      "x-items": [
        {
          "type": "string",
          "enum": [
            "fn_standard_deviation",
            "fn_exponential_moving_average",
            "fn_inverse_volatility",
            "fn_cumulative_return",
            "fn_max_drawdown",
            "fn_simple_moving_average",
            "fn_relative_strength_index"
          ]
        },
        {
          "$ref": "#/definitions/function~1call"
        },
        {
          "type": "integer",
          "format": "int64"
        }
      ],
      "x-anyOf": [
        {
          "type": "array",
          "items": {},
          "x-items": [
            {
              "type": "string",
              "enum": [
                "fn_standard_deviation",
                "fn_exponential_moving_average",
                "fn_inverse_volatility",
                "fn_cumulative_return",
                "fn_max_drawdown",
                "fn_simple_moving_average",
                "fn_relative_strength_index"
              ]
            },
            {
              "$ref": "#/definitions/function~1call"
            },
            {
              "type": "integer",
              "format": "int64"
            }
          ]
        },
        {
          "type": "array",
          "items": {},
          "x-items": [
            {
              "type": "string",
              "enum": [
                "fn_percentage_price_oscillator",
                "fn_moving_average_convergence_divergence"
              ]
            },
            {
              "$ref": "#/definitions/function~1call"
            },
            {
              "type": "integer",
              "format": "int64"
            },
            {
              "type": "integer",
              "format": "int64"
            }
          ]
        },
        {
          "type": "array",
          "items": {},
          "x-items": [
            {
              "type": "string",
              "enum": [
                "fn_moving_average_convergence_divergence_signal",
                "fn_percentage_price_oscillator_signal"
              ]
            },
            {
              "$ref": "#/definitions/function~1call"
            },
            {
              "type": "integer",
              "format": "int64"
            },
            {
              "type": "integer",
              "format": "int64"
            },
            {
              "type": "integer",
              "format": "int64"
            }
          ]
        },
        {
          "type": "array",
          "items": {},
          "x-items": [
            {
              "type": "string",
              "enum": [
                "fn_upper_bollinger",
                "fn_lower_bollinger"
              ]
            },
            {
              "type": "array",
              "items": {},
              "x-items": [
                {
                  "const": "reference"
                },
                {
                  "description": "The parameter for a function over a filter or weight node. Intended to be used within :weight_fn or :weight_every_fn.",
                  "const": "%"
                }
              ],
              "x-anyOf": [
                {
                  "type": "array",
                  "items": {},
                  "x-items": [
                    {
                      "const": "reference"
                    },
                    {
                      "description": "The parameter for a function over a filter or weight node. Intended to be used within :weight_fn or :weight_every_fn.",
                      "const": "%"
                    }
                  ]
                },
                {
                  "type": "string"
                }
              ]
            },
            {
              "type": "integer",
              "format": "int64"
            },
            {
              "type": "number",
              "format": "double"
            }
          ]
        },
        {
          "type": "array",
          "items": {},
          "x-items": [
            {
              "const": "reference"
            },
            {
              "description": "The parameter for a function over a filter or weight node. Intended to be used within :weight_fn or :weight_every_fn.",
              "const": "%"
            }
          ]
        },
        {
          "type": "array",
          "items": {},
          "x-items": [
            {
              "const": "metric_close"
            },
            {
              "type": "array",
              "items": {},
              "x-items": [
                {
                  "const": "reference"
                },
                {
                  "description": "The parameter for a function over a filter or weight node. Intended to be used within :weight_fn or :weight_every_fn.",
                  "const": "%"
                }
              ],
              "x-anyOf": [
                {
                  "type": "array",
                  "items": {},
                  "x-items": [
                    {
                      "const": "reference"
                    },
                    {
                      "description": "The parameter for a function over a filter or weight node. Intended to be used within :weight_fn or :weight_every_fn.",
                      "const": "%"
                    }
                  ]
                },
                {
                  "type": "string"
                }
              ]
            }
          ]
        },
        {
          "type": "array",
          "items": {},
          "x-items": [
            {
              "const": "fundamental_market_cap"
            },
            {
              "type": "string"
            }
          ]
        },
        {
          "type": "array",
          "items": {},
          "x-items": [
            {
              "const": "fn_rate_of_return"
            },
            {
              "$ref": "#/definitions/function~1call"
            }
          ]
        },
        {
          "type": "array",
          "items": {},
          "x-items": [
            {
              "const": "fn_constant"
            },
            {
              "type": "number",
              "format": "double"
            }
          ]
        }
      ]
    },
    "composer.cloud.domain.symphony-score-v1/wt-marketcap": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string"
        },
        "suppress-incomplete-warnings?": {
          "type": "boolean"
        },
        "collapsed?": {
          "type": "boolean"
        },
        "collapsed-specified-weight?": {
          "type": "boolean"
        },
        "weight": {
          "type": "object",
          "properties": {
            "num": {
              "type": "string",
              "x-anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "integer",
                  "format": "int64"
                },
                {
                  "type": "number",
                  "format": "double"
                }
              ]
            },
            "den": {
              "type": "string",
              "x-anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "integer",
                  "format": "int64"
                },
                {
                  "type": "number",
                  "format": "double"
                }
              ]
            }
          },
          "required": [
            "num",
            "den"
          ],
          "additionalProperties": false
        },
        "step": {
          "type": "string",
          "enum": [
            "wt-marketcap"
          ]
        },
        "children": {
          "default": [],
          "type": "array",
          "items": {
            "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1asset"
          }
        }
      },
      "required": [
        "id",
        "step"
      ]
    },
    "composer.cloud.domain.symphony-score-v1/if-child-true": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string"
        },
        "suppress-incomplete-warnings?": {
          "type": "boolean"
        },
        "collapsed?": {
          "type": "boolean"
        },
        "collapsed-specified-weight?": {
          "type": "boolean"
        },
        "weight": {
          "type": "object",
          "properties": {
            "num": {
              "type": "string",
              "x-anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "integer",
                  "format": "int64"
                },
                {
                  "type": "number",
                  "format": "double"
                }
              ]
            },
            "den": {
              "type": "string",
              "x-anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "integer",
                  "format": "int64"
                },
                {
                  "type": "number",
                  "format": "double"
                }
              ]
            }
          },
          "required": [
            "num",
            "den"
          ],
          "additionalProperties": false
        },
        "step": {
          "type": "string",
          "enum": [
            "if-child"
          ]
        },
        "is-else-condition?": {
          "enum": [
            false
          ]
        },
        "children": {
          "default": [],
          "type": "array",
          "items": {
            "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1if",
            "x-anyOf": [
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1if"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1group"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1wt-cash-equal"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1wt-cash-specified"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1asset"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1empty"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1wt-inverse-vol"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1wt-marketcap"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1filter"
              }
            ]
          }
        },
        "comparator": {
          "type": "string",
          "enum": [
            "gt",
            "gte",
            "eq",
            "lt",
            "lte"
          ]
        },
        "lhs-fn": {
          "type": "string",
          "enum": [
            "cumulative-return",
            "current-price",
            "exponential-moving-average-price",
            "max-drawdown",
            "moving-average-price",
            "moving-average-return",
            "relative-strength-index",
            "standard-deviation-price",
            "standard-deviation-return",
            "percentage-price-oscillator",
            "percentage-price-oscillator-signal",
            "moving-average-convergence-divergence",
            "moving-average-convergence-divergence-signal",
            "lower-bollinger",
            "upper-bollinger"
          ]
        },
        "lhs-val": {
          "type": "string"
        },
        "rhs-val": {
          "type": "string",
          "x-anyOf": [
            {
              "type": "string"
            },
            {
              "type": "integer",
              "format": "int64"
            },
            {
              "type": "number",
              "format": "double"
            }
          ]
        },
        "rhs-fixed-value?": {
          "type": "boolean"
        },
        "rhs-fn": {
          "type": "string",
          "enum": [
            "cumulative-return",
            "current-price",
            "exponential-moving-average-price",
            "max-drawdown",
            "moving-average-price",
            "moving-average-return",
            "relative-strength-index",
            "standard-deviation-price",
            "standard-deviation-return",
            "percentage-price-oscillator",
            "percentage-price-oscillator-signal",
            "moving-average-convergence-divergence",
            "moving-average-convergence-divergence-signal",
            "lower-bollinger",
            "upper-bollinger"
          ]
        },
        "lhs-window-days": {
          "type": "integer",
          "format": "int64",
          "x-anyOf": [
            {
              "type": "integer",
              "format": "int64"
            },
            {
              "type": "string"
            }
          ]
        },
        "rhs-window-days": {
          "type": "integer",
          "format": "int64",
          "x-anyOf": [
            {
              "type": "integer",
              "format": "int64"
            },
            {
              "type": "string"
            }
          ]
        },
        "lhs-fn-params": {
          "type": "object",
          "additionalProperties": {
            "type": "integer",
            "format": "int64",
            "x-anyOf": [
              {
                "type": "integer",
                "format": "int64"
              },
              {
                "type": "number",
                "format": "double"
              }
            ]
          }
        },
        "rhs-fn-params": {
          "type": "object",
          "additionalProperties": {
            "type": "integer",
            "format": "int64",
            "x-anyOf": [
              {
                "type": "integer",
                "format": "int64"
              },
              {
                "type": "number",
                "format": "double"
              }
            ]
          }
        },
        "condition": {
          "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1condition",
          "x-allOf": [
            {
              "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1condition"
            },
            {}
          ]
        }
      },
      "required": [
        "id",
        "step",
        "is-else-condition?"
      ]
    },
    "node/asset": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string",
          "format": "uuid"
        },
        "meta": {
          "type": "object",
          "properties": {
            "name": {
              "type": "string",
              "x-nullable": true
            }
          }
        },
        "ticker": {
          "type": "string"
        },
        "exchange": {
          "type": "string"
        },
        "type": {
          "const": "node_asset"
        }
      },
      "required": [
        "id",
        "ticker",
        "type"
      ]
    },
    "composer.cloud.domain.symphony-score-v1/condition": {
      "type": "object",
      "properties": {
        "condition-type": {
          "const": "binary"
        },
        "lhs": {
          "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1constant",
          "x-anyOf": [
            {
              "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1constant"
            },
            {
              "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1indicator"
            }
          ]
        },
        "comparator": {
          "type": "string",
          "enum": [
            "gt",
            "gte",
            "eq",
            "lt",
            "lte"
          ]
        },
        "rhs": {
          "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1constant",
          "x-anyOf": [
            {
              "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1constant"
            },
            {
              "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1indicator"
            }
          ]
        }
      },
      "required": [
        "condition-type",
        "lhs",
        "comparator",
        "rhs"
      ],
      "additionalProperties": false,
      "x-anyOf": [
        {
          "type": "object",
          "properties": {
            "condition-type": {
              "const": "binary"
            },
            "lhs": {
              "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1constant",
              "x-anyOf": [
                {
                  "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1constant"
                },
                {
                  "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1indicator"
                }
              ]
            },
            "comparator": {
              "type": "string",
              "enum": [
                "gt",
                "gte",
                "eq",
                "lt",
                "lte"
              ]
            },
            "rhs": {
              "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1constant",
              "x-anyOf": [
                {
                  "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1constant"
                },
                {
                  "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1indicator"
                }
              ]
            }
          },
          "required": [
            "condition-type",
            "lhs",
            "comparator",
            "rhs"
          ],
          "additionalProperties": false
        },
        {
          "type": "object",
          "properties": {
            "condition-type": {
              "const": "compound"
            },
            "operator": {
              "type": "string",
              "enum": [
                "any",
                "all"
              ]
            },
            "conditions": {
              "type": "array",
              "items": {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1condition"
              },
              "minItems": 1,
              "maxItems": 50
            }
          },
          "required": [
            "condition-type",
            "operator",
            "conditions"
          ],
          "additionalProperties": false
        },
        {
          "type": "object",
          "properties": {
            "condition-type": {
              "const": "binary-compound"
            },
            "operator": {
              "type": "string",
              "enum": [
                "any",
                "all"
              ]
            },
            "tickers": {
              "type": "array",
              "items": {
                "type": "string"
              },
              "minItems": 1,
              "maxItems": 50
            },
            "lhs": {
              "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1indicator-pattern"
            },
            "comparator": {
              "type": "string",
              "enum": [
                "gt",
                "gte",
                "eq",
                "lt",
                "lte"
              ]
            },
            "rhs": {
              "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1constant",
              "x-anyOf": [
                {
                  "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1constant"
                },
                {
                  "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1indicator"
                }
              ]
            }
          },
          "required": [
            "condition-type",
            "operator",
            "tickers",
            "lhs",
            "comparator",
            "rhs"
          ],
          "additionalProperties": false
        }
      ]
    },
    "composer.cloud.domain.symphony-score-v1/wt-inverse-vol": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string"
        },
        "suppress-incomplete-warnings?": {
          "type": "boolean"
        },
        "collapsed?": {
          "type": "boolean"
        },
        "collapsed-specified-weight?": {
          "type": "boolean"
        },
        "weight": {
          "type": "object",
          "properties": {
            "num": {
              "type": "string",
              "x-anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "integer",
                  "format": "int64"
                },
                {
                  "type": "number",
                  "format": "double"
                }
              ]
            },
            "den": {
              "type": "string",
              "x-anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "integer",
                  "format": "int64"
                },
                {
                  "type": "number",
                  "format": "double"
                }
              ]
            }
          },
          "required": [
            "num",
            "den"
          ],
          "additionalProperties": false
        },
        "step": {
          "type": "string",
          "enum": [
            "wt-inverse-vol"
          ]
        },
        "window-days": {
          "type": "string",
          "x-anyOf": [
            {
              "type": "string"
            },
            {
              "type": "integer",
              "format": "int64"
            }
          ]
        },
        "children": {
          "default": [],
          "type": "array",
          "items": {
            "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1if",
            "x-anyOf": [
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1if"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1group"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1wt-cash-equal"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1wt-cash-specified"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1asset"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1empty"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1wt-inverse-vol"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1wt-marketcap"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1filter"
              }
            ]
          }
        }
      },
      "required": [
        "id",
        "step"
      ]
    },
    "composer.cloud.domain.symphony-score-v1/asset": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string"
        },
        "suppress-incomplete-warnings?": {
          "type": "boolean"
        },
        "collapsed?": {
          "type": "boolean"
        },
        "collapsed-specified-weight?": {
          "type": "boolean"
        },
        "weight": {
          "type": "object",
          "properties": {
            "num": {
              "type": "string",
              "x-anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "integer",
                  "format": "int64"
                },
                {
                  "type": "number",
                  "format": "double"
                }
              ]
            },
            "den": {
              "type": "string",
              "x-anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "integer",
                  "format": "int64"
                },
                {
                  "type": "number",
                  "format": "double"
                }
              ]
            }
          },
          "required": [
            "num",
            "den"
          ],
          "additionalProperties": false
        },
        "name": {
          "type": "string",
          "x-nullable": true
        },
        "ticker": {
          "type": "string"
        },
        "exchange": {
          "type": "string"
        },
        "has_marketcap": {
          "type": "boolean"
        },
        "step": {
          "type": "string",
          "enum": [
            "asset"
          ]
        }
      },
      "required": [
        "id",
        "ticker",
        "step"
      ]
    },
    "composer.cloud.domain.symphony-score-v1/wt-cash-specified": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string"
        },
        "suppress-incomplete-warnings?": {
          "type": "boolean"
        },
        "collapsed?": {
          "type": "boolean"
        },
        "collapsed-specified-weight?": {
          "type": "boolean"
        },
        "weight": {
          "type": "object",
          "properties": {
            "num": {
              "type": "string",
              "x-anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "integer",
                  "format": "int64"
                },
                {
                  "type": "number",
                  "format": "double"
                }
              ]
            },
            "den": {
              "type": "string",
              "x-anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "integer",
                  "format": "int64"
                },
                {
                  "type": "number",
                  "format": "double"
                }
              ]
            }
          },
          "required": [
            "num",
            "den"
          ],
          "additionalProperties": false
        },
        "step": {
          "type": "string",
          "enum": [
            "wt-cash-specified"
          ]
        },
        "children": {
          "default": [],
          "type": "array",
          "items": {
            "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1if",
            "x-anyOf": [
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1if"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1group"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1wt-cash-equal"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1wt-cash-specified"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1asset"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1empty"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1wt-inverse-vol"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1wt-marketcap"
              },
              {
                "$ref": "#/definitions/composer.cloud.domain.symphony-score-v1~1filter"
              }
            ]
          }
        }
      },
      "required": [
        "id",
        "step"
      ]
    },
    "node/filter": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string",
          "format": "uuid"
        },
        "meta": {
          "type": "object",
          "properties": {
            "name": {
              "type": "string",
              "x-nullable": true
            }
          }
        },
        "type": {
          "const": "node_filter"
        },
        "sort_fn": {
          "type": "array",
          "items": {},
          "x-items": [
            {
              "const": "weight_every_fn"
            },
            {
              "$ref": "#/definitions/function~1call"
            }
          ],
          "x-anyOf": [
            {
              "type": "array",
              "items": {},
              "x-items": [
                {
                  "const": "weight_every_fn"
                },
                {
                  "$ref": "#/definitions/function~1call"
                }
              ]
            },
            {
              "type": "array",
              "items": {},
              "x-items": [
                {
                  "const": "weight_fn"
                },
                {
                  "type": "array",
                  "items": {
                    "$ref": "#/definitions/function~1call"
                  }
                }
              ]
            }
          ]
        },
        "take_count": {
          "type": "integer",
          "format": "int64"
        },
        "direction": {
          "type": "string",
          "enum": [
            "asc",
            "desc"
          ]
        },
        "children": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/node~1if",
            "x-anyOf": [
              {
                "$ref": "#/definitions/node~1if"
              },
              {
                "$ref": "#/definitions/node~1weight"
              },
              {
                "$ref": "#/definitions/node~1asset"
              },
              {
                "$ref": "#/definitions/node~1filter"
              }
            ]
          }
        }
      },
      "required": [
        "id",
        "type",
        "sort_fn",
        "take_count",
        "direction",
        "children"
      ]
    },
    "function/comparison": {
      "type": "array",
      "items": {},
      "x-items": [
        {
          "type": "string",
          "enum": [
            "fn_gte",
            "fn_lte",
            "fn_approx_eq",
            "fn_gt",
            "fn_lt"
          ]
        },
        {
          "$ref": "#/definitions/function~1call"
        },
        {
          "$ref": "#/definitions/function~1call"
        }
      ],
      "x-anyOf": [
        {
          "type": "array",
          "items": {},
          "x-items": [
            {
              "type": "string",
              "enum": [
                "fn_gte",
                "fn_lte",
                "fn_approx_eq",
                "fn_gt",
                "fn_lt"
              ]
            },
            {
              "$ref": "#/definitions/function~1call"
            },
            {
              "$ref": "#/definitions/function~1call"
            }
          ]
        },
        {
          "type": "array",
          "items": {},
          "x-items": [
            {
              "type": "string",
              "enum": [
                "fn_and",
                "fn_or"
              ]
            },
            {
              "$ref": "#/definitions/function~1comparison"
            },
            {
              "$ref": "#/definitions/function~1comparison"
            }
          ]
        },
        {
          "type": "array",
          "items": {},
          "x-items": [
            {
              "const": "fn_not"
            },
            {
              "$ref": "#/definitions/function~1comparison"
            }
          ]
        }
      ]
    },
    "composer.cloud.domain.symphony-score-v1/indicator": {
      "type": "object",
      "properties": {
        "fn": {
          "type": "string",
          "enum": [
            "cumulative-return",
            "current-price",
            "exponential-moving-average-price",
            "max-drawdown",
            "moving-average-price",
            "moving-average-return",
            "relative-strength-index",
            "standard-deviation-price",
            "standard-deviation-return",
            "percentage-price-oscillator",
            "percentage-price-oscillator-signal",
            "moving-average-convergence-divergence",
            "moving-average-convergence-divergence-signal",
            "lower-bollinger",
            "upper-bollinger"
          ]
        },
        "params": {
          "type": "object",
          "additionalProperties": {
            "type": "integer",
            "format": "int64",
            "x-anyOf": [
              {
                "type": "integer",
                "format": "int64"
              },
              {
                "type": "number",
                "format": "double"
              }
            ]
          }
        },
        "ticker": {
          "type": "string"
        }
      },
      "required": [
        "fn",
        "ticker"
      ],
      "additionalProperties": false
    },
    "node/weight": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string",
          "format": "uuid"
        },
        "meta": {
          "type": "object",
          "properties": {
            "name": {
              "type": "string",
              "x-nullable": true
            }
          }
        },
        "type": {
          "const": "node_weight"
        },
        "weight": {
          "type": "array",
          "items": {},
          "x-items": [
            {
              "const": "weight_every_fn"
            },
            {
              "$ref": "#/definitions/function~1call"
            }
          ],
          "x-anyOf": [
            {
              "type": "array",
              "items": {},
              "x-items": [
                {
                  "const": "weight_every_fn"
                },
                {
                  "$ref": "#/definitions/function~1call"
                }
              ]
            },
            {
              "type": "array",
              "items": {},
              "x-items": [
                {
                  "const": "weight_fn"
                },
                {
                  "type": "array",
                  "items": {
                    "$ref": "#/definitions/function~1call"
                  }
                }
              ]
            },
            {
              "type": "array",
              "items": {},
              "x-items": [
                {
                  "const": "weight_equal"
                }
              ]
            },
            {
              "type": "array",
              "items": {},
              "x-items": [
                {
                  "const": "weight_constants"
                },
                {
                  "type": "array",
                  "items": {
                    "type": "number",
                    "format": "double"
                  }
                }
              ]
            },
            {
              "type": "array",
              "items": {},
              "x-items": [
                {
                  "const": "weight_market_cap"
                },
                {
                  "type": "array",
                  "items": {
                    "type": "string"
                  }
                }
              ]
            }
          ]
        },
        "children": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/node~1if",
            "x-anyOf": [
              {
                "$ref": "#/definitions/node~1if"
              },
              {
                "$ref": "#/definitions/node~1weight"
              },
              {
                "$ref": "#/definitions/node~1asset"
              },
              {
                "$ref": "#/definitions/node~1filter"
              }
            ]
          }
        }
      },
      "required": [
        "id",
        "type",
        "weight",
        "children"
      ]
    },
    "node/root": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string"
        },
        "meta": {
          "type": "object",
          "properties": {
            "name": {
              "type": "string"
            },
            "description": {
              "type": "string"
            }
          },
          "required": [
            "name",
            "description"
          ]
        },
        "type": {
          "const": "node_root"
        },
        "score_version": {
          "const": "v2"
        },
        "asset_class": {
          "default": "EQUITIES",
          "type": "string",
          "enum": [
            "EQUITIES",
            "CRYPTO"
          ]
        },
        "rebalance": {
          "type": "string",
          "enum": [
            "threshold",
            "daily",
            "weekly",
            "monthly",
            "quarterly",
            "yearly"
          ]
        },
        "rebalance_corridor_width": {
          "type": "number",
          "format": "double"
        },
        "children": {
          "type": "array",
          "items": {
            "$ref": "#/definitions/node~1if",
            "x-anyOf": [
              {
                "$ref": "#/definitions/node~1if"
              },
              {
                "$ref": "#/definitions/node~1weight"
              },
              {
                "$ref": "#/definitions/node~1asset"
              },
              {
                "$ref": "#/definitions/node~1filter"
              }
            ]
          }
        }
      },
      "required": [
        "id",
        "meta",
        "type",
        "score_version",
        "asset_class",
        "rebalance",
        "children"
      ],
      "additionalProperties": false
    }
  }
}