Expand my Community achievements bar.

We are excited to introduce our latest innovation to enhance the Adobe Campaign user experience — the Adobe Campaign v8 Web User Interface!
SOLVED

provide a web service which can recreate the sent messages using message template and campaign data and return it in a HTML or file formats.

Avatar

Level 1

We need to provide a web service which can recreate the sent messages using message template and campaign data and return it in a HTML or file formats. Is this possible? If yes, how?

1 Accepted Solution

Avatar

Correct answer by
Employee Advisor

Hi Karthick,

Why not use the available feature in Campaign i.e. email archiving.

https://docs.campaign.adobe.com/doc/AC6.1/en/INS_Additional_configurations__Email_deliverability.htm...

Search for term bcc and it will give you an idea where campaign creates a copy EML for every message sent. 

Regards,

Vipul

View solution in original post

3 Replies

Avatar

Correct answer by
Employee Advisor

Hi Karthick,

Why not use the available feature in Campaign i.e. email archiving.

https://docs.campaign.adobe.com/doc/AC6.1/en/INS_Additional_configurations__Email_deliverability.htm...

Search for term bcc and it will give you an idea where campaign creates a copy EML for every message sent. 

Regards,

Vipul

Avatar

Level 10

Hi,
 
In case you have generated the mirror page on your email, then you can retrive the html data using a custom code.

write the following code as a javascript method and enable that as a  web service either using jssp page or via soap method in a schema.
 

//--------------------------------------------------------------------------- // function to build html delivery mirror page //--------------------------------------------------------------------------- function genrateDeliveryHtml(delivery, serverURL) { var sg = new StringGroup("nms:campaign"); if( String(delivery.mapping.storage.@broadLogSchema) == "" ) return "<p>" + sg.noRenderingLabel() + "</p>" // Collect broadlogs which come from last proofed delivery var queryBroadLog = xtk.queryDef.create( < queryDef schema={delivery.mapping.storage.@broadLogSchema} operation="select" lineCount="5"> < select> < node expr="@id"/> < node expr="[@delivery-id]"/> < node expr="[delivery/properties/@midRemoteId]"/> < node expr="@address"/> < node expr="[delivery/@mirrorURL]"/> < /select> < where> < condition expr={"[delivery/@proofedDelivery-id]="+delivery.@id}/> < condition expr={"@status IN ("+DELIVERY_STATUS_SENT+","+DELIVERY_STATUS_TOSENT+")"}/> < /where> < orderBy> < node expr="[delivery/@lastModified]" sortDesc="true"/> < /orderBy> < /queryDef>) var iCompt = 0 var strHtmlContent = "" var broadLogList = queryBroadLog.ExecuteQuery() var strBroadLog = delivery.mapping.storage.@broadLogSchema.toString() strBroadLog = strBroadLog.substring(strBroadLog.indexOf(':')+1) // Calculate mapping suffix var iDeliveryId = 0 for (var i=0; i<broadLogList[strBroadLog].length(); i++) { var eBroadLog = broadLogList[strBroadLog][i] var strUrl = eBroadLog.delivery.@mirrorURL if ((strUrl == "" || strUrl == undefined) && serverURL != "") strUrl = serverURL strUrl += "/nl/jsp/m.jsp?c=" var iCurrentDeliveryId = eBroadLog.delivery.properties.@midRemoteId if (iCurrentDeliveryId == 0) iCurrentDeliveryId = eBroadLog.@["delivery-id"] if (iDeliveryId != 0 && iDeliveryId != iCurrentDeliveryId) break else if (iDeliveryId == 0) iDeliveryId = iCurrentDeliveryId // Show mirror page links if delivery is not in midsourcing if (strHtmlContent != "") strHtmlContent += "<br/>" strHtmlContent += "<img src='"+serverURL+"/xtk/img/html.png' border='0' style='vertical-align:middle'/>" strHtmlContent += " <a target='_blank' class='linkProcess' href='"+strUrl+'{'+simpleRevCrypt(iDeliveryId, eBroadLog.@id)+"}'>"+sg.previewHTMLLabel(eBroadLog.@address)+"</a>" } return strHtmlContent }

alternatively, If you wish to keep a copy of every email sent from your system, you will have to buy a feature called Email archiving. Please read more about id by reading the documentation Email deliverability.(https://forums.adobe.com/thread/2224900)
 
This is a paid feature and can have increased load on your MTA. It will generate EML files for every email sent which you can then export using sftp to a server of choice and then use on your web application.
 

Regards,
Amit

Avatar

Level 2

Hi Karthick,

I have the same requirement for my client to recreate the same email content sent to the customer and store it in a file for retrieval purpose.

Were you able to recreate the content and return in HTML files?

If yes, Can you please let me know the details ..

Thanks,Kumar