I developed an application that imports many .wsdl files in order to have access to call several methods on a web service. I used Visual Studio's Add Service Reference and followed the instructions to have access to the services. In the end, I was left with the following app.config file, and I was wondering if there was a way to refactor the application so that I don't have to repeat all these endpoints. Note that all the endpoints are the same except for the value of the contract attribute.
<client>
<endpoint address="https://xxx.yyy.com:10803" behaviorConfiguration="clientEndpointCredential"
binding="basicHttpBinding" bindingConfiguration="bsapi_binding"
contract="CriteriaList.bsapi_port" name="bsapi_port" />
<endpoint address="https://xxx.yyy.com:10803" behaviorConfiguration="clientEndpointCredential"
binding="basicHttpBinding" bindingConfiguration="bsapi_binding"
contract="ContainerList.bsapi_port" name="bsapi_port" />
<endpoint address="https://xxx.yyy.com:10803" behaviorConfiguration="clientEndpointCredential"
binding="basicHttpBinding" bindingConfiguration="bsapi_binding"
contract="DisplayUnitList.bsapi_port" name="bsapi_port" />
<endpoint address="https://xxx.yyy.com:10803" behaviorConfiguration="clientEndpointCredential"
binding="basicHttpBinding" bindingConfiguration="bsapi_binding"
contract="DomainList.bsapi_port" name="bsapi_port" />
<endpoint address="https://xxx.yyy.com:10803" behaviorConfiguration="clientEndpointCredential"
binding="basicHttpBinding" bindingConfiguration="bsapi_binding"
contract="ResourceCriteriaAdd.bsapi_port" name="bsapi_port" />
<endpoint address="https://xxx.yyy.com:10803" behaviorConfiguration="clientEndpointCredential"
binding="basicHttpBinding" bindingConfiguration="bsapi_binding"
contract="ResourceCriteriaUpdate.bsapi_port" name="bsapi_port" />
<endpoint address="https://xxx.yyy.com:10803" behaviorConfiguration="clientEndpointCredential"
binding="basicHttpBinding" bindingConfiguration="bsapi_binding"
contract="ResourceCriteriaList.bsapi_port" name="bsapi_port" />
<endpoint address="https://xxx.yyy.com:10803" behaviorConfiguration="clientEndpointCredential"
binding="basicHttpBinding" bindingConfiguration="bsapi_binding"
contract="ResourceCriteriaListByCriteriaId.bsapi_port" name="bsapi_port" />
</client>