How to obtain a country list

To obtain a country list, use the following URL.

 Method URL
 POST  https://api.fairwarningsoftware.com/v1.1.1/countries

 

 Status Response
 200 {
    "countries":
        [
            {
                 "country" :
                     {

                         "id" : <id>,

                         "iso" : <iso>,

                         "name" : <name>,

                         "nicename" : <nicename>,

                         "iso3" : <iso3>,

                         "numcode" : <numcode>,

                         "phonecode" : <phonecode>

                   }

        
   }
       ]
}
401  {"error":"The API keys provided are invalid."}
403  {"error":"API keys are missing."}
500  {"error": <custom error>}

 

 Field  Type Description
countries object An object containing an array of contries.
country object An object containing country information for one country.
id int The ID of the country.
iso string The 2-character ISO for the country.
name string The name of the country.
nicename string The more readable name of the country.
iso3 string The 3-character ISO for the country.
numcode int The numeric code for the country.
phonecode int The numeric phone country code.