Invalid input data. Please verify unique constraints Strapi

Viewed 1519

I'm trying to add a product data in my Strapi product, but sometimes it shows "Invalid input data. Please verify unique constraints" errors. Anyone have dealt with this before?

I got {statusCode: 400, error: "Bad Request", message: "Invalid input data. Please verify unique constraints"} in my console.

2 Answers

This happened to me because I was missing const axios = require('axios'); in some of my model files. I did webhooks myself for each model using axios to send a POST request.

Try npm run strapi console It was very helpful. It did show an erorr in a console with enough info, as I tried to update a field in a single type.

Maybe you missing something in your model/service/controller. Strapi console will reveal it, hopefully.

Related