@prefix sioc: <http://rdfs.org/sioc/ns#> .
@prefix dc: <http://purl.org/dc/elements/1.1/> .
@prefix dcterms: <http://purl.org/dc/terms/> .
@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .
@prefix content: <http://purl.org/rss/1.0/modules/content/> .
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .

<https://lhero.org/portfolio/lh-places/>
  a sioc:Post ;
  dc:title "REST API" ;
  dcterms:identifier 149922 ;
  dc:modified "2026-10-11T15:45:17Z"^^xsd:dateTime ;
  dc:created "2026-10-11T15:45:17Z"^^xsd:dateTime ;
  sioc:link <https://lhero.org/portfolio/lh-places/rest-api/> ;
  sioc:has_creator <https://lhero.org/author/1/#account> ;
  sioc:has_container <https://lhero.org/#posts> ;
  content:encoded """<ul class="lh_portfolio-meta"><li><strong>Part of:</strong> <a href="https://lhero.org/portfolio/lh-places/">LH Places</a></li></ul>
<p class="wp-block-paragraph">All routes are under the <code>lh-places/v1</code> namespace.</p>



<h2 class="wp-block-heading">GET /geojson/{id}</h2>



<p class="wp-block-paragraph">This route is public. It returns one published post as a GeoJSON Feature whose properties are <code>id</code>, <code>title</code>, <code>url</code> and <code>address</code>. A post that is not published, or has no geodata, returns 404.</p>



<pre class="wp-block-code"><code>{
  "type": "Feature",
  "geometry": { "type": "Point", "coordinates": [144.9631, -37.8136] },
  "properties": {
    "id": 42,
    "title": "Melbourne CBD",
    "url": "https://example.com/melbourne-cbd/",
    "address": "Swanston St, Melbourne VIC 3000"
  }
}</code></pre>



<h2 class="wp-block-heading">GET /geojson</h2>



<p class="wp-block-paragraph">This route is public. It returns a FeatureCollection of published posts that have geodata, with the same properties on each feature.</p>



<figure class="wp-block-table"><table><thead><tr><th>Parameter</th><th>Default</th><th>Notes</th></tr></thead><tbody><tr><td><code>post_type</code></td><td>post</td><td>Post type to query.</td></tr><tr><td><code>posts_per_page</code></td><td>50</td><td>Capped at 500.</td></tr><tr><td><code>category</code></td><td>none</td><td>Category ID.</td></tr><tr><td><code>post_status</code></td><td>publish</td><td>Accepted but ignored. Only published posts are returned.</td></tr></tbody></table></figure>



<h2 class="wp-block-heading">GET /attachment-exif-gps/{id}</h2>



<p class="wp-block-paragraph">This route backs Import from media and requires <code>edit_post</code> on the post. It returns <code>latitude</code>, <code>longitude</code>, <code>attachment_id</code> and <code>attachment_title</code> for the first image attached to post {id} that has usable EXIF GPS data. Out-of-range coordinates, and 0,0, are treated as missing.</p>
"""^^rdf:XMLLiteral ;
  sioc:content """Part of: LH Places
All routes are under the lh-places/v1 namespace.



GET /geojson/{id}



This route is public. It returns one published post as a GeoJSON Feature whose properties are id, title, url and address. A post that is not published, or has no geodata, returns 404.



{
  "type": "Feature",
  "geometry": { "type": "Point", "coordinates": [144.9631, -37.8136] },
  "properties": {
    "id": 42,
    "title": "Melbourne CBD",
    "url": "https://example.com/melbourne-cbd/",
    "address": "Swanston St, Melbourne VIC 3000"
  }
}



GET /geojson



This route is public. It returns a FeatureCollection of published posts that have geodata, with the same properties on each feature.



ParameterDefaultNotespost_typepostPost type to query.posts_per_page50Capped at 500.categorynoneCategory ID.post_statuspublishAccepted but ignored. Only published posts are returned.



GET /attachment-exif-gps/{id}



This route backs Import from media and requires edit_post on the post. It returns latitude, longitude, attachment_id and attachment_title for the first image attached to post {id} that has usable EXIF GPS data. Out-of-range coordinates, and 0,0, are treated as missing.
""" ;
  sioc:topic <https://lhero.org/?taxonomy=author&term=cap-1> .

<https://lhero.org/author/1/#account> rdfs:seeAlso <https://lhero.org/author/1/?feed=lhrdf&format=turtle> .
<https://lhero.org/?taxonomy=author&term=cap-1> rdfs:seeAlso <https://lhero.org/?taxonomy=author&term=cap-1&feed=lhrdf&format=turtle> .
