Due to the fast advancement of network technologies, the study of service-oriented architectures (SOA) has attracted much attention recently, taking advantage of the benefits of distributed computing and integration. Web service is a very popular and widely accepted implementation of SOA. The use of Web services holds the advantages of a loosely-coupled system where all components can be developed at independent platforms and be connected with the Web service protocols via the network. However, the tendency for methods of applying Web services over the network is getting more and more complex. Many applications rely on not just one Web service, but a whole school of them. Thus, how to compose and integrate different Web services efficiently to provide complicated network services has become an essential topic in system development and design. This paper proposes a new problem which investigates the possibility of minimizing the number of hops of Web services while trying to finish a set of tasks. It also provides a polynomial-time, optimal Web service integration method using greedy strategy to integrate the Web services in order to complete those tasks. This method can achieve the goal of using the minimum number of hops of Web services over the network.