What is the point in a WSDL with a rest based service?

后端 未结 3 484
感情败类
感情败类 2021-01-18 15:57

If REST based web services are as simple as GETing and POSTing to a url and parsing the response wht exactly do we need a wsdl? Whats the point. I understand that when using

3条回答
  •  心在旅途
    2021-01-18 16:26

    There is no point in WSDL for REST services created with WCF because WCF supports only WSDL 1.1 (or 1.0) which cannot describe REST seevice. If you try to use WSDL generated for WCF REST service to create a client proxy you will not be able to call the service anyway. Visual studio templates for REST don't expose metadata so you will get useless WSDL only if you add serviceMetada behavior (and possibly also mex endpoint) yourselves.

    WSDL 2.0 and WADL supports description of REST services and the point is similar as with SOAP services - describe what you can do with the service but in the REST way.

提交回复
热议问题