Custom validation

It would be great to provide a snippet of javascript or similar that would evaluate input for a given field and return either an all-good or an error message.

We can implement this in two ways:

  • User provides an endpoint, and DatoCMS calls such endpoint passing the payload to validate
  • User provides some JS validation function, and DatoCMS runs it inside a sandbox environment https://www.npmjs.com/package/vm2
1 Like

Hi Stefano! Was this feature implemented? Thanks.

hey @guido.lode not yet.

We tag the feature requests that we release as “launched”. The ones that are currently on our backlog (being in development or soon in dev) ar tagged as “planned”, so that you can track how things are going.

@mat_jack1 Any updates on where this might land on the roadmap? Very interested to get my team on DatoCMS, but without deeper validation abilities we’re a bit hamstrung.

hey @aaronransley sorry but we haven’t decided yet for this feature. It might come in the next 3 to 6 months though, as it’s not very complex, we are just planning to do other wider features before. We’ll publish soon a roadmap for the next three months in our blog!