You can import the BAPI in SAP PI Enterprise Service Repository (ESR) and create an interface using that. Then you can create an integrated configuration in SAP PI Integration Directory (ID) using the interface and get WSDL URL.
You can provide the WSDL URL to the third-party system. Now you successfully exposed the BAPI as a SOAP web service to the third-party system.
If you have any questions, please don't hesitate to Contact us
Account General