-
Notifications
You must be signed in to change notification settings - Fork 30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error : x-fb-cd-contents : ['contents'] must be an array." #20
Comments
I assume you are using a GA4 tag? (this template is intended to ingest GA4
events) If so, simply use the standard GA4 'items' array (documentation
<https://developers.google.com/tag-manager/ecommerce-ga4#measure_a_checkout>)
and those properties will be mapped to a contents array by the template.
(items[x].item_id will be mapped to contents[x].id, items[x].item_name will
be mapped to contents[x].name, etc...)
—
Kevin O'Connor, Digital Marketing Analyst
www.iDimension.com <http://www.idimension.com/?utm_id=VwkC>
+1 (866) 524.3733
…On Mon, Aug 23, 2021 at 10:59 AM baptiste74 ***@***.***> wrote:
I try to send custom_data "contents" via x-fb-cd-contents parameter via
InitiateChekout and Purchase but I get a 200 error on server side debug
mode :
{"error":{"message":"Invalid
parameter","type":"OAuthException","code":100,"error_subcode":2804019,"is_transient":false,"error_user_title":"Server
Side Api Parameter Error","error_user_msg":"The parameter
$['data'][0]['custom_data']['contents'] must be an
array.","fbtrace_id":"Ack-e18nn4DSE933xa9Xv2_"}}
BUT, those parameters are well sent through client side tag :
Parameters: (4)
contents:
[{"id":"1234567890","name":"Boucles doreilles
ROMY","item_price":35,"quantity":1}]
value:
35
currency:
EUR
content_type:
product
It seems that the parameter x-fb-cd-contents doesn't match the "contents"
parameter or is unable to sent it correctly.
Grateful for any ideas, many thanks.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#20>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AE3LD7C2C7DFQJXWGK2JRTLT6JO53ANCNFSM5CUYR5FQ>
.
Triage notifications on the go with GitHub Mobile for iOS
<https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675>
or Android
<https://play.google.com/store/apps/details?id=com.github.android&utm_campaign=notification-email>
.
|
Yes I am using GA4 tag. I tried the "items" parameter rather than the "x-fb-cd-contents" parameter and it worked ! Thank a lot for you help. |
facebook-github-bot
pushed a commit
that referenced
this issue
Apr 20, 2023
Summary: Fix x-fb-cd-contents array receiving [object Object] from web container Differential Revision: D44755084 fbshipit-source-id: 25b458a563b3e23a14c1f5a108dea770744dc67a
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I try to send custom_data "contents" via x-fb-cd-contents parameter via InitiateChekout and Purchase but I get a 200 error on server side debug mode :
{"error":{"message":"Invalid parameter","type":"OAuthException","code":100,"error_subcode":2804019,"is_transient":false,"error_user_title":"Server Side Api Parameter Error","error_user_msg":"The parameter $['data'][0]['custom_data']['contents'] must be an array.","fbtrace_id":"Ack-e18nn4DSE933xa9Xv2_"}}
BUT, those parameters are well sent through client side tag :
Parameters: (4)
contents:
[{"id":"1234567890","name":"Boucles doreilles ROMY","item_price":35,"quantity":1}]
value:
35
currency:
EUR
content_type:
product
It seems that the parameter x-fb-cd-contents doesn't match the "contents" parameter or is unable to sent it correctly.
Grateful for any ideas, many thanks.
The text was updated successfully, but these errors were encountered: