zen_ex v0.4.0 ZenEx.HelpCenter.Model.Section

Provides functions to operate Zendesk HelpCenter Section.

Summary

Functions

Create section

Delete section specified by id

List sections specified by bcp-47 code of locale (es-419, en-us, pr-br) or locale and category_id

Show section specified by bcp-47 code of locale (es-419, en-us, pr-br) and id

Update section specified by id

Functions

create(section)
create(%ZenEx.HelpCenter.Entity.Section{category_id: term, created_at: term, description: term, html_url: term, id: term, locale: term, name: term, outdated: term, position: term, source_locale: term, translation_ids: term, updated_at: term, url: term}) :: %ZenEx.HelpCenter.Entity.Section{category_id: term, created_at: term, description: term, html_url: term, id: term, locale: term, name: term, outdated: term, position: term, source_locale: term, translation_ids: term, updated_at: term, url: term}

Create section.

Examples

iex> ZenEx.HelpCenter.Model.Section.create(%ZenEx.HelpCenter.Entity.Section{name: xxx, locale: xxx, ...})
%ZenEx.HelpCenter.Entity.Section{name: xxx, locale: xxx, ...}
destroy(id)
destroy(integer) :: :ok | :error

Delete section specified by id.

Examples

iex> ZenEx.HelpCenter.Model.Section.destroy(1)
:ok
list(locale, category_id_or_opts \\ [], opts \\ [])

List sections specified by bcp-47 code of locale (es-419, en-us, pr-br) or locale and category_id.

Examples

iex> ZenEx.HelpCenter.Model.Section.list("en-us")
%ZenEx.Collection{}

iex> ZenEx.HelpCenter.Model.Section.list("en-us", 1)
%ZenEx.Collection{}
show(locale, id)
show(String.t, integer) :: %ZenEx.HelpCenter.Entity.Section{category_id: term, created_at: term, description: term, html_url: term, id: term, locale: term, name: term, outdated: term, position: term, source_locale: term, translation_ids: term, updated_at: term, url: term}

Show section specified by bcp-47 code of locale (es-419, en-us, pr-br) and id.

Examples

iex> ZenEx.HelpCenter.Model.Section.show("en-us", 1)
%ZenEx.HelpCenter.Entity.Section{id: 1, name: xxx, locale: "en-us", ...}
update(section)
update(%ZenEx.HelpCenter.Entity.Section{category_id: term, created_at: term, description: term, html_url: term, id: term, locale: term, name: term, outdated: term, position: term, source_locale: term, translation_ids: term, updated_at: term, url: term}) :: %ZenEx.HelpCenter.Entity.Section{category_id: term, created_at: term, description: term, html_url: term, id: term, locale: term, name: term, outdated: term, position: term, source_locale: term, translation_ids: term, updated_at: term, url: term}

Update section specified by id.

Examples

iex> ZenEx.HelpCenter.Model.Section.update(%ZenEx.HelpCenter.Entity.Section{id: 1, name: xxx, locale: xxx, ...})
%ZenEx.HelpCenter.Entity.Section{id: 1, name: xxx, locale: xxx, ...}