Expand description
API Request module
Transforms raw HTTP requests into domain-specific ApiRequest objects.
This is the bridge between HTTP and domain logic, mirroring the
Haskell ApiRequest module for full API compatibility.
§Architecture
HTTP Request
├─ URL path → Resource + Action
├─ Query → QueryParams (select, filter, order, logic)
├─ Headers → Preferences, Range, Schema, MediaType
└─ Body → Payload
↓
ApiRequest structRe-exports§
pub use preferences::Preferences;pub use query_params::QueryParams;pub use range::Range;pub use types::Action;pub use types::AggregateFunction;pub use types::DbAction;pub use types::EmbedPath;pub use types::Filter;pub use types::InvokeMethod;pub use types::JoinType;pub use types::LogicTree;pub use types::Mutation;pub use types::OpExpr;pub use types::Operation;pub use types::OrderTerm;pub use types::Payload;pub use types::Resource;pub use types::SelectItem;
Modules§
- payload
- Request body (payload) parsing
- preferences
- HTTP Prefer header parsing
- query_
params - Query parameter parsing
- range
- Range parsing for limit/offset and HTTP Range header
- types
- Core types for the API request module
Structs§
- ApiRequest
- The core API request struct.
Functions§
- from_
request - Build an
ApiRequestfrom HTTP request parts.