Added stats getter to api

This commit is contained in:
2021-08-18 15:23:41 +02:00
parent 008c5e1b5e
commit 0df9a52043

View File

@@ -4,6 +4,14 @@ const config = {
password: '9VEBc596T7tiPB7mNJukfeH9LfGzrrJN' password: '9VEBc596T7tiPB7mNJukfeH9LfGzrrJN'
}; };
export default class Apiclient { export default class Apiclient {
static async getStats() {
return (
await axios.get('https://kauft.es/api/stats', {
auth: config
})
).data;
}
static async getUrls() { static async getUrls() {
return ( return (
await axios.get('https://kauft.es/api?showVisits=true', { await axios.get('https://kauft.es/api?showVisits=true', {