Skip to content

Instantly share code, notes, and snippets.

@Lh4cKg
Created September 19, 2018 15:44
Show Gist options
  • Save Lh4cKg/fdefdb0c0aa7349f0a8732774a39791f to your computer and use it in GitHub Desktop.
Save Lh4cKg/fdefdb0c0aa7349f0a8732774a39791f to your computer and use it in GitHub Desktop.
NBG currency rates
"""
Service API:
public string GetCurrency(Currency cur) აბრუნებს ვალუტის კურსს, მაგ. "1.0754"
public string GetCurrencyDescription(Currency cur) აბრუნებს ვალუტის აღწერას, მაგ. "10 ესტორნური კრონი"
public string GetCurrencyChange(Currency cur) აბრუნებს ვალუტის ცვლილების მნიშვნელობას, მაგ. "-0.0121"
public int GetCurrencyRate(Currency cur) 1 - თუ გაიზარდა; -1 - თუ დაიკლო, 0 - თუ იგივე დარჩა
public string GetDate() აბრუნებს კურსების შესაბამის თარიღს
"""
xml = """<?xml version="1.0" encoding="UTF-8"?><SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"><SOAP-ENV:Body><GetCurrency><currencyCode>USD</currencyCode></GetCurrency></SOAP-ENV:Body></SOAP-ENV:Envelope>"""
respons = requests.post('https://nbg.gov.ge:443/currency_service.php', data=xml)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment