Coffrify.Resources.Collections (Coffrify v0.9.0)

View Source

Collections — public landing pages bundling multiple transfers.

Summary

Functions

Add a transfer to the collection.

Create a collection.

Delete a collection.

Get a collection (with items and sections).

List collections.

List the items (transfers) of a collection.

Remove an item from a collection.

Update a collection.

Functions

add_item(client, id, opts)

@spec add_item(Coffrify.t(), String.t(), map() | keyword()) ::
  {:ok, map()} | {:error, Exception.t()}

Add a transfer to the collection.

create(client, opts)

@spec create(Coffrify.t(), map() | keyword()) ::
  {:ok, map()} | {:error, Exception.t()}

Create a collection.

delete(client, id)

@spec delete(Coffrify.t(), String.t()) :: {:ok, map()} | {:error, Exception.t()}

Delete a collection.

get(client, id)

@spec get(Coffrify.t(), String.t()) :: {:ok, map()} | {:error, Exception.t()}

Get a collection (with items and sections).

list(client)

@spec list(Coffrify.t()) :: {:ok, map()} | {:error, Exception.t()}

List collections.

list_items(client, id)

@spec list_items(Coffrify.t(), String.t()) :: {:ok, map()} | {:error, Exception.t()}

List the items (transfers) of a collection.

remove_item(client, collection_id, item_id)

@spec remove_item(Coffrify.t(), String.t(), String.t()) ::
  {:ok, map()} | {:error, Exception.t()}

Remove an item from a collection.

update(client, id, patch)

@spec update(Coffrify.t(), String.t(), map()) ::
  {:ok, map()} | {:error, Exception.t()}

Update a collection.