import re


def is_synapse_id(obj):
    """If the input is a Synapse ID return it, otherwise return None"""
    if isinstance(obj, str):
        m = re.match(r'(syn\d+)', obj)
        if m:
            return m.group(1)
    return None