AWS MediaTailor

2026/08/06 - AWS MediaTailor - 3 updated api methods

Changes  AWS Elemental MediaTailor now supports concurrent function execution. The new Concurrent Executor function type runs multiple independent child functions in parallel within a single lifecycle hook, reducing pipeline latency to the duration of the slowest call instead of the sum of all calls.

GetFunction (updated) Link ¶
Changes (response)
{'ConcurrentExecutorConfiguration': {'FunctionList': [{'Alias': 'string',
                                                       'FunctionId': 'string',
                                                       'RunCondition': 'string'}],
                                     'MaxConcurrency': 'integer',
                                     'Output': {'string': 'string'},
                                     'Runtime': 'JSONATA',
                                     'TimeoutMilliseconds': 'integer'},
 'FunctionType': {'CONCURRENT_EXECUTOR'},
 'SequentialExecutorConfiguration': {'FunctionList': {'Alias': 'string'}}}

Retrieves the configuration and metadata for a function. For more information about functions, see Working with functions in the MediaTailor User Guide.

See also: AWS API Documentation

Request Syntax

client.get_function(
    FunctionId='string'
)
type FunctionId:

string

param FunctionId:

[REQUIRED]

The identifier of the function.

rtype:

dict

returns:

Response Syntax

{
    'FunctionId': 'string',
    'FunctionType': 'HTTP_REQUEST'|'CUSTOM_OUTPUT'|'CONCURRENT_EXECUTOR'|'SEQUENTIAL_EXECUTOR',
    'Description': 'string',
    'HttpRequestConfiguration': {
        'Runtime': 'JSONATA',
        'Output': {
            'string': 'string'
        },
        'MethodType': 'GET'|'POST',
        'RequestTimeoutMilliseconds': 123,
        'Url': 'string',
        'Body': 'string',
        'Headers': {
            'string': 'string'
        }
    },
    'CustomOutputConfiguration': {
        'Runtime': 'JSONATA',
        'Output': {
            'string': 'string'
        }
    },
    'ConcurrentExecutorConfiguration': {
        'Runtime': 'JSONATA',
        'Output': {
            'string': 'string'
        },
        'FunctionList': [
            {
                'RunCondition': 'string',
                'FunctionId': 'string',
                'Alias': 'string'
            },
        ],
        'TimeoutMilliseconds': 123,
        'MaxConcurrency': 123
    },
    'SequentialExecutorConfiguration': {
        'Runtime': 'JSONATA',
        'Output': {
            'string': 'string'
        },
        'FunctionList': [
            {
                'RunCondition': 'string',
                'FunctionId': 'string',
                'Alias': 'string'
            },
        ],
        'TimeoutMilliseconds': 123
    },
    'Tags': {
        'string': 'string'
    },
    'Arn': 'string'
}

Response Structure

  • (dict) --

    -- Define Mixin --

    • FunctionId (string) --

      The identifier of the function.

    • FunctionType (string) --

      The type of the function.

    • Description (string) --

      A description of the function.

    • HttpRequestConfiguration (dict) --

      The configuration for an HTTP_REQUEST function.

      • Runtime (string) --

        The expression language used to evaluate expressions in the function configuration. Set this to JSONata.

      • Output (dict) --

        A map of output bindings. Each key is a namespaced output path (such as player_params.device_type or temp.identity), and each value is an expression that MediaTailor evaluates at runtime. Output expressions in an HTTP_REQUEST function can reference the response object returned by the HTTP call. For more information about expression syntax, see JSONata expression reference in the MediaTailor User Guide.

        • (string) --

          • (string) --

      • MethodType (string) --

        The HTTP method for the request. Valid values: GET and POST.

      • RequestTimeoutMilliseconds (integer) --

        The maximum time, in milliseconds, that MediaTailor waits for a response from the external service. If the call exceeds this timeout, MediaTailor sets the response status code to null and proceeds with output expression evaluation. Valid values: 100 to 2000.

      • Url (string) --

        An expression that evaluates to the request URL. Use {%...%} delimiters for dynamic expressions. The maximum length after evaluation is 2,048 characters.

      • Body (string) --

        An expression that evaluates to the request body. Used with POST requests. The maximum size after evaluation is 64 KB.

      • Headers (dict) --

        A map of HTTP header names to expression values. MediaTailor evaluates each header value expression at runtime and includes the result in the outbound HTTP request. Maximum 50 headers.

        • (string) --

          • (string) --

    • CustomOutputConfiguration (dict) --

      The configuration for a CUSTOM_OUTPUT function.

      • Runtime (string) --

        The expression language used to evaluate expressions in the function configuration. Set this to JSONata.

      • Output (dict) --

        A map of output bindings. Each key is a namespaced output path (such as player_params.device_type or temp.variant), and each value is an expression that MediaTailor evaluates at runtime against the current session state. For more information about expression syntax, see JSONata expression reference in the MediaTailor User Guide.

        • (string) --

          • (string) --

    • ConcurrentExecutorConfiguration (dict) --

      The configuration for a CONCURRENT_EXECUTOR function.

      • Runtime (string) --

        The expression language used to evaluate expressions in the function configuration. Set this to JSONata.

      • Output (dict) --

        A map of output bindings that controls which bindings the executor commits to the session state after all child functions complete. Each key is a namespaced output path, and each value is an expression that MediaTailor evaluates against the combined results of the child functions.

        • (string) --

          • (string) --

      • FunctionList (list) --

        The list of child functions that MediaTailor runs in parallel. Each entry specifies a child function to execute and an optional run condition expression that controls whether the function runs.

        • (dict) --

          A reference to a child function within a SEQUENTIAL_EXECUTOR function.

          • RunCondition (string) --

            An optional expression that evaluates to a boolean. MediaTailor evaluates this expression immediately before running the step, using the accumulated state at that point in the sequence. If the expression evaluates to false, MediaTailor skips the step and moves to the next one. If omitted, the step always runs.

          • FunctionId (string) --

            The identifier of the child function to execute in this step.

          • Alias (string) --

            An optional alternate name for the function within the executor. If omitted, MediaTailor uses the function identifier.

      • TimeoutMilliseconds (integer) --

        The maximum time, in milliseconds, for all child functions to complete. This timeout covers every function in the list, including any HTTP calls the child functions make. If the executor exceeds this timeout, MediaTailor discards all output from the executor and proceeds with default behavior.

      • MaxConcurrency (integer) --

        The maximum number of child functions that MediaTailor runs simultaneously. When the list contains more functions than MaxConcurrency, MediaTailor starts additional functions as running ones complete, so that no more than MaxConcurrency functions run at the same time.

    • SequentialExecutorConfiguration (dict) --

      The configuration for a SEQUENTIAL_EXECUTOR function.

      • Runtime (string) --

        The expression language used to evaluate expressions in the function configuration. Set this to JSONata.

      • Output (dict) --

        An optional map of output bindings that controls which bindings the sequence commits to the session state after all steps complete. If omitted, MediaTailor commits all accumulated output bindings from all child steps.

        • (string) --

          • (string) --

      • FunctionList (list) --

        An ordered list of 1 to 10 steps. Each step specifies a child function to execute and an optional run condition expression that controls whether the step runs. MediaTailor executes steps in order, passing data between steps through temporary data.

        • (dict) --

          A reference to a child function within a SEQUENTIAL_EXECUTOR function.

          • RunCondition (string) --

            An optional expression that evaluates to a boolean. MediaTailor evaluates this expression immediately before running the step, using the accumulated state at that point in the sequence. If the expression evaluates to false, MediaTailor skips the step and moves to the next one. If omitted, the step always runs.

          • FunctionId (string) --

            The identifier of the child function to execute in this step.

          • Alias (string) --

            An optional alternate name for the function within the executor. If omitted, MediaTailor uses the function identifier.

      • TimeoutMilliseconds (integer) --

        The maximum time, in milliseconds, for the entire sequence to complete. This timeout covers all steps, including any HTTP calls made by child functions. If the sequence exceeds this timeout, MediaTailor discards all output from the sequence and proceeds with default behavior.

    • Tags (dict) --

      The tags assigned to the function. Tags are key-value pairs that you can associate with Amazon resources to help with organization, access control, and cost tracking. For more information, see Tagging AWS Elemental MediaTailor Resources.

      • (string) --

        • (string) --

    • Arn (string) --

      The Amazon Resource Name (ARN) of the function.

ListFunctions (updated) Link ¶
Changes (response)
{'Items': {'ConcurrentExecutorConfiguration': {'FunctionList': [{'Alias': 'string',
                                                                 'FunctionId': 'string',
                                                                 'RunCondition': 'string'}],
                                               'MaxConcurrency': 'integer',
                                               'Output': {'string': 'string'},
                                               'Runtime': 'JSONATA',
                                               'TimeoutMilliseconds': 'integer'},
           'FunctionType': {'CONCURRENT_EXECUTOR'},
           'SequentialExecutorConfiguration': {'FunctionList': {'Alias': 'string'}}}}

Retrieves all functions associated with your AWS account in the current Region. For more information about functions, see Working with functions in the MediaTailor User Guide.

See also: AWS API Documentation

Request Syntax

client.list_functions(
    MaxResults=123,
    NextToken='string'
)
type MaxResults:

integer

param MaxResults:

The maximum number of functions that you want MediaTailor to return in response to the current request. If there are more than MaxResults functions, use the value of NextToken in the response to get the next page of results.

The default value is 100. MediaTailor uses token-based pagination, which means that a response might contain fewer than MaxResults items, including 0 items, even when more results are available. To retrieve all results, you must continue making requests using the NextToken value from each response until the response no longer includes a NextToken value.

type NextToken:

string

param NextToken:

Pagination token returned by the list request when results exceed the maximum allowed. Use the token to fetch the next page of results.

For the first ListFunctions request, omit this value. For subsequent requests, get the value of NextToken from the previous response and specify that value for NextToken in the request. Continue making requests until the response no longer includes a NextToken value, which indicates that all results have been retrieved.

rtype:

dict

returns:

Response Syntax

{
    'Items': [
        {
            'FunctionId': 'string',
            'FunctionType': 'HTTP_REQUEST'|'CUSTOM_OUTPUT'|'CONCURRENT_EXECUTOR'|'SEQUENTIAL_EXECUTOR',
            'Description': 'string',
            'HttpRequestConfiguration': {
                'Runtime': 'JSONATA',
                'Output': {
                    'string': 'string'
                },
                'MethodType': 'GET'|'POST',
                'RequestTimeoutMilliseconds': 123,
                'Url': 'string',
                'Body': 'string',
                'Headers': {
                    'string': 'string'
                }
            },
            'CustomOutputConfiguration': {
                'Runtime': 'JSONATA',
                'Output': {
                    'string': 'string'
                }
            },
            'ConcurrentExecutorConfiguration': {
                'Runtime': 'JSONATA',
                'Output': {
                    'string': 'string'
                },
                'FunctionList': [
                    {
                        'RunCondition': 'string',
                        'FunctionId': 'string',
                        'Alias': 'string'
                    },
                ],
                'TimeoutMilliseconds': 123,
                'MaxConcurrency': 123
            },
            'SequentialExecutorConfiguration': {
                'Runtime': 'JSONATA',
                'Output': {
                    'string': 'string'
                },
                'FunctionList': [
                    {
                        'RunCondition': 'string',
                        'FunctionId': 'string',
                        'Alias': 'string'
                    },
                ],
                'TimeoutMilliseconds': 123
            },
            'Tags': {
                'string': 'string'
            },
            'Arn': 'string'
        },
    ],
    'NextToken': 'string'
}

