Flutter implementation of the Quickstart Supabase User Management app.

Related tags

Auth flutter supabase
Overview

Supabase Flutter User Management

This repo is a quick sample of how you can get started building apps using Flutter and Supabase. You can find a step by step guide of how to build out this app in the Quickstart: Flutter guide.

This repo will demonstrate how to:

Supabase User Management example

Getting Started

Before running this app, you need to create a Supabase project and copy your credentials to main.dart.

You can run this app on iOS, Android or the Web.

To run this application, simply run the following for iOS or Android

flutter run

Or for web, run the following command to launch it on localhost:3000

flutter run -d web-server --web-hostname localhost --web-port 3000

Database Schema

= 3) ); alter table profiles enable row level security; create policy "Public profiles are viewable by everyone." on profiles for select using ( true ); create policy "Users can insert their own profile." on profiles for insert with check ( auth.uid() = id ); create policy "Users can update own profile." on profiles for update using ( auth.uid() = id ); -- Set up Realtime! begin; drop publication if exists supabase_realtime; create publication supabase_realtime; commit; alter publication supabase_realtime add table profiles; -- Set up Storage! insert into storage.buckets (id, name) values ('avatars', 'avatars'); create policy "Avatar images are publicly accessible." on storage.objects for select using ( bucket_id = 'avatars' ); create policy "Anyone can upload an avatar." on storage.objects for insert with check ( bucket_id = 'avatars' ); ">
-- Create a table for public "profiles"
create table profiles (
  id uuid references auth.users not null,
  updated_at timestamp with time zone,
  username text unique,
  avatar_url text,
  website text,

  primary key (id),
  unique(username),
  constraint username_length check (char_length(username) >= 3)
);

alter table profiles enable row level security;

create policy "Public profiles are viewable by everyone."
  on profiles for select
  using ( true );

create policy "Users can insert their own profile."
  on profiles for insert
  with check ( auth.uid() = id );

create policy "Users can update own profile."
  on profiles for update
  using ( auth.uid() = id );

-- Set up Realtime!
begin;
  drop publication if exists supabase_realtime;
  create publication supabase_realtime;
commit;
alter publication supabase_realtime add table profiles;

-- Set up Storage!
insert into storage.buckets (id, name)
values ('avatars', 'avatars');

create policy "Avatar images are publicly accessible."
  on storage.objects for select
  using ( bucket_id = 'avatars' );

create policy "Anyone can upload an avatar."
  on storage.objects for insert
  with check ( bucket_id = 'avatars' );
You might also like...

WebView OAuth flows for desktop flutter apps

desktop_webview_auth A new flutter plugin project. Getting Started This project is a starting point for a Flutter plug-in package, a specialized packa

Dec 17, 2022

Easy third party authentication (OAuth 2.0) for Flutter apps.

visa This is an OAuth 2.0 package that makes it super easy to add third party authentication to flutter apps. It has support for FB, Google, LinkedIn,

Dec 23, 2022

Authentication pages I made with Flutter and Firebase

Authentication pages I made with Flutter and Firebase

Auth-with-Flutter-and-Firebase Authentication pages I made with Flutter and Firebase Overview This email and password authentication is implemented wi

Jul 24, 2022

An example of JWT authentication with flutter.

flutter-jwt-auth-template An example of JWT authentication with flutter. Getting Started Clone this repository, and inside its folder, run: flutter pu

Jan 4, 2023

In this Application Built Using Flutter🎯 along with FireBase 🔥for Managing the data

In this Application Built Using Flutter🎯 along with FireBase 🔥for Managing the data, I have Curated a simple🤝 Login/Sign Up Space along with Authentication!

Oct 9, 2022

Quickstart guide for the Agora Flutter SDK(Android/iOS)

Quickstart guide for the Agora Flutter SDK(Android/iOS)

Agora Flutter Quickstart This tutorial describes how to create an Agora account and build a sample app with Agora using Flutter. Other Languages: 简体中文

Dec 30, 2022

Supabase flutter user management demo app.

Supabase flutter user management demo app.

Supabase Flutter User Management This example will set you up for a very common situation: users can sign up with a magic link and then update their a

Dec 3, 2022

Utility Manager Flutter Application is made with Flutter and Supabase which allows user to add task, set remainder to the task, set color to separate tasks and it allows to add URL with URL's informations.

Utility Manager Flutter Application is made with Flutter and Supabase which allows user to add task, set remainder to the task, set color to separate tasks and it allows to add URL with URL's informations.

Utility Manager Flutter Application! Utility Manager Flutter Application is made with Flutter and Supabase which allows user to add task, set remainde

Jan 6, 2022

A fully functional Furniture App Clone made using Flutter, Supabase and Getx State Management.

A fully functional Furniture App Clone made using Flutter, Supabase and Getx State Management.

🛌 Flutter Furniture App 🪑 Timberr is a fully functional Furniture App Clone Developed using Flutter, Supabase and Getx State Management which is bas

Nov 22, 2022

Open source geo based video sharing social app created with Flutter, Supabase and lots of love 💙💙💙

Open source geo based video sharing social app created with Flutter, Supabase and lots of love 💙💙💙

Spot Take a virtual journey around the world with Spot. Spot is a geo-tagged video sharing app, meaning every video recorded in Spot is saved on a loc

Jan 3, 2023

Basic e-commerce app made in Flutter and Supabase.

Basic e-commerce app made in Flutter and Supabase.

Available on Android / IOS Made in Flutter and Supabase Package Provider Supabase http Features Authentication filter products by discount, rating, ca

Nov 20, 2022

UI library to easily implement auth functionalities of Supabase in your app.

UI library to easily implement auth functionalities of Supabase in your app.

flutter-auth-ui A simple library of predefined widgets to easily and quickly create a auth compooents using Flutter and Supabase. ⚠️ Developer Preview

Dec 13, 2022

Flutter project integrated with Supabase, the Firebase open source alternative

This is a Flutter project integrated with Supabase, the Firebase open source alternative. This project is a sandbox for playground for Flutter & Supabase integration.

Oct 18, 2022

Addons to supabase dart (and Flutter), to make development easier.

supabase_addons Make great apps with a great backend! Supabase is an open source Firebase alternative. It has support for auth, database and storage u

Dec 3, 2022

Flutter integration for Supabase. This package makes it simple for developers to build secure and scalable products.

Flutter integration for Supabase. This package makes it simple for developers to build secure and scalable products.

supabase_flutter Flutter package for Supabase. What is Supabase Supabase is an open source Firebase alternative. We are a service to: listen to databa

Jan 7, 2023

🎯 A powerful multiplatform application with Flutter and Supabase for the Komentory project.

🎯 Multiplatform application for Komentory project A powerful multiplatform application with Flutter and Supabase for the Komentory project. Currently

Mar 1, 2022

A Flutter application to plan personal activities and routines that uses Supabase for the backend.

Flutter Planner Generated by the Very Good CLI 🤖 A Flutter application to plan personal activities and routines that uses Supabase for the backend. P

