Hi all,
With the release of Premiere 26.3 we’re happy to share a new set of updates for Premiere’s UXP APIs. You can see all this on the Premiere 26.3 Changelog and our updated API doc pages.
Breaking Changes
Sequence.setSelection
The Sequence.setSelection method is now synchronous: calling this will immediately return a boolean value instead of a Promise<boolean>.
If you are using this API with async/await, simply remove the use of await:
const project = await ppro.Project.getActiveProject();
const sequence = await project.getActiveSequence();
const selection = await sequence.getSelection();
- const success = await sequence.setSelection(selection);
+ const success = sequence.setSelection(selection);
If you are using this API with Promise.then method chaining, you’ll need a bit more updating to avoid runtime issues, e.g.:
- sequence.setSelection(selection).then((success) => {
- if (success) { ... }
- });
+ const success = sequence.setSelection(selection);
+ if (success) { ... }
Action creation in locks
Creating Action instances through the various create*Action functions must now be done so while behind a project.lockedAccess(() => { ... }) call. Previously this wasn’t consistently enforced across create*Action calls.
const audioTrack: AudioTrack = ...
project.lockedAccess(() => {
// Create the action here...
const action = audioTrack.createSetNameAction("MyAudioTrack");
project.executeTransasction((compoundAction: CompoundAction) => {
// ...and use it here
compoundAction.addAction(action);
}, "Rename AudioTrack");
});
Creating Actions within a lockedAccess call is important: many Actions contain data that can quickly become stale or inconsistent with other actions that might take place in Premiere (e.g., an editor is making changes that might conflict with a UXP plugin operating at the same time). Using the lockedAccess makes sure these actions are sequenced and properly applied to the Undo history.
The new @adobe/eslint-plugin-premierepro ESLint plugin offers several rules which help catch these cases to help make sure Action creation and usage in your plugin follows best practices. For more information see the documentation pages for:
- The ESLint Support fundamentals page
- The
adobe/eslint-plugin-premiereproGithub repo which includes setup and configuration details as well as docs for individual rules.
New APIs
A number of new APIs have been added in this release. More details on each can be seen in each class’s documentation page. If you’d like to see more examples of using all of these new APIs in action, check out the premiere-api sample panel in the UXP Premiere Pro Samples repository.
AudioTracks,CaptionTracks, andVideoTracks can now be renamed via acreateSetNameActionfunction added to each class.ClipProjectItem.createSubClipActionlets you create sub clips from theClipProjectItem.EncoderManagerhas a few new functions added for helping with exporting and using AME:launchEncoderto launch your local AME instance.setEmbeddedXMPEnabledto toggle embedding XMP metadatasetSidecarXMPEnabledto toggle adding XMP metadata in a sidecar filestartBatchEncodeto start any queued encodes in AME
Markers now have a uniqueguidproperty.- A new
ObjectMaskUtilsclass has been added. Project.createSequenceWithPresetPathhas been added to complimentProject.createSequencewhen using a Sequence Preset.- A new
ProjectConverter.exportAAFexport function has been added for AAF support. You can see what options are available when exporting AAF project files via the separateAAFExportOptionsclass. - You can set the
SourceMonitor’s current position usingsetPosition. Transcripthas added functions for working with transcriptions.querySupportedLanguagesto see what language packs are currently availablehasTranscriptto check if aClipProjectItemhas already been transcribed