Skip to content

Creating Consent

Variables - Details

Name Description Required
itemType offer type, for OTT's is usually 'ADDON' Required
actionType Action to be done on the offer, Eg : ADD/REMOVE Required
quantity Quantity of offer instance to be added to cart Required
salesJourneyId sales journey id that was received when sales session is initialized Required
catalogId Unique identifier of the offer in the catalog Required

API Specs

GraphQL API

Ready

This API is available in both integration and production.

HTTP Item HTTP Value
Url https://{host}/graphql
Method POST

 
mutation Mutation($salesJourneyId: String!) {
    createConsent(salesJourneyId: $salesJourneyId) {
        salesJourneyId
        consent {
        consentInfo {
            consentId
            status
        }
        items {
                offerId
                chargeDetails{
                    chargeType
                    currency
                    charges
                    chargeFrequency
                    duration
                }
                metadata{
                    name
                    value
                }
                presentationContents
                {
                    name
                    content
                }
                termsOfServices{
                    items {
                        id
                        description
                    }
                }
        }
        }
    }
}

 
{
    "salesJourneyId": "{{ salesJourneyId }}"
}

None

None

 
{
    "data": {
        "createConsent": {
            "salesJourneyId": "20eaf0fd-800e-47b0-bff7-5a0c6675b01f",
            "consent": {
                "consentInfo": {
                    "consentId": "3405d6b6-f1f6-46d8-9225-48ce83690731",
                    "status": "PENDING"
                },
                "items": [
                    {
                        "offerId": "EPO-90-200007",
                        "chargeDetails": [
                            {
                                "chargeType": null,
                                "currency": "USD",
                                "charges": null,
                                "chargeFrequency": null,
                                "duration": null
                            }
                        ],
                        "metadata": [
                            {
                                "name": "productName",
                                "value": "Apple TV Plus"
                            },
                            {
                                "name": "productDescription",
                                "value": "ENTMT - Apple TV+ ALC"
                            },
                            {
                                "name": "productId",
                                "value": "EPP-80-400006"
                            },
                            {
                                "name": "productVersion",
                                "value": "1"
                            },
                            {
                                "name": "productType",
                                "value": "Feature"
                            },
                            {
                                "name": "productFamily",
                                "value": ""
                            },
                            {
                                "name": "lineOfService",
                                "value": "['TPP']"
                            },
                            {
                                "name": "epcUiCategory",
                                "value": ""
                            },
                            {
                                "name": "epcProductRank",
                                "value": "0"
                            },
                            {
                                "name": "epcProductNumber",
                                "value": "NA"
                            },
                            {
                                "name": "technicalProductId",
                                "value": ""
                            },
                            {
                                "name": "minQuantity",
                                "value": "0"
                            },
                            {
                                "name": "maxQuantity",
                                "value": "1"
                            },
                            {
                                "name": "preventRemoval",
                                "value": "False"
                            },
                            {
                                "name": "productCategories",
                                "value": "['Feature']"
                            },
                            {
                                "name": "primaryProductCategory",
                                "value": "Feature"
                            },
                            {
                                "name": "durableAppId",
                                "value": "apple_inc_apple_tv"
                            },
                            {
                                "name": "description",
                                "value": "ENTMT - Apple TV+ ALC"
                            },
                            {
                                "name": "los",
                                "value": "['TPP']"
                            },
                            {
                                "name": "integrationType",
                                "value": "MANAGED_ORDER"
                            },
                            {
                                "name": "productKey",
                                "value": "CTUS_MVPD_ATV_CPAID"
                            },
                            {
                                "name": "partner",
                                "value": "comcast, xglobal"
                            },
                            {
                                "name": "entitlementProvider",
                                "value": "Bango"
                            },
                            {
                                "name": "shortNm",
                                "value": "Apple TV+"
                            },
                            {
                                "name": "appId",
                                "value": "apple_inc_apple_tv"
                            }
                        ],
                        "presentationContents": [
                            {
                                "name": "ProductName",
                                "content": "Apple TV+"
                            },
                            {
                                "name": "ProductNumber",
                                "content": "EPO-90-200007"
                            },
                            {
                                "name": "ImageURL",
                                "content": "https://assets.xfinity.com/assets/dotcom/flex/appletv_plus.svg"
                            },
                            {
                                "name": "ProductFamilyName",
                                "content": "Apple TV+"
                            },
                            {
                                "name": "PromoDescription",
                                "content": "Easily add and manage new streaming services with Xumo."
                            },
                            {
                                "name": "PromoTitle",
                                "content": "Enjoy star-studded originals and live sports"
                            },
                            {
                                "name": "BannerImageXS",
                                "content": "https://assets.xfinity.com/assets/dotcom/flex/apple_banner_xs.png"
                            },
                            {
                                "name": "BannerImageLG",
                                "content": "https://assets.xfinity.com/assets/dotcom/flex/apple_banner_lg.png"
                            }
                        ],
                        "termsOfServices": [
                            {
                                "items": [
                                    {
                                        "id": "TOS_APPLETV",
                                        "description": "By clicking Subscribe, I agree to the sharing of certain personal information, including account, device and billing information, between Xfinity and Apple to enable my access and use of the application and app-related purchases through the service and related marketing. Xumo will process information in accordance with its Privacy Policy, available at [insert Xumo privacy policy URL]. Use of Apple's service is governed by the Apple Terms of Use [insert Apple terms of use] and Privacy Policy [insert Apple privacy policy]. Apple content is Internet delivered and will count against any data plan, if applicable."
                                    }
                                ]
                            }
                        ]
                    }
                ]
            }
        }
    }
}

 
{
    "errors" : []
}

Coming soon

REST API

Info

This API is available in integration. Will be available in production in few days.

HTTP Item HTTP Value
Url https://{host}/{salesJourneyId}/cart
Method POST

None

Param Name Description Required
salesJourneyId The id you got from init step Required

 
{
    "salesJourneyId": "string",
    "consent": {
        "consentInfo": {
        "consentId": "string",
        "status": "string"
        },
        "items": [
        {
            "offerId": "string",
            "chargeDetails": [
            {
                "currency": "string",
                "charges": 0,
                "chargeType": "string",
                "chargeFrequency": "string",
                "duration": 0
            }
            ],
            "metadata": [
            {
                "name": "string",
                "value": "string"
            }
            ],
            "presentationContents": [
            {
                "name": "string",
                "content": "string"
            }
            ],
            "termsOfServices": [
            {
                "items": [
                {
                    "id": "string",
                    "description": "string"
                }
                ]
            }
            ]
        }
        ]
    }
}

 
{
    "errorCode" :  "",
    "errorMessage" : "",
    "severity" : ""
}

Coming soon

REST API - V2

Info

This API is available in integration. Will be available in production in few days.

HTTP Item HTTP Value
Url https://{host}/v2/partners/{partnerId}/accounts/{accountId}/salesJourneys/{salesJourneyId}/cart/consent
Method POST

None

Param Name Description Required
partnerId Partner id such as xglobal/comcast Required
serviceAccountNumber XBO service account number Required
salesJourneyId The id you got from init step Required

 
{
    "salesJourneyId": "string",
    "presentedConsent": "string",
    "termsOfServices": [
        {
        "termReferenceId": "string",
        "termDescription": [
            {
            "locale": "string",
            "description": [
                "string"
            ]
            }
        ]
        }
    ]
}

 
{
    "errorCode" :  "",
    "errorMessage" : "",
    "severity" : ""
}

Coming soon