Send Document as Base64 - SOAP Integration

Certified Associate Developer

Hello everyone,

I hope you are doing well.

I am currently facing an issue while sending a SOAP request through an Appian Integration. The request body contains a document that must be sent as Base64 inside the XML body.

I have been researching possible solutions, and according to the Appian documentation, automatic Base64 conversion only seems to work when using a Data Type (CDT) with automatic XML conversion enabled.

However, in my case, the XML structure required by the service contains specific namespaces and a custom structure, so when I tried using a CDT, the generated XML did not match the expected format and the service returned a 500 status code.

I also found some plugins that convert documents to Base64, but my requirement is only to convert the document temporarily and send it in the request body. I do not need to store the Base64 value in the database.

Another alternative I considered was creating an Appian Web API that returns the Base64 content and then consuming that response in the Integration. However, the main issue is that Appian does not seem to provide a native way to convert a document to Base64 when building a custom SOAP/XML request manually.

Has anyone faced a similar scenario or found a better approach to send documents as Base64 in a custom SOAP/XML request?

Thank you in advance for your help.

  Discussion posts and replies are publicly visible

Parents
  • 0
    Certified Lead Developer

    This is a very well known issue. The limited support of separate Base64 conversion is the memory consumption and potential risk of system stability.

    All my past experiences with SOAP and Appian have been painful. Mostly caused by the pure chaos of SOAP.

    I think that the most direct approach ist that database plugin trick. Just make sure to clean that table after the call.

    If this does not work, I suggest a custom plugin. A middleware or API gateway doing translation from/to JSON & XML might also be an alternative.

Reply
  • 0
    Certified Lead Developer

    This is a very well known issue. The limited support of separate Base64 conversion is the memory consumption and potential risk of system stability.

    All my past experiences with SOAP and Appian have been painful. Mostly caused by the pure chaos of SOAP.

    I think that the most direct approach ist that database plugin trick. Just make sure to clean that table after the call.

    If this does not work, I suggest a custom plugin. A middleware or API gateway doing translation from/to JSON & XML might also be an alternative.

Children
No Data