Skip to content

Save pixel

PUT/admin/v1/stores/{store_id}/marketing/pixels/{platform}

    Connect or change a platform (meta, snapchat, tiktok, google).

    Path parameters

    • store_idstringrequired

      The store's ID, like store_01k8qs5s…. Apps get it with the install, in the OAuth redirect and the token response.

    • platformenumrequired

      The platform

      • meta
      • snapchat
      • tiktok
      • google

    Headers

    • shop-api-versionYYYY-MM

      The version to answer in. Without it, your app’s pinned version, else the newest.

    Body

    • pixel_idstringrequired

      Meta Pixel ID, Snap Pixel ID, TikTok pixel code or GA4 measurement ID.

    • enabledboolean
    • ads_conversionstring · or null
    • test_codestring · or null
    • server_tokenstring · or null

      A new server token (Conversions API / Events API token, GA4 API secret). Omit to keep the stored one; "" removes it.

    Returns

    200 Saved.

    Errors

    • 404not_foundNo such platform.
    • 422validation_failedAn ID, conversion or code in the wrong shape.