ApplicationSecurity ^v2.7.212
Manages an application's users, access tags and screens.
js
const app = security.application("My Application");
app.users.add("user@example.com");
app.tags.userSetTags("user@example.com", ["North Region", "Planner Screens"]);Constructor
security.application security.application(application) ApplicationSecurity | null
Returns an application, or null when there's no such application.
| Parameter | Type | Description |
|---|---|---|
application | string | The application's name or id. |
js
const app = security.application("My Application");Properties
| Property | Type | Description |
|---|---|---|
users | ApplicationUsers | The users assigned to the application. |
tags | ApplicationTags | The application's access tags, and which users hold them. |
screens | ApplicationScreens | The application's screens. |
Methods
id id() string
Returns the application's id.
name name() string
Returns the application's name.
modelId modelId() string
Returns the id of the model the application belongs to.
modelName modelName() string
Returns the name of the model the application belongs to.
Examples
js
const app = security.application("My Application");
console.log(app.id());
console.log(app.name() + " belongs to " + app.modelName());
const financeTag = app.tags.get("Finance");
const homeScreen = app.screens.get("Home");
const currentUser = app.users.get("user@example.com");Related
- security.applications: returns every application in a model.