ExShopify v0.2.0 ExShopify.Theme

The look and feel template of a shop.

Summary

Functions

Create a new theme

Delete a theme from the database

Receive a single theme

Receive a list of all themes

Modify an existing theme

Types

theme_plural()
theme_plural() :: {:ok, [%ExShopify.Theme{created_at: term, id: term, name: term, previewable: term, processing: term, role: term, updated_at: term}], %ExShopify.Meta{api_call_limit: term}}
theme_singular()
theme_singular() :: {:ok, %ExShopify.Theme{created_at: term, id: term, name: term, previewable: term, processing: term, role: term, updated_at: term}, %ExShopify.Meta{api_call_limit: term}}

Functions

create(session, params)
create(%ExShopify.Session{access_token: term, api_key: term, domain: term, port: term, protocol: term, secret: term, shop_name: term, shop_url: term}, map) ::
  theme_singular |
  ExShopify.Resource.error

Create a new theme.

Examples

iex> params = %{
...>   name: "Lemongrass",
...>   src: "http://themes.shopify.com/theme.zip",
...>   role: "main"
...> }

iex> ExShopify.Theme.create(session, params)
{:ok, theme, meta}
delete(session, id)
delete(%ExShopify.Session{access_token: term, api_key: term, domain: term, port: term, protocol: term, secret: term, shop_name: term, shop_url: term}, integer | String.t) ::
  ExShopify.Resource.meta_only |
  ExShopify.Resource.error

Delete a theme from the database.

Examples

iex> ExShopify.Theme.delete(session, 752253240)
{:ok, meta}
find(session, id)
find(%ExShopify.Session{access_token: term, api_key: term, domain: term, port: term, protocol: term, secret: term, shop_name: term, shop_url: term}, integer | String.t) ::
  theme_singular |
  ExShopify.Resource.error
find(session, id, params)
find(%ExShopify.Session{access_token: term, api_key: term, domain: term, port: term, protocol: term, secret: term, shop_name: term, shop_url: term}, integer | String.t, map) ::
  theme_singular |
  ExShopify.Resource.error

Receive a single theme.

Examples

iex> ExShopify.Theme.find(session, 828155753)
{:ok, theme, meta}
list(session)
list(%ExShopify.Session{access_token: term, api_key: term, domain: term, port: term, protocol: term, secret: term, shop_name: term, shop_url: term}) ::
  theme_plural |
  ExShopify.Resource.error
list(session, params)
list(%ExShopify.Session{access_token: term, api_key: term, domain: term, port: term, protocol: term, secret: term, shop_name: term, shop_url: term}, map) ::
  theme_plural |
  ExShopify.Resource.error

Receive a list of all themes.

Examples

iex> ExShopify.Theme.list(session)
{:ok, themes, meta}
update(session, id, params)
update(%ExShopify.Session{access_token: term, api_key: term, domain: term, port: term, protocol: term, secret: term, shop_name: term, shop_url: term}, integer | String.t, map) ::
  theme_singular |
  ExShopify.Resource.error

Modify an existing theme.

Examples

iex> params = %{name: "Experimental"}

iex> ExShopify.Theme.update(session, 752253240, params)
{:ok, theme, meta}