{
  "openapi": "3.0.1",
  "info": {
    "title": "SEC Company Financials API: income, balance sheet, cash flow",
    "description": "US company financials from SEC XBRL: revenue, profit, EPS, balance sheet, cash flow, free cash flow and margins per fiscal year or quarter, 2009 to today. By ticker or CIK, 10-K/10-Q and 20-F filers. Each value cites its XBRL tag and SEC filing. Q4 derived where not reported.",
    "version": "0.1",
    "x-build-id": "WfbaNfSHsxMgak9sQ"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/bosco_labs~sec-company-financials/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-bosco_labs-sec-company-financials",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/acts/bosco_labs~sec-company-financials/runs": {
      "post": {
        "operationId": "runs-sync-bosco_labs-sec-company-financials",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor and returns information about the initiated run in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/runsResponseSchema"
                }
              }
            }
          }
        }
      }
    },
    "/acts/bosco_labs~sec-company-financials/run-sync": {
      "post": {
        "operationId": "run-sync-bosco_labs-sec-company-financials",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "inputSchema": {
        "type": "object",
        "properties": {
          "tickers": {
            "title": "Tickers",
            "type": "array",
            "description": "US tickers as listed by the SEC, e.g. [\"AAPL\", \"MSFT\"]; share classes with a dash or dot, e.g. \"BRK-B\". Foreign companies filing 20-F/40-F work too, e.g. \"NVO\". Mapped to the CIK with the SEC's company_tickers.json; an unknown ticker is skipped with suggestions in the status message. Empty = use `ciks`.",
            "items": {
              "type": "string",
              "pattern": "^\\s*[A-Za-z0-9][A-Za-z0-9./-]{0,9}\\s*$"
            }
          },
          "ciks": {
            "title": "CIKs",
            "type": "array",
            "description": "SEC Central Index Keys as digits, leading zeros optional, e.g. [\"320193\"] for Apple. Use for delisted companies and filers without a ticker. Empty = use `tickers`; at least one of the two is required.",
            "items": {
              "type": "string"
            }
          },
          "period": {
            "title": "Period",
            "enum": [
              "annual",
              "quarterly"
            ],
            "type": "string",
            "description": "\"annual\" = one row per fiscal year (FY). \"quarterly\" = one row per fiscal quarter, Q1-Q4, each a discrete 3-month period (Q4 and year-to-date-only cash flows are derived, see `warnings`). Companies without quarterly XBRL data (most 20-F filers) return fiscal years instead. Default \"annual\".",
            "default": "annual"
          },
          "years": {
            "title": "Fiscal years back",
            "minimum": 1,
            "maximum": 20,
            "type": "integer",
            "description": "How many of the latest fiscal years to return per company, e.g. 5 (5 rows annual, up to 20 rows quarterly; 2 with quarterly = the last 8 quarters). XBRL data starts in 2009-2011. Default 5, max 20.",
            "default": 5
          },
          "metrics": {
            "title": "Metrics",
            "type": "array",
            "description": "Only these output fields, e.g. [\"revenue\", \"net_income\", \"free_cash_flow\", \"operating_margin\"]. Valid: revenue, cost_of_revenue, gross_profit, research_and_development, selling_general_and_administrative, operating_profit, profit_before_tax, net_income, net_income_attributable_to_parent, eps_basic, eps_diluted, weighted_average_shares_basic, weighted_average_shares_diluted, depreciation_amortisation, total_assets, current_assets, cash_and_equivalents, total_liabilities, current_liabilities, noncurrent_liabilities, long_term_debt, total_equity, equity_attributable_to_parent, shares_outstanding, operating_cash_flow, investing_cash_flow, financing_cash_flow, capex, dividends_paid, free_cash_flow, ebitda, gross_margin, operating_margin, net_margin, return_on_equity, equity_ratio, revenue_growth. Empty = all of them.",
            "items": {
              "type": "string",
              "enum": [
                "revenue",
                "cost_of_revenue",
                "gross_profit",
                "research_and_development",
                "selling_general_and_administrative",
                "operating_profit",
                "profit_before_tax",
                "net_income",
                "net_income_attributable_to_parent",
                "eps_basic",
                "eps_diluted",
                "weighted_average_shares_basic",
                "weighted_average_shares_diluted",
                "depreciation_amortisation",
                "total_assets",
                "current_assets",
                "cash_and_equivalents",
                "total_liabilities",
                "current_liabilities",
                "noncurrent_liabilities",
                "long_term_debt",
                "total_equity",
                "equity_attributable_to_parent",
                "shares_outstanding",
                "operating_cash_flow",
                "investing_cash_flow",
                "financing_cash_flow",
                "capex",
                "dividends_paid",
                "free_cash_flow",
                "ebitda",
                "gross_margin",
                "operating_margin",
                "net_margin",
                "return_on_equity",
                "equity_ratio",
                "revenue_growth"
              ],
              "enumTitles": [
                "Revenue",
                "Cost of revenue",
                "Gross profit",
                "Research and development",
                "Selling general and administrative",
                "Operating profit",
                "Profit before tax",
                "Net income",
                "Net income attributable to parent",
                "Eps basic",
                "Eps diluted",
                "Weighted average shares basic",
                "Weighted average shares diluted",
                "Depreciation amortisation",
                "Total assets",
                "Current assets",
                "Cash and equivalents",
                "Total liabilities",
                "Current liabilities",
                "Noncurrent liabilities",
                "Long term debt",
                "Total equity",
                "Equity attributable to parent",
                "Shares outstanding",
                "Operating cash flow",
                "Investing cash flow",
                "Financing cash flow",
                "Capex",
                "Dividends paid",
                "Free cash flow",
                "Ebitda",
                "Gross margin",
                "Operating margin",
                "Net margin",
                "Return on equity",
                "Equity ratio",
                "Revenue growth"
              ]
            }
          },
          "includeSources": {
            "title": "Include sources",
            "type": "boolean",
            "description": "true = each row has `sources` (per value: the XBRL tag and the SEC accession number it came from, plus how it was derived) and `filings` (form, filing date and URL of each filing cited). false = values only, about 3x smaller rows. Default true.",
            "default": true
          }
        }
      },
      "runsResponseSchema": {
        "type": "object",
        "properties": {
          "data": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "actId": {
                "type": "string"
              },
              "userId": {
                "type": "string"
              },
              "startedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "finishedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "status": {
                "type": "string",
                "example": "READY"
              },
              "meta": {
                "type": "object",
                "properties": {
                  "origin": {
                    "type": "string",
                    "example": "API"
                  },
                  "userAgent": {
                    "type": "string"
                  }
                }
              },
              "stats": {
                "type": "object",
                "properties": {
                  "inputBodyLen": {
                    "type": "integer",
                    "example": 2000
                  },
                  "rebootCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "restartCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "resurrectCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "computeUnits": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "options": {
                "type": "object",
                "properties": {
                  "build": {
                    "type": "string",
                    "example": "latest"
                  },
                  "timeoutSecs": {
                    "type": "integer",
                    "example": 300
                  },
                  "memoryMbytes": {
                    "type": "integer",
                    "example": 1024
                  },
                  "diskMbytes": {
                    "type": "integer",
                    "example": 2048
                  }
                }
              },
              "buildId": {
                "type": "string"
              },
              "defaultKeyValueStoreId": {
                "type": "string"
              },
              "defaultDatasetId": {
                "type": "string"
              },
              "defaultRequestQueueId": {
                "type": "string"
              },
              "buildNumber": {
                "type": "string",
                "example": "1.0.0"
              },
              "containerUrl": {
                "type": "string"
              },
              "usage": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "integer",
                    "example": 1
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "usageTotalUsd": {
                "type": "number",
                "example": 0.00005
              },
              "usageUsd": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "number",
                    "example": 0.00005
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}