var express = require('express');
var router = express.Router();
var pipe = require('../transformers/pipe');

router.post('/\\$cds-hook', function(req, res, next) {

    var context = {
        requestParams: req.query || {},
        language: "fi",
        nation: "fi",
        cards: ["reminders", "guidelink", "cmrlink"]
    };

    pipe.execute(req, res, next, context);
});

router.get('/\\$cds-hook-metadata', function(req, res, next) {

    res.json({
        "resourceType" : "Parameters",
        "parameter" : [{
            "name" : "name",
            "valueString" : "EBMeDS patient view"
        }, {
            "name" : "description",
            "valueString" : "EBMeDS patient view"
        }, {
            "name" : "activity",
            "valueCoding" : {
                "system" : "http://cds-hooks.smarthealthit.org/activity",
                "code" : "patient-view"
            }
        }
        ]
    });
});

module.exports = router;
@@ -238,18 +238,21 @@
 guage: %22
-fi
+en_US
 %22,%0A     
@@ -267,10 +267,10 @@
 n: %22
-fi
+US
 %22,%0A 

Change language to en_US for patient view API