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

RecurlyClient.Operations.List_subscriptions

Description

Contains the different functions to run the operation list_subscriptions

Synopsis

Documentation

list_subscriptions Source #

Arguments

:: forall m. MonadHTTP m 
=> List_subscriptionsParameters

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

-> ClientT m (Response List_subscriptionsResponse)

Monadic computation which returns the result of the operation

GET /subscriptions

See the Pagination Guide to learn how to use pagination in the API and Client Libraries.

data List_subscriptionsParameters Source #

Defines the object schema located at paths./subscriptions.GET.parameters in the specification.

Constructors

List_subscriptionsParameters 

Fields

  • list_subscriptionsParametersQueryBegin_time :: Maybe JsonDateTime

    queryBegin_time: Represents the parameter named 'begin_time'

    Inclusively filter by begin_time when `sort=created_at` or `sort=updated_at`. **Note:** this value is an ISO8601 timestamp. A partial timestamp that does not include a time zone will default to UTC.

  • list_subscriptionsParametersQueryEnd_time :: Maybe JsonDateTime

    queryEnd_time: Represents the parameter named 'end_time'

    Inclusively filter by end_time when `sort=created_at` or `sort=updated_at`. **Note:** this value is an ISO8601 timestamp. A partial timestamp that does not include a time zone will default to UTC.

  • list_subscriptionsParametersQueryIds :: Maybe [Text]

    queryIds: Represents the parameter named 'ids'

    Filter results by their IDs. Up to 200 IDs can be passed at once using commas as separators, e.g. `ids=h1at4d57xlmy,gyqgg0d3v9n1,jrsm5b4yefg6`.

    • *Important notes:**
    • The `ids` parameter cannot be used with any other ordering or filtering parameters (`limit`, `order`, `sort`, `begin_time`, `end_time`, etc)
    • Invalid or unknown IDs will be ignored, so you should check that the results correspond to your request.
    • Records are returned in an arbitrary order. Since results are all returned at once you can sort the records yourself.
  • list_subscriptionsParametersQueryLimit :: Maybe Int

    queryLimit: Represents the parameter named 'limit'

    Limit number of records 1-200.

    Constraints:

    • Maxium of 200.0
    • Minimum of 1.0
  • list_subscriptionsParametersQueryOrder :: Maybe List_subscriptionsParametersQueryOrder

    queryOrder: Represents the parameter named 'order'

    Sort order.

  • list_subscriptionsParametersQuerySort :: Maybe List_subscriptionsParametersQuerySort

    querySort: Represents the parameter named 'sort'

    Sort field. You *really* only want to sort by `updated_at` in ascending order. In descending order updated records will move behind the cursor and could prevent some records from being returned.

  • list_subscriptionsParametersQueryState :: Maybe List_subscriptionsParametersQueryState

    queryState: Represents the parameter named 'state'

    Filter by state.

    • When `state=active`, `state=canceled`, `state=expired`, or `state=future`, subscriptions with states that match the query and only those subscriptions will be returned.
    • When `state=in_trial`, only subscriptions that have a trial_started_at date earlier than now and a trial_ends_at date later than now will be returned.
    • When `state=live`, only subscriptions that are in an active, canceled, or future state or are in trial will be returned.

data List_subscriptionsParametersQueryOrder Source #

Defines the enum schema located at paths./subscriptions.GET.parameters.properties.queryOrder in the specification.

Represents the parameter named 'order'

Sort order.

Constructors

List_subscriptionsParametersQueryOrderOther Value

This case is used if the value encountered during decoding does not match any of the provided cases in the specification.

List_subscriptionsParametersQueryOrderTyped Text

This constructor can be used to send values to the server which are not present in the specification yet.

List_subscriptionsParametersQueryOrderEnumAsc

Represents the JSON value "asc"

List_subscriptionsParametersQueryOrderEnumDesc

Represents the JSON value "desc"

data List_subscriptionsParametersQuerySort Source #

Defines the enum schema located at paths./subscriptions.GET.parameters.properties.querySort in the specification.

Represents the parameter named 'sort'

Sort field. You *really* only want to sort by `updated_at` in ascending order. In descending order updated records will move behind the cursor and could prevent some records from being returned.

Constructors

List_subscriptionsParametersQuerySortOther Value

This case is used if the value encountered during decoding does not match any of the provided cases in the specification.

List_subscriptionsParametersQuerySortTyped Text

This constructor can be used to send values to the server which are not present in the specification yet.

List_subscriptionsParametersQuerySortEnumCreated_at

Represents the JSON value "created_at"

List_subscriptionsParametersQuerySortEnumUpdated_at

Represents the JSON value "updated_at"

data List_subscriptionsParametersQueryState Source #

Defines the enum schema located at paths./subscriptions.GET.parameters.properties.queryState in the specification.

Represents the parameter named 'state'

Filter by state.

  • When `state=active`, `state=canceled`, `state=expired`, or `state=future`, subscriptions with states that match the query and only those subscriptions will be returned.
  • When `state=in_trial`, only subscriptions that have a trial_started_at date earlier than now and a trial_ends_at date later than now will be returned.
  • When `state=live`, only subscriptions that are in an active, canceled, or future state or are in trial will be returned.

Constructors

List_subscriptionsParametersQueryStateOther Value

This case is used if the value encountered during decoding does not match any of the provided cases in the specification.

List_subscriptionsParametersQueryStateTyped Text

This constructor can be used to send values to the server which are not present in the specification yet.

List_subscriptionsParametersQueryStateEnumActive

Represents the JSON value "active"

List_subscriptionsParametersQueryStateEnumCanceled

Represents the JSON value "canceled"

List_subscriptionsParametersQueryStateEnumExpired

Represents the JSON value "expired"

List_subscriptionsParametersQueryStateEnumFuture

Represents the JSON value "future"

List_subscriptionsParametersQueryStateEnumIn_trial

Represents the JSON value "in_trial"

List_subscriptionsParametersQueryStateEnumLive

Represents the JSON value "live"

data List_subscriptionsResponse Source #

Represents a response of the operation list_subscriptions.

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), List_subscriptionsResponseError is used.

Constructors

List_subscriptionsResponseError String

Means either no matching case available or a parse error

List_subscriptionsResponse200 SubscriptionList

A list of the site's subscriptions.

List_subscriptionsResponse400 Error

Invalid or unpermitted parameter.

List_subscriptionsResponse404 Error

Incorrect site ID.

List_subscriptionsResponseDefault Error

Unexpected error.

list_subscriptionsWithConfiguration Source #

Arguments

:: forall m. MonadHTTP m 
=> Configuration

The configuration to use in the request

-> List_subscriptionsParameters

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

-> m (Response List_subscriptionsResponse)

Monadic computation which returns the result of the operation

GET /subscriptions

The same as list_subscriptions but accepts an explicit configuration.

list_subscriptionsRaw Source #

Arguments

:: forall m. MonadHTTP m 
=> List_subscriptionsParameters

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

-> ClientT m (Response ByteString)

Monadic computation which returns the result of the operation

GET /subscriptions

The same as list_subscriptions but returns the raw ByteString.

list_subscriptionsWithConfigurationRaw Source #

Arguments

:: forall m. MonadHTTP m 
=> Configuration

The configuration to use in the request

-> List_subscriptionsParameters

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

-> m (Response ByteString)

Monadic computation which returns the result of the operation

GET /subscriptions

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