diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..d56c7b2 --- /dev/null +++ b/.gitignore @@ -0,0 +1,5 @@ +.idea +.classpath +.project +*.iml +target diff --git a/Android/LICENSE b/Android/LICENSE new file mode 100644 index 0000000..1415cbe --- /dev/null +++ b/Android/LICENSE @@ -0,0 +1,20 @@ +The MIT License (MIT) + +Copyright (c) 2013 Aldrin Bautista + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. \ No newline at end of file diff --git a/Android/docs/payment.md b/Android/docs/payment.md new file mode 100644 index 0000000..fea7cf3 --- /dev/null +++ b/Android/docs/payment.md @@ -0,0 +1,151 @@ +## Introduction + +The Globe Payment API lets you develop client applications to charge subscribers. This document describes how to use the OAUTH/RESTful calling style and client library for PHP. + +## Getting Started + +The first thing we need to do is obtain an **APP ID** and **APP SECRET** from [Globe's Developer Website](http://developer.globelabs.com.ph/users/login). When visiting the link provided you should see a login form similar to *Figure PHP.PAYMENT.1*. + +##### Figure PHP.PAYMENT.1 - Login +![Login Screen](https://raw.github.com/Openovate/rest-docs/master/sms/assets/login.jpg) +==== + + Currently Globe's RESTful API is in BETA Mode. Ask your local Globe support to gain access to this BETA. + +Next, login with your given credentials to get to the APP screen. When you get to the app screen scroll to the bottom right and click the "create" button to create a new app. You should see something familiar to *Figure PHP.PAYMENT.2* + +##### Figure PHP.PAYMENT.2 - Create App Button +![Create App Button](https://raw.github.com/Openovate/rest-docs/master/sms/assets/create.jpg) +==== + +This will bring you to a form with required information that Globe will need to process your app creation. Fill out this form with the required fields at the very least and press Submit found at the bottom right in *Figure PHP.PAYMENT.3*. + +##### Figure PHP.PAYMENT.3 - Create App Form +![Create App Form](https://raw.github.com/Openovate/rest-docs/master/sms/assets/form.jpg) +==== + + **Important:** It's important that the Redirect URI and the Notify URI are using actual + URLs as in http://www.example.com/callback. Globe will call these URLs as described in the field. + +From here you should be returned to the APP Detail Page in *Figure PHP.PAYMENT.4*. The important thing here is the **APP ID** and **APP SECRET**. These will be the information that you will need to manually set in the configurations when writing your application. + +##### Figure PHP.PAYMENT.4 - App Details +![Create App Form](https://raw.github.com/Openovate/rest-docs/master/sms/assets/detail.jpg) + + **Note:** The data in this screen doesn't actually work. Please don't assume something went + wrong because you tried to use it. + +## How to Include + +First thing before you do any calls for Globe API using PHP wrapper class is to include the base class called GlobeApi. + +##### Figure PHP.PAYMENT.5 - Include Base Class + +**Note:** To include these you have to point the location of the file and require it in your app. In my case, I am using the test script inside the test folder and it will look like this. + + require ('path/to/directory/GlobeApi.php'); + $globe = new GlobeApi([version]); + +## Authentication + +Once we obtain the **APP ID** and **APP SECRET** we can begin to understand how the authentication works. Globe uses [OAUTH2](https://developers.google.com/accounts/docs/OAuth2), a common PHP.PAYMENTcol to authenticate developers to use API PHP.PAYMENTcols. To begin the authentication process you must redirect the user to a formatted URL using your **APP ID** and **APP SECRET** as in *Figure PHP.PAYMENT.6*. + +##### Figure PHP.PAYMENT.6 - Invoke a Redirection + +Now, initialize the `Auth` class inside GlobeApi and get the login URL using the `getLoginUrl` method. + + $auth = $globe->auth( + [YOUR APP ID], + [YOUR APP SECRET] + ); + $loginUrl = auth->getLoginUrl(); + header('Location: '.$loginUrl); + +Before invoking your redirect, please replace `[YOUR APP ID]` and `[YOUR APP SECRET]` in the figure above with your actual **APP ID** and **APP SECRET**. Based on what you inputed as your **Redirect URI** in your app details. Globe will authenticate permissions first with the user which should look like *Figure PHP.PAYMENT.7a* and *Figure PHP.PAYMENT.7b*. + +##### Figure PHP.PAYMENT.7a - User Flow +![User Flow](https://raw.github.com/Openovate/rest-docs/master/sms/assets/user.jpg) +==== +##### Figure PHP.PAYMENT.7b - Authorize +![Authorize](https://raw.github.com/Openovate/rest-docs/master/sms/assets/user.jpg) +==== + +Once the user gives permission, Globe will redirect the user to your Redirect URI with a `code` parameter appended to the end of it. This is how we recieve the code to continue the authentication process. *Figure PHP.PAYMENT.8* shows how this redirect will look like given that we set our redirect URI to `http://www.example.com/callback` in our app create form in *Figure PHP.PAYMENT.3*. + + **Important:** It is also possible that a user can give permissions to your app using just their + phone via SMS. Globe will call (not a phone call) your redirect URI with `access_token` and + `subscriber_number` appended to the end of it. From here you can process this request and + ignore the rest of the authentication process below. + +##### Figure PHP.PAYMENT.8 - Redirected URI Sample + + http://www.example.com/callback?code=12345 + +`12345` in the URL figure above is what we need in order to get a more long lasting token for your app to use when making API calls. Everytime you make this call the `code` returned will be unique, so you should not hard code the `code` value in your application. The final step in the authentication process is about exchanging your `code` with a more permanent access token. We need to send Globe one final request shown in *Figure PHP.PAYMENT.9* + +##### Figure PHP.PAYMENT.9 - Get the Access Token + +Using the `Auth` object we initialized in **Figure PHP.PAYMENT.6**, we can get the access token using the script below. + + $response = $auth->getAccessToken([CODE]); + +Before sending, please replace `[CODE]` in the figure above with the code given from Figure PHP.PAYMENT.8. + +Finally, Globe will return an access token you can use to start using the Charge API. **Figure PHP.PAYMENT.10** shows how this response will look like + +##### Figure PHP.PAYMENT.10 - Access Token + + Array ( + "access_token" => "GesiE2YhZlxB9VVMhv-PoI8RwNTsmX0D38g", + "subscriber_number" => "9051234567" + ) + +## + + **Note:** The data in above doesn't actually work. Please don't assume something went wrong + because you tried to use it. + +## Charge + +To use charge API you will need to send a POST request to the URL given below. + +**Request URL** + + http://devapi.globelabs.com.ph/payment/v1/transactions/amount + +**Parameters** + +| Parameters | Definition | Data Type | +|-------|:----------:|:---------:| +| [YOUR_ACCESS_TOKEN] | which contains security information for transacting with a subscriber. Subscriber needs to grant an app first via SMS or Web Form Subscriber Consent Workflow. | String | +| [SUBSCRIBER_NUMBER] | is the MSISDN (mobile number) which you will charge to. Parameter format can be 09xxxxxxxx | String or Integer | +| [AMOUNT] | can be a whole number or decimal | String | +| [REFERENCE_NUMBER] | Is a unique transaction ID with a format of `[SHORT_CODE_WITHOUT_2158]`+`#######` where `#######` is an incremented number beginning from `1000001`. | Integer | + + +##### Figure PHP.PAYMENT.11 - Sample Charge Request + + $charge = $globe->payment( + [YOUR_ACCESS_TOKEN], + [SUBSCRIBER_NUMBER] + ); + + $response = $charge->charge( + [AMOUNT], + [REFERENCE_NUMBER] + ); + +## + + **Note:** You can get your Short Code value from your Globe App Details in `Figure PHP.PAYMENT.4. You also need to remove the `2158` digit in your short code. + +##### Figure PHP.PAYMENT.12 - Sample Charge Response + + Array ( + "access_token" => "GesiE2YhZlxB9VVMhv-PoI8RwNTsmX0D38g", + "endUserId" => "9171234567", + "amount" => "10", + "referenceCode" => "12341000001", + "success" => true + ) + diff --git a/Android/docs/sms.md b/Android/docs/sms.md new file mode 100644 index 0000000..a7c6885 --- /dev/null +++ b/Android/docs/sms.md @@ -0,0 +1,154 @@ +## Introduction + +The Globe Short Message Service(SMS) API lets you develop client applications to communicate with people via text messaging. This document describes how to use the OAUTH/RESTful calling style and client library for Android to access and create Globe message data. + +## Getting Started + +The first thing we need to do is obtain an **APP ID** and **APP SECRET** from [Globe's Developer Website](http://developer.globelabs.com.ph/users/login). When visiting the link provided you should see a login form similar to *Figure Android.SMS.1*. + +##### Figure Android.SMS.1 - Login +![Login Screen](https://raw.github.com/Openovate/rest-docs/master/sms/assets/login.jpg) +==== + + Currently Globe's RESTful API is in BETA Mode. Ask your local Globe support to gain access to this BETA. + +Next, login with your given credentials to get to the APP screen. When you get to the app screen scroll to the bottom right and click the "create" button to create a new app. You should see something familiar to *Figure Android.SMS.2* + +##### Figure Android.SMS.2 - Create App Button +![Create App Button](https://raw.github.com/Openovate/rest-docs/master/sms/assets/create.jpg) +==== + +This will bring you to a form with required information that Globe will need to process your app creation. Fill out this form with the required fields at the very least and press Submit found at the bottom right in *Figure Android.SMS.3*. + +##### Figure Android.SMS.3 - Create App Form +![Create App Form](https://raw.github.com/Openovate/rest-docs/master/sms/assets/form.jpg) +==== + + **Important:** It's important that the Redirect URI and the Notify URI are using actual + URLs as in http://www.example.com/callback. Globe will call these URLs as described in the field. + +From here you should be returned to the APP Detail Page in *Figure Android.SMS.4*. The important thing here is the **APP ID** and **APP SECRET**. These will be the information that you will need to manually set in the configurations when writing your application. + +##### Figure Android.SMS.4 - App Details +![Create App Form](https://raw.github.com/Openovate/rest-docs/master/sms/assets/detail.jpg) + + **Note:** The data in this screen doesn't actually work. Please don't assume something went + wrong because you tried to use it. + +## How to Include + +First thing before you do any calls for Globe API using Android wrapper class is to include the base class called GlobeApi. + +##### Figure Android.SMS.5 - Include Base Class +![Import](https://raw.github.com/Openovate/rest-docs/master/sms/assets/figure1.png) +Import the android project + +![Use as library](https://raw.github.com/Openovate/rest-docs/master/sms/assets/figure2.png) +Use the globe api project as a library to your android project + + GlobeApi globe = new GlobeApi(); + +##### + +## Authentication + +Once we obtain the **APP ID** and **APP SECRET** we can begin to understand how the authentication works. Globe uses [OAUTH2](https://developers.google.com/accounts/docs/OAuth2), a common Android.SMScol to authenticate developers to use API Android.SMScols. To begin the authentication process you must redirect the user to a formatted URL using your **APP ID** and **APP SECRET** as in *Figure Android.SMS.6*. + +##### Figure Android.SMS.6 - Invoke a Redirection + +Now, initialize the `Auth` class inside GlobeApi and get the login URL using the `getLoginUrl` method. + + Auth oauth = globe.auth("[KEY]", "[SECRET"); + Strnig loginUrl = oauth.getLoginUrl(); + +Before invoking your redirect, please replace `[YOUR APP ID]` and `[YOUR APP SECRET]` in the figure above with your actual **APP ID** and **APP SECRET**. Based on what you inputed as your **Redirect URI** in your app details. Globe will authenticate permissions first with the user which should look like *Figure Android.SMS.7a* and *Figure Android.SMS.7b*. + +##### Figure Android.SMS.7a - User Flow +![User Flow](https://raw.github.com/Openovate/rest-docs/master/sms/assets/user.jpg) +==== +##### Figure Android.SMS.7b - Authorize +![Authorize](https://raw.github.com/Openovate/rest-docs/master/sms/assets/user.jpg) +==== + +Once the user gives permission, Globe will redirect the user to your Redirect URI with a `code` parameter appended to the end of it. This is how we recieve the code to continue the authentication process. *Figure Android.SMS.8* shows how this redirect will look like given that we set our redirect URI to `http://www.example.com/callback` in our app create form in *Figure Android.SMS.3*. + + **Important:** It is also possible that a user can give permissions to your app using just their + phone via SMS. Globe will call (not a phone call) your redirect URI with `access_token` and + `subscriber_number` appended to the end of it. From here you can process this request and + ignore the rest of the authentication process below. + +##### Figure Android.SMS.8 - Redirected URI Sample + + http://www.example.com/callback?code=12345 + +`12345` in the URL figure above is what we need in order to get a more long lasting token for your app to use when making API calls. Everytime you make this call the `code` returned will be unique, so you should not hard code the `code` value in your application. The final step in the authentication process is about exchanging your `code` with a more permanent access token. We need to send Globe one final request shown in *Figure Android.SMS.9* + +##### Figure Android.SMS.9 - Get the Access Token + +Using the `Auth` object we initialized in **Figure Android.SMS.6**, we can get the access token using the script below. + + oauth.getAccessToken([CODE], new PostRequestHandler() { + @Override + public void postProcess(String string) { + // is a json string containing the response of the server. + Log.d("TEST ACCESS", string); + } + }); + +Before sending, please replace `[CODE]` in the figure above with the code given from *Figure Android.SMS.8*. + +Finally, Globe will return an access token you can use to start using the SMS API. **Figure Android.SMS.10** shows how this response will look like + +##### Figure Android.SMS.10 - Access Token via JSON + + { + "access_token": "GesiE2YhZlxB9VVMhv-PoI8RwNTsmX0D38g", + "subscriber_number": "9051234567"' + } + +## + + **Note:** The data in above doesn't actually work. Please don't assume something went wrong + because you tried to use it. + +## Sending + +##### Figure Android.SMS.11 - Sample Send Message Request + +First we need to initialize the `GlobeApi` class and then use that object to send SMS. + + GlobeApi globe = new GlobeApi(); + Sms sms = globe.sms([SHORT_CODE]); + sms.sendMessage([access_token], [number], [message], new PostRequestHandler() { + @Override + public void postProcess(String string) { + // is a json string containing the response of the server. + Log.d("TEST ACCESS", string); + } + }); + +##### + + **Note:** You can get your Short Code value from your Globe App Details in `Figure Android.SMS.4. You also need to remove the `2158` digit in your short code. + +##### Figure Android.SMS.12 - Sample Send Message Response + + { + "outboundSMSMessageRequest": { + "address": "09171234567", + "deliveryInfoList": { + "deliveryInfo": [], + "resourceURL": null + }, + "senderAddress": "1234", + "outboundSMSTextMessage": { + "message": "hello" + }, + "reciptRequest": { + "notifyURL": null, + "callbackData": null, + "senderName": null, + "resourceURL": null + } + } + } diff --git a/Android/lib/GlobeApiWrapper.zip b/Android/lib/GlobeApiWrapper.zip new file mode 100644 index 0000000..1ab1f7f Binary files /dev/null and b/Android/lib/GlobeApiWrapper.zip differ diff --git a/Android/src/com/globelabs/api/Auth.java b/Android/src/com/globelabs/api/Auth.java new file mode 100644 index 0000000..8336f17 --- /dev/null +++ b/Android/src/com/globelabs/api/Auth.java @@ -0,0 +1,35 @@ +package com.globelabs.api; + +import java.io.UnsupportedEncodingException; +import java.net.URLEncoder; + +public class Auth extends GlobeApi { + public static final String LOGIN_URL = "http://%s/dialog/oauth"; + public static final String AUTH_URL = "http://%s/oauth/access_token"; + + protected String key; + protected String secret; + + public Auth(String key, String secret) { + this.key = key; + this.secret = secret; + } + + public String getLoginUrl() { + return String.format(Auth.LOGIN_URL, GlobeApi.AUTH_POINT)+"?app_id="+this.key; + } + + public void getAccessToken(String code, PostRequestHandler handler) { + try { + String key = URLEncoder.encode(this.key, "utf-8"); + String secret = URLEncoder.encode(this.secret, "utf-8"); + String codeEncode = URLEncoder.encode(code, "utf-8"); + String url = String.format(Auth.AUTH_URL, GlobeApi.AUTH_POINT)+"?app_id="+key+"&app_secret="+secret+"&code="+codeEncode; + this.__curlPost(url, null, handler); + } catch (UnsupportedEncodingException e) { + // TODO Auto-generated catch block + e.printStackTrace(); + } + + } +} diff --git a/Android/src/com/globelabs/api/GlobeApi.java b/Android/src/com/globelabs/api/GlobeApi.java new file mode 100644 index 0000000..a64de32 --- /dev/null +++ b/Android/src/com/globelabs/api/GlobeApi.java @@ -0,0 +1,73 @@ +package com.globelabs.api; + +import java.io.UnsupportedEncodingException; +import java.util.List; + +import org.apache.http.NameValuePair; +import org.apache.http.client.HttpClient; +import org.apache.http.client.entity.UrlEncodedFormEntity; +import org.apache.http.client.methods.HttpGet; +import org.apache.http.client.methods.HttpPost; +import org.apache.http.impl.client.DefaultHttpClient; + +public class GlobeApi { + public static final String API_ENDPOINT = "devapi.globelabs.com.ph"; + public static final String AUTH_POINT = "developer.globelabs.com.ph"; + + protected String version; + + public GlobeApi() { + this.version = "v1"; + } + + public GlobeApi(String version) { + this.version = version; + } + + public Auth auth(String key, String secret) { + return new Auth(key, secret); + } + + public Payment payment(String token, String toCharge) { + return new Payment("v1", toCharge, token); + } + + public Payment payment(String token, String toCharge, String version) { + return new Payment(version, toCharge, token); + } + + public Sms sms(String shortCode) { + return new Sms(shortCode, this.version); + } + + public Sms sms(String shortCode, String version) { + return new Sms(shortCode, version); + } + + protected void __curlPost(String url, List fields, PostRequestHandler handler) { + HttpClient client = new DefaultHttpClient(); + HttpPost post = new HttpPost(url); + try { + if(fields!=null) { + post.setEntity(new UrlEncodedFormEntity(fields)); + } + HttpRequestAsyncTask task = new HttpRequestAsyncTask(); + task.setClient(client); + task.setPost(post); + task.setHandler(handler); + task.execute(); + } catch (UnsupportedEncodingException e) { + e.printStackTrace(); + } + } + + protected void __curlGet(String url, PostRequestHandler handler) { + HttpClient client = new DefaultHttpClient(); + HttpGet get = new HttpGet(url); + HttpRequestAsyncTask task = new HttpRequestAsyncTask(); + task.setClient(client); + task.setGet(get); + task.setHandler(handler); + task.execute(); + } +} diff --git a/Android/src/com/globelabs/api/HttpRequestAsyncTask.java b/Android/src/com/globelabs/api/HttpRequestAsyncTask.java new file mode 100644 index 0000000..8379834 --- /dev/null +++ b/Android/src/com/globelabs/api/HttpRequestAsyncTask.java @@ -0,0 +1,70 @@ +package com.globelabs.api; + +import java.io.IOException; +import java.lang.reflect.Method; + +import org.apache.http.HttpEntity; +import org.apache.http.HttpResponse; +import org.apache.http.client.ClientProtocolException; +import org.apache.http.client.HttpClient; +import org.apache.http.client.methods.HttpGet; +import org.apache.http.client.methods.HttpPost; +import org.apache.http.util.EntityUtils; + +import android.os.AsyncTask; + +public class HttpRequestAsyncTask extends AsyncTask { + HttpClient client; + HttpPost post; + HttpGet get; + String responseString=""; + Method method; + PostRequestHandler handler; + + public void setHandler(PostRequestHandler handler) { + this.handler = handler; + }; + + public void setClient(HttpClient client) { + this.client = client; + } + + public void setPost(HttpPost post) { + this.post = post; + } + + public void setGet(HttpGet get) { + this.get = get; + } + + public void setMethod(Method method) { + this.method = method; + } + + @Override + protected String doInBackground(String... arg0) { + try { + HttpResponse responseGet = null; + if(post!=null) { + responseGet = client.execute(post); + } else if (get!=null) { + responseGet = client.execute(get); + } + HttpEntity resEntityGet = responseGet.getEntity(); + if (resEntityGet != null) { + responseString = EntityUtils.toString(resEntityGet); + return responseString; + } + } catch (ClientProtocolException e) { + e.printStackTrace(); + } catch (IOException e) { + e.printStackTrace(); + } + return null; + } + + @Override + protected void onPostExecute(String response) { + handler.postProcess(response); + } +} diff --git a/Android/src/com/globelabs/api/Payment.java b/Android/src/com/globelabs/api/Payment.java new file mode 100644 index 0000000..2ccac82 --- /dev/null +++ b/Android/src/com/globelabs/api/Payment.java @@ -0,0 +1,70 @@ +package com.globelabs.api; + +import java.util.ArrayList; +import java.util.List; + +import org.apache.http.NameValuePair; +import org.apache.http.message.BasicNameValuePair; + +public class Payment extends GlobeApi{ + protected String version; + protected String toCharge; + protected String token; + protected String description; + protected String clientCorrelator; + + public Payment(String version, String toCharge, String token) { + this.version = version; + this.toCharge = toCharge; + this.token = token; + } + + public void setVersion(String version) { + this.version = version; + } + + public String getToCharge() { + return toCharge; + } + + public void setToCharge(String toCharge) { + this.toCharge = toCharge; + } + + public String getToken() { + return token; + } + + public void setToken(String token) { + this.token = token; + } + + public String getDescription() { + return description; + } + + public void setDescription(String description) { + this.description = description; + } + + public String getClientCorrelator() { + return clientCorrelator; + } + + public void setClientCorrelator(String clientCorrelator) { + this.clientCorrelator = clientCorrelator; + } + + public void charge(float amount, String refNo, PostRequestHandler handler) { + List parameters = new ArrayList(); + parameters.add(new BasicNameValuePair("endUserId", this.toCharge)); + parameters.add(new BasicNameValuePair("amount", String.format("%.2f", amount))); + parameters.add(new BasicNameValuePair("description", this.description)); + parameters.add(new BasicNameValuePair("referenceCode", refNo)); + parameters.add(new BasicNameValuePair("transactionOperationStatus", "charged")); + parameters.add(new BasicNameValuePair("access_token", this.token)); + String url = "http://%s/payment/%s/transactions/amount"; + url = String.format(url, GlobeApi.API_ENDPOINT, "v1"); + this.__curlPost(url, parameters, handler); + } +} diff --git a/Android/src/com/globelabs/api/PostRequestHandler.java b/Android/src/com/globelabs/api/PostRequestHandler.java new file mode 100644 index 0000000..0f1987c --- /dev/null +++ b/Android/src/com/globelabs/api/PostRequestHandler.java @@ -0,0 +1,5 @@ +package com.globelabs.api; + +public abstract class PostRequestHandler { + public abstract void postProcess(String string); +} diff --git a/Android/src/com/globelabs/api/Sms.java b/Android/src/com/globelabs/api/Sms.java new file mode 100644 index 0000000..879b2d8 --- /dev/null +++ b/Android/src/com/globelabs/api/Sms.java @@ -0,0 +1,42 @@ +package com.globelabs.api; + +import java.util.ArrayList; +import java.util.List; + +import org.apache.http.NameValuePair; +import org.apache.http.message.BasicNameValuePair; + +public class Sms extends GlobeApi{ + public static final String CURL_URL = "http://%s/smsmessaging/%s/outbound/%s/"; + + protected String version; + protected String address; + + public Sms() {} + + public Sms(String address) { + this.address = address; + } + + public Sms(String address, String version) { + this.address = address; + this.version = version; + } + + public void getMessages(PostRequestHandler handler) { + String url = "http://%s/smsmessaging/%s/inbound/registrations/%s/messages"; + url = String.format(url, GlobeApi.API_ENDPOINT, "v1", this.address); + this.__curlGet(url, handler); + } + + public void sendMessage(String accessToken, String sendTo, String message, PostRequestHandler handler) { + List parameters = new ArrayList(); + parameters.add(new BasicNameValuePair("access_token", accessToken)); + parameters.add(new BasicNameValuePair("address", sendTo)); + parameters.add(new BasicNameValuePair("message", message)); + parameters.add(new BasicNameValuePair("senderAddress", this.address)); + String url = "http://%s/smsmessaging/%s/outbound/%s/requests"; + url = String.format(url, GlobeApi.API_ENDPOINT, "v1", this.address); + this.__curlPost(url, parameters, handler); + } +} diff --git a/Android/test/com/globelabs/api/MainActivity.java b/Android/test/com/globelabs/api/MainActivity.java new file mode 100644 index 0000000..fefac05 --- /dev/null +++ b/Android/test/com/globelabs/api/MainActivity.java @@ -0,0 +1,54 @@ +package com.globelabs.api; + +import android.os.Bundle; +import android.app.Activity; +import android.util.Log; +import android.view.Menu; + +public class MainActivity extends Activity { + + @Override + protected void onCreate(Bundle savedInstanceState) { + super.onCreate(savedInstanceState); + setContentView(R.layout.activity_main); + GlobeApi globe = new GlobeApi(); + + Auth oauth = globe.auth("[KEY]", "[SECRET]"); + Log.d("Login", oauth.getLoginUrl()); + oauth.getAccessToken("[CODE]", + new PostRequestHandler() { + @Override + public void postProcess(String string) { + Log.d("TEST ACCESS", string); + } + }); + Sms sms = globe.sms("[SHORTCODE]"); + sms.sendMessage("[ACCESS_TOKEN]", + "[RECEIVER_NUMBER]", + "[MESSAGE]", + new PostRequestHandler() { + public void postProcess(String string) { + //process the json response here + Log.d("SEND SMS RESPONSE", string); + } + }); + + Payment payment = globe.payment("[ACCESS_TOKEN]", "[RECEIVER_NUMBER]"); + payment.charge([AMOUNT], "[REFERENCE_CODE]", new PostRequestHandler() { + @Override + public void postProcess(String string) { + //process the json response here + Log.d("CHARGE RESPONSE", string); + } + } + ); + } + + @Override + public boolean onCreateOptionsMenu(Menu menu) { + // Inflate the menu; this adds items to the action bar if it is present. + getMenuInflater().inflate(R.menu.main, menu); + return true; + } + +} diff --git a/Java/README b/Java/README index 0880c14..cd64e11 100644 --- a/Java/README +++ b/Java/README @@ -20,5 +20,7 @@ WHERE TO BEGIN First, you need to include the JAR file (and its dependencies) into your lib (and build path). -For an idea on how to use the classes (OAuth, SMS, and Payment), -kindly check out the tests and the documentation. +For an idea on how to use the classes (Auth, SMS, and Payment), +kindly check out the sample runners, tests, documentation, and +javadocs. + diff --git a/Java/docs/payment.md b/Java/docs/payment.md new file mode 100644 index 0000000..93de14f --- /dev/null +++ b/Java/docs/payment.md @@ -0,0 +1,138 @@ +## Introduction + +The Globe Payment API lets you develop client applications to charge subscribers. This document describes how to use the OAUTH/RESTful calling style and client library for Java. For other languages and library you can access the Payment protocol manually. The following documentation describes how you can access the Payment API directly with examples of request types, options and responses. + +You may also check out the javadocs at Java/javadocs. + +## Getting Started + +The first thing we need to do is obtain an **APP ID**, **APP SECRET**, and **SHORTCODE** from [Globe's Developer Website](http://developer.globelabs.com.ph/users/login). When visiting the link provided you should see a login form similar to *Figure JAVA.PAYMENT.1*. + +##### Figure JAVA.PAYMENT.1 - Login +![Login Screen](https://raw.github.com/Openovate/rest-docs/master/sms/assets/login.jpg) +==== + + Currently Globe's RESTful API is in BETA Mode. Ask your local Globe support to gain access to this BETA. + +Next, login with your given credentials to get to the APP screen. When you get to the app screen scroll to the bottom right and click the "create" button to create a new app. You should see something familiar to *Figure JAVA.PAYMENT.2* + +##### Figure JAVA.PAYMENT.2 - Create App Button +![Create App Button](https://raw.github.com/Openovate/rest-docs/master/sms/assets/create.jpg) +==== + +This will bring you to a form with required information that Globe will need to process your app creation. Fill out this form with the required fields at the very least and press Submit found at the bottom right in *Figure JAVA.PAYMENT.3*. + +##### Figure JAVA.PAYMENT.3 - Create App Form +![Create App Form](https://raw.github.com/Openovate/rest-docs/master/sms/assets/form.jpg) +==== + + **Important:** It's important that the Redirect URI and the Notify URI are using actual + URLs as in http://www.example.com/callback. Globe will call these URLs as described in the field. + +From here you should be returned to the APP Detail Page in *Figure JAVA.PAYMENT.4*. You will need the **APP ID**, **APP SECRET**, and the **SHORTCODE** in writing your application. + +##### Figure JAVA.PAYMENT.4 - App Details +![Create App Form](https://raw.github.com/Openovate/rest-docs/master/sms/assets/detail.jpg) + + **Note:** The data in this screen doesn't actually work. Please don't assume something went + wrong because you tried to use it. + +## How to Include + +##### Figure JAVA.PAYMENT.5 - Include necessary JAR files in your lib and build path + + **Note:** You can find the necessary JAR files inside the Java/lib/ folder. + + Main JAR file: globe-api-[version]-bin.jar + + Dependencies include the following JARs: + + 1. Apache Commons IO 2.4 - commons-io-2.4.jar + 2. Apache Commons Logging 1.1.3 - commons-logging-1.1.3.jar + 3. Apache HttpClient 4.3.1 - httpclient-4.3.1.jar + 4. Apache HttpCore 4.3 - httpcore-4.3.jar + 5. JSON (JavaScript Object Notation) - json-20090211.jar + + You may also include these dependencies via Maven if available. + +## Authentication + +Once we obtain the **APP ID** and **APP SECRET** we can begin to understand how the authentication works. Globe uses [OAUTH2](https://developers.google.com/accounts/docs/OAuth2), a common protocol to authenticate developers to use API protocols. To begin the authentication process you must redirect the user to a formatted URL using your **APP ID** as in *Figure JAVA.PAYMENT.6*. + +##### Figure JAVA.PAYMENT.6 - Invoke a Redirection + +Now, initialize the `Auth` class and get the login URL using the `getLoginUrl` method. + + Auth auth = new Auth(); + String loginUrl = auth.getLoginUrl([APP_ID]); + +Before invoking your redirect, please replace `[YOUR APP ID]` in the figure above with your actual **APP ID**. Globe will authenticate permissions first with the user which should look like *Figure JAVA.PAYMENT.7a* and *Figure JAVA.PAYMENT.7b*. + +##### Figure JAVA.PAYMENT.7a - User Flow +![User Flow](https://raw.github.com/Openovate/rest-docs/master/sms/assets/user.jpg) +==== +##### Figure JAVA.PAYMENT.7b - Authorize +![Authorize](https://raw.github.com/Openovate/rest-docs/master/sms/assets/user.jpg) +==== + +Once the user gives permission, Globe will redirect the user to your **Redirect URI** with a `code` parameter appended to the end of it. This is how we receive the code to continue the authentication process. *Figure JAVA.PAYMENT.8* shows how this redirect will look like given that we set our redirect URI to `http://www.example.com/callback` in our app create form in *Figure JAVA.PAYMENT.3*. + + **Important:** It is also possible that a user can give permissions to your app using just their + phone via SMS. Globe will call (not a phone call) your redirect URI with `access_token` and + `subscriber_number` appended to the end of it. From here you can process this request and + ignore the rest of the authentication process below. + +##### Figure JAVA.PAYMENT.8 - Redirected URI Sample + + http://www.example.com/callback?code=12345 + +`12345` in the URL figure above is what we need in order to get a more long lasting token for your app to use when making API calls. Everytime you make this call the `code` returned will be unique, so you should not hard code the `code` value in your application. The final step in the authentication process is about exchanging your `code` with a more permanent access token. We need to send Globe one final request shown in *Figure JAVA.PAYMENT.9* + +##### Figure JAVA.PAYMENT.9 - Get the Access Token + +Using the `Auth` object we initialized in **Figure JAVA.PAYMENT.6**, we can get the access token using the script below. + + AccessTokenResponse response = auth.getAccessToken([APP_ID], [APP_SECRET], [CODE]); + +Before sending, please replace `[APP_ID]`, `[APP_SECRET]`, and `[CODE]` in the figure above with the your respective given app ID, app secret, and the code given from Figure JAVA.PAYMENT.8. + +Finally, Globe will return an access token you can use to start using the Charge API. **Figure JAVA.PAYMENT.10** shows how this response will look like + +##### Figure JAVA.PAYMENT.10 - Access Token Response + + AccessTokenResponse [accessToken=_Ak28sdfl32r908sdf0q843qjlkjdf90234jlkasd98, subscriberNumber=9173849494] Response [responseCode=200, responseMessage=OK, statusLine=HTTP/1.1 200 OK, content={"subscriber_number":"9173849494","access_token":"_Ak28sdfl32r908sdf0q843qjlkjdf90234jlkasd98"}] + +## + + **Note:** The data above doesn't actually work. Please don't assume something went wrong + because you tried to use it. + + +## Charge a User + +To use the Payment API you will need to send a POST request to the URL given below. + +**Request URL** + + http://devapi.globelabs.com.ph/payment/v1/transactions/amount + +**Parameters** + +| Parameters | Definition | Data Type | +|-------|:----------:|:---------:| +| [ACCESS_TOKEN] | which contains security information for transacting with a subscriber. Subscriber needs to grant an app first via SMS or Web Form Subscriber Consent Workflow. | String | +| [SUBSCRIBER_NUMBER] | is the 10-digit MSISDN (mobile number) which you will charge to. Parameter format can be `9xxxxxxxx` | String | +| [AMOUNT] | amount to be charged to the subscriber | BigDecimal | +| [REFERENCE_NUMBER] | a unique transaction ID with a format of `[SHORTCODE_WITHOUT_2158]`+`#######` where `#######` is an incremented number beginning from `1000001`. | (numeric) String | + + +##### Figure JAVA.PAYMENT.11 - Sample Charge Request + + Payment payment = new Payment([SUBSCRIBER_NUMBER], [ACCESS_TOKEN]); + payment.charge([AMOUNT], [REFERENCE_NUMBER]); + + **Note:** You can get your Short Code value from your Globe App Details in `Figure JAVA.PAYMENT.4. You also need to remove the `2158` digit in your short code. + +##### Figure JAVA.PAYMENT.12 - Sample Charge Response + + ChargeUserResponse [success=true, amount=10.00, subscriberNumber=9173849494, referenceCode=99991000001, accessToken=_Ak28sdfl32r908sdf0q843qjlkjdf90234jlkasd98] Response [responseCode=201, responseMessage=Created, statusLine=HTTP/1.1 201 Created, content={"amount":"10","endUserId":"9173849494","referenceCode":"REF-12345","success":"true","access_token":"_Ak28sdfl32r908sdf0q843qjlkjdf90234jlkasd98"}] diff --git a/Java/docs/sms.md b/Java/docs/sms.md new file mode 100644 index 0000000..05720a3 --- /dev/null +++ b/Java/docs/sms.md @@ -0,0 +1,169 @@ +## Introduction + +The Globe Short Message Service(SMS) API lets you develop client applications to communicate with people via text messaging. This document describes how to use the OAUTH/RESTful calling style and client library for Java to access and create Globe message data. + +You may also check out the javadocs at Java/javadocs. + +## Getting Started + +The first thing we need to do is obtain an **APP ID**, **APP SECRET**, and **SHORTCODE** from [Globe's Developer Website](http://developer.globelabs.com.ph/users/login). When visiting the link provided you should see a login form similar to *Figure JAVA.SMS.1*. + +##### Figure JAVA.SMS.1 - Login +![Login Screen](https://raw.github.com/Openovate/rest-docs/master/sms/assets/login.jpg) +==== + + Currently Globe's RESTful API is in BETA Mode. Ask your local Globe support to gain access to this BETA. + +Next, login with your given credentials to get to the APP screen. When you get to the app screen scroll to the bottom right and click the "create" button to create a new app. You should see something familiar to *Figure JAVA.SMS.2* + +##### Figure JAVA.SMS.2 - Create App Button +![Create App Button](https://raw.github.com/Openovate/rest-docs/master/sms/assets/create.jpg) +==== + +This will bring you to a form with required information that Globe will need to process your app creation. Fill out this form with the required fields at the very least and press Submit found at the bottom right in *Figure JAVA.SMS.3*. + +##### Figure JAVA.SMS.3 - Create App Form +![Create App Form](https://raw.github.com/Openovate/rest-docs/master/sms/assets/form.jpg) +==== + + **Important:** It's important that the Redirect URI and the Notify URI are using actual + URLs as in http://www.example.com/callback. Globe will call these URLs as described in the field. + +From here you should be returned to the APP Detail Page in *Figure JAVA.SMS.4*. You will need the **APP ID**, **APP SECRET**, and the **SHORTCODE** in writing your application. + +##### Figure JAVA.SMS.4 - App Details +![Create App Form](https://raw.github.com/Openovate/rest-docs/master/sms/assets/detail.jpg) + + **Note:** The data in this screen doesn't actually work. Please don't assume something went + wrong because you tried to use it. + +## How to Include + +##### Figure JAVA.SMS.5 - Include necessary JAR files in your lib and build path + + **Note:** You can find the necessary JAR files inside the Java/lib/ folder. + + Main JAR file: globe-api-[version]-bin.jar + + Dependencies include the following JARs: + + 1. Apache Commons IO 2.4 - commons-io-2.4.jar + 2. Apache Commons Logging 1.1.3 - commons-logging-1.1.3.jar + 3. Apache HttpClient 4.3.1 - httpclient-4.3.1.jar + 4. Apache HttpCore 4.3 - httpcore-4.3.jar + 5. JSON (JavaScript Object Notation) - json-20090211.jar + + You may also include these dependencies via Maven if available. + +## Authentication + +Once we obtain the **APP ID** and **APP SECRET** we can begin to understand how the authentication works. Globe uses [OAUTH2](https://developers.google.com/accounts/docs/OAuth2), a common protocol to authenticate developers to use API protocols. To begin the authentication process you must redirect the user to a formatted URL using your **APP ID** as in *Figure JAVA.SMS.6*. + +##### Figure JAVA.SMS.6 - Invoke a Redirection + +Now, initialize the `Auth` class and get the login URL using the `getLoginUrl` method. + + Auth auth = new Auth(); + String loginUrl = auth.getLoginUrl([APP_ID]); + +Before invoking your redirect, please replace `[YOUR APP ID]` in the figure above with your actual **APP ID**. Globe will authenticate permissions first with the user which should look like *Figure JAVA.SMS.7a* and *Figure JAVA.SMS.7b*. + +##### Figure JAVA.SMS.7a - User Flow +![User Flow](https://raw.github.com/Openovate/rest-docs/master/sms/assets/user.jpg) +==== +##### Figure JAVA.SMS.7b - Authorize +![Authorize](https://raw.github.com/Openovate/rest-docs/master/sms/assets/user.jpg) +==== + +Once the user gives permission, Globe will redirect the user to your **Redirect URI** with a `code` parameter appended to the end of it. This is how we receive the code to continue the authentication process. *Figure JAVA.SMS.8* shows how this redirect will look like given that we set our redirect URI to `http://www.example.com/callback` in our app create form in *Figure JAVA.SMS.3*. + + **Important:** It is also possible that a user can give permissions to your app using just their + phone via SMS. Globe will call (not a phone call) your redirect URI with `access_token` and + `subscriber_number` appended to the end of it. From here you can process this request and + ignore the rest of the authentication process below. + +##### Figure JAVA.SMS.8 - Redirected URI Sample + + http://www.example.com/callback?code=12345 + +`12345` in the URL figure above is what we need in order to get a more long lasting token for your app to use when making API calls. Everytime you make this call the `code` returned will be unique, so you should not hard code the `code` value in your application. The final step in the authentication process is about exchanging your `code` with a more permanent access token. We need to send Globe one final request shown in *Figure JAVA.SMS.9* + +##### Figure JAVA.SMS.9 - Get the Access Token + +Using the `Auth` object we initialized in **Figure JAVA.SMS.6**, we can get the access token using the script below. + + AccessTokenResponse response = auth.getAccessToken([APP_ID], [APP_SECRET], [CODE]); + +Before sending, please replace `[APP_ID]`, `[APP_SECRET]`, and `[CODE]` in the figure above with the your respective given app ID, app secret, and the code given from Figure JAVA.SMS.8. + +Finally, Globe will return an access token you can use to start using the Charge API. **Figure JAVA.SMS.10** shows how this response will look like + +##### Figure JAVA.SMS.10 - Access Token Response + + AccessTokenResponse [accessToken=_Ak28sdfl32r908sdf0q843qjlkjdf90234jlkasd98, subscriberNumber=9173849494] Response [responseCode=200, responseMessage=OK, statusLine=HTTP/1.1 200 OK, content={"subscriber_number":"9173849494","access_token":"_Ak28sdfl32r908sdf0q843qjlkjdf90234jlkasd98"}] + +## + + **Note:** The data above doesn't actually work. Please don't assume something went wrong + because you tried to use it. + + +## Sending an SMS to a subscriber + +##### Figure JAVA.SMS.11 - Sample Send Message Request + + Sms sms = new Sms([SHORTCODE]); + sms.sendMessage([SUBSCRIBER_NUMBER], [ACCESS_TOKEN], [MESSAGE]); + sms.sendMessage([SUBSCRIBER_NUMBER], [ACCESS_TOKEN], [CLIENT_CORRELATOR]); + +**Parameters** + +| Parameters | Definition | Data Type | +|-------|:----------:|:---------:| +| [SHORTCODE] | the last 4 digits of your shortcode. 2158XXXX. | String | +| [ACCESS_TOKEN] | which contains security information for transacting with a subscriber. Subscriber needs to grant an app first via SMS or Web Form Subscriber Consent Workflow. | String | +| [SUBSCRIBER_NUMBER] | is the 10-digit MSISDN (mobile number) which you will charge to. Parameter format can be `9xxxxxxxx` | String | +| [MESSAGE] | the SMS body. Must be 160 characters or less. | String | +| [CLIENT_CORRELATOR] | (OPTIONAL) uniquely identifies this create SMS request. If there is a communication failure during the request, using the same clientCorrelator when retrying the request allows the operator to avoid sending the same SMS twice. | String | + + **Note:** You can get your Short Code value from your Globe App Details in `Figure JAVA.SMS.4. You also need to remove the `2158` digit in your short code. + +##### Figure JAVA.SMS.12 - Sample Send Message Response + + SendSmsResponse [success=true, message=Hello World, address=9173849494, senderAddress=9999, accessToken=_Ak28sdfl32r908sdf0q843qjlkjdf90234jlkasd98] Response [responseCode=201, responseMessage=Created, statusLine=HTTP/1.1 201 Created, content={"message":"Hello World","senderAddress":"9999","address":"9173849494","success":"true","access_token":"_Ak28sdfl32r908sdf0q843qjlkjdf90234jlkasd98"}] + + +## Parsing a Received SMS + +##### Figure JAVA.SMS.11 - Sample Get Message Request + + Sms sms = new Sms([SHORTCODE]); + sms.getMessage([RAW_BODY]); + +**Parameters** + +| Parameters | Definition | Data Type | +|-------|:----------:|:---------:| +| [RAW_BODY] | the raw body sent by the Globe Server to the notify URL. | String | + +Sample raw body + + { + "inboundSMSMessageList":{ + "inboundSMSMessage":[{ + "dateTime":"Fri Nov 29 2013 00:16:17 GMT+0000 (UTC)", + "destinationAddress":"tel:21589999", + "messageId":"5297dcd17b8a4ead5f000032", + "message":"A B C D .E", + "resourceURL":null, + "senderAddress":"tel:+639173849494" + }], + "numberOfMessagesInThisBatch":1, + "resourceURL":null, + "totalNumberOfPendingMessages":0 + } + } + +##### Figure JAVA.SMS.12 - Sample Send Message Response + + SmsResponse [inboundSmsMessages=[InboundSmsMessage [senderAddress=tel:+639173849494, destinationAddress=tel:21589999, message=A B C D .E, dateTime=Fri Nov 29 2013 00:16:17 GMT+0000 (UTC), messageId=5297dcd17b8a4ead5f000032, resourceURL=null]], numberOfMessagesInThisBatch=1, resourceURL=null, totalNumberOfPendingMessages=0] diff --git a/Java/globe-api-1.0.0-bin.jar b/Java/globe-api-1.0.0-bin.jar deleted file mode 100644 index 607ec76..0000000 Binary files a/Java/globe-api-1.0.0-bin.jar and /dev/null differ diff --git a/Java/javadocs/allclasses-frame.html b/Java/javadocs/allclasses-frame.html index 5b824f5..499bb01 100644 --- a/Java/javadocs/allclasses-frame.html +++ b/Java/javadocs/allclasses-frame.html @@ -2,9 +2,9 @@ - + All Classes - + @@ -12,11 +12,10 @@

All Classes

@@ -115,7 +115,7 @@

Constructor Summary

Constructor and Description -OAuth()  +Auth()  @@ -134,14 +134,14 @@

Method Summary

AccessTokenResponse -getAccessToken(java.lang.String requestURL) +getAccessToken(java.lang.String requestURL)
Parses the access token for a given subscriber provided the subscriber has completed the authentication process via SMS.
AccessTokenResponse -getAccessToken(java.lang.String appId, +getAccessToken(java.lang.String appId, java.lang.String appSecret, java.lang.String code)
Retrieves the access token for a given subscriber provided the subscriber @@ -150,11 +150,11 @@

Method Summary

HttpPostClient -getClient()  +getClient()  java.lang.String -getLoginUrl(java.lang.String appId) +getLoginUrl(java.lang.String appId)
Builds a login URL from a given app ID.
@@ -180,16 +180,16 @@

Methods inherited from class java.lang.Object

Constructor Detail

- +
  • -

    OAuth

    -
    public OAuth()
    -      throws GlobeApiException
    +

    Auth

    +
    public Auth()
    +     throws ph.com.globelabs.api.exception.GlobeApiException
    Throws:
    -
    GlobeApiException
    +
    ph.com.globelabs.api.exception.GlobeApiException
@@ -207,7 +207,7 @@

Method Detail

  • getAccessToken

    public AccessTokenResponse getAccessToken(java.lang.String requestURL)
    -                                   throws GlobeApiException
    + throws ph.com.globelabs.api.exception.GlobeApiException
    Parses the access token for a given subscriber provided the subscriber has completed the authentication process via SMS.
    Parameters:
    requestURL - The callback URL along with the query parameters as called by @@ -215,7 +215,7 @@

    getAccessToken

    must include access_token and subscription_number.
    Returns:
    Access token and subscriber number
    Throws:
    -
    GlobeApiException
    +
    ph.com.globelabs.api.exception.GlobeApiException
  • @@ -227,14 +227,14 @@

    getAccessToken

    public AccessTokenResponse getAccessToken(java.lang.String appId,
                                      java.lang.String appSecret,
                                      java.lang.String code)
    -                                   throws GlobeApiException
    + throws ph.com.globelabs.api.exception.GlobeApiException
    Retrieves the access token for a given subscriber provided the subscriber has completed the authentication process through web (via the login URL).
    Parameters:
    appId - Given app ID by Globe Labs
    appSecret - Given app secret by Globe Labs
    code - The code sent by Globe Labs to the callback URL after subscriber has completed the web authentication process
    Returns:
    Access token and subscriber number
    Throws:
    -
    GlobeApiException
    +
    ph.com.globelabs.api.exception.GlobeApiException
    @@ -253,13 +253,13 @@

    getClient

  • getLoginUrl

    public java.lang.String getLoginUrl(java.lang.String appId)
    -                             throws GlobeApiException
    + throws ph.com.globelabs.api.exception.GlobeApiException
    Builds a login URL from a given app ID. This URL is used for the OAuth first leg.
    Parameters:
    appId - Given app ID by Globe Labs
    Returns:
    Login URL for user subscription and authentication to the app
    Throws:
    -
    GlobeApiException
    +
    ph.com.globelabs.api.exception.GlobeApiException
  • @@ -279,7 +279,7 @@

    getLoginUrl

  • Overview
  • Package
  • -
  • Use
  • +
  • Use
  • Tree
  • Index
  • Help
  • @@ -291,8 +291,8 @@

    getLoginUrl

  • Next Class
  • -

    Uses of Class
    ph.com.globelabs.api.OAuth

    +

    Uses of Class
    ph.com.globelabs.api.Auth

    -
    No usage of ph.com.globelabs.api.OAuth
    +
    No usage of ph.com.globelabs.api.Auth
    @@ -74,7 +74,7 @@

    Uses of Class