I figured a different solution. I just extended the existing taxonomies onto attachments. So I can still use MLA Gallery, but with the original classifications.
$taxonomies = array('category', 'post_tag');
foreach ( $taxonomies as $tax ) {
register_taxonomy_for_object_type( $tax, 'attachment' );
}
This is not quite the issue – and my apologies because I realize I wasn’t specific in my original post.
The WP API is accessible via {domain}/wp-json/wp/v2/posts or something of the sorts. I can then only requests posts tagged appropriately by wp/v2/posts?tag={tag_id} and I’m hoping to do the same thing with the media objects that your MLA Gallery returns. When I hit the API for media objects, I can’t get the Att. Tags or Att. Categories data to come back as well.
Do you have an endpoint for that? Do you have suggestions? I can’t re-process the shortcode because our page shouldn’t ever reload. I use the shortcode to immediately get the gallery, but then I need to filter later by tags without refreshing the page.
Thanks again, sorry if I wasn’t clear in my issue.