ASP.NET

Learn how to integrate Wristband authentication with your C# server using our SDK.

An ASP.NET server integration (C# backend) uses the Backend Server pattern to handle authentication in your app. Learn more in our Integration Patterns for Backend Server documentation.


Goals

After completing this guide you will have learned the following concepts:

  • Building a C# backend API
  • Integrating the Wristband Auth SDK with your C# backend
  • Basic session management with your C# backend
  • Connecting a front-end application using React/NextJS to the ExpressJS backend
  • Implementing Cross Site Request Forgery (CSRF) protection

Prerequisites

  • .NET SDK (6.0 or later)
  • ASP.NET Core (6.0 or later)
  • A package manager such as NuGet
  • React (vanilla or NextJS)

Set Up ASP.NET Core

If you are starting your app from scratch, you will need to set up an ASP.NET Core project by following the official documentation.

๐Ÿ“˜

Handling Cookies in ASP.NET Core

Ensure your ASP.NET Core application is configured to handle cookies. The Wristband SDK relies on authentication cookies for session management. Refer to Microsoft's cookie authentication documentation for details.


Whatโ€™s Next

After your C# server is set up, you can install the Wristband Auth SDK.