Tools Developer Guide - ONE-store/inapp-sdk-eng GitHub Wiki

Overview

This guide describes URL Scheme connection and various APIs of the ONE store App.

URL Scheme Connection of ONE store App

You can use URL scheme to open an app download page of ONE store in your mobile apps and browsers. Strings like http://, ftp://, market:// are called URL scheme’ The way to execute an App via the URL scheme is as follows:

  • A URL scheme is passed to Android system when a user clicks a hyperlink with it in an app or a web page
  • The system checks whether there is an app installed in the device which is directly executable through the URL scheme
  • If there is one, the system runs the app, passing over the URL scheme
  • While being executed, the app would perform certain features by referring to the contents included in the URL scheme.

If you use the URL scheme through a mobile browser, you would need to implement an exception handling feature just in case ONE store is not installed in a device

URL Scheme Configuration

For more on each call specification, refer to Tools Reference.

App/Game Detail Call

In Product View, the clients of each mobile operator move to ‘See Details’ screen for the corresponding product ID (‘See Details’ screen of a single product).

Specification

onestore://common/product/{product ID}

Sample

onestore://common/product/0000252337

Search Call

In Search View, the ONE store App shows the search result screen for the corresponding query.

Specification

onestore://common/search/{query}

Sample

onestore://common/search/naver app

Request Update (Automatic Installation)

If the corresponding product is not the latest version, the updated version is automatically downloaded and installed at the update request of App/game products. The update works when the PKG name of the product to request update does match the PKG name of the product to be downloaded.

Specification

onestore://common/product/bg_update/{product ID}

Sample

onestore://common/product/bg_update/0000252337

Connection to Shorten URLs

You can easily generate a connection address of App detail page by using product ID.

Specification

https://onesto.re/{productID}

Sample

https://onesto.re/0000252337

Process Redirects of Current Specification

The current connection specification individually used in each store is automatically redirected. That means, an additional development is separately needed for the currently published products.

Current Spec. Redirect New Spec.
기존연동규격 리다이렉트 신규 규격

Referrer Support (Tracking tool support)

If you need to analyze advertisement performance or collect statistical data, you would want to attach referrer parameter to the end of URL scheme. Because every tracking tool including AdBrix, TUNE, Adjust, and Appsflyer is supported, you can easily collect and analyze install marekting performance with a measurement URL you issue in your tracking tool. ONE Store support maximum 60 days look-back window, so that you can tailor it in your tracking tool according to your exact marketing purpose.

Specification

onestore://common/product/{product ID}?referrer=(STRING)

or 

https://onesto.re/{product ID}?referrer=(STRING)

Sample

onestore://common/product/0000652407?referrer=com.square_enix.android.finalfantasy_sp%26ck%3d5416300%26sn%3d17866395096%26cid%3d961204606_17866395096

or 

https://onesto.re/0000652407?referrer=com.square_enix.android.finalfantasy_sp%26ck%3d5416300%26sn%3d17866395096%26cid%3d961204606_17866395096

Call URL scheme from Mobile Web page

Enter the custom URL, which is defiend above as the html hyperlink reference. Configure the html page to branch as seen below when the user clicks the corresponding link.

How to Implement Processing Method When App Is Not Installed

It can be immediately executed with an App. However, if setTimeout occurs using javascript timer without an App, use a method of branching to other stores, including mobile web pages or Google Play (if the App is not installed, an error pop-up could be shown for a while before moving to other pages). Seen below is an example script configuration.

You may need to process iframe to hide system error messages. The use of intent scheme allows simpler processing.


var url = "onestore://common/product/0000252337?view_type=1"; 
var ONEstoreUrl = "https://onesto.re/0000252337" 

function onClickApp(url) { 
    var clickedAt = +new Date; 
                                               
    AppCheckTimer = setTimeout(function() { 
    if (+new Date - clickedAt < 2000){ 
        if (window.confirm("The latest version of the ONE store app is not installed. \Move to n mobile web page")) 
        { location.href = ONEstoreUrl; } 
            }
    }, 1500);
}
    location.href = url; 

Server side API

Check PID & Version Name with packageName

If the product has already been launched, you can check PID and a range of information with packageName openAPI

For more detail, refer to Tool Reference.

Request Specification

http://m.onestore.co.kr/mobilepoc/api/getAppVersion.omp?pkgNm={package name}&deviceModelCd={model name}&osVer={OS version}

Request Sample

http://m.onestore.co.kr/mobilepoc/api/getAppVersion.omp?pkgNm=com.nhn.android.search&deviceModelCd=SM-N920S&osVer=6.0

Response Sample

{
    "menuId": "DP04202",
    "game": false,
    "result": {
        "desc": "success",
        "code": "000"
    },
    "verNm": "",
    "verCd": "",
    "topMenuId": "DP30",
    "topMenuNm": "app",
    "menuNm": "information/common sense",
    "sellerNm": "NAVER Corp.",
    "prodId": "0000030320",
    "title": "naver - NAVER"
}