Installing the ServiceStackVS Extension for Visual Studio



About


Whether you're using C# or VB.NET, you can add the ServiceStackVS extension to Visual Studio which will add the references needed to use the ServiceStack client, and also visit the REST API and retrieve all the DTO classes and place them in a file, accessible to your code.

No need to generate the DTO's or copy-paste.



Steps




  1. Install the ServiceStackVS extension

  2. Add the nuget package ServiceStack.Client

  3. Add References to System.Runtime.Serialization and System.Net

  4. Right-click on the project and choose "Add ServiceStack Reference..."

  5. Enter the address of the host and name the service

A file (JiwaServiceReference.dtos.cs or JiwaServiceReference.dtos.vb) will be added to your project containing all the DTO's you'll need to consume the REST API.