Closed
Description
version:Refit.6.0.15.nupkg
netframework:4.8
using System.Threading.Tasks;
using Refit;
namespace SnapOffline
{
public interface IWtApi
{
[Post("/xx/showreport.asp")]
Task<ResponseShowReport> ShowReport([Body(BodySerializationMethod.UrlEncoded)]
RequestShowReport req);
}
}
System.InvalidOperationException: IWtApi doesn't look like a Refit interface. Make sure it has at least one method with a Refit HTTP method attribute and Refit is installed in the project.
在 Refit.RestService.GetGeneratedType(Type refitInterfaceType) 位置 /_/Refit/RestService.cs:行号 100
在 Refit.RestService.For(Type refitInterfaceType, HttpClient client, IRequestBuilder builder) 位置 /_/Refit/RestService.cs:行号 36
在 Refit.RestService.For[T](HttpClient client, IRequestBuilder`1 builder) 位置 /_/Refit/RestService.cs:行号 13
在 Refit.RestService.For[T](HttpClient client, RefitSettings settings) 位置 /_/Refit/RestService.cs:行号 20
在 Refit.RestService.For[T](HttpClient client) 位置 /_/Refit/RestService.cs:行号 23
在 SnapOffline.Program.Main(String[] args) 位置 E:\work\med\MedSnap\weitong\Snap\SnapOffline\Program.cs:行号 23