cancel
Showing results for 
Search instead for 
Did you mean: 

SAP Marketing Campaign Restriction from SmartEdit TileFilterCategory value is missing.

dominik_gorkiewicz
Discoverer

Hi,

I'm currently integrating SAP Cloud Commerce with SAP Cloud Marketing, what I want to do right now is to use SAP Marketing Campaign Restriction form SmartEdit

As you can see on the screenshot above, my Campaign list is empty, I was sure that my configuration is fine so I decided to find out what request is coming from Commerce and use it in Postman to see the results.

Request:

{Marketing URL}/sap/opu/odata/sap/CUAN_INITIATIVE_SRV/Initiatives?saml2=disabled&%24select=InitiativeId%2CName%2CTargetGroup%2FCustomerMemberCount&%24expand=TargetGroup&%24filter=Category%2FCategoryCode+eq+%27CME%27+and+Search%2FSearchTerm+eq+%27%27+and+%28Search%2FTileFilterCategory+eq+%271%27+or+Search%2FTileFilterCategory+eq+%272%27%29&%24orderby=InitiativeId&%24top=10&%24skip=0Response:

Response:
<feed xmlns="http://www.w3.org/2005/Atom" xmlns:m="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata" xmlns:d="http://schemas.microsoft.com/ado/2007/08/dataservices" xml:base="{Marketing URL}/sap/opu/odata/sap/CUAN_INITIATIVE_SRV/">
    <id>{Marketing URL}/sap/opu/odata/sap/CUAN_INITIATIVE_SRV/Initiatives</id>
    <title type="text">Initiatives</title>
    <updated>2020-04-07T11:37:40Z</updated>
    <author>
        <name/>
    </author>
    <link href="Initiatives" rel="self" title="Initiatives"/>
</feed>
List is empty, just like in SmartEdit. I decided to edit request to find out what's the reason that the list of campaigns is empty. When I removed fragment TileFilterCategory multiple Campaign entries were received, here is example with one of them:
    <entry>
        <id>https://my304618.s4hana.ondemand.com:443/sap/opu/odata/sap/CUAN_INITIATIVE_SRV/Initiatives('0000000019')</id>
        <title type="text">Initiatives('0000000019')</title>
        <updated>2020-04-07T11:48:11Z</updated>
        <category term="CUAN_INITIATIVE_SRV.Initiative" scheme="http://schemas.microsoft.com/ado/2007/08/dataservices/scheme"/>
        <link href="Initiatives('0000000019')" rel="self" title="Initiative"/>
        <link href="Initiatives('0000000019')/TargetGroup" rel="http://schemas.microsoft.com/ado/2007/08/dataservices/related/TargetGroup" type="application/atom+xml;type=entry" title="TargetGroup">
            <m:inline>
                <entry xml:base="{Marketing URL}/sap/opu/odata/sap/CUAN_INITIATIVE_SRV/" xmlns="http://www.w3.org/2005/Atom" xmlns:m="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata" xmlns:d="http://schemas.microsoft.com/ado/2007/08/dataservices">
                    <id>{Marketing URL}/sap/opu/odata/sap/CUAN_INITIATIVE_SRV/TargetGroups('0000000035')</id>
                    <title type="text">TargetGroups('0000000035')</title>
                    <updated>2020-04-07T11:48:11Z</updated>
                    <category term="CUAN_INITIATIVE_SRV.TargetGroup" scheme="http://schemas.microsoft.com/ado/2007/08/dataservices/scheme"/>
                    <link href="TargetGroups('0000000035')" rel="self" title="TargetGroup"/>
                    <content type="application/xml">
                        <m:properties>
                            <d:CustomerMemberCount>2</d:CustomerMemberCount>
                        </m:properties>
                    </content>
                </entry>
            </m:inline>
        </link>
        <content type="application/xml">
            <m:properties xmlns:m="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata" xmlns:d="http://schemas.microsoft.com/ado/2007/08/dataservices">
                <d:Name>Blank Campaign</d:Name>
                <d:InitiativeId>0000000019</d:InitiativeId>
            </m:properties>
        </content>
    </entry>

