Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/helloimalemur/rocket-simple-api-example
An api example written in Rust, using the Rocket framework.
https://github.com/helloimalemur/rocket-simple-api-example
Last synced: 5 days ago
JSON representation
An api example written in Rust, using the Rocket framework.
- Host: GitHub
- URL: https://github.com/helloimalemur/rocket-simple-api-example
- Owner: helloimalemur
- Created: 2023-10-12T01:47:27.000Z (about 1 year ago)
- Default Branch: master
- Last Pushed: 2024-04-07T02:38:18.000Z (7 months ago)
- Last Synced: 2024-04-07T03:26:01.011Z (7 months ago)
- Language: Rust
- Homepage:
- Size: 67.4 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
## Edit config/Settings.toml
```toml
api_key = "yourapikey"
```## test and dev functions;
```shell
# postdata;
curl -XPOST -H 'x-api-key:yourapikey' -H 'Content-Type:application/json' http://127.0.0.1:8030/api/login -d '{"username": "foxx","password": "doxx","ipaddress": "0.0.0.0"}'
```
```shell
# get data
curl -XGET -H 'x-api-key:yourapikey' http://127.0.0.1:8030/api/
```