Created
April 1, 2015 18:29
-
-
Save cburmeister/9ba91e0a0f1cdd23ddbb to your computer and use it in GitHub Desktop.
Verify VAT identification numbers via http://ec.europa.eu/taxation_customs/vies/checkVatService.wsdl
This file contains hidden or 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
>>> from suds.client import Client | |
>>> url = 'http://ec.europa.eu/taxation_customs/vies/checkVatService.wsdl' | |
>>> client = Client(url) | |
>>> print client | |
Suds ( https://fedorahosted.org/suds/ ) version: 0.4 GA build: R699-20100913 | |
Service ( checkVatService ) tns="urn:ec.europa.eu:taxud:vies:services:checkVat" | |
Prefixes (1) | |
ns0 = "urn:ec.europa.eu:taxud:vies:services:checkVat:types" | |
Ports (1): | |
(checkVatPort) | |
Methods (2): | |
checkVat(xs:string countryCode, xs:string vatNumber, ) | |
checkVatApprox(xs:string countryCode, xs:string vatNumber, xs:string traderName, ns0:companyTypeCode traderCompanyType, xs:string traderStreet, xs:string traderPostcode, xs:string traderCity, xs:string requesterCountryCode, xs:string requesterVatNumber, ) | |
Types (2): | |
ns0:companyTypeCode | |
ns0:matchCode | |
>>> print client.service.checkVat(countryCode='BE', vatNumber='12345678901') | |
(reply){ | |
countryCode = "BE" | |
vatNumber = "12345678901" | |
requestDate = 2015-04-01 | |
valid = False | |
name = "---" | |
address = "---" | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment