DeveloperDeveloper
  • Standard Solutions
  • Cam Solutions
  • Native SDKs
  • App Gallery
  • Game Engine Plugins
Forum
Projects Library
Dev Discord
  • Standard Solutions
  • Cam Solutions
  • Native SDKs
  • App Gallery
  • Game Engine Plugins
Forum
Projects Library
Dev Discord
  • App Gallery (with Lovense Remote)
    • Get Started
    • Development
    • Deploy
  • Basic API
    • Life Cycle
  • Platform API
    • App Info
      • AppBaseInfo
    • Toy
      • Toy Info
      • Command
      • Feedback Mode
    • Device
      • Accelerometer
      • Screen Orientation
      • Shake
      • Vibrate
    • File System
      • Save Image
  • Open API
    • User Authorization
      • Client API
      • Server API
  • Error Code
  • Preparation
  • Step 1: Go to the App Gallery Console
  • Step 2: Create a New App and fill in the Basic Information
  • Step 3: Develop Your App
    • Integrate App Gallery
      • 1. App Type: URL
      • 2. App Type: HTML5
    • Use App Gallery API
  • Step 4: Debug Your App
    • Enable Developer Mode & Select Debugging Method
    • Debugging
Got Stuck?
Forum for Lovense Developers
Support
Document Feedback

Development

Create and Release Your Apps

Preparation

Register Lovense Developer account to access the developer dashboard.

Step 1: Go to the App Gallery Console

Visit the developer console and click on App Gallery solutions, then click the "Go to Console" button.

dashboard

Step 2: Create a New App and fill in the Basic Information

Click the "New App" button on the Apps page to create a new App.

App Gallery Console

Click on "Basic Information" in the sidebar and complete the form.

Basic Information

Example of Basic Information is displayed in App Gallery.

App Gallery

Step 3: Develop Your App

Integrate App Gallery

There are two ways to access App Gallery: URL and HTML5.

1. App Type: URL

For developers who already have a website for quick integration.

Integration Method

Integrate the SDK by introducing the following JS file in the html that needs to call the App Gallery APIs:

<script crossorigin src="https://cdn.lovense.com/appgallery/appgallery-v2.js">

2. App Type: HTML5

For developers who don' t have a website or those want a deep adaptation with App Gallery.

Integration Method

After uploading the source code as a .zip file, it will be hosted and deployed to App Gallery of the Remote App. For more details, refer to Deploy-2.HTML5.

Configuration File

Before debugging the app, you need to create a file, called appgallery_config.json. The appgallery_config.json file should be placed in the root directory of the Web App, which is used for global configuration of the app.

Create Config Json File

The file content is a JSON object with the following properties:

AttributeTypeDefaultRequiredIntroduction
versionStringYesThis version of the App Gallery SDK used by the mini-app, "2" will indicate that the 2.x version is being used.
- This is currently version 2 and is supported by Lovense Remote App version 7.14.0 and above.
- The mini-app functionality requires support from Lovense Remote App. Each new feature added to the App Gallery SDK requires a specific version of the Lovense Remote App. Some new features in a later version of the SDK may not be compatible with earlier versions of Remote app.
appIdStringYesThe appId is the App ID you create on App Gallery Console.
appVersionStringYesThe appVersion is the version number you create on App Gallery Console.
permissionArrayNoThe permissions required by the Web App. Available permissions are:  
 - user_info: User information
 - toy_info: Toy information
allowDomainsArrayNoThe allowed list of server domains is a restrictive measure implemented to ensure application security. In the case of API calls made by the web app, communication is limited to the domain names listed. For instance, only HTTP requests to the authorized domain names are allowed.

Get the appId and appVersion from App Gallery Console.

App Id And App Version

Example (appgallery_config.json):

{
  "version": "2",
  "appId": "is6cbb054xxxxea42xxx17f7xxx1abxxxxx",
  "appVersion": "1.0",
  "permission": ["user_info", "toy_info"],
  "allowDomains": ["*.example.com"]
}

Use App Gallery API

Refer to the APIs document to find out what functionality Lovense Remote app provides.

Step 4: Debug Your App

Enable Developer Mode & Select Debugging Method

Open the Lovense Remote app > Go to the "Me" page > OpenGo to the "Setting" page>Tap "Settings" at the top three times (there will be a switch of Developer Mode) > Enable Developer Mode (there will be a switch of App Debugging) > Tap App Debugging > Select the corresponding App Type according to Step 3 - Integrate App Gallery.

Developer Mode

Tips: You can deploy the web app you're developing locally or to a server. The link should be: https://server:port/index.html

Debugging

After scanning the QR Code or entering the url, Lovense Remote app will directly open your App page.

Debug Vconsole More Settings

  1. When you want to see the logs and additional debugging information output by the console, click on the button vConsole .

  2. Click on the button ... (represented by three dots) in the top-right corner.

  3. Clicking settings will open the settings pop-up box, displaying two options: Auto-Clear Cache and Enable allowDomains. By default, Auto-Clear Cache is enabled and Enable allowDomains is disabled.

  4. If the app needs to access other links or resources via the network, you need to format all the access link domains, and configure into the allowDomains properties in the appgallery_config.json file, and enable the switch for the allowDomains. Then select Reopen or rescan the QR code to check.

Last Updated:
Prev
Get Started
Next
Deploy
Explore our Forum or Support to get more inspiration or solve your problems.
Discord Channel
It is an online real-time channel where you can communicate directly with our official administrators or many excellent developers.
Forum
It is a place for Lovense developers to communicate, where you can find solutions to problems or get inspired for your projects.
Support
Find documents and tutorials that may be helpful to you.