Get paid plan for user through REST API

I have a desktop app which has a login page. Upon login I call my Wix’s site API to check if the user has paid his membership. The problem is that I cannot I find a way to query the user’s paid plans. I have went through the API documentation where I found the ’ wix-members-backend ’ module which has ’ currentMember.getMember(options) ’ but I receive a Forbidden error when I call it in my API endpoint. Is there a way this can be achieved ?
Thanks in advance !


Is this solved?

If you are experiencing a Forbidden error when calling the currentMember.getMember(options) function from the ‘wix-members-backend’ module in your Wix site’s API endpoint, there could be a few potential reasons for this issue:

  1. API Permissions: Ensure that your API endpoint has the necessary permissions to access the ‘wix-members-backend’ module and make the currentMember.getMember() call. Double-check your API’s configuration and make sure it has the required authorization to access member-related information.

  2. Authentication: Verify that the user making the API request is properly authenticated and authorized to access the member data. If the user is not logged in or does not have the necessary permissions, it could result in a Forbidden error. Make sure you have implemented the authentication flow correctly in your desktop app and that the appropriate authentication tokens or credentials are included in the API request. My HR KP

  3. Correct Endpoint: Ensure that you are calling the correct API endpoint and using the appropriate syntax for the currentMember.getMember() function. Double-check the documentation and examples provided by Wix to make sure you are using the correct method signature and passing the required parameters.

  4. Subscription and Membership Setup: Verify that your membership and subscription setup in Wix is configured correctly. Check if the user’s paid plan is associated with the proper membership settings and that the API call is being made after the user has completed the payment process successfully.