flickrex v0.3.0 Flickr.Places

Summary

Functions

Return a list of place IDs for a query string.

The flickr.places.find method is not a geocoder. It will round up to the nearest place type to which place IDs apply. For example, if you pass it a street level address it will return the city that contains the address rather than the street, or building, itself

Return a place ID for a latitude, longitude and accuracy triple.

The flickr.places.findByLatLon method is not meant to be a (reverse) geocoder in the traditional sense. It is designed to allow users to find photos for “places” and will round up to the nearest place type to which corresponding place IDs apply.

For example, if you pass it a street level coordinate it will return the city that contains the point rather than the street, or building, itself.

It will also truncate latitudes and longitudes to three decimal points

Return a list of locations with public photos that are parented by a Where on Earth (WOE) or Places ID

Get informations about a place

Lookup information about a place, by its flickr.com/places URL

Fetches a list of available place types for Flickr

Return an historical list of all the shape data generated for a Places or Where on Earth (WOE) ID

Return the top 100 most geotagged places for a day

Return all the locations of a matching place type for a bounding box.

Return a list of the top 100 unique places clustered by a given placetype for a user’s contacts

Return a list of the top 100 unique places clustered by a given placetype for set of tags or machine tags

Return a list of the top 100 unique places clustered by a given placetype for a user

Find Flickr Places information by Place ID.

This method has been deprecated. It won’t be removed but you should use flickr.places.getInfo instead

Find Flickr Places information by Place URL.

This method has been deprecated. It won’t be removed but you should use flickr.places.getInfoByUrl instead

Return a list of the top 100 unique tags for a Flickr Places or Where on Earth (WOE) ID

Types

args()
args() :: Keyword.t
client()
client() :: Flickrex.Client.t
response()
response() :: Flickrex.Parser.response

Functions

find(client, args \\ [])
find(client, args) :: response

Return a list of place IDs for a query string.

The flickr.places.find method is not a geocoder. It will round up to the nearest place type to which place IDs apply. For example, if you pass it a street level address it will return the city that contains the address rather than the street, or building, itself.

This method does not require authentication.

Arguments

  • query - (required) The query string to use for place ID lookups
find_by_lat_lon(client, args \\ [])
find_by_lat_lon(client, args) :: response

Return a place ID for a latitude, longitude and accuracy triple.

The flickr.places.findByLatLon method is not meant to be a (reverse) geocoder in the traditional sense. It is designed to allow users to find photos for “places” and will round up to the nearest place type to which corresponding place IDs apply.

For example, if you pass it a street level coordinate it will return the city that contains the point rather than the street, or building, itself.

It will also truncate latitudes and longitudes to three decimal points.

This method does not require authentication.

Arguments

  • lat - (required) The latitude whose valid range is -90 to 90. Anything more than 4 decimal places will be truncated.

  • lon - (required) The longitude whose valid range is -180 to 180. Anything more than 4 decimal places will be truncated.

  • accuracy - Recorded accuracy level of the location information. World level is 1, Country is ~3, Region ~6, City ~11, Street ~16. Current range is 1-16. The default is 16.

get_children_with_photos_public(client, args \\ [])
get_children_with_photos_public(client, args) :: response

Return a list of locations with public photos that are parented by a Where on Earth (WOE) or Places ID.

This method does not require authentication.

Arguments

  • place_id - A Flickr Places ID. (While optional, you must pass either a valid Places ID or a WOE ID.)

  • woe_id - A Where On Earth (WOE) ID. (While optional, you must pass either a valid Places ID or a WOE ID.)

get_info(client, args \\ [])
get_info(client, args) :: response

Get informations about a place.

This method does not require authentication.

Arguments

  • place_id - A Flickr Places ID. (While optional, you must pass either a valid Places ID or a WOE ID.)

  • woe_id - A Where On Earth (WOE) ID. (While optional, you must pass either a valid Places ID or a WOE ID.)

get_info_by_url(client, args \\ [])
get_info_by_url(client, args) :: response

Lookup information about a place, by its flickr.com/places URL.

This method does not require authentication.

Arguments

  • url - (required) A flickr.com/places URL in the form of /country/region/city. For example: /Canada/Quebec/Montreal
