Created
January 15, 2013 21:34
-
-
Save madis/4542301 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
```bash | |
# Make a POST request with post parameter | |
# -i for showing headers | |
# -d for passing post parameters | |
curl -i -d "site_key=almost_random" -X POST http://localhost:3001/api/visits | |
# Save a cookie in a file | |
curl -c visits_cookie.txt -d "site_key=almost_random" -X POST http://localhost:3001/api/visits | |
# Make a POST request with cookie | |
# -b for passing the cookie | |
curl -b visits_cookie.txt -d "site_key=almost_random" -X POST http://localhost:3001/api/visits | |
# Check a redis key from command line | |
redis-cli get visit_session:2d2066db-78f3-43f4-b38c-47ce258751bc | |
# Deletes redis key | |
redis-cli get visit_session:2d2066db-78f3-43f4-b38c-47ce258751bc | |
``` |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment