Please excuse the double post, but this is about a different issue to my last post.
I note that the OP's version of this script assumes that the x-callback response data will be formatted something like
app://xcallbackresponse-REQUEST_ID/?query=value&query=value. But one of the apps I'm working with formats its response like
app://xcallbackresponse-REQUEST_IDvalue which causes the URL parsing in this script to break.
Here is a modified version which handles this case a little more gracefully by setting
None when it can't parse the URL directly and by creating a new
x_callback_response.raw_response_data which is simply the response URL without the