Hi thanks a lot for your reply,
The error says "Max field length exceeds 5 Mb" . however I did managed to found a solution today.
For people who might end up on this thread here is what I did:
- Instead of sending the file as part of the CreateMessage for the document (in the field "content"), if the file is more that 5 Mb, I send content as empty
- Then call getUploadUrl
- Do a POST of the file on this url, while providing the document Id from the first call.
- Then continue as usual to attach the file to desired parent entity.