Lily, thank you very much for the answer.
I have tried this, but I had no answer.
Look:
DEBUG Log:
2019-08-13 11:08:45,199 DEBUG [actions_component] Task: <function _call_the_task at 0x7f0a764c51b8>
2019-08-13 11:08:45,200 DEBUG [decorators] Thread-3: _call_the_task
2019-08-13 11:08:45,200 INFO [utilities_call_rest_api] rest_method: POST
2019-08-13 11:08:45,201 INFO [utilities_call_rest_api] rest_url: https://10.4.0.22/rest/orgs/201/incidents/6776/attachments/query?include_tasks=true
2019-08-13 11:08:45,201 INFO [utilities_call_rest_api] rest_headers:
Content-Type: application/json
X-Frooble: Baz
2019-08-13 11:08:45,202 INFO [utilities_call_rest_api] rest_body:
{
}
2019-08-13 11:08:45,202 INFO [utilities_call_rest_api] rest_verify: False
2019-08-13 11:08:45,204 DEBUG [connectionpool] Starting new HTTPS connection (1): 10.4.0.22
2019-08-13 11:08:45,232 DEBUG [connectionpool] https://10.4.0.22:443 "POST /rest/orgs/201/incidents/6776/attachments/query?include_tasks=true HTTP/1.1" 401 None
2019-08-13 11:08:45,236 DEBUG [universaldetector] no data received!
2019-08-13 11:08:45,236 DEBUG [universaldetector] no probers hit minimum threshold
2019-08-13 11:08:45,237 DEBUG [decorators] [utilities_call_rest_api] FunctionResult: <resilient_circuits.action_message.FunctionResult object at 0x7f0a7651d850>
2019-08-13 11:08:45,603 DEBUG [actions_component] success! [<resilient_circuits.action_message.FunctionResult object at 0x7f0a7651d850>], <utilities_call_rest_api[functions.utilities_call_rest_api] (id=7, workflow=busca_adjunto, user=jdelcol@xelere.com) 2019-08-13 14:08:44.596000>
2019-08-13 11:08:45,604 DEBUG [actions_component] Message: Completed
2019-08-13 11:08:45,604 DEBUG [actions_component] Ack ID:xelres.xelerelocal.com-35915-1564572685106-3:3:719:1:1
2019-08-13 11:08:45,605 DEBUG [actions_component] Result: {'cookies': {'JSESSIONID': 'B4ED28B6F9FCB6B1B23A5B33C12CF532'}, 'links': {}, 'text': u'', 'elapsed': 30, 'apparent_encoding': None, 'reason': 'Unauthorized', 'ok': False, 'url': u'https://10.4.0.22/rest/orgs/201/incidents/6776/attachments/query?include_tasks=true', 'headers': {'Transfer-Encoding': 'chunked', 'Set-Cookie': 'JSESSIONID=B4ED28B6F9FCB6B1B23A5B33C12CF532; Path=/; Secure; HttpOnly', 'Server': 'Co3', 'X-Content-Type-Options': 'nosniff', 'Date': 'Tue, 13 Aug 2019 14:08:44 GMT'}, 'json': None, 'status_code': 401}
2019-08-13 11:08:45,607 DEBUG [stomp_component] ack_frame()
2019-08-13 11:08:45,608 DEBUG [client] Sending ACK frame [headers={'id': u'ID:xelres.xelerelocal.com-36623-1564572530524-24:3'}, version=1.2]
2019-08-13 11:08:45,608 DEBUG [stomp_component] Ack Sent
2019-08-13 11:08:45,610 DEBUG [stomp_component] send()
2019-08-13 11:08:45,610 DEBUG [client] Sending SEND frame [headers={'destination': u'/queue/acks.201.fn_utilities', 'correlation-id': u'invid:12326'}, body='{\n "message": "Comp...', version=1.2]
2019-08-13 11:08:45,611 DEBUG [stomp_component] Message sent
Nothing appears in the Note
------------------------------
Juan Cruz Del Col
------------------------------
Original Message:
Sent: Mon August 12, 2019 08:02 PM
From: LILY WANG
Subject: Attached incidents?
Hi Juan,
You can use "POST /orgs/{org_id}/incidents/{inc_id}/attachments/query" endpoint.
It will returns attachment as an array, so you can check the length of "response['attachments']" if it's greater than 0.
------------------------------
LILY WANG
Original Message:
Sent: Mon August 12, 2019 04:28 PM
From: Juan Cruz Del Col
Subject: Attached incidents?
I need to know if an incident has attachments or not.
Im using "IncidentAttachmentREST" but not seenumber of attach
/orgs/{org_id}/incidents/{inc_id}/attachments/{attach_id}
------------------------------
Juan Cruz Del Col
------------------------------