Class: Moip2::WebhooksApi
- Inherits:
-
Object
- Object
- Moip2::WebhooksApi
- Defined in:
- lib/moip2/webhooks_api.rb
Instance Attribute Summary collapse
-
#client ⇒ Object
readonly
Returns the value of attribute client.
Instance Method Summary collapse
- #base_path ⇒ Object
-
#initialize(client) ⇒ WebhooksApi
constructor
A new instance of WebhooksApi.
- #show ⇒ Object
Constructor Details
#initialize(client) ⇒ WebhooksApi
Returns a new instance of WebhooksApi.
5 6 7 |
# File 'lib/moip2/webhooks_api.rb', line 5 def initialize(client) @client = client end |
Instance Attribute Details
#client ⇒ Object (readonly)
Returns the value of attribute client.
3 4 5 |
# File 'lib/moip2/webhooks_api.rb', line 3 def client @client end |
Instance Method Details
#base_path ⇒ Object
9 10 11 |
# File 'lib/moip2/webhooks_api.rb', line 9 def base_path "/v2/webhooks" end |
#show ⇒ Object
13 14 15 |
# File 'lib/moip2/webhooks_api.rb', line 13 def show Resource::Webhooks.new(client, client.get("#{base_path}")) end |