Skip to content

Commit

Permalink
Update README
Browse files Browse the repository at this point in the history
  • Loading branch information
qewer33 committed Dec 4, 2022
1 parent 342d26f commit 0fd9979
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,16 @@
# Qewer's URL Shortener

A simple URL shortener built with Rust and Cloudflate Workers.
A simple URL shortener built with Rust and Cloudflate Workers. It has four routes:

`/`: Shows message
`/:key`: This is the main route for shortened URLs. It responds with a redirect HTML page if the key is in the KV, shows a 404 page otherwise
`/create/:secret`: Adds a new key-value combination to the KV (request body should have a "key" and a "url" field), needs secret as a parameter
`/delete/:secret`: Deletes a key-value combination from the KV by key (request body should have a "key" field), needs secret as a parameter

```bash
# condifgure the SECRET
wrangler secret put SECRET

# compiles project to WebAssembly
wrangler build

Expand Down

0 comments on commit 0fd9979

Please sign in to comment.