Class: Pushover::Limits

Inherits:
Object
  • Object
show all
Defined in:
lib/pushover/limits.rb

Overview

Limits provides operations for the account and team usage limits API.

Instance Method Summary collapse

Constructor Details

#initialize(client) ⇒ Limits

Returns a new instance of Limits.



4
5
6
# File 'lib/pushover/limits.rb', line 4

def initialize(client)
  @client = client
end

Instance Method Details

#getResponse

Retrieve the current monthly message usage limits.

Returns:

  • (Response)

    the Pushover API response



10
11
12
13
14
15
16
# File 'lib/pushover/limits.rb', line 10

def get
  response = @client.connection.get(
    path:  '/1/apps/limits.json',
    query: { token: @client.token }
  )
  Response.create_from_excon_response(response)
end