You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This zip file contains the documentation for AT&T's HTML5 SDK which provides an HTML5 framework for calling the AT&T API Platform.
1
+
This ZIP file contains the documentation for the AT&T API Platform SDK for HTML5. This SDK provides an HTML5 framework for accessing the AT&T API Platform.
Copy file name to clipboardExpand all lines: sdk/doc_src/guides/sample_app_test/README.md
+14-14Lines changed: 14 additions & 14 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
#Using the Sample Apps
2
2
3
-
Now that you have completed setting up the server component of the SDK, you should be able to load the **Sample Apps** in your supported web browser.
3
+
Now that you have set up the server component of the SDK, you should be able to load the **Sample Apps** in your supported Web browser.
4
4
5
5
The following section describes how to test your connection to the AT&T APIs using each Sample App.
6
6
@@ -14,13 +14,13 @@ A user accessing In-App Messaging features will be presented with a Consent Requ
14
14
15
15
There are several authentication methods you may use, but the easiest and fastest method is using an AT&T device with an active wireless number, and send an authorization password to AT&T’s short code:
Make sure to select "Close window", because this way the user is redirected back to your application and the OAuth token is delivered to the server.
23
+
Make sure to select "Close window" to redirect the user back to your app and deliver the OAuth token to the server.
24
24
25
25
##Speech File to Text
26
26
Point your browser to this address:
@@ -36,29 +36,29 @@ Point your browser to this address:
36
36
37
37
Use the provided audio controls to record speech and submit the audio to view the resulting text from the AT&T Speech-to-Text API.
38
38
39
-
Note that your browser must support current web audio standards in order to use this sample.
39
+
Note that your browser must support current Web audio standards in order to use this sample.
40
40
41
41
##Text To Speech
42
42
Point your browser to this address:
43
43
44
44
http://{yourdomain}:{port}/Speech/App3/index.html
45
45
46
-
Type English text into the provided text input area, and tap submit to send the test to the AT&T Text-to-Speech API. Tap **Play converted speech** to hear the resulting audio.
46
+
Type English text into the provided text input area, and tap **Submit** to send the text to the AT&T Text-to-Speech API. Tap **Play converted speech** to hear the resulting audio.
47
47
48
48
##SMS
49
-
This sample app demonstrates SMS messages sent from and to your application.
49
+
This sample app demonstrates SMS messages sent from and to your app.
50
50
51
51
Point your browser to this address:
52
52
53
53
http://{yourdomain}:{port}/SMS/App1/index.html
54
54
55
-
This sample application showcases three different features. The first one, allows the app to send a short message to a given phone number: enter the _Phone Number_ and the _Message_ and press the **Send Message** button.
55
+
This sample app showcases three different features. The first one sends a short message to a given phone number: enter the _Phone Number_ and the _Message_ and press the **Send Message** button.
56
56
57
57
After sending your message, you will see a screen showing the **Message ID** that corresponds to the sent message.
58
58
59
59
To retrieve the status of the message, tap **Get Status**.
60
60
61
-
To check the messages sent to a specific short code, you must have at least one short code configured on your AT&T Developer Program application. To add a short code, open the configuration file at this location:
61
+
To check the messages sent to a specific short code, you must have at least one short code configured on your AT&T Developer Program app. To add a short code, open the configuration file at this location:
62
62
63
63
/webcontent/SMS/App1/app/Config.js
64
64
@@ -82,9 +82,9 @@ Point your browser to this address:
82
82
83
83
http://{yourdomain}:{port}/SMS/App2/index.html
84
84
85
-
This sample application demonstrates the callback functionality. In this sample, the app counts votes sent to a specific short code using specific test in the message body.
85
+
This sample app demonstrates the callback functionality. In this sample, the app counts votes sent to a specific short code using specific text in the message body.
86
86
87
-
To configure your short code on the application, open the configuration file at this location:
87
+
To configure your short code on the app, open the configuration file at this location:
88
88
89
89
/webcontent/SMS/App2/app/Config.js
90
90
@@ -97,7 +97,7 @@ Configure the parameters for the short code:
97
97
98
98
The app will count messages to the short code with the text **"Football"**, **"Basketball”**, or **"Baseball”**.
99
99
100
-
**Note** Make sure to configure the callback for your short code so it points to:
100
+
**Note:** Make sure to configure the callback for your short code so it points to:
101
101
102
102
http://{yourdomain}:{port}/att/sms/votelistener
103
103
@@ -108,7 +108,7 @@ Point your browser to this address:
108
108
109
109
http://{yourdomain}:{port}/MMS/App1/index.html
110
110
111
-
This sample application sends a multimedia message to a given phone number. Enter the _Phone Number_ and the _Message_, select an image from the _Chose File_ menu and tap **Send Message**.
111
+
This sample application sends a multimedia message to a given phone number. Enter the _Phone Number_ and the _Message_, select an image from the _Choose File_ menu and tap **Send Message**.
112
112
113
113
After sending a message, the app displays a **Message ID** corresponding to the message sent. To retrieve the status of the message, tap **Get Status**.
114
114
@@ -131,7 +131,7 @@ Configure the parameters for the short code:
131
131
shortCode : 'your short code here'
132
132
133
133
134
-
**Note** You must configure the callback for the short code in your application so that it points to this location:
134
+
**Note:** You must configure the callback for the short code in your application so that it points to this location:
Copy file name to clipboardExpand all lines: sdk/doc_src/guides/server_java/README.md
+21-21Lines changed: 21 additions & 21 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,23 +1,23 @@
1
1
HTML5 SDK Server (Java Implementation)
2
2
===
3
3
4
-
This guide provides instructions for creating a Web application using Java. At the end of this guide you will have a Java Web application that can connect to the APIs provided by AT&T.
4
+
This guide provides instructions for creating a Web app using Java. At the end of this guide you will have a Java Web app that can connect to the APIs provided by AT&T.
5
5
6
-
To simplify the deployment of the SDK using Java, we have included an embedded Jetty servlet container. The Java code is built using Apache Ant.
6
+
To simplify the deployment of the SDK using Java, we have included an embedded Jetty servlet container. The Java code is built using Apache Ant.
7
7
8
8
Prerequisites
9
9
----
10
10
11
11
- Java version 1.6 or later. You can obtain this from [http://java.com](http://java.com).
12
-
- Apache Ant version 1.8 or later
12
+
- Apache Ant version 1.8 or later.
13
13
14
14
- Optional:
15
-
- Eclipse Integrated Development Environment (IDE) for Java Developers
15
+
- Eclipse Integrated Development Environment (IDE) for Java Developers.
16
16
17
17
18
-
We have provided the .project and .classpath files that are needed to automatically create an Eclipse project. You can build and run the application using these files instead of using the command line instructions.
18
+
We have provided the .project and .classpath files that are needed to automatically create an Eclipse project. You can build and run the app using these files instead of using the command line instructions.
19
19
20
-
**Note:** Windows users follow the **Build and Run using Eclipse** instructions to build and run the SDK using Eclipse without needing to configure a commandline environment.
20
+
**Note:** Windows users follow the **Build and Run using Eclipse** instructions to build and run the SDK using Eclipse without needing to configure a command-line environment.
21
21
22
22
Run the following commands to build and start the Java server:
23
23
@@ -27,7 +27,7 @@ Run the following commands to build and start the Java server:
27
27
$ ant -version
28
28
Apache Ant(TM) version 1.8.2 compiled on February 28 2011
29
29
30
-
If you want to generate a .war file for deployment with a different servlet container, you can use the provided Ant build file. If you deploy the .war into a path below root, modify the _serverUrl = "/att" variable in att-api-client.js to include your path.
30
+
If you want to generate a .war file for deployment with a different servlet container, you can use the provided Ant build file. If you deploy the .war into a path below root, modify the _serverUrl = "/att" variable in att-api-client.js to include your path.
31
31
32
32
Java Server Documentation
33
33
---
@@ -39,7 +39,7 @@ Server configuration
39
39
Open the file sdk/server/java/conf/att-api.properties, find the following settings and customize them with the appropriate values:
40
40
41
41
# Replace these values with App Key and Secret found in your
42
-
# application
42
+
# app
43
43
AppKey=XXXXXX
44
44
Secret=XXXXXX
45
45
@@ -54,7 +54,7 @@ This SDK comes with a default set of self-signed certificates in the server/java
54
54
55
55
Note: Since these default certificates are self-signed, you will see a certificate warning the first time you access an SSL link on the SDK server. You can either continue on through the warning, or purchase secure server certificates.
56
56
57
-
A few of the samples demonstrate scenarios involving incoming notifications from AT&T, which require certificates whose domain name matches the actual name of the server hosting the samples. You can generate or obtain appropriate self-signed certificates or purchase registrar-signed certificates. If you use your own certificate files, there are detailed instructions for generating an updated .keystore file in server/java/certs/readme.txt.
57
+
A few of the samples demonstrate scenarios involving incoming notifications from AT&T, which require certificates whose domain name matches the actual name of the server hosting the samples. You can generate or obtain appropriate self-signed certificates or purchase registrar-signed certificates. If you use your own certificate files, there are detailed instructions for generating an updated .keystore file in server/java/certs/readme.txt.
58
58
59
59
60
60
Command Line (Mac, Linux, Unix)
@@ -63,10 +63,10 @@ Command Line (Mac, Linux, Unix)
63
63
Run using the command line
64
64
---
65
65
66
-
Once you have compiled the source code and created a .war file, you can run the application using Jetty. To deploy the .war file in a different Java servlet container such as Tomcat, copy the .war file from dist/att.war into your servlet container's deployment directory and follow your vendor's instructions for deploying .war files.
66
+
Once you have compiled the source code and created a .war file, you can run the app using Jetty. To deploy the .war file in a different Java servlet container such as Tomcat, copy the .war file from dist/att.war into your servlet container's deployment directory and follow your vendor's instructions for deploying .war files.
67
67
68
68
69
-
To run the application, using the included Jetty server, use the included shell script, by typing the following at a command prompt in the sdk/server/java directory:
69
+
To run the app using the included Jetty server, use the included shell script, by typing the following at a command prompt in the sdk/server/java directory:
70
70
71
71
$ sh run.sh
72
72
@@ -78,7 +78,7 @@ You can also use the 'nohup' command to run the server in the background (<http:
78
78
79
79
$ nohup sh run.sh &
80
80
81
-
The application should now be running on http://yourhost:4567/
81
+
The app should now be running on http://yourhost:4567/
82
82
83
83
To change the port number, pass a different port as the first argument:
84
84
@@ -90,15 +90,15 @@ Stopping the server
90
90
If you run the server as an interactive process you must end the process manually using control-c.
91
91
If you use the 'nohup' command to run the server in the background, remember to manually end the process when you are done with it.
92
92
93
-
**AT&T does not recommend deploying your application using the provided embedded Jetty server.** It should be used for development and testing purposes only.
94
-
If you want your application to run for an extended period of time, we recommend deploying the application as a .war file. See "Deploy the .war File" below.
95
-
That way you can take advantage of the deployment management options on your application server.
93
+
**AT&T does not recommend deploying your app using the provided embedded Jetty server.** It should be used for development and testing purposes only.
94
+
If you want your app to run for an extended period of time, we recommend deploying the app as a .war file. See "Deploy the .war File" below.
95
+
That way you can take advantage of the deployment management options on your app server.
96
96
97
97
98
98
Build using the command line (Apache Ant)
99
99
---
100
100
101
-
To build the application using Ant from the command line:
101
+
To build the app using Ant from the command line:
102
102
103
103
$ sh build.sh
104
104
@@ -108,7 +108,7 @@ This command will create a directory called *dist*, as well the __att.jar__ and
108
108
Eclipse IDE (Mac, Linux, Unix, Windows)
109
109
====
110
110
111
-
Build and Run using Eclipse
111
+
Build and run using Eclipse
112
112
---
113
113
114
114
Start Eclipse and create a new project by choosing File->New->Project.
@@ -125,11 +125,11 @@ Start Eclipse and create a new project by choosing File->New->Project.
125
125
126
126
Once the project is created it should build automatically without error.
127
127
128
-
Using the package *explorer* expand com.html5sdk.jetty and open EmbeddedServer.
128
+
Using the package *explorer*, expand com.html5sdk.jetty and open EmbeddedServer.
129
129
130
130
From the Run menu, choose the Run command.
131
131
132
-
The application should now be running on http://yourhost:4567/
132
+
The app should now be running on http://yourhost:4567/
133
133
134
134
When you are done using the server, stop the process using the Stop button from Eclipse's console view or debug view.
135
135
@@ -151,14 +151,14 @@ Deploy the .war File
151
151
152
152
The Ant build.xml provided by the SDK creates a deployable .war file. It will bundle the client directory, java code, and the contents of **webapp/WEB-INF/**.
153
153
154
-
**att-api.properties** will be copied to **WEB-INF/classes/**, so you need to configure your application before creating the build.
154
+
**att-api.properties** will be copied to **WEB-INF/classes/**, so you must configure your app before creating the build.
155
155
156
156
Follow the directions in **Build using the command line (Apache Ant)** and copy the **att.war** to your application server. Every application server deployment is different, but the build .war file is self-contained and should deploy on any standards-compliant application server.
157
157
158
158
Alternate locations for att-api.properties
159
159
---
160
160
161
-
To provide some flexibility in the application deployment, there are two ways to load the properties file. The default is to look on the classpath using the classloader for **att-api.properties.** You can override this behavior by specifying a Java system property. By specifying a system property, the application can be re-configured without recompiling the .war file.
161
+
To provide some flexibility in deployment, there are two ways to load the properties file. The default is to look on the classpath using the classloader for **att-api.properties.** You can override this behavior by specifying a Java system property. By specifying a system property, the app can be re-configured without recompiling the .war file.
162
162
163
163
**com.html5sdk.example.servlet.AttConstants** will look first for the system property **att.api.conf:**
0 commit comments