bandwidth-sdk 7.4.2 → 8.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.github/workflows/deploy.yml +1 -1
- package/.github/workflows/test-pr.yml +1 -1
- package/.github/workflows/test-smoke.yml +1 -1
- package/.openapi-generator/FILES +48 -4
- package/README.md +28 -2
- package/api/endpoints-api.ts +519 -0
- package/api/media-api.ts +4 -4
- package/api.ts +1 -0
- package/bandwidth.yml +972 -60
- package/base.ts +30 -0
- package/configuration.ts +1 -1
- package/coverage/clover.xml +815 -616
- package/coverage/coverage-final.json +95 -88
- package/coverage/lcov-report/index.html +38 -38
- package/coverage/lcov-report/node-sdk/api/calls-api.ts.html +14 -14
- package/coverage/lcov-report/node-sdk/api/conferences-api.ts.html +18 -18
- package/coverage/lcov-report/node-sdk/api/endpoints-api.ts.html +1642 -0
- package/coverage/lcov-report/node-sdk/api/index.html +24 -9
- package/coverage/lcov-report/node-sdk/api/media-api.ts.html +17 -17
- package/coverage/lcov-report/node-sdk/api/messages-api.ts.html +11 -11
- package/coverage/lcov-report/node-sdk/api/mfaapi.ts.html +12 -12
- package/coverage/lcov-report/node-sdk/api/multi-channel-api.ts.html +10 -10
- package/coverage/lcov-report/node-sdk/api/phone-number-lookup-api.ts.html +12 -12
- package/coverage/lcov-report/node-sdk/api/recordings-api.ts.html +19 -19
- package/coverage/lcov-report/node-sdk/api/statistics-api.ts.html +10 -10
- package/coverage/lcov-report/node-sdk/api/toll-free-verification-api.ts.html +18 -18
- package/coverage/lcov-report/node-sdk/api/transcriptions-api.ts.html +12 -12
- package/coverage/lcov-report/node-sdk/api.ts.html +18 -15
- package/coverage/lcov-report/node-sdk/base.ts.html +104 -14
- package/coverage/lcov-report/node-sdk/common.ts.html +39 -39
- package/coverage/lcov-report/node-sdk/configuration.ts.html +26 -26
- package/coverage/lcov-report/node-sdk/index.html +7 -7
- package/coverage/lcov-report/node-sdk/models/business-entity-type-enum.ts.html +3 -3
- package/coverage/lcov-report/node-sdk/models/business-registration-type-enum.ts.html +3 -3
- package/coverage/lcov-report/node-sdk/models/bxml/Bxml.ts.html +4 -4
- package/coverage/lcov-report/node-sdk/models/bxml/NestableVerb.ts.html +23 -23
- package/coverage/lcov-report/node-sdk/models/bxml/Response.ts.html +4 -4
- package/coverage/lcov-report/node-sdk/models/bxml/Root.ts.html +8 -8
- package/coverage/lcov-report/node-sdk/models/bxml/Verb.ts.html +13 -13
- package/coverage/lcov-report/node-sdk/models/bxml/index.html +15 -15
- package/coverage/lcov-report/node-sdk/models/bxml/index.ts.html +3 -3
- package/coverage/lcov-report/node-sdk/models/bxml/verbs/Bridge.ts.html +4 -4
- package/coverage/lcov-report/node-sdk/models/bxml/verbs/Conference.ts.html +4 -4
- package/coverage/lcov-report/node-sdk/models/bxml/verbs/Connect.ts.html +184 -0
- package/coverage/lcov-report/node-sdk/models/bxml/verbs/CustomParam.ts.html +4 -4
- package/coverage/lcov-report/node-sdk/models/bxml/verbs/Endpoint.ts.html +142 -0
- package/coverage/lcov-report/node-sdk/models/bxml/verbs/Forward.ts.html +4 -4
- package/coverage/lcov-report/node-sdk/models/bxml/verbs/Gather.ts.html +7 -7
- package/coverage/lcov-report/node-sdk/models/bxml/verbs/Hangup.ts.html +4 -4
- package/coverage/lcov-report/node-sdk/models/bxml/verbs/Pause.ts.html +4 -4
- package/coverage/lcov-report/node-sdk/models/bxml/verbs/PauseRecording.ts.html +4 -4
- package/coverage/lcov-report/node-sdk/models/bxml/verbs/PhoneNumber.ts.html +4 -4
- package/coverage/lcov-report/node-sdk/models/bxml/verbs/PlayAudio.ts.html +4 -4
- package/coverage/lcov-report/node-sdk/models/bxml/verbs/Record.ts.html +4 -4
- package/coverage/lcov-report/node-sdk/models/bxml/verbs/Redirect.ts.html +4 -4
- package/coverage/lcov-report/node-sdk/models/bxml/verbs/ResumeRecording.ts.html +4 -4
- package/coverage/lcov-report/node-sdk/models/bxml/verbs/Ring.ts.html +4 -4
- package/coverage/lcov-report/node-sdk/models/bxml/verbs/SendDtmf.ts.html +4 -4
- package/coverage/lcov-report/node-sdk/models/bxml/verbs/SipUri.ts.html +4 -4
- package/coverage/lcov-report/node-sdk/models/bxml/verbs/SpeakSentence.ts.html +6 -6
- package/coverage/lcov-report/node-sdk/models/bxml/verbs/StartGather.ts.html +4 -4
- package/coverage/lcov-report/node-sdk/models/bxml/verbs/StartRecording.ts.html +4 -4
- package/coverage/lcov-report/node-sdk/models/bxml/verbs/StartStream.ts.html +5 -5
- package/coverage/lcov-report/node-sdk/models/bxml/verbs/StartTranscription.ts.html +5 -5
- package/coverage/lcov-report/node-sdk/models/bxml/verbs/StopGather.ts.html +4 -4
- package/coverage/lcov-report/node-sdk/models/bxml/verbs/StopRecording.ts.html +4 -4
- package/coverage/lcov-report/node-sdk/models/bxml/verbs/StopStream.ts.html +4 -4
- package/coverage/lcov-report/node-sdk/models/bxml/verbs/StopTranscription.ts.html +4 -4
- package/coverage/lcov-report/node-sdk/models/bxml/verbs/StreamParam.ts.html +4 -4
- package/coverage/lcov-report/node-sdk/models/bxml/verbs/Tag.ts.html +4 -4
- package/coverage/lcov-report/node-sdk/models/bxml/verbs/Transfer.ts.html +5 -5
- package/coverage/lcov-report/node-sdk/models/bxml/verbs/index.html +38 -8
- package/coverage/lcov-report/node-sdk/models/bxml/verbs/index.ts.html +39 -33
- package/coverage/lcov-report/node-sdk/models/call-direction-enum.ts.html +2 -2
- package/coverage/lcov-report/node-sdk/models/call-state-enum.ts.html +2 -2
- package/coverage/lcov-report/node-sdk/models/call-transcription-detected-language-enum.ts.html +2 -2
- package/coverage/lcov-report/node-sdk/models/call-transcription-track-enum.ts.html +2 -2
- package/coverage/lcov-report/node-sdk/models/callback-method-enum.ts.html +2 -2
- package/coverage/lcov-report/node-sdk/models/card-width-enum.ts.html +2 -2
- package/coverage/lcov-report/node-sdk/models/completed-lookup-status-enum.ts.html +2 -2
- package/coverage/lcov-report/node-sdk/models/conference-state-enum.ts.html +2 -2
- package/coverage/lcov-report/node-sdk/models/deactivation-event-enum.ts.html +2 -2
- package/coverage/lcov-report/node-sdk/models/device-status-enum.ts.html +163 -0
- package/coverage/lcov-report/node-sdk/models/{business-registration-issuing-country-enum.ts.html → endpoint-direction-enum.ts.html} +10 -61
- package/coverage/lcov-report/node-sdk/models/endpoint-event-type-enum.ts.html +163 -0
- package/coverage/lcov-report/node-sdk/models/endpoint-status-enum.ts.html +163 -0
- package/coverage/lcov-report/node-sdk/models/endpoint-type-enum.ts.html +160 -0
- package/coverage/lcov-report/node-sdk/models/file-format-enum.ts.html +2 -2
- package/coverage/lcov-report/node-sdk/models/in-progress-lookup-status-enum.ts.html +2 -2
- package/coverage/lcov-report/node-sdk/models/inbound-callback-type-enum.ts.html +3 -3
- package/coverage/lcov-report/node-sdk/models/index.html +76 -16
- package/coverage/lcov-report/node-sdk/models/index.ts.html +246 -183
- package/coverage/lcov-report/node-sdk/models/latest-message-delivery-status-enum.ts.html +2 -2
- package/coverage/lcov-report/node-sdk/models/line-type-enum.ts.html +2 -2
- package/coverage/lcov-report/node-sdk/models/list-message-direction-enum.ts.html +2 -2
- package/coverage/lcov-report/node-sdk/models/machine-detection-mode-enum.ts.html +2 -2
- package/coverage/lcov-report/node-sdk/models/message-direction-enum.ts.html +2 -2
- package/coverage/lcov-report/node-sdk/models/message-status-enum.ts.html +2 -2
- package/coverage/lcov-report/node-sdk/models/message-type-enum.ts.html +2 -2
- package/coverage/lcov-report/node-sdk/models/multi-channel-message-channel-enum.ts.html +2 -2
- package/coverage/lcov-report/node-sdk/models/priority-enum.ts.html +2 -2
- package/coverage/lcov-report/node-sdk/models/product-type-enum.ts.html +2 -2
- package/coverage/lcov-report/node-sdk/models/rbm-action-type-enum.ts.html +2 -2
- package/coverage/lcov-report/node-sdk/models/rbm-media-height-enum.ts.html +2 -2
- package/coverage/lcov-report/node-sdk/models/rbm-open-url-enum.ts.html +3 -3
- package/coverage/lcov-report/node-sdk/models/rbm-web-view-enum.ts.html +3 -3
- package/coverage/lcov-report/node-sdk/models/recording-state-enum.ts.html +2 -2
- package/coverage/lcov-report/node-sdk/models/redirect-method-enum.ts.html +2 -2
- package/coverage/lcov-report/node-sdk/models/standalone-card-orientation-enum.ts.html +2 -2
- package/coverage/lcov-report/node-sdk/models/status-callback-type-enum.ts.html +2 -2
- package/coverage/lcov-report/node-sdk/models/tfv-callback-status-enum.ts.html +2 -2
- package/coverage/lcov-report/node-sdk/models/tfv-status-enum.ts.html +2 -2
- package/coverage/lcov-report/node-sdk/models/thumbnail-alignment-enum.ts.html +2 -2
- package/coverage/lcov-report/node-sdk/models/webhook-subscription-type-enum.ts.html +2 -2
- package/coverage/lcov.info +1226 -764
- package/custom_templates/modelAllOf.mustache +14 -0
- package/dist/api/endpoints-api.d.ts +236 -0
- package/dist/api/endpoints-api.js +666 -0
- package/dist/api/media-api.d.ts +4 -4
- package/dist/api/media-api.js +4 -4
- package/dist/api.d.ts +1 -0
- package/dist/api.js +1 -0
- package/dist/base.js +30 -0
- package/dist/configuration.js +1 -1
- package/dist/models/brtc-error-response.d.ts +18 -0
- package/dist/models/brtc-error-source.d.ts +29 -0
- package/dist/models/brtc-error-source.js +15 -0
- package/dist/models/brtc-error.d.ts +31 -0
- package/dist/models/brtc-error.js +15 -0
- package/dist/models/brtc-link.d.ts +25 -0
- package/dist/models/brtc-link.js +15 -0
- package/dist/models/business-entity-type-enum.d.ts +1 -1
- package/dist/models/business-entity-type-enum.js +1 -1
- package/dist/models/business-registration-type-enum.d.ts +1 -1
- package/dist/models/business-registration-type-enum.js +1 -1
- package/dist/models/bxml/verbs/Connect.d.ts +25 -0
- package/dist/models/bxml/verbs/Connect.js +45 -0
- package/dist/models/bxml/verbs/Endpoint.d.ts +15 -0
- package/dist/models/bxml/verbs/Endpoint.js +37 -0
- package/dist/models/bxml/verbs/index.d.ts +2 -0
- package/dist/models/bxml/verbs/index.js +2 -0
- package/dist/models/create-call.d.ts +2 -2
- package/dist/models/create-endpoint-request-base.d.ts +29 -0
- package/dist/models/create-endpoint-request-base.js +15 -0
- package/dist/models/create-endpoint-response-data.d.ts +42 -0
- package/dist/models/create-endpoint-response-data.js +15 -0
- package/dist/models/create-endpoint-response.d.ts +19 -0
- package/dist/models/create-endpoint-response.js +15 -0
- package/dist/models/create-web-rtc-connection-request.d.ts +33 -0
- package/dist/models/create-web-rtc-connection-request.js +15 -0
- package/dist/models/device-status-enum.d.ts +16 -0
- package/dist/models/device-status-enum.js +20 -0
- package/dist/models/device.d.ts +27 -0
- package/dist/models/device.js +15 -0
- package/dist/models/endpoint-direction-enum.d.ts +17 -0
- package/dist/models/endpoint-direction-enum.js +21 -0
- package/dist/models/endpoint-event-type-enum.d.ts +16 -0
- package/dist/models/endpoint-event-type-enum.js +20 -0
- package/dist/models/endpoint-event.d.ts +45 -0
- package/dist/models/endpoint-event.js +15 -0
- package/dist/models/endpoint-response.d.ts +19 -0
- package/dist/models/endpoint-response.js +15 -0
- package/dist/models/endpoint-status-enum.d.ts +16 -0
- package/dist/models/endpoint-status-enum.js +20 -0
- package/dist/models/endpoint-type-enum.d.ts +15 -0
- package/dist/models/endpoint-type-enum.js +19 -0
- package/dist/models/endpoint.d.ts +38 -0
- package/dist/models/endpoint.js +15 -0
- package/dist/models/endpoints.d.ts +33 -0
- package/dist/models/endpoints.js +15 -0
- package/dist/models/inbound-callback-message.d.ts +48 -2
- package/dist/models/inbound-callback-type-enum.d.ts +1 -1
- package/dist/models/inbound-callback-type-enum.js +1 -1
- package/dist/models/inbound-callback.d.ts +2 -2
- package/dist/models/index.d.ts +23 -2
- package/dist/models/index.js +23 -2
- package/dist/models/list-endpoints-response.d.ts +21 -0
- package/dist/models/list-endpoints-response.js +15 -0
- package/dist/models/lookup-result.d.ts +1 -1
- package/dist/models/machine-detection-configuration.d.ts +1 -1
- package/dist/models/message-request.d.ts +1 -1
- package/dist/models/mms-message-content-file.d.ts +1 -1
- package/dist/models/multi-channel-action-calendar-event.d.ts +28 -2
- package/dist/models/multi-channel-channel-list-mmsobject.d.ts +14 -2
- package/dist/models/multi-channel-channel-list-mmsresponse-object.d.ts +18 -3
- package/dist/models/multi-channel-channel-list-rbmobject.d.ts +14 -2
- package/dist/models/multi-channel-channel-list-rbmresponse-object.d.ts +18 -3
- package/dist/models/multi-channel-channel-list-smsobject.d.ts +14 -2
- package/dist/models/multi-channel-channel-list-smsresponse-object.d.ts +18 -3
- package/dist/models/page.d.ts +29 -0
- package/dist/models/page.js +15 -0
- package/dist/models/rbm-action-dial.d.ts +16 -2
- package/dist/models/rbm-action-open-url.d.ts +20 -2
- package/dist/models/rbm-action-view-location.d.ts +24 -2
- package/dist/models/rbm-card-content-media.d.ts +12 -2
- package/dist/models/rbm-open-url-enum.d.ts +1 -1
- package/dist/models/rbm-open-url-enum.js +1 -1
- package/dist/models/rbm-web-view-enum.d.ts +1 -1
- package/dist/models/rbm-web-view-enum.js +1 -1
- package/dist/models/sip-connection-metadata.d.ts +27 -0
- package/dist/models/sip-connection-metadata.js +15 -0
- package/dist/models/sip-credentials.d.ts +21 -0
- package/dist/models/sip-credentials.js +15 -0
- package/dist/models/status-callback.d.ts +1 -1
- package/dist/models/tfv-submission-info.d.ts +5 -3
- package/dist/models/update-call.d.ts +1 -1
- package/dist/models/verification-request.d.ts +5 -3
- package/dist/models/verification-update-request.d.ts +5 -3
- package/dist/models/{model-error.d.ts → webhook-subscription-error.d.ts} +1 -1
- package/dist/models/webhook-subscription-error.js +15 -0
- package/dist/models/webhook-subscriptions-list-body.d.ts +2 -2
- package/docs/BrtcError.md +28 -0
- package/docs/BrtcErrorResponse.md +24 -0
- package/docs/BrtcErrorSource.md +26 -0
- package/docs/BrtcLink.md +24 -0
- package/docs/BusinessEntityTypeEnum.md +1 -1
- package/docs/BusinessRegistrationTypeEnum.md +1 -1
- package/docs/Callback.md +2 -2
- package/docs/CreateCall.md +2 -2
- package/docs/CreateEndpointRequestBase.md +28 -0
- package/docs/CreateEndpointResponse.md +24 -0
- package/docs/CreateEndpointResponseData.md +34 -0
- package/docs/CreateWebRtcConnectionRequest.md +30 -0
- package/docs/Device.md +26 -0
- package/docs/DeviceStatusEnum.md +10 -0
- package/docs/Endpoint.md +32 -0
- package/docs/EndpointDirectionEnum.md +12 -0
- package/docs/EndpointEvent.md +37 -0
- package/docs/EndpointEventTypeEnum.md +10 -0
- package/docs/EndpointResponse.md +24 -0
- package/docs/EndpointStatusEnum.md +10 -0
- package/docs/EndpointTypeEnum.md +8 -0
- package/docs/Endpoints.md +30 -0
- package/docs/EndpointsApi.md +334 -0
- package/docs/InboundCallback.md +2 -2
- package/docs/InboundCallbackTypeEnum.md +1 -1
- package/docs/ListEndpointsResponse.md +26 -0
- package/docs/LookupResult.md +1 -1
- package/docs/MachineDetectionConfiguration.md +1 -1
- package/docs/MediaApi.md +1 -1
- package/docs/MessageRequest.md +1 -1
- package/docs/MmsMessageContentFile.md +1 -1
- package/docs/Page.md +26 -0
- package/docs/RbmOpenUrlEnum.md +1 -1
- package/docs/RbmWebViewEnum.md +1 -1
- package/docs/SipConnectionMetadata.md +26 -0
- package/docs/SipCredentials.md +22 -0
- package/docs/StatusCallback.md +1 -1
- package/docs/TfvSubmissionInfo.md +2 -2
- package/docs/UpdateCall.md +1 -1
- package/docs/VerificationRequest.md +2 -2
- package/docs/VerificationUpdateRequest.md +2 -2
- package/docs/{Error.md → WebhookSubscriptionError.md} +3 -3
- package/docs/WebhookSubscriptionsListBody.md +1 -1
- package/models/brtc-error-response.ts +28 -0
- package/models/brtc-error-source.ts +35 -0
- package/models/brtc-error.ts +39 -0
- package/models/brtc-link.ts +31 -0
- package/models/business-entity-type-enum.ts +1 -1
- package/models/business-registration-type-enum.ts +1 -1
- package/models/bxml/verbs/Connect.ts +33 -0
- package/models/bxml/verbs/Endpoint.ts +19 -0
- package/models/bxml/verbs/index.ts +2 -0
- package/models/create-call.ts +2 -2
- package/models/create-endpoint-request-base.ts +41 -0
- package/models/create-endpoint-response-data.ts +58 -0
- package/models/create-endpoint-response.ts +31 -0
- package/models/create-web-rtc-connection-request.ts +47 -0
- package/models/device-status-enum.ts +26 -0
- package/models/device.ts +37 -0
- package/models/endpoint-direction-enum.ts +27 -0
- package/models/endpoint-event-type-enum.ts +26 -0
- package/models/endpoint-event.ts +63 -0
- package/models/endpoint-response.ts +31 -0
- package/models/endpoint-status-enum.ts +26 -0
- package/models/endpoint-type-enum.ts +25 -0
- package/models/endpoint.ts +54 -0
- package/models/endpoints.ts +45 -0
- package/models/inbound-callback-message.ts +42 -1
- package/models/inbound-callback-type-enum.ts +1 -1
- package/models/inbound-callback.ts +2 -2
- package/models/index.ts +23 -2
- package/models/list-endpoints-response.ts +35 -0
- package/models/lookup-result.ts +1 -1
- package/models/machine-detection-configuration.ts +1 -1
- package/models/message-request.ts +1 -1
- package/models/mms-message-content-file.ts +1 -1
- package/models/multi-channel-action-calendar-event.ts +27 -1
- package/models/multi-channel-channel-list-mmsobject.ts +12 -1
- package/models/multi-channel-channel-list-mmsresponse-object.ts +16 -1
- package/models/multi-channel-channel-list-rbmobject.ts +12 -1
- package/models/multi-channel-channel-list-rbmresponse-object.ts +16 -1
- package/models/multi-channel-channel-list-smsobject.ts +12 -1
- package/models/multi-channel-channel-list-smsresponse-object.ts +16 -1
- package/models/page.ts +35 -0
- package/models/rbm-action-dial.ts +15 -1
- package/models/rbm-action-open-url.ts +17 -1
- package/models/rbm-action-view-location.ts +23 -1
- package/models/rbm-card-content-media.ts +11 -1
- package/models/rbm-open-url-enum.ts +1 -1
- package/models/rbm-web-view-enum.ts +1 -1
- package/models/sip-connection-metadata.ts +35 -0
- package/models/sip-credentials.ts +27 -0
- package/models/status-callback.ts +1 -1
- package/models/tfv-submission-info.ts +5 -5
- package/models/update-call.ts +1 -1
- package/models/verification-request.ts +5 -5
- package/models/verification-update-request.ts +5 -5
- package/models/{model-error.ts → webhook-subscription-error.ts} +1 -1
- package/models/webhook-subscriptions-list-body.ts +3 -3
- package/package.json +1 -1
- package/tests/smoke/endpoints-api.test.ts +141 -0
- package/tests/smoke/phone-number-lookup-api.test.ts +2 -10
- package/tests/unit/api/endpoints-api.test.ts +106 -0
- package/tests/unit/api/toll-free-verification-api.test.ts +1 -1
- package/tests/unit/models/brtc-error-response.test.ts +50 -0
- package/tests/unit/models/brtc-error-source.test.ts +17 -0
- package/tests/unit/models/brtc-error.test.ts +30 -0
- package/tests/unit/models/brtc-link.test.ts +15 -0
- package/tests/unit/models/bxml/verbs/Connect.test.ts +47 -0
- package/tests/unit/models/bxml/verbs/Endpoint.test.ts +12 -0
- package/tests/unit/models/create-endpoint-request-base.test.ts +21 -0
- package/tests/unit/models/create-endpoint-response-data.test.ts +44 -0
- package/tests/unit/models/create-endpoint-response.test.ts +86 -0
- package/tests/unit/models/create-web-rtc-connection-request.test.ts +21 -0
- package/tests/unit/models/device-status-enum.test.ts +12 -0
- package/tests/unit/models/device.test.ts +19 -0
- package/tests/unit/models/endpoint-direction-enum.test.ts +14 -0
- package/tests/unit/models/endpoint-event-type-enum.test.ts +12 -0
- package/tests/unit/models/endpoint-event.test.ts +44 -0
- package/tests/unit/models/endpoint-response.test.ts +84 -0
- package/tests/unit/models/endpoint-status-enum.test.ts +12 -0
- package/tests/unit/models/endpoint-type-enum.test.ts +10 -0
- package/tests/unit/models/endpoint.test.ts +50 -0
- package/tests/unit/models/endpoints.test.ts +25 -0
- package/tests/unit/models/list-endpoints-response.test.ts +94 -0
- package/tests/unit/models/page.test.ts +17 -0
- package/tests/unit/models/sip-connection-metadata.test.ts +25 -0
- package/tests/unit/models/sip-credentials.test.ts +13 -0
- package/dist/models/business-registration-issuing-country-enum.d.ts +0 -34
- package/dist/models/business-registration-issuing-country-enum.js +0 -38
- package/docs/BusinessRegistrationIssuingCountryEnum.md +0 -41
- package/models/business-registration-issuing-country-enum.ts +0 -44
- package/tests/unit/models/business-registration-issuing-country-enum.test.ts +0 -23
- /package/dist/models/{model-error.js → brtc-error-response.js} +0 -0
|
@@ -0,0 +1,666 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
/**
|
|
5
|
+
* Bandwidth
|
|
6
|
+
* Bandwidth\'s Communication APIs
|
|
7
|
+
*
|
|
8
|
+
* The version of the OpenAPI document: 1.0.0
|
|
9
|
+
* Contact: letstalk@bandwidth.com
|
|
10
|
+
*
|
|
11
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
12
|
+
* https://openapi-generator.tech
|
|
13
|
+
* Do not edit the class manually.
|
|
14
|
+
*/
|
|
15
|
+
var __extends = (this && this.__extends) || (function () {
|
|
16
|
+
var extendStatics = function (d, b) {
|
|
17
|
+
extendStatics = Object.setPrototypeOf ||
|
|
18
|
+
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
19
|
+
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
20
|
+
return extendStatics(d, b);
|
|
21
|
+
};
|
|
22
|
+
return function (d, b) {
|
|
23
|
+
if (typeof b !== "function" && b !== null)
|
|
24
|
+
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
|
|
25
|
+
extendStatics(d, b);
|
|
26
|
+
function __() { this.constructor = d; }
|
|
27
|
+
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
28
|
+
};
|
|
29
|
+
})();
|
|
30
|
+
var __assign = (this && this.__assign) || function () {
|
|
31
|
+
__assign = Object.assign || function(t) {
|
|
32
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
33
|
+
s = arguments[i];
|
|
34
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
35
|
+
t[p] = s[p];
|
|
36
|
+
}
|
|
37
|
+
return t;
|
|
38
|
+
};
|
|
39
|
+
return __assign.apply(this, arguments);
|
|
40
|
+
};
|
|
41
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
42
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
43
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
44
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
45
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
46
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
47
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
48
|
+
});
|
|
49
|
+
};
|
|
50
|
+
var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
51
|
+
var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g = Object.create((typeof Iterator === "function" ? Iterator : Object).prototype);
|
|
52
|
+
return g.next = verb(0), g["throw"] = verb(1), g["return"] = verb(2), typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
|
53
|
+
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
54
|
+
function step(op) {
|
|
55
|
+
if (f) throw new TypeError("Generator is already executing.");
|
|
56
|
+
while (g && (g = 0, op[0] && (_ = 0)), _) try {
|
|
57
|
+
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
|
|
58
|
+
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
59
|
+
switch (op[0]) {
|
|
60
|
+
case 0: case 1: t = op; break;
|
|
61
|
+
case 4: _.label++; return { value: op[1], done: false };
|
|
62
|
+
case 5: _.label++; y = op[1]; op = [0]; continue;
|
|
63
|
+
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
|
64
|
+
default:
|
|
65
|
+
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
|
66
|
+
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
|
67
|
+
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
|
68
|
+
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
|
69
|
+
if (t[2]) _.ops.pop();
|
|
70
|
+
_.trys.pop(); continue;
|
|
71
|
+
}
|
|
72
|
+
op = body.call(thisArg, _);
|
|
73
|
+
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
|
74
|
+
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
75
|
+
}
|
|
76
|
+
};
|
|
77
|
+
var __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {
|
|
78
|
+
if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {
|
|
79
|
+
if (ar || !(i in from)) {
|
|
80
|
+
if (!ar) ar = Array.prototype.slice.call(from, 0, i);
|
|
81
|
+
ar[i] = from[i];
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
return to.concat(ar || Array.prototype.slice.call(from));
|
|
85
|
+
};
|
|
86
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
87
|
+
exports.EndpointsApi = exports.EndpointsApiFactory = exports.EndpointsApiFp = exports.EndpointsApiAxiosParamCreator = void 0;
|
|
88
|
+
var axios_1 = require("axios");
|
|
89
|
+
// Some imports not used depending on template conditions
|
|
90
|
+
// @ts-ignore
|
|
91
|
+
var common_1 = require("../common");
|
|
92
|
+
// @ts-ignore
|
|
93
|
+
var base_1 = require("../base");
|
|
94
|
+
/**
|
|
95
|
+
* EndpointsApi - axios parameter creator
|
|
96
|
+
*/
|
|
97
|
+
var EndpointsApiAxiosParamCreator = function (configuration) {
|
|
98
|
+
var _this = this;
|
|
99
|
+
return {
|
|
100
|
+
/**
|
|
101
|
+
* Creates a new Endpoint for the specified account.
|
|
102
|
+
* @summary Create Endpoint
|
|
103
|
+
* @param {string} accountId Your Bandwidth Account ID.
|
|
104
|
+
* @param {CreateWebRtcConnectionRequest} body
|
|
105
|
+
* @param {*} [options] Override http request option.
|
|
106
|
+
* @throws {RequiredError}
|
|
107
|
+
*/
|
|
108
|
+
createEndpoint: function (accountId_1, body_1) {
|
|
109
|
+
var args_1 = [];
|
|
110
|
+
for (var _i = 2; _i < arguments.length; _i++) {
|
|
111
|
+
args_1[_i - 2] = arguments[_i];
|
|
112
|
+
}
|
|
113
|
+
return __awaiter(_this, __spreadArray([accountId_1, body_1], args_1, true), void 0, function (accountId, body, options) {
|
|
114
|
+
var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
115
|
+
if (options === void 0) { options = {}; }
|
|
116
|
+
return __generator(this, function (_a) {
|
|
117
|
+
switch (_a.label) {
|
|
118
|
+
case 0:
|
|
119
|
+
// verify required parameter 'accountId' is not null or undefined
|
|
120
|
+
(0, common_1.assertParamExists)('createEndpoint', 'accountId', accountId);
|
|
121
|
+
// verify required parameter 'body' is not null or undefined
|
|
122
|
+
(0, common_1.assertParamExists)('createEndpoint', 'body', body);
|
|
123
|
+
localVarPath = "/accounts/{accountId}/endpoints"
|
|
124
|
+
.replace("{".concat("accountId", "}"), encodeURIComponent(String(accountId)));
|
|
125
|
+
localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
126
|
+
if (configuration) {
|
|
127
|
+
baseOptions = configuration.baseOptions;
|
|
128
|
+
}
|
|
129
|
+
localVarRequestOptions = __assign(__assign({ method: 'POST' }, baseOptions), options);
|
|
130
|
+
localVarHeaderParameter = {};
|
|
131
|
+
localVarQueryParameter = {};
|
|
132
|
+
// authentication Basic required
|
|
133
|
+
// http basic authentication required
|
|
134
|
+
(0, common_1.setBasicAuthToObject)(localVarRequestOptions, configuration);
|
|
135
|
+
// authentication OAuth2 required
|
|
136
|
+
// oauth required
|
|
137
|
+
return [4 /*yield*/, (0, common_1.setOAuthToObject)(localVarHeaderParameter, "OAuth2", [], configuration)];
|
|
138
|
+
case 1:
|
|
139
|
+
// authentication OAuth2 required
|
|
140
|
+
// oauth required
|
|
141
|
+
_a.sent();
|
|
142
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
143
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
144
|
+
headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
145
|
+
localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
146
|
+
localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(body, localVarRequestOptions, configuration);
|
|
147
|
+
return [2 /*return*/, {
|
|
148
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
149
|
+
options: localVarRequestOptions,
|
|
150
|
+
}];
|
|
151
|
+
}
|
|
152
|
+
});
|
|
153
|
+
});
|
|
154
|
+
},
|
|
155
|
+
/**
|
|
156
|
+
* Deletes the specified endpoint. If the endpoint is actively streaming media, the media stream will be terminated.
|
|
157
|
+
* @summary Delete Endpoint
|
|
158
|
+
* @param {string} accountId Your Bandwidth Account ID.
|
|
159
|
+
* @param {string} endpointId BRTC Endpoint ID.
|
|
160
|
+
* @param {*} [options] Override http request option.
|
|
161
|
+
* @throws {RequiredError}
|
|
162
|
+
*/
|
|
163
|
+
deleteEndpoint: function (accountId_1, endpointId_1) {
|
|
164
|
+
var args_1 = [];
|
|
165
|
+
for (var _i = 2; _i < arguments.length; _i++) {
|
|
166
|
+
args_1[_i - 2] = arguments[_i];
|
|
167
|
+
}
|
|
168
|
+
return __awaiter(_this, __spreadArray([accountId_1, endpointId_1], args_1, true), void 0, function (accountId, endpointId, options) {
|
|
169
|
+
var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
170
|
+
if (options === void 0) { options = {}; }
|
|
171
|
+
return __generator(this, function (_a) {
|
|
172
|
+
switch (_a.label) {
|
|
173
|
+
case 0:
|
|
174
|
+
// verify required parameter 'accountId' is not null or undefined
|
|
175
|
+
(0, common_1.assertParamExists)('deleteEndpoint', 'accountId', accountId);
|
|
176
|
+
// verify required parameter 'endpointId' is not null or undefined
|
|
177
|
+
(0, common_1.assertParamExists)('deleteEndpoint', 'endpointId', endpointId);
|
|
178
|
+
localVarPath = "/accounts/{accountId}/endpoints/{endpointId}"
|
|
179
|
+
.replace("{".concat("accountId", "}"), encodeURIComponent(String(accountId)))
|
|
180
|
+
.replace("{".concat("endpointId", "}"), encodeURIComponent(String(endpointId)));
|
|
181
|
+
localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
182
|
+
if (configuration) {
|
|
183
|
+
baseOptions = configuration.baseOptions;
|
|
184
|
+
}
|
|
185
|
+
localVarRequestOptions = __assign(__assign({ method: 'DELETE' }, baseOptions), options);
|
|
186
|
+
localVarHeaderParameter = {};
|
|
187
|
+
localVarQueryParameter = {};
|
|
188
|
+
// authentication Basic required
|
|
189
|
+
// http basic authentication required
|
|
190
|
+
(0, common_1.setBasicAuthToObject)(localVarRequestOptions, configuration);
|
|
191
|
+
// authentication OAuth2 required
|
|
192
|
+
// oauth required
|
|
193
|
+
return [4 /*yield*/, (0, common_1.setOAuthToObject)(localVarHeaderParameter, "OAuth2", [], configuration)];
|
|
194
|
+
case 1:
|
|
195
|
+
// authentication OAuth2 required
|
|
196
|
+
// oauth required
|
|
197
|
+
_a.sent();
|
|
198
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
199
|
+
headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
200
|
+
localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
201
|
+
return [2 /*return*/, {
|
|
202
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
203
|
+
options: localVarRequestOptions,
|
|
204
|
+
}];
|
|
205
|
+
}
|
|
206
|
+
});
|
|
207
|
+
});
|
|
208
|
+
},
|
|
209
|
+
/**
|
|
210
|
+
* Returns information about the specified endpoint.
|
|
211
|
+
* @summary Get Endpoint
|
|
212
|
+
* @param {string} accountId Your Bandwidth Account ID.
|
|
213
|
+
* @param {string} endpointId BRTC Endpoint ID.
|
|
214
|
+
* @param {*} [options] Override http request option.
|
|
215
|
+
* @throws {RequiredError}
|
|
216
|
+
*/
|
|
217
|
+
getEndpoint: function (accountId_1, endpointId_1) {
|
|
218
|
+
var args_1 = [];
|
|
219
|
+
for (var _i = 2; _i < arguments.length; _i++) {
|
|
220
|
+
args_1[_i - 2] = arguments[_i];
|
|
221
|
+
}
|
|
222
|
+
return __awaiter(_this, __spreadArray([accountId_1, endpointId_1], args_1, true), void 0, function (accountId, endpointId, options) {
|
|
223
|
+
var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
224
|
+
if (options === void 0) { options = {}; }
|
|
225
|
+
return __generator(this, function (_a) {
|
|
226
|
+
switch (_a.label) {
|
|
227
|
+
case 0:
|
|
228
|
+
// verify required parameter 'accountId' is not null or undefined
|
|
229
|
+
(0, common_1.assertParamExists)('getEndpoint', 'accountId', accountId);
|
|
230
|
+
// verify required parameter 'endpointId' is not null or undefined
|
|
231
|
+
(0, common_1.assertParamExists)('getEndpoint', 'endpointId', endpointId);
|
|
232
|
+
localVarPath = "/accounts/{accountId}/endpoints/{endpointId}"
|
|
233
|
+
.replace("{".concat("accountId", "}"), encodeURIComponent(String(accountId)))
|
|
234
|
+
.replace("{".concat("endpointId", "}"), encodeURIComponent(String(endpointId)));
|
|
235
|
+
localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
236
|
+
if (configuration) {
|
|
237
|
+
baseOptions = configuration.baseOptions;
|
|
238
|
+
}
|
|
239
|
+
localVarRequestOptions = __assign(__assign({ method: 'GET' }, baseOptions), options);
|
|
240
|
+
localVarHeaderParameter = {};
|
|
241
|
+
localVarQueryParameter = {};
|
|
242
|
+
// authentication Basic required
|
|
243
|
+
// http basic authentication required
|
|
244
|
+
(0, common_1.setBasicAuthToObject)(localVarRequestOptions, configuration);
|
|
245
|
+
// authentication OAuth2 required
|
|
246
|
+
// oauth required
|
|
247
|
+
return [4 /*yield*/, (0, common_1.setOAuthToObject)(localVarHeaderParameter, "OAuth2", [], configuration)];
|
|
248
|
+
case 1:
|
|
249
|
+
// authentication OAuth2 required
|
|
250
|
+
// oauth required
|
|
251
|
+
_a.sent();
|
|
252
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
253
|
+
headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
254
|
+
localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
255
|
+
return [2 /*return*/, {
|
|
256
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
257
|
+
options: localVarRequestOptions,
|
|
258
|
+
}];
|
|
259
|
+
}
|
|
260
|
+
});
|
|
261
|
+
});
|
|
262
|
+
},
|
|
263
|
+
/**
|
|
264
|
+
* Returns a list of endpoints associated with the specified account.
|
|
265
|
+
* @summary List Endpoints
|
|
266
|
+
* @param {string} accountId Your Bandwidth Account ID.
|
|
267
|
+
* @param {EndpointTypeEnum} [type] The type of endpoint.
|
|
268
|
+
* @param {EndpointStatusEnum} [status] The status of the endpoint.
|
|
269
|
+
* @param {string} [afterCursor] The cursor to use for pagination. This is the value of the `next` link in the previous response.
|
|
270
|
+
* @param {number} [limit] The maximum number of endpoints to return in the response.
|
|
271
|
+
* @param {*} [options] Override http request option.
|
|
272
|
+
* @throws {RequiredError}
|
|
273
|
+
*/
|
|
274
|
+
listEndpoints: function (accountId_1, type_1, status_1, afterCursor_1, limit_1) {
|
|
275
|
+
var args_1 = [];
|
|
276
|
+
for (var _i = 5; _i < arguments.length; _i++) {
|
|
277
|
+
args_1[_i - 5] = arguments[_i];
|
|
278
|
+
}
|
|
279
|
+
return __awaiter(_this, __spreadArray([accountId_1, type_1, status_1, afterCursor_1, limit_1], args_1, true), void 0, function (accountId, type, status, afterCursor, limit, options) {
|
|
280
|
+
var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
281
|
+
if (options === void 0) { options = {}; }
|
|
282
|
+
return __generator(this, function (_a) {
|
|
283
|
+
switch (_a.label) {
|
|
284
|
+
case 0:
|
|
285
|
+
// verify required parameter 'accountId' is not null or undefined
|
|
286
|
+
(0, common_1.assertParamExists)('listEndpoints', 'accountId', accountId);
|
|
287
|
+
localVarPath = "/accounts/{accountId}/endpoints"
|
|
288
|
+
.replace("{".concat("accountId", "}"), encodeURIComponent(String(accountId)));
|
|
289
|
+
localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
290
|
+
if (configuration) {
|
|
291
|
+
baseOptions = configuration.baseOptions;
|
|
292
|
+
}
|
|
293
|
+
localVarRequestOptions = __assign(__assign({ method: 'GET' }, baseOptions), options);
|
|
294
|
+
localVarHeaderParameter = {};
|
|
295
|
+
localVarQueryParameter = {};
|
|
296
|
+
// authentication Basic required
|
|
297
|
+
// http basic authentication required
|
|
298
|
+
(0, common_1.setBasicAuthToObject)(localVarRequestOptions, configuration);
|
|
299
|
+
// authentication OAuth2 required
|
|
300
|
+
// oauth required
|
|
301
|
+
return [4 /*yield*/, (0, common_1.setOAuthToObject)(localVarHeaderParameter, "OAuth2", [], configuration)];
|
|
302
|
+
case 1:
|
|
303
|
+
// authentication OAuth2 required
|
|
304
|
+
// oauth required
|
|
305
|
+
_a.sent();
|
|
306
|
+
if (type !== undefined) {
|
|
307
|
+
localVarQueryParameter['type'] = type;
|
|
308
|
+
}
|
|
309
|
+
if (status !== undefined) {
|
|
310
|
+
localVarQueryParameter['status'] = status;
|
|
311
|
+
}
|
|
312
|
+
if (afterCursor !== undefined) {
|
|
313
|
+
localVarQueryParameter['afterCursor'] = afterCursor;
|
|
314
|
+
}
|
|
315
|
+
if (limit !== undefined) {
|
|
316
|
+
localVarQueryParameter['limit'] = limit;
|
|
317
|
+
}
|
|
318
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
319
|
+
headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
320
|
+
localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
321
|
+
return [2 /*return*/, {
|
|
322
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
323
|
+
options: localVarRequestOptions,
|
|
324
|
+
}];
|
|
325
|
+
}
|
|
326
|
+
});
|
|
327
|
+
});
|
|
328
|
+
},
|
|
329
|
+
/**
|
|
330
|
+
* Updates the BXML for the specified endpoint.
|
|
331
|
+
* @summary Update Endpoint BXML
|
|
332
|
+
* @param {string} accountId Your Bandwidth Account ID.
|
|
333
|
+
* @param {string} endpointId BRTC Endpoint ID.
|
|
334
|
+
* @param {string} body
|
|
335
|
+
* @param {*} [options] Override http request option.
|
|
336
|
+
* @throws {RequiredError}
|
|
337
|
+
*/
|
|
338
|
+
updateEndpointBxml: function (accountId_1, endpointId_1, body_1) {
|
|
339
|
+
var args_1 = [];
|
|
340
|
+
for (var _i = 3; _i < arguments.length; _i++) {
|
|
341
|
+
args_1[_i - 3] = arguments[_i];
|
|
342
|
+
}
|
|
343
|
+
return __awaiter(_this, __spreadArray([accountId_1, endpointId_1, body_1], args_1, true), void 0, function (accountId, endpointId, body, options) {
|
|
344
|
+
var localVarPath, localVarUrlObj, baseOptions, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
345
|
+
if (options === void 0) { options = {}; }
|
|
346
|
+
return __generator(this, function (_a) {
|
|
347
|
+
switch (_a.label) {
|
|
348
|
+
case 0:
|
|
349
|
+
// verify required parameter 'accountId' is not null or undefined
|
|
350
|
+
(0, common_1.assertParamExists)('updateEndpointBxml', 'accountId', accountId);
|
|
351
|
+
// verify required parameter 'endpointId' is not null or undefined
|
|
352
|
+
(0, common_1.assertParamExists)('updateEndpointBxml', 'endpointId', endpointId);
|
|
353
|
+
// verify required parameter 'body' is not null or undefined
|
|
354
|
+
(0, common_1.assertParamExists)('updateEndpointBxml', 'body', body);
|
|
355
|
+
localVarPath = "/accounts/{accountId}/endpoints/{endpointId}/bxml"
|
|
356
|
+
.replace("{".concat("accountId", "}"), encodeURIComponent(String(accountId)))
|
|
357
|
+
.replace("{".concat("endpointId", "}"), encodeURIComponent(String(endpointId)));
|
|
358
|
+
localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
359
|
+
if (configuration) {
|
|
360
|
+
baseOptions = configuration.baseOptions;
|
|
361
|
+
}
|
|
362
|
+
localVarRequestOptions = __assign(__assign({ method: 'PUT' }, baseOptions), options);
|
|
363
|
+
localVarHeaderParameter = {};
|
|
364
|
+
localVarQueryParameter = {};
|
|
365
|
+
// authentication Basic required
|
|
366
|
+
// http basic authentication required
|
|
367
|
+
(0, common_1.setBasicAuthToObject)(localVarRequestOptions, configuration);
|
|
368
|
+
// authentication OAuth2 required
|
|
369
|
+
// oauth required
|
|
370
|
+
return [4 /*yield*/, (0, common_1.setOAuthToObject)(localVarHeaderParameter, "OAuth2", [], configuration)];
|
|
371
|
+
case 1:
|
|
372
|
+
// authentication OAuth2 required
|
|
373
|
+
// oauth required
|
|
374
|
+
_a.sent();
|
|
375
|
+
localVarHeaderParameter['Content-Type'] = 'application/xml';
|
|
376
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
377
|
+
headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
378
|
+
localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
379
|
+
localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(body, localVarRequestOptions, configuration);
|
|
380
|
+
return [2 /*return*/, {
|
|
381
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
382
|
+
options: localVarRequestOptions,
|
|
383
|
+
}];
|
|
384
|
+
}
|
|
385
|
+
});
|
|
386
|
+
});
|
|
387
|
+
},
|
|
388
|
+
};
|
|
389
|
+
};
|
|
390
|
+
exports.EndpointsApiAxiosParamCreator = EndpointsApiAxiosParamCreator;
|
|
391
|
+
/**
|
|
392
|
+
* EndpointsApi - functional programming interface
|
|
393
|
+
*/
|
|
394
|
+
var EndpointsApiFp = function (configuration) {
|
|
395
|
+
var localVarAxiosParamCreator = (0, exports.EndpointsApiAxiosParamCreator)(configuration);
|
|
396
|
+
return {
|
|
397
|
+
/**
|
|
398
|
+
* Creates a new Endpoint for the specified account.
|
|
399
|
+
* @summary Create Endpoint
|
|
400
|
+
* @param {string} accountId Your Bandwidth Account ID.
|
|
401
|
+
* @param {CreateWebRtcConnectionRequest} body
|
|
402
|
+
* @param {*} [options] Override http request option.
|
|
403
|
+
* @throws {RequiredError}
|
|
404
|
+
*/
|
|
405
|
+
createEndpoint: function (accountId, body, options) {
|
|
406
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
407
|
+
var localVarAxiosArgs, localVarOperationServerIndex, localVarOperationServerBasePath;
|
|
408
|
+
var _a, _b, _c;
|
|
409
|
+
return __generator(this, function (_d) {
|
|
410
|
+
switch (_d.label) {
|
|
411
|
+
case 0: return [4 /*yield*/, localVarAxiosParamCreator.createEndpoint(accountId, body, options)];
|
|
412
|
+
case 1:
|
|
413
|
+
localVarAxiosArgs = _d.sent();
|
|
414
|
+
localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
415
|
+
localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['EndpointsApi.createEndpoint']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
416
|
+
return [2 /*return*/, function (axios, basePath) { return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }];
|
|
417
|
+
}
|
|
418
|
+
});
|
|
419
|
+
});
|
|
420
|
+
},
|
|
421
|
+
/**
|
|
422
|
+
* Deletes the specified endpoint. If the endpoint is actively streaming media, the media stream will be terminated.
|
|
423
|
+
* @summary Delete Endpoint
|
|
424
|
+
* @param {string} accountId Your Bandwidth Account ID.
|
|
425
|
+
* @param {string} endpointId BRTC Endpoint ID.
|
|
426
|
+
* @param {*} [options] Override http request option.
|
|
427
|
+
* @throws {RequiredError}
|
|
428
|
+
*/
|
|
429
|
+
deleteEndpoint: function (accountId, endpointId, options) {
|
|
430
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
431
|
+
var localVarAxiosArgs, localVarOperationServerIndex, localVarOperationServerBasePath;
|
|
432
|
+
var _a, _b, _c;
|
|
433
|
+
return __generator(this, function (_d) {
|
|
434
|
+
switch (_d.label) {
|
|
435
|
+
case 0: return [4 /*yield*/, localVarAxiosParamCreator.deleteEndpoint(accountId, endpointId, options)];
|
|
436
|
+
case 1:
|
|
437
|
+
localVarAxiosArgs = _d.sent();
|
|
438
|
+
localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
439
|
+
localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['EndpointsApi.deleteEndpoint']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
440
|
+
return [2 /*return*/, function (axios, basePath) { return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }];
|
|
441
|
+
}
|
|
442
|
+
});
|
|
443
|
+
});
|
|
444
|
+
},
|
|
445
|
+
/**
|
|
446
|
+
* Returns information about the specified endpoint.
|
|
447
|
+
* @summary Get Endpoint
|
|
448
|
+
* @param {string} accountId Your Bandwidth Account ID.
|
|
449
|
+
* @param {string} endpointId BRTC Endpoint ID.
|
|
450
|
+
* @param {*} [options] Override http request option.
|
|
451
|
+
* @throws {RequiredError}
|
|
452
|
+
*/
|
|
453
|
+
getEndpoint: function (accountId, endpointId, options) {
|
|
454
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
455
|
+
var localVarAxiosArgs, localVarOperationServerIndex, localVarOperationServerBasePath;
|
|
456
|
+
var _a, _b, _c;
|
|
457
|
+
return __generator(this, function (_d) {
|
|
458
|
+
switch (_d.label) {
|
|
459
|
+
case 0: return [4 /*yield*/, localVarAxiosParamCreator.getEndpoint(accountId, endpointId, options)];
|
|
460
|
+
case 1:
|
|
461
|
+
localVarAxiosArgs = _d.sent();
|
|
462
|
+
localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
463
|
+
localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['EndpointsApi.getEndpoint']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
464
|
+
return [2 /*return*/, function (axios, basePath) { return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }];
|
|
465
|
+
}
|
|
466
|
+
});
|
|
467
|
+
});
|
|
468
|
+
},
|
|
469
|
+
/**
|
|
470
|
+
* Returns a list of endpoints associated with the specified account.
|
|
471
|
+
* @summary List Endpoints
|
|
472
|
+
* @param {string} accountId Your Bandwidth Account ID.
|
|
473
|
+
* @param {EndpointTypeEnum} [type] The type of endpoint.
|
|
474
|
+
* @param {EndpointStatusEnum} [status] The status of the endpoint.
|
|
475
|
+
* @param {string} [afterCursor] The cursor to use for pagination. This is the value of the `next` link in the previous response.
|
|
476
|
+
* @param {number} [limit] The maximum number of endpoints to return in the response.
|
|
477
|
+
* @param {*} [options] Override http request option.
|
|
478
|
+
* @throws {RequiredError}
|
|
479
|
+
*/
|
|
480
|
+
listEndpoints: function (accountId, type, status, afterCursor, limit, options) {
|
|
481
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
482
|
+
var localVarAxiosArgs, localVarOperationServerIndex, localVarOperationServerBasePath;
|
|
483
|
+
var _a, _b, _c;
|
|
484
|
+
return __generator(this, function (_d) {
|
|
485
|
+
switch (_d.label) {
|
|
486
|
+
case 0: return [4 /*yield*/, localVarAxiosParamCreator.listEndpoints(accountId, type, status, afterCursor, limit, options)];
|
|
487
|
+
case 1:
|
|
488
|
+
localVarAxiosArgs = _d.sent();
|
|
489
|
+
localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
490
|
+
localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['EndpointsApi.listEndpoints']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
491
|
+
return [2 /*return*/, function (axios, basePath) { return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }];
|
|
492
|
+
}
|
|
493
|
+
});
|
|
494
|
+
});
|
|
495
|
+
},
|
|
496
|
+
/**
|
|
497
|
+
* Updates the BXML for the specified endpoint.
|
|
498
|
+
* @summary Update Endpoint BXML
|
|
499
|
+
* @param {string} accountId Your Bandwidth Account ID.
|
|
500
|
+
* @param {string} endpointId BRTC Endpoint ID.
|
|
501
|
+
* @param {string} body
|
|
502
|
+
* @param {*} [options] Override http request option.
|
|
503
|
+
* @throws {RequiredError}
|
|
504
|
+
*/
|
|
505
|
+
updateEndpointBxml: function (accountId, endpointId, body, options) {
|
|
506
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
507
|
+
var localVarAxiosArgs, localVarOperationServerIndex, localVarOperationServerBasePath;
|
|
508
|
+
var _a, _b, _c;
|
|
509
|
+
return __generator(this, function (_d) {
|
|
510
|
+
switch (_d.label) {
|
|
511
|
+
case 0: return [4 /*yield*/, localVarAxiosParamCreator.updateEndpointBxml(accountId, endpointId, body, options)];
|
|
512
|
+
case 1:
|
|
513
|
+
localVarAxiosArgs = _d.sent();
|
|
514
|
+
localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
515
|
+
localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['EndpointsApi.updateEndpointBxml']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
516
|
+
return [2 /*return*/, function (axios, basePath) { return (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }];
|
|
517
|
+
}
|
|
518
|
+
});
|
|
519
|
+
});
|
|
520
|
+
},
|
|
521
|
+
};
|
|
522
|
+
};
|
|
523
|
+
exports.EndpointsApiFp = EndpointsApiFp;
|
|
524
|
+
/**
|
|
525
|
+
* EndpointsApi - factory interface
|
|
526
|
+
*/
|
|
527
|
+
var EndpointsApiFactory = function (configuration, basePath, axios) {
|
|
528
|
+
var localVarFp = (0, exports.EndpointsApiFp)(configuration);
|
|
529
|
+
return {
|
|
530
|
+
/**
|
|
531
|
+
* Creates a new Endpoint for the specified account.
|
|
532
|
+
* @summary Create Endpoint
|
|
533
|
+
* @param {string} accountId Your Bandwidth Account ID.
|
|
534
|
+
* @param {CreateWebRtcConnectionRequest} body
|
|
535
|
+
* @param {*} [options] Override http request option.
|
|
536
|
+
* @throws {RequiredError}
|
|
537
|
+
*/
|
|
538
|
+
createEndpoint: function (accountId, body, options) {
|
|
539
|
+
return localVarFp.createEndpoint(accountId, body, options).then(function (request) { return request(axios, basePath); });
|
|
540
|
+
},
|
|
541
|
+
/**
|
|
542
|
+
* Deletes the specified endpoint. If the endpoint is actively streaming media, the media stream will be terminated.
|
|
543
|
+
* @summary Delete Endpoint
|
|
544
|
+
* @param {string} accountId Your Bandwidth Account ID.
|
|
545
|
+
* @param {string} endpointId BRTC Endpoint ID.
|
|
546
|
+
* @param {*} [options] Override http request option.
|
|
547
|
+
* @throws {RequiredError}
|
|
548
|
+
*/
|
|
549
|
+
deleteEndpoint: function (accountId, endpointId, options) {
|
|
550
|
+
return localVarFp.deleteEndpoint(accountId, endpointId, options).then(function (request) { return request(axios, basePath); });
|
|
551
|
+
},
|
|
552
|
+
/**
|
|
553
|
+
* Returns information about the specified endpoint.
|
|
554
|
+
* @summary Get Endpoint
|
|
555
|
+
* @param {string} accountId Your Bandwidth Account ID.
|
|
556
|
+
* @param {string} endpointId BRTC Endpoint ID.
|
|
557
|
+
* @param {*} [options] Override http request option.
|
|
558
|
+
* @throws {RequiredError}
|
|
559
|
+
*/
|
|
560
|
+
getEndpoint: function (accountId, endpointId, options) {
|
|
561
|
+
return localVarFp.getEndpoint(accountId, endpointId, options).then(function (request) { return request(axios, basePath); });
|
|
562
|
+
},
|
|
563
|
+
/**
|
|
564
|
+
* Returns a list of endpoints associated with the specified account.
|
|
565
|
+
* @summary List Endpoints
|
|
566
|
+
* @param {string} accountId Your Bandwidth Account ID.
|
|
567
|
+
* @param {EndpointTypeEnum} [type] The type of endpoint.
|
|
568
|
+
* @param {EndpointStatusEnum} [status] The status of the endpoint.
|
|
569
|
+
* @param {string} [afterCursor] The cursor to use for pagination. This is the value of the `next` link in the previous response.
|
|
570
|
+
* @param {number} [limit] The maximum number of endpoints to return in the response.
|
|
571
|
+
* @param {*} [options] Override http request option.
|
|
572
|
+
* @throws {RequiredError}
|
|
573
|
+
*/
|
|
574
|
+
listEndpoints: function (accountId, type, status, afterCursor, limit, options) {
|
|
575
|
+
return localVarFp.listEndpoints(accountId, type, status, afterCursor, limit, options).then(function (request) { return request(axios, basePath); });
|
|
576
|
+
},
|
|
577
|
+
/**
|
|
578
|
+
* Updates the BXML for the specified endpoint.
|
|
579
|
+
* @summary Update Endpoint BXML
|
|
580
|
+
* @param {string} accountId Your Bandwidth Account ID.
|
|
581
|
+
* @param {string} endpointId BRTC Endpoint ID.
|
|
582
|
+
* @param {string} body
|
|
583
|
+
* @param {*} [options] Override http request option.
|
|
584
|
+
* @throws {RequiredError}
|
|
585
|
+
*/
|
|
586
|
+
updateEndpointBxml: function (accountId, endpointId, body, options) {
|
|
587
|
+
return localVarFp.updateEndpointBxml(accountId, endpointId, body, options).then(function (request) { return request(axios, basePath); });
|
|
588
|
+
},
|
|
589
|
+
};
|
|
590
|
+
};
|
|
591
|
+
exports.EndpointsApiFactory = EndpointsApiFactory;
|
|
592
|
+
/**
|
|
593
|
+
* EndpointsApi - object-oriented interface
|
|
594
|
+
*/
|
|
595
|
+
var EndpointsApi = /** @class */ (function (_super) {
|
|
596
|
+
__extends(EndpointsApi, _super);
|
|
597
|
+
function EndpointsApi() {
|
|
598
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
599
|
+
}
|
|
600
|
+
/**
|
|
601
|
+
* Creates a new Endpoint for the specified account.
|
|
602
|
+
* @summary Create Endpoint
|
|
603
|
+
* @param {string} accountId Your Bandwidth Account ID.
|
|
604
|
+
* @param {CreateWebRtcConnectionRequest} body
|
|
605
|
+
* @param {*} [options] Override http request option.
|
|
606
|
+
* @throws {RequiredError}
|
|
607
|
+
*/
|
|
608
|
+
EndpointsApi.prototype.createEndpoint = function (accountId, body, options) {
|
|
609
|
+
var _this = this;
|
|
610
|
+
return (0, exports.EndpointsApiFp)(this.configuration).createEndpoint(accountId, body, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
611
|
+
};
|
|
612
|
+
/**
|
|
613
|
+
* Deletes the specified endpoint. If the endpoint is actively streaming media, the media stream will be terminated.
|
|
614
|
+
* @summary Delete Endpoint
|
|
615
|
+
* @param {string} accountId Your Bandwidth Account ID.
|
|
616
|
+
* @param {string} endpointId BRTC Endpoint ID.
|
|
617
|
+
* @param {*} [options] Override http request option.
|
|
618
|
+
* @throws {RequiredError}
|
|
619
|
+
*/
|
|
620
|
+
EndpointsApi.prototype.deleteEndpoint = function (accountId, endpointId, options) {
|
|
621
|
+
var _this = this;
|
|
622
|
+
return (0, exports.EndpointsApiFp)(this.configuration).deleteEndpoint(accountId, endpointId, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
623
|
+
};
|
|
624
|
+
/**
|
|
625
|
+
* Returns information about the specified endpoint.
|
|
626
|
+
* @summary Get Endpoint
|
|
627
|
+
* @param {string} accountId Your Bandwidth Account ID.
|
|
628
|
+
* @param {string} endpointId BRTC Endpoint ID.
|
|
629
|
+
* @param {*} [options] Override http request option.
|
|
630
|
+
* @throws {RequiredError}
|
|
631
|
+
*/
|
|
632
|
+
EndpointsApi.prototype.getEndpoint = function (accountId, endpointId, options) {
|
|
633
|
+
var _this = this;
|
|
634
|
+
return (0, exports.EndpointsApiFp)(this.configuration).getEndpoint(accountId, endpointId, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
635
|
+
};
|
|
636
|
+
/**
|
|
637
|
+
* Returns a list of endpoints associated with the specified account.
|
|
638
|
+
* @summary List Endpoints
|
|
639
|
+
* @param {string} accountId Your Bandwidth Account ID.
|
|
640
|
+
* @param {EndpointTypeEnum} [type] The type of endpoint.
|
|
641
|
+
* @param {EndpointStatusEnum} [status] The status of the endpoint.
|
|
642
|
+
* @param {string} [afterCursor] The cursor to use for pagination. This is the value of the `next` link in the previous response.
|
|
643
|
+
* @param {number} [limit] The maximum number of endpoints to return in the response.
|
|
644
|
+
* @param {*} [options] Override http request option.
|
|
645
|
+
* @throws {RequiredError}
|
|
646
|
+
*/
|
|
647
|
+
EndpointsApi.prototype.listEndpoints = function (accountId, type, status, afterCursor, limit, options) {
|
|
648
|
+
var _this = this;
|
|
649
|
+
return (0, exports.EndpointsApiFp)(this.configuration).listEndpoints(accountId, type, status, afterCursor, limit, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
650
|
+
};
|
|
651
|
+
/**
|
|
652
|
+
* Updates the BXML for the specified endpoint.
|
|
653
|
+
* @summary Update Endpoint BXML
|
|
654
|
+
* @param {string} accountId Your Bandwidth Account ID.
|
|
655
|
+
* @param {string} endpointId BRTC Endpoint ID.
|
|
656
|
+
* @param {string} body
|
|
657
|
+
* @param {*} [options] Override http request option.
|
|
658
|
+
* @throws {RequiredError}
|
|
659
|
+
*/
|
|
660
|
+
EndpointsApi.prototype.updateEndpointBxml = function (accountId, endpointId, body, options) {
|
|
661
|
+
var _this = this;
|
|
662
|
+
return (0, exports.EndpointsApiFp)(this.configuration).updateEndpointBxml(accountId, endpointId, body, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
663
|
+
};
|
|
664
|
+
return EndpointsApi;
|
|
665
|
+
}(base_1.BaseAPI));
|
|
666
|
+
exports.EndpointsApi = EndpointsApi;
|