PokitDok Platform Client for C# Consumes the REST based PokitDok platform API https://platform.pokitdok.com/documentation/v4#/#overview
Inheritance: OauthApplicationClient, IDisposable
Esempio n. 1
0
        static void Main(string[] args)
        {
            OauthAccessToken token = getToken();

            PlatformClient client = new PlatformClient(
                clientId: "",
                clientSecret: ""
            );

            // Example activities query
            ResponseData activity = client.activities();
            print_response(activity, "all current activities");

            // Example providers query
            ResponseData resp = client.providers("1467560003");
            print_response(resp, "provider");

            // Example appointments query
            resp = client.appointments(new Dictionary<string, string> {
                {"patient_uuid", "769cf5a1-e848-4ba5-a670-ab1d3a4c4fd4"},
                {"start_date", "2015-02-01T08:00:00"},
                {"end_date", "2015-02-15T17:00:00"},
                {"appointment_type", ""}
            });
            print_response(resp, "appointments");

            // Example pharmacy APIs
            resp = client.pharmacyPlans(new Dictionary<string, string> {
                {"trading_partner_id", "medicare_national"},
                {"plan_number", "S5601034"}
            });
            print_response(resp, "plans");

            resp = client.pharmacyFormulary(new Dictionary<string, string> {
                {"trading_partner_id", "medicare_national"},
                {"plan_number", "H2256001"},
                {"drug",  "virazole"}
            });
            print_response(resp, "formulary");

            resp = client.pharmacyNetwork(new Dictionary<string, string> {
                {"trading_partner_id", "medicare_national"},
                {"plan_number", "S5601034"},
                {"pharmacy_type", "retail"}
            });
            print_response(resp, "network");

            resp = client.pharmacyNetwork("1275827032",
                new Dictionary<string, string> {
                {"trading_partner_id", "medicare_national"},
                {"plan_number", "S5601034"},
                });
            print_response(resp, "networkNPI");

            client.Dispose();
        }
 public void Init()
 {
     client = new PlatformClient(
         "dB6bOvgCNOAhKt5lWir1",
         "aLSjaEkr9H2f74Zk2lTB6yPlaL5j1sH53wv0gzp0"
     );
     client.ApiSite = "https://platform.pokitdok.com";
     client.Authenticate();
 }