03-post-delete

command
v0.0.0-...-228c668 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 18, 2021 License: MIT Imports: 5 Imported by: 0

README

Using Curl

  1. Start your server

  2. Enter this at the terminal

curl http://localhost:8080/user/1
curl -X POST -H "Content-Type: application/json" -d '{"Name":"James Bond","Gender":"male","Age":32,"Id":"777"}' http://localhost:8080/user

-X is short for --request Specifies a custom request method to use when communicating with the HTTP server.

-H is short for --header

-d is short for --data

curl -X DELETE -H "Content-Type: application/json" http://localhost:8080/user/777

IMPORTANT: Make sure you update your import statements to import packages from the correct location!

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL