• SudoNhim
  • NEWBIE
  • 0 Points
  • Member since 2012

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 0
    Questions
  • 2
    Replies

Hi,

I am doing a RESTful call out (Mime infact, POST). My schedule job will periodically send files/attachments to the client's (.NET) server. I am able to send any plain text data to them correctly but when I send an base64Encoded attachement using EncodingUtil.base64Encode(). Their application is not able to decode it, it says the image/document is corrupted. 

 

I also noted that for an image of 103kb, the base64 encoded string is just 73kb. Base64 is suppose to be larger than the original size correct? So, am I missing something here?

 

Another thing I noticed is that the documentation for EncodingUtil.base64Encode() says it Converts a Blob to an unencoded String representing its normal form. (check here for documentation). What does it mean 'unencoded'. Is that the issue? how to resolve this then?

  • July 12, 2012
  • Like
  • 0