Skip to content

Instantly share code, notes, and snippets.

@ashutoshkrris
Created July 11, 2026 06:40
Show Gist options
  • Select an option

  • Save ashutoshkrris/2f80f8d78fa0afa364271504e92cc8cb to your computer and use it in GitHub Desktop.

Select an option

Save ashutoshkrris/2f80f8d78fa0afa364271504e92cc8cb to your computer and use it in GitHub Desktop.
QUERY vs GET vs POST
Architectural Property GET POST QUERY
Request Body Allowed No (Undefined Semantics) Yes Yes
Safe (Read-Only) Yes Potentially No Yes
Idempotent (Safe to Retry) Yes Potentially No Yes
Default Cacheable Yes No (Only future GET/HEAD) Yes (Requires Body-Aware Keying)
Data Payload Location URL Query String Request Body Request Body
Primary Use Case Simple, short resource reads Resource creation & mutation Complex, large, or private reads
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment