Due to the popularization of Internet, widely distributed cooperative applications are expected to become commonplace on the Web. Virtual enterprises and mobile computing are good examples of such distributed applications. They both involve several actors connected together and needing to co-operate by sharing some (possibly unstable) data. To ensure consistency of shared data, traditional distributed systems are based on a client/server architecture. However, this implies that client activities have to be connected to the server continuously. This paper describes our approach to build distributed cooperative applications using a peer-to-peer architecture. An activity is viewed as a self contained component which cooperates with other components by exchanging, during its execution, some results. To ensure consistency of shared data, two activities have to negotiate a cooperation pattern first, which purpose is to control subsequent exchanges of these data between these two activities.