Defines the structure of a response sent back to the client.
This module provides helper functions to create different types of responses, such as synchronous, asynchronous, and error responses.
Summary
Functions
Creates a response for an asynchronous request, indicating that the request has been received and is being processed.
Encodes a Response struct to a map, returning {:ok, map} or {:error, reason}.
Encodes a Response struct to a map using Nestru.
Encodes a Response struct to a map. Opts is not supported yet.
Checks if the response represents an error.
Creates a response for a failed request.
Creates a response to indicate the end of a stream.
Creates a response for a streaming request.
Creates a response for a successful synchronous request.
Types
Functions
Creates a response for an asynchronous request, indicating that the request has been received and is being processed.
Encodes a Response struct to a map, returning {:ok, map} or {:error, reason}.
Encodes a Response struct to a map using Nestru.
Encodes a Response struct to a map. Opts is not supported yet.
Checks if the response represents an error.
Creates a response for a failed request.
Creates a response to indicate the end of a stream.
Creates a response for a streaming request.
Creates a response for a successful synchronous request.