The Postgres development platform. Supabase gives you a dedicated Postgres database to build your web, mobile, and AI applications.
TypeScript aialternativeauthdatabasedenoembeddingsexamplefirebasenextjsoauth2pgvectorpostgispostgrespostgresqlpostgrestrealtimesupabasevectorswebsockets
feat: update swift yml
[email protected]3a08b4967c72
diff --git a/spec/supabase_swift_v1.yml b/spec/supabase_swift_v1.ymlindex 4b6b769ef17..f4a52af1709 100644--- a/spec/supabase_swift_v1.yml+++ b/spec/supabase_swift_v1.yml@@ -137,7 +137,7 @@ functions:$ref: '@supabase/postgrest-js."lib/PostgrestQueryBuilder".PostgrestQueryBuilder.insert'notes: |- By default, every time you run `insert()`, the client library will make a `select` to return the full record.- This is convenient, but it can also cause problems if your policies are not configured to allow the `select` operation.+ This is convenient, but it can also cause problems if your Policies are not configured to allow the `select` operation.If you are using Row Level Security and you are encountering problems, try setting the `returning` param to `minimal`.examples:- id: create-a-record@@ -190,7 +190,7 @@ functions:isSpotlight: truecode: |```js- let toUpdate = CountryModel(name: "Australia")+ let toUpdate = CountryModel(name: "Austrailia")try await client.database.from("countries").update(toUpdate)@@ -201,7 +201,7 @@ functions:name: Update a record and return itcode: |```js- let toUpdate = CountryModel(name: "Australia")+ let toUpdate = CountryModel(name: "Austrailia")try await client.database.from("countries").update(toUpdate, returning: .representation)@@ -364,7 +364,7 @@ functions:Filters can be used on `select()`, `update()`, and `delete()` queries.- If a database function returns a table response, you can also apply filters.+ If a Database function returns a table response, you can also apply filters.examples:- id: applying-filtersname: Applying Filters@@ -1108,8 +1108,6 @@ functions:- id: range-lttitle: rangeLt()- description: |- Only relevant for range columns. Match only rows where every element in column is less than any element in range.examples:- id: with-selectname: With `select()`@@ -1122,48 +1120,9 @@ functions:.rangeLt(column: "during", value: "[2000-01-02 08:30, 2000-01-02 09:30]").execute()```- data:- sql: |- ```sql- create table- reservations (- id int8 primary key,- room_name text,- during tsrange- );-- insert into- reservations (id, room_name, during)- values- (1, 'Emerald', '[2000-01-01 13:00, 2000-01-01 15:00)'),- (2, 'Topaz', '[2000-01-02 09:00, 2000-01-02 10:00)');- ```- response: |- ```json- {- "data": [- {- "id": 1,- "room_name": "Emerald",- "during": "[\"2000-01-01 13:00:00\",\"2000-01-01 15:00:00\")"- }- ],- "status": 200,- "statusText": "OK"- }- ```- description: |- Postgres supports a number of [range- types](https://www.postgresql.org/docs/current/rangetypes.html). You- can filter on range columns using the string representation of range- values.- hideCodeBlock: true- id: range-gttitle: rangeGt()- description: |- Only relevant for range columns. Match only rows where every element in column is greater than any element in range.-examples:- id: with-selectname: With `select()`@@ -1176,47 +1135,9 @@ functions:.rangeGt(column: "during", value: "[2000-01-02 08:30, 2000-01-02 09:30]").execute()```- data:- sql: |- ```sql- create table- reservations (- id int8 primary key,- room_name text,- during tsrange- );-- insert into- reservations (id, room_name, during)- values- (1, 'Emerald', '[2000-01-01 13:00, 2000-01-01 15:00)'),- (2, 'Topaz', '[2000-01-02 09:00, 2000-01-02 10:00)');- ```- response: |- ```json- {- "data": [- {- "id": 2,- "room_name": "Topaz",- "during": "[\"2000-01-02 09:00:00\",\"2000-01-02 10:00:00\")"- }- ],- "status": 200,- "statusText": "OK"- }- ```- description: |- Postgres supports a number of [range- types](https://www.postgresql.org/docs/current/rangetypes.html). You- can filter on range columns using the string representation of range- values.- hideCodeBlock: true- id: range-gtetitle: rangeGte()- description: |- Only relevant for range columns. Match only rows where every element in column is either contained in range or greater than any element in range.examples:- id: with-selectname: With `select()`@@ -1229,48 +1150,9 @@ functions:.rangeGte(column: "during", value: "[2000-01-02 08:30, 2000-01-02 09:30]").execute()```- data:- sql: |- ```sql- create table- reservations (- id int8 primary key,- room_name text,- during tsrange- );-- insert into- reservations (id, room_name, during)- values- (1, 'Emerald', '[2000-01-01 13:00, 2000-01-01 15:00)'),- (2, 'Topaz', '[2000-01-02 09:00, 2000-01-02 10:00)');- ```- response: |- ```json- {- "data": [- {- "id": 2,- "room_name": "Topaz",- "during": "[\"2000-01-02 09:00:00\",\"2000-01-02 10:00:00\")"- }- ],- "status": 200,- "statusText": "OK"- }- ```- description: |- Postgres supports a number of [range- types](https://www.postgresql.org/docs/current/rangetypes.html). You- can filter on range columns using the string representation of range- values.- hideCodeBlock: true- id: range-ltetitle: rangeLte()- description: |- Only relevant for range columns. Match only rows where every element in column is either contained in range or less than any element in range.-$ref: '@supabase/postgrest-js.PostgrestFilterBuilder.rangeLte'examples:- id: with-select@@ -1284,42 +1166,6 @@ functions:.rangeLte(column: "during", value: "[2000-01-02 08:30, 2000-01-02 09:30]").execute()```- data:- sql: |- ```sql- create table- reservations (- id int8 primary key,- room_name text,- during tsrange- );-- insert into- reservations (id, room_name, during)- values- (1, 'Emerald', '[2000-01-01 13:00, 2000-01-01 15:00)'),- (2, 'Topaz', '[2000-01-02 09:00, 2000-01-02 10:00)');- ```- response: |- ```json- {- "data": [- {- "id": 1,- "room_name": "Emerald",- "during": "[\"2000-01-01 13:00:00\",\"2000-01-01 15:00:00\")"- }- ],- "status": 200,- "statusText": "OK"- }- ```- description: |- Postgres supports a number of [range- types](https://www.postgresql.org/docs/current/rangetypes.html). You- can filter on range columns using the string representation of range- values.- hideCodeBlock: true- id: range-adjacenttitle: rangeAdjacent()@@ -1335,38 +1181,6 @@ functions:.rangeAdjacent(column: "during", value: "[2000-01-02 08:30, 2000-01-02 09:30]").execute()```- data:- sql: |- ```sql- create table- reservations (- id int8 primary key,- room_name text,- during tsrange- );-- insert into- reservations (id, room_name, during)- values- (1, 'Emerald', '[2000-01-01 13:00, 2000-01-01 15:00)'),- (2, 'Topaz', '[2000-01-02 09:00, 2000-01-02 10:00)');- ```- response: |- ```json- {- "data": [- {- "id": 1,- "room_name": "Emerald",- "during": "[\"2000-01-01 13:00:00\",\"2000-01-01 15:00:00\")"- }- ],- "status": 200,- "statusText": "OK"- }- ```-- hideCodeBlock: true- id: overlapstitle: overlaps()@@ -1642,7 +1456,7 @@ functions:Filters work on the row level—they allows you to return rows thatonly match certain conditions without changing the shape of the rows.Modifiers are everything that don't fit that definition—allowing you to- change the format of the response (e.g. returning a CSV string).+ change the format of the response (e.g., returning a CSV string).Modifiers must be specified after filters. Some modifiers only apply forqueries that return rows (e.g., `select()` or `rpc()` on a function that@@ -2045,7 +1859,7 @@ functions:notes: |- Requires either an email or phone number.- This method is used for passwordless sign-ins where a OTP is sent to the user's email or phone number.- - If the user doesn't exist, `signInWithOtp()` will signup the user instead. To restrict this behavior, you can set `shouldCreateUser` in `SignInWithPasswordlessCredentials.options` to `false`.+ - If the user doesn't exist, `signInWithOtp()` will signup the user instead. To restrict this behaviour, you can set `shouldCreateUser` in `SignInWithPasswordlessCredentials.options` to `false`.- If you're using an email, you can configure whether you want the user to receive a magiclink or a OTP.- If you're using phone, you can configure whether you want the user to receive a OTP.- The magic link's destination URL is determined by the [`SITE_URL`](/docs/reference/auth/config#site_url).@@ -2082,7 +1896,7 @@ functions:description: |- getOAuthSignInURL() provides the URL which needs to be opened in a SFSafariViewController instance.- The redirectTo URL needs to be setup correctly in your project under Authentication -> URL Configuration -> Redirect URLs.- - For full implementation example check out [Supabase-Swift Github](https://github.com/supabase-community/supabase-swift#social-login-implementation).+ - For full implementation example check out [Supabase-Swift Github](https://github.com/supabase-community/supabase-swift#social-login-implementation).code: |```jslet url = try await supabase.auth@@ -2099,7 +1913,7 @@ functions:- See [redirect URLs and wildcards](/docs/guides/auth/overview#redirect-urls-and-wildcards) to add additional redirect URLs to your project.- getOAuthSignInURL() provides the URL which needs to be opened in a SFSafariViewController instance.- The redirectTo URL needs to be setup correctly in your project under Authentication -> URL Configuration -> Redirect URLs.- - For full implementation example check out [Supabase-Swift Github](https://github.com/supabase-community/supabase-swift#social-login-implementation).+ - For full implementation example check out [Supabase-Swift Github](https://github.com/supabase-community/supabase-swift#social-login-implementation).code: |```jslet url = try await supabase.auth@@ -2191,7 +2005,7 @@ functions:$ref: '@supabase/gotrue-js.GoTrueClient.updateUser'notes: |- In order to use the `updateUser()` method, the user needs to be signed in first.- - By default, email updates sends a confirmation link to both the user's current and new email.+ - By Default, email updates sends a confirmation link to both the user's current and new email.To only send a confirmation link to the user's new email, disable **Secure email change** in your project's [email auth provider settings](https://app.supabase.com/project/_/auth/providers).examples:- id: update-the-email-for-an-authenticated-user@@ -2431,8 +2245,7 @@ functions:Unsubscribes and removes Realtime channel from Realtime client.title: 'removeChannel()'notes: |- - Removing a channel is a great way to maintain the performance of your project's Realtime service as well as your database if you're listening to Postgres changes.- - Supabase will automatically handle cleanup 30 seconds after a client is disconnected, but unused channels may cause degradation as more clients are simultaneously subscribed.+ - Removing a channel is a great way to maintain the performance of your project's Realtime service as well as your database if you're listening to Postgres changes. Supabase will automatically handle cleanup 30 seconds after a client is disconnected, but unused channels may cause degradation as more clients are simultaneously subscribed.examples:- id: removes-a-channelname: Remove a channel@@ -2685,3 +2498,4 @@ functions:.from(id: "avatars").list()```+