Skip to content

Reference String

When creating an item, a reference value will be returned in the metdata with this format:

  • <scheme>:<entity-type-str>#<owner>@<id>

This uses the full entity type string format, which can be used to reference any entity type in the THG Connect Platform. It follows the format <product>:<parent entity type>.<child entity type>, for example:

/api/thg-fulfil/v1/providercompany/fulfilment-request/340fd-3s9f3e034-fs93434/dispatched/93sf39-wf839rs-srs3r34

the entity type str would be thg-fulfil:fulfilment-request.dispatched and the reference string would be thg:thg-fulfil:fulfilment-request.dispatched#providercompany@93sf39-wf839rs-srs3r34

{
    "data": {
        "attributes": {
            "courierService": {
                "name": "Evri",
                "service": "Evri Packet Standard"
            },
            "dispatchedDate": "2026-02-11T00:00:00+00:00",
            "lines": [
                {
                    "batchNumber": null,
                    "condition": "GOOD",
                    "dispatchedQuantity": 1,
                    "expectedQuantity": 1,
                    "expiryDate": null,
                    "lineId": "1",
                    "serialNumber": null
                }
            ],
            "tracking": {
                "number": "HZYEJA12345",
                "url": "https://www.evri.com/track/#/parcel/HZYEJA12345/details"
            }
        },
        "id": "511a3f57-2154-418e-928e-1b91e3d1b589",
        "meta": {
            "createdAt": "2026-02-11T13:09:43.710356",
            "creator": "providercompany",
            "owner": "providercompany",
            "parent": {
                "thg-fulfil:fulfilment-request": "1203490454434"
            },
            "product": "thg-fulfil",
            "reference": "thg:thg-fulfil:fulfilment-request.dispatched#providercompany@511a3f57-2154-418e-928e-1b91e3d1b730",
            "updatedAt": "2026-02-11T13:09:43.710356"
        },
        "type": "thg-fulfil:fulfilment-request.dispatched",
        "version": "1"
    },
    "meta": {}
}

The entity type string can be found under data.type and the reference string for the entity data.meta.reference