recurly-client-0.1.0.0: Client for Recurly subscription management
Safe HaskellSafe-Inferred
LanguageHaskell2010

RecurlyClient.Operations.Create_usage

Description

Contains the different functions to run the operation create_usage

Synopsis

Documentation

create_usage Source #

Arguments

:: forall m. MonadHTTP m 
=> Create_usageParameters

Contains all available parameters of this operation (query and path parameters)

-> UsageCreate

The request body to send

-> ClientT m (Response Create_usageResponse)

Monadic computation which returns the result of the operation

POST /subscriptions/{subscription_id}/add_ons/{add_on_id}/usage

Log a usage record on this subscription add-on

data Create_usageParameters Source #

Defines the object schema located at paths./subscriptions/{subscription_id}/add_ons/{add_on_id}/usage.POST.parameters in the specification.

Constructors

Create_usageParameters 

Fields

  • create_usageParametersPathAdd_on_id :: Text

    pathAdd_on_id: Represents the parameter named 'add_on_id'

    Add-on ID or code. For ID no prefix is used e.g. `e28zov4fw0v2`. For code use prefix `code-`, e.g. `code-gold`.

  • create_usageParametersPathSubscription_id :: Text

    pathSubscription_id: Represents the parameter named 'subscription_id'

    Subscription ID or UUID. For ID no prefix is used e.g. `e28zov4fw0v2`. For UUID use prefix `uuid-`, e.g. `uuid-123457890`.

data Create_usageResponse Source #

Represents a response of the operation create_usage.

The response constructor is chosen by the status code of the response. If no case matches (no specific case for the response code, no range case, no default case), Create_usageResponseError is used.

Constructors

Create_usageResponseError String

Means either no matching case available or a parse error

Create_usageResponse201 Usage

The created usage record.

Create_usageResponse400 Error

Invalid or unpermitted parameter.

Create_usageResponse404 Error

Incorrect site or subscription ID or add-on id.

Create_usageResponse422 Error

A validation error.

Create_usageResponseDefault Error

Unexpected error.

create_usageWithConfiguration Source #

Arguments

:: forall m. MonadHTTP m 
=> Configuration

The configuration to use in the request

-> Create_usageParameters

Contains all available parameters of this operation (query and path parameters)

-> UsageCreate

The request body to send

-> m (Response Create_usageResponse)

Monadic computation which returns the result of the operation

POST /subscriptions/{subscription_id}/add_ons/{add_on_id}/usage

The same as create_usage but accepts an explicit configuration.

create_usageRaw Source #

Arguments

:: forall m. MonadHTTP m 
=> Create_usageParameters

Contains all available parameters of this operation (query and path parameters)

-> UsageCreate

The request body to send

-> ClientT m (Response ByteString)

Monadic computation which returns the result of the operation

POST /subscriptions/{subscription_id}/add_ons/{add_on_id}/usage

The same as create_usage but returns the raw ByteString.

create_usageWithConfigurationRaw Source #

Arguments

:: forall m. MonadHTTP m 
=> Configuration

The configuration to use in the request

-> Create_usageParameters

Contains all available parameters of this operation (query and path parameters)

-> UsageCreate

The request body to send

-> m (Response ByteString)

Monadic computation which returns the result of the operation

POST /subscriptions/{subscription_id}/add_ons/{add_on_id}/usage

The same as create_usage but accepts an explicit configuration and returns the raw ByteString.