wm.tn.doc:view - runtime exception

Hi,

I am getting a runtime exception (in red below) when I invoke the wm.tn.doc:view service.

You do not have the authority to retrieve this document. Only administrators may access documents that they did not send or receive

To summarise, I am invoking the wm.tn.doc:view service when I receive the acknowledgement back from the partner to get the bizdoc of the original ebXML payload message.

[FONT=Arial][COLOR=#0000ff]

Steps:
1. The service is invoked by the processing rule ‘ebXML Acknowledgment’ when TN receives an acknowledgement message
2. I get the document id of the ebXML payload message from the eb:RefToMessageId tag from the ebXML envelope of the Acknowledgement message (attached).
3. Invoke the wm.tn.query:createDocumentQuery service to build the query using the document id.
4. Invoke the wm.tn.query:documentQuery service to get the results which has the internal TN document id of the original ebXML message for which I have received the Acknowledgement.
5. Once I have the internal document id of the original ebXML message for which I have received the acknowledgement I invoke the wm.tn.doc:view service to retrieve the biz doc of the original ebXML message.

I get the run time exception at step 5 with the error message below. When I execute the service from developer it works fine, but that is because I am logged in with the administrator user.


You do not have the authority to retrieve this document. Only administrators may access documents that they did not send or receive

[COLOR=#ff0000]

Since the original ebXML message was sent between the same partners I was not expecting to get this error at runtime.

Any ideas?

Thanks,
Gaurav.

[/COLOR]

[/COLOR][/FONT]

Instead can you try using with wm.tn.doc:viewAs (a newly wM TN7.1 added service),it should resolve.


HTH,
RMG

Hi RMG,

Thanks a lot for suggesting the alternative service, it is working now :slight_smile:

Gaurav.

your welcome!