View Source Tw.V1_1.Place (Tw v0.1.1)

Place data structure and related functions. https://developer.twitter.com/en/docs/twitter-api/v1/data-dictionary/object-model/geo

Link to this section Summary

Types

t()
fielddescription
idID representing this place. Note that this is represented as a string, not an integer. Example: "01a9a39529b27f36".
urlURL representing the location of additional place metadata for this place. Example: "https://api.twitter.com/1.1/geo/id/01a9a39529b27f36.json".
place_typeThe type of location represented by this place. Example: "city".
nameShort human-readable representation of the place’s name. Example: "Manhattan".
full_nameFull human-readable representation of the place’s name. Example: "Manhattan, NY".
country_codeShortened country code representing the country containing this place. Example: "US".
countryName of the country containing this place. Example: "United States".
bounding_boxA bounding box of coordinates which encloses this place.
attributesWhen using PowerTrack, 30-Day and Full-Archive Search APIs, and Volume Streams this hash is null. Example: {}.

Functions

Decode JSON-decoded map into t/0

Link to this section Types

Specs

id() :: binary()

Specs

t() :: %Tw.V1_1.Place{
  attributes: map(),
  bounding_box: Tw.V1_1.BoundingBox.t(),
  country: binary(),
  country_code: binary(),
  full_name: binary(),
  id: id(),
  name: binary(),
  place_type: binary(),
  url: binary()
}
fielddescription
idID representing this place. Note that this is represented as a string, not an integer. Example: "01a9a39529b27f36".
urlURL representing the location of additional place metadata for this place. Example: "https://api.twitter.com/1.1/geo/id/01a9a39529b27f36.json".
place_typeThe type of location represented by this place. Example: "city".
nameShort human-readable representation of the place’s name. Example: "Manhattan".
full_nameFull human-readable representation of the place’s name. Example: "Manhattan, NY".
country_codeShortened country code representing the country containing this place. Example: "US".
countryName of the country containing this place. Example: "United States".
bounding_boxA bounding box of coordinates which encloses this place.
attributesWhen using PowerTrack, 30-Day and Full-Archive Search APIs, and Volume Streams this hash is null. Example: {}.

Link to this section Functions

Specs

decode!(map()) :: t()

Decode JSON-decoded map into t/0