CopyHero

Get Store Analytics

GET
/api/v1/analytics/stores/{store_id}

Get detailed analytics for a specific store.

Returns store-specific metrics including:

  • store_id: The store ID
  • store_name: The store name
  • totals: Aggregated batch_count, task_count, jobs_count
  • workflow_breakdown: Per-workflow statistics for this store

Access Control:

  • Regular users: Can only access their owned or employed stores (403 otherwise)
  • Superusers in a browser session: can access any store (API keys and MCP never act as superuser)

Authorization

HTTPBearer
headerAuthorizationBearer <token>

Path Parameters

store_id*Store Id

Query Parameters

start_date?|

Start of time range (inclusive). Defaults to 30 days ago.

end_date?|

End of time range (inclusive). Defaults to now.

state?|

Filter jobs_count by state (pending, running, finished, error, cancelled)

Response Body

Successful Response

application/json
  1. response

Response schema for GET /analytics/stores/{store_id} endpoint.

store_id*Store Id

The store ID

store_name*Store Name

The store name

period*

The time period for the analytics

totals*

Aggregated counts for the store

workflow_breakdown*array<>

Per-workflow breakdown for this store

Example Request
curl -X GET 'https://app.copyhero.app/api/v1/analytics/stores/0'
Example Response
{  "store_id": 0,  "store_name": "string",  "period": {    "start": "2019-08-24T14:15:22Z",    "end": "2019-08-24T14:15:22Z"  },  "totals": {    "batch_count": 0,    "task_count": 0,    "jobs_count": 0  },  "workflow_breakdown": [    {      "blueprint_id": 0,      "blueprint_name": "string",      "task_count": 0,      "jobs_count": 0    }  ]}