Native Message API - Vendor purpose mapping

The Vendor Purpose Mapping API is intended to be used by publishers to help determine if a vendor URL has been defined appropriately in the Sourcepoint System. This API can help developers that are integrating with Content Management Systems (CMS) verify that a URL referenced in content can be related to Vendor and Purpose consent preferences that can be queried and set based on user actions.

The vendor purpose mapping returns a JSON response describing an array of vendors, an array of categories for each vendor along with the legal basis defined. This article describes the implementation, the JSON response with examples examples of both.


GET API call - Vendor purpose mapping

In order for this API to be relevant, an administrator needs to set up the URL mappings in their Vendor Lists. The URL mapping setting can be set in the Vendor List manager, by opening the appropriate Vendor List, selecting the vendor to which you wish to maps a URL, and adding the matching rules.

vendor_match_rules.png

Any number of patterns can be added to match a URL to a vendor. These mapping must be set up in the Sourcepoint portal before this API can be used.

  Note: Do not create patterns that can be matched to multiple vendors as this will cause errors.

GET API call

This GET API call requires values for parameters to be set in the url:

https://cdn.privacy-mgmt.com/consent/tcfv2/vendor-list/vendor-purpose-mapping?siteId={SITE_ID}

Query params

Query param Required Description
{SITE_ID} Yes Site id of property setup. Can be found in the Sourcepoint dashboard

Example implementation

Your organization can call the API endpoint using a server-side script or a third-party service like Postman.

With Postman PHP code

Your organization can use a third party service like Postman to retrieve the vendor purpose mapping. You will need to provide the correct API endpoint address and values for siteID.

get_purpose_mapping.png

JSON response

The response from the native message API call is a JSON string with several objects & values. The following is a description of the JSON response with their objects and values.

Field Description
consentUUID The consent UUID value
categories object List of purposes for this message
legIntCategories object List of legitimate interest purposes for this message
vendors, legIntVendors object List of vendors for this message
dateCreated The time & date this response was created
hasConsentData true if the response has consent data

grants object