Response Structure

  • (dict) --

    • Items (list) --

      A list of functions associated with your account in the current Region.

      • (dict) --

        Defines reusable logic that MediaTailor executes at lifecycle hooks during ad insertion. The FunctionType determines the function's runtime behavior. For more information about functions, see Working with functions in the MediaTailor User Guide.

        • FunctionId (string) --

          The identifier of the function.

        • FunctionType (string) --

          The type of the function.

        • Description (string) --

          A description of the function.

        • HttpRequestConfiguration (dict) --

          The configuration for an HTTP_REQUEST function.

          • Runtime (string) --

            The expression language used to evaluate expressions in the function configuration. Set this to JSONata.

          • Output (dict) --

            A map of output bindings. Each key is a namespaced output path (such as player_params.device_type or temp.identity), and each value is an expression that MediaTailor evaluates at runtime. Output expressions in an HTTP_REQUEST function can reference the response object returned by the HTTP call. For more information about expression syntax, see JSONata expression reference in the MediaTailor User Guide.

            • (string) --

              • (string) --

          • MethodType (string) --

            The HTTP method for the request. Valid values: GET and POST.

          • RequestTimeoutMilliseconds (integer) --

            The maximum time, in milliseconds, that MediaTailor waits for a response from the external service. If the call exceeds this timeout, MediaTailor sets the response status code to null and proceeds with output expression evaluation. Valid values: 100 to 2000.

          • Url (string) --

            An expression that evaluates to the request URL. Use {%...%} delimiters for dynamic expressions. The maximum length after evaluation is 2,048 characters.

          • Body (string) --

            An expression that evaluates to the request body. Used with POST requests. The maximum size after evaluation is 64 KB.

          • Headers (dict) --

            A map of HTTP header names to expression values. MediaTailor evaluates each header value expression at runtime and includes the result in the outbound HTTP request. Maximum 50 headers.

            • (string) --

              • (string) --

        • CustomOutputConfiguration (dict) --

          The configuration for a CUSTOM_OUTPUT function.

          • Runtime (string) --

            The expression language used to evaluate expressions in the function configuration. Set this to JSONata.

          • Output (dict) --

            A map of output bindings. Each key is a namespaced output path (such as player_params.device_type or temp.variant), and each value is an expression that MediaTailor evaluates at runtime against the current session state. For more information about expression syntax, see JSONata expression reference in the MediaTailor User Guide.

            • (string) --

              • (string) --

        • ConcurrentExecutorConfiguration (dict) --

          The configuration for a CONCURRENT_EXECUTOR function.

          • Runtime (string) --

            The expression language used to evaluate expressions in the function configuration. Set this to JSONata.

          • Output (dict) --

            A map of output bindings that controls which bindings the executor commits to the session state after all child functions complete. Each key is a namespaced output path, and each value is an expression that MediaTailor evaluates against the combined results of the child functions.

            • (string) --

              • (string) --

          • FunctionList (list) --

            The list of child functions that MediaTailor runs in parallel. Each entry specifies a child function to execute and an optional run condition expression that controls whether the function runs.

            • (dict) --

              A reference to a child function within a SEQUENTIAL_EXECUTOR function.

              • RunCondition (string) --

                An optional expression that evaluates to a boolean. MediaTailor evaluates this expression immediately before running the step, using the accumulated state at that point in the sequence. If the expression evaluates to false, MediaTailor skips the step and moves to the next one. If omitted, the step always runs.

              • FunctionId (string) --

                The identifier of the child function to execute in this step.

              • Alias (string) --

                An optional alternate name for the function within the executor. If omitted, MediaTailor uses the function identifier.

          • TimeoutMilliseconds (integer) --

            The maximum time, in milliseconds, for all child functions to complete. This timeout covers every function in the list, including any HTTP calls the child functions make. If the executor exceeds this timeout, MediaTailor discards all output from the executor and proceeds with default behavior.

          • MaxConcurrency (integer) --

            The maximum number of child functions that MediaTailor runs simultaneously. When the list contains more functions than MaxConcurrency, MediaTailor starts additional functions as running ones complete, so that no more than MaxConcurrency functions run at the same time.

        • SequentialExecutorConfiguration (dict) --

          The configuration for a SEQUENTIAL_EXECUTOR function.

          • Runtime (string) --

            The expression language used to evaluate expressions in the function configuration. Set this to JSONata.

          • Output (dict) --

            An optional map of output bindings that controls which bindings the sequence commits to the session state after all steps complete. If omitted, MediaTailor commits all accumulated output bindings from all child steps.

            • (string) --

              • (string) --

          • FunctionList (list) --

            An ordered list of 1 to 10 steps. Each step specifies a child function to execute and an optional run condition expression that controls whether the step runs. MediaTailor executes steps in order, passing data between steps through temporary data.

            • (dict) --

              A reference to a child function within a SEQUENTIAL_EXECUTOR function.

              • RunCondition (string) --

                An optional expression that evaluates to a boolean. MediaTailor evaluates this expression immediately before running the step, using the accumulated state at that point in the sequence. If the expression evaluates to false, MediaTailor skips the step and moves to the next one. If omitted, the step always runs.

              • FunctionId (string) --

                The identifier of the child function to execute in this step.

              • Alias (string) --

                An optional alternate name for the function within the executor. If omitted, MediaTailor uses the function identifier.

          • TimeoutMilliseconds (integer) --

            The maximum time, in milliseconds, for the entire sequence to complete. This timeout covers all steps, including any HTTP calls made by child functions. If the sequence exceeds this timeout, MediaTailor discards all output from the sequence and proceeds with default behavior.

        • Tags (dict) --

          The tags assigned to the function. Tags are key-value pairs that you can associate with Amazon resources to help with organization, access control, and cost tracking. For more information, see Tagging AWS Elemental MediaTailor Resources.

          • (string) --

            • (string) --

        • Arn (string) --

          The Amazon Resource Name (ARN) of the function.

    • NextToken (string) --

      Pagination token returned by the list request when results exceed the maximum allowed. Use the token to fetch the next page of results.

      For the first ListFunctions request, omit this value. For subsequent requests, get the value of NextToken from the previous response and specify that value for NextToken in the request. Continue making requests until the response no longer includes a NextToken value, which indicates that all results have been retrieved.

