Documentation ¶
Overview ¶
Package handlers contains the http handlers which receive requests to be processed by the API.
Index ¶
- Constants
- func HandleCreateExternalPaymentJourney(w http.ResponseWriter, req *http.Request)
- func HandleCreatePaymentSession(w http.ResponseWriter, req *http.Request)
- func HandleGetPaymentDetails(w http.ResponseWriter, req *http.Request)
- func HandleGetPaymentSession(w http.ResponseWriter, req *http.Request)
- func HandleGovPayCallback(w http.ResponseWriter, req *http.Request)
- func HandlePatchPaymentSession(w http.ResponseWriter, req *http.Request)
- func Register(mainRouter *mux.Router, cfg config.Config)
Constants ¶
const ProducerSchemaName = "payment-processed"
ProducerSchemaName is the schema which will be used to send the payment processed kafka message with
const ProducerTopic = "payment-processed"
ProducerTopic is the topic to which the payment processed kafka message is sent
Variables ¶
This section is empty.
Functions ¶
func HandleCreateExternalPaymentJourney ¶
func HandleCreateExternalPaymentJourney(w http.ResponseWriter, req *http.Request)
HandleCreateExternalPaymentJourney creates an external payment session with a Payment Provider that is given, e.g. GOV.UK Pay
func HandleCreatePaymentSession ¶
func HandleCreatePaymentSession(w http.ResponseWriter, req *http.Request)
HandleCreatePaymentSession creates a payment session and returns a journey URL for the calling app to redirect to
func HandleGetPaymentDetails ¶
func HandleGetPaymentDetails(w http.ResponseWriter, req *http.Request)
HandleGetPaymentDetails retrieves the payment details from the external provider
func HandleGetPaymentSession ¶
func HandleGetPaymentSession(w http.ResponseWriter, req *http.Request)
HandleGetPaymentSession retrieves the payment session from request context
func HandleGovPayCallback ¶
func HandleGovPayCallback(w http.ResponseWriter, req *http.Request)
HandleGovPayCallback handles the callback from Govpay and redirects the user
func HandlePatchPaymentSession ¶
func HandlePatchPaymentSession(w http.ResponseWriter, req *http.Request)
HandlePatchPaymentSession patches and updates the payment session
Types ¶
This section is empty.