<div dir="ltr">Thanks Tim, but I don't understand what you meant because I don't see any "status" in the api response.<div><br></div><div>Anyway, I have new api-related questions. <div>See the parts I extracted from this example request:<div><br><div><div><a href="http://api.gbif.org/v1/dataset/10734a60-7ed1-11df-8c4a-0800200c9a66" target="_blank">http://api.gbif.org/v1/dataset<wbr>/10734a60-7ed1-11df-8c4a-<wbr>0800200c9a66</a><br></div></div><div><br></div><div>{<br></div><div><div>  "key": "10734a60-7ed1-11df-8c4a-08002<wbr>00c9a66",</div><div>  "installationKey": "86e4d50b-d77c-4731-99fb-b3e2a<wbr>2a83163",</div><div>  "publishingOrganizationKey": "def87a70-0837-11d9-acb2-b8a03<wbr>c50a862",</div><div>(...)<br></div><div>  "lockedForAutoUpdate": false,</div><div>  "createdBy": "<a href="http://registry-migration.gbif.org" target="_blank">registry-migration.gbif.org</a>",</div><div>  "modifiedBy": "<a href="http://crawler.gbif.org" target="_blank">crawler.gbif.org</a>",</div><div>  "created": "2010-05-03T22:02:18.000+0000"<wbr>,</div><div>  <b>"modified": "2017-01-19T18:16:28.844+0000"<wbr>,</b></div><div>   (...)<br></div></div><div> <b> "machineTags": </b>[</div><div>    {</div><div>      "key": 606300,</div><div>      "namespace": "<a href="http://crawler.gbif.org" target="_blank">crawler.gbif.org</a>",</div><div>      <b>"name": "crawl_attempt",</b></div><div>      "value": "45",</div><div>      "createdBy": "<a href="http://crawler.gbif.org" target="_blank">crawler.gbif.org</a>",</div><div>      <b>"created": "2017-01-19T18:17:29.063+0000"</b></div><div>    },</div><div>    (...)<br></div></div><div><div>  ],</div><div>  (...)</div><div>  "dataLanguage": "eng",</div><div> <b> "pubDate": "2017-01-18T23:00:00.000+0000"<wbr>,</b></div><div>  (...)</div><div>}<br></div></div><div><br></div><div>I want to programatically know wether a certain published dataset is updated or not in GBIF portal, comparing to its current IPT server version.</div><div><br></div><div>1) - In the example above, there is 1 minute difference between these two values:</div><div><b>"modified":"DATETIME"</b> </div><div>"machineTags":[{"name":<b>"crawl_<wbr>attempt","created":"DATETIME"</b>}]<br></div><div><br></div><div>Does this mean the last dataset harvest began immediately after the IPT was updated? </div><div>(as I said, I don't see the <b>"status"</b> tag you mentioned).</div><div><br></div><div>2) - I believe the "modified" datetime comes from <b>IPT server clock</b>, and the crawl_attempt created datetime comes from the <b>crawler machine clock</b>. Is this correct?  </div><div>So if the IPT server clock is not in the correct time but a bit ahead, when one compares both datetime programatically, the script could wrongly conclude that GBIF portal info is outdated (if reported crawl_attempt datetime is a bit earlier than modified datetime).</div><div><br></div><div>So, my question is: can I somehow request the crawler clock current time through the API, to compare it to the IPT server clock?<br></div><div>And likewise: can I somehow request the clock current time from a given IPT server?</div><div>So, if they are not synchronized, the script can take in account tha diference when comparing modified and crawl_attempt datetimes.</div><div><br></div><div>3) - What does <b>"pubDate" </b>represent? It looks odd to me that it always shows the same time (23:00:00).</div><div><br></div><div>4) - I am curious about the api request <b>/dataset/{UUID}/crawl</b></div><div>  Api documentation says it "Schedules a new crawl of the dataset".</div><div><br></div><div>  In which case is this request supposed to be necessary, and which user credentials should be used?  Can I see a curl example request?</div><div>I suppose this is not intended for crawling IPT servers, since I had the idea that crawls would be immediate when publishing through IPT (when there are not unexpected delays due to whatever data portal necessary works). <br></div><div><br></div><div>Many thanks in advance</div><div><br></div><div>David</div><div><br></div><div class="gmail_extra"><br><div class="gmail_quote">On 19 February 2017 at 14:43, Tim Robertson <span dir="ltr"><<a href="mailto:trobertson@gbif.org" target="_blank">trobertson@gbif.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">