PutFunction (updated) Link ¶
Changes (both)
{'ConcurrentExecutorConfiguration': {'FunctionList': [{'Alias': 'string',
                                                       'FunctionId': 'string',
                                                       'RunCondition': 'string'}],
                                     'MaxConcurrency': 'integer',
                                     'Output': {'string': 'string'},
                                     'Runtime': 'JSONATA',
                                     'TimeoutMilliseconds': 'integer'},
 'FunctionType': {'CONCURRENT_EXECUTOR'},
 'SequentialExecutorConfiguration': {'FunctionList': {'Alias': 'string'}}}

Creates or updates a function. A function defines reusable logic that MediaTailor executes at lifecycle hooks during ad insertion. For more information about functions, see Working with functions in the MediaTailor User Guide.

See also: AWS API Documentation

Request Syntax

client.put_function(
    FunctionId='string',
    FunctionType='HTTP_REQUEST'|'CUSTOM_OUTPUT'|'CONCURRENT_EXECUTOR'|'SEQUENTIAL_EXECUTOR',
    Description='string',
    HttpRequestConfiguration={
        'Runtime': 'JSONATA',
        'Output': {
            'string': 'string'
        },
        'MethodType': 'GET'|'POST',
        'RequestTimeoutMilliseconds': 123,
        'Url': 'string',
        'Body': 'string',
        'Headers': {
            'string': 'string'
        }
    },
    CustomOutputConfiguration={
        'Runtime': 'JSONATA',
        'Output': {
            'string': 'string'
        }
    },
    ConcurrentExecutorConfiguration={
        'Runtime': 'JSONATA',
        'Output': {
            'string': 'string'
        },
        'FunctionList': [
            {
                'RunCondition': 'string',
                'FunctionId': 'string',
                'Alias': 'string'
            },
        ],
        'TimeoutMilliseconds': 123,
        'MaxConcurrency': 123
    },
    SequentialExecutorConfiguration={
        'Runtime': 'JSONATA',
        'Output': {
            'string': 'string'
        },
        'FunctionList': [
            {
                'RunCondition': 'string',
                'FunctionId': 'string',
                'Alias': 'string'
            },
        ],
        'TimeoutMilliseconds': 123
    },
    Tags={
        'string': 'string'
    }
)
type FunctionId:

string

param FunctionId:

[REQUIRED]

The identifier of the function. The identifier must be unique within your account.

type FunctionType:

string

param FunctionType:

[REQUIRED]

The type of the function. The function type determines what the function can do at runtime. Valid values: CUSTOM_OUTPUT evaluates expressions and produces output bindings with no external calls. HTTP_REQUEST makes an HTTP call to an external service and evaluates output expressions that can reference the response. SEQUENTIAL_EXECUTOR runs a sequence of child functions in order, passing data between steps through temporary data. For more information, see Function types and composition in the MediaTailor User Guide.

type Description:

string

param Description:

A description of the function.

type HttpRequestConfiguration:

dict

param HttpRequestConfiguration:

