MCPcopy
hub / github.com/openai/openai-python / _send_request

Method _send_request

src/openai/_client.py:1067–1080  ·  view source on GitHub ↗
(
        self,
        request: httpx.Request,
        *,
        stream: bool,
        **kwargs: Unpack[HttpxSendArgs],
    )

Source from the content-addressed store, hash-verified

1065
1066 @override
1067 async def _send_request(
1068 self,
1069 request: httpx.Request,
1070 *,
1071 stream: bool,
1072 **kwargs: Unpack[HttpxSendArgs],
1073 ) -> httpx.Response:
1074 response = await self._send_with_auth_retry(request, stream=stream, **kwargs)
1075 if self._provider_runtime is not None:
1076 if self._provider_runtime.normalize_async_response is not None:
1077 response = await self._provider_runtime.normalize_async_response(response)
1078 elif self._provider_runtime.normalize_response is not None:
1079 response = self._provider_runtime.normalize_response(response)
1080 return response
1081
1082 @override
1083 def _auth_headers(self, security: SecurityOptions) -> dict[str, str]:

Callers

nothing calls this directly

Calls 1

_send_with_auth_retryMethod · 0.95

Tested by

no test coverage detected