---
title: ScriptedModule
description: Resource path:
component: pingam
version: 8.1
page_id: pingam:entity-reference:sec-amster-entity-scriptedmodule
canonical_url: https://docs.pingidentity.com/pingam/8.1/entity-reference/sec-amster-entity-scriptedmodule.html
section_ids:
  sec-amster-entity-scriptedmodule-realm-ops: Realm Operations
  sec-amster-entity-scriptedmodule-realm-ops-create: create
  sec-amster-entity-scriptedmodule-realm-ops-delete: delete
  sec-amster-entity-scriptedmodule-realm-ops-getalltypes: getAllTypes
  sec-amster-entity-scriptedmodule-realm-ops-getcreatabletypes: getCreatableTypes
  sec-amster-entity-scriptedmodule-realm-ops-nextdescendents: nextdescendents
  sec-amster-entity-scriptedmodule-realm-ops-query: query
  sec-amster-entity-scriptedmodule-realm-ops-read: read
  sec-amster-entity-scriptedmodule-realm-ops-update: update
  sec-amster-entity-scriptedmodule-global-ops: Global Operations
  sec-amster-entity-scriptedmodule-global-ops-getalltypes: getAllTypes
  sec-amster-entity-scriptedmodule-global-ops-getcreatabletypes: getCreatableTypes
  sec-amster-entity-scriptedmodule-global-ops-nextdescendents: nextdescendents
  sec-amster-entity-scriptedmodule-global-ops-read: read
  sec-amster-entity-scriptedmodule-global-ops-update: update
---

# ScriptedModule

## Realm Operations

Resource path:

```
/realm-config/authentication/modules/scripted
```

Resource version: `0.0`

### create

**Usage**

```
am> create ScriptedModule --realm Realm --id id --body body
```

**Parameters**

* *\--id*

  The unique identifier for the resource.

* *\--body*

  The resource in JSON format, described by the following JSON schema:

  ```json
  {
    "type" : "object",
    "properties" : {
      "authenticationLevel" : {
        "title" : "Authentication Level",
        "description" : "The authentication level associated with the authentication module.<br><br>Each authentication module has an authentication level that can be used to indicate the level of security associated with the module; 0 is the lowest (and the default).",
        "propertyOrder" : 400,
        "required" : true,
        "type" : "integer",
        "exampleValue" : ""
      },
      "clientScriptEnabled" : {
        "title" : "Client-side Script Enabled",
        "description" : "Enable this setting if the client-side script should be executed.",
        "propertyOrder" : 100,
        "required" : true,
        "type" : "boolean",
        "exampleValue" : ""
      },
      "serverScript" : {
        "title" : "Server-side Script",
        "description" : "The server-side script to execute.<br><br>This script will be run on the server, subsequent to any client script having returned.",
        "propertyOrder" : 300,
        "required" : true,
        "type" : "string",
        "exampleValue" : ""
      },
      "clientScript" : {
        "title" : "Client-side Script",
        "description" : "The client-side script.",
        "propertyOrder" : 200,
        "required" : true,
        "type" : "string",
        "exampleValue" : ""
      }
    }
  }
  ```

### delete

**Usage**

```
am> delete ScriptedModule --realm Realm --id id
```

**Parameters**

* *\--id*

  The unique identifier for the resource.

### getAllTypes

Obtain the collection of all secondary configuration types related to the resource.

**Usage**

```
am> action ScriptedModule --realm Realm --actionName getAllTypes
```

### getCreatableTypes

Obtain the collection of secondary configuration types that have yet to be added to the resource.

**Usage**

```
am> action ScriptedModule --realm Realm --actionName getCreatableTypes
```

### nextdescendents

Obtain the collection of secondary configuration instances that have been added to the resource.

**Usage**

```
am> action ScriptedModule --realm Realm --actionName nextdescendents
```

### query

Get the full list of instances of this collection. This query only supports `_queryFilter=true` filter.

**Usage**

