Set meta tag via API

shopjbshopjb Member Posts: 9
Is there a way to create a meta tag via API for the frontend? I need to put the Google Search Console verification tag in the HTML Header. Basically the same functionality in Settings->Web Extras-> Google Search Console. If creating a meta tag is not possible, is it possible to set the settings field?

If that's not possible as well I guess I could create with Javascript via the ShopScript Endpoint. But creating a script seems to take a while to take effect on the live shop. How long does it take? Is it a fixed time?

3 comments

  • TimBloembergenTimBloembergen Moderator, Lightspeed Staff Posts: 38 moderator
    Hello Shopjb,

    The same functionality that you see in the backoffice for Google Search Console isn't available in the API. If you want to set this metatag you will have to do it via Web Extras or via shopScripts, but via the Backoffice is the easiest method.

    ShopScripts get added via a cronjob so it can take a while sometimes.
     

    Tim Bloembergen
    API Integrations Specialist
    Lightspeed HQ
  • JoeyJoey Administrator, Moderator, Lightspeed Staff Posts: 197 moderator
    Hi Shopjb,

    If you need the tag to verify a site you can also use a TXT record in the domains DNS settings.

    Hope this helps!
    eCom Support Team
    Lightspeed HQ
  • shopjbshopjb Member Posts: 9
    Hello Shopjb,

    ShopScripts get added via a cronjob so it can take a while sometimes.
    Could you tell me, how often the cronjob is running? I set the meta tag and verify it afterwards. I need to know how long I'd have to wait before I can verify it.
Sign In or Register to comment.