Logic App - Connector - Upload an attachment (preview) format
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-14-2024 11:43 PM - edited ‎09-15-2024 12:03 AM
https://learn.microsoft.com/en-us/connectors/service-now/#upload-an-attachment-(preview)
Trying to use the Service-Now Connector in a logic app. I've used a lot of the other functions on the connector successfully, the only one I can't get working is the "Upload an attachment (preview)".
Anyone know where I'm going wrong or able to point me to some documentation for this connector with an example.
Attached picture of Connector setup.
strfilecontent=containing the file content
Example response:
{
"error": {
"message": "Invalid content-type. Supported request media types for this service are: [multipart/form-data]",
"detail": null
},
"status": "failure"
}
{
"method": "post",
"path": "/api/now/v1/attachment/upload",
"host": {
"connection": {
"name": "/subscriptions/123
}
},
"body": {
"$content-type": "multipart/form-data",
"$multipart": [
{
"body": {
"$content-type": "application/pdf",
"$content": "JVBERi0xLjUKJeLjz9MKNCAwIG9iago8...."
},
"headers": {
"Content-Disposition": "form-data; name=\"attachment_content\"; filename=\"test.pdf\""
}
},
{
"body": "alm_hardware",
"headers": {
"Content-Disposition": "form-data; name=\"table_name\""
}
},
{
"body": "12383e6cdbd0cc10e0994837059619a5",
"headers": {
"Content-Disposition": "form-data; name=\"table_sys_id\""
}
}
]
}
}
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-23-2024 08:22 AM
I am seeing the same issue, have you been able to find a solution?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎03-19-2025 08:39 AM
Has anyone managed to get this working? I get a 400 - bad request error.
I'm passing the sys id from the output of the Create Record step and "incident" as the table name. From the input step, I see the "incident" as table name and the sys id of the incident getting passed correctly. Cross checked the sys id by opening the incident as well. Not sure about the reason for the error. 😞
{ "error": { "message": "Missing parameter: table_name", "detail": null }, "status": "failure" }