diff options
author | Yigit Sever | 2021-04-15 03:50:34 +0300 |
---|---|---|
committer | Yigit Sever | 2021-04-15 03:50:34 +0300 |
commit | dcc2d99140d25c5f163e425fb6ed7246fe88ea54 (patch) | |
tree | 9108ff3aa44622ff0bda4bb82d9b1fb38f168dfe /site/content/_index.md | |
parent | be037a6b35056ec8aa8f75e56becd009bc7c01f2 (diff) | |
parent | 412276f8dac075836aaa8fdf636aa068718a2bbf (diff) | |
download | gradecoin-dcc2d99140d25c5f163e425fb6ed7246fe88ea54.tar.gz gradecoin-dcc2d99140d25c5f163e425fb6ed7246fe88ea54.tar.bz2 gradecoin-dcc2d99140d25c5f163e425fb6ed7246fe88ea54.zip |
Merge remote-tracking branch 'origin/template' into template
Diffstat (limited to 'site/content/_index.md')
-rw-r--r-- | site/content/_index.md | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/site/content/_index.md b/site/content/_index.md new file mode 100644 index 0000000..7dd7a7c --- /dev/null +++ b/site/content/_index.md | |||
@@ -0,0 +1,28 @@ | |||
1 | +++ | ||
2 | title = "Gradecoin" | ||
3 | sort_by = "weight" | ||
4 | +++ | ||
5 | |||
6 | - Don't know where to start? Gradecoin uses RESTful API, simple `curl` commands or even your browser will work! [This website can help as well](https://curl.trillworks.com/). | ||
7 | - [JWT Debugger](https://jwt.io) and the corresponding [RFC](https://tools.ietf.org/html/rfc7519) | ||
8 | |||
9 | # Services | ||
10 | ## /register | ||
11 | - Student creates their own 2048 bit RSA `keypair` | ||
12 | - Downloads `Gradecoin`'s Public Key from [Moodle](https://odtuclass.metu.edu.tr/my/) | ||
13 | - Encrypts their JSON wrapped `Public Key`, `Student ID` and one time `passwd` using Gradecoin's Public Key | ||
14 | - Their public key is now in our database and can be used to sign their JWT's during requests | ||
15 | |||
16 | ## /transaction | ||
17 | - You can offer a [Transaction](/transaction) - POST request | ||
18 | - The request should have `Authorization` | ||
19 | - The request header should be signed by the Public Key of the `by` field in the transaction | ||
20 | - fetch the list of `Transaction`s - GET request | ||
21 | |||
22 | ## /block | ||
23 | - offer a [`schema::Block`] - POST request | ||
24 | - The request should have `Authorization` | ||
25 | - The [`schema::Block::transaction_list`] of the block should be a subset of [`schema::Db::pending_transactions`] | ||
26 | - fetch the last accepted [`schema::Block`] - GET request | ||
27 | |||
28 | `Authorization`: The request header should have Bearer JWT.Token signed with Student Public Key | ||