Class: Ibancom::API::ValidationService

Inherits:
Service
  • Object
show all
Defined in:
lib/ibancom/api/validation_service.rb

Instance Attribute Summary

Attributes inherited from Service

#client

Instance Method Summary collapse

Methods inherited from Service

#initialize

Constructor Details

This class inherits a constructor from Ibancom::API::Service

Instance Method Details

#validate(iban) ⇒ Object



6
7
8
9
# File 'lib/ibancom/api/validation_service.rb', line 6

def validate(iban)
  response = client.post("/v4/iban/", { iban: iban, sci: 1 })
  Resources::IBAN::Validation.new(response, response.body)
end