added disconnect to api