Skip to main content
  1. When registering your application for OAuth set your callback url to match this format /oauth/[provider]/validate.
  2. In the src directory of your project, create a hooks.server.ts file and paste the following code:
  1. Create an .env file at the root level of your project and define your client ID and secret as variables. Example:
  1. In your +page.svelte file that has your login page:
    • Create a button or component for each provider you want to use, that will route to an endpoint of /oauth/[provider-name-here]/auth
    • Make sure to include an anchor tag within the button and/or component.
OAuth providers are not set up to store any data in a database in this current iteration of Svault.