docs
docs copied to clipboard
ID only supports integer but strings also works
According to docs API Platform supports as ID identifiers for MongoDB only integers with an increment strategy. But when testing string IDs they seem to work well, including references to other documents. 1. Is it a non-documented feature? 2. Is it a deprecated feature to be removed in future releases? 3. Is it an unexpected behavior?
Documentation: https://api-platform.com/docs/master/core/mongodb/
Identifier fields always need to be integers with an increment strategy. API Platform does not support the native ObjectId.
Thanks!