SodaCreekDigital Posted March 18, 2021 Share Posted March 18, 2021 I'm working on a concept for a website where member areas will be used (we are in the design discussion phase so I don't have a URL to share). The idea is for members to be able to login and view a set of pages that show data from a database that is being built using SQL Server. The database developer has asked what the rendered HTML is for the user details (e.g. a user ID, a user email address are the likely information). He wants to complete a check of all users that are on the page to confirm that they are authenticated. This is a bit over my head so wondering if anyone that is more familiar with the technicalities of Squarespace and member areas that could help me understand what the user details are that are available? Or, can I put the developer in contact with you for him to explain this potentially better than I am! 😀 Thank you! Link to comment
SodaCreekDigital Posted March 20, 2021 Author Share Posted March 20, 2021 @paul2009 and @kerstinmartinI hope you don't mind me reaching out to you, but do you have any insight into my question? Thank you. Sandra Link to comment
paul2009 Posted March 20, 2021 Share Posted March 20, 2021 On 3/18/2021 at 5:56 PM, SodaCreekDigital said: I'm working on a concept for a website where member areas will be used. The idea is for members to be able to login and view a set of pages that show data from a database that is being built using SQL Server. The database developer has asked what the rendered HTML is for the user details (e.g. a user ID, a user email address are the likely information). He wants to complete a check of all users that are on the page to confirm that they are authenticated. Hi Sandra If the SQL data is to be embedded in Squarespace pages that are protected by Member Areas then I wouldn't expect the developer to need to authenticate users too. If the customer has reached the page, they are authenticated. As far as I know, they wouldn't be able to confirm if the user is authenticated in Member Areas anyway, because as the API does not mention this capability yet. Perhaps @KLin or@MaddieSmith can confirm whether the API has been updated to allow us to query if the customer is actively subscribed to a Member Area plan? However, to answer your specific question 🙂 there isn't any rendered HTML because the user details are secured in a separate account frame. You could use JS to call the User Account API to check if the user is authenticated. If they are, you can return some information about the customer such as their email address, name and customer id. -Paul Me: I'm Paul, a SQSP user for >18 yrs & Circle Leader since 2017. I value honesty, transparency, diversity and good design ♥. Work: Founder of SF.DIGITAL. We provide high quality original extensions to supercharge your Squarespace website. Content: Views and opinions are my own. Links in my posts may refer to my own SF.DIGITAL products or may be affiliate links. Forum advice is completely free. You can thank me by selecting a feedback emoji. Buying a coffee is generous but optional. Would you like your customers to be able to mark their favourite products in your Squarespace store? Link to comment
kerstinmartin Posted March 23, 2021 Share Posted March 23, 2021 On 3/20/2021 at 2:45 AM, SodaCreekDigital said: @paul2009 and @kerstinmartinI hope you don't mind me reaching out to you, but do you have any insight into my question? Hi Sandra! This gets too technical for me as well, I know the user side really well but I am not a developer. It looks like @paul2009did a stellar job in answering this! ❤️ Hi, I'm Kerstin! I offer business and marketing courses to help solopreneurs deepen their business skills and grow their confidence, audience, and revenue - without the hustle. 👩🏼💻 Is solo entrepreneurship right for you? → Take the quiz Link to comment
SodaCreekDigital Posted March 24, 2021 Author Share Posted March 24, 2021 Thank you @kerstinmartin! @paul2009Thank you as well for your response. Do you know of any examples where JS has been used to call the User Account API to check if the user is authenticated. And if there are examples, can we return some information about the customer such as their email address, name and customer id? Or, do you now of any support or knowledge documents on this? I really appreciate your help. Link to comment
Recommended Posts
Archived
This topic is now archived and is closed to further replies.