Class: DocomoNlu::Management::V23::Account
- Defined in:
- lib/docomo-nlu/management/V23/account.rb
Class Method Summary collapse
-
.count ⇒ Object
Parameter for create { “accountName”: “your account name”, “password”: “your account password”, “description”: “account description”, “authorization”: 2, “enable”: true }.
Instance Method Summary collapse
Methods inherited from Base
check_response, headers, #id_from_response, instantiate_collection, instantiate_record, #login, #logout, #static_headers
Class Method Details
.count ⇒ Object
Parameter for create
"accountName": "your account name",
"password": "your account password",
"description": "account description",
"authorization": 2,
"enable": true
18 19 20 21 |
# File 'lib/docomo-nlu/management/V23/account.rb', line 18 def self.count response_body = JSON.parse(connection.get("#{prefix}#{element_name}/count", headers).body) response_body["count"] end |
Instance Method Details
#to_json(options = {}) ⇒ Object
23 24 25 26 27 |
# File 'lib/docomo-nlu/management/V23/account.rb', line 23 def to_json( = {}) enable_params = ["accountName", "password", "description", "authorization", "enable"] attributes.select! {|a| enable_params.include?(a) } super end |