When using the NCCO builder to create a Websocket Connect Endpoint, it serializes to have a field 'contentType', whilst the API expects a field of 'content-type'
Expected Behavior
{ "content-type": "...." }
Current Behavior
{ "contentType": "...." }
Possible Solution
Code
# Where BITRATE=16, and FREQUENCY=16000
ws = ConnectEndpoints.WebsocketEndpoint(
uri=some_url,
contentType=f"audio/l{StreamingConfig.BITRATE};rate={StreamingConfig.FREQUENCY}"
)
c = Ncco.Connect(endpoint=ws, eventType="synchronous")
ncco = Ncco.build_ncco(c)
print(json.dumps(ncco, indent=4))
When using the NCCO builder to create a Websocket Connect Endpoint, it serializes to have a field 'contentType', whilst the API expects a field of 'content-type'
Expected Behavior
{ "content-type": "...." }
Current Behavior
{ "contentType": "...." }
Possible Solution
Code
Response to Voice API
Websocket Connected Message
After Applying Fix
Your Environment