Editing mongoDB via external script

Doesn’t compatible with parse-server objectId and mongoDb auto-created id, parse-server objectId calculated in cryptoUtils.js. If you want to do consistent work, you can use this class.
ex:

// script.js
const { newObjectId } = require('parse-server/lib/cryptoUtils');
//...
{
    _id: newObjectId(),
    name: 'admin'
}

If you created a new class or columns, you should update schemas according to your changes.

1 Like