Search documentation of tiger_stripe

# Stripe.Services.Billing.AlertService (tiger_stripe v0.1.1)

Copy Markdown View Source

ThresholdsResourceAlert

A billing alert is a resource that notifies you when a certain usage threshold on a meter is crossed. For example, you might create a billing alert to notify you when a certain user made 100 API requests.

## Summary

### Functions

activate(client, id, params \\ %{}, opts \\ [])

Activate a billing alert

archive(client, id, params \\ %{}, opts \\ [])

Archive a billing alert

create(client, params \\ %{}, opts \\ [])

Create a billing alert

deactivate(client, id, params \\ %{}, opts \\ [])

Deactivate a billing alert

list(client, params \\ %{}, opts \\ [])

List billing alerts

retrieve(client, id, params \\ %{}, opts \\ [])

Retrieve a billing alert

## Functions

# activate(client, id, params \\ %{}, opts \\ [])

    @spec activate(Stripe.Client.t(), String.t(), map(), keyword()) ::
      {:ok, term()} | {:error, Stripe.Error.t()}

Activate a billing alert

Reactivates this alert, allowing it to trigger again.

# archive(client, id, params \\ %{}, opts \\ [])

    @spec archive(Stripe.Client.t(), String.t(), map(), keyword()) ::
      {:ok, term()} | {:error, Stripe.Error.t()}

Archive a billing alert

Archives this alert, removing it from the list view and APIs. This is non-reversible.

# create(client, params \\ %{}, opts \\ [])

    @spec create(Stripe.Client.t(), map(), keyword()) ::
      {:ok, term()} | {:error, Stripe.Error.t()}

Create a billing alert

Creates a billing alert

# deactivate(client, id, params \\ %{}, opts \\ [])

    @spec deactivate(Stripe.Client.t(), String.t(), map(), keyword()) ::
      {:ok, term()} | {:error, Stripe.Error.t()}

Deactivate a billing alert

Deactivates this alert, preventing it from triggering.

# list(client, params \\ %{}, opts \\ [])

    @spec list(Stripe.Client.t(), map(), keyword()) ::
      {:ok, term()} | {:error, Stripe.Error.t()}

List billing alerts

Lists billing active and inactive alerts

# retrieve(client, id, params \\ %{}, opts \\ [])

    @spec retrieve(Stripe.Client.t(), String.t(), map(), keyword()) ::
      {:ok, term()} | {:error, Stripe.Error.t()}

Retrieve a billing alert

Retrieves a billing alert given an ID