View Source ActiveCampaign.Deal (active_campaign v0.3.0)

Documentation for ActiveCampaign.Deal.

Link to this section Summary

Functions

Bulk Update Deal Owners

Create a deal

Create a deal note

Delete a deal

Retrieve a deal

List all deals

Update a deal

Update a deal note

Link to this section Functions

@spec bulk([map()]) :: {:ok, map()} | {:error, any()}

Bulk Update Deal Owners

examples

Examples

iex> ActiveCampaign.Deal.bulk()
{:ok, %{...}}
@spec create(map()) :: {:ok, map()} | {:error, any()}

Create a deal

examples

Examples

iex> ActiveCampaign.Deal.create(%{contact: "51", ...})
{:ok, %{...}}
@spec create_note(integer(), map()) :: {:ok, map()} | {:error, any()}

Create a deal note

examples

Examples

iex> ActiveCampaign.Deal.create_note(123, %{note: "Note for the deal"})
{:ok, %{...}}
@spec delete(integer()) :: {:ok, map()} | {:error, any()}

Delete a deal

examples

Examples

iex> ActiveCampaign.Deal.delete(123)
{:ok, %{...}}
@spec get(integer()) :: {:ok, map()} | {:error, any()}

Retrieve a deal

examples

Examples

iex> ActiveCampaign.Deal.get(123)
{:ok, %{"owner" => "1", ...}}
@spec list(map()) :: {:ok, map()} | {:error, any()}

List all deals

examples

Examples

iex> ActiveCampaign.Deal.list()
{:ok, %{...}}
@spec update(integer(), map()) :: {:ok, map()} | {:error, any()}

Update a deal

examples

Examples

iex> ActiveCampaign.Deal.update(123, %{contact: "51", ...})
{:ok, %{...}}
Link to this function

update_note(id, note_id, note)

View Source
@spec update_note(integer(), integer(), map()) :: {:ok, map()} | {:error, any()}

Update a deal note

examples

Examples

iex> ActiveCampaign.Deal.update_note(123, %{note: "Update with more info"})
{:ok, %{...}}