Codat · Schema

Commerce report

## Structure Assess reports follow a consistent structure. Reports contain four sections of information: ### 1. Report definition Information such as: 1. The report info (e.g. enhanced_profit_and_loss). 2. The display name of the report (e.g. Enhanced Profit and Loss). ### 2. Dimension info Information about the dimension contained in the reports such as: 1. The type of dimension (e.g. datetime, recordRef). 2. The display name of the dimension (e.g. Period, Category type, Category sub type). 3. The details about each item within the dimension (e.g. displayName:"Jan 2022", start:"...", end:"...", id:"...", name:"..."). ### 3. Measure info Information about the measures contained in the report such as: 1. The display name of the measure (e.g. value of account, percentage change). 2. The type of the measure (e.g. currency, percentage). 3. The unit of the measure (e.g. %, GBP). ### 4. The data for the report When the *includeDisplayName* parameter is set to *true*, it shows the *dimensionDisplayName* and *itemDisplayName* to make the data human-readable. The default setting for *includeDisplayName* is *false*. ## Displaying the report Reports can be rendered as follows (ordering is implicit rather than explicit): ![A table showing an example of how a report can be rendered](https://files.readme.io/1fa20ca-Report1.png) # Data model ## Dimensions

Unified-API

Properties

Name Type Description
reportInfo object
dimensions array
measures array
reportData array
errors array
View JSON Schema on GitHub

JSON Schema

codat-commercereport-schema.json Raw ↑
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "#/components/schemas/CommerceReport",
  "title": "Commerce report",
  "description": "## Structure\n\nAssess reports follow a consistent structure. Reports contain four sections of information:\n\n### 1. Report definition\n\nInformation such as:\n\n  1. The report info (e.g. enhanced_profit_and_loss).\n  2. The display name of the report (e.g. Enhanced Profit and Loss).\n  \n### 2. Dimension info\n\nInformation about the dimension contained in the reports such as:\n\n  1. The type of dimension (e.g. datetime, recordRef).\n  2. The display name of the dimension (e.g. Period, Category type, Category sub type).\n  3. The details about each item within the dimension (e.g. displayName:\"Jan 2022\", start:\"...\", end:\"...\", id:\"...\", name:\"...\").\n\n### 3. Measure info\n\nInformation about the measures contained in the report such as:\n\n  1. The display name of the measure (e.g. value of account, percentage change).\n  2. The type of the measure (e.g. currency, percentage).\n  3. The unit of the measure (e.g. %, GBP).\n  \n### 4. The data for the report\n\nWhen the *includeDisplayName* parameter is set to *true*, it shows the *dimensionDisplayName* and *itemDisplayName* to make the data human-readable. The default setting for *includeDisplayName* is *false*.\n\n\n## Displaying the report\n\nReports can be rendered as follows (ordering is implicit rather than explicit):\n\n![A table showing an example of how a report can be rendered](https://files.readme.io/1fa20ca-Report1.png)\n\n# Data model\n\n## Dimensions",
  "type": "object",
  "properties": {
    "reportInfo": {
      "type": "object",
      "additionalProperties": {
        "type": "string"
      }
    },
    "dimensions": {
      "type": "array",
      "items": {
        "$ref": "#/components/schemas/CommerceReport/definitions/commerceReportDimension"
      }
    },
    "measures": {
      "type": "array",
      "items": {
        "$ref": "#/components/schemas/CommerceReport/definitions/commerceReportMeasure"
      }
    },
    "reportData": {
      "type": "array",
      "items": {
        "$ref": "#/components/schemas/CommerceReport/definitions/commerceReportComponent"
      }
    },
    "errors": {
      "type": "array",
      "items": {
        "$ref": "#/components/schemas/CommerceReport/definitions/commerceReportError"
      }
    }
  },
  "definitions": {
    "commerceReportMeasure": {
      "title": "Measure",
      "type": "object",
      "properties": {
        "displayName": {
          "description": "The measure's display name.",
          "type": "string"
        },
        "units": {
          "type": "string",
          "description": "The measure's units e.g. percentage (%)."
        },
        "index": {
          "type": "integer",
          "description": "The measure's index."
        },
        "type": {
          "type": "string",
          "description": "The measure's type."
        }
      }
    },
    "commerceReportError": {
      "title": "Error",
      "type": "object",
      "properties": {
        "message": {
          "type": "string",
          "description": "Message returned by error."
        },
        "type": {
          "type": "string",
          "description": "The type of error."
        },
        "details": {
          "description": "Additional details on the error.",
          "type": "object",
          "additionalProperties": {
            "type": "array",
            "items": {
              "type": "string"
            }
          }
        }
      }
    },
    "commerceReportDimension": {
      "title": "Dimension",
      "type": "object",
      "properties": {
        "index": {
          "type": "integer",
          "description": "The dimension's index."
        },
        "displayName": {
          "type": "string",
          "description": "The dimension's display name."
        },
        "type": {
          "type": "string",
          "description": "The dimension's type."
        },
        "items": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "index": {
                "type": "integer",
                "description": "The dimension's items index."
              }
            }
          }
        }
      }
    },
    "commerceReportComponent": {
      "title": "Report component",
      "type": "object",
      "properties": {
        "dimension": {
          "type": "integer",
          "description": "The component's dimension."
        },
        "dimensionDisplayName": {
          "type": "string",
          "description": "The component's display name."
        },
        "item": {
          "type": "integer",
          "description": "The component's item number."
        },
        "itemDisplayName": {
          "type": "string",
          "description": "The component's item display name."
        },
        "measures": {
          "type": "array",
          "items": {
            "$ref": "#/components/schemas/CommerceReport/definitions/reportComponentMeasure"
          }
        },
        "components": {
          "type": "array",
          "items": {
            "$ref": "#/components/schemas/CommerceReport/definitions/commerceReportComponent"
          }
        }
      }
    },
    "reportComponentMeasure": {
      "type": "object",
      "title": "Report component measure",
      "properties": {
        "index": {
          "type": "integer",
          "description": "The measure's index."
        },
        "measureDisplayName": {
          "type": "string",
          "description": "The measure's display name."
        },
        "value": {
          "type": "number",
          "format": "decimal",
          "description": "The measure's value."
        }
      }
    }
  },
  "x-examples": {
    "Example 1": {
      "reportInfo": {
        "additionalProp1": "string",
        "additionalProp2": "string",
        "additionalProp3": "string"
      },
      "dimensions": [
        {
          "index": 0,
          "displayName": "string",
          "type": "string",
          "items": [
            {
              "index": 0
            }
          ]
        }
      ],
      "measures": [
        {
          "displayName": "string",
          "units": "string",
          "index": 0,
          "type": "string"
        }
      ],
      "reportData": [
        {
          "dimension": 0,
          "dimensionDisplayName": "string",
          "item": 0,
          "itemDisplayName": "string",
          "measures": [
            {
              "index": 0,
              "measureDisplayName": "string"
            }
          ],
          "components": [
            "string"
          ]
        }
      ],
      "errors": [
        {
          "message": "string",
          "type": "DatesOutOfRange",
          "details": {
            "additionalProp1": [
              "string"
            ],
            "additionalProp2": [
              "string"
            ],
            "additionalProp3": [
              "string"
            ]
          }
        }
      ]
    }
  }
}

Work with this as data

Every JSON Schema here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for schemas

4 MCP tools reach this
  • find_json_schemasBrowse and filter every JSON Schema in the catalog.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This JSON Schema
curl "https://apis.io/api/v1/json-schemas/codat-commercereport"
All schemas
curl "https://apis.io/api/v1/json-schemas?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.