Architecture:MediaWiki/interaction layer

The interaction layer is responsible for responding to requests. It defines how a user or client interacts with the system. The representation, encoding and transfer of entities also belongs into this layer, including the localization of the user interface.

Sub-Layers: The interaction layer has two sub-layers:
 * the UI layer one for interacting directly with humans.
 * the API layer for interacting with client software.

Status: As per April 2020, a lot of logic that belongs into the behavior layer is entangled with interaction layer logic. As code in the interaction layer is refactored to reduce coupling, more code will be factored out and moved to the behavior layer.

Constraints: Code in the interaction layer should not make use of code in layers above it, such as the entry point layer or the wiring layer.

Dependencies: Code in the interaction layer may depend on code in layers below it, such as the behavior layer or the persistence layer.

Typical patterns: The definition interactions often uses the view pattern.

Example: An example of interaction layer code is the  class.