You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
I have a service that exposes an API that isn't very ergonomic. We see callers repeatedly writing the same 5 lines to interact with the service. We'd like to make it easier by adding a default method to our Refit interface that does the logic of those 5 lines, which includes calling a Refit-annotated method.
interfaceMine{[Get("/events.json")]Task<Events>GetEvents(stringquery);Task<Events>GetEventsOrDefault(stringquery){try{
GetEvents(query);}catch(ApiExceptione){// Look at exception for Reasons}}
Describe the solution you'd like
Right now, Refit errors with the message, "System.NotImplementedException : Either this method has no Refit HTTP method attribute or you've used something other than a string literal for the 'path' argument."
#845 Had a fix for static default methods, but it does not appear to address default instance methods.
Describe alternatives you've considered
For now we're using an extension method
The text was updated successfully, but these errors were encountered:
Is your feature request related to a problem? Please describe.
I have a service that exposes an API that isn't very ergonomic. We see callers repeatedly writing the same 5 lines to interact with the service. We'd like to make it easier by adding a default method to our Refit interface that does the logic of those 5 lines, which includes calling a Refit-annotated method.
Describe the solution you'd like
Right now, Refit errors with the message, "System.NotImplementedException : Either this method has no Refit HTTP method attribute or you've used something other than a string literal for the 'path' argument."
#845 Had a fix for static default methods, but it does not appear to address default instance methods.
Describe alternatives you've considered
For now we're using an extension method
The text was updated successfully, but these errors were encountered: