Updated README.MD with cURL instructions

This commit is contained in:
Dániel Szabó 2022-04-11 19:31:56 +01:00 committed by GitHub
parent 4ee064b834
commit a3915fed76
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -23,6 +23,24 @@ WantedBy=multi-user.target
Then start the service with `systemctl start microbin` and enable it on boot with `systemctl enable microbin`.
### Create Pasta with cURL
Simple text Pasta: `curl -d "expiration=10min&content=This is a test pasta" -X POST https://microbin.myserver.com/create`
Simple text Pasta: `curl -d "expiration=10min&content=$( < mypastafile.txt )" -X POST https://microbin.myserver.com/create`
Available expiration options:
- 1min
- 10min
- 1hour
- 24hour
- 1week
- never
Use cURL to read the pasta: `curl https://microbin.myserver.com/rawpasta/fish-pony-crow`
or to download the pasta: `curl https://microbin.myserver.com/rawpasta/fish-pony-crow > output.txt`
### Features
- No CSS or JS, super lightweight and simple
- Animal names instead of random numbers for pasta identifiers