api-model

Version, currently main branch1 version
  • main branchlatestAug 13, 2023

github.com/lanjoni/api-model

A simple Crystal API Model using Kemal

8 stars
0 dependents
License: MIT

Installation

# Add this to your shard.yml
dependencies:
  api-model:
    github: lanjoni/api-model
    branch: main

main is a branch, not a release, so this tracks it rather than pinning a version.

Then run:

shards install

shard.yml

Crystal
1.9.1
License
MIT
Author
guto <joaoaugustolanjoni@gmail.com>
Target
  • crystal-rinha-backend from src/main.cr

Dependencies

Runtime Dependencies

  • pg*github: will/crystal-pg
  • kemal*github: kemalcr/kemal

README

# Crystal API Model

A simple API model to be used with [Crystal](https://crystal-lang.org), allowing direct integration with requests using [Kemal](https://kemalcr.com/) as the main framework for handling routes

## Installation

To perform the installation just clone the repository on your machine

```sh
git clone https://github.com/lanjoni/api-model.git && cd api-model
```

### Dependencies
- Crystal 
- PostgreSQL

## Usage

To run the application and install dependencies:

```sh
shards run
```
> Don't forget to set your PostgreSQL credentials in `src/pessoa.cr`

## Contributing

1. Fork it (<https://github.com/lanjoni/api-model/fork>)
2. Create your feature branch (`git checkout -b my-new-feature`)
3. Commit your changes (`git commit -am 'Add some feature'`)
4. Push to the branch (`git push origin my-new-feature`)
5. Create a new Pull Request

## Contributors

- [João Lanjoni](https://github.com/lanjoni) - creator and maintainer