How can a code that takes dict as input and validates it based on multiple conditions be further optimized?
Keyerror
Did you test this code with some invalid input?
The code will fail with a keyError if the items key does not exist, since your code just assumes it exists.
You could do a try-except with the json_to_test['items'] so that you can handle the keyError.
Unspecificness
if any(isinstance(i, list) for i in json_input)

You're testing that json_input contains at least one element that is a list, but that could be something elese than json_to_test['items'] which you clearly said has to be a list. Why aren't you testing that particular object?
Nested code
Your code is triple-nested which makes it hard to read and to maintain.
It is better if you check each error condition separately without nesting and return only if they all pass. That also makes it much easier to add or remove another validation check without re-indenting the whole code and figuring out where it goes.
Something like this:
if fail_condition_1:
    abort(&quot;error_message_1&quot;)

if fail_condition_2:
    abort(&quot;error_message_2&quot;)

if fail_condition_3:
    abort(&quot;error_message_3&quot;)

print('Data ready to be saved to DB')
return json_input
```