/* tslint:disable */ /* eslint-disable */ /** * Bandwidth * Bandwidth\'s Communication APIs * * The version of the OpenAPI document: 1.0.0 * Contact: letstalk@bandwidth.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech * Do not edit the class manually. */ import type { Configuration } from '../configuration'; import type { AxiosPromise, AxiosInstance, RawAxiosRequestConfig } from 'axios'; import globalAxios from 'axios'; // Some imports not used depending on template conditions // @ts-ignore import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from '../common'; // @ts-ignore import { BASE_PATH, COLLECTION_FORMATS, type RequestArgs, BaseAPI, RequiredError, operationServerMap } from '../base'; // @ts-ignore import type { Conference } from '../models'; // @ts-ignore import type { ConferenceMember } from '../models'; // @ts-ignore import type { ConferenceRecordingMetadata } from '../models'; // @ts-ignore import type { UpdateConference } from '../models'; // @ts-ignore import type { UpdateConferenceMember } from '../models'; // @ts-ignore import type { VoiceApiError } from '../models'; /** * ConferencesApi - axios parameter creator */ export const ConferencesApiAxiosParamCreator = function (configuration?: Configuration) { return { /** * Downloads the specified recording file. * @summary Download Conference Recording * @param {string} accountId Your Bandwidth Account ID. * @param {string} conferenceId Programmable Voice API Conference ID. * @param {string} recordingId Programmable Voice API Recording ID. * @param {*} [options] Override http request option. * @throws {RequiredError} */ downloadConferenceRecording: async (accountId: string, conferenceId: string, recordingId: string, options: RawAxiosRequestConfig = {}): Promise => { // verify required parameter 'accountId' is not null or undefined assertParamExists('downloadConferenceRecording', 'accountId', accountId) // verify required parameter 'conferenceId' is not null or undefined assertParamExists('downloadConferenceRecording', 'conferenceId', conferenceId) // verify required parameter 'recordingId' is not null or undefined assertParamExists('downloadConferenceRecording', 'recordingId', recordingId) const localVarPath = `/accounts/{accountId}/conferences/{conferenceId}/recordings/{recordingId}/media` .replace(`{${"accountId"}}`, encodeURIComponent(String(accountId))) .replace(`{${"conferenceId"}}`, encodeURIComponent(String(conferenceId))) .replace(`{${"recordingId"}}`, encodeURIComponent(String(recordingId))); // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); let baseOptions; if (configuration) { baseOptions = configuration.baseOptions; } const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options}; const localVarHeaderParameter = {} as any; const localVarQueryParameter = {} as any; // authentication Basic required // http basic authentication required setBasicAuthToObject(localVarRequestOptions, configuration) // authentication OAuth2 required // oauth required await setOAuthToObject(localVarHeaderParameter, "OAuth2", [], configuration) setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; return { url: toPathString(localVarUrlObj), options: localVarRequestOptions, }; }, /** * Returns information about the specified conference. * @summary Get Conference Information * @param {string} accountId Your Bandwidth Account ID. * @param {string} conferenceId Programmable Voice API Conference ID. * @param {*} [options] Override http request option. * @throws {RequiredError} */ getConference: async (accountId: string, conferenceId: string, options: RawAxiosRequestConfig = {}): Promise => { // verify required parameter 'accountId' is not null or undefined assertParamExists('getConference', 'accountId', accountId) // verify required parameter 'conferenceId' is not null or undefined assertParamExists('getConference', 'conferenceId', conferenceId) const localVarPath = `/accounts/{accountId}/conferences/{conferenceId}` .replace(`{${"accountId"}}`, encodeURIComponent(String(accountId))) .replace(`{${"conferenceId"}}`, encodeURIComponent(String(conferenceId))); // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); let baseOptions; if (configuration) { baseOptions = configuration.baseOptions; } const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options}; const localVarHeaderParameter = {} as any; const localVarQueryParameter = {} as any; // authentication Basic required // http basic authentication required setBasicAuthToObject(localVarRequestOptions, configuration) // authentication OAuth2 required // oauth required await setOAuthToObject(localVarHeaderParameter, "OAuth2", [], configuration) setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; return { url: toPathString(localVarUrlObj), options: localVarRequestOptions, }; }, /** * Returns information about the specified conference member. * @summary Get Conference Member * @param {string} accountId Your Bandwidth Account ID. * @param {string} conferenceId Programmable Voice API Conference ID. * @param {string} memberId Programmable Voice API Conference Member ID. * @param {*} [options] Override http request option. * @throws {RequiredError} */ getConferenceMember: async (accountId: string, conferenceId: string, memberId: string, options: RawAxiosRequestConfig = {}): Promise => { // verify required parameter 'accountId' is not null or undefined assertParamExists('getConferenceMember', 'accountId', accountId) // verify required parameter 'conferenceId' is not null or undefined assertParamExists('getConferenceMember', 'conferenceId', conferenceId) // verify required parameter 'memberId' is not null or undefined assertParamExists('getConferenceMember', 'memberId', memberId) const localVarPath = `/accounts/{accountId}/conferences/{conferenceId}/members/{memberId}` .replace(`{${"accountId"}}`, encodeURIComponent(String(accountId))) .replace(`{${"conferenceId"}}`, encodeURIComponent(String(conferenceId))) .replace(`{${"memberId"}}`, encodeURIComponent(String(memberId))); // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); let baseOptions; if (configuration) { baseOptions = configuration.baseOptions; } const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options}; const localVarHeaderParameter = {} as any; const localVarQueryParameter = {} as any; // authentication Basic required // http basic authentication required setBasicAuthToObject(localVarRequestOptions, configuration) // authentication OAuth2 required // oauth required await setOAuthToObject(localVarHeaderParameter, "OAuth2", [], configuration) setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; return { url: toPathString(localVarUrlObj), options: localVarRequestOptions, }; }, /** * Returns metadata for the specified recording. * @summary Get Conference Recording Information * @param {string} accountId Your Bandwidth Account ID. * @param {string} conferenceId Programmable Voice API Conference ID. * @param {string} recordingId Programmable Voice API Recording ID. * @param {*} [options] Override http request option. * @throws {RequiredError} */ getConferenceRecording: async (accountId: string, conferenceId: string, recordingId: string, options: RawAxiosRequestConfig = {}): Promise => { // verify required parameter 'accountId' is not null or undefined assertParamExists('getConferenceRecording', 'accountId', accountId) // verify required parameter 'conferenceId' is not null or undefined assertParamExists('getConferenceRecording', 'conferenceId', conferenceId) // verify required parameter 'recordingId' is not null or undefined assertParamExists('getConferenceRecording', 'recordingId', recordingId) const localVarPath = `/accounts/{accountId}/conferences/{conferenceId}/recordings/{recordingId}` .replace(`{${"accountId"}}`, encodeURIComponent(String(accountId))) .replace(`{${"conferenceId"}}`, encodeURIComponent(String(conferenceId))) .replace(`{${"recordingId"}}`, encodeURIComponent(String(recordingId))); // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); let baseOptions; if (configuration) { baseOptions = configuration.baseOptions; } const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options}; const localVarHeaderParameter = {} as any; const localVarQueryParameter = {} as any; // authentication Basic required // http basic authentication required setBasicAuthToObject(localVarRequestOptions, configuration) // authentication OAuth2 required // oauth required await setOAuthToObject(localVarHeaderParameter, "OAuth2", [], configuration) setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; return { url: toPathString(localVarUrlObj), options: localVarRequestOptions, }; }, /** * Returns a (potentially empty) list of metadata for the recordings that took place during the specified conference. * @summary Get Conference Recordings * @param {string} accountId Your Bandwidth Account ID. * @param {string} conferenceId Programmable Voice API Conference ID. * @param {*} [options] Override http request option. * @throws {RequiredError} */ listConferenceRecordings: async (accountId: string, conferenceId: string, options: RawAxiosRequestConfig = {}): Promise => { // verify required parameter 'accountId' is not null or undefined assertParamExists('listConferenceRecordings', 'accountId', accountId) // verify required parameter 'conferenceId' is not null or undefined assertParamExists('listConferenceRecordings', 'conferenceId', conferenceId) const localVarPath = `/accounts/{accountId}/conferences/{conferenceId}/recordings` .replace(`{${"accountId"}}`, encodeURIComponent(String(accountId))) .replace(`{${"conferenceId"}}`, encodeURIComponent(String(conferenceId))); // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); let baseOptions; if (configuration) { baseOptions = configuration.baseOptions; } const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options}; const localVarHeaderParameter = {} as any; const localVarQueryParameter = {} as any; // authentication Basic required // http basic authentication required setBasicAuthToObject(localVarRequestOptions, configuration) // authentication OAuth2 required // oauth required await setOAuthToObject(localVarHeaderParameter, "OAuth2", [], configuration) setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; return { url: toPathString(localVarUrlObj), options: localVarRequestOptions, }; }, /** * Returns a max of 1000 conferences, sorted by `createdTime` from oldest to newest. **NOTE:** If the number of conferences in the account is bigger than `pageSize`, a `Link` header (with format `<{url}>; rel=\"next\"`) will be returned in the response. The url can be used to retrieve the next page of conference records. * @summary Get Conferences * @param {string} accountId Your Bandwidth Account ID. * @param {string} [name] Filter results by the `name` field. * @param {string} [minCreatedTime] Filter results to conferences which have a `createdTime` after or at `minCreatedTime` (in ISO8601 format). * @param {string} [maxCreatedTime] Filter results to conferences which have a `createdTime` before or at `maxCreatedTime` (in ISO8601 format). * @param {number} [pageSize] Specifies the max number of conferences that will be returned. * @param {string} [pageToken] Not intended for explicit use. To use pagination, follow the links in the `Link` header of the response, as indicated in the endpoint description. * @param {*} [options] Override http request option. * @throws {RequiredError} */ listConferences: async (accountId: string, name?: string, minCreatedTime?: string, maxCreatedTime?: string, pageSize?: number, pageToken?: string, options: RawAxiosRequestConfig = {}): Promise => { // verify required parameter 'accountId' is not null or undefined assertParamExists('listConferences', 'accountId', accountId) const localVarPath = `/accounts/{accountId}/conferences` .replace(`{${"accountId"}}`, encodeURIComponent(String(accountId))); // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); let baseOptions; if (configuration) { baseOptions = configuration.baseOptions; } const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options}; const localVarHeaderParameter = {} as any; const localVarQueryParameter = {} as any; // authentication Basic required // http basic authentication required setBasicAuthToObject(localVarRequestOptions, configuration) // authentication OAuth2 required // oauth required await setOAuthToObject(localVarHeaderParameter, "OAuth2", [], configuration) if (name !== undefined) { localVarQueryParameter['name'] = name; } if (minCreatedTime !== undefined) { localVarQueryParameter['minCreatedTime'] = minCreatedTime; } if (maxCreatedTime !== undefined) { localVarQueryParameter['maxCreatedTime'] = maxCreatedTime; } if (pageSize !== undefined) { localVarQueryParameter['pageSize'] = pageSize; } if (pageToken !== undefined) { localVarQueryParameter['pageToken'] = pageToken; } setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; return { url: toPathString(localVarUrlObj), options: localVarRequestOptions, }; }, /** * Update the conference state. * @summary Update Conference * @param {string} accountId Your Bandwidth Account ID. * @param {string} conferenceId Programmable Voice API Conference ID. * @param {UpdateConference} updateConference * @param {*} [options] Override http request option. * @throws {RequiredError} */ updateConference: async (accountId: string, conferenceId: string, updateConference: UpdateConference, options: RawAxiosRequestConfig = {}): Promise => { // verify required parameter 'accountId' is not null or undefined assertParamExists('updateConference', 'accountId', accountId) // verify required parameter 'conferenceId' is not null or undefined assertParamExists('updateConference', 'conferenceId', conferenceId) // verify required parameter 'updateConference' is not null or undefined assertParamExists('updateConference', 'updateConference', updateConference) const localVarPath = `/accounts/{accountId}/conferences/{conferenceId}` .replace(`{${"accountId"}}`, encodeURIComponent(String(accountId))) .replace(`{${"conferenceId"}}`, encodeURIComponent(String(conferenceId))); // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); let baseOptions; if (configuration) { baseOptions = configuration.baseOptions; } const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options}; const localVarHeaderParameter = {} as any; const localVarQueryParameter = {} as any; // authentication Basic required // http basic authentication required setBasicAuthToObject(localVarRequestOptions, configuration) // authentication OAuth2 required // oauth required await setOAuthToObject(localVarHeaderParameter, "OAuth2", [], configuration) localVarHeaderParameter['Content-Type'] = 'application/json'; setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; localVarRequestOptions.data = serializeDataIfNeeded(updateConference, localVarRequestOptions, configuration) return { url: toPathString(localVarUrlObj), options: localVarRequestOptions, }; }, /** * Update the conference BXML document. * @summary Update Conference BXML * @param {string} accountId Your Bandwidth Account ID. * @param {string} conferenceId Programmable Voice API Conference ID. * @param {string} body * @param {*} [options] Override http request option. * @throws {RequiredError} */ updateConferenceBxml: async (accountId: string, conferenceId: string, body: string, options: RawAxiosRequestConfig = {}): Promise => { // verify required parameter 'accountId' is not null or undefined assertParamExists('updateConferenceBxml', 'accountId', accountId) // verify required parameter 'conferenceId' is not null or undefined assertParamExists('updateConferenceBxml', 'conferenceId', conferenceId) // verify required parameter 'body' is not null or undefined assertParamExists('updateConferenceBxml', 'body', body) const localVarPath = `/accounts/{accountId}/conferences/{conferenceId}/bxml` .replace(`{${"accountId"}}`, encodeURIComponent(String(accountId))) .replace(`{${"conferenceId"}}`, encodeURIComponent(String(conferenceId))); // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); let baseOptions; if (configuration) { baseOptions = configuration.baseOptions; } const localVarRequestOptions = { method: 'PUT', ...baseOptions, ...options}; const localVarHeaderParameter = {} as any; const localVarQueryParameter = {} as any; // authentication Basic required // http basic authentication required setBasicAuthToObject(localVarRequestOptions, configuration) // authentication OAuth2 required // oauth required await setOAuthToObject(localVarHeaderParameter, "OAuth2", [], configuration) localVarHeaderParameter['Content-Type'] = 'application/xml'; setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; localVarRequestOptions.data = serializeDataIfNeeded(body, localVarRequestOptions, configuration) return { url: toPathString(localVarUrlObj), options: localVarRequestOptions, }; }, /** * Updates settings for a particular conference member. * @summary Update Conference Member * @param {string} accountId Your Bandwidth Account ID. * @param {string} conferenceId Programmable Voice API Conference ID. * @param {string} memberId Programmable Voice API Conference Member ID. * @param {UpdateConferenceMember} updateConferenceMember * @param {*} [options] Override http request option. * @throws {RequiredError} */ updateConferenceMember: async (accountId: string, conferenceId: string, memberId: string, updateConferenceMember: UpdateConferenceMember, options: RawAxiosRequestConfig = {}): Promise => { // verify required parameter 'accountId' is not null or undefined assertParamExists('updateConferenceMember', 'accountId', accountId) // verify required parameter 'conferenceId' is not null or undefined assertParamExists('updateConferenceMember', 'conferenceId', conferenceId) // verify required parameter 'memberId' is not null or undefined assertParamExists('updateConferenceMember', 'memberId', memberId) // verify required parameter 'updateConferenceMember' is not null or undefined assertParamExists('updateConferenceMember', 'updateConferenceMember', updateConferenceMember) const localVarPath = `/accounts/{accountId}/conferences/{conferenceId}/members/{memberId}` .replace(`{${"accountId"}}`, encodeURIComponent(String(accountId))) .replace(`{${"conferenceId"}}`, encodeURIComponent(String(conferenceId))) .replace(`{${"memberId"}}`, encodeURIComponent(String(memberId))); // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); let baseOptions; if (configuration) { baseOptions = configuration.baseOptions; } const localVarRequestOptions = { method: 'PUT', ...baseOptions, ...options}; const localVarHeaderParameter = {} as any; const localVarQueryParameter = {} as any; // authentication Basic required // http basic authentication required setBasicAuthToObject(localVarRequestOptions, configuration) // authentication OAuth2 required // oauth required await setOAuthToObject(localVarHeaderParameter, "OAuth2", [], configuration) localVarHeaderParameter['Content-Type'] = 'application/json'; setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers}; localVarRequestOptions.data = serializeDataIfNeeded(updateConferenceMember, localVarRequestOptions, configuration) return { url: toPathString(localVarUrlObj), options: localVarRequestOptions, }; }, } }; /** * ConferencesApi - functional programming interface */ export const ConferencesApiFp = function(configuration?: Configuration) { const localVarAxiosParamCreator = ConferencesApiAxiosParamCreator(configuration) return { /** * Downloads the specified recording file. * @summary Download Conference Recording * @param {string} accountId Your Bandwidth Account ID. * @param {string} conferenceId Programmable Voice API Conference ID. * @param {string} recordingId Programmable Voice API Recording ID. * @param {*} [options] Override http request option. * @throws {RequiredError} */ async downloadConferenceRecording(accountId: string, conferenceId: string, recordingId: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { const localVarAxiosArgs = await localVarAxiosParamCreator.downloadConferenceRecording(accountId, conferenceId, recordingId, options); const localVarOperationServerIndex = configuration?.serverIndex ?? 0; const localVarOperationServerBasePath = operationServerMap['ConferencesApi.downloadConferenceRecording']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, /** * Returns information about the specified conference. * @summary Get Conference Information * @param {string} accountId Your Bandwidth Account ID. * @param {string} conferenceId Programmable Voice API Conference ID. * @param {*} [options] Override http request option. * @throws {RequiredError} */ async getConference(accountId: string, conferenceId: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { const localVarAxiosArgs = await localVarAxiosParamCreator.getConference(accountId, conferenceId, options); const localVarOperationServerIndex = configuration?.serverIndex ?? 0; const localVarOperationServerBasePath = operationServerMap['ConferencesApi.getConference']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, /** * Returns information about the specified conference member. * @summary Get Conference Member * @param {string} accountId Your Bandwidth Account ID. * @param {string} conferenceId Programmable Voice API Conference ID. * @param {string} memberId Programmable Voice API Conference Member ID. * @param {*} [options] Override http request option. * @throws {RequiredError} */ async getConferenceMember(accountId: string, conferenceId: string, memberId: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { const localVarAxiosArgs = await localVarAxiosParamCreator.getConferenceMember(accountId, conferenceId, memberId, options); const localVarOperationServerIndex = configuration?.serverIndex ?? 0; const localVarOperationServerBasePath = operationServerMap['ConferencesApi.getConferenceMember']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, /** * Returns metadata for the specified recording. * @summary Get Conference Recording Information * @param {string} accountId Your Bandwidth Account ID. * @param {string} conferenceId Programmable Voice API Conference ID. * @param {string} recordingId Programmable Voice API Recording ID. * @param {*} [options] Override http request option. * @throws {RequiredError} */ async getConferenceRecording(accountId: string, conferenceId: string, recordingId: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { const localVarAxiosArgs = await localVarAxiosParamCreator.getConferenceRecording(accountId, conferenceId, recordingId, options); const localVarOperationServerIndex = configuration?.serverIndex ?? 0; const localVarOperationServerBasePath = operationServerMap['ConferencesApi.getConferenceRecording']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, /** * Returns a (potentially empty) list of metadata for the recordings that took place during the specified conference. * @summary Get Conference Recordings * @param {string} accountId Your Bandwidth Account ID. * @param {string} conferenceId Programmable Voice API Conference ID. * @param {*} [options] Override http request option. * @throws {RequiredError} */ async listConferenceRecordings(accountId: string, conferenceId: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise>> { const localVarAxiosArgs = await localVarAxiosParamCreator.listConferenceRecordings(accountId, conferenceId, options); const localVarOperationServerIndex = configuration?.serverIndex ?? 0; const localVarOperationServerBasePath = operationServerMap['ConferencesApi.listConferenceRecordings']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, /** * Returns a max of 1000 conferences, sorted by `createdTime` from oldest to newest. **NOTE:** If the number of conferences in the account is bigger than `pageSize`, a `Link` header (with format `<{url}>; rel=\"next\"`) will be returned in the response. The url can be used to retrieve the next page of conference records. * @summary Get Conferences * @param {string} accountId Your Bandwidth Account ID. * @param {string} [name] Filter results by the `name` field. * @param {string} [minCreatedTime] Filter results to conferences which have a `createdTime` after or at `minCreatedTime` (in ISO8601 format). * @param {string} [maxCreatedTime] Filter results to conferences which have a `createdTime` before or at `maxCreatedTime` (in ISO8601 format). * @param {number} [pageSize] Specifies the max number of conferences that will be returned. * @param {string} [pageToken] Not intended for explicit use. To use pagination, follow the links in the `Link` header of the response, as indicated in the endpoint description. * @param {*} [options] Override http request option. * @throws {RequiredError} */ async listConferences(accountId: string, name?: string, minCreatedTime?: string, maxCreatedTime?: string, pageSize?: number, pageToken?: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise>> { const localVarAxiosArgs = await localVarAxiosParamCreator.listConferences(accountId, name, minCreatedTime, maxCreatedTime, pageSize, pageToken, options); const localVarOperationServerIndex = configuration?.serverIndex ?? 0; const localVarOperationServerBasePath = operationServerMap['ConferencesApi.listConferences']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, /** * Update the conference state. * @summary Update Conference * @param {string} accountId Your Bandwidth Account ID. * @param {string} conferenceId Programmable Voice API Conference ID. * @param {UpdateConference} updateConference * @param {*} [options] Override http request option. * @throws {RequiredError} */ async updateConference(accountId: string, conferenceId: string, updateConference: UpdateConference, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { const localVarAxiosArgs = await localVarAxiosParamCreator.updateConference(accountId, conferenceId, updateConference, options); const localVarOperationServerIndex = configuration?.serverIndex ?? 0; const localVarOperationServerBasePath = operationServerMap['ConferencesApi.updateConference']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, /** * Update the conference BXML document. * @summary Update Conference BXML * @param {string} accountId Your Bandwidth Account ID. * @param {string} conferenceId Programmable Voice API Conference ID. * @param {string} body * @param {*} [options] Override http request option. * @throws {RequiredError} */ async updateConferenceBxml(accountId: string, conferenceId: string, body: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { const localVarAxiosArgs = await localVarAxiosParamCreator.updateConferenceBxml(accountId, conferenceId, body, options); const localVarOperationServerIndex = configuration?.serverIndex ?? 0; const localVarOperationServerBasePath = operationServerMap['ConferencesApi.updateConferenceBxml']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, /** * Updates settings for a particular conference member. * @summary Update Conference Member * @param {string} accountId Your Bandwidth Account ID. * @param {string} conferenceId Programmable Voice API Conference ID. * @param {string} memberId Programmable Voice API Conference Member ID. * @param {UpdateConferenceMember} updateConferenceMember * @param {*} [options] Override http request option. * @throws {RequiredError} */ async updateConferenceMember(accountId: string, conferenceId: string, memberId: string, updateConferenceMember: UpdateConferenceMember, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { const localVarAxiosArgs = await localVarAxiosParamCreator.updateConferenceMember(accountId, conferenceId, memberId, updateConferenceMember, options); const localVarOperationServerIndex = configuration?.serverIndex ?? 0; const localVarOperationServerBasePath = operationServerMap['ConferencesApi.updateConferenceMember']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, } }; /** * ConferencesApi - factory interface */ export const ConferencesApiFactory = function (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) { const localVarFp = ConferencesApiFp(configuration) return { /** * Downloads the specified recording file. * @summary Download Conference Recording * @param {string} accountId Your Bandwidth Account ID. * @param {string} conferenceId Programmable Voice API Conference ID. * @param {string} recordingId Programmable Voice API Recording ID. * @param {*} [options] Override http request option. * @throws {RequiredError} */ downloadConferenceRecording(accountId: string, conferenceId: string, recordingId: string, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.downloadConferenceRecording(accountId, conferenceId, recordingId, options).then((request) => request(axios, basePath)); }, /** * Returns information about the specified conference. * @summary Get Conference Information * @param {string} accountId Your Bandwidth Account ID. * @param {string} conferenceId Programmable Voice API Conference ID. * @param {*} [options] Override http request option. * @throws {RequiredError} */ getConference(accountId: string, conferenceId: string, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.getConference(accountId, conferenceId, options).then((request) => request(axios, basePath)); }, /** * Returns information about the specified conference member. * @summary Get Conference Member * @param {string} accountId Your Bandwidth Account ID. * @param {string} conferenceId Programmable Voice API Conference ID. * @param {string} memberId Programmable Voice API Conference Member ID. * @param {*} [options] Override http request option. * @throws {RequiredError} */ getConferenceMember(accountId: string, conferenceId: string, memberId: string, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.getConferenceMember(accountId, conferenceId, memberId, options).then((request) => request(axios, basePath)); }, /** * Returns metadata for the specified recording. * @summary Get Conference Recording Information * @param {string} accountId Your Bandwidth Account ID. * @param {string} conferenceId Programmable Voice API Conference ID. * @param {string} recordingId Programmable Voice API Recording ID. * @param {*} [options] Override http request option. * @throws {RequiredError} */ getConferenceRecording(accountId: string, conferenceId: string, recordingId: string, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.getConferenceRecording(accountId, conferenceId, recordingId, options).then((request) => request(axios, basePath)); }, /** * Returns a (potentially empty) list of metadata for the recordings that took place during the specified conference. * @summary Get Conference Recordings * @param {string} accountId Your Bandwidth Account ID. * @param {string} conferenceId Programmable Voice API Conference ID. * @param {*} [options] Override http request option. * @throws {RequiredError} */ listConferenceRecordings(accountId: string, conferenceId: string, options?: RawAxiosRequestConfig): AxiosPromise> { return localVarFp.listConferenceRecordings(accountId, conferenceId, options).then((request) => request(axios, basePath)); }, /** * Returns a max of 1000 conferences, sorted by `createdTime` from oldest to newest. **NOTE:** If the number of conferences in the account is bigger than `pageSize`, a `Link` header (with format `<{url}>; rel=\"next\"`) will be returned in the response. The url can be used to retrieve the next page of conference records. * @summary Get Conferences * @param {string} accountId Your Bandwidth Account ID. * @param {string} [name] Filter results by the `name` field. * @param {string} [minCreatedTime] Filter results to conferences which have a `createdTime` after or at `minCreatedTime` (in ISO8601 format). * @param {string} [maxCreatedTime] Filter results to conferences which have a `createdTime` before or at `maxCreatedTime` (in ISO8601 format). * @param {number} [pageSize] Specifies the max number of conferences that will be returned. * @param {string} [pageToken] Not intended for explicit use. To use pagination, follow the links in the `Link` header of the response, as indicated in the endpoint description. * @param {*} [options] Override http request option. * @throws {RequiredError} */ listConferences(accountId: string, name?: string, minCreatedTime?: string, maxCreatedTime?: string, pageSize?: number, pageToken?: string, options?: RawAxiosRequestConfig): AxiosPromise> { return localVarFp.listConferences(accountId, name, minCreatedTime, maxCreatedTime, pageSize, pageToken, options).then((request) => request(axios, basePath)); }, /** * Update the conference state. * @summary Update Conference * @param {string} accountId Your Bandwidth Account ID. * @param {string} conferenceId Programmable Voice API Conference ID. * @param {UpdateConference} updateConference * @param {*} [options] Override http request option. * @throws {RequiredError} */ updateConference(accountId: string, conferenceId: string, updateConference: UpdateConference, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.updateConference(accountId, conferenceId, updateConference, options).then((request) => request(axios, basePath)); }, /** * Update the conference BXML document. * @summary Update Conference BXML * @param {string} accountId Your Bandwidth Account ID. * @param {string} conferenceId Programmable Voice API Conference ID. * @param {string} body * @param {*} [options] Override http request option. * @throws {RequiredError} */ updateConferenceBxml(accountId: string, conferenceId: string, body: string, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.updateConferenceBxml(accountId, conferenceId, body, options).then((request) => request(axios, basePath)); }, /** * Updates settings for a particular conference member. * @summary Update Conference Member * @param {string} accountId Your Bandwidth Account ID. * @param {string} conferenceId Programmable Voice API Conference ID. * @param {string} memberId Programmable Voice API Conference Member ID. * @param {UpdateConferenceMember} updateConferenceMember * @param {*} [options] Override http request option. * @throws {RequiredError} */ updateConferenceMember(accountId: string, conferenceId: string, memberId: string, updateConferenceMember: UpdateConferenceMember, options?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.updateConferenceMember(accountId, conferenceId, memberId, updateConferenceMember, options).then((request) => request(axios, basePath)); }, }; }; /** * ConferencesApi - object-oriented interface */ export class ConferencesApi extends BaseAPI { /** * Downloads the specified recording file. * @summary Download Conference Recording * @param {string} accountId Your Bandwidth Account ID. * @param {string} conferenceId Programmable Voice API Conference ID. * @param {string} recordingId Programmable Voice API Recording ID. * @param {*} [options] Override http request option. * @throws {RequiredError} */ public downloadConferenceRecording(accountId: string, conferenceId: string, recordingId: string, options?: RawAxiosRequestConfig) { return ConferencesApiFp(this.configuration).downloadConferenceRecording(accountId, conferenceId, recordingId, options).then((request) => request(this.axios, this.basePath)); } /** * Returns information about the specified conference. * @summary Get Conference Information * @param {string} accountId Your Bandwidth Account ID. * @param {string} conferenceId Programmable Voice API Conference ID. * @param {*} [options] Override http request option. * @throws {RequiredError} */ public getConference(accountId: string, conferenceId: string, options?: RawAxiosRequestConfig) { return ConferencesApiFp(this.configuration).getConference(accountId, conferenceId, options).then((request) => request(this.axios, this.basePath)); } /** * Returns information about the specified conference member. * @summary Get Conference Member * @param {string} accountId Your Bandwidth Account ID. * @param {string} conferenceId Programmable Voice API Conference ID. * @param {string} memberId Programmable Voice API Conference Member ID. * @param {*} [options] Override http request option. * @throws {RequiredError} */ public getConferenceMember(accountId: string, conferenceId: string, memberId: string, options?: RawAxiosRequestConfig) { return ConferencesApiFp(this.configuration).getConferenceMember(accountId, conferenceId, memberId, options).then((request) => request(this.axios, this.basePath)); } /** * Returns metadata for the specified recording. * @summary Get Conference Recording Information * @param {string} accountId Your Bandwidth Account ID. * @param {string} conferenceId Programmable Voice API Conference ID. * @param {string} recordingId Programmable Voice API Recording ID. * @param {*} [options] Override http request option. * @throws {RequiredError} */ public getConferenceRecording(accountId: string, conferenceId: string, recordingId: string, options?: RawAxiosRequestConfig) { return ConferencesApiFp(this.configuration).getConferenceRecording(accountId, conferenceId, recordingId, options).then((request) => request(this.axios, this.basePath)); } /** * Returns a (potentially empty) list of metadata for the recordings that took place during the specified conference. * @summary Get Conference Recordings * @param {string} accountId Your Bandwidth Account ID. * @param {string} conferenceId Programmable Voice API Conference ID. * @param {*} [options] Override http request option. * @throws {RequiredError} */ public listConferenceRecordings(accountId: string, conferenceId: string, options?: RawAxiosRequestConfig) { return ConferencesApiFp(this.configuration).listConferenceRecordings(accountId, conferenceId, options).then((request) => request(this.axios, this.basePath)); } /** * Returns a max of 1000 conferences, sorted by `createdTime` from oldest to newest. **NOTE:** If the number of conferences in the account is bigger than `pageSize`, a `Link` header (with format `<{url}>; rel=\"next\"`) will be returned in the response. The url can be used to retrieve the next page of conference records. * @summary Get Conferences * @param {string} accountId Your Bandwidth Account ID. * @param {string} [name] Filter results by the `name` field. * @param {string} [minCreatedTime] Filter results to conferences which have a `createdTime` after or at `minCreatedTime` (in ISO8601 format). * @param {string} [maxCreatedTime] Filter results to conferences which have a `createdTime` before or at `maxCreatedTime` (in ISO8601 format). * @param {number} [pageSize] Specifies the max number of conferences that will be returned. * @param {string} [pageToken] Not intended for explicit use. To use pagination, follow the links in the `Link` header of the response, as indicated in the endpoint description. * @param {*} [options] Override http request option. * @throws {RequiredError} */ public listConferences(accountId: string, name?: string, minCreatedTime?: string, maxCreatedTime?: string, pageSize?: number, pageToken?: string, options?: RawAxiosRequestConfig) { return ConferencesApiFp(this.configuration).listConferences(accountId, name, minCreatedTime, maxCreatedTime, pageSize, pageToken, options).then((request) => request(this.axios, this.basePath)); } /** * Update the conference state. * @summary Update Conference * @param {string} accountId Your Bandwidth Account ID. * @param {string} conferenceId Programmable Voice API Conference ID. * @param {UpdateConference} updateConference * @param {*} [options] Override http request option. * @throws {RequiredError} */ public updateConference(accountId: string, conferenceId: string, updateConference: UpdateConference, options?: RawAxiosRequestConfig) { return ConferencesApiFp(this.configuration).updateConference(accountId, conferenceId, updateConference, options).then((request) => request(this.axios, this.basePath)); } /** * Update the conference BXML document. * @summary Update Conference BXML * @param {string} accountId Your Bandwidth Account ID. * @param {string} conferenceId Programmable Voice API Conference ID. * @param {string} body * @param {*} [options] Override http request option. * @throws {RequiredError} */ public updateConferenceBxml(accountId: string, conferenceId: string, body: string, options?: RawAxiosRequestConfig) { return ConferencesApiFp(this.configuration).updateConferenceBxml(accountId, conferenceId, body, options).then((request) => request(this.axios, this.basePath)); } /** * Updates settings for a particular conference member. * @summary Update Conference Member * @param {string} accountId Your Bandwidth Account ID. * @param {string} conferenceId Programmable Voice API Conference ID. * @param {string} memberId Programmable Voice API Conference Member ID. * @param {UpdateConferenceMember} updateConferenceMember * @param {*} [options] Override http request option. * @throws {RequiredError} */ public updateConferenceMember(accountId: string, conferenceId: string, memberId: string, updateConferenceMember: UpdateConferenceMember, options?: RawAxiosRequestConfig) { return ConferencesApiFp(this.configuration).updateConferenceMember(accountId, conferenceId, memberId, updateConferenceMember, options).then((request) => request(this.axios, this.basePath)); } }