View Source ExPipedrive.DealParticipants (ex_pipedrive v0.2.0)

API v1 shim for Pipedrive deal participants.

Deal participants have no /api/v2 equivalent yet; all functions here explicitly route to /api/v1/deals/:id/participants.

Example

{:ok, %PagedResult{data: participants}} = ExPipedrive.DealParticipants.list(client, deal_id)
{:ok, participant} = ExPipedrive.DealParticipants.add(client, deal_id, person_id)
{:ok, :ok} = ExPipedrive.DealParticipants.delete(client, deal_id, participant.id)

Summary

Functions

Adds a participant via POST /api/v1/deals/:id/participants.

Removes a participant via DELETE /api/v1/deals/:id/participants/:deal_participant_id.

Lists participants via GET /api/v1/deals/:id/participants.

Functions

Link to this function

add(client, deal_id, person_id)

View Source

Adds a participant via POST /api/v1/deals/:id/participants.

Link to this function

delete(client, deal_id, deal_participant_id)

View Source
@spec delete(Tesla.Client.t(), term(), term()) ::
  {:ok, :ok} | {:error, ExPipedrive.Error.t()}

Removes a participant via DELETE /api/v1/deals/:id/participants/:deal_participant_id.

Returns {:ok, :ok}.

Link to this function

list(client, deal_id, opts \\ [])

View Source
@spec list(Tesla.Client.t(), term(), keyword()) ::
  {:ok, ExPipedrive.PagedResult.t()} | {:error, ExPipedrive.Error.t()}

Lists participants via GET /api/v1/deals/:id/participants.

Options: :start (default 0), :limit.