Flush a custom cache instance

I am using a custom cache (set up in my config.php, not in a plugin) and the example at https://getkirby.com/docs/guide/cache#using-the-cache is very helpful; only: I can’t figure out how to flush that specific cache?

Use case: I am caching a complex, pre-processed list of content elements for use in a template and would like to flush it using a page.update:after hook when content changes.

$apiCache->flush()

should do the job.

It does indeed! Thank you :sunglasses: