Skip to content

Product Properties

Overview

Scalar properties will always be included in a response, unless otherwise specified.

Generic Properties

ID

Key Name: id

Example: "f204ed28-b230-4d0a-8c63-48e65a070f35"

A globally unique identifier for the Product. In most circumstances, this will be a GUID.

Created At

Key Name: created_at

Example: "2018-11-02 10:37:39"

A time stamp representing when the product was created in the CMS. Largely pointless for front end apps.

Updated At

Key Name: updated_at

Example: "2018-11-05 17:16:14"

A time stamp represented when the product was last updated in the CMS. Largely pointless for front end apps. Note: The definition of "updated" is quite broad.

Brand ID

Key Name: brand_id

Example: "f204ed28-b230-4d0a-8c63-48e65a070f35"

A globally unique identifier for the Brand this belongs to.

Often, Products are returned with (as a child of) their Brands, so this may not be particularly helpful.

Active

Key Name: active

Example: 1 (true) or 0 (false)

An integer (1 or 0) representing if this Product is active. Inactive products should not be presented to users, and are not returned by the API to app-facing endpoints.

On App

Key Name: on_app

Example: 1 (true) or 0 (false)

An integer (1 or 0) representing if this Product is on the main app.

On iMessage

Key Name: on_imessage

Example: 1 (true) or 0 (false)

An integer (1 or 0) representing if this Product is on the iMessage app.

Brand Name

Key Name: brand_name

Example: "Generic Coffee Co"

The name of this Product's Brand.

Payment Properties

Sale Price

Key Name sale_price

Example: 1000 (£10)

Example: 350 (£3.50)

An integer representing the price for this product in pence.

Handling Fee

Key Name: handling_fee

Example: 20 (20p)

An integer representing the handling fee for this product in pence.

Voucher

This field's information is not complete

Key Name: voucher

Campaign

This field's information is not complete

Key Name: campaign

Example: "9911"

Used for an EPOS system - possibly NCR?

Integration

Do not use this field.

Warning

This is returned as a string of JSON, rather than just a JSON object. If you want to read this you will need to decode this field explicitly.

Key Name: integration

Example:

"{\"id\":2,\"created_at\":"\2018-11-02 10:37:00\",\"updated_at\":\"2018-11-02 10:37:00\",\"label\":\"Code\",\"type\":1}"

This is a JSON representation of a Brand's Integration. This will be returned as a string of JSON embedded in your response, rather than just part of the JSON response itself, so you will have to decode this a second time if you want to use it.

Tag Group ID

This field's information is not complete

Key Name: tag_group_id

Probably used by NCR?

Tag ID

This field's information is not complete

Key Name: tag_id

Probably used by NCR?

UI / Text Properties

Description

Key Name: description

Example: "Anything from the Coffee or Whole Leaf Tea menus."

A human readable description of what the product is / covers.

Label (Name)

Key Name: label

Example: "Coffee"

This is the name of the product and is typically used as the main label / title when presenting it to the user during purchasing.

Over 18 Offer

Key Name: over_18_offer

Example: 1 (true) or 0 (false)

An integer (1 or 0) representing if this is an offer which is limited to over 18s. This is typically used for restricted products, such as alcohol. Apps should confirm a user is over 18 before allowing them to purchase such a product.

Redemption Instructions

Key Name: redemption_instructions

Example: "Comp drink using 'HUGGG HOT DRINK' button and enter PIN"

The instructions to be displayed to the Barista when redeeming.

Subtitle (Locations)

The name of this field is misleading

Key Name: subtitle

Example: "Bath and Bristol"

This text, originally used as an abstract subtitle for a product, is now used exclusively to display a human readable text explaining where the product can be redeemed. This will always be phrased such that "redeemable in [subtitle]" would make grammatical sense.

Recipient Description

Warning

This currently always will end with a full stop - do not add a second full stop after this text

Key Name: recipient_description

Example: "Swap your huggg for anything from the Coffee menus."

This text is displayed on redemption / stash screens as a friendly, human-readable description of the product for the receiver of a huggg.

Brand Weight

Key Name: brand_weight

Example: 1

See Brand.

Images

Warning

Many image names end in .gif despite not actually being GIFs (many are PNG). Be wary of image formats.

Image Url

Key Name: image

Example: "http://api.huggg.me/images/some-image.gif"

The URL of the image to be used for the Product in the UI.

iMessage Image Url

Key Name: imessage_image_url

Example: "http://api.huggg.me/images/some-image.gif"

The URL of the image to be used for the Product when displayed on iMessage.

Open Graph Image Url

Key Name: open_graph_image_url

Example: "http://api.huggg.me/images/some-image.gif"

The name of the image to be used for the Product's open graph pictures; as a result, this shows up when viewing in whatsapp / sharing on Facebook etc.