ReadonlyaddAdd a user to a team: https://umami.is/docs/api/teams-api#post-apiteamsteamidusers (TODO UNTESTED)
ReadonlycreateCreates a report: https://umami.is/docs/api/reports-api#post-apireports (TODO UNTESTED)
Optionaldescription?: stringDescription of report
Name of report
Optionalparameters?: anyParameters for report
ReadonlycreateCreates a team: https://umami.is/docs/api/teams-api#post-apiteams (TODO UNTESTED)
ReadonlycreateCreates a user: https://umami.is/docs/api/users-api#post-apiusers
ReadonlycreateCreates a website: https://umami.is/docs/api/websites-api#post-apiwebsites (TODO UNTESTED)
The full domain of the tracked website
Optionalid?: stringForce a UUID assignment to the website
The name of the website in Umami
OptionalshareId?: string | nullA unique string to enable a share url. Set null to unshare
OptionalteamId?: stringThe ID of the team the website will be created under
ReadonlydeleteDeletes a report: https://umami.is/docs/api/reports-api#delete-apireportsreportid (TODO UNTESTED)
ReadonlydeleteDelete a team: https://umami.is/docs/api/teams-api#delete-apiteamsteamid (TODO UNTESTED)
ReadonlydeleteDeletes a user: https://umami.is/docs/api/users-api#delete-apiusersuserid
ReadonlydeleteDeletes a website: https://umami.is/docs/api/websites-api#delete-apiwebsiteswebsiteid (TODO UNTESTED)
ReadonlygetRealtime stats within the last 30 minutes: https://umami.is/docs/api/realtime-api#get-apirealtimewebsiteid (TODO UNTESTED)
ReadonlygetGets a report by ID: https://umami.is/docs/api/reports-api#get-apireportsreportid (TODO UNTESTED)
ReadonlygetGet all reports by website ID: https://umami.is/docs/api/reports-api#get-apireports (TODO UNTESTED)
ReadonlygetSee how users engage with your marketing and what drives conversions: https://umami.is/docs/api/reports-api#post-apireportsattribution (TODO UNTESTED)
Attribution model
Conversion step
Conversion type
ReadonlygetDive deeper into your data by using segments and filters: https://umami.is/docs/api/reports-api#post-apireportsbreakdown (TODO UNTESTED)
ReadonlygetUnderstand the conversion and drop-off rate of users: https://umami.is/docs/api/reports-api#post-apireportsfunnel (TODO UNTESTED)
Type of event and conversion step
Window of days between funnel steps to be considered a conversion
ReadonlygetTrack your goals for pageviews and events: https://umami.is/docs/api/reports-api#post-apireportsgoals (TODO UNTESTED)
Conversion type
Conversion step value
ReadonlygetUnderstand how users nagivate through your website: https://umami.is/docs/api/reports-api#post-apireportsjourney (TODO UNTESTED)
OptionalendStep?: stringEnding step URL or event name
Starting step URL or event name
Number of steps from 3 to 7
ReadonlygetMeasure your website stickiness by tracking how often users return: https://umami.is/docs/api/reports-api#post-apireportsretention (TODO UNTESTED)
Timezone (ex. America/Los_Angeles)
ReadonlygetGet currency for given range. Needed for Revenue and optional in Attribution reports: https://umami.is/docs/api/reports-api#post-apireportsrevenue (TODO UNTESTED)
Currency code (ISO 4217)
Timezone (ex. America/Los_Angeles)
ReadonlygetTrack your campaigns through UTM parameters: https://umami.is/docs/api/reports-api#post-apireportsutm (TODO UNTESTED)
ReadonlygetGet a team: https://umami.is/docs/api/teams-api#get-apiteamsteamid (TODO UNTESTED)
ReadonlygetReturns all teams: https://umami.is/docs/api/teams-api#get-apiteams (TODO UNTESTED)
Optionalparameters: Omit<GenericRequestParameters, "search">ReadonlygetReturns all teams: https://umami.is/docs/api/admin-api#get-apiadminteams
Optionalparameters: GenericRequestParametersReadonlygetGet a user belonging to a team: https://umami.is/docs/api/teams-api#get-apiteamsteamidusersuserid (TODO UNTESTED)
ReadonlygetGet all users that belong to a team: https://umami.is/docs/api/teams-api#get-apiteamsteamidusers (TODO UNTESTED)
ReadonlygetGet all websites that belong to a team: https://umami.is/docs/api/teams-api#get-apiteamsteamidwebsites (TODO UNTESTED)
ReadonlygetGets a user by ID: https://umami.is/docs/api/users-api#get-apiusersuserid
ReadonlygetReturns all users: https://umami.is/docs/api/admin-api#get-apiadminusers
Optionalparameters: GenericRequestParametersReadonlygetGets all teams that belong to a user: https://umami.is/docs/api/users-api#get-apiusersuseridteams
Optionalparameters: Omit<GenericRequestParameters, "search">ReadonlygetGets all websites that belong to a user: https://umami.is/docs/api/users-api#get-apiusersuseridwebsites
ReadonlygetGets a website by ID: https://umami.is/docs/api/websites-api#get-apiwebsiteswebsiteid (TODO UNTESTED)
ReadonlygetGets the number of active users on a website: https://umami.is/docs/api/website-stats-api#get-apiwebsiteswebsiteidactive (TODO UNTESTED)
ReadonlygetGets event-data for a individual event https://umami.is/docs/api/events-api#get-apiwebsiteswebsiteidevent-dataeventid (TODO UNTESTED)
ReadonlygetGets website event details within a given time range: https://umami.is/docs/api/events-api#get-apiwebsiteswebsiteidevents (TODO UNTESTED)
ReadonlygetGets event data names, properties, and counts: https://umami.is/docs/api/events-api#get-apiwebsiteswebsiteidevent-dataevents (TODO UNTESTED)
Optionalevent?: stringEvent name filter
ReadonlygetGets event data property and value counts within a given time range: https://umami.is/docs/api/events-api#get-apiwebsiteswebsiteidevent-datafields (TODO UNTESTED)
ReadonlygetGets event name and property counts for a website: https://umami.is/docs/api/events-api#get-apiwebsiteswebsiteidevent-dataproperties (TODO UNTESTED)
ReadonlygetGets aggregated website events, properties, and records within a given time range https://umami.is/docs/api/events-api#get-apiwebsiteswebsiteidevent-datastats (TODO UNTESTED)
ReadonlygetGets event data counts for a given event and property: https://umami.is/docs/api/events-api#get-apiwebsiteswebsiteidevent-datavalues (TODO UNTESTED)
Event name filter
Property name
ReadonlygetGets events within a given time range: https://umami.is/docs/api/website-stats-api#get-apiwebsiteswebsiteideventsseries (TODO UNTESTED)
Timezone (ex. America/Los_Angeles)
ReadonlygetGets metrics for a given time range: https://umami.is/docs/api/website-stats-api#get-apiwebsiteswebsiteidmetrics (TODO UNTESTED)
Optionallimit?: number(optional, default 500) Number of rows returned
Optionaloffset?: number(optional, default 0) Number of ows to skip
Timezone (ex. America/Los_Angeles)
Metrics type
ReadonlygetGets expanded metrics for a given time range: https://umami.is/docs/api/website-stats-api#get-apiwebsiteswebsiteidmetricsexpanded (TODO UNTESTED)
ReadonlygetGets pageviews within a given time range: https://umami.is/docs/api/website-stats-api#get-apiwebsiteswebsiteidpageviews (TODO UNTESTED)
Optionalcompare?: stringComparison value prev | yoy
Timezone (ex. America/Los_Angeles)
ReadonlygetReturns all user websites: https://umami.is/docs/api/websites-api#get-apiwebsites (TODO UNTESTED)
ReadonlygetReturns all websites: https://umami.is/docs/api/admin-api#get-apiadminwebsites
Optionalparameters: GenericRequestParametersReadonlygetGets session details for a individual session: https://umami.is/docs/api/sessions-api#get-apiwebsiteswebsiteidsessionssessionid (TODO UNTESTED)
ReadonlygetGets session activity for a individual session: https://umami.is/docs/api/sessions-api#get-apiwebsiteswebsiteidsessionssessionidactivity (TODO UNTESTED)
ReadonlygetGets session data counts by property name: https://umami.is/docs/api/sessions-api#get-apiwebsiteswebsiteidsession-dataproperties (TODO UNTESTED)
ReadonlygetGets session data counts for a given property: https://umami.is/docs/api/sessions-api#get-apiwebsiteswebsiteidsession-datavalues (TODO UNTESTED)
ReadonlygetGets session properties for a individual session: https://umami.is/docs/api/sessions-api#get-apiwebsiteswebsiteidsessionssessionidproperties (TODO UNTESTED)
ReadonlygetGets website session details within a given time range: https://umami.is/docs/api/sessions-api#get-apiwebsiteswebsiteidsessions (TODO UNTESTED)
ReadonlygetGets summarized website session statistics: https://umami.is/docs/api/sessions-api#get-apiwebsiteswebsiteidsessionsstats (TODO UNTESTED)
ReadonlygetGet collected count of sessions by hour of weekday: https://umami.is/docs/api/sessions-api#get-apiwebsiteswebsiteidsessionsweekly (TODO UNTESTED)
ReadonlygetGets summarized website statistics: https://umami.is/docs/api/website-stats-api#get-apiwebsiteswebsiteidstats (TODO UNTESTED)
Timezone (ex. America/Los_Angeles)
Will replace API.getWebsiteStats, which you should use for a reliable experience
ReadonlyjoinJoin a team: https://umami.is/docs/api/teams-api#post-apiteamsjoin (TODO UNTESTED)
ReadonlyremoveRemove a user from a team: https://umami.is/docs/api/teams-api#delete-apiteamsteamidusersuserid (TODO UNTESTED)
ReadonlyresetResets a website by removing all data related to the website: https://umami.is/docs/api/websites-api#post-apiwebsiteswebsiteidreset (TODO UNTESTED)
ReadonlyupdateUpdates a report: https://umami.is/docs/api/reports-api#post-apireportsreportid (TODO UNTESTED)
Optionaldescription?: stringDescription of report
Name of report
Optionalparameters?: anyParameters for report
ReadonlyupdateUpdate a team: https://umami.is/docs/api/teams-api#post-apiteamsteamid (TODO UNTESTED)
OptionalaccessCode?: stringThe team's access code
Optionalname?: stringThe team's name
ReadonlyupdateUpdate a user's role on a team: https://umami.is/docs/api/teams-api#post-apiteamsteamidusersuserid (TODO UNTESTED)
ReadonlyupdateUpdates a user: https://umami.is/docs/api/users-api#post-apiusersuserid
ReadonlyupdateUpdates a website: https://umami.is/docs/api/websites-api#post-apiwebsiteswebsiteid (TODO UNTESTED)
The full domain of the tracked website
The name of the website in Umami
OptionalshareId?: string | nullA unique string to enable a share url. Set null to unshare
The expiration date of your token
Used in practically all requests, those are all the headers the package uses excluding Authorization, the one with the token
The password of the account
In seconds, how long should it wait after a request failed before retrying? (defaults to 2)
How many retries maximum before throwing an APIError (defaults to 4)
Should it retry a request upon successfully setting a new token due to API.set_token_on_401 being true? (defaults to true)
Upon failing a request and receiving a response, because of which received status code should the request be retried? (defaults to [429])
Should it retry a request if that request failed because it has been aborted by the API.timeout? (defaults to false)
The base URL where requests should land, should include the /api portion if applicable
If true, upon failing a request due to a 401, it will call API.setNewToken (defaults to true)
If true, the application will silently call API.setNewToken when the API.token is set to expire, as determined by API.expires (defaults to false)
The AbortSignal used in every request
The key that allows you to talk with the API
Should always be "Bearer"
Information about the account that has been used to log in
The username of the account
Which events should be logged (defaults to none)
To be replaced by API.getWebsiteStats2, no deprecation warning as the new method is unreliable
The function that directly communicates with the API! Almost all functions of the API object uses this function!
The type of request, each endpoint uses a specific one (if it uses multiple, the intent and parameters become different)
What comes in the URL after api/, DO NOT USE TEMPLATE LITERALS (`) OR THE ADDITION OPERATOR (+), put everything separately for type safety
The things to specify in the request, such as the beatmap_id when looking for a beatmap
A Promise with the API's response
This contacts the server in order to get and set a new API.token!
Whether or not the token has changed (should be true as otherwise the server would complain and an APIError would be thrown to give you some details)
The API object requires a API.username and a API.password to successfully get any token
An API instance is needed to make requests to the server!