@nhtio/adonis-maxmind/types
The module responsible for exporting all TypeScript types and interfaces used throughout the Adonis MaxMind package, including configuration types, command metadata types, MaxMind response types, and any other relevant types.
Interfaces
| Interface | Description |
|---|---|
| CountryInfo | Represents a country with its identifying codes and metadata. |
| CountryState | Represents a state or province within a country. |
| MaxmindReader | A type representing the MaxMind database reader instance, which is a wrapper around the Reader class from the maxmind package, but with the response type inferred based on the specified edition in the configuration. |
Type Aliases
| Type Alias | Description |
|---|---|
| InferMaxmindEdition | A utility type that infers the MaxMind response type based on the specified edition in the configuration. If the edition is not specified or does not match any known editions, it resolves to never. |
| InferMaxmindReader | A utility type that infers the MaxMind reader type based on the specified edition in the configuration. If the edition is not specified or does not match any known editions, it resolves to undefined. |
| MaxmindResolvedCountry | A type representing the resolved country information for a given IP address, which can be either a valid ISO 3166-1 alpha-2 country code, 'XX' for unknown or private IP addresses, or 'T1' for IP addresses that are for clients on the Tor network. |
References
AdonisMaxmindConfig
Re-exports AdonisMaxmindConfig
Country
Re-exports Country
CountryAlpha2
Re-exports CountryAlpha2
CountryAlpha3
Re-exports CountryAlpha3
CountryCitizenship
Re-exports CountryCitizenship
CountryName
Re-exports CountryName
MaxMindDatabases
Re-exports MaxMindDatabases
MaxMindDatabaseUrls
Re-exports MaxMindDatabaseUrls