{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/power-bi/json-schema/power-bi-tables-schema.json",
  "title": "Tables",
  "description": "The OData response wrapper for a Power BI table collection",
  "x-generated": "2026-11-12",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/power-bi-pushdatasets-api-openapi.yml#/components/schemas/Tables",
  "properties": {
    "@odata.context": {
      "type": "string",
      "description": "OData context"
    },
    "value": {
      "type": "array",
      "description": "The Power BI tables",
      "items": {
        "$ref": "#/$defs/Table"
      }
    }
  },
  "$defs": {
    "ASMashupExpression": {
      "description": "A dataset table source",
      "required": [
        "expression"
      ],
      "properties": {
        "expression": {
          "type": "string",
          "description": "The source expression"
        }
      }
    },
    "Column": {
      "required": [
        "name",
        "dataType"
      ],
      "description": "A dataset column",
      "properties": {
        "name": {
          "pattern": "^[\\x09\\x0A\\x0D\\x20-\\uD7FF\\uE000-\\uFFFD\\u10000-\\u10FFFF]+$",
          "type": "string",
          "description": "The column name"
        },
        "dataType": {
          "type": "string",
          "description": "The column data type"
        },
        "formatString": {
          "type": "string",
          "description": "Optional. The format of the column as specified in [FORMAT_STRING](https://docs.microsoft.com/analysis-services/multidimensional-models/mdx/mdx-cell-properties-format-string-contents)."
        },
        "sortByColumn": {
          "type": "string",
          "description": "Optional. String name of a column in the same table to be used to order the current column."
        },
        "dataCategory": {
          "type": "string",
          "description": "Optional. The string value to be used for the data category which describes the data within this column."
        },
        "isHidden": {
          "type": "boolean",
          "description": "Optional. Whether the column is hidden. The default is `false`."
        },
        "summarizeBy": {
          "type": "string",
          "description": "Optional. The aggregate function to use for summarizing this column."
        }
      }
    },
    "Measure": {
      "required": [
        "name",
        "expression"
      ],
      "description": "A Power BI measure",
      "properties": {
        "name": {
          "pattern": "^[\\x09\\x0A\\x0D\\x20-\\uD7FF\\uE000-\\uFFFD\\u10000-\\u10FFFF]+$",
          "type": "string",
          "description": "The measure name"
        },
        "expression": {
          "type": "string",
          "description": "A valid DAX expression"
        },
        "formatString": {
          "type": "string",
          "description": "Optional. A string describing how the value should be formatted when it's displayed as specified in [FORMAT_STRING](https://docs.microsoft.com/analysis-services/multidimensional-models/mdx/mdx-cell-properties-format-string-contents)."
        },
        "description": {
          "type": "string",
          "description": "Optional. The measure description."
        },
        "isHidden": {
          "type": "boolean",
          "description": "Optional. Whether the measure is hidden."
        }
      }
    },
    "Row": {
      "description": "A data row in a dataset",
      "properties": {
        "id": {
          "type": "string",
          "description": "The unique row ID"
        }
      }
    },
    "Table": {
      "required": [
        "name",
        "columns"
      ],
      "description": "A dataset table",
      "properties": {
        "name": {
          "pattern": "^[\\x09\\x0A\\x0D\\x20\\x23\\x2D\\x30-\\x39\\x40-\\x5A\\x5E-\\x5F\\x61-\\x7A\\x7E-\\uD7FF\\uE000-\\uFFFD\\u10000-\\u10FFFF]{1,100}$",
          "type": "string",
          "description": "The table name"
        },
        "columns": {
          "type": "array",
          "description": "The column schema for this table",
          "items": {
            "$ref": "#/$defs/Column"
          }
        },
        "rows": {
          "type": "array",
          "description": "The data rows within this table",
          "items": {
            "$ref": "#/$defs/Row"
          }
        },
        "measures": {
          "type": "array",
          "description": "The measures within this table",
          "items": {
            "$ref": "#/$defs/Measure"
          }
        },
        "isHidden": {
          "type": "boolean",
          "description": "Optional. Whether this dataset table is hidden."
        },
        "description": {
          "type": "string",
          "description": "The table description"
        },
        "source": {
          "type": "array",
          "description": "The table source",
          "items": {
            "$ref": "#/$defs/ASMashupExpression"
          }
        }
      }
    }
  }
}