get_place_types(client, args \\ [])
get_place_types(client, args) :: response

Fetches a list of available place types for Flickr.

This method does not require authentication.

Arguments

get_shape_history(client, args \\ [])
get_shape_history(client, args) :: response

Return an historical list of all the shape data generated for a Places or Where on Earth (WOE) ID.

This method does not require authentication.

Arguments

  • place_id - A Flickr Places ID. (While optional, you must pass either a valid Places ID or a WOE ID.)

  • woe_id - A Where On Earth (WOE) ID. (While optional, you must pass either a valid Places ID or a WOE ID.)

get_top_places_list(client, args \\ [])
get_top_places_list(client, args) :: response

Return the top 100 most geotagged places for a day.

This method does not require authentication.

Arguments

  • place_type_id - (required) The numeric ID for a specific place type to cluster photos by.

    Valid place type IDs are :

    • 22: neighbourhood
    • 7: locality
    • 8: region
    • 12: country
    • 29: continent

  • date - A valid date in YYYY-MM-DD format. The default is yesterday.

  • woe_id - Limit your query to only those top places belonging to a specific Where on Earth (WOE) identifier.

  • place_id - Limit your query to only those top places belonging to a specific Flickr Places identifier.

places_for_bounding_box(client, args \\ [])
places_for_bounding_box(client, args) :: response

Return all the locations of a matching place type for a bounding box.

The maximum allowable size of a bounding box (the distance between the SW and NE corners) is governed by the place type you are requesting. Allowable sizes are as follows:

  • neighbourhood: 3km (1.8mi)
  • locality: 7km (4.3mi)
  • county: 50km (31mi)
  • region: 200km (124mi)
  • country: 500km (310mi)
  • continent: 1500km (932mi)

This method does not require authentication.

Arguments

  • bbox - (required) A comma-delimited list of 4 values defining the Bounding Box of the area that will be searched. The 4 values represent the bottom-left corner of the box and the top-right corner, minimum_longitude, minimum_latitude, maximum_longitude, maximum_latitude.

  • place_type - The name of place type to using as the starting point to search for places in a bounding box. Valid placetypes are:

    • neighbourhood
    • locality
    • county
    • region
    • country
    • continent

    The “place_type” argument has been deprecated in favor of the “place_type_id” argument. It won’t go away but it will not be added to new methods. A complete list of place type IDs is available using the flickr.places.getPlaceTypes method. (While optional, you must pass either a valid place type or place type ID.)

  • place_type_id - The numeric ID for a specific place type to cluster photos by.

    Valid place type IDs are :

    • 22: neighbourhood
    • 7: locality
    • 8: region
    • 12: country
    • 29: continent

    (While optional, you must pass either a valid place type or place type ID.)

places_for_contacts(client, args \\ [])
places_for_contacts(client, args) :: response

Return a list of the top 100 unique places clustered by a given placetype for a user’s contacts.

This method requires authentication with “read” permission.

Arguments

  • place_type - A specific place type to cluster photos by.

    Valid place types are :

    • neighbourhood (and neighborhood)
    • locality
    • region
    • country
    • continent

    The “place_type” argument has been deprecated in favor of the “place_type_id” argument. It won’t go away but it will not be added to new methods. A complete list of place type IDs is available using the flickr.places.getPlaceTypes method. (While optional, you must pass either a valid place type or place type ID.)

  • place_type_id - The numeric ID for a specific place type to cluster photos by.

    Valid place type IDs are :

    • 22: neighbourhood
    • 7: locality
    • 8: region
    • 12: country
    • 29: continent

    (While optional, you must pass either a valid place type or place type ID.)

  • woe_id - A Where on Earth identifier to use to filter photo clusters. For example all the photos clustered by locality in the United States (WOE ID 23424977).

    (While optional, you must pass either a valid Places ID or a WOE ID.)

  • place_id - A Flickr Places identifier to use to filter photo clusters. For example all the photos clustered by locality in the United States (Place ID 4KO02SibApitvSBieQ).

    (While optional, you must pass either a valid Places ID or a WOE ID.)

  • threshold - The minimum number of photos that a place type must have to be included. If the number of photos is lowered then the parent place type for that place will be used.

    For example if your contacts only have 3 photos taken in the locality of Montreal (WOE ID 3534) but your threshold is set to 5 then those photos will be “rolled up” and included instead with a place record for the region of Quebec (WOE ID 2344924).

  • contacts - Search your contacts. Either ‘all’ or ‘ff’ for just friends and family. (Default is all)

  • min_upload_date - Minimum upload date. Photos with an upload date greater than or equal to this value will be returned. The date should be in the form of a unix timestamp.

  • max_upload_date - Maximum upload date. Photos with an upload date less than or equal to this value will be returned. The date should be in the form of a unix timestamp.

  • min_taken_date - Minimum taken date. Photos with an taken date greater than or equal to this value will be returned. The date should be in the form of a mysql datetime.

  • max_taken_date - Maximum taken date. Photos with an taken date less than or equal to this value will be returned. The date should be in the form of a mysql datetime.

