supabase / supabase-flutter

Flutter integration for Supabase. This package makes it simple for developers to build secure and scalable products.
https://supabase.com/
MIT License
656 stars 154 forks source link

Allow to pass query params when invoking function #924

Closed grdsdev closed 1 month ago

grdsdev commented 1 month ago

Is your feature request related to a problem? Please describe. When invoking a function I want to be able to pass custom query params.

Describe the solution you'd like

final res = await supabase.functions
    .invoke(
        'hello',
        query: { 'key' : 'value' }
    )

We should be able to edit the Uri here to include the new query parameters accepted on the invoke() method.

Additional context https://github.com/supabase/supabase-swift/pull/376

DanMossa commented 1 month ago

Unless I misunderstood, you can already do this.

final data = await supabase
  .rpc('echo_city', params: { 'say': '👋' });

https://supabase.com/docs/reference/dart/rpc

Vinzent03 commented 1 month ago

@DanMossa You are talking about postgres functions which are completely different from the requested query parameters for edge functions.

dshukertjr commented 1 month ago

Let's keep this issue open for community members to work on 👍 I think it's an excellent opportunity for new people to contribute!