-
Notifications
You must be signed in to change notification settings - Fork 7
mastodon_api_parametrized_routes
Alex Kirk edited this page Feb 8, 2025
·
10 revisions
add_filter(
'mastodon_api_parametrized_routes',
function ( array $string_list ) {
// Your code here
return $string_list;
}
);
-
array
$string_list
apply_filters(
'mastodon_api_parametrized_routes',
array(
'api/v1/accounts/([^/]+)/featured_tags' => 'api/v1/accounts/$matches[1]/featured_tags',
'api/v1/accounts/([^/]+)/followers' => 'api/v1/accounts/$matches[1]/followers',
'api/v1/accounts/([^/]+)/follow' => 'api/v1/accounts/$matches[1]/follow',
'api/v1/accounts/([^/]+)/unfollow' => 'api/v1/accounts/$matches[1]/unfollow',
'api/v1/accounts/([^/]+)/statuses' => 'api/v1/accounts/$matches[1]/statuses',
'api/v1/statuses/([0-9]+)/context' => 'api/v1/statuses/$matches[1]/context',
// ...