rownd-sdk
v1.0.4
Published
This is the SDK for the Rownd Data Privacy Platform. The Rownd Data Platform allows developers to quickly give their users control over their personal data. Visit https://rownd.io for more information. The Rownd Data Platform SDK is easy and fast to us
Downloads
9
Readme
Getting started
This is the SDK for the Rownd Data Privacy Platform
The Rownd Data Platform allows developers to quickly give their users control over their personal data. Visit https://rownd.io for more information.
The Rownd Data Platform SDK is easy and fast to use. Prior to using this SDK, you must register an app on the Rownd platform (https://app.rownd.io), retrieve an App-ID, App Key and Secret, and map personal data-types.
This SDK covered adding users and their personal data and retrieving end users' data. The Rownd REST API can be found at https://docs.rownd.io/api/
Rownd docs can be found at https://docs.rownd.io
Authentication
In order to setup authentication in the API client, you need the following information.
| Parameter | Description | |-----------|-------------| | xRowndAppKey | API Key: Create keys at https://app.rownd.io | | xRowndAppSecret | API Secret: Create keys at https://app.rownd.io |
API client can be initialized as following:
const lib = require('lib');
// Configuration parameters and credentials
lib.Configuration.xRowndAppKey = ""TODO: Replace""; // API Key: Create keys at https://app.rownd.io
lib.Configuration.xRowndAppSecret = ""TODO: Replace""; // API Secret: Create keys at https://app.rownd.io
Class Reference
List of Controllers
AddUserDataController
Get singleton instance
The singleton instance of the AddUserDataController
class can be accessed from the API Client.
var controller = lib.AddUserDataController;
updateApplicationUserDataUpsert
Create a user (by entering a new user ID below) or edit an existing user (by passing the previously sent userID) and add data to Rownd. Note: all data added must be set up in the Rownd Data Privacy and Ownership platform (https://app.rownd.io)
function updateApplicationUserDataUpsert(app, user, body, callback)
Parameters
| Parameter | Tags | Description |
|-----------|------|-------------|
| app | Required
| The ROWND application ID (get it from https://app.rownd.io) |
| user | Required
| This is the ROWND user ID (that app passed to Rownd) |
| body | Optional
| Pass Personal and Private data to the Rownd server. Please note: Data type must be added to the app in the Rownd Platform (https://app.rownd.io). |
Example Usage
var app = '284454822817563138';
var user = 'testtest123342113';
var body = new AppUserData({"data":{"email":"[email protected]","first_name":"xxxxxxxx","last_name":"xxxxxxxx","cell_phone_number":"55555455555"}});
controller.updateApplicationUserDataUpsert(app, user, body, function(error, response, context) {
});
GetUserDataController
Get singleton instance
The singleton instance of the GetUserDataController
class can be accessed from the API Client.
var controller = lib.GetUserDataController;
getApplicationUserDataGet
For getting one user's data.
function getApplicationUserDataGet(app, user, callback)
Parameters
| Parameter | Tags | Description |
|-----------|------|-------------|
| app | Required
| The ROWND application ID (get it from https://app.rownd.io) |
| user | Required
| This is the ROWND user ID (that app passed to Rownd) |
Example Usage
var app = '1300141209124912d';
var user = '20310948103410djad12332302';
controller.getApplicationUserDataGet(app, user, function(error, response, context) {
});
getApplicationUserDataList
This is to get all data in an application.
function getApplicationUserDataList(app, callback)
Parameters
| Parameter | Tags | Description |
|-----------|------|-------------|
| app | Required
| The ROWND application ID (get it from https://app.rownd.io) |
Example Usage
var app = '1300141209124912d';
controller.getApplicationUserDataList(app, function(error, response, context) {
});
DeleteUserDataController
Get singleton instance
The singleton instance of the DeleteUserDataController
class can be accessed from the API Client.
var controller = lib.DeleteUserDataController;
deleteApplicationUserDataDelete
To delete a user's ID and data.
function deleteApplicationUserDataDelete(app, user, callback)
Parameters
| Parameter | Tags | Description |
|-----------|------|-------------|
| app | Required
| The ROWND application ID (get it from https://app.rownd.io) |
| user | Required
| This is the ROWND user ID (that app passed to Rownd) |
Example Usage
var app = 'app';
var user = 'user';
controller.deleteApplicationUserDataDelete(app, user, function(error, response, context) {
});