CMS Examples

Examples of using the CMS API

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/cms/json/?Api-Key=a8e09fcb-76d4-4912-be4c-6ed3bcd1e93a
User-Agent: Fiddler
Content-Type: text/json
[{
	"ExternalEpisodeId": "25453",
	"ExternalPatientId": "456",
	"FirstName": "Test",
	"LastName": "Patient",
	"Alias": "78",
	"DateOfBirth": "/Date(1068451200000-0800)\/",
	"BodyPartId": "12",
	"NPI": "1234567890",
	"TIN": "123456789",
	"Visits":[
		{
			"ExternalVisitId": "6237",
			"Date": "\/Date(1535428800000-0400)\/",
			"CPTHCPCSCodes": ["99213", "88510"],
			"NPI": "1234567890",
			"TIN": "123456789",
			"IsMedicare":true,
			"ICD10Codes": ["M60.031", "M60.032", "M89.029"]
		},
		{
			"ExternalVisitId": "6268",
			"Date": "\/Date(1535428800000-0400)\/",
			"CPTHCPCSCodes": ["99214", "88510"],
			"NPI": "1234567890",
			"TIN": "123456789",
			"IsMedicare":true,
			"ICD10Codes": [ "M60.032", "M60.031", "M89.029"]
		}
		]
}]

JSON PUT

http://devs.patient-inquiry.com/cms/json/?Api-Key=a8e09fcb-76d4-4912-be4c-6ed3bcd1e93a
User-Agent: Fiddler
Content-Type: text/json
{
	"ExternalEpisodeId": "25453",
	"ExternalPatientId": "456",
	"FirstName": "Test",
	"LastName": "Patient",
	"Alias": "78",
	"DateOfBirth": "/Date(1068451200000-0800)\/",
	"BodyPartId": "12",
	"NPI": "1234567890",
	"TIN": "123456789",
	"Visits":[
		{
			"ExternalVisitId": "6237",
			"Date": "\/Date(1535428800000-0400)\/",
			"CPTHCPCSCodes": ["99213", "88510"],
			"NPI": "1234567890",
			"TIN": "123456789",
			"IsMedicare":true,
			"ICD10Codes": ["M60.031", "M60.032", "M89.029"]
		},
		{
			"ExternalVisitId": "6268",
			"Date": "\/Date(1535428800000-0400)\/",
			"CPTHCPCSCodes": ["99214", "88510"],
			"NPI": "1234567890",
			"TIN": "123456789",
			"IsMedicare":true,
			"ICD10Codes": [ "M60.032", "M60.031", "M89.029"]
		}
		]
}

JSON DELETE

http://devs.patient-inquiry.com/cms/json/<ExternalEpisodeId>?Api-Key=d96f83d9-a25d-4a13-941b-332c022634b1
User-Agent: Fiddler
Content-Type: text/json

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