API requests are the fuel for the digital economy, reading and writing data, content, and media online across every business sector. HTTP API requests have become the common building block of web, mobile, and device applications, and understanding the technical details of individual API requests are essential to how you conduct business online today.
It can be very helpful to pause, step back, and think about the parts of each individual API request. We produce and consume so many API requests as part of our regular operations that we do not always have the time to stop and think about the details of each request and why they matter. If we are simply consuming an API we do not have as much control over what these details are, but if we are producing APIs it helps to put on our API consumer hat and think about why these parts and pieces matter. Postman collections provide us with useful ways for breaking down each request we are making, contemplating which methods we use, how we apply parameters, headers, and bodies, and then also secure these resources and capabilities with authentication. Good API producers are also API consumers, feeling the pain of design constraints, working within the request vocabulary given, and spending regular time studying and thinking about the anatomy of API requests will make you more effective in your work.
- URL - A Uniform Resource Locator (URL), colloquially termed a web address is a reference to a web resource that specifies its location on a computer network and a mechanism for retrieving it, providing the base for each API request to digital resources and capabilities.
- Path Parameters - The variables applied to the URL path, allowed segments of the request to be abstracted away as part of an environment or other automation, shaping each individual request being made.
- Query Parameters - The parameters available after an API path separated by a question mark, providing one or many individual key / value pairs that can be used to shape and define each API request being made, providing many different ways an API consumer can access data, content, media, and other digital resources or capabilities via a simple web API, leverage web technology to deliver useful APIs.
- Headers - Key / Value pairs of data that can be passed back and forth as part of API requests, confirming to the HTTP standard, and relying on the IANA registry of headers to define and shape the routing and prioritization of requests being made to APIs when using HTTP as the transport protocol between client and server.
- Body - Enabling the ability to add JSON, XML, Text, and other types of data payloads as a body of the request, securely sending data (when encrypted) as part of a request.
- Pre-Request Script - A script that runs before a request is made, providing the automation of business logic before each individual request is initiated, setting the stage for each individual request. null