initial iOS implementation