After Effects API Reference
The After Effects API is the host-specific layer that After Effects adds on top of UXP. Use it to inspect and update application state, project items, layers, properties, fonts, import options, and settings from a UXP plugin.
Access the API
Load the After Effects host module to access the application API. For example, group related changes into one undo step:
const app = require("aftereffects");
app.beginUndoGroup("Update composition");
// Make changes to the active project.
app.endUndoGroup();
Browse the API
Area
Use it to
Access the running After Effects application, project, preferences, settings, and application commands.
Read and set character-level styling for a range of text in a Text layer.
Access and modify composition settings, layers, and markers.
Inspect a single composed line of text within a Text layer.
Track an asynchronous function call deferred until the script call stack clears.
Inspect the file source associated with a project item.
Organize project items into folders.
Read font properties and metadata.
Find and manage fonts available to After Effects.
Inspect imported footage or solid-color items used as layer sources.
Read and set the properties of a guide in a composition's viewer.
Configure how files and footage are imported into a project.
Create, access, and organize project items.
Read and set the ease applied to a property's keyframe.
Inspect and modify layers in a composition.
Add and configure markers on layers.
Read and set properties within a mask.
Access the output modules in a render-queue item.
Configure how a render-queue item is rendered and saved.
Read and set paragraph-level styling for text in a Text layer.
Inspect the source of a placeholder footage item.
Read, set, and animate layer and effect properties.
Queue and manage compositions for rendering.
Configure a composition queued for rendering.
Access the items in the render queue.
Store and retrieve After Effects application settings.
Read and set the outline used by a mask or shape layer path.
Inspect the source of a solid-color footage item.
Read and set the text and formatting of a Text layer's source text.
Inspect a view shown in a viewer panel.
Access and configure a Composition, Layer, or Footage viewer panel.
Configure the display options of a view.
Minimum Version Tags
Property and method tables include the minimum After Effects version where a member is available. Check the Min Version column before using an API so your plugin can support the intended host versions.
Shared UXP APIs
Use the After Effects API together with the shared UXP platform APIs for file access, storage, networking, HTML, CSS, and Spectrum UI. For those platform capabilities, start with the UXP Hub.