Magic Linking 1.0.1 has 3 actions and 17 filters, read directly from its source code on Nov 19, 2026. The list updates automatically when a new version is released.
How to use these hooks
Actions let you run your own code at a specific moment. Filters let you change a value before the plugin uses it. Put your code in a child theme's functions.php or a code-snippets plugin, never in the plugin's own files, because updates overwrite them.
// Run your own code when Magic Linking fires an action
add_action( 'magiclinking_batch_undone', function( $batch_id, $undone ) {
// Your code runs here.
}, 10, 2 );
// Change a value Magic Linking is about to use
add_filter( 'magiclinking_insertable_blocks', function( $names, $post_id ) {
// Change $names here.
return $names;
}, 10, 2 );Parts of a name in {braces} are filled in at runtime (for example a post type or field ID). Choose Example on any hook for a ready-to-edit snippet.
All hooks
-
/** * Se ha deshecho un lote (al menos uno de sus cambios). */ do_action( 'magiclinking_batch_undone', $batch_id, $undone ); -
/** * Bloques en cuyo texto se puede insertar un enlace. */ apply_filters( 'magiclinking_insertable_blocks', $names, $request->post_id ); -
/** * Otros hosts que cuentan como enlaces internos (dominios alternativos del * mismo sitio). */ apply_filters( 'magiclinking_internal_hosts', array() ); -
/** * Se ha arreglado un enlace roto (cambiando su destino o quitándolo). */ do_action( 'magiclinking_link_fixed', $result->change_id, $result->post_id, $result->batch_id, $request->action() ); -
/** * Se ha insertado un enlace. */ do_action( 'magiclinking_link_inserted', $result->change_id, $result->post_id, $result->batch_id ); -
/** * Permite añadir el HTML que un maquetador guarda fuera de post_content. */ apply_filters( 'magiclinking_post_html', $post->post_content, $post ); -
/** * Filtra cuántas peticiones de IA por minuto puede hacer cada usuario. */ apply_filters( 'magiclinking_ai_calls_per_minute', self::PER_MINUTE ); -
/** * Máximo de entradas por ejecución del indexado en segundo plano. */ apply_filters( 'magiclinking_batch_max_entries', self::MAX_ENTRIES ); -
/** * Segundos de trabajo por ejecución del indexado en segundo plano. */ apply_filters( 'magiclinking_batch_time_budget', (float) self::TIME_BUDGET ); -
/** * Permite al sitio vetar o modificar una petición de IA antes de enviarla * (además de `wp_ai_client_prevent_prompt`, que también se respeta). */ apply_filters( 'magiclinking_before_ai_request', $request, $request->type ); -
/** * Permite marcar el sitio como multilingüe (o no) para mostrar u ocultar el * idioma en el informe. */ apply_filters( 'magiclinking_is_multilingual', $active ); -
/** * Filtra los identificadores de proveedor de IA que cuentan como locales (el * texto no sale del servidor). */ apply_filters( 'magiclinking_local_ai_providers', self::LOCAL_PROVIDERS ); -
/** * Permite fijar el idioma de una entrada desde otro plugin o desde el tema. */ apply_filters( 'magiclinking_post_language', null, $post_id ); -
/** * Segundos que se espera a que otra operación suelte una entrada antes de * negarse. */ apply_filters( 'magiclinking_post_lock_timeout', 5, $post_id ); -
/** * Permite a un plugin de redirecciones (o a cualquier otro) decidir el destino * de una URL interna. */ apply_filters( 'magiclinking_resolve_link', null, $url ); -
/** * Cambios de un grupo a partir de los cuales deshacer o rehacer se hace en * segundo plano. */ apply_filters( 'magiclinking_undo_sync_limit', self::SYNC_LIMIT ); -
/** * Este filtro es el de WordPress (`wp_check_post_lock()`): ventana en segundos * de un bloqueo vigente. */ apply_filters( 'wp_check_post_lock_window', 150 ); -
apply_filters( 'get_the_terms', $terms, $post_id, $taxonomy ); -
apply_filters( 'magiclinking_seo_plugin_active', defined( $constant ), $plugin ); -
apply_filters( 'wpml_post_language_details', null, $post_id );
Generated from Magic Linking's GPL-licensed source code. Hooks inside bundled third-party libraries are not listed.
Done for you
Rather have it built for you?
Tell us what should change and we’ll write and test the code using these hooks.
Custom hook snippet
from $49
A small, update-safe change built on the plugin’s own hooks.
- Code written against the plugin’s actions and filters
- Tested on a staging copy of your site
- Install instructions included
Typical turnaround: 2–3 business days
Choose thisPlugin customisation
from $149
New features or changed behaviour, without editing the plugin’s files.
- Built as a companion plugin, so updates never wipe it
- Exact quote before we start
- Tested on staging, then deployed
Typical turnaround: 3–7 business days
Choose thisNot sure which fits? Describe what you need and we’ll suggest the simplest option.
Can't find the right hook?
We can build the customisation for you. Describe what you need: