Class: Kong::Plugin

Inherits:
Object
  • Object
show all
Includes:
Base, BelongsToApi
Defined in:
lib/kong/plugin.rb

Constant Summary collapse

ATTRIBUTE_NAMES =
%w(id api_id name config enabled consumer_id).freeze
API_END_POINT =
'/plugins/'.freeze

Instance Attribute Summary

Attributes included from BelongsToApi

#api

Attributes included from Base

#api_end_point, #attributes

Instance Method Summary collapse

Methods included from BelongsToApi

#api_id=, #use_api_end_point

Methods included from Base

#client, #create_or_update, #delete, #get, included, #initialize, #method_missing, #new?, #respond_to?, #save

Dynamic Method Handling

This class handles dynamic methods through the method_missing method in the class Kong::Base

Instance Method Details

#createObject

Create resource



12
13
14
15
# File 'lib/kong/plugin.rb', line 12

def create
  flatten_config
  super
end

#updateObject

update resource



18
19
20
21
# File 'lib/kong/plugin.rb', line 18

def update
  flatten_config
  super
end