Skip to content

Latest commit

 

History

History
47 lines (29 loc) · 3.17 KB

README.md

File metadata and controls

47 lines (29 loc) · 3.17 KB

About Klele.si API

The API for klele.si is based on the PHP framework Laravel.

Setting up the API

We use Sail for development, but there's nothing stopping you from using a different development environment.

Setting your env

There's a couple of variables that you need to set before you get going.

FRONTEND_URL

You should set the url to your frontend application. This url is used when redirecting users after they have verified their email, or when they need to reset their password.

CORS_ALLOWED_ORIGINS

Either set the url of your frontend or * if you're developing locally. Make sure that this is explicitly set when used in production. This is only needed if the API is on a different domain (or subdomain).

SESSION_DOMAIN

Because we're using Sanctum to authenticate users, we need to setup a parent session domain name, otherwise we might have a problem with setting the API cookies needed to authenticate users. This is only needed if the API is on a different domain (or subdomain)

Running tests

If you're using Sail, just run sail test and you should be good to go.

Security Vulnerabilities

If you discover a security vulnerability within Klele.si, please send an e-mail to Miha Medven via miha@klele.si. All security vulnerabilities will be promptly addressed.

License

The Klele.si API is open-sourced software licensed under the MIT license.