The cookie will expire after 4 hours.
So if an incoming call or SMS message arrives
4 hours after the cookie was set, then the expired
cookie will not be included with the request.
Right now, if a cookie expires this way, onInteractionEnd will never fire which means if you try to set up hooks to keep records of the interaction.
I think the current Flow context is a little clunky and think it'd be simpler/a better user experience to have context by user defined and retrieved from a user-defined hook.
I should probably add a hook a message is sent, since onMessage lets you see what the cookie was on Twilio in an incoming message, it makes sense to also have a hook when the outbound is sent as well to see what the new state of the cookie is.
If anyone wants to implement this PRs are welcome, otherwise I can get to it.
Twilio's documentation on SMS cookies states
Right now, if a cookie expires this way,
onInteractionEnd
will never fire which means if you try to set up hooks to keep records of the interaction.I think the current Flow context is a little clunky and think it'd be simpler/a better user experience to havecontext
by user defined and retrieved from a user-defined hook.I should probably add a hook a message is sent, since
onMessage
lets you see what the cookie was on Twilio in an incoming message, it makes sense to also have a hook when the outbound is sent as well to see what the new state of the cookie is.If anyone wants to implement this PRs are welcome, otherwise I can get to it.