api-analytics

(β˜… 654)

Effortless monitoring and analytics for API frameworks.

  • .gitignore
  • CONTRIBUTING.md
  • LICENSE
  • README.md

πŸš€ Installation Guide

1. Get the code
git clone https://github.com/tom-draper/api-analytics

Downloads the entire project code from GitHub to your computer.

cd api-analytics

Moves into the project folder you just downloaded.

2. Official Install Script

Easy Recommended
Prerequisites
  • Python 3 Python is required to use pip.
  • Ruby Ruby is required to use gem.
pip install api-analytics[fastapi]

Installs the package published on PyPI directly β€” no need to clone the source.

pip install api-analytics[flask]

Installs the package published on PyPI directly β€” no need to clone the source.

pip install api-analytics[django]

Installs the package published on PyPI directly β€” no need to clone the source.

gem install api_analytics

Installs the package published on RubyGems directly.

βœ… After installing, open a new terminal and run the program's version command (e.g. --version) to confirm it worked.

Pulled directly from this repo's README.

3. Docker

Easy
Prerequisites
  • Git Needed to download the project code from GitHub.
  • Docker Desktop Needed to build and run containers. Install it and keep it running in the background.
docker compose -f server/self-hosting/docker-compose.traefik-dev-example.yml up -d --build

Runs the command against the services defined in the compose file.

βœ… Run docker compose ps to check the containers are Up. If the README mentions a port, open http://localhost:PORT in your browser.

4. .NET

Medium
Prerequisites
  • Git Needed to download the project code from GitHub.
  • .NET SDK The SDK required for the dotnet command.
dotnet add package APIAnalytics.AspNetCore

Type this command into your terminal and run it.

βœ… After dotnet run, check the message or address shown in the terminal.

Pulled directly from this repo's README.

5. Node.js

Easy
Prerequisites
  • Git Needed to download the project code from GitHub.
  • Node.js Node.js must be installed to use npm. The LTS version is recommended.
npm install @api-analytics/express

Downloads and installs the libraries listed in package.json.

npm install @api-analytics/hono

Downloads and installs the libraries listed in package.json.

βœ… After running the command, open the address shown in the terminal (usually something like http://localhost:3000) in your browser.

Pulled directly from this repo's README.

6. Python

Easy
Prerequisites
  • Git Needed to download the project code from GitHub.
  • Python 3 On Windows, be sure to check 'Add Python to PATH' during installation.
pip install api-analytics[fastapi]

Installs the package published on PyPI directly β€” no need to clone the source.

pip install api-analytics[flask]

Installs the package published on PyPI directly β€” no need to clone the source.

pip install api-analytics[django]

Installs the package published on PyPI directly β€” no need to clone the source.

βœ… If it runs without errors and prints output in the terminal, it worked.

Pulled directly from this repo's README.

7. PHP (Composer)

Easy
Prerequisites
  • Git Needed to download the project code from GitHub.
  • PHP A PHP runtime is required.
  • Composer The package manager used to install PHP libraries.
composer require api-analytics/laravel

Type this command into your terminal and run it.

βœ… Run it with a built-in server like php -S localhost:8000, then open http://localhost:8000 in your browser.

Pulled directly from this repo's README.

8. Go

Medium
Prerequisites
  • Git Needed to download the project code from GitHub.
  • Go The Go compiler and toolchain.
cd analytics/go/chi/example

This project's files live in a subfolder, so move into it first.

go build ./...

Compiles the Go program into an executable.

go run .

Runs the Go program directly without a separate build step.

βœ… If the build finishes without errors, it worked. If you used go run ., check the terminal output.

9. Rust

Medium
Prerequisites
  • Git Needed to download the project code from GitHub.
  • Rust (rustup) Installing via rustup also installs cargo.
cargo add actix-analytics

Type this command into your terminal and run it.

cargo add axum-analytics

Type this command into your terminal and run it.

βœ… If cargo build finishes without errors, it worked. The executable is created under target/.

Pulled directly from this repo's README.

10. Ruby

Easy
Prerequisites
  • Git Needed to download the project code from GitHub.
  • Ruby Ruby is required to use the bundle command.
cd analytics/ruby/api_analytics

This project's files live in a subfolder, so move into it first.

bundle install

Installs the Ruby libraries listed in the Gemfile.

βœ… If bundle install finishes without errors, continue with the run command from the README (e.g. rails server).
// repository documentation