title: respond_with return 200 instead of 422
body: <p>I have a model with active model validations that I am using to determine the validity of search terms...  If I call my controller endpoint with an invalid search, rails' respond_with is returning a 200 instead of a 422.</p>
  
  <p>If I binding.pry inside my controller action, I see:
  search_result.valid?
  => false</p>
  
  <p>search_result.errors.full_messages
  => "Last name must be at least 2 characters"</p>
  
  <p>...  So why am I getting a 200?</p>
  
  <pre><code>model:
  
      class SearchResult
        include ActiveModel::Validations
        validate :ensure_terms_presence_and_length
  
        attr_reader :attrs
  
        def initialize(attrs = {})
          @attrs = attrs
        end
  
        def users
          valid? ? SearchClient.search(attrs) : []
        end
  
        private
  
        def ensure_terms_presence_and_length
          if attrs.values.join.blank?
            errors.add(:base, 'search fields cannot be blank')
          else
            attrs.each do |key, value|
              errors.add(key, 'must be at least 2 characters') if value.length &lt; 2
            end
          end
        end
      end
  
   controller:
  
      module Api::V1
        class SearchUsersController &lt; ApiController
          respond_to :json
  
          def index
            search_result = SearchResult.new(permitted_params)
            respond_with search_result, serializer: SearchResultSerializer
          end
  
          private
  
          def permitted_params
            params.permit(
              :username,
              :first_name,
              :last_name,
              :email
            )
          end
        end
      end
  </code></pre>