A location's address has address line 1, address line 2, city, state or province, postal code, and country. The country you choose controls how the rest of the address form behaves: it sets the labels for the city, state, and postal fields; decides whether you pick a state or province from a list or type it; and determines whether a subdivision or postal code is required.
When the address is required
The address is optional while a location does not fulfill online orders. When Fulfills online orders is enabled, address line 1, city, and country are required. A state or province is also required when the selected country provides a subdivision list, and a postal code is required when that country uses postal codes. Address line 2 and phone remain optional.
The country comes first
Set the country before the rest of the address. When you change the country, Tringify loads that country's address format and updates the form. Address formats come from Google's public address data, which Tringify keeps in sync, so the labels, the state or province list, and the postal format match how addresses are written in that country.
State or province label and picker
The label above the state field changes with the country. Depending on the country it reads State, Province, Emirate, Prefecture, Department, County, District, Parish, Island, Oblast, Region, Do/Si, or Area.
If the country has a defined list of first-level divisions, the state field becomes a searchable dropdown and the stored value must be one of the listed subdivision codes. If the country has no such list, the field is free text and its value only has to fit within the maximum length.
Postal code label and validation
The postal field's label also depends on the country. It reads ZIP code, Postal code, PIN code, or Eircode depending on where the location is.
Some countries have no postal code system. For those countries the postal field is hidden and no postal code is stored. When you switch to such a country, any postal code already typed is cleared.
For countries that use postal codes, the postal code is required when the location fulfills online orders and optional otherwise. If you enter one, it must fit the maximum length, contain only letters, digits, spaces, and hyphens, and match the country's expected format. The field shows an example of the expected format as a placeholder, for example 12345 for the United States or SW1A 1AA for the United Kingdom.
Address rules in Store API and CSV import
Store API requests and location CSV imports use the same backend rules as the form. Country code is an uppercase two-letter code such as US or GB. When fulfills_online_orders is true, the country-dependent service address is required. Subdivision values must use a listed code when the country provides a list, and postal codes are checked against the selected country's format.
In a CSV import, a row with an invalid country, subdivision, postal code, or incomplete online-fulfillment address is reported as failed with the reason. Other valid rows continue to import.
| name | address_line1 | city | state_province | postal_code | country_code |
|---|---|---|---|---|---|
| Main Warehouse | 123 Market Street | San Francisco | CA | 94105 | US |