#CodeTidbit1
1/3 đŸ§”

Cerberus is a Python validation library that provides powerful yet simple and lightweight data validation functionality.

All you need to do is define a schema and validate your post request payload against it.

#100DaysOfCode #Python

2/3

You can add various validation rules for the fields.

Even regex expressions can be used to validate data inside your fields which is very powerful.
3/3

All errors together are appended in a python dictionary which points out exactly at what place and why an error occurred.

The above code snippet prints "Valid Payload".

Check out the documentation: https://t.co/R0Pz5GSxiI

You May Also Like

I think a plausible explanation is that whatever Corbyn says or does, his critics will denounce - no matter how much hypocrisy it necessitates.


Corbyn opposes the exploitation of foreign sweatshop-workers - Labour MPs complain he's like Nigel

He speaks up in defence of migrants - Labour MPs whinge that he's not listening to the public's very real concerns about immigration:

He's wrong to prioritise Labour Party members over the public:

He's wrong to prioritise the public over Labour Party