Field Description
id (in field) The Sourcepoint id for this vendor
vendorGrant true if all purposes for this vendor have been granted by the end-user
purposeGrants object List of purposes for this vendor and if end-user has approved
Sample - JSON response
{
    "consentUUID": "9d00d173-2f08-447f-80f9-b7bad187f4f0",
    "categories": [
        "5e8b11c3ebdb0627ecca27ab",
        "5e8b11c3ebdb0627ecca279c",
        "5e8b11c3ebdb0627ecca279f",
        "5e8b11c3ebdb0627ecca27a0",
        "5e8b11c3ebdb0627ecca279d",
        "5e8b11c3ebdb0627ecca279b",
        "5e8b11c3ebdb0627ecca279e",
        "5e8b11c3ebdb0627ecca27a1",
        "5e8b11c3ebdb0627ecca27a2",
        "5e8b11c3ebdb0627ecca27a3"
    ],
    "legIntCategories": [
        "5e8b11c3ebdb0627ecca279c",
        "5e8b11c3ebdb0627ecca279d",
        "5e8b11c3ebdb0627ecca279b"
    ],
    "vendors": [
        "5eab3d5ab8e05c1c467dab7a",
        "5eab3d5ab8e05c2bbe33f398",
        "5e37fc3e56a5e60dff4e1987",
        "5f369a02b8e05c2f2d546a41",
        "5e37fc3e56a5e6615502f9c3",
        "5e7ced57b8e05c485246ccd8",
        "5e7ced57b8e05c4854221bd0",
        "5e37fc3e56a5e66147767221",
        "5eb559cfb8e05c111d01b4e3",
        "5e98e7f0b8e05c1c467daaf1",
        "5e37fc3e56a5e60e003a7124",
        "5ee15bc6b8e05c164c398ae3",
        "5e37fc3e56a5e6615502f9d2",
        "5e865b36b8e05c48537f60a7",
        "5eab3d5ab8e05c241a63c5dc",
        "5e37fc3e56a5e60dff4e1986",
        "5e98e7f0b8e05c48537f6111",
        "5e7ced56b8e05c4854221bb3",
        "5f520ca8b8e05c64357e20f4",
        "5e98e7f0b8e05c1c467daaf0",
        "5eb559d0b8e05c6f984a390b",
        "5e7ced57b8e05c4854221bba",
        "5efefe25b8e05c109b4949ca",
        "5e7ced57b8e05c485246cce0",

...
...
"60e81aada228630e634e06b1" ], "legIntVendors": [ "5e7792c8d8d48d7950873ff3", "5e7f6927b8e05c48537f6074", "5e7786abf443bb795772efee", "5e77890cd8d48d7950873ef7", "5e7793636fbbc471e4b62573", "5f21834b4e23d23c6c4ce0f3", "5f2a2b392b87b72624a333f2", "5f1b2fbeb8e05c3057240f67", "5f1b2fbdb8e05c3057240f55",

...
...
"604b382da2286319d61aa96e" ], "specialFeatures": [], "euconsent": "CPOA6HgPOA6HgFZABCDEBwCgAP_AAEwAAAYgIDpb_T7V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ApQBUAFUALAAXwAxABzAD8AIYARAAmQBRgClAFiANEAasA_AD9AIsARwAlIBcwDFAG4APQAi8BOwChwF5gMYAZOA8coATAAuACQAHIAPwArABtAGoAScAnYBYgC6gGAANeAdUA8gCuwF9AMmAcEAA.YAAAAAAAAAAA", "grants": { "5e717c8e69966540e4554f05": { "vendorGrant": false, "purposeGrants": { "5e8b11c3ebdb0627ecca279b": false, "5e8b11c3ebdb0627ecca279d": false, "5e8b11c3ebdb0627ecca27a1": false, "5e8b11c3ebdb0627ecca27a4": false, "5e8b11c3ebdb0627ecca27ab": false } }, "5e717c3a9a0b5040d5750816": { "vendorGrant": false, "purposeGrants": { "5e8b11c3ebdb0627ecca279b": false, "5e8b11c3ebdb0627ecca27a0": false, "5e8b11c3ebdb0627ecca279c": true, "5e8b11c3ebdb0627ecca279f": false, "5e8b11c3ebdb0627ecca279d": false, "5e8b11c3ebdb0627ecca279e": false, "5e8b11c3ebdb0627ecca27a1": false, "5e8b11c3ebdb0627ecca27a4": false, "5e8b11c3ebdb0627ecca27ab": false } }, "5ed90e2947dbbd564700dfaa": { "vendorGrant": false, "purposeGrants": { "5e8b11c3ebdb0627ecca279b": false, "5e8b11c3ebdb0627ecca27a1": false, "5e8b11c3ebdb0627ecca27ab": false } }, "5e717ad49a0b5040d5750815": { "vendorGrant": false, "purposeGrants": { "5e8b11c3ebdb0627ecca279b": false, "5e8b11c3ebdb0627ecca27a4": false } }, "5e717a989a0b5040d5750814": { "vendorGrant": false, "purposeGrants": { "5e8b11c3ebdb0627ecca279b": false, "5e8b11c3ebdb0627ecca279d": false, "5e8b11c3ebdb0627ecca27a1": false, "5e8b11c3ebdb0627ecca27a4": false, "5e8b11c3ebdb0627ecca27ab": false } }, "5e717a249a0b5040d5750813": { "vendorGrant": false, "purposeGrants": { "5e8b11c3ebdb0627ecca279b": false, "5e8b11c3ebdb0627ecca27a1": false, "5e8b11c3ebdb0627ecca27a4": false } },
...
...
"5e37fc3e56a5e60dff4e1992": { "vendorGrant": true, "purposeGrants": { "5e8b11c3ebdb0627ecca279b": true, "5e8b11c3ebdb0627ecca27a0": true, "5e8b11c3ebdb0627ecca279c": true, "5e8b11c3ebdb0627ecca279f": true, "5e8b11c3ebdb0627ecca279d": true, "5e8b11c3ebdb0627ecca279e": true, "5e8b11c3ebdb0627ecca27a1": true, "5e8b11c3ebdb0627ecca27a3": true, "5e8b11c3ebdb0627ecca27ab": true } }, "5e71764c69966540e4554f02": { "vendorGrant": true, "purposeGrants": { "5f20425eebd78b75ded8197a": true } } }, "dateCreated": "2021-10-15T15:58:01.118Z", "hasConsentData": true }
Was this article helpful?
0 out of 0 found this helpful