Skip to content

mmagyar/declarapi

master
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
 
 
 
 
src
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

License: MIT Latest version published Build Code coverage

declarapi

Declarative API generation.

Create your CRUD API without writing a single line of code.

Features

  • Generate full CRUD REST API based on a single schema definitions
  • Automatically validate all requests
  • Automatically generate code to communicate with the database
    • Elasticsearch (basic usage, full text search is done, more advanced search in-progress)
    • Cloudflare Workers KV
    • Redis
  • Generate fetch functions and type definitions for the client
  • Permission based authentication / authorization support.

Example project

declarapi-example

Goals / TODO

  • Use user's credentials and authorize based on data field (such as userId, so a user can edit records created by them.)
  • Generate a describe method to let the client know the schema dynamically
  • Generate the source in a way that allows to create a summary file, so in case of multiple api methods / endpoints, the user only needs to import a single file.
  • Generate automatic functional tests for the APIs
  • Generate automatic load / performance tests for the APIs
  • Add pagination to get requests
  • Other TODO.