Google email markup not showing - email

I'm trying to make a simple view action using Email markup from Google inside my emails (https://developers.google.com/gmail/markup/reference/go-to-action#view_action)
I use this ld+json inside my email template
<script type="application/ld+json">
{
"#context": "http://schema.org",
"#type": "EmailMessage",
"potentialAction": {
"#type": "ViewAction",
"target": http://google.com",
"url": "http://google.com",
"name": See ticket"
}
}
</script>
I used Google email markup tester to valid this code.
I use registred emails (https://developers.google.com/gmail/markup/registering-with-google)
But I still can show the emails markup on Gmail.
Did I miss something ?
Do you have any clues ?
Thanks

Related

Chrome DevTolls protocol's Fetch.enable does not cause all requests to be intercepted

I issue a message like this via DevTools Protocol to a running Google Chrome instance:
{
"id": 0,
"method": "Fetch.enable",
"params": {
"patterns": [{
"urlPattern": "*.js*",
"resourceType": "Script",
"requestStage": "Response"
}
]
}
}
I was expecting it would cause "Fetch.requestPaused" event for each script file downloaded by a page. It works only for the resources provided in the <head> section of the page, like <script src="..."/>
If the <script src="..."/> is included in any other part of the page (ie. outside of header) it is not being intercepted and no "Fetch.requestPaused" event is issued. Anyone knows how to intercept those reuests (I need to modify the responses before they get to the browser).

"There is an error in your Sitelinks Search Box template: INVALID_SYNTAX"

The following error occurs on all pages of my site:
https://www.newworldproductions.net/{search_term_string}Video, Production, Services, Marketing, Minneapolis, Minnesota, Corporate Videos, Commercial Videos (There is an error in your Sitelinks Search Box template: INVALID_SYNTAX.)
The error takes place on line #9:
{
"#context": "https://schema.org/",
"#type": "WebSite",
"name": "New World Productions",
"url": "https://www.newworldproductions.net/",
"potentialAction": {
"#type": "SearchAction",
"target": "https://www.newworldproductions.net/{search_term_string}Video, Production, Services, Marketing, Minneapolis, Minnesota, Corporate Videos, Commercial Videos",
"query-input": "required name=search_term_string"
}
}
It would seem that the target is implemented wrong, as detailed in this article. There is no need to list your desired search terms in the string, and you aren't even looking for a query in your current code anyway. Try implementing the following:
<script type="application/ld+json">
{
"#context": "http://schema.org",
"#type": "WebSite",
"url": "https://www.newworldproductions.net/",
"potentialAction": {
"#type": "SearchAction",
"target": "https://query.newworldproductions.net/search?q={search_term_string}",
"query-input": "required name=search_term_string"
}
}
</script>
Also, keep in mind that not every website qualifies for the searchAction schema. If they did, everyone would be doing it. There are guidelines, which are touched on in the linked article. More research may be required on your part.

Google Schema Tag for site ratings/reviews not working

I've added Schema Tags in order to show star ratings in google search like in the screenshot
I've added the below code
<script type="application/ld+json">
{
"#context": "http://schema.org",
"#type": "WebSite",
"url": "https://mysiteexample.com",
"potentialAction": { "#type": "SearchAction",
"target": "https://mysiteexample.com/search/?keyword={search_term_string}",
"query-input": "required name=search_term_string" },
"aggregateRating": {
"#type": "AggregateRating",
"ratingValue": "4.8",
"bestRating": "5.0",
"ratingCount": "45"
}
}
</script>
But it not being shown by google. I don't know what the problem is. I've also verified the schema tag from schema analyzer and its alright. Please help me understand what i'm I doing wrong here. Thanks in advance.
Google does not always show review stars, even if the markup is syntactically correct. Check the Google structured data guidelines.
Some possible reasons:
WebSite is not a specified type that can get review stars
The page with the markup should clearly relate to what is being
reviewed
The reviews should be very visible on the page
The reviews should be directly acquired by the page (submit review
option?)
Home pages do not get review stars

how to show an image in gmail inbox preview

I have been receiving promotional emails with an image along with the subject line. i have seen this only in Gmail.
Not emojis, but image preview right below the subject line portion in the inbox preview
The emails are much more catchy with this. I have been checking google for a while to see what this feature is called but could not find any clue on the same.
Any information on this is Greatly appreciated.
Gmail Promotion Annotation
Since 2018 you can, indeed, add images with a preview in Gmail by using JSON-LD markup in the email's head.
Gmail Promotions Tabs can have/show:
Logo
Image
Subject
Deal Badges with Dates Frames
Discount Code within a Badge Design
The customization is quite strict, as of now, but the google guidelines are commented in the code snippet below:
<script type="application/ld+json">
[{
"#context": "http://schema.org/",
"#type": "Organization",
// WARNING: Before sending email, either point the logo
// at your own image or delete the logo annotation.
//
// If showing a logo, we recommend using an https URL.
// It's not a requirement today, but may be in the future.
"logo": "https://www.gstatic.com/images/branding/product/1x/googleg_48dp.png"
},{
"#context": "http://schema.org/",
"#type": "EmailMessage",
// Use this optional alternative subject line to avoid duplicate text
// between the subject, deal badge, and discount code.
"subjectLine": "[Important] Please add subject line in annotation"
},{
"#context": "http://schema.org/",
"#type": "DiscountOffer",
// Describe your discount, this will be shown as a badge (eg "25% off" or "free
shipping")
"description": "20% off",
"discountCode": "PROMO",
"availabilityStarts": "2019-07-21T03:42:38-07:00",
"availabilityEnds": "2019-07-24T03:42:38-07:00"
},{
// Promotion card with single image.
// We recommend using an https URL. It's not a requirement today, but may be in
the future.
// Any image size will work and will just be cropped automatically.
// GIF & WEBP images are not supported and will be filtered out.
// Sample image is 538x138, 3.9 aspect ratio
"#context": "http://schema.org/",
"#type": "PromotionCard",
"image": "https://www.google.com/gmail-for-marketers/promo-tab/markup-
tool/sample.png"
}]
</script>
Resources for this answer can be found in Google Developers Documentation:
Promotion Tab Documentation
enter image description here
This is the image of gmail inbox preview for product listing.
Add a Event onmouseover=FuntionName() to each GridView row, and show the popup which will include the message. But get it from client side

How to deploy rich formatted link for facebook messenger bot in api.ai?

In api.ai,
Rich formatting is supported for skype pretty fine. Here's an example:-
Here's the code of custom payload of api.ai:-
{
"skype": {
"text": "OCAS means Online Credit Approval System.\n Click [here] (http://www.erainfotechbd.com/product/ocas-online-credit-approval-system/) for more information. ",
"attachments": [
{
"contentType": "image/png",
"contentUrl": "http://weknowyourdreams.com/images/smile/smile-07.jpg",
"name": "Profile-picture.png"
}
]
}
}
Now, I wanna do something like this in facebook messenger also. But in the api.ai doc, only audio, video and file is supported.
Is there any other way to do so for url also in messenger ?
Generally webhook responses can deliver any custom payload to most platforms that API.AI supports, so any feature supported by Facebook Messenger, Skype, Google Assistant, etc. can be utilized through API.AI. Unfortunately Facebook doesn't seem to support hyperlinked text. The closest analog I could find is a what Facebook calls a URL Button. Below is an example of how you could create a API.AI response that has a Facebook URL Button with Facebook's Button template:
{
"speech": "OCAS means Online Credit Approval System. Check your phone for more information.",
"displayText": "OCAS means Online Credit Approval System. Click here for more information: http://www.erainfotechbd.com/product/ocas-online-credit-approval-system/",
"data": {
"facebook": {
"attachment": {
"type": "template",
"payload": {
"template_type": "button",
"text": "OCAS means Online Credit Approval System",
"buttons": [
{
"type": "web_url",
"url": "http://www.erainfotechbd.com/product/ocas-online-credit-approval-system/",
"title": "Click here for more information"
}
]
}
}
}
}
}
You can use also use any other Facebook Messenger APIs by including any JSON inside the "message" attribute that you see from Facebook's Messenger documentation and it will be passed along to Facebook by API.AI
PS - the code above should produce a message that looks something like this: