Skip to content

Instantly share code, notes, and snippets.

@fasetto
Created April 26, 2017 15:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save fasetto/78b97aa131288097a3ae27e8fba30ca2 to your computer and use it in GitHub Desktop.
Save fasetto/78b97aa131288097a3ae27e8fba30ca2 to your computer and use it in GitHub Desktop.
[Route("/hello/{Name}", "GET")]
public class HelloRequest : IReturn<HelloResponse>
{
public string Name { get; set; }
}
public class HelloResponse
{
public string Result { get; set; }
}
public class HelloService : Service
{
public object GET(HelloRequest request)
{
return new HelloResponse { Result = $"Hello, {request.Name}" };
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment