Annotation based JSON API framework with built in param conversion

https://github.com/Blacksmoke16/athena

Annotation based JSON API web framework with built in param conversion inspired by Symfony Routing. Also supports form data and ECR rendering.

Goals

  • Extensible and customizable to fit all use cases
  • Make working with JSON APIs in Crystal much easier
  • Be easy to adopt and start using effectively
  • Remove unneeded boilerplate code to convert route/body params to correct type
  • Easy serialization via CrSerializer

Load .env files in crystal

https://github.com/drum445/dotenv

Loads .env file in Crystal and optionally loads them directly into your ENV var: https://crystal-lang.org/api/0.27.0/ENV.html Will always return the .env file as a hash regardless of whether you chose to load into your ENV or not.

Example of .env file:

ENV=dev
PORT=3000
LOGGING=true
CORS=*

DB_DRIVER=mysql
DB_USERNAME=root
DB_PASSWORD=password
DB_HOST=localhost
DB_PORT=3306
DB_DATABASE=test
require "dotenv"

Dotenv.load # => {"ENV" => "dev", "PORT" => "3000", "LOGGING" => "true", "CORS" => "*", "DB_DRIVER" => "mysql", "DB_USERNAME" => "root", "DB_PASSWORD" => "password", "DB_HOST" => "localhost", "DB_PORT" => "3306", "DB_DATABASE" => "test"}

Extensible annotation based serialization/deserialization/validation library

https://github.com/blacksmoke16/CrSerializer

JSON (and later YAML) serializer and validator inspired by JMS Serializer Annotations and Symfony Validation Constraint Annotations.

Goals

  • Be a compliment to, not a replacement for, JSON::Serializable or YAML::Serializable
  • Extensible and customizable to fit all use cases
  • Make working with JSON APIs in Crystal much easier
  • Be easy to adopt and start using effectively
  • Work out of the box with most ORMs (assuming they are compatible with JSON::Serializable/annotations)