(endpoint, credentials, options = {})
| 77526 | } |
| 77527 | return false; |
| 77528 | } |
| 77529 | |
| 77530 | // node_modules/@azure/openai/dist-esm/src/logger.js |
| 77531 | var logger2 = createClientLogger("openai"); |
| 77532 | |
| 77533 | // node_modules/@azure/openai/dist-esm/src/rest/openAIClient.js |
| 77534 | function createClient(endpoint, credentials, options = {}) { |
| 77535 | var _a5, _b2, _c2, _d2, _e2, _f, _g, _h; |
| 77536 | const baseUrl = (_a5 = options.baseUrl) !== null && _a5 !== void 0 ? _a5 : `${endpoint}/openai`; |
| 77537 | options.apiVersion = (_b2 = options.apiVersion) !== null && _b2 !== void 0 ? _b2 : "2024-03-01-preview"; |
| 77538 | const userAgentInfo = `azsdk-js-openai-rest/1.0.0-beta.12`; |
| 77539 | const userAgentPrefix = options.userAgentOptions && options.userAgentOptions.userAgentPrefix ? `${options.userAgentOptions.userAgentPrefix} ${userAgentInfo}` : `${userAgentInfo}`; |
| 77540 | options = Object.assign(Object.assign({}, options), { userAgentOptions: { |
| 77541 | userAgentPrefix |
| 77542 | }, loggingOptions: { |
| 77543 | logger: (_d2 = (_c2 = options.loggingOptions) === null || _c2 === void 0 ? void 0 : _c2.logger) !== null && _d2 !== void 0 ? _d2 : logger2.info |
| 77544 | }, credentials: { |
| 77545 | scopes: (_f = (_e2 = options.credentials) === null || _e2 === void 0 ? void 0 : _e2.scopes) !== null && _f !== void 0 ? _f : ["https://cognitiveservices.azure.com/.default"], |
| 77546 | apiKeyHeaderName: (_h = (_g = options.credentials) === null || _g === void 0 ? void 0 : _g.apiKeyHeaderName) !== null && _h !== void 0 ? _h : "api-key" |
| 77547 | } }); |
nothing calls this directly
no test coverage detected
searching dependent graphs…