User Action APIs

1. Overview

This page contains the APIs that are used for manager user actions. This does not cover actually actioning users. Instead, this is the CRUD API for manage the user action definitions. Here are the APIs:

2. Create a User Action

This API is used to create an User Action. Specifying an Id on the URI will instruct FusionAuth to use that Id when creating the User Action. Otherwise, FusionAuth will generate an Id for the User Action.

2.1. Request

Create a User Action with a randomly generated Id

URI

POST /api/user-action

Create a User Action with the provided unique Id

URI

POST /api/user-action/{userActionId}

Table 1. Request Parameters

userActionId [UUID] Optional defaults to secure random UUID

The Id to use for the new User Action. If not specified a secure random UUID will be generated.

Table 2. Request Body

userAction.cancelEmailTemplateId [UUID] Optional

The Id of the Email Template that is used when User Actions are canceled.

userAction.endEmailTemplateId [UUID] Optional

The Id of the Email Template that is used when User Actions expired automatically (end).

userAction.includeEmailInEventJSON [Boolean] Optional

The Id of the Email Template that is used when User Actions expired automatically (end).

userAction.localizedNames [Map<Locale, String>] Optional

A mapping of localized names for this User Action. The key is the Locale and the value is the name of the User Action for that language.

userAction.modifyEmailTemplateId [UUID] Optional

The Id of the Email Template that is used when User Actions are modified.

userAction.name [String] Required

The name of this User Action.

userAction.options [Array] Optional

The list of User Action Options.

userAction.options[x].localizedNames [Map<Locale, String>] Optional

A mapping of localized names for this User Action Option. The key is the Locale and the value is the name of the User Action Option for that language.

userAction.options[x].name [String] Optional

The name of this User Action Option.

userAction.preventLogin [Boolean] Optional defaults to false

Whether or not this User Action will prevent user login. When this value is set to true the action must also be marked as a time based action. See temporal.

userAction.sendEndEvent [Boolean] Optional defaults to false

Whether or not FusionAuth will send events to any registered Webhooks when this User Action expires.

userAction.startEmailTemplateId [UUID] Optional

The Id of the Email Template that is used when User Actions are started (created).

userAction.temporal [Boolean] Optional defaults to false

Whether or not this User Action is time-based (temporal). Time based actions are temporary and once expired the action will no longer be considered active and will not affect the user.

An action that prevents login must be time based.

Time based actions can still be applied to a user for an indefinite amount of time. A time based action is one that may be canceled or modified. A non time-based action may not be modified or canceled.

An example of a non time-based action would be a reward, such as sending a user a coupon. This action cannot be canceled, or modified. When a non time-based action is taken, it is immediately complete and will show up in the user action history.

userAction.userEmailingEnabled [Boolean] Optional defaults to false

Whether or not email is enabled for this User Action. If this is true, a checkbox will appear in the FusionAuth UI for this User Action that allows admins to specify that they want to email the User.

userAction.userNotificationsEnabled [Boolean] Optional defaults to false

Whether or not user notifications are enabled for this User Action. If this is true, a checkbox will appear in the FusionAuth UI for this User Action that allows admins to specify that they want to "notify users". What is does is send an additional flag named notifyUser in the event JSON that is sent to any registered Webhooks.

Example Request JSON
{
  "userAction": {
    "cancelEmailTemplateId" : "00000000-0000-0000-0000-000000000001",
    "endEmailTemplateId" : "00000000-0000-0000-0000-000000000002",
    "includeEmailInEventJSON" : true,
    "localizedNames": {
      "de": "Dauerhaft Verbieten"
    },
    "modifyEmailTemplateId" : "00000000-0000-0000-0000-000000000003",
    "name": "Permanently Ban",
    "options": [
      {
        "name": "Nicely",
        "localizedNames": {
          "de": "Schön"
        }
      },
      {
        "name": "Meanly",
        "localizedNames": {
          "de": "Bedeuten"
        }
      }
    ],
    "preventLogin": true,
    "sendEndEvent": true,
    "startEmailTemplateId" : "00000000-0000-0000-0000-000000000004",
    "temporal": true,
    "userEmailingEnabled": true,
    "userNotificationsEnabled": true
  }
}

2.2. Response

The response for this API contains the information for the User Action that was created.

Table 3. Response Codes
Code Description

200

The request was successful. The response will contain a JSON body.

400

The request was invalid and/or malformed. The response will contain an Errors JSON Object with the specific errors.

401

You did not supply a valid Authorization header. The header was omitted or your API key was not valid. The response will be empty. See Authentication.

500

There was an internal error. A stack trace is provided and logged in the FusionAuth log files. The response will be empty.

503

The search index is not available or encountered an exception so the request cannot be completed. The response will contain a JSON body.

Table 4. Response Body for a single User Action

userAction.active [Boolean]

Whether or not this User Action is active.

userAction.cancelEmailTemplateId [UUID]

The Id of the Email Template that is used when User Actions are canceled.

userAction.endEmailTemplateId [UUID]

The Id of the Email Template that is used when User Actions expired automatically (end).

userAction.id [UUID]

The Id of the User Action.

userAction.includeEmailInEventJSON [Boolean]

The Id of the Email Template that is used when User Actions expired automatically (end).

userAction.localizedNames [Map<Locale, String>]

A mapping of localized names for this User Action. The key is the Locale and the value is the name of the User Action for that language.

userAction.modifyEmailTemplateId [UUID]

The Id of the Email Template that is used when User Actions are modified.

userAction.modifyEmailTemplateId [String]

The name of this User Action.

userAction.options [Array]

The list of User Action Options.

userAction.options[x].localizedNames [Map<Locale, String>]

A mapping of localized names for this User Action Option. The key is the Locale and the value is the name of the User Action Option for that language.

userAction.options[x].name [String]

The name of this User Action Option.

userAction.preventLogin [Boolean]

Whether or not this User Action will prevent the User from logging in.

userAction.sendEndEvent [Boolean]

Whether or not FusionAuth will send events to any registered Webhooks when this User Action expires.

userAction.startEmailTemplateId [UUID]

The Id of the Email Template that is used when User Actions are started (created).

userAction.temporal [Boolean]

Whether or not this User Action is time-based (temporal). Time based actions are temporary and once expired the action will no longer be considered active and will not affect the user.

userAction.userEmailingEnabled [Boolean]

Whether or not email is enabled for this User Action. If this is true, a checkbox will appear in the FusionAuth UI for this User Action that allows admins to specify that they want to email the User.

userAction.userNotificationsEnabled [Boolean]

Whether or not user notifications are enabled for this User Action. If this is true, a checkbox will appear in the FusionAuth UI for this User Action that allows admins to specify that they want to "notify users". What is does is send an additional flag named notifyUser in the event JSON that is sent to any registered Webhooks.

Example Response JSON for a Single User Action
{
  "userAction": {
    "active": true,
    "cancelEmailTemplateId" : "00000000-0000-0000-0000-000000000001",
    "endEmailTemplateId" : "00000000-0000-0000-0000-000000000002",
    "id": "00000000-0000-0000-0000-000000000042",
    "includeEmailInEventJSON" : true,
    "localizedNames": {
      "de": "Dauerhaft Verbieten"
    },
    "modifyEmailTemplateId" : "00000000-0000-0000-0000-000000000003",
    "name": "Permanently Ban",
    "options": [
      {
        "name": "Nicely",
        "localizedNames": {
          "de": "Schön"
        }
      },
      {
        "name": "Meanly",
        "localizedNames": {
          "de": "Bedeuten"
        }
      }
    ],
    "preventLogin": true,
    "sendEndEvent": true,
    "startEmailTemplateId" : "00000000-0000-0000-0000-000000000004",
    "temporal": true,
    "userEmailingEnabled": true,
    "userNotificationsEnabled": true
  }
}

3. Retrieve a User Action

This API is used to retrieve one or all of the configured User Actions. Specifying an Id on the URI will retrieve a single User Action. Leaving off the Id will retrieve all of the User Actions.

3.1. Request

Retrieve all of the User Actions

URI

GET /api/user-action

Retrieve a User Action by Id

URI

GET /api/user-action/{userActionId}

Table 5. Request Parameters

userActionId [UUID] Optional

The Id of the User Action to retrieve.

3.2. Response

The response for this API contains either a single User Action or all of the User Actions. When you call this API with an Id the response will contain just that User Action. When you call this API without an Id the response will contain all of the User Actions. Both response types are defined below along with an example JSON response.

Table 6. Response Codes
Code Description

200

The request was successful. The response will contain a JSON body.

400

The request was invalid and/or malformed. The response will contain an Errors JSON Object with the specific errors.

401

You did not supply a valid Authorization header. The header was omitted or your API key was not valid. The response will be empty. See Authentication.

404

The object you requested doesn’t exist. The response will be empty.

500

There was an internal error. A stack trace is provided and logged in the FusionAuth log files. The response will be empty.

503

The search index is not available or encountered an exception so the request cannot be completed. The response will contain a JSON body.

Table 7. Response Body for a single User Action

userAction.active [Boolean]

Whether or not this User Action is active.

userAction.cancelEmailTemplateId [UUID]

The Id of the Email Template that is used when User Actions are canceled.

userAction.endEmailTemplateId [UUID]

The Id of the Email Template that is used when User Actions expired automatically (end).

userAction.id [UUID]

The Id of the User Action.

userAction.includeEmailInEventJSON [Boolean]

The Id of the Email Template that is used when User Actions expired automatically (end).

userAction.localizedNames [Map<Locale, String>]

A mapping of localized names for this User Action. The key is the Locale and the value is the name of the User Action for that language.

userAction.modifyEmailTemplateId [UUID]

The Id of the Email Template that is used when User Actions are modified.

userAction.modifyEmailTemplateId [String]

The name of this User Action.

userAction.options [Array]

The list of User Action Options.

userAction.options[x].localizedNames [Map<Locale, String>]

A mapping of localized names for this User Action Option. The key is the Locale and the value is the name of the User Action Option for that language.

userAction.options[x].name [String]

The name of this User Action Option.

userAction.preventLogin [Boolean]

Whether or not this User Action will prevent the User from logging in.

userAction.sendEndEvent [Boolean]

Whether or not FusionAuth will send events to any registered Webhooks when this User Action expires.

userAction.startEmailTemplateId [UUID]

The Id of the Email Template that is used when User Actions are started (created).

userAction.temporal [Boolean]

Whether or not this User Action is time-based (temporal). Time based actions are temporary and once expired the action will no longer be considered active and will not affect the user.

userAction.userEmailingEnabled [Boolean]

Whether or not email is enabled for this User Action. If this is true, a checkbox will appear in the FusionAuth UI for this User Action that allows admins to specify that they want to email the User.

userAction.userNotificationsEnabled [Boolean]

Whether or not user notifications are enabled for this User Action. If this is true, a checkbox will appear in the FusionAuth UI for this User Action that allows admins to specify that they want to "notify users". What is does is send an additional flag named notifyUser in the event JSON that is sent to any registered Webhooks.

Example Response JSON for a Single User Action
{
  "userAction": {
    "active": true,
    "cancelEmailTemplateId" : "00000000-0000-0000-0000-000000000001",
    "endEmailTemplateId" : "00000000-0000-0000-0000-000000000002",
    "id": "00000000-0000-0000-0000-000000000042",
    "includeEmailInEventJSON" : true,
    "localizedNames": {
      "de": "Dauerhaft Verbieten"
    },
    "modifyEmailTemplateId" : "00000000-0000-0000-0000-000000000003",
    "name": "Permanently Ban",
    "options": [
      {
        "name": "Nicely",
        "localizedNames": {
          "de": "Schön"
        }
      },
      {
        "name": "Meanly",
        "localizedNames": {
          "de": "Bedeuten"
        }
      }
    ],
    "preventLogin": true,
    "sendEndEvent": true,
    "startEmailTemplateId" : "00000000-0000-0000-0000-000000000004",
    "temporal": true,
    "userEmailingEnabled": true,
    "userNotificationsEnabled": true
  }
}
Table 8. Response Body for all User Actions

userActions [Array]

The list of User Action objects.

userActions[x].active [Boolean]

Whether or not this User Action is active.

userActions[x].cancelEmailTemplateId [UUID]

The Id of the Email Template that is used when User Actions are canceled.

userActions[x].endEmailTemplateId [UUID]

The Id of the Email Template that is used when User Actions expired automatically (end).

userActions[x].id [UUID]

The Id of the User Action.

userActions[x].includeEmailInEventJSON [Boolean]

The Id of the Email Template that is used when User Actions expired automatically (end).

userActions[x].localizedNames [Map<Locale, String>]

A mapping of localized names for this User Action. The key is the Locale and the value is the name of the User Action for that language.

userActions[x].modifyEmailTemplateId [UUID]

The Id of the Email Template that is used when User Actions are modified.

userActions[x].modifyEmailTemplateId [String]

The name of this User Action.

userActions[x].options [Array]

The list of User Action Options.

userActions[x].options[x].localizedNames [Map<Locale, String>]

A mapping of localized names for this User Action Option. The key is the Locale and the value is the name of the User Action Option for that language.

userActions[x].options[x].name [String]

The name of this User Action Option.

userActions[x].preventLogin [Boolean]

Whether or not this User Action will prevent the User from logging in.

userActions[x].sendEndEvent [Boolean]

Whether or not FusionAuth will send events to any registered Webhooks when this User Action expires.

userActions[x].startEmailTemplateId [UUID]

The Id of the Email Template that is used when User Actions are started (created).

userActions[x].temporal [Boolean]

Whether or not this User Action is time-based (temporal). Time based actions are temporary and once expired the action will no longer be considered active and will not affect the user.

userActions[x].userEmailingEnabled [Boolean]

Whether or not email is enabled for this User Action. If this is true, a checkbox will appear in the FusionAuth UI for this User Action that allows admins to specify that they want to email the User.

userActions[x].userNotificationsEnabled [Boolean]

Whether or not user notifications are enabled for this User Action. If this is true, a checkbox will appear in the FusionAuth UI for this User Action that allows admins to specify that they want to "notify users". What is does is send an additional flag named notifyUser in the event JSON that is sent to any registered Webhooks.

Example Response JSON for all the User Actions
{
  "userActions": [
    {
      "active": true,
      "cancelEmailTemplateId": "00000000-0000-0000-0000-000000000001",
      "endEmailTemplateId": "00000000-0000-0000-0000-000000000002",
      "id": "00000000-0000-0000-0000-000000000042",
      "includeEmailInEventJSON": true,
      "localizedNames": {
        "de": "Dauerhaft Verbieten"
      },
      "modifyEmailTemplateId": "00000000-0000-0000-0000-000000000003",
      "name": "Permanently Ban",
      "options": [
        {
          "name": "Nicely",
          "localizedNames": {
            "de": "Schön"
          }
        },
        {
          "name": "Meanly",
          "localizedNames": {
            "de": "Bedeuten"
          }
        }
      ],
      "preventLogin": true,
      "sendEndEvent": true,
      "startEmailTemplateId": "00000000-0000-0000-0000-000000000004",
      "temporal": true,
      "userEmailingEnabled": true,
      "userNotificationsEnabled": true
    }
  ]
}

4. Update a User Action

This API is used to update an User Action. You must specify the Id of the User Action to update on the URI.

4.1. Request

Update a User Action by Id

URI

PUT /api/user-action/{userActionId}

Table 9. Request Parameters

userActionId [UUID] Required

The Id of the User Action to update.

Table 10. Request Body

userAction.cancelEmailTemplateId [UUID] Optional

The Id of the Email Template that is used when User Actions are canceled.

userAction.endEmailTemplateId [UUID] Optional

The Id of the Email Template that is used when User Actions expired automatically (end).

userAction.includeEmailInEventJSON [Boolean] Optional

The Id of the Email Template that is used when User Actions expired automatically (end).

userAction.localizedNames [Map<Locale, String>] Optional

A mapping of localized names for this User Action. The key is the Locale and the value is the name of the User Action for that language.

userAction.modifyEmailTemplateId [UUID] Optional

The Id of the Email Template that is used when User Actions are modified.

userAction.name [String] Required

The name of this User Action.

userAction.options [Array] Optional

The list of User Action Options.

userAction.options[x].localizedNames [Map<Locale, String>] Optional

A mapping of localized names for this User Action Option. The key is the Locale and the value is the name of the User Action Option for that language.

userAction.options[x].name [String] Optional

The name of this User Action Option.

userAction.preventLogin [Boolean] Optional defaults to false

Whether or not this User Action will prevent user login. When this value is set to true the action must also be marked as a time based action. See temporal.

userAction.sendEndEvent [Boolean] Optional defaults to false

Whether or not FusionAuth will send events to any registered Webhooks when this User Action expires.

userAction.startEmailTemplateId [UUID] Optional

The Id of the Email Template that is used when User Actions are started (created).

userAction.temporal [Boolean] Optional defaults to false

Whether or not this User Action is time-based (temporal). Time based actions are temporary and once expired the action will no longer be considered active and will not affect the user.

An action that prevents login must be time based.

Time based actions can still be applied to a user for an indefinite amount of time. A time based action is one that may be canceled or modified. A non time-based action may not be modified or canceled.

An example of a non time-based action would be a reward, such as sending a user a coupon. This action cannot be canceled, or modified. When a non time-based action is taken, it is immediately complete and will show up in the user action history.

userAction.userEmailingEnabled [Boolean] Optional defaults to false

Whether or not email is enabled for this User Action. If this is true, a checkbox will appear in the FusionAuth UI for this User Action that allows admins to specify that they want to email the User.

userAction.userNotificationsEnabled [Boolean] Optional defaults to false

Whether or not user notifications are enabled for this User Action. If this is true, a checkbox will appear in the FusionAuth UI for this User Action that allows admins to specify that they want to "notify users". What is does is send an additional flag named notifyUser in the event JSON that is sent to any registered Webhooks.

Example Request JSON
{
  "userAction": {
    "cancelEmailTemplateId" : "00000000-0000-0000-0000-000000000001",
    "endEmailTemplateId" : "00000000-0000-0000-0000-000000000002",
    "includeEmailInEventJSON" : true,
    "localizedNames": {
      "de": "Dauerhaft Verbieten"
    },
    "modifyEmailTemplateId" : "00000000-0000-0000-0000-000000000003",
    "name": "Permanently Ban",
    "options": [
      {
        "name": "Nicely",
        "localizedNames": {
          "de": "Schön"
        }
      },
      {
        "name": "Meanly",
        "localizedNames": {
          "de": "Bedeuten"
        }
      }
    ],
    "preventLogin": true,
    "sendEndEvent": true,
    "startEmailTemplateId" : "00000000-0000-0000-0000-000000000004",
    "temporal": true,
    "userEmailingEnabled": true,
    "userNotificationsEnabled": true
  }
}

4.2. Response

The response for this API contains the new information for the User Action that was updated.

Table 11. Response Codes
Code Description

200

The request was successful. The response will contain a JSON body.

400

The request was invalid and/or malformed. The response will contain an Errors JSON Object with the specific errors.

401

You did not supply a valid Authorization header. The header was omitted or your API key was not valid. The response will be empty. See Authentication.

404

The object you are trying to updated doesn’t exist. The response will be empty.

500

There was an internal error. A stack trace is provided and logged in the FusionAuth log files. The response will be empty.

503

The search index is not available or encountered an exception so the request cannot be completed. The response will contain a JSON body.

Table 12. Response Body for a single User Action

userAction.active [Boolean]

Whether or not this User Action is active.

userAction.cancelEmailTemplateId [UUID]

The Id of the Email Template that is used when User Actions are canceled.

userAction.endEmailTemplateId [UUID]

The Id of the Email Template that is used when User Actions expired automatically (end).

userAction.id [UUID]

The Id of the User Action.

userAction.includeEmailInEventJSON [Boolean]

The Id of the Email Template that is used when User Actions expired automatically (end).

userAction.localizedNames [Map<Locale, String>]

A mapping of localized names for this User Action. The key is the Locale and the value is the name of the User Action for that language.

userAction.modifyEmailTemplateId [UUID]

The Id of the Email Template that is used when User Actions are modified.

userAction.modifyEmailTemplateId [String]

The name of this User Action.

userAction.options [Array]

The list of User Action Options.

userAction.options[x].localizedNames [Map<Locale, String>]

A mapping of localized names for this User Action Option. The key is the Locale and the value is the name of the User Action Option for that language.

userAction.options[x].name [String]

The name of this User Action Option.

userAction.preventLogin [Boolean]

Whether or not this User Action will prevent the User from logging in.

userAction.sendEndEvent [Boolean]

Whether or not FusionAuth will send events to any registered Webhooks when this User Action expires.

userAction.startEmailTemplateId [UUID]

The Id of the Email Template that is used when User Actions are started (created).

userAction.temporal [Boolean]

Whether or not this User Action is time-based (temporal). Time based actions are temporary and once expired the action will no longer be considered active and will not affect the user.

userAction.userEmailingEnabled [Boolean]

Whether or not email is enabled for this User Action. If this is true, a checkbox will appear in the FusionAuth UI for this User Action that allows admins to specify that they want to email the User.

userAction.userNotificationsEnabled [Boolean]

Whether or not user notifications are enabled for this User Action. If this is true, a checkbox will appear in the FusionAuth UI for this User Action that allows admins to specify that they want to "notify users". What is does is send an additional flag named notifyUser in the event JSON that is sent to any registered Webhooks.

Example Response JSON for a Single User Action
{
  "userAction": {
    "active": true,
    "cancelEmailTemplateId" : "00000000-0000-0000-0000-000000000001",
    "endEmailTemplateId" : "00000000-0000-0000-0000-000000000002",
    "id": "00000000-0000-0000-0000-000000000042",
    "includeEmailInEventJSON" : true,
    "localizedNames": {
      "de": "Dauerhaft Verbieten"
    },
    "modifyEmailTemplateId" : "00000000-0000-0000-0000-000000000003",
    "name": "Permanently Ban",
    "options": [
      {
        "name": "Nicely",
        "localizedNames": {
          "de": "Schön"
        }
      },
      {
        "name": "Meanly",
        "localizedNames": {
          "de": "Bedeuten"
        }
      }
    ],
    "preventLogin": true,
    "sendEndEvent": true,
    "startEmailTemplateId" : "00000000-0000-0000-0000-000000000004",
    "temporal": true,
    "userEmailingEnabled": true,
    "userNotificationsEnabled": true
  }
}

5. Delete a User Action

This API is used to delete an User Action. You must specify the Id of the User Action on the URI.

5.1. Request

Soft delete a User Action. This operation can be reversed by re-activating the User Action.

URI

DELETE /api/user-action/{userActionId}

Permanently delete a User Action. This operation cannot be reversed.

URI

DELETE /api/user-action/{userActionId}&hardDelete=true

Table 13. Request Parameters

userActionId [UUID] Required

The Id of the User Action to delete.

hardDelete [Boolean] Optional

Whether or not the User Action is soft or hard deleted.

5.2. Response

This API does not return a JSON response body.

Table 14. Response Codes
Code Description

200

The request was successful. The response will be empty.

400

The request was invalid and/or malformed. The response will contain an Errors JSON Object with the specific errors.

401

You did not supply a valid Authorization header. The header was omitted or your API key was not valid. The response will be empty. See Authentication.

404

The object you are trying to delete doesn’t exist. The response will be empty.

500

There was an internal error. A stack trace is provided and logged in the FusionAuth log files. The response will be empty.

503

The search index is not available or encountered an exception so the request cannot be completed. The response will contain a JSON body.

6. Reactivate a User Action

