Can't upload attachment to a note


I am creating a tool to migrate from our existing ticketing tool to Freshdesk.
As a part of this tool, I would like to migrate attachments etc.
A point is that in some cases Freshdesk returns status code 400 when creating a note with attachments or uploading attachments to the existing note.
I am executing the script using a user with Account Administrator privileges and I am updating notes created by other users.
As per Freshdesk uploading attachments to the existing note is something that I should be able to do. I was trying to do that rising both Python and curl with the same outcome.
Here is an example using a curl:

curl -v -u APIKEY:X -F "attachments[]=@matt.msg" -X PUT 'https://[instance]'

I have cross-checked ids with:

https://[instance][ticket number].xml

Is it a bug or is it something wrong with my call or something unusual with my setup?


Interesting fact - this code worked for a different ticket, different note.
There is something specific to the data that I was trying to upload.

Updating comments of other administrators is not allowed, so sometimes you may face issues due this reason