openapi

package
v0.0.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 8, 2025 License: Apache-2.0 Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ApiStatus

type ApiStatus interface {
	Status() Status
}

type CtapiResponse

type CtapiResponse struct {
	StatusCode string `json:"statusCode,omitempty"`
	// Error code, which is a three part code for product.module.code
	Error string `json:"error,omitempty"`
	// Error description during failure, usually in English
	Message string `json:"message,omitempty"`
	// Error description during failure, usually in Chinese
	Description string `json:"description,omitempty"`
	// Data returned upon success
	ReturnObj interface{} `json:"returnObj"`
}

type OpenapiResponse

type OpenapiResponse struct {
	StatusCode int `json:"statusCode,omitempty"`
	// Error code, which is a three part code for product.module.code
	Error string `json:"error,omitempty"`
	// Error description during failure, usually in English
	Message string `json:"message,omitempty"`
	// Error description during failure, usually in Chinese
	Description string `json:"description,omitempty"`
	// Data returned upon success
	ReturnObj interface{} `json:"returnObj"`
}

type Status

type Status struct {
	Code    int32
	Reason  string
	Message string
	Details *StatusDetails
}

type StatusDetails

type StatusDetails struct {
	Name              string
	Cause             error
	RetryAfterSeconds int32
}

type StatusError

type StatusError struct {
	ErrStatus Status
}

func (*StatusError) Error

func (e *StatusError) Error() string

Error implements the Error interface.

func (*StatusError) Status

func (e *StatusError) Status() Status

Status allows access to e's status without having to know the detailed workings of StatusError.

func (*StatusError) Unwrap

func (e *StatusError) Unwrap() error

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL