Added stats getter to api

This commit is contained in:
Nicolai Ort 2021-08-18 15:23:41 +02:00
parent 008c5e1b5e
commit 0df9a52043
Signed by: niggl
GPG Key ID: 13AFA55AF62F269F
1 changed files with 8 additions and 0 deletions

View File

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