FANDOM


Update an existing Sighting. The Sighting may only be updated by the user who created it and if the user isn’t the owner a permission_denied error is returned.

The Sighting to update is specified by the user_id and sighting_id in the url.

Url: https://resighting-api.appspot.com/api/1/sightings/<user_id>/<sighting_id>

HTTP Method: POST

ParametersEdit

Name Type Mandatory Description
access_token String(32) Yes A valid access token.
blobtracker_id String(200) No

If you wish to delete the existing evidence of the Sighting, pass an empty string.

If you wish to update the evidence pass the blobtracker_id returned by the Upload method of the new evidence image to use.

description String(200) No The new description of the Sighting. The description must not be zero length.
hold Boolean No

If the Sighting is on hold then passing ‘false’ here will release the Sighting. If the Sighting is not on hold then it will have no effect.

Passing ‘true’ will cause an invalid_request error.

publish_to_facebook Boolean No

Whether the Sighting should be published to the user’s Facebook feed. If the user hasn’t linked their Resighting account to Facebook then this flag has no effect.

This can only be changed while a Sighting is on hold. If the Sighting is not on hold then an invalid_request error will be returned.

sandbox Boolean No Whether the method should run in sandbox mode - no writes will be made to the datastore.
tweet_sighting Boolean No

Whether the Sighting should be tweeted. If the user hasn’t linked their Resighting account to Twitter then this flag has no effect.

This can only be changed while a Sighting is on hold. If the Sighting is not on hold then an invalid_request error will be returned.

ReturnsEdit

Returns a Sighting object and HTTP status 200, or an Error object and HTTP status 4xx or 5xx. If the sandbox parameter was set then the returned object will contain dummy data and a boolean attribute named sandbox, which will have the value True. See the section on sandboxing for more details.

Example UsageEdit

curl https://resighting-api.appspot.com/api/1/sightings/bf10ad015e7b4ceea9279c1b9e8889a5/492003 --data access_token=ACCESS_TOKEN --data description="Pulse"

Ad blocker interference detected!


Wikia is a free-to-use site that makes money from advertising. We have a modified experience for viewers using ad blockers

Wikia is not accessible if you’ve made further modifications. Remove the custom ad blocker rule(s) and the page will load as expected.