The bucket needs to be set to public, either via updateBucket() or by going to Storage on supabase.com/dashboard, clicking the overflow menu on a bucket and choosing "Make public"
RLS policy permissions required:
buckets table permissions: none
objects table permissions: none
Refer to the Storage guide on how access control works
Examples
Returns the URL for an asset in a public bucket
val url = supabase.storage["public-bucket"].publicUrl("folder/avatar1.png")
Returns the URL for an asset in a public bucket with transformations
val url = supabase.storage["public-bucket"].publicRenderUrl("folder/avatar1.png") \{
size(100, 100)
\}