vk.* — VK


Type Library


Overview

The VK plugin provides access to VK.com Social Network.

Supported platforms: iOS 6+, Android 2.3.3+.

The latest version requires Corona 2016.2646 or later.

Syntax

local vk = require('plugin.vk')  

Functions

vk.enableDebug()

vk.init()

vk.login()

vk.logout()

vk.isLoggedIn()

vk.getUserId()

vk.getAccessToken()

vk.request()

vk.showShareDialog()

Events

login

request

showShareDialog

Types

AccessToken

Image

Project Settings

To use this plugin, add an entry into the plugins table of build.settings. When added, the build server will integrate the plugin during the build phase.

	settings = {
		plugins = {
			['plugin.vk'] = {
				publisherId = 'com.spiralcodestudio'
			}
		}
	}

In VK dev console (https://vk.com/dev) for your app you have to: - Set “Install Application” setting to “Required”. - Add all used permissions to “Access Rights”. - Add “App Bundle ID for iOS”. - Add “Package name for Android” - Set “Main activity for Android” to “com.ansca.corona.CoronaActivity” - Add “Signing certificate fingerprint for Android”

Sample Project

A sample project can be found here.

https://github.com/Lerg/plugins-sample-vk