Skip to content

luka-lta/luka-lta-api

Repository files navigation

luka-lta-api

Contributors Forks Stargazers Issues License LinkedIn


Logo

luka-lta-api

Backend API for managing links and clicks in my system.
Explore the docs »

View Demo · Report Bug · Request Feature


About The Project

This backend API is built with PHP and the Slim framework. It manages link collections, tracks click events, and supports API key authentication for secure access.

Built With

Getting Started

Prerequisites

Ensure you have the following installed:

  • PHP 8.3 or higher
  • Docker
  • PHP Redis extension 8.3 or higher

Installation

  1. Clone the repository:

    git clone https://github.com/luka-lta/luka-lta-api.git
    cd luka-lta-api
  2. Install dependencies using Composer:

    composer install
  3. Start the application using Docker:

    docker-compose up -d
  4. Run database migrations:

    php artisan migrate

Testing the API

Use tools like Postman or cURL to test the endpoints.


API Endpoints

Authentication

  • POST /auth – Authenticate user and retrieve an access token

API Keys

  • POST /key/create – Generate a new API key (requires authentication)

Link Collection

  • GET /linkCollection/links – Get all available links (requires authentication)
  • POST /linkCollection/create – Create a new link (requires authentication)
  • PUT /linkCollection/{linkId} – Edit an existing link (requires authentication)
  • DELETE /linkCollection/{linkId} – Disable an existing link (requires authentication)

Click Tracking

  • GET /click/track – Track a click event
  • GET /click/all – Get all click events (requires authentication)

User Management

  • POST /user/create – Create a new user
  • POST /user/{userId} – Update an existing user (requires authentication)

Roadmap

See the open issues for a list of proposed features and known issues.


Contributing

Contributions are what make the open-source community amazing! Any contributions you make are greatly appreciated.

  1. Fork the project
  2. Create your feature branch (git checkout -b feature/AmazingFeature)
  3. Commit your changes (git commit -m 'Add some AmazingFeature')
  4. Push to the branch (git push origin feature/AmazingFeature)
  5. Open a pull request

Top Contributors

Contributors

License

Distributed under the MIT License. See LICENSE.txt for more information.


Contact

luka-ltainfo@luka-lta.dev

Project Link: https://github.com/luka-lta/luka-lta-api


Acknowledgments