GoatCounter · Capability
GoatCounter API
The GoatCounter API can be used to manage sites, users, count pageviews, export raw data, retrieve statistics, and build custom dashboards on top of GoatCounter web analytics.
What You Can Do
POST
Count
— Count pageviews
/count
POST
Createexport
— Create CSV export
/export
GET
Getexport
— Get export info
/export/{id}
GET
Downloadexport
— Download export
/export/{id}/download
GET
Statstotal
— List total pageview counts
/stats/total
GET
Statshits
— View/visitor stats per path
/stats/hits
GET
Statshitsrefs
— Referral stats for a path
/stats/hits/{path_id}
GET
Statsbypage
— Stats for a category (browser, system, location, etc.)
/stats/{page}
GET
Statsbypagedetail
— Detailed stats within a category
/stats/{page}/{id}
GET
Listsites
— List sites
/sites
PUT
Createsite
— Create a new site
/sites
GET
Getsite
— Get site detail
/sites/{id}
POST
Updatesitepost
— Update a site
/sites/{id}
PATCH
Patchsite
— Patch a site
/sites/{id}
GET
Getme
— Get current user
/me
GET
Listpaths
— List paths
/paths
MCP Tools
count
Count pageviews
createexport
Create CSV export
getexport
Get export info
read-only
idempotent
downloadexport
Download export
read-only
idempotent
statstotal
List total pageview counts
read-only
idempotent
statshits
View/visitor stats per path
read-only
idempotent
statshitsrefs
Referral stats for a path
read-only
idempotent
statsbypage
Stats for a category (browser, system, location, etc.)
read-only
idempotent
statsbypagedetail
Detailed stats within a category
read-only
idempotent
listsites
List sites
read-only
idempotent
createsite
Create a new site
idempotent
getsite
Get site detail
read-only
idempotent
updatesitepost
Update a site
patchsite
Patch a site
getme
Get current user
read-only
idempotent
listpaths
List paths
read-only
idempotent