Skip to content

Instantly share code, notes, and snippets.

@shollingsworth
Created April 14, 2022 21:23
Show Gist options
  • Save shollingsworth/6e329d02ff84086edaec3c6cce06dd70 to your computer and use it in GitHub Desktop.
Save shollingsworth/6e329d02ff84086edaec3c6cce06dd70 to your computer and use it in GitHub Desktop.
curl POST a json file to a http endpoint
#!/usr/bin/env bash
set -euo pipefail
IFS=$'\n\t'
curl -X POST \
-H 'Content-Type:application/json' \
-H "Accept:application/json" \
-d '@temp.json' \
http://localhost:5000/
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment