Error represents the error content.
| 99 | |
| 100 | // Error represents the error content. |
| 101 | type Error struct { |
| 102 | // The error type that occurred. |
| 103 | Code int `json:"code"` |
| 104 | // A short description of the error. The message SHOULD be limited |
| 105 | // to a concise single sentence. |
| 106 | Message string `json:"message"` |
| 107 | // Additional information about the error. The value of this member |
| 108 | // is defined by the sender (e.g. detailed error information, nested errors etc.). |
| 109 | Data interface{} `json:"data,omitempty"` |
| 110 | } |
| 111 | |
| 112 | // String returns the error type as a string based on the error code. |
| 113 | func (e Error) String() string { |
nothing calls this directly
no outgoing calls
no test coverage detected