-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathReadme.html
58 lines (43 loc) · 1.93 KB
/
Readme.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta name="keywords" content="MultiMarkdown, Markdown, XML, XHTML, XSLT, PDF"/>
<link type="text/css" rel="stylesheet" href="css/print.css"/>
<link type="text/css" rel="stylesheet" href="css/doc-less.css"/>
</head>
<body>
<p>Feel free to download and mess around with this app, it may or may not be updated regularly, when it is we will publicise on our twitter feed (@BlueVia)</p>
<h2 id="getyournode.jsenvironmentprepared">Get your Node.js environment prepared</h2>
<p>The sample has been tested with Node.js v0.4.12 and should work with v0.4.x .
It needs 5 node modules that can be installed with ‘npm’:</p>
<ul>
<li>mime</li>
<li>qs</li>
<li>connect</li>
<li>express</li>
<li>ejs</li>
</ul>
<p>plus the files</p>
<ul>
<li>oauth.js</li>
<li>sha1.js</li>
<li>_utils.js</li>
</ul>
<p>from <a href="https://github.com/alfredwesterveld/node-auth.git">https://github.com/alfredwesterveld/node-auth.git</a>: </p>
<h2 id="setupandpersonalsettings">Setup and personal settings</h2>
<p>At the beginning of ‘server.js’ 4 variables have to be adapted</p>
<pre><code> // CONFIG
var consumerKey = "xxxxxxxxxxxxxxxx";
var consumerSecret = "xxxxxxxxxxxx";
var callbackUrl = "http://localhost:3000/accesstoken";
var sandbox = "_Sandbox";
</code></pre>
<p>Add your BlueVia consumer credentials, check whether you keep on using port 3000 and change “_Sandbox” to "" if you want to test against the real mobile network</p>
<h2 id="starttheserveranduseit">Start the server and use it</h2>
<p>Go to the terminal and call</p>
<pre><code> node server.js
</code></pre>
<p>and then browse to http://localhost:3000 if yopu haven’t changed the port. It immediately will start with the authorization steps at BlueVia.</p>
</body>
</html>