def resolve_signature(command):
    """Retrieve command signature or evaluate dynamic signature.

    command: command instance or subclass [Command/type]

    return: command's signature [str]
    """
    if isinstance(command, type):
        command = command()  # instantiate if subclass passed
    try:
        return command.signature()
    except TypeError:
        return command.signature