Skip to content

Commit

Permalink
docs(readme): use form data post
Browse files Browse the repository at this point in the history
Signed-off-by: John Andersen <johnandersen777@protonmail.com>
  • Loading branch information
johnandersen777 committed Dec 3, 2024
1 parent 39879f4 commit 779e7a7
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ GitHub: https://github.com/publicdomainrelay/atprotobin
Paste

```bash
curl -X POST --data-binary @README.md -H "Content-Type: text/plain" https://paste.chadig.com
curl -X POST -F file=@README.md https://paste.chadig.com
```

Retrive using id from paste reponse JSON (`| jq -r .id`)
Expand All @@ -17,13 +17,13 @@ curl -sf https://paste.chadig.com/$id
Paste and retrive

```bash
curl -sf https://paste.chadig.com/$(curl -X POST --data-binary @README.md -H "Content-Type: text/plain" https://paste.chadig.com | tee /dev/stderr | jq -r .id)
curl -sf https://paste.chadig.com/$(curl -X POST -F file=@README.md https://paste.chadig.com | tee /dev/stderr | jq -r .id)
```

Paste and retrive (development)

```bash
curl -sf http://localhost:8000/$(curl -X POST --data-binary @src/atprotobin/cli.py -H "Content-Type: text/plain" http://localhost:8000/ | tee /dev/stderr | jq -r .id)
curl -sf http://localhost:8000/$(curl -X POST -F file=@src/atprotobin/cli.py http://localhost:8000/ | tee /dev/stderr | jq -r .id)
```

Start server
Expand Down

0 comments on commit 779e7a7

Please sign in to comment.