Skip to content

Commit

Permalink
Merge pull request #141 from Bandwidth/SWI-5508
Browse files Browse the repository at this point in the history
SWI-5508 Update SDK Based on Recent Spec Changes
  • Loading branch information
brianluisgomez authored Jun 25, 2024
2 parents 15a1211 + 13d21c4 commit 4b04e23
Show file tree
Hide file tree
Showing 55 changed files with 260 additions and 241 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ Add this dependency to your project's POM:
<dependency>
<groupId>com.bandwidth.sdk</groupId>
<artifactId>bandwidth-sdk</artifactId>
<version>10.0.0</version>
<version>10.1.0</version>
<scope>compile</scope>
</dependency>
```
Expand All @@ -57,7 +57,7 @@ Add this dependency to your project's build file:
}
dependencies {
implementation "com.bandwidth.sdk:bandwidth-sdk:10.0.0"
implementation "com.bandwidth.sdk:bandwidth-sdk:10.1.0"
}
```

Expand All @@ -71,7 +71,7 @@ mvn clean package

Then manually install the following JARs:

* `target/bandwidth-sdk-10.0.0.jar`
* `target/bandwidth-sdk-10.1.0.jar`
* `target/lib/*.jar`

## Getting Started
Expand Down
230 changes: 105 additions & 125 deletions api/openapi.yaml

Large diffs are not rendered by default.

46 changes: 28 additions & 18 deletions bandwidth.yml
Original file line number Diff line number Diff line change
Expand Up @@ -1173,7 +1173,7 @@ paths:
[startTranscription](/docs/voice/bxml/startTranscription).
Note: After the deletion is requested and a `204` is returned, the
Note: After the deletion is requested and a `200` is returned, the
transcription will not be accessible anymore. However, it is not deleted
immediately. This deletion process, while transparent and irreversible,
can take an additional 24 to 48 hours.
Expand All @@ -1183,7 +1183,7 @@ paths:
- $ref: '#/components/parameters/callId'
- $ref: '#/components/parameters/transcriptionId'
responses:
'204':
'200':
$ref: '#/components/responses/deleteCallTranscriptionResponse'
'400':
$ref: '#/components/responses/voiceBadRequestError'
Expand Down Expand Up @@ -2152,11 +2152,16 @@ components:
description: >-
A Bandwidth phone number on your account the call should come
from (must be in E.164 format, like `+15555551212`, or be one of the
following
strings: `Restricted`, `Anonymous`, `Private`, or `Unavailable`).
example: '+19195554321'
from (must be in E.164 format, like `+15555551212`) even if
`privacy` is set to true.
example: '+15555551212'
privacy:
nullable: true
type: boolean
description: >-
Hide the calling number. The `displayName` field can be used to
customize the displayed name.
example: false
displayName:
nullable: true
type: string
Expand All @@ -2165,6 +2170,9 @@ components:
May not exceed 256 characters nor contain control characters such as
new lines.
If `privacy` is true, only the following values are valid:
`Restricted`, `Anonymous`, `Private`, or `Unavailable`.
maxLength: 256
example: John Doe
uui:
Expand Down Expand Up @@ -2488,7 +2496,7 @@ components:
description: >-
The phone number that made the call, in E.164 format (e.g.
+15555555555).
example: '19195554321'
example: '+19195554321'
direction:
$ref: '#/components/schemas/callDirectionEnum'
state:
Expand Down Expand Up @@ -3023,7 +3031,10 @@ components:
description: >-
The machine detection request used to perform <a
href='/docs/voice/guides/machineDetection'>machine detection</a> on the
call.
call. Currently, there is an issue where decimal values are not getting
processed correctly. Please use whole number values. We are working to
resolve this issue. Please contact Bandwidth Support if you need more
information.
properties:
mode:
$ref: '#/components/schemas/machineDetectionModeEnum'
Expand Down Expand Up @@ -3290,7 +3301,7 @@ components:
- outbound
description: Which `track` this transcription is derived from.
example: inbound
text:
transcript:
type: string
description: The transcription itself.
example: Hello World! This is an example.
Expand Down Expand Up @@ -4128,7 +4139,7 @@ components:
accountId:
type: string
description: The user account associated with the call.
example: '920012'
example: '9900000'
applicationId:
type: string
description: The id of the application associated with the call.
Expand All @@ -4142,9 +4153,8 @@ components:
from:
type: string
description: >-
The provided identifier of the caller: can be a phone number in E.164
format (e.g. +15555555555) or one of Private, Restricted, Unavailable,
or Anonymous.
The provided identifier of the caller. Must be a phone number in E.164
format (e.g. +15555555555).
example: '+15555555555'
conferenceId:
type: string
Expand Down Expand Up @@ -4223,15 +4233,14 @@ components:
type: string
description: >-
The phone number used as the from field of the B-leg call, in E.164
format (e.g. +15555555555) or one of Restricted, Anonymous, Private, or
Unavailable.
format (e.g. +15555555555).
example: '+15555555555'
transferTo:
type: string
description: >-
The phone number used as the to field of the B-leg call, in E.164 format
(e.g. +15555555555).
example: +15555555555)
example: '+15555555555'
mediaUrl:
nullable: true
type: string
Expand Down Expand Up @@ -4442,7 +4451,7 @@ components:
messageId:
type: string
description: Messaging API Message ID.
example: 9e0df4ca-b18d-40d7-a59f-82fcdf5ae8e6
example: 1589228074636lm4k2je7j7jklbn2
verifyCodeRequest:
type: object
properties:
Expand Down Expand Up @@ -5778,6 +5787,7 @@ components:
answerMethod: POST
answerUrl: https://myServer.example/bandwidth/webhooks/answer
answerFallbackMethod: POST
answerFallbackUrl: https://myServer.example/bandwidth/webhooks/answerFallback
disconnectMethod: POST
disconnectUrl: https://myServer.example/bandwidth/webhooks/disconnect
username: mySecretUsername
Expand Down
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ apply plugin: 'java'
apply plugin: 'com.diffplug.spotless'

