这很好用,我可以省略Speed参数:
[Route("/speech/sentence/", "POST")]
public class Sentence : IReturn<HttpResult>
{
public string Input { get; set; }
public string Speed { get; set; }
}
这不起作用,得到一个&#39; HTTP / 1.1 400错误请求&#39;无法省略Speed参数:
[Route("/speech/sentence/", "POST")]
public class Sentence : IReturn<HttpResult>
{
public string Input { get; set; }
public int Speed { get; set; }
}
这也不起作用,得到一个&#39; HTTP / 1.1 400 Bad Request&#39;无法省略Speed参数:
[Route("/speech/sentence/", "POST")]
public class Sentence : IReturn<HttpResult>
{
public string Input { get; set; }
public int? Speed { get; set; }
}
任何? 感谢