All routines here should be identical to the routines in $SMEI/for/tdlib