docs(legal): cover analytics across opencode.ai and add an opt-out (#62299)

This commit is contained in:
Adam
2026-11-06 01:02:43 -06:00
committed by GitHub
Unverified
parent 286beb081a
commit 76ff9a6ab2
9 changed files with 330 additions and 44 deletions
@@ -0,0 +1,22 @@
/* The toggle reads as one of the page's links. */
[data-component="analytics-choice"] button {
padding: 0;
border: 0;
background: none;
font: inherit;
color: var(--color-text-strong);
text-decoration: underline;
text-underline-offset: 2px;
text-decoration-thickness: 1px;
cursor: pointer;
}
[data-component="analytics-choice"] button:hover {
text-decoration-thickness: 2px;
}
@media print {
[data-component="analytics-choice"] {
display: none;
}
}
@@ -0,0 +1,67 @@
import { createSignal, onMount, Show } from "solid-js"
import "./analytics-choice.css"
const YEAR_SECONDS = 31_536_000
/**
* The Privacy Policy's on and off control for analytics in this browser. Off sets `oc_optout=1` for a year and
* deletes the analytics cookies (at `/` and at `/console`, where older pages wrote them) and the day's reported
* events in local storage; on deletes `oc_optout`. It writes the cookies itself, so it works without the tracker.
* A browser with Global Privacy Control is always off, so it shows no button. services/site has the same control.
*/
export function AnalyticsChoice() {
const [state, setState] = createSignal<"on" | "off" | "gpc">()
onMount(() => setState(readState()))
const toggle = () => {
setAnalytics(state() === "off")
setState(readState())
}
return (
<Show when={state()}>
{(current) => (
<p data-component="analytics-choice">
<span role="status">
{current() === "on"
? "Analytics are on in this browser."
: current() === "off"
? "Analytics are off in this browser."
: "Analytics are off in this browser because it sends a Global Privacy Control signal."}
</span>
<Show when={current() !== "gpc"}>
{" "}
<button type="button" onClick={toggle}>
{current() === "on" ? "Turn off analytics" : "Turn on analytics"}
</button>
</Show>
</p>
)}
</Show>
)
}
function readState() {
if ("globalPrivacyControl" in navigator && navigator.globalPrivacyControl === true) return "gpc"
return document.cookie.split(";").some((part) => part.trim() === "oc_optout=1") ? "off" : "on"
}
function setAnalytics(on: boolean) {
const secure = location.protocol === "https:" ? "; Secure" : ""
if (on) {
document.cookie = `oc_optout=; Path=/; SameSite=Lax; Max-Age=0${secure}`
return
}
const cookies = [
`oc_optout=1; Path=/; SameSite=Lax; Max-Age=${YEAR_SECONDS}${secure}`,
...["oc_vid", "oc_sid", "oc_attr"].flatMap((name) =>
["/", "/console"].map((path) => `${name}=; Path=${path}; SameSite=Lax; Max-Age=0${secure}`),
),
]
cookies.forEach((cookie) => {
document.cookie = cookie
})
try {
localStorage.removeItem("opencode-console.funnel.seen")
} catch {
// Storage the browser refuses holds nothing to clear.
}
}
@@ -4,6 +4,7 @@ import { Title, Meta } from "@solidjs/meta"
import { Header } from "~/component/header"
import { Footer } from "~/component/footer"
import { Legal } from "~/component/legal"
import { AnalyticsChoice } from "~/component/analytics-choice"
import { LocaleLinks } from "~/component/locale-links"
import { useLanguage } from "~/context/language"
@@ -21,7 +22,7 @@ export default function PrivacyPolicy() {
<section data-component="brand-content">
<article data-component="privacy-policy">
<h1>Privacy Policy</h1>
<p class="effective-date">Effective date: Nov 4, 2026</p>
<p class="effective-date">Effective date: Nov 6, 2026</p>
<p>
At OpenCode, we take your privacy seriously. Please read this Privacy Policy to learn how we treat your
@@ -86,7 +87,7 @@ export default function PrivacyPolicy() {
<a href="#tracking-tools">Tracking Tools and Opt-Out</a>
<ul>
<li>
<a href="#product-analytics">Product Analytics on opencode.ai/console</a>
<a href="#product-analytics">Product Analytics on opencode.ai</a>
</li>
</ul>
</li>
@@ -449,14 +450,7 @@ export default function PrivacyPolicy() {
the Services, what pages visitors view on our Services and how long visitors are viewing pages on the
Services. Performance/Analytical Cookies also help us measure the performance of our advertising
campaigns in order to help us improve our campaigns and the Services' content for those who engage
with our advertising. For example, Google LLC ("Google") uses cookies in connection with its Google
Analytics services. Google's ability to use and disclose information collected by Google Analytics
about your visits to the Services is subject to the Google Analytics Terms of Use and the Google
Privacy Policy. You have the option to opt-out of Google's use of Cookies by visiting the Google
advertising opt-out page at{" "}
<a href="http://www.google.com/privacy_ads.html">www.google.com/privacy_ads.html</a> or the Google
Analytics Opt-out Browser Add-on at{" "}
<a href="https://tools.google.com/dlpage/gaoptout/">https://tools.google.com/dlpage/gaoptout/</a>.
with our advertising.
</li>
</ul>
@@ -475,19 +469,22 @@ export default function PrivacyPolicy() {
<a href="http://www.allaboutcookies.org/">http://www.allaboutcookies.org/</a>.
</p>
<h3 id="product-analytics">Product Analytics on opencode.ai/console</h3>
<h3 id="product-analytics">Product Analytics on opencode.ai</h3>
<p>
When you visit pages under opencode.ai/console, including the sign-in pages, we record the pages you
view, how long each page is visible, how long you're active on it and how far you scroll, the links and
buttons you click, and the type of any sign-in error. In the Console we record the pages you open and
the controls you use in its navigation, plan, billing and onboarding screens. We also record account and
workspace events: when you sign up, sign in, verify your email, approve a device, create or delete a
workspace, invite or remove members, create API keys, connect providers or clients, and start or
complete a checkout or payment, including its amount and any decline reason. We use these records to
understand how people find OpenCode and where they stop before signing up or subscribing, so we can
improve the Services.
When you visit opencode.ai, including the docs and the Console, we record the pages you view, how long
each page is visible, how long you're active on it, how far you scroll and how quickly it loads. We also
record the links and buttons you click, when you download an app or copy a command, when you search (but
not what you search for), and the type of any sign-in error. We record each click under a fixed name we
give that link or button, so text you or your team entered, such as workspace names or email addresses,
isn't recorded even when it appears on the page. We record account and workspace events: when you sign
up, sign in, verify your email, approve a device, create or delete a workspace, invite or remove
members, create API keys, connect providers or clients, and start or complete a checkout or payment,
including its amount and any decline reason. We use these records to understand how people find OpenCode
and where they stop before signing up or subscribing, so we can improve the Services.
</p>
<p>We collect these records ourselves and don't use third-party analytics services on opencode.ai.</p>
<p>
With each record sent from your browser, we keep the country, region and time zone your request came
from, the type of device, operating system and browser you used, and the size of your browser window. We
@@ -496,8 +493,8 @@ export default function PrivacyPolicy() {
</p>
<p>
We set the following first-party Cookies. Your browser sends them only to opencode.ai/console. We also
keep a list in your browser's local storage of which events it has already reported that day.
We set the following first-party Cookies. Your browser sends them only to opencode.ai. We also keep a
list in your browser's local storage of which events it has already reported that day.
</p>
<div class="table-wrapper">
@@ -513,7 +510,7 @@ export default function PrivacyPolicy() {
<tr>
<td>oc_vid</td>
<td>A random ID for your browser</td>
<td>1 year from when it's first set</td>
<td>1 year from your latest visit</td>
</tr>
<tr>
<td>oc_sid</td>
@@ -523,11 +520,16 @@ export default function PrivacyPolicy() {
<tr>
<td>oc_attr</td>
<td>
How you first and most recently arrived: the page you landed on, the domain of the website that
referred you, any campaign (UTM) parameters in the link, and the last sign-up or sign-in link
you clicked
The page you first and most recently landed on, the domain of the website that referred you and
any campaign (UTM) parameters in the link, plus the last link into the Console you clicked (a
sign-up or sign-in link, and the plan it was for, if any) and when you clicked it
</td>
<td>1 year</td>
<td>1 year from the last time it changed</td>
</tr>
<tr>
<td>oc_optout</td>
<td>A record that you turned off analytics in this browser</td>
<td>1 year from your latest visit</td>
</tr>
</tbody>
</table>
@@ -538,6 +540,18 @@ export default function PrivacyPolicy() {
that browser to your account. Records made while you're signed in carry your account ID directly.
</p>
<p>
If your browser sends a Global Privacy Control signal, or you{" "}
<a href="https://opencode.ai/legal/privacy-policy#product-analytics">turn off analytics on this page</a>
, we still record the page views, clicks and other browser events above, but without the IDs and arrival
details in oc_vid, oc_sid and oc_attr, and without your account or workspace ID. We delete those Cookies
and the local storage list from your browser and don't set them again while analytics are off. Account
and workspace events, such as sign-ups, payments and workspace changes, still carry your account ID, but
we don't link them or any other records to that browser, even if you're signed in.
</p>
<AnalyticsChoice />
<p>
We delete these records from our analytics database within a month after they turn 24 months old. We
keep an archive copy of these records for longer. It contains your account ID if you were signed in, but
@@ -0,0 +1,11 @@
/* The status line keeps the document's reading width. */
[data-slot="analytics-choice"] p {
max-inline-size: var(--measure);
}
/* The control is about this browser, so a printed or saved copy leaves it out. */
@media print {
[data-slot="analytics-choice"] {
display: none;
}
}
@@ -0,0 +1,68 @@
import { createSignal, onMount, Show } from "solid-js"
import "./analytics-choice.css"
const YEAR_SECONDS = 31_536_000
/**
* The Privacy Policy's on and off control for analytics in this browser. Off sets `oc_optout=1` for a year and
* deletes the analytics cookies (at `/` and at `/console`, where older pages wrote them) and the day's reported
* events in local storage; on deletes `oc_optout`. It writes the cookies itself, so it works without the tracker.
* A browser with Global Privacy Control is always off, so it shows no button.
*/
export function AnalyticsChoice() {
const [state, setState] = createSignal<"on" | "off" | "gpc">()
onMount(() => setState(readState()))
const toggle = () => {
setAnalytics(state() === "off")
setState(readState())
}
return (
<Show when={state()}>
{(current) => (
<div data-slot="analytics-choice">
<p role="status">
{current() === "on"
? "Analytics are on in this browser."
: current() === "off"
? "Analytics are off in this browser."
: "Analytics are off in this browser because it sends a Global Privacy Control signal."}
</p>
<Show when={current() !== "gpc"}>
<p>
<button type="button" data-component="site-button" data-variant="neutral" onClick={toggle}>
{current() === "on" ? "Turn off analytics" : "Turn on analytics"}
</button>
</p>
</Show>
</div>
)}
</Show>
)
}
function readState() {
if ("globalPrivacyControl" in navigator && navigator.globalPrivacyControl === true) return "gpc"
return document.cookie.split(";").some((part) => part.trim() === "oc_optout=1") ? "off" : "on"
}
function setAnalytics(on: boolean) {
const secure = location.protocol === "https:" ? "; Secure" : ""
if (on) {
document.cookie = `oc_optout=; Path=/; SameSite=Lax; Max-Age=0${secure}`
return
}
const cookies = [
`oc_optout=1; Path=/; SameSite=Lax; Max-Age=${YEAR_SECONDS}${secure}`,
...["oc_vid", "oc_sid", "oc_attr"].flatMap((name) =>
["/", "/console"].map((path) => `${name}=; Path=${path}; SameSite=Lax; Max-Age=0${secure}`),
),
]
cookies.forEach((cookie) => {
document.cookie = cookie
})
try {
localStorage.removeItem("opencode-console.funnel.seen")
} catch {
// Storage the browser refuses holds nothing to clear.
}
}
@@ -7,7 +7,7 @@
{
"id": "privacy-policy-table-of-contents",
"title": "Privacy Policy Table of Contents",
"body": " What this Privacy Policy CoversPersonal DataCategories of Personal Data We CollectOur Commercial or Business Purposes for Collecting Personal DataOther Permitted Purposes for Processing Personal DataCategories of Sources of Personal DataHow We Disclose Your Personal DataTracking Tools and Opt-OutProduct Analytics on opencode.ai/consoleData SecurityPersonal Data of ChildrenCalifornia Resident Rights (\"CCPA\")Colorado Resident Rights (\"CPA\")Connecticut Resident Rights (\"CTDPA\")Delaware Resident Rights (\"DPDPA\")Iowa Resident Rights (\"ICDPA\")Montana Resident Rights (\"MCDPA\")Nebraska Resident Right",
"body": " What this Privacy Policy CoversPersonal DataCategories of Personal Data We CollectOur Commercial or Business Purposes for Collecting Personal DataOther Permitted Purposes for Processing Personal DataCategories of Sources of Personal DataHow We Disclose Your Personal DataTracking Tools and Opt-OutProduct Analytics on opencode.aiData SecurityPersonal Data of ChildrenCalifornia Resident Rights (\"CCPA\")Colorado Resident Rights (\"CPA\")Connecticut Resident Rights (\"CTDPA\")Delaware Resident Rights (\"DPDPA\")Iowa Resident Rights (\"ICDPA\")Montana Resident Rights (\"MCDPA\")Nebraska Resident Rights (\"NDPA",
"path": "/legal/privacy-policy",
"document": "Privacy Policy"
},
@@ -111,8 +111,8 @@
},
{
"id": "product-analytics",
"title": "Product Analytics on opencode.ai/console",
"body": " When you visit pages under opencode.ai/console, including the sign-in pages, we record the pages you view, how long each page is visible, how long you're active on it and how far you scroll, the links and buttons you click, and the type of any sign-in error. In the Console we record the pages you open and the controls you use in its navigation, plan, billing and onboarding screens. We also record account and workspace events: when you sign up, sign in, verify your email, approve a device, create or delete a workspace, invite or remove members, create API keys, connect providers or clients, an",
"title": "Product Analytics on opencode.ai",
"body": " When you visit opencode.ai, including the docs and the Console, we record the pages you view, how long each page is visible, how long you're active on it, how far you scroll and how quickly it loads. We also record the links and buttons you click, when you download an app or copy a command, when you search (but not what you search for), and the type of any sign-in error. We record each click under a fixed name we give that link or button, so text you or your team entered, such as workspace names or email addresses, isn't recorded even when it appears on the page. We record account and workspa",
"path": "/legal/privacy-policy",
"document": "Privacy Policy"
},
@@ -21,6 +21,7 @@ import {
type LegalNode,
} from "~/lib/legal"
import { legalSummaries } from "~/lib/legal/summaries"
import { AnalyticsChoice } from "./analytics-choice"
import { CheckIcon, Chevron, CopyIcon, DownloadIcon, ExternalArrow, NewTab } from "./icons"
import { copySelection } from "~/lib/clipboard"
import { architectLabelCases, architectRules, legalHistoryViews, legalPrintStyles, siteSettings } from "./settings"
@@ -705,6 +706,7 @@ function LegalBody(props: {
}) {
if (typeof props.node === "string") return props.node
const node = props.node
if (node[0] === "analytics-choice") return <AnalyticsChoice />
if (published(node)) return <LegalElement node={node} anchors={props.anchors} />
// A note to the legal reviewers in a draft: shown only with Settings › Legal review notes.
return (
+90
View File
@@ -2,6 +2,96 @@
export const legalHistory = {
"/legal/privacy-policy": [
{
sha: "bc2891953b63dccfb3b688892b09009b9574caaa",
date: "2026-11-06",
subject: "docs(legal): cover analytics across opencode.ai and add an opt-out",
effective: "Nov 6, 2026",
first: false,
added: [
"Effective date: Nov 6, 2026",
"Product Analytics on opencode.ai",
"When you visit opencode.ai, including the docs and the Console, we record the pages you view, how long each page is visible, how long you're active on it, how far you scroll and how quickly it loads.",
"We also record the links and buttons you click, when you download an app or copy a command, when you search (but not what you search for), and the type of any sign-in error.",
"We record each click under a fixed name we give that link or button, so text you or your team entered, such as workspace names or email addresses, isn't recorded even when it appears on the page.",
"We record account and workspace events: when you sign up, sign in, verify your email, approve a device, create or delete a workspace, invite or remove members, create API keys, connect providers or clients, and start or complete a checkout or payment, including its amount and any decline reason.",
"We collect these records ourselves and don't use third-party analytics services on opencode.ai.",
"Your browser sends them only to opencode.ai.",
"1 year from your latest visit",
"The page you first and most recently landed on, the domain of the website that referred you and any campaign (UTM) parameters in the link, plus the last link into the Console you clicked (a sign-up or sign-in link, and the plan it was for, if any) and when you clicked it",
"1 year from the last time it changed",
"oc_optout",
],
removed: [
"Effective date: Nov 4, 2026",
"Product Analytics on opencode.ai/console",
'For example, Google LLC ("Google") uses cookies in connection with its Google Analytics services.',
"Google's ability to use and disclose information collected by Google Analytics about your visits to the Services is subject to the Google Analytics Terms of Use and the Google Privacy Policy.",
"You have the option to opt-out of Google's use of Cookies by visiting the Google advertising opt-out page at www.google.com/privacy_ads.html or the Google Analytics Opt-out Browser Add-on at https://tools.google.com/dlpage/gaoptout/.",
"When you visit pages under opencode.ai/console, including the sign-in pages, we record the pages you view, how long each page is visible, how long you're active on it and how far you scroll, the links and buttons you click, and the type of any sign-in error.",
"In the Console we record the pages you open and the controls you use in its navigation, plan, billing and onboarding screens.",
"We also record account and workspace events: when you sign up, sign in, verify your email, approve a device, create or delete a workspace, invite or remove members, create API keys, connect providers or clients, and start or complete a checkout or payment, including its amount and any decline reason.",
"Your browser sends them only to opencode.ai/console.",
"1 year from when it's first set",
"How you first and most recently arrived: the page you landed on, the domain of the website that referred you, any campaign (UTM) parameters in the link, and the last sign-up or sign-in link you clicked",
"1 year",
],
addedCount: 16,
removedCount: 12,
source:
"https://github.com/anomalyco/opencode/blob/bc2891953b63dccfb3b688892b09009b9574caaa/packages/console/app/src/routes/legal/privacy-policy/index.tsx",
diff: "https://github.com/anomalyco/opencode/commit/bc2891953b63dccfb3b688892b09009b9574caaa#diff-86623c1b761ddcf78790804023aeabaca6b33689a83d2402241105bf407fdc31",
},
{
sha: "926b2af0cc606398342b487a26ada2ee7badd39c",
date: "2026-11-05",
subject: "docs(legal): drop the cookie banner from the privacy policy (#62084)",
effective: "Nov 4, 2026",
first: false,
added: [],
removed: [
"oc_consent",
"Your answer to our cookie banner, or that we don't need to ask you",
"180 days for an answer, 1 day otherwise",
"If you're in the European Economic Area, the United Kingdom or Switzerland, or we can't tell where you are, we ask before setting these Cookies.",
"If you're signed in to OpenCode, we set them without asking.",
"If you haven't accepted, we still record the events above, without these Cookies' IDs, so a visit's events can't be connected to each other or to earlier visits.",
"If you're signed in, those events still carry your account ID.",
"You can change your answer at any time with the Cookies button at the bottom of our marketing pages.",
],
addedCount: 0,
removedCount: 8,
source:
"https://github.com/anomalyco/opencode/blob/926b2af0cc606398342b487a26ada2ee7badd39c/packages/console/app/src/routes/legal/privacy-policy/index.tsx",
diff: "https://github.com/anomalyco/opencode/commit/926b2af0cc606398342b487a26ada2ee7badd39c#diff-86623c1b761ddcf78790804023aeabaca6b33689a83d2402241105bf407fdc31",
},
{
sha: "eb463de93ef91b3c9355ecfefe937c68556f0040",
date: "2026-11-04",
subject: "docs(legal): describe first-party product analytics in the privacy policy (#61905)",
effective: "Nov 4, 2026",
first: false,
added: [
"Effective date: Nov 4, 2026",
"Product Analytics on opencode.ai/console",
"When you visit pages under opencode.ai/console, including the sign-in pages, we record the pages you view, how long each page is visible, how long you're active on it and how far you scroll, the links and buttons you click, and the type of any sign-in error.",
"In the Console we record the pages you open and the controls you use in its navigation, plan, billing and onboarding screens.",
"We also record account and workspace events: when you sign up, sign in, verify your email, approve a device, create or delete a workspace, invite or remove members, create API keys, connect providers or clients, and start or complete a checkout or payment, including its amount and any decline reason.",
"We use these records to understand how people find OpenCode and where they stop before signing up or subscribing, so we can improve the Services.",
"With each record sent from your browser, we keep the country, region and time zone your request came from, the type of device, operating system and browser you used, and the size of your browser window.",
"We use your IP address to determine your country and region and to limit requests, but we don't store it, your email address or anything you type in these records.",
"We set the following first-party Cookies.",
"Your browser sends them only to opencode.ai/console.",
"We also keep a list in your browser's local storage of which events it has already reported that day.",
"Cookie",
],
removed: ["Effective date: Mar 6, 2026"],
addedCount: 38,
removedCount: 1,
source:
"https://github.com/anomalyco/opencode/blob/eb463de93ef91b3c9355ecfefe937c68556f0040/packages/console/app/src/routes/legal/privacy-policy/index.tsx",
diff: "https://github.com/anomalyco/opencode/commit/eb463de93ef91b3c9355ecfefe937c68556f0040#diff-86623c1b761ddcf78790804023aeabaca6b33689a83d2402241105bf407fdc31",
},
{
sha: "19d00098910af21b33458ba4ea011c25d472f8b7",
date: "2026-08-24",
+26 -14
View File
@@ -4,7 +4,7 @@ export const privacyPolicy: LegalDocumentContent = {
path: "/legal/privacy-policy",
title: "Privacy Policy",
metaTitle: "OpenCode | Privacy Policy for the website and services",
effective: "Effective date: Nov 4, 2026",
effective: "Effective date: Nov 6, 2026",
description:
"How OpenCode collects, uses, shares and protects your personal data when you use the OpenCode website, apps and hosted services, and the choices you have.",
body: [
@@ -63,7 +63,7 @@ export const privacyPolicy: LegalDocumentContent = {
"li",
{},
["a", { href: "#tracking-tools" }, "Tracking Tools and Opt-Out"],
["ul", {}, ["li", {}, ["a", { href: "#product-analytics" }, "Product Analytics on opencode.ai/console"]]],
["ul", {}, ["li", {}, ["a", { href: "#product-analytics" }, "Product Analytics on opencode.ai"]]],
],
["li", {}, ["a", { href: "#data-security" }, "Data Security"]],
["li", {}, ["a", { href: "#personal-data-of-children" }, "Personal Data of Children"]],
@@ -425,11 +425,7 @@ export const privacyPolicy: LegalDocumentContent = {
"li",
{},
["strong", {}, "Performance/Analytical Cookies."],
" Performance/Analytical Cookies allow us to understand how visitors use our Services. They do this by collecting information about the number of visitors to the Services, what pages visitors view on our Services and how long visitors are viewing pages on the Services. Performance/Analytical Cookies also help us measure the performance of our advertising campaigns in order to help us improve our campaigns and the Services' content for those who engage with our advertising. For example, Google LLC (\"Google\") uses cookies in connection with its Google Analytics services. Google's ability to use and disclose information collected by Google Analytics about your visits to the Services is subject to the Google Analytics Terms of Use and the Google Privacy Policy. You have the option to opt-out of Google's use of Cookies by visiting the Google advertising opt-out page at ",
["a", { href: "http://www.google.com/privacy_ads.html" }, "www.google.com/privacy_ads.html"],
" or the Google Analytics Opt-out Browser Add-on at ",
["a", { href: "https://tools.google.com/dlpage/gaoptout/" }, "https://tools.google.com/dlpage/gaoptout/"],
".",
" Performance/Analytical Cookies allow us to understand how visitors use our Services. They do this by collecting information about the number of visitors to the Services, what pages visitors view on our Services and how long visitors are viewing pages on the Services. Performance/Analytical Cookies also help us measure the performance of our advertising campaigns in order to help us improve our campaigns and the Services' content for those who engage with our advertising.",
],
],
[
@@ -444,13 +440,13 @@ export const privacyPolicy: LegalDocumentContent = {
["a", { href: "http://www.allaboutcookies.org/" }, "http://www.allaboutcookies.org/"],
".",
],
// Carried over from dev: #61905 (first-party product analytics) and #62084 (no cookie banner). Needs legal sign-off.
["h3", { id: "product-analytics" }, "Product Analytics on opencode.ai/console"],
["h3", { id: "product-analytics" }, "Product Analytics on opencode.ai"],
[
"p",
{},
"When you visit pages under opencode.ai/console, including the sign-in pages, we record the pages you view, how long each page is visible, how long you're active on it and how far you scroll, the links and buttons you click, and the type of any sign-in error. In the Console we record the pages you open and the controls you use in its navigation, plan, billing and onboarding screens. We also record account and workspace events: when you sign up, sign in, verify your email, approve a device, create or delete a workspace, invite or remove members, create API keys, connect providers or clients, and start or complete a checkout or payment, including its amount and any decline reason. We use these records to understand how people find OpenCode and where they stop before signing up or subscribing, so we can improve the Services.",
"When you visit opencode.ai, including the docs and the Console, we record the pages you view, how long each page is visible, how long you're active on it, how far you scroll and how quickly it loads. We also record the links and buttons you click, when you download an app or copy a command, when you search (but not what you search for), and the type of any sign-in error. We record each click under a fixed name we give that link or button, so text you or your team entered, such as workspace names or email addresses, isn't recorded even when it appears on the page. We record account and workspace events: when you sign up, sign in, verify your email, approve a device, create or delete a workspace, invite or remove members, create API keys, connect providers or clients, and start or complete a checkout or payment, including its amount and any decline reason. We use these records to understand how people find OpenCode and where they stop before signing up or subscribing, so we can improve the Services.",
],
["p", {}, "We collect these records ourselves and don't use third-party analytics services on opencode.ai."],
[
"p",
{},
@@ -459,7 +455,7 @@ export const privacyPolicy: LegalDocumentContent = {
[
"p",
{},
"We set the following first-party Cookies. Your browser sends them only to opencode.ai/console. We also keep a list in your browser's local storage of which events it has already reported that day.",
"We set the following first-party Cookies. Your browser sends them only to opencode.ai. We also keep a list in your browser's local storage of which events it has already reported that day.",
],
[
"div",
@@ -476,7 +472,7 @@ export const privacyPolicy: LegalDocumentContent = {
{},
["td", {}, "oc_vid"],
["td", {}, "A random ID for your browser"],
["td", {}, "1 year from when it's first set"],
["td", {}, "1 year from your latest visit"],
],
[
"tr",
@@ -492,9 +488,16 @@ export const privacyPolicy: LegalDocumentContent = {
[
"td",
{},
"How you first and most recently arrived: the page you landed on, the domain of the website that referred you, any campaign (UTM) parameters in the link, and the last sign-up or sign-in link you clicked",
"The page you first and most recently landed on, the domain of the website that referred you and any campaign (UTM) parameters in the link, plus the last link into the Console you clicked (a sign-up or sign-in link, and the plan it was for, if any) and when you clicked it",
],
["td", {}, "1 year"],
["td", {}, "1 year from the last time it changed"],
],
[
"tr",
{},
["td", {}, "oc_optout"],
["td", {}, "A record that you turned off analytics in this browser"],
["td", {}, "1 year from your latest visit"],
],
],
],
@@ -504,6 +507,15 @@ export const privacyPolicy: LegalDocumentContent = {
{},
"When you create an account, sign in, verify your email or approve a device, we link the records from that browser to your account. Records made while you're signed in carry your account ID directly.",
],
[
"p",
{},
"If your browser sends a Global Privacy Control signal, or you ",
["a", { href: "https://opencode.ai/legal/privacy-policy#product-analytics" }, "turn off analytics on this page"],
", we still record the page views, clicks and other browser events above, but without the IDs and arrival details in oc_vid, oc_sid and oc_attr, and without your account or workspace ID. We delete those Cookies and the local storage list from your browser and don't set them again while analytics are off. Account and workspace events, such as sign-ups, payments and workspace changes, still carry your account ID, but we don't link them or any other records to that browser, even if you're signed in.",
],
// The on and off control for this browser (AnalyticsChoice); the Markdown version leaves it out.
["analytics-choice", {}],
[
"p",
{},