Serie: Go
go
8 righe
· Aggiornato 2026-04-18
errors.go
Go/payment-gateway-challenge/internal/handlers/errors.go
package handlers
// ErrorJSON is the standard JSON envelope for non-2xx API errors documented in Swagger.
type ErrorJSON struct {
Message string `json:"message" example:"failed to reach acquiring bank"`
Detail string `json:"detail,omitempty" example:"upstream body"`
Status int `json:"status,omitempty" example:"502"`
}
Articoli correlati
Go
go
Aggiornato 2026-04-18
main.go
main.go — go source code from the Go learning materials (Go/Baasid/cmd/hashpw/main.go).
Leggi l'articolo →
Go
go
Aggiornato 2026-04-18
main.go
main.go — go source code from the Go learning materials (Go/Baasid/cmd/server/main.go).
Leggi l'articolo →
Go
go
Aggiornato 2026-04-18
docs.go
docs.go — go source code from the Go learning materials (Go/Baasid/docs/docs.go).
Leggi l'articolo →
Go
go
Aggiornato 2026-04-18
jwt.go
jwt.go — go source code from the Go learning materials (Go/Baasid/internal/auth/jwt.go).
Leggi l'articolo →
Go
go
Aggiornato 2026-04-18
password.go
password.go — go source code from the Go learning materials (Go/Baasid/internal/auth/password.go).
Leggi l'articolo →
Go
go
Aggiornato 2026-04-18
password_test.go
password_test.go — go source code from the Go learning materials (Go/Baasid/internal/auth/password_test.go).
Leggi l'articolo →