Class: TACore::App

Inherits:
Auth show all
Defined in:
lib/tacore/app.rb

Overview

> Application class methods

Instance Attribute Summary

Attributes inherited from Auth

#client, #token

Attributes inherited from Configuration

#api_key, #api_url, #client_id, #client_secret

Class Method Summary collapse

Methods inherited from Auth

login, request

Methods inherited from Configuration

#initialize

Constructor Details

This class inherits a constructor from TACore::Configuration

Class Method Details

.all(token) ⇒ Object

Get Details on all Applications

Parameters:

  • token (String)

    Application Token after Authentication

Returns:

  • (Object)

    in JSON format



14
15
16
# File 'lib/tacore/app.rb', line 14

def self.all(token)
  request(:get, '/application/all', {}, {"token": token})
end

.devices(token) ⇒ Object

Get all Iris devices assigned to your application

Parameters:

  • token (String)

    Application Token after Authentication

Returns:

  • (Object)

    in JSON format



21
22
23
# File 'lib/tacore/app.rb', line 21

def self.devices(token)
  request(:get, '/application/devices', {}, {"token": token})
end

.find(token) ⇒ Object

Get details on a specific application by token

Parameters:

  • token (String)

    Application Token after Authentication

Returns:

  • (Object)

    in JSON format



7
8
9
# File 'lib/tacore/app.rb', line 7

def self.find(token)
  request(:get, '/application/',{}, {"token": token})
end

.gateways(token) ⇒ Object

Get all Cirrus gateways assigned to your application

Parameters:

  • token (String)

    Application Token after Authentication

Returns:

  • (Object)

    in JSON format



28
29
30
# File 'lib/tacore/app.rb', line 28

def self.gateways(token)
  request(:get, '/application/gateways', {}, {"token": token})
end