Created
March 15, 2013 06:52
-
-
Save baxang/5167948 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'nokogiri' | |
require 'addressable/uri' | |
api_key = 'your_key' | |
uri = Addressable::URI.parse 'http://openapi.epost.go.kr/postal/retrieveLotNumberAdressService/retrieveLotNumberAdressService/getComplexList' | |
uri.query_values = { | |
ServiceKey: api_key, | |
srchwrd: '무악동', | |
areaNm: '현대아파트', | |
searchSe: 'and' | |
} | |
response = `curl #{uri}` | |
doc = Nokogiri::XML( open(uri) ) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment