Resource trading between client and server