JornWildt / Ramone

A C# client framework for consuming HTTP/REST services
Other
61 stars 11 forks source link

Allow anonymous sessions #13

Closed JornWildt closed 10 years ago

JornWildt commented 10 years ago

Today we have to use a session:

ISession session = RamoneConfiguration.NewSession();

using (var response = session.Bind("some-url").Get())
{
  ...
}

It would be nice to do:

using (var response = new Request("some-url").Get())
{
}

or

using (var response = Request.Bind("some-url", new { ... }).Get())
{
}

The anonymous session would then be available on the Request object if needed.