-
Notifications
You must be signed in to change notification settings - Fork 85
activitypub_oauth_check_permission
github-actions[bot] edited this page Mar 12, 2026
·
1 revision
Filter to override OAuth permission check.
Useful for testing. Return true to bypass OAuth check, false to continue.
/**
* Filter to override OAuth permission check.
*
* Useful for testing. Return true to bypass OAuth check, false to continue.
*
* @param bool $result
* @param WP_REST_Request $request
* @param string $scope
* @return bool The filtered value.
*/
function my_activitypub_oauth_check_permission_callback( bool $result = null, WP_REST_Request $request, string $scope = null ) {
// Your code here.
return null;
}
add_filter( 'activitypub_oauth_check_permission', 'my_activitypub_oauth_check_permission_callback', 10, 3 );-
bool|null$resultThe permission result. Null to continue normal check. -
WP_REST_Request$requestThe REST request. -
string|null$scopeRequired scope.
\apply_filters( 'activitypub_oauth_check_permission', null, $request, $scope )Follow @activitypub.blog@activitypub.blog for updates and news.