This API is used to reactivate an inactive User Action. You must specify the Id of the Application on the URI.

6.1. Request

Reactivate the User Action

URI

PUT /api/user-action/{userActionId}?reactivate=true

Table 15. Request Parameters

userActionId [UUID] Required

The Id of the User Action to reactivate.

6.2. Response

The response for this API contains the information for the User Action that was reactivated.

Table 16. Response Codes
Code Description

200

The request was successful. The response will contain a JSON body.

400

The request was invalid and/or malformed. The response will contain an Errors JSON Object with the specific errors.

401

You did not supply a valid Authorization header. The header was omitted or your API key was not valid. The response will be empty. See Authentication.

404

The object you requested doesn’t exist. The response will be empty.

500

There was an internal error. A stack trace is provided and logged in the FusionAuth log files. The response will be empty.

503

The search index is not available or encountered an exception so the request cannot be completed. The response will contain a JSON body.

Table 17. Response Body for a single User Action

userAction.active [Boolean]

Whether or not this User Action is active.

userAction.cancelEmailTemplateId [UUID]

The Id of the Email Template that is used when User Actions are canceled.

userAction.endEmailTemplateId [UUID]

The Id of the Email Template that is used when User Actions expired automatically (end).

userAction.id [UUID]

The Id of the User Action.

userAction.includeEmailInEventJSON [Boolean]

The Id of the Email Template that is used when User Actions expired automatically (end).

userAction.localizedNames [Map<Locale, String>]

A mapping of localized names for this User Action. The key is the Locale and the value is the name of the User Action for that language.

userAction.modifyEmailTemplateId [UUID]

The Id of the Email Template that is used when User Actions are modified.

userAction.modifyEmailTemplateId [String]

The name of this User Action.

userAction.options [Array]

The list of User Action Options.

userAction.options[x].localizedNames [Map<Locale, String>]

A mapping of localized names for this User Action Option. The key is the Locale and the value is the name of the User Action Option for that language.

userAction.options[x].name [String]

The name of this User Action Option.

userAction.preventLogin [Boolean]

Whether or not this User Action will prevent the User from logging in.

userAction.sendEndEvent [Boolean]

Whether or not FusionAuth will send events to any registered Webhooks when this User Action expires.

userAction.startEmailTemplateId [UUID]

The Id of the Email Template that is used when User Actions are started (created).

userAction.temporal [Boolean]

Whether or not this User Action is time-based (temporal). Time based actions are temporary and once expired the action will no longer be considered active and will not affect the user.

userAction.userEmailingEnabled [Boolean]

Whether or not email is enabled for this User Action. If this is true, a checkbox will appear in the FusionAuth UI for this User Action that allows admins to specify that they want to email the User.

userAction.userNotificationsEnabled [Boolean]

Whether or not user notifications are enabled for this User Action. If this is true, a checkbox will appear in the FusionAuth UI for this User Action that allows admins to specify that they want to "notify users". What is does is send an additional flag named notifyUser in the event JSON that is sent to any registered Webhooks.

Example Response JSON for a Single User Action
{
  "userAction": {
    "active": true,
    "cancelEmailTemplateId" : "00000000-0000-0000-0000-000000000001",
    "endEmailTemplateId" : "00000000-0000-0000-0000-000000000002",
    "id": "00000000-0000-0000-0000-000000000042",
    "includeEmailInEventJSON" : true,
    "localizedNames": {
      "de": "Dauerhaft Verbieten"
    },
    "modifyEmailTemplateId" : "00000000-0000-0000-0000-000000000003",
    "name": "Permanently Ban",
    "options": [
      {
        "name": "Nicely",
        "localizedNames": {
          "de": "Schön"
        }
      },
      {
        "name": "Meanly",
        "localizedNames": {
          "de": "Bedeuten"
        }
      }
    ],
    "preventLogin": true,
    "sendEndEvent": true,
    "startEmailTemplateId" : "00000000-0000-0000-0000-000000000004",
    "temporal": true,
    "userEmailingEnabled": true,
    "userNotificationsEnabled": true
  }
}