Visit Examples (Obsolete)

Examples of using the API

Obsolete

Visit class is obsolete. Please consider use of Visit2.

REST samples

These following REST examples were all run via Fiddler. For more information on Fiddler and SOAP samples please refer to our Samples page.


JSON POST

http://devs.patient-inquiry.com/visit/json/?Api-Key=a8e09fcb-76d4-4912-be4c-6ed3bcd1e93a

  User-Agent: Fiddler
  Content-Type: text/json

  {
    "ClinicianType":"PT",
    "ExternalEpisodeId":"YourEpisodeID",
    "MinutesSpent":30,
    "VisitDate":"\/Date(928164000000-0400)\/"
  }

Response

  [{
    "EpisodeId":1596,
    "ExternalEpisodeId":"YourEpisodeID",
    "MessageID":714,
    "Success":true,
    "Text":null,
    "VisitId":1
  }]

JSON DELETE

http://devs.patient-inquiry.com/visit/json/1?Api-Key=a8e09fcb-76d4-4912-be4c-6ed3bcd1e93a

  User-Agent: Fiddler
  Content-Type: text/json

Response

  {
    "EpisodeId":1596,
    "ExternalEpisodeId":"YourEpisodeID",
    "MessageID":715,
    "Success":true,
    "Text":null,
    "VisitId":1
  }

SOAP Samples

Our SOAP testing application is built as a Windows console application in VS2010. Feel free to download our SOAP Testing Client using the link below and use it as a starting point for your implementation. If you have used web services via WCF before, then this should look familiar. A key item to pay attention to is the CustomMessageInspector.cs, which is responsible for inserting the API Key into the header.

Download