Add s2Member level access via PHP to a page

Hi all,
In the membership site I’m developing I create a page dynamically for a person who signs up for a specific membership level.
Through PHP I can add specific CCAPS to that page so access can be restricted by these CCAPS, like this:
update_post_meta($parentpost_id, 's2member_ccaps_req', $owner_ccaps);
Works great.
But now I want to add an extra layer of protection by adding Page Level Restrictions based on the s2Member Levels.
If a new member signs up, he gets Level#1 access and a bunch of CCAPS. via PHP I create a page for him, add the needed CCAPS, and now I want to add Level#1 restriction to that page.
How can this be done dynamically?

I solved it another way (aka Workaround).
I give that dynamically generated page a specific tag (e.g. ‘member’):
wp_set_post_tags( $page_id, 'member', true );
In s2Member -> Restriction Options -> Tag Access Restrictions I set the tag ‘member’ to require Level#1 access.

This might not be the best solution, but it works for what I’m trying to achieve.

p.s.: You don’t necessarily need a plugin to make tags available to pages, just assigning the tag with wp_set_post_tags is all I needed. The downside is that without a plugin you cannot see in WP Dashboard what tags are assigend to pages.