It become clear that TileFilterCategory is the problem. Documentation says that Search/TileFilterCategory - Returns only active and planned campaigns.

It looked like I have campaigns in SAP Marketing that are not active nor planned, but it is not true.
I decided to modify previous request once more, so retrieved campaign entry will contain value of Search/TileFilterCategory. Just to remind you, original requests wants campaigns with Search/TileFilterCategory = 1 or Search/TileFilterCategory = 2.

Request:

{Marketing URL}/sap/opu/odata/sap/CUAN_INITIATIVE_SRV/Initiatives?saml2=disabled&%24select=Search%2CName%2CTargetGroup%2FCustomerMemberCount&%24expand=TargetGroup&%24filter=Category%2FCategoryCode+eq+%27CME%27

Response(part of it):

<feed xmlns="http://www.w3.org/2005/Atom" xmlns:m="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata" xmlns:d="http://schemas.microsoft.com/ado/2007/08/dataservices" xml:base="{Marketing URL}/sap/opu/odata/sap/CUAN_INITIATIVE_SRV/">
    <id>{Marketing URL}/sap/opu/odata/sap/CUAN_INITIATIVE_SRV/Initiatives</id>
    <title type="text">Initiatives</title>
    <updated>2020-04-07T11:58:29Z</updated>
    <author>
        <name/>
    </author>
    <link href="Initiatives" rel="self" title="Initiatives"/>
    <entry>
        <id>{Marketing URL}/sap/opu/odata/sap/CUAN_INITIATIVE_SRV/Initiatives('0000000019')</id>
        <title type="text">Initiatives('0000000019')</title>
        <updated>2020-04-07T11:58:29Z</updated>
        <category term="CUAN_INITIATIVE_SRV.Initiative" scheme="http://schemas.microsoft.com/ado/2007/08/dataservices/scheme"/>
        <link href="Initiatives('0000000019')" rel="self" title="Initiative"/>
        <link href="Initiatives('0000000019')/TargetGroup" rel="http://schemas.microsoft.com/ado/2007/08/dataservices/related/TargetGroup" type="application/atom+xml;type=entry" title="TargetGroup">
            <m:inline>
                <entry xml:base="{Marketing URL}/sap/opu/odata/sap/CUAN_INITIATIVE_SRV/" xmlns="http://www.w3.org/2005/Atom" xmlns:m="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata" xmlns:d="http://schemas.microsoft.com/ado/2007/08/dataservices">
                    <id>{Marketing URL}/sap/opu/odata/sap/CUAN_INITIATIVE_SRV/TargetGroups('0000000035')</id>
                    <title type="text">TargetGroups('0000000035')</title>
                    <updated>2020-04-07T11:58:29Z</updated>
                    <category term="CUAN_INITIATIVE_SRV.TargetGroup" scheme="http://schemas.microsoft.com/ado/2007/08/dataservices/scheme"/>
                    <link href="TargetGroups('0000000035')" rel="self" title="TargetGroup"/>
                    <content type="application/xml">
                        <m:properties>
                            <d:CustomerMemberCount>2</d:CustomerMemberCount>
                        </m:properties>
                    </content>
                </entry>
            </m:inline>
        </link>
        <content type="application/xml">
            <m:properties xmlns:m="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata" xmlns:d="http://schemas.microsoft.com/ado/2007/08/dataservices">
                <d:Search m:type="CUAN_INITIATIVE_SRV.SearchParameterCT">
                    <d:SearchTerm></d:SearchTerm>
                    <d:TileFilterCategory></d:TileFilterCategory>
                </d:Search>
                <d:Name>Blank Campaign</d:Name>
            </m:properties>
        </content>
    </entry>
    <entry>
        <id>{Marketing URL}/sap/opu/odata/sap/CUAN_INITIATIVE_SRV/Initiatives('0000000026')</id>
        <title type="text">Initiatives('0000000026')</title>
        <updated>2020-04-07T11:58:29Z</updated>
        <category term="CUAN_INITIATIVE_SRV.Initiative" scheme="http://schemas.microsoft.com/ado/2007/08/dataservices/scheme"/>
        <link href="Initiatives('0000000026')" rel="self" title="Initiative"/>
        <link href="Initiatives('0000000026')/TargetGroup" rel="http://schemas.microsoft.com/ado/2007/08/dataservices/related/TargetGroup" type="application/atom+xml;type=entry" title="TargetGroup">
            <m:inline>
                <entry xml:base="{Marketing URL}/sap/opu/odata/sap/CUAN_INITIATIVE_SRV/" xmlns="http://www.w3.org/2005/Atom" xmlns:m="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata" xmlns:d="http://schemas.microsoft.com/ado/2007/08/dataservices">
                    <id>{Marketing URL}/sap/opu/odata/sap/CUAN_INITIATIVE_SRV/TargetGroups('0000000038')</id>
                    <title type="text">TargetGroups('0000000038')</title>
                    <updated>2020-04-07T11:58:29Z</updated>
                    <category term="CUAN_INITIATIVE_SRV.TargetGroup" scheme="http://schemas.microsoft.com/ado/2007/08/dataservices/scheme"/>
                    <link href="TargetGroups('0000000038')" rel="self" title="TargetGroup"/>
                    <content type="application/xml">
                        <m:properties>
                            <d:CustomerMemberCount>1</d:CustomerMemberCount>
                        </m:properties>
                    </content>
                </entry>
            </m:inline>
        </link>
        <content type="application/xml">
            <m:properties xmlns:m="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata" xmlns:d="http://schemas.microsoft.com/ado/2007/08/dataservices">
                <d:Search m:type="CUAN_INITIATIVE_SRV.SearchParameterCT">
                    <d:SearchTerm></d:SearchTerm>
                    <d:TileFilterCategory></d:TileFilterCategory>
                </d:Search>
                <d:Name>Dominik Email Campaign</d:Name>
            </m:properties>
        </content>
    </entry>
    <entry>
        <id>{Marketing URL}/sap/opu/odata/sap/CUAN_INITIATIVE_SRV/Initiatives('0000000020')</id>
        <title type="text">Initiatives('0000000020')</title>
        <updated>2020-04-07T11:58:29Z</updated>
        <category term="CUAN_INITIATIVE_SRV.Initiative" scheme="http://schemas.microsoft.com/ado/2007/08/dataservices/scheme"/>
        <link href="Initiatives('0000000020')" rel="self" title="Initiative"/>
        <link href="Initiatives('0000000020')/TargetGroup" rel="http://schemas.microsoft.com/ado/2007/08/dataservices/related/TargetGroup" type="application/atom+xml;type=entry" title="TargetGroup">
            <m:inline>
                <entry xml:base="{Marketing URL}/sap/opu/odata/sap/CUAN_INITIATIVE_SRV/" xmlns="http://www.w3.org/2005/Atom" xmlns:m="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata" xmlns:d="http://schemas.microsoft.com/ado/2007/08/dataservices">
                    <id>{Marketing URL}/sap/opu/odata/sap/CUAN_INITIATIVE_SRV/TargetGroups('0000000035')</id>
                    <title type="text">TargetGroups('0000000035')</title>
                    <updated>2020-04-07T11:58:29Z</updated>
                    <category term="CUAN_INITIATIVE_SRV.TargetGroup" scheme="http://schemas.microsoft.com/ado/2007/08/dataservices/scheme"/>
                    <link href="TargetGroups('0000000035')" rel="self" title="TargetGroup"/>
                    <content type="application/xml">
                        <m:properties>
                            <d:CustomerMemberCount>2</d:CustomerMemberCount>
                        </m:properties>
                    </content>
                </entry>
            </m:inline>
        </link>
        <content type="application/xml">
            <m:properties xmlns:m="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata" xmlns:d="http://schemas.microsoft.com/ado/2007/08/dataservices">
                <d:Search m:type="CUAN_INITIATIVE_SRV.SearchParameterCT">
                    <d:SearchTerm></d:SearchTerm>
                    <d:TileFilterCategory></d:TileFilterCategory>
                </d:Search>
                <d:Name>Email Campaign</d:Name>
            </m:properties>
        </content>
    </entry>
    <entry>
        <id>{Marketing URL}/sap/opu/odata/sap/CUAN_INITIATIVE_SRV/Initiatives('0000000022')</id>
        <title type="text">Initiatives('0000000022')</title>
        <updated>2020-04-07T11:58:29Z</updated>
        <category term="CUAN_INITIATIVE_SRV.Initiative" scheme="http://schemas.microsoft.com/ado/2007/08/dataservices/scheme"/>
        <link href="Initiatives('0000000022')" rel="self" title="Initiative"/>
        <link href="Initiatives('0000000022')/TargetGroup" rel="http://schemas.microsoft.com/ado/2007/08/dataservices/related/TargetGroup" type="application/atom+xml;type=entry" title="TargetGroup">
            <m:inline>
                <entry xml:base="{Marketing URL}/sap/opu/odata/sap/CUAN_INITIATIVE_SRV/" xmlns="http://www.w3.org/2005/Atom" xmlns:m="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata" xmlns:d="http://schemas.microsoft.com/ado/2007/08/dataservices">
                    <id>{Marketing URL}/sap/opu/odata/sap/CUAN_INITIATIVE_SRV/TargetGroups('')</id>
                    <title type="text">TargetGroups('')</title>
                    <updated>2020-04-07T11:58:29Z</updated>
                    <category term="CUAN_INITIATIVE_SRV.TargetGroup" scheme="http://schemas.microsoft.com/ado/2007/08/dataservices/scheme"/>
                    <link href="TargetGroups('')" rel="self" title="TargetGroup"/>
                    <content type="application/xml">
                        <m:properties>
                            <d:CustomerMemberCount>0</d:CustomerMemberCount>
                        </m:properties>
                    </content>
                </entry>
            </m:inline>
        </link>
        <content type="application/xml">
            <m:properties xmlns:m="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata" xmlns:d="http://schemas.microsoft.com/ado/2007/08/dataservices">
                <d:Search m:type="CUAN_INITIATIVE_SRV.SearchParameterCT">
                    <d:SearchTerm></d:SearchTerm>
                    <d:TileFilterCategory></d:TileFilterCategory>
                </d:Search>
                <d:Name>Email Campaign</d:Name>
            </m:properties>
        </content>
    </entry>
</feed><br>

As you can see above <d:TileFilterCategory></d:TileFilterCategory>
is always EMPTY, that's the reason why my campaigns are never returned in original response to SmartEdit, can u help me understand why this field is always empty and what I can do to change it? In SAP Marketing i'm using mostly predefined Email Campaigns so this field respresenting campaign's status should be filled automatically I guess.

Accepted Solutions (0)

Answers (3)

Answers (3)

Kunal_Bansal
Active Contributor

Hello,

You can refer to SAP Help Document here.

Best Regards,

Kunal

vervinckt_joyca
Active Contributor
0 Kudos

Hi dom.gor,

Did you solve this one? I have the same issue, I was also checking with Postman that calls are made and what is returned, and indeed this "TileFilterCategory" seems to be empty on ALL my campaigns... So I'm puzzled as to what this field actually means. There's another field "StatusCode" that seems to reflect the campaign status.

mohannad_el-jayousi
Participant
0 Kudos

Hello Dominik,

Have you considered leveraging the SAP API Business Hub: Marketing - Campaigns service?

FYI: For the CUAN_INITIATIVE_SRV, the TileFilterCategory is passed during GET calls, and will not be returned with any value.

Kind regards,

Mohannad