<commit_before>var express = require('express');
var router = express.Router();

/* GET home page. */
router.get('/', function(req, res, next) {
  res.render('index', { title: 'Express' });
});

router.get('/api/message', function(req, res, next) {

	request({
		url: "https://api.particle.io/v1/devices/stranger_electron/message",
		method: "POST",
		form: {
			arg: request.body,
			access_token: process.env.PARTICLE_ACCESS_TOKEN
		}
	}, function (error, response, body) {

		if (error) {
			res.send("<Response><Message>Something went wrong...</Message></Response>");
		}<commit_msg>tweaking get / post<commit_after>var express = require('express');
var router = express.Router();

/* GET home page. */
router.get('/', function(req, res, next) {
  res.render('index', { title: 'Express' });
});

router.get('/api/message', function(req, res, next) {

	request({
		url: "https://api.particle.io/v1/devices/stranger_electron/message",
		method: "POST",
		form: {
			arg: request.param.message,
			access_token: process.env.PARTICLE_ACCESS_TOKEN
		}
	}, function (error, response, body) {

		if (error) {
			res.send("<Response><Message>Something went wrong...</Message></Response>");
		}
		else {
			res.send("<Response><Message>Got it!</Message></Response>");
		}
	});
});


router.post('/api/message', function(req, res, next) {

	request({
		url: "https://api.particle.io/v1/devices/stranger_electron/message",
		method: "POST",
		form: {
			arg: request.body,
			access_token: process.env.PARTICLE_ACCESS_TOKEN
		}
	}, function (error, response, body) {

		if (error) {
			res.send("<Response><Message>Something went wrong...</Message></Response>");
		}
{'fraction_non_alphanumeric': 0.19710669077757687, 'fraction_numerical': 0.0018083182640144665, 'mean_word_length': 4.2037617554858935, 'pattern_counts': {'":': 0, '<': 19, '<?xml version=': 0, '>': 19, 'https://': 3, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7211727', 'n_tokens_mistral': 606, 'n_tokens_neox': 556, 'n_words': 106}