def get_args(action_parameters, action_db):
    """

    Get and serialize positional and named arguments.

    :return: (positional_args, named_args)
    :rtype: (``str``, ``dict``)
    """
    position_args_dict = _get_position_arg_dict(action_parameters, action_db)

    action_db_parameters = action_db.parameters or {}

    positional_args = []
    positional_args_keys = set()
    for _, arg in six.iteritems(position_args_dict):
        arg_type = action_db_parameters.get(arg, {}).get("type", None)

        # Perform serialization for positional arguments
        arg_value = action_parameters.get(arg, None)
        arg_value = serialize_positional_argument(
            argument_type=arg_type, argument_value=arg_value
        )

        positional_args.append(arg_value)
        positional_args_keys.add(arg)

    named_args = {}
    for param in action_parameters:
        if param not in positional_args_keys:
            named_args[param] = action_parameters.get(param)

    return positional_args, named_args


    Get and serialize positional and named arguments.

    :return: (positional_args, named_args)
    :rtype: (``str``, ``dict``)
    
st2common/st2common/util/action_db.py