MCPcopy Index your code
hub / github.com/mongodb/mongo-python-driver / add_server_api

Method add_server_api

pymongo/asynchronous/pool.py:596–599  ·  view source on GitHub ↗

Add server_api parameters.

(self, command: MutableMapping[str, Any])

Source from the content-addressed store, hash-verified

594 client._send_cluster_time(command, session)
595
596 def add_server_api(self, command: MutableMapping[str, Any]) -> None:
597 """Add server_api parameters."""
598 if self.opts.server_api:
599 _add_to_command(command, self.opts.server_api)
600
601 def update_last_checkin_time(self) -> None:
602 self.last_checkin_time = time.monotonic()

Callers 5

commandMethod · 0.95
_execute_commandMethod · 0.45
execute_command_unackMethod · 0.45
_execute_commandMethod · 0.45

Calls 1

_add_to_commandFunction · 0.90

Tested by

no test coverage detected