Draft REST API document
This document is use as a draft describing REST APIs for the project structure demo.There are only 2 features in the demo
- Login/logout
- CRUD user's profile
Technology stack
- ASP.NET core
- Entity framework
- JWT
- Docker
REST API Description
Feature | API | Description | Method | URL pattern | Return codes | |
Success | Failure | |||||
Authentication | login | Login using JWT | GET | api/v1/login | 200 | 401 |
logout | Logout(invalidate token) | POST | api/v1/logout | 200 | 500 | |
UPM |
create | Create a user with profile | POST | api/v1/upm/create | 200 | 401,500 |
getAll | Get all the user profiles | GET | api/v1/upm/get | 200 | 401,500 | |
get | Get a specific user profile | GET | api/v1/upm/get/{id} | 200 | 401,500 | |
update | Update a user profile | POST | api/v1/upm/update/{id} | 200 | 401,500 | |
delete | Delete a user profile | DELETE | api/v1/upm/delete/{id} | 200 | 401,500 |
You can also:
- Import and save files from GitHub, Dropbox, Google Drive and One Drive
- Drag and drop markdown and HTML files into Dillinger
- Export documents as Markdown, HTML and PDF
Markdown is a lightweight markup language based on the formatting conventions that people naturally use in email. As John Gruber writes on the Markdown site
The overriding design goal for Markdown's formatting syntax is to make it as readable as possible. The idea is that a Markdown-formatted document should be publishable as-is, as plain text, without looking like it's been marked up with tags or formatting instructions.
This text you see here is actually written in Markdown! To get a feel for Markdown's syntax, type some text into the left window and watch the results in the right.
Tech
Dillinger uses a number of open source projects to work properly:
- AngularJS - HTML enhanced for web apps!
- Ace Editor - awesome web-based text editor
- markdown-it - Markdown parser done right. Fast and easy to extend.
- Twitter Bootstrap - great UI boilerplate for modern web apps
- node.js - evented I/O for the backend
- Express - fast node.js network app framework @tjholowaychuk
- Gulp - the streaming build system
- Breakdance - HTML to Markdown converter
- jQuery - duh
And of course Dillinger itself is open source with a public repository on GitHub.
Plugins
Dillinger is currently extended with the following plugins. Instructions on how to use them in your own application are linked below.
Plugin | README |
---|---|
Dropbox | [plugins/dropbox/README.md] PlDb |
Github | [plugins/github/README.md] PlGh |
Google Drive | [plugins/googledrive/README.md] PlGd |
OneDrive | [plugins/onedrive/README.md] PlOd |
Medium | [plugins/medium/README.md] PlMe |
Google Analytics | [plugins/googleanalytics/README.md] PlGa |
Docker
Running the backend application
Installation
- Windows
- Ubuntu On Ubuntu/Other Linux, make sure you have docker-compose installed.
After installing Docker, clone the backend source code at: http://github.com/chuongdlb/aspnet-core-api
Step 1:
$ git clone http://github.com/chuongdlb/aspnet-core-api
$ cd aspnet-core-api
Step 2 (Build):
$ docker-compose build
Step 3 - Run the app:
$ docker-compose up -d
License
MIT
Free Software, Hell Yeah!