API Guidelines
  • adidas API Guidelines
  • General Guidelines
    • Introduction
    • API First
    • Contract
    • Immutability
    • Robustness
    • Common Data Types
    • Version Control System
    • Minimal API Surface
    • Rules for Extending
    • JSON
    • Security
    • Tooling
  • REST API Guidelines
    • Introduction
    • Core REST Principles
      • OpenAPI Specification
      • API Design Platform
      • Design Maturity
      • Testing
    • Protocol
      • HTTP
      • TLS
      • Separate Concerns
      • Request Methods
      • Status Codes
    • Message
      • Message Formats
      • Content Negotiation
      • HAL
      • Problem Detail
      • Foreign Key Relations
    • Application
      • Corporate Data Model
      • Common Data Types
    • Execution
      • Pagination
      • Long Running Tasks
        • Polling
        • Callback
        • Files Upload
      • Batch Operations
      • Search Requests
      • Query Requests with Large Inputs
      • Choosing Fields and Embedded Resources
      • Localization
      • Rate Limiting
      • Caching
      • Testing Enviroments
    • Evolution
      • Naming Conventions
      • Reserved Identifiers
      • URI Structure
      • Changes and Versioning
      • Phasing out Old Versions
    • Guides
      • API Testing CI Environment
      • Complete API Development
    • API Clients
      • Loose Coupling
    • Further References
  • Asynchronous API Guidelines
    • Introduction
    • Core Asynchronous Principles
      • Event Driven Architectures
      • Messages
        • Commands
        • Queries
        • Events
          • Events as Notifications
          • Events to Replicate Data
      • Protocols
      • Coupling
      • Bounded Context
      • Stream Processing
      • Naming Conventions
      • Tooling
        • Editors
        • Command Line Interface (CLI)
        • Generators
    • Kafka Asynchronous Guidelines
      • Introduction
        • Why AsyncAPI?
      • AsyncAPI Version
      • Internal vs Public Specifications
      • Key/Value Format
      • Message Headers
      • Specification Granularity
      • Self-Contained Specifications
        • Meaningful Descriptions
      • Schema Data Evolution
        • Backward Compatibility
        • Forward Compatibility
        • Full Compatibility
      • Automatic Schema Registration
      • Contact Information
      • AsyncAPI ID
      • Servers
      • Channels
      • Schemas
      • Security Schemes
      • External Docs
Powered by GitBook
On this page
  • HTTP Protocol Quick Start
  • Know HTTP
  • RFCs
  1. REST API Guidelines
  2. Protocol

HTTP

Every API MUST support HTTP/1.1 and MUST adhere to its semantic.

HTTP Protocol Quick Start

The understanding of HTTP starts with the understanding of HTTP message and its routing.

Once you are familiar with the HTTP message structure learn about the HTTP request methods, HTTP response status codes and HTTP headers.

Each HTTP request method, status code, and header have its semantics defined, and every API MUST strictly adhere to it.

Follow the Robustness Principle. Use only the HTTP request methods, response codes and HTTP headers you understand, be liberal in accepting others.

Know HTTP

The following documents are great overview of the HTTP protocol and related standards:

  • HTTP Headers

  • HTTP Request Methods

  • HTTP Response Status Codes

  • HTTP Link Relations

Alternatively, you can download HTTP cheat sheets at HTTP posters.

RFCs

The HTTP protocol semantics is defined in the following RFCs:

  1. RFC 7230, HTTP/1.1: Message Syntax and Routing

  2. RFC 7231, HTTP/1.1: Semantics and Content

  3. RFC 7232, HTTP/1.1: Conditional Requests

  4. RFC 7233, HTTP/1.1: Range Requests

  5. RFC 7234, HTTP/1.1: Caching

  6. RFC 7235, HTTP/1.1: Authentication

PreviousProtocolNextTLS

Last updated 6 years ago