Expected validation errors are not showing up

New guy here.

Here’s a snippet from API definition file:

      summary: Returns a list of houses.
      description:  Returns a list of all houses in the database.
        '201':    # status code
          description: Successful operation
                type: integer

And here’s my request to my API down this path:

As you can see, I have purposely incorporated two flaws in my definitions file - response code is not 201, and we receive not an integer but an array of objects.

Why are there no validation errors popping up?

From looking at your request, it doesn’t appear you have any tests.

Where have you added your validations?

It won’t error based on the definition file. You have to add tests.

I mean, straight in the Postman web-interface. As far as I get it, it should throw me errors when I send requests through it. And sometimes it works, like here:

But in the mentioned case it doesn’t…

I haven’t used that feature, so hopefully someone who has might be able to answer your question.

I don’t know how or what Postman checks when you import a definition like this.

Not sure that integer will be a valid schema type for application/json. Which would be object or array (or just object, as an array is a type of object).

Integer’s would be set against the individual properties.

First time I’ve seen the feature. Nice to know its there.

I purposely set it to integer to initiate the error.

Thanks for attempt to help. Glad you found out something new.

Hope someone will come up with the solution…