// Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.

package sdkerrors

import (
	"encoding/json"
	"github.com/censys/censys-sdk-go/models/components"
)

type ErrorModel struct {
	// A human-readable explanation specific to this occurrence of the problem.
	Detail *string `json:"detail,omitempty"`
	// Optional list of individual error details
	Errors []components.ErrorDetail `json:"errors,omitempty"`
	// A URI reference that identifies the specific occurrence of the problem.
	Instance *string `json:"instance,omitempty"`
	// HTTP status code
	Status *int64 `json:"status,omitempty"`
	// A short, human-readable summary of the problem type. This value should not change between occurrences of the error.
	Title *string `json:"title,omitempty"`
	// A URI reference to human-readable documentation for the error.
	Type *string `default:"about:blank" json:"type"`
}

var _ error = &ErrorModel{}

func (e *ErrorModel) Error() string {
	data, _ := json.Marshal(e)
	return string(data)
}
