openapi: 3.2.0 info: version: 1.0.0 title: Eclipse GeoIP REST Subnets API description: REST client to retrieve GeoIP information about IP addresses and to lookup IP information for countries given their ISO country code. license: name: Eclipse Public License - 2.0 url: https://www.eclipse.org/legal/epl-2.0/ servers: - url: http://api.eclipse.org/geoip description: Production endpoint for Eclipse GeoIP REST API tags: - name: Subnets paths: /subnets/{ipv}/{isoCountry}: description: 'Given an IP protocol version string (IPv4 or IPv6 currently) and a 2 letter ISO country code, retrieves a list of subnets registered for the given country. If an invalid IP protocol version string is given, or an invalid ISO code is passed, a server error is returned. ' get: summary: Get IP ranges for country code parameters: - name: ipv in: path required: true description: Which list of subnets to retrieve IP ranges for. schema: type: string enum: - ipv4 - ipv6 - name: isoCountry in: path required: true description: The 2 letter ISO code for the country to retrieve (case-insensitive). schema: type: string minLength: 2 maxLength: 2 responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/IpAddresses' '500': description: Server Error tags: - Subnets operationId: getSubnetsByIpvByIsoCountry x-operation-id-source: derived components: schemas: IpAddresses: type: array items: type: string description: IP ranges with subnet mask that are from the given country. example: 192.168.1.0/24