func (m *PrivateCreateSubaccountResponseAO1Result) Validate(formats strfmt.Registry) error {
	var res []error
	if err := m.validateEmail(formats); err != nil {
		res = append(res, err)
	}
	if err := m.validateID(formats); err != nil {
		res = append(res, err)
	}
	if err := m.validateIsPassword(formats); err != nil {
		res = append(res, err)
	}
	if err := m.validateLoginEnabled(formats); err != nil {
		res = append(res, err)
	}
	if err := m.validatePortfolio(formats); err != nil {
		res = append(res, err)
	}
	if err := m.validateReceiveNotifications(formats); err != nil {
		res = append(res, err)
	}
	if err := m.validateSystemName(formats); err != nil {
		res = append(res, err)
	}
	if err := m.validateTfaEnabled(formats); err != nil {
		res = append(res, err)
	}
	if err := m.validateType(formats); err != nil {
		res = append(res, err)
	}
	if err := m.validateUsername(formats); err != nil {
		res = append(res, err)
	}
	if len(res) > 0 {
		return errors.CompositeValidationError(res...)
	}
	return nil
}
Validate validates this private create subaccount response a o1 result
package models
import (
	"encoding/json"
	strfmt "github.com/go-openapi/strfmt"
	"github.com/go-openapi/errors"
	"github.com/go-openapi/swag"
	"github.com/go-openapi/validate"
)
type PrivateCreateSubaccountResponse struct {
	BaseMessage
	Result *PrivateCreateSubaccountResponseAO1Result `json:"result"`
}
func (m *PrivateCreateSubaccountResponse) UnmarshalJSON(raw []byte) error {
	var aO0 BaseMessage
	if err := swag.ReadJSON(raw, &aO0); err != nil {
		return err
	}
	m.BaseMessage = aO0
	var dataAO1 struct {
		Result *PrivateCreateSubaccountResponseAO1Result `json:"result"`
	}
	if err := swag.ReadJSON(raw, &dataAO1); err != nil {
		return err
	}
	m.Result = dataAO1.Result
	return nil
}
func (m PrivateCreateSubaccountResponse) MarshalJSON() ([]byte, error) {
	_parts := make([][]byte, 0, 2)
	aO0, err := swag.WriteJSON(m.BaseMessage)
	if err != nil {
		return nil, err
	}
	_parts = append(_parts, aO0)
	var dataAO1 struct {
		Result *PrivateCreateSubaccountResponseAO1Result `json:"result"`
	}
	dataAO1.Result = m.Result
	jsonDataAO1, errAO1 := swag.WriteJSON(dataAO1)
	if errAO1 != nil {
		return nil, errAO1
	}
	_parts = append(_parts, jsonDataAO1)
	return swag.ConcatJSON(_parts...), nil
}
func (m *PrivateCreateSubaccountResponse) Validate(formats strfmt.Registry) error {
	var res []error
	if err := m.BaseMessage.Validate(formats); err != nil {
		res = append(res, err)
	}
	if err := m.validateResult(formats); err != nil {
		res = append(res, err)
	}
	if len(res) > 0 {
		return errors.CompositeValidationError(res...)
	}
	return nil
}
func (m *PrivateCreateSubaccountResponse) validateResult(formats strfmt.Registry) error {
	if err := validate.Required("result", "body", m.Result); err != nil {
		return err
	}
	if m.Result != nil {
		if err := m.Result.Validate(formats); err != nil {
			if ve, ok := err.(*errors.Validation); ok {
				return ve.ValidateName("result")
			}
			return err
		}
	}
	return nil
}
func (m *PrivateCreateSubaccountResponse) MarshalBinary() ([]byte, error) {
	if m == nil {
		return nil, nil
	}
	return swag.WriteJSON(m)
}
func (m *PrivateCreateSubaccountResponse) UnmarshalBinary(b []byte) error {
	var res PrivateCreateSubaccountResponse
	if err := swag.ReadJSON(b, &res); err != nil {
		return err
	}
	*m = res
	return nil
}
type PrivateCreateSubaccountResponseAO1Result struct {
	Email *string `json:"email"`
	ID *int64 `json:"id"`
	IsPassword *bool `json:"is_password"`
	LoginEnabled *bool `json:"login_enabled"`
	Portfolio *Portfolio `json:"portfolio,omitempty"`
	ReceiveNotifications *bool `json:"receive_notifications"`
	SystemName *string `json:"system_name"`
	TfaEnabled *bool `json:"tfa_enabled"`
	Type *string `json:"type"`
	Username *string `json:"username"`
}