guss v0.1.6 Guss View Source
Guss generates Signed URLs for Google Cloud Storage.
Signed URLs provide a mechanism for query-string authentication for storage objects. For more information, see the Storage Docs for Signed URLs.
Link to this section Summary
Functions
Returns a new Guss.Resource for a DELETE request.
Returns an expiration value for a future timestamp, with optional granularity.
Returns a new Guss.Resource for a GET request.
Returns a new Guss.Resource.
Returns a new Guss.Resource.
Returns a new Guss.Resource for a POST request.
Returns a new Guss.Resource for a PUT request.
Converts a Guss.Resource into a Signed URL.
Link to this section Functions
delete(bucket, objectname, opts \\ [])
View Sourcedelete(binary(), binary(), keyword()) :: Guss.Resource.t()
Returns a new Guss.Resource for a DELETE request.
Returns an expiration value for a future timestamp, with optional granularity.
By default, expires_in/1 expects a value in :seconds.
To specify a different granularity, pass the value as a tuple,
for instance: {1, :hour} or {7, :days}
Valid granularities are :seconds, :hours, and :days, as well as
their singular variants.
get(bucket, objectname, opts \\ [])
View Sourceget(binary(), binary(), keyword()) :: Guss.Resource.t()
Returns a new Guss.Resource for a GET request.
new(bucket, objectname, opts \\ [])
View Sourcenew(binary(), binary(), keyword()) :: Guss.Resource.t()
Returns a new Guss.Resource.
new(verb, bucket, objectname, opts)
View Sourcenew(atom(), binary(), binary(), keyword()) :: Guss.Resource.t()
Returns a new Guss.Resource.
Returns a new Guss.Resource for a POST request.
put(bucket, objectname, opts \\ [])
View Sourceput(binary(), binary(), keyword()) :: Guss.Resource.t()
Returns a new Guss.Resource for a PUT request.
sign(resource, opts \\ [])
View Sourcesign(resource :: Guss.Resource.t(), opts :: keyword()) :: {:error, {atom(), any()}} | {:ok, binary()}
Converts a Guss.Resource into a Signed URL.