Skip to content

Get Blog Stats​

GET
/api/v1/posts/{id}/stats

Parameters​

Path Parameters

id*
Type
string
Required

Responses​

Aggregated stats

Playground​

Server
Variables
Key
Value

Samples​

Powered by VitePress OpenAPI

Read aggregated stats for a blog post.

Auth: optional.

Parameters ​

NameInTypeRequiredDescription
idpathstringYesPost id

Request Body ​

None.

Response 200 ​

json
{
	"data": {
		"post_id": "post_2",
		"views": 120,
		"comments": 8,
		"reactions": 15
	},
	"user_context": { "authenticated": false },
	"meta": {}
}

Response Errors ​

  • 404 post not found

Notes ​

  • Good for dashboards and admin analytics.
  • Can be cached if the backend exposes stale-friendly stats.