Skip to main content
07399 456 959 [email protected]

Gift Categories Images Object
Last updated: January 05 2022 11:19 PM

We supply a default set of images for each gift category in the gift categories images object.

All images in the gift categories images object can be deleted and your own images uploaded through our Content Management System (CMS). When you upload an image our CMS will automatically create multiple sizes and multiple formats. You can set the image sizes and formats you require.

Gift Categories Images Object

Attribute Type Description
images array[object] An array containing images in various formats.
images.largeFrontImageWebp string Returns a url for a large front view image 'image/webp' (600 X 600) px
images.largeFrontImagePng string Returns a url for a large front view image 'image/png' (600 X 600) px
images.largeFrontImageJpg string Returns a url for a large front view image 'image/jpg' (600 X 600) px

Gift Categories Expand Images Request Example

GET
https://api.uconvert.co.uk/deals/v1/gifts/categories/?expand=giftcategories(images)
{
  "giftCategories" : [
    {
      "id": "2",
      "name": "Games Consoles Deals",
      "slug": "games-consoles-deals",
      "images": {
        "largeFrontImageWebp": "http://static.local.co.uk/img/gifts/default/games-consoles-deals.webp",
        "largeFrontImagePng": "http://static.local.co.uk/img/gifts/default/games-consoles-deals.png",
        "largeFrontImageJpg": "http://static.local.co.uk/img/gifts/default/games-consoles-deals.jpg"
      }
    },
    {
      "id": "4",
      "name": "Laptops Deals",
      "slug": "laptops-deals",
      "images": {
        "largeFrontImageWebp": "http://static.local.co.uk/img/gifts/default/laptops-deals.webp",
        "largeFrontImagePng": "http://static.local.co.uk/img/gifts/default/laptops-deals.png",
        "largeFrontImageJpg": "http://static.local.co.uk/img/gifts/default/laptops-deals.jpg"
      }
    }
  ]
}
$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => "https://api.uconvert.co.uk/deals/v1/gifts/categories/?expand=giftcategories(images)",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => array(
    "x-api-key: 123456"
  ),
));

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
curl --request GET \
  --url 'https://api.uconvert.co.uk/deals/v1/gifts/categories/?expand=giftcategories(images)' \
  --header 'x-api-key: 123456'
var settings = {
  "async": true,
  "crossDomain": true,
  "url": "https://api.uconvert.co.uk/deals/v1/gifts/categories/?expand=giftcategories(images)",
  "method": "GET",
  "headers": {
    "x-api-key": "123456"
  }
}

$.ajax(settings).done(function (response) {
  console.log(response);
});
require 'uri'
require 'net/http'

url = URI("https://api.uconvert.co.uk/deals/v1/gifts/categories/?expand=giftcategories(images)")

http = Net::HTTP.new(url.host, url.port)

request = Net::HTTP::Get.new(url)
request["x-api-key"] = '123456'

response = http.request(request)
puts response.read_body