Retrieve reward
curl --request GET \
--url https://api-testbed.giftbit.com/papi/v1/gifts/{uuid} \
--header 'Authorization: Bearer <token>'import requests
url = "https://api-testbed.giftbit.com/papi/v1/gifts/{uuid}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api-testbed.giftbit.com/papi/v1/gifts/{uuid}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api-testbed.giftbit.com/papi/v1/gifts/{uuid}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api-testbed.giftbit.com/papi/v1/gifts/{uuid}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api-testbed.giftbit.com/papi/v1/gifts/{uuid}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api-testbed.giftbit.com/papi/v1/gifts/{uuid}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"gift": {
"uuid": "d30be501ed2546e580c5c9eaf56633d9",
"campaign_uuid": "8f5835dfb637413793c5d55f8ea95e23",
"delivery_status": "DELIVERED",
"status": "SENT_AND_REDEEMABLE",
"redelivery_count": 0,
"campaign_id": "may11",
"price_in_cents": 500,
"brand_code": "itunesus",
"created_date": "2016-05-11 12:18:25",
"delivery_date": "2016-05-11 12:18:32"
},
"info": {
"code": "INFO_GIFTS",
"name": "Gift information retrieved",
"message": "Returned gifts matching your search parameters."
},
"status": 200
}Retrieve reward
Retrieves a single reward by its uuid.
GET
/
gifts
/
{uuid}
Retrieve reward
curl --request GET \
--url https://api-testbed.giftbit.com/papi/v1/gifts/{uuid} \
--header 'Authorization: Bearer <token>'import requests
url = "https://api-testbed.giftbit.com/papi/v1/gifts/{uuid}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api-testbed.giftbit.com/papi/v1/gifts/{uuid}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api-testbed.giftbit.com/papi/v1/gifts/{uuid}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api-testbed.giftbit.com/papi/v1/gifts/{uuid}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api-testbed.giftbit.com/papi/v1/gifts/{uuid}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api-testbed.giftbit.com/papi/v1/gifts/{uuid}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"gift": {
"uuid": "d30be501ed2546e580c5c9eaf56633d9",
"campaign_uuid": "8f5835dfb637413793c5d55f8ea95e23",
"delivery_status": "DELIVERED",
"status": "SENT_AND_REDEEMABLE",
"redelivery_count": 0,
"campaign_id": "may11",
"price_in_cents": 500,
"brand_code": "itunesus",
"created_date": "2016-05-11 12:18:25",
"delivery_date": "2016-05-11 12:18:32"
},
"info": {
"code": "INFO_GIFTS",
"name": "Gift information retrieved",
"message": "Returned gifts matching your search parameters."
},
"status": 200
}Authorizations
Send your API token prefixed by Bearer in the Authorization header.
Path Parameters
The uuid of the reward. Not to be mistaken for the uuid or id of the order.