The configuration for an HTTP_REQUEST function. Specifies the HTTP method, URL, headers, body, timeout, and output expressions. Required when FunctionType is HTTP_REQUEST.

  • Runtime (string) -- [REQUIRED]

    The expression language used to evaluate expressions in the function configuration. Set this to JSONata.

  • Output (dict) --

    A map of output bindings. Each key is a namespaced output path (such as player_params.device_type or temp.identity), and each value is an expression that MediaTailor evaluates at runtime. Output expressions in an HTTP_REQUEST function can reference the response object returned by the HTTP call. For more information about expression syntax, see JSONata expression reference in the MediaTailor User Guide.

    • (string) --

      • (string) --

  • MethodType (string) -- [REQUIRED]

    The HTTP method for the request. Valid values: GET and POST.

  • RequestTimeoutMilliseconds (integer) -- [REQUIRED]

    The maximum time, in milliseconds, that MediaTailor waits for a response from the external service. If the call exceeds this timeout, MediaTailor sets the response status code to null and proceeds with output expression evaluation. Valid values: 100 to 2000.

  • Url (string) -- [REQUIRED]

    An expression that evaluates to the request URL. Use {%...%} delimiters for dynamic expressions. The maximum length after evaluation is 2,048 characters.

  • Body (string) --

    An expression that evaluates to the request body. Used with POST requests. The maximum size after evaluation is 64 KB.

  • Headers (dict) --

    A map of HTTP header names to expression values. MediaTailor evaluates each header value expression at runtime and includes the result in the outbound HTTP request. Maximum 50 headers.

    • (string) --

      • (string) --

type CustomOutputConfiguration:

dict

param CustomOutputConfiguration:

The configuration for a CUSTOM_OUTPUT function. Specifies the runtime and output expressions. Required when FunctionType is CUSTOM_OUTPUT.

  • Runtime (string) -- [REQUIRED]

    The expression language used to evaluate expressions in the function configuration. Set this to JSONata.

  • Output (dict) --

    A map of output bindings. Each key is a namespaced output path (such as player_params.device_type or temp.variant), and each value is an expression that MediaTailor evaluates at runtime against the current session state. For more information about expression syntax, see JSONata expression reference in the MediaTailor User Guide.

    • (string) --

      • (string) --

type ConcurrentExecutorConfiguration:

dict

param ConcurrentExecutorConfiguration:

The configuration for a CONCURRENT_EXECUTOR function. Specifies the list of child functions to run in parallel, the maximum concurrency, an optional output block, and a timeout. Required when FunctionType is CONCURRENT_EXECUTOR.

  • Runtime (string) -- [REQUIRED]

    The expression language used to evaluate expressions in the function configuration. Set this to JSONata.

  • Output (dict) -- [REQUIRED]

    A map of output bindings that controls which bindings the executor commits to the session state after all child functions complete. Each key is a namespaced output path, and each value is an expression that MediaTailor evaluates against the combined results of the child functions.

    • (string) --

      • (string) --

  • FunctionList (list) -- [REQUIRED]

    The list of child functions that MediaTailor runs in parallel. Each entry specifies a child function to execute and an optional run condition expression that controls whether the function runs.

    • (dict) --

      A reference to a child function within a SEQUENTIAL_EXECUTOR function.

      • RunCondition (string) --

        An optional expression that evaluates to a boolean. MediaTailor evaluates this expression immediately before running the step, using the accumulated state at that point in the sequence. If the expression evaluates to false, MediaTailor skips the step and moves to the next one. If omitted, the step always runs.

      • FunctionId (string) --

        The identifier of the child function to execute in this step.

      • Alias (string) --

        An optional alternate name for the function within the executor. If omitted, MediaTailor uses the function identifier.

  • TimeoutMilliseconds (integer) -- [REQUIRED]

    The maximum time, in milliseconds, for all child functions to complete. This timeout covers every function in the list, including any HTTP calls the child functions make. If the executor exceeds this timeout, MediaTailor discards all output from the executor and proceeds with default behavior.

  • MaxConcurrency (integer) -- [REQUIRED]

    The maximum number of child functions that MediaTailor runs simultaneously. When the list contains more functions than MaxConcurrency, MediaTailor starts additional functions as running ones complete, so that no more than MaxConcurrency functions run at the same time.

type SequentialExecutorConfiguration:

dict

param SequentialExecutorConfiguration:

