Hi.
you can suggest you customer to stop sending 997 for your 855/810.
do you want to consider 997 at ECC level? if yes find the case 1, else case2 and case 3 are optional.
case 1.
usually inbound 997 required to reconcile at ECC end for outgoing message 855/810 accepted/rejected through inbound 997. you can create a RFC for inbound 997, and finally your scenario will be.
for 855 --> IDOC------PI------AS2(855)
for 997 --> AS2 - > EDISeparator
EDISeparator -> RFC
so create a EdiSeparator sender channel for inbound 997 and fill only receiver IDs.
note: pass your IDOC number in GS06 element, and you'll get the same in inbound 997, so based on IDOC# you can store the status in RFC, and do study on 997 transaction set that will helps you.
2. case 2.
pass your inbound 997 and to server and create batch program to delete the 997 file every day.
for 997 AS2 - > EDISeparator
EDISeparator -> File
3. using TPM you may achieve this issue, but i'm not sure. lets wait for others comment.