group = 'com.bandwidth.sdk'
version = '10.0.0'
version = '10.1.0'

buildscript {
repositories {
Expand Down
2 changes: 1 addition & 1 deletion build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ lazy val root = (project in file(".")).
settings(
organization := "com.bandwidth.sdk",
name := "bandwidth-sdk",
version := "10.0.0",
version := "10.1.0",
scalaVersion := "2.11.4",
scalacOptions ++= Seq("-feature"),
javacOptions in compile ++= Seq("-Xlint:deprecation"),
Expand Down
2 changes: 1 addition & 1 deletion docs/AnswerCallback.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ The Answer event is sent to the answerUrl specified in the createCall request wh
|**eventTime** | **OffsetDateTime** | The approximate UTC date and time when the event was generated by the Bandwidth server, in ISO 8601 format. This may not be exactly the time of event execution. | [optional] |
|**accountId** | **String** | The user account associated with the call. | [optional] |
|**applicationId** | **String** | The id of the application associated with the call. | [optional] |
|**from** | **String** | The provided identifier of the caller: can be a phone number in E.164 format (e.g. +15555555555) or one of Private, Restricted, Unavailable, or Anonymous. | [optional] |
|**from** | **String** | The provided identifier of the caller. Must be a phone number in E.164 format (e.g. +15555555555). | [optional] |
|**to** | **String** | The phone number that received the call, in E.164 format (e.g. +15555555555). | [optional] |
|**direction** | **CallDirectionEnum** | | [optional] |
|**callId** | **String** | The call id associated with the event. | [optional] |
Expand Down
2 changes: 1 addition & 1 deletion docs/BridgeCompleteCallback.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ If the target call leaves the <Bridge>, then this callback is sent to the bridge
|**eventTime** | **OffsetDateTime** | The approximate UTC date and time when the event was generated by the Bandwidth server, in ISO 8601 format. This may not be exactly the time of event execution. | [optional] |
|**accountId** | **String** | The user account associated with the call. | [optional] |
|**applicationId** | **String** | The id of the application associated with the call. | [optional] |
|**from** | **String** | The provided identifier of the caller: can be a phone number in E.164 format (e.g. +15555555555) or one of Private, Restricted, Unavailable, or Anonymous. | [optional] |
|**from** | **String** | The provided identifier of the caller. Must be a phone number in E.164 format (e.g. +15555555555). | [optional] |
|**to** | **String** | The phone number that received the call, in E.164 format (e.g. +15555555555). | [optional] |
|**direction** | **CallDirectionEnum** | | [optional] |
|**callId** | **String** | The call id associated with the event. | [optional] |
Expand Down
2 changes: 1 addition & 1 deletion docs/BridgeTargetCompleteCallback.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ If the originating call leaves the <Bridge>, then this callback is sent to the b
|**eventTime** | **OffsetDateTime** | The approximate UTC date and time when the event was generated by the Bandwidth server, in ISO 8601 format. This may not be exactly the time of event execution. | [optional] |
|**accountId** | **String** | The user account associated with the call. | [optional] |
|**applicationId** | **String** | The id of the application associated with the call. | [optional] |
|**from** | **String** | The provided identifier of the caller: can be a phone number in E.164 format (e.g. +15555555555) or one of Private, Restricted, Unavailable, or Anonymous. | [optional] |
|**from** | **String** | The provided identifier of the caller. Must be a phone number in E.164 format (e.g. +15555555555). | [optional] |
|**to** | **String** | The phone number that received the call, in E.164 format (e.g. +15555555555). | [optional] |
|**direction** | **CallDirectionEnum** | | [optional] |
|**callId** | **String** | The call id associated with the event. | [optional] |
Expand Down
4 changes: 2 additions & 2 deletions docs/CallRecordingMetadata.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
|**parentCallId** | **String** | (optional) If the event is related to the B leg of a &lt;Transfer&gt;, the call id of the original call leg that executed the &lt;Transfer&gt;. Otherwise, this field will not be present. | [optional] |
|**recordingId** | **String** | The unique ID of this recording | [optional] |
|**to** | **String** | The phone number that received the call, in E.164 format (e.g. +15555555555). | [optional] |
|**from** | **String** | The provided identifier of the caller: can be a phone number in E.164 format (e.g. +15555555555) or one of Private, Restricted, Unavailable, or Anonymous. | [optional] |
|**transferCallerId** | **String** | The phone number used as the from field of the B-leg call, in E.164 format (e.g. +15555555555) or one of Restricted, Anonymous, Private, or Unavailable. | [optional] |
|**from** | **String** | The provided identifier of the caller. Must be a phone number in E.164 format (e.g. +15555555555). | [optional] |
|**transferCallerId** | **String** | The phone number used as the from field of the B-leg call, in E.164 format (e.g. +15555555555). | [optional] |
|**transferTo** | **String** | The phone number used as the to field of the B-leg call, in E.164 format (e.g. +15555555555). | [optional] |
|**duration** | **String** | The duration of the recording in ISO-8601 format | [optional] |
|**direction** | **CallDirectionEnum** | | [optional] |
Expand Down
2 changes: 1 addition & 1 deletion docs/CallTranscription.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
|------------ | ------------- | ------------- | -------------|
|**detectedLanguage** | [**DetectedLanguageEnum**](#DetectedLanguageEnum) | The detected language for this transcription. | [optional] |
|**track** | [**TrackEnum**](#TrackEnum) | Which &#x60;track&#x60; this transcription is derived from. | [optional] |
|**text** | **String** | The transcription itself. | [optional] |
|**transcript** | **String** | The transcription itself. | [optional] |
|**confidence** | **Double** | How confident the transcription engine was in transcribing the associated audio (from &#x60;0&#x60; to &#x60;1&#x60;). | [optional] |


Expand Down
2 changes: 1 addition & 1 deletion docs/ConferenceMemberExitCallback.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ The Conference Member Exit event is fired whenever a caller exits a conference t
|**eventTime** | **OffsetDateTime** | The approximate UTC date and time when the event was generated by the Bandwidth server, in ISO 8601 format. This may not be exactly the time of event execution. | [optional] |
|**conferenceId** | **String** | The unique, Bandwidth-generated ID of the conference that was recorded | [optional] |
|**name** | **String** | The user-specified name of the conference that was recorded | [optional] |
|**from** | **String** | The provided identifier of the caller: can be a phone number in E.164 format (e.g. +15555555555) or one of Private, Restricted, Unavailable, or Anonymous. | [optional] |
|**from** | **String** | The provided identifier of the caller. Must be a phone number in E.164 format (e.g. +15555555555). | [optional] |
|**to** | **String** | The phone number that received the call, in E.164 format (e.g. +15555555555). | [optional] |
|**callId** | **String** | The call id associated with the event. | [optional] |
|**tag** | **String** | (optional) The tag specified on call creation. If no tag was specified or it was previously cleared, this field will not be present. | [optional] |
Expand Down
2 changes: 1 addition & 1 deletion docs/ConferenceMemberJoinCallback.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ The Conference Member Join event is fired whenever a caller joins a conference t
|**eventTime** | **OffsetDateTime** | The approximate UTC date and time when the event was generated by the Bandwidth server, in ISO 8601 format. This may not be exactly the time of event execution. | [optional] |
|**conferenceId** | **String** | The unique, Bandwidth-generated ID of the conference that was recorded | [optional] |
|**name** | **String** | The user-specified name of the conference that was recorded | [optional] |
|**from** | **String** | The provided identifier of the caller: can be a phone number in E.164 format (e.g. +15555555555) or one of Private, Restricted, Unavailable, or Anonymous. | [optional] |
|**from** | **String** | The provided identifier of the caller. Must be a phone number in E.164 format (e.g. +15555555555). | [optional] |
|**to** | **String** | The phone number that received the call, in E.164 format (e.g. +15555555555). | [optional] |
|**callId** | **String** | The call id associated with the event. | [optional] |
|**tag** | **String** | (optional) The tag specified on call creation. If no tag was specified or it was previously cleared, this field will not be present. | [optional] |
Expand Down
5 changes: 3 additions & 2 deletions docs/CreateCall.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,9 @@
| Name | Type | Description | Notes |
|------------ | ------------- | ------------- | -------------|
|**to** | **String** | The destination to call (must be an E.164 formatted number (e.g. &#x60;+15555551212&#x60;) or a SIP URI (e.g. &#x60;sip:user@server.example&#x60;)). | |
|**from** | **String** | A Bandwidth phone number on your account the call should come from (must be in E.164 format, like &#x60;+15555551212&#x60;, or be one of the following strings: &#x60;Restricted&#x60;, &#x60;Anonymous&#x60;, &#x60;Private&#x60;, or &#x60;Unavailable&#x60;). | |
|**displayName** | **String** | The caller display name to use when the call is created. May not exceed 256 characters nor contain control characters such as new lines. | [optional] |
|**from** | **String** | A Bandwidth phone number on your account the call should come from (must be in E.164 format, like &#x60;+15555551212&#x60;) even if &#x60;privacy&#x60; is set to true. | |
|**privacy** | **Boolean** | Hide the calling number. The &#x60;displayName&#x60; field can be used to customize the displayed name. | [optional] |
|**displayName** | **String** | The caller display name to use when the call is created. May not exceed 256 characters nor contain control characters such as new lines. If &#x60;privacy&#x60; is true, only the following values are valid: &#x60;Restricted&#x60;, &#x60;Anonymous&#x60;, &#x60;Private&#x60;, or &#x60;Unavailable&#x60;. | [optional] |
|**uui** | **String** | A comma-separated list of &#39;User-To-User&#39; headers to be sent in the INVITE when calling a SIP URI. Each value must end with an &#39;encoding&#39; parameter as described in &lt;a href&#x3D;&#39;https://tools.ietf.org/html/rfc7433&#39;&gt;RFC 7433&lt;/a&gt;. Only &#39;jwt&#39; and &#39;base64&#39; encodings are allowed. The entire value cannot exceed 350 characters, including parameters and separators. | [optional] |
|**applicationId** | **String** | The id of the application associated with the &#x60;from&#x60; number. | |
|**answerUrl** | **URI** | The full URL to send the &lt;a href&#x3D;&#39;/docs/voice/webhooks/answer&#39;&gt;Answer&lt;/a&gt; event to when the called party answers. This endpoint should return the first &lt;a href&#x3D;&#39;/docs/voice/bxml&#39;&gt;BXML document&lt;/a&gt; to be executed in the call. Must use &#x60;https&#x60; if specifying &#x60;username&#x60; and &#x60;password&#x60;. | |
Expand Down
2 changes: 1 addition & 1 deletion docs/DisconnectCallback.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ The Disconnect event is fired when a call ends, for any reason.
|**eventTime** | **OffsetDateTime** | The approximate UTC date and time when the event was generated by the Bandwidth server, in ISO 8601 format. This may not be exactly the time of event execution. | [optional] |
|**accountId** | **String** | The user account associated with the call. | [optional] |
|**applicationId** | **String** | The id of the application associated with the call. | [optional] |
|**from** | **String** | The provided identifier of the caller: can be a phone number in E.164 format (e.g. +15555555555) or one of Private, Restricted, Unavailable, or Anonymous. | [optional] |
|**from** | **String** | The provided identifier of the caller. Must be a phone number in E.164 format (e.g. +15555555555). | [optional] |
|**to** | **String** | The phone number that received the call, in E.164 format (e.g. +15555555555). | [optional] |
|**callId** | **String** | The call id associated with the event. | [optional] |
|**direction** | **CallDirectionEnum** | | [optional] |
Expand Down
4 changes: 2 additions & 2 deletions docs/DtmfCallback.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ The DTMF event is sent for every digit detected after a <StartGather> verb is ex
|**eventTime** | **OffsetDateTime** | The approximate UTC date and time when the event was generated by the Bandwidth server, in ISO 8601 format. This may not be exactly the time of event execution. | [optional] |
|**accountId** | **String** | The user account associated with the call. | [optional] |
|**applicationId** | **String** | The id of the application associated with the call. | [optional] |
|**from** | **String** | The provided identifier of the caller: can be a phone number in E.164 format (e.g. +15555555555) or one of Private, Restricted, Unavailable, or Anonymous. | [optional] |
|**from** | **String** | The provided identifier of the caller. Must be a phone number in E.164 format (e.g. +15555555555). | [optional] |
|**to** | **String** | The phone number that received the call, in E.164 format (e.g. +15555555555). | [optional] |
|**callId** | **String** | The call id associated with the event. | [optional] |
|**direction** | **CallDirectionEnum** | | [optional] |
Expand All @@ -22,7 +22,7 @@ The DTMF event is sent for every digit detected after a <StartGather> verb is ex
|**startTime** | **OffsetDateTime** | Time the call was started, in ISO 8601 format. | [optional] |
|**answerTime** | **OffsetDateTime** | Time the call was answered, in ISO 8601 format. | [optional] |
|**parentCallId** | **String** | (optional) If the event is related to the B leg of a &lt;Transfer&gt;, the call id of the original call leg that executed the &lt;Transfer&gt;. Otherwise, this field will not be present. | [optional] |
|**transferCallerId** | **String** | The phone number used as the from field of the B-leg call, in E.164 format (e.g. +15555555555) or one of Restricted, Anonymous, Private, or Unavailable. | [optional] |
|**transferCallerId** | **String** | The phone number used as the from field of the B-leg call, in E.164 format (e.g. +15555555555). | [optional] |
|**transferTo** | **String** | The phone number used as the to field of the B-leg call, in E.164 format (e.g. +15555555555). | [optional] |
|**tag** | **String** | (optional) The tag specified on call creation. If no tag was specified or it was previously cleared, this field will not be present. | [optional] |

Expand Down
Loading

0 comments on commit 4b04e23

Please sign in to comment.