File size metadata mapping for a download action

Use this task to configure file size metadata mapping for a Download action in the Connector Development Kit (CDK). CDK uses this mapping to retrieve a file’s size before downloading it, helping ensure proper size validation and enabling large‑file streaming.

Before you begin

Ensure the following:
  • Your connector has an API action that returns file metadata, including file size in bytes. This can be a GET action or a HEAD‑based metadata action.
  • The metadata API exposes the file size as a response property.
  • The Download action is already created.

Procedure

  1. From your connector page in CDK, select the Download action that you created.
  2. Go to the Request tab, then scroll to File size metadata mapping section.
  3. In the File size action field, choose the action that retrieves the file’s metadata. For example, Get file metadata.
  4. Map the request parameters.
    Note: File size metadata mapping does not support arrays, array of objects, or complex nested properties.

    CDK displays the parameters of the Download action and the parameters of the metadata action. For each required parameter (for example, file ID), map the Download request parameter to the corresponding metadata action parameter.

  5. In the File size action response property field, select the property in the metadata action response that contains the file size in bytes.
  6. Click Submit to save the file size metadata mapping.
    CDK validates the mapping and displays the details of the selected metadata action and parameter‑to‑parameter mapping.
    Configured view of file size metadata mapping

What to do next

Test the configured download file action using the Test actions tab. For more information, see Testing a connector.