Ohara 1.2.1 has 8 actions and 35 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 Ohara fires an action
add_action( 'ohara_admin_enqueue', function( $hook ) {
// Your code runs here.
}, 10, 1 );
// Change a value Ohara is about to use
add_filter( 'ohara_allowed_layouts', function( $value ) {
// Change $value here.
return $value;
}, 10, 1 );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
-
/** * Fires while the Ohara builder screen's assets are being enqueued. */ do_action( 'ohara_admin_enqueue', $hook ); -
/** * Filters the layout slugs available on this site. */ apply_filters( 'ohara_allowed_layouts', self::LAYOUTS ); -
/** * Filters extra badges shown on a card's picture (escaped HTML). */ apply_filters( 'ohara_card_badges', '', $video, $data ); -
/** * Filters the per-card options handed to the card template (add-on keys reach * `ohara_card_badges` through `$data['card']`). */ apply_filters( 'ohara_card_options', self::base_card_options( $settings ), $settings ); -
/** * Filters the feed header: name, avatar and a line under the name. */ apply_filters( 'ohara_channel_header', [ 'title' => $channel_title, 'avatar' => '', 'subtitle' => '', ], $data ); -
/** * Filters the display settings: add-on keys added here are sent with the * frontend app's requests and reach `ohara_display_videos`. */ apply_filters( 'ohara_display_settings', $base, $settings ); -
/** * Filters the videos a feed shows, after hiding, word filters and order. */ apply_filters( 'ohara_display_videos', $items, $settings ); -
/** * Filters the cache key arguments for an add-on's feed type. */ apply_filters( 'ohara_feed_cache_args', [], $type, $source, $max_results, $this ); -
/** * Filters the `data-config` payload of a rendered feed. */ apply_filters( 'ohara_feed_config', $config, $args ); -
/** * Filters a rendered feed's final markup (the mount included). */ apply_filters( 'ohara_feed_html', $this->wrap_for_hydration( $markup, $args, $count ), $args ); -
/** * Filters the map of layout slug => renderer callable. */ apply_filters( 'ohara_feed_layout_renderers', [] ); -
/** * Filters the feed IDs found in a post, letting integrations contribute * references our own scanners can't see. */ apply_filters( 'ohara_feed_reference_scanners', $feed_ids, $post ); -
/** * Filters how old a stored feed may get before it is refreshed. */ apply_filters( 'ohara_feed_refresh_interval', $ttl ? $ttl : self::DEFAULT_TTL ); -
/** * Filters the per-feed control schema. */ apply_filters( 'ohara_feed_schema', self::base() ); -
/** * Filters the markup rendered into one named slot of a feed layout. */ apply_filters( "ohara_feed_slot_{$name}", '', $data ); -
/** * Filters the custom properties set on a feed's mount (`--name:value`). */ apply_filters( 'ohara_feed_style_props', $style_props, $args ); -
/** * Filters the map of feed-type slug => video source callable. */ apply_filters( 'ohara_feed_type_sources', [] ); -
/** * Filters the *additional* feed type slugs an add-on makes available. */ apply_filters( 'ohara_feed_types', [] ); -
/** * Filters whether this request may call YouTube for a stale or failed feed. */ apply_filters( 'ohara_fetch_inline', $inline ); -
/** * Filters freshly fetched videos before they are stored. */ apply_filters( 'ohara_fetched_videos', $items, $this->request, $this ); -
/** * Filters the most videos one feed may ask for. */ apply_filters( 'ohara_max_videos', 50 ); -
/** * Filters the catalogue of premium features to advertise. */ apply_filters( 'ohara_pro_features', [ 'layouts' => [], 'feed_types' => self::feed_type_teasers(), ] ); -
/** * Filters the posts whose page cache is cleared when a feed changes. */ apply_filters( 'ohara_purge_posts', $posts, $type, $source ); -
/** * Fires after Ohara cleared every page cache. */ do_action( 'ohara_purged_all' ); -
/** * Fires after Ohara cleared a post's page cache. */ do_action( 'ohara_purged_post', $post_id ); -
/** * Filters one keyless video item. */ apply_filters( 'ohara_rss_item', $item, $group_kids && isset( $group_kids->description ) ? (string) $group_kids->description : '' ); -
/** * Filters the sanitized source value for an add-on's feed type. */ apply_filters( 'ohara_sanitize_feed_source', self::source_id( $value ), $value, $type ); -
/** * Filters the tabs shown under Settings in the Ohara admin app. */ apply_filters( 'ohara_settings_tabs', $tabs ); -
/** * Filters whether a feed type reads YouTube's public feeds instead of the Data * API. */ apply_filters( 'ohara_use_rss', $use_rss, $type, $this ); -
/** * Filters whether a source value is valid for an add-on's feed type. */ apply_filters( 'ohara_validate_feed_source', false, $value, $type ); -
/** * Filters one API video item after its details were fetched. */ apply_filters( 'ohara_video_details', $item, (array) $detail ); -
/** * Filters which `videos` resource parts are fetched for API results. */ apply_filters( 'ohara_video_details_parts', [ 'statistics' ] ); -
/** * Fires once the elected SDK is loaded. Products register here. */ do_action( 'wpshark_sdk_loaded' ); -
apply_filters( 'ohara_help_url', 'https://wpshark.xyz/ohara/docs' ); -
apply_filters( 'ohara_pro_active', false ); -
apply_filters( 'ohara_upgrade_url', 'https://wpshark.xyz/ohara/pricing' ); -
apply_filters( 'wpshark_sdk_enabled', true ); -
do_action( 'litespeed_purge_all' ); -
do_action( 'litespeed_purge_post', $post_id ); -
apply_filters( 'ohara_default_settings', [ 'default_layout' => 'grid', 'videos_per_page' => 12, 'cache_duration' => HOUR_IN_SECONDS, 'gdpr_mode' => false, 'privacy_player' => true, 'local_thumbnails' => false, 'usage_tracking' => false, 'cron_cache_clearing' => false, 'custom_templates' => false, 'enqueue_js_header' => false, 'disable_wp_posts' => false, 'remote_notices' => false, ] ); -
do_action( 'wpfc_clear_all_cache' ); -
do_action( 'wpfc_clear_post_cache_by_id', false, $post_id ); -
apply_filters( 'wpshark_sdk_capability', 'manage_options' );
Generated from Ohara'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: