Skip to content

Run custom report

GET/admin/v1/stores/{store_id}/analytics/custom-reports/{report_id}/report

    A custom report's answer over a period of store-local days, with the report.

    Path parameters

    • store_idstringrequired

      The store's ID, like store_01k8qs5s…. Apps get it with the install, in the OAuth redirect and the token response.

    • report_idstringrequired

      The custom report's ID, like crpt_01k8qs5s….

    Query parameters

    • fromstringrequired

      First store-local day, YYYY-MM-DD.

    • tostringrequired

      Last store-local day (included), YYYY-MM-DD. At most 366 days from from.

    • group_byenum

      Time series only: day, week (from Sunday) or month. Default: days up to a month, weeks up to half a year, months beyond.

      • day
      • week
      • month
    • languagestring

      Exports only: the language of the column headings, en or ar (default: the store's).

    Headers

    • shop-api-versionYYYY-MM

      The version to answer in. Without it, your app’s pinned version, else the newest.

    Returns

    200 The report and its answer.

    Errors

    • 404not_foundNo such report.
    • 422validation_failedInvalid dates or range.