The configuration for a SEQUENTIAL_EXECUTOR function. Specifies the ordered list of child functions to execute, an optional output block, and a timeout. Required when FunctionType is SEQUENTIAL_EXECUTOR.

  • Runtime (string) -- [REQUIRED]

    The expression language used to evaluate expressions in the function configuration. Set this to JSONata.

  • Output (dict) --

    An optional map of output bindings that controls which bindings the sequence commits to the session state after all steps complete. If omitted, MediaTailor commits all accumulated output bindings from all child steps.

    • (string) --

      • (string) --

  • FunctionList (list) -- [REQUIRED]

    An ordered list of 1 to 10 steps. Each step specifies a child function to execute and an optional run condition expression that controls whether the step runs. MediaTailor executes steps in order, passing data between steps through temporary data.

    • (dict) --

      A reference to a child function within a SEQUENTIAL_EXECUTOR function.

      • RunCondition (string) --

        An optional expression that evaluates to a boolean. MediaTailor evaluates this expression immediately before running the step, using the accumulated state at that point in the sequence. If the expression evaluates to false, MediaTailor skips the step and moves to the next one. If omitted, the step always runs.

      • FunctionId (string) --

        The identifier of the child function to execute in this step.

      • Alias (string) --

        An optional alternate name for the function within the executor. If omitted, MediaTailor uses the function identifier.

  • TimeoutMilliseconds (integer) -- [REQUIRED]

    The maximum time, in milliseconds, for the entire sequence to complete. This timeout covers all steps, including any HTTP calls made by child functions. If the sequence exceeds this timeout, MediaTailor discards all output from the sequence and proceeds with default behavior.

type Tags:

dict

param Tags:

The tags to assign to the function. Tags are key-value pairs that you can associate with Amazon resources to help with organization, access control, and cost tracking. For more information, see Tagging AWS Elemental MediaTailor Resources.

  • (string) --

    • (string) --

rtype:

dict

returns:

Response Syntax

{
    'FunctionId': 'string',
    'FunctionType': 'HTTP_REQUEST'|'CUSTOM_OUTPUT'|'CONCURRENT_EXECUTOR'|'SEQUENTIAL_EXECUTOR',
    'Description': 'string',
    'HttpRequestConfiguration': {
        'Runtime': 'JSONATA',
        'Output': {
            'string': 'string'
        },
        'MethodType': 'GET'|'POST',
        'RequestTimeoutMilliseconds': 123,
        'Url': 'string',
        'Body': 'string',
        'Headers': {
            'string': 'string'
        }
    },
    'CustomOutputConfiguration': {
        'Runtime': 'JSONATA',
        'Output': {
            'string': 'string'
        }
    },
    'ConcurrentExecutorConfiguration': {
        'Runtime': 'JSONATA',
        'Output': {
            'string': 'string'
        },
        'FunctionList': [
            {
                'RunCondition': 'string',
                'FunctionId': 'string',
                'Alias': 'string'
            },
        ],
        'TimeoutMilliseconds': 123,
        'MaxConcurrency': 123
    },
    'SequentialExecutorConfiguration': {
        'Runtime': 'JSONATA',
        'Output': {
            'string': 'string'
        },
        'FunctionList': [
            {
                'RunCondition': 'string',
                'FunctionId': 'string',
                'Alias': 'string'
            },
        ],
        'TimeoutMilliseconds': 123
    },
    'Tags': {
        'string': 'string'
    },
    'Arn': 'string'
}

