IBM webMethods Hybrid Integration

IBM webMethods Hybrid Integration

Join this online group to communicate across IBM product users and experts by sharing advice and best practices with peers and staying up to date regarding product enhancements.

 View Only
Expand all | Collapse all

Unable to read Email attachment from service invoked by IMAP

  • 1.  Unable to read Email attachment from service invoked by IMAP

    Posted Mon January 23, 2006 04:52 AM

    Hi,

    I am currently developing a service which is invoked by E-Mail Port (IMAP) to read data from attachment or body of the email.

    Without attachment I am able to read the body of the email using the following services.

    → pub.flow:getTransportInfo
    → pub.mime:createMimeData
    → pub.mime.getBodyPartContent
    → sample.mime.helpers:streamToString
    → pub.string.stringToBytes

    and writing the values into a file

    No value is coming up in the pipeline if attachment is in the email. I need to read the attachment of the email.

    Many thanks for any help offered.

    Swami


    #Integration-Server-and-ESB
    #webMethods
    #webMethods-General


  • 2.  RE: Unable to read Email attachment from service invoked by IMAP

    Posted Tue January 24, 2006 08:10 AM

    Swami,

    I am trying the opposite of what you’re doing. I can get the contents of the attachment, but can’t get the body the email that has a single body part.

    Are you using single or multipart messages?

    Dave


    #webMethods-General
    #webMethods
    #Integration-Server-and-ESB


  • 3.  RE: Unable to read Email attachment from service invoked by IMAP

    Posted Tue January 24, 2006 07:57 PM

    Dave:

    I tried with multi part messages.

    With the help of the following services

    pub.mime.createMimeData,
    pub.mime.getBodyPartContent,
    sample.mime.helpers:streamToString

    I am able to read the body. You should have a input ‘ffdata’ object and make use of that.

    In my case, I am trying to read a zip file contents. Can you please tell me how you managed to read the attachment.

    Thanks,
    Swami


    #Integration-Server-and-ESB
    #webMethods
    #webMethods-General


  • 4.  RE: Unable to read Email attachment from service invoked by IMAP

    Posted Wed January 25, 2006 06:47 AM

    Swami,

    I have a service with 1 input named contentStream that is an object type. Then I
    call the following services:

    pub.mime:createMimeData
    pub.mime:getBodyPartContent

    after calling getBodyPartContent you should have the the attachment in the content variable.

    This worked for me using an POP3 email port.

    Dave


    #webMethods-General
    #webMethods
    #Integration-Server-and-ESB


  • 5.  RE: Unable to read Email attachment from service invoked by IMAP

    Posted Sat February 04, 2017 11:11 AM

    Hello

    Were you able to solve the issue? I am also having the same problem, when i try to read from IMAP. Only the email headers are present in the pipeline, when i try to debug. The contentStream is not visible. Plz help

    Thanks
    Anish,


    #Integration-Server-and-ESB
    #webMethods-General
    #webMethods