EndPointBlank.VersionFinder (end_point_blank_elixir v0.3.1)

Copy Markdown

Detects the API version for an incoming request.

Priority order (same as the Ruby, JS, and Java libraries):

  1. Custom config.version_finder function
  2. Accept header (vendor MIME type)
  3. X-Api-Version header
  4. Content-Type header (vendor MIME type)
  5. version query parameter
  6. Path segment (e.g. /v1/)

Summary

Functions

Returns the version string for the request, or nil if not detected.

Functions

find(conn)

Returns the version string for the request, or nil if not detected.