Closed benjaminbruch closed 4 years ago
Had to set return context option "true" in message input. Here is an example:
assistant.message(assistantID: assistantID, sessionID: sessionID, input: MessageInput(options: MessageInputOptions(returnContext: true))) { response, error in
if let error = error {
print(error)
return
}
}
Still would be nice if this and the following question would be in the docs:
Is there any current documentation on "How to set context variable for sending to Watson?
Overview [Watson Assistant V2] Context variable in message response is always "nil"
In my welcome dialog node I defined 2 context variables. But these were not send within message response.
Expected behavior These variables should be within context variable.
Actual behavior context = (Assistant.MessageContext?) nil
How to reproduce Create welcome dialog node , define context variable, start conversation and try to receive context data.
Screenshots
SDK Version 3.5.0 & 3.4.0
Additional information: Apple Swift version 5.2.4
Additonal questions: