Reference

  • Applications & Modules
  • Appirator modules are collections of classes and objects, event handlers and scripts related to those classes. Modules and applications can import other modules as needed to perform their functions and to reuse logic and resource class segments efficiently. An application is a specialised module that can be started and stopped.

  • Call Context
  • The Call Context is an object containing contextual information relating to the current request or process. It is global to all scripts under the name context.

  • Classes
  • Classes are the cornerstone of Appirator. They define the schema of resource object instances that are created and manipulated through API endpoints or internally as storable and transient objects processed through scripts and passed through events.

  • Event Handlers
  • Event handlers are configurable scripts that are triggered when a corresponding event is triggered. They can run synchronously with the trigger or asynchronously. When the script is run synchronously, it has the capability of completely interrupting the process that triggered it, resulting in a rollback of any updates that have not yet been flushed to the target. If the script is run asynchronously, this interruption doesn't occur because the asynchronous script is guaranteed to run after the completion of the initiating process.

  • Global API Object
  • Description The api script object is a global object available to all scripts. It holds objects and functions required for internal use. The objects included are: events - this object is used to submit or schedule custom events, schedule the call of local methods or functions, set up dynamic event handlers and query event metrics associated with the application. resources - this object is used for saving, updating, deleting, retrieving and searching for objects in their respective stores or proxies.

  • Lookups
  • Lookups are lists of constants that are used to restrict the value of a class property. Class properties that are a type of lookup can only contain a value that is included in the list of allowed values from that lookup.

  • Operations
  • An operation is a verb that refers to the action being performed on a target resource or resource class. Operations are mapped from inbound HTTP request methods and query strings. They're also carried forward on events that are triggered through these requests as well as similar requests that are invoked through scripts.

  • Stores & Proxies
  • Stores can be used to store or proxy data to an external destination or target. They can be linked to single resource classes or they can be shared with a number of resource classes. Resource classes are classes that are storable or are creatable over API endpoints.

  • Validators
  • Validators are used on classes and class properties to test that the value of property conforms to a specification as defined by the validator. Multiple validators can exist on a given class or class property. All validators must be satisfied on a class and all class properties in order for the overall validation on that property to succeed.