Tip via Gift Card
Enables a user to leave a tip (gratuity) using a gift card
Path Parameters
- Type: stringuuidrequired
Unique ID of the gift card used for the tip
Headers
- Type: stringx
-pch -digest requiredThe signature for the API call
- Type: stringAuthorizationrequired
Used to authorize the request with access_token. It should be supplied as
Bearer ACCESS_TOKEN_GOES_HERE. - Type: stringContent
- Type requiredSet this header to application/json.
- Type: stringAcceptrequired
Advertises which content types the client is able to understand
- Type: stringAccept
- Language Preferred language
- Type: stringUser
- Agent requiredUsed to identify the software, device, and application initiating the request, providing information about the client to the server. For details, see User Agent.
Body
application/json
- Type: integercheckin
_id requiredIdentifier of the check-in/order for which the tip is given
- Type: stringclientrequired
OAuth client ID provided by the business
- Type: numbertiprequired
Currency value of the tip, which should be less than or equal to the gift card balance
Responses
- application/json
Request Example for post/api2/mobile/gift_cards/{uuid}/tip
curl 'https://SERVER_NAME_GOES_HERE.punchh.com/api2/mobile/gift_cards/{uuid}/tip' \
--request POST \
--header 'x-pch-digest: {{$$.env.signature}}' \
--header 'Authorization: Bearer ACCESS_TOKEN_GOES_HERE' \
--header 'Content-Type: application/json' \
--header 'Accept: application/json' \
--header 'Accept-Language: en' \
--header 'User-Agent: AppName/AppVersion/BuildNumber (OS; Model; MANUFACTURER; MODEL; OS Version)' \
--data '{
"client": "CLIENT_GOES_HERE",
"checkin_id": 47004327,
"tip": 4.52
}'
{
"tipping_time": "2018-03-12T11:30:20+00:00",
"checkin_id": 47004327,
"location_id": 315736,
"approved_amount": 4.52,
"gift_card_uuid": "UUID_GOES_HERE"
}