{"library":"pyobjc-framework-replaykit","title":"PyObjC ReplayKit Framework","description":"pyobjc-framework-replaykit provides Python bindings for Apple's ReplayKit framework on macOS, enabling developers to integrate screen recording and broadcasting capabilities into their Python applications. Part of the larger PyObjC project, it closely tracks macOS SDK updates, with current version 12.1. The PyObjC project generally releases new versions multiple times a year, often aligning with major macOS releases and Python version updates.","language":"python","status":"active","last_verified":"Sat May 16","install":{"commands":["pip install pyobjc-framework-replaykit"],"cli":null},"imports":["import ReplayKit"],"auth":{"required":false,"env_vars":[]},"quickstart":{"code":"import ReplayKit\nfrom PyObjCTools import AppHelper\nfrom Foundation import NSObject, NSLog\n\nclass ReplayKitChecker(NSObject):\n    def applicationDidFinishLaunching_(self, notification):\n        # Access the shared screen recorder instance\n        recorder = ReplayKit.RPScreenRecorder.sharedRecorder()\n\n        # Check if ReplayKit is available for recording\n        if recorder.isAvailable():\n            NSLog(\"ReplayKit is available for screen recording.\")\n        else:\n            NSLog(\"ReplayKit is not available for screen recording.\")\n\n        # In a real application, you'd perform further ReplayKit actions here\n        # For this quickstart, we just check availability and then stop the application.\n        AppHelper.stopEventLoop()\n\nif __name__ == \"__main__\":\n    # Run a minimal Cocoa event loop to execute the application delegate.\n    # This is often necessary for PyObjC code interacting with UI frameworks.\n    AppHelper.runEventLoop(argv=[], appDelegate=ReplayKitChecker.alloc().init())\n","lang":"python","description":"This example demonstrates how to check if ReplayKit is available for screen recording on the current macOS system. It sets up a minimal `PyObjCTools.AppHelper` event loop, which is often required for PyObjC applications interacting with Cocoa frameworks on the main thread. The `applicationDidFinishLaunching_` method, analogous to `AppDelegate` in Objective-C, is used to interact with the `ReplayKit.RPScreenRecorder` shared instance.","tag":null,"tag_description":null,"last_tested":null,"results":[]},"compatibility":{"tag":null,"tag_description":null,"last_tested":"2026-05-16","installed_version":null,"pypi_latest":"12.1","is_stale":null,"summary":{"python_range":"3.10–3.9","success_rate":0,"avg_install_s":null,"avg_import_s":null,"wheel_type":null},"results":[{"runtime":"python:3.10-alpine","python_version":"3.10","os_libc":"alpine (musl)","variant":"pyobjc-framework-replaykit","exit_code":1,"wheel_type":null,"failure_reason":"build_error","import_side_effects":null,"install_time_s":null,"import_time_s":null,"mem_mb":null,"disk_size":null},{"runtime":"python:3.10-slim","python_version":"3.10","os_libc":"slim (glibc)","variant":"pyobjc-framework-replaykit","exit_code":1,"wheel_type":null,"failure_reason":"build_error","import_side_effects":null,"install_time_s":2.9,"import_time_s":null,"mem_mb":null,"disk_size":null},{"runtime":"python:3.11-alpine","python_version":"3.11","os_libc":"alpine (musl)","variant":"pyobjc-framework-replaykit","exit_code":1,"wheel_type":null,"failure_reason":"build_error","import_side_effects":null,"install_time_s":null,"import_time_s":null,"mem_mb":null,"disk_size":null},{"runtime":"python:3.11-slim","python_version":"3.11","os_libc":"slim (glibc)","variant":"pyobjc-framework-replaykit","exit_code":1,"wheel_type":null,"failure_reason":"build_error","import_side_effects":null,"install_time_s":2.9,"import_time_s":null,"mem_mb":null,"disk_size":null},{"runtime":"python:3.12-alpine","python_version":"3.12","os_libc":"alpine (musl)","variant":"pyobjc-framework-replaykit","exit_code":1,"wheel_type":null,"failure_reason":"build_error","import_side_effects":null,"install_time_s":null,"import_time_s":null,"mem_mb":null,"disk_size":null},{"runtime":"python:3.12-slim","python_version":"3.12","os_libc":"slim (glibc)","variant":"pyobjc-framework-replaykit","exit_code":1,"wheel_type":null,"failure_reason":"build_error","import_side_effects":null,"install_time_s":2.9,"import_time_s":null,"mem_mb":null,"disk_size":null},{"runtime":"python:3.13-alpine","python_version":"3.13","os_libc":"alpine (musl)","variant":"pyobjc-framework-replaykit","exit_code":1,"wheel_type":null,"failure_reason":"build_error","import_side_effects":null,"install_time_s":null,"import_time_s":null,"mem_mb":null,"disk_size":null},{"runtime":"python:3.13-slim","python_version":"3.13","os_libc":"slim (glibc)","variant":"pyobjc-framework-replaykit","exit_code":1,"wheel_type":null,"failure_reason":"build_error","import_side_effects":null,"install_time_s":2.5,"import_time_s":null,"mem_mb":null,"disk_size":null},{"runtime":"python:3.9-alpine","python_version":"3.9","os_libc":"alpine (musl)","variant":"pyobjc-framework-replaykit","exit_code":1,"wheel_type":null,"failure_reason":"build_error","import_side_effects":null,"install_time_s":null,"import_time_s":null,"mem_mb":null,"disk_size":null},{"runtime":"python:3.9-slim","python_version":"3.9","os_libc":"slim (glibc)","variant":"pyobjc-framework-replaykit","exit_code":1,"wheel_type":null,"failure_reason":"build_error","import_side_effects":null,"install_time_s":3.5,"import_time_s":null,"mem_mb":null,"disk_size":null}]}}