canaandog 1 Posted ... (edited) I am trying to use the API to generate a .conf file for wireguard. This works fine, curl -H "API-KEY:xxxxx" "https://airvpn.org/api/generator/?system=windows&protocols=wireguard_1_udp_1637&servers=america" but when I try to specify servers by country I get an error. Does anyone have it working for countries? As an aside, the API page mentions, "checking API Reference" on the generator page, but I don't see that option there nor am I able to find an API reference elsewhere. Edited ... by canaandog Share this post Link to post
OpenSourcerer 1441 Posted ... Bear in mind that your servers=america is the continent of America, not the United States. Country names must be in ISO-3166a2 two-letter format: us, de, jp, etc. Do you mean that, or is it that you cannot select multiple servers in a country (for which you'd need multiple API queries, anyway)? Hide OpenSourcerer's signature Hide all signatures NOT AN AIRVPN TEAM MEMBER. USE TICKETS FOR PROFESSIONAL SUPPORT. LZ1's New User Guide to AirVPN « Plenty of stuff for advanced users, too! Want to contact me directly? All relevant methods are on my About me page. Share this post Link to post
canaandog 1 Posted ... 26 minutes ago, OpenSourcerer said: Country names must be in ISO-3166a2 two-letter format: us, de, jp, etc. Thanks, that was the info I needed. I wanted to be more specific than continent, and things like the "canada" and "united-states" labels from the generator page weren't working. Didn't occur to me to try the two-letter versions. 1 OpenSourcerer reacted to this Share this post Link to post