Attachment Service
Attachment Service
The ERP Object Attachment Service supports the automatic upload and download of attachments
to and from Oracle ERP Cloud business applications. An attachment represents a collection of
meaningful business information that is commonly captured as a separate file, text, or Internet
URL. Attachments are used to supplement and provide key additional information to enhance
daily business operations and better track financials activities or events.
Business enterprises often require the capability to efficiently associate specific attachments with
a particular business entity or collection of business entities. For example:
The ERP Object Attachment Service delivers this real-time automated capability starting in
Oracle ERP Cloud Release 11 Patch Bundle 13.
Security Considerations
The ERP Object Attachment Service is secured through Oracle Web Service Manager (OWSM)
using the following policy:
oracle/wss11_saml_or_username_token_with_message_protection_service_policy.
The client must satisfy the message protection policy to ensure that the payload is encrypted or
sent over the SSL transport layer.
For illustration, to obtain the physical end point of any specific instance as a basis for the end
point URL:
“https://<hostname>.<domainname>/publicFinancialCommonErpIntegration/
ErpObjectAttachmentService” is the WSDL URL for the Oracle ERP Object Attachment
Service.
Operation: uploadAttachment
The uploadAttachment operation uploads a file to the Oracle WebCenter Content (UCM) server
based on the document details specified and submits an ESS job to load and import the uploaded
files to an application table.
Paramete
Parameter
r Mandator
Description Type
y
Name
(In/Out)
Entity Name of the attachment
User Keys
The ERP Object Attachment Service supports up to five user keys as UserKeyA, UserKeyB,
UserKeyC, UserKeyD, and UserKeyE. These keys could provide different qualifying business
contexts for a chosen entity such as business units, legal entities, ledgers, etc.
Sample Payload
The following example illustrates the sample payload to upload an attachment to a payables
invoice:
<soap:Body>
<ns1:uploadAttachment
xmlns:ns1="http://xmlns.oracle.com/apps/financials/commonModules/shared/
model/erpIntegrationService/types/">
<ns1:entityName>AP_INVOICES_ALL</ns1:entityName>
<ns1:categoryName>AP_SUPPORTING_DOC</ns1:categoryName>
<ns1:allowDuplicate>yes</ns1:allowDuplicate>
<ns1:attachmentRows
xmlns:ns2="http://xmlns.oracle.com/apps/financials/commonModules/shared/
model/erpIntegrationService/">
<ns2:UserKeyA>Vision
Operations</ns2:UserKeyA>
<ns2:UserKeyB>SBP26</ns2:UserKeyB>
<ns2:UserKeyC>1377245736</ns2:UserKeyC>
<ns2:UserKeyD>#NULL</ns2:UserKeyD>
<ns2:UserKeyE>#NULL</ns2:UserKeyE>
<ns2:AttachmentType>TEXT</ns2:AttachmentType>
<ns2:Title>Sample</ns2:Title>
<ns2:Content>Testing Text</ns2:Content>
</ns1:attachmentRows>
<ns1:attachmentRows
xmlns:ns2="http://xmlns.oracle.com/apps/financials/commonModules/shared/
model/erpIntegrationService/">
<ns2:UserKeyA>Vision
Operations</ns2:UserKeyA>
<ns2:UserKeyB>SBP26</ns2:UserKeyB>
<ns2:UserKeyC>1377245736</ns2:UserKeyC>
<ns2:UserKeyD>#NULL</ns2:UserKeyD>
<ns2:UserKeyE>#NULL</ns2:UserKeyE>
<ns2:AttachmentType>FILE</ns2:AttachmentType>
<ns2:Title>SampleFILE.txt</ns2:Title>
<ns2:Content>VGhpcyBpcyBhIHNhbXBsZSBmaWxlIHRvIHRlbWVudCBvcGVyJTEUuDQo=</
ns2:Content>
</ns1:attachmentRows>
</ns1:uploadAttachment>
</soap:Body>
Sample Response
<env:Body xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-
wssecurity-utility-1.0.xsd" wsu:Id="Body-7Us3sWti6wcgpuLGJ1ixLw22">
<ns0:uploadAttachmentResponse
xmlns:ns0="http://xmlns.oracle.com/apps/financials/commonModules/shared/
model/erpIntegrationService/types/">
<result
xmlns="http://xmlns.oracle.com/apps/financials/commonModules/shared/model/
erpIntegrationService/
types/">"Attachment1":"SUCCEEDED","Attachment2":"SUCCEEDED"</result>
</ns0:uploadAttachmentResponse>
</env:Body>
Operation: downloadAttachment
The downAttachment operation download attachments from Oracle ERP Cloud. The attachments
are stored in Oracle WebCenter Content (UCM) server.
Paramete
Parameter
r Mandator
Description Type
y
Name
(In/Out)
Entity Name of the attachment
Content
User Keys
The ERP Object Attachment Service supports up to five user keys as UserKeyA, UserKeyB,
UserKeyC, UserKeyD, and UserKeyE. These keys could provide different qualifying business
contexts for a chosen entity such as business units, legal entities, ledgers, etc.
Sample Payload
The following example illustrates the sample payload to upload an attachment to a payables
invoice:
<soap:Body>
<ns1:downloadAttachment xmlns:ns1="http://xmlns.oracle.com/apps/financials/
commonModules/shared/model/erpIntegrationService/types/">
<ns1:attachment xmlns:ns2="http://xmlns.oracle.com/oracle/apps/financials/
commonModules/shared/model/erpIntegrationService/">
<ns2:EntityName>AP_INVOICES_ALL</ns2:EntityName>
<ns2:CategoryName>AP_SUPPORTING_DOC</ns2:CategoryName>
<ns2:UserKeyA>Vision Operations</ns2:UserKeyA>
<ns2:UserKeyB>SBP26</ns2:UserKeyB>
<ns2:UserKeyC>1377245736</ns2:UserKeyC>
<ns2:UserKeyD>#NULL</ns2:UserKeyD>
<ns2:UserKeyE>#NULL</ns2:UserKeyE>
</ns1:attachment>
</ns1:downloadAttachment>
</soap:Body>
Sample Response
<env:Body xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-
utility-1.0.xsd" wsu:Id="Body-JrKcnQO298dMjx93m40Lrg22">
<ns0:downloadAttachmentResponse xmlns:ns0="http://xmlns.oracle.com/apps/
financials/commonModules/shared/model/erpIntegrationService/types/">
<ns1:result xmlns:ns1="http://xmlns.oracle.com/apps/financials/commonModules/
shared/model/erpIntegrationService/types/" xmlns:ns0="http://xmlns.oracle.com/oracle/apps/
financials/commonModules/shared/model/erpIntegrationService/" xmlns:xsi="http://
www.w3.org/2001/XMLSchema-instance" xsi:type="ns0:DownloadedAttachment">
<ns0:AttachmentType>FILE</ns0:AttachmentType>
<ns0:AttachmentContent>MTIzNCxUaWNrZXREDQoyMzQ1LFRpY2tldEUNCjQz
NDUsVGlja2V0Rg0K</ns0:AttachmentContent>
<ns0:FileName>abc.txt</ns0:FileName>
</ns1:result>
<ns1:result xmlns:ns1="http://xmlns.oracle.com/apps/financials/commonModules/
shared/model/erpIntegrationService/types/" xmlns:ns0="http://xmlns.oracle.com/oracle/apps/
financials/commonModules/shared/model/erpIntegrationService/" xmlns:xsi="http://
www.w3.org/2001/XMLSchema-instance" xsi:type="ns0:DownloadedAttachment">
<ns0:AttachmentType>FILE</ns0:AttachmentType>
<ns0:AttachmentContent>MTIzNCxUaWNrZXREDQoyMzQ1LFRpY2tldEUNCjQz
NDUsVGlja2V0Rg0K</ns0:AttachmentContent>
<ns0:FileName>xyz.doc</ns0:FileName>
</ns1:result>
<ns1:result xmlns:ns1="http://xmlns.oracle.com/apps/financials/commonModules/
shared/model/erpIntegrationService/types/" xmlns:ns0="http://xmlns.oracle.com/oracle/apps/
financials/commonModules/shared/model/erpIntegrationService/" xmlns:xsi="http://
www.w3.org/2001/XMLSchema-instance" xsi:type="ns0:DownloadedAttachment">
<ns0:AttachmentType>FILE</ns0:AttachmentType>
<ns0:AttachmentContent>MTIzNCxUaWNrZXREDQoyMzQ1LFRpY2tldEUNCjQz
NDUsVGlja2V0Rg0K</ns0:AttachmentContent>
<ns0:FileName>pqr.pdf</ns0:FileName>
</ns1:result>
<ns1:result xmlns:ns1="http://xmlns.oracle.com/apps/financials/commonModules/
shared/model/erpIntegrationService/types/" xmlns:ns0="http://xmlns.oracle.com/oracle/apps/
financials/commonModules/shared/model/erpIntegrationService/" xmlns:xsi="http://
www.w3.org/2001/XMLSchema-instance" xsi:type="ns0:DownloadedAttachment">
<ns0:AttachmentType>WEB_PAGE</ns0:AttachmentType>
<ns0:AttachmentContent>WzIwMTUtMDMtMDRUMTY6Mjk6MDEuOTM0KzAw
OjAwXSBbVUNNX3Nlcn</ns0:AttachmentContent>
<ns0:FileName></ns0:FileName>
</ns1:result>
<ns1:result xmlns:ns1="http://xmlns.oracle.com/apps/financials/commonModules/
shared/model/erpIntegrationService/types/" xmlns:ns0="http://xmlns.oracle.com/oracle/apps/
financials/commonModules/shared/model/erpIntegrationService/" xmlns:xsi="http://
www.w3.org/2001/XMLSchema-instance" xsi:type="ns0:DownloadedAttachment">
<ns0:AttachmentType>FILE</ns0:AttachmentType>
<ns0:AttachmentContent>IwojV2VkIFNlcCAyMSAwNDowNDo1MyBQRFQgMjAx
Ngo=</ns0:AttachmentContent>
<ns0:FileName>abc.txt</ns0:FileName>
</ns1:result>
<ns1:result xmlns:ns1="http://xmlns.oracle.com/apps/financials/commonModules/
shared/model/erpIntegrationService/types/" xmlns:ns0="http://xmlns.oracle.com/oracle/apps/
financials/commonModules/shared/model/erpIntegrationService/" xmlns:xsi="http://
www.w3.org/2001/XMLSchema-instance" xsi:type="ns0:DownloadedAttachment">
<ns0:AttachmentType>TEXT</ns0:AttachmentType>
<ns0:AttachmentContent>77u/SGkgVGhpcyBpcyBhdHRhY2hlZA==</
ns0:AttachmentContent>
<ns0:FileName>ABJGJKJDK</ns0:FileName>
</ns1:result>
</ns0:downloadAttachmentResponse>
</env:Body>
Conclusion
This summary highlights how to implement the ERP Object Attachment Service. It illustrates the
programmatic approach of uploading documents into the ERP Cloud from external systems. It
can be invoked through any integration platform.