connection callback shared in types project