Skip to content

Instantly share code, notes, and snippets.

@t2-support-gists
Last active October 10, 2015 17:08
Show Gist options
  • Select an option

  • Save t2-support-gists/3723805 to your computer and use it in GitHub Desktop.

Select an option

Save t2-support-gists/3723805 to your computer and use it in GitHub Desktop.
DC Csharp RESTFul App 1
******************************************************************************************
* Licensed by AT&T under 'Software Development Kit Tools Agreement.' 2013
* TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION: http://developer.att.com/sdk_agreement/
* Copyright 2013 AT&T Intellectual Property. All rights reserved. http://developer.att.com
* For more information contact [email protected]<mailto:[email protected]>
******************************************************************************************
AT&T API Platform Samples - DC App 1
-------------------------------------
This application demonstrates the usage of Device Capabilities API of AT&T platform.
The application allows an AT&T subscriber to retrieve the device specific information
about the mobile device.
This file describes how to set up, configure and run the C# Applications of the
AT&T API Platform sample applications. It covers all steps required to register the
application on de and, based on the generated API keys and secrets,
create and run one's own full-fledged sample applications.
1. Configuration
2. Installation
3. Parameters
4. Running the application
1. Configuration
Configuration consists of a few steps necessary to get an application registered
on developer site with the proper services and endpoints, depending on the type of
client-side application (autonomous/non-autonomous).
To register an application, go to https://developer.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.
NOTE: You MUST select Device Capability 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.
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.
2. Installation
** Requirements
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 an web.config file. This file
is located in the 'app' folder. This file holds configurable
parameters described in an easy-to-read format. Please modify the
web.config file using the comments specified within the file.
Note: If your application is promoted from Sandbox environment to Production
environment and you decide to use production application settings, you must
update parameters as per production application details.
4. Running the application
Suppose you copied the sample app files in your IIS server webroot/dc/app1/ folder.
In order to run the sample application, type in'http://IIS_HOSTNAME/dc/app1/Default.aspx'.
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="DC_App1" %>
<!--
Licensed by AT&T under 'Software Development Kit Tools Agreement.' 2013
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION: http://developer.att.com/sdk_agreement/
Copyright 2013 AT&T Intellectual Property. All rights reserved. http://developer.att.com
For more information contact [email protected]
-->
<!--[if lt IE 7]> <html class="ie6" lang="en"> <![endif]-->
<!--[if IE 7]> <html class="ie7" lang="en"> <![endif]-->
<!--[if IE 8]> <html class="ie8" lang="en"> <![endif]-->
<!--[if gt IE 8]><!-->
<html lang="en">
<!--<![endif]-->
<head>
<title>AT&amp;T Sample DC Application - Get Device Capabilities Application</title>
<meta id="viewport" name="viewport" content="width=device-width,minimum-scale=1,maximum-scale=1" />
<link rel="stylesheet" type="text/css" href="style/common.css" />
<script type="text/javascript">
var _gaq = _gaq || [];
_gaq.push(['_setAccount', 'UA-33466541-1']);
_gaq.push(['_trackPageview']);
(function () {
var ga = document.createElement('script');
ga.type = 'text/javascript';
ga.async = true;
ga.src = ('https:' == document.location.protocol ? 'https://ssl'
: 'http://www')
+ '.google-analytics.com/ga.js';
var s = document.getElementsByTagName('script')[0];
s.parentNode.insertBefore(ga, s);
})();
</script>
</head>
<body>
<form id="form1" runat="server">
<div id="pageContainer">
<div id="header">
<div class="logo">
</div>
<div id="menuButton" class="hide">
<a id="jump" href="#nav">Main Navigation</a>
</div>
<ul class="links" id="nav">
<li><a runat="server" target="_blank" id="SourceLink">Source<img src="images/opensource.png" /></a>
<span class="divider">|&nbsp;</span> </li>
<li><a runat="server" target="_blank" id="DownloadLink">Download<img src="images/download.png" /></a>
<span class="divider">|&nbsp;</span> </li>
<li><a runat="server" target="_blank" id="HelpLink">Help</a> </li>
<li id="back"><a href="#top">Back to top</a> </li>
</ul>
<!-- end of links -->
</div>
<!-- end of header -->
<div id="content">
<div id="contentHeading">
<h1>
AT&amp;T Sample DC Application - Get Device Capabilities Application</h1>
<div class="border">
</div>
<div id="introtext">
<div>
<b>Server Time:&nbsp;</b><%= String.Format("{0:ddd, MMMM dd, yyyy HH:mm:ss}", DateTime.UtcNow) + " UTC" %></div>
<div>
<b>Client Time:</b>
<script language="JavaScript" type="text/javascript">
var myDate = new Date();
document.write(myDate);
</script>
</div>
<div>
<b>User Agent:</b>
<script language="JavaScript" type="text/javascript">
document.write("" + navigator.userAgent);
</script>
</div>
</div>
<!-- end of introtext -->
</div>
<!-- end of contentHeading -->
<!-- SAMPLE APP CONTENT STARTS HERE! -->
<div class="formBox" id="formBox">
<div id="formContainer" class="formContainer">
<h2>
Feature 1: Get Device Capabilities</h2>
<div class="lightBorder">
</div>
<div class="note">
<strong>OnNet Flow:</strong> Request Device Capabilities details from the AT&amp;T
network for the mobile device of an AT&amp;T subscriber who is using an AT&amp;T
direct Mobile data connection to access this application.
<br />
<strong>OffNet Flow:</strong> Where the end-user is not on an AT&amp;T Mobile data
connection or using a Wi-Fi or tethering connection while accessing this application.
This will result in an HTTP 400 error.
</div>
<!-- end note -->
<% if (!string.IsNullOrEmpty(getDCSuccess))
{ %>
<div class="successWide">
<strong>SUCCESS:</strong>
<br />
Device parameters listed below.
</div>
<table class="kvp" id="kvp">
<thead>
<tr>
<th>
Parameter
</th>
<th>
Value
</th>
</tr>
</thead>
<tbody>
<% foreach (var pair in getDCResponse)
{%>
<tr>
<td data-value="Parameter">
<%= pair.Key.ToString()%>
</td>
<td data-value="Value">
<%= pair.Value.ToString()%>
</td>
</tr>
<% } %>
</tbody>
</table>
<% } %>
<% if (!string.IsNullOrEmpty(getDCError))
{ %>
<div class="errorWide">
<b>ERROR:</b><br />
<%= getDCError %>
</div>
<% } %>
</div>
<!-- end of formContainer -->
</div>
<!-- end of formBox -->
<!-- SAMPLE APP CONTENT ENDS HERE! -->
</div>
<!-- end of content -->
<div class="border">
</div>
<div id="footer">
<div id="powered_by">
Powered by AT&amp;T Cloud Architecture
</div>
<p>
The Application hosted on this site are working examples intended to be used for
reference in creating products to consume AT&amp;T Services and not meant to be
used as part of your product. The data in these pages is for test purposes only
and intended only for use as a reference in how the services perform.
<br />
<br />
For download of tools and documentation, please go to <a href="https://developer.att.com/"
target="_blank">https://developer.att.com</a>
<br />
For more information contact <a href="mailto:[email protected]">[email protected]</a>
<br />
<br />
&#169; 2014 AT&amp;T Intellectual Property. All rights reserved. <a href="https://developer.att.com/"
target="_blank">https://developer.att.com</a>
</p>
</div>
<!-- end of footer -->
</div>
<!-- end of page_container -->
</form>
</body>
</html>
// <copyright file="Default.aspx.cs" company="AT&amp;T">
// Licensed by AT&amp;T under 'Software Development Kit Tools Agreement.' 2013
// TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION: http://developer.att.com/sdk_agreement/
// Copyright 2013 AT&amp;T Intellectual Property. All rights reserved. http://developer.att.com
// For more information contact [email protected]
// </copyright>
#region Application References
using System;
using System.Configuration;
using System.Globalization;
using System.IO;
using System.Net;
using System.Net.Security;
using System.Security.Cryptography.X509Certificates;
using System.Text;
using System.Web.Script.Serialization;
using System.Web;
using System.Collections.Generic;
using System.Collections;
#endregion
/// <summary>
/// Access Token Types
/// </summary>
public enum AccessTokenType
{
/// <summary>
/// Access Token Type is based on Authorize Credential Mode
/// </summary>
Authorize_Credential,
/// <summary>
/// Access Token Type is based on Refresh Token
/// </summary>
Refresh_Token
}
/// <summary>
/// Device Capabilities Application class.
/// This application will allow an user to get the device capabilities.
/// </summary>
public partial class DC_App1 : System.Web.UI.Page
{
#region Application Instance Variables
/// <summary>
/// Instance variables
/// </summary>
private string endPoint, apiKey, secretKey, authorizeRedirectUri, authCode, scope, bypassSSL;
/// <summary>
/// OAuth access token
/// </summary>
private string accessToken;
public int indentLevel = 0;
public string tbOutput = string.Empty;
public string getDCSuccess = string.Empty;
public string getDCError = string.Empty;
public Dictionary<string, string> getDCResponse = new Dictionary<string, string>();
/// <summary>
/// OAuth refresh token
/// </summary>
private string refreshToken;
/// <summary>
/// Expirytimes of refresh and access tokens
/// </summary>
private string refreshTokenExpiryTime, accessTokenExpiryTime;
#endregion
#region Neglect SSL error
/// <summary>
/// Neglect the ssl handshake error with authentication server
/// </summary>
private static void BypassCertificateError()
{
string bypassSSL = ConfigurationManager.AppSettings["IgnoreSSL"];
if ((!string.IsNullOrEmpty(bypassSSL))
&& (string.Equals(bypassSSL, "true", StringComparison.OrdinalIgnoreCase)))
{
ServicePointManager.ServerCertificateValidationCallback +=
delegate(Object sender1, X509Certificate certificate, X509Chain chain, SslPolicyErrors sslPolicyErrors)
{
return true;
};
}
}
#endregion
#region Application Events
/// <summary>
/// This method will be executed upon loading of the page.
/// Reads the config file and assigns to local variables.
/// </summary>
/// <param name="sender">sender object</param>
/// <param name="e">event arguments</param>
protected void Page_Load(object sender, EventArgs e)
{
try
{
BypassCertificateError();
bool ableToReadConfig = this.ReadConfigFile();
if (ableToReadConfig == false)
{
return;
}
if (!IsPostBack)
{
if (Request.QueryString["error"] != null && Session["cs_dc_state"]!=null)
{
Session["cs_dc_state"] = null;
string errorString = Request.Url.Query.Remove(0,1);
getDCError = HttpUtility.UrlDecode(errorString);
return;
}
if (Session["Cs_DC_App1_AccessToken"] == null)
{
//Retrive the query string 'code' from redirect response of AT&T authorization endpoint
// get the AccessToken and device info
if (!string.IsNullOrEmpty(Convert.ToString(Request["code"])))
{
authCode = Request["code"].ToString();
if (GetAccessToken(AccessTokenType.Authorize_Credential))
{
GetDeviceInfo();
}
else
{
getDCError = "Failed to get Access token";
}
}
else
{
Session["Cs_DC_App1_AccessToken"] = null;
GetAuthCode();
}
}
else
{
GetDeviceInfo();
}
}
else
{
Session["Cs_DC_App1_AccessToken"] = null;
GetAuthCode();
}
}
catch (Exception ex)
{
getDCError = ex.ToString();
}
}
#endregion
#region Application specific methods
/// <summary>
/// Read config file and assign to local variables
/// </summary>
/// <remarks>
/// <para>Validates if the values are configured in web.config file and displays a warning message if not configured.</para>
/// </remarks>
/// <returns>true/false; true if able to read and assign; else false</returns>
private bool ReadConfigFile()
{
this.endPoint = ConfigurationManager.AppSettings["endPoint"];
if (string.IsNullOrEmpty(this.endPoint))
{
getDCError = "endPoint is not defined in configuration file";
return false;
}
this.apiKey = ConfigurationManager.AppSettings["apiKey"];
if (string.IsNullOrEmpty(this.apiKey))
{
getDCError = "apiKey is not defined in configuration file";
return false;
}
this.secretKey = ConfigurationManager.AppSettings["secretKey"];
if (string.IsNullOrEmpty(this.secretKey))
{
getDCError = "secretKey is not defined in configuration file";
return false;
}
this.authorizeRedirectUri = ConfigurationManager.AppSettings["authorizeRedirectUri"];
if (string.IsNullOrEmpty(this.authorizeRedirectUri))
{
getDCError = "authorizeRedirectUri is not defined in configuration file";
return false;
}
this.scope = ConfigurationManager.AppSettings["scope"];
if (string.IsNullOrEmpty(this.scope))
{
this.scope = "DC";
}
if (!string.IsNullOrEmpty(ConfigurationManager.AppSettings["SourceLink"]))
{
SourceLink.HRef = ConfigurationManager.AppSettings["SourceLink"];
}
else
{
SourceLink.HRef = "#"; // Default value
}
if (!string.IsNullOrEmpty(ConfigurationManager.AppSettings["DownloadLink"]))
{
DownloadLink.HRef = ConfigurationManager.AppSettings["DownloadLink"];
}
else
{
DownloadLink.HRef = "#"; // Default value
}
if (!string.IsNullOrEmpty(ConfigurationManager.AppSettings["HelpLink"]))
{
HelpLink.HRef = ConfigurationManager.AppSettings["HelpLink"];
}
else
{
HelpLink.HRef = "#"; // Default value
}
return true;
}
/// <summary>
/// This method gets access token based on either client credentials mode or refresh token.
/// </summary>
/// <param name="type">AccessTokenType; either Client_Credential or Refresh_Token</param>
/// <returns>true/false; true if able to get access token, else false</returns>
private bool GetAccessToken(AccessTokenType type)
{
Stream postStream = null;
StreamWriter streamWriter = null;
FileStream fileStream = null;
try
{
DateTime currentServerTime = DateTime.UtcNow.ToLocalTime();
WebRequest accessTokenRequest = System.Net.HttpWebRequest.Create(string.Empty + this.endPoint + "/oauth/v4/token");
accessTokenRequest.Method = "POST";
string oauthParameters = string.Empty;
if (type == AccessTokenType.Authorize_Credential)
{
oauthParameters = "client_id=" + this.apiKey.ToString() + "&client_secret=" + this.secretKey + "&code=" + this.authCode + "&grant_type=authorization_code&scope=" + this.scope;
}
else
{
oauthParameters = "grant_type=refresh_token&client_id=" + this.apiKey + "&client_secret=" + this.secretKey + "&refresh_token=" + this.refreshToken;
}
accessTokenRequest.ContentType = "application/x-www-form-urlencoded";
UTF8Encoding encoding = new UTF8Encoding();
byte[] postBytes = encoding.GetBytes(oauthParameters);
accessTokenRequest.ContentLength = postBytes.Length;
postStream = accessTokenRequest.GetRequestStream();
postStream.Write(postBytes, 0, postBytes.Length);
WebResponse accessTokenResponse = accessTokenRequest.GetResponse();
using (StreamReader accessTokenResponseStream = new StreamReader(accessTokenResponse.GetResponseStream()))
{
string jsonAccessToken = accessTokenResponseStream.ReadToEnd();
JavaScriptSerializer deserializeJsonObject = new JavaScriptSerializer();
AccessTokenResponse deserializedJsonObj = (AccessTokenResponse)deserializeJsonObject.Deserialize(jsonAccessToken, typeof(AccessTokenResponse));
DateTime accessTokenExpireTime = DateTime.Now;
Session["Cs_DC_App1_AccessToken"] = deserializedJsonObj.access_token.ToString();
double expiryMilliSeconds = Convert.ToDouble(deserializedJsonObj.expires_in);
Session["refresh_token"] = deserializedJsonObj.refresh_token.ToString();
if (expiryMilliSeconds == 0)
{
Session["accessTokenExpireTime"] = accessTokenExpireTime.AddYears(100);
}
else
{
Session["accessTokenExpireTime"] = accessTokenExpireTime.AddMilliseconds(expiryMilliSeconds);
}
return true;
}
}
catch (WebException we)
{
string errorResponse = string.Empty;
try
{
using (StreamReader sr2 = new StreamReader(we.Response.GetResponseStream()))
{
errorResponse = sr2.ReadToEnd();
sr2.Close();
}
}
catch
{
errorResponse = "Unable to get response";
}
getDCError = errorResponse + Environment.NewLine + we.Message;
}
catch (Exception ex)
{
getDCError = ex.Message;
}
finally
{
if (null != postStream)
{
postStream.Close();
}
if (null != streamWriter)
{
streamWriter.Close();
}
if (null != fileStream)
{
fileStream.Close();
}
}
return false;
}
/// <summary>
/// Redirects to authentication server to get the access code
/// </summary>
private void GetAuthCode()
{
Session["cs_dc_state"] = "FetchAuthCode";
Response.Redirect(this.endPoint + "/oauth/v4/authorize?scope=" + this.scope + "&client_id=" + this.apiKey + "&redirect_url=" + this.authorizeRedirectUri);
}
/// <summary>
/// This method invokes DeviceInfo API of AT&amp;T platform to get the device information.
/// </summary>
private void GetDeviceInfo()
{
try
{
HttpWebRequest deviceInfoRequestObject = (HttpWebRequest)System.Net.WebRequest.Create(this.endPoint + "/rest/2/Devices/Info");
deviceInfoRequestObject.Method = "GET";
deviceInfoRequestObject.Headers.Add("Authorization", "Bearer " + Session["Cs_DC_App1_AccessToken"]);
HttpWebResponse deviceInfoResponse = (HttpWebResponse)deviceInfoRequestObject.GetResponse();
using (StreamReader accessTokenResponseStream = new StreamReader(deviceInfoResponse.GetResponseStream()))
{
string deviceInfo_jsonObj = accessTokenResponseStream.ReadToEnd();
JavaScriptSerializer deserializeJsonObject = new JavaScriptSerializer();
Dictionary<string, object> dict = deserializeJsonObject.Deserialize<Dictionary<string, object>>(deviceInfo_jsonObj);
DisplayDictionary(dict);
getDCSuccess = "success";
}
}
catch (WebException we)
{
string errorResponse = string.Empty;
try
{
using (StreamReader sr2 = new StreamReader(we.Response.GetResponseStream()))
{
errorResponse = sr2.ReadToEnd();
sr2.Close();
}
}
catch
{
errorResponse = "Unable to get response";
}
getDCError = errorResponse + Environment.NewLine + we.Message;
}
catch (Exception ex)
{
getDCError = ex.Message;
}
}
#endregion
private void DisplayDictionary(Dictionary<string,object> dict)
{
foreach (string strKey in dict.Keys)
{
string strOutput = "".PadLeft(indentLevel * 8) + strKey + ":";
object o = dict[strKey];
if (o is Dictionary<string, object>)
{
DisplayDictionary((Dictionary<string, object>)o);
}
else if (o is ArrayList)
{
foreach (object oChild in ((ArrayList)o))
{
if (oChild is string)
{
strOutput = ((string)oChild);
//tbOutput = tbOutput + strOutput + ",";
}
else if (oChild is Dictionary<string, object>)
{
DisplayDictionary((Dictionary<string, object>)oChild);
//tbOutput = tbOutput + "\r\n";
}
}
}
else
{
getDCResponse.Add(strKey.ToString(),o.ToString());
//strOutput = o.ToString();
}
}
}
}
#region Access Token Data Structure
/// <summary>
/// AccessTokenResponse Object, returned upon calling get auth token api.
/// </summary>
public class AccessTokenResponse
{
/// <summary>
/// Gets or sets the value of access_token
/// </summary>
public string access_token
{
get;
set;
}
/// <summary>
/// Gets or sets the value of refresh_token
/// </summary>
public string refresh_token
{
get;
set;
}
/// <summary>
/// Gets or sets the value of expires_in
/// </summary>
public string expires_in
{
get;
set;
}
}
#endregion
#region Device Capabilities Response Structure
/// <summary>
/// This object is used to return the Device Capabilities details from the network for a particular mobile terminal.
/// </summary>
public class DeviceCapabilities
{
/// <summary>
/// Gets or sets the value of DeviceInfo object.
/// This Root Object will return two nested objects i-e DeviceId and Capabilities.
/// </summary>
public DeviceInfo DeviceInfo { get; set; }
}
/// <summary>
/// Encapsulates the device capabilities response from API gateway.
/// </summary>
public class DeviceInfo
{
/// <summary>
/// Gets or sets the value of DeviceId.
/// </summary>
public DeviceId DeviceId { get; set; }
/// <summary>
/// Gets or sets the value of Capabilities object.
/// </summary>
public Capabilities Capabilities { get; set; }
}
/// <summary>
/// Encapsulates the first 8 digits of the IMEI of the mobile device.
/// </summary>
public class DeviceId
{
/// <summary>
/// Gets or sets the value of TypeAllocationCode.
/// This will return ONLY the first 8 digits of the International Mobile Equipment Identity of the mobile device in question.
/// </summary>
public string TypeAllocationCode { get; set; }
}
/// <summary>
/// Capabilities object is returned as part of Device #Capabilities AT&amp;T's API.
/// The Device Capabilities attributes, which include Name, Vendor, Model, FirmwareVersion,
/// UaProf, MmsCapable, AssistedGps, Location Technology, Device Browser and WAP Push Capable to
/// allow developers to deliver applications that are tailored to a specific customer device.
/// </summary>
public class Capabilities
{
/// <summary>
/// Gets or sets the value of Name.
/// AT&amp;T's abbreviated code for the mobile device manufacturer and model number. These may or may not correspond to the device manufacturer's name and model number provided in the href.
/// </summary>
public string Name { get; set; }
/// <summary>
/// Gets or sets the value of Vendor.
/// AT&amp;T's abbreviated code for the mobile device manufacturer.
/// </summary>
public string Vendor { get; set; }
/// <summary>
/// Gets or sets the value of Model.
/// AT&amp;T's model number for the mobile device.
/// </summary>
public string Model { get; set; }
/// <summary>
/// Gets or sets the value of FirmwareVersion.
/// AT&amp;T's shall map the AT&amp;T's specific device firmware release number (if available) to this parameter.
/// This may or may not correspond to the mobile device manufacturer's firmware release numbers.
/// </summary>
public string FirmwareVersion { get; set; }
/// <summary>
/// Gets or sets the value of UaProf.
/// Contains a URL to the device manufacturer website which may provide specific
/// capability details for the mobile device in the request.
/// </summary>
public string UaProf { get; set; }
/// <summary>
/// Gets or sets the value of MmsCapable.
/// A value that indicates whether the device is MMS capable �Y� or �N�.
/// </summary>
public string MmsCapable { get; set; }
/// <summary>
/// Gets or sets the value of AssistedGps.
/// A value that indicates whether the device is assisted-GPS capable �Y� or �N�.
/// </summary>
public string AssistedGps { get; set; }
/// <summary>
/// Gets or sets the value of LocationTechnology.
/// A value that indicates the location technology network that is supported by the device.
/// The value is expressed in terms of network Location service technology types (i.e. �SUPL� or �SUPL2�) as supporting the Location query on 3G devices and 4G (LTE) devices respectively.
/// </summary>
public string LocationTechnology { get; set; }
/// <summary>
/// Gets or sets the value of DeviceBrowser.
/// A value that indicates the name of the browser that is resident on the device e.g. �RIM� for Blackberry devices.
/// </summary>
public string DeviceBrowser { get; set; }
/// <summary>
/// Gets or sets the value of WAPPushCapable.
/// A value that indicates whether the device is WAP Push capable �Y� or �N�.
/// </summary>
public string WapPushCapable { get; set; }
}
#endregion
<?xml version="1.0"?>
<!--
For more information on how to configure your ASP.NET application, please
visit http://go.microsoft.com/fwlink/?LinkId=169433
-->
<configuration>
<system.web>
<compilation debug="true" targetFramework="4.0"/>
<customErrors mode="Off"/>
</system.web>
<appSettings>
<!-- Set this parameter value to "true", if you need to bypass the SSL certificate. Default FALSE -->
<add key="IgnoreSSL" value="false"/>
<!-- This is mandatory key and value should be equal
to DC Service registered application 'API key'
example: value=""-->
<add key="apikey" value=""/>
<!-- This is mandatory key and value should be equal
to DC Service registered application 'Secret key'
example: value=""-->
<add key="secretkey" value=""/>
<!-- This is mandatory key and value should be equal
to https://api.att.com for production environment
example: value="https://api.att.com"-->
<add key="endPoint" value="" />
<!-- This is mandatory key and value should be equal
to DC Service registered application 'OAuth Redirect URL'
example: value="https://IIS-Server/webroot/dc/app1/Default.aspx"-->
<add key="authorizeRedirectUri" value=""/>
<!-- This is mandatory key and value should be equal
to DC Service registered application scope-->
<add key="scope" value="DC"/>
<add key="SourceLink" value=""/>
<add key="DownloadLink" value=""/>
<add key="HelpLink" value=""/>
</appSettings>
</configuration>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment