Skip to content
This repository has been archived by the owner on Dec 16, 2020. It is now read-only.

Commit

Permalink
+Set location
Browse files Browse the repository at this point in the history
Set location to get JSON array with geofilters, get access to local stories, weather, and lens filters.
  • Loading branch information
dundua committed Oct 11, 2015
1 parent 6d4d7f5 commit c853884
Showing 1 changed file with 39 additions and 0 deletions.
39 changes: 39 additions & 0 deletions src/snapchat.php
Original file line number Diff line number Diff line change
Expand Up @@ -3184,4 +3184,43 @@ public function getSnaptag()

return $result;
}

/**
* Set/update your location for geofilters, weather info, and local stories.
*
* @param int $lat
* Latitude.
*
* @param int $lon
* Longitude.
*
* @param int $acc
* Accuracy in meters.
*
* @return json array
* Returns a JSON array with geofilters, local our stories, weather, and lens filters.
*/
public function setLocation($lat, $lon, $acc)
{
$timestamp = parent::timestamp();
$result = parent::post(
'/loq/loc_data',
array(
'timestamp' => $timestamp,
'lat' => $lat,
'long' => $lon,
'loc_accuracy_in_meters' => $acc,
'checksums_dict' => '{}',
'username' => $this->username
),
array(
$this->auth_token,
$timestamp,
),
$multipart = false,
$debug = $this->debug,
);

return $result;
}
}

0 comments on commit c853884

Please sign in to comment.