<div style="word-wrap:break-word;color:rgb(0,0,0);font-size:14px;font-family:calibri,sans-serif">
<div>Hi David,</div>
<div><br>
</div>
<div>The crawl attempt is the start of the crawl with the publisher.  </div>
<div>Once the status confirms it is finished, then you could use that.  While it is crawling, the status will be something like “RUNNING” (off the top of my head)</div>
<div><br>
</div>
<div>Thanks,</div>
<div>Tim</div>
<div><br>
</div>
<div><br>
</div>
<span id="gmail-m_6951003100185910910m_-6290496056444398045m_7894682230945850427OLK_SRC_BODY_SECTION">
<div style="font-family:calibri;font-size:11pt;text-align:left;color:black;border-width:1pt medium medium;border-style:solid none none;border-bottom-color:initial;border-left-color:initial;padding:3pt 0in 0in;border-top-color:rgb(181,196,223);border-right-color:initial">
<span style="font-weight:bold">From: </span>API-users <<a href="mailto:api-users-bounces@lists.gbif.org" target="_blank">api-users-bounces@lists.gbif.<wbr>org</a>> on behalf of Herbario SANT <<a href="mailto:sant.herbarium@gmail.com" target="_blank">sant.herbarium@gmail.com</a>><br>
<span style="font-weight:bold">Date: </span>Sunday 19 February 2017 at 14:38<br>
<span style="font-weight:bold">To: </span>"<a href="mailto:api-users@lists.gbif.org" target="_blank">api-users@lists.gbif.org</a>" <<a href="mailto:api-users@lists.gbif.org" target="_blank">api-users@lists.gbif.org</a>><br>
<span style="font-weight:bold">Subject: </span>[API-users] how to check last date-time dataset was harvested?<br>
</div><div><div class="gmail-m_6951003100185910910m_-6290496056444398045h5">
<div><br>
</div>
<div>
<div>
<div dir="ltr">
<div>
<div>Hi again.</div>
<div><br>
</div>
<div>Is there any way to use GBIF portal API to know the last date & time a certain resource was harvested by GBIF? (basically, to know if it has the latest info provided by the original source, or it could be outdated)</div>
<div><br>
</div>
<div>I suspect the info in this url but I don' know how to interpretate them all:</div>
<div><br>
</div>
<div><a href="http://api.gbif.org/v1/dataset/df3eab30-0837-11d9-acb2-b8a03c50a862" target="_blank">http://api.gbif.org/v1/dataset<wbr>/df3eab30-0837-11d9-acb2-b8a03<wbr>c50a862</a><br>
</div>
<div><br>
</div>
<div>I guess this is the IPT updated time: </div>
<div><br>
</div>
<div>"modified": "2017-02-16T22:07:41.127+0000"</div>
<div><br>
</div>
<div>¿Perhaps this is what I am looking for?</div>
<div><br>
</div>
<div>"machineTags":[{..."name":"cra<wbr>wl_attempt",..."created":"2017<wbr>-01-05T12:07:12.525+0000"},...<wbr>]</div>
<div><br>
</div>
<div>Thanks a lot<br>
</div>
<div>David</div>
</div>
<div><br>
</div>
<div class="gmail_extra">
<div>-- <br>
</div>
<div class="gmail-m_6951003100185910910m_-6290496056444398045m_7894682230945850427gmail_signature">
<div>David García San León</div>
<div>Herbario SANT<br>
</div>
<div>Universidade de Santiago de Compostela<br>
</div>
<div><br>
</div>
</div>
</div>
</div>
</div>
</div>
</div></div></span>
</div>

</blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail-m_6951003100185910910m_-6290496056444398045gmail_signature"><div>David García San León</div><div>(dixitalización / control de fondos)</div><div>Herbario SANT</div><div>Facultade de Farmacia - Laboratorio de Botánica</div><div>Universidade de Santiago de Compostela</div><div>15782 - Galicia (Spain)</div><div><a href="http://www.usc.es/herbario" target="_blank">http://www.usc.es/herbario</a></div><div>Tel. <a href="tel:+34%20881%2081%2050%2022" value="+34881815022" target="_blank">+34 881815022</a></div><div>Fax <a href="tel:+34%20981%2059%2049%2012" value="+34981594912" target="_blank">+34 981594912</a></div><div>Skype: herbarium_sant</div><div>Twitter: @SANT_Herbarium</div></div>
</div></div></div></div>