How to reference schemas as environment variables or an alternative

Per Tip #4 of this article I should be able to store a schema validation in a file and reference it within a test. However I’m getting invalid JSON if I try to have the key value go across multiple lines for readability (I’m attempting to modify the raw text that is saved in the globals json).

Can I just paste the determined schema into the value for the global key? Yes. However, that feels like a very clunky way of editing the schema and when the file is saved/exported you end up with a very long string with a lot of escaped new lines.

Is this the only way of referencing a schema?

@r.m.kidd If the schema is hosted somewhere, you can download it with pm.sendRequest and use it for validation without having to save a potentially leviathan schema JSON in your variables :smile: