Module: Trustpilot
- Defined in:
- lib/trustpilot.rb,
lib/trustpilot/api.rb,
lib/trustpilot/errors.rb,
lib/trustpilot/request.rb,
lib/trustpilot/version.rb,
lib/trustpilot/auth/token.rb,
lib/trustpilot/api_resource.rb,
lib/trustpilot/error_checker.rb,
lib/trustpilot/auth/authenticator.rb,
lib/trustpilot/resources/invitation.rb
Defined Under Namespace
Modules: Auth Classes: APIError, Api, ApiResource, AuthenticationError, ClientError, Error, ErrorChecker, Invitation, OAuthTokenRequestError, RateLimitError, Request, ServerError
Constant Summary collapse
- VERSION =
'0.1.1'
Class Attribute Summary collapse
-
.api_email ⇒ Object
Returns the value of attribute api_email.
-
.api_key ⇒ Object
Returns the value of attribute api_key.
-
.api_password ⇒ Object
Returns the value of attribute api_password.
-
.api_read_timeout ⇒ Object
Returns the value of attribute api_read_timeout.
-
.api_secret ⇒ Object
Returns the value of attribute api_secret.
-
.api_url ⇒ Object
readonly
Returns the value of attribute api_url.
-
.debug ⇒ Object
Returns the value of attribute debug.
-
.default_business_unit_id ⇒ Object
Returns the value of attribute default_business_unit_id.
-
.redis ⇒ Object
Returns the value of attribute redis.
Class Method Summary collapse
Class Attribute Details
.api_email ⇒ Object
Returns the value of attribute api_email.
23 24 25 |
# File 'lib/trustpilot.rb', line 23 def api_email @api_email end |
.api_key ⇒ Object
Returns the value of attribute api_key.
23 24 25 |
# File 'lib/trustpilot.rb', line 23 def api_key @api_key end |
.api_password ⇒ Object
Returns the value of attribute api_password.
23 24 25 |
# File 'lib/trustpilot.rb', line 23 def api_password @api_password end |
.api_read_timeout ⇒ Object
Returns the value of attribute api_read_timeout.
23 24 25 |
# File 'lib/trustpilot.rb', line 23 def api_read_timeout @api_read_timeout end |
.api_secret ⇒ Object
Returns the value of attribute api_secret.
23 24 25 |
# File 'lib/trustpilot.rb', line 23 def api_secret @api_secret end |
.api_url ⇒ Object (readonly)
Returns the value of attribute api_url.
26 27 28 |
# File 'lib/trustpilot.rb', line 26 def api_url @api_url end |
.debug ⇒ Object
Returns the value of attribute debug.
23 24 25 |
# File 'lib/trustpilot.rb', line 23 def debug @debug end |
.default_business_unit_id ⇒ Object
Returns the value of attribute default_business_unit_id.
23 24 25 |
# File 'lib/trustpilot.rb', line 23 def default_business_unit_id @default_business_unit_id end |
.redis ⇒ Object
Returns the value of attribute redis.
23 24 25 |
# File 'lib/trustpilot.rb', line 23 def redis @redis end |
Class Method Details
.with_redis(&block) ⇒ Object
28 29 30 31 32 33 34 35 36 |
# File 'lib/trustpilot.rb', line 28 def with_redis &block raise Trustpilot::Error, 'Trustpilot.redis is not set' unless redis if redis.respond_to? :with redis.with( &block ) else yield redis end end |