Actions reference

Understanding Actions in the New Spark Media Platform

Actions are the building blocks of any New Spark Media Platform application. They handle all user interactions like registrations, logins, media uploads, and profile updates.

Working with Forms

Our platform uses special components to create forms and form elements:

  • Why use them? They provide better layout control than standard HTML
  • Includes buttons, inputs, dropdowns, and other common form elements
  • Learn more in our Form Components Guide

Form Tokens (Security Feature)

Every action request requires a security token:

  • Prevents unauthorized requests to your application
  • Automatically generated by the <fm:Form> component
  • Can be disabled in special cases (not recommended)

Setting Up Actions

To use actions in your application:

  • Must be configured when creating your app
  • Each action has predefined parameters (both required and optional)
  • Parameters can be adjusted during application setup

Required Email Templates

These email templates must be set up for certain actions to work:

  • Registration - For new user signups
  • Email Media - For sharing media via email
  • Resend Activation - For account activation emails
  • Lost Password - For password recovery

Redirect Options

Control where users go after completing actions:

  • redirectUrl - Where to go after successful completion
  • failRedirectUrl - Where to go if the action fails
  • failRedirectUrl_{error_code} - Specific pages for specific errors (e.g., failRedirectUrl_404)

Using these features properly will make your application more secure and user-friendly!