Theoretically, yes. Although the practical application isn’t necessarily laid out.
You’d have to have a way of determining “inactivity” – maintaining some method of setting a user meta or other data field to keep track of when the user was last active. But provided you could work that out, then you could use one of two API functions in the plugin to either remove the membership or set the expiration date to expired.
wpmem_remove_user_product()
(or, as an alias, wpmem_remove_user_membership()
) can be used to remove a membership from a user. See: https://rocketgeek.com/plugins/wp-members/docs/api-functions/wpmem_remove_user_product/
wpmem_set_user_product()
(or its alias, wpmem_set_user_membership()
) can be used to set a user’s expiration date to a specific date (including one that is expired). See: https://rocketgeek.com/plugins/wp-members/docs/api-functions/wpmem_set_user_product/