Skip to content

Commit

Permalink
Latest changes.
Browse files Browse the repository at this point in the history
  • Loading branch information
attdevsupport committed Jul 18, 2012
1 parent 8a65b16 commit f69cd00
Show file tree
Hide file tree
Showing 69 changed files with 1,759 additions and 870 deletions.
7 changes: 7 additions & 0 deletions MMS/Csharp/app1/Default.aspx
@@ -1,3 +1,10 @@
<!--
Licensed by AT&T under 'Software Development Kit Tools Agreement.' 2012
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION: http://developer.att.com/sdk_agreement/
Copyright 2012 AT&T Intellectual Property. All rights reserved. http://developer.att.com
For more information contact developer.support@att.com
-->

<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="MMS_App1" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
Expand Down
102 changes: 64 additions & 38 deletions MMS/Csharp/app1/README.txt
@@ -1,9 +1,21 @@
******************************************************************************************
* Licensed by AT&T under 'Software Development Kit Tools Agreement.' 2012
* TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION: http://developer.att.com/sdk_agreement/
* Copyright 2012 AT&T Intellectual Property. All rights reserved. http://developer.att.com
* For more information contact developer.support@att.com<mailto:developer.support@att.com>
******************************************************************************************

AT&T API Samples - MMS app 1
------------------------------
This application allows the user to

This file describes how to set up, configure and run the C# Applications of the AT&T HTML5 Program sample applications.
It covers all steps required to register the application on DevConnect and, based on the generated API keys and secrets,
1. Send MMS without attachement
2. Send MMS with maximum 3 attachements
3. Check the delivery status of the MMS

This file describes how to set up, configure and run the C# Applications of the
AT&T Platform API sample applications. It covers all steps required to register
the application on DevConnect and, based on the generated API keys and secrets,
create and run one's own full-fledged sample applications.

1. Configuration
Expand All @@ -14,70 +26,84 @@ create and run one's own full-fledged sample applications.

1. Configuration

Configuration consists of a few steps necessary to get an application registered on DevConnect with the proper services and
endpoints, depending on the type of client-side application (autonomous/non-autonomous).
Configuration consists of a few steps necessary to get an application registered
on DevConnect with the proper services and endpoints, depending on the type of
client-side application (autonomous/non-autonomous).

To register an application, go to https://devconnect-api.att.com/ and login with your valid username and password.
Next, choose "My Apps" from the bar at the top of the page and click the "Setup a New Application" button.
To register an application, go to https://devconnect-api.att.com/ and login with
your valid username and password. Next, choose "My Apps" from the bar at the top
of the page and click the "Setup a New Application" button.

Fill in the form, in particular all fields marked as "required".

Be careful while filling in the "OAuth Redirect URL" field. It should contain the URL that the oAuth provider will redirect
users to when he/she successfully authenticates and authorizes your application.
Be careful while filling in the "OAuth Redirect URL" field. It should contain the
URL that the oAuth provider will redirect users to when he/she successfully
authenticates and authorizes your application.

NOTE: You MUST select Payment in the list of services under field 'Services' in
order to use this sample application code.

NOTE: You MUST select MMS in the list of services under field 'Services' in order to use this sample application code.
Having your application registered, you will get back an important pair of data:
an API key and Secret key. They are necessary to get your applications working
with the AT&T Platform APIs.

Having your application registered, you will get back an important pair of data: an API key and Secret key. They are
necessary to get your applications working with the AT&T HTML5 APIs. See 'Adjusting parameters' below to learn how to use
these keys.
Initially your newly registered application is restricted to the "Sandbox"
environment only. To move it to production, you may promote it by clicking the
"Promote to production" button. Notice that you will get a different API key and
secret, so these values in your application should be adjusted accordingly.

Initially your newly registered application is restricted to the "Sandbox" environment only. To move it to production,
you may promote it by clicking the "Promote to production" button. Notice that you will get a different API key and secret,
so these values in your application should be adjusted accordingly.
Depending on the kind of authentication used, an application may be based on
either the Autonomous Client or the Web-Server Client OAuth flow (see
https://devconnect-api.att.com/docs/oauth20/autonomous-client-application-oauth-flow
or https://devconnect-api.att.com/docs/oauth20/web-server-client-application-oauth-flow
respectively).

Depending on the kind of authentication used, an application may be based on either the Autonomous Client or the Web-Server
Client OAuth flow (see https://devconnect-api.att.com/docs/oauth20/autonomous-client-application-oauth-flow or
https://devconnect-api.att.com/docs/oauth20/web-server-client-application-oauth-flow respectively).


2. Installation

** Requirements

To run the this sample application you need an IIS Server.

To run the examples you need an IIS Server.

3. Parameters
Download the application files from the download link published in AT&T portal
into webdomain of your IIS server.


Each sample application contains a config.web file. It holds configurable parameters described in an easy to read format. Please populate the following parameters in config.web as specified below:

1) api_key : {set the value as per your registered application 'API key' field value}

3. Parameters

2) secret_key : {set the value as per your registered application 'Secret key' field value}
Each sample application contains a web.config file. It holds configurable parameters
described in an easy to read format. Please populate the following parameters in
web.config as specified below:

1) api_key : This is mandatory parameter, Set the value as per your
registered appliaction 'API key' field value.

3) authorize_redirect_uri : {set the value as per your registered application 'OAuth Redirect URL' field value}
2) secret_key : This is mandatory parameter, Set the value as per your
registered appliaction 'Secret key' field value.

4) FQDN : https://api.att.com
3) endPoint : This is mandatory parameter, Set it to the end point
URI of AT&T Service.

5) scope : SMS
4) scope : MMS (Scope of the ATT service that will be invoked by
the Application)

6) short_code : {set the value as per your registered application 'short code' field value}
5) AccessTokenFilePath : ~\\MMSApp1AccessToken.txt (This is optional parameter,
which points to the file path, where application
stores access token information. If the parameter is
not configured, it will take the default value as
~\\MMSApp1AccessToken.txt. Give read/write access to
this file.)

7) AccessTokenFilePath : {set the value to the path of the file, which application creates and stores access token }

Note: If your application is promoted from Sandbox environment to Production environment and you decide to use production application settings, you must update parameters 1-2 as per production application details.
Note: If your application is promoted from Sandbox environment to Production environment
and you decide to use production application settings, you must update parameters 1-2
as per production application details.



4. Running the application

Suppose you copied the sample app files in your IIS server webroot/mms/app1/ folder, In order to run the sample application, type in'http://IIS_HOSTNAME/mms/app1/Default.aspx'






Suppose you copied the sample app files in your IIS server webroot/mms/app1/ folder.
In order to run the sample application, type in'http://IIS_HOSTNAME/mms/app1/Default.aspx'.
7 changes: 7 additions & 0 deletions MMS/Csharp/app2/Default.aspx
@@ -1,3 +1,10 @@
<!--
Licensed by AT&T under 'Software Development Kit Tools Agreement.' 2012
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION: http://developer.att.com/sdk_agreement/
Copyright 2012 AT&T Intellectual Property. All rights reserved. http://developer.att.com
For more information contact developer.support@att.com
-->

<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="MMS_App2" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
Expand Down
122 changes: 80 additions & 42 deletions MMS/Csharp/app2/README.txt
@@ -1,9 +1,23 @@
******************************************************************************************
* Licensed by AT&T under 'Software Development Kit Tools Agreement.' 2012
* TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION: http://developer.att.com/sdk_agreement/
* Copyright 2012 AT&T Intellectual Property. All rights reserved. http://developer.att.com
* For more information contact developer.support@att.com<mailto:developer.support@att.com>
******************************************************************************************

AT&T API Samples - MMS app 2
------------------------------

This file describes how to set up, configure and run the C# Applications of the AT&T HTML5 Program sample applications.
It covers all steps required to register the application on DevConnect and, based on the generated API keys and secrets,
This is a server side application which also has a web interface. The application
looks for a file called numbers.txt containing MSISDNs of desired recipients, and
an image called coupon.jpg, and message text from a file called subject.txt, and
then sends an MMS message with the attachment to every recipient in the list. This
can be triggered via a command line on the server, or through the web interface,
which then displays all the returned mmsIds or respective errors.

This file describes how to set up, configure and run the C# Applications of the
AT&T Platform API sample applications. It covers all steps required to register
the application on DevConnect and, based on the generated API keys and secrets,
create and run one's own full-fledged sample applications.

1. Configuration
Expand All @@ -14,30 +28,38 @@ create and run one's own full-fledged sample applications.

1. Configuration

Configuration consists of a few steps necessary to get an application registered on DevConnect with the proper services and
endpoints, depending on the type of client-side application (autonomous/non-autonomous).
Configuration consists of a few steps necessary to get an application registered
on DevConnect with the proper services and endpoints, depending on the type of
client-side application (autonomous/non-autonomous).

To register an application, go to https://devconnect-api.att.com/ and login with your valid username and password.
Next, choose "My Apps" from the bar at the top of the page and click the "Setup a New Application" button.
To register an application, go to https://devconnect-api.att.com/ and login with
your valid username and password. Next, choose "My Apps" from the bar at the top
of the page and click the "Setup a New Application" button.

Fill in the form, in particular all fields marked as "required".

Be careful while filling in the "OAuth Redirect URL" field. It should contain the URL that the oAuth provider will redirect
users to when he/she successfully authenticates and authorizes your application.
Be careful while filling in the "OAuth Redirect URL" field. It should contain the
URL that the oAuth provider will redirect users to when he/she successfully
authenticates and authorizes your application.

NOTE: You MUST select MMS in the list of services under field 'Services' in order
to use this sample application code.

NOTE: You MUST select MMS in the list of services under field 'Services' in order to use this sample application code.
Having your application registered, you will get back an important pair of data:
an API key and Secret key. They are necessary to get your applications working
with the AT&T Platform APIs.

Having your application registered, you will get back an important pair of data: an API key and Secret key. They are
necessary to get your applications working with the AT&T HTML5 APIs. See 'Adjusting parameters' below to learn how to use
these keys.
Initially your newly registered application is restricted to the "Sandbox"
environment only. To move it to production, you may promote it by clicking the
"Promote to production" button. Notice that you will get a different API key and
secret, so these values in your application should be adjusted accordingly.

Initially your newly registered application is restricted to the "Sandbox" environment only. To move it to production,
you may promote it by clicking the "Promote to production" button. Notice that you will get a different API key and secret,
so these values in your application should be adjusted accordingly.
Depending on the kind of authentication used, an application may be based on
either the Autonomous Client or the Web-Server Client OAuth flow (see
https://devconnect-api.att.com/docs/oauth20/autonomous-client-application-oauth-flow or
https://devconnect-api.att.com/docs/oauth20/web-server-client-application-oauth-flow
respectively).

Depending on the kind of authentication used, an application may be based on either the Autonomous Client or the Web-Server
Client OAuth flow (see https://devconnect-api.att.com/docs/oauth20/autonomous-client-application-oauth-flow or
https://devconnect-api.att.com/docs/oauth20/web-server-client-application-oauth-flow respectively).


2. Installation
Expand All @@ -46,46 +68,62 @@ NOTE: You MUST select MMS in the list of services under field 'Services' in orde

To run the this sample application you need an IIS Server.

Download the application files from the download link published in AT&T portal
into webdomain of your IIS server.

3. Parameters


Each sample application contains a config.web file. It holds configurable parameters described in an easy to read format. Please populate the following parameters in config.web as specified below:

1) api_key : {set the value as per your registered application 'API key' field value}


2) secret_key : {set the value as per your registered application 'Secret key' field value}
3. Parameters

Each sample application contains a web.config file. It holds configurable parameters
described in an easy to read format. Please populate the following parameters in
web.config as specified below:

1) api_key : This is mandatory parameter, Set the value as per your
registered appliaction 'API key' field value.

3) authorize_redirect_uri : {set the value as per your registered application 'OAuth Redirect URL' field value}
2) secret_key : This is mandatory parameter,Set the value as per your
registered appliaction 'Secret key' field value.

4) FQDN : https://api.att.com
3) endPoint : This is mandatory parameter, Set it to the end point
URI of AT&T Service.

5) scope : MMS
5) scope : MMS (Scope of the ATT service that will be invoked by the
Application)

6) short_code : {set the value as per your registered application 'short code' field value}
7) AccessTokenFilePath : ~\\MMSApp1AccessToken.txt (This is optional parameter,
which points to the file path, where application stores
access token information. If the parameter is not configured,
it will take the default value as ~\\MMSApp1AccessToken.txt.
Give read/write access to this file.)

7) AccessTokenFilePath : {set the value to the path of the file, which application creates and stores access token }
8) messageFilePath : coupon_info\\message.txt (This is manadatory parameter,
which points to the file path, from where application reads
the message content to be sent along with the coupon.
Give read/write access to this file and folder.)

8) messageFilePath : {set the value to the path of the file, which application reads the content and sent as message text }
9) phoneListFilePath : coupon_info\\phone.txt (This is manadatory parameter,
which points to the file path, from where application reads
the destination address for sending coupon.
Give read/write access to this file and folder.)

9) phoneListFilePath : {set the value to the path of the file, which application reads the content and used as destination numbers for mms message }
10) couponPath : coupon_info\\ (This is mandatory parameter, which will
point to the directory, which contains the image to be sent
as the coupon. Give read/write access to this folder.)

10) couponPath : {set the value to the path of the directory, which contains the image to be sent }
11) couponFileName : Coupon.jpg (This is mandatory parameter, which is the name
of the image/coupon to be sent, make sure that the image
exists in the "couponPath" key directory. Give read/write
access to this folder.)

11) couponFileName : {set the value to the path of the image file, which will be sent as an mms messsage}

Note: If your application is promoted from Sandbox environment to Production environment and you decide to use production application settings, you must update parameters 1-2 as per production application details.
Note: If your application is promoted from Sandbox environment to Production environment
and you decide to use production application settings, you must update parameters 1-2 as
per production application details.



4. Running the application

Suppose you copied the sample app files in your IIS server webroot/mms/app2/ folder, In order to run the sample application, type in'http://IIS_HOSTNAME/mms/app2/Default.aspx'






Suppose you copied the sample app files in your IIS server webroot/mms/app2/ folder.
In order to run the sample application, type in'http://IIS_HOSTNAME/mms/app2/Default.aspx'.
9 changes: 8 additions & 1 deletion MMS/Csharp/app3/Default.aspx
@@ -1,4 +1,11 @@
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="MMS_App3" %>
<!--
Licensed by AT&T under 'Software Development Kit Tools Agreement.' 2012
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION: http://developer.att.com/sdk_agreement/
Copyright 2012 AT&T Intellectual Property. All rights reserved. http://developer.att.com
For more information contact developer.support@att.com
-->

<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="MMS_App3" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xml:lang="en" xmlns="http://www.w3.org/1999/xhtml" lang="en">
Expand Down
9 changes: 8 additions & 1 deletion MMS/Csharp/app3/Listener.aspx
@@ -1,4 +1,11 @@
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Listener.aspx.cs" Inherits="MMSApp3_Listener" %>
<!--
Licensed by AT&T under 'Software Development Kit Tools Agreement.' 2012
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION: http://developer.att.com/sdk_agreement/
Copyright 2012 AT&T Intellectual Property. All rights reserved. http://developer.att.com
For more information contact developer.support@att.com
-->

<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Listener.aspx.cs" Inherits="MMSApp3_Listener" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

Expand Down

0 comments on commit f69cd00

Please sign in to comment.