wp rcp memberships command allows you to get and create membership records.
- --id=<membership_id>: Optional. A specific membership ID to retrieve.
- --email=<customer_email>: Optional. Retrieve the memberships for the customer with this email address.
- --create=<number>: Optional. Specify a number of new membership records to create. Default 30.
- --range=<number>: Optional. The range (in number of days) to use for the creation period in new memberships. Default 30.
- --status=<membership_status>: Optional. The status (active, pending, expired, cancelled) to use for new memberships. Default is a random selection of all statuses.
- --level=<membership_level_id>: Optional. ID of the membership level to assign to new memberships. Default is a random one for each membership.
Creating memberships also creates corresponding user accounts, customer records, and payment records.
Get a specific membership record by ID:
wp rcp memberships --id=206
Create 2 "active" memberships, randomly created over the last 180 days:
wp rcp memberships --create=2 --range=180 --status=active