How to query using the _id field

Too query an entity using the _id field, you need to use the MongoDB $oid operator.

Given an entity like this:

{
    "_id": "55683f7ee4b0893eca070bd1",
    "nickname": "Player 3",
    "score": 400,
    "_acl": {
        "owner": "55682777e4b015f9eb4270db",
        "mode": 0
    }
}

A valid search query to obtain this instance would be:

{_id:{$oid:'55683f7ee4b0893eca070bd1'}}

You may find it useful to use the $ne operator. For instance, if you want to get all the entities except the one with that specific _id.

More info here: Data storage guide