.. _ref: _ref and ref ============ **_ref** assigns an integer reference to objects added or found by a command. Later commands in the same request consume it through **ref** or a command-specific field such as **src**, **dst**, **image_ref**, or **video_ref**. A reference may represent several matched objects. References must be declared before use, have the object type required by the consumer, and use IDs from 1 through 100000. Do not reuse an ID for another producer in the same request. References expire with the request; use an object's **_uniqueid** or an application property to find it in a later request. Omitting **_ref** creates no reference. Setting it does not itself request properties or binary output. In a reference-only Find command, ``returned: 0`` can therefore accompany a nonempty match set; see :doc:`../Responses`. For complete creation and traversal examples, see :doc:`../TransactionsAndReferences`. See :doc:`connect`, :doc:`is_connected_to`, and :doc:`../commands/AddConnection` for consuming fields.