func NewUpdateCSPMPolicySettingsDefault(code int) *UpdateCSPMPolicySettingsDefault {
	return &UpdateCSPMPolicySettingsDefault{
		_statusCode: code,
	}
}
NewUpdateCSPMPolicySettingsDefault creates a UpdateCSPMPolicySettingsDefault with default headers values
package cspm_registration
import (
	"fmt"
	"io"
	"github.com/go-openapi/errors"
	"github.com/go-openapi/runtime"
	"github.com/go-openapi/strfmt"
	"github.com/go-openapi/swag"
	"github.com/crowdstrike/gofalcon/falcon/models"
)
type UpdateCSPMPolicySettingsReader struct {
	formats strfmt.Registry
}
func (o *UpdateCSPMPolicySettingsReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) {
	switch response.Code() {
	case 200:
		result := NewUpdateCSPMPolicySettingsOK()
		if err := result.readResponse(response, consumer, o.formats); err != nil {
			return nil, err
		}
		return result, nil
	case 207:
		result := NewUpdateCSPMPolicySettingsMultiStatus()
		if err := result.readResponse(response, consumer, o.formats); err != nil {
			return nil, err
		}
		return result, nil
	case 400:
		result := NewUpdateCSPMPolicySettingsBadRequest()
		if err := result.readResponse(response, consumer, o.formats); err != nil {
			return nil, err
		}
		return nil, result
	case 403:
		result := NewUpdateCSPMPolicySettingsForbidden()
		if err := result.readResponse(response, consumer, o.formats); err != nil {
			return nil, err
		}
		return nil, result
	case 429:
		result := NewUpdateCSPMPolicySettingsTooManyRequests()
		if err := result.readResponse(response, consumer, o.formats); err != nil {
			return nil, err
		}
		return nil, result
	case 500:
		result := NewUpdateCSPMPolicySettingsInternalServerError()
		if err := result.readResponse(response, consumer, o.formats); err != nil {
			return nil, err
		}
		return nil, result
	default:
		result := NewUpdateCSPMPolicySettingsDefault(response.Code())
		if err := result.readResponse(response, consumer, o.formats); err != nil {
			return nil, err
		}
		if response.Code()/100 == 2 {
			return result, nil
		}
		return nil, result
	}
}
func NewUpdateCSPMPolicySettingsOK() *UpdateCSPMPolicySettingsOK {
	return &UpdateCSPMPolicySettingsOK{}
}
type UpdateCSPMPolicySettingsOK struct {
	XRateLimitLimit int64
	XRateLimitRemaining int64
	Payload *models.RegistrationPolicySettingsResponseV1
}
func (o *UpdateCSPMPolicySettingsOK) Error() string {
	return fmt.Sprintf("[PATCH /settings/entities/policy/v1][%d] updateCSPMPolicySettingsOK  %+v", 200, o.Payload)
}
func (o *UpdateCSPMPolicySettingsOK) GetPayload() *models.RegistrationPolicySettingsResponseV1 {
	return o.Payload
}
func (o *UpdateCSPMPolicySettingsOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error {
	hdrXRateLimitLimit := response.GetHeader("X-RateLimit-Limit")
	if hdrXRateLimitLimit != "" {
		valxRateLimitLimit, err := swag.ConvertInt64(hdrXRateLimitLimit)
		if err != nil {
			return errors.InvalidType("X-RateLimit-Limit", "header", "int64", hdrXRateLimitLimit)
		}
		o.XRateLimitLimit = valxRateLimitLimit
	}
	hdrXRateLimitRemaining := response.GetHeader("X-RateLimit-Remaining")
	if hdrXRateLimitRemaining != "" {
		valxRateLimitRemaining, err := swag.ConvertInt64(hdrXRateLimitRemaining)
		if err != nil {
			return errors.InvalidType("X-RateLimit-Remaining", "header", "int64", hdrXRateLimitRemaining)
		}
		o.XRateLimitRemaining = valxRateLimitRemaining
	}
	o.Payload = new(models.RegistrationPolicySettingsResponseV1)
	if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF {
		return err
	}
	return nil
}
func NewUpdateCSPMPolicySettingsMultiStatus() *UpdateCSPMPolicySettingsMultiStatus {
	return &UpdateCSPMPolicySettingsMultiStatus{}
}
type UpdateCSPMPolicySettingsMultiStatus struct {
	XRateLimitLimit int64
	XRateLimitRemaining int64
	Payload *models.RegistrationPolicySettingsResponseV1
}
func (o *UpdateCSPMPolicySettingsMultiStatus) Error() string {
	return fmt.Sprintf("[PATCH /settings/entities/policy/v1][%d] updateCSPMPolicySettingsMultiStatus  %+v", 207, o.Payload)
}
func (o *UpdateCSPMPolicySettingsMultiStatus) GetPayload() *models.RegistrationPolicySettingsResponseV1 {
	return o.Payload
}
func (o *UpdateCSPMPolicySettingsMultiStatus) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error {
	hdrXRateLimitLimit := response.GetHeader("X-RateLimit-Limit")
	if hdrXRateLimitLimit != "" {
		valxRateLimitLimit, err := swag.ConvertInt64(hdrXRateLimitLimit)
		if err != nil {
			return errors.InvalidType("X-RateLimit-Limit", "header", "int64", hdrXRateLimitLimit)
		}
		o.XRateLimitLimit = valxRateLimitLimit
	}
	hdrXRateLimitRemaining := response.GetHeader("X-RateLimit-Remaining")
	if hdrXRateLimitRemaining != "" {
		valxRateLimitRemaining, err := swag.ConvertInt64(hdrXRateLimitRemaining)
		if err != nil {
			return errors.InvalidType("X-RateLimit-Remaining", "header", "int64", hdrXRateLimitRemaining)
		}
		o.XRateLimitRemaining = valxRateLimitRemaining
	}
	o.Payload = new(models.RegistrationPolicySettingsResponseV1)
	if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF {
		return err
	}
	return nil
}
func NewUpdateCSPMPolicySettingsBadRequest() *UpdateCSPMPolicySettingsBadRequest {
	return &UpdateCSPMPolicySettingsBadRequest{}
}
type UpdateCSPMPolicySettingsBadRequest struct {
	XRateLimitLimit int64
	XRateLimitRemaining int64
	Payload *models.RegistrationPolicySettingsResponseV1
}
func (o *UpdateCSPMPolicySettingsBadRequest) Error() string {
	return fmt.Sprintf("[PATCH /settings/entities/policy/v1][%d] updateCSPMPolicySettingsBadRequest  %+v", 400, o.Payload)
}
func (o *UpdateCSPMPolicySettingsBadRequest) GetPayload() *models.RegistrationPolicySettingsResponseV1 {
	return o.Payload
}
func (o *UpdateCSPMPolicySettingsBadRequest) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error {
	hdrXRateLimitLimit := response.GetHeader("X-RateLimit-Limit")
	if hdrXRateLimitLimit != "" {
		valxRateLimitLimit, err := swag.ConvertInt64(hdrXRateLimitLimit)
		if err != nil {
			return errors.InvalidType("X-RateLimit-Limit", "header", "int64", hdrXRateLimitLimit)
		}
		o.XRateLimitLimit = valxRateLimitLimit
	}
	hdrXRateLimitRemaining := response.GetHeader("X-RateLimit-Remaining")
	if hdrXRateLimitRemaining != "" {
		valxRateLimitRemaining, err := swag.ConvertInt64(hdrXRateLimitRemaining)
		if err != nil {
			return errors.InvalidType("X-RateLimit-Remaining", "header", "int64", hdrXRateLimitRemaining)
		}
		o.XRateLimitRemaining = valxRateLimitRemaining
	}
	o.Payload = new(models.RegistrationPolicySettingsResponseV1)
	if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF {
		return err
	}
	return nil
}
func NewUpdateCSPMPolicySettingsForbidden() *UpdateCSPMPolicySettingsForbidden {
	return &UpdateCSPMPolicySettingsForbidden{}
}
type UpdateCSPMPolicySettingsForbidden struct {
	XRateLimitLimit int64
	XRateLimitRemaining int64
	Payload *models.MsaReplyMetaOnly
}
func (o *UpdateCSPMPolicySettingsForbidden) Error() string {
	return fmt.Sprintf("[PATCH /settings/entities/policy/v1][%d] updateCSPMPolicySettingsForbidden  %+v", 403, o.Payload)
}
func (o *UpdateCSPMPolicySettingsForbidden) GetPayload() *models.MsaReplyMetaOnly {
	return o.Payload
}
func (o *UpdateCSPMPolicySettingsForbidden) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error {
	hdrXRateLimitLimit := response.GetHeader("X-RateLimit-Limit")
	if hdrXRateLimitLimit != "" {
		valxRateLimitLimit, err := swag.ConvertInt64(hdrXRateLimitLimit)
		if err != nil {
			return errors.InvalidType("X-RateLimit-Limit", "header", "int64", hdrXRateLimitLimit)
		}
		o.XRateLimitLimit = valxRateLimitLimit
	}
	hdrXRateLimitRemaining := response.GetHeader("X-RateLimit-Remaining")
	if hdrXRateLimitRemaining != "" {
		valxRateLimitRemaining, err := swag.ConvertInt64(hdrXRateLimitRemaining)
		if err != nil {
			return errors.InvalidType("X-RateLimit-Remaining", "header", "int64", hdrXRateLimitRemaining)
		}
		o.XRateLimitRemaining = valxRateLimitRemaining
	}
	o.Payload = new(models.MsaReplyMetaOnly)
	if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF {
		return err
	}
	return nil
}
func NewUpdateCSPMPolicySettingsTooManyRequests() *UpdateCSPMPolicySettingsTooManyRequests {
	return &UpdateCSPMPolicySettingsTooManyRequests{}
}
type UpdateCSPMPolicySettingsTooManyRequests struct {
	XRateLimitLimit int64
	XRateLimitRemaining int64
	XRateLimitRetryAfter int64
	Payload *models.MsaReplyMetaOnly
}
func (o *UpdateCSPMPolicySettingsTooManyRequests) Error() string {
	return fmt.Sprintf("[PATCH /settings/entities/policy/v1][%d] updateCSPMPolicySettingsTooManyRequests  %+v", 429, o.Payload)
}
func (o *UpdateCSPMPolicySettingsTooManyRequests) GetPayload() *models.MsaReplyMetaOnly {
	return o.Payload
}
func (o *UpdateCSPMPolicySettingsTooManyRequests) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error {
	hdrXRateLimitLimit := response.GetHeader("X-RateLimit-Limit")
	if hdrXRateLimitLimit != "" {
		valxRateLimitLimit, err := swag.ConvertInt64(hdrXRateLimitLimit)
		if err != nil {
			return errors.InvalidType("X-RateLimit-Limit", "header", "int64", hdrXRateLimitLimit)
		}
		o.XRateLimitLimit = valxRateLimitLimit
	}
	hdrXRateLimitRemaining := response.GetHeader("X-RateLimit-Remaining")
	if hdrXRateLimitRemaining != "" {
		valxRateLimitRemaining, err := swag.ConvertInt64(hdrXRateLimitRemaining)
		if err != nil {
			return errors.InvalidType("X-RateLimit-Remaining", "header", "int64", hdrXRateLimitRemaining)
		}
		o.XRateLimitRemaining = valxRateLimitRemaining
	}
	hdrXRateLimitRetryAfter := response.GetHeader("X-RateLimit-RetryAfter")
	if hdrXRateLimitRetryAfter != "" {
		valxRateLimitRetryAfter, err := swag.ConvertInt64(hdrXRateLimitRetryAfter)
		if err != nil {
			return errors.InvalidType("X-RateLimit-RetryAfter", "header", "int64", hdrXRateLimitRetryAfter)
		}
		o.XRateLimitRetryAfter = valxRateLimitRetryAfter
	}
	o.Payload = new(models.MsaReplyMetaOnly)
	if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF {
		return err
	}
	return nil
}
func NewUpdateCSPMPolicySettingsInternalServerError() *UpdateCSPMPolicySettingsInternalServerError {
	return &UpdateCSPMPolicySettingsInternalServerError{}
}
type UpdateCSPMPolicySettingsInternalServerError struct {
	XRateLimitLimit int64
	XRateLimitRemaining int64
	Payload *models.RegistrationPolicySettingsResponseV1
}
func (o *UpdateCSPMPolicySettingsInternalServerError) Error() string {
	return fmt.Sprintf("[PATCH /settings/entities/policy/v1][%d] updateCSPMPolicySettingsInternalServerError  %+v", 500, o.Payload)
}
func (o *UpdateCSPMPolicySettingsInternalServerError) GetPayload() *models.RegistrationPolicySettingsResponseV1 {
	return o.Payload
}
func (o *UpdateCSPMPolicySettingsInternalServerError) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error {
	hdrXRateLimitLimit := response.GetHeader("X-RateLimit-Limit")
	if hdrXRateLimitLimit != "" {
		valxRateLimitLimit, err := swag.ConvertInt64(hdrXRateLimitLimit)
		if err != nil {
			return errors.InvalidType("X-RateLimit-Limit", "header", "int64", hdrXRateLimitLimit)
		}
		o.XRateLimitLimit = valxRateLimitLimit
	}
	hdrXRateLimitRemaining := response.GetHeader("X-RateLimit-Remaining")
	if hdrXRateLimitRemaining != "" {
		valxRateLimitRemaining, err := swag.ConvertInt64(hdrXRateLimitRemaining)
		if err != nil {
			return errors.InvalidType("X-RateLimit-Remaining", "header", "int64", hdrXRateLimitRemaining)
		}
		o.XRateLimitRemaining = valxRateLimitRemaining
	}
	o.Payload = new(models.RegistrationPolicySettingsResponseV1)
	if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF {
		return err
	}
	return nil
}