{
  "components": {
    "responses": {
      "DEFAULT_ERROR": {
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/Error"
            }
          }
        },
        "description": "Default error response"
      },
      "UNPROCESSABLE_ENTITY": {
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/Error"
            }
          }
        },
        "description": "Unprocessable Entity"
      }
    },
    "schemas": {
      "ChannelFilters": {
        "properties": {
          "instagram_ugc": {
            "allOf": [
              {
                "$ref": "#/components/schemas/InstagramUGCFilters"
              }
            ],
            "description": "Filters for Instagram UGC channel"
          }
        },
        "type": "object"
      },
      "Dashboard": {
        "properties": {
          "id": {
            "description": "Id of the dashboard",
            "minimum": 0,
            "readOnly": true,
            "type": "integer"
          },
          "label": {
            "description": "Slugified version of name",
            "type": "string"
          },
          "layout": {
            "default": null,
            "items": {
              "$ref": "#/components/schemas/DashboardLayout"
            },
            "nullable": true,
            "type": "array"
          },
          "name": {
            "description": "Name of the dashboard",
            "type": "string"
          },
          "user_id": {
            "description": "Id of the User who created the dashboard",
            "minimum": 0,
            "readOnly": true,
            "type": "integer"
          }
        },
        "required": [
          "name"
        ],
        "type": "object"
      },
      "DashboardLayout": {
        "properties": {
          "h": {
            "description": "The height of the report object.",
            "type": "integer"
          },
          "meta": {
            "$ref": "#/components/schemas/ReportMeta"
          },
          "report_id": {
            "description": "The ID of the report object.",
            "minimum": 0,
            "type": "integer"
          },
          "type": {
            "description": "The type of report.",
            "enum": [
              "CONTENT_OWNED",
              "CONTENT_OWNED_STORIES",
              "CONTENT_UGC",
              "CONTENT",
              "MULTI_BRAND_METRIC",
              "SINGLE_METRIC",
              "GRAPH",
              "HEADER",
              "COMPETITIVE_CONTENT",
              "COMPETITIVE_MULTI_BRAND_METRIC",
              "COMPETITIVE_GRAPH",
              "MULTI_METRIC_MEDIA_TYPE",
              "BENCHMARK_METRIC",
              "BENCHMARK_GRAPH"
            ],
            "type": "string"
          },
          "w": {
            "description": "The width of the report object.",
            "type": "integer"
          },
          "x": {
            "description": "The X axis location of the report object.",
            "type": "integer"
          },
          "y": {
            "description": "The Y axis location of the report object.",
            "type": "integer"
          }
        },
        "required": [
          "type"
        ],
        "type": "object"
      },
      "DashboardRequest": {
        "properties": {
          "layout": {
            "items": {
              "$ref": "#/components/schemas/DashboardLayout"
            },
            "type": "array"
          },
          "name": {
            "description": "Name user has selected for their new dashboard",
            "maxLength": 50,
            "minLength": 1,
            "type": "string"
          }
        },
        "required": [
          "name"
        ],
        "type": "object"
      },
      "Dashboards": {
        "properties": {
          "data": {
            "items": {
              "$ref": "#/components/schemas/Dashboard"
            },
            "type": "array"
          },
          "paging": {
            "$ref": "#/components/schemas/PagingData"
          }
        },
        "type": "object"
      },
      "Error": {
        "properties": {
          "code": {
            "description": "Error code",
            "type": "integer"
          },
          "errors": {
            "description": "Errors",
            "type": "object"
          },
          "message": {
            "description": "Error message",
            "type": "string"
          },
          "status": {
            "description": "Error name",
            "type": "string"
          }
        },
        "type": "object"
      },
      "InstagramUGCFilters": {
        "properties": {
          "ugc_media_type": {
            "description": "UGC Media Type",
            "enum": [
              "MENTIONED",
              "TAGGED",
              "ALL"
            ],
            "example": "MENTIONED",
            "type": "string"
          }
        },
        "type": "object"
      },
      "PagingData": {
        "properties": {
          "count": {
            "description": "Number of records in the current page.",
            "type": "integer"
          },
          "next": {
            "description": "URL to the next page of data.",
            "format": "url",
            "type": "string"
          },
          "previous": {
            "description": "URL to the previous page of data.",
            "format": "url",
            "type": "string"
          }
        },
        "type": "object"
      },
      "ReportCreateRequest": {
        "properties": {
          "meta": {
            "$ref": "#/components/schemas/ReportMeta"
          },
          "type": {
            "description": "The type of report.",
            "enum": [
              "CONTENT_OWNED",
              "CONTENT_OWNED_STORIES",
              "CONTENT_UGC",
              "CONTENT",
              "MULTI_BRAND_METRIC",
              "SINGLE_METRIC",
              "GRAPH",
              "HEADER",
              "COMPETITIVE_CONTENT",
              "COMPETITIVE_MULTI_BRAND_METRIC",
              "COMPETITIVE_GRAPH",
              "MULTI_METRIC_MEDIA_TYPE",
              "BENCHMARK_METRIC",
              "BENCHMARK_GRAPH"
            ],
            "type": "string"
          }
        },
        "required": [
          "meta",
          "type"
        ],
        "type": "object"
      },
      "ReportDataRequestBody": {
        "properties": {
          "benchmarks": {
            "description": "List of benchmarks and their buckets requested by the report",
            "items": {
              "$ref": "#/components/schemas/ReportIndustryBenchmarksRequest"
            },
            "type": "array"
          },
          "competitor_source_account_ids": {
            "description": "List of ids of the competitive brands requested by the report",
            "items": {
              "type": "string"
            },
            "minItems": 1,
            "type": "array"
          }
        },
        "type": "object"
      },
      "ReportDataResponse": {
        "properties": {
          "data": {
            "description": "Report data on the requested metric",
            "readOnly": true
          }
        },
        "type": "object"
      },
      "ReportIndustryBenchmarksRequest": {
        "properties": {
          "follower_bucket": {
            "description": "Follower bucket grouping for the data.",
            "enum": [
              "BUCKET_UNKNOWN",
              "BUCKET_OVERALL",
              "BUCKET_10K_200K",
              "BUCKET_200K_1M",
              "BUCKET_1M_PLUS"
            ],
            "type": "string"
          },
          "industry_id": {
            "description": "Id of the Industry being requested.",
            "nullable": true,
            "type": "integer"
          }
        },
        "required": [
          "follower_bucket",
          "industry_id"
        ],
        "type": "object"
      },
      "ReportMeta": {
        "properties": {
          "benchmarks": {
            "description": "List of benchmarks and their buckets requested by the report",
            "items": {
              "$ref": "#/components/schemas/ReportIndustryBenchmarksRequest"
            },
            "type": "array"
          },
          "brand_ids": {
            "description": "List of ids of the brands requested by the report",
            "items": {
              "minimum": 0,
              "type": "integer"
            },
            "minItems": 1,
            "type": "array"
          },
          "channel": {
            "description": "Channel requested by the report",
            "enum": [
              "FACEBOOK",
              "INSTAGRAM",
              "INSTAGRAM_UGC",
              "INSTAGRAM_STORIES",
              "INSTAGRAM_COMPETITIVE",
              "INSTAGRAM_BENCHMARKS",
              "PINTEREST",
              "TIKTOK",
              "TWITTER",
              "YOUTUBE"
            ],
            "type": "string"
          },
          "channels": {
            "description": "Channels requested by the report",
            "items": {
              "enum": [
                "FACEBOOK",
                "INSTAGRAM",
                "INSTAGRAM_UGC",
                "INSTAGRAM_STORIES",
                "INSTAGRAM_COMPETITIVE",
                "INSTAGRAM_BENCHMARKS",
                "PINTEREST",
                "TIKTOK",
                "TWITTER",
                "YOUTUBE"
              ],
              "type": "string"
            },
            "type": "array"
          },
          "competitor_source_account_ids": {
            "description": "List of ids of the competitive brands requested by the report",
            "items": {
              "type": "string"
            },
            "minItems": 1,
            "type": "array"
          },
          "metric": {
            "description": "Metric requested by the report",
            "minLength": 1,
            "type": "string"
          },
          "metrics": {
            "description": "List of metrics requested by the report",
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "name": {
            "description": "Name requested by the report",
            "maxLength": 100,
            "minLength": 1,
            "type": "string"
          },
          "sort_order": {
            "description": "Sort Order requested by the report",
            "enum": [
              "ASC",
              "DESC"
            ],
            "type": "string"
          }
        },
        "type": "object"
      },
      "ReportResponse": {
        "properties": {
          "dashboard_id": {
            "description": "Id of the dashboard this report is attached to",
            "minimum": 0,
            "type": "integer"
          },
          "data": {
            "description": "Report data on the requested metric",
            "readOnly": true
          },
          "id": {
            "description": "Id of the report",
            "minimum": 0,
            "readOnly": true,
            "type": "integer"
          },
          "meta": {
            "$ref": "#/components/schemas/ReportMeta"
          },
          "type": {
            "description": "The type of report.",
            "enum": [
              "CONTENT_OWNED",
              "CONTENT_OWNED_STORIES",
              "CONTENT_UGC",
              "CONTENT",
              "MULTI_BRAND_METRIC",
              "SINGLE_METRIC",
              "GRAPH",
              "HEADER",
              "COMPETITIVE_CONTENT",
              "COMPETITIVE_MULTI_BRAND_METRIC",
              "COMPETITIVE_GRAPH",
              "MULTI_METRIC_MEDIA_TYPE",
              "BENCHMARK_METRIC",
              "BENCHMARK_GRAPH"
            ],
            "type": "string"
          }
        },
        "required": [
          "dashboard_id",
          "meta",
          "type"
        ],
        "type": "object"
      },
      "ReportUpdate": {
        "properties": {
          "meta": {
            "$ref": "#/components/schemas/ReportMeta"
          },
          "type": {
            "enum": [
              "CONTENT_OWNED",
              "CONTENT_OWNED_STORIES",
              "CONTENT_UGC",
              "CONTENT",
              "MULTI_BRAND_METRIC",
              "SINGLE_METRIC",
              "GRAPH",
              "HEADER",
              "COMPETITIVE_CONTENT",
              "COMPETITIVE_MULTI_BRAND_METRIC",
              "COMPETITIVE_GRAPH",
              "MULTI_METRIC_MEDIA_TYPE",
              "BENCHMARK_METRIC",
              "BENCHMARK_GRAPH"
            ],
            "type": "string"
          }
        },
        "required": [
          "meta"
        ],
        "type": "object"
      }
    },
    "securitySchemes": {
      "BearerAuth": {
        "type": "http",
        "scheme": "bearer",
        "bearerFormat": "API key from Dash Social developer settings"
      }
    }
  },
  "info": {
    "contact": {
      "email": "support@dashsocial.com",
      "name": "Dash Social",
      "url": "https://dashsocial.com"
    },
    "description": "Dash Social Backend Service for Dashboard.",
    "title": "Dash Social Dashboard Backend Service",
    "version": "1.0.0",
    "x-logo": {
      "altText": "Dash Social logo",
      "href": "https://developer.dashsocial.com",
      "url": "https://developer.dashsocial.com/assets/logo.svg"
    }
  },
  "openapi": "3.0.2",
  "paths": {
    "/dashboards": {
      "get": {
        "parameters": [
          {
            "description": "Number of results to return in a single response.",
            "in": "query",
            "name": "limit",
            "required": false,
            "schema": {
              "maximum": 1000,
              "minimum": 1,
              "type": "integer"
            }
          },
          {
            "description": "The offset of the first result to be returned.",
            "in": "query",
            "name": "offset",
            "required": false,
            "schema": {
              "minimum": 0,
              "type": "integer"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Dashboards"
                }
              }
            },
            "description": "OK"
          },
          "422": {
            "$ref": "#/components/responses/UNPROCESSABLE_ENTITY"
          },
          "default": {
            "$ref": "#/components/responses/DEFAULT_ERROR"
          }
        },
        "summary": "Get a list of dashboard objects",
        "tags": [
          "Dashboard"
        ],
        "x-public": true
      },
      "post": {
        "parameters": [
          {
            "description": "(Optional) The ID of a dashboard that already exists. If found, the new ./dashboard will be a duplicate of the dashboard with this ID.",
            "in": "query",
            "name": "source_id",
            "required": false,
            "schema": {
              "type": "integer"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/DashboardRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Dashboard"
                }
              }
            },
            "description": "Created"
          },
          "422": {
            "$ref": "#/components/responses/UNPROCESSABLE_ENTITY"
          },
          "default": {
            "$ref": "#/components/responses/DEFAULT_ERROR"
          }
        },
        "summary": "Create a dashboard object with a specific name",
        "tags": [
          "Dashboard"
        ],
        "x-public": true
      }
    },
    "/dashboards/{dashboard_id}": {
      "delete": {
        "responses": {
          "204": {
            "description": "No Content"
          },
          "default": {
            "$ref": "#/components/responses/DEFAULT_ERROR"
          }
        },
        "summary": "Soft delete a dashboard",
        "tags": [
          "Dashboard"
        ],
        "x-public": true
      },
      "get": {
        "parameters": [
          {
            "description": "Start date of the reporting time range. Required for spreadsheet exports",
            "in": "query",
            "name": "start_date",
            "required": false,
            "schema": {
              "example": "2021-02-01",
              "format": "date-time",
              "type": "string"
            }
          },
          {
            "description": "End date of the reporting time range. Required for spreadsheet exports",
            "in": "query",
            "name": "end_date",
            "required": false,
            "schema": {
              "example": "2021-02-07",
              "format": "date-time",
              "type": "string"
            }
          },
          {
            "description": "The socket id of the requesting entity. Required for spreadsheet exports",
            "in": "query",
            "name": "socket_id",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "The format in which the export will be returned",
            "in": "query",
            "name": "format",
            "required": false,
            "schema": {
              "enum": [
                "xlsx"
              ],
              "type": "string"
            }
          },
          {
            "description": "The way data should be grouped in graph reports, can be either DAILY or MONTHLY",
            "in": "query",
            "name": "time_scale",
            "required": false,
            "schema": {
              "enum": [
                "DAILY",
                "MONTHLY"
              ],
              "example": "DAILY",
              "type": "string"
            }
          },
          {
            "description": "Start date of the reporting comparison time range. Required for spreadsheet exports",
            "in": "query",
            "name": "context_end_date",
            "required": false,
            "schema": {
              "example": "2021-01-07",
              "format": "date-time",
              "type": "string"
            }
          },
          {
            "description": "Start date of the reporting comparison time range. Required for spreadsheet exports",
            "in": "query",
            "name": "context_start_date",
            "required": false,
            "schema": {
              "example": "2021-01-01",
              "format": "date-time",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Dashboard"
                }
              }
            },
            "description": "OK"
          },
          "422": {
            "$ref": "#/components/responses/UNPROCESSABLE_ENTITY"
          },
          "default": {
            "$ref": "#/components/responses/DEFAULT_ERROR"
          }
        },
        "summary": "Get a single dashboard object",
        "tags": [
          "Dashboard"
        ],
        "x-public": true
      },
      "parameters": [
        {
          "description": "The Dash Social assigned ID of the dashboard.",
          "in": "path",
          "name": "dashboard_id",
          "required": true,
          "schema": {
            "minimum": 0,
            "type": "integer"
          }
        }
      ],
      "patch": {
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/DashboardRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Dashboard"
                }
              }
            },
            "description": "OK"
          },
          "422": {
            "$ref": "#/components/responses/UNPROCESSABLE_ENTITY"
          },
          "default": {
            "$ref": "#/components/responses/DEFAULT_ERROR"
          }
        },
        "summary": "Update a single dashboard object",
        "tags": [
          "Dashboard"
        ],
        "x-public": true
      }
    },
    "/dashboards/{dashboard_id}/reports": {
      "parameters": [
        {
          "description": "The Dash Social assigned ID of the dashboard.",
          "in": "path",
          "name": "dashboard_id",
          "required": true,
          "schema": {
            "minimum": 0,
            "type": "integer"
          }
        }
      ],
      "post": {
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ReportCreateRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ReportResponse"
                }
              }
            },
            "description": "Created"
          },
          "422": {
            "$ref": "#/components/responses/UNPROCESSABLE_ENTITY"
          },
          "default": {
            "$ref": "#/components/responses/DEFAULT_ERROR"
          }
        },
        "summary": "Create a report object",
        "tags": [
          "Dashboard Report"
        ],
        "x-public": true
      }
    },
    "/dashboards/{dashboard_id}/reports/{report_id}": {
      "delete": {
        "responses": {
          "204": {
            "description": "No Content"
          },
          "default": {
            "$ref": "#/components/responses/DEFAULT_ERROR"
          }
        },
        "summary": "Soft deletes a report object from a dashboard",
        "tags": [
          "Dashboard Report"
        ],
        "x-public": true
      },
      "get": {
        "parameters": [
          {
            "description": "Include the report data",
            "in": "query",
            "name": "include_data",
            "required": false,
            "schema": {
              "default": false,
              "type": "boolean"
            }
          },
          {
            "description": "The content length of report data",
            "in": "query",
            "name": "limit",
            "required": false,
            "schema": {
              "default": 6,
              "type": "integer"
            }
          },
          {
            "description": "Start date of the reporting time range. Required if include_data=True",
            "in": "query",
            "name": "start_date",
            "required": false,
            "schema": {
              "example": "2021-02-01",
              "format": "date-time",
              "type": "string"
            }
          },
          {
            "description": "End date of the reporting time range. Required if include_data=True",
            "in": "query",
            "name": "end_date",
            "required": false,
            "schema": {
              "example": "2021-02-07",
              "format": "date-time",
              "type": "string"
            }
          },
          {
            "description": "The way data should be grouped in graph reports, can be either DAILY or MONTHLY",
            "in": "query",
            "name": "time_scale",
            "required": false,
            "schema": {
              "default": "DAILY",
              "enum": [
                "DAILY",
                "MONTHLY"
              ],
              "example": "DAILY",
              "type": "string"
            }
          },
          {
            "description": "The format in which the report will be returned",
            "in": "query",
            "name": "format",
            "required": false,
            "schema": {
              "enum": [
                "csv"
              ],
              "type": "string"
            }
          },
          {
            "description": "Start date of the reporting comparison time range. Required for metric reports if include_data=True",
            "in": "query",
            "name": "context_end_date",
            "required": false,
            "schema": {
              "example": "2021-01-07",
              "format": "date-time",
              "type": "string"
            }
          },
          {
            "description": "Start date of the reporting comparison time range. Required for metric reports if include_data=True",
            "in": "query",
            "name": "context_start_date",
            "required": false,
            "schema": {
              "example": "2021-01-01",
              "format": "date-time",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ReportResponse"
                }
              }
            },
            "description": "OK"
          },
          "422": {
            "$ref": "#/components/responses/UNPROCESSABLE_ENTITY"
          },
          "default": {
            "$ref": "#/components/responses/DEFAULT_ERROR"
          }
        },
        "summary": "Get a dashboard's report object",
        "tags": [
          "Dashboard Report"
        ],
        "x-public": true
      },
      "parameters": [
        {
          "description": "The Dash Social assigned ID of the dashboard.",
          "in": "path",
          "name": "dashboard_id",
          "required": true,
          "schema": {
            "minimum": 0,
            "type": "integer"
          }
        },
        {
          "description": "The Dash Social assigned ID of the report.",
          "in": "path",
          "name": "report_id",
          "required": true,
          "schema": {
            "minimum": 0,
            "type": "integer"
          }
        }
      ],
      "patch": {
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ReportUpdate"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ReportResponse"
                }
              }
            },
            "description": "OK"
          },
          "422": {
            "$ref": "#/components/responses/UNPROCESSABLE_ENTITY"
          },
          "default": {
            "$ref": "#/components/responses/DEFAULT_ERROR"
          }
        },
        "summary": "Update a single report object",
        "tags": [
          "Dashboard Report"
        ],
        "x-public": true
      }
    },
    "/reports/data": {
      "get": {
        "operationId": "get-report-data",
        "parameters": [
          {
            "description": "The content length of report data",
            "in": "query",
            "name": "limit",
            "required": false,
            "schema": {
              "default": 6,
              "type": "integer"
            }
          },
          {
            "description": "Channels requested by the report",
            "explode": false,
            "in": "query",
            "name": "channels",
            "required": true,
            "schema": {
              "items": {
                "enum": [
                  "FACEBOOK",
                  "INSTAGRAM",
                  "INSTAGRAM_UGC",
                  "INSTAGRAM_STORIES",
                  "INSTAGRAM_COMPETITIVE",
                  "INSTAGRAM_BENCHMARKS",
                  "PINTEREST",
                  "TIKTOK",
                  "TWITTER",
                  "YOUTUBE"
                ],
                "type": "string"
              },
              "minItems": 1,
              "type": "array"
            },
            "style": "form"
          },
          {
            "description": "Sort Order requested by the report (ASC | DESC)",
            "in": "query",
            "name": "sort_order",
            "required": false,
            "schema": {
              "default": "SortOrderEnum.DESC",
              "enum": [
                "ASC",
                "DESC"
              ],
              "type": "string"
            }
          },
          {
            "description": "Start date of the reporting time range. Required if include_data=True",
            "in": "query",
            "name": "start_date",
            "required": true,
            "schema": {
              "example": "2021-02-01",
              "format": "date-time",
              "type": "string"
            }
          },
          {
            "description": "End date of the reporting time range. Required if include_data=True",
            "in": "query",
            "name": "end_date",
            "required": true,
            "schema": {
              "example": "2021-02-07",
              "format": "date-time",
              "type": "string"
            }
          },
          {
            "description": "Filters for specific channels",
            "in": "query",
            "name": "filters",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/ChannelFilters"
                }
              ]
            }
          },
          {
            "description": "Preferred filename prefix for the report. If not provided, report_type type will be used.",
            "in": "query",
            "name": "filename_prefix",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Metric requested by the report",
            "explode": false,
            "in": "query",
            "name": "metrics",
            "required": true,
            "schema": {
              "items": {
                "type": "string"
              },
              "minItems": 1,
              "type": "array"
            },
            "style": "form"
          },
          {
            "description": "List of ids of the brands requested by the report",
            "explode": false,
            "in": "query",
            "name": "brand_ids",
            "required": false,
            "schema": {
              "items": {
                "minimum": 0,
                "type": "integer"
              },
              "minItems": 1,
              "type": "array"
            },
            "style": "form"
          },
          {
            "description": "The way data should be grouped in graph reports, can be either DAILY or MONTHLY",
            "in": "query",
            "name": "time_scale",
            "required": false,
            "schema": {
              "default": "DAILY",
              "enum": [
                "DAILY",
                "MONTHLY"
              ],
              "example": "DAILY",
              "type": "string"
            }
          },
          {
            "description": "The type report data to return can be: ['CONTENT_OWNED', 'CONTENT_OWNED_STORIES', 'CONTENT_UGC', 'CONTENT', 'MULTI_BRAND_METRIC', 'SINGLE_METRIC', 'GRAPH', 'HEADER', 'COMPETITIVE_CONTENT', 'COMPETITIVE_MULTI_BRAND_METRIC', 'COMPETITIVE_GRAPH', 'MULTI_METRIC_MEDIA_TYPE', 'BENCHMARK_METRIC', 'BENCHMARK_GRAPH']",
            "in": "query",
            "name": "report_type",
            "required": false,
            "schema": {
              "default": "SINGLE_METRIC",
              "enum": [
                "CONTENT_OWNED",
                "CONTENT_OWNED_STORIES",
                "CONTENT_UGC",
                "CONTENT",
                "MULTI_BRAND_METRIC",
                "SINGLE_METRIC",
                "GRAPH",
                "HEADER",
                "COMPETITIVE_CONTENT",
                "COMPETITIVE_MULTI_BRAND_METRIC",
                "COMPETITIVE_GRAPH",
                "MULTI_METRIC_MEDIA_TYPE",
                "BENCHMARK_METRIC",
                "BENCHMARK_GRAPH"
              ],
              "example": "SINGLE_METRIC",
              "type": "string"
            }
          },
          {
            "description": "The format in which the report will be returned",
            "in": "query",
            "name": "format",
            "required": false,
            "schema": {
              "enum": [
                "csv"
              ],
              "type": "string"
            }
          },
          {
            "description": "List of ids of the competitive brands requested by the report",
            "explode": false,
            "in": "query",
            "name": "competitor_source_account_ids",
            "required": false,
            "schema": {
              "items": {
                "type": "string"
              },
              "minItems": 1,
              "type": "array"
            },
            "style": "form"
          },
          {
            "description": "If true, ElasticSearch stats will have a null value instead of a 0 if no posts of the required type have been created within the requested time frame.",
            "in": "query",
            "name": "require_posts",
            "required": false,
            "schema": {
              "default": false,
              "type": "boolean"
            }
          },
          {
            "description": "Start date of the reporting comparison time range. Required for metric reports",
            "in": "query",
            "name": "context_end_date",
            "required": false,
            "schema": {
              "example": "2021-01-07",
              "format": "date-time",
              "type": "string"
            }
          },
          {
            "description": "If true, the share of voice metric will be calculated for valid isntagram competitive metrics",
            "in": "query",
            "name": "include_share_of_voice",
            "required": false,
            "schema": {
              "default": false,
              "type": "boolean"
            }
          },
          {
            "description": "Start date of the reporting comparison time range. Required for metric reports",
            "in": "query",
            "name": "context_start_date",
            "required": false,
            "schema": {
              "example": "2021-01-01",
              "format": "date-time",
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ReportDataResponse"
                }
              }
            },
            "description": "OK"
          },
          "422": {
            "$ref": "#/components/responses/UNPROCESSABLE_ENTITY"
          },
          "default": {
            "$ref": "#/components/responses/DEFAULT_ERROR"
          }
        },
        "summary": "Get report data",
        "description": "Retrieve report data for Owned, Earned, Community, Social Listening, TSI, and Social Advertising reports using query parameters.\n\n- See [Export dashboard report data via API](/guides/reporting/export-dashboard-report-data-via-api) for detailed guides on each report type.",
        "tags": [
          "Report"
        ],
        "x-public": true
      },
      "put": {
        "operationId": "query-report-data",
        "parameters": [
          {
            "description": "The content length of report data",
            "in": "query",
            "name": "limit",
            "required": false,
            "schema": {
              "default": 6,
              "type": "integer"
            }
          },
          {
            "description": "Channels requested by the report",
            "explode": false,
            "in": "query",
            "name": "channels",
            "required": true,
            "schema": {
              "items": {
                "enum": [
                  "FACEBOOK",
                  "INSTAGRAM",
                  "INSTAGRAM_UGC",
                  "INSTAGRAM_STORIES",
                  "INSTAGRAM_COMPETITIVE",
                  "INSTAGRAM_BENCHMARKS",
                  "PINTEREST",
                  "TIKTOK",
                  "TWITTER",
                  "YOUTUBE"
                ],
                "type": "string"
              },
              "minItems": 1,
              "type": "array"
            },
            "style": "form"
          },
          {
            "description": "Sort Order requested by the report (ASC | DESC)",
            "in": "query",
            "name": "sort_order",
            "required": false,
            "schema": {
              "default": "SortOrderEnum.DESC",
              "enum": [
                "ASC",
                "DESC"
              ],
              "type": "string"
            }
          },
          {
            "description": "Start date of the reporting time range. Required if include_data=True",
            "in": "query",
            "name": "start_date",
            "required": true,
            "schema": {
              "example": "2021-02-01",
              "format": "date-time",
              "type": "string"
            }
          },
          {
            "description": "End date of the reporting time range. Required if include_data=True",
            "in": "query",
            "name": "end_date",
            "required": true,
            "schema": {
              "example": "2021-02-07",
              "format": "date-time",
              "type": "string"
            }
          },
          {
            "description": "Filters for specific channels",
            "in": "query",
            "name": "filters",
            "required": false,
            "schema": {
              "allOf": [
                {
                  "$ref": "#/components/schemas/ChannelFilters"
                }
              ]
            }
          },
          {
            "description": "Preferred filename prefix for the report. If not provided, report_type type will be used.",
            "in": "query",
            "name": "filename_prefix",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Metric requested by the report",
            "explode": false,
            "in": "query",
            "name": "metrics",
            "required": true,
            "schema": {
              "items": {
                "type": "string"
              },
              "minItems": 1,
              "type": "array"
            },
            "style": "form"
          },
          {
            "description": "List of ids of the brands requested by the report",
            "explode": false,
            "in": "query",
            "name": "brand_ids",
            "required": false,
            "schema": {
              "items": {
                "minimum": 0,
                "type": "integer"
              },
              "minItems": 1,
              "type": "array"
            },
            "style": "form"
          },
          {
            "description": "The way data should be grouped in graph reports, can be either DAILY or MONTHLY",
            "in": "query",
            "name": "time_scale",
            "required": false,
            "schema": {
              "default": "DAILY",
              "enum": [
                "DAILY",
                "MONTHLY"
              ],
              "example": "DAILY",
              "type": "string"
            }
          },
          {
            "description": "The type report data to return can be: ['CONTENT_OWNED', 'CONTENT_OWNED_STORIES', 'CONTENT_UGC', 'CONTENT', 'MULTI_BRAND_METRIC', 'SINGLE_METRIC', 'GRAPH', 'HEADER', 'COMPETITIVE_CONTENT', 'COMPETITIVE_MULTI_BRAND_METRIC', 'COMPETITIVE_GRAPH', 'MULTI_METRIC_MEDIA_TYPE', 'BENCHMARK_METRIC', 'BENCHMARK_GRAPH']",
            "in": "query",
            "name": "report_type",
            "required": false,
            "schema": {
              "default": "SINGLE_METRIC",
              "enum": [
                "CONTENT_OWNED",
                "CONTENT_OWNED_STORIES",
                "CONTENT_UGC",
                "CONTENT",
                "MULTI_BRAND_METRIC",
                "SINGLE_METRIC",
                "GRAPH",
                "HEADER",
                "COMPETITIVE_CONTENT",
                "COMPETITIVE_MULTI_BRAND_METRIC",
                "COMPETITIVE_GRAPH",
                "MULTI_METRIC_MEDIA_TYPE",
                "BENCHMARK_METRIC",
                "BENCHMARK_GRAPH"
              ],
              "example": "SINGLE_METRIC",
              "type": "string"
            }
          },
          {
            "description": "The format in which the report will be returned",
            "in": "query",
            "name": "format",
            "required": false,
            "schema": {
              "enum": [
                "csv"
              ],
              "type": "string"
            }
          },
          {
            "description": "List of ids of the competitive brands requested by the report",
            "explode": false,
            "in": "query",
            "name": "competitor_source_account_ids",
            "required": false,
            "schema": {
              "items": {
                "type": "string"
              },
              "minItems": 1,
              "type": "array"
            },
            "style": "form"
          },
          {
            "description": "If true, ElasticSearch stats will have a null value instead of a 0 if no posts of the required type have been created within the requested time frame.",
            "in": "query",
            "name": "require_posts",
            "required": false,
            "schema": {
              "default": false,
              "type": "boolean"
            }
          },
          {
            "description": "Start date of the reporting comparison time range. Required for metric reports",
            "in": "query",
            "name": "context_end_date",
            "required": false,
            "schema": {
              "example": "2021-01-07",
              "format": "date-time",
              "type": "string"
            }
          },
          {
            "description": "If true, the share of voice metric will be calculated for valid isntagram competitive metrics",
            "in": "query",
            "name": "include_share_of_voice",
            "required": false,
            "schema": {
              "default": false,
              "type": "boolean"
            }
          },
          {
            "description": "Start date of the reporting comparison time range. Required for metric reports",
            "in": "query",
            "name": "context_start_date",
            "required": false,
            "schema": {
              "example": "2021-01-01",
              "format": "date-time",
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ReportDataRequestBody"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ReportDataResponse"
                }
              }
            },
            "description": "OK"
          },
          "422": {
            "$ref": "#/components/responses/UNPROCESSABLE_ENTITY"
          },
          "default": {
            "$ref": "#/components/responses/DEFAULT_ERROR"
          }
        },
        "summary": "Query report data with request body",
        "description": "Retrieve report data for Competitive and Benchmark reports. Use this endpoint when you need to pass `competitor_source_account_ids` or `benchmarks` in the request body.\n\n- See [Export dashboard report data via API](/guides/reporting/export-dashboard-report-data-via-api) for detailed guides on each report type.",
        "tags": [
          "Report"
        ],
        "x-public": true
      }
    }
  },
  "servers": [
    {
      "url": "https://dashboard.dashsocial.com"
    }
  ],
  "tags": [
    {
      "description": "Endpoints responsible for creating, reading, and updating dashboards.",
      "name": "Dashboard"
    },
    {
      "description": "Endpoints responsible for creating, reading, and updating reports.",
      "name": "Dashboard Report"
    },
    {
      "description": "Endpoints responsible for general reporting data / CSVs",
      "name": "Report"
    }
  ],
  "x-readme": {
    "explorer-enabled": true,
    "proxy-enabled": true
  },
  "security": [
    {
      "BearerAuth": []
    }
  ]
}