Class: Onepost::Client

Inherits:
Object
  • Object
show all
Includes:
Authorization, AuthorizedPage, Event, Image, Post, PostIntent, Provider, SocialPost, Webhook
Defined in:
lib/onepost/client.rb

Constant Summary collapse

RAPID_API_HOST =
"onepost1.p.rapidapi.com"
TIMEOUT =
180
JSON_CONTENT_TYPE =
"application/json"

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(data = {}) ⇒ Client

Returns a new instance of Client.



19
20
21
22
# File 'lib/onepost/client.rb', line 19

def initialize(data={})
  self.rapid_api_key = data.fetch(:rapid_api_key)
  self.secret_key = data.fetch(:secret_key)
end

Instance Attribute Details

#rapid_api_keyObject

Returns the value of attribute rapid_api_key.



17
18
19
# File 'lib/onepost/client.rb', line 17

def rapid_api_key
  @rapid_api_key
end

#secret_keyObject

Returns the value of attribute secret_key.



17
18
19
# File 'lib/onepost/client.rb', line 17

def secret_key
  @secret_key
end