How to POST a document in binary format?

Hello World,

I am looking for a way to make a Rest API call to post a document.

The document need to be converted in binary.

Best

  Discussion posts and replies are publicly visible

Parents
  • 0
    Certified Lead Developer
    Hi as per my understanding File upload smart service is the best choice in your case.

    I will not recommended you to go for Base64 approach because of following reasons:

    1. Generally when we convert a document to Base64 then the output document size will be much bigger than the actual one

    2. When Base64 conversion happens, entire output Base64 data will be stored in memory instead of streaming it, which is why it's a memory intensive operation.

    3. If we are dealing with multiple and huge file operation, Base64 will impact the server performance a lot

    Solution: we should be able to stream the Document in Binary format, which can be done by using upload file smart service.

    Hope this will help
Reply
  • 0
    Certified Lead Developer
    Hi as per my understanding File upload smart service is the best choice in your case.

    I will not recommended you to go for Base64 approach because of following reasons:

    1. Generally when we convert a document to Base64 then the output document size will be much bigger than the actual one

    2. When Base64 conversion happens, entire output Base64 data will be stored in memory instead of streaming it, which is why it's a memory intensive operation.

    3. If we are dealing with multiple and huge file operation, Base64 will impact the server performance a lot

    Solution: we should be able to stream the Document in Binary format, which can be done by using upload file smart service.

    Hope this will help
Children