gsapi - Drupal Grocery Server API
=================================
Drupal wrapper for the Grocery Server API. This implementation requires that
you provide Grocery Server with your recipes and that they have been imported
into the Grocery Service API.
Unless otherwise noted, all services return geo-targeted data automatically
based on the results of the `gsapi_zip()` function. This explains why, for
example, you don't need to provide a zip code argument to geo targeted API
calls.
Functions
---------
###Get Recipe Details###
gsapi_grd($rid)
*Parameters: $rid integer*
> Recipe ID as defined in the XML document provided to Grocery Server.
> Usually the Drupal Node ID.
*Return: array*
> Array representing the recipe and any current promotions for ingredients
> based on the user's zip code. Results are cached for 24 hours.
###Get Recipe Promotion Count###
gsapi_grpc($rid)
*Parameters: $rid integer*
> Recipe ID as defined in the XML document provided to Grocery Server.
> Usually the Drupal Node ID.
*Return: integer*
> The number of current promotions for the provided Recipe ID.
###Grocery Server Request###
gsapi_request($service, $args = null)
Interacts directly with the Grocery Server API.
*Parameter: $service string*
Allowed Values (See `gsapi.services.inc`:
* `getClosestZipCode`