Dec 29, 2022
Comments
  • Deeplink difference in repo vs guide

    Deeplink difference in repo vs guide

    The guide , https://supabase.com/docs/guides/with-flutter, shows that this should be added to AndroidManifest.xml

          <intent-filter>
            <action android:name="android.intent.action.VIEW" />
            <category android:name="android.intent.category.DEFAULT" />
            <category android:name="android.intent.category.BROWSABLE" />
            <!-- Accepts URIs that begin with YOUR_SCHEME://YOUR_HOST -->
            <data
              android:scheme="io.supabase.flutterquickstart"
              android:host="login-callback" />
          </intent-filter>
    

    Yet the repo only has

                <intent-filter>
                  <action android:name="android.intent.action.VIEW" />
                  <category android:name="android.intent.category.DEFAULT" />
                  <category android:name="android.intent.category.BROWSABLE" />
                  <!-- Accepts URIs that begin with YOUR_SCHEME://YOUR_HOST -->
                  <data
                    android:scheme="io.supabase.flutterquickstart" />
                </intent-filter>
    

    https://github.com/supabase-community/supabase-flutter-quickstart/blob/main/android/app/src/main/AndroidManifest.xml#L35

    Which one is correct?

    opened by DanMossa 1
  • This example vs `supabase/supabase/tree/master/examples/flutter-user-management`

    This example vs `supabase/supabase/tree/master/examples/flutter-user-management`

    Hello @dshukertjr!

    I wanted to start a discussion about the purpose of this repo vs the example in the supabase repo, in light of this issue https://github.com/supabase/supabase-flutter/issues/56

    I didn't realize this repo existed and was the basis of the tutorial. I assumed the project in the supabase repo was the reference project. I was planning to PR a revision of the example project and guide that doesn't "enforce" a state management approach as noted in the issue above. (I wouldn't mind your thoughts on this as it seems you wrote the initial guide, don't want to step on your toes!)

    If I proceed with that, would you want me to keep this project in sync with those changes? Or would you want one of the projects archived so we don't have 2 copies?

    opened by MisterJimson 1
A Flutter OAuth package for performing user authentication for your apps.

Flutter OAuth A Flutter OAuth package for performing user authentication for your apps. I've tested this with a small collection of APIs (Buffer, Stra

Joe Birch 173 Dec 9, 2022
By using Flutter Local Auth users can authenticate with Fingerprint & Touch ID in Flutter.

Flutter Tutorial - Fingerprint & Touch ID - Local Auth By using Flutter Local Auth users can authenticate with Fingerprint & Touch ID in Flutter. Soci

Johannes Milke 37 Dec 15, 2022
Email and Password Authentication In Flutter & Firebase in Flutter 2.2

email_password_flutter_firebase Email and Password Authentication In Flutter & Firebase in Flutter 2.2 Overview This email and password authentication

null 0 Mar 24, 2022
A Flutter plugin for allowing users to authenticate with native Android & iOS Facebook login SDKs.

flutter_facebook_login A Flutter plugin for using the native Facebook Login SDKs on Android and iOS. AndroidX support if you want to avoid AndroidX, u

Iiro Krankka 404 Nov 26, 2022
Flutter Plugin for Sign In with Apple

Apple Sign In - Flutter Plugin Access Sign In with Apple from Flutter. Platform support This plugin currently only supports iOS. There's a JavaScript

Tom Gilder 156 Dec 28, 2022
The Simplest way to Authenticate in Flutter

Most apps need to make API calls. Every API needs authentication, yet no developer wants to deal with authentication. Simple Auth embeds authenticatio

James Clancey 340 Dec 25, 2022
A Flutter wrapper for AppAuth iOS and Android SDKs

flutter_appauth A Flutter plugin that provides a wrapper for native AppAuth SDKs (https://appauth.io) used authenticating and authorizing users. The r

Michael Bui 230 Dec 21, 2022
An OAuth authentication system built in Flutter using Google OAuth.

An OAuth authentication system built in Flutter using Google OAuth.

Kaushal 0 Sep 20, 2021
This project is an example of Firebase authentication in a flutter

This project is an example of Firebase authentication in a flutter. This project shows how to implement a full authentication flow in Flutter, using sign Up with email and password, sign in with email and password, and reset password.

Nittin 4 Mar 11, 2022
A Flutter package that implements Google Sign In in pure Dart.

A Flutter package that implements Google Sign In in pure Dart. This package is compatible with google_sign_in plugin and works on all platforms Flutter supports but it's intended to be mainly used on Desktop.

Razvan Lung 10 Oct 26, 2022