/guide/download
From EveryTrail API Developer Documentation
Contents |
URL
/api/guide/download
Semantics
Call to download a trip. If the guide is not free, credits will be deducted from the specified user's account. Credits can also be added in this call.
Parameters
| Parameter name | Parameter format | Required | Description |
|---|---|---|---|
| username | string | yes | username of user performing the request |
| password | string | yes | password of user performing the request |
| url | string | yes | url of the trip ("half-dome-hike") |
| return_types | bitmask | no | A bitwise OR of the data to return (see below), default is all |
| receipt_data | string | no | base64 encoded receipt data from apple purchase |
ReturnTypes
- 0x1: Basic data
- 0x2: POIs
- 0x4: Child Guides (for guide sets)
- 0x8: track data
- 0x16: waypoint data
Success Response
<etGuideDownloadReponse status="success"> <guideUrl>${guideUrl}</guideUrl> <purchaseStatus>${purchaseStatus}</tripID> ${guideXML} </etGuideDownloadReponse>
${trip ID}: ID of trip on the server as int
${purchaseStatus}
0: purchased
1: already purchased (did not charge again)
Error Reponse
<etGuideDownloadReponse status="error"> <guideUrl>${guideUrl}</guideUrl> ${error reponse} </etGuideDownloadReponse>
