(context, deploymentName, fileContent, formatOrOptions, inputOptions)
| 78223 | tracingOptions, |
| 78224 | requestOptions |
| 78225 | })), { contentType: "multipart/form-data", body: Object.assign(Object.assign(Object.assign({}, snakeCaseKeys(rest)), { file: createFile(fileContent, "placeholder.wav") }), response_format ? { response_format } : {}) })); |
| 78226 | if (status !== "200") { |
| 78227 | throw body.error; |
| 78228 | } |
| 78229 | return response_format !== "verbose_json" ? body : camelCaseKeys(body); |
| 78230 | } |
| 78231 | async function getAudioTranslation(context, deploymentName, fileContent, formatOrOptions, inputOptions) { |
| 78232 | const options = inputOptions !== null && inputOptions !== void 0 ? inputOptions : typeof formatOrOptions === "string" ? {} : formatOrOptions !== null && formatOrOptions !== void 0 ? formatOrOptions : {}; |
| 78233 | const response_format = typeof formatOrOptions === "string" ? formatOrOptions : void 0; |
| 78234 | const { abortSignal, onResponse, requestOptions, tracingOptions } = options, rest = __rest(options, ["abortSignal", "onResponse", "requestOptions", "tracingOptions"]); |
| 78235 | const { body, status } = await context.pathUnchecked("deployments/{deploymentName}/audio/translations", deploymentName).post(Object.assign(Object.assign({}, operationOptionsToRequestParameters({ |
| 78236 | abortSignal, |
| 78237 | onResponse, |
| 78238 | tracingOptions, |
| 78239 | requestOptions |
| 78240 | })), { contentType: "multipart/form-data", body: Object.assign(Object.assign(Object.assign({}, snakeCaseKeys(rest)), { file: createFile(fileContent, "placeholder.wav") }), response_format ? { response_format } : {}) })); |
| 78241 | if (status !== "200") { |
| 78242 | throw body.error; |
no test coverage detected
searching dependent graphs…