You can check the comment section of this page https://adobe-consulting-services.github.io/acs-aem-commons/features/dispatcher-flush-rules/index.ht... ,
Sample given for content fragments, you can try similar one
For clearing the cache of content fragments that are accessed via the API Assets using a URL such as /api/assets/somepath.json, you can use the rule:
prop.replication-action-type="INHERIT"
prop.rules.hierarchical=["/content/dam/(.*)=/api/assets/$1"]
You may also need to add a rule to your Dispatcher /invalidate section to clear .json files like this:
/4444 { /glob "*.json" /type "allow" }