places_for_tags(client, args \\ [])
places_for_tags(client, args) :: response

Return a list of the top 100 unique places clustered by a given placetype for set of tags or machine tags.

This method does not require authentication.

Arguments

  • place_type_id - (required) The numeric ID for a specific place type to cluster photos by.

    Valid place type IDs are :

    • 22: neighbourhood
    • 7: locality
    • 8: region
    • 12: country
    • 29: continent

  • woe_id - A Where on Earth identifier to use to filter photo clusters. For example all the photos clustered by locality in the United States (WOE ID 23424977).

    (While optional, you must pass either a valid Places ID or a WOE ID.)

  • place_id - A Flickr Places identifier to use to filter photo clusters. For example all the photos clustered by locality in the United States (Place ID 4KO02SibApitvSBieQ).

    (While optional, you must pass either a valid Places ID or a WOE ID.)

  • threshold - The minimum number of photos that a place type must have to be included. If the number of photos is lowered then the parent place type for that place will be used.

    For example if you only have 3 photos taken in the locality of Montreal (WOE ID 3534) but your threshold is set to 5 then those photos will be “rolled up” and included instead with a place record for the region of Quebec (WOE ID 2344924).

  • tags - A comma-delimited list of tags. Photos with one or more of the tags listed will be returned.

    (While optional, you must pass either a valid tag or machine_tag

  • tag_mode - Either ‘any’ for an OR combination of tags, or ‘all’ for an AND combination. Defaults to ‘any’ if not specified.

  • machine_tags - Aside from passing in a fully formed machine tag, there is a special syntax for searching on specific properties :

    • Find photos using the ‘dc’ namespace : “machine_tags” => “dc:”
    • Find photos with a title in the ‘dc’ namespace : “machine_tags” => “dc:title=”
    • Find photos titled “mr. camera” in the ‘dc’ namespace : “machine_tags” => “dc:title=\”mr. camera\”
    • Find photos whose value is “mr. camera” : “machine_tags” => “:=\”mr. camera\””
    • Find photos that have a title, in any namespace : “machine_tags” => “:title=”
    • Find photos that have a title, in any namespace, whose value is “mr. camera” : “machine_tags” => “:title=\”mr. camera\””
    • Find photos, in the ‘dc’ namespace whose value is “mr. camera” : “machine_tags” => “dc:*=\”mr. camera\””
    Multiple machine tags may be queried by passing a comma-separated list. The number of machine tags you can pass in a single query depends on the tag mode (AND or OR) that you are querying with. “AND” queries are limited to (16) machine tags. “OR” queries are limited to (8).

    (While optional, you must pass either a valid tag or machine_tag)

  • machine_tag_mode - Either ‘any’ for an OR combination of tags, or ‘all’ for an AND combination. Defaults to ‘any’ if not specified.

  • min_upload_date - Minimum upload date. Photos with an upload date greater than or equal to this value will be returned. The date should be in the form of a unix timestamp.

  • max_upload_date - Maximum upload date. Photos with an upload date less than or equal to this value will be returned. The date should be in the form of a unix timestamp.

  • min_taken_date - Minimum taken date. Photos with an taken date greater than or equal to this value will be returned. The date should be in the form of a mysql datetime.

  • max_taken_date - Maximum taken date. Photos with an taken date less than or equal to this value will be returned. The date should be in the form of a mysql datetime.

places_for_user(client, args \\ [])
places_for_user(client, args) :: response

Return a list of the top 100 unique places clustered by a given placetype for a user.

This method requires authentication with “read” permission.

Arguments

  • place_type_id - The numeric ID for a specific place type to cluster photos by.

    Valid place type IDs are :

    • 22: neighbourhood
    • 7: locality
    • 8: region
    • 12: country
    • 29: continent

    The “place_type” argument has been deprecated in favor of the “place_type_id” argument. It won’t go away but it will not be added to new methods. A complete list of place type IDs is available using the flickr.places.getPlaceTypes method. (While optional, you must pass either a valid place type or place type ID.)

  • place_type - A specific place type to cluster photos by.

    Valid place types are :

    • neighbourhood (and neighborhood)
    • locality
    • region
    • country
    • continent

    (While optional, you must pass either a valid place type or place type ID.)

  • woe_id - A Where on Earth identifier to use to filter photo clusters. For example all the photos clustered by locality in the United States (WOE ID 23424977).

    (While optional, you must pass either a valid Places ID or a WOE ID.)

  • place_id - A Flickr Places identifier to use to filter photo clusters. For example all the photos clustered by locality in the United States (Place ID 4KO02SibApitvSBieQ).

    (While optional, you must pass either a valid Places ID or a WOE ID.)

  • threshold - The minimum number of photos that a place type must have to be included. If the number of photos is lowered then the parent place type for that place will be used.

    For example if you only have 3 photos taken in the locality of Montreal (WOE ID 3534) but your threshold is set to 5 then those photos will be “rolled up” and included instead with a place record for the region of Quebec (WOE ID 2344924).

  • min_upload_date - Minimum upload date. Photos with an upload date greater than or equal to this value will be returned. The date should be in the form of a unix timestamp.

  • max_upload_date - Maximum upload date. Photos with an upload date less than or equal to this value will be returned. The date should be in the form of a unix timestamp.

  • min_taken_date - Minimum taken date. Photos with an taken date greater than or equal to this value will be returned. The date should be in the form of a mysql datetime.

  • max_taken_date - Maximum taken date. Photos with an taken date less than or equal to this value will be returned. The date should be in the form of a mysql datetime.

resolve_place_id(client, args \\ [])
resolve_place_id(client, args) :: response

Find Flickr Places information by Place ID.

This method has been deprecated. It won’t be removed but you should use flickr.places.getInfo instead.

This method does not require authentication.

Arguments

  • place_id - (required) A Flickr Places ID
resolve_place_url(client, args \\ [])
resolve_place_url(client, args) :: response

Find Flickr Places information by Place URL.

This method has been deprecated. It won’t be removed but you should use flickr.places.getInfoByUrl instead.

This method does not require authentication.

Arguments

  • url - (required) A Flickr Places URL.

    Flickr Place URLs are of the form /country/region/city
tags_for_place(client, args \\ [])
tags_for_place(client, args) :: response

Return a list of the top 100 unique tags for a Flickr Places or Where on Earth (WOE) ID

This method does not require authentication.

Arguments

  • woe_id - A Where on Earth identifier to use to filter photo clusters.

    (While optional, you must pass either a valid Places ID or a WOE ID.)

  • place_id - A Flickr Places identifier to use to filter photo clusters.

    (While optional, you must pass either a valid Places ID or a WOE ID.)

  • min_upload_date - Minimum upload date. Photos with an upload date greater than or equal to this value will be returned. The date should be in the form of a unix timestamp.

  • max_upload_date - Maximum upload date. Photos with an upload date less than or equal to this value will be returned. The date should be in the form of a unix timestamp.

  • min_taken_date - Minimum taken date. Photos with an taken date greater than or equal to this value will be returned. The date should be in the form of a mysql datetime.

  • max_taken_date - Maximum taken date. Photos with an taken date less than or equal to this value will be returned. The date should be in the form of a mysql datetime.