I am looking to accept json data in a form field and than validate it using some database operations. The data will mostly consist of an array of integers. So can you please help me as to how can i do so.
I have tried to google this but didn’t get any decent answer. Please help.
You need to take it as text input using
CharField. And in the clean method of this field, you can validate it as per your requirement to check if input is valid.Something like:
You may also find a custom field for JSON data input.