```
am> query ScriptedModule --realm Realm --filter filter
```

**Parameters**

* *\--filter*

  A CREST formatted query filter, where "true" will query all.

### read

**Usage**

```
am> read ScriptedModule --realm Realm --id id
```

**Parameters**

* *\--id*

  The unique identifier for the resource.

### update

**Usage**

```
am> update ScriptedModule --realm Realm --id id --body body
```

**Parameters**

* *\--id*

  The unique identifier for the resource.

* *\--body*

  The resource in JSON format, described by the following JSON schema:

  ```json
  {
    "type" : "object",
    "properties" : {
      "authenticationLevel" : {
        "title" : "Authentication Level",
        "description" : "The authentication level associated with the authentication module.<br><br>Each authentication module has an authentication level that can be used to indicate the level of security associated with the module; 0 is the lowest (and the default).",
        "propertyOrder" : 400,
        "required" : true,
        "type" : "integer",
        "exampleValue" : ""
      },
      "clientScriptEnabled" : {
        "title" : "Client-side Script Enabled",
        "description" : "Enable this setting if the client-side script should be executed.",
        "propertyOrder" : 100,
        "required" : true,
        "type" : "boolean",
        "exampleValue" : ""
      },
      "serverScript" : {
        "title" : "Server-side Script",
        "description" : "The server-side script to execute.<br><br>This script will be run on the server, subsequent to any client script having returned.",
        "propertyOrder" : 300,
        "required" : true,
        "type" : "string",
        "exampleValue" : ""
      },
      "clientScript" : {
        "title" : "Client-side Script",
        "description" : "The client-side script.",
        "propertyOrder" : 200,
        "required" : true,
        "type" : "string",
        "exampleValue" : ""
      }
    }
  }
  ```

## Global Operations

Resource path:

```
/global-config/authentication/modules/scripted
```

Resource version: `1.0`

### getAllTypes

Obtain the collection of all secondary configuration types related to the resource.

**Usage**

```
am> action ScriptedModule --global --actionName getAllTypes
```

### getCreatableTypes

Obtain the collection of secondary configuration types that have yet to be added to the resource.

**Usage**

```
am> action ScriptedModule --global --actionName getCreatableTypes
```

### nextdescendents

Obtain the collection of secondary configuration instances that have been added to the resource.

**Usage**

```
am> action ScriptedModule --global --actionName nextdescendents
```

### read

**Usage**

```
am> read ScriptedModule --global
```

### update

**Usage**

```
am> update ScriptedModule --global --body body
```

**Parameters**

* *\--body*

  The resource in JSON format, described by the following JSON schema:

  ```json
  {
    "type" : "object",
    "properties" : {
      "defaults" : {
        "properties" : {
          "clientScriptEnabled" : {
            "title" : "Client-side Script Enabled",
            "description" : "Enable this setting if the client-side script should be executed.",
            "propertyOrder" : 100,
            "required" : true,
            "type" : "boolean",
            "exampleValue" : ""
          },
          "authenticationLevel" : {
            "title" : "Authentication Level",
            "description" : "The authentication level associated with the authentication module.<br><br>Each authentication module has an authentication level that can be used to indicate the level of security associated with the module; 0 is the lowest (and the default).",
            "propertyOrder" : 400,
            "required" : true,
            "type" : "integer",
            "exampleValue" : ""
          },
          "clientScript" : {
            "title" : "Client-side Script",
            "description" : "The client-side script.",
            "propertyOrder" : 200,
            "required" : true,
            "type" : "string",
            "exampleValue" : ""
          },
          "serverScript" : {
            "title" : "Server-side Script",
            "description" : "The server-side script to execute.<br><br>This script will be run on the server, subsequent to any client script having returned.",
            "propertyOrder" : 300,
            "required" : true,
            "type" : "string",
            "exampleValue" : ""
          }
        },
        "type" : "object",
        "title" : "Realm Defaults"
      }
    }
  }
  ```
