loopback/lib/models/application.js

57 lines
1.2 KiB
JavaScript
Raw Normal View History

2013-07-08 23:59:11 +00:00
/**
* Data model for Application
*/
var ApplicationSchema = {
// Basic information
id: {type: String, required: true},
name: {type: String, required: true},
description: String, // description
2013-07-08 23:59:11 +00:00
icon: String, // The icon image url
public: Boolean, // Do we list the application in the public catalog?
permissions: [String],
2013-07-08 23:59:11 +00:00
owner: String, // The user id of the developer who registers the application
collaborators: [String], // A list of users ids who have permissions to work on this app
// EMail
email: String, // e-mail address
emailVerified: Boolean, // Is the e-mail verified
2013-07-08 23:59:11 +00:00
status: String, // Status of the application, enabled/disabled
// Keys
clientKey: String,
javaScriptKey: String,
restApiKey: String,
windowsKey: String,
masterKey: String,
// Push notification
pushPlatforms: [String],
pushCredentials: [],
2013-07-08 23:59:11 +00:00
// User Authentication
authenticationEnabled: Boolean,
anonymousAllowed: Boolean,
schemes: [String], // Basic, facebook, github, google
attachedCredentials: [],
created: Date,
lastUpdated: Date
};
2013-07-08 23:59:11 +00:00
/**
* Application management functions
*/
// Register a new application