handshake API

hmmm we need to be careful about that I think