Files
Gumble-Backend/api/definitions/errors.yml
Zane Walker 7e940c83a7
Some checks failed
Build & Test / build-test (push) Has been cancelled
Build & Test / swagger-codegen-cli (push) Has been cancelled
CodeQL / Analyze (go) (push) Has been cancelled
(Feat): Initial Commit
2026-07-03 19:41:31 +05:30

80 lines
2.0 KiB
YAML

swagger: "2.0"
info:
title: allaboutapps.dev/aw/go-starter
version: 0.1.0
paths: {}
definitions:
PublicHTTPErrorType:
type: string
description: Type of error returned, should be used for client-side error handling
enum:
- generic
# push
- PUSH_TOKEN_ALREADY_EXISTS
- OLD_PUSH_TOKEN_NOT_FOUND
# files
- ZERO_FILE_SIZE
# auth
- USER_DEACTIVATED
- INVALID_PASSWORD
- NOT_LOCAL_USER
- TOKEN_NOT_FOUND
- TOKEN_EXPIRED
- USER_ALREADY_EXISTS
- MALFORMED_TOKEN
- LAST_AUTHENTICATED_AT_EXCEEDED
- MISSING_SCOPES
PublicHTTPError:
type: object
required:
- status
- type
- title
properties:
detail:
description: "More detailed, human-readable, optional explanation of the error"
type: string
example: User is lacking permission to access this resource
status:
description: HTTP status code returned for the error
type: integer
format: int64
maximum: 599
minimum: 100
x-go-name: Code
example: 403
title:
description: "Short, human-readable description of the error"
type: string
example: Forbidden
type:
$ref: "#/definitions/PublicHTTPErrorType"
PublicHTTPValidationError:
allOf:
- $ref: "#/definitions/PublicHTTPError"
type: object
required:
- validationErrors
properties:
validationErrors:
description: List of errors received while validating payload against schema
type: array
items:
$ref: "#/definitions/HTTPValidationErrorDetail"
HTTPValidationErrorDetail:
type: object
required:
- key
- in
- error
properties:
error:
description: Error describing field validation failure
type: string
in:
description: Indicates how the invalid field was provided
type: string
key:
description: Key of field failing validation
type: string