get_body() ); return \outbox\create_activity( $handle, $activity ); } function register_routes() { register_rest_route( 'activitypub/v1', '/actor/(?P[a-zA-Z0-9-]+)', array( 'methods' => 'GET', 'callback' => __NAMESPACE__ . '\get_user_actor', ) ); register_rest_route( 'activitypub/v1', '/actor/(?P[a-zA-Z0-9-]+)/outbox', array( 'methods' => 'POST', 'callback' => __NAMESPACE__ . '\post_to_outbox', ) ); } ?>