Custom Actions Beta
Frame.io Actions provide quick access to common media operations like downloading, renaming, and duplicating items – and also allow for integrations with 3rd party tools and services to be surfaced directly within the user interface of Frame.io.
About Actions
With the introduction of custom Actions (beta), developers can configure and manage their own Actions in Frame.io V4. Leveraging the same underlying Event system as Webhooks, custom Actions are an alternative mechanism for developers to connect their assets to the tools that matter most to the users in their Frame.io Account.
Actions can be executed by any user that is a Member of the Frame.io Workspace the Action is enabled in. When executing an Action, Frame.io sends a payload to a URL you provide. The receiving application responds with an HTTP status code to acknowledge receipt, or with a custom callback to render additional form fields in the Frame.io UI. The receiving application can be your own hosted program, service, or even low-code/no-code IPaaS tool like Workfront Fusion or Zapier.
Use the Custom Actions beta to build integrations directly into Frame.io as programmable UI components. This enables workflows that can be triggered by users within the app, leveraging the same underlying events routing as webhooks. You can create user-triggered single or multi-step forms that come back to Frame.io as another form or a basic response. And when a user clicks a Custom Action on an Asset, Frame.io sends a payload to a URL you provide. The receiving application responds with an HTTP status code to acknowledge receipt, or responds with a custom callback that can render additional UI in Frame.io.
Actions Improvements in V4
Leveraging learnings from users of our Legacy version, we’ve included a number of enhancements to the Actions feature set in Frame.io V4:
Previously limited to text and single-select fields, we now support multi-select, text area (for a larger text box) and a boolean field (for a radio button) as well.
Text fields don’t make it easy for users to copy/paste URLs. Use our new link field to get an easy, 1-click to copy experience instead.
Depending on the amount of data returned, you can trust your Action’s modal to dynamically resize to best fit the information in your form, including scrollable modals when needed.
Migrated Actions
There are a few things to keep in mind when migrating to a Frame.io V4 Account containing custom Actions previously created in the legacy version of Frame.io.
Action Status
Upon Account migration to Frame.io V4, all custom Actions created in earlier versions will have a status of ‘null’ and will be automatically disabled. This provides users the opportunity to first update your Actions to use the V4 API before enabling as any Actions not updated will fail. To identify Actions in this state visit the Actions Settings page and reference the column “Status” or, if using the API, by checking the is_active field.
Actionable Resources: Files, Folders & Version Stacks
Given the separation of asset types as separate resources in the Frame.io V4 API, there may be behavior to consider when interpreting the resource ID received in your Action’s payload. The behavior for individual Files is straight-forward, as the ID will reflect the specific File the Action was executed on. Likewise for Folders, you’ll be receiving the ID for the Folder the Action was executed on; however, depending on your use-case you have multiple options when defining your Action’s behavior. Use the Folder ID to make subsequent calls to the Frame.io API if you want interact with the Folder resource itself. Alternatively, you may want to get the children of that Folder in order to perform further processing on the assets within. When an action is Executed on a Version Stack, your payload will contain the ID for the ‘Head Asset’, which is the top most File in the Stack and is what is shown in the Frame.io UI.
You can read more about the differences between the Frame.io Legacy API and V4 in our Migration Guide.
Configure Custom Actions in the Experimental API.
A Custom Action requires:
Configure Your Custom Action
When a user selects a Custom Action on an Asset, Frame.io sends a payload to a URL you provide. The receiving application can respond with an HTTP status code to acknowledge receipt, or respond with a custom callback that renders additional UI in Frame.io.
Content Admin permissions are required to create Custom Actions for a Workspace. Ask your admin to modify your permissions if you don’t have access.
Payload From Frame.io
When the user clicks your Custom Action, a payload is sent to the URL you set in the URL field. Use this payload to identify:
- Which Custom Action was clicked
- Which resource was clicked
- Which user took the action
- Which event type was triggered
- Which account is associated with the Custom Action
- Which Workspace is associated with the Custom Action
- Which Project contains the resource
Interactions, Retries and Timeouts
The interaction_id
is a unique identifier to track of the interaction as it evolves over time. If you do not need to respond to the user, return a 200 status code, and you’re done. While optional, we recommend including information about the result of the action, like a success message or error alert. Custom actions support message callbacks.
Frame.io expects a response in less than 10 seconds, and attempts to retry up to 5 times while waiting for a successful response. Ideally the response is immediate and asynchronous actions occur after a trigger via a Custom Action.
Create a Message Callback
In your HTTP response to the webhook event, you can return a JSON object describing a message that will be returned to the initiating user in the Frame.io UI.
Messages close the action loop providing variable context to the user, without asking them to switch contexts. When the initial payload and subsequent calls to the Frame.io API don’t provide enough context for the receiving application, use Form Callbacks.
Create a Form Callback
Let’s say that you need more info before you start your process. For example, you may be uploading content to a system that requires additional details and settings. You can describe a Form in your response, which the user sees snd fills out, and is then sent right back to you! Here’s an example form that renders a Form in the Frame.io UI that the acting user can fill out and submit:
When the user submits the form, you’ll receive an event on the same URL as the initial POST:
All custom fields added on a form appear in the data section of the JSON payload sent by Frame.io. Use the interaction_id
to map the initial request and this new form data. And again, you can respond with a message (or even another form!). By chaining Actions, Forms, and Messages, you can effectively program entire Asset workflows in Frame.io with business logic from an external system.
Form Details
Like messages, Forms support title
and description
attributes that render at the top of the Form. Beyond that, each form field accepts the following base attributes:
- type — Tells the Frame.io UI which type of data to expect, and which component and render.
- label — Appears on the UI as the header above the field.
- name — Key by which the field will be identified on the subsequent payload.
- value — Value with which to pre-populate the field.
Supported Field Types
Text field
A simple text field with no additional parameters.
Text area
A simple text area with no additional parameters.
Select list
Defines a picklist that the user can choose from. Must include an options
list, each member of which should include a human-readable name
, and a machine-parseable value
.
Checkbox
A simple checkbox with no additional parameters.
Link
A simple link with no additional parameters.
The Frame.io Permissions Model
Custom Actions have a special permissions model: they belong to a Workspace, not to any specific user who exists on an Account. That means:
- Any Content Admin can create a Custom Action on a Workspace.
- Any Content Admin can modify or delete a Custom Action that exists on a Team.
- Once modified, all users will immediately see the result of the change.
Security and Verification
By default, all Custom Actions have a signing key generated during their creation. This is not configurable. This key can be used to verify that the request originates from Frame.io. Included in the POST
request are the following:
The timestamp is the time the request was signed on its way out of Frame.io’s network. This can be used to prevent replay attacks. We recommended verifying this time is within 5 minutes of local time.
The signature is a HMAC SHA-256 hash using the signing key provided when the Custom Action is first created.
Verifying the Signature
The provided signature is prefixed with v0=
. Currently Frame.io only has this one version for signing requests. You will need to add this prefix to your computed signature.
Beta Feedback
We’d love to hear from developers and end-users about the ways you’d like to use Actions in Frame.io V4. Be sure to reach out to us with your questions, ideas, and use-cases to help inform our prioritization.