https://github.com/samsung/restful
Suggesting standard and optimized codes for RESTful API including filter/annotator for allowing user access and validating input data, user management, data management and some utils such as protecting data using 128/256-bit AES encryption.
https://github.com/samsung/restful
Last synced: 11 months ago
JSON representation
Suggesting standard and optimized codes for RESTful API including filter/annotator for allowing user access and validating input data, user management, data management and some utils such as protecting data using 128/256-bit AES encryption.
- Host: GitHub
- URL: https://github.com/samsung/restful
- Owner: Samsung
- License: other
- Created: 2014-10-15T05:30:10.000Z (almost 12 years ago)
- Default Branch: master
- Last Pushed: 2023-04-07T10:42:48.000Z (over 3 years ago)
- Last Synced: 2025-04-11T18:24:46.905Z (over 1 year ago)
- Language: Java
- Homepage:
- Size: 4.01 MB
- Stars: 61
- Watchers: 18
- Forks: 40
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
RESTful
=======
Suggesting the codes for RESTful API including filter/annotator for allowing user access and validating input data, user management, data management and some utils such as protecting data using 128/256-bit AES encryption and so on.
Please take a look at [readme](/doc/readme) to see release note.
### Guide ###
The followings are quick guides:
[A. Preparing development environment](/doc/Quick_Guide_1.docx)
[B. Quick guide how to run RESTful using this project](/doc/Quick_Guide_2.docx)
C. Customizing for your project (in progress)
### Usage ###
#### html ####
##### User #####
- [x] [/restful/user/signup.html](/src/main/webapp/user/signup.html "Creating new user")
- [x] [/restful/user/signin.html](/src/main/webapp/user/signin.html "Signing in")
- [x] [/restful/user/profile.html](/src/main/webapp/user/profile.html "Retrieving my information")
- [x] [/restful/user/setting.html](/src/main/webapp/user/setting.html "Updating/Deleting user information")
- [x] [/restful/user/list.html](/src/main/webapp/user/list.html "Retrieving user list") (_admin only_)
##### Note #####
- [x] [/restful/note/create.html](/src/main/webapp/note/create.html "Creating new note")
- [x] [/restful/note/update.html](/src/main/webapp/note/update.html "Updating note")
- [x] [/restful/note/content.html](/src/main/webapp/note/content.html "Retrieving note content")
- [x] [/restful/note/list.html](/src/main/webapp/note/list.html "Retrieving note list")
#### Restful ####
##### User #####
```json
// Creating a user
POST /restful/api/user/signup
Content-Type: application/json
{
"name": "axpower",
"pwd": "*****",
"username": "RESTful",
"role": "User"
}
// Signing in
POST /restful/api/user/signin
Content-Type: application/json
{
"name": "axpower",
"pwd": "*****"
}
// Signing out
GET /restful/api/user/signout
Content-Type: application/json
// Retrieving my information
GET /restful/api/user/profile
Content-Type: application/json
// Updating a user
PUT /restful/api/user
Content-Type: application/json
{
"name": "axpower",
"username": "Web service"
}
// Deleting a user
DELETE /restful/api/user
Content-Type: application/json
{
"name": "axpower"
}
// Retrieving a user (admin only)
GET /restful/api/user/ax
Content-Type: application/json
// Retrieving a list of user with paging and search query (admin only)
GET /restful/api/user/list
GET /restful/api/user/list?pn=1
GET /restful/api/user/list?pn=1&q=ax
Content-Type: application/json
```
##### Note #####
```json
// Creating a note
POST /restful/api/note
Content-Type: application/json
{
"subject": "Hello",
"content": "Nice to meet you!"
}
// Updating a note
PUT /restful/api/note
Content-Type: application/json
{
"idx": 1,
"subject": "Hello",
"content": "It's really nice to meet you."
}
// Deleting a note
DELETE /restful/api/note
Content-Type: application/json
{
"idx": 1
}
// Retrieving a note
GET /restful/api/note/1
Content-Type: application/json
// Retrieving a list of note with paging and search query
GET /restful/api/note/list
GET /restful/api/note/list?pn=1
GET /restful/api/note/list?pn=1&q=hello
Content-Type: application/json
```