younifyd
Menu

Find One

Find a single document in a MongoDB collection

Use it in a workflow

  1. Add a step and choose the MongoDB connector.
  2. Pick the Find One action (under mongodb).
  3. Fill in the fields below, then reference the result from later steps as {{findOne.response.data}}.

Fields

databasestringrequired

The name of the MongoDB database

collectionstringrequired

The name of the MongoDB collection

filterstringrequired

JSON string containing the query filter (e.g., {"name": "John"} or {"_id": "507f1f77bcf86cd799439011"})

projectionstring

JSON string specifying which fields to return (e.g., {"name": 1, "email": 1, "_id": 0})

sortstring

JSON string specifying sort order (e.g., {"createdAt": -1} for descending)

Need more? See the MongoDB guide for connection setup and behaviour shared by every action.

Was this page helpful?