Response Structure

  • (dict) --

    -- Define Mixin --

    • FunctionId (string) --

      The identifier of the function.

    • FunctionType (string) --

      The type of the function.

    • Description (string) --

      A description of the function.

    • HttpRequestConfiguration (dict) --

      The configuration for an HTTP_REQUEST function.

      • Runtime (string) --

        The expression language used to evaluate expressions in the function configuration. Set this to JSONata.

      • Output (dict) --

        A map of output bindings. Each key is a namespaced output path (such as player_params.device_type or temp.identity), and each value is an expression that MediaTailor evaluates at runtime. Output expressions in an HTTP_REQUEST function can reference the response object returned by the HTTP call. For more information about expression syntax, see JSONata expression reference in the MediaTailor User Guide.

        • (string) --

          • (string) --

      • MethodType (string) --

        The HTTP method for the request. Valid values: GET and POST.

      • RequestTimeoutMilliseconds (integer) --

        The maximum time, in milliseconds, that MediaTailor waits for a response from the external service. If the call exceeds this timeout, MediaTailor sets the response status code to null and proceeds with output expression evaluation. Valid values: 100 to 2000.

      • Url (string) --

        An expression that evaluates to the request URL. Use {%...%} delimiters for dynamic expressions. The maximum length after evaluation is 2,048 characters.

      • Body (string) --

        An expression that evaluates to the request body. Used with POST requests. The maximum size after evaluation is 64 KB.

      • Headers (dict) --

        A map of HTTP header names to expression values. MediaTailor evaluates each header value expression at runtime and includes the result in the outbound HTTP request. Maximum 50 headers.

        • (string) --

          • (string) --

    • CustomOutputConfiguration (dict) --

      The configuration for a CUSTOM_OUTPUT function.

      • Runtime (string) --

        The expression language used to evaluate expressions in the function configuration. Set this to JSONata.

      • Output (dict) --

        A map of output bindings. Each key is a namespaced output path (such as player_params.device_type or temp.variant), and each value is an expression that MediaTailor evaluates at runtime against the current session state. For more information about expression syntax, see JSONata expression reference in the MediaTailor User Guide.

        • (string) --

          • (string) --

    • ConcurrentExecutorConfiguration (dict) --

      The configuration for a CONCURRENT_EXECUTOR function.

      • Runtime (string) --

        The expression language used to evaluate expressions in the function configuration. Set this to JSONata.

      • Output (dict) --

        A map of output bindings that controls which bindings the executor commits to the session state after all child functions complete. Each key is a namespaced output path, and each value is an expression that MediaTailor evaluates against the combined results of the child functions.

        • (string) --

          • (string) --

      • FunctionList (list) --

        The list of child functions that MediaTailor runs in parallel. Each entry specifies a child function to execute and an optional run condition expression that controls whether the function runs.

        • (dict) --

          A reference to a child function within a SEQUENTIAL_EXECUTOR function.

          • RunCondition (string) --

            An optional expression that evaluates to a boolean. MediaTailor evaluates this expression immediately before running the step, using the accumulated state at that point in the sequence. If the expression evaluates to false, MediaTailor skips the step and moves to the next one. If omitted, the step always runs.

          • FunctionId (string) --

            The identifier of the child function to execute in this step.

          • Alias (string) --

            An optional alternate name for the function within the executor. If omitted, MediaTailor uses the function identifier.

      • TimeoutMilliseconds (integer) --

        The maximum time, in milliseconds, for all child functions to complete. This timeout covers every function in the list, including any HTTP calls the child functions make. If the executor exceeds this timeout, MediaTailor discards all output from the executor and proceeds with default behavior.

      • MaxConcurrency (integer) --

        The maximum number of child functions that MediaTailor runs simultaneously. When the list contains more functions than MaxConcurrency, MediaTailor starts additional functions as running ones complete, so that no more than MaxConcurrency functions run at the same time.

    • SequentialExecutorConfiguration (dict) --

      The configuration for a SEQUENTIAL_EXECUTOR function.

      • Runtime (string) --

        The expression language used to evaluate expressions in the function configuration. Set this to JSONata.

      • Output (dict) --

        An optional map of output bindings that controls which bindings the sequence commits to the session state after all steps complete. If omitted, MediaTailor commits all accumulated output bindings from all child steps.

        • (string) --

          • (string) --

      • FunctionList (list) --

        An ordered list of 1 to 10 steps. Each step specifies a child function to execute and an optional run condition expression that controls whether the step runs. MediaTailor executes steps in order, passing data between steps through temporary data.

        • (dict) --

          A reference to a child function within a SEQUENTIAL_EXECUTOR function.

          • RunCondition (string) --

            An optional expression that evaluates to a boolean. MediaTailor evaluates this expression immediately before running the step, using the accumulated state at that point in the sequence. If the expression evaluates to false, MediaTailor skips the step and moves to the next one. If omitted, the step always runs.

          • FunctionId (string) --

            The identifier of the child function to execute in this step.

          • Alias (string) --

            An optional alternate name for the function within the executor. If omitted, MediaTailor uses the function identifier.

      • TimeoutMilliseconds (integer) --

        The maximum time, in milliseconds, for the entire sequence to complete. This timeout covers all steps, including any HTTP calls made by child functions. If the sequence exceeds this timeout, MediaTailor discards all output from the sequence and proceeds with default behavior.

    • Tags (dict) --

      The tags assigned to the function. Tags are key-value pairs that you can associate with Amazon resources to help with organization, access control, and cost tracking. For more information, see Tagging AWS Elemental MediaTailor Resources.

      • (string) --

        • (string) --

    • Arn (string) --

      The Amazon Resource Name (ARN) of the function.