API Reference

getUserConsents

The getUserConsents command enables your organization to retrieve a list of privacy choices and their opt-in status on properties who are utilizing a U.S. Multi-State Privacy (Standard) vendor list.

Command

window._sp_.usnat.getUserConsents((consents, success) => console.log(consents));

Response

{
  "applies": true,
  "categories": [
    {
      "_id": "655dde122889126b8bfcdb43",
      "systemId": 3,
      "consented": false
    }
  ],
  "vendors": [
    {
      "_id": "644b260b593fbd5396b01234",
      "consented": false
    }
  ]
}
schema:
      description: getUserConsents return
      type: object
      properties:
            applies:
                  type: boolean
                  description: "true: end-user's region is in the framework territories | false: end-user's region is not in the framework territories"
            categories:
                  type: array
                  description: "Privacy choices that are applicable to the end-users region and opt-in status for each"
                  items:
                        type: object
                        description: "Individual privacy choices that are applicable to the end-users region and opt-in status for each"
                        properties:
                              _id:
                                    type: string
                                    description: "ID of the privacy choice"
                                    example: "655dde122889126b8bfcdb43"
                              systemId:
                                    type: number
                                    description: "Indicates the ID used by the Sourcepoint system to identify the Standard privacy choice. This field will only appear for Standard privacy choices."
                                    example: 3
                              consented:
                                    type: boolean
                                    description: "Whether the privacy choice was opted into by the end-user"
                                    example: false
            vendors:
                  type: array
                  description: "Vendors configured in your U.S. Multi-State Privacy (Standard) vendor list and their consent status"
                  items:
                        type: object
                        description: "Individual vendors configured in your U.S. Multi-State Privacy (Standard) vendor list and their opt-in status."
                        properties:
                              _id:
                                    type: string
                                    description: "ID of the vendor"
                                    example: "644b260b593fbd5396b01234"
                              consented:
                                    type: string
                                    description: "Whether the vendor was opted into by the end-user"
                                    example: false