Hi there!
I need all the help the community can give me with this issue.
I have an automation rule which works with a Webhook as a trigger. After that is triggered, it has to create an issue.
I'm connecting Whatsapp with GPT, sending those reponses to a FLASK server and from then I'm creating a issue with the information.
The problem that I'm having is that when I finish the conversation from the chatbot and send the information to the FLASK server and from then to the JSM, I'm getting this error on the audit log of the automation rule:

I believe this is because there is something wrong with my JSON:
headers = {
'Content-Type': 'application/json',
'Authorization': f'Bearer {jira_auth_token}' # Use Bearer token for authorization
}
payload = {
"fields": {
"summary": f"New candidate: {data['name']}",
"description": f"Name: {data['name']}\nEmail: {data['email']}\nPhone: {data['phone']}\nExperience: {data['experience']}",
"issuetype": {
"name": "Task"
},
"project": {
"key": "FT" # Replace with your actual project key
}
}
}I don't know if how I'm sending the information in the JSON is correct. I also want to share how I'm managing the Webhook in case someone has the same problem:
@app.route("/webhook", methods=['POST'])
def webhook():
incoming_msg = request.form.get('Body')
client_number = request.form.get('From')
user_id = client_number
ai_response = process_message(user_id, incoming_msg)
response = MessagingResponse()
response.message(ai_response)
return str(response)
@app.route("/")
def index():
return "Hello, this is the Flask application running!"In case you need more information in order to help me please fill free to ask.
Thanks for all the help in advance!