diff --git a/.gitattributes b/.gitattributes index 24860868b59b..ab74efd46bf7 100644 --- a/.gitattributes +++ b/.gitattributes @@ -3,7 +3,8 @@ # Batch files need CRLF for cmd.exe to parse them reliably. *.cmd text eol=crlf *.bat text eol=crlf -# GitHub's and Expo's GraphQL schemas and the operations graphqlgen writes from them. +# GitHub's, Linear's and Expo's GraphQL schemas and the operations graphqlgen writes from them. packages/source-control-github/schema/** linguist-generated +packages/issue-tracker-linear/schema/** linguist-generated apps/server/schema/** linguist-generated **/*.graphql.ts linguist-generated diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 6707b0151bb3..1613036e61aa 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -104,6 +104,9 @@ jobs: - name: Check generated Expo GraphQL operations run: vp run --filter t3 generate --check + - name: Check generated Linear GraphQL operations + run: vp run --filter @t3tools/issue-tracker-linear generate --check + - name: Check run: vp check diff --git a/apps/server/package.json b/apps/server/package.json index 41da64fe8a93..62a11178bad6 100644 --- a/apps/server/package.json +++ b/apps/server/package.json @@ -41,6 +41,7 @@ "@napi-rs/keyring": "^1.3.0", "@opencode-ai/sdk": "^1.3.15", "@t3tools/issue-tracker-core": "workspace:*", + "@t3tools/issue-tracker-linear": "workspace:*", "@t3tools/provider-acp": "workspace:*", "@t3tools/provider-acp-registry": "workspace:*", "@t3tools/provider-core": "workspace:*", diff --git a/apps/server/src/auth/RpcAuthorization.ts b/apps/server/src/auth/RpcAuthorization.ts index eab392564aef..b99d8da6a401 100644 --- a/apps/server/src/auth/RpcAuthorization.ts +++ b/apps/server/src/auth/RpcAuthorization.ts @@ -131,6 +131,9 @@ export const RPC_REQUIRED_SCOPES = { [WS_METHODS.issuesComments]: AuthOrchestrationReadScope, [WS_METHODS.issuesTemplates]: AuthOrchestrationReadScope, [WS_METHODS.issuesCandidates]: AuthOrchestrationReadScope, + [WS_METHODS.issueTrackersList]: AuthOrchestrationReadScope, + [WS_METHODS.issueTrackersConnect]: AuthSettingsWriteScope, + [WS_METHODS.issueTrackersBindProject]: AuthSettingsWriteScope, [WS_METHODS.pullRequestsPreview]: AuthOrchestrationReadScope, [WS_METHODS.pullRequestsChecks]: AuthOrchestrationReadScope, [WS_METHODS.pullRequestsActivity]: AuthOrchestrationReadScope, diff --git a/apps/server/src/issue/IssueService.test.ts b/apps/server/src/issue/IssueService.test.ts index 34843bec5c51..09714b1fe478 100644 --- a/apps/server/src/issue/IssueService.test.ts +++ b/apps/server/src/issue/IssueService.test.ts @@ -11,6 +11,7 @@ import * as GitHubRest from "@t3tools/source-control-github/server/GitHubRest"; import * as GitHubIssueTracker from "@t3tools/source-control-github/server/GitHubIssueTracker"; import { IssueTrackerKind, + type IssueTrackerProjectBinding, SourceControlProviderKind, type OrchestrationProjectShell, type ProjectId, @@ -18,9 +19,11 @@ import { import { IssueTrackerError, type IssueTrackerApi, + type StandaloneIssueTrackerApi, type TrackerIssueDetail, } from "@t3tools/issue-tracker-core/server/IssueTracker"; +import * as IssueTrackerBindings from "../persistence/IssueTrackerBindings.ts"; import { normalizeGitRemoteUrl } from "@t3tools/shared/git"; import * as ProjectService from "../project/ProjectService.ts"; @@ -29,6 +32,30 @@ import * as IssueService from "./IssueService.ts"; import * as IssueTrackerRegistry from "./IssueTrackerRegistry.ts"; const GITHUB = IssueTrackerKind.make("github"); +const LINEAR = IssueTrackerKind.make("linear"); + +/** A standalone tracker shaped like Linear: its own host, team keys for scopes, `ENG-1` keys. */ +function fakeStandaloneTracker( + overrides: Partial = {}, +): StandaloneIssueTrackerApi { + return { + ...fakeTracker({ + getViewer: () => Effect.succeed("usr_julius"), + getIssue: (input) => + Effect.succeed({ ...issue(input.key), displayKey: input.key, viewer: "usr_julius" }), + ...overrides, + }), + kind: LINEAR, + standalone: { + tracker: LINEAR, + displayName: "Linear", + host: "linear.app", + scopeNoun: "team", + credential: { label: "Personal API key", helpUrl: null }, + }, + probeCredential: () => Effect.succeed({ account: "julius", scopes: [] }), + }; +} function project(input: { readonly id: string; @@ -120,12 +147,23 @@ function fakeTracker(overrides: Partial = {}): IssueTrackerApi function makeService(input: { readonly projects: ReadonlyArray; readonly trackers: ReadonlyArray; + readonly bindings?: Record; }) { return IssueService.IssueService.pipe( Effect.provide( IssueService.layer.pipe( Layer.provide( Layer.mergeAll( + Layer.mock(IssueTrackerBindings.IssueTrackerBindingsRepository)({ + list: Effect.succeed( + new Map( + Object.entries(input.bindings ?? {}).map(([id, binding]) => [ + id as ProjectId, + binding, + ]), + ), + ), + }), Layer.succeed( IssueTrackerRegistry.IssueTrackerRegistry, IssueTrackerRegistry.fromTrackers(input.trackers), @@ -408,3 +446,77 @@ describe("IssueService", () => { }), ); }); + +describe("IssueService with a standalone tracker", () => { + it.effect("lists a bound project's standalone scope beside its git host and serves both", () => + Effect.gen(function* () { + const listed: string[] = []; + const record = (tracker: IssueTrackerKind): Partial => ({ + listIssues: (input) => + Effect.sync(() => { + listed.push(`${tracker} ${input.host} ${input.scope}`); + return { items: [issue(tracker === LINEAR ? "ENG-1" : "1")], nextCursor: null }; + }), + }); + const projects = [project({ id: "web", repository: "acme/web" }), project({ id: "notes" })]; + const trackers = [fakeTracker(record(GITHUB)), fakeStandaloneTracker(record(LINEAR))]; + const bound = yield* makeService({ + projects, + trackers, + bindings: { ["web" as ProjectId]: { tracker: LINEAR, scope: "ENG" } }, + }); + + const result = yield* bound.list({ state: "open" }); + expect(listed.sort()).toEqual(["github github.com acme/web", "linear linear.app ENG"]); + expect(result.entries.map((entry) => [entry.tracker, entry.scope, entry.key]).sort()).toEqual( + [ + ["github", "acme/web", "1"], + ["linear", "ENG", "ENG-1"], + ], + ); + expect(result.trackers.map((tracker) => [tracker.tracker, tracker.host]).sort()).toEqual([ + ["github", "github.com"], + ["linear", "linear.app"], + ]); + // A reference picks the project's tracker by kind; both are the project's own, so writable. + const linearRef = { + projectId: "web" as ProjectId, + tracker: LINEAR, + scope: "ENG", + key: "ENG-1", + }; + expect(yield* bound.detail(linearRef)).toMatchObject({ host: "linear.app", writable: true }); + expect( + yield* bound.detail({ + projectId: "web" as ProjectId, + tracker: GITHUB, + scope: "acme/web", + key: "1", + }), + ).toMatchObject({ host: "github.com", writable: true }); + + // Unbound, the standalone scope is gone and its references are unsupported. + listed.length = 0; + const unbound = yield* makeService({ projects, trackers }); + const after = yield* unbound.list({ state: "open" }); + expect(listed).toEqual(["github github.com acme/web"]); + expect(after.trackers.map((tracker) => tracker.tracker)).toEqual(["github"]); + const refused = yield* Effect.flip(unbound.detail(linearRef)); + expect(refused).toMatchObject({ + _tag: "IssueUnavailableError", + reason: "tracker-unsupported", + }); + + // A project with no remote at all can still be bound, and then has only the standalone one. + const standaloneOnly = yield* makeService({ + projects, + trackers, + bindings: { ["notes" as ProjectId]: { tracker: LINEAR, scope: "OPS" } }, + }); + const notes = yield* standaloneOnly.list({ state: "open", projectId: "notes" as ProjectId }); + expect(notes.entries.map((entry) => [entry.projectId, entry.scope])).toEqual([ + ["notes", "OPS"], + ]); + }), + ); +}); diff --git a/apps/server/src/issue/IssueService.ts b/apps/server/src/issue/IssueService.ts index beadf97d578c..281a146256a2 100644 --- a/apps/server/src/issue/IssueService.ts +++ b/apps/server/src/issue/IssueService.ts @@ -1,3 +1,4 @@ +// A project bound to a standalone tracker (Linear) in settings lists it beside its git host's. // References outside the project's canonical repository may be read on the same host, // but every write must pass through requireWritable. import * as Context from "effect/Context"; @@ -37,9 +38,11 @@ import { sourceControlRepositorySelector } from "@t3tools/shared/sourceControl"; import { parseIssueUrl } from "@t3tools/shared/issueUrl"; import { IssueTrackerError, + isStandaloneIssueTracker, type IssueTrackerApi, } from "@t3tools/issue-tracker-core/server/IssueTracker"; +import * as IssueTrackerBindings from "../persistence/IssueTrackerBindings.ts"; import * as ProjectService from "../project/ProjectService.ts"; import * as RepositoryIdentityResolver from "../project/RepositoryIdentityResolver.ts"; import * as IssueTrackerRegistry from "./IssueTrackerRegistry.ts"; @@ -58,7 +61,7 @@ const traced = call(input).pipe(Effect.withSpan(`IssueService.${operation}`)); /** A tracker may fail with no detail; the wire errors carry a non-empty one. */ -function trackerDetail(error: IssueTrackerError): string { +export function trackerDetail(error: IssueTrackerError): string { return error.detail.trim() || "The issue tracker request failed."; } @@ -185,17 +188,43 @@ const make = Effect.gen(function* () { const registry = yield* IssueTrackerRegistry.IssueTrackerRegistry; const projects = yield* ProjectService.ProjectService; const repositoryIdentities = yield* RepositoryIdentityResolver.RepositoryIdentityResolver; + const bindings = yield* IssueTrackerBindings.IssueTrackerBindingsRepository; - const resolveProjectTracker = ( + // Read per resolution so a binding saved in Settings applies without a restart. + const resolveStandaloneBinding = ( project: OrchestrationProjectShell, ): Effect.Effect => - (project.repositoryIdentity != null - ? Effect.succeed(project.repositoryIdentity) - : repositoryIdentities.resolve(project.workspaceRoot) - ).pipe( - Effect.map((repositoryIdentity) => resolveGitHostBinding({ ...project, repositoryIdentity })), + bindings.list.pipe( + Effect.map((bound) => { + const binding = bound.get(project.id); + const api = binding === undefined ? null : registry.get(binding.tracker); + if (binding === undefined || api === null || !isStandaloneIssueTracker(api)) return null; + return { + canonicalKey: `${binding.tracker}:${api.standalone.host}/${binding.scope}`.toLowerCase(), + tracker: binding.tracker, + host: api.standalone.host, + scope: binding.scope, + }; + }), + Effect.orElseSucceed(() => null), ); + /** Where a project's issues live: its git host's tracker, its bound standalone one, or both. */ + const resolveProjectTracker = ( + project: OrchestrationProjectShell, + ): Effect.Effect> => + Effect.all([ + (project.repositoryIdentity != null + ? Effect.succeed(project.repositoryIdentity) + : repositoryIdentities.resolve(project.workspaceRoot) + ).pipe( + Effect.map((repositoryIdentity) => + resolveGitHostBinding({ ...project, repositoryIdentity }), + ), + ), + resolveStandaloneBinding(project), + ]).pipe(Effect.map((resolved) => resolved.filter((binding) => binding !== null))); + const listProjects = (filter: { readonly projectId?: IssueListInput["projectId"]; readonly host?: string | undefined; @@ -217,7 +246,7 @@ const make = Effect.gen(function* () { shells, (project) => resolveProjectTracker(project).pipe( - Effect.map((binding) => (binding === null ? [] : [{ project, ...binding }])), + Effect.map((bindings) => bindings.map((binding) => ({ project, ...binding }))), ), { concurrency: SCOPE_CONCURRENCY }, ), @@ -248,15 +277,16 @@ const make = Effect.gen(function* () { /** * The project whose checkout and credentials serve a reference, and whether the reference is * the project's own scope. A reference naming another scope on the same tracker and host is - * served by the project but marked read-only. + * served by the project but marked read-only. A project with two trackers serves the one the + * reference names. */ const requireProject = ( ref: IssueScopeRef, ): Effect.Effect => listProjects({ projectId: ref.projectId }).pipe( Effect.flatMap(({ supported }) => { - const own = supported[0]; - if (own === undefined || own.tracker !== ref.tracker) { + const own = supported.find((candidate) => candidate.tracker === ref.tracker); + if (own === undefined) { return Effect.fail(new IssueUnavailableError({ reason: "tracker-unsupported" })); } const host = ref.host?.trim().toLowerCase() ?? own.host; diff --git a/apps/server/src/issue/IssueTrackerConnections.ts b/apps/server/src/issue/IssueTrackerConnections.ts new file mode 100644 index 000000000000..90554d1eada4 --- /dev/null +++ b/apps/server/src/issue/IssueTrackerConnections.ts @@ -0,0 +1,184 @@ +/** + * Standalone issue trackers (Linear, Jira) as the settings page manages them: one credential per + * tracker kind in the secret store, with its status read live from the tracker, and the + * per-project binding that puts a tracker's scope beside the project's git-host issues. + * Disconnecting clears the bindings that pointed at the tracker. + * + * Nothing here knows which trackers exist: the registry lists them and each driver's descriptor + * says what to call the credential and the scope. Adding a tracker adds no code here. + * + * @module issue/IssueTrackerConnections + */ +import * as Context from "effect/Context"; +import * as Effect from "effect/Effect"; +import * as Layer from "effect/Layer"; +import * as Option from "effect/Option"; +import * as DateTime from "effect/DateTime"; +import { + IssueTrackerConnectionError, + IssueTrackerKind, + type IssueTrackerBindProjectInput, + type IssueTrackerConnectInput, + type IssueTrackerConnection, + type IssueTrackerConnectionList, +} from "@t3tools/contracts"; +import type { StandaloneIssueTrackerApi } from "@t3tools/issue-tracker-core/server/IssueTracker"; + +import * as ServerSecretStore from "../auth/ServerSecretStore.ts"; +import * as IssueTrackerBindings from "../persistence/IssueTrackerBindings.ts"; +import * as IssueService from "./IssueService.ts"; +import { issueTrackerSecretName } from "./IssueTrackerHostLive.ts"; +import * as IssueTrackerRegistry from "./IssueTrackerRegistry.ts"; + +const encoder = new TextEncoder(); + +export class IssueTrackerConnections extends Context.Service< + IssueTrackerConnections, + { + /** Every standalone tracker, each probed against its stored credential, and the bindings. */ + readonly list: Effect.Effect; + /** + * Vets the credential with the tracker and stores it only when the tracker accepts it. A null + * token removes the stored one and unbinds every project that pointed at the tracker. + */ + readonly connect: ( + input: IssueTrackerConnectInput, + ) => Effect.Effect; + /** Binds a project to one of a tracker's scopes, or unbinds it with a null binding. */ + readonly bindProject: ( + input: IssueTrackerBindProjectInput, + ) => Effect.Effect; + } +>()("t3/issue/IssueTrackerConnections") {} + +const make = Effect.gen(function* () { + const registry = yield* IssueTrackerRegistry.IssueTrackerRegistry; + const secrets = yield* ServerSecretStore.ServerSecretStore; + const bindings = yield* IssueTrackerBindings.IssueTrackerBindingsRepository; + + const requireTracker = ( + tracker: IssueTrackerKind, + ): Effect.Effect => { + const found = registry.standalone.find((api) => api.kind === tracker); + return found === undefined + ? Effect.fail( + new IssueTrackerConnectionError({ + tracker, + reason: "unknown-tracker", + detail: "This server has no such issue tracker.", + }), + ) + : Effect.succeed(found); + }; + + /** The kind an error about no tracker in particular is filed under. */ + const anyTracker = registry.standalone[0]?.kind ?? IssueTrackerKind.make("none"); + + const secretFailure = (tracker: IssueTrackerKind, detail: string) => (cause: unknown) => + new IssueTrackerConnectionError({ tracker, reason: "failed", detail, cause }); + + const disconnected = (api: StandaloneIssueTrackerApi): IssueTrackerConnection => ({ + ...api.standalone, + connected: false, + account: null, + detail: null, + scopes: [], + }); + + /** The tracker's view of a stored credential; a refusal is status, not a failure. */ + const status = (api: StandaloneIssueTrackerApi, token: string) => + api.probeCredential(token).pipe( + Effect.map((probe): IssueTrackerConnection => ({ + ...api.standalone, + connected: true, + account: probe.account, + detail: null, + scopes: probe.scopes, + })), + Effect.catch((error) => + Effect.succeed({ + ...api.standalone, + connected: true, + account: null, + detail: IssueService.trackerDetail(error), + scopes: [], + }), + ), + ); + + const current = (api: StandaloneIssueTrackerApi) => + secrets.get(issueTrackerSecretName(api.kind)).pipe( + Effect.mapError(secretFailure(api.kind, "The stored credential could not be read.")), + Effect.flatMap((stored) => + Option.isNone(stored) + ? Effect.succeed(disconnected(api)) + : status(api, new TextDecoder().decode(stored.value)), + ), + ); + + const list: IssueTrackerConnections["Service"]["list"] = Effect.all({ + trackers: Effect.forEach(registry.standalone, current, { concurrency: 4 }), + bindings: bindings.list.pipe( + Effect.map((bound) => Object.fromEntries(bound)), + // No single tracker is at fault; the first registered one carries the report. + Effect.mapError(secretFailure(anyTracker, "The project bindings could not be read.")), + ), + }); + + const disconnect = Effect.fn("IssueTrackerConnections.disconnect")(function* ( + api: StandaloneIssueTrackerApi, + ) { + yield* secrets + .remove(issueTrackerSecretName(api.kind)) + .pipe(Effect.mapError(secretFailure(api.kind, "The credential could not be removed."))); + // Bindings to a tracker nobody is signed into would only produce errors in every listing. + yield* bindings + .removeTracker(api.kind) + .pipe(Effect.mapError(secretFailure(api.kind, "The project bindings could not be cleared."))); + return disconnected(api); + }); + + const connect: IssueTrackerConnections["Service"]["connect"] = Effect.fn( + "IssueTrackerConnections.connect", + )(function* (input) { + const api = yield* requireTracker(input.tracker); + if (input.token === null) return yield* disconnect(api); + const probe = yield* api.probeCredential(input.token).pipe( + Effect.mapError( + (error) => + new IssueTrackerConnectionError({ + tracker: input.tracker, + reason: error.reason === "unauthenticated" ? "rejected" : "failed", + detail: IssueService.trackerDetail(error), + cause: error, + }), + ), + ); + yield* secrets + .set(issueTrackerSecretName(api.kind), encoder.encode(input.token)) + .pipe(Effect.mapError(secretFailure(api.kind, "The credential could not be stored."))); + return { + ...api.standalone, + connected: true, + account: probe.account, + detail: null, + scopes: probe.scopes, + }; + }); + + const bindProject: IssueTrackerConnections["Service"]["bindProject"] = Effect.fn( + "IssueTrackerConnections.bindProject", + )(function* (input) { + // Unbinding names no tracker; the first registered one carries any report. + const tracker = + input.binding === null ? anyTracker : (yield* requireTracker(input.binding.tracker)).kind; + const updatedAt = DateTime.formatIso(yield* DateTime.now); + yield* bindings + .set({ projectId: input.projectId, binding: input.binding, updatedAt }) + .pipe(Effect.mapError(secretFailure(tracker, "The project binding could not be saved."))); + }); + + return IssueTrackerConnections.of({ list, connect, bindProject }); +}); + +export const layer = Layer.effect(IssueTrackerConnections, make); diff --git a/apps/server/src/issue/IssueTrackerHostLive.ts b/apps/server/src/issue/IssueTrackerHostLive.ts new file mode 100644 index 000000000000..136932646fb8 --- /dev/null +++ b/apps/server/src/issue/IssueTrackerHostLive.ts @@ -0,0 +1,44 @@ +/** + * The server's `IssueTrackerHost`: standalone tracker credentials out of the secret store, one + * per tracker kind. The name is stable across releases so a saved key survives upgrades. + * + * @module issue/IssueTrackerHostLive + */ +import * as Effect from "effect/Effect"; +import * as Layer from "effect/Layer"; +import * as Option from "effect/Option"; +import type { IssueTrackerKind } from "@t3tools/contracts"; +import { IssueTrackerError } from "@t3tools/issue-tracker-core/server/IssueTracker"; +import * as IssueTrackerHost from "@t3tools/issue-tracker-core/server/IssueTrackerHost"; + +import * as ServerSecretStore from "../auth/ServerSecretStore.ts"; + +export function issueTrackerSecretName(tracker: IssueTrackerKind): string { + return `issue-tracker-${Buffer.from(tracker, "utf8").toString("base64url")}-token`; +} + +const decoder = new TextDecoder(); + +const make = Effect.gen(function* () { + const secrets = yield* ServerSecretStore.ServerSecretStore; + return IssueTrackerHost.IssueTrackerHost.of({ + credentials: { + get: (tracker) => + secrets.get(issueTrackerSecretName(tracker)).pipe( + Effect.map(Option.map((bytes) => decoder.decode(bytes))), + Effect.mapError( + (cause) => + new IssueTrackerError({ + tracker, + operation: "readCredential", + reason: "failed", + detail: "The stored credential could not be read.", + cause, + }), + ), + ), + }, + }); +}); + +export const layer = Layer.effect(IssueTrackerHost.IssueTrackerHost, make); diff --git a/apps/server/src/issue/IssueTrackerRegistry.ts b/apps/server/src/issue/IssueTrackerRegistry.ts index 7e0664527b4b..f7aea50af7bd 100644 --- a/apps/server/src/issue/IssueTrackerRegistry.ts +++ b/apps/server/src/issue/IssueTrackerRegistry.ts @@ -2,10 +2,15 @@ import * as Context from "effect/Context"; import * as Effect from "effect/Effect"; import * as Layer from "effect/Layer"; import type { IssueTrackerKind } from "@t3tools/contracts"; -import type { IssueTrackerApi } from "@t3tools/issue-tracker-core/server/IssueTracker"; +import { + isStandaloneIssueTracker, + type IssueTrackerApi, + type StandaloneIssueTrackerApi, +} from "@t3tools/issue-tracker-core/server/IssueTracker"; import * as BuiltInDrivers from "../sourceControl/builtInDrivers.ts"; import * as BuiltInIssueTrackers from "./builtInIssueTrackers.ts"; +import * as IssueTrackerHostLive from "./IssueTrackerHostLive.ts"; export class IssueTrackerRegistry extends Context.Service< IssueTrackerRegistry, @@ -13,6 +18,8 @@ export class IssueTrackerRegistry extends Context.Service< /** Null for a kind with no implementation, which the service reports as unsupported. */ readonly get: (kind: IssueTrackerKind) => IssueTrackerApi | null; readonly kinds: ReadonlyArray; + /** The trackers a user connects with a credential of their own, in registration order. */ + readonly standalone: ReadonlyArray; } >()("t3/issue/IssueTrackerRegistry") {} @@ -24,6 +31,7 @@ export function fromTrackers( return { get: (kind) => byKind.get(kind) ?? null, kinds: trackers.map((tracker) => tracker.kind), + standalone: trackers.filter(isStandaloneIssueTracker), }; } @@ -36,5 +44,5 @@ const make = Effect.gen(function* () { }); export const layer = Layer.effect(IssueTrackerRegistry, make).pipe( - Layer.provide(BuiltInDrivers.layer), + Layer.provide(Layer.merge(BuiltInDrivers.layer, IssueTrackerHostLive.layer)), ); diff --git a/apps/server/src/issue/builtInIssueTrackers.ts b/apps/server/src/issue/builtInIssueTrackers.ts index 42885d0bc454..a0559f33b5fb 100644 --- a/apps/server/src/issue/builtInIssueTrackers.ts +++ b/apps/server/src/issue/builtInIssueTrackers.ts @@ -3,12 +3,14 @@ import * as ForgejoIssueTrackerDriver from "@t3tools/source-control-forgejo/serv import * as GitHubIssueTrackerDriver from "@t3tools/source-control-github/server/issueTrackerDriver"; import * as GitLabIssueTrackerDriver from "@t3tools/source-control-gitlab/server/issueTrackerDriver"; import type { IssueTrackerDriver } from "@t3tools/issue-tracker-core/server/driver"; +import * as LinearIssueTrackerDriver from "@t3tools/issue-tracker-linear/server/issueTrackerDriver"; const drivers = [ GitHubIssueTrackerDriver.driver, GitLabIssueTrackerDriver.driver, AzureDevOpsIssueTrackerDriver.driver, ForgejoIssueTrackerDriver.driver, + LinearIssueTrackerDriver.driver, ]; export type BuiltInIssueTrackersEnv = diff --git a/apps/server/src/observability/RpcInstrumentation.ts b/apps/server/src/observability/RpcInstrumentation.ts index 009cc1fe23f3..cfd1d3c7403f 100644 --- a/apps/server/src/observability/RpcInstrumentation.ts +++ b/apps/server/src/observability/RpcInstrumentation.ts @@ -140,6 +140,9 @@ const RPC_AGGREGATES = { [WS_METHODS.issuesUpdate]: "issues", [WS_METHODS.issuesSetState]: "issues", [WS_METHODS.issuesReact]: "issues", + [WS_METHODS.issueTrackersList]: "issues", + [WS_METHODS.issueTrackersConnect]: "issues", + [WS_METHODS.issueTrackersBindProject]: "issues", [WS_METHODS.sourceControlLookupRepository]: "source-control", [WS_METHODS.sourceControlCloneRepository]: "source-control", [WS_METHODS.sourceControlPublishRepository]: "source-control", diff --git a/apps/server/src/persistence/Errors.ts b/apps/server/src/persistence/Errors.ts index 308bb128068e..fc0bace167ed 100644 --- a/apps/server/src/persistence/Errors.ts +++ b/apps/server/src/persistence/Errors.ts @@ -118,6 +118,7 @@ export type ProviderSessionRuntimeRepositoryError = PersistenceSqlError | Persis export type AuthPairingLinkRepositoryError = PersistenceSqlError | PersistenceDecodeError; export type AuthSessionRepositoryError = PersistenceSqlError | PersistenceDecodeError; export type PullRequestFilesViewedRepositoryError = PersistenceSqlError | PersistenceDecodeError; +export type IssueTrackerBindingsRepositoryError = PersistenceSqlError | PersistenceDecodeError; export type PullRequestReviewGuideRepositoryError = PersistenceSqlError | PersistenceDecodeError; export type ProjectionRepositoryError = PersistenceSqlError | PersistenceDecodeError; diff --git a/apps/server/src/persistence/IssueTrackerBindings.ts b/apps/server/src/persistence/IssueTrackerBindings.ts new file mode 100644 index 000000000000..4448f4969a31 --- /dev/null +++ b/apps/server/src/persistence/IssueTrackerBindings.ts @@ -0,0 +1,101 @@ +import * as Context from "effect/Context"; +import * as Effect from "effect/Effect"; +import * as Layer from "effect/Layer"; +import * as Schema from "effect/Schema"; +import * as SqlClient from "effect/sql/SqlClient"; +import * as SqlSchema from "effect/sql/SqlSchema"; +import { IssueTrackerKind, IssueTrackerProjectBinding, ProjectId } from "@t3tools/contracts"; + +import { + PersistenceDecodeError, + PersistenceSqlError, + type IssueTrackerBindingsRepositoryError, +} from "./Errors.ts"; + +const BindingRow = Schema.Struct({ + projectId: ProjectId, + tracker: IssueTrackerKind, + scope: Schema.String, +}); + +/** + * Which standalone issue tracker scope each project reads beside its git host's own issues. A + * project is bound to one scope at most, and only while it has a row. + */ +export class IssueTrackerBindingsRepository extends Context.Service< + IssueTrackerBindingsRepository, + { + readonly list: Effect.Effect< + ReadonlyMap, + IssueTrackerBindingsRepositoryError + >; + /** Null unbinds. */ + readonly set: (input: { + readonly projectId: ProjectId; + readonly binding: IssueTrackerProjectBinding | null; + /** When the binding was saved, as an ISO instant. */ + readonly updatedAt: string; + }) => Effect.Effect; + /** Unbinds every project that pointed at the tracker, when its credential is removed. */ + readonly removeTracker: ( + tracker: IssueTrackerKind, + ) => Effect.Effect; + } +>()("t3/persistence/IssueTrackerBindings/IssueTrackerBindingsRepository") {} + +function toSqlOrDecodeError(sqlOperation: string, decodeOperation: string) { + return (cause: unknown): IssueTrackerBindingsRepositoryError => + Schema.isSchemaError(cause) + ? PersistenceDecodeError.fromSchemaError(decodeOperation, cause) + : new PersistenceSqlError({ operation: sqlOperation, cause }); +} + +const make = Effect.gen(function* () { + const sql = yield* SqlClient.SqlClient; + + const listRows = SqlSchema.findAll({ + Request: Schema.Void, + Result: BindingRow, + execute: () => + sql` + SELECT project_id AS "projectId", tracker AS "tracker", scope AS "scope" + FROM issue_tracker_bindings + `, + }); + + return IssueTrackerBindingsRepository.of({ + list: listRows(undefined).pipe( + Effect.map( + (rows) => + new Map( + rows.map((row) => [row.projectId, { tracker: row.tracker, scope: row.scope }] as const), + ), + ), + Effect.mapError(toSqlOrDecodeError("listIssueTrackerBindings", "IssueTrackerBinding")), + ), + set: (input) => + (input.binding === null + ? sql`DELETE FROM issue_tracker_bindings WHERE project_id = ${input.projectId}` + : sql` + INSERT INTO issue_tracker_bindings (project_id, tracker, scope, updated_at) + VALUES (${input.projectId}, ${input.binding.tracker}, ${input.binding.scope}, ${input.updatedAt}) + ON CONFLICT (project_id) + DO UPDATE SET tracker = excluded.tracker, scope = excluded.scope, updated_at = excluded.updated_at + ` + ).pipe( + Effect.asVoid, + Effect.mapError( + (cause) => new PersistenceSqlError({ operation: "setIssueTrackerBinding", cause }), + ), + ), + removeTracker: (tracker) => + sql`DELETE FROM issue_tracker_bindings WHERE tracker = ${tracker}`.pipe( + Effect.asVoid, + Effect.mapError( + (cause) => new PersistenceSqlError({ operation: "removeIssueTrackerBindings", cause }), + ), + ), + }); +}); + +export const layer = Layer.effect(IssueTrackerBindingsRepository, make); diff --git a/apps/server/src/persistence/Migrations.ts b/apps/server/src/persistence/Migrations.ts index 5b8ca15241ba..a860d562b2f4 100644 --- a/apps/server/src/persistence/Migrations.ts +++ b/apps/server/src/persistence/Migrations.ts @@ -71,6 +71,7 @@ import Migration0065 from "./Migrations/065_CodexUsageNativeTurnIndex.ts"; import Migration0066 from "./Migrations/066_RepairClientSettlementTimestamps.ts"; import Migration0067 from "./Migrations/067_WebhookDedupe.ts"; import Migration0068 from "./Migrations/068_ShellStopRequestIndex.ts"; +import Migration0069 from "./Migrations/069_IssueTrackerBindings.ts"; const migrationEntries = [ [1, "OrchestrationEvents", Migration0001], @@ -142,6 +143,7 @@ const migrationEntries = [ [66, "RepairClientSettlementTimestamps", Migration0066], [67, "WebhookDedupe", Migration0067], [68, "ShellStopRequestIndex", Migration0068], + [69, "IssueTrackerBindings", Migration0069], ] as const; export const migrationManifest = migrationEntries.map(([id, name]) => [id, name] as const); diff --git a/apps/server/src/persistence/Migrations/069_IssueTrackerBindings.ts b/apps/server/src/persistence/Migrations/069_IssueTrackerBindings.ts new file mode 100644 index 000000000000..6eb450c0cc83 --- /dev/null +++ b/apps/server/src/persistence/Migrations/069_IssueTrackerBindings.ts @@ -0,0 +1,18 @@ +import * as Effect from "effect/Effect"; +import * as SqlClient from "effect/sql/SqlClient"; + +export default Effect.gen(function* () { + const sql = yield* SqlClient.SqlClient; + + // One row per project bound to a standalone issue tracker (Linear, Jira): which tracker and + // which of its scopes (a team or project key). Unbinding deletes the row; a project with no row + // reads only its git host's issues. The credential itself lives in the secret store. + yield* sql` + CREATE TABLE IF NOT EXISTS issue_tracker_bindings ( + project_id TEXT PRIMARY KEY, + tracker TEXT NOT NULL, + scope TEXT NOT NULL, + updated_at TEXT NOT NULL + ) WITHOUT ROWID + `; +}); diff --git a/apps/server/src/persistence/reconcileV2PreviewMigration.test.ts b/apps/server/src/persistence/reconcileV2PreviewMigration.test.ts index 64f1d9e3ae2f..af8e8e8fedb2 100644 --- a/apps/server/src/persistence/reconcileV2PreviewMigration.test.ts +++ b/apps/server/src/persistence/reconcileV2PreviewMigration.test.ts @@ -48,6 +48,7 @@ describe("V2 preview upgrade", () => { [66, "RepairClientSettlementTimestamps"], [67, "WebhookDedupe"], [68, "ShellStopRequestIndex"], + [69, "IssueTrackerBindings"], ]); assert.deepStrictEqual(yield* runMigrations(), []); assert.deepStrictEqual(yield* sql`SELECT * FROM orchestration_v2_legacy_imports`, imports); @@ -139,6 +140,7 @@ describe("V2 preview upgrade", () => { [66, "RepairClientSettlementTimestamps"], [67, "WebhookDedupe"], [68, "ShellStopRequestIndex"], + [69, "IssueTrackerBindings"], ]); }).pipe(Effect.provide(NodeSqliteClient.layer({ filename: ":memory:" }))), ); diff --git a/apps/server/src/server.ts b/apps/server/src/server.ts index 9611fecd7950..b8838a97234d 100644 --- a/apps/server/src/server.ts +++ b/apps/server/src/server.ts @@ -41,6 +41,8 @@ import * as PullRequestHttp from "./pullRequest/http.ts"; import * as PullRequestProviderRegistry from "./pullRequest/PullRequestProviderRegistry.ts"; import * as PullRequestService from "./pullRequest/PullRequestService.ts"; import * as IssueService from "./issue/IssueService.ts"; +import * as IssueTrackerConnections from "./issue/IssueTrackerConnections.ts"; +import * as IssueTrackerBindings from "./persistence/IssueTrackerBindings.ts"; import * as IssueTrackerRegistry from "./issue/IssueTrackerRegistry.ts"; import * as SqlitePersistence from "./persistence/Sqlite.ts"; import * as PullRequestFilesViewed from "./persistence/PullRequestFilesViewed.ts"; @@ -359,7 +361,11 @@ const layerPullRequestService = PullRequestService.layer.pipe( Layer.provide(SourceControlRateLimit.layer), ); -const layerIssueService = IssueService.layer.pipe(Layer.provide(IssueTrackerRegistry.layer)); +// Both read the one registry, so a standalone tracker connected in Settings is the same +// instance the listing reads through. +const layerIssueService = Layer.merge(IssueService.layer, IssueTrackerConnections.layer).pipe( + Layer.provide(Layer.merge(IssueTrackerRegistry.layer, IssueTrackerBindings.layer)), +); // One instance serves MCP link calls and refreshes snapshots on thread events. const layerThreadIssueService = ThreadIssueService.layer.pipe(Layer.provide(layerIssueService)); diff --git a/apps/server/src/ws.ts b/apps/server/src/ws.ts index 6c89b71928d8..78ae8d3e1548 100644 --- a/apps/server/src/ws.ts +++ b/apps/server/src/ws.ts @@ -236,6 +236,7 @@ import * as UsageService from "./usage/UsageService.ts"; import * as TraceDiagnostics from "./diagnostics/TraceDiagnostics.ts"; import * as PullRequestService from "./pullRequest/PullRequestService.ts"; import * as IssueService from "./issue/IssueService.ts"; +import * as IssueTrackerConnections from "./issue/IssueTrackerConnections.ts"; import * as PullRequestReviewGuideService from "./pullRequest/PullRequestReviewGuideService.ts"; import { listLinkedPullRequestThreads } from "./pullRequest/linkedThreads.ts"; import { pullRequestSyncKey } from "./pullRequest/pullRequestSyncKey.ts"; @@ -1228,6 +1229,7 @@ export const subscribeOrchestrationV2Shell = Effect.fn("ws.orchestrationV2.subsc const layerWsIssuesRpc = ServerWsIssuesRpcGroup.toLayer( Effect.gen(function* () { const issues = yield* IssueService.IssueService; + const issueTrackers = yield* IssueTrackerConnections.IssueTrackerConnections; return ServerWsIssuesRpcGroup.of({ [WS_METHODS.issuesList]: (input) => issues.list(input), [WS_METHODS.issuesDetail]: (input) => issues.detail(input), @@ -1239,6 +1241,9 @@ const layerWsIssuesRpc = ServerWsIssuesRpcGroup.toLayer( [WS_METHODS.issuesUpdate]: (input) => issues.update(input), [WS_METHODS.issuesSetState]: (input) => issues.setState(input), [WS_METHODS.issuesReact]: (input) => issues.react(input), + [WS_METHODS.issueTrackersList]: () => issueTrackers.list, + [WS_METHODS.issueTrackersConnect]: (input) => issueTrackers.connect(input), + [WS_METHODS.issueTrackersBindProject]: (input) => issueTrackers.bindProject(input), }); }), ); @@ -3210,6 +3215,7 @@ export const layer = Layer.unwrap( const serverSelfUpdate = yield* ServerSelfUpdate.ServerSelfUpdate; const pullRequests = yield* PullRequestService.PullRequestService; const issues = yield* IssueService.IssueService; + const issueTrackers = yield* IssueTrackerConnections.IssueTrackerConnections; const reviewGuides = yield* PullRequestReviewGuideService.PullRequestReviewGuideService; const sql = yield* SqlClient.SqlClient; return HttpRouter.add( @@ -3299,6 +3305,9 @@ export const layer = Layer.unwrap( // mutation invalidates the HTTP diff cache that every client reads from. Layer.provide(Layer.succeed(PullRequestService.PullRequestService, pullRequests)), Layer.provide(Layer.succeed(IssueService.IssueService, issues)), + Layer.provide( + Layer.succeed(IssueTrackerConnections.IssueTrackerConnections, issueTrackers), + ), Layer.provide(OtlpEndpointCheck.layer), Layer.provide( Layer.succeed( diff --git a/apps/web/src/components/Icons.tsx b/apps/web/src/components/Icons.tsx index 8faedef400f3..bb033fbdc534 100644 --- a/apps/web/src/components/Icons.tsx +++ b/apps/web/src/components/Icons.tsx @@ -134,6 +134,15 @@ export const JujutsuIcon: Icon = (props) => { ); }; +export const LinearIcon: Icon = (props) => ( + + + +); + export const GitLabIcon = ({ monochrome = false, ...props diff --git a/apps/web/src/components/settings/IssueTrackerSettings.tsx b/apps/web/src/components/settings/IssueTrackerSettings.tsx new file mode 100644 index 000000000000..afecaf94a85f --- /dev/null +++ b/apps/web/src/components/settings/IssueTrackerSettings.tsx @@ -0,0 +1,273 @@ +import { useAtomValue } from "@effect/atom-react"; +import { squashAtomCommandFailure } from "@t3tools/client-runtime/state/runtime"; +import { ExternalLinkIcon } from "lucide-react"; +import { useState, type ElementType } from "react"; +import type { + EnvironmentId, + IssueTrackerConnection, + IssueTrackerConnectionList, + ProjectId, +} from "@t3tools/contracts"; + +import { useEnvironmentQuery } from "../../state/query"; +import { issueTrackerEnvironment } from "../../state/issueTrackers"; +import { useProjects } from "../../state/entities"; +import { useAtomCommand } from "../../state/use-atom-command"; +import { LinearIcon } from "../Icons"; +import { Badge } from "../ui/badge"; +import { Button, InlineButton } from "../ui/button"; +import { Label } from "../ui/label"; +import { Select, SelectItem, SelectPopup, SelectTrigger, SelectValue } from "../ui/select"; +import { Skeleton } from "../ui/skeleton"; +import { SecretInput } from "./SecretInput"; +import { SettingsSection } from "./settingsLayout"; +import { searchableSetting } from "./settingsSearch"; + +type TrackerIcon = ElementType<{ className?: string }>; + +/** Web art per tracker kind; the server supplies everything else about a tracker. */ +const TRACKER_ICONS: Partial> = { + linear: LinearIcon, +}; + +const UNBOUND = ""; + +/** + * Standalone issue trackers for one environment: connect each with a credential, and bind the + * environment's projects to one of the tracker's scopes so their issues list beside the git + * host's. Generic over the trackers the server reports; nothing here names Linear but its icon. + */ +export function IssueTrackerSettings({ environmentId }: { readonly environmentId: EnvironmentId }) { + const query = useEnvironmentQuery( + issueTrackerEnvironment.connections({ environmentId, input: {} }), + ); + const trackers = query.data?.trackers ?? []; + if (query.data === null && query.isPending) { + return ( + +
+ + +
+
+ ); + } + if (trackers.length === 0) return null; + return ( + + {trackers.map((tracker) => ( + + ))} + + ); +} + +function TrackerRow({ + environmentId, + tracker, + bindings, +}: { + readonly environmentId: EnvironmentId; + readonly tracker: IssueTrackerConnection; + readonly bindings: IssueTrackerConnectionList["bindings"]; +}) { + const Icon = TRACKER_ICONS[tracker.tracker]; + const canEdit = useAtomValue(issueTrackerEnvironment.connect.permissionAtom(environmentId)); + const connect = useAtomCommand(issueTrackerEnvironment.connect, { + label: `connect ${tracker.displayName}`, + }); + const [draft, setDraft] = useState(""); + const [busy, setBusy] = useState(false); + const [failure, setFailure] = useState(null); + + const submit = async (token: string | null) => { + setBusy(true); + setFailure(null); + const result = await connect({ + environmentId, + input: { tracker: tracker.tracker, token }, + }); + setBusy(false); + if (result._tag === "Success") { + setDraft(""); + return; + } + const error = squashAtomCommandFailure(result); + setFailure(error instanceof Error ? error.message : "The request failed."); + }; + + const status = !tracker.connected ? ( + Not connected + ) : tracker.account === null ? ( + Credential rejected + ) : ( + Connected as {tracker.account} + ); + + return ( +
+
+
+
+ {Icon ? : null} + + {tracker.displayName} + + {status} +
+ {tracker.connected ? ( + + ) : null} +
+ {tracker.detail ?

{tracker.detail}

: null} +
{ + event.preventDefault(); + if (draft.trim()) void submit(draft.trim()); + }} + > + {/* Locked while saving: a successful save clears the draft, which would drop mid-request edits. */} +
+
+ +
+ setDraft(event.target.value)} + /> + +
+
+
+ {failure ?

{failure}

: null} +
+ {tracker.connected && tracker.account !== null ? ( + + ) : null} +
+
+ ); +} + +/** One picker per project of this environment: which of the tracker's scopes it reads, if any. */ +function ProjectBindings({ + environmentId, + tracker, + bindings, + disabled, +}: { + readonly environmentId: EnvironmentId; + readonly tracker: IssueTrackerConnection; + readonly bindings: IssueTrackerConnectionList["bindings"]; + readonly disabled: boolean; +}) { + const projects = useProjects().filter((project) => project.environmentId === environmentId); + const bind = useAtomCommand(issueTrackerEnvironment.bindProject, { + label: `bind project to ${tracker.displayName}`, + }); + const [pending, setPending] = useState(null); + if (projects.length === 0 || tracker.scopes.length === 0) return null; + + const change = async (projectId: ProjectId, scope: string) => { + setPending(projectId); + await bind({ + environmentId, + input: { + projectId, + binding: scope === UNBOUND ? null : { tracker: tracker.tracker, scope }, + }, + }); + setPending(null); + }; + + return ( +
+

+ Pick the {tracker.displayName} {tracker.scopeNoun} whose issues each project lists beside + its repository's own. +

+
    + {projects.map((project) => { + const bound = bindings[project.id]; + // A project bound to another tracker keeps that binding; this picker shows it unbound. + const value = bound?.tracker === tracker.tracker ? bound.scope : UNBOUND; + return ( +
  • + {project.title} + +
  • + ); + })} +
+
+ ); +} diff --git a/apps/web/src/components/settings/SourceControlSettings.tsx b/apps/web/src/components/settings/SourceControlSettings.tsx index 16d4d042693a..001ae4712725 100644 --- a/apps/web/src/components/settings/SourceControlSettings.tsx +++ b/apps/web/src/components/settings/SourceControlSettings.tsx @@ -46,6 +46,7 @@ import { Switch } from "../ui/switch"; import { Tooltip, TooltipPopup, TooltipTrigger } from "../ui/tooltip"; import { GitIcon, JujutsuIcon, type Icon } from "../Icons"; +import { IssueTrackerSettings } from "./IssueTrackerSettings"; import { SourceControlHostSettings } from "./SourceControlHostSettings"; import { GitHubAccountSettings } from "./GitHubAccountSettings"; import { GitHubTokenSettings } from "./GitHubTokenSettings"; @@ -639,6 +640,9 @@ export function SourceControlSettingsPanel() { onScan={handleScan} /> )} + {environmentId === null ? null : ( + + )} diff --git a/apps/web/src/components/settings/settingsSearch.ts b/apps/web/src/components/settings/settingsSearch.ts index c7c5f26ae90d..18d7b2fe36b9 100644 --- a/apps/web/src/components/settings/settingsSearch.ts +++ b/apps/web/src/components/settings/settingsSearch.ts @@ -797,6 +797,13 @@ export const SETTINGS_SEARCH_ITEMS = [ scope: "project-defaults", searchTerms: ["pull request merge squash rebase last selected"], }, + { + id: "issue-trackers", + title: "Issue trackers", + to: "/settings/source-control", + scope: "environment-defaults", + searchTerms: ["linear jira issues tracker team api key connect bind project"], + }, { id: "source-control", title: "Source control", diff --git a/apps/web/src/state/issueTrackers.ts b/apps/web/src/state/issueTrackers.ts new file mode 100644 index 000000000000..ec1dd56425c2 --- /dev/null +++ b/apps/web/src/state/issueTrackers.ts @@ -0,0 +1,5 @@ +import { createIssueTrackerEnvironmentAtoms } from "@t3tools/client-runtime/state/issue-trackers"; + +import { connectionAtomRuntime } from "../connection/runtime"; + +export const issueTrackerEnvironment = createIssueTrackerEnvironmentAtoms(connectionAtomRuntime); diff --git a/knip.jsonc b/knip.jsonc index babc22932ca0..fdf5cb2e76a4 100644 --- a/knip.jsonc +++ b/knip.jsonc @@ -131,6 +131,11 @@ "entry": ["test/fixtures/*.ts"], "ignoreIssues": { "src/_generated/**": ["exports", "types"] }, }, + "packages/issue-tracker-linear": { + // graphqlgen reads its config; the generated operations export every selection's class. + "entry": ["graphql.config.ts"], + "ignoreIssues": { "**/*.graphql.ts": ["exports", "types", "namespaceMembers"] }, + }, "packages/source-control-github": { // graphqlgen reads its config; the generated operations export every selection's class. "entry": ["graphql.config.ts"], diff --git a/package.json b/package.json index d7e802c1d95a..1460b301a9b5 100644 --- a/package.json +++ b/package.json @@ -29,7 +29,7 @@ "check:changed": "node scripts/check-changed.ts", "lint": "vp lint --report-unused-disable-directives", "knip": "knip --preprocessor ./scripts/knip-schemas.ts", - "knip:check": "knip --include files,dependencies --no-config-hints && knip --workspace apps/server --workspace apps/desktop --workspace apps/web --workspace packages/client-runtime --workspace packages/contracts --workspace packages/effect-acp --workspace packages/effect-codex-app-server --workspace packages/shared --workspace packages/ssh --workspace packages/tailscale --workspace packages/provider-core --workspace packages/provider-acp --workspace packages/provider-acp-registry --workspace packages/provider-testing --workspace packages/provider-pi --workspace packages/provider-muse --workspace packages/provider-opencode --workspace packages/provider-cursor --workspace packages/provider-grok --workspace packages/issue-tracker-core --workspace packages/source-control-core --workspace packages/source-control-azure-devops --workspace packages/source-control-bitbucket --workspace packages/source-control-forgejo --workspace packages/source-control-gitcafe --workspace packages/source-control-github --workspace packages/source-control-gitlab --workspace packages/source-control-testing --exports --preprocessor ./scripts/knip-schemas.ts --no-config-hints", + "knip:check": "knip --include files,dependencies --no-config-hints && knip --workspace apps/server --workspace apps/desktop --workspace apps/web --workspace packages/client-runtime --workspace packages/contracts --workspace packages/effect-acp --workspace packages/effect-codex-app-server --workspace packages/shared --workspace packages/ssh --workspace packages/tailscale --workspace packages/provider-core --workspace packages/provider-acp --workspace packages/provider-acp-registry --workspace packages/provider-testing --workspace packages/provider-pi --workspace packages/provider-muse --workspace packages/provider-opencode --workspace packages/provider-cursor --workspace packages/provider-grok --workspace packages/issue-tracker-core --workspace packages/issue-tracker-linear --workspace packages/source-control-core --workspace packages/source-control-azure-devops --workspace packages/source-control-bitbucket --workspace packages/source-control-forgejo --workspace packages/source-control-gitcafe --workspace packages/source-control-github --workspace packages/source-control-gitlab --workspace packages/source-control-testing --exports --preprocessor ./scripts/knip-schemas.ts --no-config-hints", "knip:production": "knip --production --preprocessor ./scripts/knip-schemas.ts", "lint:mobile": "node scripts/mobile-native-static-check.ts", "test": "vp run -r test", diff --git a/packages/client-runtime/package.json b/packages/client-runtime/package.json index 3d69b2ff2772..748acf9b24fc 100644 --- a/packages/client-runtime/package.json +++ b/packages/client-runtime/package.json @@ -267,6 +267,10 @@ "types": "./src/state/shell.ts", "default": "./src/state/shell.ts" }, + "./state/issue-trackers": { + "types": "./src/state/issueTrackers.ts", + "default": "./src/state/issueTrackers.ts" + }, "./state/source-control": { "types": "./src/state/sourceControl.ts", "default": "./src/state/sourceControl.ts" diff --git a/packages/client-runtime/src/state/commandPermissions.test.ts b/packages/client-runtime/src/state/commandPermissions.test.ts index 09927e38398a..2741e3f0e90e 100644 --- a/packages/client-runtime/src/state/commandPermissions.test.ts +++ b/packages/client-runtime/src/state/commandPermissions.test.ts @@ -115,6 +115,31 @@ describe("command permissions", () => { ), ); + it.effect("requires the destination settings grant to connect or bind an issue tracker", () => + Effect.scoped( + Effect.gen(function* () { + const registry = yield* setup; + const connect = createCommandPermissions(runtime, WS_METHODS.issueTrackersConnect); + const bind = createCommandPermissions(runtime, WS_METHODS.issueTrackersBindProject); + registry.set(sessions(env), AsyncResult.success(grant(true))); + expect(registry.get(connect.permissionAtom(env))).toBe(false); + expect(registry.get(bind.permissionAtom(env))).toBe(false); + registry.set( + sessions(env), + AsyncResult.success({ + ...grant(false), + scopes: [AuthSettingsWriteScope], + permissions: [AuthSettingsWriteScope], + }), + ); + expect(registry.get(connect.permissionAtom(env))).toBe(true); + expect(registry.get(bind.permissionAtom(env))).toBe(true); + yield* connect.authorize(registry, env); + yield* bind.authorize(registry, env); + }), + ), + ); + it.effect("uses the target grant for both availability and execution", () => Effect.scoped( Effect.gen(function* () { diff --git a/packages/client-runtime/src/state/issueTrackers.ts b/packages/client-runtime/src/state/issueTrackers.ts new file mode 100644 index 000000000000..1b4ebfa1dab1 --- /dev/null +++ b/packages/client-runtime/src/state/issueTrackers.ts @@ -0,0 +1,54 @@ +import { WS_METHODS } from "@t3tools/contracts"; +import * as Effect from "effect/Effect"; +import { Atom } from "effect/reactivity"; + +import { + createAtomCommandScheduler, + createEnvironmentRpcCommand, + createEnvironmentRpcQueryAtomFamily, +} from "./runtime.ts"; +import type { EnvironmentRegistry } from "../connection/registry.ts"; +import * as Persistence from "../platform/persistence.ts"; + +/** + * Standalone issue trackers (Linear, Jira) per environment: which are connected, as whom, which + * scopes they reach, and which project is bound to which scope. One query carries all of it, and + * every mutation refreshes that query, so the settings page never shows a stale status. + */ +export function createIssueTrackerEnvironmentAtoms( + runtime: Atom.AtomRuntime, +) { + const commandScheduler = createAtomCommandScheduler(); + const connections = createEnvironmentRpcQueryAtomFamily(runtime, { + label: "environment-data:issue-trackers:connections", + tag: WS_METHODS.issueTrackersList, + }); + const refresh = (environmentId: Parameters[0]["environmentId"]) => + connections({ environmentId, input: {} }); + // Connect, disconnect and bind all edit one environment's tracker state; serialized so a + // disconnect cannot race the bind of a project to the tracker being removed. + const serialPerEnvironment = { + mode: "serial" as const, + key: ({ environmentId }: { readonly environmentId: string }) => environmentId, + }; + return { + connections, + /** Saves a credential the tracker accepted, or removes the stored one with a null token. */ + connect: createEnvironmentRpcCommand(runtime, { + label: "environment-data:issue-trackers:connect", + tag: WS_METHODS.issueTrackersConnect, + scheduler: commandScheduler, + concurrency: serialPerEnvironment, + onSettled: (target, registry) => + Effect.sync(() => registry.refresh(refresh(target.environmentId))), + }), + bindProject: createEnvironmentRpcCommand(runtime, { + label: "environment-data:issue-trackers:bind-project", + tag: WS_METHODS.issueTrackersBindProject, + scheduler: commandScheduler, + concurrency: serialPerEnvironment, + onSettled: (target, registry) => + Effect.sync(() => registry.refresh(refresh(target.environmentId))), + }), + }; +} diff --git a/packages/contracts/src/clientRpcPermissions.ts b/packages/contracts/src/clientRpcPermissions.ts index 40a08aae9d51..eb41c21b7f6b 100644 --- a/packages/contracts/src/clientRpcPermissions.ts +++ b/packages/contracts/src/clientRpcPermissions.ts @@ -32,6 +32,9 @@ export const CLIENT_GUARDED_RPC_SCOPES = { [WS_METHODS.issuesUpdate]: AuthSourceControlWriteScope, [WS_METHODS.issuesSetState]: AuthSourceControlWriteScope, [WS_METHODS.issuesReact]: AuthSourceControlWriteScope, + // A tracker credential and a project's binding are settings, saved under the same grant. + [WS_METHODS.issueTrackersConnect]: AuthSettingsWriteScope, + [WS_METHODS.issueTrackersBindProject]: AuthSettingsWriteScope, // Writing a guide runs a model on this environment's providers, which reading one does not. [WS_METHODS.pullRequestsGenerateReviewGuide]: AuthOrchestrationOperateScope, [WS_METHODS.sourceControlCloneRepository]: AuthSourceControlWriteScope, diff --git a/packages/contracts/src/issue.ts b/packages/contracts/src/issue.ts index 530ed5a8cc27..73add359fce8 100644 --- a/packages/contracts/src/issue.ts +++ b/packages/contracts/src/issue.ts @@ -392,8 +392,19 @@ export const IssueTemplate = Schema.Struct({ }); export type IssueTemplate = typeof IssueTemplate.Type; +/** A starting point only the tracker's own site can render: Linear's form and rich templates. */ +export const IssueExternalTemplate = Schema.Struct({ + name: TrimmedNonEmptyString, + about: Schema.String, + /** Opens the exact template on the tracker, ready to fill in. */ + url: TrimmedNonEmptyString, +}); +export type IssueExternalTemplate = typeof IssueExternalTemplate.Type; + export const IssueTemplateList = Schema.Struct({ templates: Schema.Array(IssueTemplate), + /** Absent from a tracker whose every template is body-shaped. */ + externalTemplates: Schema.optional(Schema.Array(IssueExternalTemplate)), /** False where the scope's config forbids an issue filed from nothing. */ blankIssuesEnabled: Schema.Boolean, }); @@ -534,3 +545,98 @@ export function threadIssueRefOf(link: ThreadIssueLink): IssueRef { key: link.key, }; } + +/** + * A tracker that is not a git host: it is reached with its own credential rather than a + * checkout's, and a project opts into it by binding one of the tracker's scopes. Everything a + * client needs to draw the connect flow for any such tracker without knowing which one it is. + */ +export const StandaloneIssueTrackerDescriptor = Schema.Struct({ + tracker: IssueTrackerKind, + displayName: TrimmedNonEmptyString, + /** Where the tracker is served from; what `IssueRef.host` carries for its issues. */ + host: TrimmedNonEmptyString, + /** What the tracker calls its container, in the singular: "team" on Linear, "project" on Jira. */ + scopeNoun: TrimmedNonEmptyString, + credential: Schema.Struct({ + /** What the tracker calls the credential: "Personal API key", "API token". */ + label: TrimmedNonEmptyString, + /** Where to mint one, or null when the tracker has no stable page for it. */ + helpUrl: Schema.NullOr(TrimmedNonEmptyString), + }), +}); +export type StandaloneIssueTrackerDescriptor = typeof StandaloneIssueTrackerDescriptor.Type; + +/** Which standalone tracker scope a project's issues come from, beside its git host's own. */ +export const IssueTrackerProjectBinding = Schema.Struct({ + tracker: IssueTrackerKind, + scope: TrimmedNonEmptyString, +}); +export type IssueTrackerProjectBinding = typeof IssueTrackerProjectBinding.Type; + +/** One container the connected account can read, offered when a project is bound. */ +export const IssueTrackerScope = Schema.Struct({ + key: TrimmedNonEmptyString, + name: TrimmedNonEmptyString, +}); +export type IssueTrackerScope = typeof IssueTrackerScope.Type; + +/** + * A standalone tracker as the settings page sees it: the descriptor, whether a credential is + * stored and still works, and the scopes it can reach. `scopes` is empty until connected. + */ +export const IssueTrackerConnection = Schema.Struct({ + ...StandaloneIssueTrackerDescriptor.fields, + /** A credential is stored. It may still be rejected, which `account` being null reports. */ + connected: Schema.Boolean, + /** Who the credential signs in as, or null when there is none or it was refused. */ + account: Schema.NullOr(TrimmedNonEmptyString), + /** Why a stored credential did not work, when it did not. */ + detail: Schema.NullOr(TrimmedNonEmptyString), + scopes: Schema.Array(IssueTrackerScope), +}); +export type IssueTrackerConnection = typeof IssueTrackerConnection.Type; + +export const IssueTrackerConnectionList = Schema.Struct({ + trackers: Schema.Array(IssueTrackerConnection), + /** Which standalone tracker scope each bound project reads; a project absent here reads none. */ + bindings: Schema.Record(ProjectId, IssueTrackerProjectBinding), +}); +export type IssueTrackerConnectionList = typeof IssueTrackerConnectionList.Type; + +/** A credential for one standalone tracker; `null` disconnects it and unbinds its projects. */ +export const IssueTrackerConnectInput = Schema.Struct({ + tracker: IssueTrackerKind, + token: Schema.NullOr(TrimmedNonEmptyString.check(Schema.isMaxLength(4_096))), +}); +export type IssueTrackerConnectInput = typeof IssueTrackerConnectInput.Type; + +export const IssueTrackerBindProjectInput = Schema.Struct({ + projectId: ProjectId, + /** Null unbinds. */ + binding: Schema.NullOr(IssueTrackerProjectBinding), +}); +export type IssueTrackerBindProjectInput = typeof IssueTrackerBindProjectInput.Type; + +/** + * A standalone tracker the connect flow could not reach or that refused the credential, or a + * binding that could not be saved. + */ +export class IssueTrackerConnectionError extends Schema.TaggedError()( + "IssueTrackerConnectionError", + { + tracker: IssueTrackerKind, + reason: Schema.Literals(["unknown-tracker", "rejected", "failed"]), + detail: TrimmedNonEmptyString, + cause: Schema.optional(Schema.Defect()), + }, + { httpApiStatus: 502 }, +) { + [HttpServerRespondable.symbol]() { + return HttpServerResponse.schemaJson(IssueTrackerConnectionError)(this, { status: 502 }); + } + + override get message(): string { + return `${this.tracker} connection failed: ${this.detail}`; + } +} diff --git a/packages/contracts/src/rpc.ts b/packages/contracts/src/rpc.ts index e981abc10679..5f0d5b7bf1f7 100644 --- a/packages/contracts/src/rpc.ts +++ b/packages/contracts/src/rpc.ts @@ -177,6 +177,11 @@ import { IssueScopeRef, IssueSetStateInput, IssueTemplateList, + IssueTrackerBindProjectInput, + IssueTrackerConnectInput, + IssueTrackerConnection, + IssueTrackerConnectionError, + IssueTrackerConnectionList, IssueUnavailableError, IssueUpdateInput, } from "./issue.ts"; @@ -588,6 +593,9 @@ export const WS_METHODS = { issuesUpdate: "issues.update", issuesSetState: "issues.setState", issuesReact: "issues.react", + issueTrackersList: "issueTrackers.list", + issueTrackersConnect: "issueTrackers.connect", + issueTrackersBindProject: "issueTrackers.bindProject", sourceControlLookupRepository: "sourceControl.lookupRepository", sourceControlCloneRepository: "sourceControl.cloneRepository", @@ -1254,6 +1262,34 @@ const WsIssuesReactRpc = Rpc.make(WS_METHODS.issuesReact, { error: IssueRpcError, }); +const IssueTrackerRpcError = Schema.Union([ + IssueTrackerConnectionError, + EnvironmentAuthorizationError, +]); + +/** Every standalone tracker this server ships, each with its connection probed afresh. */ +const WsIssueTrackersListRpc = Rpc.make(WS_METHODS.issueTrackersList, { + payload: Schema.Struct({}), + success: IssueTrackerConnectionList, + error: IssueTrackerRpcError, +}); + +/** + * Verifies the credential against the tracker before storing it; the result is the new status. + * A null token disconnects, which also unbinds every project that pointed at the tracker. + */ +const WsIssueTrackersConnectRpc = Rpc.make(WS_METHODS.issueTrackersConnect, { + payload: IssueTrackerConnectInput, + success: IssueTrackerConnection, + error: IssueTrackerRpcError, +}); + +const WsIssueTrackersBindProjectRpc = Rpc.make(WS_METHODS.issueTrackersBindProject, { + payload: IssueTrackerBindProjectInput, + success: Schema.Void, + error: IssueTrackerRpcError, +}); + const WsSourceControlLookupRepositoryRpc = Rpc.make(WS_METHODS.sourceControlLookupRepository, { payload: SourceControlRepositoryLookupInput, success: SourceControlRepositoryInfo, @@ -1995,6 +2031,9 @@ export const WsIssuesRpcGroup = RpcGroup.make( WsIssuesUpdateRpc, WsIssuesSetStateRpc, WsIssuesReactRpc, + WsIssueTrackersListRpc, + WsIssueTrackersConnectRpc, + WsIssueTrackersBindProjectRpc, ).middleware(RpcScopeAuthorization); /** Every WebSocket RPC not in a domain group merged into `WsRpcGroup` below. */ diff --git a/packages/issue-tracker-core/package.json b/packages/issue-tracker-core/package.json index a3bc360a56ea..b7da4172f443 100644 --- a/packages/issue-tracker-core/package.json +++ b/packages/issue-tracker-core/package.json @@ -10,6 +10,10 @@ "./server/IssueTracker": { "types": "./src/server/IssueTracker.ts", "import": "./src/server/IssueTracker.ts" + }, + "./server/IssueTrackerHost": { + "types": "./src/server/IssueTrackerHost.ts", + "import": "./src/server/IssueTrackerHost.ts" } }, "scripts": { diff --git a/packages/issue-tracker-core/src/server/IssueTracker.ts b/packages/issue-tracker-core/src/server/IssueTracker.ts index 4913d5e6e73e..d9a53c6aae11 100644 --- a/packages/issue-tracker-core/src/server/IssueTracker.ts +++ b/packages/issue-tracker-core/src/server/IssueTracker.ts @@ -23,7 +23,9 @@ import type { IssueSummary, IssueTemplateList, IssueTrackerKind, + IssueTrackerScope, IssueViewerPermissions, + StandaloneIssueTrackerDescriptor, } from "@t3tools/contracts"; import { IssueTrackerKind as IssueTrackerKindSchema } from "@t3tools/contracts"; @@ -180,3 +182,27 @@ export interface IssueTrackerApi { input: IssueScopeTarget, ) => Effect.Effect; } + +/** + * A tracker reached with its own credential rather than a checkout's: Linear, Jira. The server + * stores one credential per kind and offers the connect flow from `standalone`; a project reads + * the tracker by binding one of the scopes `probeCredential` lists. The `cwd` on every target is + * then only the project's root, which such a tracker ignores. + */ +export interface StandaloneIssueTrackerApi extends IssueTrackerApi { + readonly standalone: StandaloneIssueTrackerDescriptor; + /** + * Who a credential signs in as and which scopes it reaches, asked of the tracker itself. Run on + * a credential before it is stored, and on the stored one to report connection status. + */ + readonly probeCredential: ( + token: string, + ) => Effect.Effect< + { readonly account: string; readonly scopes: ReadonlyArray }, + IssueTrackerError + >; +} + +export function isStandaloneIssueTracker(api: IssueTrackerApi): api is StandaloneIssueTrackerApi { + return "standalone" in api; +} diff --git a/packages/issue-tracker-core/src/server/IssueTrackerHost.ts b/packages/issue-tracker-core/src/server/IssueTrackerHost.ts new file mode 100644 index 000000000000..a03e7f476a74 --- /dev/null +++ b/packages/issue-tracker-core/src/server/IssueTrackerHost.ts @@ -0,0 +1,28 @@ +/** + * IssueTrackerHost โ€” what a standalone tracker package may ask of the server it runs in. + * + * A standalone tracker signs its requests with a credential the user saved in Settings, which the + * server keeps in its secret store. The package must not import the server, so it reads the + * credential through this one service; the server provides it. Git-host trackers never need it: + * their CLIs and the source control host carry their own credentials. + * + * @module issue-tracker-core/server/IssueTrackerHost + */ +import type { IssueTrackerKind } from "@t3tools/contracts"; +import * as Context from "effect/Context"; +import type * as Effect from "effect/Effect"; +import type * as Option from "effect/Option"; + +import type { IssueTrackerError } from "./IssueTracker.ts"; + +export class IssueTrackerHost extends Context.Service< + IssueTrackerHost, + { + readonly credentials: { + /** Read fresh on each call, so a credential saved in Settings applies without a restart. */ + readonly get: ( + tracker: IssueTrackerKind, + ) => Effect.Effect, IssueTrackerError>; + }; + } +>()("@t3tools/issue-tracker-core/server/IssueTrackerHost") {} diff --git a/packages/issue-tracker-linear/graphql.config.ts b/packages/issue-tracker-linear/graphql.config.ts new file mode 100644 index 000000000000..a08c595130d5 --- /dev/null +++ b/packages/issue-tracker-linear/graphql.config.ts @@ -0,0 +1,21 @@ +import { defineConfig } from "@effect/graphql-generator/Config"; + +// `schema/linear.graphql` is the public schema Linear publishes with its SDK +// (https://github.com/linear/linear/blob/master/packages/sdk/src/schema.graphql). +export default defineConfig({ + schema: "./schema/linear.graphql", + documents: ["src/**/*.graphql"], + scalars: { + // Kept as Linear sends it: the tracker passes these on as ISO strings. + DateTime: "effect/Schema#String", + // An attachment's metadata arrives as an object; its shape depends on the integration. + JSONObject: "effect/Schema#Json", + // Documented as stringified JSON, but a template's data has also arrived as an object. + JSON: "effect/Schema#Json", + // Filters compare dates with these; the tracker sends none of them. + DateTimeOrDuration: "effect/Schema#String", + Duration: "effect/Schema#String", + TimelessDate: "effect/Schema#String", + TimelessDateOrDuration: "effect/Schema#String", + }, +}); diff --git a/packages/issue-tracker-linear/package.json b/packages/issue-tracker-linear/package.json new file mode 100644 index 000000000000..6647627c0c3d --- /dev/null +++ b/packages/issue-tracker-linear/package.json @@ -0,0 +1,36 @@ +{ + "name": "@t3tools/issue-tracker-linear", + "private": true, + "type": "module", + "exports": { + "./server/LinearApi": { + "types": "./src/server/LinearApi.ts", + "import": "./src/server/LinearApi.ts" + }, + "./server/LinearIssueTracker": { + "types": "./src/server/LinearIssueTracker.ts", + "import": "./src/server/LinearIssueTracker.ts" + }, + "./server/issueTrackerDriver": { + "types": "./src/server/issueTrackerDriver.ts", + "import": "./src/server/issueTrackerDriver.ts" + } + }, + "scripts": { + "typecheck": "tsc --noEmit", + "test": "vp test run --config ../../vite.config.ts --dir .", + "generate": "graphqlgen" + }, + "dependencies": { + "@t3tools/contracts": "workspace:*", + "@t3tools/issue-tracker-core": "workspace:*", + "@t3tools/source-control-core": "workspace:*", + "effect": "catalog:" + }, + "devDependencies": { + "@effect/graphql-generator": "catalog:", + "@effect/vitest": "catalog:", + "@types/node": "catalog:", + "vite-plus": "catalog:" + } +} diff --git a/packages/issue-tracker-linear/schema/linear.graphql b/packages/issue-tracker-linear/schema/linear.graphql new file mode 100644 index 000000000000..635514ae55c3 --- /dev/null +++ b/packages/issue-tracker-linear/schema/linear.graphql @@ -0,0 +1,53680 @@ +schema { + query: Query + mutation: Mutation + subscription: Subscription +} + +"Indicates exactly one field must be supplied and this field must not be `null`." +directive @oneOf on INPUT_OBJECT + +""" +A release returned using a release pipeline access key. +""" +type AccessKeyRelease { + """ + The time at which the release was archived. Null if the release has not been archived. + """ + archivedAt: DateTime + """ + The Git commit SHA associated with the release. + """ + commitSha: String + """ + The time at which the release was completed. Null if the release has not been completed. + """ + completedAt: DateTime + """ + The time at which the release was created. + """ + createdAt: DateTime! + """ + The unique identifier of the release. + """ + id: ID! + """ + The name of the release. + """ + name: String! + """ + The current stage of the release. + """ + stage: AccessKeyReleaseStage! + """ + The URL to the release page in the Linear app. + """ + url: String! + """ + The version identifier for this release. Null if no version has been assigned. + """ + version: String +} + +""" +The result of a release mutation using a release pipeline access key. +""" +type AccessKeyReleasePayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + The release that was created or updated. + """ + release: AccessKeyRelease! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +A release pipeline returned using a release pipeline access key. +""" +type AccessKeyReleasePipeline { + """ + The unique identifier of the release pipeline. + """ + id: ID! + """ + Glob patterns used to filter commits by changed file path. An empty array means all commits are included. + """ + includePathPatterns: [String!]! +} + +""" +A release stage returned using a release pipeline access key. +""" +type AccessKeyReleaseStage { + """ + The name of the release stage. + """ + name: String! + """ + The type of the release stage. + """ + type: ReleaseStageType! +} + +""" +Activity collection filtering options. +""" +input ActivityCollectionFilter { + """ + Compound filters, all of which need to be matched by the activity. + """ + and: [ActivityCollectionFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Filters that needs to be matched by all activities. + """ + every: ActivityFilter + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Comparator for the collection length. + """ + length: NumberComparator + """ + Compound filters, one of which need to be matched by the activity. + """ + or: [ActivityCollectionFilter!] + """ + Filters that needs to be matched by some activities. + """ + some: ActivityFilter + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator + """ + Filters that the activity's user must satisfy. + """ + user: UserFilter +} + +""" +Activity filtering options. +""" +input ActivityFilter { + """ + Compound filters, all of which need to be matched by the activity. + """ + and: [ActivityFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Compound filters, one of which need to be matched by the activity. + """ + or: [ActivityFilter!] + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator + """ + Filters that the activity's user must satisfy. + """ + user: UserFilter +} + +""" +A bot actor representing a non-human entity that performed an action, such as an integration (GitHub, Slack, Zendesk), an AI assistant, or an automated workflow. Bot actors are displayed in activity feeds and history to indicate when changes were made by applications rather than users. +""" +type ActorBot { + """ + A URL pointing to the avatar image representing this bot, typically the integration's logo or icon. + """ + avatarUrl: String + """ + A unique identifier for the bot actor. + """ + id: ID + """ + The display name of the bot. + """ + name: String + """ + A more specific classification within the bot type, providing additional context about the integration or application variant. + """ + subType: String + """ + The source type of the bot, identifying the application or integration (e.g., 'github', 'slack', 'workflow', 'ai'). + """ + type: String! + """ + The display name of the external user on behalf of whom the bot acted. Shown when an integration action was triggered by a specific person in the external system. + """ + userDisplayName: String +} + +""" +An activity performed by or directed at an AI coding agent during a session. Activities represent the observable steps of an agent's work, including thoughts, actions (tool calls), responses, prompts from users, errors, and elicitation requests. Each activity belongs to an agent session and is associated with the user who initiated it. +""" +type AgentActivity implements Node { + """ + The agent session this activity belongs to. + """ + agentSession: AgentSession! + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The content of the activity, which varies by type (thought, action, response, prompt, error, or elicitation). + """ + content: AgentActivityContent! + """ + [Internal] Metadata about user-provided contextual information for this agent activity. + """ + contextualMetadata: JSON + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + Whether the activity is ephemeral, and should disappear after the next agent activity. + """ + ephemeral: Boolean! + """ + [Internal] The reason this activity was persisted without being sent to the agent runtime. + """ + executionSkippedReason: AgentActivityExecutionSkippedReason + """ + The unique identifier of the entity. + """ + id: ID! + """ + [Internal] What the turn pushed to its branch, captured in the sandbox at push time. Only set on the activity for a successful push. + """ + pushSummary: AgentActivityPushSummary + """ + [Internal] Whether this activity is queued for later processing. Queued activities are not sent to the agent until the session reaches a terminal state. + """ + queued: Boolean! + """ + [Internal] The time at which the prompt actually entered the conversation. Only set when the prompt did not enter the conversation immediately (i.e., it was queued and later dequeued). Null for prompts that were sent directly and for non-prompt activities. + """ + sentAt: DateTime + """ + An optional modifier that provides additional instructions on how the activity should be interpreted. + """ + signal: AgentActivitySignal + """ + Metadata about this agent activity's signal. + """ + signalMetadata: JSON + """ + The source comment this activity is linked to. Null if the activity was not triggered by a comment. + """ + sourceComment: Comment + """ + Metadata about the external source that created this agent activity. + """ + sourceMetadata: JSON + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The user who created this agent activity. + """ + user: User! +} + +""" +Content for an action activity (tool call or action). +""" +type AgentActivityActionContent { + """ + The action being performed. + """ + action: String! + """ + The parameters for the action, e.g. a file path, a keyword, etc. + """ + parameter: String! + """ + The result of the action in Markdown format. + """ + result: String + """ + [Internal] The result content as ProseMirror document. + """ + resultData: JSONObject + """ + The type of activity. + """ + type: AgentActivityType! +} + +type AgentActivityConnection { + edges: [AgentActivityEdge!]! + nodes: [AgentActivity!]! + pageInfo: PageInfo! +} + +""" +Content for different types of agent activities. +""" +union AgentActivityContent = + | AgentActivityActionContent + | AgentActivityElicitationContent + | AgentActivityErrorContent + | AgentActivityPromptContent + | AgentActivityResponseContent + | AgentActivityThoughtContent + +""" +Input for creating an agent activity. +""" +input AgentActivityCreateInput { + """ + The agent session this activity belongs to. + """ + agentSessionId: String! + """ + The content payload of the agent activity. This object is not strictly typed. + See https://linear.app/developers/agent-interaction#activity-content-payload for typing details. + """ + content: JSONObject! + """ + [Internal] Metadata about user-provided contextual information for this agent activity. + """ + contextualMetadata: JSONObject + """ + Whether the activity is ephemeral, and should disappear after the next activity. Defaults to false. + """ + ephemeral: Boolean + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + An optional modifier that provides additional instructions on how the activity should be interpreted. + """ + signal: AgentActivitySignal + """ + Metadata about this agent activity's signal. + """ + signalMetadata: JSONObject +} + +""" +[Internal] Input for creating prompt-type agent activities (created by users). +""" +input AgentActivityCreatePromptInput { + """ + The agent session this activity belongs to. + """ + agentSessionId: String! + """ + The content payload of the prompt agent activity. + """ + content: AgentActivityPromptCreateInputContent! + """ + [Internal] Metadata about user-provided contextual information for this agent activity. + """ + contextualMetadata: JSONObject + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + [Internal] If true, the activity is queued and will be sent to the agent when it finishes its current task. + """ + queued: Boolean + """ + An optional modifier that provides additional instructions on how the activity should be interpreted. + """ + signal: AgentActivitySignal + """ + Metadata about this agent activity's signal. + """ + signalMetadata: JSONObject + """ + The comment that contains the content of this activity. + """ + sourceCommentId: String +} + +type AgentActivityEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: AgentActivity! +} + +""" +Content for an elicitation activity. +""" +type AgentActivityElicitationContent { + """ + The elicitation message in Markdown format. + """ + body: String! + """ + [Internal] The elicitation content as ProseMirror document. + """ + bodyData: JSONObject! + """ + The type of activity. + """ + type: AgentActivityType! +} + +""" +Content for an error activity. +""" +type AgentActivityErrorContent { + """ + The error message in Markdown format. + """ + body: String! + """ + [Internal] The error content as ProseMirror document. + """ + bodyData: JSONObject! + """ + A stable reason code for specialized error handling. + """ + reasonCode: String + """ + The type of activity. + """ + type: AgentActivityType! +} + +""" +The reason an agent activity was persisted without being sent to the agent runtime. +""" +enum AgentActivityExecutionSkippedReason { + permissionDenied + quotaExceeded +} + +""" +Agent activity filtering options. +""" +input AgentActivityFilter { + """ + Comparator for the agent session ID. + """ + agentSessionId: StringComparator + """ + Compound filters, all of which need to be matched by the agent activity. + """ + and: [AgentActivityFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Compound filters, one of which need to be matched by the agent activity. + """ + or: [AgentActivityFilter!] + """ + Filters that the source comment must satisfy. + """ + sourceComment: NullableCommentFilter + """ + Comparator for the agent activity's content type. + """ + type: StringComparator + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +The result of an agent activity mutation. +""" +type AgentActivityPayload { + """ + The agent activity that was created or updated. + """ + agentActivity: AgentActivity! + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Content for a prompt activity. +""" +type AgentActivityPromptContent { + """ + A message requesting additional information or action from user. + """ + body: String! + """ + [Internal] The prompt content as ProseMirror document. + """ + bodyData: JSONObject! + """ + A short title capturing the intent of the prompt. + """ + title: String + """ + The type of activity. + """ + type: AgentActivityType! +} + +""" +[Internal] Input for creating prompt-type agent activities (created by users). +""" +input AgentActivityPromptCreateInputContent { + """ + A message requesting additional information or action from user in markdown format. + """ + body: String + """ + [Internal] The prompt content as a ProseMirror document. + """ + bodyData: JSON + """ + The type of activity. + """ + type: AgentActivityType! = prompt +} + +""" +[Internal] Diff stats for a single commit a coding agent turn pushed, measured in the sandbox at push time. +""" +type AgentActivityPushCommit { + """ + The number of lines the commit added across the files it touched. + """ + additions: Int! + """ + The number of files the commit changed. + """ + changedFiles: Int! + """ + The number of lines the commit removed across the files it touched. + """ + deletions: Int! + """ + The commit sha. + """ + sha: String! +} + +""" +[Internal] What a coding agent turn pushed to its branch, measured in the sandbox at push time. The range is cumulative within a turn, so a turn that pushes several times reports every commit each time โ€” consumers use the last summary in a turn rather than combining across pushes. +""" +type AgentActivityPushSummary { + """ + Shas of the turn's commits beyond the detailed cap, newest first. Stats aren't captured for these. + """ + additionalCommitShas: [String!]! + """ + The commit the turn started from โ€” the sandbox HEAD when the prompt began. + """ + baseSha: String! + """ + The number of non-merge commits the turn added. Equals the length of commits plus additionalCommitShas. + """ + commitCount: Int! + """ + The turn's non-merge commits with stats, newest first. Capped, so it may hold fewer commits than commitCount reports. + """ + commits: [AgentActivityPushCommit!]! + """ + The commit that was pushed. + """ + headSha: String! +} + +""" +Content for a response activity. +""" +type AgentActivityResponseContent { + """ + The response content in Markdown format. + """ + body: String! + """ + [Internal] The response content as ProseMirror document. + """ + bodyData: JSONObject! + """ + The type of activity. + """ + type: AgentActivityType! +} + +""" +A modifier that provides additional instructions on how the activity should be interpreted. +""" +enum AgentActivitySignal { + auth + continue + select + stop +} + +""" +Content for a thought activity. +""" +type AgentActivityThoughtContent { + """ + The thought content in Markdown format. + """ + body: String! + """ + [Internal] The thought content as ProseMirror document. + """ + bodyData: JSONObject! + """ + The type of activity. + """ + type: AgentActivityType! +} + +""" +The type of an agent activity. +""" +enum AgentActivityType { + action + elicitation + error + prompt + response + thought +} + +""" +Payload for an agent activity webhook. +""" +type AgentActivityWebhookPayload { + """ + The ID of the agent session that this activity belongs to. + """ + agentSessionId: String! + """ + The time at which the entity was archived. + """ + archivedAt: String + """ + The content of the agent activity. + """ + content: JSONObject! + """ + The time at which the entity was created. + """ + createdAt: String! + """ + The ID of the entity. + """ + id: String! + """ + An optional modifier that provides additional instructions on how the activity should be interpreted. + """ + signal: String + """ + Metadata about this agent activity's signal. + """ + signalMetadata: JSONObject + """ + The ID of the comment this activity is linked to. + """ + sourceCommentId: String + """ + The time at which the entity was updated. + """ + updatedAt: String! + """ + The user who created this agent activity. + """ + user: UserChildWebhookPayload! + """ + The ID of the user who created this agent activity. + """ + userId: String! +} + +""" +The outcome of retrying a loop run blocked by its trusted-source policy. +""" +type AgentAutomationRetryResolution { + """ + Identifier of the replacement AI conversation. Null when no replacement run was scheduled. + """ + aiConversationId: String + """ + Whether a replacement run was scheduled or the loop could no longer be retried. + """ + status: AgentAutomationRetryResolutionStatus! +} + +""" +The outcome of reconsidering a loop run blocked by its trusted-source policy. +""" +enum AgentAutomationRetryResolutionStatus { + notScheduled + scheduled +} + +""" +The scope of the usage limit that blocked a loop run: the loop's own limit or the workspace-wide limit. +""" +enum AgentAutomationUsageLimitScope { + loop + workspace +} + +""" +A session representing an AI coding agent's work on an issue or conversation. Agent sessions track the lifecycle of an agent's engagement, from creation through active work to completion or dismissal. Each session is associated with an agent user (the bot), optionally a human creator, an issue, and a comment thread where the agent posts updates. Sessions contain activities that record the agent's observable steps and can be linked to pull requests created during the work. +""" +type AgentSession implements Node { + """ + Activities associated with this agent session. + """ + activities( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned agent activities. + """ + filter: AgentActivityFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): AgentActivityConnection! + """ + The agent user that is associated with this agent session. + """ + appUser: User! + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + [Internal] Coding harness metadata for this cloud or local session. + """ + codingHarness: AgentSessionCodingHarness + """ + [Internal] Compact display label for the coding harness model used by this cloud or local session. + """ + codingHarnessModelLabel: String + """ + The comment this agent session is associated with. + """ + comment: Comment + """ + The entity contexts this session is related to, such as issues or projects referenced in direct chat sessions. Used to provide contextual awareness to the agent. + """ + context: JSON! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The human user responsible for the agent session. Null if the session was initiated via automation or by an agent user, with no responsible human user. + """ + creator: User + """ + The time a user dismissed this agent session. When dismissed, the agent is removed as delegate from the associated issue. Null if the session has not been dismissed. + """ + dismissedAt: DateTime + """ + The user who dismissed the agent session. Automatically set when dismissedAt is updated. Null if the session has not been dismissed. + """ + dismissedBy: User + """ + The time the agent session completed. Null if the session is still in progress or was dismissed before completion. + """ + endedAt: DateTime + """ + The URL of an external agent-hosted page associated with this session. + """ + externalLink: String @deprecated(reason: "Use externalUrls instead.") + """ + External links associated with this session. + """ + externalLinks: [AgentSessionExternalLink!]! + """ + URLs of external resources associated with this session. + """ + externalUrls: JSON! @deprecated(reason: "Use externalLinks instead.") + """ + The unique identifier of the entity. + """ + id: ID! + """ + The issue this agent session is associated with. + """ + issue: Issue + """ + [Internal] How Adaptive selected the model route used by this coding session. + """ + modelSelection: JSON + """ + A dynamically updated plan describing the agent's execution strategy, including steps to be taken and their current status. Updated as the agent progresses through its work. Null if no plan has been set. + """ + plan: JSON + """ + The pull request this agent session is anchored to, when started from a pull request. + """ + pullRequest: PullRequest + """ + [Internal] Pull requests associated with this agent session. + """ + pullRequests( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): AgentSessionToPullRequestConnection! + """ + The agent session's unique URL slug. + """ + slugId: String! + """ + The comment that this agent session was spawned from, if from a different thread. + """ + sourceComment: Comment + """ + Metadata about the external source that created this agent session. + """ + sourceMetadata: JSON + """ + The time the agent session transitioned to active status and began work. Null if the session has not yet started. + """ + startedAt: DateTime + """ + The current status of the agent session, such as pending, active, stopping, awaiting input, complete, error, or stale. + """ + status: AgentSessionStatus! + """ + The session title, generated automatically or set by the owning OAuth application. Null if no title is set. + """ + summary: String + """ + [DEPRECATED] The type of the agent session. + """ + type: AgentSessionType @deprecated(reason: "This field is slated for removal.") + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The URL to the agent session page in the Linear app. Null when no issue is associated. + """ + url: String + """ + [Internal] Legacy live working-tree diff metadata. Null when the sandbox is in sync. + """ + workspaceDiff: JSON @deprecated(reason: "Use the session's Diff model instead.") + """ + [Internal] Legacy per-file metadata for the agent session's live working-tree diff. + """ + workspaceDiffFiles( + """ + The diff content hash from workspaceDiff. + """ + contentHash: String! + ): [AgentSessionWorkspaceDiffFile!] @deprecated(reason: "Use Diff.files instead.") +} + +""" +[Internal] Coding harness metadata for a cloud or local coding session. +""" +type AgentSessionCodingHarness { + """ + The coding harness or local target used by the session. + """ + harness: String! + """ + Compact display label for the model used by the session. + """ + modelLabel: String! +} + +type AgentSessionConnection { + edges: [AgentSessionEdge!]! + nodes: [AgentSession!]! + pageInfo: PageInfo! +} + +""" +[Internal] Input for creating an agent session on behalf of the current user. +""" +input AgentSessionCreateInput { + """ + The app user (agent) to create a session for. + """ + appUserId: String! + """ + [Internal] No longer supported. + """ + context: JSONObject + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + The issue that this session will be associated with. Can be a UUID or issue identifier (e.g., 'LIN-123'). + """ + issueId: String +} + +""" +Input for creating an agent session on a root comment. +""" +input AgentSessionCreateOnComment { + """ + The root comment that this session will be associated with. + """ + commentId: String! + """ + The URL of an external agent-hosted page associated with this session. + """ + externalLink: String + """ + URLs of external resources associated with this session. + """ + externalUrls: [AgentSessionExternalUrlInput!] +} + +""" +Input for creating an agent session on an issue. +""" +input AgentSessionCreateOnIssue { + """ + The URL of an external agent-hosted page associated with this session. + """ + externalLink: String + """ + URLs of external resources associated with this session. + """ + externalUrls: [AgentSessionExternalUrlInput!] + """ + The issue that this session will be associated with. Can be a UUID or issue identifier (e.g., 'LIN-123'). + """ + issueId: String! +} + +type AgentSessionEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: AgentSession! +} + +""" +Payload for agent session webhook events. +""" +type AgentSessionEventWebhookPayload { + """ + The type of action that triggered the webhook. + """ + action: String! + """ + The agent activity that was created. + """ + agentActivity: AgentActivityWebhookPayload + """ + The agent session that the event belongs to. + """ + agentSession: AgentSessionWebhookPayload! + """ + ID of the app user the agent session belongs to. + """ + appUserId: String! + """ + The time the payload was created. + """ + createdAt: DateTime! + """ + Guidance to inform the agent's behavior, which comes from configuration at the level of the workspace, parent teams, and/or current team for this session. The nearest team-specific guidance should take highest precendence. + """ + guidance: [GuidanceRuleWebhookPayload!] + """ + ID of the OAuth client the app user is tied to. + """ + oauthClientId: String! + """ + ID of the organization for which the webhook belongs to. + """ + organizationId: String! + """ + The previous comments in the thread before this agent was mentioned and the session was initiated, if any. Present only for `created` events where the session was initiated by mentioning the agent in a child comment of a thread. + """ + previousComments: [CommentChildWebhookPayload!] + """ + A formatted prompt string containing the relevant context for the agent session, including issue details, comments, and guidance. Present only for `created` events. + """ + promptContext: String + """ + The type of resource. + """ + type: String! + """ + The ID of the webhook that sent this event. + """ + webhookId: String! + """ + Unix timestamp in milliseconds when the webhook was sent. + """ + webhookTimestamp: Float! +} + +""" +An external link associated with an agent session. +""" +type AgentSessionExternalLink { + """ + Label for the link. + """ + label: String! + """ + The URL of the external resource. + """ + url: String! +} + +""" +Input for an external URL associated with an agent session. +""" +input AgentSessionExternalUrlInput { + """ + Label for the URL. + """ + label: String! + """ + The URL of the external resource. + """ + url: String! +} + +type AgentSessionPayload { + """ + The agent session that was created or updated. + """ + agentSession: AgentSession! + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +The status of an agent session. +""" +enum AgentSessionStatus { + active + awaitingInput + complete + error + pending + stale + stopping +} + +""" +A link between an agent session and a pull request created or associated during that session. This join entity tracks which pull requests were produced by or connected to a coding agent's work session, and handles backfilling links when pull requests are synced after the agent has already recorded the URL. +""" +type AgentSessionToPullRequest implements Node { + """ + The agent session that the pull request is associated with. + """ + agentSession: AgentSession! + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The unique identifier of the entity. + """ + id: ID! + """ + The pull request that the agent session is associated with. + """ + pullRequest: PullRequest! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +type AgentSessionToPullRequestConnection { + edges: [AgentSessionToPullRequestEdge!]! + nodes: [AgentSessionToPullRequest!]! + pageInfo: PageInfo! +} + +type AgentSessionToPullRequestEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: AgentSessionToPullRequest! +} + +""" +[DEPRECATED] The type of an agent session. +""" +enum AgentSessionType { + commentThread +} + +""" +Input for updating the external URLs of an agent session. +""" +input AgentSessionUpdateExternalUrlInput { + """ + URLs of external resources to be added to this session. + """ + addedExternalUrls: [AgentSessionExternalUrlInput!] + """ + The URL of an external agent-hosted page associated with this session. + """ + externalLink: String + """ + URLs of external resources associated with this session. Replaces existing URLs. + """ + externalUrls: [AgentSessionExternalUrlInput!] + """ + URLs to be removed from this session. + """ + removedExternalUrls: [String!] +} + +""" +Input for updating an agent session. +""" +input AgentSessionUpdateInput { + """ + URLs of external resources to be added to this session. Only updatable by the OAuth application that owns the session. + """ + addedExternalUrls: [AgentSessionExternalUrlInput!] + """ + [Internal] The time at which the agent session was dismissed. Set to null to un-dismiss. Only updatable by internal clients. + """ + dismissedAt: DateTime + """ + The URL of an external agent-hosted page associated with this session. Only updatable by the OAuth application that owns the session. + """ + externalLink: String + """ + URLs of external resources associated with this session. Replaces existing URLs. Only updatable by the OAuth application that owns the session. If supplied, addedExternalUrls and removedExternalUrls are ignored. + """ + externalUrls: [AgentSessionExternalUrlInput!] + """ + A dynamically updated list of the agent's execution strategy. Only updatable by the OAuth application that owns the session. + """ + plan: JSONObject + """ + URLs to be removed from this session. Only updatable by the OAuth application that owns the session. + """ + removedExternalUrls: [String!] + """ + The session title, displayed as its summary. Must contain 1 to 255 characters, including a non-whitespace character, with no line breaks or NUL bytes. Set to null to clear it and allow automatic title generation. Updating only this field does not acknowledge the session. Only updatable by the OAuth application that owns the session. + """ + summary: String + """ + [Internal] User-specific state for the agent session. Only updatable by internal clients. + """ + userState: [AgentSessionUserStateInput!] +} + +input AgentSessionUserStateInput { + """ + The time at which the user most recently viewed the session. + """ + lastReadAt: DateTime + """ + The ID of the user this state belongs to. + """ + userId: String! +} + +""" +Payload for an agent session webhook. +""" +type AgentSessionWebhookPayload { + """ + The ID of the agent that the agent session belongs to. + """ + appUserId: String! + """ + The time at which the entity was archived. + """ + archivedAt: String + """ + The root comment of the thread this agent session is attached to. + """ + comment: CommentChildWebhookPayload + """ + The ID of the root comment of the thread this agent session is attached to. + """ + commentId: String + """ + The time at which the entity was created. + """ + createdAt: String! + """ + The human user responsible for the agent session. Unset if the session was initiated via automation or by an agent user, with no responsible human user. + """ + creator: UserChildWebhookPayload + """ + The ID of the human user responsible for the agent session. Unset if the session was initiated via automation or by an agent user, with no responsible human user. + """ + creatorId: String + """ + The time the agent session ended. + """ + endedAt: String + """ + The ID of the entity. + """ + id: String! + """ + The issue this agent session is associated with. + """ + issue: IssueWithDescriptionChildWebhookPayload + """ + The ID of the issue this agent session is associated with. + """ + issueId: String + """ + The ID of the organization that the agent session belongs to. + """ + organizationId: String! + """ + The ID of the comment that this agent session was spawned from, if from a different thread. + """ + sourceCommentId: String + """ + Metadata about the external source that created this agent session. + """ + sourceMetadata: JSONObject + """ + The time the agent session started working. + """ + startedAt: String + """ + The current status of the agent session. + """ + status: String! + """ + A summary of the activities in this session. + """ + summary: String + """ + The type of the agent session. + """ + type: String! + """ + The time at which the entity was updated. + """ + updatedAt: String! + """ + The URL of the agent session. + """ + url: String +} + +""" +[Internal] One changed file in a coding agent's live working-tree diff. +""" +type AgentSessionWorkspaceDiffFile { + """ + Lines added in this file. + """ + additions: Int! + """ + Lines removed in this file. + """ + deletions: Int! + """ + Previous path, when the file was renamed or copied. + """ + oldPath: String + """ + Path of the changed file (the new path, for renames). + """ + path: String! + """ + Kind of change: added, modified, deleted, renamed, copied, type_changed, unmerged, unknown. + """ + state: String! +} + +""" +A user-defined skill that can be saved and reused in conversations with the Linear Agent. Skills can be private to a user or shared with a team. +""" +type AgentSkill implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The skill instructions in markdown format. + """ + body: String! + """ + The skill's color. Null if no color is set. + """ + color: String + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The user who created the skill. + """ + creator: User! + """ + The skill's description. Null if no description has been generated. + """ + description: String + """ + The icon of the skill. Null if no icon is set. + """ + icon: String + """ + The unique identifier of the entity. + """ + id: ID! + """ + The parent-team skill this skill was inherited from. Null if the skill is not inherited. + """ + inheritedFrom: AgentSkill + """ + The user who last updated the skill. Null if unknown. + """ + lastUpdatedBy: User + """ + The time the skill was last used by anyone in the workspace. Null if it has never been used. + """ + lastUsedAt: DateTime + """ + The user who owns the skill. + """ + owner: User! + """ + The number of times the skill was used by anyone in the workspace in the last 30 days. + """ + recentUsageCount: Float! + """ + Whether the skill is shared with everyone in the workspace. When false, only the owner can use the skill. + """ + shared: Boolean! + """ + The skill's unique URL slug. + """ + slugId: String! + """ + The identifier of the team this skill is shared with. + """ + teamId: String + """ + The skill's title. + """ + title: String! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +type AgentSkillConnection { + edges: [AgentSkillEdge!]! + nodes: [AgentSkill!]! + pageInfo: PageInfo! +} + +""" +Input for creating an agent skill. +""" +input AgentSkillCreateInput { + """ + The skill instructions in markdown format. + """ + body: String! + """ + The color of the skill icon. + """ + color: String + """ + The icon of the skill. + """ + icon: String + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + The team to associate the skill with. + """ + teamId: String + """ + The title of the skill. + """ + title: String +} + +type AgentSkillEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: AgentSkill! +} + +""" +Agent skill filtering options. +""" +input AgentSkillFilter { + """ + Compound filters, all of which need to be matched by the agent skill. + """ + and: [AgentSkillFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Compound filters, one of which need to be matched by the agent skill. + """ + or: [AgentSkillFilter!] + """ + Comparator for the skill owner's user ID. + """ + ownerId: IDComparator + """ + Comparator for whether the skill is shared with the workspace. + """ + shared: BooleanComparator + """ + Filters that the skill's team must satisfy. + """ + team: NullableTeamFilter + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +The result of an agent skill mutation. +""" +type AgentSkillPayload { + """ + The agent skill that was created or updated. + """ + agentSkill: AgentSkill! + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Input for updating an agent skill. +""" +input AgentSkillUpdateInput { + """ + The skill instructions in markdown format. + """ + body: String + """ + The color of the skill icon. + """ + color: String + """ + The icon of the skill. + """ + icon: String + """ + The team to associate the skill with. + """ + teamId: String + """ + The title of the skill. + """ + title: String +} + +""" +[Internal] A conversation between a user and the Linear AI assistant. Each conversation tracks the full thread state, context references (issues, projects, documents, etc.), and conversation parts (prompts, text responses, tool calls, widgets). Conversations can originate from direct chat, issue comments, Slack threads, Microsoft Teams, or automated workflows. +""" +type AiConversation implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The client platform from which this conversation was initiated, such as web, desktop, or mobile. + """ + clientPlatform: AiConversationClientPlatform + """ + The entity contexts this conversation is related to, such as issues, projects, or documents that provide context for the AI assistant. + """ + context: JSONObject! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + [Internal] The live diff that owns this conversation. Ownership moves to the review on promotion. + """ + diff: Diff + """ + [Internal] The document this shared conversation is attached to. Null if the conversation is private. + """ + document: Document + """ + [Internal] The log ID of the AI response. + """ + evalLogId: String + """ + The unique identifier of the entity. + """ + id: ID! + """ + The source from which this conversation was initiated, such as direct chat, an issue comment, a Slack thread, Microsoft Teams, or a workflow automation. + """ + initialSource: AiConversationInitialSource! + """ + [Internal] The initiative this shared conversation is attached to. Null if the conversation is private. + """ + initiative: Initiative + """ + [Internal] The issue this shared conversation is attached to. Null if the conversation is private. + """ + issue: Issue + """ + The iteration ID when this conversation is part of an agentic workflow. Used to track multi-step workflow executions. Null for non-workflow conversations. + """ + iterationId: String + """ + [Internal] The Loop execution that created this conversation. + """ + loopExecution: LoopExecution + """ + The ordered sequence of conversation parts (prompts, text responses, reasoning steps, tool calls, errors, and widgets) that make up this conversation's visible history. + """ + parts: [AiConversationPart!] + """ + [Internal] The project this shared conversation is attached to. Null if the conversation is private. + """ + project: Project + """ + [Internal] The pull request this shared conversation is attached to. Null if the conversation is private. + """ + pullRequest: PullRequest + """ + The time when the current user marked the conversation as read. Null if the user hasn't read the conversation. + """ + readAt: DateTime + """ + [Internal] The published loop edited by this private setup conversation. + """ + setupWorkflowDefinition: WorkflowDefinition + """ + The conversation's unique URL slug. + """ + slugId: String! + """ + The materialized conversation-level processing summary used by list and gating surfaces. Assistant response lifecycle is recorded on its turn. + """ + status: AiConversationStatus! + """ + [Internal] Users subscribed to this run. + """ + subscriberIds: [String!] + """ + A summary of the conversation. + """ + summary: String + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The user who the conversation belongs to. + """ + user: User + """ + [Internal] User-specific state for the AI conversation, including per-user read state. + """ + userState: [AiConversationUserState!]! + """ + [Internal] The cron workflow definition that created this conversation. + """ + workflowCronJobDefinition: WorkflowCronJobDefinition + """ + [Internal] The workflow definition that created this conversation. + """ + workflowDefinition: WorkflowDefinition +} + +""" +The kind of acknowledgement the agent expresses when it has nothing meaningful to reply. +""" +enum AiConversationAckKind { + done + ignored + skipped + waiting +} + +""" +A silent acknowledgement emitted by the agent in place of a generated reply. +""" +type AiConversationAckPart implements AiConversationBasePart { + """ + The ID of the part. + """ + id: String! + """ + The kind of acknowledgement the agent expressed. + """ + kind: AiConversationAckKind! + """ + The metadata of the part. + """ + metadata: AiConversationPartMetadata! + """ + [Internal] A one-line, third-person summary of the action the agent completed. Null when the agent acknowledged without describing an action. + """ + summary: String + """ + The type of the part. + """ + type: AiConversationPartType! +} + +""" +A base part in an AI conversation. +""" +interface AiConversationBasePart { + """ + The ID of the part. + """ + id: String! + """ + The metadata of the part. + """ + metadata: AiConversationPartMetadata! + """ + The type of the part. + """ + type: AiConversationPartType! +} + +interface AiConversationBaseToolCall { + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON +} + +interface AiConversationBaseWidget { + """ + Display information for the widget, including ProseMirror and Markdown representations. + """ + displayInfo: AiConversationWidgetDisplayInfo + """ + The name of the widget. + """ + name: AiConversationWidgetName! + """ + The arguments of the widget. + """ + rawArgs: JSON +} + +type AiConversationBashToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationBashToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON +} + +type AiConversationBashToolCallArgs { + command: String! +} + +""" +The client platform from which an AI conversation was initiated. +""" +enum AiConversationClientPlatform { + desktop + mobile + web +} + +type AiConversationCodeIntelligenceToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationCodeIntelligenceToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON +} + +type AiConversationCodeIntelligenceToolCallArgs { + question: String! +} + +type AiConversationCodeModeToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationCodeModeToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON +} + +type AiConversationCodeModeToolCallArgs { + description: String! +} + +""" +The response recorded for a confirmation elicitation. +""" +type AiConversationConfirmationElicitationResponseData { + """ + True when the user confirmed the action. + """ + confirmed: Boolean! + """ + The kind of elicitation that was answered. + """ + kind: AiConversationElicitationKind! +} + +type AiConversationContactSupportToolCall implements AiConversationBaseToolCall { + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON +} + +type AiConversationCreateAgentChatToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: JSONObject + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON + """ + The result of the tool call. + """ + result: AiConversationCreateAgentChatToolCallResult +} + +type AiConversationCreateAgentChatToolCallResult { + conversationId: String! +} + +type AiConversationCreateEntityToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationCreateEntityToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON + """ + The result of the tool call. + """ + result: AiConversationCreateEntityToolCallResult +} + +type AiConversationCreateEntityToolCallArgs { + count: Float + type: String! +} + +type AiConversationCreateEntityToolCallResult { + createdEntities: [AiConversationCreateEntityToolCallResultCreatedEntities!] + startedAgentSessions: [AiConversationSearchEntitiesToolCallResultEntities!] +} + +type AiConversationCreateEntityToolCallResultCreatedEntities { + id: String! + label: String + parent: AiConversationSearchEntitiesToolCallResultEntities + type: String! +} + +type AiConversationCreateSandboxToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationCreateSandboxToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON +} + +type AiConversationCreateSandboxToolCallArgs { + repository: String +} + +type AiConversationDeleteEntityToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationDeleteEntityToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON + """ + The result of the tool call. + """ + result: AiConversationDeleteEntityToolCallResult +} + +type AiConversationDeleteEntityToolCallArgs { + entity: AiConversationSearchEntitiesToolCallResultEntities! +} + +type AiConversationDeleteEntityToolCallResult { + deletedEntities: [AiConversationCreateEntityToolCallResultCreatedEntities!] +} + +""" +The kind of input an AI conversation elicitation asks for. +""" +enum AiConversationElicitationKind { + confirmation + entitySelection + integrationConnection + mcpServerConnection + multipleChoice +} + +""" +A selectable option shown in an AI conversation elicitation. +""" +type AiConversationElicitationOption { + """ + The short label shown for the option. + """ + label: String! + """ + The user prompt rendered to the agent when this option is selected. Null when selecting the option only dismisses the elicitation without replying. + """ + prompt: String +} + +""" +A structured request for user input shown with an AI conversation. +""" +type AiConversationElicitationPart implements AiConversationBasePart { + """ + Entity type for entity selection. + """ + entityType: String + """ + The ID of the part. + """ + id: String! + """ + The existing MCP integration to reconnect. Null when creating a new connection. + """ + integrationId: String + """ + The service of the integration to connect. Null for other elicitation kinds. + """ + integrationService: IntegrationService + """ + The kind of input this elicitation asks for. + """ + kind: AiConversationElicitationKind! + """ + The metadata of the part. + """ + metadata: AiConversationPartMetadata! + """ + The selectable actions for multiple-choice and confirmation elicitations. + """ + options: [AiConversationElicitationOption!]! + """ + The requested owner of the MCP server connection. Null for other elicitation kinds. + """ + scope: AiConversationMcpServerConnectionScope + """ + Whether to select one or multiple entities. + """ + selection: String + """ + The MCP server URL for a new connection. Null for reconnects and other elicitation kinds. + """ + serverUrl: String + """ + Suggested entity identifiers. + """ + suggestedEntityIds: [String!] + """ + The optional title shown above the elicitation choices. + """ + title: String + """ + The type of the part. + """ + type: AiConversationPartType! +} + +""" +The kind-specific data recorded when a user answers an AI conversation elicitation. +""" +union AiConversationElicitationResponseData = + | AiConversationConfirmationElicitationResponseData + | AiConversationEntitySelectionElicitationResponseData + | AiConversationIntegrationConnectionElicitationResponseData + | AiConversationMcpServerConnectionElicitationResponseData + | AiConversationMultipleChoiceElicitationResponseData + +""" +A structured user response to an elicitation in an AI conversation. +""" +type AiConversationElicitationResponsePart implements AiConversationBasePart { + """ + Additional user-authored commentary submitted with the response. For a response batch, only the first response contains it. Null when none was provided. + """ + bodyData: JSONObject + """ + The kind-specific response data. + """ + data: AiConversationElicitationResponseData! + """ + The identifier of the elicitation that was answered. + """ + elicitationId: String! + """ + The ID of the part. + """ + id: String! + """ + The metadata of the part. + """ + metadata: AiConversationPartMetadata! + """ + The type of the part. + """ + type: AiConversationPartType! + """ + The user who answered the elicitation. + """ + user: User +} + +type AiConversationEntityCardWidget implements AiConversationBaseWidget { + """ + The arguments to the widget. + """ + args: AiConversationEntityCardWidgetArgs + """ + Display information for the widget, including ProseMirror and Markdown representations. + """ + displayInfo: AiConversationWidgetDisplayInfo + """ + The name of the widget. + """ + name: AiConversationWidgetName! + """ + The arguments of the widget. + """ + rawArgs: JSON +} + +type AiConversationEntityCardWidgetArgs { + """ + The action performed on the entity (leave empty if just found) + """ + action: AiConversationEntityCardWidgetArgsAction + """ + A concise summary shown on specialized entity cards. Leave empty unless specifically instructed. + """ + actionSummary: String + """ + The UUID of the entity to display + """ + id: String! + """ + @deprecated Optional note to display about the entity + """ + note: String @deprecated(reason: "Optional note to display about the entity") + """ + [Internal] Snapshot data for the widget. + """ + snapshot: JSONObject + """ + [Internal] The entity type + """ + type: AiConversationEntityCardWidgetArgsType! +} + +""" +The action performed on the entity (leave empty if just found) +""" +enum AiConversationEntityCardWidgetArgsAction { + created + updated +} + +""" +[Internal] The entity type +""" +enum AiConversationEntityCardWidgetArgsType { + AgentSession + AiConversation + AiPrompt + AiPromptRules + CustomView + Customer + CustomerNeed + Dashboard + Document + Draft + Initiative + InitiativeUpdate + Issue + IssueDraft + Meeting + Project + ProjectDraft + ProjectMilestone + ProjectUpdate + PullRequest + Release + ReleaseNote + ReleasePipeline + Team + Template + WorkflowDefinition +} + +type AiConversationEntityListWidget implements AiConversationBaseWidget { + """ + The arguments to the widget. + """ + args: AiConversationEntityListWidgetArgs + """ + Display information for the widget, including ProseMirror and Markdown representations. + """ + displayInfo: AiConversationWidgetDisplayInfo + """ + The name of the widget. + """ + name: AiConversationWidgetName! + """ + The arguments of the widget. + """ + rawArgs: JSON +} + +type AiConversationEntityListWidgetArgs { + """ + The action performed on the entities (leave empty if just found) + """ + action: AiConversationEntityListWidgetArgsAction + """ + Total number of entities in the list + """ + count: Float + entities: [AiConversationEntityListWidgetArgsEntities!]! +} + +""" +The action performed on the entities (leave empty if just found) +""" +enum AiConversationEntityListWidgetArgsAction { + created + updated +} + +type AiConversationEntityListWidgetArgsEntities { + """ + Entity UUID + """ + id: String! + """ + @deprecated Optional note to display about the entity + """ + note: String @deprecated(reason: "Optional note to display about the entity") + """ + [Internal] Snapshot data for the widget. + """ + snapshot: JSONObject + """ + [Internal] The entity type + """ + type: AiConversationEntityListWidgetArgsEntitiesType! +} + +""" +[Internal] The entity type +""" +enum AiConversationEntityListWidgetArgsEntitiesType { + AgentSession + AiPrompt + AiPromptRules + CustomView + Customer + CustomerNeed + Dashboard + Document + Initiative + InitiativeUpdate + Issue + IssueDraft + Project + ProjectDraft + ProjectMilestone + ProjectUpdate + PullRequest + Release + ReleaseNote + ReleasePipeline + Team + Template + WorkflowDefinition +} + +""" +Selected entities in an entity selection elicitation. +""" +type AiConversationEntitySelectionElicitationResponseData { + kind: AiConversationElicitationKind! + selectedEntityIds: [String!]! +} + +""" +An error part in an AI conversation. +""" +type AiConversationErrorPart implements AiConversationBasePart { + """ + The category of the error. Absent for errors without a specific category, which default to unknown. + """ + errorType: AiConversationErrorType + """ + The ID of the part. + """ + id: String! + """ + The user-facing error message for the failed AI response. + """ + message: String! + """ + The metadata of the part. + """ + metadata: AiConversationPartMetadata! + """ + The outcome of retrying this error's loop run. Null when the run has not been reconsidered. + """ + retryResolution: AgentAutomationRetryResolution + """ + The type of the part. + """ + type: AiConversationPartType! + """ + The time when the breached usage limit resets, as an ISO 8601 string. Null when unknown or for other error categories. + """ + usageLimitResetsAt: String + """ + The scope of the breached limit for usage-limit errors. Null for other error categories. + """ + usageLimitScope: AgentAutomationUsageLimitScope +} + +""" +The category of an error part in an AI conversation. +""" +enum AiConversationErrorType { + billing + unknown + untrustedSources + usageLimit +} + +""" +An event part in an AI conversation. +""" +type AiConversationEventPart implements AiConversationBasePart { + """ + The Markdown body of the event part. + """ + body: String! + """ + The data of the event part. + """ + bodyData: JSONObject! + """ + The ID of the part. + """ + id: String! + """ + The metadata of the part. + """ + metadata: AiConversationPartMetadata! + """ + The ID of the subscription to resolve when this event is delivered. + """ + subscriptionId: String + """ + The type of the part. + """ + type: AiConversationPartType! +} + +type AiConversationGetMicrosoftTeamsConversationHistoryToolCall implements AiConversationBaseToolCall { + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON +} + +type AiConversationGetPullRequestCheckLogsToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationGetPullRequestCheckLogsToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON +} + +type AiConversationGetPullRequestCheckLogsToolCallArgs { + checkName: String! + entity: AiConversationSearchEntitiesToolCallResultEntities! + workflowName: String +} + +type AiConversationGetPullRequestDiffToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationGetPullRequestDiffToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON +} + +type AiConversationGetPullRequestDiffToolCallArgs { + entity: AiConversationSearchEntitiesToolCallResultEntities! +} + +type AiConversationGetPullRequestFileToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationGetPullRequestFileToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON +} + +type AiConversationGetPullRequestFileToolCallArgs { + entity: AiConversationSearchEntitiesToolCallResultEntities! + path: String! +} + +type AiConversationGetSlackConversationHistoryToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationGetSlackConversationHistoryToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON + """ + The result of the tool call. + """ + result: AiConversationGetSlackConversationHistoryToolCallResult +} + +type AiConversationGetSlackConversationHistoryToolCallArgs { + channel: String + targetType: AiConversationGetSlackConversationHistoryToolCallArgsTargetType +} + +enum AiConversationGetSlackConversationHistoryToolCallArgsTargetType { + channel + thread +} + +type AiConversationGetSlackConversationHistoryToolCallResult { + conversationUrl: String + error: String + hasMore: Boolean + messageCount: Float +} + +type AiConversationHandoffToCodingSessionToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationHandoffToCodingSessionToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON +} + +type AiConversationHandoffToCodingSessionToolCallArgs { + entity: AiConversationSearchEntitiesToolCallResultEntities! + instructions: String +} + +""" +The initial source of an AI conversation. +""" +enum AiConversationInitialSource { + comment + directChat + entityChat + mcp + microsoftTeams + onboarding + pullRequestComment + slack + subAgent + workflow +} + +""" +The integration connected to a Loop and its current run by a conversation. +""" +type AiConversationIntegrationConnectionElicitationResponseData { + """ + The identifier of the integration that was connected. + """ + integrationId: String! + """ + The kind of elicitation that was answered. + """ + kind: AiConversationElicitationKind! +} + +type AiConversationInvokeMcpToolToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationInvokeMcpToolToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON +} + +type AiConversationInvokeMcpToolToolCallArgs { + server: AiConversationInvokeMcpToolToolCallArgsServer! + tool: AiConversationInvokeMcpToolToolCallArgsTool! +} + +type AiConversationInvokeMcpToolToolCallArgsServer { + integrationId: String! + name: String! + title: String +} + +type AiConversationInvokeMcpToolToolCallArgsTool { + name: String! + title: String +} + +type AiConversationListCodingSessionsToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationListCodingSessionsToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON + """ + The result of the tool call. + """ + result: AiConversationListCodingSessionsToolCallResult +} + +type AiConversationListCodingSessionsToolCallArgs { + includeDismissed: Boolean +} + +type AiConversationListCodingSessionsToolCallResult { + agentSessions: [AiConversationListCodingSessionsToolCallResultAgentSessions!]! + entities: [AiConversationSearchEntitiesToolCallResultEntities!] +} + +type AiConversationListCodingSessionsToolCallResultAgentSessions { + id: String! + pullRequests: [AiConversationSearchEntitiesToolCallResultEntities!] + type: String! +} + +""" +The integration connected by an MCP server connection elicitation. +""" +type AiConversationMcpServerConnectionElicitationResponseData { + """ + The identifier of the MCP server integration that was connected. + """ + integrationId: String! + """ + The kind of elicitation that was answered. + """ + kind: AiConversationElicitationKind! +} + +""" +The owner scope for an MCP server connection requested in an AI conversation. +""" +type AiConversationMcpServerConnectionScope { + """ + The identifier of the team that will own the connection. Null for other scope types. + """ + teamId: String + """ + The type of owner that will receive the MCP server connection. + """ + type: AiConversationMcpServerConnectionScopeType! + """ + The identifier of the Loop draft that will own the connection. Null for other scope types. + """ + workflowDefinitionDraftId: String + """ + The identifier of the Loop that will own the connection. Null for other scope types. + """ + workflowDefinitionId: String +} + +""" +The owner scope for an MCP server connection requested in an AI conversation. +""" +enum AiConversationMcpServerConnectionScopeType { + team + user + workflowDefinition + workflowDefinitionDraft +} + +type AiConversationMemoryToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationMemoryToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON +} + +type AiConversationMemoryToolCallArgs { + action: AiConversationMemoryToolCallArgsAction! + name: String +} + +enum AiConversationMemoryToolCallArgsAction { + delete + list + read + save +} + +type AiConversationMessageSubagentToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationMessageSubagentToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON + """ + The result of the tool call. + """ + result: AiConversationMessageSubagentToolCallResult +} + +type AiConversationMessageSubagentToolCallArgs { + conversationId: String! + prompt: String! + wait: Boolean +} + +type AiConversationMessageSubagentToolCallResult { + turnId: String! +} + +""" +The selected option in a multiple-choice AI conversation elicitation. +""" +type AiConversationMultipleChoiceElicitationResponseData { + """ + The kind of elicitation that was answered. + """ + kind: AiConversationElicitationKind! + """ + The zero-based index of the selected option. + """ + selectedOptionIndex: Int! +} + +type AiConversationNavigateToPageToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationNavigateToPageToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON + """ + The result of the tool call. + """ + result: AiConversationNavigateToPageToolCallResult +} + +type AiConversationNavigateToPageToolCallArgs { + entities: [AiConversationNavigateToPageToolCallArgsEntities!]! +} + +type AiConversationNavigateToPageToolCallArgsEntities { + entityType: String! + uuid: String! +} + +type AiConversationNavigateToPageToolCallResult { + urls: [String!]! +} + +type AiConversationNotifyUsersToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationNotifyUsersToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON + """ + The result of the tool call. + """ + result: AiConversationNotifyUsersToolCallResult +} + +type AiConversationNotifyUsersToolCallArgs { + message: String + summary: String + userIds: [String!]! +} + +type AiConversationNotifyUsersToolCallResult { + notifiedUserIds: [String!] + skippedUserIds: [String!] +} + +""" +A part in an AI conversation. +""" +union AiConversationPart = + | AiConversationAckPart + | AiConversationElicitationPart + | AiConversationElicitationResponsePart + | AiConversationErrorPart + | AiConversationEventPart + | AiConversationPromptPart + | AiConversationReasoningPart + | AiConversationTextPart + | AiConversationToolCallPart + | AiConversationWidgetPart + +""" +Metadata about a part in an AI conversation. +""" +type AiConversationPartMetadata { + """ + The time when the part ended, as an ISO 8601 string. + """ + endedAt: String + """ + The eval log ID of the part. + """ + evalLogId: String + """ + AI feedback state for this part. + """ + feedback: JSONObject + """ + The phase during which the part was generated. + """ + phase: AiConversationPartPhase + """ + The time when the part started, as an ISO 8601 string. + """ + startedAt: String + """ + The turn ID of the part. + """ + turnId: String! +} + +""" +The phase during which a conversation part was generated. +""" +enum AiConversationPartPhase { + answer + commentary +} + +""" +The type of a part in an AI conversation. +""" +enum AiConversationPartType { + ack + elicitation + elicitationResponse + error + event + prompt + reasoning + text + toolCall + widget + widgetPlaceholder +} + +type AiConversationPatchSettingsToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationPatchSettingsToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON +} + +type AiConversationPatchSettingsToolCallArgs { + ids: [String!]! +} + +type AiConversationPostChatMessageToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationPostChatMessageToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON + """ + The result of the tool call. + """ + result: AiConversationPostChatMessageToolCallResult +} + +type AiConversationPostChatMessageToolCallArgs { + channel: String + isReply: Boolean + platform: AiConversationPostChatMessageToolCallArgsPlatform! + recipient: String + recipientId: String +} + +enum AiConversationPostChatMessageToolCallArgsPlatform { + microsoftTeams + slack +} + +type AiConversationPostChatMessageToolCallResult { + conversationUrl: String + destination: AiConversationPostChatMessageToolCallResultDestination + error: String + message: String + posted: Boolean! +} + +type AiConversationPostChatMessageToolCallResultDestination { + channelId: String! + integrationId: String! + messageId: String! + threadId: String! +} + +type AiConversationPromptCodingSessionToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationPromptCodingSessionToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON + """ + The result of the tool call. + """ + result: AiConversationPromptCodingSessionToolCallResult +} + +type AiConversationPromptCodingSessionToolCallArgs { + prompt: String! + queued: Boolean +} + +type AiConversationPromptCodingSessionToolCallResult { + agentSession: AiConversationSearchEntitiesToolCallResultEntities! + created: Boolean + entities: [AiConversationSearchEntitiesToolCallResultEntities!] + pullRequests: [AiConversationSearchEntitiesToolCallResultEntities!] + quotaBlocked: Boolean +} + +""" +A prompt part in an AI conversation. +""" +type AiConversationPromptPart implements AiConversationBasePart { + """ + The Markdown body of the prompt part. + """ + body: String! + """ + The data of the prompt part. + """ + bodyData: JSONObject! + """ + The ID of the part. + """ + id: String! + """ + The metadata of the part. + """ + metadata: AiConversationPartMetadata! + """ + The type of the part. + """ + type: AiConversationPartType! + """ + The user who created the prompt part. + """ + user: User +} + +type AiConversationQueryActivityToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationQueryActivityToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON +} + +type AiConversationQueryActivityToolCallArgs { + entities: [AiConversationSearchEntitiesToolCallResultEntities!] +} + +type AiConversationQueryUpdatesToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationQueryUpdatesToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON +} + +type AiConversationQueryUpdatesToolCallArgs { + entity: AiConversationSearchEntitiesToolCallResultEntities + updateType: AiConversationQueryUpdatesToolCallArgsUpdateType! +} + +enum AiConversationQueryUpdatesToolCallArgsUpdateType { + InitiativeUpdate + ProjectUpdate +} + +type AiConversationQueryViewToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationQueryViewToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON +} + +type AiConversationQueryViewToolCallArgs { + filter: String + mode: AiConversationQueryViewToolCallArgsMode! + view: AiConversationQueryViewToolCallArgsView! +} + +enum AiConversationQueryViewToolCallArgsMode { + insight + list +} + +type AiConversationQueryViewToolCallArgsView { + group: AiConversationSearchEntitiesToolCallResultEntities + predefinedView: String + type: String! +} + +type AiConversationReadFileToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationReadFileToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON +} + +type AiConversationReadFileToolCallArgs { + assetUrl: String + mode: AiConversationReadFileToolCallArgsMode + name: String + query: String +} + +enum AiConversationReadFileToolCallArgsMode { + read + search +} + +type AiConversationReadSandboxFileToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationReadSandboxFileToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON +} + +type AiConversationReadSandboxFileToolCallArgs { + path: String! +} + +type AiConversationReadSettingToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationReadSettingToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON +} + +type AiConversationReadSettingToolCallArgs { + id: String! +} + +""" +A reasoning part in an AI conversation. +""" +type AiConversationReasoningPart implements AiConversationBasePart { + """ + The Markdown body of the reasoning part. + """ + body: String! + """ + The data of the reasoning part. + """ + bodyData: JSONObject! + """ + The ID of the part. + """ + id: String! + """ + The metadata of the part. + """ + metadata: AiConversationPartMetadata! + """ + The title of the reasoning part. + """ + title: String + """ + The type of the part. + """ + type: AiConversationPartType! +} + +type AiConversationRemoveSpendLimitToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationRemoveSpendLimitToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON +} + +type AiConversationRemoveSpendLimitToolCallArgs { + summary: String +} + +type AiConversationRenameAgentChatToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationRenameAgentChatToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON +} + +type AiConversationRenameAgentChatToolCallArgs { + name: String! +} + +type AiConversationRerunPullRequestReviewToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationRerunPullRequestReviewToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON +} + +type AiConversationRerunPullRequestReviewToolCallArgs { + entity: AiConversationSearchEntitiesToolCallResultEntities! +} + +type AiConversationResearchToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationResearchToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON + """ + The result of the tool call. + """ + result: AiConversationResearchToolCallResult +} + +type AiConversationResearchToolCallArgs { + context: String! + query: String! + subjects: [AiConversationSearchEntitiesToolCallResultEntities!] +} + +type AiConversationResearchToolCallResult { + progressId: String +} + +type AiConversationRestoreEntityToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationRestoreEntityToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON + """ + The result of the tool call. + """ + result: AiConversationRestoreEntityToolCallResult +} + +type AiConversationRestoreEntityToolCallArgs { + entity: AiConversationSearchEntitiesToolCallResultEntities! +} + +type AiConversationRestoreEntityToolCallResult { + restoredEntities: [AiConversationCreateEntityToolCallResultCreatedEntities!] +} + +type AiConversationRetrieveEntitiesToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationRetrieveEntitiesToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON +} + +type AiConversationRetrieveEntitiesToolCallArgs { + entities: [AiConversationSearchEntitiesToolCallResultEntities!]! +} + +type AiConversationRetryPullRequestCheckToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationRetryPullRequestCheckToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON +} + +type AiConversationRetryPullRequestCheckToolCallArgs { + checkName: String! + entity: AiConversationSearchEntitiesToolCallResultEntities! + workflowName: String +} + +type AiConversationRunLoopToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationRunLoopToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON + """ + The result of the tool call. + """ + result: AiConversationRunLoopToolCallResult +} + +type AiConversationRunLoopToolCallArgs { + workflowDefinitionId: String! +} + +type AiConversationRunLoopToolCallResult { + conversationId: String! + createdEntities: [AiConversationCreateEntityToolCallResultCreatedEntities!] + url: String! +} + +type AiConversationSandboxGitHistoryToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationSandboxGitHistoryToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON +} + +type AiConversationSandboxGitHistoryToolCallArgs { + operation: AiConversationSandboxGitHistoryToolCallArgsOperation! + paths: [String!] +} + +enum AiConversationSandboxGitHistoryToolCallArgsOperation { + blame + log + search + show +} + +type AiConversationSearchChatChannelsToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationSearchChatChannelsToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON + """ + The result of the tool call. + """ + result: AiConversationSearchChatChannelsToolCallResult +} + +type AiConversationSearchChatChannelsToolCallArgs { + filter: String! + platform: AiConversationPostChatMessageToolCallArgsPlatform! +} + +type AiConversationSearchChatChannelsToolCallResult { + totalCount: Float! +} + +type AiConversationSearchDocumentationToolCall implements AiConversationBaseToolCall { + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON +} + +type AiConversationSearchEntitiesToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationSearchEntitiesToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON + """ + The result of the tool call. + """ + result: AiConversationSearchEntitiesToolCallResult +} + +type AiConversationSearchEntitiesToolCallArgs { + queries: [String!]! + type: String +} + +type AiConversationSearchEntitiesToolCallResult { + entities: [AiConversationSearchEntitiesToolCallResultEntities!]! +} + +type AiConversationSearchEntitiesToolCallResultEntities { + id: String! + type: String! +} + +type AiConversationSearchSettingsToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationSearchSettingsToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON +} + +type AiConversationSearchSettingsToolCallArgs { + parentId: String + query: String +} + +type AiConversationSetSpendLimitToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationSetSpendLimitToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON +} + +type AiConversationSetSpendLimitToolCallArgs { + summary: String +} + +type AiConversationSettingWidget implements AiConversationBaseWidget { + """ + The arguments to the widget. + """ + args: AiConversationSettingWidgetArgs + """ + Display information for the widget, including ProseMirror and Markdown representations. + """ + displayInfo: AiConversationWidgetDisplayInfo + """ + The name of the widget. + """ + name: AiConversationWidgetName! + """ + The arguments of the widget. + """ + rawArgs: JSON +} + +type AiConversationSettingWidgetArgs { + """ + The stable semantic setting ID returned by SearchSettings + """ + id: String! + """ + The settings target when the setting scope does not imply it + """ + target: AiConversationSettingWidgetArgsTarget +} + +type AiConversationSettingWidgetArgsTarget { + """ + The settings target UUID, when the scope does not imply it + """ + id: String + """ + The settings target entity type + """ + type: String! +} + +type AiConversationSpawnSubagentToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationSpawnSubagentToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON + """ + The result of the tool call. + """ + result: AiConversationSpawnSubagentToolCallResult +} + +type AiConversationSpawnSubagentToolCallArgs { + description: String! +} + +type AiConversationSpawnSubagentToolCallResult { + conversationId: String! +} + +type AiConversationStartCodingSessionToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationStartCodingSessionToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON + """ + The result of the tool call. + """ + result: AiConversationStartCodingSessionToolCallResult +} + +type AiConversationStartCodingSessionToolCallArgs { + prompt: String! +} + +type AiConversationStartCodingSessionToolCallResult { + agentSession: AiConversationSearchEntitiesToolCallResultEntities! + entities: [AiConversationSearchEntitiesToolCallResultEntities!] + pullRequests: [AiConversationSearchEntitiesToolCallResultEntities!] +} + +""" +The status of an AI conversation. +""" +enum AiConversationStatus { + active + awaitingInput + complete + error + pending + waiting +} + +type AiConversationSubscribeToEventToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationSubscribeToEventToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON +} + +type AiConversationSubscribeToEventToolCallArgs { + endsAt: String + kind: AiConversationSubscribeToEventToolCallArgsKind + message: String + subscriptionId: String + type: AiConversationSubscribeToEventToolCallArgsType! +} + +enum AiConversationSubscribeToEventToolCallArgsKind { + timer + trigger +} + +enum AiConversationSubscribeToEventToolCallArgsType { + once + recurring +} + +type AiConversationSuggestRepositoryToolCall implements AiConversationBaseToolCall { + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON +} + +type AiConversationSuggestValuesToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationSuggestValuesToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON +} + +type AiConversationSuggestValuesToolCallArgs { + field: String! + query: String +} + +""" +A text part in an AI conversation. +""" +type AiConversationTextPart implements AiConversationBasePart { + """ + The Markdown body of the text part. + """ + body: String! + """ + The data of the text part. + """ + bodyData: JSONObject! + """ + The ID of the part. + """ + id: String! + """ + The metadata of the part. + """ + metadata: AiConversationPartMetadata! + """ + The type of the part. + """ + type: AiConversationPartType! +} + +""" +The name of a tool that was called in an AI conversation. +""" +enum AiConversationTool { + Bash + CodeIntelligence + CodeMode + ContactSupport + CreateAgentChat + CreateEntity + CreateSandbox + DeleteEntity + GetMicrosoftTeamsConversationHistory + GetPullRequestCheckLogs + GetPullRequestDiff + GetPullRequestFile + GetSlackConversationHistory + HandoffToCodingSession + InvokeMcpTool + ListCodingSessions + Memory + MessageSubagent + NavigateToPage + NotifyUsers + PatchSettings + PostChatMessage + PromptCodingSession + QueryActivity + QueryUpdates + QueryView + ReadFile + ReadSandboxFile + ReadSetting + RemoveSpendLimit + RenameAgentChat + RerunPullRequestReview + Research + RestoreEntity + RetrieveEntities + RetryPullRequestCheck + RunLoop + SandboxGitHistory + SearchChatChannels + SearchDocumentation + SearchEntities + SearchSettings + SetSpendLimit + SpawnSubagent + StartCodingSession + SubscribeToEvent + SuggestRepository + SuggestValues + TranscribeMedia + TranscribeVideo + UnsubscribeFromEvent + UpdateEntity + UpdatePullRequestReviewFinding + WebSearch +} + +""" +The tool call. +""" +union AiConversationToolCall = + | AiConversationBashToolCall + | AiConversationCodeIntelligenceToolCall + | AiConversationCodeModeToolCall + | AiConversationContactSupportToolCall + | AiConversationCreateAgentChatToolCall + | AiConversationCreateEntityToolCall + | AiConversationCreateSandboxToolCall + | AiConversationDeleteEntityToolCall + | AiConversationGetMicrosoftTeamsConversationHistoryToolCall + | AiConversationGetPullRequestCheckLogsToolCall + | AiConversationGetPullRequestDiffToolCall + | AiConversationGetPullRequestFileToolCall + | AiConversationGetSlackConversationHistoryToolCall + | AiConversationHandoffToCodingSessionToolCall + | AiConversationInvokeMcpToolToolCall + | AiConversationListCodingSessionsToolCall + | AiConversationMemoryToolCall + | AiConversationMessageSubagentToolCall + | AiConversationNavigateToPageToolCall + | AiConversationNotifyUsersToolCall + | AiConversationPatchSettingsToolCall + | AiConversationPostChatMessageToolCall + | AiConversationPromptCodingSessionToolCall + | AiConversationQueryActivityToolCall + | AiConversationQueryUpdatesToolCall + | AiConversationQueryViewToolCall + | AiConversationReadFileToolCall + | AiConversationReadSandboxFileToolCall + | AiConversationReadSettingToolCall + | AiConversationRemoveSpendLimitToolCall + | AiConversationRenameAgentChatToolCall + | AiConversationRerunPullRequestReviewToolCall + | AiConversationResearchToolCall + | AiConversationRestoreEntityToolCall + | AiConversationRetrieveEntitiesToolCall + | AiConversationRetryPullRequestCheckToolCall + | AiConversationRunLoopToolCall + | AiConversationSandboxGitHistoryToolCall + | AiConversationSearchChatChannelsToolCall + | AiConversationSearchDocumentationToolCall + | AiConversationSearchEntitiesToolCall + | AiConversationSearchSettingsToolCall + | AiConversationSetSpendLimitToolCall + | AiConversationSpawnSubagentToolCall + | AiConversationStartCodingSessionToolCall + | AiConversationSubscribeToEventToolCall + | AiConversationSuggestRepositoryToolCall + | AiConversationSuggestValuesToolCall + | AiConversationTranscribeMediaToolCall + | AiConversationTranscribeVideoToolCall + | AiConversationUnsubscribeFromEventToolCall + | AiConversationUpdateEntityToolCall + | AiConversationUpdatePullRequestReviewFindingToolCall + | AiConversationWebSearchToolCall + +""" +A tool call part in an AI conversation. +""" +type AiConversationToolCallPart implements AiConversationBasePart { + """ + The ID of the part. + """ + id: String! + """ + The metadata of the part. + """ + metadata: AiConversationPartMetadata! + """ + The tool call part. + """ + toolCall: AiConversationToolCall! + """ + The type of the part. + """ + type: AiConversationPartType! +} + +type AiConversationToolDisplayInfo { + activeLabel: String! + detail: String + icon: String! + inactiveLabel: String! + result: String +} + +type AiConversationTranscribeMediaToolCall implements AiConversationBaseToolCall { + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON +} + +type AiConversationTranscribeVideoToolCall implements AiConversationBaseToolCall { + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON +} + +type AiConversationUnsubscribeFromEventToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationUnsubscribeFromEventToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON +} + +type AiConversationUnsubscribeFromEventToolCallArgs { + message: String + subscriptionId: String! +} + +type AiConversationUpdateEntityToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationUpdateEntityToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON + """ + The result of the tool call. + """ + result: AiConversationUpdateEntityToolCallResult +} + +type AiConversationUpdateEntityToolCallArgs { + entities: [AiConversationSearchEntitiesToolCallResultEntities!] + entity: AiConversationSearchEntitiesToolCallResultEntities +} + +type AiConversationUpdateEntityToolCallResult { + startedAgentSessions: [AiConversationSearchEntitiesToolCallResultEntities!] + updatedEntities: [AiConversationCreateEntityToolCallResultCreatedEntities!] +} + +type AiConversationUpdatePullRequestReviewFindingToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationUpdatePullRequestReviewFindingToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON +} + +type AiConversationUpdatePullRequestReviewFindingToolCallArgs { + entity: AiConversationSearchEntitiesToolCallResultEntities! + findingId: String! + rejected: Boolean! +} + +""" +[Internal] Per-user state for an AI conversation, tracking read status and other user-specific data. +""" +type AiConversationUserState { + """ + The ID of the elicitation part the user dismissed. + """ + dismissedElicitationId: String + """ + The time at which the user most recently viewed the conversation. + """ + lastReadAt: DateTime + """ + The ID of the user this state belongs to. + """ + userId: String! +} + +type AiConversationWebSearchToolCall implements AiConversationBaseToolCall { + """ + The arguments to the tool call. + """ + args: AiConversationWebSearchToolCallArgs + displayInfo: AiConversationToolDisplayInfo! + """ + The name of the tool that was called. + """ + name: AiConversationTool! + """ + The arguments of the tool call. + """ + rawArgs: JSON + """ + The result of the tool call. + """ + rawResult: JSON +} + +type AiConversationWebSearchToolCallArgs { + query: String + url: String +} + +""" +The widget. +""" +union AiConversationWidget = + | AiConversationEntityCardWidget + | AiConversationEntityListWidget + | AiConversationSettingWidget + +type AiConversationWidgetDisplayInfo { + """ + The Markdown representation of the widget content. + """ + body: String! + """ + The ProseMirror data representation of the widget content. + """ + bodyData: JSONObject! +} + +""" +The name of a widget in an AI conversation. +""" +enum AiConversationWidgetName { + EntityCard + EntityList + Setting +} + +""" +A widget part in an AI conversation. +""" +type AiConversationWidgetPart implements AiConversationBasePart { + """ + The ID of the part. + """ + id: String! + """ + The metadata of the part. + """ + metadata: AiConversationPartMetadata! + """ + The type of the part. + """ + type: AiConversationPartType! + """ + The widget. + """ + widget: AiConversationWidget! +} + +""" +[Internal] Tracks the progress and state of an AI prompt workflow execution. Each progress record is associated with an issue or comment and contains the workflow type, current status, metadata about the execution, and optionally the conversation messages exchanged during the workflow. Progress records can form a hierarchy via parent-child relationships for multi-step workflows. +""" +type AiPromptProgress implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The unique identifier of the entity. + """ + id: ID! + """ + [Internal] The log ID for the prompt workflow, if available. + """ + logId: String + """ + [Internal] The metadata for the prompt workflow. + """ + metadata: JSONObject! + """ + [Internal] The status of the prompt workflow. + """ + status: AiPromptProgressStatus! + """ + [Internal] The type of AI prompt workflow. + """ + type: AiPromptType! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +type AiPromptProgressConnection { + edges: [AiPromptProgressEdge!]! + nodes: [AiPromptProgress!]! + pageInfo: PageInfo! +} + +type AiPromptProgressEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: AiPromptProgress! +} + +""" +[Internal] AI prompt progress filtering options. +""" +input AiPromptProgressFilter { + """ + [Internal] Compound filters, all of which need to be matched by the AI prompt progress. + """ + and: [AiPromptProgressFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + [Internal] Compound filters, one of which need to be matched by the AI prompt progress. + """ + or: [AiPromptProgressFilter!] + """ + [Internal] Comparator for the AI prompt workflow status. + """ + status: AiPromptProgressStatusComparator + """ + [Internal] Comparator for the AI prompt workflow type. + """ + type: AiPromptTypeComparator + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +[Internal] The status of a prompt workflow. +""" +enum AiPromptProgressStatus { + canceled + created + failed + finished + inProgress +} + +""" +[Internal] Comparator for the AI prompt workflow status. +""" +input AiPromptProgressStatusComparator { + """ + Equals constraint. + """ + eq: AiPromptProgressStatus + """ + In-array constraint. + """ + in: [AiPromptProgressStatus!] + """ + Not-equals constraint. + """ + neq: AiPromptProgressStatus + """ + Not-in-array constraint. + """ + nin: [AiPromptProgressStatus!] + """ + Null constraint. Matches any non-null values if the given value is false, otherwise it matches null values. + """ + null: Boolean +} + +""" +[Internal] Filter for AI prompt progress subscription events. +""" +input AiPromptProgressSubscriptionFilter { + """ + [Internal] Filter by comment ID. + """ + commentId: IDComparator + """ + [Internal] Filter by issue ID. + """ + issueId: IDComparator + """ + [Internal] Filter by pull request comment ID. + """ + pullRequestCommentId: IDComparator + """ + [Internal] Filter by prompt workflow status. + """ + status: AiPromptProgressStatusComparator + """ + [Internal] Filter by prompt workflow type. + """ + type: AiPromptTypeComparator +} + +""" +Custom rules that guide AI behavior for a specific scope. Rules can be defined at the workspace level, team level, integration level, or user level, and are applied hierarchically (workspace rules first, then parent team rules, then team rules). Rules contain structured content that instructs the AI assistant on how to handle specific types of prompts, such as coding agent guidance or triage intelligence configuration. +""" +type AiPromptRules implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The unique identifier of the entity. + """ + id: ID! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The user who last updated the AI prompt rules. + """ + updatedBy: User +} + +""" +The type of AI prompt workflow. +""" +enum AiPromptType { + agentGuidance + aiConversation + codeIntelligence + gongIssueIntake + initiativeUpdates + intercomIssueIntake + internalResearch + microsoftTeamsIssueIntake + productIntelligence + projectUpdates + slackIssueIntake + zendeskIssueIntake +} + +""" +[Internal] Comparator for the AI prompt workflow type. +""" +input AiPromptTypeComparator { + """ + Equals constraint. + """ + eq: AiPromptType + """ + In-array constraint. + """ + in: [AiPromptType!] + """ + Not-equals constraint. + """ + neq: AiPromptType + """ + Not-in-array constraint. + """ + nin: [AiPromptType!] + """ + Null constraint. Matches any non-null values if the given value is false, otherwise it matches null values. + """ + null: Boolean +} + +input AirbyteConfigurationInput { + """ + Linear export API key. + """ + apiKey: String! +} + +""" +Payload for app user notification webhook events. +""" +type AppUserNotificationWebhookPayload { + """ + The type of action that triggered the webhook. + """ + action: String! + """ + ID of the app user the notification is for. + """ + appUserId: String! + """ + The time the payload was created. + """ + createdAt: DateTime! + """ + Details of the notification. + """ + notification: NotificationWebhookPayload! + """ + ID of the OAuth client the app user is tied to. + """ + oauthClientId: String! + """ + ID of the organization for which the webhook belongs to. + """ + organizationId: String! + """ + The type of resource. + """ + type: String! + """ + The ID of the webhook that sent this event. + """ + webhookId: String! + """ + Unix timestamp in milliseconds when the webhook was sent. + """ + webhookTimestamp: Float! +} + +""" +Payload for app user team access change webhook events. +""" +type AppUserTeamAccessChangedWebhookPayload { + """ + The type of action that triggered the webhook. + """ + action: String! + """ + IDs of the teams the app user was added to. + """ + addedTeamIds: [String!]! + """ + ID of the app user the notification is for. + """ + appUserId: String! + """ + Whether the app user can access all public teams. + """ + canAccessAllPublicTeams: Boolean! + """ + The time the payload was created. + """ + createdAt: DateTime! + """ + ID of the OAuth client the app user is tied to. + """ + oauthClientId: String! + """ + ID of the organization for which the webhook belongs to. + """ + organizationId: String! + """ + IDs of the teams the app user was removed from. + """ + removedTeamIds: [String!]! + """ + The type of resource. + """ + type: String! + """ + The ID of the webhook that sent this event. + """ + webhookId: String! + """ + Unix timestamp in milliseconds when the webhook was sent. + """ + webhookTimestamp: Float! +} + +""" +Public-facing information about an OAuth application. Contains only the fields that are safe to display to users during the authorization flow, excluding sensitive data like client secrets and internal configuration. +""" +type Application { + """ + OAuth application's client ID. + """ + clientId: String! + """ + Information about the application. + """ + description: String + """ + Name of the developer. + """ + developer: String! + """ + URL of the developer's website, homepage, or documentation. + """ + developerUrl: String! + """ + OAuth application's ID. + """ + id: String! + """ + Image of the application. + """ + imageUrl: String + """ + Application name. + """ + name: String! +} + +""" +Customer approximate need count sorting options. +""" +input ApproximateNeedCountSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +A generic payload return from entity archive or deletion mutations. +""" +interface ArchivePayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Contains requested archived model objects. +""" +type ArchiveResponse { + """ + A JSON serialized collection of model objects loaded from the archive + """ + archive: String! + """ + The version of the remote database. Incremented by 1 for each migration run on the database. + """ + databaseVersion: Float! + """ + Whether the dependencies for the model objects are included in the archive. + """ + includesDependencies: [String!]! + """ + The total number of entities in the archive. + """ + totalCount: Float! +} + +""" +A recently archived integration. +""" +type ArchivedIntegrationPayload { + """ + The time at which the integration was archived. + """ + archivedAt: DateTime! + """ + Whether the integration had full code access. + """ + codeAccess: Boolean + """ + The enterprise URL if this is a GitHub Enterprise Cloud integration. + """ + enterpriseUrl: String + """ + The external identifier of the connected GitHub organization. + """ + externalOrgId: String + """ + The unique identifier of the integration. + """ + id: String! + """ + The avatar URL of the connected GitHub organization. + """ + orgAvatarUrl: String + """ + The login name of the connected GitHub organization. + """ + orgLogin: String + """ + The integration service type. + """ + service: String! +} + +type AsksChannelConnectPayload { + """ + Whether the bot needs to be manually added to the channel. + """ + addBot: Boolean! + """ + GitHub-specific details for the operation. Populated by GitHub-related mutations only. + """ + gitHub: GitHubIntegrationConnectDetails + """ + The integration that was created or updated. + """ + integration: Integration + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + The new Asks Slack channel mapping for the connected channel. + """ + mapping: SlackChannelNameMapping! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Issue assignee sorting options. +""" +input AssigneeSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +An attachment linking external content to an issue. Attachments represent connections to external resources such as GitHub pull requests, Slack messages, Zendesk tickets, Figma files, Sentry issues, Intercom conversations, and plain URLs. Each attachment has a title and subtitle displayed in the Linear UI, a URL serving as both the link destination and unique identifier per issue, and optional metadata specific to the source integration. +""" +type Attachment implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The body data of the attachment, if any. + """ + bodyData: String + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The creator of the attachment. + """ + creator: User + """ + The non-Linear user who created the attachment. + """ + externalUserCreator: ExternalUser + """ + Whether attachments from the same source application should be visually grouped together in the Linear issue detail view. + """ + groupBySource: Boolean! + """ + The unique identifier of the entity. + """ + id: ID! + """ + The issue this attachment belongs to. + """ + issue: Issue! + """ + Integration-specific metadata for this attachment. The schema varies by source type and may include fields such as pull request status, review counts, commit information, ticket status, or other data from the external system. + """ + metadata: JSONObject! + """ + The issue this attachment was originally created on. Null if the attachment hasn't been moved. + """ + originalIssue: Issue + """ + Information about the source which created the attachment. + """ + source: JSONObject + """ + The source type of the attachment, derived from the source metadata. Returns the integration type (e.g., 'github', 'slack', 'zendesk') or 'unknown' if no source is set. + """ + sourceType: String + """ + Content for the subtitle line in the Linear attachment widget. + """ + subtitle: String + """ + Content for the title line in the Linear attachment widget. + """ + title: String! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The URL of the external resource this attachment links to. Also serves as a unique identifier for the attachment within an issue; no two attachments on the same issue can share the same URL. + """ + url: String! +} + +""" +Attachment collection filtering options. +""" +input AttachmentCollectionFilter { + """ + Compound filters, all of which need to be matched by the attachment. + """ + and: [AttachmentCollectionFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Filters that the attachments creator must satisfy. + """ + creator: NullableUserFilter + """ + Filters that needs to be matched by all attachments. + """ + every: AttachmentFilter + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Comparator for the collection length. + """ + length: NumberComparator + """ + Compound filters, one of which need to be matched by the attachment. + """ + or: [AttachmentCollectionFilter!] + """ + Filters that needs to be matched by some attachments. + """ + some: AttachmentFilter + """ + Comparator for the source type. + """ + sourceType: SourceTypeComparator + """ + Comparator for the subtitle. + """ + subtitle: NullableStringComparator + """ + Comparator for the title. + """ + title: StringComparator + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator + """ + Comparator for the url. + """ + url: StringComparator +} + +type AttachmentConnection { + edges: [AttachmentEdge!]! + nodes: [Attachment!]! + pageInfo: PageInfo! +} + +""" +Input for creating a new issue attachment. +""" +input AttachmentCreateInput { + """ + Create a linked comment with markdown body. + """ + commentBody: String + """ + [Internal] Create a linked comment with Prosemirror body. Please use `commentBody` instead. + """ + commentBodyData: JSONObject + """ + Create attachment as a user with the provided name. This option is only available to OAuth applications creating attachments in `actor=application` mode. + """ + createAsUser: String + """ + Provide an external user avatar URL. Can only be used in conjunction with the `createAsUser` options. This option is only available to OAuth applications creating attachments in `actor=app` mode. + """ + displayIconUrl: String + """ + Indicates if attachments for the same source application should be grouped in the Linear UI. + """ + groupBySource: Boolean + """ + An icon url to display with the attachment. Should be of jpg or png format. Maximum of 1MB in size. Dimensions should be 20x20px for optimal display quality. + """ + iconUrl: String + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + The issue to associate the attachment with. Can be a UUID or issue identifier (e.g., 'LIN-123'). + """ + issueId: String! + """ + Attachment metadata object with string and number values. + """ + metadata: JSONObject + """ + The attachment subtitle. + """ + subtitle: String + """ + The attachment title. + """ + title: String! + """ + Attachment location which is also used as an unique identifier for the attachment. If another attachment is created with the same `url` value, existing record is updated instead. + """ + url: String! +} + +type AttachmentEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: Attachment! +} + +""" +Attachment filtering options. +""" +input AttachmentFilter { + """ + Compound filters, all of which need to be matched by the attachment. + """ + and: [AttachmentFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Filters that the attachments creator must satisfy. + """ + creator: NullableUserFilter + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Compound filters, one of which need to be matched by the attachment. + """ + or: [AttachmentFilter!] + """ + Comparator for the source type. + """ + sourceType: SourceTypeComparator + """ + Comparator for the subtitle. + """ + subtitle: NullableStringComparator + """ + Comparator for the title. + """ + title: StringComparator + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator + """ + Comparator for the url. + """ + url: StringComparator +} + +""" +The result of an attachment mutation. +""" +type AttachmentPayload { + """ + The issue attachment that was created. + """ + attachment: Attachment! + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +The result of an attachment sources query. +""" +type AttachmentSourcesPayload { + """ + A unique list of all source types used in this workspace. + """ + sources: JSONObject! +} + +""" +Input for updating an existing issue attachment. +""" +input AttachmentUpdateInput { + """ + An icon url to display with the attachment. Should be of jpg or png format. Maximum of 1MB in size. Dimensions should be 20x20px for optimal display quality. + """ + iconUrl: String + """ + Attachment metadata object with string and number values. + """ + metadata: JSONObject + """ + The attachment subtitle. + """ + subtitle: String + """ + The attachment title. + """ + title: String! +} + +""" +Payload for an attachment webhook. +""" +type AttachmentWebhookPayload { + """ + The time at which the entity was archived. + """ + archivedAt: String + """ + The time at which the entity was created. + """ + createdAt: String! + """ + The ID of the creator of the attachment. + """ + creatorId: String + """ + The ID of the non-Linear user who created the attachment. + """ + externalUserCreatorId: String + """ + Whether attachments for the same source application should be grouped in the Linear UI. + """ + groupBySource: Boolean! + """ + The ID of the entity. + """ + id: String! + """ + The ID of the issue this attachment belongs to. + """ + issueId: String! + """ + Custom metadata related to the attachment. + """ + metadata: JSONObject! + """ + The ID of the issue this attachment belonged to originally. + """ + originalIssueId: String + """ + Information about the source which created the attachment. + """ + source: JSONObject + """ + The source type of the attachment. + """ + sourceType: String + """ + Optional subtitle of the attachment. + """ + subtitle: String + """ + The title of the attachment. + """ + title: String! + """ + The time at which the entity was updated. + """ + updatedAt: String! + """ + The URL of the attachment. + """ + url: String! +} + +""" +A workspace audit log entry recording a security or compliance-relevant action. Audit entries capture who performed an action, when, from what IP address and country, and include type-specific metadata. The audit log is partitioned by time for performance and is accessible only to workspace administrators. Examples of audited actions include user authentication events, permission changes, data exports, and workspace setting modifications. +""" +type AuditEntry implements Node { + """ + The user that caused the audit entry to be created. + """ + actor: User + """ + The ID of the user that caused the audit entry to be created. + """ + actorId: String + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The ISO 3166-1 alpha-2 country code derived from the request IP address. Null if geo-location could not be determined. + """ + countryCode: String + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The unique identifier of the entity. + """ + id: ID! + """ + The IP address of the actor at the time the audited action was performed. Null if the IP was not captured. + """ + ip: String + """ + Additional metadata related to the audit entry. + """ + metadata: JSONObject + """ + The workspace the audit log belongs to. + """ + organization: Organization + """ + Additional information related to the request which performed the action. + """ + requestInformation: JSONObject + """ + The type of audited action (e.g., user authentication, permission change, data export, setting modification). + """ + type: String! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +type AuditEntryConnection { + edges: [AuditEntryEdge!]! + nodes: [AuditEntry!]! + pageInfo: PageInfo! +} + +type AuditEntryEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: AuditEntry! +} + +""" +Audit entry filtering options. +""" +input AuditEntryFilter { + """ + Filters that the audit entry actor must satisfy. + """ + actor: NullableUserFilter + """ + Compound filters, all of which need to be matched by the issue. + """ + and: [AuditEntryFilter!] + """ + Comparator for the country code. + """ + countryCode: StringComparator + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for the audited entity ID stored in metadata. + """ + entityId: StringComparator + """ + Comparator for the audited entity identifier stored in metadata. + """ + entityIdentifier: StringComparator + """ + Comparator for the audited entity type stored in metadata. + """ + entityType: StringComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Comparator for the IP address. + """ + ip: StringComparator + """ + Compound filters, one of which need to be matched by the issue. + """ + or: [AuditEntryFilter!] + """ + Comparator for the type. + """ + type: StringComparator + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +type AuditEntryType { + """ + Description of the audit entry type. + """ + description: String! + """ + The audit entry type. + """ + type: String! +} + +""" +Payload for an audit entry webhook. +""" +type AuditEntryWebhookPayload { + """ + The ID of the user that caused the audit entry to be created. + """ + actorId: String + """ + The time at which the entity was archived. + """ + archivedAt: String + """ + Country code of request resulting to audit entry. + """ + countryCode: String + """ + The time at which the entity was created. + """ + createdAt: String! + """ + The ID of the entity. + """ + id: String! + """ + IP from actor when entry was recorded. + """ + ip: String + """ + Additional metadata related to the audit entry. + """ + metadata: JSONObject + """ + The ID of the organization that the audit entry belongs to. + """ + organizationId: String! + """ + Additional information related to the request which performed the action. + """ + requestInformation: JSONObject + """ + The type of the audit entry. + """ + type: String! + """ + The time at which the entity was updated. + """ + updatedAt: String! +} + +""" +An identity provider. +""" +type AuthIdentityProvider { + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + Whether the identity provider is the default identity provider migrated from organization level settings. + """ + defaultMigrated: Boolean! + """ + The unique identifier of the entity. + """ + id: ID! + """ + The issuer's custom entity ID. + """ + issuerEntityId: String + """ + The SAML priority used to pick default workspace in SAML SP initiated flow, when same domain is claimed for SAML by multiple workspaces. Lower priority value means higher preference. + """ + priority: Float + """ + Whether SAML authentication is enabled for organization. + """ + samlEnabled: Boolean! + """ + Whether SCIM provisioning is enabled for organization. + """ + scimEnabled: Boolean! + """ + The service provider (Linear) custom entity ID. Defaults to https://auth.linear.app/sso + """ + spEntityId: String + """ + Binding method for authentication call. Can be either `post` (default) or `redirect`. + """ + ssoBinding: String + """ + Sign in endpoint URL for the identity provider. + """ + ssoEndpoint: String + """ + The algorithm of the Signing Certificate. Can be one of `sha1`, `sha256` (default), or `sha512`. + """ + ssoSignAlgo: String + """ + X.509 Signing Certificate in string form. + """ + ssoSigningCert: String + """ + The type of identity provider. + """ + type: IdentityProviderType! +} + +""" +An organization. Organizations are root-level objects that contain users and teams. +""" +type AuthOrganization { + """ + Allowed authentication providers, empty array means all are allowed + """ + allowedAuthServices: [String!]! + @deprecated(reason: "Use authSettings.allowedAuthServices instead.") + """ + An approximate count of users, updated once per day. + """ + approximateUserCount: Float! + """ + Authentication settings for the organization. + """ + authSettings: JSONObject! + """ + The cell the organization is hosted in. + """ + cell: String! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The time at which deletion of the organization was requested. + """ + deletionRequestedAt: DateTime + """ + Whether the organization is enabled. Used as a superuser tool to lock down the org. + """ + enabled: Boolean! + """ + Whether to hide other organizations for new users signing up with email domains claimed by this organization. + """ + hideNonPrimaryOrganizations: Boolean! + """ + The unique identifier of the entity. + """ + id: ID! + """ + The organization's logo URL. + """ + logoUrl: String + """ + The organization's name. + """ + name: String! + """ + Previously used URL keys for the organization (last 3 are kept and redirected). + """ + previousUrlKeys: [String!]! + """ + The region the organization is hosted in. + """ + region: String! + """ + The feature release channel the organization belongs to. + """ + releaseChannel: ReleaseChannel! + """ + Whether SAML authentication is enabled for organization. + """ + samlEnabled: Boolean! + """ + [INTERNAL] SAML settings + """ + samlSettings: JSONObject + """ + Whether SCIM provisioning is enabled for organization. + """ + scimEnabled: Boolean! + """ + The email domain or URL key for the organization. + """ + serviceId: String! + """ + The organization's unique URL key. + """ + urlKey: String! + userCount: Float +} + +type AuthResolverResponse { + """ + Should the signup flow allow access for the domain. + """ + allowDomainAccess: Boolean + """ + List of organizations allowing this user account to join automatically. + """ + availableOrganizations: [AuthOrganization!] + """ + Email for the authenticated account. + """ + email: String! + """ + User account ID. + """ + id: String! + """ + ID of the organization last accessed by the user. + """ + lastUsedOrganizationId: String + """ + List of organization available to this user account but locked due to the current auth method. + """ + lockedOrganizations: [AuthOrganization!] + """ + List of locked users that are locked by login restrictions + """ + lockedUsers: [AuthUser!]! + """ + The authentication service used for the current session (e.g., google, email, saml). + """ + service: String + """ + Application token. + """ + token: String @deprecated(reason: "Deprecated and not used anymore. Never populated.") + """ + List of active users that belong to the user account. + """ + users: [AuthUser!]! +} + +""" +A user that has access to the resources of an organization. +""" +type AuthUser { + """ + Whether the user is active. + """ + active: Boolean! + """ + An URL to the user's avatar image. + """ + avatarUrl: String + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The user's display (nick) name. Unique within each organization. + """ + displayName: String! + """ + The user's email address. + """ + email: String! + id: ID! + """ + [INTERNAL] Identity provider the user is managed by. + """ + identityProvider: AuthIdentityProvider + """ + The user's full name. + """ + name: String! + """ + The ID of the OAuth client that created the user. + """ + oauthClientId: String + """ + Organization the user belongs to. + """ + organization: AuthOrganization! + """ + Whether the user is an organization admin or guest on a database level. + """ + role: UserRoleType! + """ + User account ID the user belongs to. + """ + userAccountId: String! +} + +""" +Information about an active authentication session, including the device, location, and timestamps for when it was created and last used. +""" +type AuthenticationSessionResponse { + """ + Used web browser. + """ + browserType: String + """ + Client used for the session + """ + client: String + """ + Country codes of all seen locations. + """ + countryCodes: [String!]! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + Detailed name of the session including version information, derived from the user agent. + """ + detailedName: String! + id: String! + """ + IP address. + """ + ip: String + """ + Whether this session is the one used to make the current API request. + """ + isCurrentSession: Boolean! + """ + When was the session last seen + """ + lastActiveAt: DateTime + """ + Human readable location + """ + location: String + """ + Location city name. + """ + locationCity: String + """ + Location country name. + """ + locationCountry: String + """ + Location country code. + """ + locationCountryCode: String + """ + Location region code. + """ + locationRegionCode: String + """ + Name of the session, derived from the client and operating system + """ + name: String! + """ + Operating system used for the session + """ + operatingSystem: String + """ + Service used for logging in. + """ + service: String + """ + Type of application used to authenticate. + """ + type: AuthenticationSessionType! + """ + Date when the session was last updated. + """ + updatedAt: DateTime! + """ + Session's user-agent. + """ + userAgent: String +} + +enum AuthenticationSessionType { + android + desktop + ios + web +} + +""" +Base fields for all webhook payloads. +""" +type BaseWebhookPayload { + """ + The time the payload was created. + """ + createdAt: DateTime! + """ + ID of the organization for which the webhook belongs to. + """ + organizationId: String! + """ + The ID of the webhook that sent this event. + """ + webhookId: String! + """ + Unix timestamp in milliseconds when the webhook was sent. + """ + webhookTimestamp: Float! +} + +""" +Comparator for booleans. +""" +input BooleanComparator { + """ + Equals constraint. + """ + eq: Boolean + """ + Not equals constraint. + """ + neq: Boolean +} + +""" +A candidate code repository to consider when generating repository suggestions for an issue. +""" +input CandidateRepository { + """ + Hostname of the Git service (e.g., 'github.com', 'github.company.com'). + """ + hostname: String! + """ + The full name of the repository in owner/name format (e.g., 'acme/backend'). + """ + repositoryFullName: String! +} + +""" +[Internal] Detailed information about the coding agent sandbox environment associated with an agent session, including cloud infrastructure URLs for debugging and monitoring. +""" +type CodingAgentSandboxEntry { + """ + The Git ref (branch, tag, or commit) that was checked out as the base for this sandbox. Defaults to the repository's default branch. + """ + baseRef: String + """ + The Git branch name created for this sandbox session. Null if a branch has not yet been assigned. + """ + branchName: String + """ + The time at which the sandbox was created. + """ + createdAt: DateTime! + """ + The user who initiated the session. + """ + creatorId: String + """ + The time at which the session reached a terminal state. Null if still active. + """ + endedAt: DateTime + """ + The sandbox identifier. + """ + id: String! + """ + GitHub repository in owner/repo format. + """ + repository: String! + """ + URL to the sandbox execution logs in Modal. Null if the sandbox has no URL or is not running on Modal. + """ + sandboxLogsUrl: String + """ + The URL of the running sandbox environment. Null when the sandbox is hibernated or destroyed. + """ + sandboxUrl: String + """ + The time at which the sandbox first became active. Null if not yet started. + """ + startedAt: DateTime + """ + The Claude Agent SDK session ID used for resuming multi-turn conversations with the sandbox worker. + """ + workerConversationId: String +} + +""" +[Internal] Coding agent sandbox details for an agent session. +""" +type CodingAgentSandboxPayload { + """ + The agent session identifier. + """ + agentSessionId: String! + """ + Datadog logs URL covering all sandboxes in the session. + """ + datadogLogsUrl: String + """ + All sandbox containers for this session, oldest first. + """ + sandboxes: [CodingAgentSandboxEntry!]! + """ + Temporal URL to view workflows for this session. + """ + temporalWorkflowsUrl: String +} + +""" +A reason the workspace cannot trust content from the authenticated OAuth application for Coding Sessions. +""" +enum CodingSessionsDisabledReason { + """ + Coding Sessions and trusted external sources are available, but the application's source is not approved or is no longer available in the workspace. + """ + APP_NOT_TRUSTED + """ + Coding Sessions or Linear Agent are disabled in the workspace, or the workspace's plan does not support Coding Sessions. + """ + CODING_SESSIONS_DISABLED + """ + Coding Sessions are enabled, but the workspace cannot use trusted external sources. + """ + TRUSTED_EXTERNAL_SOURCES_UNAVAILABLE +} + +""" +A comment associated with an issue, project update, initiative update, document content, post, project, or initiative. Comments support rich text (ProseMirror), emoji reactions, and threaded replies via parentId. Comments can be created by workspace users or by external users through integrations (e.g., Slack, Intercom). Each comment belongs to exactly one parent entity. +""" +type Comment implements Node { + """ + Agent session associated with this comment. + """ + agentSession: AgentSession + """ + [Internal] Agent sessions associated with this comment. + """ + agentSessions( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): AgentSessionConnection! + """ + [Internal] AI prompt progresses associated with this comment. + """ + aiPromptProgresses( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned AI prompt progresses. + """ + filter: AiPromptProgressFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): AiPromptProgressConnection! + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The comment content in markdown format. This is a derived representation of the canonical bodyData ProseMirror content. + """ + body: String! + """ + [Internal] The comment content as a ProseMirror document. This is the canonical rich-text representation of the comment body. + """ + bodyData: String! + """ + The bot that created the comment. + """ + botActor: ActorBot + """ + The children of the comment. + """ + children( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned comments. + """ + filter: CommentFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): CommentConnection! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + Issues created from this comment. + """ + createdIssues( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned issues. + """ + filter: IssueFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): IssueConnection! + """ + The document content that the comment is associated with. Null if the comment belongs to a different parent entity type. Used for inline comments on documents. + """ + documentContent: DocumentContent + """ + The ID of the document content that the comment is associated with. Null if the comment belongs to a different parent entity type. + """ + documentContentId: String + """ + The time the comment was last edited by its author. Null if the comment has not been edited since creation. + """ + editedAt: DateTime + """ + The external thread that the comment is synced with. + """ + externalThread: SyncedExternalThread + """ + The external user who wrote the comment, when the comment was created through an integration such as Slack or Intercom. Null for comments created by workspace users. + """ + externalUser: ExternalUser + """ + [Internal] Whether the comment should be hidden from Linear clients. This is typically used for bot comments that provide redundant information (e.g., Slack Asks confirmation messages). + """ + hideInLinear: Boolean! + """ + The unique identifier of the entity. + """ + id: ID! + """ + The initiative that the comment is associated with. Null if the comment belongs to a different parent entity type. + """ + initiative: Initiative + """ + The ID of the initiative that the comment is associated with. Null if the comment belongs to a different parent entity type. + """ + initiativeId: String + """ + The initiative update that the comment is associated with. Null if the comment belongs to a different parent entity type. + """ + initiativeUpdate: InitiativeUpdate + """ + The ID of the initiative update that the comment is associated with. Null if the comment belongs to a different parent entity type. + """ + initiativeUpdateId: String + """ + [Internal] Whether the comment is an artificial placeholder for an agent session thread created without a comment mention. + """ + isArtificialAgentSessionRoot: Boolean! + """ + The issue that the comment is associated with. Null if the comment belongs to a different parent entity type. + """ + issue: Issue + """ + The ID of the issue that the comment is associated with. Null if the comment belongs to a different parent entity type. + """ + issueId: String + """ + [Internal] The user on whose behalf the comment was created, e.g. when the Linear assistant creates a comment for a user. + """ + onBehalfOf: User + """ + The parent comment under which the current comment is nested. Null for top-level comments that are not replies. + """ + parent: Comment + """ + The ID of the parent comment under which the current comment is nested. Null for top-level comments. + """ + parentId: String + """ + The post that the comment is associated with. Null if the comment belongs to a different parent entity type. + """ + post: Post + """ + The project that the comment is associated with. Used for project-level discussion threads. Null if the comment belongs to a different parent entity type. + """ + project: Project + """ + The ID of the project that the comment is associated with. Null if the comment belongs to a different parent entity type. + """ + projectId: String + """ + The project update that the comment is associated with. Null if the comment belongs to a different parent entity type. + """ + projectUpdate: ProjectUpdate + """ + The ID of the project update that the comment is associated with. Null if the comment belongs to a different parent entity type. + """ + projectUpdateId: String + """ + The text that this comment references, used for inline comments on documents or issue descriptions. Null for standard comments that do not quote specific text. + """ + quotedText: String + """ + Emoji reaction summary for this comment, grouped by emoji type. Each entry contains the emoji name, count, and the IDs of users who reacted. + """ + reactionData: JSONObject! + """ + Reactions associated with the comment. + """ + reactions: [Reaction!]! + """ + The time when the comment thread was resolved. Null if the thread is unresolved. + """ + resolvedAt: DateTime + """ + The child comment that resolved this thread. Only set on top-level (parent) comments. Null if the thread is unresolved. + """ + resolvingComment: Comment + """ + The ID of the child comment that resolved this thread. Null if the thread is unresolved. + """ + resolvingCommentId: String + """ + The user that resolved the comment thread. Null if the thread has not been resolved or if this is not a top-level comment. + """ + resolvingUser: User + """ + [Internal] Agent sessions spawned from this comment. + """ + spawnedAgentSessions( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): AgentSessionConnection! + """ + The external services the comment is synced with. + """ + syncedWith: [ExternalEntityInfo!] + """ + [Internal] An AI-generated summary of the comment thread. Null if no summary has been generated or if this is not a top-level comment. + """ + threadSummary: JSONObject + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + Comment's URL. + """ + url: String! + """ + The user who wrote the comment. Null for comments created by integrations or bots without a user association. + """ + user: User +} + +""" +Certain properties of a comment. +""" +type CommentChildWebhookPayload { + """ + The body of the comment. + """ + body: String! + """ + The ID of the document content this comment belongs to. + """ + documentContentId: String + """ + The ID of the comment. + """ + id: String! + """ + [Internal] The ID of the initiative this comment belongs to. + """ + initiativeId: String + """ + The ID of the initiative update this comment belongs to. + """ + initiativeUpdateId: String + """ + The ID of the issue this comment belongs to. + """ + issueId: String + """ + [Internal] The ID of the project this comment belongs to. + """ + projectId: String + """ + The ID of the project update this comment belongs to. + """ + projectUpdateId: String + """ + The ID of the user who created this comment. + """ + userId: String +} + +""" +Comment filtering options. +""" +input CommentCollectionFilter { + """ + Compound filters, all of which need to be matched by the comment. + """ + and: [CommentCollectionFilter!] + """ + Comparator for the comment's body. + """ + body: StringComparator + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Filters that the comment's document content must satisfy. + """ + documentContent: NullableDocumentContentFilter + """ + Filters that needs to be matched by all comments. + """ + every: CommentFilter + """ + Comparator for the identifier. + """ + id: IDComparator + """ + [Internal] Filters that the comment's initiative must satisfy. + """ + initiative: NullableInitiativeFilter + """ + Filters that the comment's initiative update must satisfy. + """ + initiativeUpdate: NullableInitiativeUpdateFilter + """ + Filters that the comment's issue must satisfy. + """ + issue: NullableIssueFilter + """ + Comparator for the collection length. + """ + length: NumberComparator + """ + Filters that the comment's customer needs must satisfy. + """ + needs: CustomerNeedCollectionFilter + """ + Compound filters, one of which need to be matched by the comment. + """ + or: [CommentCollectionFilter!] + """ + Filters that the comment parent must satisfy. + """ + parent: NullableCommentFilter + """ + [Internal] Filters that the comment's project must satisfy. + """ + project: NullableProjectFilter + """ + Filters that the comment's project update must satisfy. + """ + projectUpdate: NullableProjectUpdateFilter + """ + Filters that the comment's reactions must satisfy. + """ + reactions: ReactionCollectionFilter + """ + Filters that needs to be matched by some comments. + """ + some: CommentFilter + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator + """ + Filters that the comment's creator must satisfy. + """ + user: UserFilter +} + +type CommentConnection { + edges: [CommentEdge!]! + nodes: [Comment!]! + pageInfo: PageInfo! +} + +""" +Input for creating a new comment. +""" +input CommentCreateInput { + """ + The comment content in markdown format. + """ + body: String + """ + [Internal] The comment content as a Prosemirror document. + """ + bodyData: JSON + """ + Create comment as a user with the provided name. This option is only available to OAuth applications creating comments in `actor=app` mode. + """ + createAsUser: String + """ + Flag to indicate this comment should be created on the issue's synced Slack comment thread. If no synced Slack comment thread exists, the mutation will fail. If there are multiple synced Slack threads on the issue, the oldest one will be targeted. + """ + createOnSyncedSlackThread: Boolean + """ + The time at which the comment was created (e.g. if importing from another system). Must be a time in the past. If none is provided, the backend will generate the time as now. + """ + createdAt: DateTime + """ + Provide an external user avatar URL. Can only be used in conjunction with the `createAsUser` options. This option is only available to OAuth applications creating comments in `actor=app` mode. + """ + displayIconUrl: String + """ + Flag to prevent auto subscription to the issue the comment is created on. + """ + doNotSubscribeToIssue: Boolean + """ + The document content to associate the comment with. + """ + documentContentId: String + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + The initiative to associate the comment with. Can be a UUID or initiative identifier (e.g., 'I-12'). + """ + initiativeId: String + """ + The initiative update to associate the comment with. + """ + initiativeUpdateId: String + """ + [Internal] Where the commented text starts, as a base64-encoded Y.js relative position created on the commenter's copy of the document content. Requires `inlineAnchorTo` and `documentContentId`. + """ + inlineAnchorFrom: String + """ + [Internal] Where the commented text ends, as a base64-encoded Y.js relative position created on the commenter's copy of the document content. Requires `inlineAnchorFrom` and `documentContentId`. + """ + inlineAnchorTo: String + """ + The issue to associate the comment with. Can be a UUID or issue identifier (e.g., 'LIN-123'). + """ + issueId: String + """ + The parent comment under which to nest a current comment. + """ + parentId: String + """ + The post to associate the comment with. + """ + postId: String + """ + The project to associate the comment with. Can be a UUID or project identifier (e.g., 'P-LIN-123'). + """ + projectId: String + """ + The project update to associate the comment with. + """ + projectUpdateId: String + """ + The text that this comment references. Only defined for inline comments. + """ + quotedText: String + """ + [INTERNAL] The identifiers of the users subscribing to this comment thread. + """ + subscriberIds: [String!] +} + +type CommentEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: Comment! +} + +""" +Comment filtering options. +""" +input CommentFilter { + """ + Compound filters, all of which need to be matched by the comment. + """ + and: [CommentFilter!] + """ + Comparator for the comment's body. + """ + body: StringComparator + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Filters that the comment's document content must satisfy. + """ + documentContent: NullableDocumentContentFilter + """ + Comparator for the identifier. + """ + id: IDComparator + """ + [Internal] Filters that the comment's initiative must satisfy. + """ + initiative: NullableInitiativeFilter + """ + Filters that the comment's initiative update must satisfy. + """ + initiativeUpdate: NullableInitiativeUpdateFilter + """ + Filters that the comment's issue must satisfy. + """ + issue: NullableIssueFilter + """ + Filters that the comment's customer needs must satisfy. + """ + needs: CustomerNeedCollectionFilter + """ + Compound filters, one of which need to be matched by the comment. + """ + or: [CommentFilter!] + """ + Filters that the comment parent must satisfy. + """ + parent: NullableCommentFilter + """ + [Internal] Filters that the comment's project must satisfy. + """ + project: NullableProjectFilter + """ + Filters that the comment's project update must satisfy. + """ + projectUpdate: NullableProjectUpdateFilter + """ + Filters that the comment's reactions must satisfy. + """ + reactions: ReactionCollectionFilter + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator + """ + Filters that the comment's creator must satisfy. + """ + user: UserFilter +} + +""" +The result of a comment mutation. +""" +type CommentPayload { + """ + The comment that was created or updated. + """ + comment: Comment! + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Input for updating an existing comment. +""" +input CommentUpdateInput { + """ + The comment content. + """ + body: String + """ + [Internal] The comment content as a Prosemirror document. + """ + bodyData: JSON + """ + [INTERNAL] Flag to prevent auto subscription to the issue the comment is updated on. + """ + doNotSubscribeToIssue: Boolean + """ + The text that this comment references. Only defined for inline comments. + """ + quotedText: String + """ + [INTERNAL] The child comment that resolves this thread. + """ + resolvingCommentId: String + """ + [INTERNAL] The user who resolved this thread. + """ + resolvingUserId: String + """ + [INTERNAL] The identifiers of the users subscribing to this comment. + """ + subscriberIds: [String!] +} + +""" +Payload for a comment webhook. +""" +type CommentWebhookPayload { + """ + The time at which the entity was archived. + """ + archivedAt: String + """ + The body of the comment. + """ + body: String! + """ + The bot actor data for this comment. + """ + botActor: String + """ + The time at which the entity was created. + """ + createdAt: String! + """ + The document content for this comment. + """ + documentContent: DocumentContentChildWebhookPayload + """ + The ID of the document content this comment belongs to. + """ + documentContentId: String + """ + When the comment was last edited. + """ + editedAt: String + """ + The external user who created this comment. + """ + externalUser: ExternalUserChildWebhookPayload + """ + The ID of the external user who created this comment. + """ + externalUserId: String + """ + The ID of the entity. + """ + id: String! + """ + [Internal] The ID of the initiative this comment belongs to. + """ + initiativeId: String + """ + The initiative update this comment belongs to. + """ + initiativeUpdate: InitiativeUpdateChildWebhookPayload + """ + The ID of the initiative update this comment belongs to. + """ + initiativeUpdateId: String + """ + The issue this comment belongs to. + """ + issue: IssueChildWebhookPayload + """ + The ID of the issue this comment belongs to. + """ + issueId: String + """ + The parent comment. + """ + parent: CommentChildWebhookPayload + """ + The ID of the parent comment. + """ + parentId: String + """ + The ID of the post this comment belongs to. + """ + postId: String + """ + [Internal] The ID of the project this comment belongs to. + """ + projectId: String + """ + The project update this comment belongs to. + """ + projectUpdate: ProjectUpdateChildWebhookPayload + """ + The ID of the project update this comment belongs to. + """ + projectUpdateId: String + """ + The quoted text in this comment. + """ + quotedText: String + """ + The reaction data for this comment. + """ + reactionData: JSONObject! + """ + When the comment was resolved. + """ + resolvedAt: String + """ + The ID of the comment that resolved this comment. + """ + resolvingCommentId: String + """ + The ID of the user who resolved this comment. + """ + resolvingUserId: String + """ + The entity this comment is synced with. + """ + syncedWith: JSONObject + """ + The time at which the entity was updated. + """ + updatedAt: String! + """ + The user who created this comment. + """ + user: UserChildWebhookPayload + """ + The ID of the user who created this comment. + """ + userId: String +} + +""" +Issue completion date sorting options. +""" +input CompletedAtSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +Input for submitting a support contact message from an authenticated user. +""" +input ContactCreateInput { + """ + The user's browser name and version (e.g., 'Chrome 120'). + """ + browser: String + """ + The version of the Linear client application the user is running. + """ + clientVersion: String + """ + The user's device type or model information. + """ + device: String + """ + How disappointed the user would be if they could no longer use Linear. Scale: 0 = not disappointed, 1 = somewhat disappointed, 2 = very disappointed, 3 = extremely disappointed. + """ + disappointmentRating: Int + """ + The feedback or support message submitted by the user. + """ + message: String! + """ + The user's operating system name and version (e.g., 'macOS 14.0'). + """ + operatingSystem: String + """ + The type of support contact. + """ + type: String! +} + +""" +Return type for contact mutations. +""" +type ContactPayload { + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +[INTERNAL] Input for submitting a sales or pricing inquiry to the Linear sales team. Small companies are routed to Intercom support, while larger companies are routed to HubSpot. +""" +input ContactSalesCreateInput { + """ + The size of the inquiring company (e.g., '1-19', '20-99', '100-499'). Used to route the inquiry to the appropriate sales channel. + """ + companySize: String + """ + PostHog distinct ID for correlating this inquiry with anonymous analytics events. + """ + distinctId: String + """ + Work email address of the person submitting the sales inquiry. + """ + email: String! + """ + An optional message from the user describing their needs or questions. + """ + message: String + """ + Full name of the person submitting the sales inquiry. + """ + name: String! + """ + PostHog session ID for correlating this inquiry with the user's browsing session. + """ + sessionId: String + """ + The page URL from which the sales inquiry was submitted, for attribution tracking. + """ + url: String + """ + JSON serialized last-touch UTM parameters captured from the `utm` cookie at form submission. + """ + utm: String + """ + JSON serialized first-touch UTM parameters captured from the `utm_first` cookie at form submission. + """ + utmFirstTouch: String +} + +""" +[Internal] Comparator for content. +""" +input ContentComparator { + """ + [Internal] Contains constraint. + """ + contains: String + """ + [Internal] Not-contains constraint. + """ + notContains: String +} + +enum ContextViewType { + activeCycle + activeIssues + backlog + triage + upcomingCycle +} + +""" +The payload returned by the createCsvExportReport mutation. +""" +type CreateCsvExportReportPayload { + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +[INTERNAL] Response from creating or joining a workspace. +""" +type CreateOrJoinOrganizationResponse { + """ + The workspace that was created or joined. + """ + organization: AuthOrganization! + """ + The user who created or joined the workspace. + """ + user: AuthUser! +} + +input CreateOrganizationInput { + """ + Whether the organization should allow email domain access. + """ + domainAccess: Boolean + """ + The name of the organization. + """ + name: String! + """ + The timezone of the organization, passed in by client. + """ + timezone: String + """ + The URL key of the organization. + """ + urlKey: String! + """ + JSON serialized UTM parameters associated with the creation of the workspace. + """ + utm: String + """ + JSON serialized UTM parameters captured on the user's first visit to the marketing site (first-touch attribution). + """ + utmFirstTouch: String +} + +""" +Issue creation date sorting options. +""" +input CreatedAtSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +Payload for custom webhook resource events. +""" +type CustomResourceWebhookPayload { + """ + The type of action that triggered the webhook. + """ + action: String! + """ + The time the payload was created. + """ + createdAt: DateTime! + """ + ID of the organization for which the webhook belongs to. + """ + organizationId: String! + """ + The type of resource. + """ + type: String! + """ + The ID of the webhook that sent this event. + """ + webhookId: String! + """ + Unix timestamp in milliseconds when the webhook was sent. + """ + webhookTimestamp: Float! +} + +""" +A custom view built from a saved filter, sort, and grouping configuration. Views can be personal (visible only to the owner) or shared with the entire workspace. They define which issues, projects, initiatives, or feed items are displayed and how they are organized. Views can optionally be scoped to a team, project, or initiative. +""" +type CustomView implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The hex color code of the custom view icon. + """ + color: String + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The user who originally created the custom view. + """ + creator: User! + """ + The description of the custom view. + """ + description: String + """ + [INTERNAL] The facet that links this custom view to its parent entity (project, initiative, team page, etc.). Null if the view is not attached to any parent via a facet. + """ + facet: Facet + """ + The filter applied to feed items in the custom view. When set, this view displays feed items (updates) instead of issues. + """ + feedItemFilterData: JSONObject + """ + The structured filter applied to issues in the custom view. Used when the view's modelName is "Issue". + """ + filterData: JSONObject! + """ + The legacy serialized filters applied to issues in the custom view. + """ + filters: JSONObject! @deprecated(reason: "Will be replaced by `filterData` in a future update") + """ + The icon of the custom view. Can be an emoji or a decorative icon identifier. + """ + icon: String + """ + The unique identifier of the entity. + """ + id: ID! + """ + The filter applied to initiatives in the custom view. When set, this view displays initiatives instead of issues. + """ + initiativeFilterData: JSONObject + """ + Initiatives matching the custom view's initiative filter. Returns an empty connection if the view's modelName is not "Initiative". + """ + initiatives( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned initiatives. + """ + filter: InitiativeFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): InitiativeConnection! + """ + Issues matching the custom view's issue filter. Returns an empty connection if the view's modelName is not "Issue". + """ + issues( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned issues. + """ + filter: IssueFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + Include issues from sub-teams when the custom view is associated with a team. + """ + includeSubTeams: Boolean = false + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + """ + [INTERNAL] Sort returned issues. + """ + sort: [IssueSortInput!] + ): IssueConnection! + """ + The entity type this view displays. Determined by which filter is set: "Project" if projectFilterData is set, "Initiative" if initiativeFilterData is set, "FeedItem" if feedItemFilterData is set, or "Issue" by default. + """ + modelName: String! + """ + The name of the custom view, displayed in the sidebar and navigation. + """ + name: String! + """ + The workspace of the custom view. + """ + organization: Organization! + """ + The workspace-level default view preferences for this custom view, if any have been set. + """ + organizationViewPreferences: ViewPreferences + """ + The user who owns the custom view. For personal views, only the owner can see and edit the view. + """ + owner: User! + """ + The filter applied to projects in the custom view. When set, this view displays projects instead of issues. + """ + projectFilterData: JSONObject + """ + Projects matching the custom view's project filter. Returns an empty connection if the view's modelName is not "Project". + """ + projects( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned projects. + """ + filter: ProjectFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + Include projects from sub-teams when the custom view is associated with a team. + """ + includeSubTeams: Boolean = true + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + """ + [INTERNAL] Sort returned projects. + """ + sort: [ProjectSortInput!] + ): ProjectConnection! + """ + Whether the custom view is shared with everyone in the organization. Shared views appear in the workspace sidebar for all members. Personal (non-shared) views are only visible to their owner. + """ + shared: Boolean! + """ + The custom view's unique URL slug, used to construct human-readable URLs. Automatically generated on creation. + """ + slugId: String! + """ + The team that the custom view is scoped to. Null if the view is workspace-wide or scoped to a project/initiative instead. + """ + team: Team + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The user who last updated the custom view. Null if the updater's account has been deleted. + """ + updatedBy: User + """ + Feed items (updates) matching the custom view's feed item filter. Returns an empty connection if the view's modelName is not "FeedItem". + """ + updates( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned feed items. + """ + filter: FeedItemFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + Include updates from sub-teams when the custom view is associated with a team. + """ + includeSubTeams: Boolean = false + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): FeedItemConnection! + """ + The current user's personal view preferences for this custom view, if they have set any. + """ + userViewPreferences: ViewPreferences + """ + The computed view preferences values for this custom view, merging organization defaults with user overrides and system defaults. Use this for the effective display settings rather than reading raw preferences directly. + """ + viewPreferencesValues: ViewPreferencesValues +} + +type CustomViewConnection { + edges: [CustomViewEdge!]! + nodes: [CustomView!]! + pageInfo: PageInfo! +} + +""" +Input for creating a new custom view. A name is required. Optionally scope the view to a team, project, or initiative. +""" +input CustomViewCreateInput { + """ + The color of the icon of the custom view. + """ + color: String + """ + The description of the custom view. + """ + description: String + """ + The feed item filter applied to issues in the custom view. + """ + feedItemFilterData: FeedItemFilter + """ + The filter applied to issues in the custom view. + """ + filterData: IssueFilter + """ + The icon of the custom view. + """ + icon: String + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + [ALPHA] The initiative filter applied to issues in the custom view. + """ + initiativeFilterData: InitiativeFilter + """ + The id of the initiative associated with the custom view. + """ + initiativeId: String + """ + The name of the custom view. + """ + name: String! + """ + The owner of the custom view. + """ + ownerId: String + """ + The project filter applied to issues in the custom view. + """ + projectFilterData: ProjectFilter + """ + The id of the project associated with the custom view. + """ + projectId: String + """ + Whether the custom view is shared with everyone in the workspace. + """ + shared: Boolean + """ + The id of the team associated with the custom view. + """ + teamId: String +} + +""" +Custom view creation date sorting options. +""" +input CustomViewCreatedAtSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +type CustomViewEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: CustomView! +} + +""" +Custom view filtering options. +""" +input CustomViewFilter { + """ + Compound filters, all of which need to be matched by the custom view. + """ + and: [CustomViewFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Filters that the custom view creator must satisfy. + """ + creator: UserFilter + """ + [INTERNAL] Filter based on whether the custom view has a facet. + """ + hasFacet: Boolean + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Comparator for the custom view model name. + """ + modelName: StringComparator + """ + Comparator for the custom view name. + """ + name: StringComparator + """ + Compound filters, one of which need to be matched by the custom view. + """ + or: [CustomViewFilter!] + """ + Comparator for whether the custom view is shared. + """ + shared: BooleanComparator + """ + Filters that the custom view's team must satisfy. + """ + team: NullableTeamFilter + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +The result of a custom view subscribers check. +""" +type CustomViewHasSubscribersPayload { + """ + Whether the custom view has subscribers. + """ + hasSubscribers: Boolean! +} + +""" +Custom view name sorting options. +""" +input CustomViewNameSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +A notification subscription scoped to a specific custom view. The subscriber receives notifications for events matching the custom view's filter criteria. +""" +type CustomViewNotificationSubscription implements Entity & Node & NotificationSubscription { + """ + Whether the subscription is active. When inactive, no notifications are generated from this subscription even though it still exists. + """ + active: Boolean! + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The type of contextual view (e.g., active issues, backlog) that further scopes a team notification subscription. Null if the subscription is not associated with a specific view type. + """ + contextViewType: ContextViewType + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The custom view subscribed to. + """ + customView: CustomView! + """ + The customer that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + customer: Customer + """ + The cycle that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + cycle: Cycle + """ + The unique identifier of the entity. + """ + id: ID! + """ + Whether initiative update notifications also include updates from sub-initiatives. Applies only when initiative updates are enabled and the workspace supports sub-initiatives. + """ + includeSubInitiativeUpdates: Boolean! + """ + The initiative that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + initiative: Initiative + """ + The issue label that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + label: IssueLabel + """ + The notification event types that this subscription will deliver to the subscriber. + """ + notificationSubscriptionTypes: [String!]! + """ + The project that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + project: Project + """ + The user who will receive notifications from this subscription. + """ + subscriber: User! + """ + The team that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + team: Team + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The user that this notification subscription is scoped to, for user-specific view subscriptions. Null if the subscription targets a different entity type. + """ + user: User + """ + The type of user-specific view that further scopes a user notification subscription. Null if the subscription is not associated with a user view type. + """ + userContextViewType: UserContextViewType +} + +""" +The result of a custom view mutation. +""" +type CustomViewPayload { + """ + The custom view that was created or updated. + """ + customView: CustomView! + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Custom view shared status sorting options. Ascending order puts shared views last. +""" +input CustomViewSharedSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +input CustomViewSortInput { + """ + Sort by custom view creation date. + """ + createdAt: CustomViewCreatedAtSort + """ + Sort by custom view name. + """ + name: CustomViewNameSort + """ + Sort by custom view shared status. + """ + shared: CustomViewSharedSort + """ + Sort by custom view update date. + """ + updatedAt: CustomViewUpdatedAtSort +} + +""" +The result of a custom view suggestion query. +""" +type CustomViewSuggestionPayload { + """ + The suggested view description. + """ + description: String + """ + The suggested view icon. + """ + icon: String + """ + The suggested view name. + """ + name: String +} + +""" +Input for updating an existing custom view. All fields are optional; only provided fields will be updated. +""" +input CustomViewUpdateInput { + """ + The color of the icon of the custom view. + """ + color: String + """ + The description of the custom view. + """ + description: String + """ + The feed item filter applied to issues in the custom view. + """ + feedItemFilterData: FeedItemFilter + """ + The filter applied to issues in the custom view. + """ + filterData: IssueFilter + """ + The icon of the custom view. + """ + icon: String + """ + [ALPHA] The initiative filter applied to issues in the custom view. + """ + initiativeFilterData: InitiativeFilter + """ + [Internal] The id of the initiative associated with the custom view. + """ + initiativeId: String + """ + The name of the custom view. + """ + name: String + """ + The owner of the custom view. + """ + ownerId: String + """ + The project filter applied to issues in the custom view. + """ + projectFilterData: ProjectFilter + """ + [Internal] The id of the project associated with the custom view. + """ + projectId: String + """ + Whether the custom view is shared with everyone in the workspace. + """ + shared: Boolean + """ + The id of the team associated with the custom view. + """ + teamId: String +} + +""" +Custom view update date sorting options. +""" +input CustomViewUpdatedAtSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +A customer organization tracked in Linear's customer management system. Customers represent external companies or organizations whose product requests and feedback are captured as customer needs, which can be linked to issues and projects. Customers can be associated with domains, external system IDs, Slack channels, and managed by integrations such as Intercom or Salesforce. +""" +type Customer implements Node { + """ + The approximate number of distinct requests associated with this customer, deduplicated per issue or project. This is a denormalized counter and may not reflect the exact count at all times. + """ + approximateNeedCount: Float! + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The email domains associated with this customer (e.g., 'acme.com'). Used to automatically match incoming requests to this customer. Public email domains (e.g., gmail.com) are not allowed. Domains must be unique across all customers in the workspace. + """ + domains: [String!]! + """ + Identifiers for this customer in external systems (e.g., CRM IDs from Intercom, Salesforce, or HubSpot). Used for matching customers during integration syncs and upsert operations. External IDs must be unique across customers in the workspace. + """ + externalIds: [String!]! + """ + The unique identifier of the entity. + """ + id: ID! + """ + The integration that manages this customer's data (e.g., Intercom, Salesforce). Null if the customer is not managed by any data source integration. + """ + integration: Integration + """ + URL of the customer's logo image. Null if no logo has been uploaded. + """ + logoUrl: String + """ + The primary external source ID when a customer has data from multiple external systems. Must be one of the values in the externalIds array. Null if the customer has zero or one external source. + """ + mainSourceId: String + """ + The display name of the customer organization. + """ + name: String! + """ + The list of customer needs (product requests and feedback) associated with this customer. + """ + needs: [CustomerNeed!]! + """ + The workspace member assigned as the owner of this customer. Null if no owner has been assigned. App users cannot be set as customer owners. + """ + owner: User + """ + The annual revenue generated by this customer. Null if revenue data has not been provided. May be synced from an external data source such as a CRM integration. + """ + revenue: Int + """ + The number of employees or seats at the customer organization. Null if size data has not been provided. May be synced from an external data source such as a CRM integration. + """ + size: Float + """ + The ID of the Slack channel linked to this customer for communication. Null if no Slack channel has been associated. Must be unique across all customers in the workspace. + """ + slackChannelId: String + """ + A unique, human-readable URL slug for the customer. Automatically generated and used in customer page URLs. + """ + slugId: String! + """ + The current lifecycle status of the customer. Defaults to the first status by position when a customer is created without an explicit status. + """ + status: CustomerStatus! + """ + The tier or segment assigned to this customer for prioritization (e.g., Enterprise, Pro, Free). Null if no tier has been assigned. + """ + tier: CustomerTier + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The URL of the customer's page in the Linear application. + """ + url: String! +} + +""" +Certain properties of a customer. +""" +type CustomerChildWebhookPayload { + """ + The domains associated with this customer. + """ + domains: [String!]! + """ + The ids of the customers in external systems. + """ + externalIds: [String!]! + """ + The ID of the customer. + """ + id: String! + """ + The name of the customer. + """ + name: String! +} + +type CustomerConnection { + edges: [CustomerEdge!]! + nodes: [Customer!]! + pageInfo: PageInfo! +} + +""" +Issue customer count sorting options. +""" +input CustomerCountSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +Input for creating a new customer in the workspace. +""" +input CustomerCreateInput { + """ + The email domains associated with this customer (e.g., 'acme.com'). Public email domains are not allowed. Defaults to an empty array. + """ + domains: [String!] = [] + """ + Identifiers for this customer in external systems (e.g., CRM IDs). Defaults to an empty array. + """ + externalIds: [String!] = [] + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + The URL of the customer's logo image. + """ + logoUrl: String + """ + The primary external source ID for customers with multiple sources. Must be one of the values provided in externalIds. + """ + mainSourceId: String + """ + The display name of the customer organization. + """ + name: String! + """ + The identifier of the user to assign as the owner of the customer. + """ + ownerId: String + """ + The annual revenue generated by the customer, in dollars. + """ + revenue: Int + """ + The size of the customer organization (e.g., number of employees). + """ + size: Int + """ + The ID of the Slack channel to link to this customer. + """ + slackChannelId: String + """ + The identifier of the customer status to set. + """ + statusId: String + """ + The identifier of the customer tier to assign. + """ + tierId: String +} + +""" +Customer creation date sorting options. +""" +input CustomerCreatedAtSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +type CustomerEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: Customer! +} + +""" +Customer filtering options. +""" +input CustomerFilter { + """ + Compound filters, all of which need to be matched by the customer. + """ + and: [CustomerFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for the customer's domains. + """ + domains: StringArrayComparator + """ + Comparator for the customer's external IDs. + """ + externalIds: StringArrayComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Comparator for the customer name. + """ + name: StringComparator + """ + Filters that the customer's needs must satisfy. + """ + needs: CustomerNeedCollectionFilter + """ + Compound filters, one of which need to be matched by the customer. + """ + or: [CustomerFilter!] + """ + Filters that the customer owner must satisfy. + """ + owner: NullableUserFilter + """ + Comparator for the customer generated revenue. + """ + revenue: NumberComparator + """ + Comparator for the customer size. + """ + size: NumberComparator + """ + Comparator for the customer slack channel ID. + """ + slackChannelId: StringComparator + """ + Filters that the customer's status must satisfy. + """ + status: CustomerStatusFilter + """ + Filters that the customer's tier must satisfy. + """ + tier: CustomerTierFilter + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +Issue customer important count sorting options. +""" +input CustomerImportantCountSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +A customer need represents a specific product request or piece of feedback from a customer. Customer needs serve as the bridge between customer feedback and engineering work by linking a customer to an issue or project, optionally with a comment or attachment providing additional context. Needs can be created manually, from integrations, or from intake sources like email. +""" +type CustomerNeed implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The issue attachment linked to this need. Populated when the need originates from an intake source (e.g., Slack, Intercom) or when a URL is manually provided. Provides a link back to the original source of the customer feedback. Mutually exclusive with projectAttachment. + """ + attachment: Attachment + """ + The body content of the need in Markdown format. Used to capture manual input about needs that cannot be directly tied to an attachment. Null if the need's content comes from an attached source. + """ + body: String + """ + [Internal] The body content of the need as a Prosemirror document JSON string. This is the structured representation of the body field, used for rich text rendering in the editor. + """ + bodyData: String + """ + An optional comment providing additional context for this need. Null if the need was not created from or associated with a specific comment. + """ + comment: Comment + """ + The effective Markdown content shown for this customer need. Returns the manually stored body when present, otherwise falls back to content extracted from the source attachment. Null if no content is available. + """ + content: String + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The user who manually created this customer need. Null for needs created automatically by integrations or intake sources. + """ + creator: User + """ + The customer organization this need belongs to. Null if the need has not yet been associated with a customer. + """ + customer: Customer + """ + The unique identifier of the entity. + """ + id: ID! + """ + The issue this need is linked to. Either issueId or projectId must be set. When set, the need's projectId is denormalized from the issue's project. + """ + issue: Issue + """ + The issue this customer need was originally created on, before being moved to a different issue or project. Null if the customer need has not been moved from its original location. + """ + originalIssue: Issue + """ + Whether the customer need is important or not. 0 = Not important, 1 = Important. + """ + priority: Float! + """ + The project this need is linked to. For issue-based needs, this is denormalized from the issue's project. For project-only needs, this is set directly. + """ + project: Project + """ + The project attachment linked to this need. Populated when the need originates from an intake source or when a URL is manually provided for a project-level need. Provides a link back to the original source of the customer feedback. Mutually exclusive with attachment. + """ + projectAttachment: ProjectAttachment + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The URL of the source attachment linked to this need, if any. Returns the URL from either the issue attachment or project attachment. Null if the need has no attached source. + """ + url: String +} + +""" +A generic payload return from entity archive mutations. +""" +type CustomerNeedArchivePayload implements ArchivePayload { + """ + The archived/unarchived entity. Null if entity was deleted. + """ + entity: CustomerNeed + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Certain properties of a customer need. +""" +type CustomerNeedChildWebhookPayload { + """ + The ID of the attachment this need is referencing. + """ + attachmentId: String + """ + The ID of the customer that this need is attached to. + """ + customerId: String + """ + The ID of the customer need. + """ + id: String! + """ + The ID of the issue this need is referencing. + """ + issueId: String + """ + The ID of the project this need is referencing. + """ + projectId: String +} + +""" +Customer needs filtering options. +""" +input CustomerNeedCollectionFilter { + """ + Compound filters, all of which need to be matched by the customer needs. + """ + and: [CustomerNeedCollectionFilter!] + """ + Filters that the need's comment must satisfy. + """ + comment: NullableCommentFilter + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Filters that the need's customer must satisfy. + """ + customer: NullableCustomerFilter + """ + Filters that needs to be matched by all customer needs. + """ + every: CustomerNeedFilter + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Filters that the need's issue must satisfy. + """ + issue: NullableIssueFilter + """ + Comparator for the collection length. + """ + length: NumberComparator + """ + Compound filters, one of which need to be matched by the customer needs. + """ + or: [CustomerNeedCollectionFilter!] + """ + Comparator for the customer need priority. + """ + priority: NumberComparator + """ + Filters that the need's project must satisfy. + """ + project: NullableProjectFilter + """ + Filters that needs to be matched by some customer needs. + """ + some: CustomerNeedFilter + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +type CustomerNeedConnection { + edges: [CustomerNeedEdge!]! + nodes: [CustomerNeed!]! + pageInfo: PageInfo! +} + +""" +Input for creating a customer need from an existing issue attachment. If the attachment already has an archived need, it will be unarchived instead. +""" +input CustomerNeedCreateFromAttachmentInput { + """ + The UUID of the existing issue attachment to create a customer need from. + """ + attachmentId: String! +} + +""" +Input for creating a customer need linked to an issue or project. Either issueId or projectId must be provided. +""" +input CustomerNeedCreateInput { + """ + The UUID of an existing attachment to associate with this need as its source. + """ + attachmentId: String + """ + A URL to create an attachment from and associate with this customer need as its source. + """ + attachmentUrl: String + """ + The body content of the need in Markdown format. Cannot be used together with bodyData. + """ + body: String + """ + [Internal] The body content of the need as a Prosemirror document JSON string. Cannot be used together with body. + """ + bodyData: JSON + """ + The UUID of an existing comment to associate with this need for additional context. + """ + commentId: String + """ + Create the need attributed to an external user with the provided name. This option is only available to OAuth applications creating needs in `actor=app` mode. + """ + createAsUser: String + """ + The time at which the customer need was created (e.g. if importing from another system). Must be a time in the past. If none is provided, the backend will generate the time as now. + """ + createdAt: DateTime + """ + The external system ID of the customer this need belongs to. Cannot be used together with customerId. + """ + customerExternalId: String + """ + The UUID of the customer this need belongs to. Cannot be used together with customerExternalId. + """ + customerId: String + """ + Avatar URL for the external user specified in `createAsUser`. Can only be used in conjunction with `createAsUser`. This option is only available to OAuth applications creating needs in `actor=app` mode. + """ + displayIconUrl: String + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + The issue to link this need to. Accepts a UUID or issue identifier (e.g., 'LIN-123'). Either issueId or projectId must be provided. + """ + issueId: String + """ + Whether the customer need is important or not. 0 = Not important, 1 = Important. + """ + priority: Float + """ + [INTERNAL] The project to link this need to. Accepts a UUID or project identifier (e.g., 'P-LIN-123'). Either issueId or projectId must be provided. + """ + projectId: String +} + +type CustomerNeedEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: CustomerNeed! +} + +""" +Customer filtering options. +""" +input CustomerNeedFilter { + """ + Compound filters, all of which need to be matched by the customer need. + """ + and: [CustomerNeedFilter!] + """ + Filters that the need's comment must satisfy. + """ + comment: NullableCommentFilter + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Filters that the need's customer must satisfy. + """ + customer: NullableCustomerFilter + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Filters that the need's issue must satisfy. + """ + issue: NullableIssueFilter + """ + Compound filters, one of which need to be matched by the customer need. + """ + or: [CustomerNeedFilter!] + """ + Comparator for the customer need priority. + """ + priority: NumberComparator + """ + Filters that the need's project must satisfy. + """ + project: NullableProjectFilter + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +A notification related to a customer need (request), such as creation, resolution, or being marked as important. +""" +type CustomerNeedNotification implements Entity & Node & Notification { + """ + The user that caused the notification. Null if the notification was triggered by a non-user actor such as an integration, external user, or system event. + """ + actor: User + """ + [Internal] Notification actor initials if avatar is not available. + """ + actorAvatarColor: String! + """ + [Internal] Notification avatar URL. + """ + actorAvatarUrl: String + """ + [Internal] Whether the notification's user actor is deactivated in the workspace. + """ + actorInactive: Boolean! + """ + [Internal] Notification actor initials if avatar is not available. + """ + actorInitials: String + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The bot that caused the notification. + """ + botActor: ActorBot + """ + The category of the notification. + """ + category: NotificationCategory! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The customer need related to the notification. + """ + customerNeed: CustomerNeed! + """ + Related customer need. + """ + customerNeedId: String! + """ + The time at which an email reminder for this notification was sent to the user. Null if no email reminder has been sent. + """ + emailedAt: DateTime + """ + The external user that caused the notification. Populated when the notification was triggered by an external user (e.g., a commenter from a connected integration like Slack or GitHub) rather than a Linear workspace member. + """ + externalUserActor: ExternalUser + """ + [Internal] Notifications with the same grouping key will be grouped together in the UI. + """ + groupingKey: String! + """ + [Internal] Priority of the notification with the same grouping key. Higher number means higher priority. If priority is the same, notifications should be sorted by `createdAt`. + """ + groupingPriority: Float! + """ + The unique identifier of the entity. + """ + id: ID! + """ + [Internal] Inbox URL for the notification. + """ + inboxUrl: String! + """ + [Internal] Initiative update health for new updates. + """ + initiativeUpdateHealth: String + """ + [Internal] If notification actor was Linear. + """ + isLinearActor: Boolean! + """ + [Internal] Issue's status type for issue notifications. + """ + issueStatusType: String + """ + [Internal] Project update health for new updates. + """ + projectUpdateHealth: String + """ + The time at which the user marked the notification as read. Null if the notification is unread. + """ + readAt: DateTime + """ + The issue related to the notification. + """ + relatedIssue: Issue + """ + The project related to the notification. + """ + relatedProject: Project + """ + The time until which a notification is snoozed. After this time, the notification reappears in the user's inbox. Null if the notification is not currently snoozed. + """ + snoozedUntilAt: DateTime + """ + [Internal] Notification subtitle. + """ + subtitle: String! + """ + [Internal] Notification title. + """ + title: String! + """ + Notification type. Determines the kind of event that triggered this notification and which associated entity fields will be populated. + """ + type: String! + """ + The time at which a notification was unsnoozed. Null if the notification has not been unsnoozed. + """ + unsnoozedAt: DateTime + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + [Internal] URL to the target of the notification. + """ + url: String! + """ + The recipient user of this notification. + """ + user: User! +} + +""" +Return type for customer need mutations. +""" +type CustomerNeedPayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + The customer need entity that was created or updated by the mutation. + """ + need: CustomerNeed! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Input for updating a customer need. Supports reassigning the customer, moving to a different issue or project, changing priority, and updating body content. +""" +input CustomerNeedUpdateInput { + """ + When true and priority is also set, applies the same priority update to all other needs from the same customer on the same issue or project. + """ + applyPriorityToRelatedNeeds: Boolean + """ + A URL to create a new attachment from and set as the source for this customer need. Replaces any existing manually-added attachment. + """ + attachmentUrl: String + """ + The updated body content of the need in Markdown format. Set to null to clear the body. Cannot be used together with bodyData. + """ + body: String + """ + [Internal] The updated body content of the need as a Prosemirror document JSON string. Set to null to clear the body. Cannot be used together with body. + """ + bodyData: JSON + """ + The external system ID of the customer to reassign this need to. Cannot be used together with customerId. + """ + customerExternalId: String + """ + The UUID of the customer to reassign this need to. Cannot be used together with customerExternalId. + """ + customerId: String + """ + An optional identifier in UUID v4 format. If provided, will be set as the customer need's ID. + """ + id: String + """ + The issue to move this need to. Accepts a UUID or issue identifier (e.g., 'LIN-123'). The need's attachment will also be moved to the target issue. + """ + issueId: String + """ + Whether the customer need is important or not. 0 = Not important, 1 = Important. + """ + priority: Float + """ + [INTERNAL] The project to move this need to. Accepts a UUID or project identifier (e.g., 'P-LIN-123'). + """ + projectId: String +} + +""" +Return type for customer need update mutations, including any related needs that were also updated. +""" +type CustomerNeedUpdatePayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + The customer need entity that was created or updated by the mutation. + """ + need: CustomerNeed! + """ + Whether the operation was successful. + """ + success: Boolean! + """ + Additional customer needs from the same customer on the same issue/project that were updated when applyPriorityToRelatedNeeds was set. + """ + updatedRelatedNeeds: [CustomerNeed!]! +} + +""" +Payload for a customer need webhook. +""" +type CustomerNeedWebhookPayload { + """ + The time at which the entity was archived. + """ + archivedAt: String + """ + The attachment this need is referencing. + """ + attachment: AttachmentWebhookPayload + """ + The ID of the attachment this need is referencing. + """ + attachmentId: String + """ + The body of the need in Markdown format. + """ + body: String + """ + The ID of the comment this need is referencing. + """ + commentId: String + """ + The time at which the entity was created. + """ + createdAt: String! + """ + The ID of the creator of the customer need. + """ + creatorId: String + """ + The customer that this need is attached to. + """ + customer: CustomerChildWebhookPayload + """ + The ID of the customer that this need is attached to. + """ + customerId: String + """ + The ID of the entity. + """ + id: String! + """ + The issue this need is referencing. + """ + issue: IssueChildWebhookPayload + """ + The ID of the issue this need is referencing. + """ + issueId: String + """ + The issue ID this customer need was originally created on. Will be undefined if the customer need hasn't been moved. + """ + originalIssueId: String + """ + The priority of the need. + """ + priority: Float! + """ + The project this need is referencing. + """ + project: ProjectChildWebhookPayload + """ + The ID of the project attachment this need is referencing. + """ + projectAttachmentId: String + """ + The ID of the project this need is referencing. + """ + projectId: String + """ + The time at which the entity was updated. + """ + updatedAt: String! +} + +""" +A notification related to a customer, such as being added as the customer owner. +""" +type CustomerNotification implements Entity & Node & Notification { + """ + The user that caused the notification. Null if the notification was triggered by a non-user actor such as an integration, external user, or system event. + """ + actor: User + """ + [Internal] Notification actor initials if avatar is not available. + """ + actorAvatarColor: String! + """ + [Internal] Notification avatar URL. + """ + actorAvatarUrl: String + """ + [Internal] Whether the notification's user actor is deactivated in the workspace. + """ + actorInactive: Boolean! + """ + [Internal] Notification actor initials if avatar is not available. + """ + actorInitials: String + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The bot that caused the notification. + """ + botActor: ActorBot + """ + The category of the notification. + """ + category: NotificationCategory! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The customer related to the notification. + """ + customer: Customer! + """ + Related customer. + """ + customerId: String! + """ + The time at which an email reminder for this notification was sent to the user. Null if no email reminder has been sent. + """ + emailedAt: DateTime + """ + The external user that caused the notification. Populated when the notification was triggered by an external user (e.g., a commenter from a connected integration like Slack or GitHub) rather than a Linear workspace member. + """ + externalUserActor: ExternalUser + """ + [Internal] Notifications with the same grouping key will be grouped together in the UI. + """ + groupingKey: String! + """ + [Internal] Priority of the notification with the same grouping key. Higher number means higher priority. If priority is the same, notifications should be sorted by `createdAt`. + """ + groupingPriority: Float! + """ + The unique identifier of the entity. + """ + id: ID! + """ + [Internal] Inbox URL for the notification. + """ + inboxUrl: String! + """ + [Internal] Initiative update health for new updates. + """ + initiativeUpdateHealth: String + """ + [Internal] If notification actor was Linear. + """ + isLinearActor: Boolean! + """ + [Internal] Issue's status type for issue notifications. + """ + issueStatusType: String + """ + [Internal] Project update health for new updates. + """ + projectUpdateHealth: String + """ + The time at which the user marked the notification as read. Null if the notification is unread. + """ + readAt: DateTime + """ + The time until which a notification is snoozed. After this time, the notification reappears in the user's inbox. Null if the notification is not currently snoozed. + """ + snoozedUntilAt: DateTime + """ + [Internal] Notification subtitle. + """ + subtitle: String! + """ + [Internal] Notification title. + """ + title: String! + """ + Notification type. Determines the kind of event that triggered this notification and which associated entity fields will be populated. + """ + type: String! + """ + The time at which a notification was unsnoozed. Null if the notification has not been unsnoozed. + """ + unsnoozedAt: DateTime + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + [Internal] URL to the target of the notification. + """ + url: String! + """ + The recipient user of this notification. + """ + user: User! +} + +""" +A notification subscription scoped to a specific customer. The subscriber receives notifications for events related to this customer, such as new customer needs or ownership changes. +""" +type CustomerNotificationSubscription implements Entity & Node & NotificationSubscription { + """ + Whether the subscription is active. When inactive, no notifications are generated from this subscription even though it still exists. + """ + active: Boolean! + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The type of contextual view (e.g., active issues, backlog) that further scopes a team notification subscription. Null if the subscription is not associated with a specific view type. + """ + contextViewType: ContextViewType + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The custom view that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + customView: CustomView + """ + The customer subscribed to. + """ + customer: Customer! + """ + The cycle that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + cycle: Cycle + """ + The unique identifier of the entity. + """ + id: ID! + """ + Whether initiative update notifications also include updates from sub-initiatives. Applies only when initiative updates are enabled and the workspace supports sub-initiatives. + """ + includeSubInitiativeUpdates: Boolean! + """ + The initiative that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + initiative: Initiative + """ + The issue label that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + label: IssueLabel + """ + The notification event types that this subscription will deliver to the subscriber. + """ + notificationSubscriptionTypes: [String!]! + """ + The project that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + project: Project + """ + The user who will receive notifications from this subscription. + """ + subscriber: User! + """ + The team that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + team: Team + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The user that this notification subscription is scoped to, for user-specific view subscriptions. Null if the subscription targets a different entity type. + """ + user: User + """ + The type of user-specific view that further scopes a user notification subscription. Null if the subscription is not associated with a user view type. + """ + userContextViewType: UserContextViewType +} + +""" +Return type for customer mutations. +""" +type CustomerPayload { + """ + The customer entity that was created or updated by the mutation. + """ + customer: Customer! + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Issue customer revenue sorting options. +""" +input CustomerRevenueSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +Issue customer sorting options. +""" +input CustomerSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +Customer sorting options. +""" +input CustomerSortInput { + """ + Sort by approximate customer need count + """ + approximateNeedCount: ApproximateNeedCountSort + """ + Sort by customer creation date + """ + createdAt: CustomerCreatedAtSort + """ + Sort by name + """ + name: NameSort + """ + Sort by owner name + """ + owner: OwnerSort + """ + Sort by customer generated revenue + """ + revenue: RevenueSort + """ + Sort by customer size + """ + size: SizeSort + """ + Sort by customer status + """ + status: CustomerStatusSort + """ + Sort by customer tier + """ + tier: TierSort +} + +""" +A workspace-defined lifecycle status for customers (e.g., Active, Churned, Trial). Customer statuses are ordered by position and displayed with a color in the UI. Every workspace has at least one status, and a default status is assigned to new customers when none is specified. +""" +type CustomerStatus implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The color of the status indicator in the UI, as a HEX string (e.g., '#ff0000'). + """ + color: String! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + An optional description explaining what this status represents in the customer lifecycle. + """ + description: String + """ + The user-facing display name of the status shown in the UI. Defaults to the internal name if not explicitly set. + """ + displayName: String! + """ + The unique identifier of the entity. + """ + id: ID! + """ + The internal name of the status. Used as the default display name if no displayName is explicitly set. + """ + name: String! + """ + The sort position of the status in the workspace's customer lifecycle flow. Lower values appear first. Collisions are automatically resolved by redistributing positions. + """ + position: Float! + """ + [Deprecated] The type of the customer status. Always returns null as statuses are no longer grouped by type. + """ + type: CustomerStatusType @deprecated(reason: "Customer statuses are no longer grouped by type.") + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +""" +Certain properties of a customer status. +""" +type CustomerStatusChildWebhookPayload { + """ + The color of the customer status. + """ + color: String! + """ + The description of the customer status. + """ + description: String + """ + The display name of the customer status. + """ + displayName: String! + """ + The ID of the customer status. + """ + id: String! + """ + The name of the customer status. + """ + name: String! + """ + The type of the customer status. + """ + type: String @deprecated(reason: "Customer statuses are no longer grouped by type.") +} + +type CustomerStatusConnection { + edges: [CustomerStatusEdge!]! + nodes: [CustomerStatus!]! + pageInfo: PageInfo! +} + +""" +Input for creating a customer status in the workspace's customer lifecycle flow. +""" +input CustomerStatusCreateInput { + """ + The color of the status indicator in the UI, as a HEX string (e.g., '#ff0000'). + """ + color: String! + """ + An optional description explaining what this status represents. + """ + description: String + """ + The user-facing display name of the status. At least one of name or displayName must be provided. + """ + displayName: String + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + The internal name of the status. At least one of name or displayName must be provided. + """ + name: String + """ + The sort position of the status in the workspace's customer lifecycle flow. If omitted or colliding, a position is automatically assigned at the end. + """ + position: Float +} + +type CustomerStatusEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: CustomerStatus! +} + +""" +Customer status filtering options. +""" +input CustomerStatusFilter { + """ + Compound filters, all of which need to be matched by the customer status. + """ + and: [CustomerStatusFilter!] + """ + Comparator for the customer status color. + """ + color: StringComparator + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for the customer status description. + """ + description: StringComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Comparator for the customer status name. + """ + name: StringComparator + """ + Compound filters, one of which needs to be matched by the customer status. + """ + or: [CustomerStatusFilter!] + """ + Comparator for the customer status position. + """ + position: NumberComparator + """ + Comparator for the customer status type. + """ + type: StringComparator + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +Return type for customer status mutations. +""" +type CustomerStatusPayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + The customer status entity that was created or updated by the mutation. + """ + status: CustomerStatus! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Customer status sorting options. +""" +input CustomerStatusSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +[DEPRECATED] A type of customer status. +""" +enum CustomerStatusType { + active + inactive +} + +""" +Input for updating an existing customer status. +""" +input CustomerStatusUpdateInput { + """ + The updated color of the status indicator in the UI, as a HEX string. + """ + color: String + """ + The updated description of the status. + """ + description: String + """ + The updated user-facing display name of the status. + """ + displayName: String + """ + The updated internal name of the status. + """ + name: String + """ + The updated sort position of the status in the workspace's customer lifecycle flow. + """ + position: Float +} + +""" +A workspace-defined tier or segment for categorizing customers (e.g., Enterprise, Pro, Free). Customer tiers are used for prioritization and filtering, are ordered by position, and displayed with a color in the UI. Tier names are unique within a workspace. +""" +type CustomerTier implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The color of the tier indicator in the UI, as a HEX string (e.g., '#ff0000'). + """ + color: String! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + An optional description explaining what this tier represents and its intended use for customer segmentation. + """ + description: String + """ + The user-facing display name of the tier shown in the UI. Defaults to the internal name if not explicitly set. + """ + displayName: String! + """ + The unique identifier of the entity. + """ + id: ID! + """ + The internal name of the tier. Must be unique within the workspace. Used as the default display name if no displayName is explicitly set. + """ + name: String! + """ + The sort position of the tier in the workspace's customer tier ordering. Lower values appear first. Collisions are automatically resolved by redistributing positions. + """ + position: Float! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +""" +Certain properties of a customer tier. +""" +type CustomerTierChildWebhookPayload { + """ + The color of the customer tier. + """ + color: String! + """ + The description of the customer tier. + """ + description: String + """ + The display name of the customer tier. + """ + displayName: String! + """ + The ID of the customer tier. + """ + id: String! + """ + The name of the customer tier. + """ + name: String! +} + +type CustomerTierConnection { + edges: [CustomerTierEdge!]! + nodes: [CustomerTier!]! + pageInfo: PageInfo! +} + +""" +Input for creating a customer tier in the workspace's customer tier ordering. +""" +input CustomerTierCreateInput { + """ + The color of the tier indicator in the UI, as a HEX string (e.g., '#ff0000'). + """ + color: String! + """ + An optional description explaining what this tier represents. + """ + description: String + """ + The user-facing display name of the tier. At least one of name or displayName must be provided. + """ + displayName: String + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + The internal name of the tier. Must be unique within the workspace. At least one of name or displayName must be provided. + """ + name: String + """ + The sort position of the tier in the workspace's customer tier ordering. If omitted or colliding, a position is automatically assigned at the end. + """ + position: Float +} + +type CustomerTierEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: CustomerTier! +} + +""" +Customer tier filtering options. +""" +input CustomerTierFilter { + """ + Compound filters, all of which need to be matched by the customer tier. + """ + and: [CustomerTierFilter!] + """ + Comparator for the customer tier color. + """ + color: StringComparator + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for the customer tier description. + """ + description: StringComparator + """ + Comparator for the customer tier display name. + """ + displayName: StringComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Compound filters, one of which needs to be matched by the customer tier. + """ + or: [CustomerTierFilter!] + """ + Comparator for the customer tier position. + """ + position: NumberComparator + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +Return type for customer tier mutations. +""" +type CustomerTierPayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! + """ + The customer tier entity that was created or updated by the mutation. + """ + tier: CustomerTier! +} + +""" +Input for updating an existing customer tier. +""" +input CustomerTierUpdateInput { + """ + The updated color of the tier indicator in the UI, as a HEX string. + """ + color: String + """ + The updated description of the tier. + """ + description: String + """ + The updated user-facing display name of the tier. + """ + displayName: String + """ + The updated internal name of the tier. + """ + name: String + """ + The updated sort position of the tier in the workspace's customer tier ordering. + """ + position: Float +} + +""" +Input for updating an existing customer. +""" +input CustomerUpdateInput { + """ + The updated list of email domains associated with this customer. Replaces the existing domains. + """ + domains: [String!] + """ + The updated list of external system identifiers for this customer. New IDs will be appended with source metadata. + """ + externalIds: [String!] + """ + The URL of the customer's logo image. + """ + logoUrl: String + """ + The primary external source ID for customers with multiple sources. Must be one of the values in externalIds. + """ + mainSourceId: String + """ + The updated name of the customer. + """ + name: String + """ + The identifier of the user to assign as the owner of the customer. + """ + ownerId: String + """ + The annual revenue generated by the customer, in dollars. + """ + revenue: Int + """ + The size of the customer organization (e.g., number of employees). + """ + size: Int + """ + The ID of the Slack channel to link to this customer. Set to null to unlink the current channel. + """ + slackChannelId: String + """ + The identifier of the customer status to set. + """ + statusId: String + """ + The identifier of the customer tier to assign. + """ + tierId: String +} + +""" +Input for upserting a customer. Matches against existing customers using id, externalId, slackChannelId, or domains. Creates a new customer if no match is found. +""" +input CustomerUpsertInput { + """ + The email domains associated with this customer. + """ + domains: [String!] + """ + An external system identifier for this customer. Used for matching existing customers during upsert. + """ + externalId: String + """ + The identifier in UUID v4 format. Used to match an existing customer for upsert. + """ + id: String + """ + The URL of the customer's logo image. + """ + logoUrl: String + """ + The name of the customer. Required when creating a new customer. + """ + name: String + """ + The identifier of the user to assign as the owner of the customer. + """ + ownerId: String + """ + The annual revenue generated by the customer, in dollars. + """ + revenue: Int + """ + The size of the customer organization (e.g., number of employees). + """ + size: Int + """ + The ID of the Slack channel to link to this customer. + """ + slackChannelId: String + """ + The identifier of the customer status to set. + """ + statusId: String + """ + The identifier of the customer tier to assign. Cannot be used together with tierName. + """ + tierId: String + """ + The name of the customer tier to assign. A new tier will be created if one with this name does not exist. Cannot be used together with tierId. + """ + tierName: String +} + +""" +Mode that controls who can see and set Customers in Slack Asks. +""" +enum CustomerVisibilityMode { + LinearOnly + SlackMembers + SlackMembersAndGuests +} + +""" +Payload for a customer webhook. +""" +type CustomerWebhookPayload { + """ + The approximate number of distinct requests associated with this customer, deduplicated per issue or project. This is a denormalized counter and may not reflect the exact count at all times. + """ + approximateNeedCount: Float! + """ + The time at which the entity was archived. + """ + archivedAt: String + """ + The time at which the entity was created. + """ + createdAt: String! + """ + The domains associated with this customer. + """ + domains: [String!]! + """ + The ids of the customers in external systems. + """ + externalIds: [String!]! + """ + The ID of the entity. + """ + id: String! + """ + The customer's logo URL. + """ + logoUrl: String + """ + The ID of the main source, when a customer has multiple sources. Must be one of externalIds. + """ + mainSourceId: String + """ + The name of the customer. + """ + name: String! + """ + The ID of the user who owns the customer. + """ + ownerId: String + """ + The annual revenue generated by the customer. + """ + revenue: Float + """ + The size of the customer. + """ + size: Float + """ + The ID of the Slack channel used to interact with the customer. + """ + slackChannelId: String + """ + The customer's unique URL slug. + """ + slugId: String! + """ + The customer status. + """ + status: CustomerStatusChildWebhookPayload + """ + The ID of the customer status. + """ + statusId: String + """ + The customer tier. + """ + tier: CustomerTierChildWebhookPayload + """ + The ID of the customer tier. + """ + tierId: String + """ + The time at which the entity was updated. + """ + updatedAt: String! + """ + The URL of the customer. + """ + url: String! +} + +""" +[Internal] Configuration for the customer attributes data source. +""" +input CustomersAttributesDataSourceConfigurationInput { + """ + [Internal] Whether to allow manual edits to customer attributes when no source is configured. + """ + allowManualEdits: Boolean + """ + [Internal] Errors encountered while syncing customer attributes (set by sync workers). + """ + attributesErrors: JSONObject + """ + [Internal] Mapping from customer attribute keys (owner, revenue, size, status, tier, externalId) to external field IDs. + """ + attributesMapping: JSONObject + """ + [Internal] Integration details (when sourceType is 'integration'). + """ + integration: CustomersAttributesDataSourceIntegrationInput + """ + [Internal] How customer attribute values are sourced: 'manual' or 'integration'. + """ + sourceType: String! +} + +""" +[Internal] Integration providing customer attribute data. +""" +input CustomersAttributesDataSourceIntegrationInput { + """ + [Internal] The integration service that manages customer attributes. + """ + service: IntegrationService! +} + +""" +[Internal] Input for updating workspace Customers feature configuration. +""" +input CustomersConfigurationInput { + """ + [Internal] Configuration for the customer attributes data source. + """ + attributesDataSourceConfiguration: CustomersAttributesDataSourceConfigurationInput + """ + [Internal] The team to use to create default issues for new request items. + """ + defaultTeamId: String + """ + [Internal] Domains or email addresses excluded entirely from the Customers feature. + """ + excludeList: [String!] + """ + [Internal] Domains or email addresses ignored when matching to a customer. + """ + ignoreList: [String!] + """ + [Internal] The currency code used for customer revenue. + """ + revenueCurrencyCode: String + """ + [Internal] How customer revenue should be displayed. + """ + revenueDisplay: String +} + +""" +A time-boxed iteration (similar to a sprint) used for planning and tracking work. Cycles belong to a team and have defined start and end dates. Issues are assigned to cycles for time-based planning, and progress is tracked via completed, in-progress, and total scope. Cycles are automatically completed when their end date passes, and uncompleted issues can be carried over to the next cycle. +""" +type Cycle implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the cycle was automatically archived by the auto-pruning process. Null if the cycle has not been auto-archived. + """ + autoArchivedAt: DateTime + """ + The completion time of the cycle. If null, the cycle has not been completed yet. A cycle is completed either when its end date passes or when it is manually completed early. + """ + completedAt: DateTime + """ + The number of completed issues in the cycle after each day. Each entry corresponds to the same day index as issueCountHistory. + """ + completedIssueCountHistory: [Float!]! + """ + The number of completed estimation points after each day. Used together with scopeHistory for burndown charts. + """ + completedScopeHistory: [Float!]! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + [Internal] The current progress snapshot of the cycle, broken down by issue status categories. + """ + currentProgress: JSONObject! + """ + The description of the cycle. + """ + description: String + """ + [Internal] Documents associated with the cycle. + """ + documents( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned documents. + """ + filter: DocumentFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): DocumentConnection! + """ + The end date and time of the cycle. When a cycle is completed prematurely, this is updated to match the completion time. When cycles are disabled, both endsAt and completedAt are set to the current time. + """ + endsAt: DateTime! + """ + The unique identifier of the entity. + """ + id: ID! + """ + The number of in-progress estimation points after each day. Tracks work that has been started but not yet completed. + """ + inProgressScopeHistory: [Float!]! + """ + The parent cycle this cycle was inherited from. When a parent team creates cycles, sub-teams automatically receive corresponding inherited cycles. + """ + inheritedFrom: Cycle + """ + Whether the cycle is currently active. A cycle is active if the current time is between its start and end dates and it has not been completed. + """ + isActive: Boolean! + """ + Whether the cycle has not yet started. True if the cycle's start date is in the future. + """ + isFuture: Boolean! + """ + Whether this cycle is the next upcoming (not yet started) cycle for the team. + """ + isNext: Boolean! + """ + Whether the cycle's end date has passed. + """ + isPast: Boolean! + """ + Whether this cycle is the most recently completed cycle for the team. + """ + isPrevious: Boolean! + """ + The total number of issues in the cycle after each day. Each entry represents a snapshot at the end of that day, forming the basis for burndown charts. + """ + issueCountHistory: [Float!]! + """ + Issues that are currently assigned to this cycle. + """ + issues( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned issues. + """ + filter: IssueFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): IssueConnection! + """ + [Internal] Links associated with the cycle. + """ + links( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): EntityExternalLinkConnection! + """ + The custom name of the cycle. If not set, the cycle is displayed using its number (e.g., "Cycle 5"). + """ + name: String + """ + The auto-incrementing number of the cycle, unique within its team. This value is assigned automatically by the database and cannot be set on creation. + """ + number: Float! + """ + The overall progress of the cycle as a number between 0 and 1. Calculated as (completed estimate points + 0.25 * in-progress estimate points) / total estimate points. Returns 0 if no estimate points exist. + """ + progress: Float! + """ + [Internal] The detailed progress history of the cycle, including per-status breakdowns over time. + """ + progressHistory: JSONObject! + """ + The total number of estimation points (scope) in the cycle after each day. Used for scope-based burndown charts. + """ + scopeHistory: [Float!]! + """ + The start date and time of the cycle. + """ + startsAt: DateTime! + """ + The team that the cycle belongs to. Each cycle is scoped to exactly one team. + """ + team: Team! + """ + Issues that were still open (not completed) when the cycle was closed. These issues may have been moved to the next cycle. + """ + uncompletedIssuesUponClose( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned issues. + """ + filter: IssueFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): IssueConnection! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +""" +A generic payload return from entity archive mutations. +""" +type CycleArchivePayload implements ArchivePayload { + """ + The archived/unarchived entity. Null if entity was deleted. + """ + entity: Cycle + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Certain properties of a cycle. +""" +type CycleChildWebhookPayload { + """ + The end date of the cycle. + """ + endsAt: String! + """ + The ID of the cycle. + """ + id: String! + """ + The name of the cycle. + """ + name: String + """ + The number of the cycle. + """ + number: Float! + """ + The start date of the cycle. + """ + startsAt: String! +} + +type CycleConnection { + edges: [CycleEdge!]! + nodes: [Cycle!]! + pageInfo: PageInfo! +} + +""" +Input for creating a new cycle. +""" +input CycleCreateInput { + """ + The completion time of the cycle. If null, the cycle hasn't been completed. + """ + completedAt: DateTime + """ + The description of the cycle. + """ + description: String + """ + The end time of the cycle. + """ + endsAt: DateTime! + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + The custom name of the cycle. + """ + name: String + """ + The start time of the cycle. + """ + startsAt: DateTime! + """ + The team to associate the cycle with. + """ + teamId: String! +} + +type CycleEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: Cycle! +} + +""" +Cycle filtering options. +""" +input CycleFilter { + """ + Compound filters, all of which need to be matched by the cycle. + """ + and: [CycleFilter!] + """ + Comparator for the cycle completed at date. + """ + completedAt: DateComparator + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for the cycle ends at date. + """ + endsAt: DateComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Comparator for the inherited cycle ID. + """ + inheritedFromId: IDComparator + """ + Comparator for the filtering active cycle. + """ + isActive: BooleanComparator + """ + Comparator for the filtering future cycles. + """ + isFuture: BooleanComparator + """ + Comparator for filtering for whether the cycle is currently in cooldown. + """ + isInCooldown: BooleanComparator + """ + Comparator for the filtering next cycle. + """ + isNext: BooleanComparator + """ + Comparator for the filtering past cycles. + """ + isPast: BooleanComparator + """ + Comparator for the filtering previous cycle. + """ + isPrevious: BooleanComparator + """ + Filters that the cycles issues must satisfy. + """ + issues: IssueCollectionFilter + """ + Comparator for the cycle name. + """ + name: StringComparator + """ + Comparator for the cycle number. + """ + number: NumberComparator + """ + Compound filters, one of which need to be matched by the cycle. + """ + or: [CycleFilter!] + """ + Comparator for the cycle start date. + """ + startsAt: DateComparator + """ + Filters that the cycles team must satisfy. + """ + team: TeamFilter + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +A notification subscription scoped to a specific cycle. The subscriber receives notifications for events related to issues in this cycle. +""" +type CycleNotificationSubscription implements Entity & Node & NotificationSubscription { + """ + Whether the subscription is active. When inactive, no notifications are generated from this subscription even though it still exists. + """ + active: Boolean! + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The type of contextual view (e.g., active issues, backlog) that further scopes a team notification subscription. Null if the subscription is not associated with a specific view type. + """ + contextViewType: ContextViewType + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The custom view that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + customView: CustomView + """ + The customer that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + customer: Customer + """ + The cycle subscribed to. + """ + cycle: Cycle! + """ + The unique identifier of the entity. + """ + id: ID! + """ + Whether initiative update notifications also include updates from sub-initiatives. Applies only when initiative updates are enabled and the workspace supports sub-initiatives. + """ + includeSubInitiativeUpdates: Boolean! + """ + The initiative that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + initiative: Initiative + """ + The issue label that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + label: IssueLabel + """ + The notification event types that this subscription will deliver to the subscriber. + """ + notificationSubscriptionTypes: [String!]! + """ + The project that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + project: Project + """ + The user who will receive notifications from this subscription. + """ + subscriber: User! + """ + The team that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + team: Team + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The user that this notification subscription is scoped to, for user-specific view subscriptions. Null if the subscription targets a different entity type. + """ + user: User + """ + The type of user-specific view that further scopes a user notification subscription. Null if the subscription is not associated with a user view type. + """ + userContextViewType: UserContextViewType +} + +""" +The payload returned by cycle mutations. +""" +type CyclePayload { + """ + The cycle that was created or updated. + """ + cycle: Cycle + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +enum CyclePeriod { + after + before + during +} + +""" +Comparator for period when issue was added to a cycle. +""" +input CyclePeriodComparator { + """ + Equals constraint. + """ + eq: CyclePeriod + """ + In-array constraint. + """ + in: [CyclePeriod!] + """ + Not-equals constraint. + """ + neq: CyclePeriod + """ + Not-in-array constraint. + """ + nin: [CyclePeriod!] + """ + Null constraint. Matches any non-null values if the given value is false, otherwise it matches null values. + """ + null: Boolean +} + +""" +Input for shifting all cycles from a certain cycle onwards by a certain number of days. +""" +input CycleShiftAllInput { + """ + The number of days to shift the cycles by. + """ + daysToShift: Float! + """ + The cycle ID at which to start the shift. + """ + id: String! +} + +""" +Issue cycle sorting options. +""" +input CycleSort { + """ + When set to true, cycles will be ordered with a custom order. Current cycle comes first, followed by upcoming cycles in ASC order, followed by previous cycles in DESC order. + """ + currentCycleFirst: Boolean = false + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +Input for updating an existing cycle. +""" +input CycleUpdateInput { + """ + The completion time of the cycle. If null, the cycle hasn't been completed. + """ + completedAt: DateTime + """ + The description of the cycle. + """ + description: String + """ + The end time of the cycle. + """ + endsAt: DateTime + """ + The custom name of the cycle. + """ + name: String + """ + The start time of the cycle. + """ + startsAt: DateTime +} + +""" +Payload for a cycle webhook. +""" +type CycleWebhookPayload { + """ + The time at which the entity was archived. + """ + archivedAt: String + """ + The time at which the cycle was automatically archived by the auto pruning process. + """ + autoArchivedAt: String + """ + The completion time of the cycle. If null, the cycle hasn't been completed. + """ + completedAt: String + """ + The number of completed issues in the cycle after each day. + """ + completedIssueCountHistory: [Float!]! + """ + The number of completed estimation points after each day. + """ + completedScopeHistory: [Float!]! + """ + The time at which the entity was created. + """ + createdAt: String! + """ + The cycle's description. + """ + description: String + """ + The end date of the cycle. + """ + endsAt: String! + """ + The ID of the entity. + """ + id: String! + """ + The number of in progress estimation points after each day. + """ + inProgressScopeHistory: [Float!]! + """ + The ID of the cycle inherited from. + """ + inheritedFromId: String + """ + The total number of issues in the cycle after each day. + """ + issueCountHistory: [Float!]! + """ + The name of the cycle. + """ + name: String + """ + The number of the cycle. + """ + number: Float! + """ + The total number of estimation points after each day. + """ + scopeHistory: [Float!]! + """ + The start date of the cycle. + """ + startsAt: String! + """ + The team ID of the cycle. + """ + teamId: String! + """ + The IDs of the uncompleted issues upon close. + """ + uncompletedIssuesUponCloseIds: [String!]! + """ + The time at which the entity was updated. + """ + updatedAt: String! +} + +""" +[Internal] A configurable dashboard composed of widgets that display analytics, metrics, and insights. Dashboards can be personal or shared with the workspace, and optionally scoped to one or more teams. Each dashboard contains a set of widget configurations that define what data is visualized. +""" +type Dashboard implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The hex color code of the dashboard icon. + """ + color: String + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The user who created the dashboard. Null if the creator's account has been deleted. + """ + creator: User + """ + The description of the dashboard. + """ + description: String + """ + The icon of the dashboard. Can be an emoji or a decorative icon identifier. + """ + icon: String + """ + The unique identifier of the entity. + """ + id: ID! + """ + A global issue filter applied to all dashboard widgets that display issue data. Individual widgets may apply additional filters on top of this. + """ + issueFilter: JSONObject + """ + The name of the dashboard. + """ + name: String! + """ + The organization that the dashboard belongs to. + """ + organization: Organization! + """ + The owner of the dashboard. For personal dashboards, only the owner can view them. Null if the owner's account has been deleted. + """ + owner: User + """ + A global project filter applied to all dashboard widgets that display project data. Individual widgets may apply additional filters on top of this. + """ + projectFilter: JSONObject + """ + Whether the dashboard is shared with everyone in the workspace. Shared dashboards are visible to all members; unshared dashboards are only visible to the owner. + """ + shared: Boolean! + """ + The dashboard's unique URL slug, used to construct human-readable URLs. Automatically generated on creation. + """ + slugId: String! + """ + The sort order of the dashboard within the workspace or its team. Lower values appear first. + """ + sortOrder: Float! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The user who last updated the dashboard. Null if no user has updated it or the updater's account has been deleted. + """ + updatedBy: User + """ + The widget configuration for the dashboard, defining the layout grid of rows and the widgets within each row, including their type, size, and data settings. + """ + widgets: JSONObject! +} + +""" +Union type for all possible webhook entity data payloads +""" +union DataWebhookPayload = + | AgentActivityWebhookPayload + | AgentSessionWebhookPayload + | AttachmentWebhookPayload + | AuditEntryWebhookPayload + | CommentWebhookPayload + | CustomerNeedWebhookPayload + | CustomerWebhookPayload + | CycleWebhookPayload + | DocumentWebhookPayload + | InitiativeUpdateWebhookPayload + | InitiativeWebhookPayload + | IssueLabelWebhookPayload + | IssueWebhookPayload + | ProjectLabelWebhookPayload + | ProjectUpdateWebhookPayload + | ProjectWebhookPayload + | ReactionWebhookPayload + | ReleaseNoteWebhookPayload + | ReleaseWebhookPayload + | UserWebhookPayload + +""" +Comparator for dates. +""" +input DateComparator { + """ + Equals constraint. + """ + eq: DateTimeOrDuration + """ + Greater-than constraint. Matches any values that are greater than the given value. + """ + gt: DateTimeOrDuration + """ + Greater-than-or-equal constraint. Matches any values that are greater than or equal to the given value. + """ + gte: DateTimeOrDuration + """ + In-array constraint. + """ + in: [DateTimeOrDuration!] + """ + Less-than constraint. Matches any values that are less than the given value. + """ + lt: DateTimeOrDuration + """ + Less-than-or-equal constraint. Matches any values that are less than or equal to the given value. + """ + lte: DateTimeOrDuration + """ + Not-equals constraint. + """ + neq: DateTimeOrDuration + """ + Not-in-array constraint. + """ + nin: [DateTimeOrDuration!] +} + +""" +By which resolution is a date defined. +""" +enum DateResolutionType { + halfYear + month + quarter + year +} + +""" +Represents a date and time in ISO 8601 format. Accepts shortcuts like `2021` to represent midnight Fri Jan 01 2021. Also accepts ISO 8601 durations strings which are added to the current date to create the represented date (e.g '-P2W1D' represents the date that was two weeks and 1 day ago) +""" +scalar DateTime + +""" +Represents a date and time in ISO 8601 format. Accepts shortcuts like `2021` to represent midnight Fri Jan 01 2021. Also accepts ISO 8601 durations strings which are added to the current date to create the represented date (e.g '-P2W1D' represents the date that was two weeks and 1 day ago) +""" +scalar DateTimeOrDuration + +""" +The day of the week. +""" +enum Day { + Friday + Monday + Saturday + Sunday + Thursday + Tuesday + Wednesday +} + +""" +Issue delegate sorting options. +""" +input DelegateSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +Input for confirming workspace deletion with a verification code. +""" +input DeleteOrganizationInput { + """ + The deletion code to confirm operation. + """ + deletionCode: String! +} + +""" +A generic payload return from entity deletion mutations. +""" +type DeletePayload implements ArchivePayload { + """ + The identifier of the deleted entity. + """ + entityId: String! + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +A package registry a dependency file's packages can be looked up in. +""" +enum DependencyEcosystem { + npm +} + +""" +One package version to look up registry metadata for. +""" +input DependencyPackageInput { + """ + The registry the package comes from. + """ + ecosystem: DependencyEcosystem! + """ + Package name. + """ + name: String! + """ + Package version. + """ + version: String! +} + +""" +Registry metadata for one dependency package version. +""" +type DependencyPackageMetadataResult { + """ + SPDX license identifier. Null if the registry doesn't report one. + """ + license: String + """ + Package name, echoed back from the request. + """ + name: String! + """ + When this version was published. Null if the registry doesn't report it. + """ + publishedAt: DateTime + """ + Package version, echoed back from the request. + """ + version: String! + """ + Weekly download count. Null if the registry doesn't report it. + """ + weeklyDownloads: Float +} + +""" +[Internal] A first-class code diff. Starts as the live working-tree state of a coding session and is promoted to a review by linking it to a pull request, while continuing to represent local, uncommitted changes. +""" +type Diff implements Node { + """ + [Internal] The total number of added lines across the diff. + """ + additions: Float! + """ + The agent session the diff belongs to. + """ + agentSession: AgentSession + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + [Internal] The opaque content hash identifying the diff's content in code.storage. + """ + contentHash: String! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The user responsible for the diff. + """ + creator: User + """ + [Internal] The total number of deleted lines across the diff. + """ + deletions: Float! + """ + [Internal] The number of changed files in the diff. + """ + fileCount: Float! + """ + [Internal] Per-file metadata for the diff. Served behind a repository-read-access gate (the synced row carries only aggregate counts); null when the requester lacks repository access or the diff is empty. + """ + files: [DiffFile!] + """ + The unique identifier of the entity. + """ + id: ID! + """ + The workspace the diff belongs to. + """ + organization: Organization! + """ + The pull request the diff was promoted to when opened for review. + """ + pullRequest: PullRequest + """ + [Internal] The diff's unique URL slug. + """ + slugId: String! + """ + [Internal] Whether oversized files were omitted when the diff was computed. + """ + truncated: Boolean! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +""" +[Internal] One changed file in a diff. +""" +type DiffFile { + """ + Lines added in this file. + """ + additions: Int! + """ + Lines removed in this file. + """ + deletions: Int! + """ + Previous path, when the file was renamed or copied. + """ + oldPath: String + """ + True when the file's diff was omitted for exceeding the size budget; its contents are not shown. + """ + omitted: Boolean + """ + Path of the changed file (the new path, for renames). + """ + path: String! + """ + The kind of change for this file. + """ + state: DiffFileState! +} + +""" +[Internal] The kind of change for a file in a diff. +""" +enum DiffFileState { + added + copied + deleted + modified + renamed + type_changed + unknown + unmerged +} + +""" +A rich-text document that lives within a project, initiative, team, issue, release, or cycle. Documents support collaborative editing via ProseMirror/Yjs and store their content in a separate DocumentContent entity. Each document is associated with exactly one parent entity. +""" +type Document implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The hex color of the document icon. Null if no custom color has been set. + """ + color: String + """ + Comments associated with the document. + """ + comments( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned comments. + """ + filter: CommentFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): CommentConnection! + """ + The document's content in markdown format. + """ + content: String + """ + [Internal] The document's content as a base64-encoded Yjs state update. + """ + contentState: String + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The user who created the document. Null if the creator's account has been deleted. + """ + creator: User + """ + [Internal] The cycle that the document is associated with. Null if the document belongs to a different parent entity type. + """ + cycle: Cycle + """ + The ID of the document content associated with the document. + """ + documentContentId: String + """ + The time at which the document was hidden from the default view. Null if the document has not been hidden. + """ + hiddenAt: DateTime + """ + The icon of the document, either a decorative icon type or an emoji string. Null if no icon has been set. + """ + icon: String + """ + The unique identifier of the entity. + """ + id: ID! + """ + The initiative that the document is associated with. Null if the document belongs to a different parent entity type. + """ + initiative: Initiative + """ + The issue that the document is associated with. Null if the document belongs to a different parent entity type. + """ + issue: Issue + """ + The last template that was applied to this document. Null if no template has been applied. + """ + lastAppliedTemplate: Template + """ + The owner of the document. Null if no owner is assigned or the owner's account has been deleted. + """ + owner: User + """ + [Internal] The parent document. Null if the document is not a sub-document. + """ + parentDocument: Document + """ + The project that the document is associated with. Null if the document belongs to a different parent entity type. + """ + project: Project + """ + The release that the document is associated with. Null if the document belongs to a different parent entity type. + """ + release: Release + """ + The document's unique URL slug, used to construct human-readable URLs. + """ + slugId: String! + """ + The sort order of the document in its parent entity's resources list. This order is shared with other resource types such as external links. + """ + sortOrder: Float! + """ + [Internal] The sort order of the sub-document among its siblings. Null if the document is not a sub-document. + """ + subDocumentSortOrder: Float + """ + Users who are subscribed to the document. + """ + subscribers( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned subscribers. + """ + filter: UserFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + Should query return disabled/suspended users (default: false). + """ + includeDisabled: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): UserConnection! + """ + [Internal] A one-sentence AI-generated summary of the document content. Null if no summary has been generated. + """ + summary: String + """ + [Internal] The team that the document is associated with. Null if the document belongs to a different parent entity type. + """ + team: Team + """ + The title of the document. An empty string indicates an untitled document. + """ + title: String! + """ + A flag that indicates whether the document is in the trash bin. Trashed documents are archived and can be restored. + """ + trashed: Boolean + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The user who last updated the document. Null if the user's account has been deleted. + """ + updatedBy: User + """ + The canonical url for the document. + """ + url: String! +} + +""" +A generic payload return from entity archive mutations. +""" +type DocumentArchivePayload implements ArchivePayload { + """ + The archived/unarchived entity. Null if entity was deleted. + """ + entity: Document + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Certain properties of a document. +""" +type DocumentChildWebhookPayload { + """ + The ID of the document. + """ + id: String! + """ + The initiative this document belongs to. + """ + initiative: InitiativeChildWebhookPayload + """ + The ID of the initiative this document belongs to. + """ + initiativeId: String + """ + The project this document belongs to. + """ + project: ProjectChildWebhookPayload + """ + The ID of the project this document belongs to. + """ + projectId: String + """ + The title of the document. + """ + title: String! +} + +type DocumentConnection { + edges: [DocumentEdge!]! + nodes: [Document!]! + pageInfo: PageInfo! +} + +""" +The rich-text content body of a document, issue, project, initiative, project milestone, pull request, release note, automation prompt, AI prompt rules, welcome message, or workspace announcement. Content is stored as a base64-encoded Yjs state and can be converted to Markdown or ProseMirror JSON. Each DocumentContent belongs to exactly one parent entity and supports real-time collaborative editing. +""" +type DocumentContent implements Node { + """ + The AI prompt rules that the content is associated with. Null if the content belongs to a different parent entity type. + """ + aiPromptRules: AiPromptRules + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The document content in markdown format. This is a derived representation of the canonical Yjs content state. + """ + content: String + """ + The document content state as a base64-encoded Yjs state update. This is the canonical representation of the document content used for collaborative editing. + """ + contentState: String + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The document that the content is associated with. Null if the content belongs to a different parent entity type. + """ + document: Document + """ + The unique identifier of the entity. + """ + id: ID! + """ + The initiative that the content is associated with. Null if the content belongs to a different parent entity type. + """ + initiative: Initiative + """ + The issue that the content is associated with. Null if the content belongs to a different parent entity type. + """ + issue: Issue + """ + [Internal] The meeting that the content is associated with. Null if the content belongs to a different parent entity type. + """ + meeting: Meeting + """ + The project that the content is associated with. Null if the content belongs to a different parent entity type. + """ + project: Project + """ + The project milestone that the content is associated with. Null if the content belongs to a different parent entity type. + """ + projectMilestone: ProjectMilestone + """ + [Internal] The pull request that the content is associated with. Null if the content belongs to a different parent entity type. + """ + pullRequest: PullRequest + """ + The time at which the document content was restored from a previous version in the content history. Null if the content has never been restored. + """ + restoredAt: DateTime + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The welcome message that the content is associated with. Null if the content belongs to a different parent entity type. + """ + welcomeMessage: WelcomeMessage +} + +""" +Whether the checkpoint belongs to a draft-only or live document agent flow. +""" +enum DocumentContentAgentCheckpointMode { + draft + live +} + +""" +Certain properties of a document content. +""" +type DocumentContentChildWebhookPayload { + """ + The document this document content belongs to. + """ + document: DocumentChildWebhookPayload + """ + The project this document belongs to. + """ + project: ProjectChildWebhookPayload +} + +""" +A draft revision of document content, pending user review. Each user can have at most one draft per document content. Drafts are seeded from the live document state and stored as base64-encoded Yjs state updates, allowing independent editing without affecting the published document until the user explicitly applies their changes. +""" +type DocumentContentDraft implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The draft content state as a base64-encoded Yjs state update. This represents the user's in-progress edits that have not yet been applied to the live document. + """ + contentState: String! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The document content that this draft is a revision of. + """ + documentContent: DocumentContent! + """ + The identifier of the document content that this draft is a revision of. + """ + documentContentId: String! + """ + The unique identifier of the entity. + """ + id: ID! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The user who created or owns this draft. + """ + user: User! + """ + The identifier of the user who owns this draft. + """ + userId: String! +} + +""" +[Internal] An AI-authored checkpoint row included in the document content history timeline. +""" +type DocumentContentHistoryCheckpointType { + """ + The identifier of the AI conversation that created this checkpoint. + """ + aiConversationId: String! + """ + The identifier of the AI conversation turn that created this checkpoint. + """ + aiConversationTurnId: String! + """ + The time at which the document content state was captured for this checkpoint. + """ + contentDataSnapshotAt: DateTime! + """ + The time when this AI document checkpoint record was created. + """ + createdAt: DateTime! + """ + The unique identifier of the AI document checkpoint. + """ + id: String! + """ + The identifier of the user who invoked the AI checkpoint. + """ + invokedByUserId: String + """ + Whether this checkpoint is the active head for its conversation branch and mode. + """ + isActive: Boolean! + """ + Whether this checkpoint belongs to draft-only or live document content. + """ + mode: DocumentContentAgentCheckpointMode! + """ + [Internal] Source metadata associated with the AI document checkpoint. + """ + sourceMetadata: JSONObject +} + +type DocumentContentHistoryPayload { + """ + The document content history entries. + """ + history: [DocumentContentHistoryType!]! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +[Internal] The fresh document content history timeline used by the client history dialog. +""" +type DocumentContentHistoryTimelinePayload { + """ + Visible live AI document checkpoints for the same document content. + """ + checkpoints: [DocumentContentHistoryCheckpointType!]! + """ + The document content history entries. + """ + history: [DocumentContentHistoryType!]! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +type DocumentContentHistoryType { + """ + IDs of users whose edits are included in this history entry. + """ + actorIds: [String!] + """ + [Internal] The document content as a ProseMirror document at the time this history entry was captured. + """ + contentData: JSONObject + """ + The timestamp of the document content state when this snapshot was captured. This can differ from createdAt because the content is captured from its state at the previously known updatedAt timestamp in the case of an update. On document creation, these timestamps can be identical. + """ + contentDataSnapshotAt: DateTime! + """ + The date when this document content history entry record was created. + """ + createdAt: DateTime! + """ + The identifier of the document content that this history entry snapshots. + """ + documentContentId: String! + """ + The unique identifier of the document content history entry. + """ + id: String! + """ + Metadata associated with the history entry, including content diffs and AI-generated change summaries. + """ + metadata: JSONObject +} + +""" +A pending revision of document content. Revisions are seeded from the live document state and stored as base64-encoded Yjs state updates, allowing automation edits to accumulate without affecting the published document until the changes are explicitly applied. +""" +type DocumentContentRevision implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The live document content state this revision was last refreshed from, as a base64-encoded Yjs state update. + """ + baseContentState: String! + """ + Hash of the revision state that should be summarized. + """ + contentHash: String + """ + The pending revision content state as a base64-encoded Yjs state update. This represents the revision that has not yet been applied to the live document. + """ + contentState: String! + """ + The workflow definitions that contributed edits to this revision. + """ + contributorWorkflowDefinitionIds: [String!]! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The document content that this revision is based on. + """ + documentContent: DocumentContent! + """ + The identifier of the document content that this revision is based on. + """ + documentContentId: String! + """ + The unique identifier of the entity. + """ + id: ID! + """ + A short summary of the pending revision changes. + """ + summary: String + """ + Hash of the revision state that the summary describes. + """ + summaryContentHash: String + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +""" +Input for creating a new document. +""" +input DocumentCreateInput { + """ + The color of the icon. + """ + color: String + """ + The document content as markdown. + """ + content: String + """ + [Internal] Related cycle for the document. + """ + cycleId: String + """ + The icon of the document. + """ + icon: String + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + [Internal] Related initiative for the document. Can be a UUID or initiative identifier (e.g., 'I-12'). + """ + initiativeId: String + """ + Related issue for the document. Can be a UUID or issue identifier (e.g., 'LIN-123'). + """ + issueId: String + """ + The ID of the last template applied to the document. + """ + lastAppliedTemplateId: String + """ + The owner of the document. Set to null to create a document without an owner. + """ + ownerId: String + """ + [Internal] The parent document of the sub-document. The container of the document must match the container of the parent document. + """ + parentDocumentId: String + """ + Related project for the document. Can be a UUID or project identifier (e.g., 'P-LIN-123'). + """ + projectId: String + """ + Related release for the document. + """ + releaseId: String + """ + [Internal] The resource folder containing the document. + """ + resourceFolderId: String + """ + The order of the item in the resources list. + """ + sortOrder: Float + """ + [Internal] The sort order of the sub-document among its siblings. Defaults to the last position. Requires `parentDocumentId`. + """ + subDocumentSortOrder: Float + """ + [INTERNAL] The identifiers of the users subscribing to this document. + """ + subscriberIds: [String!] + """ + [Internal] Related team for the document. + """ + teamId: String + """ + The title of the document. + """ + title: String! +} + +""" +Document creation date sorting options. +""" +input DocumentCreatedAtSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +Document creator sorting options. +""" +input DocumentCreatorSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +type DocumentEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: Document! +} + +""" +Document filtering options. +""" +input DocumentFilter { + """ + Compound filters, all of which need to be matched by the document. + """ + and: [DocumentFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Filters that the document's creator must satisfy. + """ + creator: UserFilter + """ + Filters that the document's cycle must satisfy. + """ + cycle: CycleFilter + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Filters that the document's initiative must satisfy. + """ + initiative: InitiativeFilter + """ + Filters that the document's issue must satisfy. + """ + issue: IssueFilter + """ + Compound filters, one of which need to be matched by the document. + """ + or: [DocumentFilter!] + """ + Filters that the document's owner must satisfy. + """ + owner: NullableUserFilter + """ + Filters that the document's project must satisfy. + """ + project: ProjectFilter + """ + Filters that the document's release must satisfy. + """ + release: ReleaseFilter + """ + [Internal] Comparator for the document's searchable content. + """ + searchableContent: ContentComparator + """ + Comparator for the document slug ID. + """ + slugId: StringComparator + """ + Filters that the document's team must satisfy. + """ + team: NullableTeamFilter + """ + Comparator for the document title. + """ + title: StringComparator + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +A notification related to a document, such as comments, mentions, content changes, or document lifecycle events. +""" +type DocumentNotification implements Entity & Node & Notification { + """ + The user that caused the notification. Null if the notification was triggered by a non-user actor such as an integration, external user, or system event. + """ + actor: User + """ + [Internal] Notification actor initials if avatar is not available. + """ + actorAvatarColor: String! + """ + [Internal] Notification avatar URL. + """ + actorAvatarUrl: String + """ + [Internal] Whether the notification's user actor is deactivated in the workspace. + """ + actorInactive: Boolean! + """ + [Internal] Notification actor initials if avatar is not available. + """ + actorInitials: String + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The bot that caused the notification. + """ + botActor: ActorBot + """ + The category of the notification. + """ + category: NotificationCategory! + """ + Related comment ID. Null if the notification is not related to a comment. + """ + commentId: String + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + Related document ID. + """ + documentId: String! + """ + The time at which an email reminder for this notification was sent to the user. Null if no email reminder has been sent. + """ + emailedAt: DateTime + """ + The external user that caused the notification. Populated when the notification was triggered by an external user (e.g., a commenter from a connected integration like Slack or GitHub) rather than a Linear workspace member. + """ + externalUserActor: ExternalUser + """ + [Internal] Notifications with the same grouping key will be grouped together in the UI. + """ + groupingKey: String! + """ + [Internal] Priority of the notification with the same grouping key. Higher number means higher priority. If priority is the same, notifications should be sorted by `createdAt`. + """ + groupingPriority: Float! + """ + The unique identifier of the entity. + """ + id: ID! + """ + [Internal] Inbox URL for the notification. + """ + inboxUrl: String! + """ + [Internal] Initiative update health for new updates. + """ + initiativeUpdateHealth: String + """ + [Internal] If notification actor was Linear. + """ + isLinearActor: Boolean! + """ + [Internal] Issue's status type for issue notifications. + """ + issueStatusType: String + """ + Related parent comment ID. Null if the notification is not related to a comment. + """ + parentCommentId: String + """ + [Internal] Project update health for new updates. + """ + projectUpdateHealth: String + """ + Name of the reaction emoji related to the notification. + """ + reactionEmoji: String + """ + The time at which the user marked the notification as read. Null if the notification is unread. + """ + readAt: DateTime + """ + The time until which a notification is snoozed. After this time, the notification reappears in the user's inbox. Null if the notification is not currently snoozed. + """ + snoozedUntilAt: DateTime + """ + [Internal] Notification subtitle. + """ + subtitle: String! + """ + [Internal] Notification title. + """ + title: String! + """ + Notification type. Determines the kind of event that triggered this notification and which associated entity fields will be populated. + """ + type: String! + """ + The time at which a notification was unsnoozed. Null if the notification has not been unsnoozed. + """ + unsnoozedAt: DateTime + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + [Internal] URL to the target of the notification. + """ + url: String! + """ + The recipient user of this notification. + """ + user: User! +} + +""" +The result of a document mutation. +""" +type DocumentPayload { + """ + The document that was created or updated. + """ + document: Document! + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Document project sorting options. +""" +input DocumentProjectSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +type DocumentSearchPayload { + """ + Archived entities matching the search term along with all their dependencies, serialized for the client sync engine. + """ + archivePayload: ArchiveResponse! + edges: [DocumentSearchResultEdge!]! + nodes: [DocumentSearchResult!]! + pageInfo: PageInfo! + """ + Total number of matching results before pagination is applied. + """ + totalCount: Float! +} + +type DocumentSearchResult implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The hex color of the document icon. Null if no custom color has been set. + """ + color: String + """ + Comments associated with the document. + """ + comments( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned comments. + """ + filter: CommentFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): CommentConnection! + """ + The document's content in markdown format. + """ + content: String + """ + [Internal] The document's content as a base64-encoded Yjs state update. + """ + contentState: String + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The user who created the document. Null if the creator's account has been deleted. + """ + creator: User + """ + [Internal] The cycle that the document is associated with. Null if the document belongs to a different parent entity type. + """ + cycle: Cycle + """ + The ID of the document content associated with the document. + """ + documentContentId: String + """ + The time at which the document was hidden from the default view. Null if the document has not been hidden. + """ + hiddenAt: DateTime + """ + The icon of the document, either a decorative icon type or an emoji string. Null if no icon has been set. + """ + icon: String + """ + The unique identifier of the entity. + """ + id: ID! + """ + The initiative that the document is associated with. Null if the document belongs to a different parent entity type. + """ + initiative: Initiative + """ + The issue that the document is associated with. Null if the document belongs to a different parent entity type. + """ + issue: Issue + """ + The last template that was applied to this document. Null if no template has been applied. + """ + lastAppliedTemplate: Template + """ + Metadata related to search result. + """ + metadata: JSONObject! + """ + The owner of the document. Null if no owner is assigned or the owner's account has been deleted. + """ + owner: User + """ + [Internal] The parent document. Null if the document is not a sub-document. + """ + parentDocument: Document + """ + The project that the document is associated with. Null if the document belongs to a different parent entity type. + """ + project: Project + """ + The release that the document is associated with. Null if the document belongs to a different parent entity type. + """ + release: Release + """ + The document's unique URL slug, used to construct human-readable URLs. + """ + slugId: String! + """ + The sort order of the document in its parent entity's resources list. This order is shared with other resource types such as external links. + """ + sortOrder: Float! + """ + [Internal] The sort order of the sub-document among its siblings. Null if the document is not a sub-document. + """ + subDocumentSortOrder: Float + """ + Users who are subscribed to the document. + """ + subscribers( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned subscribers. + """ + filter: UserFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + Should query return disabled/suspended users (default: false). + """ + includeDisabled: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): UserConnection! + """ + [Internal] A one-sentence AI-generated summary of the document content. Null if no summary has been generated. + """ + summary: String + """ + [Internal] The team that the document is associated with. Null if the document belongs to a different parent entity type. + """ + team: Team + """ + The title of the document. An empty string indicates an untitled document. + """ + title: String! + """ + A flag that indicates whether the document is in the trash bin. Trashed documents are archived and can be restored. + """ + trashed: Boolean + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The user who last updated the document. Null if the user's account has been deleted. + """ + updatedBy: User + """ + The canonical url for the document. + """ + url: String! +} + +type DocumentSearchResultEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: DocumentSearchResult! +} + +""" +[Internal] The role of a user a personal document is shared with. +""" +enum DocumentShareRole { + """ + The user can read and comment on the document but not edit it. + """ + comment + """ + The user can read, edit, and comment on the document. + """ + edit + """ + The user can read the document but not edit or comment on it. + """ + view +} + +""" +Document sorting options. +""" +input DocumentSortInput { + """ + Sort by document creation date. + """ + createdAt: DocumentCreatedAtSort + """ + Sort by the document's creator (author). + """ + creator: DocumentCreatorSort + """ + Sort by the document's parent project name. + """ + project: DocumentProjectSort + """ + Sort by document title. + """ + title: DocumentTitleSort + """ + Sort by document last-updated date. + """ + updatedAt: DocumentUpdatedAtSort +} + +""" +Document title sorting options. +""" +input DocumentTitleSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +Input for updating an existing document. +""" +input DocumentUpdateInput { + """ + The color of the icon. + """ + color: String + """ + The document content as markdown. + """ + content: String + """ + [Internal] Related cycle for the document. + """ + cycleId: String + """ + The time at which the document was hidden. Set to null to unhide. + """ + hiddenAt: DateTime + """ + The icon of the document. + """ + icon: String + """ + [Internal] Related initiative for the document. Can be a UUID or initiative identifier (e.g., 'I-12'). + """ + initiativeId: String + """ + Related issue for the document. Can be a UUID or issue identifier (e.g., 'LIN-123'). + """ + issueId: String + """ + The ID of the last template applied to the document. + """ + lastAppliedTemplateId: String + """ + The owner of the document. Set to null to clear. + """ + ownerId: String + """ + [Internal] The parent document of the sub-document. The document and its sub-documents move to the container of the parent document. Set to null to make the document a top-level document in its container. + """ + parentDocumentId: String + """ + [Internal] Moves the document and its sub-documents into this user's personal space. Must be the acting user. + """ + personalUserId: String + """ + Related project for the document. Can be a UUID or project identifier (e.g., 'P-LIN-123'). + """ + projectId: String + """ + Related release for the document. + """ + releaseId: String + """ + [Internal] The resource folder containing the document. + """ + resourceFolderId: String + """ + The order of the item in the resources list. + """ + sortOrder: Float + """ + [Internal] The sort order of the sub-document among its siblings. + """ + subDocumentSortOrder: Float + """ + [INTERNAL] The identifiers of the users subscribing to this document. + """ + subscriberIds: [String!] + """ + [Internal] Related team for the document. + """ + teamId: String + """ + The title of the document. + """ + title: String + """ + Whether the document has been trashed. Set to true to trash, or null to restore from trash. + """ + trashed: Boolean +} + +""" +Document update date sorting options. +""" +input DocumentUpdatedAtSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +Payload for a document webhook. +""" +type DocumentWebhookPayload { + """ + The time at which the entity was archived. + """ + archivedAt: String + """ + The color of the document. + """ + color: String + """ + The content of the document. + """ + content: String + """ + The time at which the entity was created. + """ + createdAt: String! + """ + The ID of the user who created the document. + """ + creatorId: String + """ + The description of the document. + """ + description: String + """ + The time at which the document was hidden. + """ + hiddenAt: String + """ + The icon of the document. + """ + icon: String + """ + The ID of the entity. + """ + id: String! + """ + The ID of the initiative this document belongs to. + """ + initiativeId: String + """ + The ID of the last template that was applied to this document. + """ + lastAppliedTemplateId: String + """ + The ID of the project this document belongs to. + """ + projectId: String + """ + The ID of the resource folder this document belongs to. + """ + resourceFolderId: String + """ + The document's unique URL slug. + """ + slugId: String! + """ + The order of the item in the resources list. + """ + sortOrder: Float! + """ + The IDs of the users who are subscribed to this document. + """ + subscriberIds: [String!] + """ + The title of the document. + """ + title: String! + """ + A flag that indicates whether the document is in the trash bin. + """ + trashed: Boolean + """ + The time at which the entity was updated. + """ + updatedAt: String! + """ + The ID of the user who last updated the document. + """ + updatedById: String +} + +""" +A general-purpose draft for unsaved content. Drafts store in-progress text for comments, project updates, initiative updates, posts, pull request comments, and customer needs. Each draft belongs to a user and is associated with exactly one parent entity. Drafts are automatically deleted when the user publishes the corresponding comment or update. +""" +type Draft implements Node { + """ + [INTERNAL] Allows for multiple drafts per entity (currently constrained to Pull Requests). + """ + anchor: String + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The draft text content as a ProseMirror document. + """ + bodyData: JSON! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The customer need that this draft is referencing. Null if the draft belongs to a different parent entity type. + """ + customerNeed: CustomerNeed + """ + Additional properties for the draft, such as generation metadata for AI-generated drafts, health status for project updates, or post titles. + """ + data: JSONObject + """ + Metadata about the AI generation of the draft. Null when the draft was not auto-generated. This is a computed field derived from 'data', so clients can read the generation metadata without parsing that payload. + """ + generationMetadata: DraftGenerationMetadata + """ + The unique identifier of the entity. + """ + id: ID! + """ + The initiative for which this is a draft comment or initiative update. Null if the draft belongs to a different parent entity type. + """ + initiative: Initiative + """ + The initiative update for which this is a draft comment. Null if the draft belongs to a different parent entity type. + """ + initiativeUpdate: InitiativeUpdate + """ + Whether the draft was autogenerated for the user. + """ + isAutogenerated: Boolean! @deprecated(reason: "Use 'generationMetadata' instead") + """ + The issue for which this is a draft comment. Null if the draft belongs to a different parent entity type. + """ + issue: Issue + """ + The parent comment for which this is a draft reply. Null if the draft is a top-level comment or belongs to a different parent entity type. + """ + parentComment: Comment + """ + The post for which this is a draft comment. Null if the draft belongs to a different parent entity type. + """ + post: Post + """ + The project for which this is a draft comment or project update. Null if the draft belongs to a different parent entity type. + """ + project: Project + """ + The project update for which this is a draft comment. Null if the draft belongs to a different parent entity type. + """ + projectUpdate: ProjectUpdate + """ + The pull request for which this is a draft comment. Null if the draft belongs to a different parent entity type. + """ + pullRequest: PullRequest + """ + The team for which this is a draft post. Null if the draft belongs to a different parent entity type. + """ + team: Team + """ + The health status carried by a project update or initiative update draft. Possible values are onTrack, atRisk, or offTrack. Null for other draft types. This is a computed field derived from 'data', so clients can read the health without parsing that payload. + """ + updateHealth: DraftUpdateHealthType + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The user who created the draft. + """ + user: User! + """ + [INTERNAL] Whether the draft was ported from a local draft. + """ + wasLocalDraft: Boolean! +} + +type DraftConnection { + edges: [DraftEdge!]! + nodes: [Draft!]! + pageInfo: PageInfo! +} + +type DraftEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: Draft! +} + +""" +Metadata about AI-generated draft content. +""" +type DraftGenerationMetadata { + """ + The time at which the draft content was generated. + """ + generatedAt: DateTime! + """ + The generated text content as a ProseMirror document. + """ + generatedContent: JSONObject! + """ + The number of times the draft content has been generated. + """ + generationCount: Int! +} + +""" +The health status carried by a project update or initiative update draft. +""" +enum DraftUpdateHealthType { + atRisk + offTrack + onTrack +} + +""" +Issue due date sorting options. +""" +input DueDateSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +Represents a duration in ISO 8601 format. Accepts ISO 8601 duration strings or integers in milliseconds. +""" +scalar Duration + +""" +An email address that creates Linear issues when emails are sent to it. Email intake addresses can be scoped to a specific team or issue template, and support configurable auto-reply messages for issue creation, completion, and cancellation events. They can also be configured for the Asks web form feature, enabling external users to submit requests via email. +""" +type EmailIntakeAddress implements Node { + """ + The unique local part (before the @) of the intake email address, used to route incoming emails to the correct intake handler. + """ + address: String! + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The user who created the email intake address. + """ + creator: User + """ + Whether issues created from emails sent to this address are automatically converted into customer requests, linking the sender as a customer contact. + """ + customerRequestsEnabled: Boolean! + """ + Whether the email address is enabled. + """ + enabled: Boolean! + """ + The email address used to forward emails to the intake address. + """ + forwardingEmailAddress: String + """ + The unique identifier of the entity. + """ + id: ID! + """ + The auto-reply message for issue canceled. If not set, the default reply will be used. + """ + issueCanceledAutoReply: String + """ + Whether the auto-reply for issue canceled is enabled. + """ + issueCanceledAutoReplyEnabled: Boolean! + """ + The auto-reply message for issue completed. If not set, the default reply will be used. + """ + issueCompletedAutoReply: String + """ + Whether the auto-reply for issue completed is enabled. + """ + issueCompletedAutoReplyEnabled: Boolean! + """ + The auto-reply message for issue created. If not set, the default reply will be used. + """ + issueCreatedAutoReply: String + """ + Whether the auto-reply for issue created is enabled. + """ + issueCreatedAutoReplyEnabled: Boolean! + """ + The last time an inbound email was successfully ingested for this address. + """ + lastUsedAt: DateTime + """ + The workspace that the email address is associated with. + """ + organization: Organization! + """ + Whether to reopen completed or canceled issues when a substantive email reply is received. + """ + reopenOnReply: Boolean! + """ + Whether email replies are enabled. + """ + repliesEnabled: Boolean! + """ + The name to be used for outgoing emails. + """ + senderName: String + """ + The SES domain identity that the email address is associated with. + """ + sesDomainIdentity: SesDomainIdentity + """ + The team that the email address is associated with. + """ + team: Team + """ + The template that the email address is associated with. + """ + template: Template + """ + The type of the email address. + """ + type: EmailIntakeAddressType! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + Whether the commenter's name is included in the email replies. + """ + useUserNamesInReplies: Boolean! +} + +""" +Input for creating a new email intake address. +""" +input EmailIntakeAddressCreateInput { + """ + Whether customer requests are enabled. + """ + customerRequestsEnabled: Boolean + """ + The email address used to forward emails to the intake address. + """ + forwardingEmailAddress: String + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + The auto-reply message for issue canceled. + """ + issueCanceledAutoReply: String + """ + Whether the issue canceled auto-reply is enabled. + """ + issueCanceledAutoReplyEnabled: Boolean + """ + The auto-reply message for issue completed. + """ + issueCompletedAutoReply: String + """ + Whether the issue completed auto-reply is enabled. + """ + issueCompletedAutoReplyEnabled: Boolean + """ + The auto-reply message for issue created. + """ + issueCreatedAutoReply: String + """ + Whether the issue created auto-reply is enabled. + """ + issueCreatedAutoReplyEnabled: Boolean + """ + Whether to reopen completed or canceled issues when a substantive email reply is received. + """ + reopenOnReply: Boolean + """ + Whether email replies are enabled. + """ + repliesEnabled: Boolean + """ + The name to be used for outgoing emails. + """ + senderName: String + """ + The identifier or key of the team this email address will intake issues for. + """ + teamId: String + """ + The identifier of the template this email address will intake issues for. + """ + templateId: String + """ + The type of the email address. If not provided, the backend will default to team or template. + """ + type: EmailIntakeAddressType + """ + Whether the commenter's name is included in the email replies. + """ + useUserNamesInReplies: Boolean +} + +""" +The result of an email intake address mutation. +""" +type EmailIntakeAddressPayload { + """ + The email address that was created or updated. + """ + emailIntakeAddress: EmailIntakeAddress! + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +The result of requesting an on-demand SES domain status refresh. +""" +type EmailIntakeAddressRefreshSesDomainStatusPayload { + """ + Whether an on-demand status check was requested. + """ + success: Boolean! +} + +""" +The type of the email address. +""" +enum EmailIntakeAddressType { + asks + asksWeb + team + template +} + +""" +Input for updating an existing email intake address. +""" +input EmailIntakeAddressUpdateInput { + """ + Whether customer requests are enabled. + """ + customerRequestsEnabled: Boolean + """ + Whether the email address is currently enabled. If set to false, the email address will be disabled and no longer accept incoming emails. + """ + enabled: Boolean + """ + The email address used to forward emails to the intake address. + """ + forwardingEmailAddress: String + """ + Custom auto-reply message for issue canceled. + """ + issueCanceledAutoReply: String + """ + Whether the issue canceled auto-reply is enabled. + """ + issueCanceledAutoReplyEnabled: Boolean + """ + Custom auto-reply message for issue completed. + """ + issueCompletedAutoReply: String + """ + Whether the issue completed auto-reply is enabled. + """ + issueCompletedAutoReplyEnabled: Boolean + """ + The auto-reply message for issue created. + """ + issueCreatedAutoReply: String + """ + Whether the issue created auto-reply is enabled. + """ + issueCreatedAutoReplyEnabled: Boolean + """ + Whether to reopen completed or canceled issues when a substantive email reply is received. + """ + reopenOnReply: Boolean + """ + Whether email replies are enabled. + """ + repliesEnabled: Boolean + """ + The name to be used for outgoing emails. + """ + senderName: String + """ + The identifier or key of the team this email address will intake issues for. + """ + teamId: String + """ + The identifier of the template this email address will intake issues for. + """ + templateId: String + """ + Whether the commenter's name is included in the email replies. + """ + useUserNamesInReplies: Boolean +} + +""" +Input for unsubscribing a user from a specific email notification type. +""" +input EmailUnsubscribeInput { + """ + The user's email validation token. + """ + token: String! + """ + Email type to unsubscribe from. + """ + type: String! + """ + The identifier of the user. + """ + userId: String! +} + +""" +The result of an email unsubscribe mutation. +""" +type EmailUnsubscribePayload { + """ + Whether the operation was successful. + """ + success: Boolean! +} + +input EmailUserAccountAuthChallengeInput { + """ + Response from the login challenge. + """ + challengeResponse: String + """ + Auth code for the client initiating the sequence. + """ + clientAuthCode: String + """ + The email for which to generate the magic login code. + """ + email: String! + """ + The workspace invite link to associate with this authentication. + """ + inviteLink: String + """ + Whether the login was requested from the desktop app. + """ + isDesktop: Boolean + """ + Whether to only return the login code. This is used by mobile apps to skip showing the login link. + """ + loginCodeOnly: Boolean + """ + PostHog session ID for attribution tracking. + """ + sessionId: String +} + +type EmailUserAccountAuthChallengeResponse { + """ + Supported challenge for this user account. Can be either verificationCode or password. + """ + authType: String! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +A custom emoji defined in the workspace. Custom emojis are uploaded by users and can be used in reactions and other places where standard emojis are supported. Each emoji has a unique name within the workspace. +""" +type Emoji implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The user who created the emoji. + """ + creator: User + """ + The unique identifier of the entity. + """ + id: ID! + """ + The unique name of the custom emoji within the workspace. + """ + name: String! + """ + The workspace that the emoji belongs to. + """ + organization: Organization! + """ + The source of the emoji, indicating how it was created (e.g., uploaded by a user or imported). + """ + source: String! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The URL of the uploaded image for this custom emoji. + """ + url: String! +} + +type EmojiConnection { + edges: [EmojiEdge!]! + nodes: [Emoji!]! + pageInfo: PageInfo! +} + +""" +Input for creating a new custom emoji. +""" +input EmojiCreateInput { + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + The name of the custom emoji. + """ + name: String! + """ + The URL for the emoji. + """ + url: String! +} + +""" +Emoji creation date sorting options. +""" +input EmojiCreatedAtSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +type EmojiEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: Emoji! +} + +""" +Custom emoji filtering options. +""" +input EmojiFilter { + """ + Compound filters, all of which need to be matched by the emoji. + """ + and: [EmojiFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Comparator for the emoji name. + """ + name: StringComparator + """ + Compound filters, one of which needs to be matched by the emoji. + """ + or: [EmojiFilter!] + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +The result of a custom emoji mutation. +""" +type EmojiPayload { + """ + The emoji that was created. + """ + emoji: Emoji! + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Custom emoji sorting options. +""" +input EmojiSortInput { + """ + Sort by emoji creation date. + """ + createdAt: EmojiCreatedAtSort +} + +""" +A basic entity. +""" +interface Entity implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The unique identifier of the entity. + """ + id: ID! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +""" +Union type for webhook actor payloads +""" +union EntityActorWebhookPayload = + | ExternalUserActorWebhookPayload + | IntegrationActorWebhookPayload + | OauthClientActorWebhookPayload + | UserActorWebhookPayload + +""" +An external link attached to a Linear entity such as an initiative, project, team, release, or cycle. External links provide a way to reference related resources outside of Linear (e.g., documentation, design files, dashboards) directly from the entity's resources section. Each link has a URL, display label, and sort order within its parent entity. +""" +type EntityExternalLink implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The user who created the link. + """ + creator: User + """ + The unique identifier of the entity. + """ + id: ID! + """ + The initiative that the link is associated with. + """ + initiative: Initiative + """ + The link's label. + """ + label: String! + """ + The project that the link is associated with. + """ + project: Project + """ + The sort order of this link within the parent entity's resources list. Links are sorted together with documents and other resources attached to the entity. + """ + sortOrder: Float! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The link's URL. + """ + url: String! +} + +type EntityExternalLinkConnection { + edges: [EntityExternalLinkEdge!]! + nodes: [EntityExternalLink!]! + pageInfo: PageInfo! +} + +""" +Input for creating a new external link on an entity. A URL, label, and exactly one parent entity (initiative, project, team, release, or cycle) are required. +""" +input EntityExternalLinkCreateInput { + """ + [Internal] The cycle associated with the link. + """ + cycleId: String + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + The initiative associated with the link. Can be a UUID or initiative identifier (e.g., 'I-12'). + """ + initiativeId: String + """ + The label for the link. + """ + label: String! + """ + The project associated with the link. Can be a UUID or project identifier (e.g., 'P-LIN-123'). + """ + projectId: String + """ + The release associated with the link. + """ + releaseId: String + """ + [Internal] The resource folder containing the link. + """ + resourceFolderId: String + """ + The order of the item in the entities resources list. + """ + sortOrder: Float + """ + [Internal] The team associated with the link. + """ + teamId: String + """ + The URL of the link. + """ + url: String! +} + +type EntityExternalLinkEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: EntityExternalLink! +} + +""" +The result of an entity external link mutation. +""" +type EntityExternalLinkPayload { + """ + The link that was created or updated. + """ + entityExternalLink: EntityExternalLink! + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Input for updating an existing external link. All fields are optional; only provided fields will be updated. +""" +input EntityExternalLinkUpdateInput { + """ + The label for the link. + """ + label: String + """ + [Internal] The resource folder containing the link. + """ + resourceFolderId: String + """ + The order of the item in the entities resources list. + """ + sortOrder: Float + """ + The URL of the link. + """ + url: String +} + +""" +Comparator for project and initiative identifiers. Accepts UUIDs and human-readable identifiers (e.g. "PROJ-123"). +""" +input EntityIdentifierIDComparator { + """ + Equals constraint. + """ + eq: ID + """ + In-array constraint. + """ + in: [ID!] + """ + Not-equals constraint. + """ + neq: ID + """ + Not-in-array constraint. + """ + nin: [ID!] +} + +""" +Payload for entity-related webhook events. +""" +type EntityWebhookPayload { + """ + The type of action that triggered the webhook. + """ + action: String! + """ + The actor who triggered the action. + """ + actor: EntityActorWebhookPayload + """ + The time the payload was created. + """ + createdAt: DateTime! + """ + The entity that was changed. + """ + data: DataWebhookPayload! + """ + ID of the organization for which the webhook belongs to. + """ + organizationId: String! + """ + The type of resource, i.e., the name of the entity. + """ + type: String! + """ + In case of an update event, previous values of all updated properties. + """ + updatedFrom: JSONObject + """ + URL for the entity. + """ + url: String + """ + The ID of the webhook that sent this event. + """ + webhookId: String! + """ + Unix timestamp in milliseconds when the webhook was sent. + """ + webhookTimestamp: Float! +} + +""" +Comparator for estimates. +""" +input EstimateComparator { + """ + Compound filters, one of which need to be matched by the estimate. + """ + and: [NullableNumberComparator!] + """ + Equals constraint. + """ + eq: Float + """ + Greater-than constraint. Matches any values that are greater than the given value. + """ + gt: Float + """ + Greater-than-or-equal constraint. Matches any values that are greater than or equal to the given value. + """ + gte: Float + """ + In-array constraint. + """ + in: [Float!] + """ + Less-than constraint. Matches any values that are less than the given value. + """ + lt: Float + """ + Less-than-or-equal constraint. Matches any values that are less than or equal to the given value. + """ + lte: Float + """ + Not-equals constraint. + """ + neq: Float + """ + Not-in-array constraint. + """ + nin: [Float!] + """ + Null constraint. Matches any non-null values if the given value is false, otherwise it matches null values. + """ + null: Boolean + """ + Compound filters, all of which need to be matched by the estimate. + """ + or: [NullableNumberComparator!] +} + +""" +Issue estimate sorting options. +""" +input EstimateSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +Input for tracking an anonymous analytics event. +""" +input EventTrackingInput { + """ + The event name to track. + """ + event: String! + """ + Optional properties for the event. + """ + properties: JSONObject + """ + Client session ID for PostHog session correlation. + """ + sessionId: String +} + +type EventTrackingPayload { + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Information about an entity in an external system that is linked to a Linear entity. Provides the external ID, the service it belongs to, and optional service-specific metadata. +""" +type ExternalEntityInfo { + """ + The unique identifier of the entity in the external system (e.g., the Jira issue ID, GitHub issue node ID, or Slack message timestamp). + """ + id: String! + """ + Service-specific metadata about the external entity. The concrete type depends on the service (e.g., Jira issue key, GitHub repo and issue number, Slack channel info). Null for entity types that do not have additional metadata. + """ + metadata: ExternalEntityInfoMetadata + """ + The external service that this entity belongs to (e.g., jira, github, slack). + """ + service: ExternalSyncService! +} + +""" +Metadata about the external GitHub entity. +""" +type ExternalEntityInfoGithubMetadata { + """ + The number of the issue. + """ + number: Float + """ + The owner of the repository. + """ + owner: String + """ + The repository name. + """ + repo: String +} + +""" +Metadata about the external Jira entity. +""" +type ExternalEntityInfoJiraMetadata { + """ + The key of the Jira issue. + """ + issueKey: String + """ + The id of the Jira issue type. + """ + issueTypeId: String + """ + The id of the Jira project. + """ + projectId: String +} + +union ExternalEntityInfoMetadata = + | ExternalEntityInfoGithubMetadata + | ExternalEntityInfoJiraMetadata + | ExternalEntitySlackMetadata + +""" +Metadata about the external Slack entity. +""" +type ExternalEntitySlackMetadata { + """ + The id of the Slack channel. + """ + channelId: String + """ + The name of the Slack channel. + """ + channelName: String + """ + Whether the entity originated from Slack (not Linear). + """ + isFromSlack: Boolean! + """ + The URL of the Slack message. + """ + messageUrl: String +} + +""" +The service that syncs an external entity to Linear. +""" +enum ExternalSyncService { + github + jira + slack +} + +""" +An external user who interacts with Linear through an integrated external service (such as Slack, Jira, GitHub, GitLab, Salesforce, or Microsoft Teams) but does not have a Linear account. External users can create issues, post comments, and add reactions from their respective platforms. They are identified by service-specific user IDs and may optionally have an email address. External users are scoped to a single workspace. +""" +type ExternalUser implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + A URL to the external user's avatar image. Null if no avatar is available from the external service. + """ + avatarUrl: String + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The external user's display name. Unique within each workspace. Can match the display name of an actual user. + """ + displayName: String! + """ + The external user's email address. + """ + email: String + """ + The unique identifier of the entity. + """ + id: ID! + """ + The last time the external user was seen interacting with Linear through their external service. Defaults to the creation time and is updated on subsequent interactions. + """ + lastSeen: DateTime + """ + The external user's full name. + """ + name: String! + """ + The workspace that the external user belongs to. + """ + organization: Organization! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +""" +External user actor payload for webhooks. +""" +type ExternalUserActorWebhookPayload { + """ + The email of the external user. + """ + email: String! + """ + The ID of the external user. + """ + id: String! + """ + The name of the external user. + """ + name: String! + """ + The type of actor. + """ + type: String! +} + +""" +Certain properties of an external user. +""" +type ExternalUserChildWebhookPayload { + """ + The email of the external user. + """ + email: String! + """ + The ID of the external user. + """ + id: String! + """ + The name of the external user. + """ + name: String! +} + +type ExternalUserConnection { + edges: [ExternalUserEdge!]! + nodes: [ExternalUser!]! + pageInfo: PageInfo! +} + +type ExternalUserEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: ExternalUser! +} + +""" +A facet representing a join between entities. Facets connect a custom view to an owning entity such as a project, initiative, team page, workspace page, or user feed. They control the order of views within their parent via the sortOrder field. Exactly one source entity and one target entity must be set. +""" +type Facet implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The unique identifier of the entity. + """ + id: ID! + """ + The sort order of the facet within its owning entity scope. Lower values appear first. Sort order is scoped by the source entity (e.g., all facets on a project are sorted independently from facets on an initiative). + """ + sortOrder: Float! + """ + The user whose feed this facet belongs to. Set when this facet represents a view in a user's personal feed. + """ + sourceFeedUser: User + """ + The owning initiative. Set when this facet represents a view tab on an initiative. + """ + sourceInitiative: Initiative + """ + The owning organization. Set for workspace-level facets that are not scoped to a specific team, project, or initiative. + """ + sourceOrganization: Organization + """ + The fixed page type (e.g., projects, issues) that this facet is displayed on. Used together with sourceOrganizationId or sourceTeamId to place a view on a specific page at the workspace or team level. + """ + sourcePage: FacetPageSource + """ + The owning project. Set when this facet represents a view tab on a project. + """ + sourceProject: Project + """ + The owning team. Set when this facet represents a view on a team-level page. + """ + sourceTeam: Team + """ + The custom view that this facet points to. Each facet targets exactly one custom view, establishing a one-to-one relationship. + """ + targetCustomView: CustomView + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +type FacetConnection { + edges: [FacetEdge!]! + nodes: [Facet!]! + pageInfo: PageInfo! +} + +type FacetEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: Facet! +} + +enum FacetPageSource { + feed + initiatives + projects + teamIssues +} + +""" +A user's bookmarked item that appears in their sidebar for quick access. Favorites can reference various entity types including issues, projects, cycles, views, documents, initiatives, labels, users, customers, dashboards, pull requests, and Agent conversations. Favorites can be organized into folders and ordered by the user. Each favorite is owned by a single user and links to exactly one target entity (or is a folder containing other favorites). +""" +type Favorite implements Node { + """ + [INTERNAL] The favorited Agent conversation. + """ + aiConversation: AiConversation + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + Children of the favorite. Only applies to favorites of type folder. + """ + children( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): FavoriteConnection! + """ + [Internal] Returns the color of the favorite's icon. Unavailable for avatars and views with fixed icons (e.g. cycle). + """ + color: String + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The favorited custom view. + """ + customView: CustomView + """ + The favorited customer. + """ + customer: Customer + """ + The favorited cycle. + """ + cycle: Cycle + """ + The favorited dashboard. + """ + dashboard: Dashboard + """ + [Internal] Detail text for favorite's `title` (e.g. team's name for a project). + """ + detail: String + """ + The favorited document. + """ + document: Document + """ + [INTERNAL] The favorited facet. + """ + facet: Facet + """ + The name of the folder. Only applies to favorites of type folder. + """ + folderName: String + """ + [Internal] Name of the favorite's icon. Unavailable for standard views, issues, and avatars + """ + icon: String + """ + The unique identifier of the entity. + """ + id: ID! + """ + The favorited initiative. + """ + initiative: Initiative + """ + [INTERNAL] The favorited initiative label. + """ + initiativeLabel: InitiativeLabel + """ + The targeted tab of the initiative. + """ + initiativeTab: InitiativeTab + """ + The favorited issue. + """ + issue: Issue + """ + The favorited label. + """ + label: IssueLabel + """ + The versioned lazy root and filter represented by this live favorite folder. + """ + liveFolderDefinition: JSONObject + """ + The predefined live folder represented by this favorite. + """ + liveFolderPreset: String + """ + The user who owns this favorite. Favorites are personal and only visible to their owner. + """ + owner: User! + """ + The parent folder of the favorite. Null if the favorite is at the top level of the sidebar. Only favorites of type 'folder' can be parents. + """ + parent: Favorite + """ + The targeted tab of the release pipeline. + """ + pipelineTab: PipelineTab + """ + The team of the favorited predefined view. + """ + predefinedViewTeam: Team + """ + The type of favorited predefined view (e.g., 'allIssues', 'activeCycle', 'backlog', 'triage'). Only populated when the favorite type is 'predefinedView'. + """ + predefinedViewType: String + """ + The favorited project. + """ + project: Project + """ + The favorited project label. + """ + projectLabel: ProjectLabel + """ + The targeted tab of the project. + """ + projectTab: ProjectTab + """ + [DEPRECATED] The favorited team of the project. + """ + projectTeam: Team + """ + The favorited pull request. + """ + pullRequest: PullRequest + """ + The favorited release. + """ + release: Release + """ + The favorited release note. + """ + releaseNote: ReleaseNote + """ + The favorited release pipeline. + """ + releasePipeline: ReleasePipeline + """ + The position of this item in the user's favorites list. Lower values appear first. Used to maintain user-defined ordering within the sidebar. + """ + sortOrder: Float! + """ + The favorited team. + """ + team: Team + """ + [Internal] Favorite's title text (name of the favorite'd object or folder). + """ + title: String! + """ + The type of entity this favorite references, such as 'issue', 'project', 'cycle', 'customView', 'document', 'folder', etc. Determines which associated entity field is populated. + """ + type: String! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + URL of the favorited entity. Folders return 'null' value. + """ + url: String + """ + The favorited user. + """ + user: User + """ + The favorited loop. + """ + workflowDefinition: WorkflowDefinition +} + +type FavoriteConnection { + edges: [FavoriteEdge!]! + nodes: [Favorite!]! + pageInfo: PageInfo! +} + +""" +Input for creating a favorite. Exactly one target entity must be specified (e.g., issueId, projectId, customViewId, folderName, etc.). +""" +input FavoriteCreateInput { + """ + [INTERNAL] The identifier of the Agent conversation to favorite. + """ + aiConversationId: String + """ + The identifier of the custom view to favorite. + """ + customViewId: String + """ + The identifier of the customer to favorite. + """ + customerId: String + """ + The identifier of the cycle to favorite. + """ + cycleId: String + """ + The identifier of the dashboard to favorite. + """ + dashboardId: String + """ + The identifier of the document to favorite. + """ + documentId: String + """ + The identifier of the facet to favorite. + """ + facetId: String + """ + The name of the favorite folder. + """ + folderName: String + """ + The identifier. If none is provided, the backend will generate one. + """ + id: String + """ + [INTERNAL] The identifier of the initiative to favorite. + """ + initiativeId: String + """ + [INTERNAL] The identifier of the initiative label to favorite. + """ + initiativeLabelId: String + """ + The tab of the initiative to favorite. + """ + initiativeTab: InitiativeTab + """ + The identifier of the issue to favorite. Can be a UUID or issue identifier (e.g., 'LIN-123'). + """ + issueId: String + """ + The identifier of the label to favorite. + """ + labelId: String + """ + The predefined live folder to create. + """ + liveFolderPreset: String + """ + The parent folder of the favorite. + """ + parentId: String + """ + The tab of the release pipeline to favorite. + """ + pipelineTab: PipelineTab + """ + The identifier of team for the predefined view to favorite. + """ + predefinedViewTeamId: String + """ + The type of the predefined view to favorite. + """ + predefinedViewType: String + """ + The identifier of the project to favorite. + """ + projectId: String + """ + The identifier of the project label to favorite. + """ + projectLabelId: String + """ + The tab of the project to favorite. + """ + projectTab: ProjectTab + """ + The identifier of the pull request to favorite. + """ + pullRequestId: String + """ + The identifier of the release to favorite. + """ + releaseId: String + """ + The identifier of the release note to favorite. + """ + releaseNoteId: String + """ + The identifier of the release pipeline to favorite. + """ + releasePipelineId: String + """ + The position of the item in the favorites list. + """ + sortOrder: Float + """ + The identifier of the team to favorite. + """ + teamId: String + """ + The identifier of the user to favorite. + """ + userId: String + """ + The identifier of the loop to favorite. + """ + workflowDefinitionId: String +} + +type FavoriteEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: Favorite! +} + +""" +Return type for favorite mutations. +""" +type FavoritePayload { + """ + The favorite that was created or updated. + """ + favorite: Favorite! + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Input for updating a favorite's position, parent folder, or folder name. +""" +input FavoriteUpdateInput { + """ + The name of the favorite folder. + """ + folderName: String + """ + The identifier (in UUID v4 format) of the folder to move the favorite under. + """ + parentId: String + """ + The position of the item in the favorites list. + """ + sortOrder: Float +} + +""" +[Internal] An item in a user's activity feed. Feed items represent project updates, initiative updates, or posts that appear in a user's personalized feed based on their team memberships and feed subscriptions. Each feed item references exactly one content entity. Feed items older than 6 months are automatically archived. +""" +type FeedItem implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The unique identifier of the entity. + """ + id: ID! + """ + The initiative update referenced by this feed item. Null if the feed item references a different content type. + """ + initiativeUpdate: InitiativeUpdate + """ + The organization this feed item belongs to. + """ + organization: Organization! + """ + The post referenced by this feed item. Null if the feed item references a different content type. + """ + post: Post + """ + The project update referenced by this feed item. Null if the feed item references a different content type. + """ + projectUpdate: ProjectUpdate + """ + The team this feed item is associated with. Null if the feed item is not team-scoped. + """ + team: Team + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The specific user this feed item is targeted to. Null if the feed item is targeted to a team or organization rather than an individual user. + """ + user: User +} + +type FeedItemConnection { + edges: [FeedItemEdge!]! + nodes: [FeedItem!]! + pageInfo: PageInfo! +} + +type FeedItemEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: FeedItem! +} + +""" +Feed item filtering options +""" +input FeedItemFilter { + """ + Compound filters, all of which need to be matched by the feed item. + """ + and: [FeedItemFilter!] + """ + Filters that the feed item author must satisfy. + """ + author: UserFilter + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Compound filters, one of which need to be matched by the feed item. + """ + or: [FeedItemFilter!] + """ + Filters that the feed item's project update must satisfy. + """ + projectUpdate: ProjectUpdateFilter + """ + Filters that the related feed item initiatives must satisfy. + """ + relatedInitiatives: InitiativeCollectionFilter + """ + Filters that the related feed item team must satisfy. + """ + relatedTeams: TeamCollectionFilter + """ + Comparator for the project or initiative update health: onTrack, atRisk, offTrack + """ + updateHealth: StringComparator + """ + Comparator for the update type: initiative, project, team + """ + updateType: StringComparator + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +Cadence to generate feed summary +""" +enum FeedSummarySchedule { + daily + never + weekly +} + +type FileUploadDeletePayload { + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +By which resolution is frequency defined. +""" +enum FrequencyResolutionType { + daily + weekly +} + +""" +The result of a Front attachment mutation. +""" +type FrontAttachmentPayload { + """ + The issue attachment that was created. + """ + attachment: Attachment! + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +input FrontSettingsInput { + """ + Whether a ticket should be automatically reopened when its linked Linear issue is canceled. + """ + automateTicketReopeningOnCancellation: Boolean + """ + Whether a ticket should be automatically reopened when a comment is posted on its linked Linear issue + """ + automateTicketReopeningOnComment: Boolean + """ + Whether a ticket should be automatically reopened when its linked Linear issue is completed. + """ + automateTicketReopeningOnCompletion: Boolean + """ + Whether a ticket should be automatically reopened when its linked Linear project is canceled. + """ + automateTicketReopeningOnProjectCancellation: Boolean + """ + Whether a ticket should be automatically reopened when its linked Linear project is completed. + """ + automateTicketReopeningOnProjectCompletion: Boolean + """ + [ALPHA] Whether customer and customer requests should not be automatically created when conversations are linked to a Linear issue. + """ + disableCustomerRequestsAutoCreation: Boolean + """ + Whether Linear Agent should be enabled for this integration. + """ + enableAiIntake: Boolean + """ + Whether an internal message should be added when someone comments on an issue. + """ + sendNoteOnComment: Boolean + """ + Whether an internal message should be added when a Linear issue changes status (for status types except completed or canceled). + """ + sendNoteOnStatusChange: Boolean +} + +""" +A Git automation rule that automatically transitions issues to a specified workflow state when a Git event occurs (e.g., when a PR is opened, move the linked issue to 'In Review'). Each rule is scoped to a team and optionally to a specific target branch. When no target branch is specified, the rule acts as the default for all branches. Target-branch-specific rules override the defaults. +""" +type GitAutomationState implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + [DEPRECATED] The target branch, if null, the automation will be triggered on any branch. + """ + branchPattern: String @deprecated(reason: "Use targetBranch instead.") + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The Git event that triggers this automation rule (e.g., branch created, PR opened for review, or PR merged). + """ + event: GitAutomationStates! + """ + The unique identifier of the entity. + """ + id: ID! + """ + The workflow state that linked issues will be transitioned to when the Git event fires. Null if this rule is configured to take no action, overriding any default rule for the same event. + """ + state: WorkflowState + """ + The target branch that this automation rule applies to. When set, this rule only fires for pull requests targeting the specified branch pattern, overriding any default rule for the same event. Null if this is a default rule that applies to all branches. + """ + targetBranch: GitAutomationTargetBranch + """ + The team that this automation rule belongs to. Issues must belong to this team for the automation to apply. + """ + team: Team! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +type GitAutomationStateConnection { + edges: [GitAutomationStateEdge!]! + nodes: [GitAutomationState!]! + pageInfo: PageInfo! +} + +""" +Input for creating a new Git automation rule. +""" +input GitAutomationStateCreateInput { + """ + The event that triggers the automation. + """ + event: GitAutomationStates! + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + The associated workflow state. If null, will override default behaviour and take no action. + """ + stateId: String + """ + The associated target branch. If null, all branches are targeted. + """ + targetBranchId: String + """ + The team associated with the automation state. + """ + teamId: String! +} + +type GitAutomationStateEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: GitAutomationState! +} + +""" +The result of a git automation state mutation. +""" +type GitAutomationStatePayload { + """ + The automation state that was created or updated. + """ + gitAutomationState: GitAutomationState! + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Input for updating an existing Git automation rule. +""" +input GitAutomationStateUpdateInput { + """ + The event that triggers the automation. + """ + event: GitAutomationStates + """ + The associated workflow state. + """ + stateId: String + """ + The associated target branch. If null, all branches are targeted. + """ + targetBranchId: String +} + +""" +The Git events that can trigger an automation rule. Each value corresponds to a pull/merge request lifecycle event (e.g., branch created, PR opened for review, PR merged). +""" +enum GitAutomationStates { + draft + merge + mergeable + review + start +} + +""" +A target branch definition used by Git automation rules to scope automations to specific branches. The branch can be specified as an exact name (e.g., 'main') or as a regular expression pattern (e.g., 'release/.*'). Each target branch belongs to a team and can have multiple automation rules associated with it, which override the team's default automation rules when a PR targets a matching branch. +""" +type GitAutomationTargetBranch implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + Git automation rules associated with this target branch. These rules override the team's default automation rules when a pull request targets a branch matching this pattern. + """ + automationStates( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): GitAutomationStateConnection! + """ + The branch name or pattern to match against pull request target branches. Interpreted as a literal branch name unless isRegex is true, in which case it is treated as a regular expression. + """ + branchPattern: String! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The unique identifier of the entity. + """ + id: ID! + """ + Whether the branch pattern should be interpreted as a regular expression. When false, the pattern is matched as an exact branch name. + """ + isRegex: Boolean! + """ + The team that this target branch definition belongs to. The branch pattern is unique within a team. + """ + team: Team! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +""" +Input for creating a new Git target branch definition. +""" +input GitAutomationTargetBranchCreateInput { + """ + The target branch pattern. + """ + branchPattern: String! + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + Whether the branch pattern is a regular expression. + """ + isRegex: Boolean = false + """ + The team associated with the Git target branch automation. + """ + teamId: String! +} + +""" +The result of a git automation target branch mutation. +""" +type GitAutomationTargetBranchPayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! + """ + The Git target branch automation that was created or updated. + """ + targetBranch: GitAutomationTargetBranch! +} + +""" +Input for updating an existing Git target branch definition. +""" +input GitAutomationTargetBranchUpdateInput { + """ + The target branch pattern. + """ + branchPattern: String + """ + Whether the branch pattern is a regular expression. + """ + isRegex: Boolean +} + +type GitHubCommitIntegrationPayload { + """ + GitHub-specific details for the operation. Populated by GitHub-related mutations only. + """ + gitHub: GitHubIntegrationConnectDetails + """ + The integration that was created or updated. + """ + integration: Integration + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! + """ + The webhook secret to provide to GitHub. + """ + webhookSecret: String! +} + +type GitHubEnterpriseServerInstallVerificationPayload { + """ + Has the install been successful. + """ + success: Boolean! +} + +type GitHubEnterpriseServerPayload { + """ + GitHub-specific details for the operation. Populated by GitHub-related mutations only. + """ + gitHub: GitHubIntegrationConnectDetails + """ + The app install address. + """ + installUrl: String! + """ + The integration that was created or updated. + """ + integration: Integration + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + The setup address. + """ + setupUrl: String! + """ + Whether the operation was successful. + """ + success: Boolean! + """ + The webhook secret to provide to GitHub. + """ + webhookSecret: String! +} + +input GitHubImportSettingsInput { + """ + A map storing all available issue labels per repository + """ + labels: JSONObject + """ + The avatar URL for the GitHub organization. + """ + orgAvatarUrl: String! + """ + The GitHub organization's name. + """ + orgLogin: String! + """ + The type of Github org + """ + orgType: GithubOrgType! + """ + The names of the repositories connected for the GitHub integration. + """ + repositories: [GitHubRepoInput!]! + """ + The date the repository list was last loaded from GitHub. Unset while the first load is still in progress. + """ + repositoriesSyncedAt: DateTime + """ + The number of repositories the installation can access, as reported by GitHub. Known before the repository list itself has loaded. + """ + repositoryCount: Float +} + +""" +GitHub-specific details that some integration mutations may return alongside the standard payload. Populated only by GitHub-related mutations. +""" +type GitHubIntegrationConnectDetails { + """ + Full names ('owner/repo') of repositories whose existing GitHub Issues sync mappings would become inaccessible if the new GitHub App installation replaces the existing one. When non-empty the connect was halted; the client should surface the impact and re-call the mutation with `confirmReplace: true` to commit, or do nothing to leave the integration unchanged. Capped at a small constant; longer lists are truncated. + """ + lostRepositoryNames: [String!] +} + +input GitHubPersonalSettingsInput { + """ + The GitHub user's name. + """ + login: String! +} + +""" +Instruction for the client after attempting to remove code access from a GitHub integration. +""" +enum GitHubRemoveCodeAccessAction { + Done + InstallBasicApp +} + +input GitHubRepoInput { + """ + Whether the repository is archived. + """ + archived: Boolean + """ + The repository's GitHub description, if any. + """ + description: String + """ + The external identifier (GitHub node ID) for the repository. + """ + externalId: String + """ + The full name of the repository. + """ + fullName: String! + """ + The GitHub repo id. + """ + id: Float! +} + +input GitHubRepoMappingInput { + """ + Whether Linear-created issues matching this mapping will create GitHub issues. + """ + bidirectional: Boolean + """ + Whether this mapping is the default destination for Linear-created issues that do not match a label-filtered mapping. + """ + default: Boolean + """ + Label names used as a creation filter. When set, only issues matching one of these labels will create a synced issue for this mapping. + """ + gitHubLabels: [String!] + """ + The GitHub repo id. + """ + gitHubRepoId: Float! + """ + The unique identifier for this mapping. + """ + id: String! + """ + The Linear team id to map to the GitHub repository. + """ + linearTeamId: String! +} + +input GitHubSettingsInput { + """ + Whether the integration has code access + """ + codeAccess: Boolean + """ + The enterprise URL if this is a GitHub Enterprise Cloud integration. + """ + enterpriseUrl: String + """ + The stable external identifier (GitHub node ID) for the organization. + """ + externalOrgId: String + """ + The avatar URL for the GitHub organization. + """ + orgAvatarUrl: String + """ + The GitHub organization's name. + """ + orgLogin: String! + """ + The type of Github org + """ + orgType: GithubOrgType + """ + The names of the repositories connected for the GitHub integration. + """ + repositories: [GitHubRepoInput!] + """ + Mapping of team to repository for syncing. + """ + repositoriesMapping: [GitHubRepoMappingInput!] +} + +type GitLabIntegrationCreatePayload { + """ + Error message if the connection failed. + """ + error: String + """ + Method and post-encoding upstream URI of the failed request, for debugging proxy allowlist rules (e.g. `GET /api/v4/projects/aire%2Fagents`). + """ + errorRequest: String + """ + Response body from GitLab for debugging. + """ + errorResponseBody: String + """ + Response headers from GitLab for debugging (JSON stringified). + """ + errorResponseHeaders: String + """ + GitHub-specific details for the operation. Populated by GitHub-related mutations only. + """ + gitHub: GitHubIntegrationConnectDetails + """ + The integration that was created or updated. + """ + integration: Integration + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! + """ + The webhook secret to provide to GitLab. + """ + webhookSecret: String! +} + +input GitLabSettingsInput { + """ + Whether the token supports self-rotation. + """ + canSelfRotate: Boolean + """ + The ISO timestamp the GitLab access token expires. + """ + expiresAt: String + """ + The ISO timestamp of the last successful token rotation. + """ + lastRotatedAt: String + """ + The ISO timestamp of the next automatic token rotation. + """ + nextRotationAt: String + """ + Whether the token is limited to a read-only scope. + """ + readonly: Boolean + """ + Whether Linear automatically rotates the token. + """ + rotationEnabled: Boolean + """ + The reason token rotation needs attention. + """ + rotationFailureReason: String + """ + Verified scopes of the GitLab access token. + """ + scopes: [String!] + """ + The self-hosted URL of the GitLab instance. + """ + url: String + """ + When true, MR webhook PR sync uses the project-scoped REST aggregator instead of GraphQL. Set automatically for teleport-routed installations whose proxies require all upstream paths to live under `/api/v4/projects/...`. + """ + useRestPrSync: Boolean + """ + Path or numeric ID of a project to use for the setup health check. Set this when the GitLab tenant blocks non-project API endpoints; the setup check then validates against this single project instead of the personal access token endpoint. + """ + validationProjectPath: String +} + +type GitLabTestConnectionPayload { + """ + Error message if the connection test failed. + """ + error: String + """ + Method and post-encoding upstream URI of the failed request, for debugging proxy allowlist rules (e.g. `GET /api/v4/projects/aire%2Fagents`). + """ + errorRequest: String + """ + Response body from GitLab for debugging. + """ + errorResponseBody: String + """ + Response headers from GitLab for debugging (JSON stringified). + """ + errorResponseHeaders: String + """ + GitHub-specific details for the operation. Populated by GitHub-related mutations only. + """ + gitHub: GitHubIntegrationConnectDetails + """ + The integration that was created or updated. + """ + integration: Integration + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +[Internal] The kind of link between an issue and a pull request. +""" +enum GitLinkKind { + closes + contributes + links +} + +enum GithubOrgType { + organization + user +} + +input GongRecordingImportConfigInput { + """ + The team ID to create issues in for imported recordings. Set to null to disable import. + """ + teamId: String +} + +input GongSettingsInput { + """ + Configuration for recording import. + """ + importConfig: GongRecordingImportConfigInput + """ + Whether to tag matching internal Gong call participants as user mentions in created issues. + """ + tagParticipantsInIssues: Boolean +} + +input GoogleSheetsExportSettings { + """ + Whether the export is enabled. + """ + enabled: Boolean + """ + The ID of the target sheet (tab) within the Google Sheet. + """ + sheetId: Float + """ + The ID of the exported Google Sheet. + """ + spreadsheetId: String + """ + The URL of the exported Google Sheet. + """ + spreadsheetUrl: String + """ + The date of the most recent export. + """ + updatedAt: DateTime +} + +input GoogleSheetsSettingsInput { + """ + The export settings for initiatives. + """ + initiative: GoogleSheetsExportSettings + """ + The export settings for issues. + """ + issue: GoogleSheetsExportSettings + """ + The export settings for projects. + """ + project: GoogleSheetsExportSettings + """ + [Deprecated] The ID of the target sheet (tab) within the Google Sheet. + """ + sheetId: Float + """ + [Deprecated] The ID of the exported Google Sheet. + """ + spreadsheetId: String + """ + [Deprecated] The URL of the exported Google Sheet. + """ + spreadsheetUrl: String + """ + [Deprecated] The date of the most recent export. + """ + updatedIssuesAt: DateTime +} + +input GoogleUserAccountAuthInput { + """ + Code returned from Google's OAuth flow. + """ + code: String! + """ + An optional parameter to disable new user signup and force login. Default: false. + """ + disallowSignup: Boolean + """ + An optional invite link for a workspace used to populate available workspaces. + """ + inviteLink: String + """ + The URI to redirect the user to. + """ + redirectUri: String + """ + PostHog session ID for attribution tracking. + """ + sessionId: String + """ + The timezone of the user's browser. + """ + timezone: String! +} + +""" +Union type for all possible guidance rule origins +""" +union GuidanceRuleOriginWebhookPayload = OrganizationOriginWebhookPayload | TeamOriginWebhookPayload + +""" +Metadata for guidance that should be provided to an AI agent. +""" +type GuidanceRuleWebhookPayload { + """ + The content of the guidance as markdown. + """ + body: String! + """ + Where the guidance was defined within the organization. + """ + origin: GuidanceRuleOriginWebhookPayload! +} + +""" +Comparator for identifiers. +""" +input IDComparator { + """ + Equals constraint. + """ + eq: ID + """ + In-array constraint. + """ + in: [ID!] + """ + Not-equals constraint. + """ + neq: ID + """ + Not-in-array constraint. + """ + nin: [ID!] +} + +""" +A SAML/SSO or web forms identity provider configuration for a workspace. Identity providers enable single sign-on authentication via SAML 2.0 and can optionally support SCIM for automated user provisioning and group-based role mapping. Each workspace can have a default general-purpose identity provider and additional web forms identity providers for Asks web authentication. +""" +type IdentityProvider implements Node { + """ + [INTERNAL] SCIM admins group push settings. + """ + adminsGroupPush: JSONObject + """ + Whether users are allowed to change their name and display name even if SCIM is enabled. + """ + allowNameChange: Boolean! + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + Whether the identity provider is the default identity provider migrated from organization level settings. + """ + defaultMigrated: Boolean! + """ + [INTERNAL] SCIM guests group push settings. + """ + guestsGroupPush: JSONObject + """ + The unique identifier of the entity. + """ + id: ID! + """ + The issuer's custom entity ID. + """ + issuerEntityId: String + """ + [INTERNAL] SCIM owners group push settings. + """ + ownersGroupPush: JSONObject + """ + The SAML priority used to pick default workspace in SAML SP initiated flow, when same domain is claimed for SAML by multiple workspaces. Lower priority value means higher preference. + """ + priority: Float + """ + Whether SAML authentication is enabled for the workspace. + """ + samlEnabled: Boolean! + """ + Whether SCIM provisioning is enabled for the workspace. + """ + scimEnabled: Boolean! + """ + The service provider (Linear) custom entity ID. Defaults to https://auth.linear.app/sso + """ + spEntityId: String + """ + Binding method for authentication call. Can be either `post` (default) or `redirect`. + """ + ssoBinding: String + """ + Sign in endpoint URL for the identity provider. + """ + ssoEndpoint: String + """ + The algorithm of the Signing Certificate. Can be one of `sha1`, `sha256` (default), or `sha512`. + """ + ssoSignAlgo: String + """ + X.509 Signing Certificate in string form. + """ + ssoSigningCert: String + """ + The time at which the current SAML configuration was marked as verified. Null if it has not been verified. Cleared whenever the SAML configuration changes. + """ + ssoVerifiedAt: DateTime + """ + The type of identity provider. + """ + type: IdentityProviderType! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +""" +The type of identity provider. +""" +enum IdentityProviderType { + general + webForms +} + +type ImageUploadFromUrlPayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! + """ + The URL containing the image. + """ + url: String +} + +""" +Which Inbox notifications contribute to Inbox badges. +""" +enum InboxBadgeScope { + all + none + priority +} + +""" +State changes to apply to an inbox notification stack. +""" +input InboxNotificationUpdateInput { + """ + Whether to mark the notification stack as read. + """ + read: Boolean + """ + The time until which to snooze the notification stack. Null unsnoozes it. + """ + snoozedUntilAt: DateTime +} + +""" +Return type for inbox notification updates. +""" +type InboxNotificationUpdatePayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + The requested notification after the update. + """ + notification: Notification! + """ + Whether the operation was successful. + """ + success: Boolean! + """ + The notifications changed by the stack update. + """ + updatedNotifications: [Notification!]! +} + +input InheritanceEntityMapping { + """ + Mapping of the IssueLabel ID to the new IssueLabel name. + """ + issueLabels: JSONObject + """ + Mapping of the ProjectLabel ID to the new ProjectLabel name. + """ + projectLabels: JSONObject + """ + [Internal] Mapping of the ProjectStatus ID to the workspace or parent team ProjectStatus ID its projects move to. + """ + projectStatuses: JSONObject + """ + Mapping of the WorkflowState ID to the new WorkflowState ID. + """ + workflowStates: JSONObject! +} + +""" +An initiative is a high-level strategic grouping of projects toward a business goal. Initiatives can contain multiple projects, have their own status updates and health tracking, and can be organized hierarchically with parent-child relationships. +""" +type Initiative implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + [Internal] The time at which the initiative was moved into Canceled status. Null if the initiative has not been canceled. + """ + canceledAt: DateTime + """ + The initiative's color. + """ + color: String + """ + The time at which the initiative was moved into Completed status. Null if the initiative has not been completed. + """ + completedAt: DateTime + """ + The initiative's content in markdown format. + """ + content: String + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The user who created the initiative. + """ + creator: User + """ + The description of the initiative. + """ + description: String + """ + The content of the initiative description. + """ + documentContent: DocumentContent + """ + Documents associated with the initiative. + """ + documents( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned documents. + """ + filter: DocumentFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): DocumentConnection! + """ + [Internal] Facets associated with the initiative, used for filtering and categorization. + """ + facets: [Facet!]! + """ + The resolution of the reminder frequency. + """ + frequencyResolution: FrequencyResolutionType! + """ + The overall health of the initiative, derived from the most recent initiative update. Possible values are onTrack, atRisk, or offTrack. Null if no health has been reported. + """ + health: InitiativeUpdateHealthType + """ + The time at which the initiative health was last updated, typically when a new initiative update is posted. Null if health has never been set. + """ + healthUpdatedAt: DateTime + """ + History entries associated with the initiative. + """ + history( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): InitiativeHistoryConnection! + """ + The icon of the initiative. Can be an emoji or a decorative icon type. + """ + icon: String + """ + The unique identifier of the entity. + """ + id: ID! + """ + [Internal] The human-readable identifier of the initiative. Returns the custom identifier override when set, otherwise the workspace default `-`. Null for legacy initiatives that have not been backfilled. + """ + identifier: String + """ + Initiative updates associated with the initiative. + """ + initiativeUpdates( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): InitiativeUpdateConnection! + """ + Settings for all integrations associated with that initiative. + """ + integrationsSettings: IntegrationsSettings + """ + The IDs of the initiative labels associated with this initiative. + """ + labelIds: [String!]! + """ + Labels associated with this initiative. + """ + labels( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned initiative labels. + """ + filter: InitiativeLabelFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): InitiativeLabelConnection! + """ + The most recent status update posted for this initiative. Null if no updates have been posted. + """ + lastUpdate: InitiativeUpdate + """ + The team that leads the initiative. Null if no lead team is assigned. + """ + leadTeam: Team + """ + Links associated with the initiative. + """ + links( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): EntityExternalLinkConnection! + """ + The name of the initiative. + """ + name: String! + """ + The workspace of the initiative. + """ + organization: Organization! + """ + The user who owns the initiative. The owner is typically responsible for posting status updates and driving the initiative to completion. Null if no owner is assigned. + """ + owner: User + """ + Parent initiative associated with the initiative. + """ + parentInitiative: Initiative + """ + [Internal] Parent initiatives associated with the initiative. + """ + parentInitiatives( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned parent initiatives. + """ + filter: InitiativeFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + """ + [INTERNAL] Sort returned initiatives. + """ + sort: [InitiativeSortInput!] + ): InitiativeConnection! + """ + [Internal] Identifiers (default and custom) that this initiative has previously held. Used to resolve URLs that referenced an older identifier. + """ + previousIdentifiers: [String!]! + """ + The priority of the initiative. 0 = No priority, 1 = Urgent, 2 = High, 3 = Medium, 4 = Low. + """ + priority: Int! + """ + The sort order of the initiative within the workspace when ordered by priority. + """ + prioritySortOrder: Float! + """ + Projects associated with the initiative. + """ + projects( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned projects. + """ + filter: ProjectFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + Whether to include projects from sub-initiatives. Defaults to true. + """ + includeSubInitiatives: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + """ + [INTERNAL] Sort returned projects. + """ + sort: [ProjectSortInput!] + ): ProjectConnection! + """ + The initiative's unique URL slug, used to construct human-readable URLs. + """ + slugId: String! + """ + The sort order of the initiative within the workspace. + """ + sortOrder: Float! + """ + The time at which the initiative was moved into Active status. Null if the initiative has not been activated. + """ + startedAt: DateTime + """ + The lifecycle status of the initiative. One of Proposed, Planned, Active, Completed, Canceled. + """ + status: InitiativeStatus! + """ + Sub-initiatives associated with the initiative. + """ + subInitiatives( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned sub-initiatives. + """ + filter: InitiativeFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + """ + [INTERNAL] Sort returned initiatives. + """ + sort: [InitiativeSortInput!] + ): InitiativeConnection! + """ + The estimated completion date of the initiative. Null if no target date is set. + """ + targetDate: TimelessDate + """ + The resolution of the initiative's estimated completion date, indicating whether it refers to a specific day, week, month, quarter, or year. + """ + targetDateResolution: DateResolutionType + """ + A flag that indicates whether the initiative is in the trash bin. + """ + trashed: Boolean + """ + The frequency at which to prompt for updates. When not set, reminders are inherited from workspace. + """ + updateReminderFrequency: Float + """ + The n-weekly frequency at which to prompt for updates. When not set, reminders are inherited from workspace. + """ + updateReminderFrequencyInWeeks: Float + """ + The day at which to prompt for updates. + """ + updateRemindersDay: Day + """ + The hour at which to prompt for updates. + """ + updateRemindersHour: Float + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + Initiative URL. + """ + url: String! + """ + The visibility of the initiative, derived from its lead team. Public when no lead team is assigned. + """ + visibility: InitiativeVisibility! +} + +""" +A generic payload return from entity archive mutations. +""" +type InitiativeArchivePayload implements ArchivePayload { + """ + The archived/unarchived entity. Null if entity was deleted. + """ + entity: Initiative + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Certain properties of an initiative. +""" +type InitiativeChildWebhookPayload { + """ + The ID of the initiative. + """ + id: String! + """ + The name of the initiative. + """ + name: String! + """ + The URL of the initiative. + """ + url: String! +} + +""" +Initiative collection filtering options. +""" +input InitiativeCollectionFilter { + """ + Comparator for the initiative activity type. + """ + activityType: StringComparator + """ + Filters that the initiative must be an ancestor of. + """ + ancestors: InitiativeCollectionFilter + """ + Compound filters, all of which need to be matched by the initiative. + """ + and: [InitiativeCollectionFilter!] + """ + [Internal] Comparator for the initiative canceled at date. + """ + canceledAt: NullableDateComparator + """ + Comparator for the initiative completed at date. + """ + completedAt: NullableDateComparator + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Filters that the initiative creator must satisfy. + """ + creator: NullableUserFilter + """ + [Internal] Comparator for the initiative's custom identifier. + """ + customIdentifier: NullableStringComparator + """ + Filters that needs to be matched by all initiatives. + """ + every: InitiativeFilter + """ + Comparator for the initiative health: onTrack, atRisk, offTrack + """ + health: StringComparator + """ + Comparator for the initiative health (with age): onTrack, atRisk, offTrack, outdated, noUpdate + """ + healthWithAge: StringComparator + """ + Comparator for the identifier. + """ + id: EntityIdentifierIDComparator + """ + Filters that the initiative updates must satisfy. + """ + initiativeUpdates: InitiativeUpdatesCollectionFilter + """ + Filters that the initiative labels must satisfy. + """ + labels: InitiativeLabelCollectionFilter + """ + Filters that the initiative lead team must satisfy. + """ + leadTeam: NullableTeamFilter + """ + Comparator for the collection length. + """ + length: NumberComparator + """ + Comparator for the initiative name. + """ + name: StringComparator + """ + Compound filters, one of which need to be matched by the initiative. + """ + or: [InitiativeCollectionFilter!] + """ + Filters that the initiative owner must satisfy. + """ + owner: NullableUserFilter + """ + Comparator for the initiative priority. + """ + priority: NullableNumberComparator + """ + Filters that the initiative projects must satisfy. + """ + projects: ProjectCollectionFilter + """ + Comparator for the initiative slug ID. + """ + slugId: StringComparator + """ + Filters that needs to be matched by some initiatives. + """ + some: InitiativeFilter + """ + Comparator for the initiative started at date. + """ + startedAt: NullableDateComparator + """ + Comparator for the initiative status: Proposed, Planned, Active, Completed, Canceled + """ + status: StringComparator + """ + Comparator for the initiative target date. + """ + targetDate: NullableDateComparator + """ + Filters that the initiative teams must satisfy. + """ + teams: TeamCollectionFilter + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +type InitiativeConnection { + edges: [InitiativeEdge!]! + nodes: [Initiative!]! + pageInfo: PageInfo! +} + +""" +The properties of the initiative to create. +""" +input InitiativeCreateInput { + """ + The initiative's color. + """ + color: String + """ + The initiative's content in markdown format. + """ + content: String + """ + The description of the initiative. + """ + description: String + """ + The initiative's icon. + """ + icon: String + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + The identifiers of the initiative labels associated with this initiative. + """ + labelIds: [String!] + """ + The team that leads the initiative. + """ + leadTeamId: String + """ + The name of the initiative. + """ + name: String! + """ + The owner of the initiative. + """ + ownerId: String + """ + The priority of the initiative. 0 = No priority, 1 = Urgent, 2 = High, 3 = Medium, 4 = Low. + """ + priority: Int + """ + The sort order of the initiative within the workspace, when ordered by priority. + """ + prioritySortOrder: Float + """ + The sort order of the initiative within the workspace. + """ + sortOrder: Float + """ + The initiative's status. + """ + status: InitiativeStatus + """ + The estimated completion date of the initiative. + """ + targetDate: TimelessDate + """ + The resolution of the initiative's estimated completion date. + """ + targetDateResolution: DateResolutionType +} + +""" +Initiative creation date sorting options. +""" +input InitiativeCreatedAtSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +type InitiativeEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: Initiative! +} + +""" +Initiative filtering options. +""" +input InitiativeFilter { + """ + Comparator for the initiative activity type. + """ + activityType: StringComparator + """ + Filters that the initiative must be an ancestor of. + """ + ancestors: InitiativeCollectionFilter + """ + Compound filters, all of which need to be matched by the initiative. + """ + and: [InitiativeFilter!] + """ + [Internal] Comparator for the initiative canceled at date. + """ + canceledAt: NullableDateComparator + """ + Comparator for the initiative completed at date. + """ + completedAt: NullableDateComparator + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Filters that the initiative creator must satisfy. + """ + creator: NullableUserFilter + """ + [Internal] Comparator for the initiative's custom identifier. + """ + customIdentifier: NullableStringComparator + """ + Comparator for the initiative health: onTrack, atRisk, offTrack + """ + health: StringComparator + """ + Comparator for the initiative health (with age): onTrack, atRisk, offTrack, outdated, noUpdate + """ + healthWithAge: StringComparator + """ + Comparator for the identifier. + """ + id: EntityIdentifierIDComparator + """ + Filters that the initiative updates must satisfy. + """ + initiativeUpdates: InitiativeUpdatesCollectionFilter + """ + Filters that the initiative labels must satisfy. + """ + labels: InitiativeLabelCollectionFilter + """ + Filters that the initiative lead team must satisfy. + """ + leadTeam: NullableTeamFilter + """ + Comparator for the initiative name. + """ + name: StringComparator + """ + Compound filters, one of which need to be matched by the initiative. + """ + or: [InitiativeFilter!] + """ + Filters that the initiative owner must satisfy. + """ + owner: NullableUserFilter + """ + Comparator for the initiative priority. + """ + priority: NullableNumberComparator + """ + Filters that the initiative projects must satisfy. + """ + projects: ProjectCollectionFilter + """ + Comparator for the initiative slug ID. + """ + slugId: StringComparator + """ + Comparator for the initiative started at date. + """ + startedAt: NullableDateComparator + """ + Comparator for the initiative status: Proposed, Planned, Active, Completed, Canceled + """ + status: StringComparator + """ + Comparator for the initiative target date. + """ + targetDate: NullableDateComparator + """ + Filters that the initiative teams must satisfy. + """ + teams: TeamCollectionFilter + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +The result of an AI-generated initiative filter suggestion based on a text prompt. +""" +type InitiativeFilterSuggestionPayload { + """ + The json filter that is suggested. + """ + filter: JSONObject + """ + The log id of the prompt that created this filter. + """ + logId: String +} + +""" +Initiative health sorting options. +""" +input InitiativeHealthSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +Initiative health update date sorting options. +""" +input InitiativeHealthUpdatedAtSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +A history record associated with an initiative. Tracks changes to initiative properties such as name, status, owner, target date, icon, color, and parent-child relationships over time. +""" +type InitiativeHistory implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The events that happened while recording that history. + """ + entries: JSONObject! + """ + The unique identifier of the entity. + """ + id: ID! + """ + The initiative that this history record belongs to. + """ + initiative: Initiative! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +type InitiativeHistoryConnection { + edges: [InitiativeHistoryEdge!]! + nodes: [InitiativeHistory!]! + pageInfo: PageInfo! +} + +type InitiativeHistoryEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: InitiativeHistory! +} + +""" +A label that can be applied to initiatives for categorization. Initiative labels are workspace-level and can be organized into groups with a parent-child hierarchy. Only child labels (not group labels) can be directly applied to initiatives. +""" +type InitiativeLabel implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + Children of the label. + """ + children( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned initiative labels. + """ + filter: InitiativeLabelFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): InitiativeLabelConnection! + """ + The label's color as a HEX string (e.g., '#EB5757'). Used for visual identification of the label in the UI. + """ + color: String! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The user who created the label. + """ + creator: User + """ + The label's description. + """ + description: String + """ + The selection mode of this label group. Null for regular labels. Groups without a type use single-select behavior. + """ + groupType: LabelGroupType + """ + The unique identifier of the entity. + """ + id: ID! + """ + Initiatives associated with the label. + """ + initiatives( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned initiatives. + """ + filter: InitiativeFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + """ + [INTERNAL] Sort returned initiatives. + """ + sort: [InitiativeSortInput!] + ): InitiativeConnection! + """ + Whether the label is a group. When true, this label acts as a container for child labels and cannot be directly applied to issues or projects. When false, the label can be directly applied. + """ + isGroup: Boolean! + """ + The date when the label was last applied to an issue, project, or initiative. Null if the label has never been applied. + """ + lastAppliedAt: DateTime + """ + The label's name. + """ + name: String! + """ + The workspace that the initiative label belongs to. + """ + organization: Organization! + """ + The parent label group. If set, this label is a child within a group. Only one child label from each group can be applied to an initiative at a time. + """ + parent: InitiativeLabel + """ + [Internal] When the label was retired. + """ + retiredAt: DateTime + """ + The user who retired the label. Retired labels cannot be applied to new initiatives but remain on existing ones. Null if the label is active. + """ + retiredBy: User + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +""" +Certain properties of an initiative label. +""" +type InitiativeLabelChildWebhookPayload { + """ + The color of the initiative label. + """ + color: String! + """ + The ID of the initiative label. + """ + id: String! + """ + The name of the initiative label. + """ + name: String! + """ + The parent ID of the initiative label. + """ + parentId: String +} + +""" +Initiative label filtering options. +""" +input InitiativeLabelCollectionFilter { + """ + Compound filters, all of which need to be matched by the label. + """ + and: [InitiativeLabelCollectionFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Filters that the initiative labels creator must satisfy. + """ + creator: NullableUserFilter + """ + Filters that needs to be matched by all initiative labels. + """ + every: InitiativeLabelFilter + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Comparator for whether the label is a group label. + """ + isGroup: BooleanComparator + """ + Comparator for the collection length. + """ + length: NumberComparator + """ + Comparator for the name. + """ + name: StringComparator + """ + Filter based on the existence of the relation. + """ + null: Boolean + """ + Compound filters, one of which need to be matched by the label. + """ + or: [InitiativeLabelCollectionFilter!] + """ + Filters that the initiative label's parent label must satisfy. + """ + parent: InitiativeLabelFilter + """ + Filters that needs to be matched by some initiative labels. + """ + some: InitiativeLabelCollectionFilter + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +type InitiativeLabelConnection { + edges: [InitiativeLabelEdge!]! + nodes: [InitiativeLabel!]! + pageInfo: PageInfo! +} + +""" +Input for creating a new initiative label. A name is required. The label is created as a workspace-level label available to all initiatives. +""" +input InitiativeLabelCreateInput { + """ + The color of the label. + """ + color: String + """ + The description of the label. + """ + description: String + """ + The selection mode of the label group. Null uses single-select behavior. + """ + groupType: LabelGroupType + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + Whether the label is a group. + """ + isGroup: Boolean + """ + The name of the label. + """ + name: String! + """ + The identifier of the parent label. + """ + parentId: String + """ + The time at which the label was retired. Set to null to restore a retired label. + """ + retiredAt: DateTime +} + +type InitiativeLabelEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: InitiativeLabel! +} + +""" +Initiative label filtering options. +""" +input InitiativeLabelFilter { + """ + Compound filters, all of which need to be matched by the label. + """ + and: [InitiativeLabelFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Filters that the initiative labels creator must satisfy. + """ + creator: NullableUserFilter + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Comparator for whether the label is a group label. + """ + isGroup: BooleanComparator + """ + Comparator for the name. + """ + name: StringComparator + """ + Compound filters, one of which need to be matched by the label. + """ + or: [InitiativeLabelFilter!] + """ + Filters that the initiative label's parent label must satisfy. + """ + parent: InitiativeLabelFilter + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +The result of an initiative label mutation. +""" +type InitiativeLabelPayload { + """ + The label that was created or updated. + """ + initiativeLabel: InitiativeLabel! + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Input for updating an existing initiative label. All fields are optional; only provided fields will be updated. +""" +input InitiativeLabelUpdateInput { + """ + The color of the label. + """ + color: String + """ + The description of the label. + """ + description: String + """ + The selection mode of the label group. Omit to keep the current value. Null uses single-select behavior. + """ + groupType: LabelGroupType + """ + Whether the label is a group. + """ + isGroup: Boolean + """ + The name of the label. + """ + name: String + """ + The identifier of the parent label. + """ + parentId: String + """ + The time at which the label was retired. Set to null to restore a retired label. + """ + retiredAt: DateTime +} + +""" +Payload for an initiative label webhook. +""" +type InitiativeLabelWebhookPayload { + """ + The time at which the entity was archived. + """ + archivedAt: String + """ + The color of the initiative label. + """ + color: String! + """ + The time at which the entity was created. + """ + createdAt: String! + """ + The creator ID of the initiative label. + """ + creatorId: String + """ + The label's description. + """ + description: String + """ + The ID of the entity. + """ + id: String! + """ + Whether the label is a group. + """ + isGroup: Boolean! + """ + The name of the initiative label. + """ + name: String! + """ + The parent ID of the initiative label. + """ + parentId: String + """ + The time at which the entity was updated. + """ + updatedAt: String! +} + +""" +[Internal] Impact summary for changing an initiative's lead team. +""" +type InitiativeLeadTeamChangeImpact { + """ + The number of editable matching sub-initiatives whose lead team would change if the update is applied to descendants. Matching sub-initiatives currently have the same lead team as the selected initiative had before the change. + """ + affectedDescendantCount: Int! + """ + Whether the changed initiatives may gain or lose access restrictions because the current or next lead team is not public. + """ + visibilityMayChange: Boolean! +} + +""" +[Internal] Determines how a lead team change is applied to an initiative hierarchy. +""" +enum InitiativeLeadTeamChangeMode { + includeDescendants + selectedOnly +} + +""" +[Internal] The payload returned by the initiative lead team update mutation. +""" +type InitiativeLeadTeamUpdatePayload { + """ + [Internal] The matching sub-initiatives whose lead team was also changed. + """ + affectedDescendants: [Initiative!]! + """ + The initiative that was created or updated. + """ + initiative: Initiative! + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Initiative manual sorting options. +""" +input InitiativeManualSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +Initiative name sorting options. +""" +input InitiativeNameSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +A notification related to an initiative, such as being added as owner, initiative updates, comments, or mentions. +""" +type InitiativeNotification implements Entity & Node & Notification { + """ + The user that caused the notification. Null if the notification was triggered by a non-user actor such as an integration, external user, or system event. + """ + actor: User + """ + [Internal] Notification actor initials if avatar is not available. + """ + actorAvatarColor: String! + """ + [Internal] Notification avatar URL. + """ + actorAvatarUrl: String + """ + [Internal] Whether the notification's user actor is deactivated in the workspace. + """ + actorInactive: Boolean! + """ + [Internal] Notification actor initials if avatar is not available. + """ + actorInitials: String + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The bot that caused the notification. + """ + botActor: ActorBot + """ + The category of the notification. + """ + category: NotificationCategory! + """ + The comment related to the notification. + """ + comment: Comment + """ + Related comment ID. Null if the notification is not related to a comment. + """ + commentId: String + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The document related to the notification. + """ + document: Document + """ + The time at which an email reminder for this notification was sent to the user. Null if no email reminder has been sent. + """ + emailedAt: DateTime + """ + The external user that caused the notification. Populated when the notification was triggered by an external user (e.g., a commenter from a connected integration like Slack or GitHub) rather than a Linear workspace member. + """ + externalUserActor: ExternalUser + """ + [Internal] Notifications with the same grouping key will be grouped together in the UI. + """ + groupingKey: String! + """ + [Internal] Priority of the notification with the same grouping key. Higher number means higher priority. If priority is the same, notifications should be sorted by `createdAt`. + """ + groupingPriority: Float! + """ + The unique identifier of the entity. + """ + id: ID! + """ + [Internal] Inbox URL for the notification. + """ + inboxUrl: String! + """ + The initiative related to the notification. + """ + initiative: Initiative + """ + Related initiative ID. + """ + initiativeId: String! + """ + The initiative update related to the notification. + """ + initiativeUpdate: InitiativeUpdate + """ + [Internal] Initiative update health for new updates. + """ + initiativeUpdateHealth: String + """ + Related initiative update ID. + """ + initiativeUpdateId: String + """ + [Internal] If notification actor was Linear. + """ + isLinearActor: Boolean! + """ + [Internal] Issue's status type for issue notifications. + """ + issueStatusType: String + """ + The parent comment related to the notification, if a notification is a reply comment notification. + """ + parentComment: Comment + """ + Related parent comment ID. Null if the notification is not related to a comment. + """ + parentCommentId: String + """ + [Internal] Project update health for new updates. + """ + projectUpdateHealth: String + """ + Name of the reaction emoji related to the notification. + """ + reactionEmoji: String + """ + The time at which the user marked the notification as read. Null if the notification is unread. + """ + readAt: DateTime + """ + The time until which a notification is snoozed. After this time, the notification reappears in the user's inbox. Null if the notification is not currently snoozed. + """ + snoozedUntilAt: DateTime + """ + [Internal] Notification subtitle. + """ + subtitle: String! + """ + [Internal] Notification title. + """ + title: String! + """ + Notification type. Determines the kind of event that triggered this notification and which associated entity fields will be populated. + """ + type: String! + """ + The time at which a notification was unsnoozed. Null if the notification has not been unsnoozed. + """ + unsnoozedAt: DateTime + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + [Internal] URL to the target of the notification. + """ + url: String! + """ + The recipient user of this notification. + """ + user: User! +} + +""" +A notification subscription scoped to a specific initiative. The subscriber receives notifications for events related to this initiative, such as updates, comments, and ownership changes. +""" +type InitiativeNotificationSubscription implements Entity & Node & NotificationSubscription { + """ + Whether the subscription is active. When inactive, no notifications are generated from this subscription even though it still exists. + """ + active: Boolean! + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The type of contextual view (e.g., active issues, backlog) that further scopes a team notification subscription. Null if the subscription is not associated with a specific view type. + """ + contextViewType: ContextViewType + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The custom view that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + customView: CustomView + """ + The customer that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + customer: Customer + """ + The cycle that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + cycle: Cycle + """ + The unique identifier of the entity. + """ + id: ID! + """ + Whether initiative update notifications also include updates from sub-initiatives. Applies only when initiative updates are enabled and the workspace supports sub-initiatives. + """ + includeSubInitiativeUpdates: Boolean! + """ + The initiative subscribed to. + """ + initiative: Initiative! + """ + The issue label that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + label: IssueLabel + """ + The notification event types that this subscription will deliver to the subscriber. + """ + notificationSubscriptionTypes: [String!]! + """ + The project that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + project: Project + """ + The user who will receive notifications from this subscription. + """ + subscriber: User! + """ + The team that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + team: Team + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The user that this notification subscription is scoped to, for user-specific view subscriptions. Null if the subscription targets a different entity type. + """ + user: User + """ + The type of user-specific view that further scopes a user notification subscription. Null if the subscription is not associated with a user view type. + """ + userContextViewType: UserContextViewType +} + +""" +Initiative owner sorting options. +""" +input InitiativeOwnerSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +The payload returned by the initiative mutations. +""" +type InitiativePayload { + """ + The initiative that was created or updated. + """ + initiative: Initiative! + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Initiative priority sorting options. +""" +input InitiativePrioritySort { + """ + Whether to consider no priority as the highest or lowest priority + """ + noPriorityFirst: Boolean = false + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +A parent-child relation between two initiatives, forming a hierarchy. The initiative field is the parent and relatedInitiative is the child. Cycles and excessive nesting depth are prevented. +""" +type InitiativeRelation implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The unique identifier of the entity. + """ + id: ID! + """ + The parent initiative in this hierarchical relation. + """ + initiative: Initiative! + """ + The child initiative in this hierarchical relation. + """ + relatedInitiative: Initiative! + """ + The sort order of the child initiative within its parent initiative. + """ + sortOrder: Float! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The user who last created or modified the relation. Null if the user has been deleted. + """ + user: User +} + +type InitiativeRelationConnection { + edges: [InitiativeRelationEdge!]! + nodes: [InitiativeRelation!]! + pageInfo: PageInfo! +} + +""" +Input for creating a parent-child relationship between two initiatives. The initiativeId is the parent and the relatedInitiativeId is the child. +""" +input InitiativeRelationCreateInput { + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + The identifier of the parent initiative in the hierarchy. + """ + initiativeId: String! + """ + The identifier of the child initiative in the hierarchy. + """ + relatedInitiativeId: String! + """ + The sort order of the child initiative within its parent. + """ + sortOrder: Float +} + +type InitiativeRelationEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: InitiativeRelation! +} + +""" +The result of an initiative relation mutation. +""" +type InitiativeRelationPayload { + """ + The initiative relation that was created or updated. + """ + initiativeRelation: InitiativeRelation! + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +The properties of the initiative relation to update. +""" +input InitiativeRelationUpdateInput { + """ + The sort order of the child initiative within its parent. + """ + sortOrder: Float +} + +""" +Initiative sorting options. +""" +input InitiativeSortInput { + """ + Sort by initiative creation date. + """ + createdAt: InitiativeCreatedAtSort + """ + Sort by initiative health status. + """ + health: InitiativeHealthSort + """ + Sort by initiative health update date. + """ + healthUpdatedAt: InitiativeHealthUpdatedAtSort + """ + Sort by manual order. + """ + manual: InitiativeManualSort + """ + Sort by initiative name. + """ + name: InitiativeNameSort + """ + Sort by initiative owner name. + """ + owner: InitiativeOwnerSort + """ + Sort by initiative priority. + """ + priority: InitiativePrioritySort + """ + Sort by initiative target date. + """ + targetDate: InitiativeTargetDateSort + """ + Sort by initiative update date. + """ + updatedAt: InitiativeUpdatedAtSort +} + +enum InitiativeStatus { + Active + Canceled + Completed + Planned + Proposed +} + +""" +Different tabs available inside an initiative. +""" +enum InitiativeTab { + overview + projects + updates +} + +""" +Initiative target date sorting options. +""" +input InitiativeTargetDateSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +The join entity linking a project to an initiative. A project can only appear once in an initiative hierarchy -- it cannot be on both an initiative and one of its ancestor or descendant initiatives. +""" +type InitiativeToProject implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The unique identifier of the entity. + """ + id: ID! + """ + The initiative that the project is associated with. + """ + initiative: Initiative! + """ + The project that the initiative is associated with. + """ + project: Project! + """ + The sort order of the project within its parent initiative. + """ + sortOrder: String! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +type InitiativeToProjectConnection { + edges: [InitiativeToProjectEdge!]! + nodes: [InitiativeToProject!]! + pageInfo: PageInfo! +} + +""" +The properties of the initiativeToProject to create. +""" +input InitiativeToProjectCreateInput { + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + The identifier of the initiative. + """ + initiativeId: String! + """ + The identifier of the project. + """ + projectId: String! + """ + The sort order for the project within the initiative. + """ + sortOrder: Float +} + +type InitiativeToProjectEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: InitiativeToProject! +} + +""" +The result of an initiative-to-project mutation. +""" +type InitiativeToProjectPayload { + """ + The initiative-to-project association that was created or updated. + """ + initiativeToProject: InitiativeToProject! + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +The properties of the initiative-to-project association to update. +""" +input InitiativeToProjectUpdateInput { + """ + The sort order for the project within the initiative. + """ + sortOrder: Float +} + +""" +A status update posted to an initiative. Initiative updates communicate progress, health, and blockers to stakeholders. Each update captures the initiative's health at the time of writing and includes a rich-text body with the update content. +""" +type InitiativeUpdate implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The update content in markdown format. + """ + body: String! + """ + [Internal] The content of the update as a Prosemirror document. + """ + bodyData: String! + """ + Number of comments associated with the initiative update. + """ + commentCount: Int! + """ + Comments associated with the initiative update. + """ + comments( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned comments. + """ + filter: CommentFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): CommentConnection! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The diff between the current update and the previous one. + """ + diff: JSONObject + """ + The diff between the current update and the previous one, formatted as markdown. + """ + diffMarkdown: String + """ + The time the update was edited. + """ + editedAt: DateTime + """ + The health of the initiative at the time this update was posted. Possible values are onTrack, atRisk, or offTrack. + """ + health: InitiativeUpdateHealthType! + """ + The unique identifier of the entity. + """ + id: ID! + """ + [Internal] A snapshot of initiative properties at the time the update was posted, including project statuses, sub-initiative health, and target dates. Used to compute diffs between consecutive updates. + """ + infoSnapshot: JSONObject + """ + The initiative that this status update was posted to. + """ + initiative: Initiative! + """ + Whether the diff between this update and the previous one should be hidden in the UI. Only used for legacy updates. Not settable in the UI. + """ + isDiffHidden: Boolean! + """ + Whether the initiative update is stale. + """ + isStale: Boolean! + """ + Emoji reaction summary, grouped by emoji type. + """ + reactionData: JSONObject! + """ + Reactions associated with the initiative update. + """ + reactions: [Reaction!]! + """ + The update's unique URL slug. + """ + slugId: String! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The URL to the initiative update. + """ + url: String! + """ + The user who wrote the update. + """ + user: User! +} + +""" +A generic payload return from entity archive mutations. +""" +type InitiativeUpdateArchivePayload implements ArchivePayload { + """ + The archived/unarchived entity. Null if entity was deleted. + """ + entity: InitiativeUpdate + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Certain properties of an initiative update. +""" +type InitiativeUpdateChildWebhookPayload { + """ + The body of the initiative update. + """ + bodyData: String! + """ + The edited at timestamp of the initiative update. + """ + editedAt: String! + """ + The health of the initiative update. + """ + health: String! + """ + The ID of the initiative update. + """ + id: String! +} + +type InitiativeUpdateConnection { + edges: [InitiativeUpdateEdge!]! + nodes: [InitiativeUpdate!]! + pageInfo: PageInfo! +} + +""" +Input for creating a new initiative update. +""" +input InitiativeUpdateCreateInput { + """ + The content of the update in markdown format. + """ + body: String + """ + [Internal] The content of the update as a Prosemirror document. + """ + bodyData: JSON + """ + The health of the initiative at the time of the update. + """ + health: InitiativeUpdateHealthType + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + The initiative to associate the update with. + """ + initiativeId: String! + """ + Whether the diff between the current update and the previous one should be hidden. + """ + isDiffHidden: Boolean +} + +type InitiativeUpdateEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: InitiativeUpdate! +} + +""" +Options for filtering initiative updates. +""" +input InitiativeUpdateFilter { + """ + Compound filters, all of which need to be matched by the InitiativeUpdate. + """ + and: [InitiativeUpdateFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Filters that the initiative update initiative must satisfy. + """ + initiative: InitiativeFilter + """ + Compound filters, one of which need to be matched by the InitiativeUpdate. + """ + or: [InitiativeUpdateFilter!] + """ + Filters that the initiative updates reactions must satisfy. + """ + reactions: ReactionCollectionFilter + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator + """ + Filters that the initiative update creator must satisfy. + """ + user: UserFilter +} + +""" +The health type when the update is created. +""" +enum InitiativeUpdateHealthType { + atRisk + offTrack + onTrack +} + +""" +The properties of the initiative to update. +""" +input InitiativeUpdateInput { + """ + The initiative's color. + """ + color: String + """ + The initiative's content in markdown format. + """ + content: String + """ + [Internal] Sets or clears the custom identifier override for the initiative. Pass null to revert to the workspace default. + """ + customIdentifier: String + """ + The description of the initiative. + """ + description: String + """ + The resolution type for the update reminder frequency (e.g., weekly, biweekly). + """ + frequencyResolution: FrequencyResolutionType + """ + The initiative's icon. + """ + icon: String + """ + The identifiers of the initiative labels associated with this initiative. + """ + labelIds: [String!] + """ + The team that leads the initiative. Set to null to clear. + """ + leadTeamId: String + """ + The name of the initiative. + """ + name: String + """ + The owner of the initiative. + """ + ownerId: String + """ + The priority of the initiative. 0 = No priority, 1 = Urgent, 2 = High, 3 = Medium, 4 = Low. + """ + priority: Int + """ + The sort order of the initiative within the workspace, when ordered by priority. + """ + prioritySortOrder: Float + """ + The sort order of the initiative within the workspace. + """ + sortOrder: Float + """ + The initiative's status. + """ + status: InitiativeStatus + """ + The estimated completion date of the initiative. Set to null to clear. + """ + targetDate: TimelessDate + """ + The resolution of the initiative's estimated completion date. + """ + targetDateResolution: DateResolutionType + """ + Whether the initiative has been trashed. Set to true to trash, or null to restore. + """ + trashed: Boolean + """ + The frequency at which to prompt for initiative updates. When not set, reminders are inherited from workspace settings. + """ + updateReminderFrequency: Float + """ + The n-weekly frequency at which to prompt for initiative updates. When not set, reminders are inherited from workspace settings. + """ + updateReminderFrequencyInWeeks: Float + """ + The day of the week on which to prompt for initiative updates. + """ + updateRemindersDay: Day + """ + The hour of the day (0-23) at which to prompt for initiative updates. + """ + updateRemindersHour: Int +} + +""" +The result of an initiative update mutation. +""" +type InitiativeUpdatePayload { + """ + The initiative update that was created or updated. + """ + initiativeUpdate: InitiativeUpdate! + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +The result of an initiative update reminder mutation. +""" +type InitiativeUpdateReminderPayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Input for updating an existing initiative update. +""" +input InitiativeUpdateUpdateInput { + """ + The content of the update in markdown format. + """ + body: String + """ + The content of the update as a Prosemirror document. + """ + bodyData: JSON + """ + The health of the initiative at the time of the update. + """ + health: InitiativeUpdateHealthType +} + +""" +Payload for an initiative update webhook. +""" +type InitiativeUpdateWebhookPayload { + """ + The time at which the entity was archived. + """ + archivedAt: String + """ + The body of the initiative update. + """ + body: String! + """ + The body data of the initiative update. + """ + bodyData: String! + """ + The time at which the entity was created. + """ + createdAt: String! + """ + The diff between the current update and the previous one, formatted as markdown. + """ + diffMarkdown: String + """ + The edited at timestamp of the initiative update. + """ + editedAt: String! + """ + The health of the initiative update. + """ + health: String! + """ + The ID of the entity. + """ + id: String! + """ + The initiative that the initiative update belongs to. + """ + initiative: InitiativeChildWebhookPayload! + """ + The initiative id of the initiative update. + """ + initiativeId: String! + """ + The reaction data for this initiative update. + """ + reactionData: JSONObject! + """ + The slug id of the initiative update. + """ + slugId: String! + """ + The time at which the entity was updated. + """ + updatedAt: String! + """ + The URL of the initiative update. + """ + url: String + """ + The user that created the initiative update. + """ + user: UserChildWebhookPayload! + """ + The user id of the initiative update. + """ + userId: String! +} + +""" +Initiative update date sorting options. +""" +input InitiativeUpdatedAtSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +Collection filtering options for filtering initiatives by initiative updates. +""" +input InitiativeUpdatesCollectionFilter { + """ + Compound filters, all of which need to be matched by the initiative update. + """ + and: [InitiativeUpdatesCollectionFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Filters that needs to be matched by all initiative updates. + """ + every: InitiativeUpdatesFilter + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Comparator for the collection length. + """ + length: NumberComparator + """ + Compound filters, one of which need to be matched by the update. + """ + or: [InitiativeUpdatesCollectionFilter!] + """ + Filters that needs to be matched by some initiative updates. + """ + some: InitiativeUpdatesFilter + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +Options for filtering initiatives by initiative updates. +""" +input InitiativeUpdatesFilter { + """ + Compound filters, all of which need to be matched by the initiative updates. + """ + and: [InitiativeUpdatesFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Compound filters, one of which need to be matched by the initiative updates. + """ + or: [InitiativeUpdatesFilter!] + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +The visibility of an initiative. Derived from its lead team; public when no lead team is assigned. +""" +enum InitiativeVisibility { + private + public + restricted +} + +""" +Payload for an initiative webhook. +""" +type InitiativeWebhookPayload { + """ + The time at which the entity was archived. + """ + archivedAt: String + """ + When the initiative was canceled. + """ + canceledAt: String + """ + The color of the initiative. + """ + color: String + """ + When the initiative was completed. + """ + completedAt: String + """ + The time at which the entity was created. + """ + createdAt: String! + """ + The user who created the initiative. + """ + creator: UserChildWebhookPayload + """ + The ID of the user who created the initiative. + """ + creatorId: String + """ + The description of the initiative. + """ + description: String! + """ + The resolution of the update reminder frequency. + """ + frequencyResolution: String! + """ + The health status of the initiative. + """ + health: String + """ + When the health status was last updated. + """ + healthUpdatedAt: String + """ + The icon of the initiative. + """ + icon: String + """ + The ID of the entity. + """ + id: String! + """ + The human-readable identifier of the initiative. + """ + identifier: String + """ + The IDs of the initiative labels associated with this initiative. + """ + labelIds: [String!]! + """ + The last update for this initiative. + """ + lastUpdate: InitiativeUpdateChildWebhookPayload + """ + The ID of the last update for this initiative. + """ + lastUpdateId: String + """ + The ID of the team that leads the initiative. + """ + leadTeamId: String + """ + The name of the initiative. + """ + name: String! + """ + The ID of the organization this initiative belongs to. + """ + organizationId: String! + """ + The user who owns the initiative. + """ + owner: UserChildWebhookPayload + """ + The ID of the user who owns the initiative. + """ + ownerId: String + """ + The parent initiative associated with the initiative. + """ + parentInitiative: InitiativeChildWebhookPayload + """ + The parent initiatives associated with the initiative. + """ + parentInitiatives: [InitiativeChildWebhookPayload!] + """ + Previous identifiers of the initiative. + """ + previousIdentifiers: [String!] + """ + The priority of the initiative. 0 = No priority, 1 = Urgent, 2 = High, 3 = Medium, 4 = Low. + """ + priority: Float! + """ + The projects associated with the initiative. + """ + projects: [ProjectChildWebhookPayload!] + """ + The unique slug identifier of the initiative. + """ + slugId: String! + """ + The sort order of the initiative within the organization. + """ + sortOrder: Float! + """ + When the initiative was started. + """ + startedAt: String + """ + The current status of the initiative. + """ + status: String! + """ + The sub-initiatives associated with the initiative. + """ + subInitiatives: [InitiativeChildWebhookPayload!] + """ + The target date of the initiative. + """ + targetDate: String + """ + The resolution of the target date. + """ + targetDateResolution: String + """ + Whether the initiative is trashed. + """ + trashed: Boolean + """ + The frequency of update reminders. + """ + updateReminderFrequency: Float + """ + The frequency of update reminders in weeks. + """ + updateReminderFrequencyInWeeks: Float + """ + The day of the week for update reminders. + """ + updateRemindersDay: Float + """ + The hour of the day for update reminders. + """ + updateRemindersHour: Float + """ + The time at which the entity was updated. + """ + updatedAt: String! + """ + The URL of the initiative. + """ + url: String! +} + +""" +An integration with an external service. Integrations connect Linear to tools like Slack, GitHub, GitLab, Jira, Figma, Sentry, Zendesk, Intercom, Front, PagerDuty, Opsgenie, Google Sheets, Microsoft Teams, Discord, Salesforce, and others. Each integration record represents a single configured connection, scoped to a workspace and optionally to a specific team, project, initiative, or custom view. Personal integrations (e.g., Slack Personal, Jira Personal, GitHub Personal) are scoped to the user who created them. +""" +type Integration implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The user that added the integration. + """ + creator: User! + """ + The unique identifier of the entity. + """ + id: ID! + """ + The workspace that the integration is associated with. + """ + organization: Organization! + """ + The integration's type, identifying which external service this integration connects to (e.g., 'slack', 'github', 'jira', 'figma'). This determines the shape of the integration's settings and data. + """ + service: String! + """ + The team that the integration is associated with. + """ + team: Team + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +""" +Integration actor payload for webhooks. +""" +type IntegrationActorWebhookPayload { + """ + The ID of the integration. + """ + id: String! + """ + The service of the integration. + """ + service: String! + """ + The type of actor. + """ + type: String! +} + +""" +Certain properties of an integration. +""" +type IntegrationChildWebhookPayload { + """ + The ID of the integration. + """ + id: String! + """ + The service of the integration. + """ + service: String! +} + +type IntegrationConnection { + edges: [IntegrationEdge!]! + nodes: [Integration!]! + pageInfo: PageInfo! +} + +input IntegrationCustomerDataAttributesRefreshInput { + """ + The integration service to refresh customer data attributes from. + """ + service: String! +} + +""" +A Datadog feature flag environment. +""" +type IntegrationDatadogEnvironment { + id: String! + name: String! +} + +""" +Datadog environments available to connect. +""" +type IntegrationDatadogEnvironmentsPayload { + environments: [IntegrationDatadogEnvironment!]! +} + +type IntegrationEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: Integration! +} + +type IntegrationGithubRemoveCodeAccessPayload { + """ + The action the client should take next. + """ + action: GitHubRemoveCodeAccessAction! + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! +} + +type IntegrationHasScopesPayload { + """ + Whether the integration has the required scopes. + """ + hasAllScopes: Boolean! + """ + The missing scopes. + """ + missingScopes: [String!] +} + +type IntegrationPayload { + """ + GitHub-specific details for the operation. Populated by GitHub-related mutations only. + """ + gitHub: GitHubIntegrationConnectDetails + """ + The integration that was created or updated. + """ + integration: Integration + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Input for requesting a currently unavailable integration. +""" +input IntegrationRequestInput { + """ + Email associated with the request. + """ + email: String + """ + Name of the requested integration. + """ + name: String! +} + +""" +The result of an integration request mutation. +""" +type IntegrationRequestPayload { + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Linear supported integration services. +""" +enum IntegrationService { + airbyte + asksWeb + datadog + discord + email + figma + figmaPlugin + front + github + githubCodeAccessPersonal + githubCommit + githubEnterpriseServer + githubImport + githubPersonal + gitlab + gong + googleCalendarPersonal + googleSheets + intercom + jira + jiraPersonal + launchDarkly + launchDarklyPersonal + loom + mcpServer + mcpServerPersonal + microsoftPersonal + microsoftTeams + microsoftTeamsProjectPost + notion + opsgenie + origin + pagerDuty + salesforce + sentry + slack + slackAsks + slackCustomViewNotifications + slackInitiativePost + slackOrgInitiativeUpdatesPost + slackOrgProjectUpdatesPost + slackPersonal + slackPost + slackProjectPost + slackProjectUpdatesPost + zendesk +} + +input IntegrationSettingsInput { + front: FrontSettingsInput + gitHub: GitHubSettingsInput + gitHubImport: GitHubImportSettingsInput + gitHubPersonal: GitHubPersonalSettingsInput + gitLab: GitLabSettingsInput + gong: GongSettingsInput + googleSheets: GoogleSheetsSettingsInput + intercom: IntercomSettingsInput + jira: JiraSettingsInput + jiraPersonal: JiraPersonalSettingsInput + launchDarkly: LaunchDarklySettingsInput + """ + Settings shared by personal and shared MCP server connections. + """ + mcpServer: McpServerIntegrationSettingsInput + microsoftTeams: MicrosoftTeamsSettingsInput + microsoftTeamsProjectPost: MicrosoftTeamsPostSettingsInput + notion: NotionSettingsInput + opsgenie: OpsgenieInput + origin: OriginSettingsInput + pagerDuty: PagerDutyInput + salesforce: SalesforceSettingsInput + sentry: SentrySettingsInput + slack: SlackSettingsInput + slackAsks: SlackAsksSettingsInput + slackCustomViewNotifications: SlackPostSettingsInput + slackInitiativePost: SlackPostSettingsInput + slackOrgInitiativeUpdatesPost: SlackPostSettingsInput + slackOrgProjectUpdatesPost: SlackPostSettingsInput + slackPost: SlackPostSettingsInput + slackProjectPost: SlackPostSettingsInput + zendesk: ZendeskSettingsInput +} + +type IntegrationSlackWorkspaceNamePayload { + """ + The current name of the Slack workspace. + """ + name: String! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +A connection between a template and an integration. This join entity links Linear issue templates to integrations so that external systems (e.g., Slack Asks channels) can use specific templates when creating issues. Each record optionally includes a foreign entity ID to scope the template to a specific external resource, such as a particular Slack channel. +""" +type IntegrationTemplate implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The identifier of the foreign entity in the external service that this template is scoped to. For example, a Slack channel ID indicating which channel should use this template for creating issues. When null, the template applies to the integration as a whole rather than a specific external resource. + """ + foreignEntityId: String + """ + The unique identifier of the entity. + """ + id: ID! + """ + The integration that the template is associated with. + """ + integration: Integration! + """ + The template that the integration is associated with. + """ + template: Template! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +type IntegrationTemplateConnection { + edges: [IntegrationTemplateEdge!]! + nodes: [IntegrationTemplate!]! + pageInfo: PageInfo! +} + +""" +Input for creating a new integration template. +""" +input IntegrationTemplateCreateInput { + """ + The foreign identifier in the other service. + """ + foreignEntityId: String + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + The identifier of the integration. + """ + integrationId: String! + """ + The identifier of the template. + """ + templateId: String! +} + +type IntegrationTemplateEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: IntegrationTemplate! +} + +""" +The result of an integration template mutation. +""" +type IntegrationTemplatePayload { + """ + The IntegrationTemplate that was created or updated. + """ + integrationTemplate: IntegrationTemplate! + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +input IntegrationUpdateInput { + """ + The settings to update. + """ + settings: IntegrationSettingsInput + """ + The ID of the workflow definition draft that this integration should be assigned to. + """ + workflowDefinitionDraftId: String + """ + The ID of the workflow definition that this integration should be assigned to. + """ + workflowDefinitionId: String +} + +""" +The configuration of all integrations for different entities. Controls Slack notification preferences for a specific team, project, initiative, or custom view. Exactly one of teamId, projectId, customViewId, or initiativeId must be set, determining which entity these integration settings apply to. +""" +type IntegrationsSettings implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The type of view to which the integration settings context is associated with. + """ + contextViewType: ContextViewType + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The unique identifier of the entity. + """ + id: ID! + """ + Initiative which those settings apply to. + """ + initiative: Initiative + """ + Whether to send a Microsoft Teams message when a project update is created. + """ + microsoftTeamsProjectUpdateCreated: Boolean + """ + Project which those settings apply to. + """ + project: Project + """ + Whether to send a Slack message when a top-level initiative comment is created. New settings default to true. Existing unset settings inherit the initiative update preference until first edited. + """ + slackInitiativeCommentCreated: Boolean + """ + Whether to send a Slack message when an initiative update is created. + """ + slackInitiativeUpdateCreated: Boolean + """ + Whether to send a Slack message when a new issue is added to triage. + """ + slackIssueAddedToTriage: Boolean + """ + Whether to send a Slack message when an issue is added to the custom view. + """ + slackIssueAddedToView: Boolean + """ + Whether to send a Slack message when a new issue is created for the project or the team. + """ + slackIssueCreated: Boolean + @deprecated(reason: "No longer in use. Use `slackIssueAddedToView` instead.") + """ + Whether to send a Slack message when a comment is created on any of the project or team's issues. + """ + slackIssueNewComment: Boolean + """ + Whether to send a Slack message when an SLA is breached. + """ + slackIssueSlaBreached: Boolean + """ + Whether to send a Slack message when an SLA is at high risk. + """ + slackIssueSlaHighRisk: Boolean + """ + Whether to send a Slack message when any of the project or team's issues has a change in status. + """ + slackIssueStatusChangedAll: Boolean + """ + Whether to send a Slack message when any of the project or team's issues change to completed or canceled. + """ + slackIssueStatusChangedDone: Boolean + """ + Whether to send a Slack message when a top-level project comment is created. New settings default to true. Existing unset settings inherit the project update preference until first edited. + """ + slackProjectCommentCreated: Boolean + """ + Whether to send a Slack message when a project update is created. + """ + slackProjectUpdateCreated: Boolean + """ + Whether to send a new project update to team Slack channels. + """ + slackProjectUpdateCreatedToTeam: Boolean + """ + Whether to send a new project update to workspace Slack channel. + """ + slackProjectUpdateCreatedToWorkspace: Boolean + """ + Team which those settings apply to. + """ + team: Team + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +input IntegrationsSettingsCreateInput { + """ + The type of view to which the integration settings context is associated with. + """ + contextViewType: ContextViewType + """ + The identifier of the custom view to create settings for. + """ + customViewId: String + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + The identifier of the initiative to create settings for. + """ + initiativeId: String + """ + Whether to send a Microsoft Teams message when a project update is created. + """ + microsoftTeamsProjectUpdateCreated: Boolean + """ + The identifier of the project to create settings for. + """ + projectId: String + """ + Whether to send a Slack message when a top-level initiative comment is created. + """ + slackInitiativeCommentCreated: Boolean + """ + Whether to send a Slack message when an initiative update is created. + """ + slackInitiativeUpdateCreated: Boolean + """ + Whether to send a Slack message when a new issue is added to triage. + """ + slackIssueAddedToTriage: Boolean + """ + Whether to send a Slack message when an issue is added to a view. + """ + slackIssueAddedToView: Boolean + """ + Whether to send a Slack message when a new issue is created for the project or the team. + """ + slackIssueCreated: Boolean + """ + Whether to send a Slack message when a comment is created on any of the project or team's issues. + """ + slackIssueNewComment: Boolean + """ + Whether to receive notification when an SLA has breached on Slack. + """ + slackIssueSlaBreached: Boolean + """ + Whether to send a Slack message when an SLA is at high risk. + """ + slackIssueSlaHighRisk: Boolean + """ + Whether to send a Slack message when any of the project or team's issues has a change in status. + """ + slackIssueStatusChangedAll: Boolean + """ + Whether to send a Slack message when any of the project or team's issues change to completed or canceled. + """ + slackIssueStatusChangedDone: Boolean + """ + Whether to send a Slack message when a top-level project comment is created. + """ + slackProjectCommentCreated: Boolean + """ + Whether to send a Slack message when a project update is created. + """ + slackProjectUpdateCreated: Boolean + """ + Whether to send a Slack message when a project update is created to team channels. + """ + slackProjectUpdateCreatedToTeam: Boolean + """ + Whether to send a Slack message when a project update is created to workspace channel. + """ + slackProjectUpdateCreatedToWorkspace: Boolean + """ + The identifier of the team to create settings for. + """ + teamId: String +} + +type IntegrationsSettingsPayload { + """ + The settings that were created or updated. + """ + integrationsSettings: IntegrationsSettings! + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +input IntegrationsSettingsUpdateInput { + """ + Whether to send a Microsoft Teams message when a project update is created. + """ + microsoftTeamsProjectUpdateCreated: Boolean + """ + Whether to send a Slack message when a top-level initiative comment is created. + """ + slackInitiativeCommentCreated: Boolean + """ + Whether to send a Slack message when an initiative update is created. + """ + slackInitiativeUpdateCreated: Boolean + """ + Whether to send a Slack message when a new issue is added to triage. + """ + slackIssueAddedToTriage: Boolean + """ + Whether to send a Slack message when an issue is added to a view. + """ + slackIssueAddedToView: Boolean + """ + Whether to send a Slack message when a new issue is created for the project or the team. + """ + slackIssueCreated: Boolean + """ + Whether to send a Slack message when a comment is created on any of the project or team's issues. + """ + slackIssueNewComment: Boolean + """ + Whether to receive notification when an SLA has breached on Slack. + """ + slackIssueSlaBreached: Boolean + """ + Whether to send a Slack message when an SLA is at high risk. + """ + slackIssueSlaHighRisk: Boolean + """ + Whether to send a Slack message when any of the project or team's issues has a change in status. + """ + slackIssueStatusChangedAll: Boolean + """ + Whether to send a Slack message when any of the project or team's issues change to completed or canceled. + """ + slackIssueStatusChangedDone: Boolean + """ + Whether to send a Slack message when a top-level project comment is created. + """ + slackProjectCommentCreated: Boolean + """ + Whether to send a Slack message when a project update is created. + """ + slackProjectUpdateCreated: Boolean + """ + Whether to send a Slack message when a project update is created to team channels. + """ + slackProjectUpdateCreatedToTeam: Boolean + """ + Whether to send a Slack message when a project update is created to workspace channel. + """ + slackProjectUpdateCreatedToWorkspace: Boolean +} + +input IntercomSettingsInput { + """ + Whether a ticket should be automatically reopened when its linked Linear issue is canceled. + """ + automateTicketReopeningOnCancellation: Boolean + """ + Whether a ticket should be automatically reopened when a comment is posted on its linked Linear issue + """ + automateTicketReopeningOnComment: Boolean + """ + Whether a ticket should be automatically reopened when its linked Linear issue is completed. + """ + automateTicketReopeningOnCompletion: Boolean + """ + Whether a ticket should be automatically reopened when its linked Linear project is canceled. + """ + automateTicketReopeningOnProjectCancellation: Boolean + """ + Whether a ticket should be automatically reopened when its linked Linear project is completed. + """ + automateTicketReopeningOnProjectCompletion: Boolean + """ + [INTERNAL] An optional destination team ID for issues created by automatic Intercom conversation intake. + """ + automaticConversationIntakeTeamId: String + """ + [ALPHA] Whether customer and customer requests should not be automatically created when conversations are linked to a Linear issue. + """ + disableCustomerRequestsAutoCreation: Boolean + """ + Whether Linear Agent should be enabled for this integration. + """ + enableAiIntake: Boolean + """ + Whether Linear Agent should process supported attachments from Intercom conversations during AI intake. When false, attachments are omitted from the prompt. + """ + enableAiIntakeAttachmentProcessing: Boolean + """ + [INTERNAL] Whether new Intercom conversations should automatically create Linear issues with Linear Agent. + """ + enableAutomaticConversationIntake: Boolean + """ + Whether an internal message should be added when someone comments on an issue. + """ + sendNoteOnComment: Boolean + """ + Whether an internal message should be added when a Linear issue changes status (for status types except completed or canceled). + """ + sendNoteOnStatusChange: Boolean +} + +""" +An issue is the core work item in Linear. Issues belong to a team, have a workflow status, can be assigned to users, carry a priority level, and can be organized into projects and cycles. Issues support sub-issues (parent-child hierarchy up to 10 levels deep), labels, due dates, estimates, and SLA tracking. They can also be linked to other issues via relations, attached to releases, and tracked through their full history of changes. +""" +type Issue implements Node { + """ + [Internal] The activity summary information for this issue. + """ + activitySummary: JSONObject + """ + The time at which the issue was added to a cycle. + """ + addedToCycleAt: DateTime + """ + The time at which the issue was added to a project. + """ + addedToProjectAt: DateTime + """ + The time at which the issue was added to a team. + """ + addedToTeamAt: DateTime + """ + [Internal] Agent sessions associated with the issue. + """ + agentSessions( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): AgentSessionConnection! + """ + [Internal] AI-generated analyses of the issue, keyed by feature, such as coding-agent suitability. Null if no analysis has run. + """ + aiAnalysis: JSONObject + """ + [Internal] AI prompt progresses associated with this issue. + """ + aiPromptProgresses( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned AI prompt progresses. + """ + filter: AiPromptProgressFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): AiPromptProgressConnection! + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The external user who requested creation of the Asks issue on behalf of the creator. + """ + asksExternalUserRequester: ExternalUser + """ + The internal user who requested creation of the Asks issue on behalf of the creator. + """ + asksRequester: User + """ + The user to whom the issue is assigned. Null if the issue is unassigned. + """ + assignee: User + """ + Attachments associated with the issue. + """ + attachments( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned attachments. + """ + filter: AttachmentFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): AttachmentConnection! + """ + The time at which the issue was automatically archived by the auto pruning process. + """ + autoArchivedAt: DateTime + """ + The time at which the issue was automatically closed by the auto pruning process. + """ + autoClosedAt: DateTime + """ + The order of the item in its column on the board. + """ + boardOrder: Float! + @deprecated(reason: "Will be removed in near future, please use `sortOrder` instead") + """ + The bot that created the issue, if applicable. + """ + botActor: ActorBot + """ + Suggested branch name for the issue. + """ + branchName: String! + """ + The time at which the issue was moved into canceled state. + """ + canceledAt: DateTime + """ + Children of the issue. + """ + children( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned issues. + """ + filter: IssueFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): IssueConnection! + """ + Comments associated with the issue, including inline comments on the issue's description. + """ + comments( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned comments. + """ + filter: CommentFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): CommentConnection! + """ + The time at which the issue was moved into completed state. + """ + completedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The user who created the issue. Null if the creator's account has been deleted or if the issue was created by an integration or system process. + """ + creator: User + """ + Returns the number of Attachment resources which are created by customer support ticketing systems (e.g. Zendesk). + """ + customerTicketCount: Int! + """ + The cycle that the issue is associated with. Null if the issue is not part of any cycle. + """ + cycle: Cycle + """ + The agent user that is delegated to work on this issue. Set when an AI agent has been assigned to perform work on this issue. Null if no agent is working on the issue. + """ + delegate: User + """ + The issue's description in markdown format. + """ + description: String + """ + [Internal] The issue's description content as YJS state. + """ + descriptionState: String + """ + [ALPHA] The document content representing this issue description. + """ + documentContent: DocumentContent + """ + Documents associated with the issue. + """ + documents( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned documents. + """ + filter: DocumentFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): DocumentConnection! + """ + The date at which the issue is due. + """ + dueDate: TimelessDate + """ + The estimate of the complexity of the issue. The specific scale used depends on the team's estimation configuration (e.g., points, T-shirt sizes). Null if no estimate has been set. + """ + estimate: Float + """ + The external user who created the issue. Set when the issue was created via an integration (e.g., Slack, Intercom) on behalf of a non-Linear user. Null if the issue was created by a Linear user. + """ + externalUserCreator: ExternalUser + """ + The users favorite associated with this issue. + """ + favorite: Favorite + """ + Attachments previously associated with the issue before being moved to another issue. + """ + formerAttachments( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned attachments. + """ + filter: AttachmentFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): AttachmentConnection! + """ + Customer needs previously associated with the issue before being moved to another issue. + """ + formerNeeds( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned needs. + """ + filter: CustomerNeedFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): CustomerNeedConnection! + """ + History entries associated with the issue. + """ + history( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): IssueHistoryConnection! + """ + The unique identifier of the entity. + """ + id: ID! + """ + Issue's human readable identifier (e.g. ENG-123). + """ + identifier: String! + """ + [Internal] Incoming product intelligence relation suggestions for the issue. + """ + incomingSuggestions( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): IssueSuggestionConnection! + """ + Whether this issue inherits shared access from its parent issue. + """ + inheritsSharedAccess: Boolean! + """ + Integration type that created this issue, if applicable. + """ + integrationSourceType: IntegrationService + """ + Inverse relations associated with this issue. + """ + inverseRelations( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): IssueRelationConnection! + """ + Identifiers of the labels associated with this issue. Can be used to query the labels directly. + """ + labelIds: [String!]! + """ + Labels associated with this issue. + """ + labels( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned issue labels. + """ + filter: IssueLabelFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): IssueLabelConnection! + """ + The last template that was applied to this issue. + """ + lastAppliedTemplate: Template + """ + Customer needs associated with the issue. + """ + needs( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned needs. + """ + filter: CustomerNeedFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): CustomerNeedConnection! + """ + The issue's unique number, scoped to the issue's team. Together with the team key, this forms the issue's human-readable identifier (e.g., ENG-123). + """ + number: Float! + """ + The parent of the issue. + """ + parent: Issue + """ + Previous identifiers of the issue if it has been moved between teams. + """ + previousIdentifiers: [String!]! + """ + The priority of the issue. 0 = No priority, 1 = Urgent, 2 = High, 3 = Medium, 4 = Low. + """ + priority: Float! + """ + Label for the priority. + """ + priorityLabel: String! + """ + The order of the item in relation to other items in the workspace, when ordered by priority. + """ + prioritySortOrder: Float! + """ + The project that the issue is associated with. Null if the issue is not part of any project. + """ + project: Project + """ + The project milestone that the issue is associated with. Null if the issue is not assigned to a specific milestone within its project. + """ + projectMilestone: ProjectMilestone + """ + Emoji reaction summary for the issue, grouped by emoji type. Contains the count and reacting user information for each emoji. + """ + reactionData: JSONObject! + """ + Reactions associated with the issue. + """ + reactions: [Reaction!]! + """ + The recurring issue template that created this issue. + """ + recurringIssueTemplate: Template + """ + Relations associated with this issue. + """ + relations( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): IssueRelationConnection! + """ + Releases associated with the issue. + """ + releases( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned releases. + """ + filter: ReleaseFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): ReleaseConnection! + """ + Shared access metadata for this issue. + """ + sharedAccess: IssueSharedAccess! + """ + The time at which the issue's SLA will breach. + """ + slaBreachesAt: DateTime + """ + The time at which the issue's SLA will enter high risk state. + """ + slaHighRiskAt: DateTime + """ + The time at which the issue's SLA will enter medium risk state. + """ + slaMediumRiskAt: DateTime + """ + The time at which the issue's SLA began. + """ + slaStartedAt: DateTime + """ + The type of SLA set on the issue. Calendar days or business days. + """ + slaType: String + """ + The user who snoozed the issue. + """ + snoozedBy: User + """ + The time until an issue will be snoozed in Triage view. + """ + snoozedUntilAt: DateTime + """ + The order of the item in relation to other items in the organization. Used for manual sorting in list views. + """ + sortOrder: Float! + """ + The comment that this issue was created from, when an issue is created from an existing comment. Null if the issue was not created from a comment. + """ + sourceComment: Comment + """ + The time at which the issue was moved into started state. + """ + startedAt: DateTime + """ + The time at which the issue entered triage. + """ + startedTriageAt: DateTime + """ + The workflow state (issue status) that the issue is currently in. Workflow states represent the issue's progress through the team's workflow, such as Triage, Todo, In Progress, Done, or Canceled. + """ + state: WorkflowState! + """ + The issue's workflow states over time. + """ + stateHistory( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + ): IssueStateSpanConnection! + """ + The order of the item in the sub-issue list. Only set if the issue has a parent. + """ + subIssueSortOrder: Float + """ + Users who are subscribed to the issue. + """ + subscribers( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned subscribers. + """ + filter: UserFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + Should query return disabled/suspended users (default: false). + """ + includeDisabled: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): UserConnection! + """ + [Internal] Product Intelligence suggestions for the issue. + """ + suggestions( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned suggestions. + """ + filter: IssueSuggestionFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): IssueSuggestionConnection! + """ + [Internal] The time at which the most recent suggestions for this issue were generated. + """ + suggestionsGeneratedAt: DateTime + """ + [Internal] AI-generated activity summary for this issue. + """ + summary: Summary + """ + The external services the issue is synced with. + """ + syncedWith: [ExternalEntityInfo!] + """ + The team that the issue belongs to. Every issue must belong to exactly one team, which determines the available workflow states, labels, and other team-specific configuration. + """ + team: Team! + """ + The issue's title. This is the primary human-readable summary of the work item. + """ + title: String! + """ + A flag that indicates whether the issue is in the trash bin. + """ + trashed: Boolean + """ + The time at which the issue left triage. + """ + triagedAt: DateTime + """ + [Internal] Whether this issue has been explicitly marked as trusted. + """ + trusted: Boolean + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + Issue URL. + """ + url: String! +} + +""" +A generic payload return from entity archive mutations. +""" +type IssueArchivePayload implements ArchivePayload { + """ + The archived/unarchived entity. Null if entity was deleted. + """ + entity: Issue + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +An issue assignment notification type. +""" +scalar IssueAssignedToYouNotificationType + +""" +Payload for an issue assigned to you notification. +""" +type IssueAssignedToYouNotificationWebhookPayload { + """ + The actor who caused the notification. + """ + actor: UserChildWebhookPayload + """ + The ID of the actor who caused the notification. + """ + actorId: String + """ + The time at which the entity was archived. + """ + archivedAt: String + """ + The time at which the entity was created. + """ + createdAt: String! + """ + The ID of the external user who caused the notification. + """ + externalUserActorId: String + """ + The ID of the entity. + """ + id: String! + """ + The issue this notification belongs to. + """ + issue: IssueWithDescriptionChildWebhookPayload! + """ + The ID of the issue this notification belongs to. + """ + issueId: String! + """ + An issue assigned to you notification type. + """ + type: IssueAssignedToYouNotificationType! + """ + The time at which the entity was updated. + """ + updatedAt: String! + """ + The ID of the user who received the notification. + """ + userId: String! +} + +""" +Input for creating multiple issues at once in a batch operation. Up to 50 issues can be created in a single batch. +""" +input IssueBatchCreateInput { + """ + The issues to create. + """ + issues: [IssueCreateInput!]! +} + +""" +The result of a batch issue mutation, containing the updated issues and a success indicator. +""" +type IssueBatchPayload { + """ + The issues that were updated. + """ + issues: [Issue!]! + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Certain properties of an issue. +""" +type IssueChildWebhookPayload { + """ + The ID of the issue. + """ + id: String! + """ + The identifier of the issue. + """ + identifier: String! + """ + The ID of the team that the issue belongs to. + """ + team: TeamChildWebhookPayload! + """ + The ID of the team that the issue belongs to. + """ + teamId: String! + """ + The title of the issue. + """ + title: String! + """ + The URL of the issue. + """ + url: String! +} + +""" +Issue filtering options. +""" +input IssueCollectionFilter { + """ + [Internal] Comparator for the issue's accumulatedStateUpdatedAt date. + """ + accumulatedStateUpdatedAt: NullableDateComparator + """ + Filters that the issue's activities must satisfy. + """ + activity: ActivityCollectionFilter + """ + Comparator for the issues added to cycle at date. + """ + addedToCycleAt: NullableDateComparator + """ + Comparator for the period when issue was added to a cycle. + """ + addedToCyclePeriod: CyclePeriodComparator + """ + [Internal] Age (created -> now) comparator, defined if the issue is still open. + """ + ageTime: NullableDurationComparator + """ + Compound filters, all of which need to be matched by the issue. + """ + and: [IssueCollectionFilter!] + """ + Comparator for the issues archived at date. + """ + archivedAt: NullableDateComparator + """ + Filters that the issues assignee must satisfy. + """ + assignee: NullableUserFilter + """ + Filters that the issues attachments must satisfy. + """ + attachments: AttachmentCollectionFilter + """ + Comparator for the issues auto archived at date. + """ + autoArchivedAt: NullableDateComparator + """ + Comparator for the issues auto closed at date. + """ + autoClosedAt: NullableDateComparator + """ + Comparator for the issues canceled at date. + """ + canceledAt: NullableDateComparator + """ + Filters that the child issues must satisfy. + """ + children: IssueCollectionFilter + """ + Filters that the issues comments must satisfy. + """ + comments: CommentCollectionFilter + """ + Comparator for the issues completed at date. + """ + completedAt: NullableDateComparator + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Filters that the issues creator must satisfy. + """ + creator: NullableUserFilter + """ + Count of customers + """ + customerCount: NumberComparator + """ + Count of important customers + """ + customerImportantCount: NumberComparator + """ + Filters that the issues cycle must satisfy. + """ + cycle: NullableCycleFilter + """ + [Internal] Cycle time (started -> completed) comparator. + """ + cycleTime: NullableDurationComparator + """ + Filters that the issue's delegated agent must satisfy. + """ + delegate: NullableUserFilter + """ + Comparator for the issues description. + """ + description: NullableStringComparator + """ + Comparator for the issues due date. + """ + dueDate: NullableTimelessDateComparator + """ + Comparator for the issues estimate. + """ + estimate: EstimateComparator + """ + Filters that needs to be matched by all issues. + """ + every: IssueFilter + """ + [Internal] Comparator for filtering issues bucketed as having active agent sessions, no closed agent pull requests, and no merged agent pull requests. + """ + hasActiveAgentSessions: RelationExistsComparator + """ + Comparator for filtering issues which are blocked. + """ + hasBlockedByRelations: RelationExistsComparator + """ + Comparator for filtering issues which are blocking. + """ + hasBlockingRelations: RelationExistsComparator + """ + [Internal] Comparator for filtering issues bucketed as having all agent sessions dismissed or closed, and no merged agent pull requests. + """ + hasDismissedAgentSessions: RelationExistsComparator + """ + Comparator for filtering issues which are duplicates. + """ + hasDuplicateRelations: RelationExistsComparator + """ + [Internal] Comparator for filtering issues bucketed as having an errored agent session, no active sessions, and no merged agent pull requests. + """ + hasErroredAgentSessions: RelationExistsComparator + """ + [Internal] Comparator for filtering issues which have agent-session-linked pull requests that were merged. + """ + hasMergedAgentPullRequests: RelationExistsComparator + """ + Comparator for filtering issues with relations. + """ + hasRelatedRelations: RelationExistsComparator + """ + Comparator for filtering issues which have been shared with users outside of the team. + """ + hasSharedUsers: RelationExistsComparator + """ + [Internal] Comparator for filtering issues which have suggested assignees. + """ + hasSuggestedAssignees: RelationExistsComparator + """ + [Internal] Comparator for filtering issues which have suggested labels. + """ + hasSuggestedLabels: RelationExistsComparator + """ + [Internal] Comparator for filtering issues which have suggested projects. + """ + hasSuggestedProjects: RelationExistsComparator + """ + [Internal] Comparator for filtering issues which have suggested related issues. + """ + hasSuggestedRelatedIssues: RelationExistsComparator + """ + [Internal] Comparator for filtering issues which have suggested similar issues. + """ + hasSuggestedSimilarIssues: RelationExistsComparator + """ + [Internal] Comparator for filtering issues which have suggested teams. + """ + hasSuggestedTeams: RelationExistsComparator + """ + Comparator for the identifier. + """ + id: IssueIDComparator + """ + Filters that issue labels must satisfy. + """ + labels: IssueLabelCollectionFilter + """ + Filters that the last applied template must satisfy. + """ + lastAppliedTemplate: NullableTemplateFilter + """ + [Internal] Lead time (created -> completed) comparator. + """ + leadTime: NullableDurationComparator + """ + Comparator for the collection length. + """ + length: NumberComparator + """ + Filters that the issue's customer needs must satisfy. + """ + needs: CustomerNeedCollectionFilter + """ + Comparator for the issues number. + """ + number: NumberComparator + """ + Compound filters, one of which need to be matched by the issue. + """ + or: [IssueCollectionFilter!] + """ + Filters that the issue parent must satisfy. + """ + parent: NullableIssueFilter + """ + Comparator for the issues priority. 0 = No priority, 1 = Urgent, 2 = High, 3 = Medium, 4 = Low. + """ + priority: NullableNumberComparator + """ + Filters that the issues project must satisfy. + """ + project: NullableProjectFilter + """ + Filters that the issues project milestone must satisfy. + """ + projectMilestone: NullableProjectMilestoneFilter + """ + Filters that the issues reactions must satisfy. + """ + reactions: ReactionCollectionFilter + """ + [ALPHA] Filters that the recurring issue template must satisfy. + """ + recurringIssueTemplate: NullableTemplateFilter + """ + Filters that the issue's releases must satisfy. + """ + releases: ReleaseCollectionFilter + """ + [Internal] Comparator for the issues content. + """ + searchableContent: ContentComparator + """ + Filters that users the issue has been shared with must satisfy. + """ + sharedWith: UserCollectionFilter + """ + Comparator for the issue's SLA breach date. + """ + slaBreachesAt: NullableDateComparator + """ + Comparator for the issues sla status. + """ + slaStatus: SlaStatusComparator + """ + Filters that the issues snoozer must satisfy. + """ + snoozedBy: NullableUserFilter + """ + Comparator for the issues snoozed until date. + """ + snoozedUntilAt: NullableDateComparator + """ + Filters that needs to be matched by some issues. + """ + some: IssueFilter + """ + Filters that the source must satisfy. + """ + sourceMetadata: SourceMetadataComparator + """ + Comparator for the issues started at date. + """ + startedAt: NullableDateComparator + """ + Filters that the issues state must satisfy. + """ + state: WorkflowStateFilter + """ + Filters that issue subscribers must satisfy. + """ + subscribers: UserCollectionFilter + """ + [Internal] Filters that the issue's suggestions must satisfy. + """ + suggestions: IssueSuggestionCollectionFilter + """ + Filters that the issues team must satisfy. + """ + team: TeamFilter + """ + Comparator for the issues title. + """ + title: StringComparator + """ + [Internal] Triage time (entered triaged -> triaged) comparator. + """ + triageTime: NullableDurationComparator + """ + Comparator for the issues triaged at date. + """ + triagedAt: NullableDateComparator + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +An issue comment mention notification type. +""" +scalar IssueCommentMentionNotificationType + +""" +Payload for an issue comment mention notification. +""" +type IssueCommentMentionNotificationWebhookPayload { + """ + The actor who caused the notification. + """ + actor: UserChildWebhookPayload + """ + The ID of the actor who caused the notification. + """ + actorId: String + """ + The time at which the entity was archived. + """ + archivedAt: String + """ + The comment this notification belongs to. + """ + comment: CommentChildWebhookPayload! + """ + The ID of the comment this notification belongs to. + """ + commentId: String! + """ + The time at which the entity was created. + """ + createdAt: String! + """ + The ID of the external user who caused the notification. + """ + externalUserActorId: String + """ + The ID of the entity. + """ + id: String! + """ + The issue this notification belongs to. + """ + issue: IssueWithDescriptionChildWebhookPayload! + """ + The ID of the issue this notification belongs to. + """ + issueId: String! + """ + The parent comment for the comment this notification belongs to. + """ + parentComment: CommentChildWebhookPayload + """ + The ID of the parent comment for the comment this notification belongs to. + """ + parentCommentId: String + """ + An issue comment mention notification type. + """ + type: IssueCommentMentionNotificationType! + """ + The time at which the entity was updated. + """ + updatedAt: String! + """ + The ID of the user who received the notification. + """ + userId: String! +} + +""" +An issue comment reaction notification type. +""" +scalar IssueCommentReactionNotificationType + +""" +Payload for an issue comment reaction notification. +""" +type IssueCommentReactionNotificationWebhookPayload { + """ + The actor who caused the notification. + """ + actor: UserChildWebhookPayload + """ + The ID of the actor who caused the notification. + """ + actorId: String + """ + The time at which the entity was archived. + """ + archivedAt: String + """ + The comment this notification belongs to. + """ + comment: CommentChildWebhookPayload! + """ + The ID of the comment this notification belongs to. + """ + commentId: String! + """ + The time at which the entity was created. + """ + createdAt: String! + """ + The ID of the external user who caused the notification. + """ + externalUserActorId: String + """ + The ID of the entity. + """ + id: String! + """ + The issue this notification belongs to. + """ + issue: IssueWithDescriptionChildWebhookPayload! + """ + The ID of the issue this notification belongs to. + """ + issueId: String! + """ + The parent comment for the comment this notification belongs to. + """ + parentComment: CommentChildWebhookPayload + """ + The ID of the parent comment for the comment this notification belongs to. + """ + parentCommentId: String + """ + The emoji of the reaction this notification is for. + """ + reactionEmoji: String! + """ + An issue comment reaction notification type. + """ + type: IssueCommentReactionNotificationType! + """ + The time at which the entity was updated. + """ + updatedAt: String! + """ + The ID of the user who received the notification. + """ + userId: String! +} + +type IssueConnection { + edges: [IssueEdge!]! + nodes: [Issue!]! + pageInfo: PageInfo! +} + +""" +Input for creating a new issue. At minimum, a team must be specified. A title is required unless a template is provided. All other fields are optional and will use defaults from the team or template if not specified. +""" +input IssueCreateInput { + """ + The identifier of the user to assign the issue to. + """ + assigneeId: String + """ + The time at which the issue was completed (e.g. if importing from another system). Must be a time in the past and after createdAt. Cannot be provided with an incompatible workflow state. + """ + completedAt: DateTime + """ + Create issue as a user with the provided name. This option is only available to OAuth applications creating issues in `actor=app` mode. + """ + createAsUser: String + """ + The time at which the issue was created (e.g. if importing from another system). Must be a time in the past. If none is provided, the backend will generate the time as now. + """ + createdAt: DateTime + """ + The cycle associated with the issue. + """ + cycleId: String + """ + The identifier of the agent user to delegate the issue to. + """ + delegateId: String + """ + The issue description in markdown format. + """ + description: String + """ + [Internal] The issue description as a Prosemirror document. + """ + descriptionData: JSON + """ + Provide an external user avatar URL. Can only be used in conjunction with the `createAsUser` options. This option is only available to OAuth applications creating comments in `actor=app` mode. + """ + displayIconUrl: String + """ + The date at which the issue is due. + """ + dueDate: TimelessDate + """ + The estimated complexity of the issue. + """ + estimate: Int + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + [Internal] Whether this issue should inherit shared access from its parent issue. Set to false to opt out of automatic shared access inheritance when creating a sub-issue. + """ + inheritsSharedAccess: Boolean + """ + The identifiers of the issue labels associated with this ticket. + """ + labelIds: [String!] + """ + The ID of the last template applied to the issue. + """ + lastAppliedTemplateId: String + """ + The identifier of the parent issue. Can be a UUID or issue identifier (e.g., 'LIN-123'). + """ + parentId: String + """ + Whether the passed sort order should be preserved. + """ + preserveSortOrderOnCreate: Boolean + """ + The priority of the issue. 0 = No priority, 1 = Urgent, 2 = High, 3 = Medium, 4 = Low. + """ + priority: Int + """ + The position of the issue related to other issues, when ordered by priority. + """ + prioritySortOrder: Float + """ + The project associated with the issue. Can be a UUID or project identifier (e.g., 'P-LIN-123'). + """ + projectId: String + """ + The project milestone associated with the issue. + """ + projectMilestoneId: String + """ + The comment the issue is referencing. + """ + referenceCommentId: String + """ + The identifiers of the releases to associate with this issue. + """ + releaseIds: [String!] + """ + [Internal] The time at which an issue will be considered in breach of SLA. + """ + slaBreachesAt: DateTime + """ + [Internal] The time at which the issue's SLA was started. + """ + slaStartedAt: DateTime + """ + The SLA day count type for the issue. Whether SLA should be business days only or calendar days (default). + """ + slaType: SLADayCountType + """ + The position of the issue related to other issues. + """ + sortOrder: Float + """ + The comment the issue is created from. + """ + sourceCommentId: String + """ + [Internal] The pull request comment the issue is created from. + """ + sourcePullRequestCommentId: String + """ + The team state of the issue. + """ + stateId: String + """ + The position of the issue in parent's sub-issue list. + """ + subIssueSortOrder: Float + """ + The identifiers of the users subscribing to this ticket. + """ + subscriberIds: [String!] + """ + The identifier of the team associated with the issue. + """ + teamId: String! + """ + The identifier of a template the issue should be created from. If other values are provided in the input, they will override template values. + """ + templateId: String + """ + The title of the issue. + """ + title: String + """ + Whether to use the default template for the team. When set to true, the default template of this team based on user's membership will be applied. + """ + useDefaultTemplate: Boolean +} + +""" +[Internal] A draft issue that has not yet been created as a full issue. Drafts allow users to prepare issue details (title, description, labels, assignee, etc.) before committing them. Drafts belong to a team and a creator, and support a parent-child hierarchy similar to issues. A draft can have either a parent draft or a parent issue, but not both. +""" +type IssueDraft implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + Identifier of the user assigned to the draft. Can be used to query the user directly. Null if the draft is unassigned. + """ + assigneeId: String + """ + Serialized array of JSONs representing attachments. + """ + attachments: JSONObject + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The user who created the draft. + """ + creator: User! + """ + Identifier of the cycle associated with the draft. Can be used to query the cycle directly. Null if no cycle is assigned. + """ + cycleId: String + """ + The agent user delegated to work on the issue being drafted. + """ + delegateId: String + """ + The draft's description in markdown format. + """ + description: String + """ + [Internal] The draft's description as a Prosemirror document. + """ + descriptionData: JSON + """ + The date at which the issue would be due. + """ + dueDate: TimelessDate + """ + The estimate of the complexity of the draft. Null if no estimate has been set. + """ + estimate: Float + """ + The unique identifier of the entity. + """ + id: ID! + """ + Identifiers of the labels added to the draft. These labels will be applied to the issue when the draft is published. + """ + labelIds: [String!]! + """ + Serialized array of JSONs representing customer needs. + """ + needs: JSONObject + """ + The parent draft of the draft. Set when this draft represents a sub-issue of another draft. Null if this is a top-level draft or has a parent issue instead. + """ + parent: IssueDraft + """ + The ID of the parent issue draft, if any. + """ + parentId: String + """ + The parent issue of the draft. Set when this draft represents a sub-issue that will be created under an existing issue. Null if this is a top-level draft or has a parent draft instead. + """ + parentIssue: Issue + """ + The ID of the parent issue, if any. + """ + parentIssueId: String + """ + The priority of the draft. 0 = No priority, 1 = Urgent, 2 = High, 3 = Normal, 4 = Low. + """ + priority: Float! + """ + Label for the priority. + """ + priorityLabel: String! + """ + Identifier of the project associated with the draft. Can be used to query the project directly. Null if no project is assigned. + """ + projectId: String + """ + Identifier of the project milestone associated with the draft. Can be used to query the project milestone directly. Null if no milestone is assigned. + """ + projectMilestoneId: String + """ + Serialized issue relations to recreate when the draft is published. + """ + relations: JSONObject! + """ + Identifiers of the releases associated with the draft. These releases will be linked to the issue when the draft is published. + """ + releaseIds: [String!]! + """ + Serialized array of JSONs representing the recurring issue's schedule. + """ + schedule: JSONObject + """ + Identifier of the comment that the draft was created from. Set when a draft is created from an existing comment. Null if the draft was not created from a comment. + """ + sourceCommentId: String + """ + Identifier of the workflow state associated with the draft. Can be used to query the workflow state directly. Determines the initial status the issue will have when the draft is published. + """ + stateId: String! + """ + The order of items in the sub-draft list. Only set if the draft has `parent` set. + """ + subIssueSortOrder: Float + """ + Identifier of the team associated with the draft. Can be used to query the team directly. + """ + teamId: String! + """ + The draft's title. This will become the issue's title when the draft is published. + """ + title: String! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +type IssueDraftConnection { + edges: [IssueDraftEdge!]! + nodes: [IssueDraft!]! + pageInfo: PageInfo! +} + +type IssueDraftEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: IssueDraft! +} + +type IssueEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: Issue! +} + +""" +An issue emoji reaction notification type. +""" +scalar IssueEmojiReactionNotificationType + +""" +Payload for an issue emoji reaction notification. +""" +type IssueEmojiReactionNotificationWebhookPayload { + """ + The actor who caused the notification. + """ + actor: UserChildWebhookPayload + """ + The ID of the actor who caused the notification. + """ + actorId: String + """ + The time at which the entity was archived. + """ + archivedAt: String + """ + The time at which the entity was created. + """ + createdAt: String! + """ + The ID of the external user who caused the notification. + """ + externalUserActorId: String + """ + The ID of the entity. + """ + id: String! + """ + The issue this notification belongs to. + """ + issue: IssueWithDescriptionChildWebhookPayload! + """ + The ID of the issue this notification belongs to. + """ + issueId: String! + """ + The emoji of the reaction this notification is for. + """ + reactionEmoji: String! + """ + An issue emoji reaction notification type. + """ + type: IssueEmojiReactionNotificationType! + """ + The time at which the entity was updated. + """ + updatedAt: String! + """ + The ID of the user who received the notification. + """ + userId: String! +} + +""" +Issue filtering options. +""" +input IssueFilter { + """ + [Internal] Comparator for the issue's accumulatedStateUpdatedAt date. + """ + accumulatedStateUpdatedAt: NullableDateComparator + """ + Filters that the issue's activities must satisfy. + """ + activity: ActivityCollectionFilter + """ + Comparator for the issues added to cycle at date. + """ + addedToCycleAt: NullableDateComparator + """ + Comparator for the period when issue was added to a cycle. + """ + addedToCyclePeriod: CyclePeriodComparator + """ + [Internal] Age (created -> now) comparator, defined if the issue is still open. + """ + ageTime: NullableDurationComparator + """ + Compound filters, all of which need to be matched by the issue. + """ + and: [IssueFilter!] + """ + Comparator for the issues archived at date. + """ + archivedAt: NullableDateComparator + """ + Filters that the issues assignee must satisfy. + """ + assignee: NullableUserFilter + """ + Filters that the issues attachments must satisfy. + """ + attachments: AttachmentCollectionFilter + """ + Comparator for the issues auto archived at date. + """ + autoArchivedAt: NullableDateComparator + """ + Comparator for the issues auto closed at date. + """ + autoClosedAt: NullableDateComparator + """ + Comparator for the issues canceled at date. + """ + canceledAt: NullableDateComparator + """ + Filters that the child issues must satisfy. + """ + children: IssueCollectionFilter + """ + Filters that the issues comments must satisfy. + """ + comments: CommentCollectionFilter + """ + Comparator for the issues completed at date. + """ + completedAt: NullableDateComparator + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Filters that the issues creator must satisfy. + """ + creator: NullableUserFilter + """ + Count of customers + """ + customerCount: NumberComparator + """ + Count of important customers + """ + customerImportantCount: NumberComparator + """ + Filters that the issues cycle must satisfy. + """ + cycle: NullableCycleFilter + """ + [Internal] Cycle time (started -> completed) comparator. + """ + cycleTime: NullableDurationComparator + """ + Filters that the issue's delegated agent must satisfy. + """ + delegate: NullableUserFilter + """ + Comparator for the issues description. + """ + description: NullableStringComparator + """ + Comparator for the issues due date. + """ + dueDate: NullableTimelessDateComparator + """ + Comparator for the issues estimate. + """ + estimate: EstimateComparator + """ + [Internal] Comparator for filtering issues bucketed as having active agent sessions, no closed agent pull requests, and no merged agent pull requests. + """ + hasActiveAgentSessions: RelationExistsComparator + """ + Comparator for filtering issues which are blocked. + """ + hasBlockedByRelations: RelationExistsComparator + """ + Comparator for filtering issues which are blocking. + """ + hasBlockingRelations: RelationExistsComparator + """ + [Internal] Comparator for filtering issues bucketed as having all agent sessions dismissed or closed, and no merged agent pull requests. + """ + hasDismissedAgentSessions: RelationExistsComparator + """ + Comparator for filtering issues which are duplicates. + """ + hasDuplicateRelations: RelationExistsComparator + """ + [Internal] Comparator for filtering issues bucketed as having an errored agent session, no active sessions, and no merged agent pull requests. + """ + hasErroredAgentSessions: RelationExistsComparator + """ + [Internal] Comparator for filtering issues which have agent-session-linked pull requests that were merged. + """ + hasMergedAgentPullRequests: RelationExistsComparator + """ + Comparator for filtering issues with relations. + """ + hasRelatedRelations: RelationExistsComparator + """ + Comparator for filtering issues which have been shared with users outside of the team. + """ + hasSharedUsers: RelationExistsComparator + """ + [Internal] Comparator for filtering issues which have suggested assignees. + """ + hasSuggestedAssignees: RelationExistsComparator + """ + [Internal] Comparator for filtering issues which have suggested labels. + """ + hasSuggestedLabels: RelationExistsComparator + """ + [Internal] Comparator for filtering issues which have suggested projects. + """ + hasSuggestedProjects: RelationExistsComparator + """ + [Internal] Comparator for filtering issues which have suggested related issues. + """ + hasSuggestedRelatedIssues: RelationExistsComparator + """ + [Internal] Comparator for filtering issues which have suggested similar issues. + """ + hasSuggestedSimilarIssues: RelationExistsComparator + """ + [Internal] Comparator for filtering issues which have suggested teams. + """ + hasSuggestedTeams: RelationExistsComparator + """ + Comparator for the identifier. + """ + id: IssueIDComparator + """ + Filters that issue labels must satisfy. + """ + labels: IssueLabelCollectionFilter + """ + Filters that the last applied template must satisfy. + """ + lastAppliedTemplate: NullableTemplateFilter + """ + [Internal] Lead time (created -> completed) comparator. + """ + leadTime: NullableDurationComparator + """ + Filters that the issue's customer needs must satisfy. + """ + needs: CustomerNeedCollectionFilter + """ + Comparator for the issues number. + """ + number: NumberComparator + """ + Compound filters, one of which need to be matched by the issue. + """ + or: [IssueFilter!] + """ + Filters that the issue parent must satisfy. + """ + parent: NullableIssueFilter + """ + Comparator for the issues priority. 0 = No priority, 1 = Urgent, 2 = High, 3 = Medium, 4 = Low. + """ + priority: NullableNumberComparator + """ + Filters that the issues project must satisfy. + """ + project: NullableProjectFilter + """ + Filters that the issues project milestone must satisfy. + """ + projectMilestone: NullableProjectMilestoneFilter + """ + Filters that the issues reactions must satisfy. + """ + reactions: ReactionCollectionFilter + """ + [ALPHA] Filters that the recurring issue template must satisfy. + """ + recurringIssueTemplate: NullableTemplateFilter + """ + Filters that the issue's releases must satisfy. + """ + releases: ReleaseCollectionFilter + """ + [Internal] Comparator for the issues content. + """ + searchableContent: ContentComparator + """ + Filters that users the issue has been shared with must satisfy. + """ + sharedWith: UserCollectionFilter + """ + Comparator for the issue's SLA breach date. + """ + slaBreachesAt: NullableDateComparator + """ + Comparator for the issues sla status. + """ + slaStatus: SlaStatusComparator + """ + Filters that the issues snoozer must satisfy. + """ + snoozedBy: NullableUserFilter + """ + Comparator for the issues snoozed until date. + """ + snoozedUntilAt: NullableDateComparator + """ + Filters that the source must satisfy. + """ + sourceMetadata: SourceMetadataComparator + """ + Comparator for the issues started at date. + """ + startedAt: NullableDateComparator + """ + Filters that the issues state must satisfy. + """ + state: WorkflowStateFilter + """ + Filters that issue subscribers must satisfy. + """ + subscribers: UserCollectionFilter + """ + [Internal] Filters that the issue's suggestions must satisfy. + """ + suggestions: IssueSuggestionCollectionFilter + """ + Filters that the issues team must satisfy. + """ + team: TeamFilter + """ + Comparator for the issues title. + """ + title: StringComparator + """ + [Internal] Triage time (entered triaged -> triaged) comparator. + """ + triageTime: NullableDurationComparator + """ + Comparator for the issues triaged at date. + """ + triagedAt: NullableDateComparator + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +The result of an AI-generated issue filter suggestion based on a text prompt. +""" +type IssueFilterSuggestionPayload { + """ + The json filter that is suggested. + """ + filter: JSONObject + """ + The log id of the prompt, that created this filter. + """ + logId: String +} + +""" +A record of changes to an issue. Each history entry captures one or more property changes made to an issue within a short grouping window by the same actor. History entries track changes to fields such as title, assignee, status, priority, project, cycle, labels, due date, estimate, parent issue, and more. They also record metadata about what triggered the change (e.g., a user action, workflow automation, triage rule, or integration). +""" +type IssueHistory implements Node { + """ + The actor that performed the actions. This field may be empty in the case of integrations or automations. + """ + actor: User + """ + Identifier of the user who made these changes. Can be used to query the user directly. Null if the change was made by an integration, automation, or system process. + """ + actorId: String + """ + The actors that performed the actions. This field may be empty in the case of integrations or automations. + """ + actors: [User!] @deprecated(reason: "Use `actor` and `descriptionUpdatedBy` instead.") + """ + ID's of labels that were added. + """ + addedLabelIds: [String!] + """ + The labels that were added to the issue. + """ + addedLabels: [IssueLabel!] + """ + ID's of releases that the issue was added to. + """ + addedToReleaseIds: [String!] + """ + The releases that the issue was added to. + """ + addedToReleases: [Release!] + """ + Whether the issue was archived (true) or unarchived (false) in this change. Null if the archive status was not changed. + """ + archived: Boolean + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The linked attachment. + """ + attachment: Attachment + """ + Identifier of the attachment that was linked to or unlinked from the issue. Can be used to query the attachment directly. Null if no attachment change occurred. + """ + attachmentId: String + """ + Whether the issue was auto-archived. + """ + autoArchived: Boolean + """ + Whether the issue was auto-closed. + """ + autoClosed: Boolean + """ + The bot that performed the action. + """ + botActor: ActorBot + """ + [Internal] Serialized JSON representing changes for certain non-relational properties. + """ + changes: JSONObject + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + [Deprecated] Identifier of the customer need that was linked to the issue. Use customer need related arrays in changes instead. + """ + customerNeedId: String + """ + The actors that edited the description of the issue, if any. + """ + descriptionUpdatedBy: [User!] + """ + The user that was unassigned from the issue. + """ + fromAssignee: User + """ + Identifier of the user from whom the issue was re-assigned. Can be used to query the user directly. Null if the assignee was not changed or the issue was previously unassigned. + """ + fromAssigneeId: String + """ + The cycle that the issue was moved from. + """ + fromCycle: Cycle + """ + Identifier of the previous cycle of the issue. Can be used to query the cycle directly. Null if the cycle was not changed or the issue was not in a cycle. + """ + fromCycleId: String + """ + The app user from whom the issue delegation was transferred. + """ + fromDelegate: User + """ + What the due date was changed from. + """ + fromDueDate: TimelessDate + """ + What the estimate was changed from. + """ + fromEstimate: Float + """ + The parent issue that the issue was moved from. + """ + fromParent: Issue + """ + Identifier of the previous parent issue. Can be used to query the issue directly. Null if the parent was not changed or the issue previously had no parent. + """ + fromParentId: String + """ + What the priority was changed from. + """ + fromPriority: Float + """ + The project that the issue was moved from. + """ + fromProject: Project + """ + Identifier of the previous project of the issue. Can be used to query the project directly. Null if the project was not changed or the issue was not in a project. + """ + fromProjectId: String + """ + The project milestone that the issue was moved from. + """ + fromProjectMilestone: ProjectMilestone + """ + Whether the issue had previously breached its SLA. + """ + fromSlaBreached: Boolean + """ + The SLA breach time that was previously set on the issue. + """ + fromSlaBreachesAt: DateTime + """ + The time at which the issue's SLA was previously started. + """ + fromSlaStartedAt: DateTime + """ + The type of SLA that was previously set on the issue. + """ + fromSlaType: String + """ + The state that the issue was moved from. + """ + fromState: WorkflowState + """ + Identifier of the previous workflow state (issue status) of the issue. Can be used to query the workflow state directly. Null if the status was not changed. + """ + fromStateId: String + """ + The team that the issue was moved from. + """ + fromTeam: Team + """ + Identifier of the team from which the issue was moved. Can be used to query the team directly. Null if the team was not changed. + """ + fromTeamId: String + """ + What the title was changed from. + """ + fromTitle: String + """ + The unique identifier of the entity. + """ + id: ID! + """ + The issue that was changed. + """ + issue: Issue! + """ + The import record. + """ + issueImport: IssueImport + """ + Changed issue relationships. + """ + relationChanges: [IssueRelationHistoryPayload!] + """ + ID's of releases that the issue was removed from. + """ + removedFromReleaseIds: [String!] + """ + The releases that the issue was removed from. + """ + removedFromReleases: [Release!] + """ + ID's of labels that were removed. + """ + removedLabelIds: [String!] + """ + The labels that were removed from the issue. + """ + removedLabels: [IssueLabel!] + """ + The user that was assigned to the issue. + """ + toAssignee: User + """ + Identifier of the user to whom the issue was assigned. Can be used to query the user directly. Null if the assignee was not changed or the issue was unassigned. + """ + toAssigneeId: String + """ + The new project created from the issue. + """ + toConvertedProject: Project + """ + Identifier of the new project that was created by converting this issue to a project. Can be used to query the project directly. Null if the issue was not converted to a project. + """ + toConvertedProjectId: String + """ + The cycle that the issue was moved to. + """ + toCycle: Cycle + """ + Identifier of the new cycle of the issue. Can be used to query the cycle directly. Null if the cycle was not changed or the issue was removed from a cycle. + """ + toCycleId: String + """ + The app user to whom the issue delegation was transferred. + """ + toDelegate: User + """ + What the due date was changed to. + """ + toDueDate: TimelessDate + """ + What the estimate was changed to. + """ + toEstimate: Float + """ + The parent issue that the issue was moved to. + """ + toParent: Issue + """ + Identifier of the new parent issue. Can be used to query the issue directly. Null if the parent was not changed or the issue was removed from its parent. + """ + toParentId: String + """ + What the priority was changed to. + """ + toPriority: Float + """ + The project that the issue was moved to. + """ + toProject: Project + """ + Identifier of the new project of the issue. Can be used to query the project directly. Null if the project was not changed or the issue was removed from a project. + """ + toProjectId: String + """ + The project milestone that the issue was moved to. + """ + toProjectMilestone: ProjectMilestone + """ + Whether the issue has now breached its SLA. + """ + toSlaBreached: Boolean + """ + The SLA breach time that is now set on the issue. + """ + toSlaBreachesAt: DateTime + """ + The time at which the issue's SLA is now started. + """ + toSlaStartedAt: DateTime + """ + The type of SLA that is now set on the issue. + """ + toSlaType: String + """ + The state that the issue was moved to. + """ + toState: WorkflowState + """ + Identifier of the new workflow state (issue status) of the issue. Can be used to query the workflow state directly. Null if the status was not changed. + """ + toStateId: String + """ + The team that the issue was moved to. + """ + toTeam: Team + """ + Identifier of the team to which the issue was moved. Can be used to query the team directly. Null if the team was not changed. + """ + toTeamId: String + """ + What the title was changed to. + """ + toTitle: String + """ + Whether the issue was trashed or un-trashed. + """ + trashed: Boolean + """ + Boolean indicating if the issue was auto-assigned using the triage responsibility feature. + """ + triageResponsibilityAutoAssigned: Boolean + """ + The users that were notified of the issue. + """ + triageResponsibilityNotifiedUsers: [User!] + """ + The team that triggered the triage responsibility action. + """ + triageResponsibilityTeam: Team + """ + [INTERNAL] Metadata about the triage rule that made changes to the issue. + """ + triageRuleMetadata: IssueHistoryTriageRuleMetadata + @deprecated(reason: "Use `workflowMetadata` instead.") + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + Whether the issue's description was updated. + """ + updatedDescription: Boolean + """ + [INTERNAL] Metadata about the workflow that made changes to the issue. + """ + workflowMetadata: IssueHistoryWorkflowMetadata +} + +type IssueHistoryConnection { + edges: [IssueHistoryEdge!]! + nodes: [IssueHistory!]! + pageInfo: PageInfo! +} + +type IssueHistoryEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: IssueHistory! +} + +""" +An error that occurred during triage rule execution, such as a conflicting label assignment or an invalid property value. Contains the error type and optionally the property that caused the failure. +""" +type IssueHistoryTriageRuleError { + """ + Whether the conflict was for the same child label. + """ + conflictForSameChildLabel: Boolean + """ + The conflicting labels. + """ + conflictingLabels: [IssueLabel!] + """ + The team the issue was being moved from. + """ + fromTeam: Team + """ + The property that caused the error. + """ + property: String + """ + The team the issue was being moved to. + """ + toTeam: Team + """ + The type of error that occurred. + """ + type: TriageRuleErrorType! +} + +""" +Metadata about a triage responsibility rule that made changes to an issue, such as auto-assigning an issue when it enters triage. Includes information about any errors that occurred during rule execution. +""" +type IssueHistoryTriageRuleMetadata { + """ + The error that occurred, if any. + """ + triageRuleError: IssueHistoryTriageRuleError + """ + The triage rule that triggered the issue update. + """ + updatedByTriageRule: WorkflowDefinition + @deprecated(reason: "Use `IssueHistoryWorkflowMetadata.workflowDefinition` instead.") +} + +""" +Metadata about a loop that made changes to an issue. Links the issue history entry back to the workflow definition that triggered the change, and optionally to any AI conversation involved in the loop. +""" +type IssueHistoryWorkflowMetadata { + """ + The AI conversation associated with the workflow. + """ + aiConversation: AiConversation + """ + The workflow definition that triggered the issue update. + """ + workflowDefinition: WorkflowDefinition +} + +""" +Comparator for issue identifiers. +""" +input IssueIDComparator { + """ + Equals constraint. + """ + eq: ID + """ + In-array constraint. + """ + in: [ID!] + """ + Not-equals constraint. + """ + neq: ID + """ + Not-in-array constraint. + """ + nin: [ID!] +} + +""" +An import job for data from an external service such as Jira, Asana, GitHub, Shortcut, or other project management tools. Import jobs track the full lifecycle of importing issues, labels, workflow states, and other data into a Linear workspace, including progress, status, error states, and data mapping configuration. +""" +type IssueImport implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + Identifier of the user who started the import job. Can be used to query the user directly. Null if the user has been deleted. + """ + creatorId: String + """ + File URL for the uploaded CSV for the import, if there is one. + """ + csvFileUrl: String + """ + The display name of the import service. + """ + displayName: String! + """ + User readable error message, if one has occurred during the import. + """ + error: String + """ + Error code and metadata, if one has occurred during the import. + """ + errorMetadata: JSONObject + """ + The unique identifier of the entity. + """ + id: ID! + """ + The data mapping configuration for the import job. + """ + mapping: JSONObject + """ + Current step progress as a percentage (0-100). Null if the import has not yet started or progress tracking is not available. + """ + progress: Float + """ + The external service from which data is being imported (e.g., jira, asana, github, shortcut, linear). + """ + service: String! + """ + Metadata related to import service. + """ + serviceMetadata: JSONObject + """ + The current status of the import job, indicating its position in the import lifecycle (e.g., not started, in progress, complete, error). + """ + status: String! + """ + The name of the new team to be created for the import, when the import is configured to create a new team rather than importing into an existing one. Null if importing into an existing team. + """ + teamName: String + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +""" +The result of checking whether an import from an external service can proceed. +""" +type IssueImportCheckPayload { + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +The result of deleting an issue import, containing the deleted import job and a success indicator. +""" +type IssueImportDeletePayload { + """ + The import job that was deleted. + """ + issueImport: IssueImport + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +The result of validating a custom JQL query for a Jira import. +""" +type IssueImportJqlCheckPayload { + """ + An approximate number of issues matching the JQL query. Null when the query is invalid or the count is unavailable. + """ + count: Float + """ + An error message returned by Jira when validating the JQL query. + """ + error: String + """ + Returns true if the JQL query has been validated successfully, false otherwise + """ + success: Boolean! +} + +""" +The result of an issue import mutation, containing the import job and a success indicator. +""" +type IssueImportPayload { + """ + The import job that was created or updated. + """ + issueImport: IssueImport + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +The result of checking whether an issue import can be synced with its source service after import completes. +""" +type IssueImportSyncCheckPayload { + """ + Returns true if the import can be synced, false otherwise + """ + canSync: Boolean! + """ + An error message explaining why the import cannot be synced. Null when canSync is true. + """ + error: String +} + +""" +Input for updating an import job's mapping configuration, such as user and workflow state mappings between the source service and Linear. +""" +input IssueImportUpdateInput { + """ + The mapping configuration for the import. + """ + mapping: JSONObject! +} + +""" +Labels that can be associated with issues. Labels help categorize and filter issues across a workspace. They can be workspace-level (shared across all teams) or team-scoped. Labels have a color for visual identification and can be organized hierarchically into groups, where a parent label acts as a group containing child labels. Labels may also be inherited from parent teams to sub-teams. +""" +type IssueLabel implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + Child labels within this label group. Only populated when the label is a group (isGroup is true). + """ + children( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned issue labels. + """ + filter: IssueLabelFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): IssueLabelConnection! + """ + The label's color as a HEX string (e.g., '#EB5757'). Used for visual identification of the label in the UI. + """ + color: String! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The user who created the label. + """ + creator: User + """ + The label's description. + """ + description: String + """ + The selection mode of this label group. Null for regular labels. Groups without a type use single-select behavior. + """ + groupType: LabelGroupType + """ + The unique identifier of the entity. + """ + id: ID! + """ + The original workspace or parent-team label that this label was inherited from. Null if the label is not inherited. + """ + inheritedFrom: IssueLabel + """ + Whether the label is a group. When true, this label acts as a container for child labels and cannot be directly applied to issues or projects. When false, the label can be directly applied. + """ + isGroup: Boolean! + """ + Issues associated with the label. + """ + issues( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned issues. + """ + filter: IssueFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): IssueConnection! + """ + The date when the label was last applied to an issue, project, or initiative. Null if the label has never been applied. + """ + lastAppliedAt: DateTime + """ + The label's name. + """ + name: String! + organization: Organization! + @deprecated(reason: "Workspace labels are identified by their team being null.") + """ + The parent label. + """ + parent: IssueLabel + """ + [Internal] When the label was retired. + """ + retiredAt: DateTime + """ + The user who retired the label. + """ + retiredBy: User + """ + The team that the label is scoped to. If null, the label is a workspace-level label available to all teams in the workspace. + """ + team: Team + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +""" +Certain properties of an issue label. +""" +type IssueLabelChildWebhookPayload { + """ + The color of the issue label. + """ + color: String! + """ + The ID of the issue label. + """ + id: String! + """ + The name of the issue label. + """ + name: String! + """ + The parent ID of the issue label. + """ + parentId: String +} + +""" +Issue label filtering options. +""" +input IssueLabelCollectionFilter { + """ + Compound filters, all of which need to be matched by the label. + """ + and: [IssueLabelCollectionFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Filters that the issue labels creator must satisfy. + """ + creator: NullableUserFilter + """ + Filters that needs to be matched by all issue labels. + """ + every: IssueLabelFilter + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Comparator for whether the label is a group label. + """ + isGroup: BooleanComparator + """ + Comparator for the collection length. + """ + length: NumberComparator + """ + Comparator for the name. + """ + name: StringComparator + """ + Filter based on the existence of the relation. + """ + null: Boolean + """ + Compound filters, one of which need to be matched by the label. + """ + or: [IssueLabelCollectionFilter!] + """ + Filters that the issue label's parent label must satisfy. + """ + parent: IssueLabelFilter + """ + Filters that needs to be matched by some issue labels. + """ + some: IssueLabelFilter + """ + Filters that the issue labels team must satisfy. + """ + team: NullableTeamFilter + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +type IssueLabelConnection { + edges: [IssueLabelEdge!]! + nodes: [IssueLabel!]! + pageInfo: PageInfo! +} + +""" +Input for creating a new label. A name is required. If no team is specified, the label is created as a workspace-level label available to all teams. +""" +input IssueLabelCreateInput { + """ + The color of the label. + """ + color: String + """ + The description of the label. + """ + description: String + """ + The selection mode of the label group. Defaults to singleSelect for groups and null for regular labels. + """ + groupType: LabelGroupType + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + Whether the label is a group. + """ + isGroup: Boolean + """ + The name of the label. + """ + name: String! + """ + The identifier of the parent label. + """ + parentId: String + """ + The time at which the label was retired. Set to null to restore a retired label. + """ + retiredAt: DateTime + """ + The team associated with the label. If not given, the label will be associated with the entire workspace. + """ + teamId: String +} + +type IssueLabelEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: IssueLabel! +} + +""" +Issue label filtering options. +""" +input IssueLabelFilter { + """ + Compound filters, all of which need to be matched by the label. + """ + and: [IssueLabelFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Filters that the issue labels creator must satisfy. + """ + creator: NullableUserFilter + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Comparator for whether the label is a group label. + """ + isGroup: BooleanComparator + """ + Comparator for the name. + """ + name: StringComparator + """ + Compound filters, one of which need to be matched by the label. + """ + or: [IssueLabelFilter!] + """ + Filters that the issue label's parent label must satisfy. + """ + parent: IssueLabelFilter + """ + Filters that the issue labels team must satisfy. + """ + team: NullableTeamFilter + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +The result of a label mutation, containing the created or updated label and a success indicator. +""" +type IssueLabelPayload { + """ + The label that was created or updated. + """ + issueLabel: IssueLabel! + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Input for updating an existing label. All fields are optional; only provided fields will be updated. +""" +input IssueLabelUpdateInput { + """ + The color of the label. + """ + color: String + """ + The description of the label. + """ + description: String + """ + The selection mode of the label group. Omit to keep the current value. Null resets groups to singleSelect. Regular labels always use null. + """ + groupType: LabelGroupType + """ + Whether the label is a group. + """ + isGroup: Boolean + """ + The name of the label. + """ + name: String + """ + The identifier of the parent label. + """ + parentId: String + """ + The time at which the label was retired. Set to null to restore a retired label. + """ + retiredAt: DateTime +} + +""" +Payload for an issue label webhook. +""" +type IssueLabelWebhookPayload { + """ + The time at which the entity was archived. + """ + archivedAt: String + """ + The color of the issue label. + """ + color: String! + """ + The time at which the entity was created. + """ + createdAt: String! + """ + The creator ID of the issue label. + """ + creatorId: String + """ + The label's description. + """ + description: String + """ + The ID of the entity. + """ + id: String! + """ + The original label inherited from. + """ + inheritedFromId: String + """ + Whether the label is a group. + """ + isGroup: Boolean! + """ + The name of the issue label. + """ + name: String! + """ + The parent ID of the issue label. + """ + parentId: String + """ + The team ID of the issue label. + """ + teamId: String + """ + The time at which the entity was updated. + """ + updatedAt: String! +} + +""" +An issue mention notification type. +""" +scalar IssueMentionNotificationType + +""" +Payload for an issue mention notification. +""" +type IssueMentionNotificationWebhookPayload { + """ + The actor who caused the notification. + """ + actor: UserChildWebhookPayload + """ + The ID of the actor who caused the notification. + """ + actorId: String + """ + The time at which the entity was archived. + """ + archivedAt: String + """ + The time at which the entity was created. + """ + createdAt: String! + """ + The ID of the external user who caused the notification. + """ + externalUserActorId: String + """ + The ID of the entity. + """ + id: String! + """ + The issue this notification belongs to. + """ + issue: IssueWithDescriptionChildWebhookPayload! + """ + The ID of the issue this notification belongs to. + """ + issueId: String! + """ + An issue mention notification type. + """ + type: IssueMentionNotificationType! + """ + The time at which the entity was updated. + """ + updatedAt: String! + """ + The ID of the user who received the notification. + """ + userId: String! +} + +""" +An issue new comment notification type. +""" +scalar IssueNewCommentNotificationType + +""" +Payload for an issue new comment notification. +""" +type IssueNewCommentNotificationWebhookPayload { + """ + The actor who caused the notification. + """ + actor: UserChildWebhookPayload + """ + The ID of the actor who caused the notification. + """ + actorId: String + """ + The time at which the entity was archived. + """ + archivedAt: String + """ + The comment this notification belongs to. + """ + comment: CommentChildWebhookPayload! + """ + The ID of the comment this notification belongs to. + """ + commentId: String! + """ + The time at which the entity was created. + """ + createdAt: String! + """ + The ID of the external user who caused the notification. + """ + externalUserActorId: String + """ + The ID of the entity. + """ + id: String! + """ + The issue this notification belongs to. + """ + issue: IssueWithDescriptionChildWebhookPayload! + """ + The ID of the issue this notification belongs to. + """ + issueId: String! + """ + The parent comment for the comment this notification belongs to. + """ + parentComment: CommentChildWebhookPayload + """ + The ID of the parent comment for the comment this notification belongs to. + """ + parentCommentId: String + """ + An issue new comment notification type. + """ + type: IssueNewCommentNotificationType! + """ + The time at which the entity was updated. + """ + updatedAt: String! + """ + The ID of the user who received the notification. + """ + userId: String! +} + +""" +A notification related to an issue, such as assignment, comment, mention, status change, or priority change. +""" +type IssueNotification implements Entity & Node & Notification { + """ + The user that caused the notification. Null if the notification was triggered by a non-user actor such as an integration, external user, or system event. + """ + actor: User + """ + [Internal] Notification actor initials if avatar is not available. + """ + actorAvatarColor: String! + """ + [Internal] Notification avatar URL. + """ + actorAvatarUrl: String + """ + [Internal] Whether the notification's user actor is deactivated in the workspace. + """ + actorInactive: Boolean! + """ + [Internal] Notification actor initials if avatar is not available. + """ + actorInitials: String + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The bot that caused the notification. + """ + botActor: ActorBot + """ + The category of the notification. + """ + category: NotificationCategory! + """ + The comment related to the notification. + """ + comment: Comment + """ + Related comment ID. Null if the notification is not related to a comment. + """ + commentId: String + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The time at which an email reminder for this notification was sent to the user. Null if no email reminder has been sent. + """ + emailedAt: DateTime + """ + The external user that caused the notification. Populated when the notification was triggered by an external user (e.g., a commenter from a connected integration like Slack or GitHub) rather than a Linear workspace member. + """ + externalUserActor: ExternalUser + """ + [Internal] Notifications with the same grouping key will be grouped together in the UI. + """ + groupingKey: String! + """ + [Internal] Priority of the notification with the same grouping key. Higher number means higher priority. If priority is the same, notifications should be sorted by `createdAt`. + """ + groupingPriority: Float! + """ + The unique identifier of the entity. + """ + id: ID! + """ + [Internal] Inbox URL for the notification. + """ + inboxUrl: String! + """ + [Internal] Initiative update health for new updates. + """ + initiativeUpdateHealth: String + """ + [Internal] If notification actor was Linear. + """ + isLinearActor: Boolean! + """ + The issue related to the notification. + """ + issue: Issue! + """ + Related issue ID. + """ + issueId: String! + """ + [Internal] Issue's status type for issue notifications. + """ + issueStatusType: String + """ + The parent comment related to the notification, if a notification is a reply comment notification. + """ + parentComment: Comment + """ + Related parent comment ID. Null if the notification is not related to a comment. + """ + parentCommentId: String + """ + [Internal] Project update health for new updates. + """ + projectUpdateHealth: String + """ + Name of the reaction emoji related to the notification. + """ + reactionEmoji: String + """ + The time at which the user marked the notification as read. Null if the notification is unread. + """ + readAt: DateTime + """ + The time until which a notification is snoozed. After this time, the notification reappears in the user's inbox. Null if the notification is not currently snoozed. + """ + snoozedUntilAt: DateTime + """ + The subscriptions related to the notification. + """ + subscriptions: [NotificationSubscription!] + """ + [Internal] Notification subtitle. + """ + subtitle: String! + """ + The team related to the issue notification. + """ + team: Team! + """ + [Internal] Notification title. + """ + title: String! + """ + Notification type. Determines the kind of event that triggered this notification and which associated entity fields will be populated. + """ + type: String! + """ + The time at which a notification was unsnoozed. Null if the notification has not been unsnoozed. + """ + unsnoozedAt: DateTime + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + [Internal] URL to the target of the notification. + """ + url: String! + """ + The recipient user of this notification. + """ + user: User! +} + +""" +The result of an issue mutation, containing the created or updated issue and a success indicator. +""" +type IssuePayload { + """ + The issue that was created or updated. + """ + issue: Issue + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +A mapping of an issue priority value to its human-readable label. +""" +type IssuePriorityValue { + """ + Priority's label. + """ + label: String! + """ + Priority's number value. + """ + priority: Int! +} + +""" +A reference to an issue discovered during release sync, linking the issue identifier to the commit SHA where the reference was found. +""" +input IssueReferenceInput { + """ + The commit SHA where this issue reference was found. + """ + commitSha: String! + """ + The issue identifier (e.g. ENG-123). + """ + identifier: String! +} + +""" +A relation between two issues. Issue relations represent directional relationships such as blocking, being blocked by, relating to, or duplicating another issue. Each relation connects a source issue to a related issue with a specific type describing the nature of the relationship. +""" +type IssueRelation implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The unique identifier of the entity. + """ + id: ID! + """ + The source issue whose relationship is being described. This is the issue from which the relation originates. + """ + issue: Issue! + """ + The target issue that the source issue is related to. The relation type describes how the source issue relates to this issue. + """ + relatedIssue: Issue! + """ + The type of relationship between the source issue and the related issue. Possible values include blocks, duplicate, and related. + """ + type: String! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +type IssueRelationConnection { + edges: [IssueRelationEdge!]! + nodes: [IssueRelation!]! + pageInfo: PageInfo! +} + +""" +Input for creating a new issue relation between two issues. Both the source issue and related issue must be specified along with the relationship type. +""" +input IssueRelationCreateInput { + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + The identifier of the issue that is related to another issue. Can be a UUID or issue identifier (e.g., 'LIN-123'). + """ + issueId: String! + """ + The identifier of the related issue. Can be a UUID or issue identifier (e.g., 'LIN-123'). + """ + relatedIssueId: String! + """ + The type of relation of the issue to the related issue. + """ + type: IssueRelationType! +} + +type IssueRelationEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: IssueRelation! +} + +""" +Payload describing a change to an issue relation, including which issue was involved and the type of change that occurred. +""" +type IssueRelationHistoryPayload { + """ + The human-readable identifier of the related issue (e.g., ENG-123). + """ + identifier: String! + """ + The type of relation change that occurred (e.g., relation added or removed). + """ + type: String! +} + +""" +The result of an issue relation mutation, containing the created or updated issue relation and a success indicator. +""" +type IssueRelationPayload { + """ + The issue relation that was created or updated. + """ + issueRelation: IssueRelation! + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +The type of the issue relation. +""" +enum IssueRelationType { + blocks + duplicate + related + similar +} + +""" +Input for updating an existing issue relation. All fields are optional; only provided fields will be updated. +""" +input IssueRelationUpdateInput { + """ + The identifier of the issue that is related to another issue. Can be a UUID or issue identifier (e.g., 'LIN-123'). + """ + issueId: String + """ + The identifier of the related issue. Can be a UUID or issue identifier (e.g., 'LIN-123'). + """ + relatedIssueId: String + """ + The type of relation of the issue to the related issue. + """ + type: String +} + +type IssueSearchPayload { + """ + Archived entities matching the search term along with all their dependencies, serialized for the client sync engine. + """ + archivePayload: ArchiveResponse! + edges: [IssueSearchResultEdge!]! + nodes: [IssueSearchResult!]! + pageInfo: PageInfo! + """ + Total number of matching results before pagination is applied. + """ + totalCount: Float! +} + +type IssueSearchResult implements Node { + """ + [Internal] The activity summary information for this issue. + """ + activitySummary: JSONObject + """ + The time at which the issue was added to a cycle. + """ + addedToCycleAt: DateTime + """ + The time at which the issue was added to a project. + """ + addedToProjectAt: DateTime + """ + The time at which the issue was added to a team. + """ + addedToTeamAt: DateTime + """ + [Internal] Agent sessions associated with the issue. + """ + agentSessions( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): AgentSessionConnection! + """ + [Internal] AI-generated analyses of the issue, keyed by feature, such as coding-agent suitability. Null if no analysis has run. + """ + aiAnalysis: JSONObject + """ + [Internal] AI prompt progresses associated with this issue. + """ + aiPromptProgresses( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned AI prompt progresses. + """ + filter: AiPromptProgressFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): AiPromptProgressConnection! + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The external user who requested creation of the Asks issue on behalf of the creator. + """ + asksExternalUserRequester: ExternalUser + """ + The internal user who requested creation of the Asks issue on behalf of the creator. + """ + asksRequester: User + """ + The user to whom the issue is assigned. Null if the issue is unassigned. + """ + assignee: User + """ + Attachments associated with the issue. + """ + attachments( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned attachments. + """ + filter: AttachmentFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): AttachmentConnection! + """ + The time at which the issue was automatically archived by the auto pruning process. + """ + autoArchivedAt: DateTime + """ + The time at which the issue was automatically closed by the auto pruning process. + """ + autoClosedAt: DateTime + """ + The order of the item in its column on the board. + """ + boardOrder: Float! + @deprecated(reason: "Will be removed in near future, please use `sortOrder` instead") + """ + The bot that created the issue, if applicable. + """ + botActor: ActorBot + """ + Suggested branch name for the issue. + """ + branchName: String! + """ + The time at which the issue was moved into canceled state. + """ + canceledAt: DateTime + """ + Children of the issue. + """ + children( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned issues. + """ + filter: IssueFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): IssueConnection! + """ + Comments associated with the issue, including inline comments on the issue's description. + """ + comments( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned comments. + """ + filter: CommentFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): CommentConnection! + """ + The time at which the issue was moved into completed state. + """ + completedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The user who created the issue. Null if the creator's account has been deleted or if the issue was created by an integration or system process. + """ + creator: User + """ + Returns the number of Attachment resources which are created by customer support ticketing systems (e.g. Zendesk). + """ + customerTicketCount: Int! + """ + The cycle that the issue is associated with. Null if the issue is not part of any cycle. + """ + cycle: Cycle + """ + The agent user that is delegated to work on this issue. Set when an AI agent has been assigned to perform work on this issue. Null if no agent is working on the issue. + """ + delegate: User + """ + The issue's description in markdown format. + """ + description: String + """ + [Internal] The issue's description content as YJS state. + """ + descriptionState: String + """ + [ALPHA] The document content representing this issue description. + """ + documentContent: DocumentContent + """ + Documents associated with the issue. + """ + documents( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned documents. + """ + filter: DocumentFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): DocumentConnection! + """ + The date at which the issue is due. + """ + dueDate: TimelessDate + """ + The estimate of the complexity of the issue. The specific scale used depends on the team's estimation configuration (e.g., points, T-shirt sizes). Null if no estimate has been set. + """ + estimate: Float + """ + The external user who created the issue. Set when the issue was created via an integration (e.g., Slack, Intercom) on behalf of a non-Linear user. Null if the issue was created by a Linear user. + """ + externalUserCreator: ExternalUser + """ + The users favorite associated with this issue. + """ + favorite: Favorite + """ + Attachments previously associated with the issue before being moved to another issue. + """ + formerAttachments( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned attachments. + """ + filter: AttachmentFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): AttachmentConnection! + """ + Customer needs previously associated with the issue before being moved to another issue. + """ + formerNeeds( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned needs. + """ + filter: CustomerNeedFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): CustomerNeedConnection! + """ + History entries associated with the issue. + """ + history( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): IssueHistoryConnection! + """ + The unique identifier of the entity. + """ + id: ID! + """ + Issue's human readable identifier (e.g. ENG-123). + """ + identifier: String! + """ + [Internal] Incoming product intelligence relation suggestions for the issue. + """ + incomingSuggestions( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): IssueSuggestionConnection! + """ + Whether this issue inherits shared access from its parent issue. + """ + inheritsSharedAccess: Boolean! + """ + Integration type that created this issue, if applicable. + """ + integrationSourceType: IntegrationService + """ + Inverse relations associated with this issue. + """ + inverseRelations( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): IssueRelationConnection! + """ + Identifiers of the labels associated with this issue. Can be used to query the labels directly. + """ + labelIds: [String!]! + """ + Labels associated with this issue. + """ + labels( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned issue labels. + """ + filter: IssueLabelFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): IssueLabelConnection! + """ + The last template that was applied to this issue. + """ + lastAppliedTemplate: Template + """ + Metadata related to search result. + """ + metadata: JSONObject! + """ + Customer needs associated with the issue. + """ + needs( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned needs. + """ + filter: CustomerNeedFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): CustomerNeedConnection! + """ + The issue's unique number, scoped to the issue's team. Together with the team key, this forms the issue's human-readable identifier (e.g., ENG-123). + """ + number: Float! + """ + The parent of the issue. + """ + parent: Issue + """ + Previous identifiers of the issue if it has been moved between teams. + """ + previousIdentifiers: [String!]! + """ + The priority of the issue. 0 = No priority, 1 = Urgent, 2 = High, 3 = Medium, 4 = Low. + """ + priority: Float! + """ + Label for the priority. + """ + priorityLabel: String! + """ + The order of the item in relation to other items in the workspace, when ordered by priority. + """ + prioritySortOrder: Float! + """ + The project that the issue is associated with. Null if the issue is not part of any project. + """ + project: Project + """ + The project milestone that the issue is associated with. Null if the issue is not assigned to a specific milestone within its project. + """ + projectMilestone: ProjectMilestone + """ + Emoji reaction summary for the issue, grouped by emoji type. Contains the count and reacting user information for each emoji. + """ + reactionData: JSONObject! + """ + Reactions associated with the issue. + """ + reactions: [Reaction!]! + """ + The recurring issue template that created this issue. + """ + recurringIssueTemplate: Template + """ + Relations associated with this issue. + """ + relations( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): IssueRelationConnection! + """ + Releases associated with the issue. + """ + releases( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned releases. + """ + filter: ReleaseFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): ReleaseConnection! + """ + Shared access metadata for this issue. + """ + sharedAccess: IssueSharedAccess! + """ + The time at which the issue's SLA will breach. + """ + slaBreachesAt: DateTime + """ + The time at which the issue's SLA will enter high risk state. + """ + slaHighRiskAt: DateTime + """ + The time at which the issue's SLA will enter medium risk state. + """ + slaMediumRiskAt: DateTime + """ + The time at which the issue's SLA began. + """ + slaStartedAt: DateTime + """ + The type of SLA set on the issue. Calendar days or business days. + """ + slaType: String + """ + The user who snoozed the issue. + """ + snoozedBy: User + """ + The time until an issue will be snoozed in Triage view. + """ + snoozedUntilAt: DateTime + """ + The order of the item in relation to other items in the organization. Used for manual sorting in list views. + """ + sortOrder: Float! + """ + The comment that this issue was created from, when an issue is created from an existing comment. Null if the issue was not created from a comment. + """ + sourceComment: Comment + """ + The time at which the issue was moved into started state. + """ + startedAt: DateTime + """ + The time at which the issue entered triage. + """ + startedTriageAt: DateTime + """ + The workflow state (issue status) that the issue is currently in. Workflow states represent the issue's progress through the team's workflow, such as Triage, Todo, In Progress, Done, or Canceled. + """ + state: WorkflowState! + """ + The issue's workflow states over time. + """ + stateHistory( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + ): IssueStateSpanConnection! + """ + The order of the item in the sub-issue list. Only set if the issue has a parent. + """ + subIssueSortOrder: Float + """ + Users who are subscribed to the issue. + """ + subscribers( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned subscribers. + """ + filter: UserFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + Should query return disabled/suspended users (default: false). + """ + includeDisabled: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): UserConnection! + """ + [Internal] Product Intelligence suggestions for the issue. + """ + suggestions( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned suggestions. + """ + filter: IssueSuggestionFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): IssueSuggestionConnection! + """ + [Internal] The time at which the most recent suggestions for this issue were generated. + """ + suggestionsGeneratedAt: DateTime + """ + [Internal] AI-generated activity summary for this issue. + """ + summary: Summary + """ + The external services the issue is synced with. + """ + syncedWith: [ExternalEntityInfo!] + """ + The team that the issue belongs to. Every issue must belong to exactly one team, which determines the available workflow states, labels, and other team-specific configuration. + """ + team: Team! + """ + The issue's title. This is the primary human-readable summary of the work item. + """ + title: String! + """ + A flag that indicates whether the issue is in the trash bin. + """ + trashed: Boolean + """ + The time at which the issue left triage. + """ + triagedAt: DateTime + """ + [Internal] Whether this issue has been explicitly marked as trusted. + """ + trusted: Boolean + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + Issue URL. + """ + url: String! +} + +type IssueSearchResultEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: IssueSearchResult! +} + +""" +Metadata about an issue's shared access state, including which users the issue is shared with and any field restrictions for shared-only viewers. +""" +type IssueSharedAccess { + """ + Issue update fields the viewer cannot modify due to shared-only access. + """ + disallowedIssueFields: [IssueSharedAccessDisallowedField!]! + """ + Whether this issue has been shared with users outside the team. + """ + isShared: Boolean! + """ + The number of users this issue is shared with. + """ + sharedWithCount: Int! + """ + Users this issue is shared with. + """ + sharedWithUsers: [User!]! + """ + Whether the viewer can access this issue only through issue sharing. + """ + viewerHasOnlySharedAccess: Boolean! +} + +""" +Issue update fields that are disallowed for users with only shared access. +""" +enum IssueSharedAccessDisallowedField { + cycleId + projectId + projectMilestoneId + teamId +} + +""" +Policy controlling whether and by whom issues in a team can be shared with non-team-members. +""" +enum IssueSharingPolicy { + adminsOnly + allMembers + disabled +} + +""" +Payload for issue SLA webhook events. +""" +type IssueSlaWebhookPayload { + """ + The type of action that triggered the webhook. + """ + action: String! + """ + The time the payload was created. + """ + createdAt: DateTime! + """ + The issue that the SLA event is about. + """ + issueData: IssueWebhookPayload! + """ + ID of the organization for which the webhook belongs to. + """ + organizationId: String! + """ + The type of resource. + """ + type: String! + """ + URL for the issue. + """ + url: String + """ + The ID of the webhook that sent this event. + """ + webhookId: String! + """ + Unix timestamp in milliseconds when the webhook was sent. + """ + webhookTimestamp: Float! +} + +""" +Issue sorting options. +""" +input IssueSortInput { + """ + [Internal] Sort by the accumulated time in the current workflow state + """ + accumulatedStateUpdatedAt: TimeInStatusSort + """ + Sort by assignee name + """ + assignee: AssigneeSort + """ + Sort by issue completion date + """ + completedAt: CompletedAtSort + """ + Sort by issue creation date + """ + createdAt: CreatedAtSort + """ + Sort by customer name + """ + customer: CustomerSort + """ + Sort by number of customers associated with the issue + """ + customerCount: CustomerCountSort + """ + Sort by number of important customers associated with the issue + """ + customerImportantCount: CustomerImportantCountSort + """ + Sort by customer revenue + """ + customerRevenue: CustomerRevenueSort + """ + Sort by Cycle start date + """ + cycle: CycleSort + """ + Sort by delegate name + """ + delegate: DelegateSort + """ + Sort by issue due date + """ + dueDate: DueDateSort + """ + Sort by estimate + """ + estimate: EstimateSort + """ + Sort by label + """ + label: LabelSort + """ + Sort by label group + """ + labelGroup: LabelGroupSort + """ + [ALPHA] Sort by number of links associated with the issue + """ + linkCount: LinkCountSort + """ + Sort by manual order + """ + manual: ManualSort + """ + Sort by Project Milestone target date + """ + milestone: MilestoneSort + """ + Sort by priority + """ + priority: PrioritySort + """ + Sort by Project name + """ + project: ProjectSort + """ + Sort by most recent release date + """ + release: ReleaseSort + """ + Sort by the root issue + """ + rootIssue: RootIssueSort + """ + Sort by SLA status + """ + slaStatus: SlaStatusSort + """ + Sort by Team name + """ + team: TeamSort + """ + Sort by issue title + """ + title: TitleSort + """ + Sort by issue update date + """ + updatedAt: UpdatedAtSort + """ + Sort by workflow state type + """ + workflowState: WorkflowStateSort +} + +""" +A continuous period of time during which an issue remained in a specific workflow state. +""" +type IssueStateSpan { + """ + The timestamp when the issue left this state. Null if the issue is currently in this state. + """ + endedAt: DateTime + """ + The unique identifier of the state span. + """ + id: ID! + """ + The timestamp when the issue entered this state. + """ + startedAt: DateTime! + """ + The workflow state for this span. + """ + state: WorkflowState + """ + The workflow state identifier for this span. + """ + stateId: ID! +} + +type IssueStateSpanConnection { + edges: [IssueStateSpanEdge!]! + nodes: [IssueStateSpan!]! + pageInfo: PageInfo! +} + +type IssueStateSpanEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: IssueStateSpan! +} + +""" +An issue status changed notification type. +""" +scalar IssueStatusChangedNotificationType + +""" +Payload for a terminal issue status change notification. +""" +type IssueStatusChangedNotificationWebhookPayload { + """ + The actor who caused the notification. + """ + actor: UserChildWebhookPayload + """ + The ID of the actor who caused the notification. + """ + actorId: String + """ + The time at which the entity was archived. + """ + archivedAt: String + """ + The time at which the entity was created. + """ + createdAt: String! + """ + The ID of the external user who caused the notification. + """ + externalUserActorId: String + """ + The ID of the entity. + """ + id: String! + """ + The issue this notification belongs to. + """ + issue: IssueWithDescriptionChildWebhookPayload! + """ + The ID of the issue this notification belongs to. + """ + issueId: String! + """ + A terminal issue status change notification type. + """ + type: IssueStatusChangedNotificationType! + """ + The time at which the entity was updated. + """ + updatedAt: String! + """ + The ID of the user who received the notification. + """ + userId: String! +} + +""" +Filter for issue subscription events. +""" +input IssueSubscriptionFilter { + """ + Filter by assignee ID. + """ + assigneeId: IDComparator + """ + Filter by parent issue ID. + """ + parentId: IDComparator + """ + Filter by project ID. + """ + projectId: IDComparator + """ + Filter by workflow state ID. + """ + stateId: IDComparator + """ + Filter by team ID. + """ + teamId: IDComparator +} + +""" +[Internal] An AI-generated suggestion for an issue. Suggestions can recommend related or similar issues, assignees, labels, teams, or projects. Each suggestion has a type, state (active, accepted, dismissed), and optionally associated metadata with scoring information. +""" +type IssueSuggestion implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + [Internal] The reason the suggestion was dismissed by the user. Null if the suggestion has not been dismissed. + """ + dismissalReason: String + """ + The unique identifier of the entity. + """ + id: ID! + """ + [Internal] The issue that this suggestion applies to. + """ + issue: Issue! + """ + [Internal] Identifier of the issue that this suggestion applies to. Can be used to query the issue directly. + """ + issueId: String! + """ + [Internal] Metadata associated with the suggestion, including confidence scores and classification. Null if no metadata is available. + """ + metadata: IssueSuggestionMetadata + """ + The suggestion reasons with entity mentions resolved to readable labels and structured references. + """ + presentedReasons: [PresentedIssueSuggestionReason!]! + """ + [Internal] The current state of the suggestion: active, accepted, or dismissed. + """ + state: IssueSuggestionState! + """ + [Internal] The date when the suggestion's state was last changed (e.g., from active to accepted or dismissed). + """ + stateChangedAt: DateTime! + """ + [Internal] The suggested issue, when the suggestion type is similarIssue or relatedIssue. Null for other suggestion types. + """ + suggestedIssue: Issue + """ + [Internal] Identifier of the suggested issue. Set when the suggestion type is similarIssue or relatedIssue. Can be used to query the issue directly. + """ + suggestedIssueId: String + """ + [Internal] The suggested label, when the suggestion type is label. Null for other suggestion types. + """ + suggestedLabel: IssueLabel + """ + [Internal] Identifier of the suggested label. Set when the suggestion type is label. Can be used to query the label directly. + """ + suggestedLabelId: String + """ + [Internal] The suggested project, when the suggestion type is project. Null for other suggestion types. + """ + suggestedProject: Project + """ + [Internal] The suggested team, when the suggestion type is team. Null for other suggestion types. + """ + suggestedTeam: Team + """ + [Internal] The suggested user, when the suggestion type is assignee. Null for other suggestion types. + """ + suggestedUser: User + """ + [Internal] Identifier of the suggested user. Set when the suggestion type is assignee. Can be used to query the user directly. + """ + suggestedUserId: String + """ + [Internal] The type of suggestion, indicating what kind of entity is being suggested (e.g., similarIssue, relatedIssue, assignee, label, team, project). + """ + type: IssueSuggestionType! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +""" +IssueSuggestion collection filtering options. +""" +input IssueSuggestionCollectionFilter { + """ + Compound filters, all of which need to be matched by the suggestion. + """ + and: [IssueSuggestionCollectionFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Filters that needs to be matched by all suggestions. + """ + every: IssueSuggestionFilter + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Comparator for the collection length. + """ + length: NumberComparator + """ + Compound filters, one of which need to be matched by the suggestion. + """ + or: [IssueSuggestionCollectionFilter!] + """ + Filters that needs to be matched by some suggestions. + """ + some: IssueSuggestionFilter + """ + Comparator for the suggestion state. + """ + state: StringComparator + """ + Filters that the suggested label must satisfy. + """ + suggestedLabel: IssueLabelFilter + """ + Filters that the suggested project must satisfy. + """ + suggestedProject: NullableProjectFilter + """ + Filters that the suggested team must satisfy. + """ + suggestedTeam: NullableTeamFilter + """ + Filters that the suggested user must satisfy. + """ + suggestedUser: NullableUserFilter + """ + Comparator for the suggestion type. + """ + type: StringComparator + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +type IssueSuggestionConnection { + edges: [IssueSuggestionEdge!]! + nodes: [IssueSuggestion!]! + pageInfo: PageInfo! +} + +type IssueSuggestionEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: IssueSuggestion! +} + +""" +IssueSuggestion filtering options. +""" +input IssueSuggestionFilter { + """ + Compound filters, all of which need to be matched by the suggestion. + """ + and: [IssueSuggestionFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Compound filters, one of which need to be matched by the suggestion. + """ + or: [IssueSuggestionFilter!] + """ + Comparator for the suggestion state. + """ + state: StringComparator + """ + Filters that the suggested label must satisfy. + """ + suggestedLabel: IssueLabelFilter + """ + Filters that the suggested project must satisfy. + """ + suggestedProject: NullableProjectFilter + """ + Filters that the suggested team must satisfy. + """ + suggestedTeam: NullableTeamFilter + """ + Filters that the suggested user must satisfy. + """ + suggestedUser: NullableUserFilter + """ + Comparator for the suggestion type. + """ + type: StringComparator + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +[Internal] Metadata associated with an issue suggestion, including scoring and classification information. +""" +type IssueSuggestionMetadata { + """ + [Internal] Identifier of the automation rule that was applied from this suggestion. Null if no rule was applied. + """ + appliedAutomationRuleId: String + """ + [Internal] The classification category of the suggestion. Null if no classification was assigned. + """ + classification: String + """ + [Internal] Identifier of the evaluation log entry associated with this suggestion. Null if no log entry exists. + """ + evalLogId: String + """ + [Internal] Identifier of the automation rule that attempted to apply this suggestion. Null if no rule attempted to apply it or if the rule applied successfully. + """ + failedAutomationRuleId: String + """ + [Internal] Reason why an automation rule could not apply this suggestion. Null if no rule attempted to apply it or if the rule applied successfully. + """ + failedAutomationRuleReason: String + """ + [Internal] The rank of this suggestion relative to other suggestions of the same type. Lower values indicate higher priority. Null if not ranked. + """ + rank: Float + """ + [Internal] The reasons explaining why this suggestion was made. Null if no reasons are available. + """ + reasons: [String!] + """ + [Internal] The confidence score of the suggestion. Higher values indicate greater confidence. Null if no score was computed. + """ + score: Float + """ + [Internal] The AI prompt variant that generated this suggestion. Null if not applicable. + """ + variant: String +} + +""" +An entity referenced by a presented issue suggestion reason. +""" +type IssueSuggestionReasonReference { + """ + The referenced entity identifier. + """ + id: String! + """ + The readable label for the referenced entity. + """ + label: String + """ + The title of the referenced entity, when available. + """ + title: String + """ + The referenced entity type. + """ + type: String! +} + +""" +The state of an issue suggestion, indicating whether it is active, accepted, or dismissed. +""" +enum IssueSuggestionState { + accepted + active + dismissed + stale +} + +""" +The type of an issue suggestion, indicating what kind of entity is being suggested (e.g., similar issue, assignee, label, team, project). +""" +enum IssueSuggestionType { + assignee + label + project + relatedIssue + similarIssue + team +} + +""" +Return type for AI-generated issue title suggestions based on customer request content. +""" +type IssueTitleSuggestionFromCustomerRequestPayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + [Internal] The evaluation log ID of the AI response, for tracing and debugging. + """ + logId: String + """ + The AI-suggested issue title based on the customer request content. + """ + title: String! +} + +""" +A join entity linking an issue to a release for release tracking. Each record represents an association between a single issue and a single release, along with metadata about the source of the link (e.g., which pull requests connected the issue to the release). Creating or deleting these associations automatically records the change in issue history. +""" +type IssueToRelease implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The unique identifier of the entity. + """ + id: ID! + """ + The issue that is linked to the release. + """ + issue: Issue! + """ + The release that the issue is linked to. + """ + release: Release! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +type IssueToReleaseConnection { + edges: [IssueToReleaseEdge!]! + nodes: [IssueToRelease!]! + pageInfo: PageInfo! +} + +""" +Input for creating a new association between an issue and a release. Both an issue identifier and a release identifier must be provided. +""" +input IssueToReleaseCreateInput { + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + The identifier of the issue. Can be a UUID or issue identifier (e.g., 'LIN-123'). + """ + issueId: String! + """ + The identifier of the release. + """ + releaseId: String! +} + +type IssueToReleaseEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: IssueToRelease! +} + +""" +The result of an issue-to-release mutation, containing the created or updated association and a success indicator. +""" +type IssueToReleasePayload { + """ + The issueToRelease that was created or updated. + """ + issueToRelease: IssueToRelease! + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +An issue unassignment notification type. +""" +scalar IssueUnassignedFromYouNotificationType + +""" +Payload for an issue unassignment notification. +""" +type IssueUnassignedFromYouNotificationWebhookPayload { + """ + The actor who caused the notification. + """ + actor: UserChildWebhookPayload + """ + The ID of the actor who caused the notification. + """ + actorId: String + """ + The time at which the entity was archived. + """ + archivedAt: String + """ + The time at which the entity was created. + """ + createdAt: String! + """ + The ID of the external user who caused the notification. + """ + externalUserActorId: String + """ + The ID of the entity. + """ + id: String! + """ + The issue this notification belongs to. + """ + issue: IssueWithDescriptionChildWebhookPayload! + """ + The ID of the issue this notification belongs to. + """ + issueId: String! + """ + An issue unassignment notification type. + """ + type: IssueUnassignedFromYouNotificationType! + """ + The time at which the entity was updated. + """ + updatedAt: String! + """ + The ID of the user who received the notification. + """ + userId: String! +} + +""" +Input for updating an existing issue. All fields are optional; only provided fields will be updated. Setting a field to null (where supported) will clear the value. +""" +input IssueUpdateInput { + """ + The identifiers of the issue labels to be added to this issue. + """ + addedLabelIds: [String!] + """ + The identifiers of the releases to be added to this issue. + """ + addedReleaseIds: [String!] + """ + The identifier of the user to assign the issue to. + """ + assigneeId: String + """ + Whether the issue was automatically closed because its parent issue was closed. + """ + autoClosedByParentClosing: Boolean + """ + The cycle associated with the issue. + """ + cycleId: String + """ + The identifier of the agent user to delegate the issue to. + """ + delegateId: String + """ + The issue description in markdown format. + """ + description: String + """ + [Internal] The issue description as a Prosemirror document. + """ + descriptionData: JSON + """ + The date at which the issue is due. + """ + dueDate: TimelessDate + """ + The estimated complexity of the issue. + """ + estimate: Int + """ + Whether this issue should inherit shared access from its parent issue. + """ + inheritsSharedAccess: Boolean + """ + The identifiers of the issue labels associated with this ticket. + """ + labelIds: [String!] + """ + The ID of the last template applied to the issue. + """ + lastAppliedTemplateId: String + """ + The identifier of the parent issue. Can be a UUID or issue identifier (e.g., 'LIN-123'). + """ + parentId: String + """ + The priority of the issue. 0 = No priority, 1 = Urgent, 2 = High, 3 = Medium, 4 = Low. + """ + priority: Int + """ + The position of the issue related to other issues, when ordered by priority. + """ + prioritySortOrder: Float + """ + The project associated with the issue. Can be a UUID or project identifier (e.g., 'P-LIN-123'). + """ + projectId: String + """ + The project milestone associated with the issue. + """ + projectMilestoneId: String + """ + The identifiers of the releases associated with this issue. + """ + releaseIds: [String!] + """ + The identifiers of the issue labels to be removed from this issue. + """ + removedLabelIds: [String!] + """ + The identifiers of the releases to be removed from this issue. + """ + removedReleaseIds: [String!] + """ + [Internal] The time at which an issue will be considered in breach of SLA. + """ + slaBreachesAt: DateTime + """ + [Internal] The time at which the issue's SLA was started. + """ + slaStartedAt: DateTime + """ + The SLA day count type for the issue. Whether SLA should be business days only or calendar days (default). + """ + slaType: SLADayCountType + """ + The identifier of the user who snoozed the issue. + """ + snoozedById: String + """ + The time until which the issue will be snoozed in Triage view. + """ + snoozedUntilAt: DateTime + """ + The position of the issue related to other issues. + """ + sortOrder: Float + """ + The team state of the issue. + """ + stateId: String + """ + The position of the issue in parent's sub-issue list. + """ + subIssueSortOrder: Float + """ + The identifiers of the users subscribing to this ticket. + """ + subscriberIds: [String!] + """ + The identifier of the team associated with the issue. + """ + teamId: String + """ + The issue title. + """ + title: String + """ + Whether the issue has been trashed. Set to true to trash, or null to restore. + """ + trashed: Boolean + """ + [Internal] Whether this issue has been explicitly marked as trusted. + """ + trusted: Boolean +} + +""" +Payload for an issue webhook. +""" +type IssueWebhookPayload { + """ + The time at which the issue was added to a cycle. + """ + addedToCycleAt: String + """ + The time at which the issue was added to a project. + """ + addedToProjectAt: String + """ + The time at which the issue was added to a team. + """ + addedToTeamAt: String + """ + The time at which the entity was archived. + """ + archivedAt: String + """ + The user that is assigned to the issue. + """ + assignee: UserChildWebhookPayload + """ + The ID of the user that is assigned to the issue. + """ + assigneeId: String + """ + The time at which the issue was auto-archived. + """ + autoArchivedAt: String + """ + The time at which the issue was auto-closed. + """ + autoClosedAt: String + """ + The bot actor data for this issue. + """ + botActor: String + """ + The time at which the issue was canceled. + """ + canceledAt: String + """ + The time at which the issue was completed. + """ + completedAt: String + """ + The time at which the entity was created. + """ + createdAt: String! + """ + The user that created the issue. + """ + creator: UserChildWebhookPayload + """ + The ID of the user that created the issue. + """ + creatorId: String + """ + The cycle that the issue belongs to. + """ + cycle: CycleChildWebhookPayload + """ + The ID of the cycle that the issue belongs to. + """ + cycleId: String + """ + The agent user that the issue is delegated to. + """ + delegate: UserChildWebhookPayload + """ + The ID of the agent user that the issue is delegated to. + """ + delegateId: String + """ + The description of the issue. + """ + description: String + """ + The description data of the issue. + """ + descriptionData: String + """ + The due date of the issue. + """ + dueDate: String + """ + The estimate of the complexity of the issue.. + """ + estimate: Float + """ + The external user that created the issue. + """ + externalUserCreator: ExternalUserChildWebhookPayload + """ + The ID of the external user that created the issue. + """ + externalUserCreatorId: String + """ + The ID of the entity. + """ + id: String! + """ + The identifier of the issue. + """ + identifier: String! + """ + Integration type that created this issue, if applicable. + """ + integrationSourceType: String + """ + Id of the labels associated with this issue. + """ + labelIds: [String!]! + """ + The labels associated with this issue. + """ + labels: [IssueLabelChildWebhookPayload!]! + """ + The ID of the last template that was applied to the issue. + """ + lastAppliedTemplateId: String + """ + The project milestone that the issue belongs to. + """ + milestone: ProjectMilestoneChildWebhookPayload + @deprecated(reason: "Use `projectMilestone` instead.") + """ + The issue's unique number. + """ + number: Float! + """ + The ID of the parent issue. + """ + parentId: String + """ + Previous identifiers of the issue if it has been moved between teams. + """ + previousIdentifiers: [String!]! + """ + The priority of the issue. 0 = No priority, 1 = Urgent, 2 = High, 3 = Medium, 4 = Low. + """ + priority: Float! + """ + The label of the issue's priority. + """ + priorityLabel: String! + """ + The order of the item in relation to other items in the organization, when ordered by priority. + """ + prioritySortOrder: Float! + """ + The project that the issue belongs to. + """ + project: ProjectChildWebhookPayload + """ + The ID of the project that the issue belongs to. + """ + projectId: String + """ + The project milestone that the issue belongs to. + """ + projectMilestone: ProjectMilestoneChildWebhookPayload + """ + The ID of the project milestone that the issue belongs to. + """ + projectMilestoneId: String + """ + The reaction data for this issue. + """ + reactionData: JSONObject! + """ + The ID of the recurring issue template that created the issue. + """ + recurringIssueTemplateId: String + """ + The releases associated with this issue. + """ + releases: [ReleaseChildWebhookPayload!]! + """ + The time at which the issue would breach its SLA. + """ + slaBreachesAt: String + """ + The time at which the issue would enter SLA high risk. + """ + slaHighRiskAt: String + """ + The time at which the issue would enter SLA medium risk. + """ + slaMediumRiskAt: String + """ + The time at which the issue's SLA started. + """ + slaStartedAt: String + """ + The type of SLA the issue is under. + """ + slaType: String + """ + The time until an issue will be snoozed in Triage view. + """ + snoozedUntilAt: String + """ + The order of the item in relation to other items in the organization. + """ + sortOrder: Float! + """ + The ID of the source comment that the issue was created from. + """ + sourceCommentId: String + """ + The time at which the issue was moved into started state. + """ + startedAt: String + """ + The time at which the issue entered triage. + """ + startedTriageAt: String + """ + The issue's current workflow state. + """ + state: WorkflowStateChildWebhookPayload! + """ + The ID of the issue's current workflow state. + """ + stateId: String! + """ + The order of the item in the sub-issue list. Only set if the issue has a parent. + """ + subIssueSortOrder: Float + """ + The IDs of the users that are subscribed to the issue. + """ + subscriberIds: [String!]! + """ + The entity this issue is synced with. + """ + syncedWith: JSONObject + """ + The team that the issue belongs to. + """ + team: TeamChildWebhookPayload + """ + The ID of the team that the issue belongs to. + """ + teamId: String! + """ + The issue's title. + """ + title: String! + """ + A flag that indicates whether the issue is in the trash bin. + """ + trashed: Boolean + """ + The time at which the issue was triaged. + """ + triagedAt: String + """ + The time at which the entity was updated. + """ + updatedAt: String! + """ + The URL of the issue. + """ + url: String! +} + +""" +Certain properties of an issue, including its description. +""" +type IssueWithDescriptionChildWebhookPayload { + """ + The description of the issue. + """ + description: String + """ + The ID of the issue. + """ + id: String! + """ + The identifier of the issue. + """ + identifier: String! + """ + The ID of the team that the issue belongs to. + """ + team: TeamChildWebhookPayload! + """ + The ID of the team that the issue belongs to. + """ + teamId: String! + """ + The title of the issue. + """ + title: String! + """ + The URL of the issue. + """ + url: String! +} + +""" +The `JSON` scalar type represents arbitrary values as *stringified* JSON +""" +scalar JSON + +""" +The `JSONObject` scalar type represents arbitrary values as *embedded* JSON +""" +scalar JSONObject + +input JiraConfigurationInput { + """ + The Jira personal access token, or the API key of a Jira Cloud service account. + """ + accessToken: String! + """ + The Jira user's email address. A username is also accepted on Jira Server / DC. + """ + email: String! + """ + The Jira installation hostname. + """ + hostname: String! + """ + Whether this integration will be setup using the manual webhook flow. + """ + manualSetup: Boolean + """ + Whether the access token is the API key of a Jira Cloud service account. Defaults to detecting the service account key prefix. The site's cloudId is resolved from the hostname, and webhooks are always set up manually. + """ + serviceAccount: Boolean +} + +input JiraFetchProjectStatusesInput { + """ + The id of the Jira integration. + """ + integrationId: String! + """ + The Jira project ID to fetch statuses for. + """ + projectId: String! +} + +type JiraFetchProjectStatusesPayload { + """ + GitHub-specific details for the operation. Populated by GitHub-related mutations only. + """ + gitHub: GitHubIntegrationConnectDetails + """ + The integration that was created or updated. + """ + integration: Integration + """ + The fetched Jira issue statuses (non-Epic). + """ + issueStatuses: [String!]! + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + The fetched Jira project statuses (Epic). + """ + projectStatuses: [String!]! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +input JiraLinearMappingInput { + """ + Whether the sync for this mapping is bidirectional. + """ + bidirectional: Boolean + """ + Whether this mapping is the default one for issue creation. + """ + default: Boolean + """ + The Jira id for this project. + """ + jiraProjectId: String! + """ + Whether this mapping uses legacy unidirectional sync behavior where no changes sync from Linear to Jira. + """ + legacyUnidirectional: Boolean + """ + The Linear team id to map to the given project. + """ + linearTeamId: String! +} + +input JiraPersonalSettingsInput { + """ + The name of the Jira site currently authorized through the integration. + """ + siteName: String + """ + The id of the workspace Jira integration this personal integration authenticates through. + """ + workspaceIntegrationId: String +} + +input JiraProjectDataInput { + """ + The Jira id for this project. + """ + id: String! + """ + The Jira key for this project, such as ENG. + """ + key: String! + """ + The Jira name for this project, such as Engineering. + """ + name: String! +} + +type JiraProjectStatusesPayload { + """ + The status categories of each of the Jira project's issue statuses (non-Epic). + """ + issueStatusCategories: [JiraStatusNameCategoriesPayload!]! + """ + The Jira project's issue statuses (non-Epic). + """ + issueStatuses: [String!]! + """ + The status categories of each of the Jira project's project statuses (Epic). + """ + projectStatusCategories: [JiraStatusNameCategoriesPayload!]! + """ + The Jira project's project statuses (Epic). + """ + projectStatuses: [String!]! +} + +input JiraSettingsInput { + """ + The custom OAuth server token endpoint URL (enterprise SSO). + """ + customOAuthServerUrl: String + """ + Whether this integration authenticates with a Jira Cloud service account API key. + """ + isCloudServiceAccount: Boolean + """ + Whether this integration uses custom OAuth authentication (enterprise SSO). + """ + isCustomOAuth: Boolean + """ + Whether this integration is for Jira Server or not. + """ + isJiraServer: Boolean = false + """ + The label of the Jira instance, for visual identification purposes only + """ + label: String + """ + Whether this integration is using a manual setup flow. + """ + manualSetup: Boolean + """ + The OAuth client ID for the personal connection OAuth app, when using custom OAuth. + """ + personalOAuthClientId: String + """ + The mapping of Jira project id => Linear team id. + """ + projectMapping: [JiraLinearMappingInput!] + """ + The Jira projects for the organization. + """ + projects: [JiraProjectDataInput!]! + """ + Whether the user needs to provide setup information about the webhook to complete the integration setup. Only relevant for integrations that use a manual setup flow + """ + setupPending: Boolean +} + +type JiraStatusNameCategoriesPayload { + """ + The distinct status category keys (new, indeterminate, or done) of the Jira statuses with this name. + """ + categories: [String!]! + """ + The name of the Jira status. + """ + name: String! +} + +input JiraUpdateInput { + """ + The Jira personal access token, or the API key of a Jira Cloud service account. + """ + accessToken: String + """ + The mapped Jira project to use as its team's default. Omit to keep the current default. + """ + defaultProjectId: String + """ + Whether to delete the current manual webhook configuration. + """ + deleteWebhook: Boolean + """ + The Jira user email address associated with the access token. + """ + email: String + """ + The id of the integration to update. + """ + id: String! + """ + Whether to refresh Jira metadata for the integration. + """ + updateMetadata: Boolean + """ + Whether to refresh Jira Projects for the integration. + """ + updateProjects: Boolean + """ + Webhook secret for a new manual configuration. + """ + webhookSecret: String +} + +input JoinOrganizationInput { + """ + An optional invite link for an organization. + """ + inviteLink: String + """ + The identifier of the organization. + """ + organizationId: String! +} + +""" +Issue label-group sorting options. +""" +input LabelGroupSort { + """ + The label-group id to sort by + """ + labelGroupId: String! + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +The selection mode of a label group. +""" +enum LabelGroupType { + multiSelect + singleSelect +} + +""" +A notification subscription scoped to a specific issue label. The subscriber receives notifications for events related to issues with this label. +""" +type LabelNotificationSubscription implements Entity & Node & NotificationSubscription { + """ + Whether the subscription is active. When inactive, no notifications are generated from this subscription even though it still exists. + """ + active: Boolean! + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The type of contextual view (e.g., active issues, backlog) that further scopes a team notification subscription. Null if the subscription is not associated with a specific view type. + """ + contextViewType: ContextViewType + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The custom view that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + customView: CustomView + """ + The customer that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + customer: Customer + """ + The cycle that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + cycle: Cycle + """ + The unique identifier of the entity. + """ + id: ID! + """ + Whether initiative update notifications also include updates from sub-initiatives. Applies only when initiative updates are enabled and the workspace supports sub-initiatives. + """ + includeSubInitiativeUpdates: Boolean! + """ + The initiative that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + initiative: Initiative + """ + The label subscribed to. + """ + label: IssueLabel! + """ + The notification event types that this subscription will deliver to the subscriber. + """ + notificationSubscriptionTypes: [String!]! + """ + The project that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + project: Project + """ + The user who will receive notifications from this subscription. + """ + subscriber: User! + """ + The team that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + team: Team + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The user that this notification subscription is scoped to, for user-specific view subscriptions. Null if the subscription targets a different entity type. + """ + user: User + """ + The type of user-specific view that further scopes a user notification subscription. Null if the subscription is not associated with a user view type. + """ + userContextViewType: UserContextViewType +} + +""" +Issue label sorting options. +""" +input LabelSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +input LaunchDarklySettingsInput { + """ + The environment of the LaunchDarkly integration. + """ + environment: String! + """ + The project key of the LaunchDarkly integration. + """ + projectKey: String! +} + +""" +How workspace MCP server access is restricted for Linear Agent. +""" +enum LinearAgentMcpServersMode { + all + allowlist +} + +""" +How workspace trusted source access is restricted for loops. +""" +enum LinearAgentTrustedSourcesMode { + allowlist + none +} + +""" +[ALPHA] Issue link count sorting options. +""" +input LinkCountSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +type LogoutResponse { + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +[Internal] A Loop execution and the entity that triggered it. +""" +type LoopExecution implements Node { + """ + [Internal] The AI conversation created for this Loop execution. + """ + aiConversation: AiConversation! + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + [Internal] The cycle that triggered this Loop execution. + """ + cycle: Cycle + """ + [Internal] The document that triggered this Loop execution. + """ + document: Document + """ + The unique identifier of the entity. + """ + id: ID! + """ + [Internal] The initiative that triggered this Loop execution. + """ + initiative: Initiative + """ + [Internal] The issue that triggered this Loop execution. + """ + issue: Issue + """ + [Internal] The project that triggered this Loop execution. + """ + project: Project + """ + [Internal] The release that triggered this Loop execution. + """ + release: Release + """ + [Internal] The team that triggered this Loop execution. + """ + team: Team + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + [Internal] The Loop that was executed. + """ + workflowDefinition: WorkflowDefinition +} + +""" +Issue manual sorting options. +""" +input ManualSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +An additional HTTP header sent with requests to the connected MCP server. Header values are stored securely. +""" +input McpServerCustomHeaderInput { + """ + The HTTP header name. + """ + name: String! + """ + The HTTP header value. + """ + value: String! +} + +input McpServerIntegrationSettingsInput { + """ + Who may use this connector in conversations. + """ + conversationAccess: String + """ + Who may add this connector to a Loop. + """ + loopAccess: String + """ + The connection-specific display name. + """ + name: String +} + +""" +[Internal] A meeting attached to one project or initiative. Its transcript is stored in related document content. +""" +type Meeting implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + [Internal] The IDs of the workspace users who attended the meeting, identified during import. + """ + attendeeIds: [String!]! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + [Internal] The user who created the meeting. Null if the user was deleted. + """ + creator: User + """ + [Internal] The date when the meeting occurred. Null when clients should use the creation date. + """ + date: TimelessDate + """ + The unique identifier of the entity. + """ + id: ID! + """ + [Internal] The initiative that contains the meeting. Null when the meeting belongs to a project. + """ + initiative: Initiative + """ + [Internal] The project that contains the meeting. Null when the meeting belongs to an initiative. + """ + project: Project + """ + [Internal] The meeting title generated during import. Null when the import produced no title. + """ + title: String + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +type MicrosoftTeamsChannel { + """ + The display name of the channel. + """ + displayName: String! + """ + The Microsoft Teams channel id (e.g. `19:abc@thread.tacv2`). + """ + id: String! + """ + The membership type of the channel: standard, private, or shared. + """ + membershipType: String! +} + +type MicrosoftTeamsChannelsPayload { + """ + Whether the operation was successful. + """ + success: Boolean! + """ + The teams the user belongs to with their channels. + """ + teams: [MicrosoftTeamsTeam!]! +} + +input MicrosoftTeamsPostSettingsInput { + """ + Microsoft Teams channel id. + """ + channelId: String! + """ + Display name of the channel. + """ + channelName: String! + """ + Membership type of the channel: standard, private, or shared. + """ + membershipType: String! + """ + AAD group id of the Team. + """ + teamId: String! + """ + Display name of the Team. + """ + teamName: String! + """ + Azure AD tenant id the team belongs to. + """ + tenantId: String! +} + +input MicrosoftTeamsSettingsInput { + """ + Whether Code Intelligence should be enabled for this Microsoft Teams integration. + """ + enableCodeIntelligence: Boolean + """ + The display name of the Azure AD tenant. + """ + tenantName: String +} + +type MicrosoftTeamsTeam { + """ + The channels in the team the user can access. + """ + channels: [MicrosoftTeamsChannel!]! + """ + The display name of the team. + """ + displayName: String! + """ + The AAD group id of the team. + """ + id: String! +} + +""" +Issue project milestone options. +""" +input MilestoneSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +type Mutation { + """ + Creates an agent activity. + """ + agentActivityCreate( + """ + The agent activity object to create. + """ + input: AgentActivityCreateInput! + ): AgentActivityPayload! + """ + [Internal] Creates a prompt agent activity from Linear user input. + """ + agentActivityCreatePrompt( + """ + The prompt agent activity object to create. + """ + input: AgentActivityCreatePromptInput! + ): AgentActivityPayload! + """ + [Internal] Deletes a queued prompt activity, removing it from the queue. + """ + agentActivityDeleteQueued( + """ + The ID of the queued agent activity to delete. + """ + id: String! + ): AgentActivityPayload! + """ + [Internal] Immediately sends a queued prompt activity to the agent, bypassing the queue. + """ + agentActivitySendQueued( + """ + The ID of the queued agent activity to send. + """ + id: String! + ): AgentActivityPayload! + """ + [Internal] Creates a new agent session on behalf of the current user + """ + agentSessionCreate( + """ + The agent session object to create. + """ + input: AgentSessionCreateInput! + """ + [Internal] Optional pull request to associate with the created session. + """ + pullRequestId: String + ): AgentSessionPayload! + """ + Creates a new agent session on a root comment. + """ + agentSessionCreateOnComment( + """ + The agent session object to create. + """ + input: AgentSessionCreateOnComment! + ): AgentSessionPayload! + """ + Creates a new agent session on an issue. + """ + agentSessionCreateOnIssue( + """ + The agent session object to create. + """ + input: AgentSessionCreateOnIssue! + ): AgentSessionPayload! + """ + [Internal] Restarts a routed coding session with the default model. + """ + agentSessionRestartWithDefaultModel( + """ + The identifier of the agent session to restart. + """ + id: String! + ): AgentSessionPayload! + """ + Updates an agent session. + """ + agentSessionUpdate( + """ + The identifier of the agent session to update. + """ + id: String! + """ + A partial agent session object to update the agent session with. + """ + input: AgentSessionUpdateInput! + ): AgentSessionPayload! + """ + Updates the externalUrl of an agent session, which is an agent-hosted page associated with this session. + """ + agentSessionUpdateExternalUrl( + """ + The identifier of the agent session to update. + """ + id: String! + """ + The agent session object to update. + """ + input: AgentSessionUpdateExternalUrlInput! + ): AgentSessionPayload! + """ + Creates an agent skill. + """ + agentSkillCreate( + """ + The agent skill object to create. + """ + input: AgentSkillCreateInput! + ): AgentSkillPayload! + """ + Deletes an agent skill. + """ + agentSkillDelete( + """ + The identifier of the agent skill to delete. + """ + id: String! + ): DeletePayload! + """ + Updates an agent skill. + """ + agentSkillUpdate( + """ + The identifier of the agent skill to update. + """ + id: String! + """ + Data to update the agent skill with. + """ + input: AgentSkillUpdateInput! + ): AgentSkillPayload! + """ + Creates an integration api key for Airbyte to connect with Linear. + """ + airbyteIntegrationConnect( + """ + Airbyte integration settings. + """ + input: AirbyteConfigurationInput! + ): IntegrationPayload! + """ + Creates a new attachment, or updates existing if the same `url` and `issueId` is used. To create an integration-aware attachment, use the integration-specific mutations such as `attachmentLinkZendesk`, `attachmentLinkSlack`, or `attachmentLinkURL` instead. + """ + attachmentCreate( + """ + The attachment object to create. + """ + input: AttachmentCreateInput! + ): AttachmentPayload! + """ + Deletes an issue attachment. + """ + attachmentDelete( + """ + The identifier of the attachment to delete. + """ + id: String! + ): DeletePayload! + """ + Link an existing Discord message to an issue. This creates a rich attachment using the workspace's Discord integration. + """ + attachmentLinkDiscord( + """ + The Discord channel ID for the message to link. + """ + channelId: String! + """ + Create attachment as a user with the provided name. This option is only available to OAuth applications creating attachments in `actor=app` mode. + """ + createAsUser: String + """ + Provide an external user avatar URL. Can only be used in conjunction with the `createAsUser` options. This option is only available to OAuth applications creating comments in `actor=app` mode. + """ + displayIconUrl: String + """ + Optional attachment ID that may be provided through the API. + """ + id: String + """ + The issue for which to link the Discord message. Can be a UUID or issue identifier (e.g., 'LIN-123'). + """ + issueId: String! + """ + The Discord message ID for the message to link. + """ + messageId: String! + """ + The title to use for the attachment. + """ + title: String + """ + The Discord message URL for the message to link. + """ + url: String! + ): AttachmentPayload! + """ + Link an existing Front conversation to an issue. This creates a rich attachment using the workspace's Front integration, enabling features like automated conversation updates. + """ + attachmentLinkFront( + """ + The Front conversation ID to link. + """ + conversationId: String! + """ + Create attachment as a user with the provided name. This option is only available to OAuth applications creating attachments in `actor=app` mode. + """ + createAsUser: String + """ + Provide an external user avatar URL. Can only be used in conjunction with the `createAsUser` options. This option is only available to OAuth applications creating comments in `actor=app` mode. + """ + displayIconUrl: String + """ + Optional attachment ID that may be provided through the API. + """ + id: String + """ + The issue for which to link the Front conversation. Can be a UUID or issue identifier (e.g., 'LIN-123'). + """ + issueId: String! + """ + The title to use for the attachment. + """ + title: String + ): FrontAttachmentPayload! + """ + Link a GitHub issue to a Linear issue. This creates a rich attachment using the workspace's GitHub integration, enabling features like automated status syncing. + """ + attachmentLinkGitHubIssue( + """ + Create attachment as a user with the provided name. This option is only available to OAuth applications creating attachments in `actor=app` mode. + """ + createAsUser: String + """ + Provide an external user avatar URL. Can only be used in conjunction with the `createAsUser` options. This option is only available to OAuth applications creating comments in `actor=app` mode. + """ + displayIconUrl: String + """ + Optional attachment ID that may be provided through the API. + """ + id: String + """ + The Linear issue for which to link the GitHub issue. Can be a UUID or issue identifier (e.g., 'LIN-123'). + """ + issueId: String! + """ + The title to use for the attachment. + """ + title: String + """ + The URL of the GitHub issue to link. + """ + url: String! + ): AttachmentPayload! + """ + Link a GitHub pull request to an issue. This creates a rich attachment using the workspace's GitHub integration, enabling features like automated status syncing. + """ + attachmentLinkGitHubPR( + """ + Create attachment as a user with the provided name. This option is only available to OAuth applications creating attachments in `actor=app` mode. + """ + createAsUser: String + """ + Provide an external user avatar URL. Can only be used in conjunction with the `createAsUser` options. This option is only available to OAuth applications creating comments in `actor=app` mode. + """ + displayIconUrl: String + """ + Optional attachment ID that may be provided through the API. + """ + id: String + """ + The issue for which to link the GitHub pull request. Can be a UUID or issue identifier (e.g., 'LIN-123'). + """ + issueId: String! + """ + [Internal] The kind of link between the issue and the pull request. + """ + linkKind: GitLinkKind + """ + The title to use for the attachment. + """ + title: String + """ + The URL of the GitHub pull request to link. + """ + url: String! + ): AttachmentPayload! + """ + Link an existing GitLab MR to an issue. This creates a rich attachment using the workspace's GitLab integration, enabling features like automated status syncing. + """ + attachmentLinkGitLabMR( + """ + Create attachment as a user with the provided name. This option is only available to OAuth applications creating attachments in `actor=app` mode. + """ + createAsUser: String + """ + Provide an external user avatar URL. Can only be used in conjunction with the `createAsUser` options. This option is only available to OAuth applications creating comments in `actor=app` mode. + """ + displayIconUrl: String + """ + Optional attachment ID that may be provided through the API. + """ + id: String + """ + The issue for which to link the GitLab merge request. Can be a UUID or issue identifier (e.g., 'LIN-123'). + """ + issueId: String! + """ + The GitLab merge request number to link. + """ + number: Float! + """ + The path name to the project including any (sub)groups. E.g. linear/main/client. + """ + projectPathWithNamespace: String! + """ + The title to use for the attachment. + """ + title: String + """ + The URL of the GitLab merge request to link. + """ + url: String! + ): AttachmentPayload! + """ + Link an existing Intercom conversation to an issue. This creates a rich attachment using the workspace's Intercom integration, enabling features like automated conversation updates. + """ + attachmentLinkIntercom( + """ + The Intercom conversation ID to link. + """ + conversationId: String! + """ + Create attachment as a user with the provided name. This option is only available to OAuth applications creating attachments in `actor=app` mode. + """ + createAsUser: String + """ + Provide an external user avatar URL. Can only be used in conjunction with the `createAsUser` options. This option is only available to OAuth applications creating comments in `actor=app` mode. + """ + displayIconUrl: String + """ + Optional attachment ID that may be provided through the API. + """ + id: String + """ + The issue for which to link the Intercom conversation. Can be a UUID or issue identifier (e.g., 'LIN-123'). + """ + issueId: String! + """ + An optional Intercom conversation part ID to link to + """ + partId: String + """ + The title to use for the attachment. + """ + title: String + ): AttachmentPayload! + """ + Link an existing Jira issue to an issue. This creates a rich attachment using the workspace's Jira integration, enabling features like automated status syncing. + """ + attachmentLinkJiraIssue( + """ + Create attachment as a user with the provided name. This option is only available to OAuth applications creating attachments in `actor=app` mode. + """ + createAsUser: String + """ + Provide an external user avatar URL. Can only be used in conjunction with the `createAsUser` options. This option is only available to OAuth applications creating comments in `actor=app` mode. + """ + displayIconUrl: String + """ + Optional attachment ID that may be provided through the API. + """ + id: String + """ + The issue for which to link the Jira issue. Can be a UUID or issue identifier (e.g., 'LIN-123'). + """ + issueId: String! + """ + The Jira issue key or ID to link. + """ + jiraIssueId: String! + """ + The title to use for the attachment. + """ + title: String + """ + Optional fallback URL to use if the Jira issue cannot be found. + """ + url: String + ): AttachmentPayload! + """ + Link an existing Salesforce case to an issue. This creates a rich attachment using the workspace's Salesforce integration. + """ + attachmentLinkSalesforce( + """ + Create attachment as a user with the provided name. This option is only available to OAuth applications creating attachments in `actor=app` mode. + """ + createAsUser: String + """ + Provide an external user avatar URL. Can only be used in conjunction with the `createAsUser` options. This option is only available to OAuth applications creating comments in `actor=app` mode. + """ + displayIconUrl: String + """ + Optional attachment ID that may be provided through the API. + """ + id: String + """ + The issue for which to link the Salesforce case. Can be a UUID or issue identifier (e.g., 'LIN-123'). + """ + issueId: String! + """ + The title to use for the attachment. + """ + title: String + """ + The URL of the Salesforce case to link. + """ + url: String! + ): AttachmentPayload! + """ + Link an existing Slack message to an issue. This creates a rich attachment using the workspace's Slack integration. + """ + attachmentLinkSlack( + """ + Create attachment as a user with the provided name. This option is only available to OAuth applications creating attachments in `actor=app` mode. + """ + createAsUser: String + """ + Provide an external user avatar URL. Can only be used in conjunction with the `createAsUser` options. This option is only available to OAuth applications creating comments in `actor=app` mode. + """ + displayIconUrl: String + """ + Optional attachment ID that may be provided through the API. + """ + id: String + """ + The issue to which to link the Slack message. Can be a UUID or issue identifier (e.g., 'LIN-123'). + """ + issueId: String! + """ + Whether to begin syncing the message's Slack thread with a comment thread on the issue. + """ + syncToCommentThread: Boolean + """ + The title to use for the attachment. + """ + title: String + """ + The Slack message URL for the message to link. + """ + url: String! + ): AttachmentPayload! + """ + Link any URL to an issue. If the workspace has a matching integration configured and the URL is recognized (e.g., Zendesk, GitHub, Slack), a rich attachment will be created that enables features like automated status updates. Otherwise, a basic attachment is created. + """ + attachmentLinkURL( + """ + Create attachment as a user with the provided name. This option is only available to OAuth applications creating attachments in `actor=app` mode. + """ + createAsUser: String + """ + Provide an external user avatar URL. Can only be used in conjunction with the `createAsUser` options. This option is only available to OAuth applications creating comments in `actor=app` mode. + """ + displayIconUrl: String + """ + The id for the attachment. + """ + id: String + """ + The issue for which to link the url. Can be a UUID or issue identifier (e.g., 'LIN-123'). + """ + issueId: String! + """ + The title to use for the attachment. + """ + title: String + """ + The url to link. + """ + url: String! + ): AttachmentPayload! + """ + Link an existing Zendesk ticket to an issue. This creates a rich attachment using the workspace's Zendesk integration, enabling features like automated ticket reopening when the Linear issue is completed. + """ + attachmentLinkZendesk( + """ + Create attachment as a user with the provided name. This option is only available to OAuth applications creating attachments in `actor=app` mode. + """ + createAsUser: String + """ + Provide an external user avatar URL. Can only be used in conjunction with the `createAsUser` options. This option is only available to OAuth applications creating comments in `actor=app` mode. + """ + displayIconUrl: String + """ + Optional attachment ID that may be provided through the API. + """ + id: String + """ + The issue for which to link the Zendesk ticket. Can be a UUID or issue identifier (e.g., 'LIN-123'). + """ + issueId: String! + """ + The Zendesk ticket ID to link. + """ + ticketId: String! + """ + The title to use for the attachment. + """ + title: String + """ + The URL of the Zendesk ticket to link. + """ + url: String + ): AttachmentPayload! + """ + Begin syncing the thread for an existing Slack message attachment with a comment thread on its issue. + """ + attachmentSyncToSlack( + """ + The ID of the Slack attachment to begin syncing. + """ + id: String! + ): AttachmentPayload! + """ + Updates an existing issue attachment. + """ + attachmentUpdate( + """ + The identifier of the attachment to update. + """ + id: String! + """ + A partial attachment object to update the attachment with. + """ + input: AttachmentUpdateInput! + ): AttachmentPayload! + """ + Creates a new comment. + """ + commentCreate( + """ + The comment object to create. + """ + input: CommentCreateInput! + ): CommentPayload! + """ + Deletes a comment. + """ + commentDelete( + """ + The identifier of the comment to delete. + """ + id: String! + ): DeletePayload! + """ + Resolves a comment thread. Marks the root comment as resolved by the current user. + """ + commentResolve( + """ + The identifier of the comment to resolve. + """ + id: String! + """ + The identifier of the child comment that resolves the thread. If not provided, the thread is resolved without a specific resolving comment. + """ + resolvingCommentId: String + ): CommentPayload! + """ + Unresolves a previously resolved comment thread. Clears the resolved state on the root comment. + """ + commentUnresolve( + """ + The identifier of the comment to unresolve. + """ + id: String! + ): CommentPayload! + """ + Updates a comment. + """ + commentUpdate( + """ + The identifier of the comment to update. + """ + id: String! + """ + A partial comment object to update the comment with. + """ + input: CommentUpdateInput! + """ + [INTERNAL] Flag to prevent setting editedAt when updating bodyData (used for background uploads). + """ + skipEditedAt: Boolean + ): CommentPayload! + """ + Creates a support contact message from an authenticated user. The message is saved and forwarded to Intercom for support handling. + """ + contactCreate( + """ + The contact entry to create. + """ + input: ContactCreateInput! + ): ContactPayload! + """ + [INTERNAL] Submits a sales pricing inquiry from the website. Small companies (1-19 employees) are routed to Intercom, while larger companies are routed to HubSpot. + """ + contactSalesCreate( + """ + The contact entry to create. + """ + input: ContactSalesCreateInput! + ): ContactPayload! + """ + Creates a CSV export report for the workspace. The report is generated asynchronously and delivered via email. Requires workspace admin export permission. + """ + createCsvExportReport( + """ + IDs of private teams to include in the export. If null, only data from public teams is exported. + """ + includePrivateTeamIds: [String!] + """ + IDs of restricted teams to include in the export. If null, restricted team data is omitted. + """ + includeRestrictedTeamIds: [String!] + ): CreateCsvExportReportPayload! + """ + Create a notification to remind a user about an initiative update. + """ + createInitiativeUpdateReminder( + """ + The identifier of the initiative to remind about. + """ + initiativeId: String! + """ + The user identifier to whom the notification will be sent. By default, it is set to the initiative owner. + """ + userId: String + ): InitiativeUpdateReminderPayload! + """ + Creates a new workspace from onboarding. + """ + createOrganizationFromOnboarding( + """ + Details for the new workspace. + """ + input: CreateOrganizationInput! + """ + Signed partner-offer signup token minted when the visitor redeemed a partner offer on the marketing website. + """ + partnerOfferToken: String + """ + PostHog session ID for attribution tracking. + """ + sessionId: String + """ + Onboarding survey. + """ + survey: OnboardingCustomerSurvey + ): CreateOrJoinOrganizationResponse! + """ + Create a notification to remind a user about a project update. + """ + createProjectUpdateReminder( + """ + The identifier of the project to remind about. + """ + projectId: String! + """ + The user identifier to whom the notification will be sent. By default, it is set to the project lead. + """ + userId: String + ): ProjectUpdateReminderPayload! + """ + Creates a new custom view. + """ + customViewCreate( + """ + The properties of the custom view to create. + """ + input: CustomViewCreateInput! + ): CustomViewPayload! + """ + Deletes a custom view. + """ + customViewDelete( + """ + The identifier of the custom view to delete. + """ + id: String! + ): DeletePayload! + """ + Updates a custom view. + """ + customViewUpdate( + """ + The identifier of the custom view to update. + """ + id: String! + """ + The properties of the custom view to update. + """ + input: CustomViewUpdateInput! + ): CustomViewPayload! + """ + Creates a new customer. + """ + customerCreate( + """ + The customer to create. + """ + input: CustomerCreateInput! + ): CustomerPayload! + """ + Deletes a customer. + """ + customerDelete( + """ + The identifier of the customer to delete. + """ + id: String! + ): DeletePayload! + """ + Merges two customers by transferring all needs from the source customer to the target customer. The source customer is archived after the merge. Domains, external IDs, and metadata are combined on the target customer. + """ + customerMerge( + """ + The ID of the source customer to merge. All needs from this customer will be transferred to the target, and this customer will be archived. + """ + sourceCustomerId: String! + """ + The ID of the target customer to merge into. This customer will receive all needs from the source customer and retain its own. + """ + targetCustomerId: String! + ): CustomerPayload! + """ + Archives a customer need. + """ + customerNeedArchive( + """ + The identifier of the customer need to archive. + """ + id: String! + ): CustomerNeedArchivePayload! + """ + Creates a new customer need. + """ + customerNeedCreate( + """ + The customer need to create. + """ + input: CustomerNeedCreateInput! + ): CustomerNeedPayload! + """ + Creates a new customer need from an existing issue attachment. If the attachment already has an archived need, it will be unarchived instead of creating a duplicate. + """ + customerNeedCreateFromAttachment( + """ + The customer need to create. + """ + input: CustomerNeedCreateFromAttachmentInput! + ): CustomerNeedPayload! + """ + Deletes a customer need. + """ + customerNeedDelete( + """ + The identifier of the customer need to delete. + """ + id: String! + """ + Whether to keep the attachment associated with the customer need. + """ + keepAttachment: Boolean + ): DeletePayload! + """ + Unarchives a customer need. + """ + customerNeedUnarchive( + """ + The identifier of the customer need to unarchive. + """ + id: String! + ): CustomerNeedArchivePayload! + """ + Updates an existing customer need. Supports moving the need to a different issue or project, changing priority, updating the body content, and managing the attached source URL. + """ + customerNeedUpdate( + """ + Whether to remove any existing attachment associated with the customer need. + """ + clearAttachment: Boolean + """ + The identifier of the customer need to update. + """ + id: String! + """ + The properties of the customer need to update. + """ + input: CustomerNeedUpdateInput! + ): CustomerNeedUpdatePayload! + """ + Creates a new customer status. + """ + customerStatusCreate( + """ + The CustomerStatus object to create. + """ + input: CustomerStatusCreateInput! + ): CustomerStatusPayload! + """ + Deletes a customer status. Cannot delete the last remaining status in a workspace, and the status must not be in use by any customers. + """ + customerStatusDelete( + """ + The identifier of the customer status to delete. + """ + id: String! + ): DeletePayload! + """ + Updates a customer status. + """ + customerStatusUpdate( + """ + The identifier of the customer status to update. + """ + id: String! + """ + A partial CustomerStatus object to update the CustomerStatus with. + """ + input: CustomerStatusUpdateInput! + ): CustomerStatusPayload! + """ + Creates a new customer tier. + """ + customerTierCreate( + """ + The CustomerTier object to create. + """ + input: CustomerTierCreateInput! + ): CustomerTierPayload! + """ + Deletes a customer tier. The tier must not be in use by any customers. + """ + customerTierDelete( + """ + The identifier of the customer tier to delete. + """ + id: String! + ): DeletePayload! + """ + Updates a customer tier. + """ + customerTierUpdate( + """ + The identifier of the customer tier to update. + """ + id: String! + """ + A partial CustomerTier object to update the CustomerTier with. + """ + input: CustomerTierUpdateInput! + ): CustomerTierPayload! + """ + Unsyncs a managed customer from its current data source integration. External IDs mapping to the external source will be cleared, and the customer will no longer be updated by the integration. + """ + customerUnsync( + """ + The identifier of the customer to unsync. + """ + id: String! + ): CustomerPayload! + """ + Updates an existing customer. + """ + customerUpdate( + """ + The identifier of the customer to update. + """ + id: String! + """ + The properties of the customer to update. + """ + input: CustomerUpdateInput! + ): CustomerPayload! + """ + Upserts a customer, creating it if no match is found, or updating it otherwise. Matches against existing customers using `id`, `externalId`, `slackChannelId`, or `domains`. + """ + customerUpsert( + """ + The customer to create. + """ + input: CustomerUpsertInput! + ): CustomerPayload! + """ + Archives a cycle. All issues currently assigned to the cycle are unlinked from it before archiving. + """ + cycleArchive( + """ + The identifier of the cycle to archive. + """ + id: String! + ): CycleArchivePayload! + """ + Creates a new cycle. + """ + cycleCreate( + """ + The cycle object to create. + """ + input: CycleCreateInput! + ): CyclePayload! @deprecated(reason: "Cycle creation is not supported.") + """ + Shifts all cycles starts and ends by a certain number of days, starting from the provided cycle onwards. + """ + cycleShiftAll( + """ + The shift parameters specifying which cycle to start from and how many days to shift. + """ + input: CycleShiftAllInput! + ): CyclePayload! + """ + Starts the upcoming cycle as of midnight today. Completes the previous cycle if it has not yet ended. Only the next upcoming (not yet started) cycle for the team can be started. + """ + cycleStartUpcomingCycleToday( + """ + The identifier of the cycle to start as of midnight today. Must be the upcoming cycle. + """ + id: String! + ): CyclePayload! + """ + Updates a cycle. + """ + cycleUpdate( + """ + The identifier of the cycle to update. + """ + id: String! + """ + A partial cycle object to update the cycle with. + """ + input: CycleUpdateInput! + ): CyclePayload! + """ + Creates a new document. + """ + documentCreate( + """ + The document to create. + """ + input: DocumentCreateInput! + ): DocumentPayload! + """ + Deletes (trashes) a document. The document is marked as trashed and archived, but not permanently removed. + """ + documentDelete( + """ + The identifier of the document to delete. + """ + id: String! + """ + [Internal] Only trash the document if it is still a sub-document of this document. Otherwise the mutation fails and the document is left unchanged. + """ + ifParentDocumentId: String + ): DocumentArchivePayload! + """ + [Internal] Shares a personal document and its sub-documents with workspace members at a role. Only the owner of the document can share it. New collaborators are subscribed to the document. Users who already have another role move to the given one. + """ + documentShare( + """ + The identifier of the personal document to share. + """ + id: String! + """ + The role of the collaborators. Defaults to edit. + """ + role: DocumentShareRole = edit + """ + The identifiers of the users to share the document with. + """ + userIds: [String!]! + ): DocumentPayload! + """ + Restores a previously trashed document by unarchiving it. + """ + documentUnarchive( + """ + The identifier of the document to restore. + """ + id: String! + ): DocumentArchivePayload! + """ + [Internal] Stops sharing a personal document and its sub-documents with users. The owner can remove any collaborator; a collaborator can only remove themselves. + """ + documentUnshare( + """ + The identifier of the personal document to stop sharing. + """ + id: String! + """ + The identifiers of the users to remove from the document. + """ + userIds: [String!]! + ): DocumentPayload! + """ + Updates a document. + """ + documentUpdate( + """ + The identifier of the document to update. Also the identifier from the URL is accepted. + """ + id: String! + """ + A partial document object to update the document with. + """ + input: DocumentUpdateInput! + ): DocumentPayload! + """ + [Internal] Changes the role of users a personal document is shared with. Only the owner of the document can change roles. Only users who already collaborate on the document change; no one is added. With applyToSubDocuments, sub-documents where a user has the role they had on this document before the change are also changed. + """ + documentUpdateCollaboratorRole( + """ + Whether to also change the sub-documents where each user has the role they had on this document before the change. Sub-documents where they have a different role keep it. + """ + applyToSubDocuments: Boolean = false + """ + The identifier of the personal document. + """ + id: String! + """ + The role the users had on this document when the change was confirmed. When given, the change fails if any of the users has another role on the document now. + """ + previousRole: DocumentShareRole + """ + The new role of the collaborators. + """ + role: DocumentShareRole! + """ + The identifiers of the collaborators whose role changes. + """ + userIds: [String!]! + ): DocumentPayload! + """ + [Internal] Changes what users other than the owner can do with a document that is not personal: edit, comment, or view. Only the owner of the document or a workspace admin can change it. Comment and view need an owner who can access the document. + """ + documentUpdateGeneralAccess( + """ + Whether to also change the sub-documents whose level equals the document's level before the change. Sub-documents with another level, without an owner who can access them, or that the user cannot loosen keep their level. + """ + applyToSubDocuments: Boolean = false + """ + The new general access level: edit, comment, or view. + """ + generalAccess: String! + """ + The identifier of the document. + """ + id: String! + """ + The general access level of this document when the change was confirmed. When given, the change fails if the document has another level now. + """ + previousGeneralAccess: String + ): DocumentPayload! + """ + Creates a new email intake address. + """ + emailIntakeAddressCreate( + """ + The email intake address object to create. + """ + input: EmailIntakeAddressCreateInput! + ): EmailIntakeAddressPayload! + """ + Deletes an email intake address object. + """ + emailIntakeAddressDelete( + """ + The identifier of the email intake address to delete. + """ + id: String! + ): DeletePayload! + """ + Requests an immediate, on-demand SES domain verification status check for an email intake address and keeps it in the frequent (per-minute) check lane for a short window. Use when a user is actively configuring their custom sending domain so authorization converges quickly instead of waiting for the once-a-day lane. + """ + emailIntakeAddressRefreshSesDomainStatus( + """ + The identifier of the email intake address to refresh the domain status for. + """ + id: String! + ): EmailIntakeAddressRefreshSesDomainStatusPayload! + """ + Rotates an existing email intake address. + """ + emailIntakeAddressRotate( + """ + The identifier of the email intake address. + """ + id: String! + ): EmailIntakeAddressPayload! + """ + Updates an existing email intake address. + """ + emailIntakeAddressUpdate( + """ + The identifier of the email intake address. + """ + id: String! + """ + The properties of the email intake address to update. + """ + input: EmailIntakeAddressUpdateInput! + ): EmailIntakeAddressPayload! + """ + Authenticates a user account via email and authentication token. + """ + emailTokenUserAccountAuth( + """ + The data used for token authentication. + """ + input: TokenUserAccountAuthInput! + ): AuthResolverResponse! + """ + Unsubscribes the user from one type of email. + """ + emailUnsubscribe( + """ + Unsubscription details. + """ + input: EmailUnsubscribeInput! + ): EmailUnsubscribePayload! + """ + Finds or creates a new user account by email and sends an email with token. + """ + emailUserAccountAuthChallenge( + """ + The data used for email authentication. + """ + input: EmailUserAccountAuthChallengeInput! + ): EmailUserAccountAuthChallengeResponse! + """ + Creates a custom emoji. + """ + emojiCreate( + """ + The emoji object to create. + """ + input: EmojiCreateInput! + ): EmojiPayload! + """ + Deletes an emoji. + """ + emojiDelete( + """ + The identifier of the emoji to delete. + """ + id: String! + ): DeletePayload! + """ + Creates a new external link on an initiative, project, team, release, or cycle. + """ + entityExternalLinkCreate( + """ + The entity link object to create. + """ + input: EntityExternalLinkCreateInput! + ): EntityExternalLinkPayload! + """ + Deletes an entity external link. + """ + entityExternalLinkDelete( + """ + The identifier of the entity link to delete. + """ + id: String! + ): DeletePayload! + """ + Updates an existing entity external link's URL, label, or sort order. + """ + entityExternalLinkUpdate( + """ + The identifier of the entity link to update. + """ + id: String! + """ + The entity link object to update. + """ + input: EntityExternalLinkUpdateInput! + ): EntityExternalLinkPayload! + """ + Creates a new favorite for the authenticated user. Exactly one target entity must be specified. If a favorite for the same entity already exists, the existing favorite is returned (upsert behavior). + """ + favoriteCreate( + """ + The favorite object to create. + """ + input: FavoriteCreateInput! + ): FavoritePayload! + """ + Deletes a favorite, removing it from the user's sidebar. This is an idempotent operation -- deleting a non-existent favorite succeeds silently. + """ + favoriteDelete( + """ + The identifier of the favorite reference to delete. + """ + id: String! + ): DeletePayload! + """ + Updates a favorite's position, parent folder, or folder name. + """ + favoriteUpdate( + """ + The identifier of the favorite to update. + """ + id: String! + """ + A partial favorite object to update the favorite with. + """ + input: FavoriteUpdateInput! + ): FavoritePayload! + """ + XHR request payload to upload an images, video and other attachments directly to Linear's cloud storage. + """ + fileUpload( + """ + MIME type of the uploaded file. + """ + contentType: String! + """ + Filename of the uploaded file. + """ + filename: String! + """ + Should the file be made publicly accessible (default: false). + """ + makePublic: Boolean + """ + Optional metadata. + """ + metaData: JSON + """ + File size of the uploaded file. + """ + size: Int! + ): UploadPayload! + """ + [INTERNAL] Permanently delete an uploaded file by asset URL. This should be used as a last resort and will break comments and documents that reference the asset. + """ + fileUploadDangerouslyDelete( + """ + The asset URL of the uploaded file to delete. + """ + assetUrl: String! + ): FileUploadDeletePayload! + """ + Creates a new Git automation rule that maps a Git event to a workflow state transition for a team. + """ + gitAutomationStateCreate( + """ + The automation state to create. + """ + input: GitAutomationStateCreateInput! + ): GitAutomationStatePayload! + """ + Deletes a Git automation rule. + """ + gitAutomationStateDelete( + """ + The identifier of the automation state to archive. + """ + id: String! + ): DeletePayload! + """ + Updates an existing Git automation rule, including its workflow state, target branch, and triggering event. + """ + gitAutomationStateUpdate( + """ + The identifier of the state to update. + """ + id: String! + """ + The state to update. + """ + input: GitAutomationStateUpdateInput! + ): GitAutomationStatePayload! + """ + Creates a new Git target branch definition that scopes automation rules to pull requests targeting a specific branch pattern. + """ + gitAutomationTargetBranchCreate( + """ + The Git target branch automation to create. + """ + input: GitAutomationTargetBranchCreateInput! + ): GitAutomationTargetBranchPayload! + """ + Deletes a Git target branch definition and its associated automation rules. + """ + gitAutomationTargetBranchDelete( + """ + The identifier of the Git target branch automation to archive. + """ + id: String! + ): DeletePayload! + """ + Updates an existing Git target branch definition, including its branch pattern and regex flag. + """ + gitAutomationTargetBranchUpdate( + """ + The identifier of the Git target branch automation to update. + """ + id: String! + """ + The updates. + """ + input: GitAutomationTargetBranchUpdateInput! + ): GitAutomationTargetBranchPayload! + """ + Authenticate user account through Google OAuth. This is the 2nd step of OAuth flow. + """ + googleUserAccountAuth( + """ + The data used for Google authentication. + """ + input: GoogleUserAccountAuthInput! + ): AuthResolverResponse! + """ + Upload an image from an URL to Linear. + """ + imageUploadFromUrl( + """ + URL of the file to be uploaded to Linear. + """ + url: String! + ): ImageUploadFromUrlPayload! + """ + XHR request payload to upload a file for import, directly to Linear's cloud storage. + """ + importFileUpload( + """ + MIME type of the uploaded file. + """ + contentType: String! + """ + Filename of the uploaded file. + """ + filename: String! + """ + Optional metadata. + """ + metaData: JSON + """ + File size of the uploaded file. + """ + size: Int! + ): UploadPayload! + """ + Updates a notification in the authenticated user's inbox using inbox grouping behavior. + """ + inboxNotificationUpdate( + """ + The identifier of the inbox notification to update. + """ + id: String! + """ + The inbox state changes to apply. + """ + input: InboxNotificationUpdateInput! + ): InboxNotificationUpdatePayload! + """ + Adds a label to an initiative. + """ + initiativeAddLabel( + """ + The identifier of the initiative to add the label to. + """ + id: String! + """ + The identifier of the label to add. + """ + labelId: String! + ): InitiativePayload! + """ + Archives an initiative. + """ + initiativeArchive( + """ + The identifier of the initiative to archive. + """ + id: String! + ): InitiativeArchivePayload! + """ + Creates a new initiative. + """ + initiativeCreate( + """ + The properties of the initiative to create. + """ + input: InitiativeCreateInput! + ): InitiativePayload! + """ + Deletes (trashes) an initiative. + """ + initiativeDelete( + """ + The identifier of the initiative to delete. + """ + id: String! + ): DeletePayload! + """ + Creates a new initiative label. + """ + initiativeLabelCreate( + """ + The initiative label to create. + """ + input: InitiativeLabelCreateInput! + ): InitiativeLabelPayload! + """ + Deletes an initiative label. + """ + initiativeLabelDelete( + """ + The identifier of the label to delete. + """ + id: String! + ): DeletePayload! + """ + Restores a previously retired initiative label, making it available for use on new initiatives. + """ + initiativeLabelRestore( + """ + The identifier of the label to restore. + """ + id: String! + ): InitiativeLabelPayload! + """ + Retires an initiative label. Retired labels remain on existing initiatives but cannot be applied to new ones. + """ + initiativeLabelRetire( + """ + The identifier of the label to retire. + """ + id: String! + ): InitiativeLabelPayload! + """ + Updates an initiative label. + """ + initiativeLabelUpdate( + """ + The identifier of the label to update. + """ + id: String! + """ + A partial label object to update. + """ + input: InitiativeLabelUpdateInput! + ): InitiativeLabelPayload! + """ + [Internal] Updates an initiative's lead team, optionally applying it to matching editable sub-initiatives. + """ + initiativeLeadTeamUpdate( + """ + The identifier of the initiative whose lead team should change. + """ + id: String! + """ + The identifier of the new lead team. Pass null to clear the lead team. + """ + leadTeamId: String + """ + Whether to update only the selected initiative or also matching editable sub-initiatives. Matching sub-initiatives currently have the same lead team as the selected initiative had before the change. + """ + mode: InitiativeLeadTeamChangeMode = selectedOnly + ): InitiativeLeadTeamUpdatePayload! + """ + Creates a new parent-child relation between two initiatives. The relation cannot create cycles or exceed maximum nesting depth. + """ + initiativeRelationCreate( + """ + The initiative relation to create. + """ + input: InitiativeRelationCreateInput! + ): InitiativeRelationPayload! + """ + Deletes an initiative relation. + """ + initiativeRelationDelete( + """ + The identifier of the initiative relation to delete. + """ + id: String! + ): DeletePayload! + """ + Updates an initiative relation. + """ + initiativeRelationUpdate( + """ + The identifier of the initiative relation to update. + """ + id: String! + """ + The properties of the initiative relation to update. + """ + input: InitiativeRelationUpdateInput! + ): InitiativeRelationPayload! + """ + Removes a label from an initiative. + """ + initiativeRemoveLabel( + """ + The identifier of the initiative to remove the label from. + """ + id: String! + """ + The identifier of the label to remove. + """ + labelId: String! + ): InitiativePayload! + """ + Associates a project with an initiative. A project can only appear once in an initiative hierarchy. + """ + initiativeToProjectCreate( + """ + The properties of the initiativeToProject to create. + """ + input: InitiativeToProjectCreateInput! + ): InitiativeToProjectPayload! + """ + Removes a project from an initiative. + """ + initiativeToProjectDelete( + """ + The identifier of the initiativeToProject to delete. + """ + id: String! + ): DeletePayload! + """ + Updates an initiative-to-project association, such as its sort order. + """ + initiativeToProjectUpdate( + """ + The identifier of the initiativeToProject to update. + """ + id: String! + """ + The properties of the initiativeToProject to update. + """ + input: InitiativeToProjectUpdateInput! + ): InitiativeToProjectPayload! + """ + Unarchives an initiative. + """ + initiativeUnarchive( + """ + The identifier of the initiative to unarchive. + """ + id: String! + ): InitiativeArchivePayload! + """ + Updates an initiative. + """ + initiativeUpdate( + """ + The identifier of the initiative to update. + """ + id: String! + """ + The properties of the initiative to update. + """ + input: InitiativeUpdateInput! + ): InitiativePayload! + """ + Archives an initiative update. + """ + initiativeUpdateArchive( + """ + The identifier of the initiative update to archive. + """ + id: String! + ): InitiativeUpdateArchivePayload! + """ + Creates an initiative update. + """ + initiativeUpdateCreate( + """ + The initiative update object to create. + """ + input: InitiativeUpdateCreateInput! + ): InitiativeUpdatePayload! + """ + Unarchives an initiative update. + """ + initiativeUpdateUnarchive( + """ + The identifier of the initiative update to unarchive. + """ + id: String! + ): InitiativeUpdateArchivePayload! + """ + Updates an initiative update. + """ + initiativeUpdateUpdate( + """ + The identifier of the initiative update to update. + """ + id: String! + """ + The properties of the initiative update to update. + """ + input: InitiativeUpdateUpdateInput! + ): InitiativeUpdatePayload! + """ + Archives an integration. + """ + integrationArchive( + """ + The identifier of the integration to archive. + """ + id: String! + ): DeletePayload! + """ + Connect a Slack channel to Asks. + """ + integrationAsksConnectChannel( + """ + The Slack OAuth code. + """ + code: String! + """ + The Slack OAuth redirect URI. + """ + redirectUri: String! + ): AsksChannelConnectPayload! + """ + [INTERNAL] Refreshes the customer data attributes from the specified integration service. + """ + integrationCustomerDataAttributesRefresh( + """ + The integration service to refresh customer data attributes from. + """ + input: IntegrationCustomerDataAttributesRefreshInput! + ): IntegrationPayload! + """ + [Internal] Connects Datadog feature flags to the workspace. + """ + integrationDatadogConnect( + """ + The Datadog API key. + """ + apiKey: String! + """ + The Datadog application key with feature flag read access. + """ + applicationKey: String! + """ + The Datadog environment ID. + """ + environmentId: String! + """ + The Datadog site domain. + """ + site: String! + ): IntegrationPayload! + """ + [Internal] Lists Datadog environments available to connect. + """ + integrationDatadogEnvironments( + """ + The Datadog API key. + """ + apiKey: String! + """ + The Datadog application key with feature flag read access. + """ + applicationKey: String! + """ + The Datadog site domain. + """ + site: String! + ): IntegrationDatadogEnvironmentsPayload! + """ + Deletes an integration. + """ + integrationDelete( + """ + The identifier of the integration to delete. + """ + id: String! + """ + Whether to skip deleting the installation on the external service side. + """ + skipInstallationDeletion: Boolean + ): DeletePayload! + """ + Integrates the workspace with Discord. + """ + integrationDiscord( + """ + The Discord OAuth code. + """ + code: String! + """ + The Discord OAuth redirect URI. + """ + redirectUri: String! + ): IntegrationPayload! + """ + Integrates the workspace with Figma. + """ + integrationFigma( + """ + The Figma OAuth code. + """ + code: String! + """ + The Figma OAuth redirect URI. + """ + redirectUri: String! + ): IntegrationPayload! + """ + Integrates the workspace with Front. + """ + integrationFront( + """ + The Front OAuth code. + """ + code: String! + """ + The Front OAuth redirect URI. + """ + redirectUri: String! + ): IntegrationPayload! + """ + Connects the workspace with a GitHub Enterprise Server. + """ + integrationGitHubEnterpriseServerConnect( + """ + The base URL of the GitHub Enterprise Server installation. + """ + githubUrl: String! + """ + The name of GitHub organization. + """ + organizationName: String! + ): GitHubEnterpriseServerPayload! + """ + Connect your GitHub account to Linear. + """ + integrationGitHubPersonal( + """ + The GitHub OAuth code. + """ + code: String! + """ + Whether to connect with code access. + """ + codeAccess: Boolean + """ + The enterprise URL for GitHub Enterprise Cloud connections. Omit for github.com. + """ + enterpriseUrl: String + ): IntegrationPayload! + """ + Generates a webhook for the GitHub commit integration. + """ + integrationGithubCommitCreate: GitHubCommitIntegrationPayload! + """ + Connects the workspace with the GitHub App. + """ + integrationGithubConnect( + """ + The GitHub grant code that's exchanged for OAuth tokens. + """ + code: String! + """ + Whether the integration should have code access + """ + codeAccess: Boolean = false + """ + Set to true to force-replace the existing GitHub App installation (e.g. to ignore repository access conflicts). + """ + confirmReplace: Boolean = false + """ + The GitHub Enterprise Cloud host (e.g., 'linear-development.ghe.com'). When provided, this creates a GEC integration. + """ + githubHost: String + """ + The GitHub data to connect with. + """ + installationId: String! + ): IntegrationPayload! + """ + Connects the workspace with the GitHub Import App. + """ + integrationGithubImportConnect( + """ + The GitHub grant code that's exchanged for OAuth tokens. + """ + code: String! + """ + The GitHub data to connect with. + """ + installationId: String! + ): IntegrationPayload! + """ + Refreshes the data for a GitHub import integration. + """ + integrationGithubImportRefresh( + """ + The id of the integration to update. + """ + id: String! + ): IntegrationPayload! + """ + Removes code access from a GitHub integration, downgrading to the basic GitHub App. + """ + integrationGithubRemoveCodeAccess( + """ + The ID of the integration to remove code access from. + """ + integrationId: String! + ): IntegrationGithubRemoveCodeAccessPayload! + """ + Connects the workspace with a GitLab Access Token. + """ + integrationGitlabConnect( + """ + The GitLab Access Token to connect with. + """ + accessToken: String! + """ + ISO timestamp when the access token expires. Used as a fallback when `validationProjectPath` is set and `personal_access_tokens/self` is unreachable. + """ + expiresAt: String + """ + The URL of the GitLab installation. + """ + gitlabUrl: String! + """ + Whether the access token is limited to a read-only scope. Used as a fallback when `validationProjectPath` is set and `personal_access_tokens/self` is unreachable. + """ + readonly: Boolean + """ + Optional path or numeric ID of a project to use for the setup health check. Set this when the GitLab tenant blocks non-project API endpoints. + """ + validationProjectPath: String + ): GitLabIntegrationCreatePayload! + """ + Rotates the GitLab token, revoking the previous token and saving its replacement. + """ + integrationGitlabRotate(integrationId: String!): IntegrationPayload! + """ + Tests connectivity to a self-hosted GitLab instance and clears auth errors if successful. + """ + integrationGitlabTestConnection( + """ + The ID of the GitLab integration to test. + """ + integrationId: String! + ): GitLabTestConnectionPayload! + """ + Enables or disables automatic self-rotation of the GitLab token. + """ + integrationGitlabUpdateRotationSettings( + enabled: Boolean! + integrationId: String! + ): IntegrationPayload! + """ + Replaces the GitLab access token while preserving the connected host and webhook. + """ + integrationGitlabUpdateToken( + accessToken: String! + """ + The time at which the replacement token expires. Used when GitLab cannot return its expiry. + """ + expiresAt: DateTime + integrationId: String! + """ + Whether the replacement token has read-only access. Required when GitLab cannot return its scopes. + """ + readonly: Boolean + ): IntegrationPayload! + """ + Integrates the workspace with Gong. + """ + integrationGong( + """ + The Gong OAuth code. + """ + code: String! + """ + The Gong OAuth redirect URI. + """ + redirectUri: String! + ): IntegrationPayload! + """ + [Internal] Connects the Google Calendar to the user to this Linear account via OAuth2. + """ + integrationGoogleCalendarPersonalConnect( + """ + [Internal] The Google OAuth code. + """ + code: String! + ): IntegrationPayload! + """ + Integrates the workspace with Google Sheets. + """ + integrationGoogleSheets( + """ + The Google OAuth code. + """ + code: String! + ): IntegrationPayload! + """ + Integrates the workspace with Intercom. + """ + integrationIntercom( + """ + The Intercom OAuth code. + """ + code: String! + """ + The Intercom domain URL to use for the integration. Defaults to app.intercom.com if not provided. + """ + domainUrl: String + """ + The Intercom OAuth redirect URI. + """ + redirectUri: String! + ): IntegrationPayload! + """ + Disconnects the workspace from Intercom. + """ + integrationIntercomDelete: IntegrationPayload! + """ + [DEPRECATED] Updates settings on the Intercom integration. + """ + integrationIntercomSettingsUpdate( + """ + A partial Intercom integration settings object to update the integration settings with. + """ + input: IntercomSettingsInput! + ): IntegrationPayload! + @deprecated( + reason: "This mutation is deprecated, please use `integrationSettingsUpdate` instead" + ) + """ + [INTERNAL] Fetches Jira project statuses for the status mapping settings UI. + """ + integrationJiraFetchProjectStatuses( + """ + Input for fetching Jira project statuses. + """ + input: JiraFetchProjectStatusesInput! + ): JiraFetchProjectStatusesPayload! + @deprecated(reason: "Use the `integrationJiraProjectStatuses` query instead.") + """ + Connect your Jira account to Linear. + """ + integrationJiraPersonal( + """ + The Jira personal access token, when connecting using a PAT. + """ + accessToken: String + """ + The Jira OAuth code, when connecting using OAuth. + """ + code: String + """ + The workspace Jira integration to connect to. Required when the connection would otherwise be ambiguous. + """ + workspaceIntegrationId: String + ): IntegrationPayload! + """ + [INTERNAL] Updates a Jira Integration. + """ + integrationJiraUpdate( + """ + Jira integration update input. + """ + input: JiraUpdateInput! + ): IntegrationPayload! + """ + [INTERNAL] Integrates the workspace with LaunchDarkly. + """ + integrationLaunchDarklyConnect( + """ + The LaunchDarkly OAuth code. + """ + code: String! + """ + The LaunchDarkly environment. + """ + environment: String! + """ + The LaunchDarkly project key. + """ + projectKey: String! + ): IntegrationPayload! + """ + [INTERNAL] Integrates your personal account with LaunchDarkly. + """ + integrationLaunchDarklyPersonalConnect( + """ + The LaunchDarkly OAuth code. + """ + code: String! + ): IntegrationPayload! + """ + Enables Loom integration for the workspace. + """ + integrationLoom: IntegrationPayload! @deprecated(reason: "Not available.") + """ + [INTERNAL] Connects the workspace with an MCP server. + """ + integrationMcpServerConnect( + """ + Optional additional HTTP headers to include with requests to this MCP server. + """ + customHeaders: [McpServerCustomHeaderInput!] + """ + The workspace-approved MCP server definition used to start this connection. + """ + mcpServerDefinitionId: String + """ + The URL of the MCP server to connect with. + """ + serverUrl: String! + """ + Access settings for a new team MCP connector. + """ + settings: McpServerIntegrationSettingsInput + """ + The ID of the team to connect the MCP server to. + """ + teamId: String + """ + The ID of the workflow definition draft to connect the MCP server to. + """ + workflowDefinitionDraftId: String + """ + The ID of the workflow definition to connect the MCP server to. + """ + workflowDefinitionId: String + ): IntegrationPayload! + """ + [INTERNAL] Connects the user's personal account with an MCP server. + """ + integrationMcpServerPersonalConnect( + """ + Optional additional HTTP headers to include with requests to this MCP server. + """ + customHeaders: [McpServerCustomHeaderInput!] + """ + The workspace-approved MCP server definition used to start this connection. + """ + mcpServerDefinitionId: String + """ + The URL of the MCP server to connect with. + """ + serverUrl: String! + ): IntegrationPayload! + """ + Connects the user's personal Microsoft account to Linear. + """ + integrationMicrosoftPersonalConnect( + """ + The Microsoft OAuth code. + """ + code: String! + """ + The Microsoft OAuth redirect URI. + """ + redirectUri: String! + ): IntegrationPayload! + """ + Integrates the workspace with Microsoft Teams. + """ + integrationMicrosoftTeams( + """ + The Microsoft OAuth code. + """ + code: String! + """ + The Microsoft OAuth redirect URI. + """ + redirectUri: String! + ): IntegrationPayload! + """ + [Internal] Connect a project to a Microsoft Teams channel. Find-or-update semantics: creates a microsoftTeamsProjectPost integration row if none exists for the project, or overwrites the existing one's team/channel selection. Requires the connecting user to have linked their personal Microsoft account. + """ + integrationMicrosoftTeamsProjectPost( + """ + Microsoft Teams channel id. + """ + channelId: String! + """ + Display name of the chosen channel. + """ + channelName: String! + """ + Membership type of the channel: standard, private, or shared. + """ + membershipType: String! + """ + Integration's associated project. + """ + projectId: String! + """ + AAD group id of the chosen team. + """ + teamId: String! + """ + Display name of the chosen team. + """ + teamName: String! + ): IntegrationPayload! + """ + [INTERNAL] Integrates the workspace with Opsgenie. + """ + integrationOpsgenieConnect( + """ + The Opsgenie API key. + """ + apiKey: String! + ): IntegrationPayload! + """ + [INTERNAL] Refresh Opsgenie schedule mappings. + """ + integrationOpsgenieRefreshScheduleMappings: IntegrationPayload! + """ + [Internal] Completes the Origin app installation so the workspace receives Origin webhooks. + """ + integrationOriginConnect( + """ + The signed `installation_receipt` Origin returned to the install callback. + """ + installationReceipt: String! + ): IntegrationPayload! + """ + [Internal] Connects an Origin installation that started on Origin, after the workspace admin who installed it confirms. + """ + integrationOriginConnectInstallation( + """ + The Origin installation id from the install redirect. + """ + installationId: String! + ): IntegrationPayload! + """ + [INTERNAL] Integrates the workspace with PagerDuty. + """ + integrationPagerDutyConnect( + """ + The PagerDuty OAuth code. + """ + code: String! + """ + The PagerDuty OAuth redirect URI. + """ + redirectUri: String! + ): IntegrationPayload! + """ + [INTERNAL] Refresh PagerDuty schedule mappings. + """ + integrationPagerDutyRefreshScheduleMappings: IntegrationPayload! + """ + Requests a currently unavailable integration. + """ + integrationRequest( + """ + Integration request details. + """ + input: IntegrationRequestInput! + ): IntegrationRequestPayload! + """ + Integrates the workspace with Salesforce. + """ + integrationSalesforce( + """ + The Salesforce OAuth code. + """ + code: String! + """ + The PKCE code verifier matching the code_challenge sent on authorization. + """ + codeVerifier: String! + """ + The Salesforce OAuth redirect URI. + """ + redirectUri: String! + """ + The Salesforce installation subdomain. + """ + subdomain: String! + ): IntegrationPayload! + """ + [INTERNAL] Refreshes the Salesforce integration metadata. + """ + integrationSalesforceMetadataRefresh( + """ + The ID of the integration to refresh metadata for. + """ + id: String! + ): IntegrationPayload! + """ + Integrates the workspace with Sentry. + """ + integrationSentryConnect( + """ + The Sentry grant code that's exchanged for OAuth tokens. + """ + code: String! + """ + The Sentry installationId to connect with. + """ + installationId: String! + """ + The slug of the Sentry organization being connected. + """ + organizationSlug: String! + ): IntegrationPayload! + """ + [INTERNAL] Updates the integration settings. + """ + integrationSettingsUpdate( + """ + The identifier of the integration to update. + """ + id: String! + """ + An integration settings object. + """ + input: IntegrationSettingsInput! + ): IntegrationPayload! @deprecated(reason: "Use integrationUpdate instead.") + """ + Integrates the workspace with Slack. + """ + integrationSlack( + """ + The Slack OAuth code. + """ + code: String! + """ + The Slack OAuth redirect URI. + """ + redirectUri: String! + """ + The Slack OAuth scopes the client requested. Used to warn when Slack grants fewer scopes than requested. + """ + requestedScopes: [String!] + """ + [DEPRECATED] Whether or not v2 of Slack OAuth should be used. No longer used. + """ + shouldUseV2Auth: Boolean + ): IntegrationPayload! + """ + Integrates the workspace with the Slack Asks app. + """ + integrationSlackAsks( + """ + The Slack OAuth code. + """ + code: String! + """ + The Slack OAuth redirect URI. + """ + redirectUri: String! + """ + The Slack OAuth scopes the client requested. Used to warn when Slack grants fewer scopes than requested. + """ + requestedScopes: [String!] + ): IntegrationPayload! + """ + Slack integration for custom view notifications. + """ + integrationSlackCustomViewNotifications( + """ + The Slack OAuth code. + """ + code: String! + """ + Integration's associated custom view. + """ + customViewId: String! + """ + The Slack OAuth redirect URI. + """ + redirectUri: String! + ): SlackChannelConnectPayload! + """ + Integrates a Slack Asks channel with a Customer. + """ + integrationSlackCustomerChannelLink( + """ + The Slack OAuth code. + """ + code: String! + """ + The customer to link the Slack channel with + """ + customerId: String! + """ + The Slack OAuth redirect URI. + """ + redirectUri: String! + ): SuccessPayload! + """ + Imports custom emojis from your Slack workspace. + """ + integrationSlackImportEmojis( + """ + The Slack OAuth code. + """ + code: String! + """ + The Slack OAuth redirect URI. + """ + redirectUri: String! + ): IntegrationPayload! + """ + [Internal] Slack integration for initiative notifications. + """ + integrationSlackInitiativePost( + """ + The Slack OAuth code. + """ + code: String! + """ + Integration's associated initiative. + """ + initiativeId: String! + """ + The Slack OAuth redirect URI. + """ + redirectUri: String! + ): SlackChannelConnectPayload! + """ + Updates the Slack team's name in Linear for an existing Slack or Asks integration. + """ + integrationSlackOrAsksUpdateSlackTeamName( + """ + The integration ID. + """ + integrationId: String! + ): IntegrationSlackWorkspaceNamePayload! + """ + [Internal] Slack integration for workspace-level initiative update notifications. + """ + integrationSlackOrgInitiativeUpdatesPost( + """ + The Slack OAuth code. + """ + code: String! + """ + The Slack OAuth redirect URI. + """ + redirectUri: String! + ): SlackChannelConnectPayload! + """ + Slack integration for workspace-level project update notifications. + """ + integrationSlackOrgProjectUpdatesPost( + """ + The Slack OAuth code. + """ + code: String! + """ + The Slack OAuth redirect URI. + """ + redirectUri: String! + ): SlackChannelConnectPayload! + """ + Integrates your personal notifications with Slack. + """ + integrationSlackPersonal( + """ + The Slack OAuth code. + """ + code: String! + """ + The Slack OAuth redirect URI. + """ + redirectUri: String! + ): IntegrationPayload! + """ + Slack integration for team notifications. + """ + integrationSlackPost( + """ + The Slack OAuth code. + """ + code: String! + """ + The Slack OAuth redirect URI. + """ + redirectUri: String! + """ + [DEPRECATED] Whether or not v2 of Slack OAuth should be used. No longer used. + """ + shouldUseV2Auth: Boolean + """ + Integration's associated team. + """ + teamId: String! + ): SlackChannelConnectPayload! + """ + Slack integration for project notifications. + """ + integrationSlackProjectPost( + """ + The Slack OAuth code. + """ + code: String! + """ + Integration's associated project. + """ + projectId: String! + """ + The Slack OAuth redirect URI. + """ + redirectUri: String! + """ + The service to enable once connected, either 'notifications' or 'updates'. + """ + service: String! + ): SlackChannelConnectPayload! + """ + [Internal] Enables Linear Agent Slack workflow access for a Slack or Slack Asks integration. + """ + integrationSlackWorkflowAccessUpdate( + """ + Whether to enable workflow access. + """ + enabled: Boolean! + """ + The ID of the integration to toggle workflow access for. + """ + integrationId: String! + ): IntegrationPayload! + """ + Creates a new connection between a template and an integration, optionally scoped to a specific external resource such as a Slack channel. + """ + integrationTemplateCreate( + """ + The properties of the integrationTemplate to create. + """ + input: IntegrationTemplateCreateInput! + ): IntegrationTemplatePayload! + """ + Deletes an integration template connection, removing the link between a template and an integration. + """ + integrationTemplateDelete( + """ + The identifier of the integrationTemplate to delete. + """ + id: String! + ): DeletePayload! + """ + [INTERNAL] Updates the integration. + """ + integrationUpdate( + """ + The identifier of the integration to update. + """ + id: String! + """ + A partial integration object to update the integration with. + """ + input: IntegrationUpdateInput! + ): IntegrationPayload! + """ + Integrates the workspace with Zendesk. + """ + integrationZendesk( + """ + [INTERNAL] Bearer token that authenticates API requests instead of a Zendesk OAuth token. Requires `customApiUrl`; no OAuth exchange is performed. + """ + accessToken: String + """ + The Zendesk user ID to use as the author of internal notes instead of creating a bot user. Omit to keep the configured user on reconnect, or pass null to create a new bot user. + """ + botUserId: String + """ + The role to assign to the Linear bot user in Zendesk. + """ + botUserRole: String + """ + The Zendesk OAuth code. Required unless connecting with `accessToken`. + """ + code: String + """ + [INTERNAL] Custom base URL for Zendesk API requests, such as a proxy in front of Zendesk. OAuth requests always use the standard subdomain URL. + """ + customApiUrl: String + """ + The Zendesk OAuth redirect URI. Required when connecting with `code`. + """ + redirectUri: String + """ + The Zendesk OAuth scopes. Required when connecting with `code`. + """ + scope: String + """ + The Zendesk installation subdomain. + """ + subdomain: String! + ): IntegrationPayload! + """ + Creates new Slack notification settings for a team, project, initiative, or custom view. + """ + integrationsSettingsCreate( + """ + The settings to create. + """ + input: IntegrationsSettingsCreateInput! + ): IntegrationsSettingsPayload! + """ + Updates Slack notification settings for a team, project, initiative, or custom view. + """ + integrationsSettingsUpdate( + """ + The identifier of the settings to update. + """ + id: String! + """ + A settings object to update the settings with. + """ + input: IntegrationsSettingsUpdateInput! + ): IntegrationsSettingsPayload! + """ + Adds a label to an issue. + """ + issueAddLabel( + """ + The identifier of the issue to add the label to. + """ + id: String! + """ + The identifier of the label to add. + """ + labelId: String! + ): IssuePayload! + """ + Archives an issue. + """ + issueArchive( + """ + The identifier of the issue to archive. + """ + id: String! + """ + Whether to trash the issue. + """ + trash: Boolean + ): IssueArchivePayload! + """ + Creates a list of issues atomically. + """ + issueBatchCreate( + """ + A list of issue objects to create. + """ + input: IssueBatchCreateInput! + ): IssueBatchPayload! + """ + Updates multiple issues at once. + """ + issueBatchUpdate( + """ + The id's of the issues to update. Can't be more than 50 at a time. + """ + ids: [UUID!]! + """ + A partial issue object to update the issues with. + """ + input: IssueUpdateInput! + ): IssueBatchPayload! + """ + Creates a new issue. + """ + issueCreate( + """ + The issue object to create. + """ + input: IssueCreateInput! + ): IssuePayload! + """ + Deletes (trashes) an issue. + """ + issueDelete( + """ + The identifier of the issue to delete. + """ + id: String! + """ + Whether to permanently delete the issue and skip the grace period of 30 days. Available only to admins! + """ + permanentlyDelete: Boolean + ): IssueArchivePayload! + """ + [INTERNAL] Updates an issue description from the Front app to handle Front attachments correctly. + """ + issueDescriptionUpdateFromFront( + """ + Description to update the issue with. + """ + description: String! + """ + The identifier of the issue to update. + """ + id: String! + ): IssuePayload! + """ + Disables external sync on an issue. + """ + issueExternalSyncDisable( + """ + The ID of the sync attachment to disable. + """ + attachmentId: String! + ): IssuePayload! + """ + Kicks off an Asana import job. + """ + issueImportCreateAsana( + """ + Names of Asana projects in the team. When set, only tasks from these projects are imported. When empty, all projects are imported. + """ + asanaProjectNames: [String!] + """ + Asana team name to choose which issues we should import. + """ + asanaTeamName: String! + """ + Asana token to fetch information from the Asana API. + """ + asanaToken: String! + """ + ID of issue import. If not provided it will be generated. + """ + id: String + """ + Whether or not we should collect the data for closed issues. + """ + includeClosedIssues: Boolean + """ + Whether to instantly process the import with the default configuration mapping. + """ + instantProcess: Boolean + """ + ID of the team into which to import data. + """ + teamId: String + """ + Name of new team. When teamId is not set. + """ + teamName: String + ): IssueImportPayload! + """ + Kicks off a Jira import job from a CSV. + """ + issueImportCreateCSVJira( + """ + URL for the CSV. + """ + csvUrl: String! + """ + Jira user account email. + """ + jiraEmail: String + """ + Jira installation or cloud hostname. + """ + jiraHostname: String + """ + Jira personal access token to access Jira REST API. + """ + jiraToken: String + """ + ID of the team into which to import data. Empty to create new team. + """ + teamId: String + """ + Name of new team. When teamId is not set. + """ + teamName: String + ): IssueImportPayload! + """ + Kicks off a Shortcut (formerly Clubhouse) import job. + """ + issueImportCreateClubhouse( + """ + Shortcut (formerly Clubhouse) group name to choose which issues we should import. + """ + clubhouseGroupName: String! + """ + Shortcut (formerly Clubhouse) token to fetch information from the Clubhouse API. + """ + clubhouseToken: String! + """ + ID of issue import. If not provided it will be generated. + """ + id: String + """ + Whether or not we should collect the data for closed issues. + """ + includeClosedIssues: Boolean + """ + Whether to instantly process the import with the default configuration mapping. + """ + instantProcess: Boolean + """ + ID of the team into which to import data. + """ + teamId: String + """ + Name of new team. When teamId is not set. + """ + teamName: String + ): IssueImportPayload! + """ + Kicks off a GitHub import job. + """ + issueImportCreateGithub( + """ + Labels to use to filter the import data. Only issues matching any of these filters will be imported. + """ + githubLabels: [String!] + """ + IDs of the Github repositories from which we will import data. + """ + githubRepoIds: [Int!] + """ + Whether or not we should collect the data for closed issues. + """ + includeClosedIssues: Boolean + """ + Whether to instantly process the import with the default configuration mapping. + """ + instantProcess: Boolean + """ + ID of the team into which to import data. + """ + teamId: String + """ + Name of new team. When teamId is not set. + """ + teamName: String + ): IssueImportPayload! + """ + Kicks off a Jira import job. + """ + issueImportCreateJira( + """ + ID of issue import. If not provided it will be generated. + """ + id: String + """ + Whether or not we should collect the data for closed issues. + """ + includeClosedIssues: Boolean + """ + Whether to instantly process the import with the default configuration mapping. + """ + instantProcess: Boolean + """ + Jira user account email. + """ + jiraEmail: String! + """ + Jira installation or cloud hostname. + """ + jiraHostname: String! + """ + Jira project key from which we will import data. + """ + jiraProject: String! + """ + Jira personal access token to access Jira REST API. + """ + jiraToken: String! + """ + A custom JQL query to filter issues being imported + """ + jql: String + """ + ID of the team into which to import data. Empty to create new team. + """ + teamId: String + """ + Name of new team. When teamId is not set. + """ + teamName: String + ): IssueImportPayload! + """ + [INTERNAL] Kicks off a Linear to Linear import job. + """ + issueImportCreateLinearV2( + """ + ID of issue import. If not provided it will be generated. + """ + id: String + """ + The source workspace to import from. + """ + linearSourceOrganizationId: String! + ): IssueImportPayload! + """ + Deletes an import job. + """ + issueImportDelete( + """ + ID of the issue import to delete. + """ + issueImportId: String! + ): IssueImportDeletePayload! + """ + Kicks off import processing. + """ + issueImportProcess( + """ + ID of the issue import which we're going to process. + """ + issueImportId: String! + """ + The mapping configuration to use for processing the import. + """ + mapping: JSONObject! + ): IssueImportPayload! + """ + Updates the mapping for the issue import. + """ + issueImportUpdate( + """ + The identifier of the issue import. + """ + id: String! + """ + The properties of the issue import to update. + """ + input: IssueImportUpdateInput! + ): IssueImportPayload! + """ + Creates a new label. + """ + issueLabelCreate( + """ + The issue label to create. + """ + input: IssueLabelCreateInput! + """ + Whether to replace all team-specific labels with the same name with this newly created workspace label (default: false). + """ + replaceTeamLabels: Boolean + ): IssueLabelPayload! + """ + Deletes an issue label. + """ + issueLabelDelete( + """ + The identifier of the label to delete. + """ + id: String! + ): DeletePayload! + """ + Restores a previously retired label, making it available for use again. + """ + issueLabelRestore( + """ + The identifier of the label to restore. + """ + id: String! + ): IssueLabelPayload! + """ + Retires a label. Retired labels are still visible but cannot be applied to new issues. Existing issues with the label are not affected. + """ + issueLabelRetire( + """ + The identifier of the label to retire. + """ + id: String! + ): IssueLabelPayload! + """ + Updates a label. + """ + issueLabelUpdate( + """ + The identifier of the label to update. + """ + id: String! + """ + A partial label object to update. + """ + input: IssueLabelUpdateInput! + """ + Whether to replace all team-specific labels with the same name with this updated workspace label (default: false). + """ + replaceTeamLabels: Boolean + ): IssueLabelPayload! + """ + Creates a new issue relation. + """ + issueRelationCreate( + """ + The issue relation to create. + """ + input: IssueRelationCreateInput! + """ + Used by client undo operations. Should not be set directly. + """ + overrideCreatedAt: DateTime + ): IssueRelationPayload! + """ + Deletes an issue relation. + """ + issueRelationDelete( + """ + The identifier of the issue relation to delete. + """ + id: String! + ): DeletePayload! + """ + Updates an issue relation. + """ + issueRelationUpdate( + """ + The identifier of the issue relation to update. + """ + id: String! + """ + The properties of the issue relation to update. + """ + input: IssueRelationUpdateInput! + ): IssueRelationPayload! + """ + Adds an issue reminder. Will cause a notification to be sent when the issue reminder time is reached. + """ + issueReminder( + """ + The identifier of the issue to add a reminder for. + """ + id: String! + """ + The time when a reminder notification will be sent. + """ + reminderAt: DateTime! + ): IssuePayload! + """ + Removes a label from an issue. + """ + issueRemoveLabel( + """ + The identifier of the issue to remove the label from. + """ + id: String! + """ + The identifier of the label to remove. + """ + labelId: String! + ): IssuePayload! + """ + [Internal] Requests a coding-agent suitability prediction for an issue without a current one, such as an issue created before predictions existed. + """ + issueRequestSolubilityPrediction( + """ + The identifier of the issue to predict suitability for. + """ + id: String! + ): SuccessPayload! + """ + Shares an issue with a user who would not otherwise be able to access it. The viewer must have native access to the issue's full sub-issue tree and permission to share issues in the issue's team. Issues that inherit sharing from a parent issue cannot be shared directly. + """ + issueShare( + """ + The identifier of the issue to share. + """ + id: String! + """ + The identifier of the user to share the issue with. + """ + userId: String! + ): IssuePayload! + """ + Subscribes a user to an issue. + """ + issueSubscribe( + """ + The identifier of the issue to subscribe to. + """ + id: String! + """ + The email of the user to subscribe, default is the current user. + """ + userEmail: String + """ + The identifier of the user to subscribe, default is the current user. + """ + userId: String + ): IssuePayload! + """ + Creates a new association between an issue and a release, linking the issue to the release for tracking purposes. + """ + issueToReleaseCreate( + """ + The properties of the issueToRelease to create. + """ + input: IssueToReleaseCreateInput! + ): IssueToReleasePayload! + """ + Deletes an issue-to-release association by its identifier, removing the issue from the release. + """ + issueToReleaseDelete( + """ + The identifier of the issue-to-release association to delete. + """ + id: String! + ): DeletePayload! + """ + Deletes an issue-to-release association by looking up the issue and release identifiers, removing the issue from the release. + """ + issueToReleaseDeleteByIssueAndRelease( + """ + The identifier of the issue. Can be a UUID or issue identifier (e.g., 'LIN-123'). + """ + issueId: String! + """ + The identifier of the release. + """ + releaseId: String! + ): DeletePayload! + """ + Unarchives an issue. + """ + issueUnarchive( + """ + The identifier of the issue to unarchive. + """ + id: String! + ): IssueArchivePayload! + """ + Stops sharing an issue with a user. The viewer must have native access to the issue's full sub-issue tree and permission to share issues in the issue's team. Issues that inherit sharing from a parent issue cannot be unshared directly. + """ + issueUnshare( + """ + The identifier of the issue to stop sharing. + """ + id: String! + """ + The identifier of the user to remove from the issue share. + """ + userId: String! + ): IssuePayload! + """ + Unsubscribes a user from an issue. + """ + issueUnsubscribe( + """ + The identifier of the issue to unsubscribe from. + """ + id: String! + """ + The email of the user to unsubscribe, default is the current user. + """ + userEmail: String + """ + The identifier of the user to unsubscribe, default is the current user. + """ + userId: String + ): IssuePayload! + """ + Updates an issue. + """ + issueUpdate( + """ + The identifier of the issue to update. + """ + id: String! + """ + A partial issue object to update the issue with. + """ + input: IssueUpdateInput! + ): IssuePayload! + """ + [INTERNAL] Connects the workspace with a Jira Personal Access Token. + """ + jiraIntegrationConnect( + """ + Jira integration settings. + """ + input: JiraConfigurationInput! + ): IntegrationPayload! + """ + Join a workspace from onboarding. + """ + joinOrganizationFromOnboarding( + """ + Details of the workspace to join. + """ + input: JoinOrganizationInput! + ): CreateOrJoinOrganizationResponse! + """ + Leave a workspace. + """ + leaveOrganization( + """ + ID of the workspace to leave. + """ + organizationId: String! + ): CreateOrJoinOrganizationResponse! + """ + Logout the client. + """ + logout( + """ + The reason for logging out. + """ + reason: String + ): LogoutResponse! + """ + Logout all of user's sessions including the active one. + """ + logoutAllSessions( + """ + The reason for logging out. + """ + reason: String + ): LogoutResponse! + """ + Logout all of user's sessions excluding the current one. + """ + logoutOtherSessions( + """ + The reason for logging out. + """ + reason: String + ): LogoutResponse! + """ + Logout an individual session with its ID. + """ + logoutSession( + """ + ID of the session to logout. + """ + sessionId: String! + ): LogoutResponse! + """ + Archives a notification. + """ + notificationArchive( + """ + The id of the notification to archive. + """ + id: String! + ): NotificationArchivePayload! + """ + Archives a notification and all related notifications. + """ + notificationArchiveAll( + """ + The type and id of the entity to archive notifications for. + """ + input: NotificationEntityInput! + ): NotificationBatchActionPayload! + """ + Subscribes to or unsubscribes from a specific notification category for a given notification channel. For example, subscribe to 'issueAssignment' notifications via the 'email' channel. + """ + notificationCategoryChannelSubscriptionUpdate( + """ + The notification category to subscribe to or unsubscribe from + """ + category: NotificationCategory! + """ + The notification channel in which to subscribe to or unsubscribe from the category + """ + channel: NotificationChannel! + """ + True if the user wants to subscribe, false if the user wants to unsubscribe + """ + subscribe: Boolean! + ): UserSettingsPayload! + """ + Marks notification and all related notifications as read. + """ + notificationMarkReadAll( + """ + The type and id of the entity to archive notifications for. + """ + input: NotificationEntityInput! + """ + The time when notification was marked as read. + """ + readAt: DateTime! + ): NotificationBatchActionPayload! + """ + Marks notification and all related notifications as unread. + """ + notificationMarkUnreadAll( + """ + The type and id of the entity to archive notifications for. + """ + input: NotificationEntityInput! + ): NotificationBatchActionPayload! + """ + Snoozes a notification and all related notifications. + """ + notificationSnoozeAll( + """ + The type and id of the entity to archive notifications for. + """ + input: NotificationEntityInput! + """ + The time until a notification will be snoozed. After that it will appear in the inbox again. + """ + snoozedUntilAt: DateTime! + ): NotificationBatchActionPayload! + """ + Creates a new notification subscription for a specific entity. The subscription determines which notification types the authenticated user will receive for the target entity. Exactly one target entity (customer, custom view, cycle, initiative, label, project, team, or user) must be specified. + """ + notificationSubscriptionCreate( + """ + The subscription object to create. + """ + input: NotificationSubscriptionCreateInput! + ): NotificationSubscriptionPayload! + """ + Deletes a notification subscription reference. + """ + notificationSubscriptionDelete( + """ + The identifier of the notification subscription reference to delete. + """ + id: String! + ): DeletePayload! + @deprecated(reason: "Update `notificationSubscription.active` to `false` instead.") + """ + Updates a notification subscription. + """ + notificationSubscriptionUpdate( + """ + The identifier of the notification subscription to update. + """ + id: String! + """ + A partial notification subscription object to update the notification subscription with. + """ + input: NotificationSubscriptionUpdateInput! + ): NotificationSubscriptionPayload! + """ + Unarchives a notification. + """ + notificationUnarchive( + """ + The id of the notification to unarchive. + """ + id: String! + ): NotificationArchivePayload! + """ + Unsnoozes a notification and all related notifications. + """ + notificationUnsnoozeAll( + """ + The type and id of the entity to archive notifications for. + """ + input: NotificationEntityInput! + """ + The time when the notification was unsnoozed. + """ + unsnoozedAt: DateTime! + ): NotificationBatchActionPayload! + """ + Updates a notification. + """ + notificationUpdate( + """ + The identifier of the notification to update. + """ + id: String! + """ + A partial notification object to update the notification with. + """ + input: NotificationUpdateInput! + ): NotificationPayload! + """ + [ALPHA] Archives an OAuth application created by the calling OAuth application. + """ + oauthApplicationArchive( + """ + The identifier of the OAuth application to archive. + """ + id: String! + ): OAuthApplicationArchivePayload! + """ + [ALPHA] Creates an OAuth application owned by the calling OAuth application. + """ + oauthApplicationCreate( + """ + The OAuth application object to create. + """ + input: OAuthApplicationCreateInput! + ): OAuthApplicationCreatePayload! + """ + [ALPHA] Rotates the client secret for an OAuth application created by the calling OAuth application. + """ + oauthApplicationRotateSecret( + """ + The identifier of the OAuth application for which to rotate the secret. + """ + id: String! + ): OAuthApplicationRotateSecretPayload! + """ + [ALPHA] Rotates the webhook signing secret for an OAuth application created by the calling OAuth application. + """ + oauthApplicationRotateWebhookSecret( + """ + The identifier of the OAuth application for which to rotate the webhook secret. + """ + id: String! + ): OAuthApplicationRotateWebhookSecretPayload! + """ + [ALPHA] Updates an OAuth application created by the calling OAuth application. + """ + oauthApplicationUpdate( + """ + The identifier of the OAuth application to update. + """ + id: String! + """ + A partial OAuth application object to update. + """ + input: OAuthApplicationUpdateInput! + ): OAuthApplicationPayload! + """ + Cancels a previously requested workspace deletion, if the workspace has not yet been fully deleted. + """ + organizationCancelDelete: OrganizationCancelDeletePayload! + """ + Permanently deletes the workspace and all its data. Requires a valid deletion code obtained from organizationDeleteChallenge. This action is irreversible. + """ + organizationDelete( + """ + Information required to delete the workspace. + """ + input: DeleteOrganizationInput! + ): OrganizationDeletePayload! + """ + Requests a deletion confirmation code for the workspace. The code is sent to the requesting user's email and must be used with the organizationDelete mutation to confirm deletion. + """ + organizationDeleteChallenge: OrganizationDeletePayload! + """ + [INTERNAL] Verifies a domain claim. + """ + organizationDomainClaim( + """ + The ID of the organization domain to claim. + """ + id: String! + ): OrganizationDomainSimplePayload! + """ + [INTERNAL] Adds a domain to be allowed for a workspace. + """ + organizationDomainCreate( + """ + The organization domain entry to create. + """ + input: OrganizationDomainCreateInput! + """ + Whether to trigger an email verification flow during domain creation. + """ + triggerEmailVerification: Boolean + ): OrganizationDomainPayload! + """ + Deletes a domain. + """ + organizationDomainDelete( + """ + The identifier of the domain to delete. + """ + id: String! + ): DeletePayload! + """ + [INTERNAL] Updates a workspace domain's settings. + """ + organizationDomainUpdate( + """ + The identifier of the domain to update. + """ + id: String! + """ + The organization domain entry to update. + """ + input: OrganizationDomainUpdateInput! + ): OrganizationDomainPayload! + """ + [INTERNAL] Verifies a domain to be added to a workspace. + """ + organizationDomainVerify( + """ + The organization domain to verify. + """ + input: OrganizationDomainVerificationInput! + ): OrganizationDomainPayload! + """ + Creates a new workspace invite and sends an invitation email to the specified address. The invite includes a role assignment and optional team memberships. + """ + organizationInviteCreate( + """ + The organization invite object to create. + """ + input: OrganizationInviteCreateInput! + ): OrganizationInvitePayload! + """ + Deletes (archives) a workspace invite, preventing it from being accepted. + """ + organizationInviteDelete( + """ + The identifier of the organization invite to delete. + """ + id: String! + ): DeletePayload! + """ + Updates an existing workspace invite, such as changing the teams the invitee will be added to. + """ + organizationInviteUpdate( + """ + The identifier of the organization invite to update. + """ + id: String! + """ + The updates to make to the organization invite object. + """ + input: OrganizationInviteUpdateInput! + ): OrganizationInvitePayload! + """ + [DEPRECATED] Starts a trial for the workspace. + """ + organizationStartTrial: OrganizationStartTrialPayload! + @deprecated(reason: "Use organizationStartTrialForPlan") + """ + Starts a trial for the workspace on the specified plan type. The workspace must not already be on a paid plan or in an active trial. + """ + organizationStartTrialForPlan( + """ + Plan details for trial + """ + input: OrganizationStartTrialInput! + ): OrganizationStartTrialPayload! + """ + Updates the user's workspace settings. Different settings require different permission levels; most require the workspaceSettings admin permission. + """ + organizationUpdate( + """ + A partial workspace object to update the workspace with. + """ + input: OrganizationUpdateInput! + ): OrganizationPayload! + """ + [Internal] Removes Linear's app from an Origin installation that started on Origin and that no workspace connected. + """ + originInstallationCancel( + """ + The Origin installation id from the install redirect. + """ + installationId: String! + ): OriginInstallationCancelPayload! + """ + [INTERNAL] Submits a Startup Program partner application from the website, creating a triage issue for the startup team. + """ + partnerApplicationCreate( + """ + The partner application to submit. + """ + input: PartnerApplicationCreateInput! + ): ContactPayload! + """ + [Internal] Redeems a partner-offer token for one of the viewer's existing workspaces, recording a pending redemption that is applied when the workspace subscribes. Requires an admin or owner role in the workspace. + """ + partnerOfferRedeem( + """ + The identifier of the workspace to redeem the offer for. + """ + organizationId: String! + """ + The signed partner-offer token to redeem. + """ + token: String! + ): PartnerOfferRedeemPayload! + """ + [INTERNAL] Finish passkey login process. + """ + passkeyLoginFinish( + """ + Random ID to start passkey login with. + """ + authId: String! + """ + The WebAuthn authenticator response from the passkey challenge. + """ + response: JSONObject! + ): AuthResolverResponse! + """ + [INTERNAL] Starts passkey login process. + """ + passkeyLoginStart( + """ + Random ID to start passkey login with. + """ + authId: String! + ): PasskeyLoginStartResponse! + """ + Adds a label to a project. + """ + projectAddLabel( + """ + The identifier of the project to add the label to. + """ + id: String! + """ + The identifier of the label to add. + """ + labelId: String! + ): ProjectPayload! + """ + Archives a project. + """ + projectArchive( + """ + The identifier of the project to archive. Also the identifier from the URL is accepted. + """ + id: String! + """ + Whether to trash the project. + """ + trash: Boolean + ): ProjectArchivePayload! @deprecated(reason: "Deprecated in favor of projectDelete.") + """ + Creates a new project. + """ + projectCreate( + """ + [Internal] The identifier of the project draft conversation to attach to this project. + """ + aiConversationId: String + """ + The project properties to set on the new project. + """ + input: ProjectCreateInput! + """ + [Internal] The identifier of the project draft that produced this project. + """ + projectDraftId: String + """ + The full name for the Slack channel to create (including prefix). When provided, a Slack channel will be created and connected to the project. + """ + slackChannelName: String + ): ProjectPayload! + """ + [Internal] Creates a Slack channel for an existing project. + """ + projectCreateSlackChannel( + """ + The identifier of the project. + """ + id: String! + """ + The identifier of the Slack integration to use. When not provided, uses the organization's configured integration. + """ + integrationId: String + """ + The full name for the Slack channel to create (including prefix). When provided, a Slack channel will be created and connected to the project. + """ + slackChannelName: String! + ): ProjectPayload! + """ + Deletes (trashes) a project. The project can be restored later with projectUnarchive. + """ + projectDelete( + """ + The identifier of the project to delete. + """ + id: String! + ): ProjectArchivePayload! + """ + [Internal] Dismisses the Slack channel creation failure notice for a project. + """ + projectDismissSlackChannelCreationFailure( + """ + The identifier of the project. + """ + id: String! + ): ProjectPayload! + """ + Disables external sync on a project. + """ + projectExternalSyncDisable( + """ + The ID of the project to disable external sync for. + """ + projectId: String! + """ + The source of the external sync to disable. + """ + syncSource: ExternalSyncService! + ): ProjectPayload! + """ + Creates a new project label. + """ + projectLabelCreate( + """ + The project label to create. + """ + input: ProjectLabelCreateInput! + """ + Whether to replace all team-specific labels with the same name with this newly created workspace label (default: false). + """ + replaceTeamLabels: Boolean + ): ProjectLabelPayload! + """ + Deletes a project label. + """ + projectLabelDelete( + """ + The identifier of the label to delete. + """ + id: String! + ): DeletePayload! + """ + Restores a previously retired project label, making it available for use on new projects. + """ + projectLabelRestore( + """ + The identifier of the label to restore. + """ + id: String! + ): ProjectLabelPayload! + """ + Retires a project label. Retired labels remain on existing projects but cannot be applied to new ones. + """ + projectLabelRetire( + """ + The identifier of the label to retire. + """ + id: String! + ): ProjectLabelPayload! + """ + Updates a project label. + """ + projectLabelUpdate( + """ + The identifier of the label to update. + """ + id: String! + """ + A partial label object to update. + """ + input: ProjectLabelUpdateInput! + """ + Whether to replace all team-specific labels with the same name with this updated workspace label (default: false). + """ + replaceTeamLabels: Boolean + ): ProjectLabelPayload! + """ + Creates a new project milestone. + """ + projectMilestoneCreate( + """ + The project milestone to create. + """ + input: ProjectMilestoneCreateInput! + ): ProjectMilestonePayload! + """ + Deletes a project milestone. + """ + projectMilestoneDelete( + """ + The identifier of the project milestone to delete. + """ + id: String! + ): DeletePayload! + """ + [Internal] Moves a project milestone to another project, can be called to undo a prior move. + """ + projectMilestoneMove( + """ + The identifier of the project milestone to move. + """ + id: String! + """ + The project to move the milestone to, as well as any additional options need to make a successful move, or undo a previous move. + """ + input: ProjectMilestoneMoveInput! + ): ProjectMilestoneMovePayload! + """ + Updates a project milestone. + """ + projectMilestoneUpdate( + """ + The identifier of the project milestone to update. Also the identifier from the URL is accepted. + """ + id: String! + """ + A partial object to update the project milestone with. + """ + input: ProjectMilestoneUpdateInput! + ): ProjectMilestonePayload! + """ + [INTERNAL] Reassigns all projects from one project status to another. Used when archiving or deleting a project status. + """ + projectReassignStatus( + """ + The identifier of the new project status to update the projects to. + """ + newProjectStatusId: String! + """ + The identifier of the project status with which projects will be updated. + """ + originalProjectStatusId: String! + ): SuccessPayload! + """ + Creates a new project relation. + """ + projectRelationCreate( + """ + The project relation to create. + """ + input: ProjectRelationCreateInput! + ): ProjectRelationPayload! + """ + Deletes a project relation. + """ + projectRelationDelete( + """ + The identifier of the project relation to delete. + """ + id: String! + ): DeletePayload! + """ + Updates a project relation. + """ + projectRelationUpdate( + """ + The identifier of the project relation to update. + """ + id: String! + """ + The properties of the project relation to update. + """ + input: ProjectRelationUpdateInput! + ): ProjectRelationPayload! + """ + Removes a label from a project. + """ + projectRemoveLabel( + """ + The identifier of the project to remove the label from. + """ + id: String! + """ + The identifier of the label to remove. + """ + labelId: String! + ): ProjectPayload! + """ + Archives a project status. The status must not have any active projects assigned to it and must not be the last status of its type. + """ + projectStatusArchive( + """ + The identifier of the project status to archive. + """ + id: String! + ): ProjectStatusArchivePayload! + """ + Creates a new project status. + """ + projectStatusCreate( + """ + The ProjectStatus object to create. + """ + input: ProjectStatusCreateInput! + ): ProjectStatusPayload! + """ + Unarchives a project status. + """ + projectStatusUnarchive( + """ + The identifier of the project status to unarchive. + """ + id: String! + ): ProjectStatusArchivePayload! + """ + Updates a project status. + """ + projectStatusUpdate( + """ + The identifier of the project status to update. + """ + id: String! + """ + A partial ProjectStatus object to update the ProjectStatus with. + """ + input: ProjectStatusUpdateInput! + ): ProjectStatusPayload! + """ + Restores a previously trashed or archived project. + """ + projectUnarchive( + """ + The identifier of the project to restore. Also the identifier from the URL is accepted. + """ + id: String! + ): ProjectArchivePayload! + """ + Updates a project. + """ + projectUpdate( + """ + The identifier of the project to update. Also the identifier from the URL is accepted. + """ + id: String! + """ + A partial project object to update the project with. + """ + input: ProjectUpdateInput! + ): ProjectPayload! + """ + Archives a project update. + """ + projectUpdateArchive( + """ + The identifier of the project update to archive. + """ + id: String! + ): ProjectUpdateArchivePayload! + """ + Creates a new project update. + """ + projectUpdateCreate( + """ + Data for the project update to create. + """ + input: ProjectUpdateCreateInput! + ): ProjectUpdatePayload! + """ + Deletes a project update. + """ + projectUpdateDelete( + """ + The identifier of the project update to delete. + """ + id: String! + ): DeletePayload! @deprecated(reason: "Use `projectUpdateArchive` instead.") + """ + Unarchives a project update. + """ + projectUpdateUnarchive( + """ + The identifier of the project update to unarchive. + """ + id: String! + ): ProjectUpdateArchivePayload! + """ + Updates a project update. + """ + projectUpdateUpdate( + """ + The identifier of the project update to update. + """ + id: String! + """ + The properties of the project update to update. + """ + input: ProjectUpdateUpdateInput! + ): ProjectUpdatePayload! + """ + Creates a push subscription for the authenticated user's current device or browser. If a subscription already exists for the same session, the old one is replaced. + """ + pushSubscriptionCreate( + """ + The push subscription to create. + """ + input: PushSubscriptionCreateInput! + ): PushSubscriptionPayload! + """ + Deletes a push subscription, unregistering the device from receiving push notifications. + """ + pushSubscriptionDelete( + """ + The identifier of the push subscription to delete. + """ + id: String! + ): PushSubscriptionPayload! + """ + Creates a new reaction. + """ + reactionCreate( + """ + The reaction object to create. + """ + input: ReactionCreateInput! + ): ReactionPayload! + """ + Deletes a reaction. + """ + reactionDelete( + """ + The identifier of the reaction to delete. + """ + id: String! + ): DeletePayload! + """ + Manually update Google Sheets data. + """ + refreshGoogleSheetsData( + """ + The identifier of the Google Sheets integration to update. + """ + id: String! + """ + The type of export. + """ + type: String + ): IntegrationPayload! + """ + Archives a release. + """ + releaseArchive( + """ + The identifier of the release to archive. + """ + id: String! + ): ReleaseArchivePayload! + """ + Marks a release as completed. If version is provided, completes that specific release; otherwise completes the most recent started release. + """ + releaseComplete( + """ + The input containing the pipeline ID and optional version. + """ + input: ReleaseCompleteInput! + ): ReleasePayload! + """ + Marks a release as completed using an access key. If version is provided, completes that specific release; otherwise completes the most recent started release. The pipeline is inferred from the access key. + """ + releaseCompleteByAccessKey( + """ + The input containing the optional version. + """ + input: ReleaseCompleteInputBase! + ): AccessKeyReleasePayload! + """ + Creates a new release in a pipeline. If no stage is specified, defaults to the first completed stage for continuous pipelines or the first started stage for scheduled pipelines. + """ + releaseCreate( + """ + The release to create. + """ + input: ReleaseCreateInput! + ): ReleasePayload! + """ + Moves a release to the trash bin. Trashed releases are archived and will be permanently deleted after a retention period. If the release is already archived, it is marked as trashed with a fresh archive timestamp. + """ + releaseDelete( + """ + The identifier of the release to delete. + """ + id: String! + ): ReleaseArchivePayload! + """ + Creates a release note. + """ + releaseNoteCreate( + """ + The release note fields. + """ + input: ReleaseNoteCreateInput! + ): ReleaseNotePayload! + """ + Deletes a release note. + """ + releaseNoteDelete( + """ + The identifier of the release note to delete. + """ + id: String! + ): DeletePayload! + """ + Updates a release note. + """ + releaseNoteUpdate( + """ + The identifier of the release note to update. + """ + id: String! + """ + The fields to update. + """ + input: ReleaseNoteUpdateInput! + ): ReleaseNotePayload! + """ + Archives a release pipeline. + """ + releasePipelineArchive( + """ + The identifier of the release pipeline to archive. + """ + id: String! + ): ReleasePipelineArchivePayload! + """ + Creates a new release pipeline with default stages. Subject to plan entitlement and quota limits. + """ + releasePipelineCreate( + """ + The ReleasePipeline object to create. + """ + input: ReleasePipelineCreateInput! + ): ReleasePipelinePayload! + """ + Moves a release pipeline to the trash bin. Trashed pipelines are archived and will be permanently deleted after a retention period, along with all their releases. If the pipeline is already archived, it is marked as trashed with a fresh archive timestamp. + """ + releasePipelineDelete( + """ + The identifier of the release pipeline to delete. + """ + id: String! + ): ReleasePipelineArchivePayload! + """ + Unarchives a release pipeline. + """ + releasePipelineUnarchive( + """ + The identifier of the release pipeline to unarchive. + """ + id: String! + ): ReleasePipelineArchivePayload! + """ + Updates an existing release pipeline. Supports updating name, slug, type, production flag, path patterns, and team associations. Private teams that the current user cannot access are preserved in the team list. + """ + releasePipelineUpdate( + """ + The identifier of the release pipeline to update. + """ + id: String! + """ + A partial ReleasePipeline object to update the ReleasePipeline with. + """ + input: ReleasePipelineUpdateInput! + ): ReleasePipelinePayload! + """ + Archives a release stage. Only started-type stages can be archived, and only if they have no active releases and at least one other stage of the same type remains. Cannot archive the last non-frozen started stage. + """ + releaseStageArchive( + """ + The identifier of the release stage to archive. + """ + id: String! + ): ReleaseStageArchivePayload! + """ + Creates a new release stage in a pipeline. Non-started stages must use default names and colors and are unique by type; creating a canonical duplicate returns the existing stage. Started stages can optionally be frozen, but at least one non-frozen started stage must remain. + """ + releaseStageCreate( + """ + The ReleaseStage object to create. + """ + input: ReleaseStageCreateInput! + ): ReleaseStagePayload! + """ + Unarchives a release stage. + """ + releaseStageUnarchive( + """ + The identifier of the release stage to unarchive. + """ + id: String! + ): ReleaseStageArchivePayload! + """ + Updates an existing release stage. Only started-type stages can be edited. Supports updating name, color, position, and frozen status. + """ + releaseStageUpdate( + """ + The identifier of the release stage to update. + """ + id: String! + """ + A partial ReleaseStage object to update the ReleaseStage with. + """ + input: ReleaseStageUpdateInput! + ): ReleaseStagePayload! + """ + Syncs release data by resolving issue and pull request references and associating them with a release. For continuous pipelines, creates a new completed release. For scheduled pipelines, finds or creates a started release and accumulates issues into it. + """ + releaseSync( + """ + The release data to sync. + """ + input: ReleaseSyncInput! + ): ReleasePayload! + """ + Syncs release data using an access key for CI/CD integration. The pipeline is automatically inferred from the access key's configured resources, so no pipeline ID is needed in the input. + """ + releaseSyncByAccessKey( + """ + The release data to sync. + """ + input: ReleaseSyncInputBase! + ): AccessKeyReleasePayload! + """ + Unarchives a release. + """ + releaseUnarchive( + """ + The identifier of the release to unarchive. + """ + id: String! + ): ReleaseArchivePayload! + """ + Updates an existing release by ID. Supports updating name, description, version, commit SHA, pipeline, stage, and dates. + """ + releaseUpdate( + """ + The identifier of the release to update. + """ + id: String! + """ + A partial Release object to update the Release with. + """ + input: ReleaseUpdateInput! + ): ReleasePayload! + """ + Updates a release by pipeline identifier. Finds the release by version or latest started/planned release, and optionally transitions it to a new stage by name. + """ + releaseUpdateByPipeline( + """ + The input containing the pipeline ID, optional version, and optional stage name. + """ + input: ReleaseUpdateByPipelineInput! + ): ReleasePayload! + """ + Updates a release by pipeline using an access key. + """ + releaseUpdateByPipelineByAccessKey( + """ + The input containing the optional version and optional stage name. + """ + input: ReleaseUpdateByPipelineInputBase! + ): AccessKeyReleasePayload! + """ + Re-sends a workspace invitation email for the specified invite ID. + """ + resendOrganizationInvite( + """ + The identifier of the organization invite to re-send. + """ + id: String! + ): DeletePayload! + """ + Re-sends a workspace invitation email to the specified email address, if an outstanding invite exists for that address. + """ + resendOrganizationInviteByEmail( + """ + The email address tied to the organization invite to re-send. + """ + email: String! + ): DeletePayload! + """ + Archives a roadmap. + """ + roadmapArchive( + """ + The identifier of the roadmap to archive. + """ + id: String! + ): RoadmapArchivePayload! @deprecated(reason: "Roadmaps are deprecated, use initiatives instead.") + """ + Creates a new roadmap. + """ + roadmapCreate( + """ + The properties of the roadmap to create. + """ + input: RoadmapCreateInput! + ): RoadmapPayload! @deprecated(reason: "Roadmaps are deprecated, use initiatives instead.") + """ + Deletes a roadmap. + """ + roadmapDelete( + """ + The identifier of the roadmap to delete. + """ + id: String! + ): DeletePayload! @deprecated(reason: "Roadmaps are deprecated, use initiatives instead.") + """ + [Deprecated] Creates a new roadmap-to-project association. Use InitiativeToProject instead. + """ + roadmapToProjectCreate( + """ + The properties of the roadmapToProject to create. + """ + input: RoadmapToProjectCreateInput! + ): RoadmapToProjectPayload! + """ + [Deprecated] Deletes a roadmap-to-project association. Use InitiativeToProject instead. + """ + roadmapToProjectDelete( + """ + The identifier of the roadmapToProject to delete. + """ + id: String! + ): DeletePayload! + """ + [Deprecated] Updates a roadmap-to-project association. Use InitiativeToProject instead. + """ + roadmapToProjectUpdate( + """ + The identifier of the roadmapToProject to update. + """ + id: String! + """ + The properties of the roadmapToProject to update. + """ + input: RoadmapToProjectUpdateInput! + ): RoadmapToProjectPayload! + """ + Unarchives a roadmap. + """ + roadmapUnarchive( + """ + The identifier of the roadmap to unarchive. + """ + id: String! + ): RoadmapArchivePayload! @deprecated(reason: "Roadmaps are deprecated, use initiatives instead.") + """ + Updates a roadmap. + """ + roadmapUpdate( + """ + The identifier of the roadmap to update. + """ + id: String! + """ + The properties of the roadmap to update. + """ + input: RoadmapUpdateInput! + ): RoadmapPayload! @deprecated(reason: "Roadmaps are deprecated, use initiatives instead.") + """ + Authenticates a user account via email and authentication token for SAML. + """ + samlTokenUserAccountAuth( + """ + The data used for token authentication. + """ + input: TokenUserAccountAuthInput! + ): AuthResolverResponse! + """ + Creates a new team. The user who creates the team will automatically be added as a member and owner of the newly created team. Default workflow states, labels, and other team resources are created alongside the team. + """ + teamCreate( + """ + The team id to copy settings from, if any. + """ + copySettingsFromTeamId: String + """ + The team object to create. + """ + input: TeamCreateInput! + ): TeamPayload! + """ + Deletes all cycle data for a team, disabling the cycles feature. This removes all cycles and their issue associations. + """ + teamCyclesDelete( + """ + The identifier of the team, which cycles will be deleted. + """ + id: String! + ): TeamPayload! + """ + Archives a team and schedules its data for deletion. Requires team owner or workspace admin permissions. + """ + teamDelete( + """ + The identifier of the team to delete. + """ + id: String! + ): DeletePayload! + """ + Deletes a previously used team key. The active team key (the team's current key) cannot be deleted. + """ + teamKeyDelete( + """ + The identifier of the team key to delete. + """ + id: String! + ): DeletePayload! + """ + Creates a new team membership, adding a user to a team. Validates that the user is not already a member, the team is not archived or retired, and the requesting user has permission to add members. + """ + teamMembershipCreate( + """ + The team membership object to create. + """ + input: TeamMembershipCreateInput! + ): TeamMembershipPayload! + """ + Deletes a team membership, removing the user from the team. Users can remove their own membership, or team owners and workspace admins can remove other members. + """ + teamMembershipDelete( + """ + Whether to leave the parent teams. + """ + alsoLeaveParentTeams: Boolean + """ + The identifier of the team membership to delete. + """ + id: String! + ): DeletePayload! + """ + Updates a team membership, such as changing ownership status or sort order. + """ + teamMembershipUpdate( + """ + The identifier of the team membership to update. + """ + id: String! + """ + A partial team membership object to update the team membership with. + """ + input: TeamMembershipUpdateInput! + ): TeamMembershipPayload! + """ + Unarchives a team and cancels deletion. + """ + teamUnarchive( + """ + The identifier of the team to unarchive. + """ + id: String! + ): TeamArchivePayload! + """ + Updates a team's settings, properties, or configuration. Requires team owner or workspace admin permissions for most changes. + """ + teamUpdate( + """ + The identifier of the team to update. + """ + id: String! + """ + A partial team object to update the team with. + """ + input: TeamUpdateInput! + """ + [INTERNAL] Mapping of existing team entities to those inherited from the parent team + """ + mapping: InheritanceEntityMapping + ): TeamPayload! + """ + Creates a new template. + """ + templateCreate( + """ + The template object to create. + """ + input: TemplateCreateInput! + ): TemplatePayload! + """ + Deletes a template. + """ + templateDelete( + """ + The identifier of the template to delete. + """ + id: String! + ): DeletePayload! + """ + Updates an existing template. + """ + templateUpdate( + """ + The identifier of the template. + """ + id: String! + """ + The properties of the template to update. + """ + input: TemplateUpdateInput! + ): TemplatePayload! + """ + Creates a new time schedule. + """ + timeScheduleCreate( + """ + The properties of the time schedule to create. + """ + input: TimeScheduleCreateInput! + ): TimeSchedulePayload! + """ + Deletes a time schedule. + """ + timeScheduleDelete( + """ + The identifier of the time schedule to delete. + """ + id: String! + ): DeletePayload! + """ + Refresh the integration schedule information. + """ + timeScheduleRefreshIntegrationSchedule( + """ + The identifier of the time schedule to refresh. + """ + id: String! + ): TimeSchedulePayload! + """ + Updates a time schedule. + """ + timeScheduleUpdate( + """ + The identifier of the time schedule to update. + """ + id: String! + """ + The properties of the time schedule to update. + """ + input: TimeScheduleUpdateInput! + ): TimeSchedulePayload! + """ + Upsert an external time schedule. + """ + timeScheduleUpsertExternal( + """ + The unique identifier of the external schedule. + """ + externalId: String! + """ + The properties of the time schedule to insert or update. + """ + input: TimeScheduleUpdateInput! + ): TimeSchedulePayload! + """ + Track an anonymous analytics event. + """ + trackAnonymousEvent( + """ + Event tracking details. + """ + input: EventTrackingInput! + ): EventTrackingPayload! + """ + Creates a new triage responsibility. + """ + triageResponsibilityCreate( + """ + The properties of the triage responsibility to create. + """ + input: TriageResponsibilityCreateInput! + ): TriageResponsibilityPayload! + """ + Deletes a triage responsibility. + """ + triageResponsibilityDelete( + """ + The identifier of the triage responsibility to delete. + """ + id: String! + ): DeletePayload! + """ + Updates an existing triage responsibility. + """ + triageResponsibilityUpdate( + """ + The identifier of the triage responsibility to update. + """ + id: String! + """ + The properties of the triage responsibility to update. + """ + input: TriageResponsibilityUpdateInput! + ): TriageResponsibilityPayload! + """ + [Internal] Updates existing Slack and Asks integration scopes. + """ + updateIntegrationSlackScopes( + """ + The Slack OAuth code. + """ + code: String! + """ + The ID of the existing Slack integration + """ + integrationId: String! + """ + The Slack OAuth redirect URI. + """ + redirectUri: String! + """ + The Slack OAuth scopes the client requested. Used to warn when Slack grants fewer scopes than requested. + """ + requestedScopes: [String!] + ): IntegrationPayload! + """ + Changes the workspace role of a user. The requesting user must have a role equal to or higher than the target role. Requires workspace admin permissions. + """ + userChangeRole( + """ + The identifier of the user + """ + id: String! + """ + The new role for the user. + """ + role: UserRoleType! + ): UserAdminPayload! + """ + Connects the Discord user to this Linear account via OAuth2. + """ + userDiscordConnect( + """ + The Discord OAuth code. + """ + code: String! + """ + The Discord OAuth redirect URI. + """ + redirectUri: String! + ): UserPayload! + """ + Disconnects the external user from this Linear account. + """ + userExternalUserDisconnect( + """ + The external service to disconnect. + """ + service: String! + """ + The workspace Jira integration whose account mapping to remove. If omitted, removes all Jira mappings without a personal connection. + """ + workspaceIntegrationId: String + ): UserPayload! + """ + Updates a specific user settings flag by performing an operation (e.g., increment or clear) on it. + """ + userFlagUpdate( + """ + Settings flag to increment. + """ + flag: UserFlagType! + """ + Flag operation to perform. + """ + operation: UserFlagUpdateOperation! + ): UserSettingsFlagPayload! + """ + Revokes all active sessions for a user, forcing them to re-authenticate. Can only be called by a workspace admin or owner. + """ + userRevokeAllSessions( + """ + The identifier of the user to logout all sessions of. + """ + id: String! + ): UserAdminPayload! + """ + Revokes a specific authentication session for a user. The admin cannot revoke their own sessions with this mutation. Can only be called by a workspace admin or owner. + """ + userRevokeSession( + """ + The identifier of the user whose session to revoke. + """ + id: String! + """ + The identifier of the session to revoke. + """ + sessionId: String! + ): UserAdminPayload! + """ + Resets one or more of the user's setting flags. If no specific flags are provided, all flags are reset. + """ + userSettingsFlagsReset( + """ + The flags to reset. If not provided all flags will be reset. + """ + flags: [UserFlagType!] + ): UserSettingsFlagsResetPayload! + """ + Updates the authenticated user's settings, including notification preferences, email subscriptions, theme, and other UI preferences. + """ + userSettingsUpdate( + """ + The identifier of the userSettings to update. + """ + id: String! + """ + A partial notification object to update the settings with. + """ + input: UserSettingsUpdateInput! + ): UserSettingsPayload! + """ + Suspends a user, deactivating their account and revoking access to the workspace. The suspended user's sessions are invalidated. Can only be called by a workspace admin or owner. + """ + userSuspend( + """ + [INTERNAL] Whether to bypass SCIM restrictions when suspending. Use with caution โ€” this overrides identity provider management. + """ + forceBypassScimRestrictions: Boolean + """ + The identifier of the user to suspend. + """ + id: String! + ): UserAdminPayload! + """ + Unlinks a guest user from their identity provider. Can only be called by an admin when SCIM is enabled. + """ + userUnlinkFromIdentityProvider( + """ + The identifier of the guest user to unlink from their identity provider. + """ + id: String! + ): UserAdminPayload! + """ + Re-activates a suspended user, restoring their access to the workspace. Can only be called by a workspace admin or owner. + """ + userUnsuspend( + """ + [INTERNAL] Whether to bypass SCIM restrictions when unsuspending. Use with caution โ€” this overrides identity provider management. + """ + forceBypassScimRestrictions: Boolean + """ + The identifier of the user to unsuspend. + """ + id: String! + ): UserAdminPayload! + """ + Updates a user's profile information. Users can update their own profile; workspace admins can update any user's profile. SCIM-managed users may have restricted name changes. + """ + userUpdate( + """ + The identifier of the user to update. Use `me` to reference currently authenticated user. + """ + id: String! + """ + A partial user object to update the user with. + """ + input: UserUpdateInput! + ): UserPayload! + """ + Creates a new view preferences object. If conflicting preferences already exist for the same view type and scope, the existing preferences are replaced. + """ + viewPreferencesCreate( + """ + The ViewPreferences object to create. + """ + input: ViewPreferencesCreateInput! + ): ViewPreferencesPayload! + """ + Deletes a view preferences object. If the preferences do not exist, the operation is treated as a successful idempotent deletion. + """ + viewPreferencesDelete( + """ + The identifier of the ViewPreferences to delete. + """ + id: String! + ): DeletePayload! + """ + Updates an existing view preferences object. For user-type preferences, only the owning user can update them. + """ + viewPreferencesUpdate( + """ + The identifier of the ViewPreferences object. + """ + id: String! + """ + The properties of the view preferences. + """ + input: ViewPreferencesUpdateInput! + ): ViewPreferencesPayload! + """ + Creates a new webhook subscription for the workspace. Requires specifying a URL, resource types to subscribe to, and either a specific team or all public teams. + """ + webhookCreate( + """ + The webhook object to create. + """ + input: WebhookCreateInput! + ): WebhookPayload! + """ + Deletes a Webhook. + """ + webhookDelete( + """ + The identifier of the Webhook to delete. + """ + id: String! + ): DeletePayload! + """ + Rotates the signing secret for a webhook, generating a new HMAC-SHA256 key and returning it. The old secret is immediately invalidated. + """ + webhookRotateSecret( + """ + The identifier of the Webhook to rotate the secret for. + """ + id: String! + ): WebhookRotateSecretPayload! + """ + Updates an existing Webhook. + """ + webhookUpdate( + """ + The identifier of the Webhook. + """ + id: String! + """ + The properties of the Webhook. + """ + input: WebhookUpdateInput! + ): WebhookPayload! + """ + Archives a state. Only states with issues that have all been archived can be archived. + """ + workflowStateArchive( + """ + The identifier of the state to archive. + """ + id: String! + ): WorkflowStateArchivePayload! + """ + Creates a new state, adding it to the workflow of a team. + """ + workflowStateCreate( + """ + The state to create. + """ + input: WorkflowStateCreateInput! + ): WorkflowStatePayload! + """ + Updates a state. + """ + workflowStateUpdate( + """ + The identifier of the state to update. + """ + id: String! + """ + A partial state object to update. + """ + input: WorkflowStateUpdateInput! + ): WorkflowStatePayload! +} + +""" +Customer name sorting options. +""" +input NameSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +interface Node { + """ + The unique identifier of the entity. + """ + id: ID! +} + +""" +A notification delivered to a user's inbox. Notifications are created in response to activity in the workspace such as issue assignments, comments, mentions, and status changes. Each notification has a specific type that determines the associated entity (issue, project, document, etc.) and the nature of the event. Notifications can be read, snoozed, or archived by the user. +""" +interface Notification implements Entity & Node { + """ + The user that caused the notification. Null if the notification was triggered by a non-user actor such as an integration, external user, or system event. + """ + actor: User + """ + [Internal] Notification actor initials if avatar is not available. + """ + actorAvatarColor: String! + """ + [Internal] Notification avatar URL. + """ + actorAvatarUrl: String + """ + [Internal] Whether the notification's user actor is deactivated in the workspace. + """ + actorInactive: Boolean! + """ + [Internal] Notification actor initials if avatar is not available. + """ + actorInitials: String + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The bot that caused the notification. + """ + botActor: ActorBot + """ + The category of the notification. + """ + category: NotificationCategory! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The time at which an email reminder for this notification was sent to the user. Null if no email reminder has been sent. + """ + emailedAt: DateTime + """ + The external user that caused the notification. Populated when the notification was triggered by an external user (e.g., a commenter from a connected integration like Slack or GitHub) rather than a Linear workspace member. + """ + externalUserActor: ExternalUser + """ + [Internal] Notifications with the same grouping key will be grouped together in the UI. + """ + groupingKey: String! + """ + [Internal] Priority of the notification with the same grouping key. Higher number means higher priority. If priority is the same, notifications should be sorted by `createdAt`. + """ + groupingPriority: Float! + """ + The unique identifier of the entity. + """ + id: ID! + """ + [Internal] Inbox URL for the notification. + """ + inboxUrl: String! + """ + [Internal] Initiative update health for new updates. + """ + initiativeUpdateHealth: String + """ + [Internal] If notification actor was Linear. + """ + isLinearActor: Boolean! + """ + [Internal] Issue's status type for issue notifications. + """ + issueStatusType: String + """ + [Internal] Project update health for new updates. + """ + projectUpdateHealth: String + """ + The time at which the user marked the notification as read. Null if the notification is unread. + """ + readAt: DateTime + """ + The time until which a notification is snoozed. After this time, the notification reappears in the user's inbox. Null if the notification is not currently snoozed. + """ + snoozedUntilAt: DateTime + """ + [Internal] Notification subtitle. + """ + subtitle: String! + """ + [Internal] Notification title. + """ + title: String! + """ + Notification type. Determines the kind of event that triggered this notification and which associated entity fields will be populated. + """ + type: String! + """ + The time at which a notification was unsnoozed. Null if the notification has not been unsnoozed. + """ + unsnoozedAt: DateTime + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + [Internal] URL to the target of the notification. + """ + url: String! + """ + The recipient user of this notification. + """ + user: User! +} + +""" +A generic payload return from entity archive mutations. +""" +type NotificationArchivePayload implements ArchivePayload { + """ + The archived/unarchived entity. Null if entity was deleted. + """ + entity: Notification + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Return type for batch notification mutations that operate on multiple notifications at once. +""" +type NotificationBatchActionPayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + The notifications that were updated by the batch operation. + """ + notifications: [Notification!]! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +The categories of notifications a user can subscribe to. +""" +enum NotificationCategory { + appsAndIntegrations + assignments + billing + commentsAndReplies + customers + documentChanges + feed + loops + mentions + postsAndUpdates + reactions + reminders + reviews + statusChanges + subscriptions + system + triage +} + +""" +A user's fully resolved notification category preferences. Each category maps to channel preferences indicating whether mobile, desktop, email, and Slack delivery are enabled. +""" +type NotificationCategoryPreferences { + """ + The preferences for notifications about apps and integrations. + """ + appsAndIntegrations: NotificationChannelPreferences! + """ + The preferences for notifications about assignments. + """ + assignments: NotificationChannelPreferences! + """ + The preferences for billing notifications. + """ + billing: NotificationChannelPreferences! + """ + The preferences for notifications about comments and replies. + """ + commentsAndReplies: NotificationChannelPreferences! + """ + The preferences for customer notifications. + """ + customers: NotificationChannelPreferences! + """ + The preferences for notifications about document changes. + """ + documentChanges: NotificationChannelPreferences! + """ + The preferences for feed summary notifications. + """ + feed: NotificationChannelPreferences! + """ + The preferences for notifications about loops. + """ + loops: NotificationChannelPreferences! + """ + The preferences for notifications about mentions. + """ + mentions: NotificationChannelPreferences! + """ + The preferences for notifications about posts and updates. + """ + postsAndUpdates: NotificationChannelPreferences! + """ + The preferences for notifications about reactions. + """ + reactions: NotificationChannelPreferences! + """ + The preferences for notifications about reminders. + """ + reminders: NotificationChannelPreferences! + """ + The preferences for notifications about reviews. + """ + reviews: NotificationChannelPreferences! + """ + The preferences for notifications about status changes. + """ + statusChanges: NotificationChannelPreferences! + """ + The preferences for notifications about subscriptions. + """ + subscriptions: NotificationChannelPreferences! + """ + The preferences for system notifications. + """ + system: NotificationChannelPreferences! + """ + The preferences for triage notifications. + """ + triage: NotificationChannelPreferences! +} + +input NotificationCategoryPreferencesInput { + """ + The preferences for notifications about apps and integrations. + """ + appsAndIntegrations: PartialNotificationChannelPreferencesInput + """ + The preferences for notifications about assignments. + """ + assignments: PartialNotificationChannelPreferencesInput + """ + The preferences for billing notifications. + """ + billing: PartialNotificationChannelPreferencesInput + """ + The preferences for notifications about comments and replies. + """ + commentsAndReplies: PartialNotificationChannelPreferencesInput + """ + The preferences for notifications about customers. + """ + customers: PartialNotificationChannelPreferencesInput + """ + The preferences for notifications about document changes. + """ + documentChanges: PartialNotificationChannelPreferencesInput + """ + The preferences for notifications about feed summaries. + """ + feed: PartialNotificationChannelPreferencesInput + """ + The preferences for notifications about loops. + """ + loops: PartialNotificationChannelPreferencesInput + """ + The preferences for notifications about mentions. + """ + mentions: PartialNotificationChannelPreferencesInput + """ + The preferences for notifications about posts and updates. + """ + postsAndUpdates: PartialNotificationChannelPreferencesInput + """ + The preferences for notifications about reactions. + """ + reactions: PartialNotificationChannelPreferencesInput + """ + The preferences for notifications about reminders. + """ + reminders: PartialNotificationChannelPreferencesInput + """ + The preferences for notifications about reviews. + """ + reviews: PartialNotificationChannelPreferencesInput + """ + The preferences for notifications about status changes. + """ + statusChanges: PartialNotificationChannelPreferencesInput + """ + The preferences for notifications about subscriptions. + """ + subscriptions: PartialNotificationChannelPreferencesInput + """ + The preferences for notifications about triage. + """ + triage: PartialNotificationChannelPreferencesInput +} + +""" +The delivery channels a user can receive notifications in. +""" +enum NotificationChannel { + desktop + email + mobile + slack +} + +""" +A user's resolved notification channel preferences, indicating whether each delivery channel (mobile, desktop, email, Slack) is enabled or disabled. +""" +type NotificationChannelPreferences { + """ + Whether notifications are currently enabled for desktop. + """ + desktop: Boolean! + """ + Whether notifications are currently enabled for email. + """ + email: Boolean! + """ + Whether notifications are currently enabled for mobile. + """ + mobile: Boolean! + """ + Whether notifications are currently enabled for Slack. + """ + slack: Boolean! +} + +type NotificationConnection { + edges: [NotificationEdge!]! + nodes: [Notification!]! + pageInfo: PageInfo! +} + +""" +A user's notification delivery preferences across channels. Currently only supports mobile channel delivery scheduling. +""" +type NotificationDeliveryPreferences { + """ + The delivery preferences for the mobile channel. + """ + mobile: NotificationDeliveryPreferencesChannel +} + +""" +Delivery preferences for a specific notification channel, including an optional delivery schedule that restricts when notifications are sent. +""" +type NotificationDeliveryPreferencesChannel { + """ + [DEPRECATED] Whether notifications are enabled for this channel. Use notificationChannelPreferences instead. + """ + notificationsDisabled: Boolean + @deprecated(reason: "This field has been replaced by notificationChannelPreferences") + """ + The schedule for notifications on this channel. + """ + schedule: NotificationDeliveryPreferencesSchedule +} + +input NotificationDeliveryPreferencesChannelInput { + """ + The schedule for notifications on this channel. + """ + schedule: NotificationDeliveryPreferencesScheduleInput +} + +""" +A user's notification delivery window for a specific day of the week. Defines the time range during which notifications will be delivered. +""" +type NotificationDeliveryPreferencesDay { + """ + The end time of the notification delivery window in HH:MM military time format (e.g., '18:00'). Must be later than 'start'. + """ + end: String + """ + The start time of the notification delivery window in HH:MM military time format (e.g., '09:00'). Must be earlier than 'end'. + """ + start: String +} + +input NotificationDeliveryPreferencesDayInput { + """ + The end time of the notification delivery window in HH:MM military time format (e.g., '18:00'). Must be later than 'start'. + """ + end: String + """ + The start time of the notification delivery window in HH:MM military time format (e.g., '09:00'). Must be earlier than 'end'. + """ + start: String +} + +input NotificationDeliveryPreferencesInput { + """ + The delivery preferences for the mobile channel. + """ + mobile: NotificationDeliveryPreferencesChannelInput +} + +""" +A user's weekly notification delivery schedule, defining delivery windows for each day of the week. Notifications outside these windows are held and delivered when the window opens. +""" +type NotificationDeliveryPreferencesSchedule { + """ + Whether the entire delivery schedule is disabled. When true, notifications are delivered at any time regardless of the per-day settings. + """ + disabled: Boolean + """ + Delivery preferences for Friday. + """ + friday: NotificationDeliveryPreferencesDay! + """ + Delivery preferences for Monday. + """ + monday: NotificationDeliveryPreferencesDay! + """ + Delivery preferences for Saturday. + """ + saturday: NotificationDeliveryPreferencesDay! + """ + Delivery preferences for Sunday. + """ + sunday: NotificationDeliveryPreferencesDay! + """ + Delivery preferences for Thursday. + """ + thursday: NotificationDeliveryPreferencesDay! + """ + Delivery preferences for Tuesday. + """ + tuesday: NotificationDeliveryPreferencesDay! + """ + Delivery preferences for Wednesday. + """ + wednesday: NotificationDeliveryPreferencesDay! +} + +input NotificationDeliveryPreferencesScheduleInput { + """ + Whether the entire delivery schedule is disabled. When true, notifications are delivered at any time regardless of the per-day settings. + """ + disabled: Boolean + """ + Delivery preferences for Friday. + """ + friday: NotificationDeliveryPreferencesDayInput! + """ + Delivery preferences for Monday. + """ + monday: NotificationDeliveryPreferencesDayInput! + """ + Delivery preferences for Saturday. + """ + saturday: NotificationDeliveryPreferencesDayInput! + """ + Delivery preferences for Sunday. + """ + sunday: NotificationDeliveryPreferencesDayInput! + """ + Delivery preferences for Thursday. + """ + thursday: NotificationDeliveryPreferencesDayInput! + """ + Delivery preferences for Tuesday. + """ + tuesday: NotificationDeliveryPreferencesDayInput! + """ + Delivery preferences for Wednesday. + """ + wednesday: NotificationDeliveryPreferencesDayInput! +} + +type NotificationEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: Notification! +} + +""" +Identifies a specific entity whose related notifications should be targeted by a batch operation. Exactly one entity identifier should be provided. +""" +input NotificationEntityInput { + """ + The id of the notification. + """ + id: String + """ + The id of the initiative related to the notification. + """ + initiativeId: String + """ + The id of the initiative update related to the notification. + """ + initiativeUpdateId: String + """ + The id of the issue related to the notification. + """ + issueId: String + """ + The id of the OAuth client approval related to the notification. + """ + oauthClientApprovalId: String + """ + [DEPRECATED] The id of the project related to the notification. + """ + projectId: String + """ + The id of the project update related to the notification. + """ + projectUpdateId: String +} + +""" +Notification filtering options. +""" +input NotificationFilter { + """ + Compound filters, all of which need to be matched by the notification. + """ + and: [NotificationFilter!] + """ + Comparator for the archived at date. + """ + archivedAt: DateComparator + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Compound filters, one of which need to be matched by the notification. + """ + or: [NotificationFilter!] + """ + Comparator for the notification subscription type. + """ + subscriptionType: NotificationSubscriptionTypeComparator + """ + Comparator for the notification type. + """ + type: StringComparator + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +Return type for notification mutations. +""" +type NotificationPayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + The notification that was updated. + """ + notification: Notification! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +A subscription that controls which notifications a user receives for a specific entity such as a team, project, cycle, label, custom view, initiative, or user. This is not a billing subscription -- it determines notification preferences. Each subscription is scoped to exactly one target entity and specifies the notification types the subscriber wants to receive. When active, matching events on the target entity generate notifications for the subscriber. +""" +interface NotificationSubscription implements Entity & Node { + """ + Whether the subscription is active. When inactive, no notifications are generated from this subscription even though it still exists. + """ + active: Boolean! + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The type of contextual view (e.g., active issues, backlog) that further scopes a team notification subscription. Null if the subscription is not associated with a specific view type. + """ + contextViewType: ContextViewType + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The custom view that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + customView: CustomView + """ + The customer that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + customer: Customer + """ + The cycle that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + cycle: Cycle + """ + The unique identifier of the entity. + """ + id: ID! + """ + Whether initiative update notifications also include updates from sub-initiatives. Applies only when initiative updates are enabled and the workspace supports sub-initiatives. + """ + includeSubInitiativeUpdates: Boolean! + """ + The initiative that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + initiative: Initiative + """ + The issue label that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + label: IssueLabel + """ + The project that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + project: Project + """ + The user who will receive notifications from this subscription. + """ + subscriber: User! + """ + The team that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + team: Team + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The user that this notification subscription is scoped to, for user-specific view subscriptions. Null if the subscription targets a different entity type. + """ + user: User + """ + The type of user-specific view that further scopes a user notification subscription. Null if the subscription is not associated with a user view type. + """ + userContextViewType: UserContextViewType +} + +type NotificationSubscriptionConnection { + edges: [NotificationSubscriptionEdge!]! + nodes: [NotificationSubscription!]! + pageInfo: PageInfo! +} + +""" +Input for creating a notification subscription. Exactly one target entity (customer, custom view, cycle, initiative, label, project, team, or user) must be specified along with the notification types to subscribe to. +""" +input NotificationSubscriptionCreateInput { + """ + Whether the subscription is active. Set to false to pause notifications without deleting the subscription. + """ + active: Boolean + """ + The type of view to which the notification subscription context is associated with. + """ + contextViewType: ContextViewType + """ + The identifier of the custom view to subscribe to. + """ + customViewId: String + """ + The identifier of the customer to subscribe to. + """ + customerId: String + """ + The identifier of the cycle to subscribe to. + """ + cycleId: String + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + Whether to include updates from sub-initiatives. + """ + includeSubInitiativeUpdates: Boolean + """ + The identifier of the initiative to subscribe to. + """ + initiativeId: String + """ + The identifier of the label to subscribe to. + """ + labelId: String + """ + The specific notification event types the subscriber wants to receive for the target entity. + """ + notificationSubscriptionTypes: [String!] + """ + The identifier of the project to subscribe to. + """ + projectId: String + """ + The identifier of the team to subscribe to. + """ + teamId: String + """ + The type of user view to which the notification subscription context is associated with. + """ + userContextViewType: UserContextViewType + """ + The identifier of the user to subscribe to. + """ + userId: String +} + +type NotificationSubscriptionEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: NotificationSubscription! +} + +""" +The result of a notification subscription mutation. +""" +type NotificationSubscriptionPayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + The notification subscription that was created or updated. This controls which notifications the user receives for the associated entity. + """ + notificationSubscription: NotificationSubscription! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +The delivery target type that caused a notification to be sent. +""" +enum NotificationSubscriptionType { + customView + customer + cycle + document + initiative + issue + label + oauthClientApproval + project + pullRequest + team + user + workflowDefinition +} + +""" +Comparator for notification subscription type. +""" +input NotificationSubscriptionTypeComparator { + """ + Equals constraint. + """ + eq: NotificationSubscriptionType + """ + In-array constraint. + """ + in: [NotificationSubscriptionType!] + """ + Not-equals constraint. + """ + neq: NotificationSubscriptionType + """ + Not-in-array constraint. + """ + nin: [NotificationSubscriptionType!] +} + +""" +Input for updating an existing notification subscription. Allows changing the subscribed notification types and active state. +""" +input NotificationSubscriptionUpdateInput { + """ + Whether the subscription is active. + """ + active: Boolean + """ + Whether to include updates from sub-initiatives. + """ + includeSubInitiativeUpdates: Boolean + """ + The specific notification event types the subscriber wants to receive. Replaces all previously configured types. + """ + notificationSubscriptionTypes: [String!] +} + +""" +Input for updating a notification's read and snooze state. +""" +input NotificationUpdateInput { + """ + The id of the initiative update related to the notification. + """ + initiativeUpdateId: String + """ + The id of the project update related to the notification. + """ + projectUpdateId: String + """ + The time when notification was marked as read. + """ + readAt: DateTime + """ + The time until a notification will be snoozed. After that it will appear in the inbox again. + """ + snoozedUntilAt: DateTime +} + +union NotificationWebhookPayload = + | IssueAssignedToYouNotificationWebhookPayload + | IssueCommentMentionNotificationWebhookPayload + | IssueCommentReactionNotificationWebhookPayload + | IssueEmojiReactionNotificationWebhookPayload + | IssueMentionNotificationWebhookPayload + | IssueNewCommentNotificationWebhookPayload + | IssueStatusChangedNotificationWebhookPayload + | IssueUnassignedFromYouNotificationWebhookPayload + | OtherNotificationWebhookPayload + +input NotionSettingsInput { + """ + The ID of the Notion workspace being connected. + """ + workspaceId: String! + """ + The name of the Notion workspace being connected. + """ + workspaceName: String! +} + +""" +Comment filtering options. +""" +input NullableCommentFilter { + """ + Compound filters, all of which need to be matched by the comment. + """ + and: [NullableCommentFilter!] + """ + Comparator for the comment's body. + """ + body: StringComparator + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Filters that the comment's document content must satisfy. + """ + documentContent: NullableDocumentContentFilter + """ + Comparator for the identifier. + """ + id: IDComparator + """ + [Internal] Filters that the comment's initiative must satisfy. + """ + initiative: NullableInitiativeFilter + """ + Filters that the comment's initiative update must satisfy. + """ + initiativeUpdate: NullableInitiativeUpdateFilter + """ + Filters that the comment's issue must satisfy. + """ + issue: NullableIssueFilter + """ + Filters that the comment's customer needs must satisfy. + """ + needs: CustomerNeedCollectionFilter + """ + Filter based on the existence of the relation. + """ + null: Boolean + """ + Compound filters, one of which need to be matched by the comment. + """ + or: [NullableCommentFilter!] + """ + Filters that the comment parent must satisfy. + """ + parent: NullableCommentFilter + """ + [Internal] Filters that the comment's project must satisfy. + """ + project: NullableProjectFilter + """ + Filters that the comment's project update must satisfy. + """ + projectUpdate: NullableProjectUpdateFilter + """ + Filters that the comment's reactions must satisfy. + """ + reactions: ReactionCollectionFilter + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator + """ + Filters that the comment's creator must satisfy. + """ + user: UserFilter +} + +""" +Customer filtering options. +""" +input NullableCustomerFilter { + """ + Compound filters, all of which need to be matched by the customer. + """ + and: [NullableCustomerFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for the customer's domains. + """ + domains: StringArrayComparator + """ + Comparator for the customer's external IDs. + """ + externalIds: StringArrayComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Comparator for the customer name. + """ + name: StringComparator + """ + Filters that the customer's needs must satisfy. + """ + needs: CustomerNeedCollectionFilter + """ + Filter based on the existence of the relation. + """ + null: Boolean + """ + Compound filters, one of which need to be matched by the customer. + """ + or: [NullableCustomerFilter!] + """ + Filters that the customer owner must satisfy. + """ + owner: NullableUserFilter + """ + Comparator for the customer generated revenue. + """ + revenue: NumberComparator + """ + Comparator for the customer size. + """ + size: NumberComparator + """ + Comparator for the customer slack channel ID. + """ + slackChannelId: StringComparator + """ + Filters that the customer's status must satisfy. + """ + status: CustomerStatusFilter + """ + Filters that the customer's tier must satisfy. + """ + tier: CustomerTierFilter + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +Cycle filtering options. +""" +input NullableCycleFilter { + """ + Compound filters, all of which need to be matched by the cycle. + """ + and: [NullableCycleFilter!] + """ + Comparator for the cycle completed at date. + """ + completedAt: DateComparator + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for the cycle ends at date. + """ + endsAt: DateComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Comparator for the inherited cycle ID. + """ + inheritedFromId: IDComparator + """ + Comparator for the filtering active cycle. + """ + isActive: BooleanComparator + """ + Comparator for the filtering future cycles. + """ + isFuture: BooleanComparator + """ + Comparator for filtering for whether the cycle is currently in cooldown. + """ + isInCooldown: BooleanComparator + """ + Comparator for the filtering next cycle. + """ + isNext: BooleanComparator + """ + Comparator for the filtering past cycles. + """ + isPast: BooleanComparator + """ + Comparator for the filtering previous cycle. + """ + isPrevious: BooleanComparator + """ + Filters that the cycles issues must satisfy. + """ + issues: IssueCollectionFilter + """ + Comparator for the cycle name. + """ + name: StringComparator + """ + Filter based on the existence of the relation. + """ + null: Boolean + """ + Comparator for the cycle number. + """ + number: NumberComparator + """ + Compound filters, one of which need to be matched by the cycle. + """ + or: [NullableCycleFilter!] + """ + Comparator for the cycle start date. + """ + startsAt: DateComparator + """ + Filters that the cycles team must satisfy. + """ + team: TeamFilter + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +Comparator for optional dates. +""" +input NullableDateComparator { + """ + Equals constraint. + """ + eq: DateTimeOrDuration + """ + Greater-than constraint. Matches any values that are greater than the given value. + """ + gt: DateTimeOrDuration + """ + Greater-than-or-equal constraint. Matches any values that are greater than or equal to the given value. + """ + gte: DateTimeOrDuration + """ + In-array constraint. + """ + in: [DateTimeOrDuration!] + """ + Less-than constraint. Matches any values that are less than the given value. + """ + lt: DateTimeOrDuration + """ + Less-than-or-equal constraint. Matches any values that are less than or equal to the given value. + """ + lte: DateTimeOrDuration + """ + Not-equals constraint. + """ + neq: DateTimeOrDuration + """ + Not-in-array constraint. + """ + nin: [DateTimeOrDuration!] + """ + Null constraint. Matches any non-null values if the given value is false, otherwise it matches null values. + """ + null: Boolean +} + +""" +Document content filtering options. +""" +input NullableDocumentContentFilter { + """ + Compound filters, all of which need to be matched by the user. + """ + and: [NullableDocumentContentFilter!] + """ + Comparator for the document content. + """ + content: NullableStringComparator + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Filters that the document content document must satisfy. + """ + document: DocumentFilter + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Filters that the document content initiative must satisfy. + """ + initiative: InitiativeFilter + """ + Filters that the document content issue must satisfy. + """ + issue: IssueFilter + """ + Filter based on the existence of the relation. + """ + null: Boolean + """ + Compound filters, one of which need to be matched by the user. + """ + or: [NullableDocumentContentFilter!] + """ + Filters that the document content project must satisfy. + """ + project: ProjectFilter + """ + Filters that the document content project milestone must satisfy. + """ + projectMilestone: ProjectMilestoneFilter + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +Nullable comparator for optional durations. +""" +input NullableDurationComparator { + """ + Equals constraint. + """ + eq: Duration + """ + Greater-than constraint. Matches any values that are greater than the given value. + """ + gt: Duration + """ + Greater-than-or-equal constraint. Matches any values that are greater than or equal to the given value. + """ + gte: Duration + """ + In-array constraint. + """ + in: [Duration!] + """ + Less-than constraint. Matches any values that are less than the given value. + """ + lt: Duration + """ + Less-than-or-equal constraint. Matches any values that are less than or equal to the given value. + """ + lte: Duration + """ + Not-equals constraint. + """ + neq: Duration + """ + Not-in-array constraint. + """ + nin: [Duration!] + """ + Null constraint. Matches any non-null values if the given value is false, otherwise it matches null values. + """ + null: Boolean +} + +""" +Initiative filtering options. +""" +input NullableInitiativeFilter { + """ + Comparator for the initiative activity type. + """ + activityType: StringComparator + """ + Filters that the initiative must be an ancestor of. + """ + ancestors: InitiativeCollectionFilter + """ + Compound filters, all of which need to be matched by the initiative. + """ + and: [NullableInitiativeFilter!] + """ + [Internal] Comparator for the initiative canceled at date. + """ + canceledAt: NullableDateComparator + """ + Comparator for the initiative completed at date. + """ + completedAt: NullableDateComparator + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Filters that the initiative creator must satisfy. + """ + creator: NullableUserFilter + """ + [Internal] Comparator for the initiative's custom identifier. + """ + customIdentifier: NullableStringComparator + """ + Comparator for the initiative health: onTrack, atRisk, offTrack + """ + health: StringComparator + """ + Comparator for the initiative health (with age): onTrack, atRisk, offTrack, outdated, noUpdate + """ + healthWithAge: StringComparator + """ + Comparator for the identifier. + """ + id: EntityIdentifierIDComparator + """ + Filters that the initiative updates must satisfy. + """ + initiativeUpdates: InitiativeUpdatesCollectionFilter + """ + Filters that the initiative labels must satisfy. + """ + labels: InitiativeLabelCollectionFilter + """ + Filters that the initiative lead team must satisfy. + """ + leadTeam: NullableTeamFilter + """ + Comparator for the initiative name. + """ + name: StringComparator + """ + Filter based on the existence of the relation. + """ + null: Boolean + """ + Compound filters, one of which need to be matched by the initiative. + """ + or: [NullableInitiativeFilter!] + """ + Filters that the initiative owner must satisfy. + """ + owner: NullableUserFilter + """ + Comparator for the initiative priority. + """ + priority: NullableNumberComparator + """ + Filters that the initiative projects must satisfy. + """ + projects: ProjectCollectionFilter + """ + Comparator for the initiative slug ID. + """ + slugId: StringComparator + """ + Comparator for the initiative started at date. + """ + startedAt: NullableDateComparator + """ + Comparator for the initiative status: Proposed, Planned, Active, Completed, Canceled + """ + status: StringComparator + """ + Comparator for the initiative target date. + """ + targetDate: NullableDateComparator + """ + Filters that the initiative teams must satisfy. + """ + teams: TeamCollectionFilter + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +Nullable initiative update filtering options. +""" +input NullableInitiativeUpdateFilter { + """ + Compound filters, all of which need to be matched by the initiative update. + """ + and: [NullableInitiativeUpdateFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Filters that the initiative update initiative must satisfy. + """ + initiative: InitiativeFilter + """ + Filter based on the existence of the relation. + """ + null: Boolean + """ + Compound filters, one of which need to be matched by the initiative update. + """ + or: [NullableInitiativeUpdateFilter!] + """ + Filters that the initiative updates reactions must satisfy. + """ + reactions: ReactionCollectionFilter + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator + """ + Filters that the initiative update creator must satisfy. + """ + user: UserFilter +} + +""" +Issue filtering options. +""" +input NullableIssueFilter { + """ + [Internal] Comparator for the issue's accumulatedStateUpdatedAt date. + """ + accumulatedStateUpdatedAt: NullableDateComparator + """ + Filters that the issue's activities must satisfy. + """ + activity: ActivityCollectionFilter + """ + Comparator for the issues added to cycle at date. + """ + addedToCycleAt: NullableDateComparator + """ + Comparator for the period when issue was added to a cycle. + """ + addedToCyclePeriod: CyclePeriodComparator + """ + [Internal] Age (created -> now) comparator, defined if the issue is still open. + """ + ageTime: NullableDurationComparator + """ + Compound filters, all of which need to be matched by the issue. + """ + and: [NullableIssueFilter!] + """ + Comparator for the issues archived at date. + """ + archivedAt: NullableDateComparator + """ + Filters that the issues assignee must satisfy. + """ + assignee: NullableUserFilter + """ + Filters that the issues attachments must satisfy. + """ + attachments: AttachmentCollectionFilter + """ + Comparator for the issues auto archived at date. + """ + autoArchivedAt: NullableDateComparator + """ + Comparator for the issues auto closed at date. + """ + autoClosedAt: NullableDateComparator + """ + Comparator for the issues canceled at date. + """ + canceledAt: NullableDateComparator + """ + Filters that the child issues must satisfy. + """ + children: IssueCollectionFilter + """ + Filters that the issues comments must satisfy. + """ + comments: CommentCollectionFilter + """ + Comparator for the issues completed at date. + """ + completedAt: NullableDateComparator + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Filters that the issues creator must satisfy. + """ + creator: NullableUserFilter + """ + Count of customers + """ + customerCount: NumberComparator + """ + Count of important customers + """ + customerImportantCount: NumberComparator + """ + Filters that the issues cycle must satisfy. + """ + cycle: NullableCycleFilter + """ + [Internal] Cycle time (started -> completed) comparator. + """ + cycleTime: NullableDurationComparator + """ + Filters that the issue's delegated agent must satisfy. + """ + delegate: NullableUserFilter + """ + Comparator for the issues description. + """ + description: NullableStringComparator + """ + Comparator for the issues due date. + """ + dueDate: NullableTimelessDateComparator + """ + Comparator for the issues estimate. + """ + estimate: EstimateComparator + """ + [Internal] Comparator for filtering issues bucketed as having active agent sessions, no closed agent pull requests, and no merged agent pull requests. + """ + hasActiveAgentSessions: RelationExistsComparator + """ + Comparator for filtering issues which are blocked. + """ + hasBlockedByRelations: RelationExistsComparator + """ + Comparator for filtering issues which are blocking. + """ + hasBlockingRelations: RelationExistsComparator + """ + [Internal] Comparator for filtering issues bucketed as having all agent sessions dismissed or closed, and no merged agent pull requests. + """ + hasDismissedAgentSessions: RelationExistsComparator + """ + Comparator for filtering issues which are duplicates. + """ + hasDuplicateRelations: RelationExistsComparator + """ + [Internal] Comparator for filtering issues bucketed as having an errored agent session, no active sessions, and no merged agent pull requests. + """ + hasErroredAgentSessions: RelationExistsComparator + """ + [Internal] Comparator for filtering issues which have agent-session-linked pull requests that were merged. + """ + hasMergedAgentPullRequests: RelationExistsComparator + """ + Comparator for filtering issues with relations. + """ + hasRelatedRelations: RelationExistsComparator + """ + Comparator for filtering issues which have been shared with users outside of the team. + """ + hasSharedUsers: RelationExistsComparator + """ + [Internal] Comparator for filtering issues which have suggested assignees. + """ + hasSuggestedAssignees: RelationExistsComparator + """ + [Internal] Comparator for filtering issues which have suggested labels. + """ + hasSuggestedLabels: RelationExistsComparator + """ + [Internal] Comparator for filtering issues which have suggested projects. + """ + hasSuggestedProjects: RelationExistsComparator + """ + [Internal] Comparator for filtering issues which have suggested related issues. + """ + hasSuggestedRelatedIssues: RelationExistsComparator + """ + [Internal] Comparator for filtering issues which have suggested similar issues. + """ + hasSuggestedSimilarIssues: RelationExistsComparator + """ + [Internal] Comparator for filtering issues which have suggested teams. + """ + hasSuggestedTeams: RelationExistsComparator + """ + Comparator for the identifier. + """ + id: IssueIDComparator + """ + Filters that issue labels must satisfy. + """ + labels: IssueLabelCollectionFilter + """ + Filters that the last applied template must satisfy. + """ + lastAppliedTemplate: NullableTemplateFilter + """ + [Internal] Lead time (created -> completed) comparator. + """ + leadTime: NullableDurationComparator + """ + Filters that the issue's customer needs must satisfy. + """ + needs: CustomerNeedCollectionFilter + """ + Filter based on the existence of the relation. + """ + null: Boolean + """ + Comparator for the issues number. + """ + number: NumberComparator + """ + Compound filters, one of which need to be matched by the issue. + """ + or: [NullableIssueFilter!] + """ + Filters that the issue parent must satisfy. + """ + parent: NullableIssueFilter + """ + Comparator for the issues priority. 0 = No priority, 1 = Urgent, 2 = High, 3 = Medium, 4 = Low. + """ + priority: NullableNumberComparator + """ + Filters that the issues project must satisfy. + """ + project: NullableProjectFilter + """ + Filters that the issues project milestone must satisfy. + """ + projectMilestone: NullableProjectMilestoneFilter + """ + Filters that the issues reactions must satisfy. + """ + reactions: ReactionCollectionFilter + """ + [ALPHA] Filters that the recurring issue template must satisfy. + """ + recurringIssueTemplate: NullableTemplateFilter + """ + Filters that the issue's releases must satisfy. + """ + releases: ReleaseCollectionFilter + """ + [Internal] Comparator for the issues content. + """ + searchableContent: ContentComparator + """ + Filters that users the issue has been shared with must satisfy. + """ + sharedWith: UserCollectionFilter + """ + Comparator for the issue's SLA breach date. + """ + slaBreachesAt: NullableDateComparator + """ + Comparator for the issues sla status. + """ + slaStatus: SlaStatusComparator + """ + Filters that the issues snoozer must satisfy. + """ + snoozedBy: NullableUserFilter + """ + Comparator for the issues snoozed until date. + """ + snoozedUntilAt: NullableDateComparator + """ + Filters that the source must satisfy. + """ + sourceMetadata: SourceMetadataComparator + """ + Comparator for the issues started at date. + """ + startedAt: NullableDateComparator + """ + Filters that the issues state must satisfy. + """ + state: WorkflowStateFilter + """ + Filters that issue subscribers must satisfy. + """ + subscribers: UserCollectionFilter + """ + [Internal] Filters that the issue's suggestions must satisfy. + """ + suggestions: IssueSuggestionCollectionFilter + """ + Filters that the issues team must satisfy. + """ + team: TeamFilter + """ + Comparator for the issues title. + """ + title: StringComparator + """ + [Internal] Triage time (entered triaged -> triaged) comparator. + """ + triageTime: NullableDurationComparator + """ + Comparator for the issues triaged at date. + """ + triagedAt: NullableDateComparator + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +Comparator for optional numbers. +""" +input NullableNumberComparator { + """ + Equals constraint. + """ + eq: Float + """ + Greater-than constraint. Matches any values that are greater than the given value. + """ + gt: Float + """ + Greater-than-or-equal constraint. Matches any values that are greater than or equal to the given value. + """ + gte: Float + """ + In-array constraint. + """ + in: [Float!] + """ + Less-than constraint. Matches any values that are less than the given value. + """ + lt: Float + """ + Less-than-or-equal constraint. Matches any values that are less than or equal to the given value. + """ + lte: Float + """ + Not-equals constraint. + """ + neq: Float + """ + Not-in-array constraint. + """ + nin: [Float!] + """ + Null constraint. Matches any non-null values if the given value is false, otherwise it matches null values. + """ + null: Boolean +} + +""" +Project filtering options. +""" +input NullableProjectFilter { + """ + Filters that the project's team must satisfy. + """ + accessibleTeams: TeamCollectionFilter + """ + [ALPHA] Comparator for the project activity type: buzzin, active, some, none + """ + activityType: StringComparator + """ + Compound filters, all of which need to be matched by the project. + """ + and: [NullableProjectFilter!] + """ + Comparator for the project cancelation date. + """ + canceledAt: NullableDateComparator + """ + Comparator for the project completion date. + """ + completedAt: NullableDateComparator + """ + Filters that the project's completed milestones must satisfy. + """ + completedProjectMilestones: ProjectMilestoneCollectionFilter + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Filters that the projects creator must satisfy. + """ + creator: UserFilter + """ + [Internal] Comparator for the project's custom identifier. + """ + customIdentifier: NullableStringComparator + """ + Count of customers + """ + customerCount: NumberComparator + """ + Count of important customers + """ + customerImportantCount: NumberComparator + """ + Comparator for filtering projects which are blocked. + """ + hasBlockedByRelations: RelationExistsComparator + """ + Comparator for filtering projects which are blocking. + """ + hasBlockingRelations: RelationExistsComparator + """ + [Deprecated] Comparator for filtering projects which this is depended on by. + """ + hasDependedOnByRelations: RelationExistsComparator + """ + [Deprecated]Comparator for filtering projects which this depends on. + """ + hasDependsOnRelations: RelationExistsComparator + """ + Comparator for filtering projects with relations. + """ + hasRelatedRelations: RelationExistsComparator + """ + Comparator for filtering projects with violated dependencies. + """ + hasViolatedRelations: RelationExistsComparator + """ + Comparator for the project health: onTrack, atRisk, offTrack + """ + health: StringComparator + """ + Comparator for the project health (with age): onTrack, atRisk, offTrack, outdated, noUpdate + """ + healthWithAge: StringComparator + """ + Comparator for the identifier. + """ + id: EntityIdentifierIDComparator + """ + Filters that the projects initiatives must satisfy. + """ + initiatives: InitiativeCollectionFilter + """ + Filters that the projects issues must satisfy. + """ + issues: IssueCollectionFilter + """ + Filters that project labels must satisfy. + """ + labels: ProjectLabelCollectionFilter + """ + Filters that the last applied template must satisfy. + """ + lastAppliedTemplate: NullableTemplateFilter + """ + Filters that the projects lead must satisfy. + """ + lead: NullableUserFilter + """ + [ALPHA] Filters that the project's lead team must satisfy. + """ + leadTeam: NullableTeamFilter + """ + Filters that the projects members must satisfy. + """ + members: UserCollectionFilter + """ + Comparator for the project name. + """ + name: StringComparator + """ + Filters that the project's customer needs must satisfy. + """ + needs: CustomerNeedCollectionFilter + """ + Filters that the project's next milestone must satisfy. + """ + nextProjectMilestone: ProjectMilestoneFilter + """ + Filter based on the existence of the relation. + """ + null: Boolean + """ + Compound filters, one of which need to be matched by the project. + """ + or: [NullableProjectFilter!] + """ + Comparator for the project priority. + """ + priority: NullableNumberComparator + """ + Filters that the project's milestones must satisfy. + """ + projectMilestones: ProjectMilestoneCollectionFilter + """ + Comparator for the project updates. + """ + projectUpdates: ProjectUpdatesCollectionFilter + """ + Filters that the projects roadmaps must satisfy. + """ + roadmaps: RoadmapCollectionFilter + """ + [Internal] Comparator for the project's content. + """ + searchableContent: ContentComparator + """ + Comparator for the project slug ID. + """ + slugId: StringComparator + """ + Comparator for the project start date. + """ + startDate: NullableDateComparator + """ + Comparator for the project started date (when it was moved to an "In Progress" status). + """ + startedAt: NullableDateComparator + """ + [DEPRECATED] Comparator for the project state. + """ + state: StringComparator + """ + Filters that the project status must satisfy. + """ + status: ProjectStatusFilter + """ + Comparator for the project target date. + """ + targetDate: NullableDateComparator + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +Project milestone filtering options. +""" +input NullableProjectMilestoneFilter { + """ + Compound filters, all of which need to be matched by the project milestone. + """ + and: [NullableProjectMilestoneFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Comparator for the project milestone name. + """ + name: NullableStringComparator + """ + Filter based on the existence of the relation. + """ + null: Boolean + """ + Compound filters, one of which need to be matched by the project milestone. + """ + or: [NullableProjectMilestoneFilter!] + """ + Filters that the project milestone's project must satisfy. + """ + project: NullableProjectFilter + """ + Comparator for the project milestone target date. + """ + targetDate: NullableDateComparator + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +Nullable project update filtering options. +""" +input NullableProjectUpdateFilter { + """ + Compound filters, all of which need to be matched by the project update. + """ + and: [NullableProjectUpdateFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Filter based on the existence of the relation. + """ + null: Boolean + """ + Compound filters, one of which need to be matched by the project update. + """ + or: [NullableProjectUpdateFilter!] + """ + Filters that the project update project must satisfy. + """ + project: ProjectFilter + """ + Filters that the project updates reactions must satisfy. + """ + reactions: ReactionCollectionFilter + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator + """ + Filters that the project update creator must satisfy. + """ + user: UserFilter +} + +""" +Comparator for optional strings. +""" +input NullableStringComparator { + """ + Contains constraint. Matches any values that contain the given string. + """ + contains: String + """ + Contains case insensitive constraint. Matches any values that contain the given string case insensitive. + """ + containsIgnoreCase: String + """ + Contains case and accent insensitive constraint. Matches any values that contain the given string case and accent insensitive. + """ + containsIgnoreCaseAndAccent: String + """ + Ends with constraint. Matches any values that end with the given string. + """ + endsWith: String + """ + Equals constraint. + """ + eq: String + """ + Equals case insensitive. Matches any values that matches the given string case insensitive. + """ + eqIgnoreCase: String + """ + In-array constraint. + """ + in: [String!] + """ + Not-equals constraint. + """ + neq: String + """ + Not-equals case insensitive. Matches any values that don't match the given string case insensitive. + """ + neqIgnoreCase: String + """ + Not-in-array constraint. + """ + nin: [String!] + """ + Doesn't contain constraint. Matches any values that don't contain the given string. + """ + notContains: String + """ + Doesn't contain case insensitive constraint. Matches any values that don't contain the given string case insensitive. + """ + notContainsIgnoreCase: String + """ + Doesn't end with constraint. Matches any values that don't end with the given string. + """ + notEndsWith: String + """ + Doesn't start with constraint. Matches any values that don't start with the given string. + """ + notStartsWith: String + """ + Null constraint. Matches any non-null values if the given value is false, otherwise it matches null values. + """ + null: Boolean + """ + Starts with constraint. Matches any values that start with the given string. + """ + startsWith: String + """ + Starts with case insensitive constraint. Matches any values that start with the given string. + """ + startsWithIgnoreCase: String +} + +""" +Team filtering options. +""" +input NullableTeamFilter { + """ + Filters that the team's ancestors must satisfy. + """ + ancestors: TeamCollectionFilter + """ + Compound filters, all of which need to be matched by the team. + """ + and: [NullableTeamFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for the team description. + """ + description: NullableStringComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Filters that the team's issues must satisfy. + """ + issues: IssueCollectionFilter + """ + Comparator for the team key. + """ + key: StringComparator + """ + Filters that the team's members must satisfy. + """ + members: UserCollectionFilter + """ + Comparator for the team name. + """ + name: StringComparator + """ + Filter based on the existence of the relation. + """ + null: Boolean + """ + Compound filters, one of which need to be matched by the team. + """ + or: [NullableTeamFilter!] + """ + Filters that the team's owners must satisfy. + """ + owners: UserCollectionFilter + """ + Filters that the team's parent must satisfy. + """ + parent: NullableTeamFilter + """ + [DEPRECATED] Comparator for the team privacy. + """ + private: BooleanComparator + """ + Filters that the team's release pipelines must satisfy. + """ + releasePipelines: ReleasePipelineCollectionFilter + """ + [Internal] Filters that the private team forming this team's visibility boundary must satisfy. Only relevant for non-public teams. + """ + restrictedBy: NullableTeamFilter + """ + Comparator for the time at which the team was retired. + """ + retiredAt: NullableDateComparator + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator + """ + [Internal] Filters that the team's members must satisfy. Alias of `members` matching the filter shape produced by the app; prefer `members`. + """ + users: UserCollectionFilter + """ + Comparator for the team visibility. + """ + visibility: TeamVisibilityComparator +} + +""" +Template filtering options. +""" +input NullableTemplateFilter { + """ + Compound filters, all of which need to be matched by the template. + """ + and: [NullableTemplateFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Comparator for the inherited template's ID. + """ + inheritedFromId: IDComparator + """ + Comparator for the template's name. + """ + name: StringComparator + """ + Filter based on the existence of the relation. + """ + null: Boolean + """ + Compound filters, one of which need to be matched by the template. + """ + or: [NullableTemplateFilter!] + """ + Filters that the template's team must satisfy. + """ + team: NullableTeamFilter + """ + Comparator for the template's type. + """ + type: StringComparator + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +Comparator for optional timeless dates. +""" +input NullableTimelessDateComparator { + """ + Equals constraint. + """ + eq: TimelessDateOrDuration + """ + Greater-than constraint. Matches any values that are greater than the given value. + """ + gt: TimelessDateOrDuration + """ + Greater-than-or-equal constraint. Matches any values that are greater than or equal to the given value. + """ + gte: TimelessDateOrDuration + """ + In-array constraint. + """ + in: [TimelessDateOrDuration!] + """ + Less-than constraint. Matches any values that are less than the given value. + """ + lt: TimelessDateOrDuration + """ + Less-than-or-equal constraint. Matches any values that are less than or equal to the given value. + """ + lte: TimelessDateOrDuration + """ + Not-equals constraint. + """ + neq: TimelessDateOrDuration + """ + Not-in-array constraint. + """ + nin: [TimelessDateOrDuration!] + """ + Null constraint. Matches any non-null values if the given value is false, otherwise it matches null values. + """ + null: Boolean +} + +""" +User filtering options. +""" +input NullableUserFilter { + """ + Comparator for the user's activity status. + """ + active: BooleanComparator + """ + Comparator for the user's admin status. + """ + admin: BooleanComparator + """ + Compound filters, all of which need to be matched by the user. + """ + and: [NullableUserFilter!] + """ + Comparator for the user's app status. + """ + app: BooleanComparator + """ + Filters that the users assigned issues must satisfy. + """ + assignedIssues: IssueCollectionFilter + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for the user's display name. + """ + displayName: StringComparator + """ + Comparator for the user's email. + """ + email: StringComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Comparator for the user's invited status. + """ + invited: BooleanComparator + """ + Comparator for the user's invited status. + """ + isInvited: BooleanComparator + """ + Filter based on the currently authenticated user. Set to true to filter for the authenticated user, false for any other user. + """ + isMe: BooleanComparator + """ + Comparator for the user's name. + """ + name: StringComparator + """ + Filter based on the existence of the relation. + """ + null: Boolean + """ + Compound filters, one of which need to be matched by the user. + """ + or: [NullableUserFilter!] + """ + Comparator for the user's owner status. + """ + owner: BooleanComparator + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +Comparator for numbers. +""" +input NumberComparator { + """ + Equals constraint. + """ + eq: Float + """ + Greater-than constraint. Matches any values that are greater than the given value. + """ + gt: Float + """ + Greater-than-or-equal constraint. Matches any values that are greater than or equal to the given value. + """ + gte: Float + """ + In-array constraint. + """ + in: [Float!] + """ + Less-than constraint. Matches any values that are less than the given value. + """ + lt: Float + """ + Less-than-or-equal constraint. Matches any values that are less than or equal to the given value. + """ + lte: Float + """ + Not-equals constraint. + """ + neq: Float + """ + Not-in-array constraint. + """ + nin: [Float!] +} + +""" +Payload for OAuth app webhook events. +""" +type OAuthAppWebhookPayload { + """ + The type of action that triggered the webhook. + """ + action: String! + """ + The time the payload was created. + """ + createdAt: DateTime! + """ + Id of the OAuth client that was revoked. + """ + oauthClientId: String! + """ + ID of the organization for which the webhook belongs to. + """ + organizationId: String! + """ + The type of resource. + """ + type: String! + """ + The ID of the webhook that sent this event. + """ + webhookId: String! + """ + Unix timestamp in milliseconds when the webhook was sent. + """ + webhookTimestamp: Float! +} + +""" +An OAuth application that can be managed by the calling OAuth application. +""" +type OAuthApplication { + """ + The client ID used during OAuth authorization flows. + """ + clientId: String! + """ + The time at which the OAuth application was created. + """ + createdAt: DateTime! + """ + User-facing description of the OAuth application. Null if not set. + """ + description: String + """ + Name of the developer or company that built the OAuth application. + """ + developer: String! + """ + URL of the developer's website, homepage, or documentation. + """ + developerUrl: String! + """ + Distribution setting for the OAuth application. Private applications are only installable by the owning workspace. + """ + distribution: OAuthApplicationDistribution! + """ + OAuth grant types supported by this application. authorization_code is always included. + """ + grantTypes: [OAuthApplicationGrantType!]! + """ + The unique identifier of the OAuth application. + """ + id: String! + """ + URL of the OAuth application's icon. Null if not set. + """ + imageUrl: String + """ + The human-readable name of the OAuth application. + """ + name: String! + """ + Allowed redirect URIs for OAuth authorization flows. + """ + redirectUris: [String!]! + """ + The time at which the OAuth application was last updated. + """ + updatedAt: DateTime! + """ + Whether webhook delivery is enabled for this OAuth application. + """ + webhookEnabled: Boolean! + """ + Resource types the OAuth application's webhooks subscribe to. + """ + webhookResourceTypes: [WebhookResourceType!]! + """ + Webhook URL used for delivering webhook payloads. Null if not set. + """ + webhookUrl: String +} + +""" +The result of archiving an OAuth application. +""" +type OAuthApplicationArchivePayload { + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +The authenticated OAuth application's trusted-source status for Coding Sessions in the token's workspace. Combines workspace availability with the application's trust setting. This status does not grant permissions or account for team and repository access. +""" +type OAuthApplicationCodingSessionTrustedSource { + """ + The first reason that enabled is false, or null when enabled is true. Checks run in this order: workspace availability, trusted external source availability, then application approval. + """ + disabledReason: CodingSessionsDisabledReason + """ + Whether Coding Sessions are available and enabled in the workspace, trusted external sources are available, and the authenticated OAuth application is trusted. A true value does not guarantee that a specific session can start. + """ + enabled: Boolean! +} + +""" +Input for creating an OAuth application through the public API. +""" +input OAuthApplicationCreateInput { + """ + User-facing description of the OAuth application. + """ + description: String + """ + Name of the developer or company that built the OAuth application. + """ + developer: String! + """ + URL of the developer's website, homepage, or documentation. + """ + developerUrl: String + """ + OAuth grant capabilities the app may use. authorization_code is required. Defaults to authorization_code. + """ + grantTypes: [OAuthApplicationGrantType!] + """ + Optional client-supplied idempotency key. Reusing the same key with the same managing OAuth application returns the existing OAuth application instead of creating a duplicate. The key does not apply to archived applications. + """ + idempotencyKey: String + """ + URL of the OAuth application's icon. + """ + imageUrl: String + """ + The OAuth application's name. + """ + name: String! + """ + Allowed redirect URIs for OAuth authorization flows. + """ + redirectUris: [String!]! + """ + Resource types the OAuth application's webhooks subscribe to. + """ + webhookResourceTypes: [WebhookResourceType!] + """ + Webhook URL used for delivering webhook payloads. + """ + webhookUrl: String +} + +""" +The result of creating an OAuth application. +""" +type OAuthApplicationCreatePayload { + """ + The OAuth application that was created or updated. + """ + application: OAuthApplication! + """ + The client secret. Store this value securely because it cannot be retrieved later. Null when returning an existing OAuth application for an idempotency key. + """ + clientSecret: String + """ + Whether the operation was successful. + """ + success: Boolean! + """ + The webhook signing secret. Null if the OAuth application does not have a webhook configured or an existing OAuth application is returned for an idempotency key. + """ + webhookSecret: String +} + +""" +Distribution setting for an OAuth application. +""" +enum OAuthApplicationDistribution { + private + public +} + +""" +OAuth grant type supported by an OAuth application. +""" +enum OAuthApplicationGrantType { + authorization_code + client_credentials +} + +""" +The result of an OAuth application mutation. +""" +type OAuthApplicationPayload { + """ + The OAuth application that was created or updated. + """ + application: OAuthApplication! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +The result of rotating an OAuth application's client secret. +""" +type OAuthApplicationRotateSecretPayload { + """ + The new client secret. Store this value securely because it cannot be retrieved later. + """ + clientSecret: String! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +The result of rotating an OAuth application's webhook signing secret. +""" +type OAuthApplicationRotateWebhookSecretPayload { + """ + Whether the operation was successful. + """ + success: Boolean! + """ + The new webhook signing secret. + """ + webhookSecret: String! +} + +""" +Input for updating an OAuth application through the public API. +""" +input OAuthApplicationUpdateInput { + """ + User-facing description of the OAuth application. + """ + description: String + """ + Name of the developer or company that built the OAuth application. + """ + developer: String + """ + URL of the developer's website, homepage, or documentation. + """ + developerUrl: String + """ + OAuth grant capabilities the app may use. authorization_code is required. Omit to keep the existing grant types. + """ + grantTypes: [OAuthApplicationGrantType!] + """ + URL of the OAuth application's icon. + """ + imageUrl: String + """ + The OAuth application's name. + """ + name: String + """ + Allowed redirect URIs for OAuth authorization flows. + """ + redirectUris: [String!] + """ + Whether webhook delivery is enabled for this OAuth application. + """ + webhookEnabled: Boolean + """ + Resource types the OAuth application's webhooks subscribe to. + """ + webhookResourceTypes: [WebhookResourceType!] + """ + Webhook URL used for delivering webhook payloads. + """ + webhookUrl: String +} + +""" +Payload for OAuth authorization webhook events. +""" +type OAuthAuthorizationWebhookPayload { + """ + The type of action that triggered the webhook. + """ + action: String! + """ + The number of currently active tokens for the user for this client. + """ + activeTokensForUser: Float! + """ + The time the payload was created. + """ + createdAt: DateTime! + """ + Details of the OAuth client the authorization belongs to. + """ + oauthClient: OauthClientChildWebhookPayload! + """ + ID of the OAuth client the authorization belongs to. + """ + oauthClientId: String! + """ + ID of the organization for which the webhook belongs to. + """ + organizationId: String! + """ + The type of resource. + """ + type: String! + """ + Details of the user that the authorization belongs to. + """ + user: UserChildWebhookPayload! + """ + ID of the user that the authorization belongs to. + """ + userId: String! + """ + The ID of the webhook that sent this event. + """ + webhookId: String! + """ + Unix timestamp in milliseconds when the webhook was sent. + """ + webhookTimestamp: Float! +} + +""" +The different requests statuses possible for an OAuth client approval request. +""" +enum OAuthClientApprovalStatus { + approved + denied + requested +} + +""" +OAuth client actor payload for webhooks. +""" +type OauthClientActorWebhookPayload { + """ + The ID of the OAuth client. + """ + id: String! + """ + The name of the OAuth client. + """ + name: String! + """ + The type of actor. + """ + type: String! +} + +""" +A request to install an OAuth client application on a workspace, along with the admin's approval or denial response. When a user attempts to install an OAuth application that requires admin approval, an approval record is created. A workspace admin can then approve or deny the request, optionally providing a reason. The record also tracks any newly requested scopes that were added after the initial approval. +""" +type OauthClientApproval implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + An optional explanation from the admin for why the installation request was denied. + """ + denyReason: String + """ + The unique identifier of the entity. + """ + id: ID! + """ + Additional OAuth scopes requested after the initial approval. These scopes are not yet approved and require a separate admin decision. Null if no additional scopes have been requested. These scopes will never overlap with the already-approved scopes. + """ + newlyRequestedScopes: [String!] + """ + The identifier of the OAuth client application being requested for installation in this workspace. + """ + oauthClientId: String! + """ + An optional message from the requester explaining why they want to install the OAuth application. + """ + requestReason: String + """ + The identifier of the user who initiated the request to install the OAuth client application. + """ + requesterId: String! + """ + The identifier of the workspace admin who approved or denied the installation request. Null if the request has not yet been responded to. + """ + responderId: String + """ + The OAuth scopes that the application has been approved to use within this workspace (e.g., 'read', 'write', 'issues:create'). + """ + scopes: [String!]! + """ + The current status of the approval request: requested (pending admin review), approved, or denied. + """ + status: OAuthClientApprovalStatus! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +""" +A notification related to an OAuth client approval request, sent to workspace admins when an application requests access. +""" +type OauthClientApprovalNotification implements Entity & Node & Notification { + """ + The user that caused the notification. Null if the notification was triggered by a non-user actor such as an integration, external user, or system event. + """ + actor: User + """ + [Internal] Notification actor initials if avatar is not available. + """ + actorAvatarColor: String! + """ + [Internal] Notification avatar URL. + """ + actorAvatarUrl: String + """ + [Internal] Whether the notification's user actor is deactivated in the workspace. + """ + actorInactive: Boolean! + """ + [Internal] Notification actor initials if avatar is not available. + """ + actorInitials: String + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The bot that caused the notification. + """ + botActor: ActorBot + """ + The category of the notification. + """ + category: NotificationCategory! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The time at which an email reminder for this notification was sent to the user. Null if no email reminder has been sent. + """ + emailedAt: DateTime + """ + The external user that caused the notification. Populated when the notification was triggered by an external user (e.g., a commenter from a connected integration like Slack or GitHub) rather than a Linear workspace member. + """ + externalUserActor: ExternalUser + """ + [Internal] Notifications with the same grouping key will be grouped together in the UI. + """ + groupingKey: String! + """ + [Internal] Priority of the notification with the same grouping key. Higher number means higher priority. If priority is the same, notifications should be sorted by `createdAt`. + """ + groupingPriority: Float! + """ + The unique identifier of the entity. + """ + id: ID! + """ + [Internal] Inbox URL for the notification. + """ + inboxUrl: String! + """ + [Internal] Initiative update health for new updates. + """ + initiativeUpdateHealth: String + """ + [Internal] If notification actor was Linear. + """ + isLinearActor: Boolean! + """ + [Internal] Issue's status type for issue notifications. + """ + issueStatusType: String + """ + The OAuth client approval request related to the notification. + """ + oauthClientApproval: OauthClientApproval! + """ + Related OAuth client approval request ID. + """ + oauthClientApprovalId: String! + """ + [Internal] Project update health for new updates. + """ + projectUpdateHealth: String + """ + The time at which the user marked the notification as read. Null if the notification is unread. + """ + readAt: DateTime + """ + The time until which a notification is snoozed. After this time, the notification reappears in the user's inbox. Null if the notification is not currently snoozed. + """ + snoozedUntilAt: DateTime + """ + [Internal] Notification subtitle. + """ + subtitle: String! + """ + [Internal] Notification title. + """ + title: String! + """ + Notification type. Determines the kind of event that triggered this notification and which associated entity fields will be populated. + """ + type: String! + """ + The time at which a notification was unsnoozed. Null if the notification has not been unsnoozed. + """ + unsnoozedAt: DateTime + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + [Internal] URL to the target of the notification. + """ + url: String! + """ + The recipient user of this notification. + """ + user: User! +} + +""" +Certain properties of an OAuth client. +""" +type OauthClientChildWebhookPayload { + """ + The ID of the OAuth client. + """ + id: String! + """ + The name of the OAuth client. + """ + name: String! +} + +input OnboardingCustomerSurvey { + companyRole: String + companySize: String +} + +input OpsgenieInput { + """ + The date when the Opsgenie API failed with an unauthorized error. + """ + apiFailedWithUnauthorizedErrorAt: DateTime +} + +""" +A workspace (referred to as Organization in the API). Workspaces are the root-level container for all teams, users, projects, issues, and settings. Every user belongs to at least one workspace, and all data is scoped within a workspace boundary. +""" +type Organization implements Node { + """ + [INTERNAL] Whether the workspace has enabled agent automation. + """ + agentAutomationEnabled: Boolean! + """ + [INTERNAL] Whether the workspace has enabled the AI add-on (which at this point only includes triage suggestions). + """ + aiAddonEnabled: Boolean! + """ + Whether the workspace has enabled AI discussion summaries for issues. + """ + aiDiscussionSummariesEnabled: Boolean! + """ + [INTERNAL] Configure per-modality AI host providers and model families. + """ + aiProviderConfiguration: JSONObject + """ + [INTERNAL] Whether the workspace has opted in to AI telemetry. + """ + aiTelemetryEnabled: Boolean! + """ + Whether the workspace has enabled resolved thread AI summaries. + """ + aiThreadSummariesEnabled: Boolean! + """ + [DEPRECATED] Whether member users are allowed to send invites. + """ + allowMembersToInvite: Boolean + @deprecated(reason: "Use `securitySettings.invitationsRole` instead.") + """ + [INTERNAL] Permitted AI providers. + """ + allowedAiProviders: [String!]! @deprecated(reason: "Use aiProviderConfiguration instead.") + """ + Allowed authentication providers, empty array means all are allowed. + """ + allowedAuthServices: [String!]! + @deprecated(reason: "Use authSettings.allowedAuthServices instead.") + """ + Allowed file upload content types + """ + allowedFileUploadContentTypes: [String!] + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + Authentication settings for the workspace, including allowed auth providers, bypass rules, and organization visibility during signup. + """ + authSettings: JSONObject! + """ + [INTERNAL] Whether code intelligence is enabled for the workspace. + """ + codeIntelligenceEnabled: Boolean! + """ + [INTERNAL] GitHub repository in owner/repo format for code intelligence. + """ + codeIntelligenceRepository: String + """ + [INTERNAL] Whether the workspace has enabled Coding Sessions. + """ + codingAgentEnabled: Boolean! + """ + [Internal] Settings for Coding Sessions features. OAuth responses omit the trusted external source list. + """ + codingAgentSettings: JSONObject! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + Approximate total number of issues created in the workspace, including archived ones. This count is cached and may not reflect the exact real-time count. + """ + createdIssueCount: Int! + """ + The number of active (non-archived) customers tracked in the workspace. + """ + customerCount: Int! + """ + Configuration settings for the Customers feature, including revenue currency and other customer tracking preferences. + """ + customersConfiguration: JSONObject! + """ + Whether the Customers feature is enabled and accessible for the workspace based on the current plan. + """ + customersEnabled: Boolean! + """ + Default schedule for how often feed summaries are generated. + """ + defaultFeedSummarySchedule: FeedSummarySchedule + """ + The default home view for members of the workspace who have not chosen their own default. + """ + defaultHomeView: String + """ + The id of the specific initiative, project, view, dashboard, or page tab used as the default home view. The type of entity is given by defaultHomeView. + """ + defaultHomeViewTargetId: String + """ + The time at which deletion of the workspace was requested. Null if no deletion has been requested. + """ + deletionRequestedAt: DateTime + """ + [Internal] Facets associated with the workspace, used for configuring custom views and filters. + """ + facets: [Facet!]! + """ + Whether the activity feed feature is enabled for the workspace. + """ + feedEnabled: Boolean! + """ + The zero-indexed month at which the fiscal year starts (0 = January, 11 = December). Defaults to 0 (January). + """ + fiscalYearStartMonth: Float! + """ + [INTERNAL] Whether the workspace has enabled generated updates. + """ + generatedUpdatesEnabled: Boolean! + """ + The template format for Git branch names created from issues. Supports template variables like {issueIdentifier} and {issueTitle}. If null, the default formatting will be used. + """ + gitBranchFormat: String + """ + Whether issue descriptions should be included in the Git integration linkback messages posted to pull requests. + """ + gitLinkbackDescriptionsEnabled: Boolean! + """ + Whether the Git integration linkback messages should be posted as comments on pull requests in private repositories. + """ + gitLinkbackMessagesEnabled: Boolean! + """ + Whether the Git integration linkback messages should be posted as comments on pull requests in public repositories. + """ + gitPublicLinkbackMessagesEnabled: Boolean! + """ + Whether to hide other organizations for new users signing up with email domains claimed by this organization. + """ + hideNonPrimaryOrganizations: Boolean! + @deprecated(reason: "Use authSettings.hideNonPrimaryOrganizations instead.") + """ + Whether HIPAA compliance is enabled for the workspace. When enabled, certain data processing features are restricted to meet compliance requirements. + """ + hipaaComplianceEnabled: Boolean! + """ + The unique identifier of the entity. + """ + id: ID! + """ + The frequency in weeks at which to prompt for initiative updates. When null, initiative update reminders are disabled. Valid values range from 0 to 8. + """ + initiativeUpdateReminderFrequencyInWeeks: Float + """ + The day of the week on which initiative update reminders are sent. + """ + initiativeUpdateRemindersDay: Day! + """ + The hour of the day (0-23) at which initiative update reminders are sent. + """ + initiativeUpdateRemindersHour: Float! + """ + Third-party integrations configured for the workspace (e.g., GitHub, Slack, Figma). + """ + integrations( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): IntegrationConnection! + """ + IP restriction configurations. + """ + ipRestrictions: [OrganizationIpRestriction!] + """ + Workspace-level issue labels (not associated with any specific team). These labels are available across all teams in the workspace. + """ + labels( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned issue labels. + """ + filter: IssueLabelFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): IssueLabelConnection! + """ + [Internal] Whether the workspace has enabled Linear Agent. + """ + linearAgentEnabled: Boolean! + """ + [Internal] Settings for Linear Agent features. + """ + linearAgentSettings: JSONObject! + """ + The URL of the workspace's logo image. Null if no logo has been uploaded. + """ + logoUrl: String + """ + Loops in the workspace that are visible to the requesting user, including workspace and team loops. Includes enabled and disabled loops. + """ + loops( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): WorkflowDefinitionConnection! + """ + [Internal] The teams each managed team feature is limited to, keyed by feature. The workspace's own setting for each feature still applies. + """ + managedTeamFeatures: JSONObject! + """ + The workspace's name. + """ + name: String! + """ + Rolling 30-day total file upload volume for the workspace, measured in megabytes. Used for enforcing upload quotas. + """ + periodUploadVolume: Float! + """ + Previously used URL keys for the workspace. The last 3 are kept and automatically redirected to the current URL key. + """ + previousUrlKeys: [String!]! + """ + Project labels available in the workspace for categorizing projects. + """ + projectLabels( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned project labels. + """ + filter: ProjectLabelFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): ProjectLabelConnection! + """ + The workspace's available project statuses, which define the lifecycle stages for projects. + """ + projectStatuses: [ProjectStatus!]! + """ + The frequency in weeks at which to prompt for project updates. When null, project update reminders are disabled. Valid values range from 0 to 8. + """ + projectUpdateReminderFrequencyInWeeks: Float + """ + The day of the week on which project update reminders are sent. + """ + projectUpdateRemindersDay: Day! + """ + The hour of the day (0-23) at which project update reminders are sent. + """ + projectUpdateRemindersHour: Float! + """ + [DEPRECATED] The frequency at which to prompt for project updates. + """ + projectUpdatesReminderFrequency: ProjectUpdateReminderFrequency! + @deprecated(reason: "Use organization.projectUpdatesReminderFrequencyInWeeks instead") + """ + How Linear suggests and links issues for pull requests that have none linked: 'off', 'suggest', or 'autoOnMerge'. + """ + pullRequestIssueMode: String! + """ + Whether the workspace generates AI Pull Request guides for new pull requests. + """ + pullRequestTourEnabled: Boolean! + """ + The feature release channel the workspace belongs to, which controls access to pre-release features. + """ + releaseChannel: ReleaseChannel! + """ + Whether release management is enabled for the workspace. + """ + releasesEnabled: Boolean! + """ + [Internal] Whether agent invocation is restricted to full workspace members. + """ + restrictAgentInvocationToMembers: Boolean + """ + [DEPRECATED] Whether workspace label creation, update, and deletion is restricted to admins. + """ + restrictLabelManagementToAdmins: Boolean + @deprecated(reason: "Use `securitySettings.labelManagementRole` instead.") + """ + [DEPRECATED] Whether team creation is restricted to admins. + """ + restrictTeamCreationToAdmins: Boolean + @deprecated(reason: "Use `securitySettings.teamCreationRole` instead.") + """ + Whether the roadmap feature is enabled for the workspace. + """ + roadmapEnabled: Boolean! + """ + Whether SAML-based single sign-on authentication is enabled for the workspace. + """ + samlEnabled: Boolean! + """ + [INTERNAL] SAML settings. + """ + samlSettings: JSONObject + """ + Whether SCIM provisioning is enabled for the workspace, allowing automated user and team management from an identity provider. + """ + scimEnabled: Boolean! + """ + [INTERNAL] SCIM settings. + """ + scimSettings: JSONObject + """ + Security settings for the workspace, including role-based restrictions for invitations, team creation, label management, and other sensitive operations. + """ + securitySettings: JSONObject! + """ + [DEPRECATED] Which day count to use for SLA calculations. + """ + slaDayCount: SLADayCountType! @deprecated(reason: "No longer in use") + """ + [Internal] Whether to automatically create a Slack channel when a new project is created. + """ + slackAutoCreateProjectChannel: Boolean! + """ + The Slack integration used for auto-creating project channels. + """ + slackProjectChannelIntegration: Integration + """ + The prefix used for auto-created Slack project channels. + """ + slackProjectChannelPrefix: String! + """ + [Internal] Whether the Slack project channels feature is enabled for the workspace. + """ + slackProjectChannelsEnabled: Boolean! + """ + The workspace's subscription to a paid plan. + """ + subscription: PaidSubscription + """ + Whether the default prompt for copying an issue or opening it in a coding tool includes a suggested Git branch name. + """ + suggestedBranchNameEnabled: Boolean! + """ + [Internal] Workspace restrictions for team permissions. + """ + teamSecuritySettings: JSONObject! + """ + Teams in the workspace. Returns only teams visible to the requesting user (all public teams plus private teams the user is a member of). + """ + teams( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned teams. + """ + filter: TeamFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): TeamConnection! + """ + Workspace-level templates (not associated with any specific team). These templates are available across all teams in the workspace. + """ + templates( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned templates. + """ + filter: NullableTemplateFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): TemplateConnection! + """ + [ALPHA] Theme settings for the workspace. + """ + themeSettings: JSONObject + """ + The time at which the current plan trial will end. Null if the workspace is not in a trial period. + """ + trialEndsAt: DateTime + """ + The time at which the current plan trial started. Null if the workspace is not in a trial period. + """ + trialStartsAt: DateTime + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The workspace's unique URL key, used in URLs to identify the workspace. + """ + urlKey: String! + """ + The number of active (non-deactivated) users in the workspace. + """ + userCount: Int! + """ + Users belonging to the workspace. By default only returns active users; use the includeDisabled argument to include deactivated users. + """ + users( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + Should query return disabled/suspended users (default: false). + """ + includeDisabled: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): UserConnection! + """ + [Internal] The list of working days. Sunday is 0, Monday is 1, etc. + """ + workingDays: [Float!]! +} + +type OrganizationAcceptedOrExpiredInviteDetailsPayload { + """ + The status of the invite. + """ + status: OrganizationInviteStatus! +} + +""" +Input for updating workspace authentication settings. +""" +input OrganizationAuthSettingsInput { + """ + [Internal] The minimum role required for the auth service bypass exemption. + """ + allowedAuthServiceBypassRole: String + """ + Allowed authentication providers, empty array means all are allowed. + """ + allowedAuthServices: [String!] + """ + Whether to disable admin/owner auth service bypass. + """ + disableAuthServiceBypass: Boolean + """ + Whether to hide non-primary workspaces during signup for users with matching email domains. + """ + hideNonPrimaryOrganizations: Boolean +} + +""" +Workspace deletion cancellation response. +""" +type OrganizationCancelDeletePayload { + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +[Internal] Input for updating Coding Sessions settings for the workspace. +""" +input OrganizationCodingAgentSettingsInput { + """ + [Internal] Whether Coding Sessions require uploaded user commit signing keys. + """ + commitSigningEnabled: Boolean + """ + [Internal] The provider-agnostic reasoning effort level used for Coding Sessions. Clamped to the selected model's provider when the session runs. + """ + effort: String + """ + [Internal] The model preference used for Coding Sessions. + """ + model: String + """ + [Internal] Whether new Coding Session sandboxes should use workspace region pinning. + """ + regionPinning: Boolean + """ + [Internal] The default sandbox size used for Coding Sessions. + """ + sandboxSize: String + """ + [Internal] Approve or remove one external source for coding-session delegation. + """ + trustedExternalSourceUpdate: OrganizationCodingAgentTrustedSourceUpdateInput + """ + [Internal] Approval snapshot. Ignored on writes; use trustedExternalSourceUpdate to change approvals. + """ + trustedExternalSources: [String!] +} + +""" +[Internal] An approval change for one external coding-session source. +""" +input OrganizationCodingAgentTrustedSourceUpdateInput { + """ + [Internal] Whether this source may start coding sessions. + """ + allowed: Boolean! + """ + [Internal] The external source whose approval to change. + """ + key: String! +} + +""" +Workspace deletion operation response. +""" +type OrganizationDeletePayload { + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +A verified email domain associated with a workspace. Domains are used for automatic team joining, SSO/SAML authentication, and controlling workspace access. Each domain has an authentication type (general or SAML) and can be verified via email or DNS. +""" +type OrganizationDomain implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The authentication type this domain is used for. 'general' means standard email-based auth, 'saml' means SAML SSO authentication. + """ + authType: OrganizationDomainAuthType! + """ + Whether the domain was claimed by the workspace through DNS TXT record verification. Claimed domains provide stronger ownership proof than email verification and enable additional features like preventing users from creating new workspaces. + """ + claimed: Boolean + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The user who added the domain. + """ + creator: User + """ + Whether users with email addresses from this domain are prevented from creating new workspaces. Can only be set on claimed domains. + """ + disableOrganizationCreation: Boolean + """ + The unique identifier of the entity. + """ + id: ID! + """ + The identity provider the domain belongs to. + """ + identityProvider: IdentityProvider + """ + The domain name (e.g., 'example.com'). + """ + name: String! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The email address used to verify this domain. Null if the domain was verified via DNS or has not been verified. + """ + verificationEmail: String + """ + Whether the domain has been verified via email verification. + """ + verified: Boolean! +} + +""" +What type of auth is the domain used for. +""" +enum OrganizationDomainAuthType { + general + saml +} + +""" +[INTERNAL] Domain claim request response. +""" +type OrganizationDomainClaimPayload { + """ + String to put into DNS for verification. + """ + verificationString: String! +} + +input OrganizationDomainCreateInput { + """ + The authentication type this domain is for. + """ + authType: String = "general" + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + The identity provider to which to add the domain. + """ + identityProviderId: String + """ + The domain name to add. + """ + name: String! + """ + The email address to which to send the verification code. + """ + verificationEmail: String +} + +""" +[INTERNAL] Organization domain operation response. +""" +type OrganizationDomainPayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + The workspace domain that was created or updated. + """ + organizationDomain: OrganizationDomain! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +[INTERNAL] Organization domain operation response. +""" +type OrganizationDomainSimplePayload { + """ + Whether the operation was successful. + """ + success: Boolean! +} + +input OrganizationDomainUpdateInput { + """ + Prevent users with this domain to create new workspaces. Only allowed to set on claimed domains! + """ + disableOrganizationCreation: Boolean +} + +input OrganizationDomainVerificationInput { + """ + The identifier in UUID v4 format of the domain being verified. + """ + organizationDomainId: String! + """ + The verification code sent via email. + """ + verificationCode: String! +} + +""" +Response for checking whether a workspace exists. +""" +type OrganizationExistsPayload { + """ + Whether the organization exists. + """ + exists: Boolean! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +A pending invitation to join the workspace, sent via email. Invites specify the role the invitee will receive and can optionally include team assignments. Invites can expire and must be accepted by the invitee to grant workspace access. +""" +type OrganizationInvite implements Node { + """ + The time at which the invite was accepted by the invitee. Null if the invite is still pending. + """ + acceptedAt: DateTime + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The email address of the person being invited to the workspace. + """ + email: String! + """ + The time at which the invite will expire and can no longer be accepted. Null if the invite does not have an expiration date. + """ + expiresAt: DateTime + """ + Whether the invite was sent to an email address outside the workspace's verified domains. + """ + external: Boolean! + """ + The unique identifier of the entity. + """ + id: ID! + """ + The user who has accepted the invite. Null, if the invite hasn't been accepted. + """ + invitee: User + """ + The user who created the invitation. + """ + inviter: User! + """ + Extra metadata associated with the invite. + """ + metadata: JSONObject + """ + The workspace that the invite is associated with. + """ + organization: Organization! + """ + The workspace role (admin, member, guest, or owner) that the invitee will receive upon accepting the invite. + """ + role: UserRoleType! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +type OrganizationInviteConnection { + edges: [OrganizationInviteEdge!]! + nodes: [OrganizationInvite!]! + pageInfo: PageInfo! +} + +input OrganizationInviteCreateInput { + """ + The email of the invitee. + """ + email: String! + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + [INTERNAL] Optional metadata about the invite. + """ + metadata: JSONObject + """ + What user role the invite should grant. + """ + role: UserRoleType = user + """ + The teams that the user has been invited to. + """ + teamIds: [String!] +} + +union OrganizationInviteDetailsPayload = + | OrganizationAcceptedOrExpiredInviteDetailsPayload + | OrganizationInviteFullDetailsPayload + +type OrganizationInviteEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: OrganizationInvite! +} + +type OrganizationInviteFullDetailsPayload { + """ + Whether the invite has already been accepted. + """ + accepted: Boolean! + """ + Allowed authentication providers, empty array means all are allowed. + """ + allowedAuthServices: [String!]! + """ + When the invite was created. + """ + createdAt: DateTime! + """ + The email of the invitee. + """ + email: String! + """ + Whether the invite has expired. + """ + expired: Boolean! + """ + The name of the inviter. + """ + inviter: String! + """ + ID of the workspace the invite is for. + """ + organizationId: String! + """ + URL of the workspace logo the invite is for. + """ + organizationLogoUrl: String + """ + Name of the workspace the invite is for. + """ + organizationName: String! + """ + What user role the invite should grant. + """ + role: UserRoleType! + """ + The status of the invite. + """ + status: OrganizationInviteStatus! +} + +""" +Workspace invite operation response. +""" +type OrganizationInvitePayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + The organization invite that was created or updated. + """ + organizationInvite: OrganizationInvite! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +The different statuses possible for an organization invite. +""" +enum OrganizationInviteStatus { + accepted + expired + pending +} + +input OrganizationInviteUpdateInput { + """ + The teams that the user has been invited to. + """ + teamIds: [String!]! +} + +""" +[INTERNAL] IP restriction rule for a workspace, defining allowed or blocked IP ranges. +""" +type OrganizationIpRestriction { + """ + Optional restriction description. + """ + description: String + """ + Whether the restriction is enabled. + """ + enabled: Boolean! + """ + IP range in CIDR format. + """ + range: String! + """ + Restriction type. + """ + type: String! +} + +""" +[INTERNAL] Organization IP restriction configuration. +""" +input OrganizationIpRestrictionInput { + """ + Optional restriction description. + """ + description: String + """ + Whether the restriction is enabled. + """ + enabled: Boolean! + """ + IP range in CIDR format. + """ + range: String! + """ + Restriction type. + """ + type: String! +} + +""" +[Internal] An MCP server URL entry for the Linear Agent allowlist. +""" +input OrganizationLinearAgentMcpServerAllowlistEntryInput { + """ + [Internal] Slug of the built-in MCP integration this entry was added from, if any. + """ + knownIntegrationKey: String + """ + [Internal] The MCP server URL that Linear Agent is allowed to use. + """ + url: String! +} + +""" +[Internal] Input for updating Linear Agent settings for the workspace. +""" +input OrganizationLinearAgentSettingsInput { + """ + [Internal] Legacy MCP server allowlist for Linear Agent. + """ + mcpServersAllowlist: [OrganizationLinearAgentMcpServerAllowlistEntryInput!] + """ + [Internal] Whether the workspace has enabled MCP servers for Linear Agent. + """ + mcpServersEnabled: Boolean + """ + [Internal] Whether all MCP servers or only approved MCP servers are allowed for Linear Agent. + """ + mcpServersMode: LinearAgentMcpServersMode + """ + [Internal] Trusted-source allowlist for loops. + """ + trustedSourcesAllowlist: [OrganizationLinearAgentTrustedSourcesAllowlistEntryInput!] + """ + [Internal] Whether external trusted sources are disabled or restricted to approved sources for loops. + """ + trustedSourcesMode: LinearAgentTrustedSourcesMode + """ + [Internal] Whether the workspace has enabled web search for Linear Agent. + """ + webSearchEnabled: Boolean +} + +""" +[Internal] A trusted-source entry for the loop allowlist. +""" +input OrganizationLinearAgentTrustedSourcesAllowlistEntryInput { + """ + [Internal] The trusted-source key that loops are allowed to use. + """ + key: String! +} + +""" +[Internal] One team a managed team feature is limited to. +""" +input OrganizationManagedFeatureTeamInput { + """ + [Internal] Whether the team's sub-teams, at any depth, can use the feature too. + """ + includeSubTeams: Boolean! + """ + [Internal] The identifier of the team. + """ + teamId: UUID! +} + +""" +[Internal] The teams each managed team feature is limited to in the workspace. +""" +input OrganizationManagedTeamFeaturesInput { + """ + [Internal] The teams coding sessions are limited to. Omit it to not limit coding sessions by team, or pass an empty list to allow no team. `codingAgentEnabled` still turns coding sessions on or off for the workspace. + """ + codingSessions: [OrganizationManagedFeatureTeamInput!] + """ + [Internal] The teams Loops are limited to. Omit it to not limit Loops by team, or pass an empty list to allow no team. `agentAutomationEnabled` still turns Loops on or off for the workspace. + """ + loops: [OrganizationManagedFeatureTeamInput!] +} + +""" +[INTERNAL] Workspace metadata including region and allowed authentication providers. +""" +type OrganizationMeta { + """ + Allowed authentication providers, empty array means all are allowed. + """ + allowedAuthServices: [String!]! + """ + The region the workspace is hosted in. + """ + region: String! +} + +""" +Organization origin for guidance rules. +""" +type OrganizationOriginWebhookPayload { + """ + The type of origin, always 'Organization'. + """ + type: String! +} + +""" +Workspace update operation response. +""" +type OrganizationPayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + The workspace that was created or updated. + """ + organization: Organization + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +A public resource quota for the current workspace. +""" +type OrganizationQuota implements Node { + description: String! + """ + The unique identifier of the entity. + """ + id: ID! + """ + Stable quota key. + """ + key: String! + """ + Effective quota limit, including workspace overrides. Scoped quotas apply this limit to each entity. + """ + limit: Float! + """ + [Internal] The highest usage of the quota in any team, project, or initiative, and the entity with that usage. Counts include data that the user cannot see. Null for workspace quotas, which return their usage in `usage`. The value is cached because it counts every row in the workspace. It can be up to 1 hour old for `max-issues-per-team` and `max-issues-per-project`, and up to 10 minutes old for other quotas. Changes to the data do not refresh the cache. For a current value, query `usage` with the ID of that entity. + """ + maxUsage: OrganizationQuotaMaxUsage + name: String! + """ + The entity that the limit applies to. Workspace quotas limit the whole workspace. Team, project, and initiative quotas limit each of those entities separately. To get their usage, pass the ID of the entity to `usage`. + """ + scope: OrganizationQuotaScope! + """ + [Internal] Current usage of the quota, counted with the same rules as quota enforcement. The value is not cached. Counts include data that the user cannot see. Workspace quotas ignore the arguments. Team, project, and initiative quotas return null unless you pass `teamId`, `projectId`, or `initiativeId` that matches their scope. The user must have access to that entity. + """ + usage( + """ + The initiative to count usage for initiative quotas in. + """ + initiativeId: String + """ + The project to count usage for project quotas in. + """ + projectId: String + """ + The team to count usage for team quotas in. + """ + teamId: String + ): Float +} + +type OrganizationQuotaConnection { + edges: [OrganizationQuotaEdge!]! + nodes: [OrganizationQuota!]! + pageInfo: PageInfo! +} + +type OrganizationQuotaEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: OrganizationQuota! +} + +""" +Filter public workspace quotas by key or scope. +""" +input OrganizationQuotaFilter { + and: [OrganizationQuotaFilter!] + key: StringComparator + or: [OrganizationQuotaFilter!] + """ + Comparator for the quota scope: workspace, team, project, or initiative. + """ + scope: StringComparator +} + +""" +The team, project, or initiative with the highest usage of a scoped quota. The limit applies to each entity, so this entity is the closest to the limit. +""" +type OrganizationQuotaMaxUsage { + """ + The ID of the entity with the highest usage. Null if the user cannot see the entity, if no entity uses the quota, or if workspace-level templates have the highest usage of a template quota. + """ + entityId: String + """ + The usage of the quota in the entity with the highest usage. + """ + usage: Float! +} + +""" +The entity that a quota limit applies to. +""" +enum OrganizationQuotaScope { + """ + The limit applies to each initiative separately. + """ + initiative + """ + The limit applies to each project separately. + """ + project + """ + The limit applies to each team separately. + """ + team + """ + The limit applies to the whole workspace. + """ + workspace +} + +""" +Input for updating workspace security settings such as role-based access controls. +""" +input OrganizationSecuritySettingsInput { + """ + The minimum role required to grant or revoke the workspace admin role. + """ + adminManagementRole: UserRoleType + """ + The minimum role required to manage agent guidance prompts and settings. + """ + agentGuidanceRole: UserRoleType + """ + The minimum role required to manage API settings. + """ + apiSettingsRole: UserRoleType + """ + The minimum role required to manage workspace loops. + """ + automationManagementRole: UserRoleType + """ + The minimum role required to import data. + """ + importRole: UserRoleType + """ + The minimum role required to install and connect new integrations. + """ + integrationCreationRole: UserRoleType + """ + The minimum role required to invite users. + """ + invitationsRole: UserRoleType + """ + The minimum role required to manage workspace labels. + """ + labelManagementRole: UserRoleType + """ + The minimum role required to create personal API keys. + """ + personalApiKeysRole: UserRoleType + """ + The minimum role required to pin views to workspace pages and to change the views pinned there. + """ + pinnedViewManagementRole: UserRoleType + """ + The minimum role required to create teams. + """ + teamCreationRole: UserRoleType + """ + The minimum role required to manage workspace templates. + """ + templateManagementRole: UserRoleType + """ + The minimum role required to create initiatives without a lead team or move initiatives between workspace and team scopes. + """ + workspaceInitiativesRole: UserRoleType +} + +""" +Input for starting a workspace trial on a specific plan. +""" +input OrganizationStartTrialInput { + """ + The plan type to trial. + """ + planType: String! +} + +""" +Workspace trial start response. +""" +type OrganizationStartTrialPayload { + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +[Internal] Input for updating workspace theme settings. +""" +input OrganizationThemeSettingsInput { + """ + [ALPHA] Dark theme palette: CSS custom property name (`--name`) to color or length value. + """ + darkTheme: JSONObject + """ + [ALPHA] Light theme palette: CSS custom property name (`--name`) to color or length value. + """ + lightTheme: JSONObject +} + +""" +Input for updating the workspace. +""" +input OrganizationUpdateInput { + """ + [INTERNAL] Whether the workspace has enabled loops. + """ + agentAutomationEnabled: Boolean + """ + [INTERNAL] Whether the workspace has enabled the AI add-on. + """ + aiAddonEnabled: Boolean + """ + Whether the workspace has enabled AI discussion summaries for issues. + """ + aiDiscussionSummariesEnabled: Boolean + """ + [INTERNAL] Whether the workspace has opted in to AI telemetry. + """ + aiTelemetryEnabled: Boolean + """ + Whether the workspace has enabled resolved thread AI summaries. + """ + aiThreadSummariesEnabled: Boolean + """ + Allowed file upload content types. + """ + allowedFileUploadContentTypes: [String!] + """ + The authentication settings for the workspace. + """ + authSettings: OrganizationAuthSettingsInput + """ + [INTERNAL] Whether code intelligence is enabled for the workspace. + """ + codeIntelligenceEnabled: Boolean + """ + [INTERNAL] GitHub repository in owner/repo format for code intelligence. + """ + codeIntelligenceRepository: String + """ + [INTERNAL] Whether the workspace has enabled Coding Sessions. + """ + codingAgentEnabled: Boolean + """ + [Internal] Settings for Coding Sessions features. + """ + codingAgentSettings: OrganizationCodingAgentSettingsInput + """ + [INTERNAL] Configuration settings for the Customers feature. + """ + customersConfiguration: CustomersConfigurationInput + """ + [INTERNAL] Whether the workspace is using customers. + """ + customersEnabled: Boolean + """ + Default schedule for how often feed summaries are generated. + """ + defaultFeedSummarySchedule: FeedSummarySchedule + """ + The default home view for members of the workspace who have not chosen their own default. + """ + defaultHomeView: String + """ + The id of the specific initiative, project, view, or dashboard used as the default home view. The type of entity is given by defaultHomeView. + """ + defaultHomeViewTargetId: String + """ + Whether the workspace has enabled the feed feature. + """ + feedEnabled: Boolean + """ + The month at which the fiscal year starts. + """ + fiscalYearStartMonth: Float + """ + [INTERNAL] Whether the workspace has enabled generated updates. + """ + generatedUpdatesEnabled: Boolean + """ + How git branches are formatted. If null, default formatting will be used. + """ + gitBranchFormat: String + """ + Whether issue descriptions should be included in Git integration linkback messages. + """ + gitLinkbackDescriptionsEnabled: Boolean + """ + Whether the Git integration linkback messages should be sent for private repositories. + """ + gitLinkbackMessagesEnabled: Boolean + """ + Whether the Git integration linkback messages should be sent for public repositories. + """ + gitPublicLinkbackMessagesEnabled: Boolean + """ + Whether HIPAA compliance is enabled for the workspace. + """ + hipaaComplianceEnabled: Boolean + """ + [ALPHA] The n-weekly frequency at which to prompt for initiative updates. + """ + initiativeUpdateReminderFrequencyInWeeks: Float + """ + [ALPHA] The day at which initiative updates are sent. + """ + initiativeUpdateRemindersDay: Day + """ + [ALPHA] The hour at which initiative updates are sent. + """ + initiativeUpdateRemindersHour: Float + """ + IP restriction configurations controlling allowed access the workspace. + """ + ipRestrictions: [OrganizationIpRestrictionInput!] + """ + [Internal] Whether the workspace has enabled Linear Agent. + """ + linearAgentEnabled: Boolean + """ + [Internal] Settings for Linear Agent features. + """ + linearAgentSettings: OrganizationLinearAgentSettingsInput + """ + The logo URL of the workspace. + """ + logoUrl: String + """ + [Internal] The teams each managed team feature is limited to. Replaces the current lists, and updates each team's matching setting. + """ + managedTeamFeatures: OrganizationManagedTeamFeaturesInput + """ + The name of the workspace. + """ + name: String + """ + Whether the workspace has opted for having to approve all OAuth applications for install. + """ + oauthAppReview: Boolean + """ + The n-weekly frequency at which to prompt for project updates. + """ + projectUpdateReminderFrequencyInWeeks: Float + """ + The day at which project updates are sent. + """ + projectUpdateRemindersDay: Day + """ + The hour at which project updates are sent. + """ + projectUpdateRemindersHour: Float + """ + How Linear suggests and links issues for pull requests that have none linked: 'off', 'suggest', or 'autoOnMerge'. + """ + pullRequestIssueMode: String + """ + Whether the workspace generates AI Pull Request guides for new pull requests. + """ + pullRequestTourEnabled: Boolean + """ + Whether the workspace has opted for reduced customer support attachment information. + """ + reducedPersonalInformation: Boolean + """ + Whether agent invocation is restricted to full workspace members. + """ + restrictAgentInvocationToMembers: Boolean + """ + Whether the workspace is using roadmap. + """ + roadmapEnabled: Boolean + """ + The security settings for the workspace. + """ + securitySettings: OrganizationSecuritySettingsInput + """ + Internal. Whether SLAs have been enabled for the workspace. + """ + slaEnabled: Boolean + """ + [Internal] Whether to automatically create a Slack channel when a new project is created. + """ + slackAutoCreateProjectChannel: Boolean + """ + The ID of the Slack integration to use for auto-creating project channels. + """ + slackProjectChannelIntegrationId: String + """ + The prefix to use for auto-created Slack project channels (p-, proj-, or project-). + """ + slackProjectChannelPrefix: String + """ + [Internal] Whether the Slack project channels feature is enabled for the workspace. + """ + slackProjectChannelsEnabled: Boolean + """ + Whether the default prompt for copying an issue or opening it in a coding tool includes a suggested Git branch name. + """ + suggestedBranchNameEnabled: Boolean + """ + [Internal] Workspace restrictions for team permissions. + """ + teamSecuritySettings: WorkspaceTeamSecuritySettingsInput + """ + [ALPHA] Theme settings for the workspace. + """ + themeSettings: OrganizationThemeSettingsInput + """ + The URL key of the workspace. + """ + urlKey: String + """ + [Internal] The list of working days. Sunday is 0, Monday is 1, etc. + """ + workingDays: [Float!] +} + +type OriginInstallUrlPayload { + """ + The Origin URL to send the user to in order to install Linear's app. + """ + installUrl: String! +} + +type OriginInstallationCancelPayload { + """ + Whether Linear's app was removed from the installation. + """ + success: Boolean! +} + +type OriginInstallationDetails { + """ + Whether the installation is already connected to the current workspace, as after a reinstall that updated it. + """ + connectedToWorkspace: Boolean! + """ + The Origin installation id. + """ + installationId: String! + """ + The slug of the Origin owner the app was installed on. + """ + ownerSlug: String! + """ + Whether the Origin owner is a `team` or a `user`. + """ + ownerType: String + """ + Whether the installation covers `all` repositories of the owner or only `selected` ones. + """ + repositorySelection: String! +} + +input OriginSettingsInput { + """ + The slug of the Origin team or user that owns the installation. + """ + ownerSlug: String +} + +""" +A generic type of notification. +""" +enum OtherNotificationType { + agentConversationMention + customerAddedAsOwner + customerNeedCreated + customerNeedMarkedAsImportant + customerNeedResolved + documentAddedAsOwner + documentCommentMention + documentCommentReaction + documentContentChange + documentDeleted + documentMention + documentMoved + documentNewComment + documentReminder + documentRemovedAsOwner + documentRestored + documentSharedWithYou + documentSubscribed + documentThreadResolved + documentUnsubscribed + feedSummaryGenerated + initiativeAddedAsOwner + initiativeCommentMention + initiativeCommentReaction + initiativeDescriptionContentChange + initiativeMention + initiativeNewComment + initiativeReminder + initiativeThreadResolved + initiativeUpdateCommentMention + initiativeUpdateCommentReaction + initiativeUpdateCreated + initiativeUpdateMention + initiativeUpdateNewComment + initiativeUpdatePrompt + initiativeUpdateReaction + issueAddedToTriage + issueAddedToView + issueBlocking + issueCreated + issueDue + issuePriorityUrgent + issueReminder + issueReopened + issueSlaBreached + issueSlaHighRisk + issueStatusChangedAll + issueSubscribed + issueThreadResolved + issueUnblocked + issueUnsubscribed + oauthClientApprovalCreated + projectAddedAsLead + projectAddedAsMember + projectCommentMention + projectCommentReaction + projectDescriptionContentChange + projectMention + projectMilestoneCommentMention + projectMilestoneCommentReaction + projectMilestoneDescriptionContentChange + projectMilestoneMention + projectMilestoneNewComment + projectMilestoneThreadResolved + projectNewComment + projectReminder + projectThreadResolved + projectUpdateCommentMention + projectUpdateCommentReaction + projectUpdateCreated + projectUpdateMention + projectUpdateNewComment + projectUpdatePrompt + projectUpdateReaction + pullRequestApproved + pullRequestChangesRequested + pullRequestChecksFailed + pullRequestCommentMention + pullRequestCommented + pullRequestMention + pullRequestRemovedFromMergeQueue + pullRequestReviewRequested + pullRequestReviewRerequested + system + teamUpdateCommentMention + teamUpdateCommentReaction + teamUpdateCreated + teamUpdateMention + teamUpdateNewComment + teamUpdateReaction + triageResponsibilityIssueAddedToTriage +} + +""" +Generic notification payload. +""" +type OtherNotificationWebhookPayload { + """ + The actor who caused the notification. + """ + actor: UserChildWebhookPayload + """ + The ID of the actor who caused the notification. + """ + actorId: String + """ + The time at which the entity was archived. + """ + archivedAt: String + """ + The comment this notification belongs to. + """ + comment: CommentChildWebhookPayload + """ + The ID of the comment this notification belongs to. + """ + commentId: String + """ + The time at which the entity was created. + """ + createdAt: String! + """ + The document this notification belongs to. + """ + document: DocumentChildWebhookPayload + """ + The ID of the document this notification belongs to. + """ + documentId: String + """ + The ID of the external user who caused the notification. + """ + externalUserActorId: String + """ + The ID of the entity. + """ + id: String! + """ + The issue this notification belongs to. + """ + issue: IssueWithDescriptionChildWebhookPayload + """ + The ID of the issue this notification belongs to. + """ + issueId: String + """ + The parent comment this notification belongs to. + """ + parentComment: CommentChildWebhookPayload + """ + The ID of the parent comment this notification belongs to. + """ + parentCommentId: String + """ + The project this notification belongs to. + """ + project: ProjectChildWebhookPayload + """ + The ID of the project this notification belongs to. + """ + projectId: String + """ + The project update this notification belongs to. + """ + projectUpdate: ProjectUpdateChildWebhookPayload + """ + The ID of the project update this notification belongs to. + """ + projectUpdateId: String + """ + The emoji of the reaction this notification is for. + """ + reactionEmoji: String + """ + The type of the notification. + """ + type: OtherNotificationType! + """ + The time at which the entity was updated. + """ + updatedAt: String! + """ + The ID of the user who received the notification. + """ + userId: String! +} + +""" +Customer owner sorting options. +""" +input OwnerSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +type PageInfo { + """ + Cursor representing the last result in the paginated results. + """ + endCursor: String + """ + Indicates if there are more results when paginating forward. + """ + hasNextPage: Boolean! + """ + Indicates if there are more results when paginating backward. + """ + hasPreviousPage: Boolean! + """ + Cursor representing the first result in the paginated results. + """ + startCursor: String +} + +input PagerDutyInput { + """ + The date when the PagerDuty API failed with an unauthorized error. + """ + apiFailedWithUnauthorizedErrorAt: DateTime +} + +""" +How to treat NULL values, whether they should appear first or last +""" +enum PaginationNulls { + first + last +} + +""" +By which field should the pagination order by +""" +enum PaginationOrderBy { + createdAt + updatedAt +} + +""" +Whether to sort in ascending or descending order +""" +enum PaginationSortOrder { + Ascending + Descending +} + +""" +The billing subscription of a workspace. Represents an active paid plan (e.g., Basic, Business, Enterprise) backed by a Stripe subscription. If a workspace has no Subscription record, it is on the free plan. Only one active subscription per workspace is expected. +""" +type PaidSubscription implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The date the subscription is scheduled to be canceled in the future. Null if no cancellation is scheduled. The subscription remains active until this date. + """ + cancelAt: DateTime + """ + The date the subscription was canceled. Null if the subscription has not been canceled. + """ + canceledAt: DateTime + """ + The billing collection method for this subscription. 'automatic' means the payment method on file is charged automatically. 'send_invoice' means invoices are sent to the billing email for manual payment. + """ + collectionMethod: String! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The user who initially created (purchased) the subscription. Null if the creator has been removed from the workspace. + """ + creator: User + """ + The unique identifier of the entity. + """ + id: ID! + """ + The date the subscription will be billed next. Null if the subscription is canceled or has no upcoming billing date. + """ + nextBillingAt: DateTime + """ + The workspace that the subscription is associated with. + """ + organization: Organization! + """ + The subscription plan type that the workspace is scheduled to change to at the next billing cycle. Null if no plan change is pending. + """ + pendingChangeType: String + """ + The number of seats (active members) in the subscription. This is the raw count before applying minimum and maximum seat limits. + """ + seats: Float! + """ + The maximum number of seats that will be billed in the subscription. The billed seat count will never exceed this value even if actual member count is higher. Null if no maximum is enforced. + """ + seatsMaximum: Float + """ + The minimum number of seats that will be billed in the subscription. The billed seat count will never go below this value even if actual member count is lower. Null if no minimum is enforced. + """ + seatsMinimum: Float + """ + The subscription plan type (e.g., basic, business, enterprise). Determines the feature set and pricing tier for the workspace. + """ + type: String! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +input PartialNotificationChannelPreferencesInput { + """ + Whether notifications are currently enabled for desktop. + """ + desktop: Boolean + """ + Whether notifications are currently enabled for email. + """ + email: Boolean + """ + Whether notifications are currently enabled for mobile. + """ + mobile: Boolean + """ + Whether notifications are currently enabled for Slack. + """ + slack: Boolean +} + +""" +[INTERNAL] Input for a Startup Program partner application submitted from the website. +""" +input PartnerApplicationCreateInput { + """ + Number of cohorts run per year (accelerators and programs). + """ + cohortsPerYear: String + """ + Number of companies per cohort (accelerators and programs). + """ + companiesPerCohort: String + """ + Whether the applicant confirmed the distribution terms. + """ + consent: Boolean! + """ + One-line description of what the organization does. + """ + description: String! + """ + Channels the organization will use to distribute the offer. + """ + distributionChannels: [String!] + """ + Business email of the applicant. + """ + email: String! + """ + Full name of the applicant. + """ + fullName: String! + """ + Stages the firm primarily invests at (venture capital firms). + """ + investmentStages: [String!] + """ + Number of active members or startups in the network (communities). + """ + networkSize: String + """ + Whether the organization already offers software perks from other companies. + """ + offersSoftwarePerks: String + """ + Name of the partner organization. + """ + organizationName: String! + """ + Type of the partner organization (e.g., venture capital firm, accelerator). + """ + organizationType: String! + """ + Website of the partner organization. + """ + organizationWebsite: String! + """ + Which other software perks the organization offers, when applicable. + """ + otherPerks: String + """ + Number of active portfolio companies (venture capital firms). + """ + portfolioCompanies: String + """ + Primary countries or regions the organization operates in. + """ + region: String! + """ + The applicant's role or title at the organization. + """ + role: String! +} + +""" +[Internal] The kind of benefit a partner offer grants, which determines how its discount value is interpreted. +""" +enum PartnerDiscountType { + amount_off + free_seats + percent_off +} + +""" +The kind of partner program an offer belongs to. +""" +enum PartnerOfferCategory { + accelerator + creator + investor + startup_community +} + +""" +[Internal] Public details of an active partner-program offer. +""" +type PartnerOfferDetailsPayload { + """ + How the offer's benefit is applied, which determines the meaning of `discountValue`. + """ + discountType: PartnerDiscountType! + """ + The magnitude of the benefit, interpreted according to `discountType`. + """ + discountValue: Int! + """ + Duration of the benefit in months, or null when the benefit is not time-bounded. + """ + durationMonths: Int + """ + The unique identifier of the offer. + """ + id: String! + """ + Display name of the partner. + """ + partnerName: String! + """ + Stable, URL-safe identifier for the partner. + """ + partnerSlug: String! + """ + Short-lived signed token that carries the redemption through signup or an existing-workspace redemption. Embeds a pre-minted redemption identifier, the offer identifier, and its mint and expiry times. + """ + token: String! +} + +""" +[Internal] Why a workspace cannot redeem a partner offer. +""" +enum PartnerOfferIneligibilityReason { + alreadyRedeemed + alreadySubscribed + otherOfferPending +} + +""" +[Internal] The result of redeeming a partner offer for an existing workspace. +""" +type PartnerOfferRedeemPayload { + """ + Whether the redemption was recorded. + """ + success: Boolean! +} + +""" +[Internal] One of the viewer's workspaces and whether it can redeem a partner offer. +""" +type PartnerOfferWorkspacePayload { + """ + Whether the workspace can redeem the offer. + """ + eligible: Boolean! + """ + Why the workspace cannot redeem the offer. Null when the workspace is eligible. + """ + ineligibilityReason: PartnerOfferIneligibilityReason + """ + The identifier of the workspace. + """ + organizationId: String! +} + +""" +[Internal] The viewer's workspaces hosted in the serving cell, with partner-offer eligibility. +""" +type PartnerOfferWorkspacesPayload { + """ + Details of the offer the token was minted for. + """ + offer: PartnerOfferDetailsPayload! + """ + The viewer's workspaces hosted in the cell that served this request. Workspaces hosted in other cells are not included; query each cell to assemble the full list. + """ + workspaces: [PartnerOfferWorkspacePayload!]! +} + +""" +[Internal] A partner listed in the Linear Startup Program. +""" +type PartnerProgramPartnerPayload { + """ + The kind of partner program the offer belongs to. + """ + category: PartnerOfferCategory! + """ + Display name of the partner. + """ + partnerName: String! +} + +type PasskeyLoginStartResponse { + """ + The passkey authentication options to pass to the WebAuthn API. + """ + options: JSONObject! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Different tabs available inside a release pipeline. +""" +enum PipelineTab { + releaseNotes + releases +} + +""" +[Internal] A post or announcement in a team or user feed. Posts can be manually authored by users or AI-generated summaries of team activity. They support rich text content (ProseMirror), emoji reactions, threaded comments, and audio summaries. Posts are associated with either a team or a user, but not both. +""" +type Post implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The post content summarized for audio text-to-speech consumption. Null if no audio summary has been generated. + """ + audioSummary: String + """ + The post content in markdown format. + """ + body: String! + """ + [Internal] The content of the post as a ProseMirror document. This is the canonical rich-text representation of the post body. + """ + bodyData: String! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The user who created the post. Null for system-generated posts. + """ + creator: User + """ + The time the post was last edited. Null if the post has not been edited since creation. + """ + editedAt: DateTime + """ + The evaluation log ID of the AI response that generated this post. Null for non-AI-generated posts. + """ + evalLogId: String + """ + The feed summary schedule cadence that was active when this post was created. Null for non-summary posts. + """ + feedSummaryScheduleAtCreate: FeedSummarySchedule + """ + The unique identifier of the entity. + """ + id: ID! + """ + Emoji reaction summary for this post, grouped by emoji type. Each entry contains the emoji name, count, and the IDs of users who reacted. + """ + reactionData: JSONObject! + """ + The post's unique URL slug, used to construct human-readable URLs. + """ + slugId: String! + """ + The team that the post is scoped to, for team-level feed posts. Null for user-scoped posts. + """ + team: Team + """ + The post's title. Null or empty for posts that do not have a title. + """ + title: String + """ + A URL of the text-to-speech audio rendering of the post body. Null if no audio has been generated. + """ + ttlUrl: String + """ + The type of the post, such as 'summary' for AI-generated feed summaries. Null for standard user-authored posts. + """ + type: PostType + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The user that the post is scoped to, for user-level feed posts. Null for team-scoped posts. + """ + user: User + """ + [Internal] The structured data used to compose an AI-generated written summary post, including section content and source references. + """ + writtenSummaryData: JSONObject +} + +""" +A notification related to a post, such as new comments or reactions. +""" +type PostNotification implements Entity & Node & Notification { + """ + The user that caused the notification. Null if the notification was triggered by a non-user actor such as an integration, external user, or system event. + """ + actor: User + """ + [Internal] Notification actor initials if avatar is not available. + """ + actorAvatarColor: String! + """ + [Internal] Notification avatar URL. + """ + actorAvatarUrl: String + """ + [Internal] Whether the notification's user actor is deactivated in the workspace. + """ + actorInactive: Boolean! + """ + [Internal] Notification actor initials if avatar is not available. + """ + actorInitials: String + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The bot that caused the notification. + """ + botActor: ActorBot + """ + The category of the notification. + """ + category: NotificationCategory! + """ + Related comment ID. Null if the notification is not related to a comment. + """ + commentId: String + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The time at which an email reminder for this notification was sent to the user. Null if no email reminder has been sent. + """ + emailedAt: DateTime + """ + The external user that caused the notification. Populated when the notification was triggered by an external user (e.g., a commenter from a connected integration like Slack or GitHub) rather than a Linear workspace member. + """ + externalUserActor: ExternalUser + """ + [Internal] Notifications with the same grouping key will be grouped together in the UI. + """ + groupingKey: String! + """ + [Internal] Priority of the notification with the same grouping key. Higher number means higher priority. If priority is the same, notifications should be sorted by `createdAt`. + """ + groupingPriority: Float! + """ + The unique identifier of the entity. + """ + id: ID! + """ + [Internal] Inbox URL for the notification. + """ + inboxUrl: String! + """ + [Internal] Initiative update health for new updates. + """ + initiativeUpdateHealth: String + """ + [Internal] If notification actor was Linear. + """ + isLinearActor: Boolean! + """ + [Internal] Issue's status type for issue notifications. + """ + issueStatusType: String + """ + Related parent comment ID. Null if the notification is not related to a comment. + """ + parentCommentId: String + """ + Related post ID. + """ + postId: String! + """ + [Internal] Project update health for new updates. + """ + projectUpdateHealth: String + """ + Name of the reaction emoji related to the notification. + """ + reactionEmoji: String + """ + The time at which the user marked the notification as read. Null if the notification is unread. + """ + readAt: DateTime + """ + The time until which a notification is snoozed. After this time, the notification reappears in the user's inbox. Null if the notification is not currently snoozed. + """ + snoozedUntilAt: DateTime + """ + [Internal] Notification subtitle. + """ + subtitle: String! + """ + [Internal] Notification title. + """ + title: String! + """ + Notification type. Determines the kind of event that triggered this notification and which associated entity fields will be populated. + """ + type: String! + """ + The time at which a notification was unsnoozed. Null if the notification has not been unsnoozed. + """ + unsnoozedAt: DateTime + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + [Internal] URL to the target of the notification. + """ + url: String! + """ + The recipient user of this notification. + """ + user: User! +} + +""" +Type of Post +""" +enum PostType { + summary + update +} + +""" +A readable issue suggestion reason and its structured entity references. +""" +type PresentedIssueSuggestionReason { + """ + Entities referenced by the reason. + """ + references: [IssueSuggestionReasonReference!]! + """ + The reason with entity mentions rendered as readable text. + """ + text: String! +} + +""" +Issue priority sorting options. +""" +input PrioritySort { + """ + Whether to consider no priority as the highest or lowest priority + """ + noPriorityFirst: Boolean = false + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder + """ + Whether to tiebreak issues sharing a priority by their priority sort order + """ + usePrioritySortOrderTiebreaker: Boolean = true +} + +""" +A product announcement shown in targeted workspace inbox notifications. Product announcements store reusable launch copy and are sent to specific recipients through related notifications. +""" +type ProductAnnouncement implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + Stable campaign identifier used to deduplicate product announcement notifications. + """ + campaignId: String! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + Body copy shown in the product announcement detail view. + """ + description: String! + """ + Headline shown at the top of the product announcement detail view. + """ + headline: String! + """ + The unique identifier of the entity. + """ + id: ID! + """ + Renderer identifier for this announcement. Unknown values should fall back to generic title, headline, and description rendering. + """ + kind: String! + """ + Short title shown in the inbox notification list and push notification. + """ + title: String! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +""" +A notification related to a product announcement sent by Linear. +""" +type ProductAnnouncementNotification implements Entity & Node & Notification { + """ + The user that caused the notification. Null if the notification was triggered by a non-user actor such as an integration, external user, or system event. + """ + actor: User + """ + [Internal] Notification actor initials if avatar is not available. + """ + actorAvatarColor: String! + """ + [Internal] Notification avatar URL. + """ + actorAvatarUrl: String + """ + [Internal] Whether the notification's user actor is deactivated in the workspace. + """ + actorInactive: Boolean! + """ + [Internal] Notification actor initials if avatar is not available. + """ + actorInitials: String + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The bot that caused the notification. + """ + botActor: ActorBot + """ + The category of the notification. + """ + category: NotificationCategory! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The time at which an email reminder for this notification was sent to the user. Null if no email reminder has been sent. + """ + emailedAt: DateTime + """ + The external user that caused the notification. Populated when the notification was triggered by an external user (e.g., a commenter from a connected integration like Slack or GitHub) rather than a Linear workspace member. + """ + externalUserActor: ExternalUser + """ + [Internal] Notifications with the same grouping key will be grouped together in the UI. + """ + groupingKey: String! + """ + [Internal] Priority of the notification with the same grouping key. Higher number means higher priority. If priority is the same, notifications should be sorted by `createdAt`. + """ + groupingPriority: Float! + """ + The unique identifier of the entity. + """ + id: ID! + """ + [Internal] Inbox URL for the notification. + """ + inboxUrl: String! + """ + [Internal] Initiative update health for new updates. + """ + initiativeUpdateHealth: String + """ + [Internal] If notification actor was Linear. + """ + isLinearActor: Boolean! + """ + [Internal] Issue's status type for issue notifications. + """ + issueStatusType: String + """ + The product announcement related to the notification. + """ + productAnnouncement: ProductAnnouncement! + """ + Identifier of the associated product announcement. + """ + productAnnouncementId: String! + """ + [Internal] Project update health for new updates. + """ + projectUpdateHealth: String + """ + The time at which the user marked the notification as read. Null if the notification is unread. + """ + readAt: DateTime + """ + The time until which a notification is snoozed. After this time, the notification reappears in the user's inbox. Null if the notification is not currently snoozed. + """ + snoozedUntilAt: DateTime + """ + [Internal] Notification subtitle. + """ + subtitle: String! + """ + [Internal] Notification title. + """ + title: String! + """ + Notification type. Determines the kind of event that triggered this notification and which associated entity fields will be populated. + """ + type: String! + """ + The time at which a notification was unsnoozed. Null if the notification has not been unsnoozed. + """ + unsnoozedAt: DateTime + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + [Internal] URL to the target of the notification. + """ + url: String! + """ + The recipient user of this notification. + """ + user: User! +} + +""" +[Internal] The scope of product intelligence suggestion data for a team. +""" +enum ProductIntelligenceScope { + none + team + teamHierarchy + workspace +} + +""" +A project is a collection of issues working toward a shared goal. Projects have start and target dates, milestones, status tracking, and progress metrics. They can span multiple teams and be grouped under initiatives. +""" +type Project implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + Attachments associated with the project. + """ + attachments( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): ProjectAttachmentConnection! + """ + The time at which the project was automatically archived by the auto-pruning process. Null if the project has not been auto-archived. + """ + autoArchivedAt: DateTime + """ + The time at which the project was moved into a canceled status. Null if the project has not been canceled. + """ + canceledAt: DateTime + """ + The project's color as a HEX string. Used in the UI to visually identify the project. + """ + color: String! + """ + Comments associated with the project overview. + """ + comments( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned comments. + """ + filter: CommentFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): CommentConnection! + """ + The time at which the project was moved into a completed status. Null if the project has not been completed. + """ + completedAt: DateTime + """ + The number of completed issues in the project at the end of each week since project creation. Each entry represents one week. + """ + completedIssueCountHistory: [Float!]! + """ + The number of completed estimation points at the end of each week since project creation. Each entry represents one week. + """ + completedScopeHistory: [Float!]! + """ + The project's content in markdown format. + """ + content: String + """ + [Internal] The project's content as YJS state. + """ + contentState: String + """ + The issue that was converted into this project. Null if the project was not created from an issue. + """ + convertedFromIssue: Issue + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The user who created the project. + """ + creator: User + """ + [INTERNAL] The current progress of the project, broken down by issue status category. + """ + currentProgress: JSONObject! + """ + The short description of the project. + """ + description: String! + """ + The content of the project description. + """ + documentContent: DocumentContent + """ + Documents associated with the project. + """ + documents( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned documents. + """ + filter: DocumentFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): DocumentConnection! + """ + External links associated with the project. + """ + externalLinks( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): EntityExternalLinkConnection! + """ + [Internal] Facets associated with the project, used for filtering and categorization. + """ + facets: [Facet!]! + """ + The user's favorite associated with this project. + """ + favorite: Favorite + """ + The resolution of the reminder frequency. + """ + frequencyResolution: FrequencyResolutionType! + """ + The overall health of the project, derived from the most recent project update. Possible values are onTrack, atRisk, or offTrack. Null if no health has been reported. + """ + health: ProjectUpdateHealthType + """ + The time at which the project health was last updated, typically when a new project update is posted. Null if health has never been set. + """ + healthUpdatedAt: DateTime + """ + History entries associated with the project. + """ + history( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): ProjectHistoryConnection! + """ + The icon of the project. Can be an emoji or a decorative icon type. + """ + icon: String + """ + The unique identifier of the entity. + """ + id: ID! + """ + [Internal] The human-readable identifier of the project. Returns the custom identifier override when set, otherwise the default `P--`. Null for projects without a lead team and for legacy projects that have not been backfilled. + """ + identifier: String + """ + The number of in-progress estimation points at the end of each week since project creation. Each entry represents one week. + """ + inProgressScopeHistory: [Float!]! + """ + Associations of this project to parent initiatives. + """ + initiativeToProjects( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): InitiativeToProjectConnection! + """ + Initiatives that this project belongs to. + """ + initiatives( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): InitiativeConnection! + """ + Settings for all integrations associated with that project. + """ + integrationsSettings: IntegrationsSettings + """ + Inverse relations associated with this project. + """ + inverseRelations( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): ProjectRelationConnection! + """ + The total number of issues in the project at the end of each week since project creation. Each entry represents one week. + """ + issueCountHistory: [Float!]! + """ + Issues associated with the project. + """ + issues( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned issues. + """ + filter: IssueFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): IssueConnection! + """ + The IDs of the project labels associated with this project. + """ + labelIds: [String!]! + """ + Labels associated with this project. + """ + labels( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned project labels. + """ + filter: ProjectLabelFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): ProjectLabelConnection! + """ + The last template that was applied to this project. + """ + lastAppliedTemplate: Template + """ + The most recent status update posted for this project. Null if no updates have been posted. + """ + lastUpdate: ProjectUpdate + """ + The user who leads the project. The project lead is typically responsible for posting status updates and driving the project to completion. Null if no lead is assigned. + """ + lead: User + """ + [Internal] The team that leads the project. Null if the viewer does not have access to the team. + """ + leadTeam: Team + """ + [Internal] The ID of the team that leads the project, even when the viewer cannot access the team. + """ + leadTeamId: String! + """ + Users that are members of the project. + """ + members( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned users. + """ + filter: UserFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + Should query return disabled/suspended users (default: false). + """ + includeDisabled: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): UserConnection! + """ + The ID of the Microsoft Teams channel connected to the project, if any. + """ + microsoftTeamsChannelId: String + """ + The name of the project. + """ + name: String! + """ + Customer needs associated with the project. + """ + needs( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned needs. + """ + filter: CustomerNeedFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): CustomerNeedConnection! + """ + [Internal] Identifiers (default and custom) that this project has previously held. Used to resolve URLs that referenced an older identifier. + """ + previousIdentifiers: [String!]! + """ + The priority of the project. 0 = No priority, 1 = Urgent, 2 = High, 3 = Medium, 4 = Low. + """ + priority: Int! + """ + The priority of the project as a label. + """ + priorityLabel: String! + """ + The sort order for the project within the workspace when ordered by priority. + """ + prioritySortOrder: Float! + """ + The overall progress of the project. This is the (completed estimate points + 0.25 * in progress estimate points) / total estimate points. + """ + progress: Float! + """ + [INTERNAL] The progress history of the project, tracking issue completion over time. + """ + progressHistory: JSONObject! + """ + Milestones associated with the project. + """ + projectMilestones( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned milestones. + """ + filter: ProjectMilestoneFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): ProjectMilestoneConnection! + """ + The time until which project update reminders are paused. When set, no update reminders will be sent for this project until this date passes. Null means reminders are active. + """ + projectUpdateRemindersPausedUntilAt: DateTime + """ + Project updates associated with the project. + """ + projectUpdates( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): ProjectUpdateConnection! + """ + Relations associated with this project. + """ + relations( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): ProjectRelationConnection! + """ + The number of resources associated with the project, including documents, external links, and attachments. + """ + resourceCount: Int! + """ + The overall scope (total estimate points) of the project. + """ + scope: Float! + """ + The total scope (estimation points) of the project at the end of each week since project creation. Each entry represents one week. + """ + scopeHistory: [Float!]! + """ + The ID of the Slack channel connected to the project, if any. + """ + slackChannelId: String + """ + Whether to send new issue comment notifications to Slack. + """ + slackIssueComments: Boolean! @deprecated(reason: "No longer in use") + """ + Whether to send new issue status updates to Slack. + """ + slackIssueStatuses: Boolean! @deprecated(reason: "No longer is use") + """ + Whether to send new issue notifications to Slack. + """ + slackNewIssue: Boolean! @deprecated(reason: "No longer in use") + """ + The project's unique URL slug, used to construct human-readable URLs. + """ + slugId: String! + """ + The sort order for the project within the workspace. Used for manual ordering in list views. + """ + sortOrder: Float! + """ + The estimated start date of the project. Null if no start date is set. + """ + startDate: TimelessDate + """ + The resolution of the project's start date, indicating whether it refers to a specific month, quarter, half-year, or year. + """ + startDateResolution: DateResolutionType + """ + The time at which the project was moved into a started status. Null if the project has not been started. + """ + startedAt: DateTime + """ + [DEPRECATED] The type of the state. + """ + state: String! @deprecated(reason: "Use project.status instead") + """ + The current project status. Defines the project's position in its lifecycle (e.g., backlog, planned, started, paused, completed, canceled). + """ + status: ProjectStatus! + """ + The external services the project is synced with. + """ + syncedWith: [ExternalEntityInfo!] + """ + The estimated completion date of the project. Null if no target date is set. + """ + targetDate: TimelessDate + """ + The resolution of the project's estimated completion date, indicating whether it refers to a specific month, quarter, half-year, or year. + """ + targetDateResolution: DateResolutionType + """ + Teams associated with this project. + """ + teams( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned teams. + """ + filter: TeamFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): TeamConnection! + """ + A flag that indicates whether the project is in the trash bin. + """ + trashed: Boolean + """ + The frequency at which to prompt for updates. When not set, reminders are inherited from workspace. + """ + updateReminderFrequency: Float + """ + The n-weekly frequency at which to prompt for updates. When not set, reminders are inherited from workspace. + """ + updateReminderFrequencyInWeeks: Float + """ + The day at which to prompt for updates. + """ + updateRemindersDay: Day + """ + The hour at which to prompt for updates. + """ + updateRemindersHour: Float + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + Project URL. + """ + url: String! +} + +""" +A generic payload return from entity archive mutations. +""" +type ProjectArchivePayload implements ArchivePayload { + """ + The archived/unarchived entity. Null if entity was deleted. + """ + entity: Project + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +An attachment (link, reference, or integration data) associated with a project. Attachments are typically created by integrations and contain metadata for rendering in the client. +""" +type ProjectAttachment implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The creator of the attachment. + """ + creator: User + """ + The unique identifier of the entity. + """ + id: ID! + """ + Custom metadata related to the attachment. Contains user-facing content such as conversation messages or rendered attributes from integrations. + """ + metadata: JSONObject! + """ + Metadata about the external source which created the attachment, including foreign identifiers used for syncing with external services. Null if the attachment was not created by an integration. + """ + source: JSONObject + """ + The source type of the attachment, derived from the source metadata. Returns the integration type that created the attachment (e.g., 'slack', 'github'), or null if not set. + """ + sourceType: String + """ + Optional subtitle of the attachment, providing additional context below the title. + """ + subtitle: String + """ + Title of the attachment. + """ + title: String! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + URL of the attachment. + """ + url: String! +} + +type ProjectAttachmentConnection { + edges: [ProjectAttachmentEdge!]! + nodes: [ProjectAttachment!]! + pageInfo: PageInfo! +} + +type ProjectAttachmentEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: ProjectAttachment! +} + +""" +Certain properties of a project. +""" +type ProjectChildWebhookPayload { + """ + The ID of the project. + """ + id: String! + """ + The name of the project. + """ + name: String! + """ + The URL of the project. + """ + url: String! +} + +""" +Project filtering options. +""" +input ProjectCollectionFilter { + """ + Filters that the project's team must satisfy. + """ + accessibleTeams: TeamCollectionFilter + """ + [ALPHA] Comparator for the project activity type: buzzin, active, some, none + """ + activityType: StringComparator + """ + Compound filters, all of which need to be matched by the project. + """ + and: [ProjectCollectionFilter!] + """ + Comparator for the project cancelation date. + """ + canceledAt: NullableDateComparator + """ + Comparator for the project completion date. + """ + completedAt: NullableDateComparator + """ + Filters that the project's completed milestones must satisfy. + """ + completedProjectMilestones: ProjectMilestoneCollectionFilter + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Filters that the projects creator must satisfy. + """ + creator: UserFilter + """ + [Internal] Comparator for the project's custom identifier. + """ + customIdentifier: NullableStringComparator + """ + Count of customers + """ + customerCount: NumberComparator + """ + Count of important customers + """ + customerImportantCount: NumberComparator + """ + Filters that needs to be matched by all projects. + """ + every: ProjectFilter + """ + Comparator for filtering projects which are blocked. + """ + hasBlockedByRelations: RelationExistsComparator + """ + Comparator for filtering projects which are blocking. + """ + hasBlockingRelations: RelationExistsComparator + """ + [Deprecated] Comparator for filtering projects which this is depended on by. + """ + hasDependedOnByRelations: RelationExistsComparator + """ + [Deprecated]Comparator for filtering projects which this depends on. + """ + hasDependsOnRelations: RelationExistsComparator + """ + Comparator for filtering projects with relations. + """ + hasRelatedRelations: RelationExistsComparator + """ + Comparator for filtering projects with violated dependencies. + """ + hasViolatedRelations: RelationExistsComparator + """ + Comparator for the project health: onTrack, atRisk, offTrack + """ + health: StringComparator + """ + Comparator for the project health (with age): onTrack, atRisk, offTrack, outdated, noUpdate + """ + healthWithAge: StringComparator + """ + Comparator for the identifier. + """ + id: EntityIdentifierIDComparator + """ + Filters that the projects initiatives must satisfy. + """ + initiatives: InitiativeCollectionFilter + """ + Filters that the projects issues must satisfy. + """ + issues: IssueCollectionFilter + """ + Filters that project labels must satisfy. + """ + labels: ProjectLabelCollectionFilter + """ + Filters that the last applied template must satisfy. + """ + lastAppliedTemplate: NullableTemplateFilter + """ + Filters that the projects lead must satisfy. + """ + lead: NullableUserFilter + """ + [ALPHA] Filters that the project's lead team must satisfy. + """ + leadTeam: NullableTeamFilter + """ + Comparator for the collection length. + """ + length: NumberComparator + """ + Filters that the projects members must satisfy. + """ + members: UserCollectionFilter + """ + Comparator for the project name. + """ + name: StringComparator + """ + Filters that the project's customer needs must satisfy. + """ + needs: CustomerNeedCollectionFilter + """ + Filters that the project's next milestone must satisfy. + """ + nextProjectMilestone: ProjectMilestoneFilter + """ + Compound filters, one of which need to be matched by the project. + """ + or: [ProjectCollectionFilter!] + """ + Comparator for the project priority. + """ + priority: NullableNumberComparator + """ + Filters that the project's milestones must satisfy. + """ + projectMilestones: ProjectMilestoneCollectionFilter + """ + Comparator for the project updates. + """ + projectUpdates: ProjectUpdatesCollectionFilter + """ + Filters that the projects roadmaps must satisfy. + """ + roadmaps: RoadmapCollectionFilter + """ + [Internal] Comparator for the project's content. + """ + searchableContent: ContentComparator + """ + Comparator for the project slug ID. + """ + slugId: StringComparator + """ + Filters that needs to be matched by some projects. + """ + some: ProjectFilter + """ + Comparator for the project start date. + """ + startDate: NullableDateComparator + """ + Comparator for the project started date (when it was moved to an "In Progress" status). + """ + startedAt: NullableDateComparator + """ + [DEPRECATED] Comparator for the project state. + """ + state: StringComparator + """ + Filters that the project status must satisfy. + """ + status: ProjectStatusFilter + """ + Comparator for the project target date. + """ + targetDate: NullableDateComparator + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +type ProjectConnection { + edges: [ProjectEdge!]! + nodes: [Project!]! + pageInfo: PageInfo! +} + +""" +Input for creating a new project. A name and at least one team are required. All other fields are optional and will use defaults if not specified. +""" +input ProjectCreateInput { + """ + The color of the project. + """ + color: String + """ + The project content as markdown. + """ + content: String + """ + The ID of the issue that was converted into this project. + """ + convertedFromIssueId: String + """ + The description for the project. + """ + description: String + """ + The icon of the project. + """ + icon: String + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + The identifiers of the project labels associated with this project. + """ + labelIds: [String!] + """ + The ID of the last template applied to the project. + """ + lastAppliedTemplateId: String + """ + The identifier of the project lead. + """ + leadId: String + """ + [Internal] The identifier of the team that leads the project. + """ + leadTeamId: String + """ + The identifiers of the members of this project. + """ + memberIds: [String!] + """ + The name of the project. + """ + name: String! + """ + The priority of the project. 0 = No priority, 1 = Urgent, 2 = High, 3 = Medium, 4 = Low. + """ + priority: Int + """ + The sort order for the project within shared views, when ordered by priority. + """ + prioritySortOrder: Float + """ + The sort order for the project within shared views. + """ + sortOrder: Float + """ + The planned start date of the project. + """ + startDate: TimelessDate + """ + The resolution of the project's start date. + """ + startDateResolution: DateResolutionType + """ + The ID of the project status. + """ + statusId: String + """ + The planned target date of the project. + """ + targetDate: TimelessDate + """ + The resolution of the project's estimated completion date. + """ + targetDateResolution: DateResolutionType + """ + The identifiers of the teams this project is associated with. + """ + teamIds: [String!]! + """ + The ID of a project template to apply when creating the project. Overrides useDefaultTemplate if both are provided. + """ + templateId: String + """ + When set to true, the default project template of the first team provided will be applied. If templateId is provided, this will be ignored. + """ + useDefaultTemplate: Boolean +} + +""" +Project creation date sorting options. +""" +input ProjectCreatedAtSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +type ProjectEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: Project! +} + +""" +Project filtering options. +""" +input ProjectFilter { + """ + Filters that the project's team must satisfy. + """ + accessibleTeams: TeamCollectionFilter + """ + [ALPHA] Comparator for the project activity type: buzzin, active, some, none + """ + activityType: StringComparator + """ + Compound filters, all of which need to be matched by the project. + """ + and: [ProjectFilter!] + """ + Comparator for the project cancelation date. + """ + canceledAt: NullableDateComparator + """ + Comparator for the project completion date. + """ + completedAt: NullableDateComparator + """ + Filters that the project's completed milestones must satisfy. + """ + completedProjectMilestones: ProjectMilestoneCollectionFilter + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Filters that the projects creator must satisfy. + """ + creator: UserFilter + """ + [Internal] Comparator for the project's custom identifier. + """ + customIdentifier: NullableStringComparator + """ + Count of customers + """ + customerCount: NumberComparator + """ + Count of important customers + """ + customerImportantCount: NumberComparator + """ + Comparator for filtering projects which are blocked. + """ + hasBlockedByRelations: RelationExistsComparator + """ + Comparator for filtering projects which are blocking. + """ + hasBlockingRelations: RelationExistsComparator + """ + [Deprecated] Comparator for filtering projects which this is depended on by. + """ + hasDependedOnByRelations: RelationExistsComparator + """ + [Deprecated]Comparator for filtering projects which this depends on. + """ + hasDependsOnRelations: RelationExistsComparator + """ + Comparator for filtering projects with relations. + """ + hasRelatedRelations: RelationExistsComparator + """ + Comparator for filtering projects with violated dependencies. + """ + hasViolatedRelations: RelationExistsComparator + """ + Comparator for the project health: onTrack, atRisk, offTrack + """ + health: StringComparator + """ + Comparator for the project health (with age): onTrack, atRisk, offTrack, outdated, noUpdate + """ + healthWithAge: StringComparator + """ + Comparator for the identifier. + """ + id: EntityIdentifierIDComparator + """ + Filters that the projects initiatives must satisfy. + """ + initiatives: InitiativeCollectionFilter + """ + Filters that the projects issues must satisfy. + """ + issues: IssueCollectionFilter + """ + Filters that project labels must satisfy. + """ + labels: ProjectLabelCollectionFilter + """ + Filters that the last applied template must satisfy. + """ + lastAppliedTemplate: NullableTemplateFilter + """ + Filters that the projects lead must satisfy. + """ + lead: NullableUserFilter + """ + [ALPHA] Filters that the project's lead team must satisfy. + """ + leadTeam: NullableTeamFilter + """ + Filters that the projects members must satisfy. + """ + members: UserCollectionFilter + """ + Comparator for the project name. + """ + name: StringComparator + """ + Filters that the project's customer needs must satisfy. + """ + needs: CustomerNeedCollectionFilter + """ + Filters that the project's next milestone must satisfy. + """ + nextProjectMilestone: ProjectMilestoneFilter + """ + Compound filters, one of which need to be matched by the project. + """ + or: [ProjectFilter!] + """ + Comparator for the project priority. + """ + priority: NullableNumberComparator + """ + Filters that the project's milestones must satisfy. + """ + projectMilestones: ProjectMilestoneCollectionFilter + """ + Comparator for the project updates. + """ + projectUpdates: ProjectUpdatesCollectionFilter + """ + Filters that the projects roadmaps must satisfy. + """ + roadmaps: RoadmapCollectionFilter + """ + [Internal] Comparator for the project's content. + """ + searchableContent: ContentComparator + """ + Comparator for the project slug ID. + """ + slugId: StringComparator + """ + Comparator for the project start date. + """ + startDate: NullableDateComparator + """ + Comparator for the project started date (when it was moved to an "In Progress" status). + """ + startedAt: NullableDateComparator + """ + [DEPRECATED] Comparator for the project state. + """ + state: StringComparator + """ + Filters that the project status must satisfy. + """ + status: ProjectStatusFilter + """ + Comparator for the project target date. + """ + targetDate: NullableDateComparator + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +The result of a project filter suggestion query. +""" +type ProjectFilterSuggestionPayload { + """ + The json filter that is suggested. + """ + filter: JSONObject + """ + The log id of the prompt, that created this filter. + """ + logId: String +} + +""" +Project health sorting options. +""" +input ProjectHealthSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +A history record associated with a project. Tracks changes to project properties, status, members, teams, milestones, labels, and relationships over time. +""" +type ProjectHistory implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The events that happened while recording that history. + """ + entries: JSONObject! + """ + The unique identifier of the entity. + """ + id: ID! + """ + The project that this history record belongs to. + """ + project: Project! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +type ProjectHistoryConnection { + edges: [ProjectHistoryEdge!]! + nodes: [ProjectHistory!]! + pageInfo: PageInfo! +} + +type ProjectHistoryEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: ProjectHistory! +} + +""" +A label that can be applied to projects for categorization. Project labels can be workspace-level (available to all teams) or team-scoped, and can be organized into groups with a parent-child hierarchy. Only child labels (not group labels) can be directly applied to projects. Team-scoped labels may be inherited from parent teams to sub-teams. +""" +type ProjectLabel implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + Children of the label. + """ + children( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned project labels. + """ + filter: ProjectLabelFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): ProjectLabelConnection! + """ + The label's color as a HEX string (e.g., '#EB5757'). Used for visual identification of the label in the UI. + """ + color: String! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The user who created the label. + """ + creator: User + """ + The label's description. + """ + description: String + """ + The selection mode of this label group. Null for regular labels. Groups without a type use single-select behavior. + """ + groupType: LabelGroupType + """ + The unique identifier of the entity. + """ + id: ID! + """ + The original workspace or parent-team label that this label was inherited from. Null if the label is not inherited. + """ + inheritedFrom: ProjectLabel + """ + Whether the label is a group. When true, this label acts as a container for child labels and cannot be directly applied to issues or projects. When false, the label can be directly applied. + """ + isGroup: Boolean! + """ + The date when the label was last applied to an issue, project, or initiative. Null if the label has never been applied. + """ + lastAppliedAt: DateTime + """ + The label's name. + """ + name: String! + """ + The workspace that the project label belongs to. + """ + organization: Organization! + """ + The parent label group. If set, this label is a child within a group. Only one child label from each group can be applied to a project at a time. + """ + parent: ProjectLabel + """ + Projects associated with the label. + """ + projects( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned projects. + """ + filter: ProjectFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + """ + [INTERNAL] Sort returned projects. + """ + sort: [ProjectSortInput!] + ): ProjectConnection! + """ + [Internal] When the label was retired. + """ + retiredAt: DateTime + """ + The user who retired the label. Retired labels cannot be applied to new projects but remain on existing ones. Null if the label is active. + """ + retiredBy: User + """ + The team that the label is scoped to. If null, the label is a workspace-level label available to all teams in the workspace. + """ + team: Team + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +""" +Certain properties of a project label. +""" +type ProjectLabelChildWebhookPayload { + """ + The color of the project label. + """ + color: String! + """ + The ID of the project label. + """ + id: String! + """ + The name of the project label. + """ + name: String! + """ + The parent ID of the project label. + """ + parentId: String +} + +""" +Project label filtering options. +""" +input ProjectLabelCollectionFilter { + """ + Compound filters, all of which need to be matched by the label. + """ + and: [ProjectLabelCollectionFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Filters that the project labels creator must satisfy. + """ + creator: NullableUserFilter + """ + Filters that needs to be matched by all project labels. + """ + every: ProjectLabelFilter + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Comparator for whether the label is a group label. + """ + isGroup: BooleanComparator + """ + Comparator for the collection length. + """ + length: NumberComparator + """ + Comparator for the name. + """ + name: StringComparator + """ + Filter based on the existence of the relation. + """ + null: Boolean + """ + Compound filters, one of which need to be matched by the label. + """ + or: [ProjectLabelCollectionFilter!] + """ + Filters that the project label's parent label must satisfy. + """ + parent: ProjectLabelFilter + """ + Filters that needs to be matched by some project labels. + """ + some: ProjectLabelCollectionFilter + """ + Filters that the project label's team must satisfy. Use `{ null: true }` to filter workspace-level labels. + """ + team: NullableTeamFilter + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +type ProjectLabelConnection { + edges: [ProjectLabelEdge!]! + nodes: [ProjectLabel!]! + pageInfo: PageInfo! +} + +""" +Input for creating a new project label. A name is required. If no team is specified, the label is created as a workspace-level label available to all teams. +""" +input ProjectLabelCreateInput { + """ + The color of the label. + """ + color: String + """ + The description of the label. + """ + description: String + """ + The selection mode of the label group. Null uses single-select behavior. + """ + groupType: LabelGroupType + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + Whether the label is a group. + """ + isGroup: Boolean + """ + The name of the label. + """ + name: String! + """ + The identifier of the parent label. + """ + parentId: String + """ + The time at which the label was retired. Set to null to restore a retired label. + """ + retiredAt: DateTime + """ + The identifier of the team to scope the label to. If not given, the label is a workspace-level label available to all teams. + """ + teamId: String +} + +type ProjectLabelEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: ProjectLabel! +} + +""" +Project label filtering options. +""" +input ProjectLabelFilter { + """ + Compound filters, all of which need to be matched by the label. + """ + and: [ProjectLabelFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Filters that the project labels creator must satisfy. + """ + creator: NullableUserFilter + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Comparator for whether the label is a group label. + """ + isGroup: BooleanComparator + """ + Comparator for the name. + """ + name: StringComparator + """ + Compound filters, one of which need to be matched by the label. + """ + or: [ProjectLabelFilter!] + """ + Filters that the project label's parent label must satisfy. + """ + parent: ProjectLabelFilter + """ + Filters that the project label's team must satisfy. Use `{ null: true }` to filter workspace-level labels. + """ + team: NullableTeamFilter + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +The result of a project label mutation. +""" +type ProjectLabelPayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + The label that was created or updated. + """ + projectLabel: ProjectLabel! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Input for updating an existing project label. All fields are optional; only provided fields will be updated. +""" +input ProjectLabelUpdateInput { + """ + The color of the label. + """ + color: String + """ + The description of the label. + """ + description: String + """ + The selection mode of the label group. Omit to keep the current value. Null uses single-select behavior. + """ + groupType: LabelGroupType + """ + Whether the label is a group. + """ + isGroup: Boolean + """ + The name of the label. + """ + name: String + """ + The identifier of the parent label. + """ + parentId: String + """ + The time at which the label was retired. Set to null to restore a retired label. + """ + retiredAt: DateTime +} + +""" +Payload for a project label webhook. +""" +type ProjectLabelWebhookPayload { + """ + The time at which the entity was archived. + """ + archivedAt: String + """ + The color of the project label. + """ + color: String! + """ + The time at which the entity was created. + """ + createdAt: String! + """ + The creator ID of the project label. + """ + creatorId: String + """ + The label's description. + """ + description: String + """ + The ID of the entity. + """ + id: String! + """ + The ID of the original label this label was inherited from. Null if the label is not inherited. + """ + inheritedFromId: String + """ + Whether the label is a group. + """ + isGroup: Boolean! + """ + The name of the project label. + """ + name: String! + """ + The parent ID of the project label. + """ + parentId: String + """ + The team ID of the project label. Null if the label is a workspace-level label. + """ + teamId: String + """ + The time at which the entity was updated. + """ + updatedAt: String! +} + +""" +Project lead sorting options. +""" +input ProjectLeadSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +Project manual order sorting options. +""" +input ProjectManualSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +A milestone within a project. Milestones break a project into phases or target checkpoints, each with its own target date and set of issues. Issues can be assigned to a milestone to track progress toward that checkpoint. +""" +type ProjectMilestone implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + [Internal] The current progress of the milestone, broken down by issue status category. + """ + currentProgress: JSONObject! + """ + The project milestone's description in markdown format. + """ + description: String + """ + [Internal] The project milestone's description as YJS state. + """ + descriptionState: String + """ + The rich-text content of the milestone description. Null if no description has been set. + """ + documentContent: DocumentContent + """ + The unique identifier of the entity. + """ + id: ID! + """ + Issues associated with the project milestone. + """ + issues( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned issues. + """ + filter: IssueFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): IssueConnection! + """ + The name of the project milestone. + """ + name: String! + """ + The progress % of the project milestone. + """ + progress: Float! + """ + [Internal] The progress history of the milestone, tracking issue completion over time. + """ + progressHistory: JSONObject! + """ + The project that this milestone belongs to. + """ + project: Project! + """ + The order of the milestone in relation to other milestones within a project. + """ + sortOrder: Float! + """ + The status of the project milestone. + """ + status: ProjectMilestoneStatus! + """ + The planned completion date of the milestone. Null if no target date is set. + """ + targetDate: TimelessDate + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +""" +Certain properties of a project milestone. +""" +type ProjectMilestoneChildWebhookPayload { + """ + The ID of the project milestone. + """ + id: String! + """ + The name of the project milestone. + """ + name: String! + """ + The target date of the project milestone. + """ + targetDate: String! +} + +""" +Milestone collection filtering options. +""" +input ProjectMilestoneCollectionFilter { + """ + Compound filters, all of which need to be matched by the milestone. + """ + and: [ProjectMilestoneCollectionFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Filters that needs to be matched by all milestones. + """ + every: ProjectMilestoneFilter + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Comparator for the collection length. + """ + length: NumberComparator + """ + Comparator for the project milestone name. + """ + name: NullableStringComparator + """ + Compound filters, one of which need to be matched by the milestone. + """ + or: [ProjectMilestoneCollectionFilter!] + """ + Filters that the project milestone's project must satisfy. + """ + project: NullableProjectFilter + """ + Filters that needs to be matched by some milestones. + """ + some: ProjectMilestoneFilter + """ + Comparator for the project milestone target date. + """ + targetDate: NullableDateComparator + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +type ProjectMilestoneConnection { + edges: [ProjectMilestoneEdge!]! + nodes: [ProjectMilestone!]! + pageInfo: PageInfo! +} + +""" +Input for creating a new project milestone. +""" +input ProjectMilestoneCreateInput { + """ + The description of the project milestone in markdown format. + """ + description: String + """ + [Internal] The description of the project milestone as a Prosemirror document. + """ + descriptionData: JSONObject + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + The name of the project milestone. + """ + name: String! + """ + Related project for the project milestone. Can be a UUID or project identifier (e.g., 'P-LIN-123'). + """ + projectId: String! + """ + The sort order for the project milestone within a project. + """ + sortOrder: Float + """ + The planned target date of the project milestone. + """ + targetDate: TimelessDate +} + +type ProjectMilestoneEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: ProjectMilestone! +} + +""" +Project milestone filtering options. +""" +input ProjectMilestoneFilter { + """ + Compound filters, all of which need to be matched by the project milestone. + """ + and: [ProjectMilestoneFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Comparator for the project milestone name. + """ + name: NullableStringComparator + """ + Compound filters, one of which need to be matched by the project milestone. + """ + or: [ProjectMilestoneFilter!] + """ + Filters that the project milestone's project must satisfy. + """ + project: NullableProjectFilter + """ + Comparator for the project milestone target date. + """ + targetDate: NullableDateComparator + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +[Internal] Input for moving a project milestone to another project. +""" +input ProjectMilestoneMoveInput { + """ + Whether to add each milestone issue's team to the project. This is needed when there is a mismatch between a project's teams and the milestone's issues' teams. Either this or newIssueTeamId is required in that situation to resolve constraints. + """ + addIssueTeamToProject: Boolean + """ + The team id to move the attached issues to. This is needed when there is a mismatch between a project's teams and the milestone's issues' teams. Either this or addIssueTeamToProject is required in that situation to resolve constraints. + """ + newIssueTeamId: String + """ + The identifier of the project to move the milestone to. + """ + projectId: String! + """ + A list of issue id to team ids, used for undoing a previous milestone move where the specified issues were moved from the specified teams. + """ + undoIssueTeamIds: [ProjectMilestoneMoveIssueToTeamInput!] + """ + A mapping of project id to a previous set of team ids, used for undoing a previous milestone move where the specified teams were added to the project. + """ + undoProjectTeamIds: ProjectMilestoneMoveProjectTeamsInput +} + +type ProjectMilestoneMoveIssueToTeam { + """ + The issue id in this relationship, you can use * as wildcard if all issues are being moved to the same team + """ + issueId: String! + """ + The team id in this relationship + """ + teamId: String! +} + +""" +[Internal] Used for ProjectMilestoneMoveInput to describe a mapping between an issue and its team. +""" +input ProjectMilestoneMoveIssueToTeamInput { + """ + The issue id in this relationship, you can use * as wildcard if all issues are being moved to the same team + """ + issueId: String! + """ + The team id in this relationship + """ + teamId: String! +} + +""" +[Internal] The result of a project milestone move mutation. +""" +type ProjectMilestoneMovePayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + A snapshot of the issues that were moved to new teams, if the user selected to do it, containing an array of mappings between an issue and its previous team. Store on the client to use for undoing a previous milestone move. + """ + previousIssueTeamIds: [ProjectMilestoneMoveIssueToTeam!] + """ + A snapshot of the project that had new teams added to it, if the user selected to do it, containing an array of mappings between a project and its previous teams. Store on the client to use for undoing a previous milestone move. + """ + previousProjectTeamIds: ProjectMilestoneMoveProjectTeams + """ + The project milestone that was created or updated. + """ + projectMilestone: ProjectMilestone! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +type ProjectMilestoneMoveProjectTeams { + """ + The project id + """ + projectId: String! + """ + The team ids for the project + """ + teamIds: [String!]! +} + +""" +[Internal] Used for ProjectMilestoneMoveInput to describe a snapshot of a project and its team ids +""" +input ProjectMilestoneMoveProjectTeamsInput { + """ + The project id + """ + projectId: String! + """ + The team ids for the project + """ + teamIds: [String!]! +} + +""" +The result of a project milestone mutation. +""" +type ProjectMilestonePayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + The project milestone that was created or updated. + """ + projectMilestone: ProjectMilestone! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +The status of a project milestone. +""" +enum ProjectMilestoneStatus { + done + next + overdue + unstarted +} + +""" +Input for updating an existing project milestone. +""" +input ProjectMilestoneUpdateInput { + """ + The description of the project milestone in markdown format. + """ + description: String + """ + [Internal] The description of the project milestone as a Prosemirror document. + """ + descriptionData: JSONObject + """ + The name of the project milestone. + """ + name: String + """ + Related project for the project milestone. Can be a UUID or project identifier (e.g., 'P-LIN-123'). + """ + projectId: String + """ + The sort order for the project milestone within a project. + """ + sortOrder: Float + """ + The planned target date of the project milestone. + """ + targetDate: TimelessDate +} + +""" +Project name sorting options. +""" +input ProjectNameSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +A notification related to a project, such as being added as a member or lead, project updates, comments, or mentions on the project or its milestones. +""" +type ProjectNotification implements Entity & Node & Notification { + """ + The user that caused the notification. Null if the notification was triggered by a non-user actor such as an integration, external user, or system event. + """ + actor: User + """ + [Internal] Notification actor initials if avatar is not available. + """ + actorAvatarColor: String! + """ + [Internal] Notification avatar URL. + """ + actorAvatarUrl: String + """ + [Internal] Whether the notification's user actor is deactivated in the workspace. + """ + actorInactive: Boolean! + """ + [Internal] Notification actor initials if avatar is not available. + """ + actorInitials: String + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The bot that caused the notification. + """ + botActor: ActorBot + """ + The category of the notification. + """ + category: NotificationCategory! + """ + The comment related to the notification. + """ + comment: Comment + """ + Related comment ID. Null if the notification is not related to a comment. + """ + commentId: String + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The document related to the notification. + """ + document: Document + """ + The time at which an email reminder for this notification was sent to the user. Null if no email reminder has been sent. + """ + emailedAt: DateTime + """ + The external user that caused the notification. Populated when the notification was triggered by an external user (e.g., a commenter from a connected integration like Slack or GitHub) rather than a Linear workspace member. + """ + externalUserActor: ExternalUser + """ + [Internal] Notifications with the same grouping key will be grouped together in the UI. + """ + groupingKey: String! + """ + [Internal] Priority of the notification with the same grouping key. Higher number means higher priority. If priority is the same, notifications should be sorted by `createdAt`. + """ + groupingPriority: Float! + """ + The unique identifier of the entity. + """ + id: ID! + """ + [Internal] Inbox URL for the notification. + """ + inboxUrl: String! + """ + [Internal] Initiative update health for new updates. + """ + initiativeUpdateHealth: String + """ + [Internal] If notification actor was Linear. + """ + isLinearActor: Boolean! + """ + [Internal] Issue's status type for issue notifications. + """ + issueStatusType: String + """ + The parent comment related to the notification, if a notification is a reply comment notification. + """ + parentComment: Comment + """ + Related parent comment ID. Null if the notification is not related to a comment. + """ + parentCommentId: String + """ + The project related to the notification. + """ + project: Project! + """ + Related project ID. + """ + projectId: String! + """ + Related project milestone ID. + """ + projectMilestoneId: String + """ + The project update related to the notification. + """ + projectUpdate: ProjectUpdate + """ + [Internal] Project update health for new updates. + """ + projectUpdateHealth: String + """ + Related project update ID. + """ + projectUpdateId: String + """ + Name of the reaction emoji related to the notification. + """ + reactionEmoji: String + """ + The time at which the user marked the notification as read. Null if the notification is unread. + """ + readAt: DateTime + """ + The time until which a notification is snoozed. After this time, the notification reappears in the user's inbox. Null if the notification is not currently snoozed. + """ + snoozedUntilAt: DateTime + """ + [Internal] Notification subtitle. + """ + subtitle: String! + """ + [Internal] Notification title. + """ + title: String! + """ + Notification type. Determines the kind of event that triggered this notification and which associated entity fields will be populated. + """ + type: String! + """ + The time at which a notification was unsnoozed. Null if the notification has not been unsnoozed. + """ + unsnoozedAt: DateTime + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + [Internal] URL to the target of the notification. + """ + url: String! + """ + The recipient user of this notification. + """ + user: User! +} + +""" +A notification subscription scoped to a specific project. The subscriber receives notifications for events related to this project, such as updates, comments, and membership changes. +""" +type ProjectNotificationSubscription implements Entity & Node & NotificationSubscription { + """ + Whether the subscription is active. When inactive, no notifications are generated from this subscription even though it still exists. + """ + active: Boolean! + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The type of contextual view (e.g., active issues, backlog) that further scopes a team notification subscription. Null if the subscription is not associated with a specific view type. + """ + contextViewType: ContextViewType + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The custom view that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + customView: CustomView + """ + The customer that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + customer: Customer + """ + The cycle that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + cycle: Cycle + """ + The unique identifier of the entity. + """ + id: ID! + """ + Whether initiative update notifications also include updates from sub-initiatives. Applies only when initiative updates are enabled and the workspace supports sub-initiatives. + """ + includeSubInitiativeUpdates: Boolean! + """ + The initiative that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + initiative: Initiative + """ + The issue label that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + label: IssueLabel + """ + The notification event types that this subscription will deliver to the subscriber. + """ + notificationSubscriptionTypes: [String!]! + """ + The project subscribed to. + """ + project: Project! + """ + The user who will receive notifications from this subscription. + """ + subscriber: User! + """ + The team that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + team: Team + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The user that this notification subscription is scoped to, for user-specific view subscriptions. Null if the subscription targets a different entity type. + """ + user: User + """ + The type of user-specific view that further scopes a user notification subscription. Null if the subscription is not associated with a user view type. + """ + userContextViewType: UserContextViewType +} + +""" +The result of a project mutation. +""" +type ProjectPayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + The project that was created or updated. + """ + project: Project + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Project priority sorting options. +""" +input ProjectPrioritySort { + """ + Whether to consider no priority as the highest or lowest priority + """ + noPriorityFirst: Boolean = false + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +A dependency relation between two projects. Relations can optionally be anchored to specific milestones within each project, allowing fine-grained dependency tracking. +""" +type ProjectRelation implements Node { + """ + The type of anchor on the source project end of the relation, indicating whether it is anchored to the project itself or a specific milestone. + """ + anchorType: String! + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The unique identifier of the entity. + """ + id: ID! + """ + The source project in the dependency relation. + """ + project: Project! + """ + The specific milestone within the source project that the relation is anchored to. Null if the relation applies to the project as a whole. + """ + projectMilestone: ProjectMilestone + """ + The type of anchor on the target project end of the relation, indicating whether it is anchored to the project itself or a specific milestone. + """ + relatedAnchorType: String! + """ + The target project in the dependency relation. + """ + relatedProject: Project! + """ + The specific milestone within the target project that the relation is anchored to. Null if the relation applies to the target project as a whole. + """ + relatedProjectMilestone: ProjectMilestone + """ + The type of dependency relationship from the project to the related project (e.g., blocks). + """ + type: String! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The user who last created or modified the relation. Null if the user has been deleted. + """ + user: User +} + +type ProjectRelationConnection { + edges: [ProjectRelationEdge!]! + nodes: [ProjectRelation!]! + pageInfo: PageInfo! +} + +""" +Input for creating a new project relation. +""" +input ProjectRelationCreateInput { + """ + The type of the anchor for the project. + """ + anchorType: String! + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + The identifier of the project that is related to another project. Can be a UUID or project identifier (e.g., 'P-LIN-123'). + """ + projectId: String! + """ + The identifier of the project milestone. + """ + projectMilestoneId: String + """ + The type of the anchor for the related project. + """ + relatedAnchorType: String! + """ + The identifier of the related project. Can be a UUID or project identifier (e.g., 'P-LIN-123'). + """ + relatedProjectId: String! + """ + The identifier of the related project milestone. + """ + relatedProjectMilestoneId: String + """ + The type of relation of the project to the related project. + """ + type: String! +} + +type ProjectRelationEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: ProjectRelation! +} + +""" +The result of a project relation mutation. +""" +type ProjectRelationPayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + The project relation that was created or updated. + """ + projectRelation: ProjectRelation! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Input for updating an existing project relation. +""" +input ProjectRelationUpdateInput { + """ + The type of the anchor for the project. + """ + anchorType: String + """ + The identifier of the project that is related to another project. Can be a UUID or project identifier (e.g., 'P-LIN-123'). + """ + projectId: String + """ + The identifier of the project milestone. + """ + projectMilestoneId: String + """ + The type of the anchor for the related project. + """ + relatedAnchorType: String + """ + The identifier of the related project. Can be a UUID or project identifier (e.g., 'P-LIN-123'). + """ + relatedProjectId: String + """ + The identifier of the related project milestone. + """ + relatedProjectMilestoneId: String + """ + The type of relation of the project to the related project. + """ + type: String +} + +type ProjectSearchPayload { + """ + Archived entities matching the search term along with all their dependencies, serialized for the client sync engine. + """ + archivePayload: ArchiveResponse! + edges: [ProjectSearchResultEdge!]! + nodes: [ProjectSearchResult!]! + pageInfo: PageInfo! + """ + Total number of matching results before pagination is applied. + """ + totalCount: Float! +} + +type ProjectSearchResult implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + Attachments associated with the project. + """ + attachments( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): ProjectAttachmentConnection! + """ + The time at which the project was automatically archived by the auto-pruning process. Null if the project has not been auto-archived. + """ + autoArchivedAt: DateTime + """ + The time at which the project was moved into a canceled status. Null if the project has not been canceled. + """ + canceledAt: DateTime + """ + The project's color as a HEX string. Used in the UI to visually identify the project. + """ + color: String! + """ + Comments associated with the project overview. + """ + comments( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned comments. + """ + filter: CommentFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): CommentConnection! + """ + The time at which the project was moved into a completed status. Null if the project has not been completed. + """ + completedAt: DateTime + """ + The number of completed issues in the project at the end of each week since project creation. Each entry represents one week. + """ + completedIssueCountHistory: [Float!]! + """ + The number of completed estimation points at the end of each week since project creation. Each entry represents one week. + """ + completedScopeHistory: [Float!]! + """ + The project's content in markdown format. + """ + content: String + """ + [Internal] The project's content as YJS state. + """ + contentState: String + """ + The issue that was converted into this project. Null if the project was not created from an issue. + """ + convertedFromIssue: Issue + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The user who created the project. + """ + creator: User + """ + [INTERNAL] The current progress of the project, broken down by issue status category. + """ + currentProgress: JSONObject! + """ + The short description of the project. + """ + description: String! + """ + The content of the project description. + """ + documentContent: DocumentContent + """ + Documents associated with the project. + """ + documents( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned documents. + """ + filter: DocumentFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): DocumentConnection! + """ + External links associated with the project. + """ + externalLinks( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): EntityExternalLinkConnection! + """ + [Internal] Facets associated with the project, used for filtering and categorization. + """ + facets: [Facet!]! + """ + The user's favorite associated with this project. + """ + favorite: Favorite + """ + The resolution of the reminder frequency. + """ + frequencyResolution: FrequencyResolutionType! + """ + The overall health of the project, derived from the most recent project update. Possible values are onTrack, atRisk, or offTrack. Null if no health has been reported. + """ + health: ProjectUpdateHealthType + """ + The time at which the project health was last updated, typically when a new project update is posted. Null if health has never been set. + """ + healthUpdatedAt: DateTime + """ + History entries associated with the project. + """ + history( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): ProjectHistoryConnection! + """ + The icon of the project. Can be an emoji or a decorative icon type. + """ + icon: String + """ + The unique identifier of the entity. + """ + id: ID! + """ + [Internal] The human-readable identifier of the project. Returns the custom identifier override when set, otherwise the default `P--`. Null for projects without a lead team and for legacy projects that have not been backfilled. + """ + identifier: String + """ + The number of in-progress estimation points at the end of each week since project creation. Each entry represents one week. + """ + inProgressScopeHistory: [Float!]! + """ + Associations of this project to parent initiatives. + """ + initiativeToProjects( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): InitiativeToProjectConnection! + """ + Initiatives that this project belongs to. + """ + initiatives( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): InitiativeConnection! + """ + Settings for all integrations associated with that project. + """ + integrationsSettings: IntegrationsSettings + """ + Inverse relations associated with this project. + """ + inverseRelations( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): ProjectRelationConnection! + """ + The total number of issues in the project at the end of each week since project creation. Each entry represents one week. + """ + issueCountHistory: [Float!]! + """ + Issues associated with the project. + """ + issues( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned issues. + """ + filter: IssueFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): IssueConnection! + """ + The IDs of the project labels associated with this project. + """ + labelIds: [String!]! + """ + Labels associated with this project. + """ + labels( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned project labels. + """ + filter: ProjectLabelFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): ProjectLabelConnection! + """ + The last template that was applied to this project. + """ + lastAppliedTemplate: Template + """ + The most recent status update posted for this project. Null if no updates have been posted. + """ + lastUpdate: ProjectUpdate + """ + The user who leads the project. The project lead is typically responsible for posting status updates and driving the project to completion. Null if no lead is assigned. + """ + lead: User + """ + [Internal] The team that leads the project. Null if the viewer does not have access to the team. + """ + leadTeam: Team + """ + [Internal] The ID of the team that leads the project, even when the viewer cannot access the team. + """ + leadTeamId: String! + """ + Users that are members of the project. + """ + members( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned users. + """ + filter: UserFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + Should query return disabled/suspended users (default: false). + """ + includeDisabled: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): UserConnection! + """ + Metadata related to search result. + """ + metadata: JSONObject! + """ + The ID of the Microsoft Teams channel connected to the project, if any. + """ + microsoftTeamsChannelId: String + """ + The name of the project. + """ + name: String! + """ + Customer needs associated with the project. + """ + needs( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned needs. + """ + filter: CustomerNeedFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): CustomerNeedConnection! + """ + [Internal] Identifiers (default and custom) that this project has previously held. Used to resolve URLs that referenced an older identifier. + """ + previousIdentifiers: [String!]! + """ + The priority of the project. 0 = No priority, 1 = Urgent, 2 = High, 3 = Medium, 4 = Low. + """ + priority: Int! + """ + The priority of the project as a label. + """ + priorityLabel: String! + """ + The sort order for the project within the workspace when ordered by priority. + """ + prioritySortOrder: Float! + """ + The overall progress of the project. This is the (completed estimate points + 0.25 * in progress estimate points) / total estimate points. + """ + progress: Float! + """ + [INTERNAL] The progress history of the project, tracking issue completion over time. + """ + progressHistory: JSONObject! + """ + Milestones associated with the project. + """ + projectMilestones( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned milestones. + """ + filter: ProjectMilestoneFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): ProjectMilestoneConnection! + """ + The time until which project update reminders are paused. When set, no update reminders will be sent for this project until this date passes. Null means reminders are active. + """ + projectUpdateRemindersPausedUntilAt: DateTime + """ + Project updates associated with the project. + """ + projectUpdates( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): ProjectUpdateConnection! + """ + Relations associated with this project. + """ + relations( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): ProjectRelationConnection! + """ + The number of resources associated with the project, including documents, external links, and attachments. + """ + resourceCount: Int! + """ + The overall scope (total estimate points) of the project. + """ + scope: Float! + """ + The total scope (estimation points) of the project at the end of each week since project creation. Each entry represents one week. + """ + scopeHistory: [Float!]! + """ + The ID of the Slack channel connected to the project, if any. + """ + slackChannelId: String + """ + Whether to send new issue comment notifications to Slack. + """ + slackIssueComments: Boolean! @deprecated(reason: "No longer in use") + """ + Whether to send new issue status updates to Slack. + """ + slackIssueStatuses: Boolean! @deprecated(reason: "No longer is use") + """ + Whether to send new issue notifications to Slack. + """ + slackNewIssue: Boolean! @deprecated(reason: "No longer in use") + """ + The project's unique URL slug, used to construct human-readable URLs. + """ + slugId: String! + """ + The sort order for the project within the workspace. Used for manual ordering in list views. + """ + sortOrder: Float! + """ + The estimated start date of the project. Null if no start date is set. + """ + startDate: TimelessDate + """ + The resolution of the project's start date, indicating whether it refers to a specific month, quarter, half-year, or year. + """ + startDateResolution: DateResolutionType + """ + The time at which the project was moved into a started status. Null if the project has not been started. + """ + startedAt: DateTime + """ + [DEPRECATED] The type of the state. + """ + state: String! @deprecated(reason: "Use project.status instead") + """ + The current project status. Defines the project's position in its lifecycle (e.g., backlog, planned, started, paused, completed, canceled). + """ + status: ProjectStatus! + """ + The external services the project is synced with. + """ + syncedWith: [ExternalEntityInfo!] + """ + The estimated completion date of the project. Null if no target date is set. + """ + targetDate: TimelessDate + """ + The resolution of the project's estimated completion date, indicating whether it refers to a specific month, quarter, half-year, or year. + """ + targetDateResolution: DateResolutionType + """ + Teams associated with this project. + """ + teams( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned teams. + """ + filter: TeamFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): TeamConnection! + """ + A flag that indicates whether the project is in the trash bin. + """ + trashed: Boolean + """ + The frequency at which to prompt for updates. When not set, reminders are inherited from workspace. + """ + updateReminderFrequency: Float + """ + The n-weekly frequency at which to prompt for updates. When not set, reminders are inherited from workspace. + """ + updateReminderFrequencyInWeeks: Float + """ + The day at which to prompt for updates. + """ + updateRemindersDay: Day + """ + The hour at which to prompt for updates. + """ + updateRemindersHour: Float + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + Project URL. + """ + url: String! +} + +type ProjectSearchResultEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: ProjectSearchResult! +} + +""" +Issue project sorting options. +""" +input ProjectSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +Project sorting options. +""" +input ProjectSortInput { + """ + Sort by project creation date + """ + createdAt: ProjectCreatedAtSort + """ + Sort by project health status. + """ + health: ProjectHealthSort + """ + Sort by project lead name. + """ + lead: ProjectLeadSort + """ + Sort by manual order + """ + manual: ProjectManualSort + """ + Sort by project name + """ + name: ProjectNameSort + """ + Sort by project priority + """ + priority: ProjectPrioritySort + """ + Sort by project start date + """ + startDate: StartDateSort + """ + Sort by project status + """ + status: ProjectStatusSort + """ + Sort by project target date + """ + targetDate: TargetDateSort + """ + Sort by project update date + """ + updatedAt: ProjectUpdatedAtSort +} + +""" +A custom project status within a workspace. Statuses are grouped by type (backlog, planned, started, paused, completed, canceled) and define the lifecycle stages a project can move through. Each workspace can customize the names and colors of its project statuses. +""" +type ProjectStatus implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The color of the status as a HEX string, used for display in the UI. + """ + color: String! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + Description of the status. + """ + description: String + """ + The unique identifier of the entity. + """ + id: ID! + """ + Whether a project can remain in this status indefinitely. When false, projects in this status may trigger reminders or auto-archiving after a period of inactivity. + """ + indefinite: Boolean! + """ + [Internal] The original workspace or parent-team status that this status was inherited from. Null if the status is not inherited. + """ + inheritedFrom: ProjectStatus + """ + The name of the status. + """ + name: String! + """ + The position of the status within its type group in the workspace's project flow. Used for ordering statuses of the same type. + """ + position: Float! + """ + [Internal] The team that the status is scoped to. If null, the status is a workspace-level status. + """ + team: Team + """ + [Internal] The ID of the team that owns the status, even when the viewer cannot access the team. Null for workspace statuses. + """ + teamId: String + """ + The category type of the project status (e.g., backlog, planned, started, paused, completed, canceled). Determines the status's behavior and position in the project lifecycle. + """ + type: ProjectStatusType! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +""" +A generic payload return from entity archive mutations. +""" +type ProjectStatusArchivePayload implements ArchivePayload { + """ + The archived/unarchived entity. Null if entity was deleted. + """ + entity: ProjectStatus + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Certain properties of a project status. +""" +type ProjectStatusChildWebhookPayload { + """ + The color of the project status. + """ + color: String! + """ + The ID of the project status. + """ + id: String! + """ + The name of the project status. + """ + name: String! + """ + The type of the project status. + """ + type: String! +} + +type ProjectStatusConnection { + edges: [ProjectStatusEdge!]! + nodes: [ProjectStatus!]! + pageInfo: PageInfo! +} + +""" +The count of projects using a specific project status. +""" +type ProjectStatusCountPayload { + """ + Total number of projects using this project status that are not visible to the user because they are in an archived team. + """ + archivedTeamCount: Float! + """ + Total number of projects using this project status. + """ + count: Float! + """ + Total number of projects using this project status that are not visible to the user because they are in a private team. + """ + privateCount: Float! +} + +""" +Input for creating a new project status. +""" +input ProjectStatusCreateInput { + """ + The UI color of the status as a HEX string. + """ + color: String! + """ + Description of the status. + """ + description: String + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + Whether or not a project can be in this status indefinitely. + """ + indefinite: Boolean = false + """ + The name of the status. + """ + name: String! + """ + The position of the status in the workspace's project flow. + """ + position: Float! + """ + [Internal] The identifier of the team to scope the status to. If not given, the status is a workspace-level status. + """ + teamId: String + """ + The type of the project status. + """ + type: ProjectStatusType! +} + +type ProjectStatusEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: ProjectStatus! +} + +""" +Project status filtering options. +""" +input ProjectStatusFilter { + """ + Compound filters, all of which need to be matched by the project status. + """ + and: [ProjectStatusFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for the project status description. + """ + description: StringComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Comparator for the project status name. + """ + name: StringComparator + """ + Compound filters, one of which needs to be matched by the project status. + """ + or: [ProjectStatusFilter!] + """ + Comparator for the project status position. + """ + position: NumberComparator + """ + Filters that the project status projects must satisfy. + """ + projects: ProjectCollectionFilter + """ + Filters that the project status's team must satisfy. Use `{ null: true }` to filter workspace-level statuses. + """ + team: NullableTeamFilter + """ + Comparator for the project status type. + """ + type: StringComparator + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +The result of a project status mutation. +""" +type ProjectStatusPayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + The project status that was created or updated. + """ + status: ProjectStatus! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Project status sorting options. +""" +input ProjectStatusSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +A type of project status. +""" +enum ProjectStatusType { + backlog + canceled + completed + paused + planned + started +} + +""" +Input for updating an existing project status. +""" +input ProjectStatusUpdateInput { + """ + The UI color of the status as a HEX string. + """ + color: String + """ + Description of the status. + """ + description: String + """ + Whether or not a project can be in this status indefinitely. + """ + indefinite: Boolean + """ + The name of the status. + """ + name: String + """ + The position of the status in the workspace's project flow. + """ + position: Float + """ + The type of the project status. + """ + type: ProjectStatusType +} + +""" +Different tabs available inside a project. +""" +enum ProjectTab { + customers + documents + issues + loops + updates +} + +""" +A status update posted to a project. Project updates communicate progress, health, and blockers to stakeholders. Each update captures the project's health at the time of writing and includes a rich-text body with the update content. +""" +type ProjectUpdate implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The update content in markdown format. + """ + body: String! + """ + [Internal] The content of the update as a Prosemirror document. + """ + bodyData: String! + """ + Number of comments associated with the project update. + """ + commentCount: Int! + """ + Comments associated with the project update. + """ + comments( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned comments. + """ + filter: CommentFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): CommentConnection! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The diff between the current update and the previous one. + """ + diff: JSONObject + """ + The diff between the current update and the previous one, formatted as markdown. + """ + diffMarkdown: String + """ + The time the update was edited. + """ + editedAt: DateTime + """ + The health of the project at the time this update was posted. Possible values are onTrack, atRisk, or offTrack. + """ + health: ProjectUpdateHealthType! + """ + The unique identifier of the entity. + """ + id: ID! + """ + [Internal] A snapshot of project properties at the time the update was posted, including team, milestone, and issue statistics. Used to compute diffs between consecutive updates. + """ + infoSnapshot: JSONObject + """ + Whether the diff between this update and the previous one should be hidden in the UI. + """ + isDiffHidden: Boolean! + """ + Whether the project update is stale. + """ + isStale: Boolean! + """ + The project that this status update was posted to. + """ + project: Project! + """ + Emoji reaction summary, grouped by emoji type. + """ + reactionData: JSONObject! + """ + Reactions associated with the project update. + """ + reactions: [Reaction!]! + """ + A short AI-generated summary of the project update. Null if no short summary is available. + """ + shortSummary: String + """ + The update's unique URL slug. + """ + slugId: String! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The URL to the project update. + """ + url: String! + """ + The user who wrote the update. + """ + user: User! +} + +""" +A generic payload return from entity archive mutations. +""" +type ProjectUpdateArchivePayload implements ArchivePayload { + """ + The archived/unarchived entity. Null if entity was deleted. + """ + entity: ProjectUpdate + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Certain properties of a project update. +""" +type ProjectUpdateChildWebhookPayload { + """ + The body of the project update. + """ + body: String! + """ + The ID of the project update. + """ + id: String! + """ + The project that the project update belongs to. + """ + project: ProjectChildWebhookPayload! + """ + The ID of the user who wrote the project update. + """ + userId: String! +} + +type ProjectUpdateConnection { + edges: [ProjectUpdateEdge!]! + nodes: [ProjectUpdate!]! + pageInfo: PageInfo! +} + +""" +Input for creating a new project update. +""" +input ProjectUpdateCreateInput { + """ + The content of the project update in markdown format. + """ + body: String + """ + [Internal] The content of the project update as a Prosemirror document. + """ + bodyData: JSON + """ + The health of the project at the time of the update. + """ + health: ProjectUpdateHealthType + """ + The identifier. If none is provided, the backend will generate one. + """ + id: String + """ + Whether the diff between the current update and the previous one should be hidden. + """ + isDiffHidden: Boolean + """ + The project to associate the project update with. Can be a UUID or project identifier (e.g., 'P-LIN-123'). + """ + projectId: String! +} + +type ProjectUpdateEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: ProjectUpdate! +} + +""" +Options for filtering project updates. +""" +input ProjectUpdateFilter { + """ + Compound filters, all of which need to be matched by the ProjectUpdate. + """ + and: [ProjectUpdateFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Compound filters, one of which need to be matched by the ProjectUpdate. + """ + or: [ProjectUpdateFilter!] + """ + Filters that the project update project must satisfy. + """ + project: ProjectFilter + """ + Filters that the project updates reactions must satisfy. + """ + reactions: ReactionCollectionFilter + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator + """ + Filters that the project update creator must satisfy. + """ + user: UserFilter +} + +""" +The health type when the project update is created. +""" +enum ProjectUpdateHealthType { + atRisk + offTrack + onTrack +} + +""" +Input for updating an existing project. All fields are optional; only provided fields will be updated. Setting a field to null (where supported) will clear the value. +""" +input ProjectUpdateInput { + """ + The time at which the project was canceled. + """ + canceledAt: DateTime + """ + The color of the project. + """ + color: String + """ + The time at which the project was completed. + """ + completedAt: DateTime + """ + The project content as markdown. + """ + content: String + """ + The ID of the issue from which that project is created. + """ + convertedFromIssueId: String + """ + The description for the project. + """ + description: String + """ + The resolution type for the update reminder frequency (e.g., weekly, biweekly). + """ + frequencyResolution: FrequencyResolutionType + """ + The icon of the project. + """ + icon: String + """ + The identifiers of the project labels associated with this project. + """ + labelIds: [String!] + """ + The ID of the last template applied to the project. + """ + lastAppliedTemplateId: String + """ + The identifier of the project lead. + """ + leadId: String + """ + [Internal] The identifier of the team that leads the project. + """ + leadTeamId: String + """ + The identifiers of the members of this project. + """ + memberIds: [String!] + """ + The name of the project. + """ + name: String + """ + The priority of the project. 0 = No priority, 1 = Urgent, 2 = High, 3 = Medium, 4 = Low. + """ + priority: Int + """ + The sort order for the project within shared views, when ordered by priority. + """ + prioritySortOrder: Float + """ + The time until which project update reminders are paused. Set to null to resume reminders. + """ + projectUpdateRemindersPausedUntilAt: DateTime + """ + Whether to send new issue comment notifications to Slack. + """ + slackIssueComments: Boolean + """ + Whether to send issue status update notifications to Slack. + """ + slackIssueStatuses: Boolean + """ + Whether to send new issue notifications to Slack. + """ + slackNewIssue: Boolean + """ + The sort order for the project in shared views. + """ + sortOrder: Float + """ + The planned start date of the project. + """ + startDate: TimelessDate + """ + The resolution of the project's start date. + """ + startDateResolution: DateResolutionType + """ + The ID of the project status. + """ + statusId: String + """ + The planned target date of the project. + """ + targetDate: TimelessDate + """ + The resolution of the project's estimated completion date. + """ + targetDateResolution: DateResolutionType + """ + The identifiers of the teams this project is associated with. + """ + teamIds: [String!] + """ + Whether the project has been trashed. Set to true to trash, or null to restore. + """ + trashed: Boolean + """ + The frequency at which to prompt for project updates. When not set, reminders are inherited from workspace settings. + """ + updateReminderFrequency: Float + """ + The n-weekly frequency at which to prompt for project updates. When not set, reminders are inherited from workspace settings. + """ + updateReminderFrequencyInWeeks: Float + """ + The day of the week on which to prompt for project updates. + """ + updateRemindersDay: Day + """ + The hour of the day (0-23) at which to prompt for project updates. + """ + updateRemindersHour: Int +} + +""" +The result of a project update mutation. +""" +type ProjectUpdatePayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + The project update that was created or updated. + """ + projectUpdate: ProjectUpdate! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +The frequency at which to send project update reminders. +""" +enum ProjectUpdateReminderFrequency { + month + never + twoWeeks + week +} + +""" +The result of a project update reminder mutation. +""" +type ProjectUpdateReminderPayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Input for updating an existing project update. +""" +input ProjectUpdateUpdateInput { + """ + The content of the project update in markdown format. + """ + body: String + """ + The content of the project update as a Prosemirror document. + """ + bodyData: JSON + """ + The health of the project at the time of the update. + """ + health: ProjectUpdateHealthType +} + +""" +Payload for a project update webhook. +""" +type ProjectUpdateWebhookPayload { + """ + The time at which the entity was archived. + """ + archivedAt: String + """ + The body of the project update. + """ + body: String! + """ + The body data of the project update. + """ + bodyData: String! + """ + The time at which the entity was created. + """ + createdAt: String! + """ + The diff between the current update and the previous one, formatted as markdown. + """ + diffMarkdown: String + """ + The edited at timestamp of the project update. + """ + editedAt: String! + """ + The health of the project update. + """ + health: String! + """ + The ID of the entity. + """ + id: String! + """ + The project that the project update belongs to. + """ + project: ProjectChildWebhookPayload! + """ + The project id of the project update. + """ + projectId: String! + """ + The reaction data for this project update. + """ + reactionData: JSONObject! + """ + The slug id of the project update. + """ + slugId: String! + """ + The time at which the entity was updated. + """ + updatedAt: String! + """ + The URL of the project update. + """ + url: String + """ + The user who wrote the project update. + """ + user: UserChildWebhookPayload! + """ + The user id of the project update. + """ + userId: String! +} + +""" +Project update date sorting options. +""" +input ProjectUpdatedAtSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +Collection filtering options for filtering projects by project updates. +""" +input ProjectUpdatesCollectionFilter { + """ + Compound filters, all of which need to be matched by the project update. + """ + and: [ProjectUpdatesCollectionFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Filters that needs to be matched by all updates. + """ + every: ProjectUpdatesFilter + """ + Comparator for the project update health. + """ + health: StringComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Comparator for the collection length. + """ + length: NumberComparator + """ + Compound filters, one of which need to be matched by the update. + """ + or: [ProjectUpdatesCollectionFilter!] + """ + Filters that needs to be matched by some updates. + """ + some: ProjectUpdatesFilter + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +Options for filtering projects by project updates. +""" +input ProjectUpdatesFilter { + """ + Compound filters, all of which need to be matched by the project updates. + """ + and: [ProjectUpdatesFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for the project update health. + """ + health: StringComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Compound filters, one of which need to be matched by the project updates. + """ + or: [ProjectUpdatesFilter!] + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +Payload for a project webhook. +""" +type ProjectWebhookPayload { + """ + The time at which the entity was archived. + """ + archivedAt: String + """ + The auto archived at timestamp of the project. + """ + autoArchivedAt: String + """ + The canceled at timestamp of the project. + """ + canceledAt: String + """ + The project's color. + """ + color: String! + """ + The completed at timestamp of the project. + """ + completedAt: String + """ + The number of completed issues in the project after each week. + """ + completedIssueCountHistory: [Float!]! + """ + The number of completed estimation points after each week. + """ + completedScopeHistory: [Float!]! + """ + The content of the project. + """ + content: String + """ + The ID of the issue that was converted to the project. + """ + convertedFromIssueId: String + """ + The time at which the entity was created. + """ + createdAt: String! + """ + The ID of the user who created the project. + """ + creatorId: String + """ + The project's description. + """ + description: String! + """ + The document content ID of the project. + """ + documentContentId: String + """ + The health of the project. + """ + health: String + """ + The time at which the project health was updated. + """ + healthUpdatedAt: String + """ + The icon of the project. + """ + icon: String + """ + The ID of the entity. + """ + id: String! + """ + The human-readable identifier of the project. + """ + identifier: String + """ + The number of in progress estimation points after each week. + """ + inProgressScopeHistory: [Float!]! + """ + The initiatives associated with the project. + """ + initiatives: [InitiativeChildWebhookPayload!] + """ + The total number of issues in the project after each week. + """ + issueCountHistory: [Float!]! + """ + IDs of the labels associated with this project. + """ + labelIds: [String!]! + """ + The ID of the last template that was applied to the project. + """ + lastAppliedTemplateId: String + """ + The ID of the last update posted for this project. + """ + lastUpdateId: String + """ + The project lead. + """ + lead: UserChildWebhookPayload + """ + The ID of the project lead. + """ + leadId: String + """ + IDs of the members of the project. + """ + memberIds: [String!]! + """ + The milestones associated with the project. + """ + milestones: [ProjectMilestoneChildWebhookPayload!] + """ + The project's name. + """ + name: String! + """ + Previous identifiers of the project. + """ + previousIdentifiers: [String!] + """ + The priority of the project. 0 = No priority, 1 = Urgent, 2 = High, 3 = Medium, 4 = Low. + """ + priority: Float! + """ + The sort order for the project within the organization, when ordered by priority. + """ + prioritySortOrder: Float! + """ + The time at which the project update reminders were paused until. + """ + projectUpdateRemindersPausedUntilAt: String + """ + The total number of estimation points after each week. + """ + scopeHistory: [Float!]! + """ + The project's unique URL slug. + """ + slugId: String! + """ + The sort order for the project within the organization. + """ + sortOrder: Float! + """ + The estimated start date of the project. + """ + startDate: String + """ + The resolution of the project's estimated start date. + """ + startDateResolution: String + """ + The time at which the project was moved into started state. + """ + startedAt: String + """ + The project status. + """ + status: ProjectStatusChildWebhookPayload + """ + The ID of the project status. + """ + statusId: String! + """ + The external services the project is synced with. + """ + syncedWith: JSONObject + """ + The target date of the project. + """ + targetDate: String + """ + The resolution of the project's target date. + """ + targetDateResolution: String + """ + IDs of the teams associated with this project. + """ + teamIds: [String!]! + """ + The trashed status of the project. + """ + trashed: Boolean + """ + The time at which the entity was updated. + """ + updatedAt: String! + """ + The URL of the project. + """ + url: String! +} + +""" +[Internal] A pull or merge request from a connected version control system (GitHub or GitLab). Pull requests are automatically linked to Linear issues via branch names or commit messages containing issue identifiers. They track the full lifecycle including status, reviewers, checks, and merge state, and are synced bidirectionally with the hosting provider. +""" +type PullRequest implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + Whether auto-merge is enabled for the pull request. + """ + autoMergeEnabled: Boolean! + """ + The Git SHA of the base commit on the target branch that the pull request is compared against. Null if not yet synced. + """ + baseSha: String + """ + [Internal] The CI/CD checks and status checks associated with the pull request, synced from the hosting provider. + """ + checks: [PullRequestCheck!]! + """ + The time at which the pull request was closed. Hosting providers also set this when a pull request is merged, so read `status` to tell a closed pull request from a merged one. Null while the pull request is still open. + """ + closedAt: DateTime + """ + [ALPHA] The commits included in the pull request, synced from the hosting provider. Includes metadata such as SHA, message, diff stats, and author information. + """ + commits: [PullRequestCommit!]! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + [Internal] The Linear user who created the pull request. Null if the creator is an external user not mapped to a Linear account, or if the creator's account has been deleted. + """ + creator: User + """ + [Internal] The external user who opened the pull request, when the author is not mapped to a Linear account, such as a bot. Null if the author is a Linear user. + """ + externalCreator: ExternalUser + """ + Whether the source branch has conflicts with the target branch. When true, the conflicts must be resolved before the pull request can be merged. This is reported separately from `mergeStatus`, which describes whether the pull request is blocked by required approvals or checks. + """ + hasConflicts: Boolean! + """ + The Git SHA of the latest commit on the source branch. Updated as new commits are pushed. Null if not yet synced. + """ + headSha: String + """ + The unique identifier of the entity. + """ + id: ID! + """ + Whether the source branch is behind the target branch. When true, the source branch is missing commits that have landed on the target branch since it was last updated. + """ + isBehind: Boolean! + """ + The merge commit created when the pull request was merged. Null if the pull request has not been merged or if the merge commit data is not available. + """ + mergeCommit: PullRequestCommit + """ + Merge settings and allowed merge methods for this pull request's repository. Null if the settings have not been synced from the provider. + """ + mergeSettings: PullRequestMergeSettings + """ + The current merge status of the pull request, synced from the hosting provider. + """ + mergeStatus: String! + """ + The time at which the pull request was merged. Null if the pull request has not been merged. + """ + mergedAt: DateTime + """ + [Internal] The external user who merged the pull request, when the person who merged it is not mapped to a Linear account. Null if the pull request has not been merged or the merger is a Linear user. + """ + mergedByExternalUser: ExternalUser + """ + [Internal] The Linear user who merged the pull request. This is the person who merged it, which the hosting provider reports separately from the merge commit's author. Null if the pull request has not been merged, was merged by an external user not mapped to a Linear account, or if that account has been deleted. + """ + mergedByUser: User + """ + [Internal] The host-qualified external ID of the native stack that contains this pull request. Null if the pull request is not in a native stack or stack data is unavailable. + """ + nativeStackId: String + """ + [Internal] The number the hosting provider assigns to the native stack within its repository. Null if the pull request is not in a native stack or stack data is unavailable. + """ + nativeStackNumber: Float + """ + [Internal] The pull request's one-based position in its native stack, where 1 is closest to the target branch. Null if the pull request is not in a native stack or stack data is unavailable. + """ + nativeStackPosition: Float + """ + [Internal] The total number of pull requests in the native stack. Null if the pull request is not in a native stack or stack data is unavailable. + """ + nativeStackSize: Float + """ + [Internal] The target branch shared by the native stack. Null if the pull request is not in a native stack or stack data is unavailable. + """ + nativeStackTargetBranch: String + """ + The pull request number as assigned by the hosting provider (e.g., #123 on GitHub). Unique within a repository. + """ + number: Float! + """ + The time at which the pull request was opened. + """ + openedAt: DateTime! + """ + [Internal] The deploy/build preview links parsed from the pull request description and comments. + """ + previewLinks: [PullRequestPreviewLink!]! + """ + Emoji reaction summary for this pull request, grouped by emoji type. Each entry contains the emoji name, count, and the IDs of users who reacted. + """ + reactionData: JSONObject! + """ + Reactions associated with this pull request. + """ + reactions: [Reaction!]! + """ + The pull request's unique URL slug, used to construct human-readable URLs within the Linear app. + """ + slugId: String! + """ + The source (head) branch of the pull request that contains the proposed changes. + """ + sourceBranch: String! + """ + The current status of the pull request (open, closed, merged, or draft). Synced from the hosting provider. + """ + status: PullRequestStatus! + """ + The target (base) branch that the pull request will be merged into. + """ + targetBranch: String! + """ + The title of the pull request. + """ + title: String! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The URL of the pull request on the hosting provider (e.g., a GitHub or GitLab URL). + """ + url: String! +} + +""" +[ALPHA] A CI/CD check or status check associated with a pull request (e.g., a GitHub Actions workflow run or a required status check). +""" +type PullRequestCheck { + """ + The date and time when the check finished running. Null if the check has not completed yet. + """ + completedAt: DateTime + """ + Whether this check is required to pass before the pull request can be merged. Null if the required status is unknown. + """ + isRequired: Boolean + """ + The name of the check. + """ + name: String! + """ + How the check should be opened in the client. + """ + presentation: PullRequestCheckPresentation + """ + The date and time when the check started running. Null if the check has not started yet. + """ + startedAt: DateTime + """ + The status of the check. + """ + status: String! + """ + The URL to view the check details on the hosting provider. Null if no URL is available. + """ + url: String + """ + The name of the CI workflow that triggered the check (e.g., 'CI' or 'Build and Test'). Null if the check is not part of a named workflow. + """ + workflowName: String +} + +""" +[ALPHA] How a pull request check should be opened in the client. +""" +enum PullRequestCheckPresentation { + externalOnly + jobLogs + markdown + runLogs +} + +""" +[ALPHA] A Git commit associated with a pull request, including metadata about the commit's content and authors. +""" +type PullRequestCommit { + """ + Number of additions in this commit. 0 when the hosting provider did not report per-commit diff stats. + """ + additions: Float! + """ + External user IDs for commit authors (includes co-authors). + """ + authorExternalUserIds: [String!]! + """ + Linear user IDs for commit authors (includes co-authors). + """ + authorUserIds: [String!]! + """ + The time when the commit was authored, as an ISO 8601 string. Null if unavailable. + """ + authoredAt: String + """ + The number of files changed in this commit. Null if the hosting provider did not include this information. + """ + changedFiles: Float + """ + The timestamp when the commit was committed, as an ISO 8601 string. + """ + committedAt: String! + """ + The external user ID for the commit's committer. Null if no matching external user is available. + """ + committerExternalUserId: String + """ + The Linear user ID for the commit's committer. Null if no matching Linear user is available. + """ + committerUserId: String + """ + Number of deletions in this commit. 0 when the hosting provider did not report per-commit diff stats. + """ + deletions: Float! + """ + Whether this commit is a merge commit (has multiple parents). Merge commits are typically filtered out when counting diff stats. + """ + isMergeCommit: Boolean + """ + The full commit message. + """ + message: String! + """ + The parent commit SHAs in provider-reported order. The first parent is used for merge-commit review ranges when available. + """ + parentShas: [String!] + """ + The Git commit SHA. + """ + sha: String! + """ + Signature verification metadata for this commit. Null if the hosting provider did not return signature information. + """ + signature: PullRequestCommitSignature +} + +""" +Signature verification metadata for a Git commit associated with a pull request. +""" +type PullRequestCommitSignature { + """ + Whether the hosting provider considers the signature valid and verified. + """ + isVerified: Boolean! + """ + The hex-encoded fingerprint of the SSH key that signed this commit. Null for non-SSH signatures. + """ + keyFingerprint: String + """ + The hex-encoded ID of the GPG key that signed this commit. Null for non-GPG signatures. + """ + keyId: String + """ + The provider-specific verification state for the signature. + """ + state: String! + """ + The type of signature reported for this commit. + """ + type: String! + """ + Whether the commit was signed with the hosting provider's signing key. + """ + wasSignedByProvider: Boolean +} + +""" +The method used to merge a pull request. +""" +enum PullRequestMergeMethod { + MERGE + REBASE + SQUASH +} + +""" +[Internal] Merge settings and capabilities for a pull request's repository, including which merge methods are allowed and whether features like merge queues and auto-merge are enabled. +""" +type PullRequestMergeSettings { + """ + Whether auto-merge is allowed for the PR's repository. + """ + autoMergeAllowed: Boolean! + """ + Whether the branch will be deleted when the pull request is merged. + """ + deleteBranchOnMerge: Boolean! + """ + Whether a merge queue is enabled for pull requests in this repository. When enabled, merges go through an ordered queue rather than being merged directly. + """ + isMergeQueueEnabled: Boolean! + """ + Whether merge commits are allowed for pull requests PR's repository. + """ + mergeCommitAllowed: Boolean! + """ + The merge method used by the merge queue, if applicable. Null when merge queue is not enabled or the method is not specified. + """ + mergeQueueMergeMethod: PullRequestMergeMethod + """ + Whether rebase merge is allowed for pull requests PR's repository. + """ + rebaseMergeAllowed: Boolean! + """ + Whether squash merge is allowed for this pull request's repository. + """ + squashMergeAllowed: Boolean! +} + +""" +A notification related to a pull request, such as review requests, approvals, comments, check failures, or merge queue events. +""" +type PullRequestNotification implements Entity & Node & Notification { + """ + The user that caused the notification. Null if the notification was triggered by a non-user actor such as an integration, external user, or system event. + """ + actor: User + """ + [Internal] Notification actor initials if avatar is not available. + """ + actorAvatarColor: String! + """ + [Internal] Notification avatar URL. + """ + actorAvatarUrl: String + """ + [Internal] Whether the notification's user actor is deactivated in the workspace. + """ + actorInactive: Boolean! + """ + [Internal] Notification actor initials if avatar is not available. + """ + actorInitials: String + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The bot that caused the notification. + """ + botActor: ActorBot + """ + The category of the notification. + """ + category: NotificationCategory! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The time at which an email reminder for this notification was sent to the user. Null if no email reminder has been sent. + """ + emailedAt: DateTime + """ + The external user that caused the notification. Populated when the notification was triggered by an external user (e.g., a commenter from a connected integration like Slack or GitHub) rather than a Linear workspace member. + """ + externalUserActor: ExternalUser + """ + [Internal] Notifications with the same grouping key will be grouped together in the UI. + """ + groupingKey: String! + """ + [Internal] Priority of the notification with the same grouping key. Higher number means higher priority. If priority is the same, notifications should be sorted by `createdAt`. + """ + groupingPriority: Float! + """ + The unique identifier of the entity. + """ + id: ID! + """ + [Internal] Inbox URL for the notification. + """ + inboxUrl: String! + """ + [Internal] Initiative update health for new updates. + """ + initiativeUpdateHealth: String + """ + [Internal] If notification actor was Linear. + """ + isLinearActor: Boolean! + """ + [Internal] Issue's status type for issue notifications. + """ + issueStatusType: String + """ + [Internal] Project update health for new updates. + """ + projectUpdateHealth: String + """ + The pull request related to the notification. + """ + pullRequest: PullRequest! + """ + Related pull request comment ID. Null if the notification is not related to a pull request comment. + """ + pullRequestCommentId: String + """ + Related pull request. + """ + pullRequestId: String! + """ + The time at which the user marked the notification as read. Null if the notification is unread. + """ + readAt: DateTime + """ + The time until which a notification is snoozed. After this time, the notification reappears in the user's inbox. Null if the notification is not currently snoozed. + """ + snoozedUntilAt: DateTime + """ + [Internal] Notification subtitle. + """ + subtitle: String! + """ + [Internal] Notification title. + """ + title: String! + """ + Notification type. Determines the kind of event that triggered this notification and which associated entity fields will be populated. + """ + type: String! + """ + The time at which a notification was unsnoozed. Null if the notification has not been unsnoozed. + """ + unsnoozedAt: DateTime + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + [Internal] URL to the target of the notification. + """ + url: String! + """ + The recipient user of this notification. + """ + user: User! +} + +""" +[Internal] A deploy or build preview link (e.g., Vercel, Cloudflare Pages, Netlify) parsed from a pull request's description or comments. +""" +type PullRequestPreviewLink { + """ + Whether the preview is still building. Null when the build state is unknown. + """ + isBuilding: Boolean + """ + The display name of the preview (e.g., the deploy target). Null if the provider did not supply one. + """ + name: String + """ + The URL of the preview. Empty for a deployment that is still building and has not reported its URL. + """ + url: String! +} + +""" +A reference to a pull request by its repository owner, name, and pull request number. Used during release sync to look up pull requests and associate their linked issues with the release. +""" +input PullRequestReferenceInput { + """ + The pull request number. + """ + number: Int! + """ + The name of the repository. + """ + repositoryName: String! + """ + The owner of the repository (e.g., organization or user name). + """ + repositoryOwner: String! +} + +""" +The status of a pull request. +""" +enum PullRequestStatus { + approved + closed + draft + inReview + merged + open +} + +""" +A device registration for receiving push notifications. Each PushSubscription represents a specific browser or mobile device endpoint where a user has opted in to receive real-time push notifications. A user may have multiple push subscriptions across different devices and browsers. +""" +type PushSubscription implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The unique identifier of the entity. + """ + id: ID! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +""" +Input for creating a push subscription to receive push notifications on a device or browser. +""" +input PushSubscriptionCreateInput { + """ + The push subscription data in stringified JSON format. For web subscriptions, this must contain keys, endpoint, and expirationTime fields per the Web Push API specification. For mobile subscriptions, this contains the device token. + """ + data: String! + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + The type of push subscription: 'web' for browser-based Web Push API, 'apple' for Apple Push Notification service (or 'appleDevelopment' for sandbox), or 'firebase' for Firebase Cloud Messaging (Android). + """ + type: PushSubscriptionType = web +} + +""" +Return type for push subscription mutations. +""" +type PushSubscriptionPayload { + """ + The push subscription that was created or deleted. + """ + entity: PushSubscription! + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Return type for the push subscription test query. +""" +type PushSubscriptionTestPayload { + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +The different push subscription types. +""" +enum PushSubscriptionType { + apple + appleDevelopment + firebase + web +} + +type Query { + _dummy: String! + """ + All teams whose settings the user can administer. This includes teams the user can change settings for, but whose issues they may not have direct access to. This differs from the `teams` query which returns teams based on issue access. + """ + administrableTeams( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned teams. + """ + filter: TeamFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): TeamConnection! + """ + All agent activities. + """ + agentActivities( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned agent activities. + """ + filter: AgentActivityFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): AgentActivityConnection! + """ + A specific agent activity. + """ + agentActivity( + """ + The identifier of the agent activity to retrieve. + """ + id: String! + ): AgentActivity! + """ + A specific agent session. + """ + agentSession( + """ + The identifier of the agent session to retrieve. + """ + id: String! + ): AgentSession! + """ + [Internal] Retrieves coding agent sandbox details for a given agent session ID. + """ + agentSessionSandbox( + """ + The identifier of the agent session. + """ + agentSessionId: String! + ): CodingAgentSandboxPayload + """ + [Internal] SSH address of the current user's running coding sandbox for this agent session. + """ + agentSessionSshAddress( + """ + The identifier of the agent session. + """ + agentSessionId: String! + ): String + """ + All agent sessions. + """ + agentSessions( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): AgentSessionConnection! + """ + A specific agent skill. + """ + agentSkill( + """ + The identifier of the agent skill to retrieve. + """ + id: String! + ): AgentSkill! + """ + All agent skills. + """ + agentSkills( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned skills + """ + filter: AgentSkillFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): AgentSkillConnection! + """ + Retrieves public information about an OAuth application by its client ID. Used during the authorization flow to display application details to the user. + """ + applicationInfo( + """ + The client ID of the application. + """ + clientId: String! + ): Application! + """ + Recently archived GitHub integrations. Returns integrations archived within the last 30 days. + """ + archivedIntegrations: [ArchivedIntegrationPayload!]! + """ + [Internal] All archived teams of the workspace. + """ + archivedTeams: [Team!]! + """ + One specific issue attachment. + [Deprecated] 'url' can no longer be used as the 'id' parameter. Use 'attachmentsForUrl' instead + """ + attachment(id: String!): Attachment! + """ + Query an issue by its associated attachment, and its id. + """ + attachmentIssue( + """ + `id` of the attachment for which you'll want to get the issue for. [Deprecated] `url` as the `id` parameter. + """ + id: String! + ): Issue! + @deprecated( + reason: "Will be removed in near future, please use `attachmentsForURL` to get attachments and their issues instead." + ) + """ + [Internal] Get a list of all unique attachment sources in the workspace. + """ + attachmentSources( + """ + (optional) if provided will only return attachment sources for the given team. + """ + teamId: String + ): AttachmentSourcesPayload! + """ + All issue attachments. + + To get attachments for a given URL, use `attachmentsForURL` query. + """ + attachments( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned attachments. + """ + filter: AttachmentFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): AttachmentConnection! + """ + Returns issue attachments for a given `url`. + """ + attachmentsForURL( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + """ + The attachment URL. + """ + url: String! + ): AttachmentConnection! + """ + All audit log entries. + """ + auditEntries( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned audit entries. + """ + filter: AuditEntryFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): AuditEntryConnection! + """ + List of audit entry types. + """ + auditEntryTypes: [AuditEntryType!]! + """ + [INTERNAL] Failure events for an audit log webhook (last 50). + """ + auditLogWebhookFailureEvents( + """ + The identifier of the audit log webhook. + """ + webhookId: String! + ): [WebhookFailureEvent!]! + """ + User's active sessions. + """ + authenticationSessions: [AuthenticationSessionResponse!]! + """ + Fetch users belonging to this user account. + """ + availableUsers: AuthResolverResponse! + """ + A specific comment. + """ + comment( + """ + The hash of the comment to retrieve. + """ + hash: String + """ + The identifier of the comment to retrieve. + """ + id: String + ): Comment! + """ + All comments the user has access to in the workspace. + """ + comments( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned comments. + """ + filter: CommentFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): CommentConnection! + """ + One specific custom view, looked up by ID or slug. + """ + customView( + """ + The identifier of the custom view to retrieve. + """ + id: String! + ): CustomView! + """ + [INTERNAL] Suggests metadata (name, description, icon) for a view based on its filters using AI. Rate-limited to 30 requests per minute. + """ + customViewDetailsSuggestion( + """ + The filter object to generate suggestions for. + """ + filter: JSONObject! + """ + The entity type the view targets. If null, defaults to "issue". Valid values: "issue", "project", "initiative", "feedItem". + """ + modelName: String + ): CustomViewSuggestionPayload! + """ + Whether a custom view has active notification subscribers other than the current user. Useful for warning before deleting a shared view. + """ + customViewHasSubscribers( + """ + The identifier of the custom view. + """ + id: String! + ): CustomViewHasSubscribersPayload! + """ + All custom views accessible to the user, including personal views and shared workspace views. Excludes views scoped to a specific project or initiative. + """ + customViews( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned custom views. + """ + filter: CustomViewFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + """ + [INTERNAL] Sort returned custom views. + """ + sort: [CustomViewSortInput!] + ): CustomViewConnection! + """ + Retrieves a single customer by ID or slug. + """ + customer( + """ + The identifier or slug of the customer to retrieve. + """ + id: String! + ): Customer! + """ + Retrieves a single customer need by ID or hash. + """ + customerNeed( + """ + The hash prefix of the customer need to retrieve (minimum 8 characters). Cannot be used together with id. + """ + hash: String + """ + The UUID of the customer need to retrieve. Cannot be used together with hash. + """ + id: String + ): CustomerNeed! + """ + All customer needs in the workspace, with optional filtering. + """ + customerNeeds( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned customer needs. + """ + filter: CustomerNeedFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): CustomerNeedConnection! + """ + One specific customer status. + """ + customerStatus( + """ + The identifier of the customer status to retrieve. + """ + id: String! + ): CustomerStatus! + """ + All customer statuses defined in the workspace. + """ + customerStatuses( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): CustomerStatusConnection! + """ + One specific customer tier. + """ + customerTier( + """ + The identifier of the customer tier to retrieve. + """ + id: String! + ): CustomerTier! + """ + All customer tiers defined in the workspace. + """ + customerTiers( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): CustomerTierConnection! + """ + All customers in the workspace, with optional filtering and sorting. + """ + customers( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned customers. + """ + filter: CustomerFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + """ + Sort criteria for the returned customers. Up to 3 sort fields can be specified. + """ + sorts: [CustomerSortInput!] + ): CustomerConnection! + """ + One specific cycle, looked up by ID or slug. + """ + cycle( + """ + The identifier of the cycle to retrieve. + """ + id: String! + ): Cycle! + """ + All cycles accessible to the user. + """ + cycles( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned cycles. + """ + filter: CycleFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): CycleConnection! + """ + Registry metadata (license, publish date, weekly download count) for a batch of dependency package versions, used by the dependency lock file diff preview. Cached across all workspaces since registry data isn't workspace-specific. A package the registry has no data for (or an unsupported ecosystem) is simply omitted from the result rather than erroring. At most 500 packages per request. + """ + dependencyPackageMetadata( + packages: [DependencyPackageInput!]! + ): [DependencyPackageMetadataResult!]! + """ + [Internal] A specific diff. + """ + diff( + """ + The identifier of the diff to retrieve. + """ + id: String! + ): Diff! + """ + A specific document by ID or slug. + """ + document( + """ + The identifier or slug of the document to retrieve. + """ + id: String! + ): Document! + """ + A collection of document content history entries. + """ + documentContentHistory( + """ + The identifier of the document content to retrieve history for. + """ + id: String! + ): DocumentContentHistoryPayload! + """ + [Internal] Fetches document content history entries by their IDs, including content data. + """ + documentContentHistoryEntries( + """ + The identifiers of the history entries to retrieve. Maximum 10 per request. + """ + entryIds: [String!]! + ): DocumentContentHistoryPayload! + """ + [Internal] Fetches the fresh document content history timeline for the client history dialog. + """ + documentContentHistoryTimeline( + """ + The identifier of the document content to retrieve timeline entries for. + """ + id: String! + ): DocumentContentHistoryTimelinePayload! + """ + All documents the user has access to in the workspace. + """ + documents( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned documents. + """ + filter: DocumentFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + """ + [INTERNAL] Sort returned documents. + """ + sort: [DocumentSortInput!] + ): DocumentConnection! + """ + One specific email intake address. + """ + emailIntakeAddress(id: String!): EmailIntakeAddress! + """ + A specific custom emoji by ID or name. + """ + emoji( + """ + The identifier or the name of the emoji to retrieve. + """ + id: String! + ): Emoji! + """ + All custom emojis in the workspace. + """ + emojis( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned emojis. + """ + filter: EmojiFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + """ + [INTERNAL] Sort returned emojis. + """ + sort: [EmojiSortInput!] + ): EmojiConnection! + """ + Retrieves a single entity external link by its identifier. + """ + entityExternalLink( + """ + The identifier of the entity external link to retrieve. + """ + id: String! + ): EntityExternalLink! + """ + Retrieves a single external user by their identifier. + """ + externalUser( + """ + The identifier of the external user to retrieve. + """ + id: String! + ): ExternalUser! + """ + All external users for the organization. External users are people who interact with Linear through integrated services (Slack, Jira, GitHub, etc.) without having a Linear account. + """ + externalUsers( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): ExternalUserConnection! + """ + [INTERNAL] Webhook failure events for webhooks that belong to an OAuth application. (last 50) + """ + failuresForOauthWebhooks( + """ + The identifier of the OAuth client to retrieve failures for. + """ + oauthClientId: String! + ): [WebhookFailureEvent!]! + """ + A specific favorite by ID. + """ + favorite(id: String!): Favorite! + """ + The authenticated user's favorites. Returns all bookmarked items that appear in the user's sidebar. + """ + favorites( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): FavoriteConnection! + """ + The authenticated user's active inbox notifications, grouped according to inbox behavior. + """ + inboxNotifications( + """ + The cursor after which to return inbox notification stacks. + """ + after: String + """ + The maximum number of inbox notification stacks to return. Defaults to 50. + """ + first: Int + """ + Whether to return only unread inbox notification stacks. + """ + unreadOnly: Boolean + ): NotificationConnection! + """ + Returns a single initiative by its identifier or URL slug. + """ + initiative(id: String!): Initiative! + """ + Suggests filters for an initiative view based on a text prompt. + """ + initiativeFilterSuggestion( + """ + The text prompt to generate a filter suggestion from. + """ + prompt: String! + """ + [Internal] The ID of the team if filtering a team view. + """ + teamId: String + ): InitiativeFilterSuggestionPayload! + """ + Returns a single initiative label by its identifier. + """ + initiativeLabel(id: String!): InitiativeLabel! + """ + Returns all initiative labels in the workspace, with optional filtering. + """ + initiativeLabels( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned initiative labels. + """ + filter: InitiativeLabelFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): InitiativeLabelConnection! + """ + [Internal] Returns the impact of changing an initiative's lead team before applying the update to matching sub-initiatives. + """ + initiativeLeadTeamChangeImpact( + """ + The identifier of the initiative whose lead team would change. + """ + id: String! + """ + The identifier of the new lead team. Pass null to clear the lead team. + """ + leadTeamId: String + ): InitiativeLeadTeamChangeImpact! + """ + Returns a single initiative relation by its identifier. + """ + initiativeRelation(id: String!): InitiativeRelation! + """ + Returns all initiative parent-child relations in the workspace. + """ + initiativeRelations( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): InitiativeRelationConnection! + """ + Returns a single initiative-to-project association by its identifier. + """ + initiativeToProject(id: String!): InitiativeToProject! + """ + Returns all initiative-to-project associations in the workspace. + """ + initiativeToProjects( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): InitiativeToProjectConnection! + """ + Returns a single initiative update by its identifier. + """ + initiativeUpdate( + """ + The identifier of the initiative update to retrieve. + """ + id: String! + ): InitiativeUpdate! + """ + Returns all initiative status updates in the workspace, with optional filtering. + """ + initiativeUpdates( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned initiative updates. + """ + filter: InitiativeUpdateFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): InitiativeUpdateConnection! + """ + Returns all initiatives in the workspace, with optional filtering and sorting. + """ + initiatives( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned initiatives. + """ + filter: InitiativeFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + """ + [INTERNAL] Sort returned initiatives. + """ + sort: [InitiativeSortInput!] + ): InitiativeConnection! + """ + Retrieves a single integration by its identifier. + """ + integration( + """ + The identifier of the integration to retrieve. + """ + id: String! + ): Integration! + """ + Checks if the integration has all required scopes. + """ + integrationHasScopes( + """ + The integration ID. + """ + integrationId: String! + """ + Required scopes. + """ + scopes: [String!]! + ): IntegrationHasScopesPayload! + """ + [INTERNAL] Fetches a Jira project's status names, split into issue (non-Epic) and project (Epic) statuses. + """ + integrationJiraProjectStatuses( + """ + The id of the Jira integration. + """ + integrationId: String! + """ + The Jira project ID to fetch statuses for. + """ + projectId: String! + ): JiraProjectStatusesPayload! + """ + [INTERNAL] Jira project IDs available for issue sync. + """ + integrationSyncResourceIds( + """ + The workspace integration to configure. + """ + integrationId: String! + ): [String!]! + """ + Retrieves a single integration template connection by its identifier. + """ + integrationTemplate( + """ + The identifier of the integration template to retrieve. + """ + id: String! + ): IntegrationTemplate! + """ + All integration template connections for the workspace, linking templates to integrations. + """ + integrationTemplates( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): IntegrationTemplateConnection! + """ + All integrations for the workspace. + """ + integrations( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): IntegrationConnection! + """ + Retrieves a specific integration settings configuration by its identifier. + """ + integrationsSettings( + """ + The identifier of the integration settings to retrieve. + """ + id: String! + ): IntegrationsSettings! + """ + One specific issue, looked up by its unique identifier. + """ + issue( + """ + The identifier of the issue to retrieve. + """ + id: String! + ): Issue! + """ + Find issues that are related to a given Figma file key. + """ + issueFigmaFileKeySearch( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The Figma file key. + """ + fileKey: String! + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): IssueConnection! + """ + Suggests filters for an issue view based on a text prompt. + """ + issueFilterSuggestion( + """ + The ID of the project if filtering a project view. + """ + projectId: String + """ + The text prompt to generate a filter suggestion from. + """ + prompt: String! + """ + [Internal] The ID of the team if filtering a team view. + """ + teamId: String + ): IssueFilterSuggestionPayload! + """ + Checks a CSV file validity against a specific import service. + """ + issueImportCheckCSV( + """ + The CSV file storage URL. + """ + csvUrl: String! + """ + The service the CSV contains data from. + """ + service: String! + ): IssueImportCheckPayload! + """ + Checks whether it will be possible to set up sync for this project or repository at the end of import. + """ + issueImportCheckSync( + """ + The ID of the issue import for which to check sync eligibility + """ + issueImportId: String! + ): IssueImportSyncCheckPayload! + """ + Checks whether a custom JQL query is valid and can be used to filter issues of a Jira import. + """ + issueImportJqlCheck( + """ + Jira user account email. + """ + jiraEmail: String! + """ + Jira installation or cloud hostname. + """ + jiraHostname: String! + """ + Jira project key to use as the base filter of the query. + """ + jiraProject: String! + """ + Jira personal access token to access Jira REST API. + """ + jiraToken: String! + """ + The JQL query to validate. + """ + jql: String! + ): IssueImportJqlCheckPayload! + """ + One specific label, looked up by its unique identifier. + """ + issueLabel( + """ + The identifier of the label to retrieve. + """ + id: String! + ): IssueLabel! + """ + All issue labels. Returns a paginated list of labels visible to the authenticated user, including both workspace-level and team-scoped labels. + """ + issueLabels( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned issue labels. + """ + filter: IssueLabelFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): IssueLabelConnection! + """ + Issue priority values and corresponding labels. + """ + issuePriorityValues: [IssuePriorityValue!]! + """ + One specific issue relation, looked up by its unique identifier. + """ + issueRelation( + """ + The identifier of the issue relation to retrieve. + """ + id: String! + ): IssueRelation! + """ + All issue relations. Returns a paginated list of all issue relations (blocks, blocked by, relates to, duplicates) visible to the authenticated user. + """ + issueRelations( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): IssueRelationConnection! + """ + Returns code repositories that are most likely to be relevant for implementing an issue. + """ + issueRepositorySuggestions( + """ + Optional AgentSession ID associated with the issue for which the suggestions are being generated. + """ + agentSessionId: String + """ + List of candidate repositories to restrict suggestions to. + """ + candidateRepositories: [CandidateRepository!]! + """ + The ID of the issue to get repository suggestions for. + """ + issueId: String! + ): RepositorySuggestionsPayload! + """ + [DEPRECATED] Search issues. This endpoint is deprecated and will be removed in the future โ€“ use `searchIssues` instead. + """ + issueSearch( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned issues. + """ + filter: IssueFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + """ + [Deprecated] Search string to look for. + """ + query: String + ): IssueConnection! + """ + Suggests an issue title based on a customer request message using AI summarization. + """ + issueTitleSuggestionFromCustomerRequest( + """ + The customer request message to generate an issue title from. + """ + request: String! + ): IssueTitleSuggestionFromCustomerRequestPayload! + """ + One specific issue-to-release association, looked up by its unique identifier. + """ + issueToRelease( + """ + The identifier of the issue-to-release association to retrieve. + """ + id: String! + ): IssueToRelease! + """ + All issue-to-release associations. Returns a paginated list of all issue-to-release links visible to the authenticated user. + """ + issueToReleases( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): IssueToReleaseConnection! + """ + Find issue based on the VCS branch name. + """ + issueVcsBranchSearch( + """ + The VCS branch name to search for. + """ + branchName: String! + ): Issue + """ + All issues. Returns a paginated list of issues visible to the authenticated user. Can be filtered by various criteria including team, assignee, state, labels, project, and cycle. + """ + issues( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned issues. + """ + filter: IssueFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + """ + [INTERNAL] Sort returned issues. + """ + sort: [IssueSortInput!] + ): IssueConnection! + """ + Returns the most recently completed or updated release for the pipeline associated with the access key. + """ + latestReleaseByAccessKey: AccessKeyRelease + """ + [Internal] Lists Microsoft Teams teams and channels accessible to the connecting user. Uses the user's microsoftPersonal integration for auth. Used by the project channel picker dialog to populate the team/channel dropdowns. + """ + microsoftTeamsChannels: MicrosoftTeamsChannelsPayload! + """ + A specific notification by ID. + """ + notification( + """ + The identifier of the notification to retrieve. + """ + id: String! + ): Notification! + """ + A specific notification subscription by ID. + """ + notificationSubscription( + """ + The identifier of the notification subscription to retrieve. + """ + id: String! + ): NotificationSubscription! + """ + The authenticated user's notification subscriptions. These subscriptions control which notifications the user receives for specific entities such as teams, projects, cycles, labels, custom views, initiatives, customers, and users. + """ + notificationSubscriptions( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): NotificationSubscriptionConnection! + """ + The authenticated user's notifications. + """ + notifications( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filters returned notifications. + """ + filter: NotificationFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): NotificationConnection! + """ + [Internal] A number of unread notifications. + """ + notificationsUnreadCount: Int! + """ + [ALPHA] A specific OAuth application created by the calling OAuth application through the public API. + """ + oauthApplication( + """ + The identifier of the OAuth application to retrieve. + """ + id: String! + ): OAuthApplication! + """ + Returns the authenticated OAuth application's trusted-source status for Coding Sessions in the workspace. Requires an OAuth access token with the `read` scope. + """ + oauthApplicationCodingSessionTrustedSource: OAuthApplicationCodingSessionTrustedSource! + """ + [ALPHA] OAuth applications created by the calling OAuth application through the public API. + """ + oauthApplications: [OAuthApplication!]! + """ + The authenticated user's workspace. + """ + organization: Organization! + """ + [INTERNAL] Checks whether the domain can be claimed. + """ + organizationDomainClaimRequest( + """ + The ID of the organization domain to claim. + """ + id: String! + ): OrganizationDomainClaimPayload! + """ + Checks whether a workspace with the given URL key exists. + """ + organizationExists( + """ + The URL key of the workspace to check. + """ + urlKey: String! + ): OrganizationExistsPayload! + """ + Fetches a specific workspace invite by its ID. + """ + organizationInvite( + """ + The identifier of the invite to retrieve. + """ + id: String! + ): OrganizationInvite! + """ + Fetches public details of a specific workspace invite by its ID. This query does not require authentication and is used for invite acceptance flows. + """ + organizationInviteDetails( + """ + The identifier of the invite to retrieve details for. + """ + id: String! + ): OrganizationInviteDetailsPayload! + """ + All pending and accepted invites for the workspace. + """ + organizationInvites( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): OrganizationInviteConnection! + """ + [INTERNAL] Get workspace metadata by URL key or workspace ID. + """ + organizationMeta( + """ + The URL key of the workspace to retrieve metadata for. + """ + urlKey: String! + ): OrganizationMeta + """ + [Internal] Builds the URL that starts installing Linear's Origin app into a codebase, or reinstalling it to grant new scopes. + """ + originInstallUrl: OriginInstallUrlPayload! + """ + [Internal] Describes an Origin installation that started on Origin, for its installer to confirm before connecting. + """ + originInstallation( + """ + The Origin installation id from the install redirect. + """ + installationId: String! + ): OriginInstallationDetails! + """ + [Internal] Lists the Origin installations the current user started on Origin that no workspace has connected yet, matched by the user's email. + """ + originPendingInstallations: [OriginInstallationDetails!]! + """ + [Internal] Fetches public details of an active partner-program offer by its partner slug. Returns null when no active offer matches the slug. + """ + partnerOfferDetails( + """ + The URL-safe partner slug, for example "y_combinator". + """ + slug: String! + ): PartnerOfferDetailsPayload + """ + [Internal] Fetches the viewer's workspaces hosted in the serving cell, with each workspace's eligibility to redeem the given partner-offer token. Returns null when the token is invalid or the offer is no longer available. + """ + partnerOfferWorkspaces( + """ + The signed partner-offer token to check eligibility for. + """ + token: String! + ): PartnerOfferWorkspacesPayload + """ + [Internal] Lists every partner with an active partner-program offer, ordered by display name. Backs the partner directory on the marketing website. + """ + partnerProgramPartners: [PartnerProgramPartnerPayload!]! + """ + Returns a single project by its identifier or URL slug. + """ + project(id: String!): Project! + """ + Suggests filters for a project view based on a text prompt. + """ + projectFilterSuggestion( + prompt: String! + """ + [Internal] The ID of the team if filtering a team view. + """ + teamId: String + ): ProjectFilterSuggestionPayload! + """ + Returns a single project label by its identifier. + """ + projectLabel(id: String!): ProjectLabel! + """ + All project labels. Returns a paginated list of labels visible to the authenticated user, including both workspace-level and team-scoped labels, with optional filtering. + """ + projectLabels( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned project labels. + """ + filter: ProjectLabelFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): ProjectLabelConnection! + """ + Returns a single project milestone by its identifier. + """ + projectMilestone(id: String!): ProjectMilestone! + """ + Returns all project milestones in the workspace, with optional filtering. + """ + projectMilestones( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned project milestones. + """ + filter: ProjectMilestoneFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): ProjectMilestoneConnection! + """ + Returns a single project relation by its identifier. + """ + projectRelation(id: String!): ProjectRelation! + """ + Returns all project dependency relations in the workspace. + """ + projectRelations( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): ProjectRelationConnection! + """ + Returns a single project status by its identifier. + """ + projectStatus(id: String!): ProjectStatus! + """ + [INTERNAL] Count of projects using this project status across the workspace. + """ + projectStatusProjectCount( + """ + The identifier of the project status to find the project count for. + """ + id: String! + ): ProjectStatusCountPayload! + """ + Returns all project statuses in the workspace. + """ + projectStatuses( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): ProjectStatusConnection! + """ + Returns a single project update by its identifier. + """ + projectUpdate( + """ + The identifier of the project update to retrieve. + """ + id: String! + """ + The id or URL slug of the project containing the update. When provided, the update is resolved by id or URL slug within that project. + """ + projectId: String + ): ProjectUpdate! + """ + Returns all project status updates in the workspace, with optional filtering. + """ + projectUpdates( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned project updates. + """ + filter: ProjectUpdateFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): ProjectUpdateConnection! + """ + Returns all projects in the workspace, with optional filtering and sorting. + """ + projects( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned projects. + """ + filter: ProjectFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + """ + [INTERNAL] Sort returned projects. + """ + sort: [ProjectSortInput!] + ): ProjectConnection! + """ + Sends a test push notification to the authenticated user's registered devices. Useful for verifying that push notification delivery is working correctly. + """ + pushSubscriptionTest( + """ + The send strategy to use. + """ + sendStrategy: SendStrategy = push + """ + Whether to send to mobile devices. + """ + targetMobile: Boolean = false + ): PushSubscriptionTestPayload! + """ + Public resource quotas for the authenticated workspace. These are not subscription limits. + """ + quotas( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + filter: OrganizationQuotaFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + ): OrganizationQuotaConnection! + """ + The current rate limit status for the authenticated client, including remaining quota and reset timing for each limit type. + """ + rateLimitStatus: RateLimitPayload! + """ + Returns releases for the pipeline associated with the access key, ordered with the most recently completed or updated first. + """ + recentReleasesByAccessKey( + """ + Maximum number of releases to return. Defaults to 20 and is capped at 100. + """ + limit: Int + ): [AccessKeyRelease!]! + """ + Fetch a single release by its UUID or slug identifier. + """ + release(id: String!): Release! + """ + Fetch a release note by its UUID or slug identifier. + """ + releaseNote(id: String!): ReleaseNote! + """ + Release notes in the workspace. + """ + releaseNotes( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned release notes. + """ + filter: ReleaseNoteFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): ReleaseNoteConnection! + """ + Fetch a single release pipeline by its UUID or slug identifier. + """ + releasePipeline(id: String!): ReleasePipeline! + """ + Returns the release pipeline associated with the access key. + """ + releasePipelineByAccessKey: AccessKeyReleasePipeline! + """ + All release pipelines in the workspace, with optional filtering and sorting. + """ + releasePipelines( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned release pipelines. + """ + filter: ReleasePipelineFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + """ + Sort returned release pipelines. + """ + sort: [ReleasePipelineSortInput!] + ): ReleasePipelineConnection! + """ + Search releases with optional text matching against name, version, and pipeline name. When no search term is provided, returns releases ordered by stage priority (started > planned > completed > canceled). + """ + releaseSearch( + """ + Filter to apply to the release results. + """ + filter: ReleaseFilter + """ + Maximum results. Capped at 50. + """ + first: Int = 20 + """ + Search term to match against release name, version, and pipeline name. When omitted, returns releases ordered by stage priority. + """ + term: String + ): [Release!]! + """ + Fetch a single release stage by its UUID. + """ + releaseStage(id: String!): ReleaseStage! + """ + All release stages in the workspace, with optional filtering. + """ + releaseStages( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned release stages. + """ + filter: ReleaseStageFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): ReleaseStageConnection! + """ + All releases in the workspace, with optional filtering and sorting. + """ + releases( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned releases. + """ + filter: ReleaseFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + """ + Sort returned releases. + """ + sort: [ReleaseSortInput!] + ): ReleaseConnection! + """ + [Deprecated] Returns a single roadmap by its identifier. Use initiatives instead. + """ + roadmap(id: String!): Roadmap! + @deprecated(reason: "Roadmaps are deprecated, use initiatives instead.") + """ + [Deprecated] Returns a single roadmap-to-project association. Use InitiativeToProject instead. + """ + roadmapToProject(id: String!): RoadmapToProject! + @deprecated(reason: "RoadmapToProject is deprecated, use InitiativeToProject instead.") + """ + [Deprecated] Returns all roadmap-to-project associations. Use InitiativeToProject instead. + """ + roadmapToProjects( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): RoadmapToProjectConnection! + @deprecated(reason: "RoadmapToProject is deprecated, use InitiativeToProject instead.") + """ + [Deprecated] Returns all roadmaps in the workspace. Use initiatives instead. + """ + roadmaps( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): RoadmapConnection! @deprecated(reason: "Roadmaps are deprecated, use initiatives instead.") + """ + Search documents by text query using full-text and vector search. Results are ranked by relevance unless an orderBy parameter is specified. Rate-limited to 30 requests per minute. + """ + searchDocuments( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + Should associated comments be searched (default: false). + """ + includeComments: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + """ + UUID of a team to boost in search results. Results from this team are ranked higher. If null, no team boosting is applied. + """ + teamId: String + """ + Search string to look for. + """ + term: String! + ): DocumentSearchPayload! + """ + Search issues by text query using full-text and vector search. Results are ranked by relevance unless an orderBy parameter is specified. Supports optional issue filters and comment inclusion. Rate-limited to 30 requests per minute. + """ + searchIssues( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned issues. + """ + filter: IssueFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + Should associated comments be searched (default: false). + """ + includeComments: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + """ + UUID of a team to boost in search results. Results from this team are ranked higher. If null, no team boosting is applied. + """ + teamId: String + """ + Search string to look for. + """ + term: String! + ): IssueSearchPayload! + """ + Search projects by text query using full-text and vector search. Results are ranked by relevance unless an orderBy parameter is specified. Rate-limited to 30 requests per minute. + """ + searchProjects( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + Should associated comments be searched (default: false). + """ + includeComments: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + """ + UUID of a team to boost in search results. Results from this team are ranked higher. If null, no team boosting is applied. + """ + teamId: String + """ + Search string to look for. + """ + term: String! + ): ProjectSearchPayload! + """ + Search for issues, projects, initiatives, and documents using natural language. Uses vector-based semantic search with optional full-text search and reranking. Results can be filtered by type and by entity-specific filters. Rate-limited to 30 requests per minute. + """ + semanticSearch( + """ + Filters to apply to the semantic search results of each type. + """ + filters: SemanticSearchFilters + """ + Whether to include archived results in the search (default: false). + """ + includeArchived: Boolean + """ + The maximum number of results to return (default: 50). + """ + maxResults: Int + """ + Search query to look for. + """ + query: String! + """ + The types of results to return (default: all). + """ + types: [SemanticSearchResultType!] + ): SemanticSearchPayload! + """ + Active SLA configurations that can apply to the requested team. + """ + slaConfigurations( + """ + The identifier or key of the team to evaluate SLA rules against. + """ + teamId: String! + ): [SlaConfiguration!]! + """ + Fetch SSO login URL for the email provided. + """ + ssoUrlFromEmail( + """ + Email to query the SSO login URL by. + """ + email: String! + """ + Whether the client is the desktop app. + """ + isDesktop: Boolean + """ + Type of identity provider. + """ + type: IdentityProviderType! = general + ): SsoUrlFromEmailResponse! + """ + Fetches a specific team by its ID. + """ + team( + """ + The identifier of the team to retrieve. + """ + id: String! + ): Team! + """ + Fetches a specific team membership by its ID. + """ + teamMembership( + """ + The identifier of the team membership to retrieve. + """ + id: String! + ): TeamMembership! + """ + All team memberships in the workspace. + """ + teamMemberships( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): TeamMembershipConnection! + """ + All teams whose issues the user can access. This includes public teams and private teams the user is a member of. This may differ from `administrableTeams`, which returns teams whose settings the user can change but whose issues they don't necessarily have access to. + """ + teams( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned teams. + """ + filter: TeamFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): TeamConnection! + """ + A specific template. + """ + template( + """ + The identifier of the template to retrieve. + """ + id: String! + ): Template! + """ + Templates matching a filter, in the order they appear in the app. Filter on a null team to return only workspace-level templates. + """ + templateSearch( + """ + Filter to apply to the template results. + """ + filter: TemplateFilter + """ + Maximum results. Capped at 250. + """ + first: Int = 50 + """ + Should archived resources be included (default: false). + """ + includeArchived: Boolean = false + ): [Template!]! + """ + All templates in the workspace, including both team-scoped and workspace-level templates. + """ + templates: [Template!]! + """ + Returns all templates that are associated with the integration type. + """ + templatesForIntegration( + """ + The type of integration for which to return associated templates. + """ + integrationType: String! + ): [Template!]! + """ + A specific time schedule. + """ + timeSchedule( + """ + The identifier of the time schedule to retrieve. + """ + id: String! + ): TimeSchedule! + """ + All time schedules. + """ + timeSchedules( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): TimeScheduleConnection! + """ + All triage responsibilities. + """ + triageResponsibilities( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): TriageResponsibilityConnection! + """ + A specific triage responsibility. + """ + triageResponsibility( + """ + The identifier of the triage responsibility to retrieve. + """ + id: String! + ): TriageResponsibility! + """ + One usage-based billing alert, by its identifier. + """ + usageAlert( + """ + The identifier of the usage alert to retrieve. + """ + id: String! + ): UsageAlert! + """ + The workspace's usage-based billing alerts, such as a low or exhausted usage credit balance. Alerts for expired promotional credits are archived and excluded unless archived resources are requested. Use resolvedAt to tell an open alert from one whose condition has since cleared. + """ + usageAlerts( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned usage alerts. + """ + filter: UsageAlertFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): UsageAlertConnection! + """ + Fetches a specific user by their ID. + """ + user( + """ + The identifier of the user to retrieve. To retrieve the authenticated user, use `viewer` query. + """ + id: String! + ): User! + """ + Lists all active authentication sessions for a user. Can only be called by a workspace admin or owner. + """ + userSessions( + """ + The identifier of the user to list sessions of. + """ + id: String! + ): [AuthenticationSessionResponse!]! + """ + The authenticated user's notification and UI settings. + """ + userSettings: UserSettings! + """ + The authenticated user's workspace-level view display preferences for a view type. Returns the user-type preferences that are not scoped to a team, project, or other entity. Null if the user has not customized the view. + """ + userViewPreferences( + """ + The view type the preferences are associated with. + """ + viewType: ViewType! + ): ViewPreferences + """ + All users in the workspace. Supports filtering, sorting, and pagination. + """ + users( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned users. + """ + filter: UserFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + Should query return disabled/suspended users (default: false). + """ + includeDisabled: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + """ + [INTERNAL] Sort returned users. + """ + sort: [UserSortInput!] + ): UserConnection! + """ + Verify that we received the correct response from the GitHub Enterprise Server. + """ + verifyGitHubEnterpriseServerInstallation( + """ + The integration ID. + """ + integrationId: String! + ): GitHubEnterpriseServerInstallVerificationPayload! + """ + The currently authenticated user making the API request. + """ + viewer: User! + """ + Retrieves a single webhook by its identifier. + """ + webhook( + """ + The identifier of the webhook to retrieve. + """ + id: String! + ): Webhook! + """ + All webhooks for the current workspace. + """ + webhooks( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): WebhookConnection! + """ + One specific workflow state (issue status), looked up by its unique identifier. + """ + workflowState( + """ + The identifier of the workflow state to retrieve. + """ + id: String! + ): WorkflowState! + """ + All issue workflow states (issue statuses). Returns a paginated list of workflow states visible to the authenticated user, across all teams they have access to. + """ + workflowStates( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned workflow states. + """ + filter: WorkflowStateFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): WorkflowStateConnection! +} + +""" +The current rate limit status for the authenticated entity. +""" +type RateLimitPayload { + """ + The identifier being rate limited, typically the API key or user ID. + """ + identifier: String + """ + The category of rate limit applied to this request, such as API complexity or request count. + """ + kind: String! + """ + The current state of each rate limit type, including remaining quota and reset timing. + """ + limits: [RateLimitResultPayload!]! +} + +""" +The state of a specific rate limit type, including remaining quota and reset timing. +""" +type RateLimitResultPayload { + """ + The total allowed quantity for this type of limit. + """ + allowedAmount: Float! + """ + The duration in milliseconds of the rate limit window. After this period elapses, the limit is fully replenished. + """ + period: Float! + """ + The remaining quantity for this type of limit after this request. + """ + remainingAmount: Float! + """ + The requested quantity for this type of limit. + """ + requestedAmount: Float! + """ + The UNIX timestamp (in milliseconds) at which the rate limit will be fully replenished. + """ + reset: Float! + """ + The specific type of rate limit being tracked, such as query complexity or mutation count. + """ + type: String! +} + +""" +An emoji reaction on a comment, issue, project update, initiative update, post, pull request, or pull request comment. Each reaction is associated with exactly one parent entity and is created by either a workspace user or an external user. Reactions are persisted individually but surfaced on their parent entities as aggregated reactionData. +""" +type Reaction implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The comment that the reaction is associated with. Null if the reaction belongs to a different parent entity type. + """ + comment: Comment + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The name of the emoji used for this reaction. For custom workspace emojis, this is the custom emoji name; for standard emojis, this is the normalized emoji name. + """ + emoji: String! + """ + The external user that created the reaction through an integration. Null if the reaction was created by a workspace user. + """ + externalUser: ExternalUser + """ + The unique identifier of the entity. + """ + id: ID! + """ + The initiative update that the reaction is associated with. Null if the reaction belongs to a different parent entity type. + """ + initiativeUpdate: InitiativeUpdate + """ + The issue that the reaction is associated with. Null if the reaction belongs to a different parent entity type. + """ + issue: Issue + """ + The post that the reaction is associated with. Null if the reaction belongs to a different parent entity type. + """ + post: Post + """ + The project update that the reaction is associated with. Null if the reaction belongs to a different parent entity type. + """ + projectUpdate: ProjectUpdate + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The workspace user that created the reaction. Null if the reaction was created by an external user through an integration. + """ + user: User +} + +""" +Reaction filtering options. +""" +input ReactionCollectionFilter { + """ + Compound filters, all of which need to be matched by the reaction. + """ + and: [ReactionCollectionFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for the reactions custom emoji. + """ + customEmojiId: IDComparator + """ + Comparator for the reactions emoji. + """ + emoji: StringComparator + """ + Filters that needs to be matched by all reactions. + """ + every: ReactionFilter + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Comparator for the collection length. + """ + length: NumberComparator + """ + Compound filters, one of which need to be matched by the reaction. + """ + or: [ReactionCollectionFilter!] + """ + Filters that needs to be matched by some reactions. + """ + some: ReactionFilter + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +Input for creating a new reaction. +""" +input ReactionCreateInput { + """ + The comment to associate the reaction with. + """ + commentId: String + """ + The emoji the user reacted with. + """ + emoji: String! + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + The update to associate the reaction with. + """ + initiativeUpdateId: String + """ + The issue to associate the reaction with. Can be a UUID or issue identifier (e.g., 'LIN-123'). + """ + issueId: String + """ + [Internal] The post to associate the reaction with. + """ + postId: String + """ + The project update to associate the reaction with. + """ + projectUpdateId: String + """ + [Internal] The pull request comment to associate the reaction with. + """ + pullRequestCommentId: String + """ + [Internal] The pull request to associate the reaction with. + """ + pullRequestId: String +} + +""" +Reaction filtering options. +""" +input ReactionFilter { + """ + Compound filters, all of which need to be matched by the reaction. + """ + and: [ReactionFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for the reactions custom emoji. + """ + customEmojiId: IDComparator + """ + Comparator for the reactions emoji. + """ + emoji: StringComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Compound filters, one of which need to be matched by the reaction. + """ + or: [ReactionFilter!] + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +The result of a reaction mutation. +""" +type ReactionPayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + The reaction that was created. + """ + reaction: Reaction! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Payload for a reaction webhook. +""" +type ReactionWebhookPayload { + """ + The time at which the entity was archived. + """ + archivedAt: String + """ + The comment the reaction is associated with. + """ + comment: CommentChildWebhookPayload + """ + The ID of the comment that the reaction is associated with. + """ + commentId: String + """ + The time at which the entity was created. + """ + createdAt: String! + """ + Name of the reaction's emoji. + """ + emoji: String! + """ + The ID of the external user that created the reaction. + """ + externalUserId: String + """ + The ID of the entity. + """ + id: String! + """ + The ID of the initiative update that the reaction is associated with. + """ + initiativeUpdateId: String + """ + The issue the reaction is associated with. + """ + issue: IssueChildWebhookPayload + """ + The ID of the issue that the reaction is associated with. + """ + issueId: String + """ + The ID of the post that the reaction is associated with. + """ + postId: String + """ + The project update the reaction is associated with. + """ + projectUpdate: ProjectUpdateChildWebhookPayload + """ + The ID of the project update that the reaction is associated with. + """ + projectUpdateId: String + """ + The time at which the entity was updated. + """ + updatedAt: String! + """ + The user that created the reaction. + """ + user: UserChildWebhookPayload + """ + The ID of the user that created the reaction. + """ + userId: String +} + +""" +Comparator for relation existence. +""" +input RelationExistsComparator { + """ + Equals constraint. + """ + eq: Boolean + """ + Not equals constraint. + """ + neq: Boolean +} + +""" +A release that bundles issues together for a software deployment or version. Releases belong to a release pipeline and progress through stages (e.g., planned, started, completed, canceled). Issues are associated with releases via the IssueToRelease join entity, and the release tracks lifecycle timestamps such as when it was started, completed, or canceled. +""" +type Release implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the release was automatically archived by the auto pruning process. + """ + autoArchivedAt: DateTime + """ + The time at which the release was canceled. Set automatically when the release moves to a canceled stage. Reset to null if the release moves back to a non-canceled stage. + """ + canceledAt: DateTime + """ + The Git commit SHA associated with this release. Used for SHA-based idempotency when completing releases and for linking releases to specific points in the repository history. Null if the release was created without a commit reference. + """ + commitSha: String + """ + The time at which the release was completed. Set automatically when the release moves to a completed stage. Reset to null if the release moves back to a non-completed stage. + """ + completedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The user who created the release. Null if the release was created by a non-user context such as an access key or automation. + """ + creator: User + """ + The current progress summary for the release, including counts of issues by workflow state type (e.g., completed, in progress, unstarted). + """ + currentProgress: JSONObject! + """ + The description of the release in plain text or markdown. Null if no description has been set. + """ + description: String + """ + Documents associated with the release. + """ + documents( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned documents. + """ + filter: DocumentFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): DocumentConnection! + """ + History entries associated with the release. + """ + history( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): ReleaseHistoryConnection! + """ + The unique identifier of the entity. + """ + id: ID! + """ + Number of issues associated with the release. + """ + issueCount( + """ + Include archived issues in the count. + """ + includeArchived: Boolean = false + ): Int! + """ + Issues associated with the release. + """ + issues( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned issues. + """ + filter: IssueFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): IssueConnection! + """ + Links associated with the release. + """ + links( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): EntityExternalLinkConnection! + """ + The name of the release. + """ + name: String! + """ + The release pipeline that this release belongs to. A release always belongs to exactly one pipeline. + """ + pipeline: ReleasePipeline! + """ + The historical progress snapshots for the release, tracking how issue completion has evolved over time. + """ + progressHistory: JSONObject! + """ + [Internal] The primary release note covering this release. Null if no release note covers it. + """ + releaseNote: ReleaseNote + """ + Release notes for the release. + """ + releaseNotes: [ReleaseNote!]! + """ + The release's unique URL slug, used to construct human-readable URLs for the release. + """ + slugId: String! + """ + The current stage of the release within its pipeline (e.g., Planned, In Progress, Completed, Canceled). Changing the stage triggers lifecycle timestamp updates and may move non-closed issues to a new release when completing a scheduled pipeline release. + """ + stage: ReleaseStage! + """ + The estimated start date of the release. This is a date-only value without a time component. Automatically set to today when the release moves to a started stage if not already set. Null if no start date has been specified. + """ + startDate: TimelessDate + """ + The time at which the release first entered a started stage. Null if the release has not yet been started. + """ + startedAt: DateTime + """ + The estimated completion date of the release. This is a date-only value without a time component. Null if no target date has been specified. + """ + targetDate: TimelessDate + """ + A flag that indicates whether the release is in the trash bin. Trashed releases are archived and will be permanently deleted after a retention period. Null when the release is not trashed. + """ + trashed: Boolean + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The URL to the release page in the Linear app. + """ + url: String! + """ + The version identifier for this release (e.g., 'v1.2.3' or a short commit hash). Must be unique within the pipeline. Null if no version has been assigned. + """ + version: String +} + +""" +A generic payload return from entity archive mutations. +""" +type ReleaseArchivePayload implements ArchivePayload { + """ + The archived/unarchived entity. Null if entity was deleted. + """ + entity: Release + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Features release channel. +""" +enum ReleaseChannel { + beta + development + internal + preRelease + privateBeta + public +} + +""" +Certain properties of a release. +""" +type ReleaseChildWebhookPayload { + """ + The time at which the release was completed. + """ + completedAt: String + """ + The ID of the release. + """ + id: String! + """ + The name of the release. + """ + name: String! + """ + The pipeline this release belongs to. + """ + pipeline: ReleasePipelineChildWebhookPayload + """ + The current stage of the release. + """ + stage: ReleaseStageChildWebhookPayload + """ + The version of the release. + """ + version: String +} + +""" +Release collection filtering options. +""" +input ReleaseCollectionFilter { + """ + Compound filters, all of which need to be matched by the release. + """ + and: [ReleaseCollectionFilter!] + """ + Comparator for the release completion date. + """ + completedAt: NullableDateComparator + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Filters that needs to be matched by all releases. + """ + every: ReleaseFilter + """ + Comparator for whether the release is covered by any (non-archived) release note. Filter with `{ eq: false }` to retrieve releases that do not yet have release notes attached. + """ + hasReleaseNotes: BooleanComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Comparator for the collection length. + """ + length: NumberComparator + """ + Comparator for the release name. + """ + name: StringComparator + """ + Compound filters, one of which need to be matched by the release. + """ + or: [ReleaseCollectionFilter!] + """ + Filters that the release's pipeline must satisfy. + """ + pipeline: ReleasePipelineFilter + """ + Filters that needs to be matched by some releases. + """ + some: ReleaseFilter + """ + Filters that the release's stage must satisfy. + """ + stage: ReleaseStageFilter + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator + """ + Comparator for the release version. + """ + version: StringComparator +} + +""" +Input for completing a release in a specific pipeline. +""" +input ReleaseCompleteInput { + """ + The commit SHA to store when moving a release to completed. With a version, an existing SHA is preserved. Without a version, this SHA replaces the started release's SHA and is used to detect retries. + """ + commitSha: String + """ + Optional release description to apply when completing the release. Pass null to clear it. + """ + description: String + """ + Documents to attach to the completed release. Existing documents with the same title are updated. + """ + documents: [ReleaseDocumentInput!] + """ + External links to attach to the completed release. + """ + links: [ReleaseLinkInput!] + """ + Optional release name to apply when completing the release. + """ + name: String + """ + The identifier of the pipeline to mark a release as completed. + """ + pipelineId: String! + """ + Release notes covering the completed release. + """ + releaseNotes: ReleaseNoteInput + """ + The version of the release to complete. If not provided, the latest started release will be completed. + """ + version: String +} + +""" +Base input for completing a release. Contains the optional version and commit SHA. The pipeline ID is provided separately or inferred from the access key. +""" +input ReleaseCompleteInputBase { + """ + The commit SHA to store when moving a release to completed. With a version, an existing SHA is preserved. Without a version, this SHA replaces the started release's SHA and is used to detect retries. + """ + commitSha: String + """ + Optional release description to apply when completing the release. Pass null to clear it. + """ + description: String + """ + Documents to attach to the completed release. Existing documents with the same title are updated. + """ + documents: [ReleaseDocumentInput!] + """ + External links to attach to the completed release. + """ + links: [ReleaseLinkInput!] + """ + Optional release name to apply when completing the release. + """ + name: String + """ + Release notes covering the completed release. + """ + releaseNotes: ReleaseNoteInput + """ + The version of the release to complete. If not provided, the latest started release will be completed. + """ + version: String +} + +type ReleaseConnection { + edges: [ReleaseEdge!]! + nodes: [Release!]! + pageInfo: PageInfo! +} + +""" +The input for creating a release. +""" +input ReleaseCreateInput { + """ + The commit SHA associated with this release. + """ + commitSha: String + """ + The time at which the release was completed (e.g. if importing from another system). Must be a time in the past and after createdAt. Cannot be provided with an incompatible stage. + """ + completedAt: DateTime + """ + The time at which the release was created (e.g. if importing from another system). Must be a time in the past. If none is provided, the backend will generate the time as now. + """ + createdAt: DateTime + """ + The description of the release. + """ + description: String + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + The name of the release. + """ + name: String! + """ + The identifier of the pipeline this release belongs to. + """ + pipelineId: String! + """ + The current stage of the release. Defaults to the first 'completed' stage for continuous pipelines, or the first 'started' stage for scheduled pipelines. + """ + stageId: String + """ + The estimated start date of the release. + """ + startDate: TimelessDate + """ + The time at which the release was started (e.g. if importing from another system). Must be a time in the past and after createdAt. + """ + startedAt: DateTime + """ + The estimated completion date of the release. + """ + targetDate: TimelessDate + """ + The version of the release. + """ + version: String +} + +""" +Diagnostic data captured during release sync, including inspected commits, discovered issue references, and pull request metadata. Stored on the release for debugging release association issues. +""" +input ReleaseDebugSinkInput { + """ + List of paths applied during commit scanning. + """ + includePaths: [String!] + """ + Regex used to filter commit subjects during scanning. + """ + includeSubjects: [String!] + """ + List of commit SHAs that were inspected. + """ + inspectedShas: [String!]! + """ + Custom regex used to extract issue identifiers from commit subjects. + """ + issuePattern: String + """ + Map of issue identifiers to their source information. + """ + issues: JSONObject! + """ + Pull request debug information. + """ + pullRequests: [JSONObject!]! + """ + Map of reverted issue identifiers to their source information. + """ + revertedIssues: JSONObject +} + +""" +A document to attach to the release. Existing documents on the release with the same title are updated in place. Bad rows (empty title, oversized title/body) are skipped with a warning rather than failing the release command. +""" +input ReleaseDocumentInput { + """ + The document body as markdown. + """ + content: String! + """ + The title of the document. Used to match existing documents on the release for upsert. + """ + title: String! +} + +type ReleaseEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: Release! +} + +""" +Release filtering options. +""" +input ReleaseFilter { + """ + Compound filters, all of which need to be matched by the release. + """ + and: [ReleaseFilter!] + """ + Comparator for the release completion date. + """ + completedAt: NullableDateComparator + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for whether the release is covered by any (non-archived) release note. Filter with `{ eq: false }` to retrieve releases that do not yet have release notes attached. + """ + hasReleaseNotes: BooleanComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Comparator for the release name. + """ + name: StringComparator + """ + Compound filters, one of which need to be matched by the release. + """ + or: [ReleaseFilter!] + """ + Filters that the release's pipeline must satisfy. + """ + pipeline: ReleasePipelineFilter + """ + Filters that the release's stage must satisfy. + """ + stage: ReleaseStageFilter + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator + """ + Comparator for the release version. + """ + version: StringComparator +} + +""" +A release history record containing a batch of chronologically ordered change events for a release. Each record holds up to 30 entries, and new records are created once the current record is full and a time window has elapsed. Tracks changes to name, description, version, stage, dates, pipeline, and archive status. +""" +type ReleaseHistory implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The events that happened while recording that history. + """ + entries: JSONObject! + """ + The unique identifier of the entity. + """ + id: ID! + """ + The release that this history record tracks changes for. + """ + release: Release! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +type ReleaseHistoryConnection { + edges: [ReleaseHistoryEdge!]! + nodes: [ReleaseHistory!]! + pageInfo: PageInfo! +} + +type ReleaseHistoryEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: ReleaseHistory! +} + +""" +An external link to attach to the release. +""" +input ReleaseLinkInput { + """ + Optional label for the link. If omitted, the API derives one from the URL. + """ + label: String + """ + The URL of the link. + """ + url: String! +} + +""" +A note documenting one or more releases. The note body is stored in related document content. +""" +type ReleaseNote implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + Document content backing the release note body. + """ + documentContent: DocumentContent + """ + The earliest release covered by this note. + """ + firstRelease: Release + """ + Generation status when these release notes are being auto-generated: `pending` while the LLM call is running, `completed` once it lands. `null` means the release notes were written by a user and never went through auto-generation. + """ + generationStatus: ReleaseNoteGenerationStatus + """ + The unique identifier of the entity. + """ + id: ID! + """ + The most recent release covered by this note. + """ + lastRelease: Release + """ + The release pipeline that this note belongs to. A note always belongs to exactly one pipeline. + """ + pipeline: ReleasePipeline! + """ + The number of releases covered by this note. + """ + releaseCount: Int! + """ + Releases included in the note. + """ + releases: [Release!]! + """ + The release note's unique URL slug, used to construct human-readable URLs for the note. + """ + slugId: String! + """ + User-supplied title for the release note. + """ + title: String + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The URL to the release note page in the Linear app. + """ + url: String! +} + +type ReleaseNoteConnection { + edges: [ReleaseNoteEdge!]! + nodes: [ReleaseNote!]! + pageInfo: PageInfo! +} + +""" +Input for creating a release note. +""" +input ReleaseNoteCreateInput { + """ + The release note body as markdown. + """ + content: String + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + Identifier of the release pipeline. + """ + pipelineId: String! + """ + Oldest release (by createdAt) to include. When paired with rangeToReleaseId, expands to every release in the pipeline within the createdAt window. + """ + rangeFromReleaseId: String + """ + Newest release (by createdAt) to include. Paired with rangeFromReleaseId. + """ + rangeToReleaseId: String + """ + Explicit release IDs to include. Mutually exclusive with rangeFromReleaseId/rangeToReleaseId โ€” exactly one of the two shapes must be provided. + """ + releaseIds: [String!] + """ + Optional user-supplied title. + """ + title: String +} + +type ReleaseNoteEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: ReleaseNote! +} + +""" +Release note filtering options. +""" +input ReleaseNoteFilter { + """ + Compound filters, all of which need to be matched by the release note. + """ + and: [ReleaseNoteFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Compound filters, one of which need to be matched by the release note. + """ + or: [ReleaseNoteFilter!] + """ + Filters that the release note's pipeline must satisfy. + """ + pipeline: ReleasePipelineFilter + """ + Filters that a release covered by the release note must satisfy. + """ + release: ReleaseFilter + """ + Comparator for the release note slug ID. + """ + slugId: StringComparator + """ + Comparator for the release note title. + """ + title: StringComparator + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +The generation status of a release note's body content. +""" +enum ReleaseNoteGenerationStatus { + completed + pending +} + +""" +Release notes to attach to the release. Upserts the existing release notes that cover only this release. Bad input (empty title, oversized title/body) is skipped with a warning rather than failing the release command. +""" +input ReleaseNoteInput { + """ + The release notes body as markdown. + """ + content: String! + """ + Optional title. If omitted, the UI derives one from the release range. + """ + title: String +} + +""" +The result of a release note mutation. +""" +type ReleaseNotePayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + The release note that was created or updated. + """ + releaseNote: ReleaseNote! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Input for updating a release note. +""" +input ReleaseNoteUpdateInput { + """ + The release note body as markdown. + """ + content: String + """ + Oldest release (by createdAt) of the new range. Paired with rangeToReleaseId. + """ + rangeFromReleaseId: String + """ + Newest release (by createdAt) of the new range. Paired with rangeFromReleaseId. + """ + rangeToReleaseId: String + """ + Explicit release IDs to set. Mutually exclusive with rangeFromReleaseId/rangeToReleaseId. + """ + releaseIds: [String!] + """ + Optional user-supplied title. + """ + title: String +} + +""" +Payload for a release note webhook. +""" +type ReleaseNoteWebhookPayload { + """ + The time at which the entity was archived. + """ + archivedAt: String + """ + The release note's body as markdown. + """ + content: String + """ + The time at which the entity was created. + """ + createdAt: String! + """ + The ID of the user who created the release note. + """ + creatorId: String + """ + The ID of the entity. + """ + id: String! + """ + The ID of the most recent release covered by this note. + """ + lastReleaseId: String + """ + The pipeline this release note belongs to. + """ + pipeline: ReleasePipelineChildWebhookPayload + """ + The ID of the pipeline this release note belongs to. + """ + pipelineId: String! + """ + IDs of the releases included in the note. + """ + releaseIds: [String!]! + """ + The release note's unique URL slug. + """ + slugId: String! + """ + User-supplied title for the release note. + """ + title: String + """ + The time at which the entity was updated. + """ + updatedAt: String! + """ + The URL of the release note. + """ + url: String! +} + +""" +The result of a release mutation, containing the release that was created or updated and a success indicator. +""" +type ReleasePayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + The release that was created or updated. + """ + release: Release! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +A release pipeline that defines a release workflow with ordered stages. Pipelines can be continuous (each sync creates a completed release) or scheduled (issues accumulate in a started release that is explicitly completed). Pipelines are associated with teams and can filter commits by file path patterns. +""" +type ReleasePipeline implements Node { + """ + The approximate number of non-archived releases in this pipeline. This is a denormalized count that is updated when releases are created or archived, and may not reflect the exact count at all times. + """ + approximateReleaseCount: Int! + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + Whether to automatically generate a release note when a release is completed. + """ + autoGenerateReleaseNotesOnCompletion: Boolean! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The unique identifier of the entity. + """ + id: ID! + """ + Glob patterns to filter commits by file path. When non-empty, only commits that modify files matching at least one pattern will be included in release syncs. An empty array means all commits are included regardless of file paths. + """ + includePathPatterns: [String!]! + """ + Whether this pipeline targets a production environment. Defaults to true. Used to distinguish production pipelines from staging or development pipelines. + """ + isProduction: Boolean! + """ + The release note in this pipeline whose covered range ends with the most recent release. + """ + latestReleaseNote: ReleaseNote + """ + The name of the pipeline. + """ + name: String! + """ + The document template used to define the release notes format for this pipeline. AI-generated release notes follow the structure and tone of this template. Null if no template has been configured. + """ + releaseNoteTemplate: Template + """ + Releases associated with this pipeline. + """ + releases( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + """ + Sort returned releases. + """ + sort: [ReleaseSortInput!] + ): ReleaseConnection! + """ + Whether completing a scheduled release moves its open issues to the next release. When false, open issues remain on the completed release. + """ + rolloverIssuesOnCompletion: Boolean! + """ + The pipeline's unique slug identifier, used in URLs and for lookup by human-readable identifier instead of UUID. + """ + slugId: String! + """ + Stages associated with this pipeline. + """ + stages( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): ReleaseStageConnection! + """ + Teams associated with this pipeline. + """ + teams( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): TeamConnection! + """ + A flag that indicates whether the pipeline is in the trash bin. Trashed pipelines are archived and will be permanently deleted after a retention period. Null when the pipeline is not trashed. + """ + trashed: Boolean + """ + The type of the pipeline, which determines how releases are created and managed. Continuous pipelines create a completed release per sync, while scheduled pipelines accumulate issues in a started release. + """ + type: ReleasePipelineType! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The URL to the release pipeline's releases list in the Linear app. + """ + url: String! +} + +""" +A generic payload return from entity archive mutations. +""" +type ReleasePipelineArchivePayload implements ArchivePayload { + """ + The archived/unarchived entity. Null if entity was deleted. + """ + entity: ReleasePipeline + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Certain properties of a release pipeline. +""" +type ReleasePipelineChildWebhookPayload { + """ + The ID of the release pipeline. + """ + id: String! + """ + The name of the release pipeline. + """ + name: String! + """ + The pipeline's unique slug identifier. + """ + slugId: String! + """ + The type of the release pipeline. + """ + type: String! + """ + The URL of the release pipeline. + """ + url: String! +} + +""" +Release pipeline collection filtering options. +""" +input ReleasePipelineCollectionFilter { + """ + Compound filters, all of which need to be matched by the release pipeline. + """ + and: [ReleasePipelineCollectionFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Filters that needs to be matched by all release pipelines. + """ + every: ReleasePipelineFilter + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Comparator for the pipeline production flag. + """ + isProduction: BooleanComparator + """ + Comparator for the collection length. + """ + length: NumberComparator + """ + Comparator for the pipeline name. + """ + name: StringComparator + """ + Compound filters, one of which need to be matched by the release pipeline. + """ + or: [ReleasePipelineCollectionFilter!] + """ + Filters that needs to be matched by some release pipelines. + """ + some: ReleasePipelineFilter + """ + Filters that the release pipeline's teams must satisfy. + """ + teams: TeamCollectionFilter + """ + Comparator for the pipeline type. + """ + type: ReleasePipelineTypeComparator + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +type ReleasePipelineConnection { + edges: [ReleasePipelineEdge!]! + nodes: [ReleasePipeline!]! + pageInfo: PageInfo! +} + +""" +Input for creating a new release pipeline. +""" +input ReleasePipelineCreateInput { + """ + Whether to automatically generate a release note when a release is completed. Defaults to false. + """ + autoGenerateReleaseNotesOnCompletion: Boolean + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + Glob patterns to include commits affecting matching file paths. + """ + includePathPatterns: [String!] + """ + Whether this pipeline targets a production environment. Default to true. + """ + isProduction: Boolean + """ + The name of the pipeline. + """ + name: String! + """ + Whether completing a scheduled release moves its open issues to the next release. Defaults to true. When false, open issues remain on the completed release. + """ + rolloverIssuesOnCompletion: Boolean + """ + The pipeline's unique slug identifier. If not provided, it will be auto-generated. + """ + slugId: String + """ + The identifiers of the teams this pipeline is associated with. + """ + teamIds: [String!] + """ + The type of the pipeline. + """ + type: ReleasePipelineType +} + +type ReleasePipelineEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: ReleasePipeline! +} + +""" +Release pipeline filtering options. +""" +input ReleasePipelineFilter { + """ + Compound filters, all of which need to be matched by the pipeline. + """ + and: [ReleasePipelineFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Comparator for the pipeline production flag. + """ + isProduction: BooleanComparator + """ + Comparator for the pipeline name. + """ + name: StringComparator + """ + Compound filters, one of which need to be matched by the pipeline. + """ + or: [ReleasePipelineFilter!] + """ + Filters that the release pipeline's teams must satisfy. + """ + teams: TeamCollectionFilter + """ + Comparator for the pipeline type. + """ + type: ReleasePipelineTypeComparator + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +Release pipeline name sorting options. +""" +input ReleasePipelineNameSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +The result of a release pipeline mutation. +""" +type ReleasePipelinePayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + The release pipeline that was created or updated. + """ + releasePipeline: ReleasePipeline! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Release pipeline sorting options. +""" +input ReleasePipelineSortInput { + """ + Sort by release pipeline name. + """ + name: ReleasePipelineNameSort +} + +""" +The type of a release pipeline, which determines how releases are created and managed. Continuous pipelines create a new completed release for each sync. Scheduled pipelines accumulate issues into a started release that is explicitly completed. +""" +enum ReleasePipelineType { + continuous + scheduled +} + +""" +Comparator for release pipeline type. +""" +input ReleasePipelineTypeComparator { + """ + Equals constraint. + """ + eq: ReleasePipelineType + """ + In-array constraint. + """ + in: [ReleasePipelineType!] + """ + Not-equals constraint. + """ + neq: ReleasePipelineType + """ + Not-in-array constraint. + """ + nin: [ReleasePipelineType!] + """ + Null constraint. Matches any non-null values if the given value is false, otherwise it matches null values. + """ + null: Boolean +} + +""" +Input for updating an existing release pipeline. +""" +input ReleasePipelineUpdateInput { + """ + Whether to automatically generate a release note when a release is completed. + """ + autoGenerateReleaseNotesOnCompletion: Boolean + """ + Glob patterns to include commits affecting matching file paths. + """ + includePathPatterns: [String!] + """ + Whether this pipeline targets a production environment. Default to true. + """ + isProduction: Boolean + """ + The name of the pipeline. + """ + name: String + """ + Whether completing a scheduled release moves its open issues to the next release. When false, open issues remain on the completed release. + """ + rolloverIssuesOnCompletion: Boolean + """ + The pipeline's unique slug identifier. + """ + slugId: String + """ + The identifiers of the teams this pipeline is associated with. + """ + teamIds: [String!] + """ + The type of the pipeline. + """ + type: ReleasePipelineType +} + +""" +Issue release sorting options. +""" +input ReleaseSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +Release sorting options. +""" +input ReleaseSortInput { + """ + Sort by release stage + """ + stage: ReleaseStageSort +} + +""" +A stage within a release pipeline that represents a phase in the release lifecycle (e.g., Planned, In Progress, Completed, Canceled). Releases progress through stages as they move toward production. Started-type stages can be frozen to prevent new issues from being automatically synced into releases at that stage. +""" +type ReleaseStage implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The display color of the stage as a HEX string (e.g., '#0f783c'), used for visual representation in the UI. + """ + color: String! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + Whether this stage is frozen. Only applicable to started-type stages. When a stage is frozen, automated release syncs will not target releases in this stage, and new issues will not be automatically added. At least one started stage in the pipeline must remain non-frozen. + """ + frozen: Boolean! + """ + The unique identifier of the entity. + """ + id: ID! + """ + The name of the stage. + """ + name: String! + """ + The release pipeline that this stage belongs to. A stage always belongs to exactly one pipeline. + """ + pipeline: ReleasePipeline! + """ + The position of the stage within its pipeline, used for ordering stages in the UI. Lower values appear first. + """ + position: Float! + """ + Releases associated with this stage. + """ + releases( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): ReleaseConnection! + """ + The lifecycle type of the stage (planned, started, completed, or canceled). The type determines what lifecycle timestamps are set on a release when it enters this stage. + """ + type: ReleaseStageType! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +""" +A generic payload return from entity archive mutations. +""" +type ReleaseStageArchivePayload implements ArchivePayload { + """ + The archived/unarchived entity. Null if entity was deleted. + """ + entity: ReleaseStage + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Certain properties of a release stage. +""" +type ReleaseStageChildWebhookPayload { + """ + The UI color of the stage as a HEX string. + """ + color: String! + """ + The ID of the release stage. + """ + id: String! + """ + The name of the stage. + """ + name: String! + """ + The position of the stage. + """ + position: Float! + """ + The type of the stage. + """ + type: String! +} + +type ReleaseStageConnection { + edges: [ReleaseStageEdge!]! + nodes: [ReleaseStage!]! + pageInfo: PageInfo! +} + +""" +Input for creating a new release stage. +""" +input ReleaseStageCreateInput { + """ + The UI color of the stage as a HEX string. + """ + color: String! + """ + Whether this stage is frozen. Only applicable to started stages. + """ + frozen: Boolean + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + The name of the stage. + """ + name: String! + """ + The identifier of the pipeline this stage belongs to. + """ + pipelineId: String! + """ + The position of the stage. + """ + position: Float! + """ + The type of the stage. + """ + type: ReleaseStageType! +} + +type ReleaseStageEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: ReleaseStage! +} + +""" +Release stage filtering options. +""" +input ReleaseStageFilter { + """ + Compound filters, all of which need to be matched by the stage. + """ + and: [ReleaseStageFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Comparator for the stage name. + """ + name: StringComparator + """ + Compound filters, one of which need to be matched by the stage. + """ + or: [ReleaseStageFilter!] + """ + Comparator for the stage type. + """ + type: ReleaseStageTypeComparator + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +The result of a release stage mutation. +""" +type ReleaseStagePayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + The release stage that was created or updated. + """ + releaseStage: ReleaseStage! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Release stage sorting options. +""" +input ReleaseStageSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +The type of a release stage, which determines the release's lifecycle state. Types include planned, started, completed, and canceled. Each pipeline must have at least one stage of each type, though only started stages may have multiple instances. +""" +enum ReleaseStageType { + canceled + completed + planned + started +} + +""" +Comparator for release stage type. +""" +input ReleaseStageTypeComparator { + """ + Equals constraint. + """ + eq: ReleaseStageType + """ + In-array constraint. + """ + in: [ReleaseStageType!] + """ + Not-equals constraint. + """ + neq: ReleaseStageType + """ + Not-in-array constraint. + """ + nin: [ReleaseStageType!] + """ + Null constraint. Matches any non-null values if the given value is false, otherwise it matches null values. + """ + null: Boolean +} + +""" +Input for updating an existing release stage. +""" +input ReleaseStageUpdateInput { + """ + The UI color of the stage as a HEX string. + """ + color: String + """ + Whether this stage is frozen. Only applicable to started stages. + """ + frozen: Boolean + """ + The name of the stage. + """ + name: String + """ + The position of the stage. + """ + position: Float +} + +""" +Input for syncing release data to a specific pipeline. Extends the base sync input with the target pipeline identifier. +""" +input ReleaseSyncInput { + """ + The commit SHA associated with this release. + """ + commitSha: String! + """ + Debug information for release creation diagnostics. + """ + debugSink: ReleaseDebugSinkInput + """ + The description of the release. Pass null to clear an existing description. + """ + description: String + """ + Documents to attach to the release. Existing documents on the release with the same title are updated. + """ + documents: [ReleaseDocumentInput!] + """ + Issue references (e.g. ENG-123) to associate with this release. + """ + issueReferences: [IssueReferenceInput!] + """ + External links to attach to the release. + """ + links: [ReleaseLinkInput!] + """ + The name of the release. + """ + name: String + """ + The identifier of the pipeline this release belongs to. + """ + pipelineId: String! + """ + When true, an existing scheduled release keeps its stored commit SHA instead of taking this sync's commit. Set by CLI syncs from a checkout behind the stored commit, so the scan baseline does not move backwards. Has no effect on continuous pipelines, which identify releases by commit SHA. + """ + preserveStoredCommitSha: Boolean + """ + Pull request references to look up. Issues linked to found PRs will be associated with this release. + """ + pullRequestReferences: [PullRequestReferenceInput!] + """ + Release notes covering this release. Upserts the existing release notes that cover only this release. + """ + releaseNotes: ReleaseNoteInput + """ + Information about the source repository. + """ + repository: RepositoryDataInput + """ + Issue references that were reverted and should be removed from the release. + """ + revertedIssueReferences: [IssueReferenceInput!] + """ + The version of the release. + """ + version: String +} + +""" +Base input for syncing release data, containing the commit SHA, issue references, pull request references, and optional metadata. Does not include the pipeline ID, which is provided separately or inferred from the access key. +""" +input ReleaseSyncInputBase { + """ + The commit SHA associated with this release. + """ + commitSha: String! + """ + Debug information for release creation diagnostics. + """ + debugSink: ReleaseDebugSinkInput + """ + The description of the release. Pass null to clear an existing description. + """ + description: String + """ + Documents to attach to the release. Existing documents on the release with the same title are updated. + """ + documents: [ReleaseDocumentInput!] + """ + Issue references (e.g. ENG-123) to associate with this release. + """ + issueReferences: [IssueReferenceInput!] + """ + External links to attach to the release. + """ + links: [ReleaseLinkInput!] + """ + The name of the release. + """ + name: String + """ + When true, an existing scheduled release keeps its stored commit SHA instead of taking this sync's commit. Set by CLI syncs from a checkout behind the stored commit, so the scan baseline does not move backwards. Has no effect on continuous pipelines, which identify releases by commit SHA. + """ + preserveStoredCommitSha: Boolean + """ + Pull request references to look up. Issues linked to found PRs will be associated with this release. + """ + pullRequestReferences: [PullRequestReferenceInput!] + """ + Release notes covering this release. Upserts the existing release notes that cover only this release. + """ + releaseNotes: ReleaseNoteInput + """ + Information about the source repository. + """ + repository: RepositoryDataInput + """ + Issue references that were reverted and should be removed from the release. + """ + revertedIssueReferences: [IssueReferenceInput!] + """ + The version of the release. + """ + version: String +} + +""" +Input for updating a release by pipeline identifier. Extends the base update input with the target pipeline identifier. +""" +input ReleaseUpdateByPipelineInput { + """ + Optional release description to apply when updating the release. Pass null to clear it. + """ + description: String + """ + Documents to attach to the updated release. Existing documents with the same title are updated. + """ + documents: [ReleaseDocumentInput!] + """ + External links to attach to the updated release. + """ + links: [ReleaseLinkInput!] + """ + Optional release name to apply when updating the release. + """ + name: String + """ + The identifier of the pipeline. + """ + pipelineId: String! + """ + Release notes covering the updated release. + """ + releaseNotes: ReleaseNoteInput + """ + The stage name to set. First tries exact match, then falls back to case-insensitive matching with dashes/underscores treated as spaces. + """ + stage: String + """ + The version of the release to update. If not provided, the latest started or latest planned release will be updated. + """ + version: String +} + +""" +Base input for updating a release by pipeline. Contains optional version and stage name. The pipeline ID is provided separately or inferred from the access key. +""" +input ReleaseUpdateByPipelineInputBase { + """ + Optional release description to apply when updating the release. Pass null to clear it. + """ + description: String + """ + Documents to attach to the updated release. Existing documents with the same title are updated. + """ + documents: [ReleaseDocumentInput!] + """ + External links to attach to the updated release. + """ + links: [ReleaseLinkInput!] + """ + Optional release name to apply when updating the release. + """ + name: String + """ + Release notes covering the updated release. + """ + releaseNotes: ReleaseNoteInput + """ + The stage name to set. First tries exact match, then falls back to case-insensitive matching with dashes/underscores treated as spaces. + """ + stage: String + """ + The version of the release to update. If not provided, the latest started or latest planned release will be updated. + """ + version: String +} + +""" +Input for updating an existing release. +""" +input ReleaseUpdateInput { + """ + The commit SHA associated with this release. + """ + commitSha: String + """ + The time at which the release was completed. + """ + completedAt: DateTime + """ + The description of the release. + """ + description: String + """ + The name of the release. + """ + name: String + """ + The current stage of the release. + """ + stageId: String + """ + The estimated start date of the release. + """ + startDate: TimelessDate + """ + The time at which the release was started. + """ + startedAt: DateTime + """ + The estimated completion date of the release. + """ + targetDate: TimelessDate + """ + Whether the release has been trashed. Set to true to trash, or null to restore. + """ + trashed: Boolean + """ + The version of the release. + """ + version: String +} + +""" +Payload for a release webhook. +""" +type ReleaseWebhookPayload { + """ + The time at which the entity was archived. + """ + archivedAt: String + """ + The time at which the release was canceled. + """ + canceledAt: String + """ + The commit SHA associated with this release. + """ + commitSha: String + """ + The time at which the release was completed. + """ + completedAt: String + """ + The time at which the entity was created. + """ + createdAt: String! + """ + The ID of the user who created the release. + """ + creatorId: String + """ + The release's description. + """ + description: String + """ + The ID of the entity. + """ + id: String! + """ + The issues associated with the release. + """ + issues: [IssueChildWebhookPayload!] + """ + The name of the release. + """ + name: String! + """ + The pipeline this release belongs to. + """ + pipeline: ReleasePipelineChildWebhookPayload + """ + The ID of the pipeline this release belongs to. + """ + pipelineId: String! + """ + The release's unique URL slug. + """ + slugId: String! + """ + The current stage of the release. + """ + stage: ReleaseStageChildWebhookPayload + """ + The ID of the current stage of the release. + """ + stageId: String! + """ + The estimated start date of the release. + """ + startDate: String + """ + The time at which the release was started. + """ + startedAt: String + """ + The estimated completion date of the release. + """ + targetDate: String + """ + Whether the release is in the trash bin. + """ + trashed: Boolean + """ + The time at which the entity was updated. + """ + updatedAt: String! + """ + The URL of the release. + """ + url: String! + """ + The version of the release. + """ + version: String +} + +""" +Metadata about the source code repository from which a release is being synced, including the hosting provider and repository coordinates. +""" +input RepositoryDataInput { + """ + The name of the repository. + """ + name: String! + """ + The owner of the repository (e.g., organization or user name). + """ + owner: String! + """ + The VCS provider hosting the repository (e.g., 'github', 'gitlab', 'bitbucket'). + """ + provider: String! + """ + The base URL of the repository on the hosting provider (e.g., 'https://github.com/linear/linear-app'). + """ + url: String! +} + +""" +A suggested code repository that may be relevant for implementing an issue. +""" +type RepositorySuggestion { + """ + Confidence score from 0.0 to 1.0. + """ + confidence: Float! + """ + Hostname of the Git service (e.g., 'github.com', 'github.company.com'). + """ + hostname: String + """ + The full name of the repository in owner/name format (e.g., 'acme/backend'). + """ + repositoryFullName: String! +} + +""" +The result of a repository suggestions query, containing the list of suggested repositories. +""" +type RepositorySuggestionsPayload { + """ + The suggested repositories. + """ + suggestions: [RepositorySuggestion!]! +} + +""" +Customer revenue sorting options. +""" +input RevenueSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +[Deprecated] A roadmap for grouping projects. Use Initiative instead, which supersedes this entity and provides richer hierarchy and tracking capabilities. +""" +type Roadmap implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The roadmap's color. + """ + color: String + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The user who created the roadmap. + """ + creator: User! + """ + The description of the roadmap. + """ + description: String + """ + The unique identifier of the entity. + """ + id: ID! + """ + The name of the roadmap. + """ + name: String! + """ + The workspace of the roadmap. + """ + organization: Organization! + """ + The user who owns the roadmap. + """ + owner: User + """ + Projects associated with the roadmap. + """ + projects( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned projects. + """ + filter: ProjectFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): ProjectConnection! + """ + The roadmap's unique URL slug. + """ + slugId: String! + """ + The sort order of the roadmap within the workspace. + """ + sortOrder: Float! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The canonical url for the roadmap. + """ + url: String! +} + +""" +A generic payload return from entity archive mutations. +""" +type RoadmapArchivePayload implements ArchivePayload { + """ + The archived/unarchived entity. Null if entity was deleted. + """ + entity: Roadmap + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Roadmap collection filtering options. +""" +input RoadmapCollectionFilter { + """ + Compound filters, all of which need to be matched by the roadmap. + """ + and: [RoadmapCollectionFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Filters that the roadmap creator must satisfy. + """ + creator: UserFilter + """ + Filters that needs to be matched by all roadmaps. + """ + every: RoadmapFilter + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Comparator for the collection length. + """ + length: NumberComparator + """ + Comparator for the roadmap name. + """ + name: StringComparator + """ + Compound filters, one of which need to be matched by the roadmap. + """ + or: [RoadmapCollectionFilter!] + """ + Comparator for the roadmap slug ID. + """ + slugId: StringComparator + """ + Filters that needs to be matched by some roadmaps. + """ + some: RoadmapFilter + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +type RoadmapConnection { + edges: [RoadmapEdge!]! + nodes: [Roadmap!]! + pageInfo: PageInfo! +} + +""" +Input for creating a new roadmap. +""" +input RoadmapCreateInput { + """ + The roadmap's color. + """ + color: String + """ + The description of the roadmap. + """ + description: String + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + The name of the roadmap. + """ + name: String! + """ + The owner of the roadmap. + """ + ownerId: String + """ + The sort order of the roadmap within the workspace. + """ + sortOrder: Float +} + +type RoadmapEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: Roadmap! +} + +""" +Roadmap filtering options. +""" +input RoadmapFilter { + """ + Compound filters, all of which need to be matched by the roadmap. + """ + and: [RoadmapFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Filters that the roadmap creator must satisfy. + """ + creator: UserFilter + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Comparator for the roadmap name. + """ + name: StringComparator + """ + Compound filters, one of which need to be matched by the roadmap. + """ + or: [RoadmapFilter!] + """ + Comparator for the roadmap slug ID. + """ + slugId: StringComparator + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +The result of a roadmap mutation. +""" +type RoadmapPayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + The roadmap that was created or updated. + """ + roadmap: Roadmap! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +[Deprecated] The join entity linking a project to a roadmap. Use InitiativeToProject instead, which supersedes this entity. +""" +type RoadmapToProject implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The unique identifier of the entity. + """ + id: ID! + """ + The project that the roadmap is associated with. + """ + project: Project! + """ + The roadmap that the project is associated with. + """ + roadmap: Roadmap! + """ + The sort order of the project within the roadmap. + """ + sortOrder: String! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +type RoadmapToProjectConnection { + edges: [RoadmapToProjectEdge!]! + nodes: [RoadmapToProject!]! + pageInfo: PageInfo! +} + +""" +Input for creating a new roadmap-to-project mapping. +""" +input RoadmapToProjectCreateInput { + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + The identifier of the project. + """ + projectId: String! + """ + The identifier of the roadmap. + """ + roadmapId: String! + """ + The sort order for the project within its workspace. + """ + sortOrder: Float +} + +type RoadmapToProjectEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: RoadmapToProject! +} + +""" +The result of a roadmap-to-project mutation. +""" +type RoadmapToProjectPayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + The roadmapToProject that was created or updated. + """ + roadmapToProject: RoadmapToProject! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Input for updating an existing roadmap-to-project mapping. +""" +input RoadmapToProjectUpdateInput { + """ + The sort order for the project within its workspace. + """ + sortOrder: Float +} + +""" +Input for updating an existing roadmap. +""" +input RoadmapUpdateInput { + """ + The roadmap's color. + """ + color: String + """ + The description of the roadmap. + """ + description: String + """ + The name of the roadmap. + """ + name: String + """ + The owner of the roadmap. + """ + ownerId: String + """ + The sort order of the roadmap within the workspace. + """ + sortOrder: Float +} + +""" +Issue root-issue sorting options. +""" +input RootIssueSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder + """ + The sort to apply to the root issues + """ + sort: IssueSortInput! +} + +""" +Which day count to use for SLA calculations. +""" +enum SLADayCountType { + all + onlyBusinessDays +} + +""" +Determines when timing begins for an SLA applied by a rule. +""" +enum SLAStartMode { + issueCreation + ruleMatch +} + +""" +[INTERNAL] Comparator for Salesforce metadata. +""" +input SalesforceMetadataIntegrationComparator { + """ + Salesforce Case metadata filter + """ + caseMetadata: JSONObject +} + +input SalesforceSettingsInput { + """ + Whether a ticket should be automatically reopened when its linked Linear issue is canceled. + """ + automateTicketReopeningOnCancellation: Boolean + """ + Whether a ticket should be automatically reopened when a comment is posted on its linked Linear issue + """ + automateTicketReopeningOnComment: Boolean + """ + Whether a ticket should be automatically reopened when its linked Linear issue is completed. + """ + automateTicketReopeningOnCompletion: Boolean + """ + Whether a ticket should be automatically reopened when its linked Linear project is canceled. + """ + automateTicketReopeningOnProjectCancellation: Boolean + """ + Whether a ticket should be automatically reopened when its linked Linear project is completed. + """ + automateTicketReopeningOnProjectCompletion: Boolean + """ + The Salesforce team to use when a template doesn't specify a team. + """ + defaultTeam: String + """ + [ALPHA] Whether customer and customer requests should not be automatically created when conversations are linked to a Linear issue. + """ + disableCustomerRequestsAutoCreation: Boolean + """ + Whether Linear Agent should be enabled for this integration. + """ + enableAiIntake: Boolean + """ + The Salesforce case status to use to reopen cases. + """ + reopenCaseStatus: String + """ + Whether to restrict visibility of the integration to issues that have been either created from Salesforce or linked to Salesforce. + """ + restrictVisibility: Boolean + """ + Whether an internal message should be added when someone comments on an issue. + """ + sendNoteOnComment: Boolean + """ + Whether an internal message should be added when a Linear issue changes status (for status types except completed or canceled). + """ + sendNoteOnStatusChange: Boolean + """ + The Salesforce subdomain. + """ + subdomain: String + """ + Whether replies posted on the Chatter feed of a linked Salesforce case are synced back into the Linear issue's synced comment thread. Requires a managed package version that ships the Chatter feed trigger. + """ + syncCommentsFromChatter: Boolean + """ + The Salesforce instance URL. + """ + url: String +} + +""" +Filters for semantic search results. +""" +input SemanticSearchFilters { + """ + Filters applied to documents. + """ + documents: DocumentFilter + """ + Filters applied to initiatives. + """ + initiatives: InitiativeFilter + """ + Filters applied to issues. + """ + issues: IssueFilter + """ + Filters applied to projects. + """ + projects: ProjectFilter +} + +""" +The payload returned by the semantic search query, containing the list of matching results. +""" +type SemanticSearchPayload { + """ + Whether the semantic search is enabled. + """ + enabled: Boolean! @deprecated(reason: "Always true.") + """ + The list of matching search results, ordered by relevance score. + """ + results: [SemanticSearchResult!]! +} + +""" +A reference to an entity returned by semantic search, containing its type and ID. Resolve the specific entity using the type-specific field resolvers (issue, project, initiative, document). +""" +type SemanticSearchResult implements Node { + """ + The document entity, if this search result is of type Document. Null for other result types. + """ + document: Document + """ + The unique identifier of the entity. + """ + id: ID! + """ + The initiative entity, if this search result is of type Initiative. Null for other result types. + """ + initiative: Initiative + """ + The issue entity, if this search result is of type Issue. Null for other result types. + """ + issue: Issue + """ + The project entity, if this search result is of type Project. Null for other result types. + """ + project: Project + """ + The type of the semantic search result. + """ + type: SemanticSearchResultType! +} + +""" +The type of the semantic search result. +""" +enum SemanticSearchResultType { + document + initiative + issue + project +} + +enum SendStrategy { + desktop + desktopAndPush + desktopThenPush + push +} + +input SentrySettingsInput { + """ + The ID of the Sentry organization being connected. + """ + organizationId: ID! + """ + The slug of the Sentry organization being connected. + """ + organizationSlug: String! + """ + Whether Sentry issues resolving completes Linear issues. + """ + resolvingCompletesIssues: Boolean! + """ + Whether Sentry issues unresolving reopens Linear issues. + """ + unresolvingReopensIssues: Boolean! +} + +""" +A verified Amazon SES domain identity that enables sending emails from a custom domain. Organizations configure SES domain identities to send issue notification replies and Asks auto-replies from their own domain instead of the default Linear domain. Full verification requires DKIM signing, a custom MAIL FROM domain, and organization ownership confirmation. Multiple organizations sharing the same domain each have their own SesDomainIdentity record but share the underlying SES identity. +""" +type SesDomainIdentity implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + Whether the domain is fully verified and can be used for sending emails. + """ + canSendFromCustomDomain: Boolean! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The user who created the SES domain identity. + """ + creator: User + """ + The DNS records for the SES domain identity. + """ + dnsRecords: [SesDomainIdentityDnsRecord!]! + """ + The domain of the SES domain identity. + """ + domain: String! + """ + The unique identifier of the entity. + """ + id: ID! + """ + The workspace of the SES domain identity. + """ + organization: Organization! + """ + The AWS region of the SES domain identity. + """ + region: String! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +""" +A DNS record for a SES domain identity. +""" +type SesDomainIdentityDnsRecord { + """ + The content of the DNS record. + """ + content: String! + """ + Whether the DNS record is verified in the domain's DNS configuration. + """ + isVerified: Boolean! + """ + The name of the DNS record. + """ + name: String! + """ + The type of the DNS record. + """ + type: String! +} + +""" +Customer size sorting options. +""" +input SizeSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +An active SLA rule that can apply to a team. +""" +type SlaConfiguration { + """ + The workflow conditions that determine when this SLA rule applies. + """ + conditions: JSONObject! + """ + The identifier of the SLA rule. + """ + id: String! + """ + The name of the SLA rule. + """ + name: String! + """ + Whether the rule removes an SLA instead of setting one. + """ + removesSla: Boolean! + """ + The SLA value configured by the rule, expressed in milliseconds or business days depending on the day-count type. + """ + sla: Float + """ + The SLA type used when the rule sets an SLA. + """ + slaType: SLADayCountType + """ + When SLA timing begins. Null when the rule removes an SLA. + """ + startMode: SLAStartMode +} + +enum SlaStatus { + Breached + Completed + Failed + HighRisk + LowRisk + MediumRisk +} + +""" +Comparator for sla status. +""" +input SlaStatusComparator { + """ + Equals constraint. + """ + eq: SlaStatus + """ + In-array constraint. + """ + in: [SlaStatus!] + """ + Not-equals constraint. + """ + neq: SlaStatus + """ + Not-in-array constraint. + """ + nin: [SlaStatus!] + """ + Null constraint. Matches any non-null values if the given value is false, otherwise it matches null values. + """ + null: Boolean +} + +""" +Issue SLA status sorting options. +""" +input SlaStatusSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +input SlackAsksSettingsInput { + """ + The user role type that is allowed to manage Asks settings. + """ + canAdministrate: UserRoleType! + """ + Controls who can see and set Customers when creating Asks in Slack. + """ + customerVisibility: CustomerVisibilityMode + """ + Whether Linear Agent should be enabled for this Slack Asks integration. + """ + enableAgent: Boolean + """ + Whether Linear Agent should be given Org-wide access within Slack workflows. + """ + enableLinearAgentWorkflowAccess: Boolean + """ + Enterprise id of the connected Slack enterprise + """ + enterpriseId: String + """ + Enterprise name of the connected Slack enterprise + """ + enterpriseName: String + """ + Whether to allow external users to perform actions on unfurls + """ + externalUserActions: Boolean + """ + Whether to show unfurl previews in Slack + """ + shouldUnfurl: Boolean + """ + Whether to show unfurls in the default style instead of Work Objects in Slack + """ + shouldUseDefaultUnfurl: Boolean + """ + The mapping of Slack channel ID => Slack channel name for connected channels. + """ + slackChannelMapping: [SlackChannelNameMappingInput!] + """ + Slack workspace id + """ + teamId: String + """ + Slack workspace name + """ + teamName: String +} + +""" +Configuration for a Linear team within a Slack Asks channel mapping. Controls whether the default Asks template is enabled for the team in a given Slack channel. +""" +type SlackAsksTeamSettings { + """ + Whether the default Asks template is enabled in the given channel for this team. + """ + hasDefaultAsk: Boolean! + """ + The Linear team ID. + """ + id: String! +} + +input SlackAsksTeamSettingsInput { + """ + Whether the default Asks template is enabled in the given channel for this team. + """ + hasDefaultAsk: Boolean! + """ + The Linear team ID. + """ + id: String! +} + +type SlackChannelConnectPayload { + """ + Whether the bot needs to be manually added to the channel. + """ + addBot: Boolean! + """ + GitHub-specific details for the operation. Populated by GitHub-related mutations only. + """ + gitHub: GitHubIntegrationConnectDetails + """ + The integration that was created or updated. + """ + integration: Integration + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether it's recommended to connect main Slack integration. + """ + nudgeToConnectMainSlackIntegration: Boolean + """ + Whether it's recommended to update main Slack integration. + """ + nudgeToUpdateMainSlackIntegration: Boolean + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Configuration for a Slack channel connected to Linear via Slack Asks. Maps the Slack channel ID and name to team assignments and auto-creation settings that control how issues are created from Slack messages in this channel. +""" +type SlackChannelNameMapping { + """ + Whether or not to use AI to generate titles for Asks created in this channel. + """ + aiTitles: Boolean + """ + Whether or not @-mentioning the bot should automatically create an Ask with the message. + """ + autoCreateOnBotMention: Boolean + """ + Whether or not using the :ticket: emoji in this channel should automatically create Asks. + """ + autoCreateOnEmoji: Boolean + """ + Whether or not top-level messages in this channel should automatically create Asks. + """ + autoCreateOnMessage: Boolean + """ + The optional template ID to use for Asks auto-created in this channel. If not set, auto-created Asks won't use any template. + """ + autoCreateTemplateId: String + """ + Whether or not the Linear Asks bot has been added to this Slack channel. + """ + botAdded: Boolean + """ + The Slack channel ID. + """ + id: String! + """ + Whether or not the Slack channel is private. + """ + isPrivate: Boolean + """ + Whether or not the Slack channel is shared with an external org. + """ + isShared: Boolean + """ + The Slack channel name. + """ + name: String! + """ + Whether or not synced Slack threads should be updated with a message when their Ask is accepted from triage. + """ + postAcceptedFromTriageUpdates: Boolean + """ + Whether or not synced Slack threads should be updated with a message when their Ask has an updated assignee. + """ + postAssignmentUpdates: Boolean + """ + Whether or not synced Slack threads should be updated with a message and emoji when their Ask is canceled. + """ + postCancellationUpdates: Boolean + """ + Whether or not synced Slack threads should be updated with a message and emoji when their Ask is completed. + """ + postCompletionUpdates: Boolean + """ + Whether or not synced Slack threads should be updated with a message when their Ask's SLA is at risk or breached. + """ + postSlaUpdates: Boolean + """ + Which teams are connected to the channel and settings for those teams. + """ + teams: [SlackAsksTeamSettings!]! +} + +input SlackChannelNameMappingInput { + """ + Whether or not to use AI to generate titles for Asks created in this channel. + """ + aiTitles: Boolean + """ + Whether or not @-mentioning the bot should automatically create an Ask with the message. + """ + autoCreateOnBotMention: Boolean + """ + Whether or not using the :ticket: emoji in this channel should automatically create Asks. + """ + autoCreateOnEmoji: Boolean + """ + Whether or not top-level messages in this channel should automatically create Asks. + """ + autoCreateOnMessage: Boolean + """ + The optional template ID to use for Asks auto-created in this channel. If not set, auto-created Asks won't use any template. + """ + autoCreateTemplateId: String + """ + Whether or not the Linear Asks bot has been added to this Slack channel. + """ + botAdded: Boolean + """ + The Slack channel ID. + """ + id: String! + """ + Whether or not the Slack channel is private. + """ + isPrivate: Boolean + """ + Whether or not the Slack channel is shared with an external org. + """ + isShared: Boolean + """ + The Slack channel name. + """ + name: String! + """ + Whether or not synced Slack threads should be updated with a message when their Ask is accepted from triage. + """ + postAcceptedFromTriageUpdates: Boolean + """ + Whether or not synced Slack threads should be updated with a message when their Ask has an updated assignee. + """ + postAssignmentUpdates: Boolean + """ + Whether or not synced Slack threads should be updated with a message and emoji when their Ask is canceled. + """ + postCancellationUpdates: Boolean + """ + Whether or not synced Slack threads should be updated with a message and emoji when their Ask is completed. + """ + postCompletionUpdates: Boolean + """ + Whether or not synced Slack threads should be updated with a message when their Ask's SLA is at risk or breached. + """ + postSlaUpdates: Boolean + """ + Which teams are connected to the channel and settings for those teams. + """ + teams: [SlackAsksTeamSettingsInput!]! +} + +enum SlackChannelType { + DirectMessage + MultiPersonDirectMessage + Private + PrivateGroup + Public +} + +input SlackPostSettingsInput { + """ + The name of the Slack channel. + """ + channel: String! + """ + The Slack channel ID. + """ + channelId: String! + """ + The type of the Slack channel (e.g., public, private, or DM). + """ + channelType: SlackChannelType + """ + The URL to the Slack integration configuration page. + """ + configurationUrl: String! + """ + The Slack workspace ID. + """ + teamId: String +} + +input SlackSettingsInput { + """ + Whether Linear Agent may respond in private channels for this Slack integration. + """ + allowAgentInPrivateChannels: Boolean + """ + Whether Linear Agent should be enabled for this Slack integration. + """ + enableAgent: Boolean + """ + Whether Code Intelligence should be enabled for this Slack integration. + """ + enableCodeIntelligence: Boolean + """ + Whether Linear Agent should be given Org-wide access within Slack workflows. + """ + enableLinearAgentWorkflowAccess: Boolean + """ + Whether Loops may read and send messages through this Slack integration. + """ + enableLoops: Boolean + """ + Enterprise id of the connected Slack enterprise + """ + enterpriseId: String + """ + Enterprise name of the connected Slack enterprise + """ + enterpriseName: String + """ + Whether to allow external users to perform actions on unfurls + """ + externalUserActions: Boolean + """ + Whether Linear should automatically respond with issue unfurls when an issue identifier is mentioned in a Slack message. + """ + linkOnIssueIdMention: Boolean! + """ + Whether to show unfurl previews in Slack + """ + shouldUnfurl: Boolean + """ + Whether to show unfurls in the default style instead of Work Objects in Slack + """ + shouldUseDefaultUnfurl: Boolean + """ + Whether Linear Agent should automatically sync threads in private channels for this Slack integration. + """ + syncAgentThreadsInPrivateChannels: Boolean + """ + Slack workspace id + """ + teamId: String + """ + Slack workspace name + """ + teamName: String +} + +""" +Comparator for issue source type. +""" +input SourceMetadataComparator { + """ + Null constraint. When true, matches issues without an external source: issues with no source metadata and issues created through the API, an OAuth application, or a loop. When false, matches issues created by an integration or an intake source such as email. + """ + null: Boolean + """ + [INTERNAL] Comparator for the salesforce metadata. + """ + salesforceMetadata: SalesforceMetadataIntegrationComparator + """ + Comparator for the sub type. + """ + subType: SubTypeComparator + """ + Comparator for the workflow definition that created the issue. + """ + workflowDefinitionId: WorkflowDefinitionIdComparator +} + +""" +Comparator for `sourceType` field. +""" +input SourceTypeComparator { + """ + Contains constraint. Matches any values that contain the given string. + """ + contains: String + """ + Contains case insensitive constraint. Matches any values that contain the given string case insensitive. + """ + containsIgnoreCase: String + """ + Contains case and accent insensitive constraint. Matches any values that contain the given string case and accent insensitive. + """ + containsIgnoreCaseAndAccent: String + """ + Ends with constraint. Matches any values that end with the given string. + """ + endsWith: String + """ + Equals constraint. + """ + eq: String + """ + Equals case insensitive. Matches any values that matches the given string case insensitive. + """ + eqIgnoreCase: String + """ + In-array constraint. + """ + in: [String!] + """ + Not-equals constraint. + """ + neq: String + """ + Not-equals case insensitive. Matches any values that don't match the given string case insensitive. + """ + neqIgnoreCase: String + """ + Not-in-array constraint. + """ + nin: [String!] + """ + Doesn't contain constraint. Matches any values that don't contain the given string. + """ + notContains: String + """ + Doesn't contain case insensitive constraint. Matches any values that don't contain the given string case insensitive. + """ + notContainsIgnoreCase: String + """ + Doesn't end with constraint. Matches any values that don't end with the given string. + """ + notEndsWith: String + """ + Doesn't start with constraint. Matches any values that don't start with the given string. + """ + notStartsWith: String + """ + Starts with constraint. Matches any values that start with the given string. + """ + startsWith: String + """ + Starts with case insensitive constraint. Matches any values that start with the given string. + """ + startsWithIgnoreCase: String +} + +type SsoUrlFromEmailResponse { + """ + SAML SSO sign-in URL. + """ + samlSsoUrl: String! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Project start date sorting options. +""" +input StartDateSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +Comparator for strings. +""" +input StringArrayComparator { + """ + Compound filters, all of which need to be matched. + """ + every: StringItemComparator + """ + Length of the array. Matches any values that have the given length. + """ + length: NumberComparator + """ + Compound filters, one of which needs to be matched. + """ + some: StringItemComparator +} + +""" +Comparator for strings. +""" +input StringComparator { + """ + Contains constraint. Matches any values that contain the given string. + """ + contains: String + """ + Contains case insensitive constraint. Matches any values that contain the given string case insensitive. + """ + containsIgnoreCase: String + """ + Contains case and accent insensitive constraint. Matches any values that contain the given string case and accent insensitive. + """ + containsIgnoreCaseAndAccent: String + """ + Ends with constraint. Matches any values that end with the given string. + """ + endsWith: String + """ + Equals constraint. + """ + eq: String + """ + Equals case insensitive. Matches any values that matches the given string case insensitive. + """ + eqIgnoreCase: String + """ + In-array constraint. + """ + in: [String!] + """ + Not-equals constraint. + """ + neq: String + """ + Not-equals case insensitive. Matches any values that don't match the given string case insensitive. + """ + neqIgnoreCase: String + """ + Not-in-array constraint. + """ + nin: [String!] + """ + Doesn't contain constraint. Matches any values that don't contain the given string. + """ + notContains: String + """ + Doesn't contain case insensitive constraint. Matches any values that don't contain the given string case insensitive. + """ + notContainsIgnoreCase: String + """ + Doesn't end with constraint. Matches any values that don't end with the given string. + """ + notEndsWith: String + """ + Doesn't start with constraint. Matches any values that don't start with the given string. + """ + notStartsWith: String + """ + Starts with constraint. Matches any values that start with the given string. + """ + startsWith: String + """ + Starts with case insensitive constraint. Matches any values that start with the given string. + """ + startsWithIgnoreCase: String +} + +""" +Comparator for strings in arrays. +""" +input StringItemComparator { + """ + Contains constraint. Matches any values that contain the given string. + """ + contains: String + """ + Contains case insensitive constraint. Matches any values that contain the given string case insensitive. + """ + containsIgnoreCase: String + """ + Contains case and accent insensitive constraint. Matches any values that contain the given string case and accent insensitive. + """ + containsIgnoreCaseAndAccent: String + """ + Ends with constraint. Matches any values that end with the given string. + """ + endsWith: String + """ + Equals constraint. + """ + eq: String + """ + Equals case insensitive. Matches any values that matches the given string case insensitive. + """ + eqIgnoreCase: String + """ + In-array constraint. + """ + in: [String!] + """ + Not-equals constraint. + """ + neq: String + """ + Not-equals case insensitive. Matches any values that don't match the given string case insensitive. + """ + neqIgnoreCase: String + """ + Not-in-array constraint. + """ + nin: [String!] + """ + Doesn't contain constraint. Matches any values that don't contain the given string. + """ + notContains: String + """ + Doesn't contain case insensitive constraint. Matches any values that don't contain the given string case insensitive. + """ + notContainsIgnoreCase: String + """ + Doesn't end with constraint. Matches any values that don't end with the given string. + """ + notEndsWith: String + """ + Doesn't start with constraint. Matches any values that don't start with the given string. + """ + notStartsWith: String + """ + Starts with constraint. Matches any values that start with the given string. + """ + startsWith: String + """ + Starts with case insensitive constraint. Matches any values that start with the given string. + """ + startsWithIgnoreCase: String +} + +""" +Comparator for source type. +""" +input SubTypeComparator { + """ + Equals constraint. + """ + eq: String + """ + In-array constraint. + """ + in: [String!] + """ + Not-equals constraint. + """ + neq: String + """ + Not-in-array constraint. + """ + nin: [String!] + """ + Null constraint. Matches any non-null values if the given value is false, otherwise it matches null values. + """ + null: Boolean +} + +type Subscription { + """ + Triggered when an agent activity is archived + """ + agentActivityArchived: AgentActivity! + """ + Triggered when an agent activity is created + """ + agentActivityCreated: AgentActivity! + """ + Triggered when an agent activity is updated + """ + agentActivityUpdated: AgentActivity! + """ + Triggered when an agent session is created + """ + agentSessionCreated: AgentSession! + """ + Triggered when an agent session is updated + """ + agentSessionUpdated: AgentSession! + """ + Triggered when an ai conversation is updated + """ + aiConversationUpdated: AiConversation! + """ + Triggered when an ai prompt progress is created + """ + aiPromptProgressCreated( + """ + [Internal] Optional filter for AI prompt progress subscription events. + """ + filter: AiPromptProgressSubscriptionFilter + ): AiPromptProgress! + """ + Triggered when an ai prompt progress is updated + """ + aiPromptProgressUpdated( + """ + [Internal] Optional filter for AI prompt progress subscription events. + """ + filter: AiPromptProgressSubscriptionFilter + ): AiPromptProgress! + """ + Triggered when a comment is archived + """ + commentArchived: Comment! + """ + Triggered when a comment is created + """ + commentCreated: Comment! + """ + Triggered when a comment is deleted + """ + commentDeleted: Comment! + """ + Triggered when a comment is unarchived + """ + commentUnarchived: Comment! + """ + Triggered when a comment is updated + """ + commentUpdated: Comment! + """ + Triggered when a cycle is archived + """ + cycleArchived: Cycle! + """ + Triggered when a cycle is created + """ + cycleCreated: Cycle! + """ + Triggered when a cycle is updated + """ + cycleUpdated: Cycle! + """ + Triggered when a document is archived + """ + documentArchived: Document! + """ + Triggered when a document content is created + """ + documentContentCreated: DocumentContent! + """ + Triggered when a document content draft is created + """ + documentContentDraftCreated: DocumentContentDraft! + """ + Triggered when a document content draft is deleted + """ + documentContentDraftDeleted: DocumentContentDraft! + """ + Triggered when a document content draft is updated + """ + documentContentDraftUpdated: DocumentContentDraft! + """ + Triggered when a document content revision is created + """ + documentContentRevisionCreated: DocumentContentRevision! + """ + Triggered when a document content revision is deleted + """ + documentContentRevisionDeleted: DocumentContentRevision! + """ + Triggered when a document content revision is updated + """ + documentContentRevisionUpdated: DocumentContentRevision! + """ + Triggered when a document content is updated + """ + documentContentUpdated: DocumentContent! + """ + Triggered when a document is created + """ + documentCreated: Document! + """ + Triggered when a document is unarchived + """ + documentUnarchived: Document! + """ + Triggered when a document is updated + """ + documentUpdated: Document! + """ + Triggered when a draft is created + """ + draftCreated: Draft! + """ + Triggered when a draft is deleted + """ + draftDeleted: Draft! + """ + Triggered when a draft is updated + """ + draftUpdated: Draft! + """ + Triggered when a favorite is created + """ + favoriteCreated: Favorite! + """ + Triggered when a favorite is deleted + """ + favoriteDeleted: Favorite! + """ + Triggered when a favorite is updated + """ + favoriteUpdated: Favorite! + """ + Triggered when an initiative is created + """ + initiativeCreated: Initiative! + """ + Triggered when an initiative is deleted + """ + initiativeDeleted: Initiative! + """ + Triggered when an initiative is updated + """ + initiativeUpdated: Initiative! + """ + Triggered when an issue is archived + """ + issueArchived: Issue! + """ + Triggered when an issue is created + """ + issueCreated( + """ + Optional filter for issue subscription events. + """ + filter: IssueSubscriptionFilter + ): Issue! + """ + Triggered when an issue draft is created + """ + issueDraftCreated: IssueDraft! + """ + Triggered when an issue draft is deleted + """ + issueDraftDeleted: IssueDraft! + """ + Triggered when an issue draft is updated + """ + issueDraftUpdated: IssueDraft! + """ + Triggered when an issue history is created + """ + issueHistoryCreated: IssueHistory! + """ + Triggered when an issue history is updated + """ + issueHistoryUpdated: IssueHistory! + """ + Triggered when an issue label is created + """ + issueLabelCreated: IssueLabel! + """ + Triggered when an issue label is deleted + """ + issueLabelDeleted: IssueLabel! + """ + Triggered when an issue label is updated + """ + issueLabelUpdated: IssueLabel! + """ + Triggered when an issue relation is created + """ + issueRelationCreated: IssueRelation! + """ + Triggered when an issue relation is deleted + """ + issueRelationDeleted: IssueRelation! + """ + Triggered when an issue relation is updated + """ + issueRelationUpdated: IssueRelation! + """ + Triggered when an issue is unarchived + """ + issueUnarchived: Issue! + """ + Triggered when an issue is updated + """ + issueUpdated( + """ + Optional filter for issue subscription events. + """ + filter: IssueSubscriptionFilter + ): Issue! + """ + Triggered when a notification is archived + """ + notificationArchived: Notification! + """ + Triggered when a notification is created + """ + notificationCreated: Notification! + """ + Triggered when a notification is deleted + """ + notificationDeleted: Notification! + """ + Triggered when a notification is unarchived + """ + notificationUnarchived: Notification! + """ + Triggered when a notification is updated + """ + notificationUpdated: Notification! + """ + Triggered when an organization is updated + """ + organizationUpdated: Organization! + """ + Triggered when a project is archived + """ + projectArchived: Project! + """ + Triggered when a project is created + """ + projectCreated: Project! + """ + Triggered when a project label is created + """ + projectLabelCreated: ProjectLabel! + """ + Triggered when a project label is deleted + """ + projectLabelDeleted: ProjectLabel! + """ + Triggered when a project label is updated + """ + projectLabelUpdated: ProjectLabel! + """ + Triggered when a project is unarchived + """ + projectUnarchived: Project! + """ + Triggered when a project update is archived + """ + projectUpdateArchived: ProjectUpdate! + """ + Triggered when a project update is created + """ + projectUpdateCreated: ProjectUpdate! + """ + Triggered when a project update is deleted + """ + projectUpdateDeleted: ProjectUpdate! + """ + Triggered when a project update is updated + """ + projectUpdateUpdated: ProjectUpdate! + """ + Triggered when a project is updated + """ + projectUpdated: Project! + """ + Triggered when a pull request is updated + """ + pullRequestUpdated: PullRequest! + """ + Triggered when a roadmap is created + """ + roadmapCreated: Roadmap! + """ + Triggered when a roadmap is deleted + """ + roadmapDeleted: Roadmap! + """ + Triggered when a roadmap is updated + """ + roadmapUpdated: Roadmap! + """ + Triggered when a team is created + """ + teamCreated: Team! + """ + Triggered when a team is deleted + """ + teamDeleted: Team! + """ + Triggered when a team membership is created + """ + teamMembershipCreated: TeamMembership! + """ + Triggered when a team membership is deleted + """ + teamMembershipDeleted: TeamMembership! + """ + Triggered when a team membership is updated + """ + teamMembershipUpdated: TeamMembership! + """ + Triggered when a team is updated + """ + teamUpdated: Team! + """ + Triggered when an user is created + """ + userCreated: User! + """ + Triggered when an user settings is updated + """ + userSettingsUpdated: UserSettings! + """ + Triggered when an user is updated + """ + userUpdated: User! + """ + Triggered when a workflow state is archived + """ + workflowStateArchived: WorkflowState! + """ + Triggered when a workflow state is created + """ + workflowStateCreated: WorkflowState! + """ + Triggered when a workflow state is updated + """ + workflowStateUpdated: WorkflowState! +} + +type SuccessPayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +An AI-generated summary of an issue. Each issue can have at most one summary. The summary content is stored as ProseMirror data and tracks its generation status and timing. +""" +type Summary implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The summary content as a ProseMirror document containing the AI-generated summary text. + """ + content: JSONObject! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The evaluation log ID for this summary generation, used for tracking and debugging AI output quality. Null if not available. + """ + evalLogId: String + """ + The time at which the summary content was generated or last regenerated. + """ + generatedAt: DateTime! + """ + The current generation status of the summary, indicating whether generation is in progress, completed, or failed. + """ + generationStatus: SummaryGenerationStatus! + """ + The unique identifier of the entity. + """ + id: ID! + """ + The issue that this summary was generated for. + """ + issue: Issue! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +""" +The generation status of a summary. +""" +enum SummaryGenerationStatus { + completed + failed + pending +} + +""" +A comment thread that is synced with an external source such as Slack, Jira, GitHub, Salesforce, or email. Provides information about the external thread's origin, its current sync status, and whether the user has the necessary personal integration connected to participate in the thread. +""" +type SyncedExternalThread { + """ + A human-readable display name for the thread, derived from the external source. For Slack threads this is the channel name, for Jira it's the issue key, for email it's the sender name and count of other participants. + """ + displayName: String + """ + The unique identifier of this synced external thread. Auto-generated if not provided. + """ + id: ID + """ + Whether this thread is currently syncing comments bidirectionally with the external service. False if the external entity relation has been removed or if the thread was explicitly unsynced. + """ + isConnected: Boolean! + """ + Whether the current user has a working personal integration connected for the external service. For example, whether they have connected their personal Jira, GitHub, or Slack account. A connected personal integration may still return false if it has an authentication error. + """ + isPersonalIntegrationConnected: Boolean! + """ + Whether a connected personal integration is required to post comments in this synced thread. True for Jira and GitHub threads, where comments must be attributed to a specific user in the external system. False for Slack and other services where the workspace integration can post on behalf of users. + """ + isPersonalIntegrationRequired: Boolean! + """ + A human-readable display name for the external source (e.g., 'Slack', 'Jira', 'GitHub'). + """ + name: String + """ + The specific integration service for the external source (e.g., 'slack', 'jira', 'github', 'salesforce'). Null if the source type does not have a sub-type. + """ + subType: String + """ + The category of the external source (e.g., 'integration' for service integrations, 'email' for email-based threads). + """ + type: String! + """ + A URL linking to the thread in the external service. For example, a Slack message permalink, a Jira issue URL, or a GitHub issue URL. + """ + url: String +} + +""" +Project target date sorting options. +""" +input TargetDateSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +A team is the primary organizational unit in Linear. Issues belong to teams, and each team has its own workflow states, cycles, labels, and settings. Teams can be public (visible to all workspace members), private (visible only to team members), or restricted (visible only within an enclosing private-team boundary). Teams can also have sub-teams that inherit settings from their parent. +""" +type Team implements Node { + """ + Team's currently active cycle. + """ + activeCycle: Cycle + """ + [Internal] Whether the team can use Loops. The workspace's Loops team list sets it. + """ + agentAutomationEnabled: Boolean! + """ + Whether to enable AI discussion summaries for issues in this team. + """ + aiDiscussionSummariesEnabled: Boolean! + """ + Whether to enable resolved thread AI summaries. + """ + aiThreadSummariesEnabled: Boolean! + """ + Whether all members in the workspace can join the team. Only used for public teams. + """ + allMembersCanJoin: Boolean + """ + [Internal] The team's ancestor teams, ordered from the root to the immediate parent. + """ + ancestors: [Team!]! + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + Period after which automatically closed, completed, and duplicate issues are automatically archived in months. + """ + autoArchivePeriod: Float! + """ + Whether child issues should automatically close when their parent issue is closed + """ + autoCloseChildIssues: Boolean + """ + Whether parent issues should automatically close when all child issues are closed + """ + autoCloseParentIssues: Boolean + """ + Period after which issues are automatically closed in months. Null/undefined means disabled. + """ + autoClosePeriod: Float + """ + The canceled workflow state which auto closed issues will be set to. Defaults to the first canceled state. + """ + autoCloseStateId: String + """ + [Internal] The team's sub-teams. + """ + children: [Team!]! + """ + [Internal] Whether the team can use coding sessions. The workspace's coding sessions team list sets it. + """ + codingAgentEnabled: Boolean! + """ + The team's color. + """ + color: String + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + [Internal] The current progress of the team. + """ + currentProgress: JSONObject! + """ + Calendar feed URL (iCal) for cycles. + """ + cycleCalenderUrl: String! + """ + The cooldown time after each cycle in weeks. + """ + cycleCooldownTime: Float! + """ + The duration of each cycle in weeks. + """ + cycleDuration: Float! + """ + Auto assign completed issues to current cycle. + """ + cycleIssueAutoAssignCompleted: Boolean! + """ + Auto assign started issues to current cycle. + """ + cycleIssueAutoAssignStarted: Boolean! + """ + Auto assign issues to current cycle if in active status. + """ + cycleLockToActive: Boolean! + """ + The day of the week that a new cycle starts (0 = Sunday, 1 = Monday, ..., 6 = Saturday). + """ + cycleStartDay: Float! + """ + Cycles associated with the team. + """ + cycles( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned cycles. + """ + filter: CycleFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): CycleConnection! + """ + Whether the team uses cycles for sprint-style issue management. + """ + cyclesEnabled: Boolean! + """ + What to use as a default estimate for unestimated issues. + """ + defaultIssueEstimate: Float! + """ + The default workflow state into which issues are set when they are opened by team members. + """ + defaultIssueState: WorkflowState + """ + The default template to use for new projects created for the team. + """ + defaultProjectTemplate: Template + """ + The default template to use for new issues created by members of the team. + """ + defaultTemplateForMembers: Template + """ + The id of the default template to use for new issues created by members of the team. + """ + defaultTemplateForMembersId: String @deprecated(reason: "Use defaultTemplateForMembers instead") + """ + The default template to use for new issues created by non-members of the team. + """ + defaultTemplateForNonMembers: Template + """ + The id of the default template to use for new issues created by non-members of the team. + """ + defaultTemplateForNonMembersId: String + @deprecated(reason: "Use defaultTemplateForNonMembers instead") + """ + The team's description. + """ + description: String + """ + The name of the team including its parent team name if it has one. + """ + displayName: String! + """ + The workflow state into which issues are moved when a PR has been opened as draft. + """ + draftWorkflowState: WorkflowState @deprecated(reason: "Use team.gitAutomationStates instead.") + """ + [Internal] Facets associated with the team. + """ + facets: [Facet!]! + """ + The Git automation states for the team. + """ + gitAutomationStates( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): GitAutomationStateConnection! + """ + Whether to group recent issue history entries. + """ + groupIssueHistory: Boolean! + """ + The icon of the team. + """ + icon: String + """ + The unique identifier of the entity. + """ + id: ID! + """ + Whether the team should inherit its estimation settings from its parent. Only applies to sub-teams. + """ + inheritIssueEstimation: Boolean! + """ + [Internal] Whether the team should inherit its project statuses from its parent team, or from the workspace when it has no parent. + """ + inheritProjectStatuses: Boolean! + """ + [Internal] Whether the team should inherit its Slack auto-create project channel setting from its parent. Only applies to sub-teams. + """ + inheritSlackAutoCreateProjectChannel: Boolean! + """ + Whether the team should inherit its workflow statuses from its parent. Only applies to sub-teams. + """ + inheritWorkflowStatuses: Boolean! + """ + Whether team initiatives are enabled and shown in the team's sidebar. + """ + initiativesEnabled: Boolean! + """ + Settings for all integrations associated with that team. + """ + integrationsSettings: IntegrationsSettings + """ + [DEPRECATED] Unique hash for the team to be used in invite URLs. + """ + inviteHash: String! @deprecated(reason: "Not used anymore, simply returning an empty string.") + """ + The total number of issues in the team. By default excludes archived issues; use the includeArchived argument to include them. + """ + issueCount( + """ + Include archived issues in the count. + """ + includeArchived: Boolean = false + ): Int! + """ + Whether to allow zeros in issues estimates. + """ + issueEstimationAllowZero: Boolean! + """ + Whether to add additional points to the estimate scale. + """ + issueEstimationExtended: Boolean! + """ + The issue estimation type to use. Must be one of "notUsed", "exponential", "fibonacci", "linear", "tShirt". + """ + issueEstimationType: String! + """ + [DEPRECATED] Whether issues without priority should be sorted first. + """ + issueOrderingNoPriorityFirst: Boolean! @deprecated(reason: "This setting is no longer in use.") + """ + [DEPRECATED] Whether to move issues to bottom of the column when changing state. + """ + issueSortOrderDefaultToBottom: Boolean! + @deprecated(reason: "Use setIssueSortOrderOnStateChange instead.") + """ + Issues belonging to the team. Supports filtering and optional inclusion of sub-team issues. + """ + issues( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned issues. + """ + filter: IssueFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + Include issues from sub-teams. + """ + includeSubTeams: Boolean = false + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): IssueConnection! + """ + [Internal] Whether new users should join this team by default. + """ + joinByDefault: Boolean + """ + The team's unique key, used as a prefix in issue identifiers (e.g., 'ENG' in 'ENG-123') and in URLs. + """ + key: String! + """ + Labels associated with the team. + """ + labels( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned issue labels. + """ + filter: IssueLabelFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): IssueLabelConnection! + """ + The number of initiatives led by this team that would be deleted along with it. Counts every led initiative, including ones not otherwise visible to the caller, to mirror what deleting the team cascades. + """ + ledInitiativeCount: Int! + """ + Loops owned by the team that are visible to the requesting user. Includes enabled and disabled loops. + """ + loops( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): WorkflowDefinitionConnection! + """ + [DEPRECATED] No longer in use. Duplicates are now system-managed via the native duplicate state. + """ + markedAsDuplicateWorkflowState: WorkflowState + @deprecated(reason: "Duplicates are now system-managed via the native duplicate state.") + """ + Users who are members of this team. Supports filtering and pagination. + """ + members( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned users. + """ + filter: UserFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + Should query return disabled/suspended users (default: false). + """ + includeDisabled: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + """ + [INTERNAL] Sort returned users. + """ + sort: [UserSortInput!] + ): UserConnection! + """ + [ALPHA] The membership of the given user in the team. + """ + membership( + """ + The user ID. + """ + userId: String! + ): TeamMembership + """ + Memberships associated with the team. For easier access of the same data, use `members` query. + """ + memberships( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): TeamMembershipConnection! + """ + The workflow state into which issues are moved when a PR has been merged. + """ + mergeWorkflowState: WorkflowState @deprecated(reason: "Use team.gitAutomationStates instead.") + """ + The workflow state into which issues are moved when a PR is ready to be merged. + """ + mergeableWorkflowState: WorkflowState @deprecated(reason: "Use team.gitAutomationStates instead.") + """ + The team's name. + """ + name: String! + """ + The workspace that the team belongs to. + """ + organization: Organization! + """ + The team's parent team. + """ + parent: Team + """ + [Internal] Documents and external links pinned to the team home, optionally grouped under sections. + """ + pinnedResources: [TeamPinnedResource!]! + """ + [Internal] Posts associated with the team. + """ + posts: [Post!]! + """ + Whether the team is private. Private teams are only visible to their members and require an explicit invitation to join. + """ + private: Boolean! @deprecated(reason: "Use `Team.visibility` instead.") + """ + [Internal] The progress history of the team. + """ + progressHistory: JSONObject! + """ + Projects associated with the team. + """ + projects( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned projects. + """ + filter: ProjectFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + Include projects from sub-teams. + """ + includeSubTeams: Boolean = false + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + """ + [INTERNAL] Sort returned projects. + """ + sort: [ProjectSortInput!] + ): ProjectConnection! + """ + [Internal] For restricted teams, the enclosing private team that forms the visibility boundary. + """ + protectedBy: Team @deprecated(reason: "Use restrictedBy instead.") + """ + [Internal] The identifier of the enclosing private team that forms the visibility boundary for restricted teams. + """ + protectedById: String @deprecated(reason: "Use restrictedById instead.") + """ + Release pipelines associated with the team. + """ + releasePipelines( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned release pipelines. + """ + filter: ReleasePipelineFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): ReleasePipelineConnection! + """ + Whether an issue needs to have a priority set before leaving triage. + """ + requirePriorityToLeaveTriage: Boolean! + """ + [Internal] Sections shown on the team home that group pinned resources. + """ + resourceSections: [TeamResourceSection!]! + """ + [Internal] For restricted teams, the enclosing private team that forms the visibility boundary. Null for public and private teams. + """ + restrictedBy: Team + """ + [Internal] The identifier of the enclosing private team that forms the visibility boundary for restricted teams. + """ + restrictedById: String + """ + The time at which the team was retired. Retired teams no longer accept new issues or members. Null if the team has not been retired. + """ + retiredAt: DateTime + """ + The workflow state into which issues are moved when a review has been requested for the PR. + """ + reviewWorkflowState: WorkflowState @deprecated(reason: "Use team.gitAutomationStates instead.") + """ + The SCIM group name for the team. + """ + scimGroupName: String + """ + Whether the team is managed by a SCIM integration. SCIM-managed teams have their membership controlled by the identity provider. + """ + scimManaged: Boolean! + """ + Security settings for the team, including role-based restrictions for issue sharing, label management, member management, template management, and agent skills. + """ + securitySettings: JSONObject! + """ + Where to move issues when changing state. + """ + setIssueSortOrderOnStateChange: String! + """ + [Internal] Whether to automatically create a Slack channel when a new project is created in this team. + """ + slackAutoCreateProjectChannel: Boolean + """ + Whether to send new issue comment notifications to Slack. + """ + slackIssueComments: Boolean! @deprecated(reason: "No longer in use") + """ + Whether to send new issue status updates to Slack. + """ + slackIssueStatuses: Boolean! @deprecated(reason: "No longer in use") + """ + Whether to send new issue notifications to Slack. + """ + slackNewIssue: Boolean! @deprecated(reason: "No longer is use") + """ + The workflow state into which issues are moved when a PR has been opened. + """ + startWorkflowState: WorkflowState @deprecated(reason: "Use team.gitAutomationStates instead.") + """ + The states that define the workflow associated with the team. + """ + states( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned workflow states. + """ + filter: WorkflowStateFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): WorkflowStateConnection! + """ + Templates associated with the team. + """ + templates( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned templates. + """ + filter: NullableTemplateFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): TemplateConnection! + """ + The timezone of the team. Defaults to "America/Los_Angeles" + """ + timezone: String! + """ + Whether triage mode is enabled for the team. When enabled, issues created by non-members or integrations are routed to a triage state for review before entering the normal workflow. + """ + triageEnabled: Boolean! + """ + The workflow state into which issues are set when they are opened by non-team members or integrations if triage is enabled. + """ + triageIssueState: WorkflowState + """ + Team's triage responsibility. + """ + triageResponsibility: TriageResponsibility + """ + How many upcoming cycles to create. + """ + upcomingCycleCount: Float! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + Whether the viewer can add themselves to the team. False when the viewer is already a member, the team is archived, retired, or SCIM-managed, the viewer lacks the plan access or permission to add themselves, or the viewer has reached their team membership limit. Runs the same checks `teamMembershipCreate` applies to a viewer joining on their own. + """ + viewerCanJoin: Boolean! + """ + Whether the viewer can remove themselves from the team. False when the viewer is not a member, the team is SCIM-managed, the viewer is an app user the team does not accept, or leaving would leave the viewer without an active team. Otherwise mirrors the checks `teamMembershipDelete` applies to a viewer leaving on their own. + """ + viewerCanLeave: Boolean! + """ + The viewer's membership in the team. Null when the viewer is not a member. + """ + viewerMembership: TeamMembership + """ + The visibility of the team. Returns public for teams visible to all workspace members, private for teams visible only to members, and restricted for non-private teams inside a private-team boundary. + """ + visibility: TeamVisibility! + """ + Webhooks associated with the team. + """ + webhooks( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): WebhookConnection! +} + +""" +A generic payload return from entity archive mutations. +""" +type TeamArchivePayload implements ArchivePayload { + """ + The archived/unarchived entity. Null if entity was deleted. + """ + entity: Team + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Certain properties of a team. +""" +type TeamChildWebhookPayload { + """ + The ID of the team. + """ + id: String! + """ + The key of the team. + """ + key: String! + """ + The name of the team. + """ + name: String! +} + +""" +Team collection filtering options. +""" +input TeamCollectionFilter { + """ + Filters that the team's ancestors must satisfy. + """ + ancestors: TeamCollectionFilter + """ + Compound filters, all of which need to be matched by the team. + """ + and: [TeamCollectionFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Filters that needs to be matched by all teams. + """ + every: TeamFilter + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Comparator for the collection length. + """ + length: NumberComparator + """ + Compound filters, one of which need to be matched by the team. + """ + or: [TeamCollectionFilter!] + """ + Filters that the teams parent must satisfy. + """ + parent: NullableTeamFilter + """ + Filters that needs to be matched by some teams. + """ + some: TeamFilter + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +type TeamConnection { + edges: [TeamEdge!]! + nodes: [Team!]! + pageInfo: PageInfo! +} + +input TeamCreateInput { + """ + Period after which closed (completed, canceled, or duplicate) issues are automatically archived, in months. 0 means disabled. + """ + autoArchivePeriod: Float + """ + Period after which issues are automatically closed, in months. + """ + autoClosePeriod: Float + """ + The canceled workflow state which auto closed issues will be set to. + """ + autoCloseStateId: String + """ + The color of the team. + """ + color: String + """ + The cooldown time after each cycle in weeks. + """ + cycleCooldownTime: Int + """ + The duration of each cycle in weeks. + """ + cycleDuration: Int + """ + Auto assign completed issues to current active cycle setting. + """ + cycleIssueAutoAssignCompleted: Boolean + """ + Auto assign started issues to current active cycle setting. + """ + cycleIssueAutoAssignStarted: Boolean + """ + Only allow issues with cycles in Active Issues. + """ + cycleLockToActive: Boolean + """ + The day of the week that a new cycle starts. + """ + cycleStartDay: Float + """ + Whether the team uses cycles. + """ + cyclesEnabled: Boolean + """ + What to use as an default estimate for unestimated issues. + """ + defaultIssueEstimate: Float + """ + The identifier of the default project template of this team. + """ + defaultProjectTemplateId: String + """ + The identifier of the default template for members of this team. + """ + defaultTemplateForMembersId: String + """ + The identifier of the default template for non-members of this team. + """ + defaultTemplateForNonMembersId: String + """ + The description of the team. + """ + description: String + """ + Whether to group recent issue history entries. + """ + groupIssueHistory: Boolean + """ + The icon of the team. + """ + icon: String + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + Whether the team should inherit estimation settings from its parent. Only applies to sub-teams. + """ + inheritIssueEstimation: Boolean + """ + [Internal] Whether the team should inherit its product intelligence scope from its parent. Only applies to sub-teams. + """ + inheritProductIntelligenceScope: Boolean + """ + [Internal] Whether the team should inherit project statuses from its parent team, or from the workspace when it has no parent. + """ + inheritProjectStatuses: Boolean + """ + [Internal] Whether the team should inherit its Slack auto-create project channel setting from its parent. Only applies to sub-teams. + """ + inheritSlackAutoCreateProjectChannel: Boolean + """ + [Internal] Whether the team should inherit workflow statuses from its parent. + """ + inheritWorkflowStatuses: Boolean + """ + Whether initiatives are shown in the team's sidebar. + """ + initiativesEnabled: Boolean + """ + Whether to allow zeros in issues estimates. + """ + issueEstimationAllowZero: Boolean + """ + Whether to add additional points to the estimate scale. + """ + issueEstimationExtended: Boolean + """ + The issue estimation type to use. Must be one of "notUsed", "exponential", "fibonacci", "linear", "tShirt". + """ + issueEstimationType: String + """ + Whether issue sharing is enabled for this team. + """ + issueSharingEnabled: Boolean + """ + The key of the team. If not given, the key will be generated based on the name of the team. + """ + key: String + """ + The name of the team. + """ + name: String! + """ + The parent team ID. + """ + parentId: String + """ + Internal. Whether the team is private or not. + """ + private: Boolean + """ + [Internal] The scope of product intelligence suggestion data for the team. + """ + productIntelligenceScope: ProductIntelligenceScope + """ + Whether an issue needs to have a priority set before leaving triage. + """ + requirePriorityToLeaveTriage: Boolean + """ + Whether to move issues to bottom of the column when changing state. + """ + setIssueSortOrderOnStateChange: String + """ + [Internal] Whether to automatically create a Slack channel when a new project is created in this team. + """ + slackAutoCreateProjectChannel: Boolean + """ + The timezone of the team. + """ + timezone: String + """ + Whether triage mode is enabled for the team. + """ + triageEnabled: Boolean + """ + How many upcoming cycles to create. + """ + upcomingCycleCount: Float +} + +type TeamEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: Team! +} + +""" +Team filtering options. +""" +input TeamFilter { + """ + Filters that the team's ancestors must satisfy. + """ + ancestors: TeamCollectionFilter + """ + Compound filters, all of which need to be matched by the team. + """ + and: [TeamFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for the team description. + """ + description: NullableStringComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Filters that the team's issues must satisfy. + """ + issues: IssueCollectionFilter + """ + Comparator for the team key. + """ + key: StringComparator + """ + Filters that the team's members must satisfy. + """ + members: UserCollectionFilter + """ + Comparator for the team name. + """ + name: StringComparator + """ + Compound filters, one of which need to be matched by the team. + """ + or: [TeamFilter!] + """ + Filters that the team's owners must satisfy. + """ + owners: UserCollectionFilter + """ + Filters that the team's parent must satisfy. + """ + parent: NullableTeamFilter + """ + [DEPRECATED] Comparator for the team privacy. + """ + private: BooleanComparator + """ + Filters that the team's release pipelines must satisfy. + """ + releasePipelines: ReleasePipelineCollectionFilter + """ + [Internal] Filters that the private team forming this team's visibility boundary must satisfy. Only relevant for non-public teams. + """ + restrictedBy: NullableTeamFilter + """ + Comparator for the time at which the team was retired. + """ + retiredAt: NullableDateComparator + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator + """ + [Internal] Filters that the team's members must satisfy. Alias of `members` matching the filter shape produced by the app; prefer `members`. + """ + users: UserCollectionFilter + """ + Comparator for the team visibility. + """ + visibility: TeamVisibilityComparator +} + +""" +A join entity that defines a user's membership in a team. Each membership record links a user to a team and tracks whether the user is a team owner. Users can be members of multiple teams, and their memberships determine which teams' issues and resources they can access. +""" +type TeamMembership implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The unique identifier of the entity. + """ + id: ID! + """ + Whether the user is an owner of the team. Team owners have elevated permissions for managing team settings, members, and resources. + """ + owner: Boolean! + """ + The sort order of this team in the user's personal team list. Lower values appear first. + """ + sortOrder: Float! + """ + The team that the membership is associated with. + """ + team: Team! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The user that the membership is associated with. + """ + user: User! +} + +type TeamMembershipConnection { + edges: [TeamMembershipEdge!]! + nodes: [TeamMembership!]! + pageInfo: PageInfo! +} + +""" +Input for creating a new team membership. +""" +input TeamMembershipCreateInput { + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + Internal. Whether the user is the owner of the team. + """ + owner: Boolean + """ + The position of the item in the users list. + """ + sortOrder: Float + """ + The identifier of the team associated with the membership. + """ + teamId: String! + """ + The identifier of the user associated with the membership. + """ + userId: String! +} + +type TeamMembershipEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: TeamMembership! +} + +""" +Team membership operation response. +""" +type TeamMembershipPayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! + """ + The team membership that was created or updated. + """ + teamMembership: TeamMembership +} + +""" +Input for updating an existing team membership. +""" +input TeamMembershipUpdateInput { + """ + Internal. Whether the user is the owner of the team. + """ + owner: Boolean + """ + The position of the item in the users list. + """ + sortOrder: Float +} + +""" +A notification subscription scoped to a specific team. The subscriber receives notifications for events related to issues and activity in this team. +""" +type TeamNotificationSubscription implements Entity & Node & NotificationSubscription { + """ + Whether the subscription is active. When inactive, no notifications are generated from this subscription even though it still exists. + """ + active: Boolean! + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The type of contextual view (e.g., active issues, backlog) that further scopes a team notification subscription. Null if the subscription is not associated with a specific view type. + """ + contextViewType: ContextViewType + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The custom view that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + customView: CustomView + """ + The customer that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + customer: Customer + """ + The cycle that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + cycle: Cycle + """ + The unique identifier of the entity. + """ + id: ID! + """ + Whether initiative update notifications also include updates from sub-initiatives. Applies only when initiative updates are enabled and the workspace supports sub-initiatives. + """ + includeSubInitiativeUpdates: Boolean! + """ + The initiative that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + initiative: Initiative + """ + The issue label that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + label: IssueLabel + """ + The notification event types that this subscription will deliver to the subscriber. + """ + notificationSubscriptionTypes: [String!]! + """ + The project that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + project: Project + """ + The user who will receive notifications from this subscription. + """ + subscriber: User! + """ + The team subscribed to. + """ + team: Team! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The user that this notification subscription is scoped to, for user-specific view subscriptions. Null if the subscription targets a different entity type. + """ + user: User + """ + The type of user-specific view that further scopes a user notification subscription. Null if the subscription is not associated with a user view type. + """ + userContextViewType: UserContextViewType +} + +""" +Team origin for guidance rules. +""" +type TeamOriginWebhookPayload { + """ + The team that the guidance was defined in. + """ + team: TeamWithParentWebhookPayload! + """ + The type of origin, always 'Team'. + """ + type: String! +} + +""" +Team operation response. +""" +type TeamPayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! + """ + The team that was created or updated. + """ + team: Team +} + +""" +References a document or external link pinned to a team home for quick access. Pinning does not move the underlying resource; the same resource may be pinned on multiple teams. +""" +type TeamPinnedResource implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The user who created the pin. Null if the user was deleted. + """ + creator: User + """ + The pinned document, when the pin targets a document. + """ + document: Document + """ + The pinned external link, when the pin targets a link. + """ + entityExternalLink: EntityExternalLink + """ + The unique identifier of the entity. + """ + id: ID! + """ + The section this pin is grouped under on the team home. Null if the pin is not inside a section. + """ + section: TeamResourceSection + """ + Sort order of this pin among pins with the same team and section (including pins without a section). + """ + sortOrder: Float! + """ + The team home where this pin appears. + """ + team: Team! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The user who last updated the pin. Null if the user was deleted. + """ + updatedBy: User +} + +""" +A titled section on a team home that groups pinned resources (documents and external links). Sections are specific to the team home and do not change where resources live in their source team or project. +""" +type TeamResourceSection implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The user who created the section. Null if the creator was deleted. + """ + creator: User + """ + The unique identifier of the entity. + """ + id: ID! + """ + Sort order of this section among other sections on the same team home. + """ + sortOrder: Float! + """ + The team whose home page owns this section. + """ + team: Team! + """ + The section title shown on the team home. + """ + title: String! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The user who last updated the section. Null if the user was deleted. + """ + updatedBy: User +} + +""" +[Internal] How to handle sub-teams when retiring a parent team. +""" +enum TeamRetirementSubTeamHandling { + retire + unnest +} + +""" +All possible roles within a team in terms of access to team settings and operations. +""" +enum TeamRoleType { + member + owner +} + +input TeamSecuritySettingsInput { + """ + The minimum team role required to manage agent skills in the team. + """ + agentSkillsManagement: TeamRoleType + """ + The minimum team role required to manage loops in the team. + """ + automationManagement: TeamRoleType + """ + The minimum team role required to share issues with non-team-members. + """ + issueSharing: TeamRoleType + """ + The minimum team role required to manage labels in the team. + """ + labelManagement: TeamRoleType + """ + The minimum team role required to manage full workspace members (non-guests) in the team. + """ + memberManagement: TeamRoleType + """ + The minimum team role required to pin views to the team's pages and to change the views pinned there. + """ + pinnedViewManagement: TeamRoleType + """ + The minimum team role required to manage team settings. + """ + teamManagement: TeamRoleType + """ + The minimum team role required to manage templates in the team. + """ + templateManagement: TeamRoleType +} + +""" +Issue team sorting options. +""" +input TeamSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +input TeamUpdateInput { + """ + Whether to enable AI discussion summaries for issues. + """ + aiDiscussionSummariesEnabled: Boolean + """ + Whether to enable resolved thread AI summaries. + """ + aiThreadSummariesEnabled: Boolean + """ + Whether all members in the workspace can join the team. Only used for public teams. + """ + allMembersCanJoin: Boolean + """ + Period after which closed (completed, canceled, or duplicate) issues are automatically archived, in months. + """ + autoArchivePeriod: Float + """ + Whether to automatically close all sub-issues when a parent issue in this team is closed. + """ + autoCloseChildIssues: Boolean + """ + Whether to automatically close a parent issue in this team if all its sub-issues are closed. + """ + autoCloseParentIssues: Boolean + """ + Period after which issues are automatically closed, in months. + """ + autoClosePeriod: Float + """ + The canceled workflow state which auto closed issues will be set to. + """ + autoCloseStateId: String + """ + The color of the team. + """ + color: String + """ + The cooldown time after each cycle in weeks. + """ + cycleCooldownTime: Int + """ + The duration of each cycle in weeks. + """ + cycleDuration: Int + """ + The time at which to begin cycles. + """ + cycleEnabledStartDate: DateTime + """ + Auto assign completed issues to current active cycle setting. + """ + cycleIssueAutoAssignCompleted: Boolean + """ + Auto assign started issues to current active cycle setting. + """ + cycleIssueAutoAssignStarted: Boolean + """ + Only allow issues with cycles in Active Issues. + """ + cycleLockToActive: Boolean + """ + The day of the week that a new cycle starts. + """ + cycleStartDay: Float + """ + Whether the team uses cycles. + """ + cyclesEnabled: Boolean + """ + What to use as an default estimate for unestimated issues. + """ + defaultIssueEstimate: Float + """ + Default status for newly created issues. + """ + defaultIssueStateId: String + """ + The identifier of the default project template of this team. + """ + defaultProjectTemplateId: String + """ + The identifier of the default template for members of this team. + """ + defaultTemplateForMembersId: String + """ + The identifier of the default template for non-members of this team. + """ + defaultTemplateForNonMembersId: String + """ + The description of the team. + """ + description: String + """ + Whether to group recent issue history entries. + """ + groupIssueHistory: Boolean + """ + [Internal] How to handle sub-teams when retiring. Required if the team has active sub-teams. + """ + handleSubTeamsOnRetirement: TeamRetirementSubTeamHandling + """ + The icon of the team. + """ + icon: String + """ + Whether the team should inherit estimation settings from its parent. Only applies to sub-teams. + """ + inheritIssueEstimation: Boolean + """ + [Internal] Whether the team should inherit its product intelligence scope from its parent. Only applies to sub-teams. + """ + inheritProductIntelligenceScope: Boolean + """ + [Internal] Whether the team should inherit project statuses from its parent team, or from the workspace when it has no parent. + """ + inheritProjectStatuses: Boolean + """ + [Internal] Whether the team should inherit its Slack auto-create project channel setting from its parent. Only applies to sub-teams. + """ + inheritSlackAutoCreateProjectChannel: Boolean + """ + [Internal] Whether the team should inherit workflow statuses from its parent. + """ + inheritWorkflowStatuses: Boolean + """ + Whether initiatives are shown in the team's sidebar. + """ + initiativesEnabled: Boolean + """ + Whether to allow zeros in issues estimates. + """ + issueEstimationAllowZero: Boolean + """ + Whether to add additional points to the estimate scale. + """ + issueEstimationExtended: Boolean + """ + The issue estimation type to use. Must be one of "notUsed", "exponential", "fibonacci", "linear", "tShirt". + """ + issueEstimationType: String + """ + Whether issue sharing is enabled for this team. + """ + issueSharingEnabled: Boolean + """ + Whether new users should join this team by default. Mutation restricted to workspace admins or owners! + """ + joinByDefault: Boolean + """ + The key of the team. + """ + key: String + """ + The name of the team. + """ + name: String + """ + The parent team ID. + """ + parentId: String + """ + Whether the team is private or not. + """ + private: Boolean + """ + [Internal] The scope of product intelligence suggestion data for the team. + """ + productIntelligenceScope: ProductIntelligenceScope + """ + Whether an issue needs to have a priority set before leaving triage. + """ + requirePriorityToLeaveTriage: Boolean + """ + When the team was retired. + """ + retiredAt: DateTime + """ + The SCIM group name for the team. + """ + scimGroupName: String + """ + Whether the team is managed by SCIM integration. Mutation restricted to workspace admins or owners and only unsetting is allowed! + """ + scimManaged: Boolean + """ + The security settings for the team. + """ + securitySettings: TeamSecuritySettingsInput + """ + Whether to move issues to bottom of the column when changing state. + """ + setIssueSortOrderOnStateChange: String + """ + [Internal] Whether to automatically create a Slack channel when a new project is created in this team. + """ + slackAutoCreateProjectChannel: Boolean + """ + Whether to send new issue comment notifications to Slack. + """ + slackIssueComments: Boolean + """ + Whether to send issue status update notifications to Slack. + """ + slackIssueStatuses: Boolean + """ + Whether to send new issue notifications to Slack. + """ + slackNewIssue: Boolean + """ + The timezone of the team. + """ + timezone: String + """ + Whether triage mode is enabled for the team. + """ + triageEnabled: Boolean + """ + How many upcoming cycles to create. + """ + upcomingCycleCount: Float +} + +""" +The visibility of a team. A team can be public, private, or restricted within an enclosing private-team boundary. +""" +enum TeamVisibility { + private + public + restricted +} + +""" +Comparator for team visibility. +""" +input TeamVisibilityComparator { + """ + Equals constraint. + """ + eq: TeamVisibility + """ + In-array constraint. + """ + in: [TeamVisibility!] + """ + Not-equals constraint. + """ + neq: TeamVisibility + """ + Not-in-array constraint. + """ + nin: [TeamVisibility!] +} + +""" +Team properties including parent information for guidance rules. +""" +type TeamWithParentWebhookPayload { + """ + The team's display name including parent team names if applicable. + """ + displayName: String! + """ + The ID of the team. + """ + id: String! + """ + The key of the team. + """ + key: String! + """ + The name of the team. + """ + name: String! + """ + The parent team's unique identifier, if any. + """ + parentId: String +} + +""" +A reusable template for creating issues, projects, or documents. Templates store pre-filled field values and content as JSON data. They can be scoped to a specific team or shared across the entire workspace. Team-scoped templates may be inherited from parent teams. +""" +type Template implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The hex color of the template icon. Null if no custom color has been set. + """ + color: String + """ + The template's content in markdown format: the body it pre-fills on the entity it creates. Distinct from `description`, which says what the template is for. Form templates serialize their form fields as markdown placeholders instead. Null when the template has no content. + """ + content: String + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The user who created the template. Null if the creator's account has been deleted. + """ + creator: User + """ + A description of what the template is used for. + """ + description: String + """ + [Internal] Whether the template has form fields + """ + hasFormFields: Boolean! + """ + The icon of the template, either a decorative icon type or an emoji string. Null if no icon has been set. + """ + icon: String + """ + The unique identifier of the entity. + """ + id: ID! + """ + The parent team template this template was inherited from. Null for original (non-inherited) templates. + """ + inheritedFrom: Template + """ + The date when the template was last applied to create or update an entity. Null if the template has never been applied. + """ + lastAppliedAt: DateTime + """ + The user who last updated the template. Null if the user's account has been deleted. + """ + lastUpdatedBy: User + """ + The name of the template. + """ + name: String! + """ + The workspace that owns this template. + """ + organization: Organization! + """ + The release pipeline this template is bound to. Required when the template type is 'releaseNote' and forbidden otherwise. The pipeline owns at most one release note template, which defines the format AI follows when generating release notes. + """ + pipeline: ReleasePipeline + """ + The sort order of the template within the templates list. + """ + sortOrder: Float! + """ + The team that the template is associated with. If null, the template is global to the workspace. + """ + team: Team + """ + The template data as a JSON-encoded string containing the pre-filled attributes for the entity type (e.g., issue fields, project configuration, or document content). + """ + templateData: JSON! + """ + The entity type this template is for, such as 'issue', 'project', or 'document'. + """ + type: String! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +type TemplateConnection { + edges: [TemplateEdge!]! + nodes: [Template!]! + pageInfo: PageInfo! +} + +""" +Input for creating a new template. A name, type, and template data are required. If no team is specified, the template is shared across the workspace. +""" +input TemplateCreateInput { + """ + The color of the template icon. + """ + color: String + """ + The template description. + """ + description: String + """ + The icon of the template. + """ + icon: String + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + The template name. + """ + name: String! + """ + The identifier of the release pipeline this template is bound to. Required when the template type is 'releaseNote' and rejected otherwise. Each pipeline can have at most one release note template. + """ + pipelineId: String + """ + The sort position of the template in the templates list. + """ + sortOrder: Float + """ + The identifier or key of the team associated with the template. If not given, the template will be shared across all teams. + """ + teamId: String + """ + The template data as JSON-encoded attributes of the target entity type, such as pre-filled issue fields, project configuration, or document content. + """ + templateData: JSON! + """ + The template type, e.g. 'issue', 'project', or 'document'. + """ + type: String! +} + +type TemplateEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: Template! +} + +""" +Template filtering options. +""" +input TemplateFilter { + """ + Compound filters, all of which need to be matched by the template. + """ + and: [TemplateFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Comparator for the inherited template's ID. + """ + inheritedFromId: IDComparator + """ + Comparator for the template's name. + """ + name: StringComparator + """ + Compound filters, one of which need to be matched by the template. + """ + or: [TemplateFilter!] + """ + Filters that the template's team must satisfy. + """ + team: NullableTeamFilter + """ + Comparator for the template's type. + """ + type: StringComparator + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +The result of a template mutation. +""" +type TemplatePayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! + """ + The template that was created or updated. + """ + template: Template! +} + +""" +Input for updating an existing template. All fields are optional; only provided fields will be updated. +""" +input TemplateUpdateInput { + """ + The color of the template icon. + """ + color: String + """ + The template description. + """ + description: String + """ + The icon of the template. + """ + icon: String + """ + The template name. + """ + name: String + """ + The position of the template in the templates list. + """ + sortOrder: Float + """ + The identifier or key of the team associated with the template. If set to null, the template will be shared across all teams. + """ + teamId: String + """ + The template data as JSON-encoded attributes of the target entity type, such as pre-filled issue fields, project configuration, or document content. + """ + templateData: JSON +} + +""" +Customer tier sorting options. +""" +input TierSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +Issue time in status sorting options. +""" +input TimeInStatusSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +A time-based schedule defining on-call rotations or availability windows. Schedules contain a series of time entries, each specifying a user and their active period. They can be synced from external services (such as PagerDuty or Opsgenie) via integrations, or created manually. Schedules are used by triage responsibilities to determine who should be assigned or notified when issues enter triage. +""" +type TimeSchedule implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + [ALPHA] The schedule configuration. + """ + config: TimeScheduleConfig + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The schedule entries. + """ + entries: [TimeScheduleEntry!] + """ + The identifier of the external schedule. + """ + externalId: String + """ + The URL to the external schedule. + """ + externalUrl: String + """ + The unique identifier of the entity. + """ + id: ID! + """ + The identifier of the Linear integration populating the schedule. + """ + integration: Integration + """ + The name of the schedule. + """ + name: String! + """ + The workspace of the schedule. + """ + organization: Organization! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +""" +[ALPHA] The configuration of a time schedule. +""" +type TimeScheduleConfig { + """ + Record of the next on-call shift keyed by Linear user id, e.g. `{ "": { "startsAt": "X", "endsAt": "Y" } }`. + """ + nextShiftByUserId: JSONObject! +} + +input TimeScheduleConfigInput { + """ + Record of the next on-call shift keyed by Linear user id, e.g. `{ "": { "startsAt": "X", "endsAt": "Y" } }`. + """ + nextShiftByUserId: JSONObject! +} + +type TimeScheduleConnection { + edges: [TimeScheduleEdge!]! + nodes: [TimeSchedule!]! + pageInfo: PageInfo! +} + +""" +Input for creating a new time schedule. +""" +input TimeScheduleCreateInput { + """ + [ALPHA] The schedule configuration. + """ + config: TimeScheduleConfigInput + """ + The schedule entries. + """ + entries: [TimeScheduleEntryInput!]! + """ + The unique identifier of the external schedule. + """ + externalId: String + """ + The URL to the external schedule. + """ + externalUrl: String + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + The name of the schedule. + """ + name: String! +} + +type TimeScheduleEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: TimeSchedule! +} + +""" +A single entry in a time schedule, defining a time range and the user responsible during that period. +""" +type TimeScheduleEntry { + """ + The end time of the schedule entry in ISO 8601 date-time format. + """ + endsAt: DateTime! + """ + [ALPHA] The user this entry replaced, set when the entry is an override. + """ + overriddenUser: TimeScheduleUser + """ + The start time of the schedule entry in ISO 8601 date-time format. + """ + startsAt: DateTime! + """ + The external email, name or reference text for the user when the reference cannot be mapped to a Linear user id. + """ + userEmail: String + """ + The Linear user id of the referenced user. If the reference cannot be mapped to a Linear user then `userEmail` can be used instead. + """ + userId: String +} + +input TimeScheduleEntryInput { + """ + The end time of the schedule entry in ISO 8601 date-time format. + """ + endsAt: DateTime! + """ + [ALPHA] The user this entry replaced, set when the entry is an override. + """ + overriddenUser: TimeScheduleUserInput + """ + The start time of the schedule entry in ISO 8601 date-time format. + """ + startsAt: DateTime! + """ + The external email, name or reference text for the user when the reference cannot be mapped to a Linear user id. + """ + userEmail: String + """ + The Linear user id of the referenced user. If the reference cannot be mapped to a Linear user then `userEmail` can be used instead. + """ + userId: String +} + +""" +The result of a time schedule mutation. +""" +type TimeSchedulePayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! + """ + The time schedule that was created or updated. + """ + timeSchedule: TimeSchedule! +} + +""" +Input for updating an existing time schedule. +""" +input TimeScheduleUpdateInput { + """ + [ALPHA] The schedule configuration. Pass null to clear it. + """ + config: TimeScheduleConfigInput + """ + The schedule entries. + """ + entries: [TimeScheduleEntryInput!] + """ + The unique identifier of the external schedule. + """ + externalId: String + """ + The URL to the external schedule. + """ + externalUrl: String + """ + The name of the schedule. + """ + name: String +} + +""" +A reference to a user on a time schedule. +""" +type TimeScheduleUser { + """ + The external email, name or reference text for the user when the reference cannot be mapped to a Linear user id. + """ + userEmail: String + """ + The Linear user id of the referenced user. If the reference cannot be mapped to a Linear user then `userEmail` can be used instead. + """ + userId: String +} + +input TimeScheduleUserInput { + """ + The external email, name or reference text for the user when the reference cannot be mapped to a Linear user id. + """ + userEmail: String + """ + The Linear user id of the referenced user. If the reference cannot be mapped to a Linear user then `userEmail` can be used instead. + """ + userId: String +} + +""" +Represents a date in ISO 8601 format. Accepts shortcuts like `2021` to represent midnight Fri Jan 01 2021. Also accepts ISO 8601 durations strings which are added to the current date to create the represented date (e.g '-P2W1D' represents the date that was two weeks and 1 day ago) +""" +scalar TimelessDate + +""" +Represents a date in ISO 8601 format or a duration. Accepts shortcuts like `2021` to represent midnight Fri Jan 01 2021. Also accepts ISO 8601 durations strings (e.g '-P2W1D'), which are not converted to dates. +""" +scalar TimelessDateOrDuration + +""" +Issue title sorting options. +""" +input TitleSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +input TokenUserAccountAuthInput { + """ + Auth code for the client initiating the login sequence. + """ + clientAuthCode: String + """ + The email which to login via the magic login code. + """ + email: String! + """ + An optional invite link for a workspace. + """ + inviteLink: String + """ + The timezone of the user's browser. + """ + timezone: String! + """ + The magic login code. + """ + token: String! +} + +""" +A team's triage responsibility configuration that defines how issues entering triage are handled. Each team can have one triage responsibility, which specifies the action to take (notify or assign) and the responsible users, determined either by a manual selection of specific users or by an on-call time schedule. +""" +type TriageResponsibility implements Node { + """ + The action to take when an issue is added to triage. + """ + action: TriageResponsibilityAction! + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The user currently responsible for triage. + """ + currentUser: User + """ + The unique identifier of the entity. + """ + id: ID! + """ + Set of users used for triage responsibility. + """ + manualSelection: TriageResponsibilityManualSelection + """ + The team to which the triage responsibility belongs to. + """ + team: Team! + """ + The time schedule used for scheduling. + """ + timeSchedule: TimeSchedule + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +""" +Which action should be taken after an issue is added to triage. +""" +enum TriageResponsibilityAction { + assign + notify +} + +type TriageResponsibilityConnection { + edges: [TriageResponsibilityEdge!]! + nodes: [TriageResponsibility!]! + pageInfo: PageInfo! +} + +""" +Input for creating a new triage responsibility. +""" +input TriageResponsibilityCreateInput { + """ + The action to take when an issue is added to triage. + """ + action: String! + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + The manual selection of users responsible for triage. + """ + manualSelection: TriageResponsibilityManualSelectionInput + """ + The identifier of the team associated with the triage responsibility. + """ + teamId: String! + """ + The identifier of the time schedule used for scheduling triage responsibility + """ + timeScheduleId: String +} + +type TriageResponsibilityEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: TriageResponsibility! +} + +""" +Manual triage responsibility configuration specifying a set of users to assign triaged issues to, with optional round-robin rotation. +""" +type TriageResponsibilityManualSelection { + """ + [Internal] The index of the current userId used for the assign action when having more than one user. + """ + assignmentIndex: Int + """ + The set of users responsible for triage. + """ + userIds: [String!]! +} + +""" +Manual triage responsibility using a set of users. +""" +input TriageResponsibilityManualSelectionInput { + """ + [Internal] The index of the current userId used for the assign action when having more than one user. + """ + assignmentIndex: Int + """ + The set of users responsible for triage. + """ + userIds: [String!]! +} + +""" +The result of a triage responsibility mutation. +""" +type TriageResponsibilityPayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! + """ + The triage responsibility that was created or updated. + """ + triageResponsibility: TriageResponsibility! +} + +""" +Input for updating an existing triage responsibility. +""" +input TriageResponsibilityUpdateInput { + """ + The action to take when an issue is added to triage. + """ + action: String + """ + The manual selection of users responsible for triage. + """ + manualSelection: TriageResponsibilityManualSelectionInput + """ + The identifier of the time schedule used for scheduling triage responsibility. + """ + timeScheduleId: String +} + +""" +The type of error that occurred during triage rule execution. +""" +enum TriageRuleErrorType { + codingAgentQuotaExceeded + cycle + default + labelGroupConflict +} + +""" +A universally unique identifier as specified by RFC 4122. +""" +scalar UUID + +""" +Issue update date sorting options. +""" +input UpdatedAtSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +Represents a file upload destination with a pre-signed upload URL, asset URL, and required request headers for uploading to cloud storage. +""" +type UploadFile { + """ + The permanent asset URL where the file will be accessible after upload. + """ + assetUrl: String! + """ + The content type. + """ + contentType: String! + """ + The filename. + """ + filename: String! + """ + HTTP headers that must be included in the PUT request to the upload URL. + """ + headers: [UploadFileHeader!]! + """ + Optional metadata associated with the upload, such as the related issue or comment ID. + """ + metaData: JSONObject + """ + The size of the uploaded file. + """ + size: Int! + """ + The pre-signed URL to which the file should be uploaded via a PUT request. + """ + uploadUrl: String! +} + +type UploadFileHeader { + """ + Upload file header key. + """ + key: String! + """ + Upload file header value. + """ + value: String! +} + +type UploadPayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! + """ + The upload file details including signed URL, asset URL, and required headers. Null if the upload could not be prepared. + """ + uploadFile: UploadFile +} + +""" +A usage alert triggered when a workspace crosses a billing or consumption threshold. +""" +type UsageAlert implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The unique identifier of the entity. + """ + id: ID! + """ + Type-specific snapshot captured when the alert was triggered, keyed by the alert type โ€” for example the credit balance and threshold for a lowBalance alert. A resolution entry is added once new usage credits have landed and cleared the alert's condition. + """ + metadata: JSONObject! + """ + The time when the usage alert was resolved or archived. Null if the alert is still active. + """ + resolvedAt: DateTime + """ + The kind of usage alert that was triggered. + """ + type: String! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +type UsageAlertConnection { + edges: [UsageAlertEdge!]! + nodes: [UsageAlert!]! + pageInfo: PageInfo! +} + +type UsageAlertEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: UsageAlert! +} + +""" +Usage alert filtering options. +""" +input UsageAlertFilter { + """ + Compound filters, all of which need to be matched by the alert. + """ + and: [UsageAlertFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Compound filters, one of which need to be matched by the alert. + """ + or: [UsageAlertFilter!] + """ + Comparator for the condition the alert was triggered by. + """ + type: UsageAlertTypeComparator + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +A notification related to a usage alert, sent to workspace billing admins. +""" +type UsageAlertNotification implements Entity & Node & Notification { + """ + The user that caused the notification. Null if the notification was triggered by a non-user actor such as an integration, external user, or system event. + """ + actor: User + """ + [Internal] Notification actor initials if avatar is not available. + """ + actorAvatarColor: String! + """ + [Internal] Notification avatar URL. + """ + actorAvatarUrl: String + """ + [Internal] Whether the notification's user actor is deactivated in the workspace. + """ + actorInactive: Boolean! + """ + [Internal] Notification actor initials if avatar is not available. + """ + actorInitials: String + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The bot that caused the notification. + """ + botActor: ActorBot + """ + The category of the notification. + """ + category: NotificationCategory! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The time at which an email reminder for this notification was sent to the user. Null if no email reminder has been sent. + """ + emailedAt: DateTime + """ + The external user that caused the notification. Populated when the notification was triggered by an external user (e.g., a commenter from a connected integration like Slack or GitHub) rather than a Linear workspace member. + """ + externalUserActor: ExternalUser + """ + [Internal] Notifications with the same grouping key will be grouped together in the UI. + """ + groupingKey: String! + """ + [Internal] Priority of the notification with the same grouping key. Higher number means higher priority. If priority is the same, notifications should be sorted by `createdAt`. + """ + groupingPriority: Float! + """ + The unique identifier of the entity. + """ + id: ID! + """ + [Internal] Inbox URL for the notification. + """ + inboxUrl: String! + """ + [Internal] Initiative update health for new updates. + """ + initiativeUpdateHealth: String + """ + [Internal] If notification actor was Linear. + """ + isLinearActor: Boolean! + """ + [Internal] Issue's status type for issue notifications. + """ + issueStatusType: String + """ + [Internal] Project update health for new updates. + """ + projectUpdateHealth: String + """ + The time at which the user marked the notification as read. Null if the notification is unread. + """ + readAt: DateTime + """ + The time until which a notification is snoozed. After this time, the notification reappears in the user's inbox. Null if the notification is not currently snoozed. + """ + snoozedUntilAt: DateTime + """ + [Internal] Notification subtitle. + """ + subtitle: String! + """ + [Internal] Notification title. + """ + title: String! + """ + Notification type. Determines the kind of event that triggered this notification and which associated entity fields will be populated. + """ + type: String! + """ + The time at which a notification was unsnoozed. Null if the notification has not been unsnoozed. + """ + unsnoozedAt: DateTime + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + [Internal] URL to the target of the notification. + """ + url: String! + """ + The usage alert related to the notification. + """ + usageAlert: UsageAlert! + """ + Related usage alert. + """ + usageAlertId: String! + """ + The recipient user of this notification. + """ + user: User! +} + +""" +The condition a usage alert was triggered by. +""" +enum UsageAlertType { + """ + Usage credits ran out. + """ + exhausted + """ + A promotional usage credit grant is nearing its expiration. + """ + expiringPromoCredit + """ + Prepaid usage credits crossed below the low-balance threshold. + """ + lowBalance +} + +""" +Comparator for the condition a usage alert was triggered by. +""" +input UsageAlertTypeComparator { + """ + Equals constraint. + """ + eq: UsageAlertType + """ + In-array constraint. + """ + in: [UsageAlertType!] + """ + Not-equals constraint. + """ + neq: UsageAlertType + """ + Not-in-array constraint. + """ + nin: [UsageAlertType!] +} + +""" +A user that belongs to a workspace. Users can have different roles (admin, member, guest, or app) that determine their level of access. Users can be members of multiple teams, and can be active or deactivated. Guest users have limited access scoped to specific teams they are invited to. +""" +type User implements Node { + """ + Whether the user account is active or disabled (suspended). + """ + active: Boolean! + """ + Whether the user is a workspace administrator. On Free plans, all members are treated as admins. + """ + admin: Boolean! + """ + Whether the user is an app. + """ + app: Boolean! + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + Issues assigned to the user. + """ + assignedIssues( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned issues. + """ + filter: IssueFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): IssueConnection! + """ + The background color of the avatar for users without set avatar. + """ + avatarBackgroundColor: String! + """ + An URL to the user's avatar image. + """ + avatarUrl: String + """ + [DEPRECATED] Hash for the user to be used in calendar URLs. + """ + calendarHash: String + """ + Whether this user can access any public team in the workspace. True for non-guest members and app users with public team access. + """ + canAccessAnyPublicTeam: Boolean! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + Number of issues created. + """ + createdIssueCount: Int! + """ + Issues created by the user. + """ + createdIssues( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned issues. + """ + filter: IssueFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): IssueConnection! + """ + Issues delegated to this user. + """ + delegatedIssues( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned issues. + """ + filter: IssueFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): IssueConnection! + """ + A short description of the user, such as their title or a brief bio. + """ + description: String + """ + The reason why the user account is disabled. Null if the user is active. Possible values include admin suspension, downgrade, voluntary departure, or pending invite. + """ + disableReason: String + """ + The user's display (nick) name. Must be unique within the workspace. + """ + displayName: String! + """ + The user's saved drafts. + """ + drafts( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): DraftConnection! + """ + The user's email address. + """ + email: String! + """ + [INTERNAL] The user's pinned feeds. + """ + feedFacets( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): FacetConnection! + """ + The user's GitHub user ID. + """ + gitHubUserId: String + """ + Whether the user is a guest in the workspace and limited to accessing a subset of teams. + """ + guest: Boolean! + """ + [Internal] Whether this user can access GitHub source code through Linear. True when the workspace has connected GitHub code-access repositories and the user has an active personal GitHub code-access token for the same GitHub host. Always false when queried for a user other than the authenticated viewer. + """ + hasGitHubCodeAccess: Boolean! + """ + The unique identifier of the entity. + """ + id: ID! + """ + [INTERNAL] Identity provider the user is managed by. + """ + identityProvider: IdentityProvider + """ + The initials of the user. + """ + initials: String! + """ + [DEPRECATED] Unique hash for the user to be used in invite URLs. + """ + inviteHash: String! + @deprecated(reason: "This hash is not in use anymore, this value will always be empty.") + """ + Whether the user can be assigned to issues. Active app users require the assignments capability. The Linear agent also requires coding sessions to be enabled. + """ + isAssignable: Boolean! + """ + Whether the user is the currently authenticated user. + """ + isMe: Boolean! + """ + Whether the user can be mentioned. Active app users require the mentions capability. + """ + isMentionable: Boolean! + """ + Issue drafts that the user has created but not yet submitted. + """ + issueDrafts( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): IssueDraftConnection! + """ + The last time the user was seen online. Updated based on user activity. Null if the user has never been seen. + """ + lastSeen: DateTime + """ + The user's full name. + """ + name: String! + """ + The workspace that the user belongs to. + """ + organization: Organization! + """ + Whether the user is a workspace owner, which is the highest permission level. + """ + owner: Boolean! + """ + The emoji representing the user's current status. Null if no status is set. + """ + statusEmoji: String + """ + The text label of the user's current status. Null if no status is set. + """ + statusLabel: String + """ + The date and time at which the user's current status should be automatically cleared. Null if the status has no expiration. + """ + statusUntilAt: DateTime + """ + Whether this agent user supports agent sessions. + """ + supportsAgentSessions( + """ + Whether to require an active webhook for sessions started by the current user. + """ + forCurrentUser: Boolean! = false + ): Boolean! + """ + Memberships associated with the user. For easier access of the same data, use `teams` query. + """ + teamMemberships( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): TeamMembershipConnection! + """ + Teams the user is a member of. Supports filtering by team properties. + """ + teams( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned teams. + """ + filter: TeamFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): TeamConnection! + """ + The local timezone of the user. + """ + timezone: String + """ + The user's job title. + """ + title: String + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + User's profile URL. + """ + url: String! +} + +""" +User actor payload for webhooks. +""" +type UserActorWebhookPayload { + """ + The avatar URL of the user. + """ + avatarUrl: String + """ + The email of the user. + """ + email: String! + """ + The ID of the user. + """ + id: String! + """ + The name of the user. + """ + name: String! + """ + The type of actor. + """ + type: String! + """ + The URL of the user. + """ + url: String! +} + +""" +User admin operation response. +""" +type UserAdminPayload { + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Certain properties of a user. +""" +type UserChildWebhookPayload { + """ + The avatar URL of the user. + """ + avatarUrl: String + """ + The email of the user. + """ + email: String! + """ + The ID of the user. + """ + id: String! + """ + The name of the user. + """ + name: String! + """ + The URL of the user. + """ + url: String! +} + +""" +User filtering options. +""" +input UserCollectionFilter { + """ + Comparator for the user's activity status. + """ + active: BooleanComparator + """ + Comparator for the user's admin status. + """ + admin: BooleanComparator + """ + Compound filters, all of which need to be matched by the user. + """ + and: [UserCollectionFilter!] + """ + Comparator for the user's app status. + """ + app: BooleanComparator + """ + Filters that the users assigned issues must satisfy. + """ + assignedIssues: IssueCollectionFilter + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for the user's display name. + """ + displayName: StringComparator + """ + Comparator for the user's email. + """ + email: StringComparator + """ + Filters that needs to be matched by all users. + """ + every: UserFilter + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Comparator for the user's invited status. + """ + invited: BooleanComparator + """ + Comparator for the user's invited status. + """ + isInvited: BooleanComparator + """ + Filter based on the currently authenticated user. Set to true to filter for the authenticated user, false for any other user. + """ + isMe: BooleanComparator + """ + Comparator for the collection length. + """ + length: NumberComparator + """ + Comparator for the user's name. + """ + name: StringComparator + """ + Compound filters, one of which need to be matched by the user. + """ + or: [UserCollectionFilter!] + """ + Comparator for the user's owner status. + """ + owner: BooleanComparator + """ + Filters that needs to be matched by some users. + """ + some: UserFilter + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +type UserConnection { + edges: [UserEdge!]! + nodes: [User!]! + pageInfo: PageInfo! +} + +enum UserContextViewType { + assigned +} + +""" +User display name sorting options. +""" +input UserDisplayNameSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +type UserEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: User! +} + +""" +User filtering options. +""" +input UserFilter { + """ + Comparator for the user's activity status. + """ + active: BooleanComparator + """ + Comparator for the user's admin status. + """ + admin: BooleanComparator + """ + Compound filters, all of which need to be matched by the user. + """ + and: [UserFilter!] + """ + Comparator for the user's app status. + """ + app: BooleanComparator + """ + Filters that the users assigned issues must satisfy. + """ + assignedIssues: IssueCollectionFilter + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for the user's display name. + """ + displayName: StringComparator + """ + Comparator for the user's email. + """ + email: StringComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Comparator for the user's invited status. + """ + invited: BooleanComparator + """ + Comparator for the user's invited status. + """ + isInvited: BooleanComparator + """ + Filter based on the currently authenticated user. Set to true to filter for the authenticated user, false for any other user. + """ + isMe: BooleanComparator + """ + Comparator for the user's name. + """ + name: StringComparator + """ + Compound filters, one of which need to be matched by the user. + """ + or: [UserFilter!] + """ + Comparator for the user's owner status. + """ + owner: BooleanComparator + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +The types of flags that the user can have. +""" +enum UserFlagType { + agentExamplesDismissed + agentHomeHeadlineSeen + agentHomePageNotice + agentLoopsPromoShown + agentSharedSkillsPromoDismissed + agentSharedSkillsSplashAnimationSeen + all + analyticsWelcomeDismissed + canPlaySnake + canPlayTetris + commandMenuClearShortcutTip + completedOnboarding + cycleWelcomeDismissed + desktopDownloadToastDismissed + desktopInstalled + desktopTabsOnboardingDismissed + dueDateShortcutMigration + editorSlashCommandUsed + emptyActiveIssuesDismissed + emptyBacklogDismissed + emptyCustomViewsDismissed + emptyMyIssuesDismissed + emptyParagraphSlashCommandTip + figmaPluginBannerDismissed + figmaPromptDismissed + helpIslandFeatureInsightsDismissed + importBannerDismissed + initiativesBannerDismissed + insightsHelpDismissed + insightsWelcomeDismissed + issueLabelSuggestionUsed + issueMovePromptCompleted + joinTeamIntroductionDismissed + listSelectionTip + loopEditRestrictionSpeedbumpShown + migrateThemePreference + milestoneOnboardingIsSeenAndDismissed + projectBacklogWelcomeDismissed + projectBoardOnboardingIsSeenAndDismissed + projectUpdatesWelcomeDismissed + projectWelcomeDismissed + pulseWelcomeDismissed + reviewsPromptToConnectGithubDismissed + rewindBannerDismissed + slackAgentPromoFromCreateNewIssueShown + slackAiFeedbackAcknowledgementShown + slackBotWelcomeMessageShown + slackCommentReactionTipShown + slackProjectChannelsPromoDismissed + slackProjectChannelsPromoShown + teamsBotWelcomeMessageShown + teamsPageIntroductionDismissed + threadedCommentsNudgeIsSeen + triageWelcomeDismissed + tryCodexDismissed + tryCursorDismissed + tryCyclesDismissed + tryGithubDismissed + tryInvitePeopleDismissed + tryRoadmapsDismissed + tryTriageDismissed + updatedSlackThreadSyncIntegration +} + +""" +Operations that can be applied to UserFlagType. +""" +enum UserFlagUpdateOperation { + clear + decr + incr + lock +} + +""" +User name sorting options. +""" +input UserNameSort { + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder +} + +""" +A notification subscription scoped to a specific user view. The subscriber receives notifications for events in the context of a particular user's activity view. +""" +type UserNotificationSubscription implements Entity & Node & NotificationSubscription { + """ + Whether the subscription is active. When inactive, no notifications are generated from this subscription even though it still exists. + """ + active: Boolean! + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The type of contextual view (e.g., active issues, backlog) that further scopes a team notification subscription. Null if the subscription is not associated with a specific view type. + """ + contextViewType: ContextViewType + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The custom view that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + customView: CustomView + """ + The customer that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + customer: Customer + """ + The cycle that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + cycle: Cycle + """ + The unique identifier of the entity. + """ + id: ID! + """ + Whether initiative update notifications also include updates from sub-initiatives. Applies only when initiative updates are enabled and the workspace supports sub-initiatives. + """ + includeSubInitiativeUpdates: Boolean! + """ + The initiative that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + initiative: Initiative + """ + The issue label that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + label: IssueLabel + """ + The notification event types that this subscription will deliver to the subscriber. + """ + notificationSubscriptionTypes: [String!]! + """ + The project that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + project: Project + """ + The user who will receive notifications from this subscription. + """ + subscriber: User! + """ + The team that this notification subscription is scoped to. Null if the subscription targets a different entity type. + """ + team: Team + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The user subscribed to. + """ + user: User! + """ + The type of user-specific view that further scopes a user notification subscription. Null if the subscription is not associated with a user view type. + """ + userContextViewType: UserContextViewType +} + +""" +User operation response. +""" +type UserPayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! + """ + The user that was created or updated. + """ + user: User +} + +""" +The different permission roles available to users in a workspace. +""" +enum UserRoleType { + admin + app + guest + owner + user +} + +""" +Per-user settings and preferences for a workspace member. Includes notification delivery preferences, email subscription settings, notification category and channel preferences, theme configuration, and various UI preferences. Each user has exactly one UserSettings record per workspace. +""" +type UserSettings implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + Whether to auto-assign newly created issues to the current user by default. + """ + autoAssignToSelf: Boolean! + """ + A unique hash for the user, used to construct secure calendar subscription URLs. + """ + calendarHash: String + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The user's last seen time for the pulse feed. + """ + feedLastSeenTime: DateTime + """ + The user's preferred schedule for receiving feed summary digests. Null if the user has not set a preference and will use the workspace default. + """ + feedSummarySchedule: FeedSummarySchedule + """ + The unique identifier of the entity. + """ + id: ID! + """ + The user's notification category preferences, indicating which notification categories are enabled or disabled per notification channel. + """ + notificationCategoryPreferences: NotificationCategoryPreferences! + """ + The user's notification channel preferences, indicating which notification delivery channels (email, in-app, mobile push, Slack) are enabled. + """ + notificationChannelPreferences: NotificationChannelPreferences! + """ + The notification delivery preferences for the user. Note: notificationDisabled field is deprecated in favor of notificationChannelPreferences. + """ + notificationDeliveryPreferences: NotificationDeliveryPreferences! + """ + [Internal] The user's preferred merge method for pull requests. Null if the user chooses a method for each pull request. + """ + pullRequestMergeStrategyPreference: PullRequestMergeMethod + """ + Whether to show line numbers in code blocks. + """ + showCodeBlockLineNumbers: Boolean! + """ + Whether to show full user names instead of display names. + """ + showFullUserNames: Boolean! + """ + Whether this user is subscribed to receive changelog emails about Linear product updates. + """ + subscribedToChangelog: Boolean! + """ + Whether this user is subscribed to receive Data Processing Agreement (DPA) related emails. + """ + subscribedToDPA: Boolean! + """ + Whether this user is subscribed to receive email notifications when their workspace invitations are accepted. + """ + subscribedToInviteAccepted: Boolean! + """ + Whether this user is subscribed to receive emails about privacy policy and legal updates. + """ + subscribedToPrivacyLegalUpdates: Boolean! + """ + The user's theme configuration for the specified color mode (light/dark) and device type (desktop/mobile). Returns null if no valid theme preset is configured. + """ + theme( + """ + The device type. + """ + deviceType: UserSettingsThemeDeviceType = desktop + """ + The theme color mode. + """ + mode: UserSettingsThemeMode = light + ): UserSettingsTheme + """ + The email types the user has unsubscribed from. + """ + unsubscribedFrom: [String!]! + @deprecated( + reason: "Use individual subscription fields instead. This field's value is now outdated." + ) + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The user that these settings belong to. + """ + user: User! +} + +""" +Custom sidebar theme definition with accent, base colors and contrast. +""" +type UserSettingsCustomSidebarTheme { + """ + The accent color in LCH format. + """ + accent: [Float!]! + """ + The base color in LCH format. + """ + base: [Float!]! + """ + The contrast value. + """ + contrast: Int! +} + +""" +Custom theme definition with accent, base colors, contrast, and optional sidebar theme. +""" +type UserSettingsCustomTheme { + """ + The accent color in LCH format. + """ + accent: [Float!]! + """ + The base color in LCH format. + """ + base: [Float!]! + """ + The contrast value. + """ + contrast: Int! + """ + Optional sidebar theme colors. + """ + sidebar: UserSettingsCustomSidebarTheme +} + +""" +User settings flag update response. +""" +type UserSettingsFlagPayload { + """ + The flag key which was updated. + """ + flag: String + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! + """ + The flag value after update. + """ + value: Int +} + +""" +User settings flags reset response. +""" +type UserSettingsFlagsResetPayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +User settings operation response. +""" +type UserSettingsPayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! + """ + The user's settings. + """ + userSettings: UserSettings! +} + +""" +The user's resolved theme configuration for a specific color mode and device type. +""" +type UserSettingsTheme { + """ + The custom theme definition, only present when preset is 'custom'. + """ + custom: UserSettingsCustomTheme + """ + The theme preset. + """ + preset: UserSettingsThemePreset! +} + +""" +Device type for theme +""" +enum UserSettingsThemeDeviceType { + desktop + mobileWeb +} + +""" +Theme color mode +""" +enum UserSettingsThemeMode { + dark + light +} + +""" +Theme preset options +""" +enum UserSettingsThemePreset { + classicDark + custom + dark + light + magicBlue + pureLight + system +} + +input UserSettingsUpdateInput { + """ + [Internal] The user's last seen time for the pulse feed. + """ + feedLastSeenTime: DateTime + """ + [Internal] How often to generate a feed summary. + """ + feedSummarySchedule: FeedSummarySchedule + """ + [Internal] Which Inbox notifications contribute to Inbox badges. 'all' includes all unread notifications; 'priority' includes only Priority Inbox notifications; 'none' hides the count. + """ + inboxBadgeScope: InboxBadgeScope + """ + The user's notification category preferences. + """ + notificationCategoryPreferences: NotificationCategoryPreferencesInput + """ + The user's notification channel preferences. + """ + notificationChannelPreferences: PartialNotificationChannelPreferencesInput + """ + The user's notification delivery preferences. + """ + notificationDeliveryPreferences: NotificationDeliveryPreferencesInput + """ + [Internal] Whether the Priority Inbox is enabled for the user. + """ + priorityInboxEnabled: Boolean + """ + The user's settings. Merged key by key into the existing settings: keys missing from the object are left unchanged, and a key set to null is removed. + """ + settings: JSONObject + """ + Whether this user is subscribed to changelog email or not. + """ + subscribedToChangelog: Boolean + """ + Whether this user is subscribed to DPA emails or not. + """ + subscribedToDPA: Boolean + """ + Whether this user is subscribed to general marketing communications or not. + """ + subscribedToGeneralMarketingCommunications: Boolean + """ + Whether this user is subscribed to invite accepted emails or not. + """ + subscribedToInviteAccepted: Boolean + """ + Whether this user is subscribed to privacy and legal update emails or not. + """ + subscribedToPrivacyLegalUpdates: Boolean + """ + [Internal] The user's usage warning history. + """ + usageWarningHistory: JSONObject +} + +""" +User sorting options. +""" +input UserSortInput { + """ + Sort by user display name + """ + displayName: UserDisplayNameSort + """ + Sort by user name + """ + name: UserNameSort +} + +""" +Input for updating the authenticated user. +""" +input UserUpdateInput { + """ + The avatar image URL of the user. + """ + avatarUrl: String + """ + The user description or a short bio. + """ + description: String + """ + The display name of the user. + """ + displayName: String + """ + The name of the user. + """ + name: String + """ + The emoji part of the user status. + """ + statusEmoji: String + """ + The label part of the user status. + """ + statusLabel: String + """ + When the user status should be cleared. + """ + statusUntilAt: DateTime + """ + The local timezone of the user. + """ + timezone: String + """ + The user's job title. + """ + title: String +} + +""" +Payload for a user webhook. +""" +type UserWebhookPayload { + """ + Whether the user is active. + """ + active: Boolean! + """ + Whether the user is an admin. + """ + admin: Boolean! + """ + Whether the user is an app. + """ + app: Boolean! + """ + The time at which the entity was archived. + """ + archivedAt: String + """ + The avatar URL of the user. + """ + avatarUrl: String + """ + The time at which the entity was created. + """ + createdAt: String! + """ + The description of the user. + """ + description: String + """ + The reason the user is disabled. + """ + disableReason: String + """ + The display name of the user. + """ + displayName: String! + """ + The email of the user. + """ + email: String! + """ + Whether the user is a guest. + """ + guest: Boolean! + """ + The ID of the entity. + """ + id: String! + """ + The name of the user. + """ + name: String! + """ + Whether the user is an owner. + """ + owner: Boolean + """ + The local timezone of the user. + """ + timezone: String + """ + The time at which the entity was updated. + """ + updatedAt: String! + """ + The URL of the user. + """ + url: String! +} + +""" +The display preferences for a view, controlling layout mode (list, board, spreadsheet), grouping, sorting, column visibility, and other visual settings. View preferences exist at two levels: organization-wide defaults and per-user overrides. The effective preferences are computed by merging both layers, with user preferences taking priority. +""" +type ViewPreferences implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The unique identifier of the entity. + """ + id: ID! + """ + The view preferences values, containing layout, grouping, sorting, and field visibility settings. + """ + preferences: ViewPreferencesValues! + """ + The type of view preferences: "organization" for workspace-wide defaults or "user" for personal overrides. + """ + type: String! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The type of view these preferences apply to, such as board, cycle, project, customView, myIssues, etc. + """ + viewType: String! +} + +""" +Input for creating view preferences. +""" +input ViewPreferencesCreateInput { + """ + The custom view these view preferences are associated with. + """ + customViewId: String + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + [Internal] The initiative these view preferences are associated with. + """ + initiativeId: String + """ + The initiative label these view preferences are associated with. + """ + initiativeLabelId: String + """ + The default parameters for the insight on that view. + """ + insights: JSONObject + """ + The label these view preferences are associated with. + """ + labelId: String + """ + View preferences object. + """ + preferences: JSONObject! + """ + The project these view preferences are associated with. + """ + projectId: String + """ + The project label these view preferences are associated with. + """ + projectLabelId: String + """ + The release pipeline these view preferences are associated with. + """ + releasePipelineId: String + """ + The team these view preferences are associated with. + """ + teamId: String + """ + The type of view preferences (either user or workspace level preferences). + """ + type: ViewPreferencesType! + """ + The user profile these view preferences are associated with. + """ + userId: String + """ + The view type of the view preferences are associated with. + """ + viewType: ViewType! +} + +""" +A label group column configuration for the initiative list view. +""" +type ViewPreferencesInitiativeLabelGroupColumn { + """ + Whether the label group column is active. + """ + active: Boolean! + """ + The identifier of the label group. + """ + id: String! +} + +""" +The result of a view preferences mutation. +""" +type ViewPreferencesPayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! + """ + The view preferences entity being mutated. + """ + viewPreferences: ViewPreferences! +} + +""" +A label group column configuration for the project list view. +""" +type ViewPreferencesProjectLabelGroupColumn { + """ + Whether the label group column is active. + """ + active: Boolean! + """ + The identifier of the label group. + """ + id: String! +} + +""" +The type of view preferences (either user or workspace level preferences). +""" +enum ViewPreferencesType { + organization + user +} + +""" +Input for updating view preferences. +""" +input ViewPreferencesUpdateInput { + """ + The default parameters for the insight on that view. + """ + insights: JSONObject + """ + View preferences. + """ + preferences: JSONObject +} + +""" +The computed view preferences values for a view, containing all display settings such as layout mode, grouping, sorting, field visibility, and other visual configuration. These values represent the merged result of organization defaults and user overrides. +""" +type ViewPreferencesValues { + """ + Whether to show the loop last executed field. + """ + automationFieldLastExecuted: Boolean + """ + Whether to show the loop status field. + """ + automationFieldStats: Boolean + """ + Whether to show the loop team field. + """ + automationFieldTeam: Boolean + """ + Whether to show the loop trigger field. + """ + automationFieldTrigger: Boolean + """ + The loop grouping. + """ + automationGrouping: String + """ + The loop ordering. + """ + automationOrdering: String + """ + Whether to show the run duration in Loop run history. + """ + automationRunHistoryShowDuration: Boolean + """ + Whether to show the initiative identifier in Loop run history. + """ + automationRunHistoryShowInitiativeIdentifier: Boolean + """ + Whether to show the issue identifier in Loop run history. + """ + automationRunHistoryShowIssueIdentifier: Boolean + """ + Whether to show the project identifier in Loop run history. + """ + automationRunHistoryShowProjectIdentifier: Boolean + """ + Whether to show sub-team loops. + """ + automationShowDescendants: Boolean + """ + Whether to show disabled loops. + """ + automationShowDisabled: Boolean + """ + Whether to show templates above the workspace loops list. + """ + automationShowTemplates: Boolean + """ + The loop stats period. + """ + automationStatsPeriod: String + """ + Whether issues in closed columns should be ordered by recency. + """ + closedIssuesOrderedByRecency: Boolean + """ + Custom ordering of groups on the board layout. + """ + columnOrderBoard: [String!] + """ + Custom ordering of groups on the list layout. + """ + columnOrderList: [String!] + """ + Whether to show the release date field for continuous pipeline releases. + """ + continuousPipelineReleaseFieldReleaseDate: Boolean + """ + Whether to show the release-note field for continuous pipeline releases. + """ + continuousPipelineReleaseFieldReleaseNote: Boolean + """ + Whether to show the version field for continuous pipeline releases. + """ + continuousPipelineReleaseFieldVersion: Boolean + """ + The continuous pipeline releases view grouping. + """ + continuousPipelineReleasesViewGrouping: String + """ + Whether to show the custom view creation date field. + """ + customViewFieldDateCreated: Boolean + """ + Whether to show the custom view updated date field. + """ + customViewFieldDateUpdated: Boolean + """ + Whether to show the custom view owner field. + """ + customViewFieldOwner: Boolean + """ + Whether to show the custom view visibility field. + """ + customViewFieldVisibility: Boolean + """ + The custom views ordering. + """ + customViewsOrdering: String + """ + Whether to show the customer domains field. + """ + customerFieldDomains: Boolean + """ + Whether to show the customer owner field. + """ + customerFieldOwner: Boolean + """ + Whether to show the customer request count field. + """ + customerFieldRequestCount: Boolean + """ + Whether to show the customer revenue field. + """ + customerFieldRevenue: Boolean + """ + Whether to show the customer size field. + """ + customerFieldSize: Boolean + """ + Whether to show the customer source field. + """ + customerFieldSource: Boolean + """ + Whether to show the customer status field. + """ + customerFieldStatus: Boolean + """ + Whether to show the customer tier field. + """ + customerFieldTier: Boolean + """ + Whether to show the issue identifier field in the customer page. + """ + customerPageNeedsFieldIssueIdentifier: Boolean + """ + Whether to show the issue priority field in the customer page. + """ + customerPageNeedsFieldIssuePriority: Boolean + """ + Whether to show the issue status field in the customer page. + """ + customerPageNeedsFieldIssueStatus: Boolean + """ + Whether to show the issue due date field in the customer page. + """ + customerPageNeedsFieldIssueTargetDueDate: Boolean + """ + Whether to show completed issues and projects in the customer page. + """ + customerPageNeedsShowCompletedIssuesAndProjects: String + """ + Whether to show important customer needs first. + """ + customerPageNeedsShowImportantFirst: Boolean + """ + The customer page needs view grouping. + """ + customerPageNeedsViewGrouping: String + """ + The customer page needs view ordering. + """ + customerPageNeedsViewOrdering: String + """ + The customers view ordering. + """ + customersViewOrdering: String + """ + Whether to show the dashboard creation date field. + """ + dashboardFieldDateCreated: Boolean + """ + Whether to show the dashboard updated date field. + """ + dashboardFieldDateUpdated: Boolean + """ + Whether to show the dashboard owner field. + """ + dashboardFieldOwner: Boolean + """ + The dashboards ordering. + """ + dashboardsOrdering: String + """ + [Internal] Whether to show the collaborators column in documents lists. + """ + documentFieldCollaborators: Boolean + """ + Whether to show the creator field for documents. + """ + documentFieldCreator: Boolean + """ + Whether to show the created date field for documents. + """ + documentFieldDateCreated: Boolean + """ + Whether to show the updated date field for documents. + """ + documentFieldDateUpdated: Boolean + """ + Whether to show the owner field for documents. + """ + documentFieldOwner: Boolean + """ + Whether to show the parent field for documents. + """ + documentFieldParent: Boolean + """ + [Internal] Whether to show the project column in documents lists. + """ + documentFieldProject: Boolean + """ + [Internal] Direction of a documents list when ordered by created date. + """ + documentsListCreatedDateDirection: String + """ + [Internal] Grouping of a documents list. + """ + documentsListGrouping: String + """ + [Internal] Direction of a documents list when ordered by last edited. + """ + documentsListLastEditedDirection: String + """ + [Internal] Direction of a documents list when ordered by name. + """ + documentsListNameDirection: String + """ + [Internal] Ordering of a documents list. + """ + documentsListOrdering: String + """ + [Internal] Direction of a documents list when ordered by owner. + """ + documentsListOwnerDirection: String + """ + [Internal] Direction of a documents list when ordered by project. + """ + documentsListProjectDirection: String + """ + [Internal] Whether a documents list shows documents from completed or canceled projects. + """ + documentsListShowInactiveProjects: Boolean + """ + [Internal] Whether a documents list only shows documents from projects the user is part of. + """ + documentsListShowOnlyMyProjects: Boolean + """ + Whether to show important embedded customer needs first. + """ + embeddedCustomerNeedsShowImportantFirst: Boolean + """ + The embedded customer needs view ordering. + """ + embeddedCustomerNeedsViewOrdering: String + """ + Whether to show the issue assignee field. + """ + fieldAssignee: Boolean + """ + Whether to show the customer request count field. + """ + fieldCustomerCount: Boolean + """ + Whether to show the customer revenue field. + """ + fieldCustomerRevenue: Boolean + """ + Whether to show the cycle field. + """ + fieldCycle: Boolean + """ + Whether to show the issue archived date field. + """ + fieldDateArchived: Boolean + """ + Whether to show the issue creation date field. + """ + fieldDateCreated: Boolean + """ + Whether to show the issue last activity date field. + """ + fieldDateMyActivity: Boolean + """ + Whether to show the issue updated date field. + """ + fieldDateUpdated: Boolean + """ + Whether to show the due date field. + """ + fieldDueDate: Boolean + """ + Whether to show the issue estimate field. + """ + fieldEstimate: Boolean + """ + Whether to show the issue identifier field. + """ + fieldId: Boolean + """ + Whether to show the labels field. + """ + fieldLabels: Boolean + """ + Whether to show the link count field. + """ + fieldLinkCount: Boolean + """ + Whether to show the milestone field. + """ + fieldMilestone: Boolean + """ + Whether to show preview links. + """ + fieldPreviewLinks: Boolean + """ + Whether to show the issue priority field. + """ + fieldPriority: Boolean + """ + Whether to show the project field. + """ + fieldProject: Boolean + """ + Whether to show the pull requests field. + """ + fieldPullRequests: Boolean + """ + Whether to show the release field. + """ + fieldRelease: Boolean + """ + Whether to show the Sentry issues field. + """ + fieldSentryIssues: Boolean + """ + Whether to show the SLA field. + """ + fieldSla: Boolean + """ + Whether to show the issue status field. + """ + fieldStatus: Boolean + """ + Whether to show the time in current status field. + """ + fieldTimeInCurrentStatus: Boolean + """ + Whether to show the avatars of the other people currently viewing an issue. + """ + fieldUserPresence: Boolean + """ + The focus view grouping. + """ + focusViewGrouping: String @deprecated(reason: "No longer available") + """ + The focus view ordering. + """ + focusViewOrdering: String @deprecated(reason: "No longer available") + """ + The focus view ordering direction. + """ + focusViewOrderingDirection: String @deprecated(reason: "No longer available") + """ + The ordering mode for groups. Supersedes projectGroupOrdering. + """ + groupOrderingMode: String + """ + List of column model IDs which should be hidden on a board. + """ + hiddenColumns: [String!] + """ + List of group model IDs which should be hidden on a list. + """ + hiddenGroupsList: [String!] + """ + List of row model IDs which should be hidden on a board. + """ + hiddenRows: [String!] + """ + The inbox view grouping. + """ + inboxViewGrouping: String + """ + The inbox view ordering. + """ + inboxViewOrdering: String + """ + Whether to show the initiative activity field. + """ + initiativeFieldActivity: Boolean + """ + Whether to show the initiative completed date field. + """ + initiativeFieldDateCompleted: Boolean + """ + Whether to show the initiative created date field. + """ + initiativeFieldDateCreated: Boolean + """ + Whether to show the initiative updated date field. + """ + initiativeFieldDateUpdated: Boolean + """ + Whether to show the initiative description field. + """ + initiativeFieldDescription: Boolean + """ + Whether to show the initiative active projects health field. + """ + initiativeFieldHealth: Boolean + """ + Whether to show the initiative identifier field. + """ + initiativeFieldId: Boolean + """ + Whether to show the initiative health field. + """ + initiativeFieldInitiativeHealth: Boolean + """ + Whether to show the initiative labels field. + """ + initiativeFieldLabels: Boolean + """ + Whether to show the initiative lead team field. + """ + initiativeFieldLeadTeam: Boolean + """ + Whether to show the initiative owner field. + """ + initiativeFieldOwner: Boolean + """ + Whether to show the initiative priority field. + """ + initiativeFieldPriority: Boolean + """ + Whether to show the initiative projects field. + """ + initiativeFieldProjects: Boolean + """ + Whether to show the initiative start date field. + """ + initiativeFieldStartDate: Boolean + """ + Whether to show the initiative status field. + """ + initiativeFieldStatus: Boolean + """ + Whether to show the initiative target date field. + """ + initiativeFieldTargetDate: Boolean + """ + Whether to show the initiative teams field. + """ + initiativeFieldTeams: Boolean + """ + The initiative grouping. + """ + initiativeGrouping: String + """ + The label group ID used for initiative grouping. + """ + initiativeGroupingLabelGroupId: String + """ + The initiative label group columns configuration. + """ + initiativeLabelGroupColumns: [ViewPreferencesInitiativeLabelGroupColumn!] + """ + The initiative ordering. + """ + initiativesViewOrdering: String + """ + The issue grouping. + """ + issueGrouping: String + """ + The label group ID used for issue grouping. + """ + issueGroupingLabelGroupId: String + """ + How sub-issues should be nested and displayed. + """ + issueNesting: String + """ + The issue sub-grouping. + """ + issueSubGrouping: String + """ + The label group ID used for issue sub-grouping. + """ + issueSubGroupingLabelGroupId: String + """ + The issue layout type. + """ + layout: String + """ + Whether to show the member joined date field. + """ + memberFieldJoined: Boolean + """ + Whether to show the member status field. + """ + memberFieldStatus: Boolean + """ + Whether to show the member teams field. + """ + memberFieldTeams: Boolean + """ + [Internal] Ordered ids of the documents pinned to the top of a documents list. + """ + pinnedDocumentIds: [String!] + """ + Whether to show completed issues last in project customer needs. + """ + projectCustomerNeedsShowCompletedIssuesLast: Boolean + """ + Whether to show important project customer needs first. + """ + projectCustomerNeedsShowImportantFirst: Boolean + """ + The project customer needs view grouping. + """ + projectCustomerNeedsViewGrouping: String + """ + The project customer needs view ordering. + """ + projectCustomerNeedsViewOrdering: String + """ + Whether to show the project activity field. + """ + projectFieldActivity: Boolean + """ + Whether to show the project customer count field. + """ + projectFieldCustomerCount: Boolean + """ + Whether to show the project customer revenue field. + """ + projectFieldCustomerRevenue: Boolean + """ + Whether to show the project completion date field. + """ + projectFieldDateCompleted: Boolean + """ + Whether to show the project creation date field. + """ + projectFieldDateCreated: Boolean + """ + Whether to show the project updated date field. + """ + projectFieldDateUpdated: Boolean + """ + Whether to show the project description field. + """ + projectFieldDescription: Boolean + """ + Whether to show the project description field on the board. + """ + projectFieldDescriptionBoard: Boolean + """ + Whether to show the project health field. + """ + projectFieldHealth: Boolean + """ + Whether to show the project health field on the timeline. + """ + projectFieldHealthTimeline: Boolean + """ + Whether to show the project identifier field. + """ + projectFieldId: Boolean + """ + Whether to show the project initiatives field. + """ + projectFieldInitiatives: Boolean + """ + Whether to show the project issue count field. + """ + projectFieldIssues: Boolean + """ + Whether to show the project labels field. + """ + projectFieldLabels: Boolean + """ + Whether to show the project lead field. + """ + projectFieldLead: Boolean + """ + Whether to show the project lead field on the timeline. + """ + projectFieldLeadTimeline: Boolean + """ + Whether to show the project members field. + """ + projectFieldMembers: Boolean + """ + Whether to show the project members field on the board. + """ + projectFieldMembersBoard: Boolean + """ + Whether to show the project members field on the list. + """ + projectFieldMembersList: Boolean + """ + Whether to show the project members field on the timeline. + """ + projectFieldMembersTimeline: Boolean + """ + Whether to show the project milestone field. + """ + projectFieldMilestone: Boolean + """ + Whether to show the project milestone field on the timeline. + """ + projectFieldMilestoneTimeline: Boolean + """ + Whether to show the project predictions field. + """ + projectFieldPredictions: Boolean + """ + Whether to show the project predictions field on the timeline. + """ + projectFieldPredictionsTimeline: Boolean + """ + Whether to show the project priority field. + """ + projectFieldPriority: Boolean + """ + Whether to show the project relations field. + """ + projectFieldRelations: Boolean + """ + Whether to show the project relations field on the timeline. + """ + projectFieldRelationsTimeline: Boolean + """ + Whether to show the project roadmaps field. + """ + projectFieldRoadmaps: Boolean + """ + Whether to show the project roadmaps field on the board. + """ + projectFieldRoadmapsBoard: Boolean + """ + Whether to show the project roadmaps field on the list. + """ + projectFieldRoadmapsList: Boolean + """ + Whether to show the project roadmaps field on the timeline. + """ + projectFieldRoadmapsTimeline: Boolean + """ + Whether to show the project rollout stage field. + """ + projectFieldRolloutStage: Boolean + """ + Whether to show the project start date field. + """ + projectFieldStartDate: Boolean + """ + Whether to show the project status field. + """ + projectFieldStatus: Boolean + """ + Whether to show the project status field on the timeline. + """ + projectFieldStatusTimeline: Boolean + """ + Whether to show the project target date field. + """ + projectFieldTargetDate: Boolean + """ + Whether to show the project teams field. + """ + projectFieldTeams: Boolean + """ + Whether to show the project teams field on the board. + """ + projectFieldTeamsBoard: Boolean + """ + Whether to show the project teams field on the list. + """ + projectFieldTeamsList: Boolean + """ + Whether to show the project teams field on the timeline. + """ + projectFieldTeamsTimeline: Boolean + """ + The ordering of project groups. + """ + projectGroupOrdering: String @deprecated(reason: "Use groupOrderingMode instead.") + """ + The project grouping. + """ + projectGrouping: String + """ + The date resolution when grouping projects by date. + """ + projectGroupingDateResolution: String + """ + The label group ID used for project grouping. + """ + projectGroupingLabelGroupId: String + """ + The project label group columns configuration. + """ + projectLabelGroupColumns: [ViewPreferencesProjectLabelGroupColumn!] + """ + The project layout type. + """ + projectLayout: String + """ + How to show empty project groups. + """ + projectShowEmptyGroups: String + """ + How to show empty project groups on the board layout. + """ + projectShowEmptyGroupsBoard: String + """ + How to show empty project groups on the list layout. + """ + projectShowEmptyGroupsList: String + """ + How to show empty project groups on the timeline layout. + """ + projectShowEmptyGroupsTimeline: String + """ + How to show empty project sub-groups. + """ + projectShowEmptySubGroups: String + """ + How to show empty project sub-groups on the board layout. + """ + projectShowEmptySubGroupsBoard: String + """ + How to show empty project sub-groups on the list layout. + """ + projectShowEmptySubGroupsList: String + """ + How to show empty project sub-groups on the timeline layout. + """ + projectShowEmptySubGroupsTimeline: String + """ + The project sub-grouping. + """ + projectSubGrouping: String + """ + The label group ID used for project sub-grouping. + """ + projectSubGroupingLabelGroupId: String + """ + The project ordering. + """ + projectViewOrdering: String + """ + The zoom level for the timeline view. + """ + projectZoomLevel: String @deprecated(reason: "Use timelineZoomScale instead.") + """ + Whether to show the latest release field for release pipelines. + """ + releasePipelineFieldLatestRelease: Boolean + """ + Whether to show the releases field for release pipelines. + """ + releasePipelineFieldReleases: Boolean + """ + Whether to show the teams field for release pipelines. + """ + releasePipelineFieldTeams: Boolean + """ + Whether to show the type field for release pipelines. + """ + releasePipelineFieldType: Boolean + """ + The release pipeline grouping. + """ + releasePipelineGrouping: String + """ + The release pipelines view ordering. + """ + releasePipelinesViewOrdering: String + """ + Whether to show the review avatar field. + """ + reviewFieldAvatar: Boolean + """ + No longer used. Previously controlled the review checks field. + """ + reviewFieldChecks: Boolean + """ + Whether to show the review GitHub team field. + """ + reviewFieldGithubTeam: Boolean + """ + Whether to show the review identifier field. + """ + reviewFieldIdentifier: Boolean + """ + Whether to show the pull request opened timestamp. + """ + reviewFieldOpenedAt: Boolean + """ + No longer used. Previously controlled the review preview links field. + """ + reviewFieldPreviewLinks: Boolean + """ + Whether to show the quick-to-review badge on review list items. Null if the preference is unset. + """ + reviewFieldQuickToReview: Boolean + """ + Whether to show the review repository field. + """ + reviewFieldRepository: Boolean + """ + Whether to show reviewer avatars on review list items. Null if the preference is unset. + """ + reviewFieldReviewers: Boolean + """ + Whether to show the most pressing SLA from connected issues on review list items. Null if the preference is unset. + """ + reviewFieldSla: Boolean + """ + Whether to show review status details on a second line. + """ + reviewFieldStatusDetails: Boolean + """ + The review grouping. + """ + reviewGrouping: String + """ + The review view ordering. + """ + reviewViewOrdering: String + """ + Whether to show the completion field for scheduled pipeline releases. + """ + scheduledPipelineReleaseFieldCompletion: Boolean + """ + Whether to show the description field for scheduled pipeline releases. + """ + scheduledPipelineReleaseFieldDescription: Boolean + """ + Whether to show the release date field for scheduled pipeline releases. + """ + scheduledPipelineReleaseFieldReleaseDate: Boolean + """ + Whether to show the release-note field for scheduled pipeline releases. + """ + scheduledPipelineReleaseFieldReleaseNote: Boolean + """ + Whether to show the version field for scheduled pipeline releases. + """ + scheduledPipelineReleaseFieldVersion: Boolean + """ + The scheduled pipeline releases view grouping. + """ + scheduledPipelineReleasesViewGrouping: String + """ + The scheduled pipeline releases view ordering. + """ + scheduledPipelineReleasesViewOrdering: String + """ + The search result type filter. + """ + searchResultType: String + """ + The search view ordering. + """ + searchViewOrdering: String + """ + Whether to show archived items. + """ + showArchivedItems: Boolean + """ + Whether completed agent sessions are shown and for how long. + """ + showCompletedAgentSessions: String + """ + Whether completed issues are shown and for how long. + """ + showCompletedIssues: String + """ + Whether completed projects are shown and for how long. + """ + showCompletedProjects: String + """ + Whether completed reviews are shown and for how long. + """ + showCompletedReviews: String + """ + Whether to show draft reviews. + """ + showDraftReviews: Boolean + """ + Whether to show empty groups. + """ + showEmptyGroups: Boolean + """ + Whether to show empty groups on the board layout. + """ + showEmptyGroupsBoard: Boolean + """ + Whether to show empty groups on the list layout. + """ + showEmptyGroupsList: Boolean + """ + Whether to show empty sub-groups. + """ + showEmptySubGroups: Boolean + """ + Whether to show empty sub-groups on the board layout. + """ + showEmptySubGroupsBoard: Boolean + """ + Whether to show empty sub-groups on the list layout. + """ + showEmptySubGroupsList: Boolean + """ + Whether to show sub-initiatives nested. + """ + showNestedInitiatives: Boolean + """ + Whether a team's project views show only the projects that team leads. When true, projects the team only contributes to are hidden. Null if the preference is unset. + """ + showOnlyLeadTeamProjects: Boolean + """ + Whether to show only snoozed items. + """ + showOnlySnoozedItems: Boolean + """ + [Internal] Whether parent initiatives that do not match the view are shown. Defaults to true when unset. + """ + showParentInitiatives: Boolean + """ + Whether to show parent issues for sub-issues. + """ + showParents: Boolean + """ + Whether to show read items. + """ + showReadItems: Boolean + """ + Whether to show snoozed items. + """ + showSnoozedItems: Boolean + """ + Whether to show sub-initiative projects. + """ + showSubInitiativeProjects: Boolean + """ + Whether to show sub-issues. + """ + showSubIssues: Boolean + """ + Whether to show sub-team issues. + """ + showSubTeamIssues: Boolean + """ + Whether to show sub-team projects. + """ + showSubTeamProjects: Boolean + """ + Whether to show supervised issues. + """ + showSupervisedIssues: Boolean + """ + Whether to show team-level initiatives in the workspace. + """ + showTeamInitiatives: Boolean + """ + Whether team reviews are shown in the reviews list. + """ + showTeamReviews: Boolean + """ + Whether to show triage issues. + """ + showTriageIssues: Boolean + """ + Whether to show unread items first. + """ + showUnreadItemsFirst: Boolean + """ + Whether to show the team cycle field. + """ + teamFieldCycle: Boolean + """ + Whether to show the team creation date field. + """ + teamFieldDateCreated: Boolean + """ + Whether to show the team updated date field. + """ + teamFieldDateUpdated: Boolean + """ + Whether to show the team identifier field. + """ + teamFieldIdentifier: Boolean + """ + Whether to show the team members field. + """ + teamFieldMembers: Boolean + """ + Whether to show the team membership field. + """ + teamFieldMembership: Boolean + """ + Whether to show the team owner field. + """ + teamFieldOwner: Boolean + """ + Whether to show the team projects field. + """ + teamFieldProjects: Boolean + """ + [Internal] On the team initiatives page, whether sub-initiatives the team only contributes to are shown. + """ + teamInitiativesShowContributing: Boolean + """ + The team view ordering. + """ + teamViewOrdering: String + """ + Selected team IDs to show cycles for in timeline chronology bar. + """ + timelineChronologyShowCycleTeamIds: [String!] + """ + Whether to show week numbers in timeline chronology bar. + """ + timelineChronologyShowWeekNumbers: Boolean + """ + Whether to show the projects aside panel on the timeline. + """ + timelineShowProjectsAside: Boolean + """ + The zoom scale for the timeline view. + """ + timelineZoomScale: Float + """ + The triage view ordering. + """ + triageViewOrdering: String + """ + The issue ordering. + """ + viewOrdering: String + """ + The direction of the issue ordering. + """ + viewOrderingDirection: String + """ + The workspace members view ordering. + """ + workspaceMembersViewOrdering: String +} + +""" +The client view this custom view is targeting. +""" +enum ViewType { + activeIssues + agents + """ + [Internal] The All tab of the documents page. + """ + allDocuments + allIssues + archive + automationRunHistory + automations + backlog + board + completedCycle + continuousPipelineReleases + createdReviews + customView + customViews + customer + customers + cycle + dashboards + embeddedCustomerNeeds + feedAll + feedCreated + feedFollowing + feedPopular + focus @deprecated(reason: "No longer available") + inbox + inboxOther + inboxPriority + initiative + initiativeLabel + initiativeOverview + initiativeOverviewSubInitiatives + initiatives + initiativesAll + initiativesCanceled + initiativesCompleted + initiativesPlanned + initiativesProposed + issueIdentifiers + label + """ + [Internal] The My documents tab of the documents page. + """ + myDocuments + myIssues + myIssuesActivity + myIssuesCreatedByMe + myIssuesSharedWithMe + myIssuesSubscribedTo + myReviews + project + projectCustomerNeeds + projectDocuments + projectLabel + projects + projectsAll + projectsBacklog + projectsClosed + quickView + release + releaseOverviewIssues + releasePipelines + reviews + roadmap + roadmapAll + roadmapBacklog + roadmapClosed + roadmaps + scheduledPipelineReleases + search + """ + [Internal] The Shared with me tab of the documents page. + """ + sharedDocuments + splitSearch + subIssues + """ + [Internal] The documents list of a team. + """ + teamDocuments + teams + triage + userProfile + userProfileCreatedByUser + workspaceMembers +} + +""" +A webhook subscription that sends HTTP POST callbacks to an external URL when events occur in Linear. Webhooks can be scoped to a specific team, multiple teams, or all public teams in the organization. They support filtering by resource type (e.g., Issue, Comment, Project) and can be created either manually by users or automatically by OAuth applications. Each webhook has a signing secret for verifying payload authenticity on the recipient side. +""" +type Webhook implements Node { + """ + Whether the webhook receives events from all public (non-private) teams in the organization, including teams created after the webhook was set up. When true, the webhook automatically covers new public teams without requiring reconfiguration. + """ + allPublicTeams: Boolean! + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The user who created the webhook. + """ + creator: User + """ + Whether the webhook is enabled. When disabled, no payloads will be delivered even if matching events occur. + """ + enabled: Boolean! + """ + [INTERNAL] Webhook failure events associated with the webhook (last 50). + """ + failures: [WebhookFailureEvent!]! + """ + The unique identifier of the entity. + """ + id: ID! + """ + A human-readable label for the webhook, used for identification in the UI. Null if no label has been set. + """ + label: String + """ + The resource types this webhook is subscribed to (e.g., 'Issue', 'Comment', 'Project', 'Cycle'). The webhook will only receive payloads for events affecting these resource types. + """ + resourceTypes: [String!]! + """ + A secret token used to sign webhook payloads with HMAC-SHA256, allowing the recipient to verify that the payload originated from Linear and was not tampered with. Automatically generated if not provided during creation. + """ + secret: String + """ + The single team that the webhook is scoped to. When null, the webhook either targets all public teams (if allPublicTeams is true), multiple specific teams (if teamIds is set), or organization-wide events. + """ + team: Team + """ + [INTERNAL] An array of team IDs that the webhook is subscribed to. Used to represent a webhook that targets multiple specific teams, potentially in addition to all public teams (when allPublicTeams is also true). Null when the webhook targets a single team via teamId or all public teams only. + """ + teamIds: [String!] + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The destination URL where webhook payloads will be sent via HTTP POST. Null for OAuth application webhooks, which use the webhook URL configured on the OAuth client instead. + """ + url: String +} + +type WebhookConnection { + edges: [WebhookEdge!]! + nodes: [Webhook!]! + pageInfo: PageInfo! +} + +""" +Input for creating a new webhook. +""" +input WebhookCreateInput { + """ + Whether this webhook is enabled for all public teams. + """ + allPublicTeams: Boolean + """ + Whether this webhook is enabled. + """ + enabled: Boolean = true + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + Label for the webhook. + """ + label: String + """ + List of resources the webhook should subscribe to. + """ + resourceTypes: [String!]! + """ + A secret token used to sign the webhook payload. + """ + secret: String + """ + The identifier or key of the team associated with the Webhook. + """ + teamId: String + """ + The URL that will be called on data changes. + """ + url: String! +} + +type WebhookEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: Webhook! +} + +""" +A record of a failed webhook delivery attempt. Created when a webhook payload could not be successfully delivered to the destination URL, either due to an HTTP error response or a network failure. Each failure event captures the HTTP status code (if available), the response body or error message, and a stable execution ID that is shared across retries of the same delivery. +""" +type WebhookFailureEvent { + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + A stable identifier for the webhook delivery attempt. This ID remains the same across retries of the same payload, making it useful for correlating multiple failure events that belong to the same logical delivery. + """ + executionId: String! + """ + The HTTP status code returned by the webhook recipient. Null if the request failed before receiving a response (e.g., DNS resolution failure, connection timeout). + """ + httpStatus: Float + """ + The unique identifier of the entity. + """ + id: ID! + """ + The HTTP response body returned by the recipient, or the error message if the request failed before receiving a response. Truncated to 1000 characters. + """ + responseOrError: String + """ + The URL that the webhook was trying to push to. + """ + url: String! + """ + The webhook that this failure event is associated with. + """ + webhook: Webhook! +} + +""" +The result of a webhook mutation. +""" +type WebhookPayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! + """ + The webhook entity being mutated. + """ + webhook: Webhook! +} + +""" +A webhook event stream resource type that an OAuth application can subscribe to. +""" +enum WebhookResourceType { + AgentSessionEvent + AppUserNotification + Attachment + Comment + Customer + CustomerNeed + Cycle + Document + Initiative + InitiativeUpdate + Issue + IssueLabel + IssueSLA + OAuthAuthorization + PermissionChange + Project + ProjectLabel + ProjectUpdate + Reaction + Release + ReleaseNote + User +} + +""" +The result of a webhook secret rotation mutation. +""" +type WebhookRotateSecretPayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + The new webhook signing secret. + """ + secret: String! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Input for updating an existing webhook. +""" +input WebhookUpdateInput { + """ + Whether this webhook is enabled. + """ + enabled: Boolean + """ + Label for the webhook. + """ + label: String + """ + List of resources the webhook should subscribe to. + """ + resourceTypes: [String!] + """ + A secret token used to sign the webhook payload. + """ + secret: String + """ + The URL that will be called on data changes. + """ + url: String +} + +""" +A welcome message configuration for the workspace. When enabled, new users joining the workspace receive a notification with this message in their inbox. Each workspace has at most one welcome message. The message body is stored in a related DocumentContent entity. +""" +type WelcomeMessage implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + Whether the welcome message is enabled and should be sent to new users joining the workspace. + """ + enabled: Boolean! + """ + The unique identifier of the entity. + """ + id: ID! + """ + The title of the welcome message notification. Null defaults to 'Welcome to {workspace name}'. + """ + title: String + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The user who last updated the welcome message configuration. Null if the user's account has been deleted. + """ + updatedBy: User +} + +""" +A notification containing a workspace welcome message, sent to newly joined users. +""" +type WelcomeMessageNotification implements Entity & Node & Notification { + """ + The user that caused the notification. Null if the notification was triggered by a non-user actor such as an integration, external user, or system event. + """ + actor: User + """ + [Internal] Notification actor initials if avatar is not available. + """ + actorAvatarColor: String! + """ + [Internal] Notification avatar URL. + """ + actorAvatarUrl: String + """ + [Internal] Whether the notification's user actor is deactivated in the workspace. + """ + actorInactive: Boolean! + """ + [Internal] Notification actor initials if avatar is not available. + """ + actorInitials: String + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The bot that caused the notification. + """ + botActor: ActorBot + """ + The category of the notification. + """ + category: NotificationCategory! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The time at which an email reminder for this notification was sent to the user. Null if no email reminder has been sent. + """ + emailedAt: DateTime + """ + The external user that caused the notification. Populated when the notification was triggered by an external user (e.g., a commenter from a connected integration like Slack or GitHub) rather than a Linear workspace member. + """ + externalUserActor: ExternalUser + """ + [Internal] Notifications with the same grouping key will be grouped together in the UI. + """ + groupingKey: String! + """ + [Internal] Priority of the notification with the same grouping key. Higher number means higher priority. If priority is the same, notifications should be sorted by `createdAt`. + """ + groupingPriority: Float! + """ + The unique identifier of the entity. + """ + id: ID! + """ + [Internal] Inbox URL for the notification. + """ + inboxUrl: String! + """ + [Internal] Initiative update health for new updates. + """ + initiativeUpdateHealth: String + """ + [Internal] If notification actor was Linear. + """ + isLinearActor: Boolean! + """ + [Internal] Issue's status type for issue notifications. + """ + issueStatusType: String + """ + [Internal] Project update health for new updates. + """ + projectUpdateHealth: String + """ + The time at which the user marked the notification as read. Null if the notification is unread. + """ + readAt: DateTime + """ + The time until which a notification is snoozed. After this time, the notification reappears in the user's inbox. Null if the notification is not currently snoozed. + """ + snoozedUntilAt: DateTime + """ + [Internal] Notification subtitle. + """ + subtitle: String! + """ + [Internal] Notification title. + """ + title: String! + """ + Notification type. Determines the kind of event that triggered this notification and which associated entity fields will be populated. + """ + type: String! + """ + The time at which a notification was unsnoozed. Null if the notification has not been unsnoozed. + """ + unsnoozedAt: DateTime + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + [Internal] URL to the target of the notification. + """ + url: String! + """ + The recipient user of this notification. + """ + user: User! + """ + Related welcome message. + """ + welcomeMessageId: String! +} + +enum WorkflowActivationMode { + anyUpdate + collectionChanged + conditionsStartedMatching + watchedPropertyChanged +} + +""" +A time-triggered automation workflow definition that executes on a recurring schedule. Cron job definitions are scoped to a team and contain a set of activities (actions) that run automatically according to the configured cron schedule, such as periodically assigning issues or sending notifications. +""" +type WorkflowCronJobDefinition implements Node { + """ + An array of activities that will be executed as part of the workflow cron job. + """ + activities: JSONObject! + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The user who created the workflow cron job. + """ + creator: User! + """ + The description of the workflow cron job. + """ + description: String + """ + Whether the workflow cron job is enabled and will execute on its schedule. + """ + enabled: Boolean! + """ + The unique identifier of the entity. + """ + id: ID! + """ + The name of the workflow cron job. + """ + name: String! + """ + Recurring schedule which is used to execute the workflow cron job. + """ + schedule: JSONObject! + """ + The sort order of the workflow cron job definition within its siblings. + """ + sortOrder: String! + """ + The team associated with the workflow cron job. + """ + team: Team + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +""" +An automation workflow definition that executes a set of activities when triggered by specific events. Workflows can be scoped to a team, project, cycle, label, custom view, initiative, or user context. They are triggered by entity changes (e.g., issue status change, new comment) and can include conditions that filter which events actually execute the workflow. Activities define the actions taken, such as updating issue properties, sending notifications, or posting to Slack. +""" +type WorkflowDefinition implements Node { + """ + The explicit activation semantics for entity updates. When null, the mode is inferred from the legacy trigger fields. + """ + activationMode: WorkflowActivationMode + """ + The ordered list of activities (actions) that are executed when the workflow triggers, such as updating issue properties, sending notifications, or calling webhooks. + """ + activities: JSONObject! + """ + Whether the workflow should apply to sub teams. + """ + applyToSubTeams: Boolean! + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The color of the workflow as a HEX string. Used in the UI to visually identify the workflow. + """ + color: String + """ + The filter conditions that must match for the workflow to execute. When null, the workflow triggers on all matching events. + """ + conditions: JSONObject + """ + The type of view to which this workflow's context is associated with. + """ + contextViewType: ContextViewType + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The user who created the workflow. + """ + creator: User! + """ + The context custom view associated with the workflow. + """ + customView: CustomView + """ + The contextual cycle view associated with the workflow. + """ + cycle: Cycle + """ + The description of the workflow. + """ + description: String + """ + The edit access setting for this workflow definition. When unset, everyone can edit the workflow. + """ + editAccess: WorkflowDefinitionEditAccess + """ + Whether the workflow is enabled and will execute when its trigger conditions are met. + """ + enabled: Boolean! + """ + The name of the group that the workflow belongs to. + """ + groupName: String + """ + The icon of the workflow. Can be an emoji or a decorative icon type. + """ + icon: String + """ + The unique identifier of the entity. + """ + id: ID! + """ + The contextual initiative view associated with the workflow. + """ + initiative: Initiative + """ + The intelligence level used to run the workflow. When null, Auto is used. + """ + intelligence: WorkflowIntelligence + """ + The contextual label view associated with the workflow. + """ + label: IssueLabel + """ + The date and time when the workflow was last triggered and executed. Null if the workflow has never been executed. + """ + lastExecutedAt: DateTime + """ + The user who last updated the workflow. + """ + lastUpdatedBy: User + """ + The name of the workflow. + """ + name: String! + """ + The user who owns the workflow. If not defined, it means the creator should be considered as the owner. + """ + owner: User + """ + The contextual project view associated with the workflow. + """ + project: Project + """ + Whether editing the workflow is restricted to its owner, team owners, and workspace administrators. + """ + restrictEditing: Boolean! @deprecated(reason: "Use editAccess instead.") + """ + Whether the workflow should only execute once per entity. When true, the workflow is excluded from matching automations for an entity if it has already been executed for that entity. + """ + runOnce: Boolean! + """ + Recurring schedule which is used to execute the workflow. + """ + schedule: JSONObject + """ + The workflow definition's unique URL slug. + """ + slugId: String! + """ + The sort order of the workflow definition within its siblings. + """ + sortOrder: String! + """ + Aggregated usage stats for this automation workflow definition. + """ + stats: JSONObject + """ + The team associated with the workflow. If not set, the workflow is associated with the entire workspace. + """ + team: Team + """ + The event that triggers the workflow, such as entity creation, update, or a specific state change. + """ + trigger: WorkflowTrigger! + """ + [Internal] The configuration for the selected trigger type. Null when that type does not use this field. + """ + triggerConfig: JSONObject + """ + The entity type that triggers this workflow, such as Issue, Project, or Release. + """ + triggerType: WorkflowTriggerType! + """ + The type of the workflow, such as custom automation, SLA, or auto-close. + """ + type: WorkflowType! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + The contextual user view associated with the workflow. + """ + user: User + """ + The type of user view to which this workflow's context is associated with. + """ + userContextViewType: UserContextViewType +} + +type WorkflowDefinitionConnection { + edges: [WorkflowDefinitionEdge!]! + nodes: [WorkflowDefinition!]! + pageInfo: PageInfo! +} + +type WorkflowDefinitionEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: WorkflowDefinition! +} + +enum WorkflowDefinitionEditAccess { + everyone + owner + teamOwners + workspaceAdmins +} + +""" +Comparator for the workflow definition that created an issue. +""" +input WorkflowDefinitionIdComparator { + """ + Equals constraint. + """ + eq: ID + """ + In-array constraint. + """ + in: [ID!] + """ + Not-equals constraint. + """ + neq: ID + """ + Not-in-array constraint. + """ + nin: [ID!] + """ + Null constraint. Matches any non-null values if the given value is false, otherwise it matches null values. + """ + null: Boolean +} + +""" +A notification related to an automation workflow definition (loop), such as runs that failed to start. +""" +type WorkflowDefinitionNotification implements Entity & Node & Notification { + """ + The user that caused the notification. Null if the notification was triggered by a non-user actor such as an integration, external user, or system event. + """ + actor: User + """ + [Internal] Notification actor initials if avatar is not available. + """ + actorAvatarColor: String! + """ + [Internal] Notification avatar URL. + """ + actorAvatarUrl: String + """ + [Internal] Whether the notification's user actor is deactivated in the workspace. + """ + actorInactive: Boolean! + """ + [Internal] Notification actor initials if avatar is not available. + """ + actorInitials: String + """ + [Internal] The AI conversation identifier for the related loop run, if one was created. + """ + aiConversationId: String + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The bot that caused the notification. + """ + botActor: ActorBot + """ + The category of the notification. + """ + category: NotificationCategory! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The time at which an email reminder for this notification was sent to the user. Null if no email reminder has been sent. + """ + emailedAt: DateTime + """ + The external user that caused the notification. Populated when the notification was triggered by an external user (e.g., a commenter from a connected integration like Slack or GitHub) rather than a Linear workspace member. + """ + externalUserActor: ExternalUser + """ + [Internal] Notifications with the same grouping key will be grouped together in the UI. + """ + groupingKey: String! + """ + [Internal] Priority of the notification with the same grouping key. Higher number means higher priority. If priority is the same, notifications should be sorted by `createdAt`. + """ + groupingPriority: Float! + """ + The unique identifier of the entity. + """ + id: ID! + """ + [Internal] Inbox URL for the notification. + """ + inboxUrl: String! + """ + [Internal] Initiative update health for new updates. + """ + initiativeUpdateHealth: String + """ + [Internal] If notification actor was Linear. + """ + isLinearActor: Boolean! + """ + [Internal] Issue's status type for issue notifications. + """ + issueStatusType: String + """ + [Internal] Project update health for new updates. + """ + projectUpdateHealth: String + """ + The time at which the user marked the notification as read. Null if the notification is unread. + """ + readAt: DateTime + """ + The time until which a notification is snoozed. After this time, the notification reappears in the user's inbox. Null if the notification is not currently snoozed. + """ + snoozedUntilAt: DateTime + """ + [Internal] Notification subtitle. + """ + subtitle: String! + """ + [Internal] Notification title. + """ + title: String! + """ + Notification type. Determines the kind of event that triggered this notification and which associated entity fields will be populated. + """ + type: String! + """ + The time at which a notification was unsnoozed. Null if the notification has not been unsnoozed. + """ + unsnoozedAt: DateTime + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + [Internal] URL to the target of the notification. + """ + url: String! + """ + The recipient user of this notification. + """ + user: User! + """ + The workflow definition (loop) related to the notification. + """ + workflowDefinition: WorkflowDefinition! + """ + Identifier of the associated workflow definition (loop). + """ + workflowDefinitionId: String! +} + +enum WorkflowIntelligence { + auto + high + low + medium +} + +""" +A state in a team's workflow, representing an issue status such as Triage, Backlog, Todo, In Progress, In Review, Done, or Canceled. Each team has its own set of workflow states that define the progression of issues through the team's process. Workflow states have a type that categorizes them (triage, backlog, unstarted, started, completed, canceled), a position that determines their display order, and a color for visual identification. States can be inherited from parent teams to sub-teams. +""" +type WorkflowState implements Node { + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The state's UI color as a HEX string. + """ + color: String! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + Description of the state. + """ + description: String + """ + The unique identifier of the entity. + """ + id: ID! + """ + The parent team's workflow state that this state was inherited from. Null if the state is not inherited from a parent team. + """ + inheritedFrom: WorkflowState + """ + Issues that currently have this workflow state. Returns a paginated and filterable list of issues. + """ + issues( + """ + A cursor to be used with first for forward pagination + """ + after: String + """ + A cursor to be used with last for backward pagination. + """ + before: String + """ + Filter returned issues. + """ + filter: IssueFilter + """ + The number of items to forward paginate (used with after). Defaults to 50. + """ + first: Int + """ + Should archived resources be included (default: false) + """ + includeArchived: Boolean + """ + The number of items to backward paginate (used with before). Defaults to 50. + """ + last: Int + """ + By which field should the pagination order by. Available options are createdAt (default) and updatedAt. + """ + orderBy: PaginationOrderBy + ): IssueConnection! + """ + The state's human-readable name (e.g., 'In Progress', 'Done', 'Backlog'). + """ + name: String! + """ + The position of the state in the team's workflow. States are displayed in ascending order of position within their type group. + """ + position: Float! + """ + The team that this workflow state belongs to. Each team has its own set of workflow states. + """ + team: Team! + """ + The type of the state. One of "triage", "backlog", "unstarted", "started", "completed", "canceled", "duplicate". + """ + type: String! + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! +} + +""" +A generic payload return from entity archive mutations. +""" +type WorkflowStateArchivePayload implements ArchivePayload { + """ + The archived/unarchived entity. Null if entity was deleted. + """ + entity: WorkflowState + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! +} + +""" +Certain properties of a workflow state. +""" +type WorkflowStateChildWebhookPayload { + """ + The color of the workflow state. + """ + color: String! + """ + The ID of the workflow state. + """ + id: String! + """ + The name of the workflow state. + """ + name: String! + """ + The type of the workflow state. + """ + type: String! +} + +type WorkflowStateConnection { + edges: [WorkflowStateEdge!]! + nodes: [WorkflowState!]! + pageInfo: PageInfo! +} + +""" +Input for creating a new workflow state (issue status) in a team. The name, type, color, and team are required. +""" +input WorkflowStateCreateInput { + """ + The color of the state. + """ + color: String! + """ + The description of the state. + """ + description: String + """ + The identifier in UUID v4 format. If none is provided, the backend will generate one. + """ + id: String + """ + The name of the state. + """ + name: String! + """ + The position of the state. + """ + position: Float + """ + The team associated with the state. + """ + teamId: String! + """ + The workflow state type, which categorizes the state. Valid values: backlog, unstarted, started, completed, canceled. The type determines how the state is treated in workflow progression and reporting. + """ + type: String! +} + +type WorkflowStateEdge { + """ + Used in `before` and `after` args + """ + cursor: String! + node: WorkflowState! +} + +""" +Workflow state filtering options. +""" +input WorkflowStateFilter { + """ + Compound filters, all of which need to be matched by the workflow state. + """ + and: [WorkflowStateFilter!] + """ + Comparator for the created at date. + """ + createdAt: DateComparator + """ + Comparator for the workflow state description. + """ + description: StringComparator + """ + Comparator for the identifier. + """ + id: IDComparator + """ + Filters that the workflow states issues must satisfy. + """ + issues: IssueCollectionFilter + """ + Comparator for the workflow state name. + """ + name: StringComparator + """ + Compound filters, one of which need to be matched by the workflow state. + """ + or: [WorkflowStateFilter!] + """ + Comparator for the workflow state position. + """ + position: NumberComparator + """ + Filters that the workflow states team must satisfy. + """ + team: TeamFilter + """ + Comparator for the workflow state type. Possible values are "triage", "backlog", "unstarted", "started", "completed", "canceled", "duplicate". + """ + type: StringComparator + """ + Comparator for the updated at date. + """ + updatedAt: DateComparator +} + +""" +The result of a workflow state mutation, containing the created or updated state and a success indicator. +""" +type WorkflowStatePayload { + """ + The identifier of the last sync operation. + """ + lastSyncId: Float! + """ + Whether the operation was successful. + """ + success: Boolean! + """ + The state that was created or updated. + """ + workflowState: WorkflowState! +} + +""" +Issue workflow state sorting options. +""" +input WorkflowStateSort { + """ + Whether to sort closed issues by recency + """ + closedIssuesOrderedByRecency: Boolean = false + """ + Whether nulls should be sorted first or last + """ + nulls: PaginationNulls = last + """ + The order for the individual sort + """ + order: PaginationSortOrder + """ + Whether to sort by status type without ordering individual statuses within each type. + """ + typeOnly: Boolean = false +} + +""" +Input for updating an existing workflow state. All fields are optional; only provided fields will be updated. The state type cannot be changed after creation. +""" +input WorkflowStateUpdateInput { + """ + The color of the state. + """ + color: String + """ + The description of the state. + """ + description: String + """ + The name of the state. + """ + name: String + """ + The position of the state. + """ + position: Float +} + +enum WorkflowTrigger { + addedToMergeQueue + chatMessagePosted + chatReactionAdded + commentAdded + commentResolved + customerRequestAdded + cycleEnded + cycleStarted + entityCreated + entityCreatedOrUpdated + entityRemoved + entityUnarchived + entityUpdated + removedFromMergeQueue + reviewSubmitted + updatePosted + webhookReceived +} + +enum WorkflowTriggerType { + chat + cycle + document + initiative + issue + project + pullRequest + release + schedule + team + webhook +} + +enum WorkflowType { + automation + release + sla + triage + triageAutomation + viewSubscription +} + +""" +A workspace announcement delivered to a member's inbox. +""" +type WorkspaceAnnouncementNotification implements Entity & Node & Notification { + """ + The user that caused the notification. Null if the notification was triggered by a non-user actor such as an integration, external user, or system event. + """ + actor: User + """ + [Internal] Notification actor initials if avatar is not available. + """ + actorAvatarColor: String! + """ + [Internal] Notification avatar URL. + """ + actorAvatarUrl: String + """ + [Internal] Whether the notification's user actor is deactivated in the workspace. + """ + actorInactive: Boolean! + """ + [Internal] Notification actor initials if avatar is not available. + """ + actorInitials: String + """ + The time at which the entity was archived. Null if the entity has not been archived. + """ + archivedAt: DateTime + """ + The bot that caused the notification. + """ + botActor: ActorBot + """ + The category of the notification. + """ + category: NotificationCategory! + """ + The time at which the entity was created. + """ + createdAt: DateTime! + """ + The time at which an email reminder for this notification was sent to the user. Null if no email reminder has been sent. + """ + emailedAt: DateTime + """ + The external user that caused the notification. Populated when the notification was triggered by an external user (e.g., a commenter from a connected integration like Slack or GitHub) rather than a Linear workspace member. + """ + externalUserActor: ExternalUser + """ + [Internal] Notifications with the same grouping key will be grouped together in the UI. + """ + groupingKey: String! + """ + [Internal] Priority of the notification with the same grouping key. Higher number means higher priority. If priority is the same, notifications should be sorted by `createdAt`. + """ + groupingPriority: Float! + """ + The unique identifier of the entity. + """ + id: ID! + """ + [Internal] Inbox URL for the notification. + """ + inboxUrl: String! + """ + [Internal] Initiative update health for new updates. + """ + initiativeUpdateHealth: String + """ + [Internal] If notification actor was Linear. + """ + isLinearActor: Boolean! + """ + [Internal] Issue's status type for issue notifications. + """ + issueStatusType: String + """ + [Internal] Project update health for new updates. + """ + projectUpdateHealth: String + """ + The time at which the user marked the notification as read. Null if the notification is unread. + """ + readAt: DateTime + """ + The time until which a notification is snoozed. After this time, the notification reappears in the user's inbox. Null if the notification is not currently snoozed. + """ + snoozedUntilAt: DateTime + """ + [Internal] Notification subtitle. + """ + subtitle: String! + """ + [Internal] Notification title. + """ + title: String! + """ + Notification type. Determines the kind of event that triggered this notification and which associated entity fields will be populated. + """ + type: String! + """ + The time at which a notification was unsnoozed. Null if the notification has not been unsnoozed. + """ + unsnoozedAt: DateTime + """ + The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + been updated after creation. + """ + updatedAt: DateTime! + """ + [Internal] URL to the target of the notification. + """ + url: String! + """ + The recipient user of this notification. + """ + user: User! + """ + Related workspace announcement. + """ + workspaceAnnouncementId: String! +} + +input WorkspaceTeamSecuritySettingsInput { + """ + Whether members may join teams without an invitation. + """ + allMembersCanJoin: Boolean + """ + Minimum role required to manage team members. + """ + memberManagement: TeamRoleType + """ + Minimum role required to manage team settings. + """ + teamManagement: TeamRoleType +} + +input ZendeskSettingsInput { + """ + Whether a ticket should be automatically reopened when its linked Linear issue is canceled. + """ + automateTicketReopeningOnCancellation: Boolean + """ + Whether a ticket should be automatically reopened when a comment is posted on its linked Linear issue + """ + automateTicketReopeningOnComment: Boolean + """ + Whether a ticket should be automatically reopened when its linked Linear issue is completed. + """ + automateTicketReopeningOnCompletion: Boolean + """ + Whether a ticket should be automatically reopened when its linked Linear project is canceled. + """ + automateTicketReopeningOnProjectCancellation: Boolean + """ + Whether a ticket should be automatically reopened when its linked Linear project is completed. + """ + automateTicketReopeningOnProjectCompletion: Boolean + """ + [INTERNAL] Whether API requests authenticate with a user-provided bearer token instead of a Zendesk OAuth token. Only used together with `customApiUrl`. + """ + bearerTokenAuth: Boolean + """ + The ID of the Linear bot user. + """ + botUserId: String + """ + [INTERNAL] Temporary flag indicating if the integration has the necessary scopes for Customers + """ + canReadCustomers: Boolean + """ + [INTERNAL] Custom base URL for Zendesk API requests, such as a proxy in front of Zendesk. When unset, API requests use the standard subdomain URL. OAuth requests always use the standard subdomain URL. + """ + customApiUrl: String + """ + [ALPHA] Whether customer and customer requests should not be automatically created when conversations are linked to a Linear issue. + """ + disableCustomerRequestsAutoCreation: Boolean + """ + Whether Linear Agent should be enabled for this integration. + """ + enableAiIntake: Boolean + """ + Whether Linear Agent should process supported attachments from Zendesk tickets during AI intake. When false, attachments are omitted from the prompt. + """ + enableAiIntakeAttachmentProcessing: Boolean + """ + The host mappings from Zendesk brands. + """ + hostMappings: [String!] + """ + Whether an internal message should be added when someone comments on an issue. + """ + sendNoteOnComment: Boolean + """ + Whether an internal message should be added when a Linear issue changes status (for status types except completed or canceled). + """ + sendNoteOnStatusChange: Boolean + """ + The subdomain of the Zendesk organization being connected. + """ + subdomain: String! + """ + [INTERNAL] Flag indicating if the integration supports OAuth refresh tokens + """ + supportsOAuthRefresh: Boolean + """ + The URL of the connected Zendesk organization, used to link into Zendesk. API requests use `customApiUrl` when it is set. + """ + url: String! +} diff --git a/packages/issue-tracker-linear/schema/linear.graphql.ts b/packages/issue-tracker-linear/schema/linear.graphql.ts new file mode 100644 index 000000000000..3f9e8a7644a8 --- /dev/null +++ b/packages/issue-tracker-linear/schema/linear.graphql.ts @@ -0,0 +1,5424 @@ +// Generated by @effect/graphql-generator. Do not edit. +import * as Schema from "effect/Schema" + +export const Int = Schema.Number.check(Schema.isInt32()) + +export const Float = Schema.Finite + +export const ID = Schema.String + +/** Represents a date and time in ISO 8601 format. Accepts shortcuts like `2021` to represent midnight Fri Jan 01 2021. Also accepts ISO 8601 durations strings which are added to the current date to create the represented date (e.g '-P2W1D' represents the date that was two weeks and 1 day ago) */ +export const DateTime = Schema.String + +/** Represents a date and time in ISO 8601 format. Accepts shortcuts like `2021` to represent midnight Fri Jan 01 2021. Also accepts ISO 8601 durations strings which are added to the current date to create the represented date (e.g '-P2W1D' represents the date that was two weeks and 1 day ago) */ +export const DateTimeOrDuration = Schema.String + +/** Represents a duration in ISO 8601 format. Accepts ISO 8601 duration strings or integers in milliseconds. */ +export const Duration = Schema.String + +/** The `JSON` scalar type represents arbitrary values as *stringified* JSON */ +export const JSON = Schema.Json + +/** The `JSONObject` scalar type represents arbitrary values as *embedded* JSON */ +export const JSONObject = Schema.Json + +/** Represents a date in ISO 8601 format. Accepts shortcuts like `2021` to represent midnight Fri Jan 01 2021. Also accepts ISO 8601 durations strings which are added to the current date to create the represented date (e.g '-P2W1D' represents the date that was two weeks and 1 day ago) */ +export const TimelessDate = Schema.String + +/** Represents a date in ISO 8601 format or a duration. Accepts shortcuts like `2021` to represent midnight Fri Jan 01 2021. Also accepts ISO 8601 durations strings (e.g '-P2W1D'), which are not converted to dates. */ +export const TimelessDateOrDuration = Schema.String + +/** + * - `after` + * - `before` + * - `during` + */ +export const CyclePeriod = Schema.Literals(["after", "before", "during"]) +export type CyclePeriod = typeof CyclePeriod.Type + +/** + * The type of a release pipeline, which determines how releases are created and managed. Continuous pipelines create a new completed release for each sync. Scheduled pipelines accumulate issues into a started release that is explicitly completed. + * + * - `continuous` + * - `scheduled` + */ +export const ReleasePipelineType = Schema.Literals(["continuous", "scheduled"]) +export type ReleasePipelineType = typeof ReleasePipelineType.Type + +/** + * The type of a release stage, which determines the release's lifecycle state. Types include planned, started, completed, and canceled. Each pipeline must have at least one stage of each type, though only started stages may have multiple instances. + * + * - `canceled` + * - `completed` + * - `planned` + * - `started` + */ +export const ReleaseStageType = Schema.Literals(["canceled", "completed", "planned", "started"]) +export type ReleaseStageType = typeof ReleaseStageType.Type + +/** + * Which day count to use for SLA calculations. + * + * - `all` + * - `onlyBusinessDays` + */ +export const SLADayCountType = Schema.Literals(["all", "onlyBusinessDays"]) +export type SLADayCountType = typeof SLADayCountType.Type + +/** + * - `Breached` + * - `Completed` + * - `Failed` + * - `HighRisk` + * - `LowRisk` + * - `MediumRisk` + */ +export const SlaStatus = Schema.Literals(["Breached", "Completed", "Failed", "HighRisk", "LowRisk", "MediumRisk"]) +export type SlaStatus = typeof SlaStatus.Type + +/** + * The visibility of a team. A team can be public, private, or restricted within an enclosing private-team boundary. + * + * - `private` + * - `public` + * - `restricted` + */ +export const TeamVisibility = Schema.Literals(["private", "public", "restricted"]) +export type TeamVisibility = typeof TeamVisibility.Type + +/** Input for creating a new comment. */ +export const CommentCreateInput = Schema.Struct({ + /** The comment content in markdown format. */ + body: Schema.optional(Schema.NullOr(Schema.String)), + /** [Internal] The comment content as a Prosemirror document. */ + bodyData: Schema.optional(Schema.NullOr(JSON)), + /** Create comment as a user with the provided name. This option is only available to OAuth applications creating comments in `actor=app` mode. */ + createAsUser: Schema.optional(Schema.NullOr(Schema.String)), + /** Flag to indicate this comment should be created on the issue's synced Slack comment thread. If no synced Slack comment thread exists, the mutation will fail. If there are multiple synced Slack threads on the issue, the oldest one will be targeted. */ + createOnSyncedSlackThread: Schema.optional(Schema.NullOr(Schema.Boolean)), + /** The time at which the comment was created (e.g. if importing from another system). Must be a time in the past. If none is provided, the backend will generate the time as now. */ + createdAt: Schema.optional(Schema.NullOr(DateTime)), + /** Provide an external user avatar URL. Can only be used in conjunction with the `createAsUser` options. This option is only available to OAuth applications creating comments in `actor=app` mode. */ + displayIconUrl: Schema.optional(Schema.NullOr(Schema.String)), + /** Flag to prevent auto subscription to the issue the comment is created on. */ + doNotSubscribeToIssue: Schema.optional(Schema.NullOr(Schema.Boolean)), + /** The document content to associate the comment with. */ + documentContentId: Schema.optional(Schema.NullOr(Schema.String)), + /** The identifier in UUID v4 format. If none is provided, the backend will generate one. */ + id: Schema.optional(Schema.NullOr(Schema.String)), + /** The initiative to associate the comment with. Can be a UUID or initiative identifier (e.g., 'I-12'). */ + initiativeId: Schema.optional(Schema.NullOr(Schema.String)), + /** The initiative update to associate the comment with. */ + initiativeUpdateId: Schema.optional(Schema.NullOr(Schema.String)), + /** [Internal] Where the commented text starts, as a base64-encoded Y.js relative position created on the commenter's copy of the document content. Requires `inlineAnchorTo` and `documentContentId`. */ + inlineAnchorFrom: Schema.optional(Schema.NullOr(Schema.String)), + /** [Internal] Where the commented text ends, as a base64-encoded Y.js relative position created on the commenter's copy of the document content. Requires `inlineAnchorFrom` and `documentContentId`. */ + inlineAnchorTo: Schema.optional(Schema.NullOr(Schema.String)), + /** The issue to associate the comment with. Can be a UUID or issue identifier (e.g., 'LIN-123'). */ + issueId: Schema.optional(Schema.NullOr(Schema.String)), + /** The parent comment under which to nest a current comment. */ + parentId: Schema.optional(Schema.NullOr(Schema.String)), + /** The post to associate the comment with. */ + postId: Schema.optional(Schema.NullOr(Schema.String)), + /** The project to associate the comment with. Can be a UUID or project identifier (e.g., 'P-LIN-123'). */ + projectId: Schema.optional(Schema.NullOr(Schema.String)), + /** The project update to associate the comment with. */ + projectUpdateId: Schema.optional(Schema.NullOr(Schema.String)), + /** The text that this comment references. Only defined for inline comments. */ + quotedText: Schema.optional(Schema.NullOr(Schema.String)), + /** [INTERNAL] The identifiers of the users subscribing to this comment thread. */ + subscriberIds: Schema.optional(Schema.NullOr(Schema.Array(Schema.String))) +}) +export interface CommentCreateInput extends Schema.Struct.Type {} + +/** Input for creating a new issue. At minimum, a team must be specified. A title is required unless a template is provided. All other fields are optional and will use defaults from the team or template if not specified. */ +export const IssueCreateInput = Schema.Struct({ + /** The identifier of the user to assign the issue to. */ + assigneeId: Schema.optional(Schema.NullOr(Schema.String)), + /** The time at which the issue was completed (e.g. if importing from another system). Must be a time in the past and after createdAt. Cannot be provided with an incompatible workflow state. */ + completedAt: Schema.optional(Schema.NullOr(DateTime)), + /** Create issue as a user with the provided name. This option is only available to OAuth applications creating issues in `actor=app` mode. */ + createAsUser: Schema.optional(Schema.NullOr(Schema.String)), + /** The time at which the issue was created (e.g. if importing from another system). Must be a time in the past. If none is provided, the backend will generate the time as now. */ + createdAt: Schema.optional(Schema.NullOr(DateTime)), + /** The cycle associated with the issue. */ + cycleId: Schema.optional(Schema.NullOr(Schema.String)), + /** The identifier of the agent user to delegate the issue to. */ + delegateId: Schema.optional(Schema.NullOr(Schema.String)), + /** The issue description in markdown format. */ + description: Schema.optional(Schema.NullOr(Schema.String)), + /** [Internal] The issue description as a Prosemirror document. */ + descriptionData: Schema.optional(Schema.NullOr(JSON)), + /** Provide an external user avatar URL. Can only be used in conjunction with the `createAsUser` options. This option is only available to OAuth applications creating comments in `actor=app` mode. */ + displayIconUrl: Schema.optional(Schema.NullOr(Schema.String)), + /** The date at which the issue is due. */ + dueDate: Schema.optional(Schema.NullOr(TimelessDate)), + /** The estimated complexity of the issue. */ + estimate: Schema.optional(Schema.NullOr(Int)), + /** The identifier in UUID v4 format. If none is provided, the backend will generate one. */ + id: Schema.optional(Schema.NullOr(Schema.String)), + /** [Internal] Whether this issue should inherit shared access from its parent issue. Set to false to opt out of automatic shared access inheritance when creating a sub-issue. */ + inheritsSharedAccess: Schema.optional(Schema.NullOr(Schema.Boolean)), + /** The identifiers of the issue labels associated with this ticket. */ + labelIds: Schema.optional(Schema.NullOr(Schema.Array(Schema.String))), + /** The ID of the last template applied to the issue. */ + lastAppliedTemplateId: Schema.optional(Schema.NullOr(Schema.String)), + /** The identifier of the parent issue. Can be a UUID or issue identifier (e.g., 'LIN-123'). */ + parentId: Schema.optional(Schema.NullOr(Schema.String)), + /** Whether the passed sort order should be preserved. */ + preserveSortOrderOnCreate: Schema.optional(Schema.NullOr(Schema.Boolean)), + /** The priority of the issue. 0 = No priority, 1 = Urgent, 2 = High, 3 = Medium, 4 = Low. */ + priority: Schema.optional(Schema.NullOr(Int)), + /** The position of the issue related to other issues, when ordered by priority. */ + prioritySortOrder: Schema.optional(Schema.NullOr(Float)), + /** The project associated with the issue. Can be a UUID or project identifier (e.g., 'P-LIN-123'). */ + projectId: Schema.optional(Schema.NullOr(Schema.String)), + /** The project milestone associated with the issue. */ + projectMilestoneId: Schema.optional(Schema.NullOr(Schema.String)), + /** The comment the issue is referencing. */ + referenceCommentId: Schema.optional(Schema.NullOr(Schema.String)), + /** The identifiers of the releases to associate with this issue. */ + releaseIds: Schema.optional(Schema.NullOr(Schema.Array(Schema.String))), + /** [Internal] The time at which an issue will be considered in breach of SLA. */ + slaBreachesAt: Schema.optional(Schema.NullOr(DateTime)), + /** [Internal] The time at which the issue's SLA was started. */ + slaStartedAt: Schema.optional(Schema.NullOr(DateTime)), + /** The SLA day count type for the issue. Whether SLA should be business days only or calendar days (default). */ + slaType: Schema.optional(Schema.NullOr(SLADayCountType)), + /** The position of the issue related to other issues. */ + sortOrder: Schema.optional(Schema.NullOr(Float)), + /** The comment the issue is created from. */ + sourceCommentId: Schema.optional(Schema.NullOr(Schema.String)), + /** [Internal] The pull request comment the issue is created from. */ + sourcePullRequestCommentId: Schema.optional(Schema.NullOr(Schema.String)), + /** The team state of the issue. */ + stateId: Schema.optional(Schema.NullOr(Schema.String)), + /** The position of the issue in parent's sub-issue list. */ + subIssueSortOrder: Schema.optional(Schema.NullOr(Float)), + /** The identifiers of the users subscribing to this ticket. */ + subscriberIds: Schema.optional(Schema.NullOr(Schema.Array(Schema.String))), + /** The identifier of the team associated with the issue. */ + teamId: Schema.String, + /** The identifier of a template the issue should be created from. If other values are provided in the input, they will override template values. */ + templateId: Schema.optional(Schema.NullOr(Schema.String)), + /** The title of the issue. */ + title: Schema.optional(Schema.NullOr(Schema.String)), + /** Whether to use the default template for the team. When set to true, the default template of this team based on user's membership will be applied. */ + useDefaultTemplate: Schema.optional(Schema.NullOr(Schema.Boolean)) +}) +export interface IssueCreateInput extends Schema.Struct.Type {} + +/** Comparator for optional dates. */ +export const NullableDateComparator = Schema.Struct({ + /** Equals constraint. */ + eq: Schema.optional(Schema.NullOr(DateTimeOrDuration)), + /** Greater-than constraint. Matches any values that are greater than the given value. */ + gt: Schema.optional(Schema.NullOr(DateTimeOrDuration)), + /** Greater-than-or-equal constraint. Matches any values that are greater than or equal to the given value. */ + gte: Schema.optional(Schema.NullOr(DateTimeOrDuration)), + /** In-array constraint. */ + in: Schema.optional(Schema.NullOr(Schema.Array(DateTimeOrDuration))), + /** Less-than constraint. Matches any values that are less than the given value. */ + lt: Schema.optional(Schema.NullOr(DateTimeOrDuration)), + /** Less-than-or-equal constraint. Matches any values that are less than or equal to the given value. */ + lte: Schema.optional(Schema.NullOr(DateTimeOrDuration)), + /** Not-equals constraint. */ + neq: Schema.optional(Schema.NullOr(DateTimeOrDuration)), + /** Not-in-array constraint. */ + nin: Schema.optional(Schema.NullOr(Schema.Array(DateTimeOrDuration))), + /** Null constraint. Matches any non-null values if the given value is false, otherwise it matches null values. */ + null: Schema.optional(Schema.NullOr(Schema.Boolean)) +}) +export interface NullableDateComparator extends Schema.Struct.Type {} + +/** Comparator for dates. */ +export const DateComparator = Schema.Struct({ + /** Equals constraint. */ + eq: Schema.optional(Schema.NullOr(DateTimeOrDuration)), + /** Greater-than constraint. Matches any values that are greater than the given value. */ + gt: Schema.optional(Schema.NullOr(DateTimeOrDuration)), + /** Greater-than-or-equal constraint. Matches any values that are greater than or equal to the given value. */ + gte: Schema.optional(Schema.NullOr(DateTimeOrDuration)), + /** In-array constraint. */ + in: Schema.optional(Schema.NullOr(Schema.Array(DateTimeOrDuration))), + /** Less-than constraint. Matches any values that are less than the given value. */ + lt: Schema.optional(Schema.NullOr(DateTimeOrDuration)), + /** Less-than-or-equal constraint. Matches any values that are less than or equal to the given value. */ + lte: Schema.optional(Schema.NullOr(DateTimeOrDuration)), + /** Not-equals constraint. */ + neq: Schema.optional(Schema.NullOr(DateTimeOrDuration)), + /** Not-in-array constraint. */ + nin: Schema.optional(Schema.NullOr(Schema.Array(DateTimeOrDuration))) +}) +export interface DateComparator extends Schema.Struct.Type {} + +/** Comparator for identifiers. */ +export const IDComparator = Schema.Struct({ + /** Equals constraint. */ + eq: Schema.optional(Schema.NullOr(ID)), + /** In-array constraint. */ + in: Schema.optional(Schema.NullOr(Schema.Array(ID))), + /** Not-equals constraint. */ + neq: Schema.optional(Schema.NullOr(ID)), + /** Not-in-array constraint. */ + nin: Schema.optional(Schema.NullOr(Schema.Array(ID))) +}) +export interface IDComparator extends Schema.Struct.Type {} + +/** Comparator for booleans. */ +export const BooleanComparator = Schema.Struct({ + /** Equals constraint. */ + eq: Schema.optional(Schema.NullOr(Schema.Boolean)), + /** Not equals constraint. */ + neq: Schema.optional(Schema.NullOr(Schema.Boolean)) +}) +export interface BooleanComparator extends Schema.Struct.Type {} + +/** Comparator for period when issue was added to a cycle. */ +export const CyclePeriodComparator = Schema.Struct({ + /** Equals constraint. */ + eq: Schema.optional(Schema.NullOr(CyclePeriod)), + /** In-array constraint. */ + in: Schema.optional(Schema.NullOr(Schema.Array(CyclePeriod))), + /** Not-equals constraint. */ + neq: Schema.optional(Schema.NullOr(CyclePeriod)), + /** Not-in-array constraint. */ + nin: Schema.optional(Schema.NullOr(Schema.Array(CyclePeriod))), + /** Null constraint. Matches any non-null values if the given value is false, otherwise it matches null values. */ + null: Schema.optional(Schema.NullOr(Schema.Boolean)) +}) +export interface CyclePeriodComparator extends Schema.Struct.Type {} + +/** Nullable comparator for optional durations. */ +export const NullableDurationComparator = Schema.Struct({ + /** Equals constraint. */ + eq: Schema.optional(Schema.NullOr(Duration)), + /** Greater-than constraint. Matches any values that are greater than the given value. */ + gt: Schema.optional(Schema.NullOr(Duration)), + /** Greater-than-or-equal constraint. Matches any values that are greater than or equal to the given value. */ + gte: Schema.optional(Schema.NullOr(Duration)), + /** In-array constraint. */ + in: Schema.optional(Schema.NullOr(Schema.Array(Duration))), + /** Less-than constraint. Matches any values that are less than the given value. */ + lt: Schema.optional(Schema.NullOr(Duration)), + /** Less-than-or-equal constraint. Matches any values that are less than or equal to the given value. */ + lte: Schema.optional(Schema.NullOr(Duration)), + /** Not-equals constraint. */ + neq: Schema.optional(Schema.NullOr(Duration)), + /** Not-in-array constraint. */ + nin: Schema.optional(Schema.NullOr(Schema.Array(Duration))), + /** Null constraint. Matches any non-null values if the given value is false, otherwise it matches null values. */ + null: Schema.optional(Schema.NullOr(Schema.Boolean)) +}) +export interface NullableDurationComparator extends Schema.Struct.Type {} + +/** Comparator for strings. */ +export const StringComparator = Schema.Struct({ + /** Contains constraint. Matches any values that contain the given string. */ + contains: Schema.optional(Schema.NullOr(Schema.String)), + /** Contains case insensitive constraint. Matches any values that contain the given string case insensitive. */ + containsIgnoreCase: Schema.optional(Schema.NullOr(Schema.String)), + /** Contains case and accent insensitive constraint. Matches any values that contain the given string case and accent insensitive. */ + containsIgnoreCaseAndAccent: Schema.optional(Schema.NullOr(Schema.String)), + /** Ends with constraint. Matches any values that end with the given string. */ + endsWith: Schema.optional(Schema.NullOr(Schema.String)), + /** Equals constraint. */ + eq: Schema.optional(Schema.NullOr(Schema.String)), + /** Equals case insensitive. Matches any values that matches the given string case insensitive. */ + eqIgnoreCase: Schema.optional(Schema.NullOr(Schema.String)), + /** In-array constraint. */ + in: Schema.optional(Schema.NullOr(Schema.Array(Schema.String))), + /** Not-equals constraint. */ + neq: Schema.optional(Schema.NullOr(Schema.String)), + /** Not-equals case insensitive. Matches any values that don't match the given string case insensitive. */ + neqIgnoreCase: Schema.optional(Schema.NullOr(Schema.String)), + /** Not-in-array constraint. */ + nin: Schema.optional(Schema.NullOr(Schema.Array(Schema.String))), + /** Doesn't contain constraint. Matches any values that don't contain the given string. */ + notContains: Schema.optional(Schema.NullOr(Schema.String)), + /** Doesn't contain case insensitive constraint. Matches any values that don't contain the given string case insensitive. */ + notContainsIgnoreCase: Schema.optional(Schema.NullOr(Schema.String)), + /** Doesn't end with constraint. Matches any values that don't end with the given string. */ + notEndsWith: Schema.optional(Schema.NullOr(Schema.String)), + /** Doesn't start with constraint. Matches any values that don't start with the given string. */ + notStartsWith: Schema.optional(Schema.NullOr(Schema.String)), + /** Starts with constraint. Matches any values that start with the given string. */ + startsWith: Schema.optional(Schema.NullOr(Schema.String)), + /** Starts with case insensitive constraint. Matches any values that start with the given string. */ + startsWithIgnoreCase: Schema.optional(Schema.NullOr(Schema.String)) +}) +export interface StringComparator extends Schema.Struct.Type {} + +/** Comparator for `sourceType` field. */ +export const SourceTypeComparator = Schema.Struct({ + /** Contains constraint. Matches any values that contain the given string. */ + contains: Schema.optional(Schema.NullOr(Schema.String)), + /** Contains case insensitive constraint. Matches any values that contain the given string case insensitive. */ + containsIgnoreCase: Schema.optional(Schema.NullOr(Schema.String)), + /** Contains case and accent insensitive constraint. Matches any values that contain the given string case and accent insensitive. */ + containsIgnoreCaseAndAccent: Schema.optional(Schema.NullOr(Schema.String)), + /** Ends with constraint. Matches any values that end with the given string. */ + endsWith: Schema.optional(Schema.NullOr(Schema.String)), + /** Equals constraint. */ + eq: Schema.optional(Schema.NullOr(Schema.String)), + /** Equals case insensitive. Matches any values that matches the given string case insensitive. */ + eqIgnoreCase: Schema.optional(Schema.NullOr(Schema.String)), + /** In-array constraint. */ + in: Schema.optional(Schema.NullOr(Schema.Array(Schema.String))), + /** Not-equals constraint. */ + neq: Schema.optional(Schema.NullOr(Schema.String)), + /** Not-equals case insensitive. Matches any values that don't match the given string case insensitive. */ + neqIgnoreCase: Schema.optional(Schema.NullOr(Schema.String)), + /** Not-in-array constraint. */ + nin: Schema.optional(Schema.NullOr(Schema.Array(Schema.String))), + /** Doesn't contain constraint. Matches any values that don't contain the given string. */ + notContains: Schema.optional(Schema.NullOr(Schema.String)), + /** Doesn't contain case insensitive constraint. Matches any values that don't contain the given string case insensitive. */ + notContainsIgnoreCase: Schema.optional(Schema.NullOr(Schema.String)), + /** Doesn't end with constraint. Matches any values that don't end with the given string. */ + notEndsWith: Schema.optional(Schema.NullOr(Schema.String)), + /** Doesn't start with constraint. Matches any values that don't start with the given string. */ + notStartsWith: Schema.optional(Schema.NullOr(Schema.String)), + /** Starts with constraint. Matches any values that start with the given string. */ + startsWith: Schema.optional(Schema.NullOr(Schema.String)), + /** Starts with case insensitive constraint. Matches any values that start with the given string. */ + startsWithIgnoreCase: Schema.optional(Schema.NullOr(Schema.String)) +}) +export interface SourceTypeComparator extends Schema.Struct.Type {} + +/** Comparator for optional strings. */ +export const NullableStringComparator = Schema.Struct({ + /** Contains constraint. Matches any values that contain the given string. */ + contains: Schema.optional(Schema.NullOr(Schema.String)), + /** Contains case insensitive constraint. Matches any values that contain the given string case insensitive. */ + containsIgnoreCase: Schema.optional(Schema.NullOr(Schema.String)), + /** Contains case and accent insensitive constraint. Matches any values that contain the given string case and accent insensitive. */ + containsIgnoreCaseAndAccent: Schema.optional(Schema.NullOr(Schema.String)), + /** Ends with constraint. Matches any values that end with the given string. */ + endsWith: Schema.optional(Schema.NullOr(Schema.String)), + /** Equals constraint. */ + eq: Schema.optional(Schema.NullOr(Schema.String)), + /** Equals case insensitive. Matches any values that matches the given string case insensitive. */ + eqIgnoreCase: Schema.optional(Schema.NullOr(Schema.String)), + /** In-array constraint. */ + in: Schema.optional(Schema.NullOr(Schema.Array(Schema.String))), + /** Not-equals constraint. */ + neq: Schema.optional(Schema.NullOr(Schema.String)), + /** Not-equals case insensitive. Matches any values that don't match the given string case insensitive. */ + neqIgnoreCase: Schema.optional(Schema.NullOr(Schema.String)), + /** Not-in-array constraint. */ + nin: Schema.optional(Schema.NullOr(Schema.Array(Schema.String))), + /** Doesn't contain constraint. Matches any values that don't contain the given string. */ + notContains: Schema.optional(Schema.NullOr(Schema.String)), + /** Doesn't contain case insensitive constraint. Matches any values that don't contain the given string case insensitive. */ + notContainsIgnoreCase: Schema.optional(Schema.NullOr(Schema.String)), + /** Doesn't end with constraint. Matches any values that don't end with the given string. */ + notEndsWith: Schema.optional(Schema.NullOr(Schema.String)), + /** Doesn't start with constraint. Matches any values that don't start with the given string. */ + notStartsWith: Schema.optional(Schema.NullOr(Schema.String)), + /** Null constraint. Matches any non-null values if the given value is false, otherwise it matches null values. */ + null: Schema.optional(Schema.NullOr(Schema.Boolean)), + /** Starts with constraint. Matches any values that start with the given string. */ + startsWith: Schema.optional(Schema.NullOr(Schema.String)), + /** Starts with case insensitive constraint. Matches any values that start with the given string. */ + startsWithIgnoreCase: Schema.optional(Schema.NullOr(Schema.String)) +}) +export interface NullableStringComparator extends Schema.Struct.Type {} + +/** Comparator for numbers. */ +export const NumberComparator = Schema.Struct({ + /** Equals constraint. */ + eq: Schema.optional(Schema.NullOr(Float)), + /** Greater-than constraint. Matches any values that are greater than the given value. */ + gt: Schema.optional(Schema.NullOr(Float)), + /** Greater-than-or-equal constraint. Matches any values that are greater than or equal to the given value. */ + gte: Schema.optional(Schema.NullOr(Float)), + /** In-array constraint. */ + in: Schema.optional(Schema.NullOr(Schema.Array(Float))), + /** Less-than constraint. Matches any values that are less than the given value. */ + lt: Schema.optional(Schema.NullOr(Float)), + /** Less-than-or-equal constraint. Matches any values that are less than or equal to the given value. */ + lte: Schema.optional(Schema.NullOr(Float)), + /** Not-equals constraint. */ + neq: Schema.optional(Schema.NullOr(Float)), + /** Not-in-array constraint. */ + nin: Schema.optional(Schema.NullOr(Schema.Array(Float))) +}) +export interface NumberComparator extends Schema.Struct.Type {} + +/** Comparator for release pipeline type. */ +export const ReleasePipelineTypeComparator = Schema.Struct({ + /** Equals constraint. */ + eq: Schema.optional(Schema.NullOr(ReleasePipelineType)), + /** In-array constraint. */ + in: Schema.optional(Schema.NullOr(Schema.Array(ReleasePipelineType))), + /** Not-equals constraint. */ + neq: Schema.optional(Schema.NullOr(ReleasePipelineType)), + /** Not-in-array constraint. */ + nin: Schema.optional(Schema.NullOr(Schema.Array(ReleasePipelineType))), + /** Null constraint. Matches any non-null values if the given value is false, otherwise it matches null values. */ + null: Schema.optional(Schema.NullOr(Schema.Boolean)) +}) +export interface ReleasePipelineTypeComparator extends Schema.Struct.Type {} + +/** Comparator for team visibility. */ +export const TeamVisibilityComparator = Schema.Struct({ + /** Equals constraint. */ + eq: Schema.optional(Schema.NullOr(TeamVisibility)), + /** In-array constraint. */ + in: Schema.optional(Schema.NullOr(Schema.Array(TeamVisibility))), + /** Not-equals constraint. */ + neq: Schema.optional(Schema.NullOr(TeamVisibility)), + /** Not-in-array constraint. */ + nin: Schema.optional(Schema.NullOr(Schema.Array(TeamVisibility))) +}) +export interface TeamVisibilityComparator extends Schema.Struct.Type {} + +/** Comparator for project and initiative identifiers. Accepts UUIDs and human-readable identifiers (e.g. "PROJ-123"). */ +export const EntityIdentifierIDComparator = Schema.Struct({ + /** Equals constraint. */ + eq: Schema.optional(Schema.NullOr(ID)), + /** In-array constraint. */ + in: Schema.optional(Schema.NullOr(Schema.Array(ID))), + /** Not-equals constraint. */ + neq: Schema.optional(Schema.NullOr(ID)), + /** Not-in-array constraint. */ + nin: Schema.optional(Schema.NullOr(Schema.Array(ID))) +}) +export interface EntityIdentifierIDComparator extends Schema.Struct.Type {} + +/** Options for filtering initiatives by initiative updates. */ +export const InitiativeUpdatesFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => InitiativeUpdatesFilter)))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + id: Schema.optional(Schema.NullOr(IDComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => InitiativeUpdatesFilter)))), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface InitiativeUpdatesFilter { + /** Compound filters, all of which need to be matched by the initiative updates. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Compound filters, one of which need to be matched by the initiative updates. */ + readonly or?: ReadonlyArray | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface InitiativeUpdatesFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Collection filtering options for filtering initiatives by initiative updates. */ +export const InitiativeUpdatesCollectionFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => InitiativeUpdatesCollectionFilter)))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + every: Schema.optional(Schema.NullOr(InitiativeUpdatesFilter)), + id: Schema.optional(Schema.NullOr(IDComparator)), + length: Schema.optional(Schema.NullOr(NumberComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => InitiativeUpdatesCollectionFilter)))), + some: Schema.optional(Schema.NullOr(InitiativeUpdatesFilter)), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface InitiativeUpdatesCollectionFilter { + /** Compound filters, all of which need to be matched by the initiative update. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Filters that needs to be matched by all initiative updates. */ + readonly every?: InitiativeUpdatesFilter | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Comparator for the collection length. */ + readonly length?: NumberComparator | null | undefined + /** Compound filters, one of which need to be matched by the update. */ + readonly or?: ReadonlyArray | null | undefined + /** Filters that needs to be matched by some initiative updates. */ + readonly some?: InitiativeUpdatesFilter | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface InitiativeUpdatesCollectionFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly every?: InitiativeUpdatesFilterEncoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly length?: typeof NumberComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly some?: InitiativeUpdatesFilterEncoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Comparator for optional numbers. */ +export const NullableNumberComparator = Schema.Struct({ + /** Equals constraint. */ + eq: Schema.optional(Schema.NullOr(Float)), + /** Greater-than constraint. Matches any values that are greater than the given value. */ + gt: Schema.optional(Schema.NullOr(Float)), + /** Greater-than-or-equal constraint. Matches any values that are greater than or equal to the given value. */ + gte: Schema.optional(Schema.NullOr(Float)), + /** In-array constraint. */ + in: Schema.optional(Schema.NullOr(Schema.Array(Float))), + /** Less-than constraint. Matches any values that are less than the given value. */ + lt: Schema.optional(Schema.NullOr(Float)), + /** Less-than-or-equal constraint. Matches any values that are less than or equal to the given value. */ + lte: Schema.optional(Schema.NullOr(Float)), + /** Not-equals constraint. */ + neq: Schema.optional(Schema.NullOr(Float)), + /** Not-in-array constraint. */ + nin: Schema.optional(Schema.NullOr(Schema.Array(Float))), + /** Null constraint. Matches any non-null values if the given value is false, otherwise it matches null values. */ + null: Schema.optional(Schema.NullOr(Schema.Boolean)) +}) +export interface NullableNumberComparator extends Schema.Struct.Type {} + +/** Comparator for relation existence. */ +export const RelationExistsComparator = Schema.Struct({ + /** Equals constraint. */ + eq: Schema.optional(Schema.NullOr(Schema.Boolean)), + /** Not equals constraint. */ + neq: Schema.optional(Schema.NullOr(Schema.Boolean)) +}) +export interface RelationExistsComparator extends Schema.Struct.Type {} + +/** Reaction filtering options. */ +export const ReactionFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => ReactionFilter)))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + customEmojiId: Schema.optional(Schema.NullOr(IDComparator)), + emoji: Schema.optional(Schema.NullOr(StringComparator)), + id: Schema.optional(Schema.NullOr(IDComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => ReactionFilter)))), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface ReactionFilter { + /** Compound filters, all of which need to be matched by the reaction. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Comparator for the reactions custom emoji. */ + readonly customEmojiId?: IDComparator | null | undefined + /** Comparator for the reactions emoji. */ + readonly emoji?: StringComparator | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Compound filters, one of which need to be matched by the reaction. */ + readonly or?: ReadonlyArray | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface ReactionFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly customEmojiId?: typeof IDComparator.Encoded | null | undefined + readonly emoji?: typeof StringComparator.Encoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Reaction filtering options. */ +export const ReactionCollectionFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => ReactionCollectionFilter)))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + customEmojiId: Schema.optional(Schema.NullOr(IDComparator)), + emoji: Schema.optional(Schema.NullOr(StringComparator)), + every: Schema.optional(Schema.NullOr(ReactionFilter)), + id: Schema.optional(Schema.NullOr(IDComparator)), + length: Schema.optional(Schema.NullOr(NumberComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => ReactionCollectionFilter)))), + some: Schema.optional(Schema.NullOr(ReactionFilter)), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface ReactionCollectionFilter { + /** Compound filters, all of which need to be matched by the reaction. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Comparator for the reactions custom emoji. */ + readonly customEmojiId?: IDComparator | null | undefined + /** Comparator for the reactions emoji. */ + readonly emoji?: StringComparator | null | undefined + /** Filters that needs to be matched by all reactions. */ + readonly every?: ReactionFilter | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Comparator for the collection length. */ + readonly length?: NumberComparator | null | undefined + /** Compound filters, one of which need to be matched by the reaction. */ + readonly or?: ReadonlyArray | null | undefined + /** Filters that needs to be matched by some reactions. */ + readonly some?: ReactionFilter | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface ReactionCollectionFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly customEmojiId?: typeof IDComparator.Encoded | null | undefined + readonly emoji?: typeof StringComparator.Encoded | null | undefined + readonly every?: ReactionFilterEncoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly length?: typeof NumberComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly some?: ReactionFilterEncoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Comparator for optional timeless dates. */ +export const NullableTimelessDateComparator = Schema.Struct({ + /** Equals constraint. */ + eq: Schema.optional(Schema.NullOr(TimelessDateOrDuration)), + /** Greater-than constraint. Matches any values that are greater than the given value. */ + gt: Schema.optional(Schema.NullOr(TimelessDateOrDuration)), + /** Greater-than-or-equal constraint. Matches any values that are greater than or equal to the given value. */ + gte: Schema.optional(Schema.NullOr(TimelessDateOrDuration)), + /** In-array constraint. */ + in: Schema.optional(Schema.NullOr(Schema.Array(TimelessDateOrDuration))), + /** Less-than constraint. Matches any values that are less than the given value. */ + lt: Schema.optional(Schema.NullOr(TimelessDateOrDuration)), + /** Less-than-or-equal constraint. Matches any values that are less than or equal to the given value. */ + lte: Schema.optional(Schema.NullOr(TimelessDateOrDuration)), + /** Not-equals constraint. */ + neq: Schema.optional(Schema.NullOr(TimelessDateOrDuration)), + /** Not-in-array constraint. */ + nin: Schema.optional(Schema.NullOr(Schema.Array(TimelessDateOrDuration))), + /** Null constraint. Matches any non-null values if the given value is false, otherwise it matches null values. */ + null: Schema.optional(Schema.NullOr(Schema.Boolean)) +}) +export interface NullableTimelessDateComparator extends Schema.Struct.Type {} + +/** Comparator for estimates. */ +export const EstimateComparator = Schema.Struct({ + /** Compound filters, one of which need to be matched by the estimate. */ + and: Schema.optional(Schema.NullOr(Schema.Array(NullableNumberComparator))), + /** Equals constraint. */ + eq: Schema.optional(Schema.NullOr(Float)), + /** Greater-than constraint. Matches any values that are greater than the given value. */ + gt: Schema.optional(Schema.NullOr(Float)), + /** Greater-than-or-equal constraint. Matches any values that are greater than or equal to the given value. */ + gte: Schema.optional(Schema.NullOr(Float)), + /** In-array constraint. */ + in: Schema.optional(Schema.NullOr(Schema.Array(Float))), + /** Less-than constraint. Matches any values that are less than the given value. */ + lt: Schema.optional(Schema.NullOr(Float)), + /** Less-than-or-equal constraint. Matches any values that are less than or equal to the given value. */ + lte: Schema.optional(Schema.NullOr(Float)), + /** Not-equals constraint. */ + neq: Schema.optional(Schema.NullOr(Float)), + /** Not-in-array constraint. */ + nin: Schema.optional(Schema.NullOr(Schema.Array(Float))), + /** Null constraint. Matches any non-null values if the given value is false, otherwise it matches null values. */ + null: Schema.optional(Schema.NullOr(Schema.Boolean)), + /** Compound filters, all of which need to be matched by the estimate. */ + or: Schema.optional(Schema.NullOr(Schema.Array(NullableNumberComparator))) +}) +export interface EstimateComparator extends Schema.Struct.Type {} + +/** Comparator for issue identifiers. */ +export const IssueIDComparator = Schema.Struct({ + /** Equals constraint. */ + eq: Schema.optional(Schema.NullOr(ID)), + /** In-array constraint. */ + in: Schema.optional(Schema.NullOr(Schema.Array(ID))), + /** Not-equals constraint. */ + neq: Schema.optional(Schema.NullOr(ID)), + /** Not-in-array constraint. */ + nin: Schema.optional(Schema.NullOr(Schema.Array(ID))) +}) +export interface IssueIDComparator extends Schema.Struct.Type {} + +/** Comparator for release stage type. */ +export const ReleaseStageTypeComparator = Schema.Struct({ + /** Equals constraint. */ + eq: Schema.optional(Schema.NullOr(ReleaseStageType)), + /** In-array constraint. */ + in: Schema.optional(Schema.NullOr(Schema.Array(ReleaseStageType))), + /** Not-equals constraint. */ + neq: Schema.optional(Schema.NullOr(ReleaseStageType)), + /** Not-in-array constraint. */ + nin: Schema.optional(Schema.NullOr(Schema.Array(ReleaseStageType))), + /** Null constraint. Matches any non-null values if the given value is false, otherwise it matches null values. */ + null: Schema.optional(Schema.NullOr(Schema.Boolean)) +}) +export interface ReleaseStageTypeComparator extends Schema.Struct.Type {} + +/** Release stage filtering options. */ +export const ReleaseStageFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => ReleaseStageFilter)))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + id: Schema.optional(Schema.NullOr(IDComparator)), + name: Schema.optional(Schema.NullOr(StringComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => ReleaseStageFilter)))), + type: Schema.optional(Schema.NullOr(ReleaseStageTypeComparator)), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface ReleaseStageFilter { + /** Compound filters, all of which need to be matched by the stage. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Comparator for the stage name. */ + readonly name?: StringComparator | null | undefined + /** Compound filters, one of which need to be matched by the stage. */ + readonly or?: ReadonlyArray | null | undefined + /** Comparator for the stage type. */ + readonly type?: ReleaseStageTypeComparator | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface ReleaseStageFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly name?: typeof StringComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly type?: typeof ReleaseStageTypeComparator.Encoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** [Internal] Comparator for content. */ +export const ContentComparator = Schema.Struct({ + /** [Internal] Contains constraint. */ + contains: Schema.optional(Schema.NullOr(Schema.String)), + /** [Internal] Not-contains constraint. */ + notContains: Schema.optional(Schema.NullOr(Schema.String)) +}) +export interface ContentComparator extends Schema.Struct.Type {} + +/** Comparator for sla status. */ +export const SlaStatusComparator = Schema.Struct({ + /** Equals constraint. */ + eq: Schema.optional(Schema.NullOr(SlaStatus)), + /** In-array constraint. */ + in: Schema.optional(Schema.NullOr(Schema.Array(SlaStatus))), + /** Not-equals constraint. */ + neq: Schema.optional(Schema.NullOr(SlaStatus)), + /** Not-in-array constraint. */ + nin: Schema.optional(Schema.NullOr(Schema.Array(SlaStatus))), + /** Null constraint. Matches any non-null values if the given value is false, otherwise it matches null values. */ + null: Schema.optional(Schema.NullOr(Schema.Boolean)) +}) +export interface SlaStatusComparator extends Schema.Struct.Type {} + +/** [INTERNAL] Comparator for Salesforce metadata. */ +export const SalesforceMetadataIntegrationComparator = Schema.Struct({ + /** Salesforce Case metadata filter */ + caseMetadata: Schema.optional(Schema.NullOr(JSONObject)) +}) +export interface SalesforceMetadataIntegrationComparator extends Schema.Struct.Type {} + +/** Comparator for source type. */ +export const SubTypeComparator = Schema.Struct({ + /** Equals constraint. */ + eq: Schema.optional(Schema.NullOr(Schema.String)), + /** In-array constraint. */ + in: Schema.optional(Schema.NullOr(Schema.Array(Schema.String))), + /** Not-equals constraint. */ + neq: Schema.optional(Schema.NullOr(Schema.String)), + /** Not-in-array constraint. */ + nin: Schema.optional(Schema.NullOr(Schema.Array(Schema.String))), + /** Null constraint. Matches any non-null values if the given value is false, otherwise it matches null values. */ + null: Schema.optional(Schema.NullOr(Schema.Boolean)) +}) +export interface SubTypeComparator extends Schema.Struct.Type {} + +/** Comparator for the workflow definition that created an issue. */ +export const WorkflowDefinitionIdComparator = Schema.Struct({ + /** Equals constraint. */ + eq: Schema.optional(Schema.NullOr(ID)), + /** In-array constraint. */ + in: Schema.optional(Schema.NullOr(Schema.Array(ID))), + /** Not-equals constraint. */ + neq: Schema.optional(Schema.NullOr(ID)), + /** Not-in-array constraint. */ + nin: Schema.optional(Schema.NullOr(Schema.Array(ID))), + /** Null constraint. Matches any non-null values if the given value is false, otherwise it matches null values. */ + null: Schema.optional(Schema.NullOr(Schema.Boolean)) +}) +export interface WorkflowDefinitionIdComparator extends Schema.Struct.Type {} + +/** Comparator for issue source type. */ +export const SourceMetadataComparator = Schema.Struct({ + /** Null constraint. When true, matches issues without an external source: issues with no source metadata and issues created through the API, an OAuth application, or a loop. When false, matches issues created by an integration or an intake source such as email. */ + null: Schema.optional(Schema.NullOr(Schema.Boolean)), + /** [INTERNAL] Comparator for the salesforce metadata. */ + salesforceMetadata: Schema.optional(Schema.NullOr(SalesforceMetadataIntegrationComparator)), + /** Comparator for the sub type. */ + subType: Schema.optional(Schema.NullOr(SubTypeComparator)), + /** Comparator for the workflow definition that created the issue. */ + workflowDefinitionId: Schema.optional(Schema.NullOr(WorkflowDefinitionIdComparator)) +}) +export interface SourceMetadataComparator extends Schema.Struct.Type {} + +/** Options for filtering projects by project updates. */ +export const ProjectUpdatesFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => ProjectUpdatesFilter)))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + health: Schema.optional(Schema.NullOr(StringComparator)), + id: Schema.optional(Schema.NullOr(IDComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => ProjectUpdatesFilter)))), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface ProjectUpdatesFilter { + /** Compound filters, all of which need to be matched by the project updates. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Comparator for the project update health. */ + readonly health?: StringComparator | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Compound filters, one of which need to be matched by the project updates. */ + readonly or?: ReadonlyArray | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface ProjectUpdatesFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly health?: typeof StringComparator.Encoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Collection filtering options for filtering projects by project updates. */ +export const ProjectUpdatesCollectionFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => ProjectUpdatesCollectionFilter)))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + every: Schema.optional(Schema.NullOr(ProjectUpdatesFilter)), + health: Schema.optional(Schema.NullOr(StringComparator)), + id: Schema.optional(Schema.NullOr(IDComparator)), + length: Schema.optional(Schema.NullOr(NumberComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => ProjectUpdatesCollectionFilter)))), + some: Schema.optional(Schema.NullOr(ProjectUpdatesFilter)), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface ProjectUpdatesCollectionFilter { + /** Compound filters, all of which need to be matched by the project update. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Filters that needs to be matched by all updates. */ + readonly every?: ProjectUpdatesFilter | null | undefined + /** Comparator for the project update health. */ + readonly health?: StringComparator | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Comparator for the collection length. */ + readonly length?: NumberComparator | null | undefined + /** Compound filters, one of which need to be matched by the update. */ + readonly or?: ReadonlyArray | null | undefined + /** Filters that needs to be matched by some updates. */ + readonly some?: ProjectUpdatesFilter | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface ProjectUpdatesCollectionFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly every?: ProjectUpdatesFilterEncoded | null | undefined + readonly health?: typeof StringComparator.Encoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly length?: typeof NumberComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly some?: ProjectUpdatesFilterEncoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Comparator for strings in arrays. */ +export const StringItemComparator = Schema.Struct({ + /** Contains constraint. Matches any values that contain the given string. */ + contains: Schema.optional(Schema.NullOr(Schema.String)), + /** Contains case insensitive constraint. Matches any values that contain the given string case insensitive. */ + containsIgnoreCase: Schema.optional(Schema.NullOr(Schema.String)), + /** Contains case and accent insensitive constraint. Matches any values that contain the given string case and accent insensitive. */ + containsIgnoreCaseAndAccent: Schema.optional(Schema.NullOr(Schema.String)), + /** Ends with constraint. Matches any values that end with the given string. */ + endsWith: Schema.optional(Schema.NullOr(Schema.String)), + /** Equals constraint. */ + eq: Schema.optional(Schema.NullOr(Schema.String)), + /** Equals case insensitive. Matches any values that matches the given string case insensitive. */ + eqIgnoreCase: Schema.optional(Schema.NullOr(Schema.String)), + /** In-array constraint. */ + in: Schema.optional(Schema.NullOr(Schema.Array(Schema.String))), + /** Not-equals constraint. */ + neq: Schema.optional(Schema.NullOr(Schema.String)), + /** Not-equals case insensitive. Matches any values that don't match the given string case insensitive. */ + neqIgnoreCase: Schema.optional(Schema.NullOr(Schema.String)), + /** Not-in-array constraint. */ + nin: Schema.optional(Schema.NullOr(Schema.Array(Schema.String))), + /** Doesn't contain constraint. Matches any values that don't contain the given string. */ + notContains: Schema.optional(Schema.NullOr(Schema.String)), + /** Doesn't contain case insensitive constraint. Matches any values that don't contain the given string case insensitive. */ + notContainsIgnoreCase: Schema.optional(Schema.NullOr(Schema.String)), + /** Doesn't end with constraint. Matches any values that don't end with the given string. */ + notEndsWith: Schema.optional(Schema.NullOr(Schema.String)), + /** Doesn't start with constraint. Matches any values that don't start with the given string. */ + notStartsWith: Schema.optional(Schema.NullOr(Schema.String)), + /** Starts with constraint. Matches any values that start with the given string. */ + startsWith: Schema.optional(Schema.NullOr(Schema.String)), + /** Starts with case insensitive constraint. Matches any values that start with the given string. */ + startsWithIgnoreCase: Schema.optional(Schema.NullOr(Schema.String)) +}) +export interface StringItemComparator extends Schema.Struct.Type {} + +/** Comparator for strings. */ +export const StringArrayComparator = Schema.Struct({ + /** Compound filters, all of which need to be matched. */ + every: Schema.optional(Schema.NullOr(StringItemComparator)), + /** Length of the array. Matches any values that have the given length. */ + length: Schema.optional(Schema.NullOr(NumberComparator)), + /** Compound filters, one of which needs to be matched. */ + some: Schema.optional(Schema.NullOr(StringItemComparator)) +}) +export interface StringArrayComparator extends Schema.Struct.Type {} + +/** Customer status filtering options. */ +export const CustomerStatusFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => CustomerStatusFilter)))), + color: Schema.optional(Schema.NullOr(StringComparator)), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + description: Schema.optional(Schema.NullOr(StringComparator)), + id: Schema.optional(Schema.NullOr(IDComparator)), + name: Schema.optional(Schema.NullOr(StringComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => CustomerStatusFilter)))), + position: Schema.optional(Schema.NullOr(NumberComparator)), + type: Schema.optional(Schema.NullOr(StringComparator)), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface CustomerStatusFilter { + /** Compound filters, all of which need to be matched by the customer status. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the customer status color. */ + readonly color?: StringComparator | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Comparator for the customer status description. */ + readonly description?: StringComparator | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Comparator for the customer status name. */ + readonly name?: StringComparator | null | undefined + /** Compound filters, one of which needs to be matched by the customer status. */ + readonly or?: ReadonlyArray | null | undefined + /** Comparator for the customer status position. */ + readonly position?: NumberComparator | null | undefined + /** Comparator for the customer status type. */ + readonly type?: StringComparator | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface CustomerStatusFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly color?: typeof StringComparator.Encoded | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly description?: typeof StringComparator.Encoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly name?: typeof StringComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly position?: typeof NumberComparator.Encoded | null | undefined + readonly type?: typeof StringComparator.Encoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Customer tier filtering options. */ +export const CustomerTierFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => CustomerTierFilter)))), + color: Schema.optional(Schema.NullOr(StringComparator)), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + description: Schema.optional(Schema.NullOr(StringComparator)), + displayName: Schema.optional(Schema.NullOr(StringComparator)), + id: Schema.optional(Schema.NullOr(IDComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => CustomerTierFilter)))), + position: Schema.optional(Schema.NullOr(NumberComparator)), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface CustomerTierFilter { + /** Compound filters, all of which need to be matched by the customer tier. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the customer tier color. */ + readonly color?: StringComparator | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Comparator for the customer tier description. */ + readonly description?: StringComparator | null | undefined + /** Comparator for the customer tier display name. */ + readonly displayName?: StringComparator | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Compound filters, one of which needs to be matched by the customer tier. */ + readonly or?: ReadonlyArray | null | undefined + /** Comparator for the customer tier position. */ + readonly position?: NumberComparator | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface CustomerTierFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly color?: typeof StringComparator.Encoded | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly description?: typeof StringComparator.Encoded | null | undefined + readonly displayName?: typeof StringComparator.Encoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly position?: typeof NumberComparator.Encoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Issue filtering options. */ +export const IssueFilter: Schema.Codec = Schema.Struct({ + accumulatedStateUpdatedAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + activity: Schema.optional(Schema.NullOr(Schema.suspend(() => ActivityCollectionFilter))), + addedToCycleAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + addedToCyclePeriod: Schema.optional(Schema.NullOr(CyclePeriodComparator)), + ageTime: Schema.optional(Schema.NullOr(NullableDurationComparator)), + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => IssueFilter)))), + archivedAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + assignee: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableUserFilter))), + attachments: Schema.optional(Schema.NullOr(Schema.suspend(() => AttachmentCollectionFilter))), + autoArchivedAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + autoClosedAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + canceledAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + children: Schema.optional(Schema.NullOr(Schema.suspend(() => IssueCollectionFilter))), + comments: Schema.optional(Schema.NullOr(Schema.suspend(() => CommentCollectionFilter))), + completedAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + creator: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableUserFilter))), + customerCount: Schema.optional(Schema.NullOr(NumberComparator)), + customerImportantCount: Schema.optional(Schema.NullOr(NumberComparator)), + cycle: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableCycleFilter))), + cycleTime: Schema.optional(Schema.NullOr(NullableDurationComparator)), + delegate: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableUserFilter))), + description: Schema.optional(Schema.NullOr(NullableStringComparator)), + dueDate: Schema.optional(Schema.NullOr(NullableTimelessDateComparator)), + estimate: Schema.optional(Schema.NullOr(EstimateComparator)), + hasActiveAgentSessions: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasBlockedByRelations: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasBlockingRelations: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasDismissedAgentSessions: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasDuplicateRelations: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasErroredAgentSessions: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasMergedAgentPullRequests: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasRelatedRelations: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasSharedUsers: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasSuggestedAssignees: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasSuggestedLabels: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasSuggestedProjects: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasSuggestedRelatedIssues: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasSuggestedSimilarIssues: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasSuggestedTeams: Schema.optional(Schema.NullOr(RelationExistsComparator)), + id: Schema.optional(Schema.NullOr(IssueIDComparator)), + labels: Schema.optional(Schema.NullOr(Schema.suspend(() => IssueLabelCollectionFilter))), + lastAppliedTemplate: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableTemplateFilter))), + leadTime: Schema.optional(Schema.NullOr(NullableDurationComparator)), + needs: Schema.optional(Schema.NullOr(Schema.suspend(() => CustomerNeedCollectionFilter))), + number: Schema.optional(Schema.NullOr(NumberComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => IssueFilter)))), + parent: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableIssueFilter))), + priority: Schema.optional(Schema.NullOr(NullableNumberComparator)), + project: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableProjectFilter))), + projectMilestone: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableProjectMilestoneFilter))), + reactions: Schema.optional(Schema.NullOr(ReactionCollectionFilter)), + recurringIssueTemplate: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableTemplateFilter))), + releases: Schema.optional(Schema.NullOr(Schema.suspend(() => ReleaseCollectionFilter))), + searchableContent: Schema.optional(Schema.NullOr(ContentComparator)), + sharedWith: Schema.optional(Schema.NullOr(Schema.suspend(() => UserCollectionFilter))), + slaBreachesAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + slaStatus: Schema.optional(Schema.NullOr(SlaStatusComparator)), + snoozedBy: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableUserFilter))), + snoozedUntilAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + sourceMetadata: Schema.optional(Schema.NullOr(SourceMetadataComparator)), + startedAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + state: Schema.optional(Schema.NullOr(Schema.suspend(() => WorkflowStateFilter))), + subscribers: Schema.optional(Schema.NullOr(Schema.suspend(() => UserCollectionFilter))), + suggestions: Schema.optional(Schema.NullOr(Schema.suspend(() => IssueSuggestionCollectionFilter))), + team: Schema.optional(Schema.NullOr(Schema.suspend(() => TeamFilter))), + title: Schema.optional(Schema.NullOr(StringComparator)), + triageTime: Schema.optional(Schema.NullOr(NullableDurationComparator)), + triagedAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface IssueFilter { + /** [Internal] Comparator for the issue's accumulatedStateUpdatedAt date. */ + readonly accumulatedStateUpdatedAt?: NullableDateComparator | null | undefined + /** Filters that the issue's activities must satisfy. */ + readonly activity?: ActivityCollectionFilter | null | undefined + /** Comparator for the issues added to cycle at date. */ + readonly addedToCycleAt?: NullableDateComparator | null | undefined + /** Comparator for the period when issue was added to a cycle. */ + readonly addedToCyclePeriod?: CyclePeriodComparator | null | undefined + /** [Internal] Age (created -> now) comparator, defined if the issue is still open. */ + readonly ageTime?: NullableDurationComparator | null | undefined + /** Compound filters, all of which need to be matched by the issue. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the issues archived at date. */ + readonly archivedAt?: NullableDateComparator | null | undefined + /** Filters that the issues assignee must satisfy. */ + readonly assignee?: NullableUserFilter | null | undefined + /** Filters that the issues attachments must satisfy. */ + readonly attachments?: AttachmentCollectionFilter | null | undefined + /** Comparator for the issues auto archived at date. */ + readonly autoArchivedAt?: NullableDateComparator | null | undefined + /** Comparator for the issues auto closed at date. */ + readonly autoClosedAt?: NullableDateComparator | null | undefined + /** Comparator for the issues canceled at date. */ + readonly canceledAt?: NullableDateComparator | null | undefined + /** Filters that the child issues must satisfy. */ + readonly children?: IssueCollectionFilter | null | undefined + /** Filters that the issues comments must satisfy. */ + readonly comments?: CommentCollectionFilter | null | undefined + /** Comparator for the issues completed at date. */ + readonly completedAt?: NullableDateComparator | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Filters that the issues creator must satisfy. */ + readonly creator?: NullableUserFilter | null | undefined + /** Count of customers */ + readonly customerCount?: NumberComparator | null | undefined + /** Count of important customers */ + readonly customerImportantCount?: NumberComparator | null | undefined + /** Filters that the issues cycle must satisfy. */ + readonly cycle?: NullableCycleFilter | null | undefined + /** [Internal] Cycle time (started -> completed) comparator. */ + readonly cycleTime?: NullableDurationComparator | null | undefined + /** Filters that the issue's delegated agent must satisfy. */ + readonly delegate?: NullableUserFilter | null | undefined + /** Comparator for the issues description. */ + readonly description?: NullableStringComparator | null | undefined + /** Comparator for the issues due date. */ + readonly dueDate?: NullableTimelessDateComparator | null | undefined + /** Comparator for the issues estimate. */ + readonly estimate?: EstimateComparator | null | undefined + /** [Internal] Comparator for filtering issues bucketed as having active agent sessions, no closed agent pull requests, and no merged agent pull requests. */ + readonly hasActiveAgentSessions?: RelationExistsComparator | null | undefined + /** Comparator for filtering issues which are blocked. */ + readonly hasBlockedByRelations?: RelationExistsComparator | null | undefined + /** Comparator for filtering issues which are blocking. */ + readonly hasBlockingRelations?: RelationExistsComparator | null | undefined + /** [Internal] Comparator for filtering issues bucketed as having all agent sessions dismissed or closed, and no merged agent pull requests. */ + readonly hasDismissedAgentSessions?: RelationExistsComparator | null | undefined + /** Comparator for filtering issues which are duplicates. */ + readonly hasDuplicateRelations?: RelationExistsComparator | null | undefined + /** [Internal] Comparator for filtering issues bucketed as having an errored agent session, no active sessions, and no merged agent pull requests. */ + readonly hasErroredAgentSessions?: RelationExistsComparator | null | undefined + /** [Internal] Comparator for filtering issues which have agent-session-linked pull requests that were merged. */ + readonly hasMergedAgentPullRequests?: RelationExistsComparator | null | undefined + /** Comparator for filtering issues with relations. */ + readonly hasRelatedRelations?: RelationExistsComparator | null | undefined + /** Comparator for filtering issues which have been shared with users outside of the team. */ + readonly hasSharedUsers?: RelationExistsComparator | null | undefined + /** [Internal] Comparator for filtering issues which have suggested assignees. */ + readonly hasSuggestedAssignees?: RelationExistsComparator | null | undefined + /** [Internal] Comparator for filtering issues which have suggested labels. */ + readonly hasSuggestedLabels?: RelationExistsComparator | null | undefined + /** [Internal] Comparator for filtering issues which have suggested projects. */ + readonly hasSuggestedProjects?: RelationExistsComparator | null | undefined + /** [Internal] Comparator for filtering issues which have suggested related issues. */ + readonly hasSuggestedRelatedIssues?: RelationExistsComparator | null | undefined + /** [Internal] Comparator for filtering issues which have suggested similar issues. */ + readonly hasSuggestedSimilarIssues?: RelationExistsComparator | null | undefined + /** [Internal] Comparator for filtering issues which have suggested teams. */ + readonly hasSuggestedTeams?: RelationExistsComparator | null | undefined + /** Comparator for the identifier. */ + readonly id?: IssueIDComparator | null | undefined + /** Filters that issue labels must satisfy. */ + readonly labels?: IssueLabelCollectionFilter | null | undefined + /** Filters that the last applied template must satisfy. */ + readonly lastAppliedTemplate?: NullableTemplateFilter | null | undefined + /** [Internal] Lead time (created -> completed) comparator. */ + readonly leadTime?: NullableDurationComparator | null | undefined + /** Filters that the issue's customer needs must satisfy. */ + readonly needs?: CustomerNeedCollectionFilter | null | undefined + /** Comparator for the issues number. */ + readonly number?: NumberComparator | null | undefined + /** Compound filters, one of which need to be matched by the issue. */ + readonly or?: ReadonlyArray | null | undefined + /** Filters that the issue parent must satisfy. */ + readonly parent?: NullableIssueFilter | null | undefined + /** Comparator for the issues priority. 0 = No priority, 1 = Urgent, 2 = High, 3 = Medium, 4 = Low. */ + readonly priority?: NullableNumberComparator | null | undefined + /** Filters that the issues project must satisfy. */ + readonly project?: NullableProjectFilter | null | undefined + /** Filters that the issues project milestone must satisfy. */ + readonly projectMilestone?: NullableProjectMilestoneFilter | null | undefined + /** Filters that the issues reactions must satisfy. */ + readonly reactions?: ReactionCollectionFilter | null | undefined + /** [ALPHA] Filters that the recurring issue template must satisfy. */ + readonly recurringIssueTemplate?: NullableTemplateFilter | null | undefined + /** Filters that the issue's releases must satisfy. */ + readonly releases?: ReleaseCollectionFilter | null | undefined + /** [Internal] Comparator for the issues content. */ + readonly searchableContent?: ContentComparator | null | undefined + /** Filters that users the issue has been shared with must satisfy. */ + readonly sharedWith?: UserCollectionFilter | null | undefined + /** Comparator for the issue's SLA breach date. */ + readonly slaBreachesAt?: NullableDateComparator | null | undefined + /** Comparator for the issues sla status. */ + readonly slaStatus?: SlaStatusComparator | null | undefined + /** Filters that the issues snoozer must satisfy. */ + readonly snoozedBy?: NullableUserFilter | null | undefined + /** Comparator for the issues snoozed until date. */ + readonly snoozedUntilAt?: NullableDateComparator | null | undefined + /** Filters that the source must satisfy. */ + readonly sourceMetadata?: SourceMetadataComparator | null | undefined + /** Comparator for the issues started at date. */ + readonly startedAt?: NullableDateComparator | null | undefined + /** Filters that the issues state must satisfy. */ + readonly state?: WorkflowStateFilter | null | undefined + /** Filters that issue subscribers must satisfy. */ + readonly subscribers?: UserCollectionFilter | null | undefined + /** [Internal] Filters that the issue's suggestions must satisfy. */ + readonly suggestions?: IssueSuggestionCollectionFilter | null | undefined + /** Filters that the issues team must satisfy. */ + readonly team?: TeamFilter | null | undefined + /** Comparator for the issues title. */ + readonly title?: StringComparator | null | undefined + /** [Internal] Triage time (entered triaged -> triaged) comparator. */ + readonly triageTime?: NullableDurationComparator | null | undefined + /** Comparator for the issues triaged at date. */ + readonly triagedAt?: NullableDateComparator | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface IssueFilterEncoded { + readonly accumulatedStateUpdatedAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly activity?: ActivityCollectionFilterEncoded | null | undefined + readonly addedToCycleAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly addedToCyclePeriod?: typeof CyclePeriodComparator.Encoded | null | undefined + readonly ageTime?: typeof NullableDurationComparator.Encoded | null | undefined + readonly and?: ReadonlyArray | null | undefined + readonly archivedAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly assignee?: NullableUserFilterEncoded | null | undefined + readonly attachments?: AttachmentCollectionFilterEncoded | null | undefined + readonly autoArchivedAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly autoClosedAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly canceledAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly children?: IssueCollectionFilterEncoded | null | undefined + readonly comments?: CommentCollectionFilterEncoded | null | undefined + readonly completedAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly creator?: NullableUserFilterEncoded | null | undefined + readonly customerCount?: typeof NumberComparator.Encoded | null | undefined + readonly customerImportantCount?: typeof NumberComparator.Encoded | null | undefined + readonly cycle?: NullableCycleFilterEncoded | null | undefined + readonly cycleTime?: typeof NullableDurationComparator.Encoded | null | undefined + readonly delegate?: NullableUserFilterEncoded | null | undefined + readonly description?: typeof NullableStringComparator.Encoded | null | undefined + readonly dueDate?: typeof NullableTimelessDateComparator.Encoded | null | undefined + readonly estimate?: typeof EstimateComparator.Encoded | null | undefined + readonly hasActiveAgentSessions?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasBlockedByRelations?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasBlockingRelations?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasDismissedAgentSessions?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasDuplicateRelations?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasErroredAgentSessions?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasMergedAgentPullRequests?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasRelatedRelations?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasSharedUsers?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasSuggestedAssignees?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasSuggestedLabels?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasSuggestedProjects?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasSuggestedRelatedIssues?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasSuggestedSimilarIssues?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasSuggestedTeams?: typeof RelationExistsComparator.Encoded | null | undefined + readonly id?: typeof IssueIDComparator.Encoded | null | undefined + readonly labels?: IssueLabelCollectionFilterEncoded | null | undefined + readonly lastAppliedTemplate?: NullableTemplateFilterEncoded | null | undefined + readonly leadTime?: typeof NullableDurationComparator.Encoded | null | undefined + readonly needs?: CustomerNeedCollectionFilterEncoded | null | undefined + readonly number?: typeof NumberComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly parent?: NullableIssueFilterEncoded | null | undefined + readonly priority?: typeof NullableNumberComparator.Encoded | null | undefined + readonly project?: NullableProjectFilterEncoded | null | undefined + readonly projectMilestone?: NullableProjectMilestoneFilterEncoded | null | undefined + readonly reactions?: ReactionCollectionFilterEncoded | null | undefined + readonly recurringIssueTemplate?: NullableTemplateFilterEncoded | null | undefined + readonly releases?: ReleaseCollectionFilterEncoded | null | undefined + readonly searchableContent?: typeof ContentComparator.Encoded | null | undefined + readonly sharedWith?: UserCollectionFilterEncoded | null | undefined + readonly slaBreachesAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly slaStatus?: typeof SlaStatusComparator.Encoded | null | undefined + readonly snoozedBy?: NullableUserFilterEncoded | null | undefined + readonly snoozedUntilAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly sourceMetadata?: typeof SourceMetadataComparator.Encoded | null | undefined + readonly startedAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly state?: WorkflowStateFilterEncoded | null | undefined + readonly subscribers?: UserCollectionFilterEncoded | null | undefined + readonly suggestions?: IssueSuggestionCollectionFilterEncoded | null | undefined + readonly team?: TeamFilterEncoded | null | undefined + readonly title?: typeof StringComparator.Encoded | null | undefined + readonly triageTime?: typeof NullableDurationComparator.Encoded | null | undefined + readonly triagedAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Activity collection filtering options. */ +export const ActivityCollectionFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => ActivityCollectionFilter)))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + every: Schema.optional(Schema.NullOr(Schema.suspend(() => ActivityFilter))), + id: Schema.optional(Schema.NullOr(IDComparator)), + length: Schema.optional(Schema.NullOr(NumberComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => ActivityCollectionFilter)))), + some: Schema.optional(Schema.NullOr(Schema.suspend(() => ActivityFilter))), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)), + user: Schema.optional(Schema.NullOr(Schema.suspend(() => UserFilter))) +}) +export interface ActivityCollectionFilter { + /** Compound filters, all of which need to be matched by the activity. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Filters that needs to be matched by all activities. */ + readonly every?: ActivityFilter | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Comparator for the collection length. */ + readonly length?: NumberComparator | null | undefined + /** Compound filters, one of which need to be matched by the activity. */ + readonly or?: ReadonlyArray | null | undefined + /** Filters that needs to be matched by some activities. */ + readonly some?: ActivityFilter | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined + /** Filters that the activity's user must satisfy. */ + readonly user?: UserFilter | null | undefined +} +export interface ActivityCollectionFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly every?: ActivityFilterEncoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly length?: typeof NumberComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly some?: ActivityFilterEncoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined + readonly user?: UserFilterEncoded | null | undefined +} + +/** Activity filtering options. */ +export const ActivityFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => ActivityFilter)))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + id: Schema.optional(Schema.NullOr(IDComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => ActivityFilter)))), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)), + user: Schema.optional(Schema.NullOr(Schema.suspend(() => UserFilter))) +}) +export interface ActivityFilter { + /** Compound filters, all of which need to be matched by the activity. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Compound filters, one of which need to be matched by the activity. */ + readonly or?: ReadonlyArray | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined + /** Filters that the activity's user must satisfy. */ + readonly user?: UserFilter | null | undefined +} +export interface ActivityFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined + readonly user?: UserFilterEncoded | null | undefined +} + +/** User filtering options. */ +export const UserFilter: Schema.Codec = Schema.Struct({ + active: Schema.optional(Schema.NullOr(BooleanComparator)), + admin: Schema.optional(Schema.NullOr(BooleanComparator)), + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => UserFilter)))), + app: Schema.optional(Schema.NullOr(BooleanComparator)), + assignedIssues: Schema.optional(Schema.NullOr(Schema.suspend(() => IssueCollectionFilter))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + displayName: Schema.optional(Schema.NullOr(StringComparator)), + email: Schema.optional(Schema.NullOr(StringComparator)), + id: Schema.optional(Schema.NullOr(IDComparator)), + invited: Schema.optional(Schema.NullOr(BooleanComparator)), + isInvited: Schema.optional(Schema.NullOr(BooleanComparator)), + isMe: Schema.optional(Schema.NullOr(BooleanComparator)), + name: Schema.optional(Schema.NullOr(StringComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => UserFilter)))), + owner: Schema.optional(Schema.NullOr(BooleanComparator)), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface UserFilter { + /** Comparator for the user's activity status. */ + readonly active?: BooleanComparator | null | undefined + /** Comparator for the user's admin status. */ + readonly admin?: BooleanComparator | null | undefined + /** Compound filters, all of which need to be matched by the user. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the user's app status. */ + readonly app?: BooleanComparator | null | undefined + /** Filters that the users assigned issues must satisfy. */ + readonly assignedIssues?: IssueCollectionFilter | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Comparator for the user's display name. */ + readonly displayName?: StringComparator | null | undefined + /** Comparator for the user's email. */ + readonly email?: StringComparator | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Comparator for the user's invited status. */ + readonly invited?: BooleanComparator | null | undefined + /** Comparator for the user's invited status. */ + readonly isInvited?: BooleanComparator | null | undefined + /** Filter based on the currently authenticated user. Set to true to filter for the authenticated user, false for any other user. */ + readonly isMe?: BooleanComparator | null | undefined + /** Comparator for the user's name. */ + readonly name?: StringComparator | null | undefined + /** Compound filters, one of which need to be matched by the user. */ + readonly or?: ReadonlyArray | null | undefined + /** Comparator for the user's owner status. */ + readonly owner?: BooleanComparator | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface UserFilterEncoded { + readonly active?: typeof BooleanComparator.Encoded | null | undefined + readonly admin?: typeof BooleanComparator.Encoded | null | undefined + readonly and?: ReadonlyArray | null | undefined + readonly app?: typeof BooleanComparator.Encoded | null | undefined + readonly assignedIssues?: IssueCollectionFilterEncoded | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly displayName?: typeof StringComparator.Encoded | null | undefined + readonly email?: typeof StringComparator.Encoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly invited?: typeof BooleanComparator.Encoded | null | undefined + readonly isInvited?: typeof BooleanComparator.Encoded | null | undefined + readonly isMe?: typeof BooleanComparator.Encoded | null | undefined + readonly name?: typeof StringComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly owner?: typeof BooleanComparator.Encoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Issue filtering options. */ +export const IssueCollectionFilter: Schema.Codec = Schema.Struct({ + accumulatedStateUpdatedAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + activity: Schema.optional(Schema.NullOr(Schema.suspend(() => ActivityCollectionFilter))), + addedToCycleAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + addedToCyclePeriod: Schema.optional(Schema.NullOr(CyclePeriodComparator)), + ageTime: Schema.optional(Schema.NullOr(NullableDurationComparator)), + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => IssueCollectionFilter)))), + archivedAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + assignee: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableUserFilter))), + attachments: Schema.optional(Schema.NullOr(Schema.suspend(() => AttachmentCollectionFilter))), + autoArchivedAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + autoClosedAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + canceledAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + children: Schema.optional(Schema.NullOr(Schema.suspend(() => IssueCollectionFilter))), + comments: Schema.optional(Schema.NullOr(Schema.suspend(() => CommentCollectionFilter))), + completedAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + creator: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableUserFilter))), + customerCount: Schema.optional(Schema.NullOr(NumberComparator)), + customerImportantCount: Schema.optional(Schema.NullOr(NumberComparator)), + cycle: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableCycleFilter))), + cycleTime: Schema.optional(Schema.NullOr(NullableDurationComparator)), + delegate: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableUserFilter))), + description: Schema.optional(Schema.NullOr(NullableStringComparator)), + dueDate: Schema.optional(Schema.NullOr(NullableTimelessDateComparator)), + estimate: Schema.optional(Schema.NullOr(EstimateComparator)), + every: Schema.optional(Schema.NullOr(Schema.suspend(() => IssueFilter))), + hasActiveAgentSessions: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasBlockedByRelations: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasBlockingRelations: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasDismissedAgentSessions: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasDuplicateRelations: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasErroredAgentSessions: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasMergedAgentPullRequests: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasRelatedRelations: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasSharedUsers: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasSuggestedAssignees: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasSuggestedLabels: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasSuggestedProjects: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasSuggestedRelatedIssues: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasSuggestedSimilarIssues: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasSuggestedTeams: Schema.optional(Schema.NullOr(RelationExistsComparator)), + id: Schema.optional(Schema.NullOr(IssueIDComparator)), + labels: Schema.optional(Schema.NullOr(Schema.suspend(() => IssueLabelCollectionFilter))), + lastAppliedTemplate: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableTemplateFilter))), + leadTime: Schema.optional(Schema.NullOr(NullableDurationComparator)), + length: Schema.optional(Schema.NullOr(NumberComparator)), + needs: Schema.optional(Schema.NullOr(Schema.suspend(() => CustomerNeedCollectionFilter))), + number: Schema.optional(Schema.NullOr(NumberComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => IssueCollectionFilter)))), + parent: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableIssueFilter))), + priority: Schema.optional(Schema.NullOr(NullableNumberComparator)), + project: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableProjectFilter))), + projectMilestone: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableProjectMilestoneFilter))), + reactions: Schema.optional(Schema.NullOr(ReactionCollectionFilter)), + recurringIssueTemplate: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableTemplateFilter))), + releases: Schema.optional(Schema.NullOr(Schema.suspend(() => ReleaseCollectionFilter))), + searchableContent: Schema.optional(Schema.NullOr(ContentComparator)), + sharedWith: Schema.optional(Schema.NullOr(Schema.suspend(() => UserCollectionFilter))), + slaBreachesAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + slaStatus: Schema.optional(Schema.NullOr(SlaStatusComparator)), + snoozedBy: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableUserFilter))), + snoozedUntilAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + some: Schema.optional(Schema.NullOr(Schema.suspend(() => IssueFilter))), + sourceMetadata: Schema.optional(Schema.NullOr(SourceMetadataComparator)), + startedAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + state: Schema.optional(Schema.NullOr(Schema.suspend(() => WorkflowStateFilter))), + subscribers: Schema.optional(Schema.NullOr(Schema.suspend(() => UserCollectionFilter))), + suggestions: Schema.optional(Schema.NullOr(Schema.suspend(() => IssueSuggestionCollectionFilter))), + team: Schema.optional(Schema.NullOr(Schema.suspend(() => TeamFilter))), + title: Schema.optional(Schema.NullOr(StringComparator)), + triageTime: Schema.optional(Schema.NullOr(NullableDurationComparator)), + triagedAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface IssueCollectionFilter { + /** [Internal] Comparator for the issue's accumulatedStateUpdatedAt date. */ + readonly accumulatedStateUpdatedAt?: NullableDateComparator | null | undefined + /** Filters that the issue's activities must satisfy. */ + readonly activity?: ActivityCollectionFilter | null | undefined + /** Comparator for the issues added to cycle at date. */ + readonly addedToCycleAt?: NullableDateComparator | null | undefined + /** Comparator for the period when issue was added to a cycle. */ + readonly addedToCyclePeriod?: CyclePeriodComparator | null | undefined + /** [Internal] Age (created -> now) comparator, defined if the issue is still open. */ + readonly ageTime?: NullableDurationComparator | null | undefined + /** Compound filters, all of which need to be matched by the issue. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the issues archived at date. */ + readonly archivedAt?: NullableDateComparator | null | undefined + /** Filters that the issues assignee must satisfy. */ + readonly assignee?: NullableUserFilter | null | undefined + /** Filters that the issues attachments must satisfy. */ + readonly attachments?: AttachmentCollectionFilter | null | undefined + /** Comparator for the issues auto archived at date. */ + readonly autoArchivedAt?: NullableDateComparator | null | undefined + /** Comparator for the issues auto closed at date. */ + readonly autoClosedAt?: NullableDateComparator | null | undefined + /** Comparator for the issues canceled at date. */ + readonly canceledAt?: NullableDateComparator | null | undefined + /** Filters that the child issues must satisfy. */ + readonly children?: IssueCollectionFilter | null | undefined + /** Filters that the issues comments must satisfy. */ + readonly comments?: CommentCollectionFilter | null | undefined + /** Comparator for the issues completed at date. */ + readonly completedAt?: NullableDateComparator | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Filters that the issues creator must satisfy. */ + readonly creator?: NullableUserFilter | null | undefined + /** Count of customers */ + readonly customerCount?: NumberComparator | null | undefined + /** Count of important customers */ + readonly customerImportantCount?: NumberComparator | null | undefined + /** Filters that the issues cycle must satisfy. */ + readonly cycle?: NullableCycleFilter | null | undefined + /** [Internal] Cycle time (started -> completed) comparator. */ + readonly cycleTime?: NullableDurationComparator | null | undefined + /** Filters that the issue's delegated agent must satisfy. */ + readonly delegate?: NullableUserFilter | null | undefined + /** Comparator for the issues description. */ + readonly description?: NullableStringComparator | null | undefined + /** Comparator for the issues due date. */ + readonly dueDate?: NullableTimelessDateComparator | null | undefined + /** Comparator for the issues estimate. */ + readonly estimate?: EstimateComparator | null | undefined + /** Filters that needs to be matched by all issues. */ + readonly every?: IssueFilter | null | undefined + /** [Internal] Comparator for filtering issues bucketed as having active agent sessions, no closed agent pull requests, and no merged agent pull requests. */ + readonly hasActiveAgentSessions?: RelationExistsComparator | null | undefined + /** Comparator for filtering issues which are blocked. */ + readonly hasBlockedByRelations?: RelationExistsComparator | null | undefined + /** Comparator for filtering issues which are blocking. */ + readonly hasBlockingRelations?: RelationExistsComparator | null | undefined + /** [Internal] Comparator for filtering issues bucketed as having all agent sessions dismissed or closed, and no merged agent pull requests. */ + readonly hasDismissedAgentSessions?: RelationExistsComparator | null | undefined + /** Comparator for filtering issues which are duplicates. */ + readonly hasDuplicateRelations?: RelationExistsComparator | null | undefined + /** [Internal] Comparator for filtering issues bucketed as having an errored agent session, no active sessions, and no merged agent pull requests. */ + readonly hasErroredAgentSessions?: RelationExistsComparator | null | undefined + /** [Internal] Comparator for filtering issues which have agent-session-linked pull requests that were merged. */ + readonly hasMergedAgentPullRequests?: RelationExistsComparator | null | undefined + /** Comparator for filtering issues with relations. */ + readonly hasRelatedRelations?: RelationExistsComparator | null | undefined + /** Comparator for filtering issues which have been shared with users outside of the team. */ + readonly hasSharedUsers?: RelationExistsComparator | null | undefined + /** [Internal] Comparator for filtering issues which have suggested assignees. */ + readonly hasSuggestedAssignees?: RelationExistsComparator | null | undefined + /** [Internal] Comparator for filtering issues which have suggested labels. */ + readonly hasSuggestedLabels?: RelationExistsComparator | null | undefined + /** [Internal] Comparator for filtering issues which have suggested projects. */ + readonly hasSuggestedProjects?: RelationExistsComparator | null | undefined + /** [Internal] Comparator for filtering issues which have suggested related issues. */ + readonly hasSuggestedRelatedIssues?: RelationExistsComparator | null | undefined + /** [Internal] Comparator for filtering issues which have suggested similar issues. */ + readonly hasSuggestedSimilarIssues?: RelationExistsComparator | null | undefined + /** [Internal] Comparator for filtering issues which have suggested teams. */ + readonly hasSuggestedTeams?: RelationExistsComparator | null | undefined + /** Comparator for the identifier. */ + readonly id?: IssueIDComparator | null | undefined + /** Filters that issue labels must satisfy. */ + readonly labels?: IssueLabelCollectionFilter | null | undefined + /** Filters that the last applied template must satisfy. */ + readonly lastAppliedTemplate?: NullableTemplateFilter | null | undefined + /** [Internal] Lead time (created -> completed) comparator. */ + readonly leadTime?: NullableDurationComparator | null | undefined + /** Comparator for the collection length. */ + readonly length?: NumberComparator | null | undefined + /** Filters that the issue's customer needs must satisfy. */ + readonly needs?: CustomerNeedCollectionFilter | null | undefined + /** Comparator for the issues number. */ + readonly number?: NumberComparator | null | undefined + /** Compound filters, one of which need to be matched by the issue. */ + readonly or?: ReadonlyArray | null | undefined + /** Filters that the issue parent must satisfy. */ + readonly parent?: NullableIssueFilter | null | undefined + /** Comparator for the issues priority. 0 = No priority, 1 = Urgent, 2 = High, 3 = Medium, 4 = Low. */ + readonly priority?: NullableNumberComparator | null | undefined + /** Filters that the issues project must satisfy. */ + readonly project?: NullableProjectFilter | null | undefined + /** Filters that the issues project milestone must satisfy. */ + readonly projectMilestone?: NullableProjectMilestoneFilter | null | undefined + /** Filters that the issues reactions must satisfy. */ + readonly reactions?: ReactionCollectionFilter | null | undefined + /** [ALPHA] Filters that the recurring issue template must satisfy. */ + readonly recurringIssueTemplate?: NullableTemplateFilter | null | undefined + /** Filters that the issue's releases must satisfy. */ + readonly releases?: ReleaseCollectionFilter | null | undefined + /** [Internal] Comparator for the issues content. */ + readonly searchableContent?: ContentComparator | null | undefined + /** Filters that users the issue has been shared with must satisfy. */ + readonly sharedWith?: UserCollectionFilter | null | undefined + /** Comparator for the issue's SLA breach date. */ + readonly slaBreachesAt?: NullableDateComparator | null | undefined + /** Comparator for the issues sla status. */ + readonly slaStatus?: SlaStatusComparator | null | undefined + /** Filters that the issues snoozer must satisfy. */ + readonly snoozedBy?: NullableUserFilter | null | undefined + /** Comparator for the issues snoozed until date. */ + readonly snoozedUntilAt?: NullableDateComparator | null | undefined + /** Filters that needs to be matched by some issues. */ + readonly some?: IssueFilter | null | undefined + /** Filters that the source must satisfy. */ + readonly sourceMetadata?: SourceMetadataComparator | null | undefined + /** Comparator for the issues started at date. */ + readonly startedAt?: NullableDateComparator | null | undefined + /** Filters that the issues state must satisfy. */ + readonly state?: WorkflowStateFilter | null | undefined + /** Filters that issue subscribers must satisfy. */ + readonly subscribers?: UserCollectionFilter | null | undefined + /** [Internal] Filters that the issue's suggestions must satisfy. */ + readonly suggestions?: IssueSuggestionCollectionFilter | null | undefined + /** Filters that the issues team must satisfy. */ + readonly team?: TeamFilter | null | undefined + /** Comparator for the issues title. */ + readonly title?: StringComparator | null | undefined + /** [Internal] Triage time (entered triaged -> triaged) comparator. */ + readonly triageTime?: NullableDurationComparator | null | undefined + /** Comparator for the issues triaged at date. */ + readonly triagedAt?: NullableDateComparator | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface IssueCollectionFilterEncoded { + readonly accumulatedStateUpdatedAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly activity?: ActivityCollectionFilterEncoded | null | undefined + readonly addedToCycleAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly addedToCyclePeriod?: typeof CyclePeriodComparator.Encoded | null | undefined + readonly ageTime?: typeof NullableDurationComparator.Encoded | null | undefined + readonly and?: ReadonlyArray | null | undefined + readonly archivedAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly assignee?: NullableUserFilterEncoded | null | undefined + readonly attachments?: AttachmentCollectionFilterEncoded | null | undefined + readonly autoArchivedAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly autoClosedAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly canceledAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly children?: IssueCollectionFilterEncoded | null | undefined + readonly comments?: CommentCollectionFilterEncoded | null | undefined + readonly completedAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly creator?: NullableUserFilterEncoded | null | undefined + readonly customerCount?: typeof NumberComparator.Encoded | null | undefined + readonly customerImportantCount?: typeof NumberComparator.Encoded | null | undefined + readonly cycle?: NullableCycleFilterEncoded | null | undefined + readonly cycleTime?: typeof NullableDurationComparator.Encoded | null | undefined + readonly delegate?: NullableUserFilterEncoded | null | undefined + readonly description?: typeof NullableStringComparator.Encoded | null | undefined + readonly dueDate?: typeof NullableTimelessDateComparator.Encoded | null | undefined + readonly estimate?: typeof EstimateComparator.Encoded | null | undefined + readonly every?: IssueFilterEncoded | null | undefined + readonly hasActiveAgentSessions?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasBlockedByRelations?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasBlockingRelations?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasDismissedAgentSessions?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasDuplicateRelations?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasErroredAgentSessions?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasMergedAgentPullRequests?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasRelatedRelations?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasSharedUsers?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasSuggestedAssignees?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasSuggestedLabels?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasSuggestedProjects?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasSuggestedRelatedIssues?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasSuggestedSimilarIssues?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasSuggestedTeams?: typeof RelationExistsComparator.Encoded | null | undefined + readonly id?: typeof IssueIDComparator.Encoded | null | undefined + readonly labels?: IssueLabelCollectionFilterEncoded | null | undefined + readonly lastAppliedTemplate?: NullableTemplateFilterEncoded | null | undefined + readonly leadTime?: typeof NullableDurationComparator.Encoded | null | undefined + readonly length?: typeof NumberComparator.Encoded | null | undefined + readonly needs?: CustomerNeedCollectionFilterEncoded | null | undefined + readonly number?: typeof NumberComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly parent?: NullableIssueFilterEncoded | null | undefined + readonly priority?: typeof NullableNumberComparator.Encoded | null | undefined + readonly project?: NullableProjectFilterEncoded | null | undefined + readonly projectMilestone?: NullableProjectMilestoneFilterEncoded | null | undefined + readonly reactions?: ReactionCollectionFilterEncoded | null | undefined + readonly recurringIssueTemplate?: NullableTemplateFilterEncoded | null | undefined + readonly releases?: ReleaseCollectionFilterEncoded | null | undefined + readonly searchableContent?: typeof ContentComparator.Encoded | null | undefined + readonly sharedWith?: UserCollectionFilterEncoded | null | undefined + readonly slaBreachesAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly slaStatus?: typeof SlaStatusComparator.Encoded | null | undefined + readonly snoozedBy?: NullableUserFilterEncoded | null | undefined + readonly snoozedUntilAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly some?: IssueFilterEncoded | null | undefined + readonly sourceMetadata?: typeof SourceMetadataComparator.Encoded | null | undefined + readonly startedAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly state?: WorkflowStateFilterEncoded | null | undefined + readonly subscribers?: UserCollectionFilterEncoded | null | undefined + readonly suggestions?: IssueSuggestionCollectionFilterEncoded | null | undefined + readonly team?: TeamFilterEncoded | null | undefined + readonly title?: typeof StringComparator.Encoded | null | undefined + readonly triageTime?: typeof NullableDurationComparator.Encoded | null | undefined + readonly triagedAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** User filtering options. */ +export const NullableUserFilter: Schema.Codec = Schema.Struct({ + active: Schema.optional(Schema.NullOr(BooleanComparator)), + admin: Schema.optional(Schema.NullOr(BooleanComparator)), + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => NullableUserFilter)))), + app: Schema.optional(Schema.NullOr(BooleanComparator)), + assignedIssues: Schema.optional(Schema.NullOr(Schema.suspend(() => IssueCollectionFilter))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + displayName: Schema.optional(Schema.NullOr(StringComparator)), + email: Schema.optional(Schema.NullOr(StringComparator)), + id: Schema.optional(Schema.NullOr(IDComparator)), + invited: Schema.optional(Schema.NullOr(BooleanComparator)), + isInvited: Schema.optional(Schema.NullOr(BooleanComparator)), + isMe: Schema.optional(Schema.NullOr(BooleanComparator)), + name: Schema.optional(Schema.NullOr(StringComparator)), + null: Schema.optional(Schema.NullOr(Schema.Boolean)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => NullableUserFilter)))), + owner: Schema.optional(Schema.NullOr(BooleanComparator)), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface NullableUserFilter { + /** Comparator for the user's activity status. */ + readonly active?: BooleanComparator | null | undefined + /** Comparator for the user's admin status. */ + readonly admin?: BooleanComparator | null | undefined + /** Compound filters, all of which need to be matched by the user. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the user's app status. */ + readonly app?: BooleanComparator | null | undefined + /** Filters that the users assigned issues must satisfy. */ + readonly assignedIssues?: IssueCollectionFilter | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Comparator for the user's display name. */ + readonly displayName?: StringComparator | null | undefined + /** Comparator for the user's email. */ + readonly email?: StringComparator | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Comparator for the user's invited status. */ + readonly invited?: BooleanComparator | null | undefined + /** Comparator for the user's invited status. */ + readonly isInvited?: BooleanComparator | null | undefined + /** Filter based on the currently authenticated user. Set to true to filter for the authenticated user, false for any other user. */ + readonly isMe?: BooleanComparator | null | undefined + /** Comparator for the user's name. */ + readonly name?: StringComparator | null | undefined + /** Filter based on the existence of the relation. */ + readonly null?: boolean | null | undefined + /** Compound filters, one of which need to be matched by the user. */ + readonly or?: ReadonlyArray | null | undefined + /** Comparator for the user's owner status. */ + readonly owner?: BooleanComparator | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface NullableUserFilterEncoded { + readonly active?: typeof BooleanComparator.Encoded | null | undefined + readonly admin?: typeof BooleanComparator.Encoded | null | undefined + readonly and?: ReadonlyArray | null | undefined + readonly app?: typeof BooleanComparator.Encoded | null | undefined + readonly assignedIssues?: IssueCollectionFilterEncoded | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly displayName?: typeof StringComparator.Encoded | null | undefined + readonly email?: typeof StringComparator.Encoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly invited?: typeof BooleanComparator.Encoded | null | undefined + readonly isInvited?: typeof BooleanComparator.Encoded | null | undefined + readonly isMe?: typeof BooleanComparator.Encoded | null | undefined + readonly name?: typeof StringComparator.Encoded | null | undefined + readonly null?: boolean | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly owner?: typeof BooleanComparator.Encoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Attachment collection filtering options. */ +export const AttachmentCollectionFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => AttachmentCollectionFilter)))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + creator: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableUserFilter))), + every: Schema.optional(Schema.NullOr(Schema.suspend(() => AttachmentFilter))), + id: Schema.optional(Schema.NullOr(IDComparator)), + length: Schema.optional(Schema.NullOr(NumberComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => AttachmentCollectionFilter)))), + some: Schema.optional(Schema.NullOr(Schema.suspend(() => AttachmentFilter))), + sourceType: Schema.optional(Schema.NullOr(SourceTypeComparator)), + subtitle: Schema.optional(Schema.NullOr(NullableStringComparator)), + title: Schema.optional(Schema.NullOr(StringComparator)), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)), + url: Schema.optional(Schema.NullOr(StringComparator)) +}) +export interface AttachmentCollectionFilter { + /** Compound filters, all of which need to be matched by the attachment. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Filters that the attachments creator must satisfy. */ + readonly creator?: NullableUserFilter | null | undefined + /** Filters that needs to be matched by all attachments. */ + readonly every?: AttachmentFilter | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Comparator for the collection length. */ + readonly length?: NumberComparator | null | undefined + /** Compound filters, one of which need to be matched by the attachment. */ + readonly or?: ReadonlyArray | null | undefined + /** Filters that needs to be matched by some attachments. */ + readonly some?: AttachmentFilter | null | undefined + /** Comparator for the source type. */ + readonly sourceType?: SourceTypeComparator | null | undefined + /** Comparator for the subtitle. */ + readonly subtitle?: NullableStringComparator | null | undefined + /** Comparator for the title. */ + readonly title?: StringComparator | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined + /** Comparator for the url. */ + readonly url?: StringComparator | null | undefined +} +export interface AttachmentCollectionFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly creator?: NullableUserFilterEncoded | null | undefined + readonly every?: AttachmentFilterEncoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly length?: typeof NumberComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly some?: AttachmentFilterEncoded | null | undefined + readonly sourceType?: typeof SourceTypeComparator.Encoded | null | undefined + readonly subtitle?: typeof NullableStringComparator.Encoded | null | undefined + readonly title?: typeof StringComparator.Encoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined + readonly url?: typeof StringComparator.Encoded | null | undefined +} + +/** Attachment filtering options. */ +export const AttachmentFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => AttachmentFilter)))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + creator: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableUserFilter))), + id: Schema.optional(Schema.NullOr(IDComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => AttachmentFilter)))), + sourceType: Schema.optional(Schema.NullOr(SourceTypeComparator)), + subtitle: Schema.optional(Schema.NullOr(NullableStringComparator)), + title: Schema.optional(Schema.NullOr(StringComparator)), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)), + url: Schema.optional(Schema.NullOr(StringComparator)) +}) +export interface AttachmentFilter { + /** Compound filters, all of which need to be matched by the attachment. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Filters that the attachments creator must satisfy. */ + readonly creator?: NullableUserFilter | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Compound filters, one of which need to be matched by the attachment. */ + readonly or?: ReadonlyArray | null | undefined + /** Comparator for the source type. */ + readonly sourceType?: SourceTypeComparator | null | undefined + /** Comparator for the subtitle. */ + readonly subtitle?: NullableStringComparator | null | undefined + /** Comparator for the title. */ + readonly title?: StringComparator | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined + /** Comparator for the url. */ + readonly url?: StringComparator | null | undefined +} +export interface AttachmentFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly creator?: NullableUserFilterEncoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly sourceType?: typeof SourceTypeComparator.Encoded | null | undefined + readonly subtitle?: typeof NullableStringComparator.Encoded | null | undefined + readonly title?: typeof StringComparator.Encoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined + readonly url?: typeof StringComparator.Encoded | null | undefined +} + +/** Comment filtering options. */ +export const CommentCollectionFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => CommentCollectionFilter)))), + body: Schema.optional(Schema.NullOr(StringComparator)), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + documentContent: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableDocumentContentFilter))), + every: Schema.optional(Schema.NullOr(Schema.suspend(() => CommentFilter))), + id: Schema.optional(Schema.NullOr(IDComparator)), + initiative: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableInitiativeFilter))), + initiativeUpdate: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableInitiativeUpdateFilter))), + issue: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableIssueFilter))), + length: Schema.optional(Schema.NullOr(NumberComparator)), + needs: Schema.optional(Schema.NullOr(Schema.suspend(() => CustomerNeedCollectionFilter))), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => CommentCollectionFilter)))), + parent: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableCommentFilter))), + project: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableProjectFilter))), + projectUpdate: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableProjectUpdateFilter))), + reactions: Schema.optional(Schema.NullOr(ReactionCollectionFilter)), + some: Schema.optional(Schema.NullOr(Schema.suspend(() => CommentFilter))), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)), + user: Schema.optional(Schema.NullOr(Schema.suspend(() => UserFilter))) +}) +export interface CommentCollectionFilter { + /** Compound filters, all of which need to be matched by the comment. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the comment's body. */ + readonly body?: StringComparator | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Filters that the comment's document content must satisfy. */ + readonly documentContent?: NullableDocumentContentFilter | null | undefined + /** Filters that needs to be matched by all comments. */ + readonly every?: CommentFilter | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** [Internal] Filters that the comment's initiative must satisfy. */ + readonly initiative?: NullableInitiativeFilter | null | undefined + /** Filters that the comment's initiative update must satisfy. */ + readonly initiativeUpdate?: NullableInitiativeUpdateFilter | null | undefined + /** Filters that the comment's issue must satisfy. */ + readonly issue?: NullableIssueFilter | null | undefined + /** Comparator for the collection length. */ + readonly length?: NumberComparator | null | undefined + /** Filters that the comment's customer needs must satisfy. */ + readonly needs?: CustomerNeedCollectionFilter | null | undefined + /** Compound filters, one of which need to be matched by the comment. */ + readonly or?: ReadonlyArray | null | undefined + /** Filters that the comment parent must satisfy. */ + readonly parent?: NullableCommentFilter | null | undefined + /** [Internal] Filters that the comment's project must satisfy. */ + readonly project?: NullableProjectFilter | null | undefined + /** Filters that the comment's project update must satisfy. */ + readonly projectUpdate?: NullableProjectUpdateFilter | null | undefined + /** Filters that the comment's reactions must satisfy. */ + readonly reactions?: ReactionCollectionFilter | null | undefined + /** Filters that needs to be matched by some comments. */ + readonly some?: CommentFilter | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined + /** Filters that the comment's creator must satisfy. */ + readonly user?: UserFilter | null | undefined +} +export interface CommentCollectionFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly body?: typeof StringComparator.Encoded | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly documentContent?: NullableDocumentContentFilterEncoded | null | undefined + readonly every?: CommentFilterEncoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly initiative?: NullableInitiativeFilterEncoded | null | undefined + readonly initiativeUpdate?: NullableInitiativeUpdateFilterEncoded | null | undefined + readonly issue?: NullableIssueFilterEncoded | null | undefined + readonly length?: typeof NumberComparator.Encoded | null | undefined + readonly needs?: CustomerNeedCollectionFilterEncoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly parent?: NullableCommentFilterEncoded | null | undefined + readonly project?: NullableProjectFilterEncoded | null | undefined + readonly projectUpdate?: NullableProjectUpdateFilterEncoded | null | undefined + readonly reactions?: ReactionCollectionFilterEncoded | null | undefined + readonly some?: CommentFilterEncoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined + readonly user?: UserFilterEncoded | null | undefined +} + +/** Document content filtering options. */ +export const NullableDocumentContentFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => NullableDocumentContentFilter)))), + content: Schema.optional(Schema.NullOr(NullableStringComparator)), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + document: Schema.optional(Schema.NullOr(Schema.suspend(() => DocumentFilter))), + id: Schema.optional(Schema.NullOr(IDComparator)), + initiative: Schema.optional(Schema.NullOr(Schema.suspend(() => InitiativeFilter))), + issue: Schema.optional(Schema.NullOr(Schema.suspend(() => IssueFilter))), + null: Schema.optional(Schema.NullOr(Schema.Boolean)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => NullableDocumentContentFilter)))), + project: Schema.optional(Schema.NullOr(Schema.suspend(() => ProjectFilter))), + projectMilestone: Schema.optional(Schema.NullOr(Schema.suspend(() => ProjectMilestoneFilter))), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface NullableDocumentContentFilter { + /** Compound filters, all of which need to be matched by the user. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the document content. */ + readonly content?: NullableStringComparator | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Filters that the document content document must satisfy. */ + readonly document?: DocumentFilter | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Filters that the document content initiative must satisfy. */ + readonly initiative?: InitiativeFilter | null | undefined + /** Filters that the document content issue must satisfy. */ + readonly issue?: IssueFilter | null | undefined + /** Filter based on the existence of the relation. */ + readonly null?: boolean | null | undefined + /** Compound filters, one of which need to be matched by the user. */ + readonly or?: ReadonlyArray | null | undefined + /** Filters that the document content project must satisfy. */ + readonly project?: ProjectFilter | null | undefined + /** Filters that the document content project milestone must satisfy. */ + readonly projectMilestone?: ProjectMilestoneFilter | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface NullableDocumentContentFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly content?: typeof NullableStringComparator.Encoded | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly document?: DocumentFilterEncoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly initiative?: InitiativeFilterEncoded | null | undefined + readonly issue?: IssueFilterEncoded | null | undefined + readonly null?: boolean | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly project?: ProjectFilterEncoded | null | undefined + readonly projectMilestone?: ProjectMilestoneFilterEncoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Document filtering options. */ +export const DocumentFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => DocumentFilter)))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + creator: Schema.optional(Schema.NullOr(Schema.suspend(() => UserFilter))), + cycle: Schema.optional(Schema.NullOr(Schema.suspend(() => CycleFilter))), + id: Schema.optional(Schema.NullOr(IDComparator)), + initiative: Schema.optional(Schema.NullOr(Schema.suspend(() => InitiativeFilter))), + issue: Schema.optional(Schema.NullOr(Schema.suspend(() => IssueFilter))), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => DocumentFilter)))), + owner: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableUserFilter))), + project: Schema.optional(Schema.NullOr(Schema.suspend(() => ProjectFilter))), + release: Schema.optional(Schema.NullOr(Schema.suspend(() => ReleaseFilter))), + searchableContent: Schema.optional(Schema.NullOr(ContentComparator)), + slugId: Schema.optional(Schema.NullOr(StringComparator)), + team: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableTeamFilter))), + title: Schema.optional(Schema.NullOr(StringComparator)), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface DocumentFilter { + /** Compound filters, all of which need to be matched by the document. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Filters that the document's creator must satisfy. */ + readonly creator?: UserFilter | null | undefined + /** Filters that the document's cycle must satisfy. */ + readonly cycle?: CycleFilter | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Filters that the document's initiative must satisfy. */ + readonly initiative?: InitiativeFilter | null | undefined + /** Filters that the document's issue must satisfy. */ + readonly issue?: IssueFilter | null | undefined + /** Compound filters, one of which need to be matched by the document. */ + readonly or?: ReadonlyArray | null | undefined + /** Filters that the document's owner must satisfy. */ + readonly owner?: NullableUserFilter | null | undefined + /** Filters that the document's project must satisfy. */ + readonly project?: ProjectFilter | null | undefined + /** Filters that the document's release must satisfy. */ + readonly release?: ReleaseFilter | null | undefined + /** [Internal] Comparator for the document's searchable content. */ + readonly searchableContent?: ContentComparator | null | undefined + /** Comparator for the document slug ID. */ + readonly slugId?: StringComparator | null | undefined + /** Filters that the document's team must satisfy. */ + readonly team?: NullableTeamFilter | null | undefined + /** Comparator for the document title. */ + readonly title?: StringComparator | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface DocumentFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly creator?: UserFilterEncoded | null | undefined + readonly cycle?: CycleFilterEncoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly initiative?: InitiativeFilterEncoded | null | undefined + readonly issue?: IssueFilterEncoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly owner?: NullableUserFilterEncoded | null | undefined + readonly project?: ProjectFilterEncoded | null | undefined + readonly release?: ReleaseFilterEncoded | null | undefined + readonly searchableContent?: typeof ContentComparator.Encoded | null | undefined + readonly slugId?: typeof StringComparator.Encoded | null | undefined + readonly team?: NullableTeamFilterEncoded | null | undefined + readonly title?: typeof StringComparator.Encoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Cycle filtering options. */ +export const CycleFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => CycleFilter)))), + completedAt: Schema.optional(Schema.NullOr(DateComparator)), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + endsAt: Schema.optional(Schema.NullOr(DateComparator)), + id: Schema.optional(Schema.NullOr(IDComparator)), + inheritedFromId: Schema.optional(Schema.NullOr(IDComparator)), + isActive: Schema.optional(Schema.NullOr(BooleanComparator)), + isFuture: Schema.optional(Schema.NullOr(BooleanComparator)), + isInCooldown: Schema.optional(Schema.NullOr(BooleanComparator)), + isNext: Schema.optional(Schema.NullOr(BooleanComparator)), + isPast: Schema.optional(Schema.NullOr(BooleanComparator)), + isPrevious: Schema.optional(Schema.NullOr(BooleanComparator)), + issues: Schema.optional(Schema.NullOr(Schema.suspend(() => IssueCollectionFilter))), + name: Schema.optional(Schema.NullOr(StringComparator)), + number: Schema.optional(Schema.NullOr(NumberComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => CycleFilter)))), + startsAt: Schema.optional(Schema.NullOr(DateComparator)), + team: Schema.optional(Schema.NullOr(Schema.suspend(() => TeamFilter))), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface CycleFilter { + /** Compound filters, all of which need to be matched by the cycle. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the cycle completed at date. */ + readonly completedAt?: DateComparator | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Comparator for the cycle ends at date. */ + readonly endsAt?: DateComparator | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Comparator for the inherited cycle ID. */ + readonly inheritedFromId?: IDComparator | null | undefined + /** Comparator for the filtering active cycle. */ + readonly isActive?: BooleanComparator | null | undefined + /** Comparator for the filtering future cycles. */ + readonly isFuture?: BooleanComparator | null | undefined + /** Comparator for filtering for whether the cycle is currently in cooldown. */ + readonly isInCooldown?: BooleanComparator | null | undefined + /** Comparator for the filtering next cycle. */ + readonly isNext?: BooleanComparator | null | undefined + /** Comparator for the filtering past cycles. */ + readonly isPast?: BooleanComparator | null | undefined + /** Comparator for the filtering previous cycle. */ + readonly isPrevious?: BooleanComparator | null | undefined + /** Filters that the cycles issues must satisfy. */ + readonly issues?: IssueCollectionFilter | null | undefined + /** Comparator for the cycle name. */ + readonly name?: StringComparator | null | undefined + /** Comparator for the cycle number. */ + readonly number?: NumberComparator | null | undefined + /** Compound filters, one of which need to be matched by the cycle. */ + readonly or?: ReadonlyArray | null | undefined + /** Comparator for the cycle start date. */ + readonly startsAt?: DateComparator | null | undefined + /** Filters that the cycles team must satisfy. */ + readonly team?: TeamFilter | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface CycleFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly completedAt?: typeof DateComparator.Encoded | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly endsAt?: typeof DateComparator.Encoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly inheritedFromId?: typeof IDComparator.Encoded | null | undefined + readonly isActive?: typeof BooleanComparator.Encoded | null | undefined + readonly isFuture?: typeof BooleanComparator.Encoded | null | undefined + readonly isInCooldown?: typeof BooleanComparator.Encoded | null | undefined + readonly isNext?: typeof BooleanComparator.Encoded | null | undefined + readonly isPast?: typeof BooleanComparator.Encoded | null | undefined + readonly isPrevious?: typeof BooleanComparator.Encoded | null | undefined + readonly issues?: IssueCollectionFilterEncoded | null | undefined + readonly name?: typeof StringComparator.Encoded | null | undefined + readonly number?: typeof NumberComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly startsAt?: typeof DateComparator.Encoded | null | undefined + readonly team?: TeamFilterEncoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Team filtering options. */ +export const TeamFilter: Schema.Codec = Schema.Struct({ + ancestors: Schema.optional(Schema.NullOr(Schema.suspend(() => TeamCollectionFilter))), + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => TeamFilter)))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + description: Schema.optional(Schema.NullOr(NullableStringComparator)), + id: Schema.optional(Schema.NullOr(IDComparator)), + issues: Schema.optional(Schema.NullOr(Schema.suspend(() => IssueCollectionFilter))), + key: Schema.optional(Schema.NullOr(StringComparator)), + members: Schema.optional(Schema.NullOr(Schema.suspend(() => UserCollectionFilter))), + name: Schema.optional(Schema.NullOr(StringComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => TeamFilter)))), + owners: Schema.optional(Schema.NullOr(Schema.suspend(() => UserCollectionFilter))), + parent: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableTeamFilter))), + private: Schema.optional(Schema.NullOr(BooleanComparator)), + releasePipelines: Schema.optional(Schema.NullOr(Schema.suspend(() => ReleasePipelineCollectionFilter))), + restrictedBy: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableTeamFilter))), + retiredAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)), + users: Schema.optional(Schema.NullOr(Schema.suspend(() => UserCollectionFilter))), + visibility: Schema.optional(Schema.NullOr(TeamVisibilityComparator)) +}) +export interface TeamFilter { + /** Filters that the team's ancestors must satisfy. */ + readonly ancestors?: TeamCollectionFilter | null | undefined + /** Compound filters, all of which need to be matched by the team. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Comparator for the team description. */ + readonly description?: NullableStringComparator | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Filters that the team's issues must satisfy. */ + readonly issues?: IssueCollectionFilter | null | undefined + /** Comparator for the team key. */ + readonly key?: StringComparator | null | undefined + /** Filters that the team's members must satisfy. */ + readonly members?: UserCollectionFilter | null | undefined + /** Comparator for the team name. */ + readonly name?: StringComparator | null | undefined + /** Compound filters, one of which need to be matched by the team. */ + readonly or?: ReadonlyArray | null | undefined + /** Filters that the team's owners must satisfy. */ + readonly owners?: UserCollectionFilter | null | undefined + /** Filters that the team's parent must satisfy. */ + readonly parent?: NullableTeamFilter | null | undefined + /** [DEPRECATED] Comparator for the team privacy. */ + readonly private?: BooleanComparator | null | undefined + /** Filters that the team's release pipelines must satisfy. */ + readonly releasePipelines?: ReleasePipelineCollectionFilter | null | undefined + /** [Internal] Filters that the private team forming this team's visibility boundary must satisfy. Only relevant for non-public teams. */ + readonly restrictedBy?: NullableTeamFilter | null | undefined + /** Comparator for the time at which the team was retired. */ + readonly retiredAt?: NullableDateComparator | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined + /** [Internal] Filters that the team's members must satisfy. Alias of `members` matching the filter shape produced by the app; prefer `members`. */ + readonly users?: UserCollectionFilter | null | undefined + /** Comparator for the team visibility. */ + readonly visibility?: TeamVisibilityComparator | null | undefined +} +export interface TeamFilterEncoded { + readonly ancestors?: TeamCollectionFilterEncoded | null | undefined + readonly and?: ReadonlyArray | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly description?: typeof NullableStringComparator.Encoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly issues?: IssueCollectionFilterEncoded | null | undefined + readonly key?: typeof StringComparator.Encoded | null | undefined + readonly members?: UserCollectionFilterEncoded | null | undefined + readonly name?: typeof StringComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly owners?: UserCollectionFilterEncoded | null | undefined + readonly parent?: NullableTeamFilterEncoded | null | undefined + readonly private?: typeof BooleanComparator.Encoded | null | undefined + readonly releasePipelines?: ReleasePipelineCollectionFilterEncoded | null | undefined + readonly restrictedBy?: NullableTeamFilterEncoded | null | undefined + readonly retiredAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined + readonly users?: UserCollectionFilterEncoded | null | undefined + readonly visibility?: typeof TeamVisibilityComparator.Encoded | null | undefined +} + +/** Team collection filtering options. */ +export const TeamCollectionFilter: Schema.Codec = Schema.Struct({ + ancestors: Schema.optional(Schema.NullOr(Schema.suspend(() => TeamCollectionFilter))), + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => TeamCollectionFilter)))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + every: Schema.optional(Schema.NullOr(Schema.suspend(() => TeamFilter))), + id: Schema.optional(Schema.NullOr(IDComparator)), + length: Schema.optional(Schema.NullOr(NumberComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => TeamCollectionFilter)))), + parent: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableTeamFilter))), + some: Schema.optional(Schema.NullOr(Schema.suspend(() => TeamFilter))), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface TeamCollectionFilter { + /** Filters that the team's ancestors must satisfy. */ + readonly ancestors?: TeamCollectionFilter | null | undefined + /** Compound filters, all of which need to be matched by the team. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Filters that needs to be matched by all teams. */ + readonly every?: TeamFilter | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Comparator for the collection length. */ + readonly length?: NumberComparator | null | undefined + /** Compound filters, one of which need to be matched by the team. */ + readonly or?: ReadonlyArray | null | undefined + /** Filters that the teams parent must satisfy. */ + readonly parent?: NullableTeamFilter | null | undefined + /** Filters that needs to be matched by some teams. */ + readonly some?: TeamFilter | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface TeamCollectionFilterEncoded { + readonly ancestors?: TeamCollectionFilterEncoded | null | undefined + readonly and?: ReadonlyArray | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly every?: TeamFilterEncoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly length?: typeof NumberComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly parent?: NullableTeamFilterEncoded | null | undefined + readonly some?: TeamFilterEncoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Team filtering options. */ +export const NullableTeamFilter: Schema.Codec = Schema.Struct({ + ancestors: Schema.optional(Schema.NullOr(Schema.suspend(() => TeamCollectionFilter))), + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => NullableTeamFilter)))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + description: Schema.optional(Schema.NullOr(NullableStringComparator)), + id: Schema.optional(Schema.NullOr(IDComparator)), + issues: Schema.optional(Schema.NullOr(Schema.suspend(() => IssueCollectionFilter))), + key: Schema.optional(Schema.NullOr(StringComparator)), + members: Schema.optional(Schema.NullOr(Schema.suspend(() => UserCollectionFilter))), + name: Schema.optional(Schema.NullOr(StringComparator)), + null: Schema.optional(Schema.NullOr(Schema.Boolean)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => NullableTeamFilter)))), + owners: Schema.optional(Schema.NullOr(Schema.suspend(() => UserCollectionFilter))), + parent: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableTeamFilter))), + private: Schema.optional(Schema.NullOr(BooleanComparator)), + releasePipelines: Schema.optional(Schema.NullOr(Schema.suspend(() => ReleasePipelineCollectionFilter))), + restrictedBy: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableTeamFilter))), + retiredAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)), + users: Schema.optional(Schema.NullOr(Schema.suspend(() => UserCollectionFilter))), + visibility: Schema.optional(Schema.NullOr(TeamVisibilityComparator)) +}) +export interface NullableTeamFilter { + /** Filters that the team's ancestors must satisfy. */ + readonly ancestors?: TeamCollectionFilter | null | undefined + /** Compound filters, all of which need to be matched by the team. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Comparator for the team description. */ + readonly description?: NullableStringComparator | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Filters that the team's issues must satisfy. */ + readonly issues?: IssueCollectionFilter | null | undefined + /** Comparator for the team key. */ + readonly key?: StringComparator | null | undefined + /** Filters that the team's members must satisfy. */ + readonly members?: UserCollectionFilter | null | undefined + /** Comparator for the team name. */ + readonly name?: StringComparator | null | undefined + /** Filter based on the existence of the relation. */ + readonly null?: boolean | null | undefined + /** Compound filters, one of which need to be matched by the team. */ + readonly or?: ReadonlyArray | null | undefined + /** Filters that the team's owners must satisfy. */ + readonly owners?: UserCollectionFilter | null | undefined + /** Filters that the team's parent must satisfy. */ + readonly parent?: NullableTeamFilter | null | undefined + /** [DEPRECATED] Comparator for the team privacy. */ + readonly private?: BooleanComparator | null | undefined + /** Filters that the team's release pipelines must satisfy. */ + readonly releasePipelines?: ReleasePipelineCollectionFilter | null | undefined + /** [Internal] Filters that the private team forming this team's visibility boundary must satisfy. Only relevant for non-public teams. */ + readonly restrictedBy?: NullableTeamFilter | null | undefined + /** Comparator for the time at which the team was retired. */ + readonly retiredAt?: NullableDateComparator | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined + /** [Internal] Filters that the team's members must satisfy. Alias of `members` matching the filter shape produced by the app; prefer `members`. */ + readonly users?: UserCollectionFilter | null | undefined + /** Comparator for the team visibility. */ + readonly visibility?: TeamVisibilityComparator | null | undefined +} +export interface NullableTeamFilterEncoded { + readonly ancestors?: TeamCollectionFilterEncoded | null | undefined + readonly and?: ReadonlyArray | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly description?: typeof NullableStringComparator.Encoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly issues?: IssueCollectionFilterEncoded | null | undefined + readonly key?: typeof StringComparator.Encoded | null | undefined + readonly members?: UserCollectionFilterEncoded | null | undefined + readonly name?: typeof StringComparator.Encoded | null | undefined + readonly null?: boolean | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly owners?: UserCollectionFilterEncoded | null | undefined + readonly parent?: NullableTeamFilterEncoded | null | undefined + readonly private?: typeof BooleanComparator.Encoded | null | undefined + readonly releasePipelines?: ReleasePipelineCollectionFilterEncoded | null | undefined + readonly restrictedBy?: NullableTeamFilterEncoded | null | undefined + readonly retiredAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined + readonly users?: UserCollectionFilterEncoded | null | undefined + readonly visibility?: typeof TeamVisibilityComparator.Encoded | null | undefined +} + +/** User filtering options. */ +export const UserCollectionFilter: Schema.Codec = Schema.Struct({ + active: Schema.optional(Schema.NullOr(BooleanComparator)), + admin: Schema.optional(Schema.NullOr(BooleanComparator)), + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => UserCollectionFilter)))), + app: Schema.optional(Schema.NullOr(BooleanComparator)), + assignedIssues: Schema.optional(Schema.NullOr(Schema.suspend(() => IssueCollectionFilter))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + displayName: Schema.optional(Schema.NullOr(StringComparator)), + email: Schema.optional(Schema.NullOr(StringComparator)), + every: Schema.optional(Schema.NullOr(Schema.suspend(() => UserFilter))), + id: Schema.optional(Schema.NullOr(IDComparator)), + invited: Schema.optional(Schema.NullOr(BooleanComparator)), + isInvited: Schema.optional(Schema.NullOr(BooleanComparator)), + isMe: Schema.optional(Schema.NullOr(BooleanComparator)), + length: Schema.optional(Schema.NullOr(NumberComparator)), + name: Schema.optional(Schema.NullOr(StringComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => UserCollectionFilter)))), + owner: Schema.optional(Schema.NullOr(BooleanComparator)), + some: Schema.optional(Schema.NullOr(Schema.suspend(() => UserFilter))), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface UserCollectionFilter { + /** Comparator for the user's activity status. */ + readonly active?: BooleanComparator | null | undefined + /** Comparator for the user's admin status. */ + readonly admin?: BooleanComparator | null | undefined + /** Compound filters, all of which need to be matched by the user. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the user's app status. */ + readonly app?: BooleanComparator | null | undefined + /** Filters that the users assigned issues must satisfy. */ + readonly assignedIssues?: IssueCollectionFilter | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Comparator for the user's display name. */ + readonly displayName?: StringComparator | null | undefined + /** Comparator for the user's email. */ + readonly email?: StringComparator | null | undefined + /** Filters that needs to be matched by all users. */ + readonly every?: UserFilter | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Comparator for the user's invited status. */ + readonly invited?: BooleanComparator | null | undefined + /** Comparator for the user's invited status. */ + readonly isInvited?: BooleanComparator | null | undefined + /** Filter based on the currently authenticated user. Set to true to filter for the authenticated user, false for any other user. */ + readonly isMe?: BooleanComparator | null | undefined + /** Comparator for the collection length. */ + readonly length?: NumberComparator | null | undefined + /** Comparator for the user's name. */ + readonly name?: StringComparator | null | undefined + /** Compound filters, one of which need to be matched by the user. */ + readonly or?: ReadonlyArray | null | undefined + /** Comparator for the user's owner status. */ + readonly owner?: BooleanComparator | null | undefined + /** Filters that needs to be matched by some users. */ + readonly some?: UserFilter | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface UserCollectionFilterEncoded { + readonly active?: typeof BooleanComparator.Encoded | null | undefined + readonly admin?: typeof BooleanComparator.Encoded | null | undefined + readonly and?: ReadonlyArray | null | undefined + readonly app?: typeof BooleanComparator.Encoded | null | undefined + readonly assignedIssues?: IssueCollectionFilterEncoded | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly displayName?: typeof StringComparator.Encoded | null | undefined + readonly email?: typeof StringComparator.Encoded | null | undefined + readonly every?: UserFilterEncoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly invited?: typeof BooleanComparator.Encoded | null | undefined + readonly isInvited?: typeof BooleanComparator.Encoded | null | undefined + readonly isMe?: typeof BooleanComparator.Encoded | null | undefined + readonly length?: typeof NumberComparator.Encoded | null | undefined + readonly name?: typeof StringComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly owner?: typeof BooleanComparator.Encoded | null | undefined + readonly some?: UserFilterEncoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Release pipeline collection filtering options. */ +export const ReleasePipelineCollectionFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => ReleasePipelineCollectionFilter)))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + every: Schema.optional(Schema.NullOr(Schema.suspend(() => ReleasePipelineFilter))), + id: Schema.optional(Schema.NullOr(IDComparator)), + isProduction: Schema.optional(Schema.NullOr(BooleanComparator)), + length: Schema.optional(Schema.NullOr(NumberComparator)), + name: Schema.optional(Schema.NullOr(StringComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => ReleasePipelineCollectionFilter)))), + some: Schema.optional(Schema.NullOr(Schema.suspend(() => ReleasePipelineFilter))), + teams: Schema.optional(Schema.NullOr(Schema.suspend(() => TeamCollectionFilter))), + type: Schema.optional(Schema.NullOr(ReleasePipelineTypeComparator)), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface ReleasePipelineCollectionFilter { + /** Compound filters, all of which need to be matched by the release pipeline. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Filters that needs to be matched by all release pipelines. */ + readonly every?: ReleasePipelineFilter | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Comparator for the pipeline production flag. */ + readonly isProduction?: BooleanComparator | null | undefined + /** Comparator for the collection length. */ + readonly length?: NumberComparator | null | undefined + /** Comparator for the pipeline name. */ + readonly name?: StringComparator | null | undefined + /** Compound filters, one of which need to be matched by the release pipeline. */ + readonly or?: ReadonlyArray | null | undefined + /** Filters that needs to be matched by some release pipelines. */ + readonly some?: ReleasePipelineFilter | null | undefined + /** Filters that the release pipeline's teams must satisfy. */ + readonly teams?: TeamCollectionFilter | null | undefined + /** Comparator for the pipeline type. */ + readonly type?: ReleasePipelineTypeComparator | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface ReleasePipelineCollectionFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly every?: ReleasePipelineFilterEncoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly isProduction?: typeof BooleanComparator.Encoded | null | undefined + readonly length?: typeof NumberComparator.Encoded | null | undefined + readonly name?: typeof StringComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly some?: ReleasePipelineFilterEncoded | null | undefined + readonly teams?: TeamCollectionFilterEncoded | null | undefined + readonly type?: typeof ReleasePipelineTypeComparator.Encoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Release pipeline filtering options. */ +export const ReleasePipelineFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => ReleasePipelineFilter)))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + id: Schema.optional(Schema.NullOr(IDComparator)), + isProduction: Schema.optional(Schema.NullOr(BooleanComparator)), + name: Schema.optional(Schema.NullOr(StringComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => ReleasePipelineFilter)))), + teams: Schema.optional(Schema.NullOr(Schema.suspend(() => TeamCollectionFilter))), + type: Schema.optional(Schema.NullOr(ReleasePipelineTypeComparator)), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface ReleasePipelineFilter { + /** Compound filters, all of which need to be matched by the pipeline. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Comparator for the pipeline production flag. */ + readonly isProduction?: BooleanComparator | null | undefined + /** Comparator for the pipeline name. */ + readonly name?: StringComparator | null | undefined + /** Compound filters, one of which need to be matched by the pipeline. */ + readonly or?: ReadonlyArray | null | undefined + /** Filters that the release pipeline's teams must satisfy. */ + readonly teams?: TeamCollectionFilter | null | undefined + /** Comparator for the pipeline type. */ + readonly type?: ReleasePipelineTypeComparator | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface ReleasePipelineFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly isProduction?: typeof BooleanComparator.Encoded | null | undefined + readonly name?: typeof StringComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly teams?: TeamCollectionFilterEncoded | null | undefined + readonly type?: typeof ReleasePipelineTypeComparator.Encoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Initiative filtering options. */ +export const InitiativeFilter: Schema.Codec = Schema.Struct({ + activityType: Schema.optional(Schema.NullOr(StringComparator)), + ancestors: Schema.optional(Schema.NullOr(Schema.suspend(() => InitiativeCollectionFilter))), + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => InitiativeFilter)))), + canceledAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + completedAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + creator: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableUserFilter))), + customIdentifier: Schema.optional(Schema.NullOr(NullableStringComparator)), + health: Schema.optional(Schema.NullOr(StringComparator)), + healthWithAge: Schema.optional(Schema.NullOr(StringComparator)), + id: Schema.optional(Schema.NullOr(EntityIdentifierIDComparator)), + initiativeUpdates: Schema.optional(Schema.NullOr(InitiativeUpdatesCollectionFilter)), + labels: Schema.optional(Schema.NullOr(Schema.suspend(() => InitiativeLabelCollectionFilter))), + leadTeam: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableTeamFilter))), + name: Schema.optional(Schema.NullOr(StringComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => InitiativeFilter)))), + owner: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableUserFilter))), + priority: Schema.optional(Schema.NullOr(NullableNumberComparator)), + projects: Schema.optional(Schema.NullOr(Schema.suspend(() => ProjectCollectionFilter))), + slugId: Schema.optional(Schema.NullOr(StringComparator)), + startedAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + status: Schema.optional(Schema.NullOr(StringComparator)), + targetDate: Schema.optional(Schema.NullOr(NullableDateComparator)), + teams: Schema.optional(Schema.NullOr(Schema.suspend(() => TeamCollectionFilter))), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface InitiativeFilter { + /** Comparator for the initiative activity type. */ + readonly activityType?: StringComparator | null | undefined + /** Filters that the initiative must be an ancestor of. */ + readonly ancestors?: InitiativeCollectionFilter | null | undefined + /** Compound filters, all of which need to be matched by the initiative. */ + readonly and?: ReadonlyArray | null | undefined + /** [Internal] Comparator for the initiative canceled at date. */ + readonly canceledAt?: NullableDateComparator | null | undefined + /** Comparator for the initiative completed at date. */ + readonly completedAt?: NullableDateComparator | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Filters that the initiative creator must satisfy. */ + readonly creator?: NullableUserFilter | null | undefined + /** [Internal] Comparator for the initiative's custom identifier. */ + readonly customIdentifier?: NullableStringComparator | null | undefined + /** Comparator for the initiative health: onTrack, atRisk, offTrack */ + readonly health?: StringComparator | null | undefined + /** Comparator for the initiative health (with age): onTrack, atRisk, offTrack, outdated, noUpdate */ + readonly healthWithAge?: StringComparator | null | undefined + /** Comparator for the identifier. */ + readonly id?: EntityIdentifierIDComparator | null | undefined + /** Filters that the initiative updates must satisfy. */ + readonly initiativeUpdates?: InitiativeUpdatesCollectionFilter | null | undefined + /** Filters that the initiative labels must satisfy. */ + readonly labels?: InitiativeLabelCollectionFilter | null | undefined + /** Filters that the initiative lead team must satisfy. */ + readonly leadTeam?: NullableTeamFilter | null | undefined + /** Comparator for the initiative name. */ + readonly name?: StringComparator | null | undefined + /** Compound filters, one of which need to be matched by the initiative. */ + readonly or?: ReadonlyArray | null | undefined + /** Filters that the initiative owner must satisfy. */ + readonly owner?: NullableUserFilter | null | undefined + /** Comparator for the initiative priority. */ + readonly priority?: NullableNumberComparator | null | undefined + /** Filters that the initiative projects must satisfy. */ + readonly projects?: ProjectCollectionFilter | null | undefined + /** Comparator for the initiative slug ID. */ + readonly slugId?: StringComparator | null | undefined + /** Comparator for the initiative started at date. */ + readonly startedAt?: NullableDateComparator | null | undefined + /** Comparator for the initiative status: Proposed, Planned, Active, Completed, Canceled */ + readonly status?: StringComparator | null | undefined + /** Comparator for the initiative target date. */ + readonly targetDate?: NullableDateComparator | null | undefined + /** Filters that the initiative teams must satisfy. */ + readonly teams?: TeamCollectionFilter | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface InitiativeFilterEncoded { + readonly activityType?: typeof StringComparator.Encoded | null | undefined + readonly ancestors?: InitiativeCollectionFilterEncoded | null | undefined + readonly and?: ReadonlyArray | null | undefined + readonly canceledAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly completedAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly creator?: NullableUserFilterEncoded | null | undefined + readonly customIdentifier?: typeof NullableStringComparator.Encoded | null | undefined + readonly health?: typeof StringComparator.Encoded | null | undefined + readonly healthWithAge?: typeof StringComparator.Encoded | null | undefined + readonly id?: typeof EntityIdentifierIDComparator.Encoded | null | undefined + readonly initiativeUpdates?: InitiativeUpdatesCollectionFilterEncoded | null | undefined + readonly labels?: InitiativeLabelCollectionFilterEncoded | null | undefined + readonly leadTeam?: NullableTeamFilterEncoded | null | undefined + readonly name?: typeof StringComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly owner?: NullableUserFilterEncoded | null | undefined + readonly priority?: typeof NullableNumberComparator.Encoded | null | undefined + readonly projects?: ProjectCollectionFilterEncoded | null | undefined + readonly slugId?: typeof StringComparator.Encoded | null | undefined + readonly startedAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly status?: typeof StringComparator.Encoded | null | undefined + readonly targetDate?: typeof NullableDateComparator.Encoded | null | undefined + readonly teams?: TeamCollectionFilterEncoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Initiative collection filtering options. */ +export const InitiativeCollectionFilter: Schema.Codec = Schema.Struct({ + activityType: Schema.optional(Schema.NullOr(StringComparator)), + ancestors: Schema.optional(Schema.NullOr(Schema.suspend(() => InitiativeCollectionFilter))), + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => InitiativeCollectionFilter)))), + canceledAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + completedAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + creator: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableUserFilter))), + customIdentifier: Schema.optional(Schema.NullOr(NullableStringComparator)), + every: Schema.optional(Schema.NullOr(Schema.suspend(() => InitiativeFilter))), + health: Schema.optional(Schema.NullOr(StringComparator)), + healthWithAge: Schema.optional(Schema.NullOr(StringComparator)), + id: Schema.optional(Schema.NullOr(EntityIdentifierIDComparator)), + initiativeUpdates: Schema.optional(Schema.NullOr(InitiativeUpdatesCollectionFilter)), + labels: Schema.optional(Schema.NullOr(Schema.suspend(() => InitiativeLabelCollectionFilter))), + leadTeam: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableTeamFilter))), + length: Schema.optional(Schema.NullOr(NumberComparator)), + name: Schema.optional(Schema.NullOr(StringComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => InitiativeCollectionFilter)))), + owner: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableUserFilter))), + priority: Schema.optional(Schema.NullOr(NullableNumberComparator)), + projects: Schema.optional(Schema.NullOr(Schema.suspend(() => ProjectCollectionFilter))), + slugId: Schema.optional(Schema.NullOr(StringComparator)), + some: Schema.optional(Schema.NullOr(Schema.suspend(() => InitiativeFilter))), + startedAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + status: Schema.optional(Schema.NullOr(StringComparator)), + targetDate: Schema.optional(Schema.NullOr(NullableDateComparator)), + teams: Schema.optional(Schema.NullOr(Schema.suspend(() => TeamCollectionFilter))), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface InitiativeCollectionFilter { + /** Comparator for the initiative activity type. */ + readonly activityType?: StringComparator | null | undefined + /** Filters that the initiative must be an ancestor of. */ + readonly ancestors?: InitiativeCollectionFilter | null | undefined + /** Compound filters, all of which need to be matched by the initiative. */ + readonly and?: ReadonlyArray | null | undefined + /** [Internal] Comparator for the initiative canceled at date. */ + readonly canceledAt?: NullableDateComparator | null | undefined + /** Comparator for the initiative completed at date. */ + readonly completedAt?: NullableDateComparator | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Filters that the initiative creator must satisfy. */ + readonly creator?: NullableUserFilter | null | undefined + /** [Internal] Comparator for the initiative's custom identifier. */ + readonly customIdentifier?: NullableStringComparator | null | undefined + /** Filters that needs to be matched by all initiatives. */ + readonly every?: InitiativeFilter | null | undefined + /** Comparator for the initiative health: onTrack, atRisk, offTrack */ + readonly health?: StringComparator | null | undefined + /** Comparator for the initiative health (with age): onTrack, atRisk, offTrack, outdated, noUpdate */ + readonly healthWithAge?: StringComparator | null | undefined + /** Comparator for the identifier. */ + readonly id?: EntityIdentifierIDComparator | null | undefined + /** Filters that the initiative updates must satisfy. */ + readonly initiativeUpdates?: InitiativeUpdatesCollectionFilter | null | undefined + /** Filters that the initiative labels must satisfy. */ + readonly labels?: InitiativeLabelCollectionFilter | null | undefined + /** Filters that the initiative lead team must satisfy. */ + readonly leadTeam?: NullableTeamFilter | null | undefined + /** Comparator for the collection length. */ + readonly length?: NumberComparator | null | undefined + /** Comparator for the initiative name. */ + readonly name?: StringComparator | null | undefined + /** Compound filters, one of which need to be matched by the initiative. */ + readonly or?: ReadonlyArray | null | undefined + /** Filters that the initiative owner must satisfy. */ + readonly owner?: NullableUserFilter | null | undefined + /** Comparator for the initiative priority. */ + readonly priority?: NullableNumberComparator | null | undefined + /** Filters that the initiative projects must satisfy. */ + readonly projects?: ProjectCollectionFilter | null | undefined + /** Comparator for the initiative slug ID. */ + readonly slugId?: StringComparator | null | undefined + /** Filters that needs to be matched by some initiatives. */ + readonly some?: InitiativeFilter | null | undefined + /** Comparator for the initiative started at date. */ + readonly startedAt?: NullableDateComparator | null | undefined + /** Comparator for the initiative status: Proposed, Planned, Active, Completed, Canceled */ + readonly status?: StringComparator | null | undefined + /** Comparator for the initiative target date. */ + readonly targetDate?: NullableDateComparator | null | undefined + /** Filters that the initiative teams must satisfy. */ + readonly teams?: TeamCollectionFilter | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface InitiativeCollectionFilterEncoded { + readonly activityType?: typeof StringComparator.Encoded | null | undefined + readonly ancestors?: InitiativeCollectionFilterEncoded | null | undefined + readonly and?: ReadonlyArray | null | undefined + readonly canceledAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly completedAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly creator?: NullableUserFilterEncoded | null | undefined + readonly customIdentifier?: typeof NullableStringComparator.Encoded | null | undefined + readonly every?: InitiativeFilterEncoded | null | undefined + readonly health?: typeof StringComparator.Encoded | null | undefined + readonly healthWithAge?: typeof StringComparator.Encoded | null | undefined + readonly id?: typeof EntityIdentifierIDComparator.Encoded | null | undefined + readonly initiativeUpdates?: InitiativeUpdatesCollectionFilterEncoded | null | undefined + readonly labels?: InitiativeLabelCollectionFilterEncoded | null | undefined + readonly leadTeam?: NullableTeamFilterEncoded | null | undefined + readonly length?: typeof NumberComparator.Encoded | null | undefined + readonly name?: typeof StringComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly owner?: NullableUserFilterEncoded | null | undefined + readonly priority?: typeof NullableNumberComparator.Encoded | null | undefined + readonly projects?: ProjectCollectionFilterEncoded | null | undefined + readonly slugId?: typeof StringComparator.Encoded | null | undefined + readonly some?: InitiativeFilterEncoded | null | undefined + readonly startedAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly status?: typeof StringComparator.Encoded | null | undefined + readonly targetDate?: typeof NullableDateComparator.Encoded | null | undefined + readonly teams?: TeamCollectionFilterEncoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Initiative label filtering options. */ +export const InitiativeLabelCollectionFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => InitiativeLabelCollectionFilter)))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + creator: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableUserFilter))), + every: Schema.optional(Schema.NullOr(Schema.suspend(() => InitiativeLabelFilter))), + id: Schema.optional(Schema.NullOr(IDComparator)), + isGroup: Schema.optional(Schema.NullOr(BooleanComparator)), + length: Schema.optional(Schema.NullOr(NumberComparator)), + name: Schema.optional(Schema.NullOr(StringComparator)), + null: Schema.optional(Schema.NullOr(Schema.Boolean)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => InitiativeLabelCollectionFilter)))), + parent: Schema.optional(Schema.NullOr(Schema.suspend(() => InitiativeLabelFilter))), + some: Schema.optional(Schema.NullOr(Schema.suspend(() => InitiativeLabelCollectionFilter))), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface InitiativeLabelCollectionFilter { + /** Compound filters, all of which need to be matched by the label. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Filters that the initiative labels creator must satisfy. */ + readonly creator?: NullableUserFilter | null | undefined + /** Filters that needs to be matched by all initiative labels. */ + readonly every?: InitiativeLabelFilter | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Comparator for whether the label is a group label. */ + readonly isGroup?: BooleanComparator | null | undefined + /** Comparator for the collection length. */ + readonly length?: NumberComparator | null | undefined + /** Comparator for the name. */ + readonly name?: StringComparator | null | undefined + /** Filter based on the existence of the relation. */ + readonly null?: boolean | null | undefined + /** Compound filters, one of which need to be matched by the label. */ + readonly or?: ReadonlyArray | null | undefined + /** Filters that the initiative label's parent label must satisfy. */ + readonly parent?: InitiativeLabelFilter | null | undefined + /** Filters that needs to be matched by some initiative labels. */ + readonly some?: InitiativeLabelCollectionFilter | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface InitiativeLabelCollectionFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly creator?: NullableUserFilterEncoded | null | undefined + readonly every?: InitiativeLabelFilterEncoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly isGroup?: typeof BooleanComparator.Encoded | null | undefined + readonly length?: typeof NumberComparator.Encoded | null | undefined + readonly name?: typeof StringComparator.Encoded | null | undefined + readonly null?: boolean | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly parent?: InitiativeLabelFilterEncoded | null | undefined + readonly some?: InitiativeLabelCollectionFilterEncoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Initiative label filtering options. */ +export const InitiativeLabelFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => InitiativeLabelFilter)))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + creator: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableUserFilter))), + id: Schema.optional(Schema.NullOr(IDComparator)), + isGroup: Schema.optional(Schema.NullOr(BooleanComparator)), + name: Schema.optional(Schema.NullOr(StringComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => InitiativeLabelFilter)))), + parent: Schema.optional(Schema.NullOr(Schema.suspend(() => InitiativeLabelFilter))), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface InitiativeLabelFilter { + /** Compound filters, all of which need to be matched by the label. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Filters that the initiative labels creator must satisfy. */ + readonly creator?: NullableUserFilter | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Comparator for whether the label is a group label. */ + readonly isGroup?: BooleanComparator | null | undefined + /** Comparator for the name. */ + readonly name?: StringComparator | null | undefined + /** Compound filters, one of which need to be matched by the label. */ + readonly or?: ReadonlyArray | null | undefined + /** Filters that the initiative label's parent label must satisfy. */ + readonly parent?: InitiativeLabelFilter | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface InitiativeLabelFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly creator?: NullableUserFilterEncoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly isGroup?: typeof BooleanComparator.Encoded | null | undefined + readonly name?: typeof StringComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly parent?: InitiativeLabelFilterEncoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Project filtering options. */ +export const ProjectCollectionFilter: Schema.Codec = Schema.Struct({ + accessibleTeams: Schema.optional(Schema.NullOr(Schema.suspend(() => TeamCollectionFilter))), + activityType: Schema.optional(Schema.NullOr(StringComparator)), + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => ProjectCollectionFilter)))), + canceledAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + completedAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + completedProjectMilestones: Schema.optional(Schema.NullOr(Schema.suspend(() => ProjectMilestoneCollectionFilter))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + creator: Schema.optional(Schema.NullOr(Schema.suspend(() => UserFilter))), + customIdentifier: Schema.optional(Schema.NullOr(NullableStringComparator)), + customerCount: Schema.optional(Schema.NullOr(NumberComparator)), + customerImportantCount: Schema.optional(Schema.NullOr(NumberComparator)), + every: Schema.optional(Schema.NullOr(Schema.suspend(() => ProjectFilter))), + hasBlockedByRelations: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasBlockingRelations: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasDependedOnByRelations: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasDependsOnRelations: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasRelatedRelations: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasViolatedRelations: Schema.optional(Schema.NullOr(RelationExistsComparator)), + health: Schema.optional(Schema.NullOr(StringComparator)), + healthWithAge: Schema.optional(Schema.NullOr(StringComparator)), + id: Schema.optional(Schema.NullOr(EntityIdentifierIDComparator)), + initiatives: Schema.optional(Schema.NullOr(Schema.suspend(() => InitiativeCollectionFilter))), + issues: Schema.optional(Schema.NullOr(Schema.suspend(() => IssueCollectionFilter))), + labels: Schema.optional(Schema.NullOr(Schema.suspend(() => ProjectLabelCollectionFilter))), + lastAppliedTemplate: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableTemplateFilter))), + lead: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableUserFilter))), + leadTeam: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableTeamFilter))), + length: Schema.optional(Schema.NullOr(NumberComparator)), + members: Schema.optional(Schema.NullOr(Schema.suspend(() => UserCollectionFilter))), + name: Schema.optional(Schema.NullOr(StringComparator)), + needs: Schema.optional(Schema.NullOr(Schema.suspend(() => CustomerNeedCollectionFilter))), + nextProjectMilestone: Schema.optional(Schema.NullOr(Schema.suspend(() => ProjectMilestoneFilter))), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => ProjectCollectionFilter)))), + priority: Schema.optional(Schema.NullOr(NullableNumberComparator)), + projectMilestones: Schema.optional(Schema.NullOr(Schema.suspend(() => ProjectMilestoneCollectionFilter))), + projectUpdates: Schema.optional(Schema.NullOr(ProjectUpdatesCollectionFilter)), + roadmaps: Schema.optional(Schema.NullOr(Schema.suspend(() => RoadmapCollectionFilter))), + searchableContent: Schema.optional(Schema.NullOr(ContentComparator)), + slugId: Schema.optional(Schema.NullOr(StringComparator)), + some: Schema.optional(Schema.NullOr(Schema.suspend(() => ProjectFilter))), + startDate: Schema.optional(Schema.NullOr(NullableDateComparator)), + startedAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + state: Schema.optional(Schema.NullOr(StringComparator)), + status: Schema.optional(Schema.NullOr(Schema.suspend(() => ProjectStatusFilter))), + targetDate: Schema.optional(Schema.NullOr(NullableDateComparator)), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface ProjectCollectionFilter { + /** Filters that the project's team must satisfy. */ + readonly accessibleTeams?: TeamCollectionFilter | null | undefined + /** [ALPHA] Comparator for the project activity type: buzzin, active, some, none */ + readonly activityType?: StringComparator | null | undefined + /** Compound filters, all of which need to be matched by the project. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the project cancelation date. */ + readonly canceledAt?: NullableDateComparator | null | undefined + /** Comparator for the project completion date. */ + readonly completedAt?: NullableDateComparator | null | undefined + /** Filters that the project's completed milestones must satisfy. */ + readonly completedProjectMilestones?: ProjectMilestoneCollectionFilter | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Filters that the projects creator must satisfy. */ + readonly creator?: UserFilter | null | undefined + /** [Internal] Comparator for the project's custom identifier. */ + readonly customIdentifier?: NullableStringComparator | null | undefined + /** Count of customers */ + readonly customerCount?: NumberComparator | null | undefined + /** Count of important customers */ + readonly customerImportantCount?: NumberComparator | null | undefined + /** Filters that needs to be matched by all projects. */ + readonly every?: ProjectFilter | null | undefined + /** Comparator for filtering projects which are blocked. */ + readonly hasBlockedByRelations?: RelationExistsComparator | null | undefined + /** Comparator for filtering projects which are blocking. */ + readonly hasBlockingRelations?: RelationExistsComparator | null | undefined + /** [Deprecated] Comparator for filtering projects which this is depended on by. */ + readonly hasDependedOnByRelations?: RelationExistsComparator | null | undefined + /** [Deprecated]Comparator for filtering projects which this depends on. */ + readonly hasDependsOnRelations?: RelationExistsComparator | null | undefined + /** Comparator for filtering projects with relations. */ + readonly hasRelatedRelations?: RelationExistsComparator | null | undefined + /** Comparator for filtering projects with violated dependencies. */ + readonly hasViolatedRelations?: RelationExistsComparator | null | undefined + /** Comparator for the project health: onTrack, atRisk, offTrack */ + readonly health?: StringComparator | null | undefined + /** Comparator for the project health (with age): onTrack, atRisk, offTrack, outdated, noUpdate */ + readonly healthWithAge?: StringComparator | null | undefined + /** Comparator for the identifier. */ + readonly id?: EntityIdentifierIDComparator | null | undefined + /** Filters that the projects initiatives must satisfy. */ + readonly initiatives?: InitiativeCollectionFilter | null | undefined + /** Filters that the projects issues must satisfy. */ + readonly issues?: IssueCollectionFilter | null | undefined + /** Filters that project labels must satisfy. */ + readonly labels?: ProjectLabelCollectionFilter | null | undefined + /** Filters that the last applied template must satisfy. */ + readonly lastAppliedTemplate?: NullableTemplateFilter | null | undefined + /** Filters that the projects lead must satisfy. */ + readonly lead?: NullableUserFilter | null | undefined + /** [ALPHA] Filters that the project's lead team must satisfy. */ + readonly leadTeam?: NullableTeamFilter | null | undefined + /** Comparator for the collection length. */ + readonly length?: NumberComparator | null | undefined + /** Filters that the projects members must satisfy. */ + readonly members?: UserCollectionFilter | null | undefined + /** Comparator for the project name. */ + readonly name?: StringComparator | null | undefined + /** Filters that the project's customer needs must satisfy. */ + readonly needs?: CustomerNeedCollectionFilter | null | undefined + /** Filters that the project's next milestone must satisfy. */ + readonly nextProjectMilestone?: ProjectMilestoneFilter | null | undefined + /** Compound filters, one of which need to be matched by the project. */ + readonly or?: ReadonlyArray | null | undefined + /** Comparator for the project priority. */ + readonly priority?: NullableNumberComparator | null | undefined + /** Filters that the project's milestones must satisfy. */ + readonly projectMilestones?: ProjectMilestoneCollectionFilter | null | undefined + /** Comparator for the project updates. */ + readonly projectUpdates?: ProjectUpdatesCollectionFilter | null | undefined + /** Filters that the projects roadmaps must satisfy. */ + readonly roadmaps?: RoadmapCollectionFilter | null | undefined + /** [Internal] Comparator for the project's content. */ + readonly searchableContent?: ContentComparator | null | undefined + /** Comparator for the project slug ID. */ + readonly slugId?: StringComparator | null | undefined + /** Filters that needs to be matched by some projects. */ + readonly some?: ProjectFilter | null | undefined + /** Comparator for the project start date. */ + readonly startDate?: NullableDateComparator | null | undefined + /** Comparator for the project started date (when it was moved to an "In Progress" status). */ + readonly startedAt?: NullableDateComparator | null | undefined + /** [DEPRECATED] Comparator for the project state. */ + readonly state?: StringComparator | null | undefined + /** Filters that the project status must satisfy. */ + readonly status?: ProjectStatusFilter | null | undefined + /** Comparator for the project target date. */ + readonly targetDate?: NullableDateComparator | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface ProjectCollectionFilterEncoded { + readonly accessibleTeams?: TeamCollectionFilterEncoded | null | undefined + readonly activityType?: typeof StringComparator.Encoded | null | undefined + readonly and?: ReadonlyArray | null | undefined + readonly canceledAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly completedAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly completedProjectMilestones?: ProjectMilestoneCollectionFilterEncoded | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly creator?: UserFilterEncoded | null | undefined + readonly customIdentifier?: typeof NullableStringComparator.Encoded | null | undefined + readonly customerCount?: typeof NumberComparator.Encoded | null | undefined + readonly customerImportantCount?: typeof NumberComparator.Encoded | null | undefined + readonly every?: ProjectFilterEncoded | null | undefined + readonly hasBlockedByRelations?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasBlockingRelations?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasDependedOnByRelations?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasDependsOnRelations?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasRelatedRelations?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasViolatedRelations?: typeof RelationExistsComparator.Encoded | null | undefined + readonly health?: typeof StringComparator.Encoded | null | undefined + readonly healthWithAge?: typeof StringComparator.Encoded | null | undefined + readonly id?: typeof EntityIdentifierIDComparator.Encoded | null | undefined + readonly initiatives?: InitiativeCollectionFilterEncoded | null | undefined + readonly issues?: IssueCollectionFilterEncoded | null | undefined + readonly labels?: ProjectLabelCollectionFilterEncoded | null | undefined + readonly lastAppliedTemplate?: NullableTemplateFilterEncoded | null | undefined + readonly lead?: NullableUserFilterEncoded | null | undefined + readonly leadTeam?: NullableTeamFilterEncoded | null | undefined + readonly length?: typeof NumberComparator.Encoded | null | undefined + readonly members?: UserCollectionFilterEncoded | null | undefined + readonly name?: typeof StringComparator.Encoded | null | undefined + readonly needs?: CustomerNeedCollectionFilterEncoded | null | undefined + readonly nextProjectMilestone?: ProjectMilestoneFilterEncoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly priority?: typeof NullableNumberComparator.Encoded | null | undefined + readonly projectMilestones?: ProjectMilestoneCollectionFilterEncoded | null | undefined + readonly projectUpdates?: ProjectUpdatesCollectionFilterEncoded | null | undefined + readonly roadmaps?: RoadmapCollectionFilterEncoded | null | undefined + readonly searchableContent?: typeof ContentComparator.Encoded | null | undefined + readonly slugId?: typeof StringComparator.Encoded | null | undefined + readonly some?: ProjectFilterEncoded | null | undefined + readonly startDate?: typeof NullableDateComparator.Encoded | null | undefined + readonly startedAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly state?: typeof StringComparator.Encoded | null | undefined + readonly status?: ProjectStatusFilterEncoded | null | undefined + readonly targetDate?: typeof NullableDateComparator.Encoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Milestone collection filtering options. */ +export const ProjectMilestoneCollectionFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => ProjectMilestoneCollectionFilter)))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + every: Schema.optional(Schema.NullOr(Schema.suspend(() => ProjectMilestoneFilter))), + id: Schema.optional(Schema.NullOr(IDComparator)), + length: Schema.optional(Schema.NullOr(NumberComparator)), + name: Schema.optional(Schema.NullOr(NullableStringComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => ProjectMilestoneCollectionFilter)))), + project: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableProjectFilter))), + some: Schema.optional(Schema.NullOr(Schema.suspend(() => ProjectMilestoneFilter))), + targetDate: Schema.optional(Schema.NullOr(NullableDateComparator)), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface ProjectMilestoneCollectionFilter { + /** Compound filters, all of which need to be matched by the milestone. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Filters that needs to be matched by all milestones. */ + readonly every?: ProjectMilestoneFilter | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Comparator for the collection length. */ + readonly length?: NumberComparator | null | undefined + /** Comparator for the project milestone name. */ + readonly name?: NullableStringComparator | null | undefined + /** Compound filters, one of which need to be matched by the milestone. */ + readonly or?: ReadonlyArray | null | undefined + /** Filters that the project milestone's project must satisfy. */ + readonly project?: NullableProjectFilter | null | undefined + /** Filters that needs to be matched by some milestones. */ + readonly some?: ProjectMilestoneFilter | null | undefined + /** Comparator for the project milestone target date. */ + readonly targetDate?: NullableDateComparator | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface ProjectMilestoneCollectionFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly every?: ProjectMilestoneFilterEncoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly length?: typeof NumberComparator.Encoded | null | undefined + readonly name?: typeof NullableStringComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly project?: NullableProjectFilterEncoded | null | undefined + readonly some?: ProjectMilestoneFilterEncoded | null | undefined + readonly targetDate?: typeof NullableDateComparator.Encoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Project milestone filtering options. */ +export const ProjectMilestoneFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => ProjectMilestoneFilter)))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + id: Schema.optional(Schema.NullOr(IDComparator)), + name: Schema.optional(Schema.NullOr(NullableStringComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => ProjectMilestoneFilter)))), + project: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableProjectFilter))), + targetDate: Schema.optional(Schema.NullOr(NullableDateComparator)), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface ProjectMilestoneFilter { + /** Compound filters, all of which need to be matched by the project milestone. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Comparator for the project milestone name. */ + readonly name?: NullableStringComparator | null | undefined + /** Compound filters, one of which need to be matched by the project milestone. */ + readonly or?: ReadonlyArray | null | undefined + /** Filters that the project milestone's project must satisfy. */ + readonly project?: NullableProjectFilter | null | undefined + /** Comparator for the project milestone target date. */ + readonly targetDate?: NullableDateComparator | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface ProjectMilestoneFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly name?: typeof NullableStringComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly project?: NullableProjectFilterEncoded | null | undefined + readonly targetDate?: typeof NullableDateComparator.Encoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Project filtering options. */ +export const NullableProjectFilter: Schema.Codec = Schema.Struct({ + accessibleTeams: Schema.optional(Schema.NullOr(Schema.suspend(() => TeamCollectionFilter))), + activityType: Schema.optional(Schema.NullOr(StringComparator)), + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => NullableProjectFilter)))), + canceledAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + completedAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + completedProjectMilestones: Schema.optional(Schema.NullOr(Schema.suspend(() => ProjectMilestoneCollectionFilter))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + creator: Schema.optional(Schema.NullOr(Schema.suspend(() => UserFilter))), + customIdentifier: Schema.optional(Schema.NullOr(NullableStringComparator)), + customerCount: Schema.optional(Schema.NullOr(NumberComparator)), + customerImportantCount: Schema.optional(Schema.NullOr(NumberComparator)), + hasBlockedByRelations: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasBlockingRelations: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasDependedOnByRelations: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasDependsOnRelations: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasRelatedRelations: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasViolatedRelations: Schema.optional(Schema.NullOr(RelationExistsComparator)), + health: Schema.optional(Schema.NullOr(StringComparator)), + healthWithAge: Schema.optional(Schema.NullOr(StringComparator)), + id: Schema.optional(Schema.NullOr(EntityIdentifierIDComparator)), + initiatives: Schema.optional(Schema.NullOr(Schema.suspend(() => InitiativeCollectionFilter))), + issues: Schema.optional(Schema.NullOr(Schema.suspend(() => IssueCollectionFilter))), + labels: Schema.optional(Schema.NullOr(Schema.suspend(() => ProjectLabelCollectionFilter))), + lastAppliedTemplate: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableTemplateFilter))), + lead: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableUserFilter))), + leadTeam: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableTeamFilter))), + members: Schema.optional(Schema.NullOr(Schema.suspend(() => UserCollectionFilter))), + name: Schema.optional(Schema.NullOr(StringComparator)), + needs: Schema.optional(Schema.NullOr(Schema.suspend(() => CustomerNeedCollectionFilter))), + nextProjectMilestone: Schema.optional(Schema.NullOr(Schema.suspend(() => ProjectMilestoneFilter))), + null: Schema.optional(Schema.NullOr(Schema.Boolean)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => NullableProjectFilter)))), + priority: Schema.optional(Schema.NullOr(NullableNumberComparator)), + projectMilestones: Schema.optional(Schema.NullOr(Schema.suspend(() => ProjectMilestoneCollectionFilter))), + projectUpdates: Schema.optional(Schema.NullOr(ProjectUpdatesCollectionFilter)), + roadmaps: Schema.optional(Schema.NullOr(Schema.suspend(() => RoadmapCollectionFilter))), + searchableContent: Schema.optional(Schema.NullOr(ContentComparator)), + slugId: Schema.optional(Schema.NullOr(StringComparator)), + startDate: Schema.optional(Schema.NullOr(NullableDateComparator)), + startedAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + state: Schema.optional(Schema.NullOr(StringComparator)), + status: Schema.optional(Schema.NullOr(Schema.suspend(() => ProjectStatusFilter))), + targetDate: Schema.optional(Schema.NullOr(NullableDateComparator)), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface NullableProjectFilter { + /** Filters that the project's team must satisfy. */ + readonly accessibleTeams?: TeamCollectionFilter | null | undefined + /** [ALPHA] Comparator for the project activity type: buzzin, active, some, none */ + readonly activityType?: StringComparator | null | undefined + /** Compound filters, all of which need to be matched by the project. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the project cancelation date. */ + readonly canceledAt?: NullableDateComparator | null | undefined + /** Comparator for the project completion date. */ + readonly completedAt?: NullableDateComparator | null | undefined + /** Filters that the project's completed milestones must satisfy. */ + readonly completedProjectMilestones?: ProjectMilestoneCollectionFilter | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Filters that the projects creator must satisfy. */ + readonly creator?: UserFilter | null | undefined + /** [Internal] Comparator for the project's custom identifier. */ + readonly customIdentifier?: NullableStringComparator | null | undefined + /** Count of customers */ + readonly customerCount?: NumberComparator | null | undefined + /** Count of important customers */ + readonly customerImportantCount?: NumberComparator | null | undefined + /** Comparator for filtering projects which are blocked. */ + readonly hasBlockedByRelations?: RelationExistsComparator | null | undefined + /** Comparator for filtering projects which are blocking. */ + readonly hasBlockingRelations?: RelationExistsComparator | null | undefined + /** [Deprecated] Comparator for filtering projects which this is depended on by. */ + readonly hasDependedOnByRelations?: RelationExistsComparator | null | undefined + /** [Deprecated]Comparator for filtering projects which this depends on. */ + readonly hasDependsOnRelations?: RelationExistsComparator | null | undefined + /** Comparator for filtering projects with relations. */ + readonly hasRelatedRelations?: RelationExistsComparator | null | undefined + /** Comparator for filtering projects with violated dependencies. */ + readonly hasViolatedRelations?: RelationExistsComparator | null | undefined + /** Comparator for the project health: onTrack, atRisk, offTrack */ + readonly health?: StringComparator | null | undefined + /** Comparator for the project health (with age): onTrack, atRisk, offTrack, outdated, noUpdate */ + readonly healthWithAge?: StringComparator | null | undefined + /** Comparator for the identifier. */ + readonly id?: EntityIdentifierIDComparator | null | undefined + /** Filters that the projects initiatives must satisfy. */ + readonly initiatives?: InitiativeCollectionFilter | null | undefined + /** Filters that the projects issues must satisfy. */ + readonly issues?: IssueCollectionFilter | null | undefined + /** Filters that project labels must satisfy. */ + readonly labels?: ProjectLabelCollectionFilter | null | undefined + /** Filters that the last applied template must satisfy. */ + readonly lastAppliedTemplate?: NullableTemplateFilter | null | undefined + /** Filters that the projects lead must satisfy. */ + readonly lead?: NullableUserFilter | null | undefined + /** [ALPHA] Filters that the project's lead team must satisfy. */ + readonly leadTeam?: NullableTeamFilter | null | undefined + /** Filters that the projects members must satisfy. */ + readonly members?: UserCollectionFilter | null | undefined + /** Comparator for the project name. */ + readonly name?: StringComparator | null | undefined + /** Filters that the project's customer needs must satisfy. */ + readonly needs?: CustomerNeedCollectionFilter | null | undefined + /** Filters that the project's next milestone must satisfy. */ + readonly nextProjectMilestone?: ProjectMilestoneFilter | null | undefined + /** Filter based on the existence of the relation. */ + readonly null?: boolean | null | undefined + /** Compound filters, one of which need to be matched by the project. */ + readonly or?: ReadonlyArray | null | undefined + /** Comparator for the project priority. */ + readonly priority?: NullableNumberComparator | null | undefined + /** Filters that the project's milestones must satisfy. */ + readonly projectMilestones?: ProjectMilestoneCollectionFilter | null | undefined + /** Comparator for the project updates. */ + readonly projectUpdates?: ProjectUpdatesCollectionFilter | null | undefined + /** Filters that the projects roadmaps must satisfy. */ + readonly roadmaps?: RoadmapCollectionFilter | null | undefined + /** [Internal] Comparator for the project's content. */ + readonly searchableContent?: ContentComparator | null | undefined + /** Comparator for the project slug ID. */ + readonly slugId?: StringComparator | null | undefined + /** Comparator for the project start date. */ + readonly startDate?: NullableDateComparator | null | undefined + /** Comparator for the project started date (when it was moved to an "In Progress" status). */ + readonly startedAt?: NullableDateComparator | null | undefined + /** [DEPRECATED] Comparator for the project state. */ + readonly state?: StringComparator | null | undefined + /** Filters that the project status must satisfy. */ + readonly status?: ProjectStatusFilter | null | undefined + /** Comparator for the project target date. */ + readonly targetDate?: NullableDateComparator | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface NullableProjectFilterEncoded { + readonly accessibleTeams?: TeamCollectionFilterEncoded | null | undefined + readonly activityType?: typeof StringComparator.Encoded | null | undefined + readonly and?: ReadonlyArray | null | undefined + readonly canceledAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly completedAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly completedProjectMilestones?: ProjectMilestoneCollectionFilterEncoded | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly creator?: UserFilterEncoded | null | undefined + readonly customIdentifier?: typeof NullableStringComparator.Encoded | null | undefined + readonly customerCount?: typeof NumberComparator.Encoded | null | undefined + readonly customerImportantCount?: typeof NumberComparator.Encoded | null | undefined + readonly hasBlockedByRelations?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasBlockingRelations?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasDependedOnByRelations?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasDependsOnRelations?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasRelatedRelations?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasViolatedRelations?: typeof RelationExistsComparator.Encoded | null | undefined + readonly health?: typeof StringComparator.Encoded | null | undefined + readonly healthWithAge?: typeof StringComparator.Encoded | null | undefined + readonly id?: typeof EntityIdentifierIDComparator.Encoded | null | undefined + readonly initiatives?: InitiativeCollectionFilterEncoded | null | undefined + readonly issues?: IssueCollectionFilterEncoded | null | undefined + readonly labels?: ProjectLabelCollectionFilterEncoded | null | undefined + readonly lastAppliedTemplate?: NullableTemplateFilterEncoded | null | undefined + readonly lead?: NullableUserFilterEncoded | null | undefined + readonly leadTeam?: NullableTeamFilterEncoded | null | undefined + readonly members?: UserCollectionFilterEncoded | null | undefined + readonly name?: typeof StringComparator.Encoded | null | undefined + readonly needs?: CustomerNeedCollectionFilterEncoded | null | undefined + readonly nextProjectMilestone?: ProjectMilestoneFilterEncoded | null | undefined + readonly null?: boolean | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly priority?: typeof NullableNumberComparator.Encoded | null | undefined + readonly projectMilestones?: ProjectMilestoneCollectionFilterEncoded | null | undefined + readonly projectUpdates?: ProjectUpdatesCollectionFilterEncoded | null | undefined + readonly roadmaps?: RoadmapCollectionFilterEncoded | null | undefined + readonly searchableContent?: typeof ContentComparator.Encoded | null | undefined + readonly slugId?: typeof StringComparator.Encoded | null | undefined + readonly startDate?: typeof NullableDateComparator.Encoded | null | undefined + readonly startedAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly state?: typeof StringComparator.Encoded | null | undefined + readonly status?: ProjectStatusFilterEncoded | null | undefined + readonly targetDate?: typeof NullableDateComparator.Encoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Project label filtering options. */ +export const ProjectLabelCollectionFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => ProjectLabelCollectionFilter)))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + creator: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableUserFilter))), + every: Schema.optional(Schema.NullOr(Schema.suspend(() => ProjectLabelFilter))), + id: Schema.optional(Schema.NullOr(IDComparator)), + isGroup: Schema.optional(Schema.NullOr(BooleanComparator)), + length: Schema.optional(Schema.NullOr(NumberComparator)), + name: Schema.optional(Schema.NullOr(StringComparator)), + null: Schema.optional(Schema.NullOr(Schema.Boolean)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => ProjectLabelCollectionFilter)))), + parent: Schema.optional(Schema.NullOr(Schema.suspend(() => ProjectLabelFilter))), + some: Schema.optional(Schema.NullOr(Schema.suspend(() => ProjectLabelCollectionFilter))), + team: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableTeamFilter))), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface ProjectLabelCollectionFilter { + /** Compound filters, all of which need to be matched by the label. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Filters that the project labels creator must satisfy. */ + readonly creator?: NullableUserFilter | null | undefined + /** Filters that needs to be matched by all project labels. */ + readonly every?: ProjectLabelFilter | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Comparator for whether the label is a group label. */ + readonly isGroup?: BooleanComparator | null | undefined + /** Comparator for the collection length. */ + readonly length?: NumberComparator | null | undefined + /** Comparator for the name. */ + readonly name?: StringComparator | null | undefined + /** Filter based on the existence of the relation. */ + readonly null?: boolean | null | undefined + /** Compound filters, one of which need to be matched by the label. */ + readonly or?: ReadonlyArray | null | undefined + /** Filters that the project label's parent label must satisfy. */ + readonly parent?: ProjectLabelFilter | null | undefined + /** Filters that needs to be matched by some project labels. */ + readonly some?: ProjectLabelCollectionFilter | null | undefined + /** Filters that the project label's team must satisfy. Use `{ null: true }` to filter workspace-level labels. */ + readonly team?: NullableTeamFilter | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface ProjectLabelCollectionFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly creator?: NullableUserFilterEncoded | null | undefined + readonly every?: ProjectLabelFilterEncoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly isGroup?: typeof BooleanComparator.Encoded | null | undefined + readonly length?: typeof NumberComparator.Encoded | null | undefined + readonly name?: typeof StringComparator.Encoded | null | undefined + readonly null?: boolean | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly parent?: ProjectLabelFilterEncoded | null | undefined + readonly some?: ProjectLabelCollectionFilterEncoded | null | undefined + readonly team?: NullableTeamFilterEncoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Project label filtering options. */ +export const ProjectLabelFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => ProjectLabelFilter)))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + creator: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableUserFilter))), + id: Schema.optional(Schema.NullOr(IDComparator)), + isGroup: Schema.optional(Schema.NullOr(BooleanComparator)), + name: Schema.optional(Schema.NullOr(StringComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => ProjectLabelFilter)))), + parent: Schema.optional(Schema.NullOr(Schema.suspend(() => ProjectLabelFilter))), + team: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableTeamFilter))), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface ProjectLabelFilter { + /** Compound filters, all of which need to be matched by the label. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Filters that the project labels creator must satisfy. */ + readonly creator?: NullableUserFilter | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Comparator for whether the label is a group label. */ + readonly isGroup?: BooleanComparator | null | undefined + /** Comparator for the name. */ + readonly name?: StringComparator | null | undefined + /** Compound filters, one of which need to be matched by the label. */ + readonly or?: ReadonlyArray | null | undefined + /** Filters that the project label's parent label must satisfy. */ + readonly parent?: ProjectLabelFilter | null | undefined + /** Filters that the project label's team must satisfy. Use `{ null: true }` to filter workspace-level labels. */ + readonly team?: NullableTeamFilter | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface ProjectLabelFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly creator?: NullableUserFilterEncoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly isGroup?: typeof BooleanComparator.Encoded | null | undefined + readonly name?: typeof StringComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly parent?: ProjectLabelFilterEncoded | null | undefined + readonly team?: NullableTeamFilterEncoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Template filtering options. */ +export const NullableTemplateFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => NullableTemplateFilter)))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + id: Schema.optional(Schema.NullOr(IDComparator)), + inheritedFromId: Schema.optional(Schema.NullOr(IDComparator)), + name: Schema.optional(Schema.NullOr(StringComparator)), + null: Schema.optional(Schema.NullOr(Schema.Boolean)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => NullableTemplateFilter)))), + team: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableTeamFilter))), + type: Schema.optional(Schema.NullOr(StringComparator)), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface NullableTemplateFilter { + /** Compound filters, all of which need to be matched by the template. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Comparator for the inherited template's ID. */ + readonly inheritedFromId?: IDComparator | null | undefined + /** Comparator for the template's name. */ + readonly name?: StringComparator | null | undefined + /** Filter based on the existence of the relation. */ + readonly null?: boolean | null | undefined + /** Compound filters, one of which need to be matched by the template. */ + readonly or?: ReadonlyArray | null | undefined + /** Filters that the template's team must satisfy. */ + readonly team?: NullableTeamFilter | null | undefined + /** Comparator for the template's type. */ + readonly type?: StringComparator | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface NullableTemplateFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly inheritedFromId?: typeof IDComparator.Encoded | null | undefined + readonly name?: typeof StringComparator.Encoded | null | undefined + readonly null?: boolean | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly team?: NullableTeamFilterEncoded | null | undefined + readonly type?: typeof StringComparator.Encoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Customer needs filtering options. */ +export const CustomerNeedCollectionFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => CustomerNeedCollectionFilter)))), + comment: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableCommentFilter))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + customer: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableCustomerFilter))), + every: Schema.optional(Schema.NullOr(Schema.suspend(() => CustomerNeedFilter))), + id: Schema.optional(Schema.NullOr(IDComparator)), + issue: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableIssueFilter))), + length: Schema.optional(Schema.NullOr(NumberComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => CustomerNeedCollectionFilter)))), + priority: Schema.optional(Schema.NullOr(NumberComparator)), + project: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableProjectFilter))), + some: Schema.optional(Schema.NullOr(Schema.suspend(() => CustomerNeedFilter))), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface CustomerNeedCollectionFilter { + /** Compound filters, all of which need to be matched by the customer needs. */ + readonly and?: ReadonlyArray | null | undefined + /** Filters that the need's comment must satisfy. */ + readonly comment?: NullableCommentFilter | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Filters that the need's customer must satisfy. */ + readonly customer?: NullableCustomerFilter | null | undefined + /** Filters that needs to be matched by all customer needs. */ + readonly every?: CustomerNeedFilter | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Filters that the need's issue must satisfy. */ + readonly issue?: NullableIssueFilter | null | undefined + /** Comparator for the collection length. */ + readonly length?: NumberComparator | null | undefined + /** Compound filters, one of which need to be matched by the customer needs. */ + readonly or?: ReadonlyArray | null | undefined + /** Comparator for the customer need priority. */ + readonly priority?: NumberComparator | null | undefined + /** Filters that the need's project must satisfy. */ + readonly project?: NullableProjectFilter | null | undefined + /** Filters that needs to be matched by some customer needs. */ + readonly some?: CustomerNeedFilter | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface CustomerNeedCollectionFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly comment?: NullableCommentFilterEncoded | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly customer?: NullableCustomerFilterEncoded | null | undefined + readonly every?: CustomerNeedFilterEncoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly issue?: NullableIssueFilterEncoded | null | undefined + readonly length?: typeof NumberComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly priority?: typeof NumberComparator.Encoded | null | undefined + readonly project?: NullableProjectFilterEncoded | null | undefined + readonly some?: CustomerNeedFilterEncoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Comment filtering options. */ +export const NullableCommentFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => NullableCommentFilter)))), + body: Schema.optional(Schema.NullOr(StringComparator)), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + documentContent: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableDocumentContentFilter))), + id: Schema.optional(Schema.NullOr(IDComparator)), + initiative: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableInitiativeFilter))), + initiativeUpdate: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableInitiativeUpdateFilter))), + issue: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableIssueFilter))), + needs: Schema.optional(Schema.NullOr(Schema.suspend(() => CustomerNeedCollectionFilter))), + null: Schema.optional(Schema.NullOr(Schema.Boolean)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => NullableCommentFilter)))), + parent: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableCommentFilter))), + project: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableProjectFilter))), + projectUpdate: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableProjectUpdateFilter))), + reactions: Schema.optional(Schema.NullOr(ReactionCollectionFilter)), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)), + user: Schema.optional(Schema.NullOr(Schema.suspend(() => UserFilter))) +}) +export interface NullableCommentFilter { + /** Compound filters, all of which need to be matched by the comment. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the comment's body. */ + readonly body?: StringComparator | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Filters that the comment's document content must satisfy. */ + readonly documentContent?: NullableDocumentContentFilter | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** [Internal] Filters that the comment's initiative must satisfy. */ + readonly initiative?: NullableInitiativeFilter | null | undefined + /** Filters that the comment's initiative update must satisfy. */ + readonly initiativeUpdate?: NullableInitiativeUpdateFilter | null | undefined + /** Filters that the comment's issue must satisfy. */ + readonly issue?: NullableIssueFilter | null | undefined + /** Filters that the comment's customer needs must satisfy. */ + readonly needs?: CustomerNeedCollectionFilter | null | undefined + /** Filter based on the existence of the relation. */ + readonly null?: boolean | null | undefined + /** Compound filters, one of which need to be matched by the comment. */ + readonly or?: ReadonlyArray | null | undefined + /** Filters that the comment parent must satisfy. */ + readonly parent?: NullableCommentFilter | null | undefined + /** [Internal] Filters that the comment's project must satisfy. */ + readonly project?: NullableProjectFilter | null | undefined + /** Filters that the comment's project update must satisfy. */ + readonly projectUpdate?: NullableProjectUpdateFilter | null | undefined + /** Filters that the comment's reactions must satisfy. */ + readonly reactions?: ReactionCollectionFilter | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined + /** Filters that the comment's creator must satisfy. */ + readonly user?: UserFilter | null | undefined +} +export interface NullableCommentFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly body?: typeof StringComparator.Encoded | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly documentContent?: NullableDocumentContentFilterEncoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly initiative?: NullableInitiativeFilterEncoded | null | undefined + readonly initiativeUpdate?: NullableInitiativeUpdateFilterEncoded | null | undefined + readonly issue?: NullableIssueFilterEncoded | null | undefined + readonly needs?: CustomerNeedCollectionFilterEncoded | null | undefined + readonly null?: boolean | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly parent?: NullableCommentFilterEncoded | null | undefined + readonly project?: NullableProjectFilterEncoded | null | undefined + readonly projectUpdate?: NullableProjectUpdateFilterEncoded | null | undefined + readonly reactions?: ReactionCollectionFilterEncoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined + readonly user?: UserFilterEncoded | null | undefined +} + +/** Initiative filtering options. */ +export const NullableInitiativeFilter: Schema.Codec = Schema.Struct({ + activityType: Schema.optional(Schema.NullOr(StringComparator)), + ancestors: Schema.optional(Schema.NullOr(Schema.suspend(() => InitiativeCollectionFilter))), + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => NullableInitiativeFilter)))), + canceledAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + completedAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + creator: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableUserFilter))), + customIdentifier: Schema.optional(Schema.NullOr(NullableStringComparator)), + health: Schema.optional(Schema.NullOr(StringComparator)), + healthWithAge: Schema.optional(Schema.NullOr(StringComparator)), + id: Schema.optional(Schema.NullOr(EntityIdentifierIDComparator)), + initiativeUpdates: Schema.optional(Schema.NullOr(InitiativeUpdatesCollectionFilter)), + labels: Schema.optional(Schema.NullOr(Schema.suspend(() => InitiativeLabelCollectionFilter))), + leadTeam: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableTeamFilter))), + name: Schema.optional(Schema.NullOr(StringComparator)), + null: Schema.optional(Schema.NullOr(Schema.Boolean)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => NullableInitiativeFilter)))), + owner: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableUserFilter))), + priority: Schema.optional(Schema.NullOr(NullableNumberComparator)), + projects: Schema.optional(Schema.NullOr(Schema.suspend(() => ProjectCollectionFilter))), + slugId: Schema.optional(Schema.NullOr(StringComparator)), + startedAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + status: Schema.optional(Schema.NullOr(StringComparator)), + targetDate: Schema.optional(Schema.NullOr(NullableDateComparator)), + teams: Schema.optional(Schema.NullOr(Schema.suspend(() => TeamCollectionFilter))), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface NullableInitiativeFilter { + /** Comparator for the initiative activity type. */ + readonly activityType?: StringComparator | null | undefined + /** Filters that the initiative must be an ancestor of. */ + readonly ancestors?: InitiativeCollectionFilter | null | undefined + /** Compound filters, all of which need to be matched by the initiative. */ + readonly and?: ReadonlyArray | null | undefined + /** [Internal] Comparator for the initiative canceled at date. */ + readonly canceledAt?: NullableDateComparator | null | undefined + /** Comparator for the initiative completed at date. */ + readonly completedAt?: NullableDateComparator | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Filters that the initiative creator must satisfy. */ + readonly creator?: NullableUserFilter | null | undefined + /** [Internal] Comparator for the initiative's custom identifier. */ + readonly customIdentifier?: NullableStringComparator | null | undefined + /** Comparator for the initiative health: onTrack, atRisk, offTrack */ + readonly health?: StringComparator | null | undefined + /** Comparator for the initiative health (with age): onTrack, atRisk, offTrack, outdated, noUpdate */ + readonly healthWithAge?: StringComparator | null | undefined + /** Comparator for the identifier. */ + readonly id?: EntityIdentifierIDComparator | null | undefined + /** Filters that the initiative updates must satisfy. */ + readonly initiativeUpdates?: InitiativeUpdatesCollectionFilter | null | undefined + /** Filters that the initiative labels must satisfy. */ + readonly labels?: InitiativeLabelCollectionFilter | null | undefined + /** Filters that the initiative lead team must satisfy. */ + readonly leadTeam?: NullableTeamFilter | null | undefined + /** Comparator for the initiative name. */ + readonly name?: StringComparator | null | undefined + /** Filter based on the existence of the relation. */ + readonly null?: boolean | null | undefined + /** Compound filters, one of which need to be matched by the initiative. */ + readonly or?: ReadonlyArray | null | undefined + /** Filters that the initiative owner must satisfy. */ + readonly owner?: NullableUserFilter | null | undefined + /** Comparator for the initiative priority. */ + readonly priority?: NullableNumberComparator | null | undefined + /** Filters that the initiative projects must satisfy. */ + readonly projects?: ProjectCollectionFilter | null | undefined + /** Comparator for the initiative slug ID. */ + readonly slugId?: StringComparator | null | undefined + /** Comparator for the initiative started at date. */ + readonly startedAt?: NullableDateComparator | null | undefined + /** Comparator for the initiative status: Proposed, Planned, Active, Completed, Canceled */ + readonly status?: StringComparator | null | undefined + /** Comparator for the initiative target date. */ + readonly targetDate?: NullableDateComparator | null | undefined + /** Filters that the initiative teams must satisfy. */ + readonly teams?: TeamCollectionFilter | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface NullableInitiativeFilterEncoded { + readonly activityType?: typeof StringComparator.Encoded | null | undefined + readonly ancestors?: InitiativeCollectionFilterEncoded | null | undefined + readonly and?: ReadonlyArray | null | undefined + readonly canceledAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly completedAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly creator?: NullableUserFilterEncoded | null | undefined + readonly customIdentifier?: typeof NullableStringComparator.Encoded | null | undefined + readonly health?: typeof StringComparator.Encoded | null | undefined + readonly healthWithAge?: typeof StringComparator.Encoded | null | undefined + readonly id?: typeof EntityIdentifierIDComparator.Encoded | null | undefined + readonly initiativeUpdates?: InitiativeUpdatesCollectionFilterEncoded | null | undefined + readonly labels?: InitiativeLabelCollectionFilterEncoded | null | undefined + readonly leadTeam?: NullableTeamFilterEncoded | null | undefined + readonly name?: typeof StringComparator.Encoded | null | undefined + readonly null?: boolean | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly owner?: NullableUserFilterEncoded | null | undefined + readonly priority?: typeof NullableNumberComparator.Encoded | null | undefined + readonly projects?: ProjectCollectionFilterEncoded | null | undefined + readonly slugId?: typeof StringComparator.Encoded | null | undefined + readonly startedAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly status?: typeof StringComparator.Encoded | null | undefined + readonly targetDate?: typeof NullableDateComparator.Encoded | null | undefined + readonly teams?: TeamCollectionFilterEncoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Nullable initiative update filtering options. */ +export const NullableInitiativeUpdateFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => NullableInitiativeUpdateFilter)))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + id: Schema.optional(Schema.NullOr(IDComparator)), + initiative: Schema.optional(Schema.NullOr(Schema.suspend(() => InitiativeFilter))), + null: Schema.optional(Schema.NullOr(Schema.Boolean)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => NullableInitiativeUpdateFilter)))), + reactions: Schema.optional(Schema.NullOr(ReactionCollectionFilter)), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)), + user: Schema.optional(Schema.NullOr(Schema.suspend(() => UserFilter))) +}) +export interface NullableInitiativeUpdateFilter { + /** Compound filters, all of which need to be matched by the initiative update. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Filters that the initiative update initiative must satisfy. */ + readonly initiative?: InitiativeFilter | null | undefined + /** Filter based on the existence of the relation. */ + readonly null?: boolean | null | undefined + /** Compound filters, one of which need to be matched by the initiative update. */ + readonly or?: ReadonlyArray | null | undefined + /** Filters that the initiative updates reactions must satisfy. */ + readonly reactions?: ReactionCollectionFilter | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined + /** Filters that the initiative update creator must satisfy. */ + readonly user?: UserFilter | null | undefined +} +export interface NullableInitiativeUpdateFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly initiative?: InitiativeFilterEncoded | null | undefined + readonly null?: boolean | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly reactions?: ReactionCollectionFilterEncoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined + readonly user?: UserFilterEncoded | null | undefined +} + +/** Issue filtering options. */ +export const NullableIssueFilter: Schema.Codec = Schema.Struct({ + accumulatedStateUpdatedAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + activity: Schema.optional(Schema.NullOr(Schema.suspend(() => ActivityCollectionFilter))), + addedToCycleAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + addedToCyclePeriod: Schema.optional(Schema.NullOr(CyclePeriodComparator)), + ageTime: Schema.optional(Schema.NullOr(NullableDurationComparator)), + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => NullableIssueFilter)))), + archivedAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + assignee: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableUserFilter))), + attachments: Schema.optional(Schema.NullOr(Schema.suspend(() => AttachmentCollectionFilter))), + autoArchivedAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + autoClosedAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + canceledAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + children: Schema.optional(Schema.NullOr(Schema.suspend(() => IssueCollectionFilter))), + comments: Schema.optional(Schema.NullOr(Schema.suspend(() => CommentCollectionFilter))), + completedAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + creator: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableUserFilter))), + customerCount: Schema.optional(Schema.NullOr(NumberComparator)), + customerImportantCount: Schema.optional(Schema.NullOr(NumberComparator)), + cycle: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableCycleFilter))), + cycleTime: Schema.optional(Schema.NullOr(NullableDurationComparator)), + delegate: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableUserFilter))), + description: Schema.optional(Schema.NullOr(NullableStringComparator)), + dueDate: Schema.optional(Schema.NullOr(NullableTimelessDateComparator)), + estimate: Schema.optional(Schema.NullOr(EstimateComparator)), + hasActiveAgentSessions: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasBlockedByRelations: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasBlockingRelations: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasDismissedAgentSessions: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasDuplicateRelations: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasErroredAgentSessions: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasMergedAgentPullRequests: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasRelatedRelations: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasSharedUsers: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasSuggestedAssignees: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasSuggestedLabels: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasSuggestedProjects: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasSuggestedRelatedIssues: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasSuggestedSimilarIssues: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasSuggestedTeams: Schema.optional(Schema.NullOr(RelationExistsComparator)), + id: Schema.optional(Schema.NullOr(IssueIDComparator)), + labels: Schema.optional(Schema.NullOr(Schema.suspend(() => IssueLabelCollectionFilter))), + lastAppliedTemplate: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableTemplateFilter))), + leadTime: Schema.optional(Schema.NullOr(NullableDurationComparator)), + needs: Schema.optional(Schema.NullOr(Schema.suspend(() => CustomerNeedCollectionFilter))), + null: Schema.optional(Schema.NullOr(Schema.Boolean)), + number: Schema.optional(Schema.NullOr(NumberComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => NullableIssueFilter)))), + parent: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableIssueFilter))), + priority: Schema.optional(Schema.NullOr(NullableNumberComparator)), + project: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableProjectFilter))), + projectMilestone: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableProjectMilestoneFilter))), + reactions: Schema.optional(Schema.NullOr(ReactionCollectionFilter)), + recurringIssueTemplate: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableTemplateFilter))), + releases: Schema.optional(Schema.NullOr(Schema.suspend(() => ReleaseCollectionFilter))), + searchableContent: Schema.optional(Schema.NullOr(ContentComparator)), + sharedWith: Schema.optional(Schema.NullOr(Schema.suspend(() => UserCollectionFilter))), + slaBreachesAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + slaStatus: Schema.optional(Schema.NullOr(SlaStatusComparator)), + snoozedBy: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableUserFilter))), + snoozedUntilAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + sourceMetadata: Schema.optional(Schema.NullOr(SourceMetadataComparator)), + startedAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + state: Schema.optional(Schema.NullOr(Schema.suspend(() => WorkflowStateFilter))), + subscribers: Schema.optional(Schema.NullOr(Schema.suspend(() => UserCollectionFilter))), + suggestions: Schema.optional(Schema.NullOr(Schema.suspend(() => IssueSuggestionCollectionFilter))), + team: Schema.optional(Schema.NullOr(Schema.suspend(() => TeamFilter))), + title: Schema.optional(Schema.NullOr(StringComparator)), + triageTime: Schema.optional(Schema.NullOr(NullableDurationComparator)), + triagedAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface NullableIssueFilter { + /** [Internal] Comparator for the issue's accumulatedStateUpdatedAt date. */ + readonly accumulatedStateUpdatedAt?: NullableDateComparator | null | undefined + /** Filters that the issue's activities must satisfy. */ + readonly activity?: ActivityCollectionFilter | null | undefined + /** Comparator for the issues added to cycle at date. */ + readonly addedToCycleAt?: NullableDateComparator | null | undefined + /** Comparator for the period when issue was added to a cycle. */ + readonly addedToCyclePeriod?: CyclePeriodComparator | null | undefined + /** [Internal] Age (created -> now) comparator, defined if the issue is still open. */ + readonly ageTime?: NullableDurationComparator | null | undefined + /** Compound filters, all of which need to be matched by the issue. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the issues archived at date. */ + readonly archivedAt?: NullableDateComparator | null | undefined + /** Filters that the issues assignee must satisfy. */ + readonly assignee?: NullableUserFilter | null | undefined + /** Filters that the issues attachments must satisfy. */ + readonly attachments?: AttachmentCollectionFilter | null | undefined + /** Comparator for the issues auto archived at date. */ + readonly autoArchivedAt?: NullableDateComparator | null | undefined + /** Comparator for the issues auto closed at date. */ + readonly autoClosedAt?: NullableDateComparator | null | undefined + /** Comparator for the issues canceled at date. */ + readonly canceledAt?: NullableDateComparator | null | undefined + /** Filters that the child issues must satisfy. */ + readonly children?: IssueCollectionFilter | null | undefined + /** Filters that the issues comments must satisfy. */ + readonly comments?: CommentCollectionFilter | null | undefined + /** Comparator for the issues completed at date. */ + readonly completedAt?: NullableDateComparator | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Filters that the issues creator must satisfy. */ + readonly creator?: NullableUserFilter | null | undefined + /** Count of customers */ + readonly customerCount?: NumberComparator | null | undefined + /** Count of important customers */ + readonly customerImportantCount?: NumberComparator | null | undefined + /** Filters that the issues cycle must satisfy. */ + readonly cycle?: NullableCycleFilter | null | undefined + /** [Internal] Cycle time (started -> completed) comparator. */ + readonly cycleTime?: NullableDurationComparator | null | undefined + /** Filters that the issue's delegated agent must satisfy. */ + readonly delegate?: NullableUserFilter | null | undefined + /** Comparator for the issues description. */ + readonly description?: NullableStringComparator | null | undefined + /** Comparator for the issues due date. */ + readonly dueDate?: NullableTimelessDateComparator | null | undefined + /** Comparator for the issues estimate. */ + readonly estimate?: EstimateComparator | null | undefined + /** [Internal] Comparator for filtering issues bucketed as having active agent sessions, no closed agent pull requests, and no merged agent pull requests. */ + readonly hasActiveAgentSessions?: RelationExistsComparator | null | undefined + /** Comparator for filtering issues which are blocked. */ + readonly hasBlockedByRelations?: RelationExistsComparator | null | undefined + /** Comparator for filtering issues which are blocking. */ + readonly hasBlockingRelations?: RelationExistsComparator | null | undefined + /** [Internal] Comparator for filtering issues bucketed as having all agent sessions dismissed or closed, and no merged agent pull requests. */ + readonly hasDismissedAgentSessions?: RelationExistsComparator | null | undefined + /** Comparator for filtering issues which are duplicates. */ + readonly hasDuplicateRelations?: RelationExistsComparator | null | undefined + /** [Internal] Comparator for filtering issues bucketed as having an errored agent session, no active sessions, and no merged agent pull requests. */ + readonly hasErroredAgentSessions?: RelationExistsComparator | null | undefined + /** [Internal] Comparator for filtering issues which have agent-session-linked pull requests that were merged. */ + readonly hasMergedAgentPullRequests?: RelationExistsComparator | null | undefined + /** Comparator for filtering issues with relations. */ + readonly hasRelatedRelations?: RelationExistsComparator | null | undefined + /** Comparator for filtering issues which have been shared with users outside of the team. */ + readonly hasSharedUsers?: RelationExistsComparator | null | undefined + /** [Internal] Comparator for filtering issues which have suggested assignees. */ + readonly hasSuggestedAssignees?: RelationExistsComparator | null | undefined + /** [Internal] Comparator for filtering issues which have suggested labels. */ + readonly hasSuggestedLabels?: RelationExistsComparator | null | undefined + /** [Internal] Comparator for filtering issues which have suggested projects. */ + readonly hasSuggestedProjects?: RelationExistsComparator | null | undefined + /** [Internal] Comparator for filtering issues which have suggested related issues. */ + readonly hasSuggestedRelatedIssues?: RelationExistsComparator | null | undefined + /** [Internal] Comparator for filtering issues which have suggested similar issues. */ + readonly hasSuggestedSimilarIssues?: RelationExistsComparator | null | undefined + /** [Internal] Comparator for filtering issues which have suggested teams. */ + readonly hasSuggestedTeams?: RelationExistsComparator | null | undefined + /** Comparator for the identifier. */ + readonly id?: IssueIDComparator | null | undefined + /** Filters that issue labels must satisfy. */ + readonly labels?: IssueLabelCollectionFilter | null | undefined + /** Filters that the last applied template must satisfy. */ + readonly lastAppliedTemplate?: NullableTemplateFilter | null | undefined + /** [Internal] Lead time (created -> completed) comparator. */ + readonly leadTime?: NullableDurationComparator | null | undefined + /** Filters that the issue's customer needs must satisfy. */ + readonly needs?: CustomerNeedCollectionFilter | null | undefined + /** Filter based on the existence of the relation. */ + readonly null?: boolean | null | undefined + /** Comparator for the issues number. */ + readonly number?: NumberComparator | null | undefined + /** Compound filters, one of which need to be matched by the issue. */ + readonly or?: ReadonlyArray | null | undefined + /** Filters that the issue parent must satisfy. */ + readonly parent?: NullableIssueFilter | null | undefined + /** Comparator for the issues priority. 0 = No priority, 1 = Urgent, 2 = High, 3 = Medium, 4 = Low. */ + readonly priority?: NullableNumberComparator | null | undefined + /** Filters that the issues project must satisfy. */ + readonly project?: NullableProjectFilter | null | undefined + /** Filters that the issues project milestone must satisfy. */ + readonly projectMilestone?: NullableProjectMilestoneFilter | null | undefined + /** Filters that the issues reactions must satisfy. */ + readonly reactions?: ReactionCollectionFilter | null | undefined + /** [ALPHA] Filters that the recurring issue template must satisfy. */ + readonly recurringIssueTemplate?: NullableTemplateFilter | null | undefined + /** Filters that the issue's releases must satisfy. */ + readonly releases?: ReleaseCollectionFilter | null | undefined + /** [Internal] Comparator for the issues content. */ + readonly searchableContent?: ContentComparator | null | undefined + /** Filters that users the issue has been shared with must satisfy. */ + readonly sharedWith?: UserCollectionFilter | null | undefined + /** Comparator for the issue's SLA breach date. */ + readonly slaBreachesAt?: NullableDateComparator | null | undefined + /** Comparator for the issues sla status. */ + readonly slaStatus?: SlaStatusComparator | null | undefined + /** Filters that the issues snoozer must satisfy. */ + readonly snoozedBy?: NullableUserFilter | null | undefined + /** Comparator for the issues snoozed until date. */ + readonly snoozedUntilAt?: NullableDateComparator | null | undefined + /** Filters that the source must satisfy. */ + readonly sourceMetadata?: SourceMetadataComparator | null | undefined + /** Comparator for the issues started at date. */ + readonly startedAt?: NullableDateComparator | null | undefined + /** Filters that the issues state must satisfy. */ + readonly state?: WorkflowStateFilter | null | undefined + /** Filters that issue subscribers must satisfy. */ + readonly subscribers?: UserCollectionFilter | null | undefined + /** [Internal] Filters that the issue's suggestions must satisfy. */ + readonly suggestions?: IssueSuggestionCollectionFilter | null | undefined + /** Filters that the issues team must satisfy. */ + readonly team?: TeamFilter | null | undefined + /** Comparator for the issues title. */ + readonly title?: StringComparator | null | undefined + /** [Internal] Triage time (entered triaged -> triaged) comparator. */ + readonly triageTime?: NullableDurationComparator | null | undefined + /** Comparator for the issues triaged at date. */ + readonly triagedAt?: NullableDateComparator | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface NullableIssueFilterEncoded { + readonly accumulatedStateUpdatedAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly activity?: ActivityCollectionFilterEncoded | null | undefined + readonly addedToCycleAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly addedToCyclePeriod?: typeof CyclePeriodComparator.Encoded | null | undefined + readonly ageTime?: typeof NullableDurationComparator.Encoded | null | undefined + readonly and?: ReadonlyArray | null | undefined + readonly archivedAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly assignee?: NullableUserFilterEncoded | null | undefined + readonly attachments?: AttachmentCollectionFilterEncoded | null | undefined + readonly autoArchivedAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly autoClosedAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly canceledAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly children?: IssueCollectionFilterEncoded | null | undefined + readonly comments?: CommentCollectionFilterEncoded | null | undefined + readonly completedAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly creator?: NullableUserFilterEncoded | null | undefined + readonly customerCount?: typeof NumberComparator.Encoded | null | undefined + readonly customerImportantCount?: typeof NumberComparator.Encoded | null | undefined + readonly cycle?: NullableCycleFilterEncoded | null | undefined + readonly cycleTime?: typeof NullableDurationComparator.Encoded | null | undefined + readonly delegate?: NullableUserFilterEncoded | null | undefined + readonly description?: typeof NullableStringComparator.Encoded | null | undefined + readonly dueDate?: typeof NullableTimelessDateComparator.Encoded | null | undefined + readonly estimate?: typeof EstimateComparator.Encoded | null | undefined + readonly hasActiveAgentSessions?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasBlockedByRelations?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasBlockingRelations?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasDismissedAgentSessions?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasDuplicateRelations?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasErroredAgentSessions?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasMergedAgentPullRequests?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasRelatedRelations?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasSharedUsers?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasSuggestedAssignees?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasSuggestedLabels?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasSuggestedProjects?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasSuggestedRelatedIssues?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasSuggestedSimilarIssues?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasSuggestedTeams?: typeof RelationExistsComparator.Encoded | null | undefined + readonly id?: typeof IssueIDComparator.Encoded | null | undefined + readonly labels?: IssueLabelCollectionFilterEncoded | null | undefined + readonly lastAppliedTemplate?: NullableTemplateFilterEncoded | null | undefined + readonly leadTime?: typeof NullableDurationComparator.Encoded | null | undefined + readonly needs?: CustomerNeedCollectionFilterEncoded | null | undefined + readonly null?: boolean | null | undefined + readonly number?: typeof NumberComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly parent?: NullableIssueFilterEncoded | null | undefined + readonly priority?: typeof NullableNumberComparator.Encoded | null | undefined + readonly project?: NullableProjectFilterEncoded | null | undefined + readonly projectMilestone?: NullableProjectMilestoneFilterEncoded | null | undefined + readonly reactions?: ReactionCollectionFilterEncoded | null | undefined + readonly recurringIssueTemplate?: NullableTemplateFilterEncoded | null | undefined + readonly releases?: ReleaseCollectionFilterEncoded | null | undefined + readonly searchableContent?: typeof ContentComparator.Encoded | null | undefined + readonly sharedWith?: UserCollectionFilterEncoded | null | undefined + readonly slaBreachesAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly slaStatus?: typeof SlaStatusComparator.Encoded | null | undefined + readonly snoozedBy?: NullableUserFilterEncoded | null | undefined + readonly snoozedUntilAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly sourceMetadata?: typeof SourceMetadataComparator.Encoded | null | undefined + readonly startedAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly state?: WorkflowStateFilterEncoded | null | undefined + readonly subscribers?: UserCollectionFilterEncoded | null | undefined + readonly suggestions?: IssueSuggestionCollectionFilterEncoded | null | undefined + readonly team?: TeamFilterEncoded | null | undefined + readonly title?: typeof StringComparator.Encoded | null | undefined + readonly triageTime?: typeof NullableDurationComparator.Encoded | null | undefined + readonly triagedAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Cycle filtering options. */ +export const NullableCycleFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => NullableCycleFilter)))), + completedAt: Schema.optional(Schema.NullOr(DateComparator)), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + endsAt: Schema.optional(Schema.NullOr(DateComparator)), + id: Schema.optional(Schema.NullOr(IDComparator)), + inheritedFromId: Schema.optional(Schema.NullOr(IDComparator)), + isActive: Schema.optional(Schema.NullOr(BooleanComparator)), + isFuture: Schema.optional(Schema.NullOr(BooleanComparator)), + isInCooldown: Schema.optional(Schema.NullOr(BooleanComparator)), + isNext: Schema.optional(Schema.NullOr(BooleanComparator)), + isPast: Schema.optional(Schema.NullOr(BooleanComparator)), + isPrevious: Schema.optional(Schema.NullOr(BooleanComparator)), + issues: Schema.optional(Schema.NullOr(Schema.suspend(() => IssueCollectionFilter))), + name: Schema.optional(Schema.NullOr(StringComparator)), + null: Schema.optional(Schema.NullOr(Schema.Boolean)), + number: Schema.optional(Schema.NullOr(NumberComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => NullableCycleFilter)))), + startsAt: Schema.optional(Schema.NullOr(DateComparator)), + team: Schema.optional(Schema.NullOr(Schema.suspend(() => TeamFilter))), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface NullableCycleFilter { + /** Compound filters, all of which need to be matched by the cycle. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the cycle completed at date. */ + readonly completedAt?: DateComparator | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Comparator for the cycle ends at date. */ + readonly endsAt?: DateComparator | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Comparator for the inherited cycle ID. */ + readonly inheritedFromId?: IDComparator | null | undefined + /** Comparator for the filtering active cycle. */ + readonly isActive?: BooleanComparator | null | undefined + /** Comparator for the filtering future cycles. */ + readonly isFuture?: BooleanComparator | null | undefined + /** Comparator for filtering for whether the cycle is currently in cooldown. */ + readonly isInCooldown?: BooleanComparator | null | undefined + /** Comparator for the filtering next cycle. */ + readonly isNext?: BooleanComparator | null | undefined + /** Comparator for the filtering past cycles. */ + readonly isPast?: BooleanComparator | null | undefined + /** Comparator for the filtering previous cycle. */ + readonly isPrevious?: BooleanComparator | null | undefined + /** Filters that the cycles issues must satisfy. */ + readonly issues?: IssueCollectionFilter | null | undefined + /** Comparator for the cycle name. */ + readonly name?: StringComparator | null | undefined + /** Filter based on the existence of the relation. */ + readonly null?: boolean | null | undefined + /** Comparator for the cycle number. */ + readonly number?: NumberComparator | null | undefined + /** Compound filters, one of which need to be matched by the cycle. */ + readonly or?: ReadonlyArray | null | undefined + /** Comparator for the cycle start date. */ + readonly startsAt?: DateComparator | null | undefined + /** Filters that the cycles team must satisfy. */ + readonly team?: TeamFilter | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface NullableCycleFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly completedAt?: typeof DateComparator.Encoded | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly endsAt?: typeof DateComparator.Encoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly inheritedFromId?: typeof IDComparator.Encoded | null | undefined + readonly isActive?: typeof BooleanComparator.Encoded | null | undefined + readonly isFuture?: typeof BooleanComparator.Encoded | null | undefined + readonly isInCooldown?: typeof BooleanComparator.Encoded | null | undefined + readonly isNext?: typeof BooleanComparator.Encoded | null | undefined + readonly isPast?: typeof BooleanComparator.Encoded | null | undefined + readonly isPrevious?: typeof BooleanComparator.Encoded | null | undefined + readonly issues?: IssueCollectionFilterEncoded | null | undefined + readonly name?: typeof StringComparator.Encoded | null | undefined + readonly null?: boolean | null | undefined + readonly number?: typeof NumberComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly startsAt?: typeof DateComparator.Encoded | null | undefined + readonly team?: TeamFilterEncoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Issue label filtering options. */ +export const IssueLabelCollectionFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => IssueLabelCollectionFilter)))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + creator: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableUserFilter))), + every: Schema.optional(Schema.NullOr(Schema.suspend(() => IssueLabelFilter))), + id: Schema.optional(Schema.NullOr(IDComparator)), + isGroup: Schema.optional(Schema.NullOr(BooleanComparator)), + length: Schema.optional(Schema.NullOr(NumberComparator)), + name: Schema.optional(Schema.NullOr(StringComparator)), + null: Schema.optional(Schema.NullOr(Schema.Boolean)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => IssueLabelCollectionFilter)))), + parent: Schema.optional(Schema.NullOr(Schema.suspend(() => IssueLabelFilter))), + some: Schema.optional(Schema.NullOr(Schema.suspend(() => IssueLabelFilter))), + team: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableTeamFilter))), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface IssueLabelCollectionFilter { + /** Compound filters, all of which need to be matched by the label. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Filters that the issue labels creator must satisfy. */ + readonly creator?: NullableUserFilter | null | undefined + /** Filters that needs to be matched by all issue labels. */ + readonly every?: IssueLabelFilter | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Comparator for whether the label is a group label. */ + readonly isGroup?: BooleanComparator | null | undefined + /** Comparator for the collection length. */ + readonly length?: NumberComparator | null | undefined + /** Comparator for the name. */ + readonly name?: StringComparator | null | undefined + /** Filter based on the existence of the relation. */ + readonly null?: boolean | null | undefined + /** Compound filters, one of which need to be matched by the label. */ + readonly or?: ReadonlyArray | null | undefined + /** Filters that the issue label's parent label must satisfy. */ + readonly parent?: IssueLabelFilter | null | undefined + /** Filters that needs to be matched by some issue labels. */ + readonly some?: IssueLabelFilter | null | undefined + /** Filters that the issue labels team must satisfy. */ + readonly team?: NullableTeamFilter | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface IssueLabelCollectionFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly creator?: NullableUserFilterEncoded | null | undefined + readonly every?: IssueLabelFilterEncoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly isGroup?: typeof BooleanComparator.Encoded | null | undefined + readonly length?: typeof NumberComparator.Encoded | null | undefined + readonly name?: typeof StringComparator.Encoded | null | undefined + readonly null?: boolean | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly parent?: IssueLabelFilterEncoded | null | undefined + readonly some?: IssueLabelFilterEncoded | null | undefined + readonly team?: NullableTeamFilterEncoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Issue label filtering options. */ +export const IssueLabelFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => IssueLabelFilter)))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + creator: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableUserFilter))), + id: Schema.optional(Schema.NullOr(IDComparator)), + isGroup: Schema.optional(Schema.NullOr(BooleanComparator)), + name: Schema.optional(Schema.NullOr(StringComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => IssueLabelFilter)))), + parent: Schema.optional(Schema.NullOr(Schema.suspend(() => IssueLabelFilter))), + team: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableTeamFilter))), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface IssueLabelFilter { + /** Compound filters, all of which need to be matched by the label. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Filters that the issue labels creator must satisfy. */ + readonly creator?: NullableUserFilter | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Comparator for whether the label is a group label. */ + readonly isGroup?: BooleanComparator | null | undefined + /** Comparator for the name. */ + readonly name?: StringComparator | null | undefined + /** Compound filters, one of which need to be matched by the label. */ + readonly or?: ReadonlyArray | null | undefined + /** Filters that the issue label's parent label must satisfy. */ + readonly parent?: IssueLabelFilter | null | undefined + /** Filters that the issue labels team must satisfy. */ + readonly team?: NullableTeamFilter | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface IssueLabelFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly creator?: NullableUserFilterEncoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly isGroup?: typeof BooleanComparator.Encoded | null | undefined + readonly name?: typeof StringComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly parent?: IssueLabelFilterEncoded | null | undefined + readonly team?: NullableTeamFilterEncoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Project milestone filtering options. */ +export const NullableProjectMilestoneFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => NullableProjectMilestoneFilter)))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + id: Schema.optional(Schema.NullOr(IDComparator)), + name: Schema.optional(Schema.NullOr(NullableStringComparator)), + null: Schema.optional(Schema.NullOr(Schema.Boolean)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => NullableProjectMilestoneFilter)))), + project: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableProjectFilter))), + targetDate: Schema.optional(Schema.NullOr(NullableDateComparator)), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface NullableProjectMilestoneFilter { + /** Compound filters, all of which need to be matched by the project milestone. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Comparator for the project milestone name. */ + readonly name?: NullableStringComparator | null | undefined + /** Filter based on the existence of the relation. */ + readonly null?: boolean | null | undefined + /** Compound filters, one of which need to be matched by the project milestone. */ + readonly or?: ReadonlyArray | null | undefined + /** Filters that the project milestone's project must satisfy. */ + readonly project?: NullableProjectFilter | null | undefined + /** Comparator for the project milestone target date. */ + readonly targetDate?: NullableDateComparator | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface NullableProjectMilestoneFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly name?: typeof NullableStringComparator.Encoded | null | undefined + readonly null?: boolean | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly project?: NullableProjectFilterEncoded | null | undefined + readonly targetDate?: typeof NullableDateComparator.Encoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Release collection filtering options. */ +export const ReleaseCollectionFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => ReleaseCollectionFilter)))), + completedAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + every: Schema.optional(Schema.NullOr(Schema.suspend(() => ReleaseFilter))), + hasReleaseNotes: Schema.optional(Schema.NullOr(BooleanComparator)), + id: Schema.optional(Schema.NullOr(IDComparator)), + length: Schema.optional(Schema.NullOr(NumberComparator)), + name: Schema.optional(Schema.NullOr(StringComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => ReleaseCollectionFilter)))), + pipeline: Schema.optional(Schema.NullOr(Schema.suspend(() => ReleasePipelineFilter))), + some: Schema.optional(Schema.NullOr(Schema.suspend(() => ReleaseFilter))), + stage: Schema.optional(Schema.NullOr(ReleaseStageFilter)), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)), + version: Schema.optional(Schema.NullOr(StringComparator)) +}) +export interface ReleaseCollectionFilter { + /** Compound filters, all of which need to be matched by the release. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the release completion date. */ + readonly completedAt?: NullableDateComparator | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Filters that needs to be matched by all releases. */ + readonly every?: ReleaseFilter | null | undefined + /** Comparator for whether the release is covered by any (non-archived) release note. Filter with `{ eq: false }` to retrieve releases that do not yet have release notes attached. */ + readonly hasReleaseNotes?: BooleanComparator | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Comparator for the collection length. */ + readonly length?: NumberComparator | null | undefined + /** Comparator for the release name. */ + readonly name?: StringComparator | null | undefined + /** Compound filters, one of which need to be matched by the release. */ + readonly or?: ReadonlyArray | null | undefined + /** Filters that the release's pipeline must satisfy. */ + readonly pipeline?: ReleasePipelineFilter | null | undefined + /** Filters that needs to be matched by some releases. */ + readonly some?: ReleaseFilter | null | undefined + /** Filters that the release's stage must satisfy. */ + readonly stage?: ReleaseStageFilter | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined + /** Comparator for the release version. */ + readonly version?: StringComparator | null | undefined +} +export interface ReleaseCollectionFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly completedAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly every?: ReleaseFilterEncoded | null | undefined + readonly hasReleaseNotes?: typeof BooleanComparator.Encoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly length?: typeof NumberComparator.Encoded | null | undefined + readonly name?: typeof StringComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly pipeline?: ReleasePipelineFilterEncoded | null | undefined + readonly some?: ReleaseFilterEncoded | null | undefined + readonly stage?: ReleaseStageFilterEncoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined + readonly version?: typeof StringComparator.Encoded | null | undefined +} + +/** Release filtering options. */ +export const ReleaseFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => ReleaseFilter)))), + completedAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + hasReleaseNotes: Schema.optional(Schema.NullOr(BooleanComparator)), + id: Schema.optional(Schema.NullOr(IDComparator)), + name: Schema.optional(Schema.NullOr(StringComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => ReleaseFilter)))), + pipeline: Schema.optional(Schema.NullOr(Schema.suspend(() => ReleasePipelineFilter))), + stage: Schema.optional(Schema.NullOr(ReleaseStageFilter)), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)), + version: Schema.optional(Schema.NullOr(StringComparator)) +}) +export interface ReleaseFilter { + /** Compound filters, all of which need to be matched by the release. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the release completion date. */ + readonly completedAt?: NullableDateComparator | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Comparator for whether the release is covered by any (non-archived) release note. Filter with `{ eq: false }` to retrieve releases that do not yet have release notes attached. */ + readonly hasReleaseNotes?: BooleanComparator | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Comparator for the release name. */ + readonly name?: StringComparator | null | undefined + /** Compound filters, one of which need to be matched by the release. */ + readonly or?: ReadonlyArray | null | undefined + /** Filters that the release's pipeline must satisfy. */ + readonly pipeline?: ReleasePipelineFilter | null | undefined + /** Filters that the release's stage must satisfy. */ + readonly stage?: ReleaseStageFilter | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined + /** Comparator for the release version. */ + readonly version?: StringComparator | null | undefined +} +export interface ReleaseFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly completedAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly hasReleaseNotes?: typeof BooleanComparator.Encoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly name?: typeof StringComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly pipeline?: ReleasePipelineFilterEncoded | null | undefined + readonly stage?: ReleaseStageFilterEncoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined + readonly version?: typeof StringComparator.Encoded | null | undefined +} + +/** Workflow state filtering options. */ +export const WorkflowStateFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => WorkflowStateFilter)))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + description: Schema.optional(Schema.NullOr(StringComparator)), + id: Schema.optional(Schema.NullOr(IDComparator)), + issues: Schema.optional(Schema.NullOr(Schema.suspend(() => IssueCollectionFilter))), + name: Schema.optional(Schema.NullOr(StringComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => WorkflowStateFilter)))), + position: Schema.optional(Schema.NullOr(NumberComparator)), + team: Schema.optional(Schema.NullOr(Schema.suspend(() => TeamFilter))), + type: Schema.optional(Schema.NullOr(StringComparator)), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface WorkflowStateFilter { + /** Compound filters, all of which need to be matched by the workflow state. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Comparator for the workflow state description. */ + readonly description?: StringComparator | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Filters that the workflow states issues must satisfy. */ + readonly issues?: IssueCollectionFilter | null | undefined + /** Comparator for the workflow state name. */ + readonly name?: StringComparator | null | undefined + /** Compound filters, one of which need to be matched by the workflow state. */ + readonly or?: ReadonlyArray | null | undefined + /** Comparator for the workflow state position. */ + readonly position?: NumberComparator | null | undefined + /** Filters that the workflow states team must satisfy. */ + readonly team?: TeamFilter | null | undefined + /** Comparator for the workflow state type. Possible values are "triage", "backlog", "unstarted", "started", "completed", "canceled", "duplicate". */ + readonly type?: StringComparator | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface WorkflowStateFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly description?: typeof StringComparator.Encoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly issues?: IssueCollectionFilterEncoded | null | undefined + readonly name?: typeof StringComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly position?: typeof NumberComparator.Encoded | null | undefined + readonly team?: TeamFilterEncoded | null | undefined + readonly type?: typeof StringComparator.Encoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** IssueSuggestion collection filtering options. */ +export const IssueSuggestionCollectionFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => IssueSuggestionCollectionFilter)))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + every: Schema.optional(Schema.NullOr(Schema.suspend(() => IssueSuggestionFilter))), + id: Schema.optional(Schema.NullOr(IDComparator)), + length: Schema.optional(Schema.NullOr(NumberComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => IssueSuggestionCollectionFilter)))), + some: Schema.optional(Schema.NullOr(Schema.suspend(() => IssueSuggestionFilter))), + state: Schema.optional(Schema.NullOr(StringComparator)), + suggestedLabel: Schema.optional(Schema.NullOr(Schema.suspend(() => IssueLabelFilter))), + suggestedProject: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableProjectFilter))), + suggestedTeam: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableTeamFilter))), + suggestedUser: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableUserFilter))), + type: Schema.optional(Schema.NullOr(StringComparator)), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface IssueSuggestionCollectionFilter { + /** Compound filters, all of which need to be matched by the suggestion. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Filters that needs to be matched by all suggestions. */ + readonly every?: IssueSuggestionFilter | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Comparator for the collection length. */ + readonly length?: NumberComparator | null | undefined + /** Compound filters, one of which need to be matched by the suggestion. */ + readonly or?: ReadonlyArray | null | undefined + /** Filters that needs to be matched by some suggestions. */ + readonly some?: IssueSuggestionFilter | null | undefined + /** Comparator for the suggestion state. */ + readonly state?: StringComparator | null | undefined + /** Filters that the suggested label must satisfy. */ + readonly suggestedLabel?: IssueLabelFilter | null | undefined + /** Filters that the suggested project must satisfy. */ + readonly suggestedProject?: NullableProjectFilter | null | undefined + /** Filters that the suggested team must satisfy. */ + readonly suggestedTeam?: NullableTeamFilter | null | undefined + /** Filters that the suggested user must satisfy. */ + readonly suggestedUser?: NullableUserFilter | null | undefined + /** Comparator for the suggestion type. */ + readonly type?: StringComparator | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface IssueSuggestionCollectionFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly every?: IssueSuggestionFilterEncoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly length?: typeof NumberComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly some?: IssueSuggestionFilterEncoded | null | undefined + readonly state?: typeof StringComparator.Encoded | null | undefined + readonly suggestedLabel?: IssueLabelFilterEncoded | null | undefined + readonly suggestedProject?: NullableProjectFilterEncoded | null | undefined + readonly suggestedTeam?: NullableTeamFilterEncoded | null | undefined + readonly suggestedUser?: NullableUserFilterEncoded | null | undefined + readonly type?: typeof StringComparator.Encoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** IssueSuggestion filtering options. */ +export const IssueSuggestionFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => IssueSuggestionFilter)))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + id: Schema.optional(Schema.NullOr(IDComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => IssueSuggestionFilter)))), + state: Schema.optional(Schema.NullOr(StringComparator)), + suggestedLabel: Schema.optional(Schema.NullOr(Schema.suspend(() => IssueLabelFilter))), + suggestedProject: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableProjectFilter))), + suggestedTeam: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableTeamFilter))), + suggestedUser: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableUserFilter))), + type: Schema.optional(Schema.NullOr(StringComparator)), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface IssueSuggestionFilter { + /** Compound filters, all of which need to be matched by the suggestion. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Compound filters, one of which need to be matched by the suggestion. */ + readonly or?: ReadonlyArray | null | undefined + /** Comparator for the suggestion state. */ + readonly state?: StringComparator | null | undefined + /** Filters that the suggested label must satisfy. */ + readonly suggestedLabel?: IssueLabelFilter | null | undefined + /** Filters that the suggested project must satisfy. */ + readonly suggestedProject?: NullableProjectFilter | null | undefined + /** Filters that the suggested team must satisfy. */ + readonly suggestedTeam?: NullableTeamFilter | null | undefined + /** Filters that the suggested user must satisfy. */ + readonly suggestedUser?: NullableUserFilter | null | undefined + /** Comparator for the suggestion type. */ + readonly type?: StringComparator | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface IssueSuggestionFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly state?: typeof StringComparator.Encoded | null | undefined + readonly suggestedLabel?: IssueLabelFilterEncoded | null | undefined + readonly suggestedProject?: NullableProjectFilterEncoded | null | undefined + readonly suggestedTeam?: NullableTeamFilterEncoded | null | undefined + readonly suggestedUser?: NullableUserFilterEncoded | null | undefined + readonly type?: typeof StringComparator.Encoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Nullable project update filtering options. */ +export const NullableProjectUpdateFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => NullableProjectUpdateFilter)))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + id: Schema.optional(Schema.NullOr(IDComparator)), + null: Schema.optional(Schema.NullOr(Schema.Boolean)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => NullableProjectUpdateFilter)))), + project: Schema.optional(Schema.NullOr(Schema.suspend(() => ProjectFilter))), + reactions: Schema.optional(Schema.NullOr(ReactionCollectionFilter)), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)), + user: Schema.optional(Schema.NullOr(Schema.suspend(() => UserFilter))) +}) +export interface NullableProjectUpdateFilter { + /** Compound filters, all of which need to be matched by the project update. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Filter based on the existence of the relation. */ + readonly null?: boolean | null | undefined + /** Compound filters, one of which need to be matched by the project update. */ + readonly or?: ReadonlyArray | null | undefined + /** Filters that the project update project must satisfy. */ + readonly project?: ProjectFilter | null | undefined + /** Filters that the project updates reactions must satisfy. */ + readonly reactions?: ReactionCollectionFilter | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined + /** Filters that the project update creator must satisfy. */ + readonly user?: UserFilter | null | undefined +} +export interface NullableProjectUpdateFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly null?: boolean | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly project?: ProjectFilterEncoded | null | undefined + readonly reactions?: ReactionCollectionFilterEncoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined + readonly user?: UserFilterEncoded | null | undefined +} + +/** Project filtering options. */ +export const ProjectFilter: Schema.Codec = Schema.Struct({ + accessibleTeams: Schema.optional(Schema.NullOr(Schema.suspend(() => TeamCollectionFilter))), + activityType: Schema.optional(Schema.NullOr(StringComparator)), + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => ProjectFilter)))), + canceledAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + completedAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + completedProjectMilestones: Schema.optional(Schema.NullOr(Schema.suspend(() => ProjectMilestoneCollectionFilter))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + creator: Schema.optional(Schema.NullOr(Schema.suspend(() => UserFilter))), + customIdentifier: Schema.optional(Schema.NullOr(NullableStringComparator)), + customerCount: Schema.optional(Schema.NullOr(NumberComparator)), + customerImportantCount: Schema.optional(Schema.NullOr(NumberComparator)), + hasBlockedByRelations: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasBlockingRelations: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasDependedOnByRelations: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasDependsOnRelations: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasRelatedRelations: Schema.optional(Schema.NullOr(RelationExistsComparator)), + hasViolatedRelations: Schema.optional(Schema.NullOr(RelationExistsComparator)), + health: Schema.optional(Schema.NullOr(StringComparator)), + healthWithAge: Schema.optional(Schema.NullOr(StringComparator)), + id: Schema.optional(Schema.NullOr(EntityIdentifierIDComparator)), + initiatives: Schema.optional(Schema.NullOr(Schema.suspend(() => InitiativeCollectionFilter))), + issues: Schema.optional(Schema.NullOr(Schema.suspend(() => IssueCollectionFilter))), + labels: Schema.optional(Schema.NullOr(Schema.suspend(() => ProjectLabelCollectionFilter))), + lastAppliedTemplate: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableTemplateFilter))), + lead: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableUserFilter))), + leadTeam: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableTeamFilter))), + members: Schema.optional(Schema.NullOr(Schema.suspend(() => UserCollectionFilter))), + name: Schema.optional(Schema.NullOr(StringComparator)), + needs: Schema.optional(Schema.NullOr(Schema.suspend(() => CustomerNeedCollectionFilter))), + nextProjectMilestone: Schema.optional(Schema.NullOr(Schema.suspend(() => ProjectMilestoneFilter))), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => ProjectFilter)))), + priority: Schema.optional(Schema.NullOr(NullableNumberComparator)), + projectMilestones: Schema.optional(Schema.NullOr(Schema.suspend(() => ProjectMilestoneCollectionFilter))), + projectUpdates: Schema.optional(Schema.NullOr(ProjectUpdatesCollectionFilter)), + roadmaps: Schema.optional(Schema.NullOr(Schema.suspend(() => RoadmapCollectionFilter))), + searchableContent: Schema.optional(Schema.NullOr(ContentComparator)), + slugId: Schema.optional(Schema.NullOr(StringComparator)), + startDate: Schema.optional(Schema.NullOr(NullableDateComparator)), + startedAt: Schema.optional(Schema.NullOr(NullableDateComparator)), + state: Schema.optional(Schema.NullOr(StringComparator)), + status: Schema.optional(Schema.NullOr(Schema.suspend(() => ProjectStatusFilter))), + targetDate: Schema.optional(Schema.NullOr(NullableDateComparator)), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface ProjectFilter { + /** Filters that the project's team must satisfy. */ + readonly accessibleTeams?: TeamCollectionFilter | null | undefined + /** [ALPHA] Comparator for the project activity type: buzzin, active, some, none */ + readonly activityType?: StringComparator | null | undefined + /** Compound filters, all of which need to be matched by the project. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the project cancelation date. */ + readonly canceledAt?: NullableDateComparator | null | undefined + /** Comparator for the project completion date. */ + readonly completedAt?: NullableDateComparator | null | undefined + /** Filters that the project's completed milestones must satisfy. */ + readonly completedProjectMilestones?: ProjectMilestoneCollectionFilter | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Filters that the projects creator must satisfy. */ + readonly creator?: UserFilter | null | undefined + /** [Internal] Comparator for the project's custom identifier. */ + readonly customIdentifier?: NullableStringComparator | null | undefined + /** Count of customers */ + readonly customerCount?: NumberComparator | null | undefined + /** Count of important customers */ + readonly customerImportantCount?: NumberComparator | null | undefined + /** Comparator for filtering projects which are blocked. */ + readonly hasBlockedByRelations?: RelationExistsComparator | null | undefined + /** Comparator for filtering projects which are blocking. */ + readonly hasBlockingRelations?: RelationExistsComparator | null | undefined + /** [Deprecated] Comparator for filtering projects which this is depended on by. */ + readonly hasDependedOnByRelations?: RelationExistsComparator | null | undefined + /** [Deprecated]Comparator for filtering projects which this depends on. */ + readonly hasDependsOnRelations?: RelationExistsComparator | null | undefined + /** Comparator for filtering projects with relations. */ + readonly hasRelatedRelations?: RelationExistsComparator | null | undefined + /** Comparator for filtering projects with violated dependencies. */ + readonly hasViolatedRelations?: RelationExistsComparator | null | undefined + /** Comparator for the project health: onTrack, atRisk, offTrack */ + readonly health?: StringComparator | null | undefined + /** Comparator for the project health (with age): onTrack, atRisk, offTrack, outdated, noUpdate */ + readonly healthWithAge?: StringComparator | null | undefined + /** Comparator for the identifier. */ + readonly id?: EntityIdentifierIDComparator | null | undefined + /** Filters that the projects initiatives must satisfy. */ + readonly initiatives?: InitiativeCollectionFilter | null | undefined + /** Filters that the projects issues must satisfy. */ + readonly issues?: IssueCollectionFilter | null | undefined + /** Filters that project labels must satisfy. */ + readonly labels?: ProjectLabelCollectionFilter | null | undefined + /** Filters that the last applied template must satisfy. */ + readonly lastAppliedTemplate?: NullableTemplateFilter | null | undefined + /** Filters that the projects lead must satisfy. */ + readonly lead?: NullableUserFilter | null | undefined + /** [ALPHA] Filters that the project's lead team must satisfy. */ + readonly leadTeam?: NullableTeamFilter | null | undefined + /** Filters that the projects members must satisfy. */ + readonly members?: UserCollectionFilter | null | undefined + /** Comparator for the project name. */ + readonly name?: StringComparator | null | undefined + /** Filters that the project's customer needs must satisfy. */ + readonly needs?: CustomerNeedCollectionFilter | null | undefined + /** Filters that the project's next milestone must satisfy. */ + readonly nextProjectMilestone?: ProjectMilestoneFilter | null | undefined + /** Compound filters, one of which need to be matched by the project. */ + readonly or?: ReadonlyArray | null | undefined + /** Comparator for the project priority. */ + readonly priority?: NullableNumberComparator | null | undefined + /** Filters that the project's milestones must satisfy. */ + readonly projectMilestones?: ProjectMilestoneCollectionFilter | null | undefined + /** Comparator for the project updates. */ + readonly projectUpdates?: ProjectUpdatesCollectionFilter | null | undefined + /** Filters that the projects roadmaps must satisfy. */ + readonly roadmaps?: RoadmapCollectionFilter | null | undefined + /** [Internal] Comparator for the project's content. */ + readonly searchableContent?: ContentComparator | null | undefined + /** Comparator for the project slug ID. */ + readonly slugId?: StringComparator | null | undefined + /** Comparator for the project start date. */ + readonly startDate?: NullableDateComparator | null | undefined + /** Comparator for the project started date (when it was moved to an "In Progress" status). */ + readonly startedAt?: NullableDateComparator | null | undefined + /** [DEPRECATED] Comparator for the project state. */ + readonly state?: StringComparator | null | undefined + /** Filters that the project status must satisfy. */ + readonly status?: ProjectStatusFilter | null | undefined + /** Comparator for the project target date. */ + readonly targetDate?: NullableDateComparator | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface ProjectFilterEncoded { + readonly accessibleTeams?: TeamCollectionFilterEncoded | null | undefined + readonly activityType?: typeof StringComparator.Encoded | null | undefined + readonly and?: ReadonlyArray | null | undefined + readonly canceledAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly completedAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly completedProjectMilestones?: ProjectMilestoneCollectionFilterEncoded | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly creator?: UserFilterEncoded | null | undefined + readonly customIdentifier?: typeof NullableStringComparator.Encoded | null | undefined + readonly customerCount?: typeof NumberComparator.Encoded | null | undefined + readonly customerImportantCount?: typeof NumberComparator.Encoded | null | undefined + readonly hasBlockedByRelations?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasBlockingRelations?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasDependedOnByRelations?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasDependsOnRelations?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasRelatedRelations?: typeof RelationExistsComparator.Encoded | null | undefined + readonly hasViolatedRelations?: typeof RelationExistsComparator.Encoded | null | undefined + readonly health?: typeof StringComparator.Encoded | null | undefined + readonly healthWithAge?: typeof StringComparator.Encoded | null | undefined + readonly id?: typeof EntityIdentifierIDComparator.Encoded | null | undefined + readonly initiatives?: InitiativeCollectionFilterEncoded | null | undefined + readonly issues?: IssueCollectionFilterEncoded | null | undefined + readonly labels?: ProjectLabelCollectionFilterEncoded | null | undefined + readonly lastAppliedTemplate?: NullableTemplateFilterEncoded | null | undefined + readonly lead?: NullableUserFilterEncoded | null | undefined + readonly leadTeam?: NullableTeamFilterEncoded | null | undefined + readonly members?: UserCollectionFilterEncoded | null | undefined + readonly name?: typeof StringComparator.Encoded | null | undefined + readonly needs?: CustomerNeedCollectionFilterEncoded | null | undefined + readonly nextProjectMilestone?: ProjectMilestoneFilterEncoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly priority?: typeof NullableNumberComparator.Encoded | null | undefined + readonly projectMilestones?: ProjectMilestoneCollectionFilterEncoded | null | undefined + readonly projectUpdates?: ProjectUpdatesCollectionFilterEncoded | null | undefined + readonly roadmaps?: RoadmapCollectionFilterEncoded | null | undefined + readonly searchableContent?: typeof ContentComparator.Encoded | null | undefined + readonly slugId?: typeof StringComparator.Encoded | null | undefined + readonly startDate?: typeof NullableDateComparator.Encoded | null | undefined + readonly startedAt?: typeof NullableDateComparator.Encoded | null | undefined + readonly state?: typeof StringComparator.Encoded | null | undefined + readonly status?: ProjectStatusFilterEncoded | null | undefined + readonly targetDate?: typeof NullableDateComparator.Encoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Roadmap collection filtering options. */ +export const RoadmapCollectionFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => RoadmapCollectionFilter)))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + creator: Schema.optional(Schema.NullOr(Schema.suspend(() => UserFilter))), + every: Schema.optional(Schema.NullOr(Schema.suspend(() => RoadmapFilter))), + id: Schema.optional(Schema.NullOr(IDComparator)), + length: Schema.optional(Schema.NullOr(NumberComparator)), + name: Schema.optional(Schema.NullOr(StringComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => RoadmapCollectionFilter)))), + slugId: Schema.optional(Schema.NullOr(StringComparator)), + some: Schema.optional(Schema.NullOr(Schema.suspend(() => RoadmapFilter))), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface RoadmapCollectionFilter { + /** Compound filters, all of which need to be matched by the roadmap. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Filters that the roadmap creator must satisfy. */ + readonly creator?: UserFilter | null | undefined + /** Filters that needs to be matched by all roadmaps. */ + readonly every?: RoadmapFilter | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Comparator for the collection length. */ + readonly length?: NumberComparator | null | undefined + /** Comparator for the roadmap name. */ + readonly name?: StringComparator | null | undefined + /** Compound filters, one of which need to be matched by the roadmap. */ + readonly or?: ReadonlyArray | null | undefined + /** Comparator for the roadmap slug ID. */ + readonly slugId?: StringComparator | null | undefined + /** Filters that needs to be matched by some roadmaps. */ + readonly some?: RoadmapFilter | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface RoadmapCollectionFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly creator?: UserFilterEncoded | null | undefined + readonly every?: RoadmapFilterEncoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly length?: typeof NumberComparator.Encoded | null | undefined + readonly name?: typeof StringComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly slugId?: typeof StringComparator.Encoded | null | undefined + readonly some?: RoadmapFilterEncoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Roadmap filtering options. */ +export const RoadmapFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => RoadmapFilter)))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + creator: Schema.optional(Schema.NullOr(Schema.suspend(() => UserFilter))), + id: Schema.optional(Schema.NullOr(IDComparator)), + name: Schema.optional(Schema.NullOr(StringComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => RoadmapFilter)))), + slugId: Schema.optional(Schema.NullOr(StringComparator)), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface RoadmapFilter { + /** Compound filters, all of which need to be matched by the roadmap. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Filters that the roadmap creator must satisfy. */ + readonly creator?: UserFilter | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Comparator for the roadmap name. */ + readonly name?: StringComparator | null | undefined + /** Compound filters, one of which need to be matched by the roadmap. */ + readonly or?: ReadonlyArray | null | undefined + /** Comparator for the roadmap slug ID. */ + readonly slugId?: StringComparator | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface RoadmapFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly creator?: UserFilterEncoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly name?: typeof StringComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly slugId?: typeof StringComparator.Encoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Project status filtering options. */ +export const ProjectStatusFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => ProjectStatusFilter)))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + description: Schema.optional(Schema.NullOr(StringComparator)), + id: Schema.optional(Schema.NullOr(IDComparator)), + name: Schema.optional(Schema.NullOr(StringComparator)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => ProjectStatusFilter)))), + position: Schema.optional(Schema.NullOr(NumberComparator)), + projects: Schema.optional(Schema.NullOr(Schema.suspend(() => ProjectCollectionFilter))), + team: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableTeamFilter))), + type: Schema.optional(Schema.NullOr(StringComparator)), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface ProjectStatusFilter { + /** Compound filters, all of which need to be matched by the project status. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Comparator for the project status description. */ + readonly description?: StringComparator | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Comparator for the project status name. */ + readonly name?: StringComparator | null | undefined + /** Compound filters, one of which needs to be matched by the project status. */ + readonly or?: ReadonlyArray | null | undefined + /** Comparator for the project status position. */ + readonly position?: NumberComparator | null | undefined + /** Filters that the project status projects must satisfy. */ + readonly projects?: ProjectCollectionFilter | null | undefined + /** Filters that the project status's team must satisfy. Use `{ null: true }` to filter workspace-level statuses. */ + readonly team?: NullableTeamFilter | null | undefined + /** Comparator for the project status type. */ + readonly type?: StringComparator | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface ProjectStatusFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly description?: typeof StringComparator.Encoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly name?: typeof StringComparator.Encoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly position?: typeof NumberComparator.Encoded | null | undefined + readonly projects?: ProjectCollectionFilterEncoded | null | undefined + readonly team?: NullableTeamFilterEncoded | null | undefined + readonly type?: typeof StringComparator.Encoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Customer filtering options. */ +export const NullableCustomerFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => NullableCustomerFilter)))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + domains: Schema.optional(Schema.NullOr(StringArrayComparator)), + externalIds: Schema.optional(Schema.NullOr(StringArrayComparator)), + id: Schema.optional(Schema.NullOr(IDComparator)), + name: Schema.optional(Schema.NullOr(StringComparator)), + needs: Schema.optional(Schema.NullOr(Schema.suspend(() => CustomerNeedCollectionFilter))), + null: Schema.optional(Schema.NullOr(Schema.Boolean)), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => NullableCustomerFilter)))), + owner: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableUserFilter))), + revenue: Schema.optional(Schema.NullOr(NumberComparator)), + size: Schema.optional(Schema.NullOr(NumberComparator)), + slackChannelId: Schema.optional(Schema.NullOr(StringComparator)), + status: Schema.optional(Schema.NullOr(CustomerStatusFilter)), + tier: Schema.optional(Schema.NullOr(CustomerTierFilter)), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface NullableCustomerFilter { + /** Compound filters, all of which need to be matched by the customer. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Comparator for the customer's domains. */ + readonly domains?: StringArrayComparator | null | undefined + /** Comparator for the customer's external IDs. */ + readonly externalIds?: StringArrayComparator | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Comparator for the customer name. */ + readonly name?: StringComparator | null | undefined + /** Filters that the customer's needs must satisfy. */ + readonly needs?: CustomerNeedCollectionFilter | null | undefined + /** Filter based on the existence of the relation. */ + readonly null?: boolean | null | undefined + /** Compound filters, one of which need to be matched by the customer. */ + readonly or?: ReadonlyArray | null | undefined + /** Filters that the customer owner must satisfy. */ + readonly owner?: NullableUserFilter | null | undefined + /** Comparator for the customer generated revenue. */ + readonly revenue?: NumberComparator | null | undefined + /** Comparator for the customer size. */ + readonly size?: NumberComparator | null | undefined + /** Comparator for the customer slack channel ID. */ + readonly slackChannelId?: StringComparator | null | undefined + /** Filters that the customer's status must satisfy. */ + readonly status?: CustomerStatusFilter | null | undefined + /** Filters that the customer's tier must satisfy. */ + readonly tier?: CustomerTierFilter | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface NullableCustomerFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly domains?: typeof StringArrayComparator.Encoded | null | undefined + readonly externalIds?: typeof StringArrayComparator.Encoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly name?: typeof StringComparator.Encoded | null | undefined + readonly needs?: CustomerNeedCollectionFilterEncoded | null | undefined + readonly null?: boolean | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly owner?: NullableUserFilterEncoded | null | undefined + readonly revenue?: typeof NumberComparator.Encoded | null | undefined + readonly size?: typeof NumberComparator.Encoded | null | undefined + readonly slackChannelId?: typeof StringComparator.Encoded | null | undefined + readonly status?: CustomerStatusFilterEncoded | null | undefined + readonly tier?: CustomerTierFilterEncoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Customer filtering options. */ +export const CustomerNeedFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => CustomerNeedFilter)))), + comment: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableCommentFilter))), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + customer: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableCustomerFilter))), + id: Schema.optional(Schema.NullOr(IDComparator)), + issue: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableIssueFilter))), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => CustomerNeedFilter)))), + priority: Schema.optional(Schema.NullOr(NumberComparator)), + project: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableProjectFilter))), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)) +}) +export interface CustomerNeedFilter { + /** Compound filters, all of which need to be matched by the customer need. */ + readonly and?: ReadonlyArray | null | undefined + /** Filters that the need's comment must satisfy. */ + readonly comment?: NullableCommentFilter | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Filters that the need's customer must satisfy. */ + readonly customer?: NullableCustomerFilter | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** Filters that the need's issue must satisfy. */ + readonly issue?: NullableIssueFilter | null | undefined + /** Compound filters, one of which need to be matched by the customer need. */ + readonly or?: ReadonlyArray | null | undefined + /** Comparator for the customer need priority. */ + readonly priority?: NumberComparator | null | undefined + /** Filters that the need's project must satisfy. */ + readonly project?: NullableProjectFilter | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined +} +export interface CustomerNeedFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly comment?: NullableCommentFilterEncoded | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly customer?: NullableCustomerFilterEncoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly issue?: NullableIssueFilterEncoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly priority?: typeof NumberComparator.Encoded | null | undefined + readonly project?: NullableProjectFilterEncoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined +} + +/** Comment filtering options. */ +export const CommentFilter: Schema.Codec = Schema.Struct({ + and: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => CommentFilter)))), + body: Schema.optional(Schema.NullOr(StringComparator)), + createdAt: Schema.optional(Schema.NullOr(DateComparator)), + documentContent: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableDocumentContentFilter))), + id: Schema.optional(Schema.NullOr(IDComparator)), + initiative: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableInitiativeFilter))), + initiativeUpdate: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableInitiativeUpdateFilter))), + issue: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableIssueFilter))), + needs: Schema.optional(Schema.NullOr(Schema.suspend(() => CustomerNeedCollectionFilter))), + or: Schema.optional(Schema.NullOr(Schema.Array(Schema.suspend(() => CommentFilter)))), + parent: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableCommentFilter))), + project: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableProjectFilter))), + projectUpdate: Schema.optional(Schema.NullOr(Schema.suspend(() => NullableProjectUpdateFilter))), + reactions: Schema.optional(Schema.NullOr(ReactionCollectionFilter)), + updatedAt: Schema.optional(Schema.NullOr(DateComparator)), + user: Schema.optional(Schema.NullOr(Schema.suspend(() => UserFilter))) +}) +export interface CommentFilter { + /** Compound filters, all of which need to be matched by the comment. */ + readonly and?: ReadonlyArray | null | undefined + /** Comparator for the comment's body. */ + readonly body?: StringComparator | null | undefined + /** Comparator for the created at date. */ + readonly createdAt?: DateComparator | null | undefined + /** Filters that the comment's document content must satisfy. */ + readonly documentContent?: NullableDocumentContentFilter | null | undefined + /** Comparator for the identifier. */ + readonly id?: IDComparator | null | undefined + /** [Internal] Filters that the comment's initiative must satisfy. */ + readonly initiative?: NullableInitiativeFilter | null | undefined + /** Filters that the comment's initiative update must satisfy. */ + readonly initiativeUpdate?: NullableInitiativeUpdateFilter | null | undefined + /** Filters that the comment's issue must satisfy. */ + readonly issue?: NullableIssueFilter | null | undefined + /** Filters that the comment's customer needs must satisfy. */ + readonly needs?: CustomerNeedCollectionFilter | null | undefined + /** Compound filters, one of which need to be matched by the comment. */ + readonly or?: ReadonlyArray | null | undefined + /** Filters that the comment parent must satisfy. */ + readonly parent?: NullableCommentFilter | null | undefined + /** [Internal] Filters that the comment's project must satisfy. */ + readonly project?: NullableProjectFilter | null | undefined + /** Filters that the comment's project update must satisfy. */ + readonly projectUpdate?: NullableProjectUpdateFilter | null | undefined + /** Filters that the comment's reactions must satisfy. */ + readonly reactions?: ReactionCollectionFilter | null | undefined + /** Comparator for the updated at date. */ + readonly updatedAt?: DateComparator | null | undefined + /** Filters that the comment's creator must satisfy. */ + readonly user?: UserFilter | null | undefined +} +export interface CommentFilterEncoded { + readonly and?: ReadonlyArray | null | undefined + readonly body?: typeof StringComparator.Encoded | null | undefined + readonly createdAt?: typeof DateComparator.Encoded | null | undefined + readonly documentContent?: NullableDocumentContentFilterEncoded | null | undefined + readonly id?: typeof IDComparator.Encoded | null | undefined + readonly initiative?: NullableInitiativeFilterEncoded | null | undefined + readonly initiativeUpdate?: NullableInitiativeUpdateFilterEncoded | null | undefined + readonly issue?: NullableIssueFilterEncoded | null | undefined + readonly needs?: CustomerNeedCollectionFilterEncoded | null | undefined + readonly or?: ReadonlyArray | null | undefined + readonly parent?: NullableCommentFilterEncoded | null | undefined + readonly project?: NullableProjectFilterEncoded | null | undefined + readonly projectUpdate?: NullableProjectUpdateFilterEncoded | null | undefined + readonly reactions?: ReactionCollectionFilterEncoded | null | undefined + readonly updatedAt?: typeof DateComparator.Encoded | null | undefined + readonly user?: UserFilterEncoded | null | undefined +} + +/** Input for updating an existing issue. All fields are optional; only provided fields will be updated. Setting a field to null (where supported) will clear the value. */ +export const IssueUpdateInput = Schema.Struct({ + /** The identifiers of the issue labels to be added to this issue. */ + addedLabelIds: Schema.optional(Schema.NullOr(Schema.Array(Schema.String))), + /** The identifiers of the releases to be added to this issue. */ + addedReleaseIds: Schema.optional(Schema.NullOr(Schema.Array(Schema.String))), + /** The identifier of the user to assign the issue to. */ + assigneeId: Schema.optional(Schema.NullOr(Schema.String)), + /** Whether the issue was automatically closed because its parent issue was closed. */ + autoClosedByParentClosing: Schema.optional(Schema.NullOr(Schema.Boolean)), + /** The cycle associated with the issue. */ + cycleId: Schema.optional(Schema.NullOr(Schema.String)), + /** The identifier of the agent user to delegate the issue to. */ + delegateId: Schema.optional(Schema.NullOr(Schema.String)), + /** The issue description in markdown format. */ + description: Schema.optional(Schema.NullOr(Schema.String)), + /** [Internal] The issue description as a Prosemirror document. */ + descriptionData: Schema.optional(Schema.NullOr(JSON)), + /** The date at which the issue is due. */ + dueDate: Schema.optional(Schema.NullOr(TimelessDate)), + /** The estimated complexity of the issue. */ + estimate: Schema.optional(Schema.NullOr(Int)), + /** Whether this issue should inherit shared access from its parent issue. */ + inheritsSharedAccess: Schema.optional(Schema.NullOr(Schema.Boolean)), + /** The identifiers of the issue labels associated with this ticket. */ + labelIds: Schema.optional(Schema.NullOr(Schema.Array(Schema.String))), + /** The ID of the last template applied to the issue. */ + lastAppliedTemplateId: Schema.optional(Schema.NullOr(Schema.String)), + /** The identifier of the parent issue. Can be a UUID or issue identifier (e.g., 'LIN-123'). */ + parentId: Schema.optional(Schema.NullOr(Schema.String)), + /** The priority of the issue. 0 = No priority, 1 = Urgent, 2 = High, 3 = Medium, 4 = Low. */ + priority: Schema.optional(Schema.NullOr(Int)), + /** The position of the issue related to other issues, when ordered by priority. */ + prioritySortOrder: Schema.optional(Schema.NullOr(Float)), + /** The project associated with the issue. Can be a UUID or project identifier (e.g., 'P-LIN-123'). */ + projectId: Schema.optional(Schema.NullOr(Schema.String)), + /** The project milestone associated with the issue. */ + projectMilestoneId: Schema.optional(Schema.NullOr(Schema.String)), + /** The identifiers of the releases associated with this issue. */ + releaseIds: Schema.optional(Schema.NullOr(Schema.Array(Schema.String))), + /** The identifiers of the issue labels to be removed from this issue. */ + removedLabelIds: Schema.optional(Schema.NullOr(Schema.Array(Schema.String))), + /** The identifiers of the releases to be removed from this issue. */ + removedReleaseIds: Schema.optional(Schema.NullOr(Schema.Array(Schema.String))), + /** [Internal] The time at which an issue will be considered in breach of SLA. */ + slaBreachesAt: Schema.optional(Schema.NullOr(DateTime)), + /** [Internal] The time at which the issue's SLA was started. */ + slaStartedAt: Schema.optional(Schema.NullOr(DateTime)), + /** The SLA day count type for the issue. Whether SLA should be business days only or calendar days (default). */ + slaType: Schema.optional(Schema.NullOr(SLADayCountType)), + /** The identifier of the user who snoozed the issue. */ + snoozedById: Schema.optional(Schema.NullOr(Schema.String)), + /** The time until which the issue will be snoozed in Triage view. */ + snoozedUntilAt: Schema.optional(Schema.NullOr(DateTime)), + /** The position of the issue related to other issues. */ + sortOrder: Schema.optional(Schema.NullOr(Float)), + /** The team state of the issue. */ + stateId: Schema.optional(Schema.NullOr(Schema.String)), + /** The position of the issue in parent's sub-issue list. */ + subIssueSortOrder: Schema.optional(Schema.NullOr(Float)), + /** The identifiers of the users subscribing to this ticket. */ + subscriberIds: Schema.optional(Schema.NullOr(Schema.Array(Schema.String))), + /** The identifier of the team associated with the issue. */ + teamId: Schema.optional(Schema.NullOr(Schema.String)), + /** The issue title. */ + title: Schema.optional(Schema.NullOr(Schema.String)), + /** Whether the issue has been trashed. Set to true to trash, or null to restore. */ + trashed: Schema.optional(Schema.NullOr(Schema.Boolean)), + /** [Internal] Whether this issue has been explicitly marked as trusted. */ + trusted: Schema.optional(Schema.NullOr(Schema.Boolean)) +}) +export interface IssueUpdateInput extends Schema.Struct.Type {} + +/** Input for creating a new reaction. */ +export const ReactionCreateInput = Schema.Struct({ + /** The comment to associate the reaction with. */ + commentId: Schema.optional(Schema.NullOr(Schema.String)), + /** The emoji the user reacted with. */ + emoji: Schema.String, + /** The identifier in UUID v4 format. If none is provided, the backend will generate one. */ + id: Schema.optional(Schema.NullOr(Schema.String)), + /** The update to associate the reaction with. */ + initiativeUpdateId: Schema.optional(Schema.NullOr(Schema.String)), + /** The issue to associate the reaction with. Can be a UUID or issue identifier (e.g., 'LIN-123'). */ + issueId: Schema.optional(Schema.NullOr(Schema.String)), + /** [Internal] The post to associate the reaction with. */ + postId: Schema.optional(Schema.NullOr(Schema.String)), + /** The project update to associate the reaction with. */ + projectUpdateId: Schema.optional(Schema.NullOr(Schema.String)), + /** [Internal] The pull request comment to associate the reaction with. */ + pullRequestCommentId: Schema.optional(Schema.NullOr(Schema.String)), + /** [Internal] The pull request to associate the reaction with. */ + pullRequestId: Schema.optional(Schema.NullOr(Schema.String)) +}) +export interface ReactionCreateInput extends Schema.Struct.Type {} diff --git a/packages/issue-tracker-linear/src/server/LinearApi.graphql b/packages/issue-tracker-linear/src/server/LinearApi.graphql new file mode 100644 index 000000000000..aab15de8de03 --- /dev/null +++ b/packages/issue-tracker-linear/src/server/LinearApi.graphql @@ -0,0 +1,275 @@ +fragment LinearUser on User { + id + name + displayName + email + avatarUrl +} + +fragment LinearWorkflowState on WorkflowState { + id + name + type + position +} + +fragment LinearLabel on IssueLabel { + id + name + color +} + +fragment LinearTeamLabel on IssueLabel { + ...LinearLabel + description +} + +fragment LinearReaction on Reaction { + id + emoji + user { + ...LinearUser + } +} + +fragment LinearComment on Comment { + id + body + createdAt + url + user { + ...LinearUser + } + reactions { + ...LinearReaction + } +} + +fragment LinearIssue on Issue { + id + identifier + number + title + url + description + createdAt + updatedAt + completedAt + canceledAt + state { + ...LinearWorkflowState + } + team { + key + } + creator { + ...LinearUser + } + assignee { + ...LinearUser + } + labels { + nodes { + ...LinearLabel + } + } +} + +fragment LinearPageInfo on PageInfo { + hasNextPage + endCursor +} + +query T3Viewer { + viewer { + ...LinearUser + } + teams(first: 250) { + nodes { + id + key + name + } + } +} + +query T3Issues($first: Int!, $after: String, $filter: IssueFilter!) { + issues(first: $first, after: $after, filter: $filter, orderBy: updatedAt) { + nodes { + ...LinearIssue + } + pageInfo { + ...LinearPageInfo + } + } +} + +query T3Issue($id: String!, $comments: Int!) { + issue(id: $id) { + ...LinearIssue + comments(first: $comments, orderBy: createdAt) { + nodes { + ...LinearComment + } + pageInfo { + ...LinearPageInfo + } + } + reactions { + ...LinearReaction + } + attachments(first: 50) { + nodes { + url + title + sourceType + metadata + } + } + history(first: 100, orderBy: createdAt) { + nodes { + id + createdAt + actor { + ...LinearUser + } + fromState { + ...LinearWorkflowState + } + toState { + ...LinearWorkflowState + } + fromAssignee { + ...LinearUser + } + toAssignee { + ...LinearUser + } + addedLabels { + ...LinearLabel + } + removedLabels { + ...LinearLabel + } + fromTitle + toTitle + } + } + } +} + +query T3Comments($id: String!, $first: Int!, $after: String) { + issue(id: $id) { + comments(first: $first, after: $after, orderBy: createdAt) { + nodes { + ...LinearComment + } + pageInfo { + ...LinearPageInfo + } + } + } +} + +query T3Team($key: String!) { + teams(first: 1, filter: { key: { eq: $key } }) { + nodes { + id + key + name + states(first: 100) { + nodes { + ...LinearWorkflowState + } + pageInfo { + ...LinearPageInfo + } + } + labels(first: 250) { + nodes { + ...LinearTeamLabel + } + pageInfo { + ...LinearPageInfo + } + } + members(first: 250) { + nodes { + ...LinearUser + } + pageInfo { + ...LinearPageInfo + } + } + templates { + nodes { + id + name + description + content + type + hasFormFields + templateData + } + } + } + } + issueLabels(first: 250, filter: { team: { null: true } }) { + nodes { + ...LinearTeamLabel + } + pageInfo { + ...LinearPageInfo + } + } +} + +mutation T3IssueCreate($input: IssueCreateInput!) { + issueCreate(input: $input) { + success + issue { + identifier + url + } + } +} + +mutation T3IssueUpdate($id: String!, $input: IssueUpdateInput!) { + issueUpdate(id: $id, input: $input) { + success + } +} + +mutation T3CommentCreate($input: CommentCreateInput!) { + commentCreate(input: $input) { + success + } +} + +mutation T3ReactionCreate($input: ReactionCreateInput!) { + reactionCreate(input: $input) { + success + } +} + +mutation T3ReactionDelete($id: String!) { + reactionDelete(id: $id) { + success + } +} + +query T3IssueReactions($id: String!) { + issue(id: $id) { + reactions { + ...LinearReaction + } + } +} + +query T3CommentReactions($id: String!) { + comment(id: $id) { + reactions { + ...LinearReaction + } + } +} diff --git a/packages/issue-tracker-linear/src/server/LinearApi.graphql.ts b/packages/issue-tracker-linear/src/server/LinearApi.graphql.ts new file mode 100644 index 000000000000..6ad4364a4ca9 --- /dev/null +++ b/packages/issue-tracker-linear/src/server/LinearApi.graphql.ts @@ -0,0 +1,728 @@ +// Generated by @effect/graphql-generator from LinearApi.graphql. Do not edit. +import { GraphQL, GraphQLGroup } from "effect/graphql" +import * as Schema from "effect/Schema" +import * as Shared from "../../schema/linear.graphql.ts" + +/** + * `fragment LinearUser on User` + * + * A user that belongs to a workspace. Users can have different roles (admin, member, guest, or app) that determine their level of access. Users can be members of multiple teams, and can be active or deactivated. Guest users have limited access scoped to specific teams they are invited to. + */ +export const LinearUser = Schema.Struct({ + /** The unique identifier of the entity. */ + id: Shared.ID, + /** The user's full name. */ + name: Schema.String, + /** The user's display (nick) name. Must be unique within the workspace. */ + displayName: Schema.String, + /** The user's email address. */ + email: Schema.String, + /** An URL to the user's avatar image. */ + avatarUrl: Schema.NullOr(Schema.String) +}) +export interface LinearUser extends Schema.Struct.Type {} + +/** + * `fragment LinearWorkflowState on WorkflowState` + * + * A state in a team's workflow, representing an issue status such as Triage, Backlog, Todo, In Progress, In Review, Done, or Canceled. Each team has its own set of workflow states that define the progression of issues through the team's process. Workflow states have a type that categorizes them (triage, backlog, unstarted, started, completed, canceled), a position that determines their display order, and a color for visual identification. States can be inherited from parent teams to sub-teams. + */ +export const LinearWorkflowState = Schema.Struct({ + /** The unique identifier of the entity. */ + id: Shared.ID, + /** The state's human-readable name (e.g., 'In Progress', 'Done', 'Backlog'). */ + name: Schema.String, + /** The type of the state. One of "triage", "backlog", "unstarted", "started", "completed", "canceled", "duplicate". */ + type: Schema.String, + /** The position of the state in the team's workflow. States are displayed in ascending order of position within their type group. */ + position: Shared.Float +}) +export interface LinearWorkflowState extends Schema.Struct.Type {} + +/** + * `fragment LinearLabel on IssueLabel` + * + * Labels that can be associated with issues. Labels help categorize and filter issues across a workspace. They can be workspace-level (shared across all teams) or team-scoped. Labels have a color for visual identification and can be organized hierarchically into groups, where a parent label acts as a group containing child labels. Labels may also be inherited from parent teams to sub-teams. + */ +export const LinearLabel = Schema.Struct({ + /** The unique identifier of the entity. */ + id: Shared.ID, + /** The label's name. */ + name: Schema.String, + /** The label's color as a HEX string (e.g., '#EB5757'). Used for visual identification of the label in the UI. */ + color: Schema.String +}) +export interface LinearLabel extends Schema.Struct.Type {} + +/** + * `fragment LinearTeamLabel on IssueLabel` + * + * Labels that can be associated with issues. Labels help categorize and filter issues across a workspace. They can be workspace-level (shared across all teams) or team-scoped. Labels have a color for visual identification and can be organized hierarchically into groups, where a parent label acts as a group containing child labels. Labels may also be inherited from parent teams to sub-teams. + */ +export const LinearTeamLabel = Schema.Struct({ + ...LinearLabel.fields, + /** The label's description. */ + description: Schema.NullOr(Schema.String) +}) +export interface LinearTeamLabel extends Schema.Struct.Type {} + +/** + * `fragment LinearReaction on Reaction` + * + * An emoji reaction on a comment, issue, project update, initiative update, post, pull request, or pull request comment. Each reaction is associated with exactly one parent entity and is created by either a workspace user or an external user. Reactions are persisted individually but surfaced on their parent entities as aggregated reactionData. + */ +export const LinearReaction = Schema.Struct({ + /** The unique identifier of the entity. */ + id: Shared.ID, + /** The name of the emoji used for this reaction. For custom workspace emojis, this is the custom emoji name; for standard emojis, this is the normalized emoji name. */ + emoji: Schema.String, + /** The workspace user that created the reaction. Null if the reaction was created by an external user through an integration. */ + user: Schema.NullOr(LinearUser) +}) +export interface LinearReaction extends Schema.Struct.Type {} + +/** + * `fragment LinearComment on Comment` + * + * A comment associated with an issue, project update, initiative update, document content, post, project, or initiative. Comments support rich text (ProseMirror), emoji reactions, and threaded replies via parentId. Comments can be created by workspace users or by external users through integrations (e.g., Slack, Intercom). Each comment belongs to exactly one parent entity. + */ +export const LinearComment = Schema.Struct({ + /** The unique identifier of the entity. */ + id: Shared.ID, + /** The comment content in markdown format. This is a derived representation of the canonical bodyData ProseMirror content. */ + body: Schema.String, + /** The time at which the entity was created. */ + createdAt: Shared.DateTime, + /** Comment's URL. */ + url: Schema.String, + /** The user who wrote the comment. Null for comments created by integrations or bots without a user association. */ + user: Schema.NullOr(LinearUser), + /** Reactions associated with the comment. */ + reactions: Schema.Array(LinearReaction) +}) +export interface LinearComment extends Schema.Struct.Type {} + +/** A team is the primary organizational unit in Linear. Issues belong to teams, and each team has its own workflow states, cycles, labels, and settings. Teams can be public (visible to all workspace members), private (visible only to team members), or restricted (visible only within an enclosing private-team boundary). Teams can also have sub-teams that inherit settings from their parent. */ +export const TeamTeam = Schema.Struct({ + /** The team's unique key, used as a prefix in issue identifiers (e.g., 'ENG' in 'ENG-123') and in URLs. */ + key: Schema.String +}) +export interface TeamTeam extends Schema.Struct.Type {} + +export const LinearIssueLabelsIssueLabelConnection = Schema.Struct({ + nodes: Schema.Array(LinearLabel) +}) +export interface LinearIssueLabelsIssueLabelConnection extends Schema.Struct.Type {} + +/** + * `fragment LinearIssue on Issue` + * + * An issue is the core work item in Linear. Issues belong to a team, have a workflow status, can be assigned to users, carry a priority level, and can be organized into projects and cycles. Issues support sub-issues (parent-child hierarchy up to 10 levels deep), labels, due dates, estimates, and SLA tracking. They can also be linked to other issues via relations, attached to releases, and tracked through their full history of changes. + */ +export const LinearIssue = Schema.Struct({ + /** The unique identifier of the entity. */ + id: Shared.ID, + /** Issue's human readable identifier (e.g. ENG-123). */ + identifier: Schema.String, + /** The issue's unique number, scoped to the issue's team. Together with the team key, this forms the issue's human-readable identifier (e.g., ENG-123). */ + number: Shared.Float, + /** The issue's title. This is the primary human-readable summary of the work item. */ + title: Schema.String, + /** Issue URL. */ + url: Schema.String, + /** The issue's description in markdown format. */ + description: Schema.NullOr(Schema.String), + /** The time at which the entity was created. */ + createdAt: Shared.DateTime, + /** + * The last time at which the entity was meaningfully updated. This is the same as the creation time if the entity hasn't + * been updated after creation. + */ + updatedAt: Shared.DateTime, + /** The time at which the issue was moved into completed state. */ + completedAt: Schema.NullOr(Shared.DateTime), + /** The time at which the issue was moved into canceled state. */ + canceledAt: Schema.NullOr(Shared.DateTime), + /** The workflow state (issue status) that the issue is currently in. Workflow states represent the issue's progress through the team's workflow, such as Triage, Todo, In Progress, Done, or Canceled. */ + state: LinearWorkflowState, + /** The team that the issue belongs to. Every issue must belong to exactly one team, which determines the available workflow states, labels, and other team-specific configuration. */ + team: TeamTeam, + /** The user who created the issue. Null if the creator's account has been deleted or if the issue was created by an integration or system process. */ + creator: Schema.NullOr(LinearUser), + /** The user to whom the issue is assigned. Null if the issue is unassigned. */ + assignee: Schema.NullOr(LinearUser), + /** Labels associated with this issue. */ + labels: LinearIssueLabelsIssueLabelConnection +}) +export interface LinearIssue extends Schema.Struct.Type {} + +/** `fragment LinearPageInfo on PageInfo` */ +export const LinearPageInfo = Schema.Struct({ + /** Indicates if there are more results when paginating forward. */ + hasNextPage: Schema.Boolean, + /** Cursor representing the last result in the paginated results. */ + endCursor: Schema.NullOr(Schema.String) +}) +export interface LinearPageInfo extends Schema.Struct.Type {} + +/** A team is the primary organizational unit in Linear. Issues belong to teams, and each team has its own workflow states, cycles, labels, and settings. Teams can be public (visible to all workspace members), private (visible only to team members), or restricted (visible only within an enclosing private-team boundary). Teams can also have sub-teams that inherit settings from their parent. */ +export const T3ViewerTeamsNodesTeam = Schema.Struct({ + /** The unique identifier of the entity. */ + id: Shared.ID, + /** The team's unique key, used as a prefix in issue identifiers (e.g., 'ENG' in 'ENG-123') and in URLs. */ + key: Schema.String, + /** The team's name. */ + name: Schema.String +}) +export interface T3ViewerTeamsNodesTeam extends Schema.Struct.Type {} + +export const T3ViewerTeamsTeamConnection = Schema.Struct({ + nodes: Schema.Array(T3ViewerTeamsNodesTeam) +}) +export interface T3ViewerTeamsTeamConnection extends Schema.Struct.Type {} + +/** `query T3Viewer` */ +export const T3Viewer = GraphQL.query("T3Viewer", { + document: { + variables: [], + selections: [ + { name: "viewer", body: ["{...LinearUser}"] }, + { name: "teams", body: ["(first:250){nodes{id key name}}"] } + ], + fragments: [ + { name: "LinearUser", body: ["on User{id name displayName email avatarUrl}"] } + ] + }, + result: Schema.Struct({ + /** The currently authenticated user making the API request. */ + viewer: LinearUser, + /** All teams whose issues the user can access. This includes public teams and private teams the user is a member of. This may differ from `administrableTeams`, which returns teams whose settings the user can change but whose issues they don't necessarily have access to. */ + teams: T3ViewerTeamsTeamConnection + }) +}) +export declare namespace T3Viewer { + export type Variables = typeof T3Viewer.variables.Type + export type Result = typeof T3Viewer.result.Type +} + +export const IssueConnection = Schema.Struct({ + nodes: Schema.Array(LinearIssue), + pageInfo: LinearPageInfo +}) +export interface IssueConnection extends Schema.Struct.Type {} + +/** `query T3Issues` */ +export const T3Issues = GraphQL.query("T3Issues", { + document: { + variables: [ + { name: "first", body: "Int!" }, + { name: "after", body: "String" }, + { name: "filter", body: "IssueFilter!" } + ], + selections: [ + { name: "issues", body: ["(first:$", "first", " after:$", "after", " filter:$", "filter", " orderBy:updatedAt){nodes{...LinearIssue}pageInfo{...LinearPageInfo}}"] } + ], + fragments: [ + { name: "LinearIssue", body: ["on Issue{id identifier number title url description createdAt updatedAt completedAt canceledAt state{...LinearWorkflowState}team{key}creator{...LinearUser}assignee{...LinearUser}labels{nodes{...LinearLabel}}}"] }, + { name: "LinearPageInfo", body: ["on PageInfo{hasNextPage endCursor}"] }, + { name: "LinearWorkflowState", body: ["on WorkflowState{id name type position}"] }, + { name: "LinearUser", body: ["on User{id name displayName email avatarUrl}"] }, + { name: "LinearLabel", body: ["on IssueLabel{id name color}"] } + ] + }, + variables: { + first: Shared.Int, + after: Schema.optional(Schema.NullOr(Schema.String)), + filter: Shared.IssueFilter + }, + result: Schema.Struct({ + /** All issues. Returns a paginated list of issues visible to the authenticated user. Can be filtered by various criteria including team, assignee, state, labels, project, and cycle. */ + issues: IssueConnection + }) +}) +export declare namespace T3Issues { + export type Variables = typeof T3Issues.variables.Type + export type Result = typeof T3Issues.result.Type +} + +export const CommentConnection = Schema.Struct({ + nodes: Schema.Array(LinearComment), + pageInfo: LinearPageInfo +}) +export interface CommentConnection extends Schema.Struct.Type {} + +/** An attachment linking external content to an issue. Attachments represent connections to external resources such as GitHub pull requests, Slack messages, Zendesk tickets, Figma files, Sentry issues, Intercom conversations, and plain URLs. Each attachment has a title and subtitle displayed in the Linear UI, a URL serving as both the link destination and unique identifier per issue, and optional metadata specific to the source integration. */ +export const Attachment = Schema.Struct({ + /** The URL of the external resource this attachment links to. Also serves as a unique identifier for the attachment within an issue; no two attachments on the same issue can share the same URL. */ + url: Schema.String, + /** Content for the title line in the Linear attachment widget. */ + title: Schema.String, + /** The source type of the attachment, derived from the source metadata. Returns the integration type (e.g., 'github', 'slack', 'zendesk') or 'unknown' if no source is set. */ + sourceType: Schema.NullOr(Schema.String), + /** Integration-specific metadata for this attachment. The schema varies by source type and may include fields such as pull request status, review counts, commit information, ticket status, or other data from the external system. */ + metadata: Shared.JSONObject +}) +export interface Attachment extends Schema.Struct.Type {} + +export const AttachmentConnection = Schema.Struct({ + nodes: Schema.Array(Attachment) +}) +export interface AttachmentConnection extends Schema.Struct.Type {} + +/** A record of changes to an issue. Each history entry captures one or more property changes made to an issue within a short grouping window by the same actor. History entries track changes to fields such as title, assignee, status, priority, project, cycle, labels, due date, estimate, parent issue, and more. They also record metadata about what triggered the change (e.g., a user action, workflow automation, triage rule, or integration). */ +export const IssueHistory = Schema.Struct({ + /** The unique identifier of the entity. */ + id: Shared.ID, + /** The time at which the entity was created. */ + createdAt: Shared.DateTime, + /** The actor that performed the actions. This field may be empty in the case of integrations or automations. */ + actor: Schema.NullOr(LinearUser), + /** The state that the issue was moved from. */ + fromState: Schema.NullOr(LinearWorkflowState), + /** The state that the issue was moved to. */ + toState: Schema.NullOr(LinearWorkflowState), + /** The user that was unassigned from the issue. */ + fromAssignee: Schema.NullOr(LinearUser), + /** The user that was assigned to the issue. */ + toAssignee: Schema.NullOr(LinearUser), + /** The labels that were added to the issue. */ + addedLabels: Schema.NullOr(Schema.Array(LinearLabel)), + /** The labels that were removed from the issue. */ + removedLabels: Schema.NullOr(Schema.Array(LinearLabel)), + /** What the title was changed from. */ + fromTitle: Schema.NullOr(Schema.String), + /** What the title was changed to. */ + toTitle: Schema.NullOr(Schema.String) +}) +export interface IssueHistory extends Schema.Struct.Type {} + +export const IssueHistoryConnection = Schema.Struct({ + nodes: Schema.Array(IssueHistory) +}) +export interface IssueHistoryConnection extends Schema.Struct.Type {} + +/** An issue is the core work item in Linear. Issues belong to a team, have a workflow status, can be assigned to users, carry a priority level, and can be organized into projects and cycles. Issues support sub-issues (parent-child hierarchy up to 10 levels deep), labels, due dates, estimates, and SLA tracking. They can also be linked to other issues via relations, attached to releases, and tracked through their full history of changes. */ +export const T3IssueIssueIssue = Schema.Struct({ + ...LinearIssue.fields, + /** Comments associated with the issue, including inline comments on the issue's description. */ + comments: CommentConnection, + /** Reactions associated with the issue. */ + reactions: Schema.Array(LinearReaction), + /** Attachments associated with the issue. */ + attachments: AttachmentConnection, + /** History entries associated with the issue. */ + history: IssueHistoryConnection +}) +export interface T3IssueIssueIssue extends Schema.Struct.Type {} + +/** `query T3Issue` */ +export const T3Issue = GraphQL.query("T3Issue", { + document: { + variables: [ + { name: "id", body: "String!" }, + { name: "comments", body: "Int!" } + ], + selections: [ + { name: "issue", body: ["(id:$", "id", "){...LinearIssue comments(first:$", "comments", " orderBy:createdAt){nodes{...LinearComment}pageInfo{...LinearPageInfo}}reactions{...LinearReaction}attachments(first:50){nodes{url title sourceType metadata}}history(first:100 orderBy:createdAt){nodes{id createdAt actor{...LinearUser}fromState{...LinearWorkflowState}toState{...LinearWorkflowState}fromAssignee{...LinearUser}toAssignee{...LinearUser}addedLabels{...LinearLabel}removedLabels{...LinearLabel}fromTitle toTitle}}}"] } + ], + fragments: [ + { name: "LinearIssue", body: ["on Issue{id identifier number title url description createdAt updatedAt completedAt canceledAt state{...LinearWorkflowState}team{key}creator{...LinearUser}assignee{...LinearUser}labels{nodes{...LinearLabel}}}"] }, + { name: "LinearComment", body: ["on Comment{id body createdAt url user{...LinearUser}reactions{...LinearReaction}}"] }, + { name: "LinearPageInfo", body: ["on PageInfo{hasNextPage endCursor}"] }, + { name: "LinearReaction", body: ["on Reaction{id emoji user{...LinearUser}}"] }, + { name: "LinearUser", body: ["on User{id name displayName email avatarUrl}"] }, + { name: "LinearWorkflowState", body: ["on WorkflowState{id name type position}"] }, + { name: "LinearLabel", body: ["on IssueLabel{id name color}"] } + ] + }, + variables: { + id: Schema.String, + comments: Shared.Int + }, + result: Schema.Struct({ + /** One specific issue, looked up by its unique identifier. */ + issue: T3IssueIssueIssue + }) +}) +export declare namespace T3Issue { + export type Variables = typeof T3Issue.variables.Type + export type Result = typeof T3Issue.result.Type +} + +/** An issue is the core work item in Linear. Issues belong to a team, have a workflow status, can be assigned to users, carry a priority level, and can be organized into projects and cycles. Issues support sub-issues (parent-child hierarchy up to 10 levels deep), labels, due dates, estimates, and SLA tracking. They can also be linked to other issues via relations, attached to releases, and tracked through their full history of changes. */ +export const T3CommentsIssueIssue = Schema.Struct({ + /** Comments associated with the issue, including inline comments on the issue's description. */ + comments: CommentConnection +}) +export interface T3CommentsIssueIssue extends Schema.Struct.Type {} + +/** `query T3Comments` */ +export const T3Comments = GraphQL.query("T3Comments", { + document: { + variables: [ + { name: "id", body: "String!" }, + { name: "first", body: "Int!" }, + { name: "after", body: "String" } + ], + selections: [ + { name: "issue", body: ["(id:$", "id", "){comments(first:$", "first", " after:$", "after", " orderBy:createdAt){nodes{...LinearComment}pageInfo{...LinearPageInfo}}}"] } + ], + fragments: [ + { name: "LinearComment", body: ["on Comment{id body createdAt url user{...LinearUser}reactions{...LinearReaction}}"] }, + { name: "LinearPageInfo", body: ["on PageInfo{hasNextPage endCursor}"] }, + { name: "LinearUser", body: ["on User{id name displayName email avatarUrl}"] }, + { name: "LinearReaction", body: ["on Reaction{id emoji user{...LinearUser}}"] } + ] + }, + variables: { + id: Schema.String, + first: Shared.Int, + after: Schema.optional(Schema.NullOr(Schema.String)) + }, + result: Schema.Struct({ + /** One specific issue, looked up by its unique identifier. */ + issue: T3CommentsIssueIssue + }) +}) +export declare namespace T3Comments { + export type Variables = typeof T3Comments.variables.Type + export type Result = typeof T3Comments.result.Type +} + +export const WorkflowStateConnection = Schema.Struct({ + nodes: Schema.Array(LinearWorkflowState), + pageInfo: LinearPageInfo +}) +export interface WorkflowStateConnection extends Schema.Struct.Type {} + +export const NodesLabelsIssueLabelConnection = Schema.Struct({ + nodes: Schema.Array(LinearTeamLabel), + pageInfo: LinearPageInfo +}) +export interface NodesLabelsIssueLabelConnection extends Schema.Struct.Type {} + +export const UserConnection = Schema.Struct({ + nodes: Schema.Array(LinearUser), + pageInfo: LinearPageInfo +}) +export interface UserConnection extends Schema.Struct.Type {} + +/** A reusable template for creating issues, projects, or documents. Templates store pre-filled field values and content as JSON data. They can be scoped to a specific team or shared across the entire workspace. Team-scoped templates may be inherited from parent teams. */ +export const Template = Schema.Struct({ + /** The unique identifier of the entity. */ + id: Shared.ID, + /** The name of the template. */ + name: Schema.String, + /** A description of what the template is used for. */ + description: Schema.NullOr(Schema.String), + /** The template's content in markdown format: the body it pre-fills on the entity it creates. Distinct from `description`, which says what the template is for. Form templates serialize their form fields as markdown placeholders instead. Null when the template has no content. */ + content: Schema.NullOr(Schema.String), + /** The entity type this template is for, such as 'issue', 'project', or 'document'. */ + type: Schema.String, + /** [Internal] Whether the template has form fields */ + hasFormFields: Schema.Boolean, + /** The template data as a JSON-encoded string containing the pre-filled attributes for the entity type (e.g., issue fields, project configuration, or document content). */ + templateData: Shared.JSON +}) +export interface Template extends Schema.Struct.Type {} + +export const TemplateConnection = Schema.Struct({ + nodes: Schema.Array(Template) +}) +export interface TemplateConnection extends Schema.Struct.Type {} + +/** A team is the primary organizational unit in Linear. Issues belong to teams, and each team has its own workflow states, cycles, labels, and settings. Teams can be public (visible to all workspace members), private (visible only to team members), or restricted (visible only within an enclosing private-team boundary). Teams can also have sub-teams that inherit settings from their parent. */ +export const T3TeamTeamsNodesTeam = Schema.Struct({ + /** The unique identifier of the entity. */ + id: Shared.ID, + /** The team's unique key, used as a prefix in issue identifiers (e.g., 'ENG' in 'ENG-123') and in URLs. */ + key: Schema.String, + /** The team's name. */ + name: Schema.String, + /** The states that define the workflow associated with the team. */ + states: WorkflowStateConnection, + /** Labels associated with the team. */ + labels: NodesLabelsIssueLabelConnection, + /** Users who are members of this team. Supports filtering and pagination. */ + members: UserConnection, + /** Templates associated with the team. */ + templates: TemplateConnection +}) +export interface T3TeamTeamsNodesTeam extends Schema.Struct.Type {} + +export const T3TeamTeamsTeamConnection = Schema.Struct({ + nodes: Schema.Array(T3TeamTeamsNodesTeam) +}) +export interface T3TeamTeamsTeamConnection extends Schema.Struct.Type {} + +/** `query T3Team` */ +export const T3Team = GraphQL.query("T3Team", { + document: { + variables: [ + { name: "key", body: "String!" } + ], + selections: [ + { name: "teams", body: ["(first:1 filter:{key:{eq:$", "key", "}}){nodes{id key name states(first:100){nodes{...LinearWorkflowState}pageInfo{...LinearPageInfo}}labels(first:250){nodes{...LinearTeamLabel}pageInfo{...LinearPageInfo}}members(first:250){nodes{...LinearUser}pageInfo{...LinearPageInfo}}templates{nodes{id name description content type hasFormFields templateData}}}}"] }, + { name: "issueLabels", body: ["(first:250 filter:{team:{null:true}}){nodes{...LinearTeamLabel}pageInfo{...LinearPageInfo}}"] } + ], + fragments: [ + { name: "LinearWorkflowState", body: ["on WorkflowState{id name type position}"] }, + { name: "LinearPageInfo", body: ["on PageInfo{hasNextPage endCursor}"] }, + { name: "LinearTeamLabel", body: ["on IssueLabel{...LinearLabel description}"] }, + { name: "LinearUser", body: ["on User{id name displayName email avatarUrl}"] }, + { name: "LinearLabel", body: ["on IssueLabel{id name color}"] } + ] + }, + variables: { + key: Schema.String + }, + result: Schema.Struct({ + /** All teams whose issues the user can access. This includes public teams and private teams the user is a member of. This may differ from `administrableTeams`, which returns teams whose settings the user can change but whose issues they don't necessarily have access to. */ + teams: T3TeamTeamsTeamConnection, + /** All issue labels. Returns a paginated list of labels visible to the authenticated user, including both workspace-level and team-scoped labels. */ + issueLabels: NodesLabelsIssueLabelConnection + }) +}) +export declare namespace T3Team { + export type Variables = typeof T3Team.variables.Type + export type Result = typeof T3Team.result.Type +} + +/** An issue is the core work item in Linear. Issues belong to a team, have a workflow status, can be assigned to users, carry a priority level, and can be organized into projects and cycles. Issues support sub-issues (parent-child hierarchy up to 10 levels deep), labels, due dates, estimates, and SLA tracking. They can also be linked to other issues via relations, attached to releases, and tracked through their full history of changes. */ +export const IssueCreateIssueIssue = Schema.Struct({ + /** Issue's human readable identifier (e.g. ENG-123). */ + identifier: Schema.String, + /** Issue URL. */ + url: Schema.String +}) +export interface IssueCreateIssueIssue extends Schema.Struct.Type {} + +/** The result of an issue mutation, containing the created or updated issue and a success indicator. */ +export const IssueCreateIssuePayload = Schema.Struct({ + /** Whether the operation was successful. */ + success: Schema.Boolean, + /** The issue that was created or updated. */ + issue: Schema.NullOr(IssueCreateIssueIssue) +}) +export interface IssueCreateIssuePayload extends Schema.Struct.Type {} + +/** `mutation T3IssueCreate` */ +export const T3IssueCreate = GraphQL.mutation("T3IssueCreate", { + document: { + variables: [ + { name: "input", body: "IssueCreateInput!" } + ], + selections: [ + { name: "issueCreate", body: ["(input:$", "input", "){success issue{identifier url}}"] } + ], + fragments: [] + }, + variables: { + input: Shared.IssueCreateInput + }, + result: Schema.Struct({ + /** Creates a new issue. */ + issueCreate: IssueCreateIssuePayload + }) +}) +export declare namespace T3IssueCreate { + export type Variables = typeof T3IssueCreate.variables.Type + export type Result = typeof T3IssueCreate.result.Type +} + +/** The result of an issue mutation, containing the created or updated issue and a success indicator. */ +export const IssueUpdateIssuePayload = Schema.Struct({ + /** Whether the operation was successful. */ + success: Schema.Boolean +}) +export interface IssueUpdateIssuePayload extends Schema.Struct.Type {} + +/** `mutation T3IssueUpdate` */ +export const T3IssueUpdate = GraphQL.mutation("T3IssueUpdate", { + document: { + variables: [ + { name: "id", body: "String!" }, + { name: "input", body: "IssueUpdateInput!" } + ], + selections: [ + { name: "issueUpdate", body: ["(id:$", "id", " input:$", "input", "){success}"] } + ], + fragments: [] + }, + variables: { + id: Schema.String, + input: Shared.IssueUpdateInput + }, + result: Schema.Struct({ + /** Updates an issue. */ + issueUpdate: IssueUpdateIssuePayload + }) +}) +export declare namespace T3IssueUpdate { + export type Variables = typeof T3IssueUpdate.variables.Type + export type Result = typeof T3IssueUpdate.result.Type +} + +/** The result of a comment mutation. */ +export const CommentPayload = Schema.Struct({ + /** Whether the operation was successful. */ + success: Schema.Boolean +}) +export interface CommentPayload extends Schema.Struct.Type {} + +/** `mutation T3CommentCreate` */ +export const T3CommentCreate = GraphQL.mutation("T3CommentCreate", { + document: { + variables: [ + { name: "input", body: "CommentCreateInput!" } + ], + selections: [ + { name: "commentCreate", body: ["(input:$", "input", "){success}"] } + ], + fragments: [] + }, + variables: { + input: Shared.CommentCreateInput + }, + result: Schema.Struct({ + /** Creates a new comment. */ + commentCreate: CommentPayload + }) +}) +export declare namespace T3CommentCreate { + export type Variables = typeof T3CommentCreate.variables.Type + export type Result = typeof T3CommentCreate.result.Type +} + +/** The result of a reaction mutation. */ +export const ReactionPayload = Schema.Struct({ + /** Whether the operation was successful. */ + success: Schema.Boolean +}) +export interface ReactionPayload extends Schema.Struct.Type {} + +/** `mutation T3ReactionCreate` */ +export const T3ReactionCreate = GraphQL.mutation("T3ReactionCreate", { + document: { + variables: [ + { name: "input", body: "ReactionCreateInput!" } + ], + selections: [ + { name: "reactionCreate", body: ["(input:$", "input", "){success}"] } + ], + fragments: [] + }, + variables: { + input: Shared.ReactionCreateInput + }, + result: Schema.Struct({ + /** Creates a new reaction. */ + reactionCreate: ReactionPayload + }) +}) +export declare namespace T3ReactionCreate { + export type Variables = typeof T3ReactionCreate.variables.Type + export type Result = typeof T3ReactionCreate.result.Type +} + +/** A generic payload return from entity deletion mutations. */ +export const DeletePayload = Schema.Struct({ + /** Whether the operation was successful. */ + success: Schema.Boolean +}) +export interface DeletePayload extends Schema.Struct.Type {} + +/** `mutation T3ReactionDelete` */ +export const T3ReactionDelete = GraphQL.mutation("T3ReactionDelete", { + document: { + variables: [ + { name: "id", body: "String!" } + ], + selections: [ + { name: "reactionDelete", body: ["(id:$", "id", "){success}"] } + ], + fragments: [] + }, + variables: { + id: Schema.String + }, + result: Schema.Struct({ + /** Deletes a reaction. */ + reactionDelete: DeletePayload + }) +}) +export declare namespace T3ReactionDelete { + export type Variables = typeof T3ReactionDelete.variables.Type + export type Result = typeof T3ReactionDelete.result.Type +} + +/** An issue is the core work item in Linear. Issues belong to a team, have a workflow status, can be assigned to users, carry a priority level, and can be organized into projects and cycles. Issues support sub-issues (parent-child hierarchy up to 10 levels deep), labels, due dates, estimates, and SLA tracking. They can also be linked to other issues via relations, attached to releases, and tracked through their full history of changes. */ +export const T3IssueReactionsIssueIssue = Schema.Struct({ + /** Reactions associated with the issue. */ + reactions: Schema.Array(LinearReaction) +}) +export interface T3IssueReactionsIssueIssue extends Schema.Struct.Type {} + +/** `query T3IssueReactions` */ +export const T3IssueReactions = GraphQL.query("T3IssueReactions", { + document: { + variables: [ + { name: "id", body: "String!" } + ], + selections: [ + { name: "issue", body: ["(id:$", "id", "){reactions{...LinearReaction}}"] } + ], + fragments: [ + { name: "LinearReaction", body: ["on Reaction{id emoji user{...LinearUser}}"] }, + { name: "LinearUser", body: ["on User{id name displayName email avatarUrl}"] } + ] + }, + variables: { + id: Schema.String + }, + result: Schema.Struct({ + /** One specific issue, looked up by its unique identifier. */ + issue: T3IssueReactionsIssueIssue + }) +}) +export declare namespace T3IssueReactions { + export type Variables = typeof T3IssueReactions.variables.Type + export type Result = typeof T3IssueReactions.result.Type +} + +/** A comment associated with an issue, project update, initiative update, document content, post, project, or initiative. Comments support rich text (ProseMirror), emoji reactions, and threaded replies via parentId. Comments can be created by workspace users or by external users through integrations (e.g., Slack, Intercom). Each comment belongs to exactly one parent entity. */ +export const Comment = Schema.Struct({ + /** Reactions associated with the comment. */ + reactions: Schema.Array(LinearReaction) +}) +export interface Comment extends Schema.Struct.Type {} + +/** `query T3CommentReactions` */ +export const T3CommentReactions = GraphQL.query("T3CommentReactions", { + document: { + variables: [ + { name: "id", body: "String!" } + ], + selections: [ + { name: "comment", body: ["(id:$", "id", "){reactions{...LinearReaction}}"] } + ], + fragments: [ + { name: "LinearReaction", body: ["on Reaction{id emoji user{...LinearUser}}"] }, + { name: "LinearUser", body: ["on User{id name displayName email avatarUrl}"] } + ] + }, + variables: { + id: Schema.String + }, + result: Schema.Struct({ + /** A specific comment. */ + comment: Comment + }) +}) +export declare namespace T3CommentReactions { + export type Variables = typeof T3CommentReactions.variables.Type + export type Result = typeof T3CommentReactions.result.Type +} + +/** Every operation in LinearApi.graphql. */ +export const LinearApiGraphQLGroup = GraphQLGroup.make(T3Viewer, T3Issues, T3Issue, T3Comments, T3Team, T3IssueCreate, T3IssueUpdate, T3CommentCreate, T3ReactionCreate, T3ReactionDelete, T3IssueReactions, T3CommentReactions) diff --git a/packages/issue-tracker-linear/src/server/LinearApi.ts b/packages/issue-tracker-linear/src/server/LinearApi.ts new file mode 100644 index 000000000000..06233fd71794 --- /dev/null +++ b/packages/issue-tracker-linear/src/server/LinearApi.ts @@ -0,0 +1,415 @@ +/** + * Linear's GraphQL API over the platform HttpClient, signed with the personal API key the user + * saved in Settings. The operations live in `LinearApi.graphql`; their client is generated from + * `schema/linear.graphql` (`vp run generate`), so the tracker above sees Linear's shapes and + * nothing looser. + * + * Linear rate-limits by query complexity and reports the budget in `x-ratelimit-*` headers; a + * refusal arrives as HTTP 429 or as a `RATELIMITED` GraphQL error on a 400, and both map to + * `rate-limited` with the reset time when Linear names one. + * + * @module issue-tracker-linear/server/LinearApi + */ +import * as Clock from "effect/Clock"; +import * as Config from "effect/Config"; +import * as Context from "effect/Context"; +import * as Effect from "effect/Effect"; +import * as Layer from "effect/Layer"; +import * as Option from "effect/Option"; +import * as Schema from "effect/Schema"; +import { + GraphQLClient, + GraphQLClientError, + GraphQLMiddleware, + GraphQLProtocol, +} from "effect/graphql"; +import { HttpClient } from "effect/http"; +import * as Headers from "effect/http/Headers"; +import { IssueTrackerKind } from "@t3tools/contracts"; +import { IssueTrackerError } from "@t3tools/issue-tracker-core/server/IssueTracker"; +import * as IssueTrackerHost from "@t3tools/issue-tracker-core/server/IssueTrackerHost"; +import { retryAtFromHeader } from "@t3tools/source-control-core/server/SourceControlRateLimit"; + +import type { + CommentCreateInput, + IssueCreateInput, + IssueFilter, + IssueUpdateInput, +} from "../../schema/linear.graphql.ts"; +import { + LinearApiGraphQLGroup, + type Attachment, + type IssueHistory, + type LinearComment, + type LinearIssue, + type LinearReaction, + type LinearTeamLabel, + type LinearUser, + type T3Issue, + type T3Team, + type Template, +} from "./LinearApi.graphql.ts"; + +export type { IssueFilter } from "../../schema/linear.graphql.ts"; +export type { + LinearComment, + LinearIssue, + LinearReaction, + LinearUser, +} from "./LinearApi.graphql.ts"; +export type { LinearWorkflowState } from "./LinearApi.graphql.ts"; +export type LinearAttachment = Attachment; +export type LinearHistoryEntry = IssueHistory; + +export const KIND = IssueTrackerKind.make("linear"); +const DEFAULT_API_URL = "https://api.linear.app/graphql"; + +const LinearApiConfig = Config.all({ + apiUrl: Config.String("T3CODE_LINEAR_API_URL").pipe(Config.withDefault(DEFAULT_API_URL)), +}); + +const LinearTemplateData = Schema.Struct({ + title: Schema.optional(Schema.NullOr(Schema.String)), + description: Schema.optional(Schema.Unknown), + descriptionData: Schema.optional(Schema.Unknown), + labelIds: Schema.optional(Schema.NullOr(Schema.Array(Schema.String))), + assigneeId: Schema.optional(Schema.NullOr(Schema.String)), +}); +type LinearTemplateData = typeof LinearTemplateData.Type; +const decodeTemplateData = Schema.decodeUnknownOption( + Schema.Union([Schema.fromJsonString(LinearTemplateData), LinearTemplateData]), +); + +/** A template with its data read: Linear sends it as a JSON string, and has sent an object. */ +export interface LinearTemplate extends Omit { + readonly templateData: LinearTemplateData; +} + +type LinearTeamDetail = T3Team.Result["teams"]["nodes"][number]; +type LinearIssueDetail = NonNullable; + +/** The team with the workspace-wide labels that any of its issues may also carry. */ +export interface LinearTeamScope { + readonly team: Omit & { + readonly templates: { readonly nodes: ReadonlyArray }; + }; + readonly workspaceLabels: ReadonlyArray; + /** Linear had more than one page of something; a missing label or member may still exist. */ + readonly truncated: boolean; +} + +export class LinearApi extends Context.Service< + LinearApi, + { + /** Who a credential is, and the teams it reaches. Takes the token so it can vet a new one. */ + readonly viewer: (token?: string) => Effect.Effect< + { + readonly viewer: LinearUser; + readonly teams: ReadonlyArray<{ + readonly id: string; + readonly key: string; + readonly name: string; + }>; + }, + IssueTrackerError + >; + readonly listIssues: (input: { + readonly filter: IssueFilter; + readonly first: number; + readonly after?: string | undefined; + }) => Effect.Effect< + { readonly nodes: ReadonlyArray; readonly nextCursor: string | null }, + IssueTrackerError + >; + /** Null when Linear has no issue by that identifier, or the credential cannot see it. */ + readonly getIssue: ( + identifier: string, + comments: number, + ) => Effect.Effect; + readonly getComments: (input: { + readonly identifier: string; + readonly first: number; + readonly after: string; + }) => Effect.Effect< + { readonly nodes: ReadonlyArray; readonly nextCursor: string | null }, + IssueTrackerError + >; + readonly getTeam: (key: string) => Effect.Effect; + readonly createIssue: ( + input: IssueCreateInput, + ) => Effect.Effect<{ readonly identifier: string; readonly url: string }, IssueTrackerError>; + readonly updateIssue: ( + identifier: string, + input: IssueUpdateInput, + ) => Effect.Effect; + readonly createComment: (input: CommentCreateInput) => Effect.Effect; + readonly createReaction: (input: { + readonly issueId?: string | undefined; + readonly commentId?: string | undefined; + readonly emoji: string; + }) => Effect.Effect; + readonly deleteReaction: (id: string) => Effect.Effect; + /** Reactions on an issue (by identifier) or a comment (by id), to find the viewer's own. */ + readonly listReactions: (input: { + readonly issueId?: string | undefined; + readonly commentId?: string | undefined; + }) => Effect.Effect, IssueTrackerError>; + } +>()("@t3tools/issue-tracker-linear/server/LinearApi") {} + +/** The API key a call is sent with: the stored one, or a new one being vetted. */ +class LinearToken extends Context.Service()( + "@t3tools/issue-tracker-linear/server/LinearApi/LinearToken", +) {} + +class LinearAuth extends GraphQLMiddleware.Service()( + "@t3tools/issue-tracker-linear/server/LinearApi/LinearAuth", +) {} + +const LinearGroup = LinearApiGraphQLGroup.middleware(LinearAuth); + +const fail = ( + operation: string, + reason: IssueTrackerError["reason"], + detail: string, + extra: { readonly retryAt?: number; readonly cause?: unknown } = {}, +) => + new IssueTrackerError({ + tracker: KIND, + operation, + reason, + detail, + ...(extra.retryAt === undefined ? {} : { retryAt: extra.retryAt }), + ...(extra.cause === undefined ? {} : { cause: extra.cause }), + }); + +const hasCode = (errors: ReadonlyArray, code: string) => + errors.some((error) => error.extensions?.["code"] === code); + +/** Linear's answer as the tracker's error. Linear writes its messages for people. */ +const toTrackerError = ( + operation: string, + error: GraphQLClientError.GraphQLClientError, + now: number, +): IssueTrackerError => { + const reason = error.reason; + if (reason._tag !== "ResponseError" && reason._tag !== "TransportError") { + return fail(operation, "failed", "Linear returned an unexpected body.", { cause: error }); + } + const errors = reason._tag === "ResponseError" ? reason.errors : []; + const headers = reason.headers ?? Headers.empty; + if (reason.status === 429 || hasCode(errors, "RATELIMITED")) { + const retryAt = retryAtFromHeader( + headers["x-ratelimit-requests-reset"] ?? headers["x-ratelimit-complexity-reset"], + now, + ); + return fail( + operation, + "rate-limited", + "Linear's rate limit was reached.", + retryAt === undefined ? {} : { retryAt }, + ); + } + if (reason.status === 401 || reason.status === 403 || hasCode(errors, "AUTHENTICATION_ERROR")) { + return fail(operation, "unauthenticated", "Linear rejected the API key."); + } + if (reason._tag === "ResponseError") { + return fail(operation, "failed", errors[0]?.message.trim() || "Linear refused the request."); + } + return reason.status === undefined + ? fail(operation, "failed", "Linear could not be reached.", { cause: error }) + : fail(operation, "failed", `Linear returned HTTP ${reason.status} with an unexpected body.`); +}; + +const nextCursor = (pageInfo: { + readonly hasNextPage: boolean; + readonly endCursor: string | null; +}) => (pageInfo.hasNextPage ? pageInfo.endCursor : null); + +export const make = Effect.gen(function* () { + // Only a default-carrying string: nothing in the environment can make it fail. + const config = yield* LinearApiConfig.pipe(Effect.orDie); + const httpClient = yield* HttpClient.HttpClient; + const host = yield* IssueTrackerHost.IssueTrackerHost; + + const client = yield* GraphQLClient.make(LinearGroup).pipe( + Effect.provide( + Layer.mergeAll( + Layer.succeed( + LinearAuth, + GraphQLMiddleware.mapRequest((request) => + Effect.gen(function* () { + const token = yield* LinearToken; + // A personal API key goes in as-is; `Bearer` is for OAuth tokens, which this is not. + return { ...request, headers: Headers.set(request.headers, "authorization", token) }; + }), + ), + ), + GraphQLProtocol.layerHttp({ url: config.apiUrl }).pipe( + Layer.provide(Layer.succeed(HttpClient.HttpClient, httpClient)), + ), + ), + ), + ); + + const storedToken = (operation: string) => + host.credentials + .get(KIND) + .pipe( + Effect.flatMap( + Effect.fromOption(() => + fail(operation, "unauthenticated", "Linear is not connected on this server."), + ), + ), + ); + + const call = Effect.fn("LinearApi.call")(function* ( + operation: string, + run: ( + linear: typeof client, + ) => Effect.Effect, + token?: string, + ): Effect.fn.Return { + yield* Effect.annotateCurrentSpan({ "linear.operation": operation }); + const key = token ?? (yield* storedToken(operation)); + return yield* run(client).pipe( + Effect.catch((error) => + Effect.flatMap(Clock.currentTimeMillis, (now) => + Effect.fail(toTrackerError(operation, error, now)), + ), + ), + Effect.provideService(LinearToken, key), + ); + }); + + const applied = (operation: string, result: { readonly success: boolean }) => + result.success + ? Effect.void + : Effect.fail(fail(operation, "failed", "Linear did not apply the change.")); + + const viewer: LinearApi["Service"]["viewer"] = (token) => + call("viewer", (linear) => linear.T3Viewer(), token).pipe( + Effect.map((data) => ({ viewer: data.viewer, teams: data.teams.nodes })), + ); + + const listIssues: LinearApi["Service"]["listIssues"] = (input) => + call("listIssues", (linear) => + linear.T3Issues({ first: input.first, after: input.after ?? null, filter: input.filter }), + ).pipe( + Effect.map((data) => ({ + nodes: data.issues.nodes, + nextCursor: nextCursor(data.issues.pageInfo), + })), + ); + + const getIssue: LinearApi["Service"]["getIssue"] = (identifier, comments) => + call("getIssue", (linear) => linear.T3Issue({ id: identifier, comments })).pipe( + Effect.map((data) => data.issue), + // Linear answers an unknown identifier with an error and no data, not with null. + Effect.catchIf( + (error) => error.reason === "failed" && /not found/i.test(error.detail), + () => Effect.succeed(null), + ), + ); + + const getComments: LinearApi["Service"]["getComments"] = (input) => + call("getComments", (linear) => + linear.T3Comments({ id: input.identifier, first: input.first, after: input.after }), + ).pipe( + Effect.flatMap((data) => + data.issue === null + ? Effect.fail(fail("getComments", "not-found", "This issue no longer exists.")) + : Effect.succeed({ + nodes: data.issue.comments.nodes, + nextCursor: nextCursor(data.issue.comments.pageInfo), + }), + ), + ); + + const getTeam: LinearApi["Service"]["getTeam"] = (key) => + call("getTeam", (linear) => linear.T3Team({ key })).pipe( + Effect.map((data) => { + const team = data.teams.nodes[0]; + if (team === undefined) return null; + return { + team: { + ...team, + templates: { + nodes: team.templates.nodes.map((template) => ({ + ...template, + templateData: Option.getOrElse( + decodeTemplateData(template.templateData), + (): LinearTemplateData => ({}), + ), + })), + }, + }, + workspaceLabels: data.issueLabels.nodes, + truncated: + team.states.pageInfo.hasNextPage || + team.labels.pageInfo.hasNextPage || + team.members.pageInfo.hasNextPage || + data.issueLabels.pageInfo.hasNextPage, + }; + }), + ); + + const createIssue: LinearApi["Service"]["createIssue"] = (input) => + call("createIssue", (linear) => linear.T3IssueCreate({ input })).pipe( + Effect.flatMap(({ issueCreate }) => + issueCreate.success && issueCreate.issue !== null + ? Effect.succeed(issueCreate.issue) + : Effect.fail(fail("createIssue", "failed", "Linear did not create the issue.")), + ), + ); + + const updateIssue: LinearApi["Service"]["updateIssue"] = (identifier, input) => + call("updateIssue", (linear) => linear.T3IssueUpdate({ id: identifier, input })).pipe( + Effect.flatMap(({ issueUpdate }) => applied("updateIssue", issueUpdate)), + ); + + const createComment: LinearApi["Service"]["createComment"] = (input) => + call("createComment", (linear) => linear.T3CommentCreate({ input })).pipe( + Effect.flatMap(({ commentCreate }) => applied("createComment", commentCreate)), + ); + + const createReaction: LinearApi["Service"]["createReaction"] = (input) => + call("createReaction", (linear) => + linear.T3ReactionCreate({ + input: + input.commentId === undefined + ? { issueId: input.issueId ?? null, emoji: input.emoji } + : { commentId: input.commentId, emoji: input.emoji }, + }), + ).pipe(Effect.flatMap(({ reactionCreate }) => applied("createReaction", reactionCreate))); + + const deleteReaction: LinearApi["Service"]["deleteReaction"] = (id) => + call("deleteReaction", (linear) => linear.T3ReactionDelete({ id })).pipe( + Effect.flatMap(({ reactionDelete }) => applied("deleteReaction", reactionDelete)), + ); + + const listReactions: LinearApi["Service"]["listReactions"] = (input) => + input.commentId === undefined + ? call("listReactions", (linear) => + linear.T3IssueReactions({ id: input.issueId ?? "" }), + ).pipe(Effect.map((data) => data.issue.reactions)) + : call("listReactions", (linear) => + linear.T3CommentReactions({ id: input.commentId ?? "" }), + ).pipe(Effect.map((data) => data.comment.reactions)); + + return LinearApi.of({ + viewer, + listIssues, + getIssue, + getComments, + getTeam, + createIssue, + updateIssue, + createComment, + createReaction, + deleteReaction, + listReactions, + }); +}); + +export const layer = Layer.effect(LinearApi, make); diff --git a/packages/issue-tracker-linear/src/server/LinearIssueTracker.test.ts b/packages/issue-tracker-linear/src/server/LinearIssueTracker.test.ts new file mode 100644 index 000000000000..edbcf7bf50f4 --- /dev/null +++ b/packages/issue-tracker-linear/src/server/LinearIssueTracker.test.ts @@ -0,0 +1,377 @@ +import { describe, expect, it } from "@effect/vitest"; +import * as Effect from "effect/Effect"; +import * as Layer from "effect/Layer"; +import * as Option from "effect/Option"; +import { HttpClient, HttpClientResponse } from "effect/http"; +import { IssueTrackerKind } from "@t3tools/contracts"; +import type { StandaloneIssueTrackerApi } from "@t3tools/issue-tracker-core/server/IssueTracker"; +import * as IssueTrackerHost from "@t3tools/issue-tracker-core/server/IssueTrackerHost"; + +import * as LinearApi from "./LinearApi.ts"; +import * as LinearIssueTracker from "./LinearIssueTracker.ts"; + +const user = (id: string, displayName: string) => ({ + id, + name: displayName, + displayName, + email: `${displayName}@acme.test`, + avatarUrl: null, +}); +const JULIUS = user("usr_julius", "julius"); +const THEO = user("usr_theo", "theo"); + +const state = (name: string, type: string, position = 0) => ({ + id: `st_${name.toLowerCase().replaceAll(" ", "-")}`, + name, + type, + position, +}); + +const issue = ( + identifier: string, + overrides: Partial> = {}, +): Record => ({ + id: `iss_${identifier}`, + identifier, + number: Number(identifier.split("-")[1]), + title: `Issue ${identifier}`, + url: `https://linear.app/acme/issue/${identifier}`, + description: "body", + createdAt: "2026-07-01T00:00:00.000Z", + updatedAt: "2026-07-02T00:00:00.000Z", + completedAt: null, + canceledAt: null, + state: state("In Progress", "started"), + team: { key: identifier.split("-")[0] }, + creator: JULIUS, + assignee: THEO, + labels: { nodes: [{ id: "lbl_bug", name: "Bug", color: "#f00" }] }, + ...overrides, +}); + +/** An issue as the detail query answers it, with nothing hanging off it. */ +const bareDetail = (identifier: string) => + issue(identifier, { + comments: { nodes: [], pageInfo: { hasNextPage: false, endCursor: null } }, + reactions: [], + attachments: { nodes: [] }, + history: { nodes: [] }, + }); + +/** Answers each GraphQL document by its operation name, the way Linear would. */ +function fakeLinear( + answers: Record) => unknown>, + stored: string | null = "lin_api_stored", +) { + const requests: Array<{ + readonly authorization: string | undefined; + readonly operation: string; + }> = []; + const http = Layer.succeed( + HttpClient.HttpClient, + HttpClient.make((request) => + Effect.sync(() => { + const body = request.body; + const text = + body._tag === "Uint8Array" ? new TextDecoder().decode(body.body) : String(body._tag); + const parsed = JSON.parse(text) as { query: string; variables: Record }; + const operation = /^(?:query|mutation) (\w+)/.exec(parsed.query)?.[1] ?? "?"; + requests.push({ authorization: request.headers.authorization, operation }); + const answer = answers[operation]; + const response = + answer === undefined + ? new Response( + JSON.stringify({ errors: [{ message: `No answer for ${operation}` }] }), + { + status: 400, + headers: { "content-type": "application/json" }, + }, + ) + : new Response(JSON.stringify({ data: answer(parsed.variables) }), { + status: 200, + headers: { "content-type": "application/json" }, + }); + return HttpClientResponse.fromWeb(request, response); + }), + ), + ); + const host = Layer.succeed( + IssueTrackerHost.IssueTrackerHost, + IssueTrackerHost.IssueTrackerHost.of({ + credentials: { get: () => Effect.succeed(Option.fromNullishOr(stored)) }, + }), + ); + // Every optional write is implemented here; the type says so for the calls below. + const tracker = LinearIssueTracker.make.pipe( + Effect.map((api) => api as Required), + Effect.provide(LinearApi.layer.pipe(Layer.provide(Layer.merge(http, host)))), + ); + return { tracker, requests }; +} + +const target = { cwd: "/w/web", host: "linear.app", scope: "ENG" }; + +describe("LinearIssueTracker", () => { + it.effect("lists a team's issues as summaries keyed by identifier", () => + Effect.gen(function* () { + const { tracker, requests } = fakeLinear({ + T3Viewer: () => ({ viewer: JULIUS, teams: { nodes: [] } }), + T3Issues: (variables) => { + expect(variables.filter).toMatchObject({ + team: { key: { eq: "ENG" } }, + state: { type: { nin: ["completed", "canceled"] } }, + assignee: { id: { eq: "usr_julius" } }, + }); + return { + issues: { + nodes: [ + issue("ENG-2", { + state: state("Done", "completed"), + completedAt: "2026-07-03T00:00:00.000Z", + }), + issue("ENG-1"), + ], + pageInfo: { hasNextPage: true, endCursor: "cur_2" }, + }, + }; + }, + }); + const api = yield* tracker; + expect(api.kind).toBe(IssueTrackerKind.make("linear")); + expect(api.standalone).toMatchObject({ host: "linear.app", scopeNoun: "team" }); + + const page = yield* api.listIssues({ + ...target, + state: "open", + involvement: "assigned", + viewer: "usr_julius", + limit: 50, + }); + expect(page.nextCursor).toBe("cur_2"); + expect(page.items.map((item) => [item.key, item.displayKey, item.state])).toEqual([ + ["ENG-2", "ENG-2", { category: "closed", name: "Done", closeReason: "completed" }], + ["ENG-1", "ENG-1", { category: "open", name: "In Progress" }], + ]); + expect(page.items[0]).toMatchObject({ + closedAt: "2026-07-03T00:00:00.000Z", + author: { login: "usr_julius", name: "julius" }, + assignees: [{ login: "usr_theo", name: "theo" }], + labels: [{ name: "Bug", color: "#f00" }], + }); + // The stored key goes in as-is, not as a bearer token. + expect(requests.map((request) => request.authorization)).toEqual(["lin_api_stored"]); + }), + ); + + it.effect("reads an issue with its comments, reactions, history and linked pull requests", () => + Effect.gen(function* () { + const { tracker } = fakeLinear({ + T3Viewer: () => ({ viewer: JULIUS, teams: { nodes: [] } }), + T3Issue: () => ({ + issue: issue("ENG-7", { + comments: { + nodes: [ + { + id: "cmt_1", + body: "hi", + createdAt: "2026-07-02T01:00:00.000Z", + url: "https://linear.app/acme/issue/ENG-7#comment-cmt_1", + user: THEO, + reactions: [{ id: "r1", emoji: "๐Ÿ‘", user: JULIUS }], + }, + ], + pageInfo: { hasNextPage: true, endCursor: "cmt_cur" }, + }, + reactions: [ + { id: "r2", emoji: "๐Ÿš€", user: THEO }, + { id: "r3", emoji: "๐Ÿš€", user: JULIUS }, + { id: "r4", emoji: "๐Ÿคท", user: THEO }, + ], + attachments: { + nodes: [ + { + url: "https://github.com/acme/web/pull/12", + title: "Fix it", + sourceType: "github", + metadata: { status: "merged" }, + }, + { url: "https://example.test/doc", title: "Doc", sourceType: null, metadata: {} }, + ], + }, + history: { + nodes: [ + { + id: "h1", + createdAt: "2026-07-01T01:00:00.000Z", + actor: THEO, + fromState: state("Todo", "unstarted"), + toState: state("Done", "completed"), + fromAssignee: null, + toAssignee: JULIUS, + addedLabels: [{ id: "lbl_bug", name: "Bug", color: "#f00" }], + removedLabels: null, + fromTitle: null, + toTitle: null, + }, + ], + }, + }), + }), + }); + const api = yield* tracker; + const detail = yield* api.getIssue({ ...target, key: "eng-7" }); + expect(detail.viewer).toBe("usr_julius"); + expect(detail.commentsCursor).toBe("cmt_cur"); + expect(detail.comments[0]?.reactions).toEqual([ + { content: "thumbs-up", count: 1, actors: [], viewerHasReacted: true }, + ]); + // Grouped per emoji, the viewer left out of the names; an emoji outside the vocabulary is dropped. + expect(detail.reactions).toEqual([ + { content: "rocket", count: 2, actors: ["theo"], viewerHasReacted: true }, + ]); + expect(detail.events.map((event) => [event.kind, event.detail])).toEqual([ + ["closed", "Done"], + ["labeled", "Bug"], + ["assigned", "julius"], + ]); + expect(detail.linkedPullRequests).toEqual([ + expect.objectContaining({ repository: "acme/web", number: 12, state: "merged" }), + ]); + + const missing = yield* Effect.flip(api.getIssue({ ...target, key: "123" })); + expect(missing.reason).toBe("not-found"); + }), + ); + + it.effect("closes through the team's completed state, without a key or outside the team", () => + Effect.gen(function* () { + const updates: Array> = []; + const { tracker } = fakeLinear( + { + T3Team: () => ({ + teams: { + nodes: [ + { + id: "team_eng", + key: "ENG", + name: "Engineering", + states: { + nodes: [ + state("Canceled", "canceled", 3), + state("Done", "completed", 2), + state("Todo", "unstarted", 1), + ], + pageInfo: { hasNextPage: false, endCursor: null }, + }, + labels: { nodes: [], pageInfo: { hasNextPage: false, endCursor: null } }, + members: { nodes: [], pageInfo: { hasNextPage: false, endCursor: null } }, + templates: { nodes: [] }, + }, + ], + }, + issueLabels: { nodes: [], pageInfo: { hasNextPage: false, endCursor: null } }, + }), + T3IssueUpdate: (variables) => { + updates.push(variables); + return { issueUpdate: { success: true } }; + }, + }, + null, + ); + const api = yield* tracker; + const unauthenticated = yield* Effect.flip( + api.setState({ ...target, key: "ENG-1", state: "closed" }), + ); + expect(unauthenticated.reason).toBe("unauthenticated"); + + const connected = fakeLinear({ + T3Team: () => ({ + teams: { + nodes: [ + { + id: "team_eng", + key: "ENG", + name: "Engineering", + states: { + nodes: [ + state("Canceled", "canceled", 3), + state("Done", "completed", 2), + state("Todo", "unstarted", 1), + ], + pageInfo: { hasNextPage: false, endCursor: null }, + }, + labels: { nodes: [], pageInfo: { hasNextPage: false, endCursor: null } }, + members: { nodes: [], pageInfo: { hasNextPage: false, endCursor: null } }, + templates: { nodes: [] }, + }, + ], + }, + issueLabels: { nodes: [], pageInfo: { hasNextPage: false, endCursor: null } }, + }), + T3Issue: (variables) => ({ issue: bareDetail(String(variables.id)) }), + T3IssueUpdate: (variables) => { + updates.push(variables); + return { issueUpdate: { success: true } }; + }, + }); + const live = yield* connected.tracker; + // An identifier from another team resolves in Linear, so the team is checked before writing. + const foreign = yield* Effect.flip( + live.setState({ ...target, key: "OPS-3", state: "closed" }), + ); + expect(foreign.detail).toContain("OPS"); + yield* live.setState({ ...target, key: "ENG-1", state: "closed", closeReason: "canceled" }); + yield* live.setState({ ...target, key: "ENG-1", state: "closed" }); + yield* live.setState({ ...target, key: "ENG-1", state: "open" }); + expect(updates.map((update) => update.input)).toEqual([ + { stateId: "st_canceled" }, + { stateId: "st_done" }, + { stateId: "st_todo" }, + ]); + }), + ); + + it("offers plain templates as drafts and form or rich ones as links into Linear", () => { + const labels = new Map([["lbl_bug", "Bug"]]); + const plain = LinearIssueTracker.toTemplate( + { + id: "tpl_1", + name: "Bug report", + description: "For bugs", + content: "## Steps", + type: "issue", + hasFormFields: false, + templateData: { title: "Bug: ", labelIds: ["lbl_bug", "lbl_unknown"], assigneeId: null }, + }, + "ENG", + labels, + ); + expect(plain).toEqual({ + template: { + key: "tpl_1", + name: "Bug report", + about: "For bugs", + title: "Bug: ", + body: "## Steps", + labels: ["Bug"], + assignees: [], + }, + }); + const form = LinearIssueTracker.toTemplate( + { + id: "tpl_2", + name: "Intake", + description: null, + content: null, + type: "issue", + hasFormFields: true, + templateData: {}, + }, + "ENG", + labels, + ); + expect(form).toEqual({ + link: { name: "Intake", about: "", url: "https://linear.app/team/ENG/new?template=tpl_2" }, + }); + }); +}); diff --git a/packages/issue-tracker-linear/src/server/LinearIssueTracker.ts b/packages/issue-tracker-linear/src/server/LinearIssueTracker.ts new file mode 100644 index 000000000000..1d0066fd612d --- /dev/null +++ b/packages/issue-tracker-linear/src/server/LinearIssueTracker.ts @@ -0,0 +1,573 @@ +/** + * Linear as an issue tracker. A scope is a team key (`ENG`), an issue key is its identifier + * (`ENG-123`), and Linear's workflow states travel by name with the category read off their + * type: `completed` and `canceled` are closed, every other type is open. Closing therefore picks + * the team's first state of the matching type, which is what Linear's own "Done" and "Canceled" + * buttons do. + * + * Templates: a plain template becomes a draft here; one with form fields or rich (non-markdown) + * content opens the exact template in Linear instead, through the template list's contact links. + * + * @module issue-tracker-linear/server/LinearIssueTracker + */ +import * as Effect from "effect/Effect"; +import * as Schema from "effect/Schema"; +import { + type IssueActor, + type IssueCapabilities, + type IssueComment, + type IssueEvent, + type IssueExternalTemplate, + type IssueInvolvement, + type IssueLinkedPullRequest, + type IssueReaction, + type IssueReactionContent, + type IssueState, + type IssueTemplate, + type IssueViewerPermissions, + type StandaloneIssueTrackerDescriptor, +} from "@t3tools/contracts"; +import { + IssueTrackerError, + type StandaloneIssueTrackerApi, + type TrackerIssueSummary, +} from "@t3tools/issue-tracker-core/server/IssueTracker"; + +import * as LinearApi from "./LinearApi.ts"; + +const DESCRIPTOR: StandaloneIssueTrackerDescriptor = { + tracker: LinearApi.KIND, + displayName: "Linear", + host: "linear.app", + scopeNoun: "team", + credential: { + label: "Personal API key", + helpUrl: "https://linear.app/settings/account/security", + }, +}; + +/** + * Only the two categories here: Linear's actual columns differ per team and are offered to the + * detail page through `getIssue`'s state, while the service's `setState` guard needs a fixed list. + * The driver maps `open` to the team's default state and `closed` to its first completed state, + * with `canceled` as the close reason for its first canceled state. + */ +const CAPABILITIES: IssueCapabilities = { + create: true, + edit: true, + comment: true, + labels: true, + assignees: true, + reactions: true, + templates: true, + linkedPullRequests: true, + events: true, + search: true, + states: [ + { category: "open", name: "open" }, + { category: "closed", name: "closed" }, + ], + closeReasons: ["completed", "canceled"], +}; + +/** Everything granted: Linear's API reports no per-issue permissions and refuses with a message. */ +const VIEWER_PERMISSIONS: IssueViewerPermissions = { + setState: true, + comment: true, + edit: true, + labels: true, + assignees: true, +}; + +const COMMENTS_PAGE = 50; +const CLOSED_STATE_TYPES = ["completed", "canceled"]; + +/** Linear reacts with the emoji itself; GitHub's names are the contract's vocabulary. */ +const EMOJI_BY_CONTENT: Record = { + "thumbs-up": "๐Ÿ‘", + "thumbs-down": "๐Ÿ‘Ž", + laugh: "๐Ÿ˜„", + hooray: "๐ŸŽ‰", + confused: "๐Ÿ˜•", + heart: "โค๏ธ", + rocket: "๐Ÿš€", + eyes: "๐Ÿ‘€", +}; +const CONTENT_BY_EMOJI = new Map( + Object.entries(EMOJI_BY_CONTENT).map(([content, emoji]) => [ + emoji, + content as IssueReactionContent, + ]), +); + +/** `ENG-123`, or null for anything that is not a Linear identifier. */ +function parseIdentifier(key: string): string | null { + return /^[A-Za-z][A-Za-z0-9]*-[1-9]\d*$/.test(key.trim()) ? key.trim().toUpperCase() : null; +} + +function toState(state: LinearApi.LinearWorkflowState): IssueState { + return CLOSED_STATE_TYPES.includes(state.type) + ? { category: "closed", name: state.name, closeReason: state.type } + : { category: "open", name: state.name }; +} + +/** Linear identifies people by id, so that is the login; the display name is what people see. */ +function toActor(user: LinearApi.LinearUser): IssueActor { + return { + login: user.id, + name: user.displayName ?? user.name, + avatarUrl: user.avatarUrl ?? null, + }; +} + +/** How a user shows in a picker and an event: display name first, falling back to the id. */ +function userName(user: LinearApi.LinearUser): string { + return user.displayName ?? user.name ?? user.email ?? user.id; +} + +/** Linear's connections report no totals, so a listing shows no comment count. */ +function toSummary(issue: LinearApi.LinearIssue, commentCount = 0): TrackerIssueSummary { + return { + key: issue.identifier, + displayKey: issue.identifier, + title: issue.title, + url: issue.url, + author: issue.creator === null ? null : toActor(issue.creator), + state: toState(issue.state), + createdAt: issue.createdAt, + updatedAt: issue.updatedAt, + closedAt: issue.completedAt ?? issue.canceledAt ?? null, + assignees: issue.assignee === null ? [] : [toActor(issue.assignee)], + labels: issue.labels.nodes.map((label) => ({ name: label.name, color: label.color })), + commentCount, + }; +} + +function toReactions( + reactions: ReadonlyArray, + viewerId: string | null, +): IssueReaction[] { + const grouped = new Map(); + for (const reaction of reactions) { + const content = CONTENT_BY_EMOJI.get(reaction.emoji); + if (content === undefined) continue; + const mine = reaction.user !== null && reaction.user.id === viewerId; + const existing = grouped.get(content); + const actor = reaction.user === null || mine ? [] : [userName(reaction.user)]; + grouped.set( + content, + existing === undefined + ? { content, count: 1, actors: actor, viewerHasReacted: mine } + : { + ...existing, + count: existing.count + 1, + actors: [...existing.actors, ...actor], + viewerHasReacted: existing.viewerHasReacted || mine, + }, + ); + } + return [...grouped.values()]; +} + +function toComment(comment: LinearApi.LinearComment, viewerId: string | null): IssueComment { + return { + id: comment.id, + author: comment.user === null ? null : toActor(comment.user), + body: comment.body, + createdAt: comment.createdAt, + url: comment.url, + reactions: toReactions(comment.reactions, viewerId), + }; +} + +function toEvents(history: ReadonlyArray): IssueEvent[] { + const events: IssueEvent[] = []; + for (const entry of history) { + const actor = entry.actor === null ? null : toActor(entry.actor); + const add = (kind: IssueEvent["kind"], detail: string | null, suffix: string) => + events.push({ id: `${entry.id}:${suffix}`, kind, actor, createdAt: entry.createdAt, detail }); + if (entry.toState !== null && entry.toState.id !== entry.fromState?.id) { + const wasClosed = + entry.fromState !== null && CLOSED_STATE_TYPES.includes(entry.fromState.type); + const isClosed = CLOSED_STATE_TYPES.includes(entry.toState.type); + add( + isClosed && !wasClosed ? "closed" : wasClosed && !isClosed ? "reopened" : "state-changed", + entry.toState.name, + "state", + ); + } + for (const label of entry.addedLabels ?? []) add("labeled", label.name, `label+${label.id}`); + for (const label of entry.removedLabels ?? []) + add("unlabeled", label.name, `label-${label.id}`); + if (entry.fromAssignee !== null && entry.fromAssignee.id !== entry.toAssignee?.id) + add("unassigned", userName(entry.fromAssignee), "unassigned"); + if (entry.toAssignee !== null && entry.toAssignee.id !== entry.fromAssignee?.id) + add("assigned", userName(entry.toAssignee), "assigned"); + if (entry.toTitle !== null && entry.toTitle !== entry.fromTitle) + add("renamed", entry.toTitle, "title"); + } + return events; +} + +const PULL_REQUEST_URL = + /^https:\/\/(?:github\.com\/([^/]+\/[^/]+)\/pull|gitlab\.com\/(.+?)\/-\/merge_requests)\/(\d+)\/?(?:[?#]|$)/u; + +const isJsonObject = Schema.is(Schema.Record(Schema.String, Schema.Json)); + +/** Linear's GitHub and GitLab integrations record change requests as attachments. */ +function toLinkedPullRequests( + attachments: ReadonlyArray, +): IssueLinkedPullRequest[] { + const seen = new Set(); + return attachments.flatMap((attachment) => { + const match = PULL_REQUEST_URL.exec(attachment.url); + if (match === null || seen.has(attachment.url)) return []; + seen.add(attachment.url); + const fields = isJsonObject(attachment.metadata) ? attachment.metadata : {}; + const status = fields["status"]; + return [ + { + repository: match[1] ?? match[2]!, + number: Number(match[3]), + title: attachment.title.trim() || attachment.url, + url: attachment.url, + state: status === "merged" ? "merged" : status === "closed" ? "closed" : "open", + isDraft: status === "draft" || fields["draft"] === true, + closesIssue: false, + } as const, + ]; + }); +} + +/** + * A template the composer can hold: markdown content, no form fields. Anything else is offered + * as a link into Linear, where the exact template renders. + */ +export function toTemplate( + template: LinearApi.LinearTemplate, + teamKey: string, + labelNames: ReadonlyMap, +): { readonly template: IssueTemplate } | { readonly link: IssueExternalTemplate } { + const data = template.templateData; + const body = template.content ?? (typeof data.description === "string" ? data.description : null); + if (template.hasFormFields || (body === null && data.descriptionData != null)) { + const url = new URL(`https://linear.app/team/${encodeURIComponent(teamKey)}/new`); + url.searchParams.set("template", template.id); + return { link: { name: template.name, about: template.description ?? "", url: url.href } }; + } + return { + template: { + key: template.id, + name: template.name, + about: template.description ?? "", + title: data.title ?? "", + body: body ?? "", + labels: (data.labelIds ?? []).flatMap((id) => { + const name = labelNames.get(id); + return name === undefined ? [] : [name]; + }), + assignees: data.assigneeId ? [data.assigneeId] : [], + }, + }; +} + +function involvementFilter(input: { + readonly involvement: IssueInvolvement; + readonly viewer: string; +}): LinearApi.IssueFilter { + switch (input.involvement) { + case "assigned": + return { assignee: { id: { eq: input.viewer } } }; + case "authored": + return { creator: { id: { eq: input.viewer } } }; + case "mentioned": + return { subscribers: { some: { id: { eq: input.viewer } } } }; + case "all": + return {}; + } +} + +const notFound = (operation: string) => + new IssueTrackerError({ + tracker: LinearApi.KIND, + operation, + reason: "not-found", + detail: "Linear has no issue by that identifier, or this account cannot see it.", + }); + +const failed = (operation: string, detail: string) => + new IssueTrackerError({ tracker: LinearApi.KIND, operation, reason: "failed", detail }); + +export const make: Effect.Effect = + Effect.gen(function* () { + const linear = yield* LinearApi.LinearApi; + + const requireIdentifier = (operation: string, key: string) => { + const identifier = parseIdentifier(key); + return identifier === null ? Effect.fail(notFound(operation)) : Effect.succeed(identifier); + }; + + /** + * The issue a write names, refused unless it sits in the bound team: an identifier from + * another team, or one that moved away, still resolves in Linear. + */ + const requireTeamIssue = Effect.fn("LinearIssueTracker.requireTeamIssue")(function* ( + operation: string, + input: { readonly scope: string; readonly key: string }, + ) { + const identifier = yield* requireIdentifier(operation, input.key); + const issue = yield* linear.getIssue(identifier, 0); + if (issue === null) return yield* notFound(operation); + const team = input.scope.trim().toUpperCase(); + if (issue.team.key !== team) { + return yield* failed( + operation, + `${issue.identifier} belongs to Linear team ${issue.team.key}, not ${team}.`, + ); + } + return issue; + }); + + const requireTeam = (operation: string, scope: string) => + linear.getTeam(scope.trim().toUpperCase()).pipe( + Effect.filterOrFail( + (team): team is LinearApi.LinearTeamScope => team !== null, + () => failed(operation, `No Linear team has the key "${scope}".`), + ), + ); + + /** Names to label ids, within the team's and the workspace's labels. */ + const labelIds = ( + operation: string, + scope: LinearApi.LinearTeamScope, + names: ReadonlyArray, + ) => + Effect.forEach(names, (name) => { + const match = [...scope.team.labels.nodes, ...scope.workspaceLabels].find( + (label) => label.name.toLowerCase() === name.trim().toLowerCase(), + ); + return match === undefined + ? Effect.fail(failed(operation, `Linear has no label named "${name}" for this team.`)) + : Effect.succeed(match.id); + }); + + /** One assignee at most: Linear issues have a single assignee. */ + const assigneeId = ( + operation: string, + scope: LinearApi.LinearTeamScope, + assignees: ReadonlyArray, + ): Effect.Effect => { + const [first, ...rest] = assignees; + if (first === undefined) return Effect.succeed(null); + if (rest.length > 0) + return Effect.fail(failed(operation, "A Linear issue has one assignee at most.")); + const member = scope.team.members.nodes.find( + (user) => + user.id === first || + user.email?.toLowerCase() === first.toLowerCase() || + user.displayName?.toLowerCase() === first.toLowerCase(), + ); + return member === undefined + ? Effect.fail(failed(operation, `"${first}" is not a member of this Linear team.`)) + : Effect.succeed(member.id); + }; + + const viewerId: Effect.Effect = linear.viewer().pipe( + Effect.map((data) => data.viewer.id), + Effect.orElseSucceed(() => null), + ); + + const api: StandaloneIssueTrackerApi = { + kind: LinearApi.KIND, + capabilities: CAPABILITIES, + standalone: DESCRIPTOR, + + probeCredential: (token) => + linear.viewer(token).pipe( + Effect.map((data) => ({ + account: userName(data.viewer), + scopes: data.teams.map((team) => ({ key: team.key, name: team.name })), + })), + ), + + // The id, not the display name: it is what the involvement filters compare against. + getViewer: () => linear.viewer().pipe(Effect.map((data) => data.viewer.id)), + + listIssues: (input) => { + // `ENG-12`, `#12` or `12` asks for one issue of this team by number. + const reference = + input.query === undefined + ? null + : /^(?:[A-Za-z][A-Za-z0-9]*-|#)?(\d+)$/.exec(input.query.trim()); + const filter: LinearApi.IssueFilter = { + team: { key: { eq: input.scope.trim().toUpperCase() } }, + ...involvementFilter(input), + ...(input.state === "all" + ? {} + : { + state: { + type: + input.state === "closed" + ? { in: CLOSED_STATE_TYPES } + : { nin: CLOSED_STATE_TYPES }, + }, + }), + ...(input.query === undefined + ? {} + : { + or: [ + { title: { containsIgnoreCase: input.query } }, + { description: { containsIgnoreCase: input.query } }, + ...(reference === null ? [] : [{ number: { eq: Number(reference[1]) } }]), + ], + }), + }; + return linear.listIssues({ filter, first: input.limit, after: input.cursor }).pipe( + Effect.map((page) => ({ + items: page.nodes.map(toSummary), + nextCursor: page.nextCursor, + })), + ); + }, + + getIssue: Effect.fn("LinearIssueTracker.getIssue")(function* (input) { + const identifier = yield* requireIdentifier("getIssue", input.key); + const [issue, viewer] = yield* Effect.all([ + linear.getIssue(identifier, COMMENTS_PAGE), + viewerId, + ]); + if (issue === null) return yield* notFound("getIssue"); + return { + ...toSummary(issue, issue.comments.nodes.length), + body: issue.description ?? "", + viewer, + viewerPermissions: VIEWER_PERMISSIONS, + reactions: toReactions(issue.reactions, viewer), + comments: issue.comments.nodes.map((comment) => toComment(comment, viewer)), + commentsCursor: issue.comments.pageInfo.hasNextPage + ? issue.comments.pageInfo.endCursor + : null, + events: toEvents(issue.history.nodes), + linkedPullRequests: toLinkedPullRequests(issue.attachments.nodes), + }; + }), + + getComments: Effect.fn("LinearIssueTracker.getComments")(function* (input) { + const identifier = yield* requireIdentifier("getComments", input.key); + const [page, viewer] = yield* Effect.all([ + linear.getComments({ identifier, first: COMMENTS_PAGE, after: input.cursor }), + viewerId, + ]); + return { + comments: page.nodes.map((comment) => toComment(comment, viewer)), + nextCursor: page.nextCursor, + }; + }), + + create: Effect.fn("LinearIssueTracker.create")(function* (input) { + const scope = yield* requireTeam("create", input.scope); + const labels = yield* labelIds("create", scope, input.labels); + const assignee = yield* assigneeId("create", scope, input.assignees); + const created = yield* linear.createIssue({ + teamId: scope.team.id, + title: input.title, + description: input.body, + labelIds: labels, + ...(assignee === null ? {} : { assigneeId: assignee }), + }); + return { key: created.identifier, displayKey: created.identifier, url: created.url }; + }), + + comment: Effect.fn("LinearIssueTracker.comment")(function* (input) { + const issue = yield* requireTeamIssue("comment", input); + yield* linear.createComment({ issueId: issue.id, body: input.body }); + }), + + update: Effect.fn("LinearIssueTracker.update")(function* (input) { + const { identifier } = yield* requireTeamIssue("update", input); + const scope = + input.labels !== undefined || input.assignees !== undefined + ? yield* requireTeam("update", input.scope) + : null; + yield* linear.updateIssue(identifier, { + ...(input.title === undefined ? {} : { title: input.title }), + ...(input.body === undefined ? {} : { description: input.body }), + ...(scope === null || input.labels === undefined + ? {} + : { labelIds: yield* labelIds("update", scope, input.labels) }), + ...(scope === null || input.assignees === undefined + ? {} + : { assigneeId: yield* assigneeId("update", scope, input.assignees) }), + }); + }), + + setState: Effect.fn("LinearIssueTracker.setState")(function* (input) { + const { identifier } = yield* requireTeamIssue("setState", input); + const scope = yield* requireTeam("setState", input.scope); + const states = scope.team.states.nodes.toSorted( + (a, b) => (a.position ?? 0) - (b.position ?? 0), + ); + const wanted = + input.state === "closed" + ? states.find((state) => state.type === (input.closeReason ?? "completed")) + : (states.find((state) => state.type === "unstarted") ?? + states.find((state) => state.type === "backlog") ?? + states.find((state) => state.type === "triage")); + if (wanted === undefined) + return yield* failed("setState", "This team has no workflow state for that change."); + yield* linear.updateIssue(identifier, { stateId: wanted.id }); + }), + + setReaction: Effect.fn("LinearIssueTracker.setReaction")(function* (input) { + const issue = yield* requireTeamIssue("setReaction", input); + const emoji = EMOJI_BY_CONTENT[input.content]; + const target = + input.subjectId === undefined ? { issueId: issue.id } : { commentId: input.subjectId }; + if (input.reacted) { + yield* linear.createReaction({ ...target, emoji }); + return; + } + const viewer = yield* viewerId; + const reactions = yield* linear.listReactions(target); + const own = reactions.find( + (reaction) => reaction.emoji === emoji && reaction.user?.id === viewer, + ); + if (own !== undefined) yield* linear.deleteReaction(own.id); + }), + + listTemplates: (input) => + requireTeam("listTemplates", input.scope).pipe( + Effect.map((scope) => { + const labelNames = new Map( + [...scope.team.labels.nodes, ...scope.workspaceLabels].map((label) => [ + label.id, + label.name, + ]), + ); + const templates: IssueTemplate[] = []; + const externalTemplates: IssueExternalTemplate[] = []; + for (const template of scope.team.templates.nodes) { + if (template.type !== "issue") continue; + const mapped = toTemplate(template, scope.team.key, labelNames); + if ("template" in mapped) templates.push(mapped.template); + else externalTemplates.push(mapped.link); + } + return { templates, externalTemplates, blankIssuesEnabled: true }; + }), + ), + + listCandidates: (input) => + requireTeam("listCandidates", input.scope).pipe( + Effect.map((scope) => ({ + labels: [...scope.team.labels.nodes, ...scope.workspaceLabels].map((label) => ({ + name: label.name, + color: label.color, + description: label.description ?? null, + })), + assignees: scope.team.members.nodes.map((user) => ({ ...toActor(user), id: user.id })), + truncated: scope.truncated, + })), + ), + }; + return api; + }); diff --git a/packages/issue-tracker-linear/src/server/issueTrackerDriver.ts b/packages/issue-tracker-linear/src/server/issueTrackerDriver.ts new file mode 100644 index 000000000000..6cf00474e6ae --- /dev/null +++ b/packages/issue-tracker-linear/src/server/issueTrackerDriver.ts @@ -0,0 +1,18 @@ +/** + * The Linear issue tracker driver. Yields the Linear API, which in turn needs the platform + * HttpClient and the server's `IssueTrackerHost` for the stored credential. + * + * @module issue-tracker-linear/server/issueTrackerDriver + */ +import * as Effect from "effect/Effect"; +import { defineIssueTrackerDriver } from "@t3tools/issue-tracker-core/server/driver"; + +import * as LinearApi from "./LinearApi.ts"; +import * as LinearIssueTracker from "./LinearIssueTracker.ts"; + +export const driver = defineIssueTrackerDriver({ + kind: LinearApi.KIND, + make: LinearIssueTracker.make.pipe( + Effect.provideServiceEffect(LinearApi.LinearApi, LinearApi.make), + ), +}); diff --git a/packages/issue-tracker-linear/tsconfig.json b/packages/issue-tracker-linear/tsconfig.json new file mode 100644 index 000000000000..374bac55202d --- /dev/null +++ b/packages/issue-tracker-linear/tsconfig.json @@ -0,0 +1,7 @@ +{ + "extends": "../../tsconfig.base.json", + "compilerOptions": { + "types": ["node"] + }, + "include": ["src"] +} diff --git a/patches/@effect__graphql-generator@4.0.5.patch b/patches/@effect__graphql-generator@4.0.5.patch new file mode 100644 index 000000000000..9b7bab43a4f4 --- /dev/null +++ b/patches/@effect__graphql-generator@4.0.5.patch @@ -0,0 +1,553 @@ +diff --git a/dist/Generator.d.ts b/dist/Generator.d.ts +index 1347b47..91ee6e8 100644 +--- a/dist/Generator.d.ts ++++ b/dist/Generator.d.ts +@@ -99,7 +99,9 @@ export { ConfigError } from "./internal/Generate.ts"; + * a last member built with `GraphQL.otherTypename`. + * - `@skip` / `@include` with a variable condition make the fields they cover + * optional keys; literal conditions are folded. +- * - Recursive input objects produce error diagnostics. ++ * - Input objects on a cycle, such as filters with `and` / `or`, are ++ * `Schema.Codec` consts annotated with written-out Type and Encoded ++ * interfaces, and reference the cycle through `Schema.suspend`. + * + * @stability experimental + * @category generation +diff --git a/dist/Generator.js b/dist/Generator.js +index a49f6b8..25846b0 100644 +--- a/dist/Generator.js ++++ b/dist/Generator.js +@@ -36,7 +36,9 @@ export { ConfigError } from "./internal/Generate.js"; + * a last member built with `GraphQL.otherTypename`. + * - `@skip` / `@include` with a variable condition make the fields they cover + * optional keys; literal conditions are folded. +- * - Recursive input objects produce error diagnostics. ++ * - Input objects on a cycle, such as filters with `and` / `or`, are ++ * `Schema.Codec` consts annotated with written-out Type and Encoded ++ * interfaces, and reference the cycle through `Schema.suspend`. + * + * @stability experimental + * @category generation +diff --git a/dist/internal/Emitter.js b/dist/internal/Emitter.js +index 6a89aaf..f73df71 100644 +--- a/dist/internal/Emitter.js ++++ b/dist/internal/Emitter.js +@@ -1,8 +1,8 @@ + /** + * Emits per-document and shared modules from validated documents. Paths and + * import specifiers are supplied by the caller; output needs no formatter. +- * Recursive input objects and generated class names that can't be made +- * unique produce diagnostics instead of output. ++ * Generated class names that can't be made unique produce diagnostics instead ++ * of output. + * + * @internal + */ +@@ -235,7 +235,7 @@ class Emitter { + // --------------------------------------------------------------------------- + // Checks + // --------------------------------------------------------------------------- +- /** Names generated code can't use, recursive input objects and import cycles, sorted by file and position. */ ++ /** Names generated code can't use and import cycles, sorted by file and position. */ + check() { + const errors = []; + this.options.files.forEach((file, fileIndex) => { +@@ -259,11 +259,6 @@ class Emitter { + report(name.loc.start, `The name "${name.value}" is taken by the group this file exports.`); + } + } +- if (definition._tag === "OperationDefinition") { +- for (const variable of definition.variableDefinitions) { +- this.checkVariable(variable, report); +- } +- } + } + }); + errors.push(...this.importCycles()); +@@ -355,28 +350,6 @@ class Emitter { + }; + }); + } +- checkVariable(variable, report) { +- const visiting = new Set(); +- const done = new Set(); +- const visit = name => { +- const type = this.options.schema.types.get(name); +- if (type === undefined || type._tag !== "InputObjectType") return undefined; +- if (visiting.has(name)) { +- return `Variable "$${variable.variable.name.value}" uses the recursive input object "${name}"; recursive input objects are not supported yet.`; +- } +- if (done.has(name)) return undefined; +- visiting.add(name); +- for (const field of type.fields) { +- const problem = visit(SchemaModel.namedTypeOf(field.type)); +- if (problem !== undefined) return problem; +- } +- visiting.delete(name); +- done.add(name); +- return undefined; +- }; +- const problem = visit(SchemaModel.namedTypeOf(SchemaModel.fromAstType(variable.type))); +- if (problem !== undefined) report(variable.loc.start, problem); +- } + // --------------------------------------------------------------------------- + // Result selections + // --------------------------------------------------------------------------- +@@ -1070,15 +1043,58 @@ class Emitter { + /** The shared module, and the custom scalars it holds without a mapping. */ + emitShared() { + // Close over input objects: each one reaches the types of all its fields. ++ // Inputs are declared after the inputs they use, and the members of a ++ // cycle together (Tarjan's strongly connected components). + const inputs = []; + const all = new Set(); ++ /** The members of the cycle each recursive input object is on. */ ++ const cycles = new Map(); ++ /** Whether an input object's Encoded type differs from its Type. */ ++ const transforms = new Map(); ++ const transformsLeaf = name => { ++ const type = this.type(name); ++ if (type._tag === "InputObjectType") return transforms.get(name) ?? false; ++ // A mapped codec may transform; the built-in `DateTime` default does. ++ return type._tag === "ScalarType" && (this.options.scalars.has(name) || name === "DateTime"); ++ }; ++ const index = new Map(); ++ const low = new Map(); ++ const stack = []; ++ const onStack = new Set(); + const visit = name => { + if (all.has(name)) return; + all.add(name); + const type = this.type(name); + if (type._tag !== "InputObjectType") return; +- for (const field of type.fields) visit(SchemaModel.namedTypeOf(field.type)); +- inputs.push(type); ++ index.set(name, index.size); ++ low.set(name, index.get(name)); ++ stack.push(type); ++ onStack.add(name); ++ for (const field of type.fields) { ++ const child = SchemaModel.namedTypeOf(field.type); ++ if (!all.has(child)) { ++ visit(child); ++ if (index.has(child)) low.set(name, Math.min(low.get(name), low.get(child))); ++ } else if (onStack.has(child)) { ++ low.set(name, Math.min(low.get(name), index.get(child))); ++ } ++ } ++ if (low.get(name) !== index.get(name)) return; ++ const component = []; ++ let member; ++ do { ++ member = stack.pop(); ++ onStack.delete(member.name); ++ component.unshift(member); ++ } while (member !== type); ++ const members = new Set(component.map(input => input.name)); ++ const fieldTypes = component.flatMap(input => input.fields.map(field => SchemaModel.namedTypeOf(field.type))); ++ if (members.size > 1 || fieldTypes.includes(name)) { ++ for (const input of members) cycles.set(input, members); ++ } ++ const transformed = fieldTypes.some(leaf => !members.has(leaf) && transformsLeaf(leaf)); ++ for (const input of members) transforms.set(input, transformed); ++ inputs.push(...component); + }; + for (const name of Array.from(this.reached).sort()) visit(name); + all.delete("String"); +@@ -1148,10 +1164,31 @@ class Emitter { + const literals = type.values.map(value => JSON.stringify(value.name)).join(", "); + blocks.push(declare(type.name, docLines(descriptionLines(type.description), values), (b, e) => `${e}const ${b} = ${schema}.Literals([${literals}])\n${e}type ${b} = typeof ${b}.Type`)); + } ++ // A recursive input object's Encoded interface, when it differs from the Type. ++ const encodedNames = new Map(); ++ for (const type of inputs) { ++ if (cycles.has(type.name) && transforms.get(type.name)) { ++ encodedNames.set(type.name, allocate(`${type.name}Encoded`)); ++ } ++ } ++ // Enums and input objects declare a type under their name; scalars don't. ++ const typeLeaf = name => this.type(name)._tag === "ScalarType" ? `typeof ${alias(name)}.Type` : alias(name); ++ const encodedLeaf = name => cycles.has(name) ? encodedNames.get(name) ?? alias(name) : `typeof ${alias(name)}.Encoded`; + for (const type of inputs) { + const doc = descriptionLines(type.description); ++ const cycle = cycles.get(type.name); ++ if (cycle !== undefined) { ++ const recursion = { ++ encoded: encodedNames.get(type.name), ++ ref: name => cycle.has(name) ? `${schema}.suspend(() => ${alias(name)})` : alias(name), ++ typeLeaf, ++ encodedLeaf ++ }; ++ blocks.push(declare(type.name, doc, (b, e) => recursiveDeclaration(type, b, e, schema, recursion))); ++ continue; ++ } + if (type.oneOf) { +- blocks.push(declare(type.name, doc, (b, e) => oneOfDeclaration(type, b, e, schema, alias))); ++ blocks.push(declare(type.name, doc, (b, e) => oneOfDeclaration(type, b, e, schema, alias, typeLeaf))); + continue; + } + const members = type.fields.map(field => { +@@ -1191,24 +1228,52 @@ class Emitter { + * encode. A class can't extend `Opaque` over a union, so it is an Opaque const + * with the type written out beside it. + */ +-const oneOfDeclaration = (type, binding, exported, schema, ref) => { +- const required = field => field.type._tag === "NonNullTypeRef" ? field.type : { +- _tag: "NonNullTypeRef", +- ofType: field.type +- }; +- const structs = type.fields.map(selected => { +- const members = type.fields.map(field => { +- if (field !== selected) return ` ${propertyKey(field.name)}: ${schema}.optionalKey(${schema}.Never)`; +- const doc = docLines(descriptionLines(field.description), deprecatedTag(field.deprecationReason)); +- return `${jsdoc(doc, " ")} ${propertyKey(field.name)}: ${inputSchema(required(field), false, ref, schema)}`; +- }); +- return ` ${struct(members, " ", schema)}`; ++const oneOfDeclaration = (type, binding, exported, schema, ref, typeLeaf) => `${exported}const ${binding} = ${schema}.Opaque<${binding}>()(${schema}.Union([\n${oneOfStructs(type, schema, ref).join(",\n")}\n]))\n` + `${exported}type ${binding} =\n${oneOfAlternatives(type, typeLeaf).join("\n")}`; ++const required = field => field.type._tag === "NonNullTypeRef" ? field.type : { ++ _tag: "NonNullTypeRef", ++ ofType: field.type ++}; ++const oneOfStructs = (type, schema, ref) => type.fields.map(selected => { ++ const members = type.fields.map(field => { ++ if (field !== selected) return ` ${propertyKey(field.name)}: ${schema}.optionalKey(${schema}.Never)`; ++ const doc = docLines(descriptionLines(field.description), deprecatedTag(field.deprecationReason)); ++ return `${jsdoc(doc, " ")} ${propertyKey(field.name)}: ${inputSchema(required(field), false, ref, schema)}`; + }); +- const alternatives = type.fields.map(selected => ` | { ${type.fields.map(field => field === selected ? `readonly ${propertyKey(field.name)}: ${inputTypeText(required(field), ref)}` : `readonly ${propertyKey(field.name)}?: never`).join("; ")} }`); +- return `${exported}const ${binding} = ${schema}.Opaque<${binding}>()(${schema}.Union([\n${structs.join(",\n")}\n]))\n` + `${exported}type ${binding} =\n${alternatives.join("\n")}`; ++ return ` ${struct(members, " ", schema)}`; ++}); ++const oneOfAlternatives = (type, leaf) => type.fields.map(selected => ` | { ${type.fields.map(field => field === selected ? `readonly ${propertyKey(field.name)}: ${inputTypeText(required(field), leaf)}` : `readonly ${propertyKey(field.name)}?: never`).join("; ")} }`); ++/** ++ * An input object on a cycle of input objects. TypeScript can't infer the ++ * type of a const read in its own initializer, so the Type, and the Encoded ++ * type when it differs, are written out and annotate a `Schema.Codec`. Every ++ * reference to a type on the same cycle is a `Schema.suspend`, since the ++ * cycle's later members aren't initialized yet. ++ */ ++const recursiveDeclaration = (type, binding, exported, schema, recursion) => { ++ const { ++ encoded, ++ encodedLeaf, ++ ref, ++ typeLeaf ++ } = recursion; ++ const codec = `${schema}.Codec<${binding}${encoded === undefined ? "" : `, ${encoded}`}>`; ++ if (type.oneOf) { ++ return `${exported}const ${binding}: ${codec} = ${schema}.Union([\n${oneOfStructs(type, schema, ref).join(",\n")}\n])\n` + `${exported}type ${binding} =\n${oneOfAlternatives(type, typeLeaf).join("\n")}` + (encoded === undefined ? "" : `\nexport type ${encoded} =\n${oneOfAlternatives(type, encodedLeaf).join("\n")}`); ++ } ++ const members = type.fields.map(field => ` ${propertyKey(field.name)}: ${inputSchema(field.type, field.defaultValue !== undefined, ref, schema)}`); ++ const fields = (leaf, documented) => { ++ if (type.fields.length === 0) return "{}"; ++ const lines = type.fields.map(field => { ++ const doc = documented ? docLines(descriptionLines(field.description), [...deprecatedTag(field.deprecationReason), ...defaultTag(field.defaultValue)]) : []; ++ const optional = field.defaultValue !== undefined || field.type._tag !== "NonNullTypeRef"; ++ return `${jsdoc(doc, " ")} readonly ${propertyKey(field.name)}${optional ? "?" : ""}: ${inputTypeText(field.type, leaf)}${optional ? " | undefined" : ""}`; ++ }); ++ return `{\n${lines.join("\n")}\n}`; ++ }; ++ return `${exported}const ${binding}: ${codec} = ${struct(members, "", schema)}\n` + `${exported}interface ${binding} ${fields(typeLeaf, true)}` + (encoded === undefined ? "" : `\nexport interface ${encoded} ${fields(encodedLeaf, false)}`); + }; +-/** The decoded TypeScript type of an input, as written in the shared module. */ +-const inputTypeText = (type, ref) => typeRef(type, name => name === "String" || name === "Boolean" ? name.toLowerCase() : `typeof ${ref(name)}.Type`, element => `ReadonlyArray<${element}>`, inner => `${inner} | null`); ++/** The TypeScript type of an input, as written in the shared module, with `leaf` for each named type. */ ++const inputTypeText = (type, leaf) => typeRef(type, name => name === "String" || name === "Boolean" ? name.toLowerCase() : leaf(name), element => `ReadonlyArray<${element}>`, inner => `${inner} | null`); + /** A string or string array literal. */ + const literal = value => typeof value === "string" ? JSON.stringify(value) : `[${value.map(item => JSON.stringify(item)).join(", ")}]`; + /** A `DocumentTemplate` literal with one line per entry, keys in the order `Printer.template` builds them. */ +diff --git a/src/Generator.ts b/src/Generator.ts +index 6cbb6f3..21736a9 100644 +--- a/src/Generator.ts ++++ b/src/Generator.ts +@@ -104,7 +104,9 @@ export { ConfigError } from "./internal/Generate.ts" + * a last member built with `GraphQL.otherTypename`. + * - `@skip` / `@include` with a variable condition make the fields they cover + * optional keys; literal conditions are folded. +- * - Recursive input objects produce error diagnostics. ++ * - Input objects on a cycle, such as filters with `and` / `or`, are ++ * `Schema.Codec` consts annotated with written-out Type and Encoded ++ * interfaces, and reference the cycle through `Schema.suspend`. + * + * @stability experimental + * @category generation +diff --git a/src/internal/Emitter.ts b/src/internal/Emitter.ts +index b243d52..c606d26 100644 +--- a/src/internal/Emitter.ts ++++ b/src/internal/Emitter.ts +@@ -1,8 +1,8 @@ + /** + * Emits per-document and shared modules from validated documents. Paths and + * import specifiers are supplied by the caller; output needs no formatter. +- * Recursive input objects and generated class names that can't be made +- * unique produce diagnostics instead of output. ++ * Generated class names that can't be made unique produce diagnostics instead ++ * of output. + * + * @internal + */ +@@ -423,7 +423,7 @@ class Emitter { + // Checks + // --------------------------------------------------------------------------- + +- /** Names generated code can't use, recursive input objects and import cycles, sorted by file and position. */ ++ /** Names generated code can't use and import cycles, sorted by file and position. */ + check(): ReadonlyArray { + const errors: Array<{ readonly file: number; readonly offset: number; readonly message: string }> = [] + this.options.files.forEach((file, fileIndex) => { +@@ -443,11 +443,6 @@ class Emitter { + report(name.loc.start, `The name "${name.value}" is taken by the group this file exports.`) + } + } +- if (definition._tag === "OperationDefinition") { +- for (const variable of definition.variableDefinitions) { +- this.checkVariable(variable, report) +- } +- } + } + }) + errors.push(...this.importCycles()) +@@ -546,29 +541,6 @@ class Emitter { + }) + } + +- checkVariable(variable: Ast.VariableDefinition, report: (offset: number, message: string) => void): void { +- const visiting = new Set() +- const done = new Set() +- const visit = (name: string): string | undefined => { +- const type = this.options.schema.types.get(name) +- if (type === undefined || type._tag !== "InputObjectType") return undefined +- if (visiting.has(name)) { +- return `Variable "$${variable.variable.name.value}" uses the recursive input object "${name}"; recursive input objects are not supported yet.` +- } +- if (done.has(name)) return undefined +- visiting.add(name) +- for (const field of type.fields) { +- const problem = visit(SchemaModel.namedTypeOf(field.type)) +- if (problem !== undefined) return problem +- } +- visiting.delete(name) +- done.add(name) +- return undefined +- } +- const problem = visit(SchemaModel.namedTypeOf(SchemaModel.fromAstType(variable.type))) +- if (problem !== undefined) report(variable.loc.start, problem) +- } +- + // --------------------------------------------------------------------------- + // Result selections + // --------------------------------------------------------------------------- +@@ -1375,15 +1347,58 @@ class Emitter { + /** The shared module, and the custom scalars it holds without a mapping. */ + emitShared(): { readonly file: GeneratedFile; readonly unmapped: ReadonlyArray } { + // Close over input objects: each one reaches the types of all its fields. ++ // Inputs are declared after the inputs they use, and the members of a ++ // cycle together (Tarjan's strongly connected components). + const inputs: Array = [] + const all = new Set() ++ /** The members of the cycle each recursive input object is on. */ ++ const cycles = new Map>() ++ /** Whether an input object's Encoded type differs from its Type. */ ++ const transforms = new Map() ++ const transformsLeaf = (name: string): boolean => { ++ const type = this.type(name) ++ if (type._tag === "InputObjectType") return transforms.get(name) ?? false ++ // A mapped codec may transform; the built-in `DateTime` default does. ++ return type._tag === "ScalarType" && (this.options.scalars.has(name) || name === "DateTime") ++ } ++ const index = new Map() ++ const low = new Map() ++ const stack: Array = [] ++ const onStack = new Set() + const visit = (name: string): void => { + if (all.has(name)) return + all.add(name) + const type = this.type(name) + if (type._tag !== "InputObjectType") return +- for (const field of type.fields) visit(SchemaModel.namedTypeOf(field.type)) +- inputs.push(type) ++ index.set(name, index.size) ++ low.set(name, index.get(name)!) ++ stack.push(type) ++ onStack.add(name) ++ for (const field of type.fields) { ++ const child = SchemaModel.namedTypeOf(field.type) ++ if (!all.has(child)) { ++ visit(child) ++ if (index.has(child)) low.set(name, Math.min(low.get(name)!, low.get(child)!)) ++ } else if (onStack.has(child)) { ++ low.set(name, Math.min(low.get(name)!, index.get(child)!)) ++ } ++ } ++ if (low.get(name) !== index.get(name)) return ++ const component: Array = [] ++ let member: SchemaModel.InputObjectType ++ do { ++ member = stack.pop()! ++ onStack.delete(member.name) ++ component.unshift(member) ++ } while (member !== type) ++ const members = new Set(component.map((input) => input.name)) ++ const fieldTypes = component.flatMap((input) => input.fields.map((field) => SchemaModel.namedTypeOf(field.type))) ++ if (members.size > 1 || fieldTypes.includes(name)) { ++ for (const input of members) cycles.set(input, members) ++ } ++ const transformed = fieldTypes.some((leaf) => !members.has(leaf) && transformsLeaf(leaf)) ++ for (const input of members) transforms.set(input, transformed) ++ inputs.push(...component) + } + for (const name of Array.from(this.reached).sort()) visit(name) + all.delete("String") +@@ -1471,10 +1486,33 @@ class Emitter { + (b, e) => `${e}const ${b} = ${schema}.Literals([${literals}])\n${e}type ${b} = typeof ${b}.Type` + )) + } ++ // A recursive input object's Encoded interface, when it differs from the Type. ++ const encodedNames = new Map() ++ for (const type of inputs) { ++ if (cycles.has(type.name) && transforms.get(type.name)) { ++ encodedNames.set(type.name, allocate(`${type.name}Encoded`)) ++ } ++ } ++ // Enums and input objects declare a type under their name; scalars don't. ++ const typeLeaf = (name: string): string => ++ this.type(name)._tag === "ScalarType" ? `typeof ${alias(name)}.Type` : alias(name) ++ const encodedLeaf = (name: string): string => ++ cycles.has(name) ? encodedNames.get(name) ?? alias(name) : `typeof ${alias(name)}.Encoded` + for (const type of inputs) { + const doc = descriptionLines(type.description) ++ const cycle = cycles.get(type.name) ++ if (cycle !== undefined) { ++ const recursion: Recursion = { ++ encoded: encodedNames.get(type.name), ++ ref: (name) => cycle.has(name) ? `${schema}.suspend(() => ${alias(name)})` : alias(name), ++ typeLeaf, ++ encodedLeaf ++ } ++ blocks.push(declare(type.name, doc, (b, e) => recursiveDeclaration(type, b, e, schema, recursion))) ++ continue ++ } + if (type.oneOf) { +- blocks.push(declare(type.name, doc, (b, e) => oneOfDeclaration(type, b, e, schema, alias))) ++ blocks.push(declare(type.name, doc, (b, e) => oneOfDeclaration(type, b, e, schema, alias, typeLeaf))) + continue + } + const members = type.fields.map((field) => { +@@ -1533,11 +1571,23 @@ const oneOfDeclaration = ( + binding: string, + exported: string, + schema: string, ++ ref: (name: string) => string, ++ typeLeaf: (name: string) => string ++): string => ++ `${exported}const ${binding} = ${schema}.Opaque<${binding}>()(${schema}.Union([\n${ ++ oneOfStructs(type, schema, ref).join(",\n") ++ }\n]))\n` + ++ `${exported}type ${binding} =\n${oneOfAlternatives(type, typeLeaf).join("\n")}` ++ ++const required = (field: SchemaModel.InputValue): SchemaModel.TypeRef => ++ field.type._tag === "NonNullTypeRef" ? field.type : { _tag: "NonNullTypeRef", ofType: field.type } ++ ++const oneOfStructs = ( ++ type: SchemaModel.InputObjectType, ++ schema: string, + ref: (name: string) => string +-): string => { +- const required = (field: SchemaModel.InputValue): SchemaModel.TypeRef => +- field.type._tag === "NonNullTypeRef" ? field.type : { _tag: "NonNullTypeRef", ofType: field.type } +- const structs = type.fields.map((selected) => { ++): Array => ++ type.fields.map((selected) => { + const members = type.fields.map((field) => { + if (field !== selected) return ` ${propertyKey(field.name)}: ${schema}.optionalKey(${schema}.Never)` + const doc = docLines(descriptionLines(field.description), deprecatedTag(field.deprecationReason)) +@@ -1545,26 +1595,80 @@ const oneOfDeclaration = ( + }) + return ` ${struct(members, " ", schema)}` + }) +- const alternatives = type.fields.map((selected) => ++ ++const oneOfAlternatives = (type: SchemaModel.InputObjectType, leaf: (name: string) => string): Array => ++ type.fields.map((selected) => + ` | { ${ + type.fields.map((field) => + field === selected +- ? `readonly ${propertyKey(field.name)}: ${inputTypeText(required(field), ref)}` ++ ? `readonly ${propertyKey(field.name)}: ${inputTypeText(required(field), leaf)}` + : `readonly ${propertyKey(field.name)}?: never` + ).join("; ") + } }` + ) +- return `${exported}const ${binding} = ${schema}.Opaque<${binding}>()(${schema}.Union([\n${ +- structs.join(",\n") +- }\n]))\n` + +- `${exported}type ${binding} =\n${alternatives.join("\n")}` ++ ++/** How a recursive input object refers to the types of its fields. */ ++interface Recursion { ++ /** The name of the Encoded type, when it differs from the Type. */ ++ readonly encoded: string | undefined ++ /** The Schema for a type, suspended when it is on the same cycle. */ ++ readonly ref: (name: string) => string ++ readonly typeLeaf: (name: string) => string ++ readonly encodedLeaf: (name: string) => string ++} ++ ++/** ++ * An input object on a cycle of input objects. TypeScript can't infer the ++ * type of a const read in its own initializer, so the Type, and the Encoded ++ * type when it differs, are written out and annotate a `Schema.Codec`. Every ++ * reference to a type on the same cycle is a `Schema.suspend`, since the ++ * cycle's later members aren't initialized yet. ++ */ ++const recursiveDeclaration = ( ++ type: SchemaModel.InputObjectType, ++ binding: string, ++ exported: string, ++ schema: string, ++ recursion: Recursion ++): string => { ++ const { encoded, encodedLeaf, ref, typeLeaf } = recursion ++ const codec = `${schema}.Codec<${binding}${encoded === undefined ? "" : `, ${encoded}`}>` ++ if (type.oneOf) { ++ return `${exported}const ${binding}: ${codec} = ${schema}.Union([\n${ ++ oneOfStructs(type, schema, ref).join(",\n") ++ }\n])\n` + ++ `${exported}type ${binding} =\n${oneOfAlternatives(type, typeLeaf).join("\n")}` + ++ (encoded === undefined ? "" : `\nexport type ${encoded} =\n${oneOfAlternatives(type, encodedLeaf).join("\n")}`) ++ } ++ const members = type.fields.map((field) => ++ ` ${propertyKey(field.name)}: ${inputSchema(field.type, field.defaultValue !== undefined, ref, schema)}` ++ ) ++ const fields = (leaf: (name: string) => string, documented: boolean): string => { ++ if (type.fields.length === 0) return "{}" ++ const lines = type.fields.map((field) => { ++ const doc = documented ++ ? docLines( ++ descriptionLines(field.description), ++ [...deprecatedTag(field.deprecationReason), ...defaultTag(field.defaultValue)] ++ ) ++ : [] ++ const optional = field.defaultValue !== undefined || field.type._tag !== "NonNullTypeRef" ++ return `${jsdoc(doc, " ")} readonly ${propertyKey(field.name)}${optional ? "?" : ""}: ${ ++ inputTypeText(field.type, leaf) ++ }${optional ? " | undefined" : ""}` ++ }) ++ return `{\n${lines.join("\n")}\n}` ++ } ++ return `${exported}const ${binding}: ${codec} = ${struct(members, "", schema)}\n` + ++ `${exported}interface ${binding} ${fields(typeLeaf, true)}` + ++ (encoded === undefined ? "" : `\nexport interface ${encoded} ${fields(encodedLeaf, false)}`) + } + +-/** The decoded TypeScript type of an input, as written in the shared module. */ +-const inputTypeText = (type: SchemaModel.TypeRef, ref: (name: string) => string): string => ++/** The TypeScript type of an input, as written in the shared module, with `leaf` for each named type. */ ++const inputTypeText = (type: SchemaModel.TypeRef, leaf: (name: string) => string): string => + typeRef( + type, +- (name) => name === "String" || name === "Boolean" ? name.toLowerCase() : `typeof ${ref(name)}.Type`, ++ (name) => name === "String" || name === "Boolean" ? name.toLowerCase() : leaf(name), + (element) => `ReadonlyArray<${element}>`, + (inner) => `${inner} | null` + ) diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 2aabe22e9c84..60c329104174 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -167,9 +167,6 @@ catalogs: '@distilled.cloud/cloudflare': specifier: 1.0.0-rc.13 version: 1.0.0-rc.13 - '@effect/graphql-generator': - specifier: 4.0.5 - version: 4.0.5 '@effect/openapi-generator': specifier: 4.0.5 version: 4.0.5 @@ -308,6 +305,7 @@ overrides: '@effect/platform-node': 4.0.5 '@effect/platform-node-shared': 4.0.5 '@effect/sql-pg': 4.0.5 + '@effect/graphql-generator': 4.0.5 '@effect/vitest': 4.0.5 '@effect/vitest>vitest': '-' '@expo/dom-webview': 58.0.2 @@ -344,6 +342,7 @@ pnpmfileChecksum: sha256-YzTn4CWqI4l/Czk2VAdpGztl9kv2T+Fnt/Gw1mJ7Lu0= patchedDependencies: '@clerk/expo-native-components@0.4.0': 7a808b92da8460750b85818552e13be3fb73d111691c7db76965970351e124e4 + '@effect/graphql-generator@4.0.5': 70fe80318292f76113ccebfff22289a387248367a8bf6a0c390f541c47f1f8d5 '@effect/vitest@4.0.5': 2731c9c3761c595f25ddc625a7d61ca376b389d5b3049ecb837c8940f21cfa02 '@expo/fingerprint@0.21.5': 8fba80d6bbce46c72de427fe8c7907462d262a0bfe50c6b2b7ee9c4e0c61e5e1 '@expo/metro-config@58.0.14': 90fa980e8b6480631fb2fbb04559834e3c612db40c550cd828f11be297d8d760 @@ -860,6 +859,9 @@ importers: '@t3tools/issue-tracker-core': specifier: workspace:* version: link:../../packages/issue-tracker-core + '@t3tools/issue-tracker-linear': + specifier: workspace:* + version: link:../../packages/issue-tracker-linear '@t3tools/provider-acp': specifier: workspace:* version: link:../../packages/provider-acp @@ -937,8 +939,8 @@ importers: version: 3.4.0 devDependencies: '@effect/graphql-generator': - specifier: 'catalog:' - version: 4.0.5(@effect/platform-node@4.0.5(bufferutil@4.1.0)(effect@4.0.5)(redis@6.2.1)(utf-8-validate@6.0.6))(effect@4.0.5) + specifier: 4.0.5 + version: 4.0.5(patch_hash=70fe80318292f76113ccebfff22289a387248367a8bf6a0c390f541c47f1f8d5)(@effect/platform-node@4.0.5(bufferutil@4.1.0)(effect@4.0.5)(redis@6.2.1)(utf-8-validate@6.0.6))(effect@4.0.5) '@effect/vitest': specifier: 4.0.5 version: 4.0.5(patch_hash=2731c9c3761c595f25ddc625a7d61ca376b389d5b3049ecb837c8940f21cfa02)(@astrojs/compiler-rs@0.5.1)(@tsc-rs/typescript@0.8.0)(@types/node@24.12.4)(@vitest/browser-playwright@5.0.5)(@vitest/ui@5.0.5)(@volar/typescript@2.4.28(@tsc-rs/typescript@0.8.0))(bufferutil@4.1.0)(effect@4.0.5)(esbuild@0.28.2)(jiti@2.7.0)(jsdom@30.1.0(@noble/hashes@1.8.0))(playwright@1.60.0)(terser@5.48.0)(unrun@0.2.39)(utf-8-validate@6.0.6)(yaml@2.9.0) @@ -1278,10 +1280,10 @@ importers: version: link:../../packages/shared alchemy: specifier: 2.0.0-beta.80 - version: 2.0.0-beta.80(patch_hash=bea1b6c0c0b23157fd5f439a1d7feff430f28ac1621ba135d8a13eeec60ccacd)(2676e7bf1eae706a0c10853e80d0a1b0) + version: 2.0.0-beta.80(patch_hash=bea1b6c0c0b23157fd5f439a1d7feff430f28ac1621ba135d8a13eeec60ccacd)(c74a1cfb3df8b67fc508b7f3e6f07baa) drizzle-orm: specifier: 1.0.0-rc.5-ab785fc - version: 1.0.0-rc.5-ab785fc(@cloudflare/workers-types@4.20260604.1)(@effect/sql-d1@4.0.0(effect@4.0.5))(@effect/sql-pg@4.0.5(effect@4.0.5))(@effect/sql-sqlite-bun@4.0.0-rc.112(effect@4.0.5))(@effect/sql-sqlite-do@4.0.5(effect@4.0.5))(@electric-sql/pglite@0.3.15)(@libsql/client@0.17.3(bufferutil@4.1.0)(utf-8-validate@6.0.6))(bun-types@1.3.14)(effect@4.0.5)(expo-sqlite@58.0.13(expo@58.0.14)(react-native@0.88.0(@babel/core@7.29.7(supports-color@8.1.1))(@react-native/metro-config@0.88.0(@babel/core@7.29.7(supports-color@8.1.1))(bufferutil@4.1.0)(supports-color@8.1.1)(utf-8-validate@6.0.6))(@types/react@19.3.0)(bufferutil@4.1.0)(react@19.3.0)(supports-color@8.1.1)(utf-8-validate@6.0.6))(react@19.3.0))(pg@8.23.0)(zod@4.4.3) + version: 1.0.0-rc.5-ab785fc(@cloudflare/workers-types@4.20260604.1)(@effect/sql-d1@4.0.0(effect@4.0.5))(@effect/sql-pg@4.0.5(effect@4.0.5))(@effect/sql-sqlite-bun@4.0.0-rc.112(effect@4.0.5))(@effect/sql-sqlite-do@4.0.5(effect@4.0.5))(@electric-sql/pglite@0.3.15)(@libsql/client@0.17.3(bufferutil@4.1.0)(utf-8-validate@6.0.6))(bun-types@1.3.14)(effect@4.0.5)(expo-sqlite@58.0.13(expo@58.0.14)(react-native@0.88.0(@babel/core@7.29.7(supports-color@8.1.1))(@react-native/metro-config@0.88.0(@babel/core@7.29.7(supports-color@8.1.1))(bufferutil@4.1.0)(supports-color@8.1.1)(utf-8-validate@6.0.6))(@types/react@19.3.0)(bufferutil@4.1.0)(react@19.3.0)(supports-color@8.1.1)(utf-8-validate@6.0.6))(react@19.3.0))(pg@8.23.0)(zod@4.6.5) effect: specifier: 4.0.5 version: 4.0.5 @@ -1318,7 +1320,7 @@ importers: version: 4.0.5(bufferutil@4.1.0)(effect@4.0.5)(redis@6.2.1)(utf-8-validate@6.0.6) '@oxlint/plugins': specifier: ^1.63.0 - version: 1.68.0 + version: 1.88.0 effect: specifier: 4.0.5 version: 4.0.5 @@ -1449,6 +1451,34 @@ importers: specifier: 24.12.4 version: 24.12.4 + packages/issue-tracker-linear: + dependencies: + '@t3tools/contracts': + specifier: workspace:* + version: link:../contracts + '@t3tools/issue-tracker-core': + specifier: workspace:* + version: link:../issue-tracker-core + '@t3tools/source-control-core': + specifier: workspace:* + version: link:../source-control-core + effect: + specifier: 4.0.5 + version: 4.0.5 + devDependencies: + '@effect/graphql-generator': + specifier: 4.0.5 + version: 4.0.5(patch_hash=70fe80318292f76113ccebfff22289a387248367a8bf6a0c390f541c47f1f8d5)(@effect/platform-node@4.0.5(bufferutil@4.1.0)(effect@4.0.5)(redis@6.2.1)(utf-8-validate@6.0.6))(effect@4.0.5) + '@effect/vitest': + specifier: 4.0.5 + version: 4.0.5(patch_hash=2731c9c3761c595f25ddc625a7d61ca376b389d5b3049ecb837c8940f21cfa02)(@astrojs/compiler-rs@0.5.1)(@tsc-rs/typescript@0.8.0)(@types/node@24.12.4)(@vitest/browser-playwright@5.0.5)(@vitest/ui@5.0.5)(@volar/typescript@2.4.28(@tsc-rs/typescript@0.8.0))(bufferutil@4.1.0)(effect@4.0.5)(esbuild@0.28.2)(jiti@2.7.0)(jsdom@30.1.0(@noble/hashes@1.8.0))(playwright@1.60.0)(terser@5.48.0)(unrun@0.2.39)(utf-8-validate@6.0.6)(yaml@2.9.0) + '@types/node': + specifier: 24.12.4 + version: 24.12.4 + vite-plus: + specifier: 1.3.0 + version: 1.3.0(@astrojs/compiler-rs@0.5.1)(@tsc-rs/typescript@0.8.0)(@types/node@24.12.4)(@vitest/browser-playwright@5.0.5)(@vitest/ui@5.0.5)(@volar/typescript@2.4.28(@tsc-rs/typescript@0.8.0))(bufferutil@4.1.0)(esbuild@0.28.2)(jiti@2.7.0)(jsdom@30.1.0(@noble/hashes@1.8.0))(playwright@1.60.0)(terser@5.48.0)(unrun@0.2.39)(utf-8-validate@6.0.6)(yaml@2.9.0) + packages/provider-acp: dependencies: '@t3tools/contracts': @@ -2008,8 +2038,8 @@ importers: version: 2.9.0 devDependencies: '@effect/graphql-generator': - specifier: 'catalog:' - version: 4.0.5(@effect/platform-node@4.0.5(bufferutil@4.1.0)(effect@4.0.5)(redis@6.2.1)(utf-8-validate@6.0.6))(effect@4.0.5) + specifier: 4.0.5 + version: 4.0.5(patch_hash=70fe80318292f76113ccebfff22289a387248367a8bf6a0c390f541c47f1f8d5)(@effect/platform-node@4.0.5(bufferutil@4.1.0)(effect@4.0.5)(redis@6.2.1)(utf-8-validate@6.0.6))(effect@4.0.5) '@effect/platform-node': specifier: 4.0.5 version: 4.0.5(bufferutil@4.1.0)(effect@4.0.5)(redis@6.2.1)(utf-8-validate@6.0.6) @@ -2189,10 +2219,6 @@ packages: peerDependencies: zod: ^3.25.76 || ^4.1.8 - '@ai-sdk/provider@3.0.15': - resolution: {integrity: sha512-XeZW1CcDF2GMbH4wejW6xBRI2QCOgnkVYUnxoeDadB1mf85riL2bMUeDoh+6gJ/r4mjNfzUPW8OjLjvwTP0u1Q==} - engines: {node: '>=18'} - '@ai-sdk/provider@3.0.18': resolution: {integrity: sha512-IpefF5ssZVOZCD4Wu7zxt6PwZoGT2HLVjxpJ10Bjx6EAmRfLYJPjyrfxb0RYDlwvXnDb9nkQ7Do/oJVDuRFzew==} engines: {node: '>=18'} @@ -2840,10 +2866,6 @@ packages: resolution: {integrity: sha512-EhlfNQtZ+NK22w5BM61ciuiq1m58ed33Wr1Xan//ZRTy6hgjnwyCffRYwzsGXdASJSUJ1guZILsErh1eQcl+zw==} engines: {node: '>=6.9.0'} - '@babel/types@7.29.7': - resolution: {integrity: sha512-4zBIxpPzowiZpusoFkyGVwakdRJUyuH5PxQ/PrqghfdFWWasvnCdPfQXHrenDai+gyLARulZjZowCOj6fjT4pA==} - engines: {node: '>=6.9.0'} - '@babel/types@7.29.8': resolution: {integrity: sha512-Vj1jF3cPfxg7OAfoI7QnVKLoILlm2JF9pnVHrX8qx7AHMiYWT+NDAA7jChlNgRS4WTLc/fD1lXLmPixluj+3Gg==} engines: {node: '>=6.9.0'} @@ -4566,12 +4588,6 @@ packages: resolution: {integrity: sha512-WrOw/bcXm0f9qHkumlT1QlArXSTWqaY9sunsDpOk+yCCorCKMxvWT/a3xko4EYHVdeZoh00yI2TydXn6eyICDA==} engines: {node: '>= 10'} - '@napi-rs/wasm-runtime@1.1.6': - resolution: {integrity: sha512-ZLv/JdUfkvOy9eCnnBaGfiO+XimbjebAeO+MRQqD/B+FR1tnRN0tpKSJHRbE8sFfS6aqsXZ67TQjfwfsxULVbg==} - peerDependencies: - '@emnapi/core': ^1.7.1 - '@emnapi/runtime': ^1.7.1 - '@napi-rs/wasm-runtime@1.2.4': resolution: {integrity: sha512-AJxoUD2/15ESHbvpcyjU274nsAPLuOtPHCk0vKJM5pj//Fg/B1FXNWjPnXTT9PymCYYiHo4zPj0ZomXBKhoy7g==} engines: {node: ^20.19.0 || ^22.13.0 || >=23.5.0} @@ -5536,10 +5552,6 @@ packages: cpu: [x64] os: [win32] - '@oxlint/plugins@1.68.0': - resolution: {integrity: sha512-titLmukUt/h8ho7Svlf0xSBjoy2ccZKrXjpXpZCj+v6V4CJccC2KyP45BLSCMx8YIpifMyiDyUptM4+5sruKbQ==} - engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} - '@oxlint/plugins@1.88.0': resolution: {integrity: sha512-G2xbfWTrbqYRhR/vfeKNMQf/sS3/ti0iKJAAkRxHuXWZH/hne/dyIb9QKk5LuR6cJLARxsL6FMoAYmfspd74MQ==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} @@ -6544,9 +6556,6 @@ packages: '@tweenjs/tween.js@23.1.3': resolution: {integrity: sha512-vJmvvwFxYuGnF2axRtPYocag6Clbb5YS7kLL+SO/TeVFzHqDIWrNKYtcsPMibjDx9O+bu+psAy9NKfWklassUA==} - '@tybys/wasm-util@0.10.3': - resolution: {integrity: sha512-F3fo1MYrRJYL3zER0OUOmkutjr1Vp23m7OsSgp7nq4SP6OqX6C/56XFIPAl5bt3zaBRjmW7SGz3u/6LwFpYcOg==} - '@tybys/wasm-util@0.10.4': resolution: {integrity: sha512-W3c4gRigFS0T/Ma4qIYF3GDAc5AQdHb1yL5znJT1Zv1YaD9Kitx656wBjvr19qbiosmZT8lWDM5BEMynUqX65A==} @@ -9260,9 +9269,6 @@ packages: jose@6.2.2: resolution: {integrity: sha512-d7kPDd34KO/YnzaDOlikGpOurfF0ByC2sEV4cANCtdqLlTfBlw2p14O/5d/zv40gJPbIQxfES3nSx1/oYNyuZQ==} - jose@6.2.3: - resolution: {integrity: sha512-YYVDInQKFJfR/xa3ojUTl8c2KoTwiL1R5Wg9YCydwH0x0B9grbzlg5HC7mMjCtUJjbQ/YnGEZIhI5tCgfTb4Hw==} - js-base64@3.7.8: resolution: {integrity: sha512-hNngCeKxIUQiEUN3GPJOkz4wF/YvdUdbNL9hsBcMQTkKzboD7T/q3OYOuuPZLUE6dBxSGpwhk5mwuDud7JVAow==} @@ -9543,9 +9549,6 @@ packages: magic-string@0.30.21: resolution: {integrity: sha512-vd2F4YUyEXKGcLHoq+TEyCjxueSeHnFxyyjNp80yg0XV4vUhnDer/lvvlqM/arB5bXQN5K2/3oinyCRyx8T2CQ==} - magic-string@1.4.1: - resolution: {integrity: sha512-8lyCu36ErXR0J9uaGKlKQoiLZKmtI63YGLE8G2o9jyRPdr4X47LusSOwgOJOzcVtp81fTAAjxR7BwKz682Jhow==} - magic-string@1.4.3: resolution: {integrity: sha512-z12OxmaPGE0F4xlpGdjuAUckipLpQlTAuAmyGhNoD7ODpYUzvDfvtxUbjM/jwznyP178oju/KDdyi220wNJ0RQ==} @@ -9959,11 +9962,6 @@ packages: multitars@1.0.2: resolution: {integrity: sha512-6GwVw5eLi9sThdtlS4PKwC7yRLaf45pYhIEzKBHdKxi+YOXGKFX8acIniH+Uh/+k9mS2lQOupTccjoe5r0/1IQ==} - nanoid@3.3.19: - resolution: {integrity: sha512-Y2tUNy4ouw6tq5oDSKeQYGOyhkUBhNOcGV/02KC+6kd9eDGqdZd++mjMiIDilrBYvjEnCYvVtsuHCuP+okSfug==} - engines: {node: ^10 || ^12 || ^13.7 || ^14 || >=15.0.1} - hasBin: true - nanoid@3.3.20: resolution: {integrity: sha512-uKdg2G3GNCKQn9byYOpxbGqrT2fGO5KRt5J/8b3pok8rT6qxGWF6hxMyJiEYtAf+FVyYuD9hRaDqX5uPFYJ4ZQ==} engines: {node: ^10 || ^12 || ^13.7 || ^14 || >=15.0.1} @@ -10248,9 +10246,6 @@ packages: resolution: {integrity: sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==} engines: {node: '>=6'} - package-manager-detector@1.6.0: - resolution: {integrity: sha512-61A5ThoTiDG/C8s8UMZwSorAGwMJ0ERVGj2OjoW5pAalsNOg15+iQiPzrLJ4jhZ1HJzmC2PIHT2oEiH3R5fzNA==} - package-manager-detector@1.8.0: resolution: {integrity: sha512-yQA4H19AmPEoMUeavPMDIe1higySl/gH/yaQrkT/s07Qp+7pp2hYz30N3z2l5BkjVkF9Ow6o0wjJamm2y7Sn0A==} @@ -11128,10 +11123,6 @@ packages: resolution: {integrity: sha512-LJhUYUvItdQ0LkJTmPeaEObWXAqFyfmP85x0tch/ez9cahmhlBBLbIqDFnvBnUJGagb0JbIQrkBs1wJ+yRYpEw==} engines: {node: '>= 10.0.0', npm: '>= 3.0.0'} - source-map-js@1.2.1: - resolution: {integrity: sha512-UXWMKhLOwVKb728IUtQPXxfYU+usdybtUrK/8uGE8CQMvrhOpwvzDBwj0QhSL7MQc7vIsISBG8VQ8+IDQxpfQA==} - engines: {node: '>=0.10.0'} - source-map-js@1.2.2: resolution: {integrity: sha512-KGj/8Y43x35aZVDtt+J4mK1hoLGHULMYfSkODJNQjNDC3oW1PqPoxMwo0pLUsWM/UEGzON/NxeHywEfNXNP3Vw==} engines: {node: '>=0.10.0'} @@ -11357,10 +11348,6 @@ packages: resolution: {integrity: sha512-nTv2raKFMzGG6JJp0lpNDsRPdfFE6UHlu2rVEjXo8vkx1ZS3LW2CVXqIaLu8xZlu+6tbFs9V58Qc/Jmk/Ii7wA==} engines: {node: ^16.14.0 || >= 17.3.0} - tinyexec@1.2.4: - resolution: {integrity: sha512-SHf/r48b7vOrjve9PxJo3MN5v5yuyjHvdUcrQffT3WXMUfnGmHDVbC4k3sHJaJTgZCwpUplIaAo5ANtMyp3YHg==} - engines: {node: '>=18'} - tinyexec@1.3.1: resolution: {integrity: sha512-GCvB3aoys96IuDFBMcTB46JOR6mdMtAToqwiW8JlWhsoh1mhHi/xn9ss/Dg7N555GiJyEt2qzoG/NHCwM6h1EA==} engines: {node: '>=18'} @@ -12118,9 +12105,6 @@ packages: zod@3.25.76: resolution: {integrity: sha512-gzUt/qt81nXsFGKIFcC3YnfEAx5NkunCfnDlvuBSSFS02bcXu4Lmea0AFIUwbLWxWPx3d9p8S5QoaujKcNQxcQ==} - zod@4.4.3: - resolution: {integrity: sha512-ytENFjIJFl2UwYglde2jchW2Hwm4GJFLDiSXWdTrJQBIN9Fcyp7n4DhxJEiWNAJMV1/BqWfW/kkg71UDcHJyTQ==} - zod@4.5.4: resolution: {integrity: sha512-sC95tT5iHHH9gtpj6A81kh+NEaRAUFN+qlUPDUbRfOMvNf5QCBqsb3WgvnpVtK5Y+4UfA6KqufotuTvMGiTlsA==} @@ -12159,17 +12143,13 @@ snapshots: optionalDependencies: typescript: '@tsc-rs/typescript@0.8.0' - '@ai-sdk/provider-utils@4.0.57(zod@4.4.3)': + '@ai-sdk/provider-utils@4.0.57(zod@4.6.5)': dependencies: '@ai-sdk/provider': 3.0.18 '@standard-schema/spec': 1.1.0 eventsource-parser: 3.1.0 undici: 6.29.0 - zod: 4.4.3 - - '@ai-sdk/provider@3.0.15': - dependencies: - json-schema: 0.4.0 + zod: 4.6.5 '@ai-sdk/provider@3.0.18': dependencies: @@ -13071,11 +13051,6 @@ snapshots: transitivePeerDependencies: - supports-color - '@babel/types@7.29.7': - dependencies: - '@babel/helper-string-parser': 7.29.7 - '@babel/helper-validator-identifier': 7.29.7 - '@babel/types@7.29.8': dependencies: '@babel/helper-string-parser': 7.29.7 @@ -13521,7 +13496,7 @@ snapshots: react: 19.3.0 scheduler: 0.28.0 - '@effect/graphql-generator@4.0.5(@effect/platform-node@4.0.5(bufferutil@4.1.0)(effect@4.0.5)(redis@6.2.1)(utf-8-validate@6.0.6))(effect@4.0.5)': + '@effect/graphql-generator@4.0.5(patch_hash=70fe80318292f76113ccebfff22289a387248367a8bf6a0c390f541c47f1f8d5)(@effect/platform-node@4.0.5(bufferutil@4.1.0)(effect@4.0.5)(redis@6.2.1)(utf-8-validate@6.0.6))(effect@4.0.5)': dependencies: '@effect/platform-node': 4.0.5(bufferutil@4.1.0)(effect@4.0.5)(redis@6.2.1)(utf-8-validate@6.0.6) effect: 4.0.5 @@ -14723,7 +14698,7 @@ snapshots: express: 5.2.1(supports-color@8.1.1) express-rate-limit: 8.5.2(express@5.2.1(supports-color@8.1.1)) hono: 4.13.7 - jose: 6.2.3 + jose: 6.2.2 json-schema-typed: 8.0.2 pkce-challenge: 5.0.1 raw-body: 3.0.2 @@ -14792,13 +14767,6 @@ snapshots: '@napi-rs/keyring-win32-ia32-msvc': 1.3.0 '@napi-rs/keyring-win32-x64-msvc': 1.3.0 - '@napi-rs/wasm-runtime@1.1.6(@emnapi/core@1.11.2)(@emnapi/runtime@1.11.2)': - dependencies: - '@emnapi/core': 1.11.2 - '@emnapi/runtime': 1.11.2 - '@tybys/wasm-util': 0.10.3 - optional: true - '@napi-rs/wasm-runtime@1.2.4(@emnapi/core@1.10.0)(@emnapi/runtime@1.10.0)': dependencies: '@emnapi/core': 1.10.0 @@ -14813,6 +14781,13 @@ snapshots: '@tybys/wasm-util': 0.10.4 optional: true + '@napi-rs/wasm-runtime@1.2.4(@emnapi/core@1.11.2)(@emnapi/runtime@1.11.2)': + dependencies: + '@emnapi/core': 1.11.2 + '@emnapi/runtime': 1.11.2 + '@tybys/wasm-util': 0.10.4 + optional: true + '@napi-rs/wasm-runtime@1.2.4(@emnapi/core@1.11.3)(@emnapi/runtime@1.11.3)': dependencies: '@emnapi/core': 1.11.3 @@ -15172,7 +15147,7 @@ snapshots: dependencies: '@emnapi/core': 1.11.2 '@emnapi/runtime': 1.11.2 - '@napi-rs/wasm-runtime': 1.1.6(@emnapi/core@1.11.2)(@emnapi/runtime@1.11.2) + '@napi-rs/wasm-runtime': 1.2.4(@emnapi/core@1.11.2)(@emnapi/runtime@1.11.2) optional: true '@oxc-resolver/binding-win32-arm64-msvc@11.24.2': @@ -15370,8 +15345,6 @@ snapshots: '@oxlint/binding-win32-x64-msvc@1.88.0': optional: true - '@oxlint/plugins@1.68.0': {} - '@oxlint/plugins@1.88.0': {} '@peculiar/asn1-schema@2.8.0': @@ -15458,17 +15431,17 @@ snapshots: commander: 14.0.3 ignore: 7.0.5 ora: 9.4.0 - package-manager-detector: 1.6.0 + package-manager-detector: 1.8.0 picocolors: 1.1.1 prompts: 2.4.2 - tinyexec: 1.2.4 + tinyexec: 1.3.1 '@react-native-ai/apple@0.12.0(patch_hash=2d09870c2848d185cb05b53ed823a46e12dba519324d8dd8e584e28731990f9d)(react-native@0.88.0(@babel/core@7.29.7(supports-color@8.1.1))(@react-native/metro-config@0.88.0(@babel/core@7.29.7(supports-color@8.1.1))(bufferutil@4.1.0)(supports-color@8.1.1)(utf-8-validate@6.0.6))(@types/react@19.3.0)(bufferutil@4.1.0)(react@19.3.0)(supports-color@8.1.1)(utf-8-validate@6.0.6))': dependencies: - '@ai-sdk/provider': 3.0.15 - '@ai-sdk/provider-utils': 4.0.57(zod@4.4.3) + '@ai-sdk/provider': 3.0.18 + '@ai-sdk/provider-utils': 4.0.57(zod@4.6.5) react-native: 0.88.0(@babel/core@7.29.7(supports-color@8.1.1))(@react-native/metro-config@0.88.0(@babel/core@7.29.7(supports-color@8.1.1))(bufferutil@4.1.0)(supports-color@8.1.1)(utf-8-validate@6.0.6))(@types/react@19.3.0)(bufferutil@4.1.0)(react@19.3.0)(supports-color@8.1.1)(utf-8-validate@6.0.6) - zod: 4.4.3 + zod: 4.6.5 '@react-native-async-storage/async-storage@3.1.1(react-native@0.88.0(@babel/core@7.29.7(supports-color@8.1.1))(@react-native/metro-config@0.88.0(@babel/core@7.29.7(supports-color@8.1.1))(bufferutil@4.1.0)(supports-color@8.1.1)(utf-8-validate@6.0.6))(@types/react@19.3.0)(bufferutil@4.1.0)(react@19.3.0)(supports-color@8.1.1)(utf-8-validate@6.0.6))(react@19.3.0)': dependencies: @@ -15667,7 +15640,7 @@ snapshots: '@react-navigation/core': 7.24.0(react@19.3.0) escape-string-regexp: 4.0.0 fast-deep-equal: 3.1.3 - nanoid: 3.3.19 + nanoid: 3.3.20 react: 19.3.0 react-native: 0.88.0(@babel/core@7.29.7(supports-color@8.1.1))(@react-native/metro-config@0.88.0(@babel/core@7.29.7(supports-color@8.1.1))(bufferutil@4.1.0)(supports-color@8.1.1)(utf-8-validate@6.0.6))(@types/react@19.3.0)(bufferutil@4.1.0)(react@19.3.0)(supports-color@8.1.1)(utf-8-validate@6.0.6) standard-navigation: 0.0.8(react@19.3.0) @@ -16085,14 +16058,14 @@ snapshots: '@babel/plugin-syntax-typescript': 7.29.7(@babel/core@7.29.7(supports-color@8.1.1)) '@babel/template': 7.29.7 '@babel/traverse': 7.29.7(supports-color@8.1.1) - '@babel/types': 7.29.7 + '@babel/types': 7.29.8 '@tanstack/router-core': 1.171.8 '@tanstack/router-generator': 1.167.12(supports-color@8.1.1) '@tanstack/router-utils': 1.162.1(supports-color@8.1.1) '@tanstack/virtual-file-routes': 1.162.0 chokidar: 5.0.0 unplugin: 3.0.0 - zod: 4.4.3 + zod: 4.6.5 optionalDependencies: '@tanstack/react-router': 1.170.10(react-dom@19.3.0(react@19.3.0))(react@19.3.0) vite: '@voidzero-dev/vite-plus-core@1.3.0(@tsc-rs/typescript@0.8.0)(@types/node@24.12.4)(@volar/typescript@2.4.28(@tsc-rs/typescript@0.8.0))(esbuild@0.28.2)(jiti@2.7.0)(terser@5.48.0)(unrun@0.2.39)(yaml@2.9.0)' @@ -16344,11 +16317,6 @@ snapshots: '@tweenjs/tween.js@23.1.3': {} - '@tybys/wasm-util@0.10.3': - dependencies: - tslib: 2.8.1 - optional: true - '@tybys/wasm-util@0.10.4': dependencies: tslib: 2.8.1 @@ -17018,7 +16986,7 @@ snapshots: json-schema-traverse: 1.0.0 require-from-string: 2.0.2 - alchemy@2.0.0-beta.80(patch_hash=bea1b6c0c0b23157fd5f439a1d7feff430f28ac1621ba135d8a13eeec60ccacd)(2676e7bf1eae706a0c10853e80d0a1b0): + alchemy@2.0.0-beta.80(patch_hash=bea1b6c0c0b23157fd5f439a1d7feff430f28ac1621ba135d8a13eeec60ccacd)(c74a1cfb3df8b67fc508b7f3e6f07baa): dependencies: '@alchemy.run/cloudflare-runtime': 2.0.0-beta.80(@distilled.cloud/cloudflare@1.0.0-rc.13(effect@4.0.5))(@effect/platform-node@4.0.5(bufferutil@4.1.0)(effect@4.0.5)(redis@6.2.1)(utf-8-validate@6.0.6))(@tsc-rs/typescript@0.8.0)(@types/node@24.12.4)(@voidzero-dev/vite-plus-core@1.3.0(@tsc-rs/typescript@0.8.0)(@types/node@24.12.4)(@volar/typescript@2.4.28(@tsc-rs/typescript@0.8.0))(esbuild@0.28.2)(jiti@2.7.0)(terser@5.48.0)(unrun@0.2.39)(yaml@2.9.0))(effect@4.0.5)(rolldown@1.2.5) '@alchemy.run/floci': 2.0.0-beta.80(effect@4.0.5) @@ -17061,7 +17029,7 @@ snapshots: '@effect/sql-pg': 4.0.5(effect@4.0.5) '@effect/vitest': 4.0.5(patch_hash=2731c9c3761c595f25ddc625a7d61ca376b389d5b3049ecb837c8940f21cfa02)(@astrojs/compiler-rs@0.5.1)(@tsc-rs/typescript@0.8.0)(@types/node@24.12.4)(@vitest/browser-playwright@5.0.5)(@vitest/ui@5.0.5)(@volar/typescript@2.4.28(@tsc-rs/typescript@0.8.0))(bufferutil@4.1.0)(effect@4.0.5)(esbuild@0.28.2)(jiti@2.7.0)(jsdom@30.1.0(@noble/hashes@1.8.0))(playwright@1.60.0)(terser@5.48.0)(unrun@0.2.39)(utf-8-validate@6.0.6)(yaml@2.9.0) drizzle-kit: 1.0.0-rc.5-ab785fc - drizzle-orm: 1.0.0-rc.5-ab785fc(@cloudflare/workers-types@4.20260604.1)(@effect/sql-d1@4.0.0(effect@4.0.5))(@effect/sql-pg@4.0.5(effect@4.0.5))(@effect/sql-sqlite-bun@4.0.0-rc.112(effect@4.0.5))(@effect/sql-sqlite-do@4.0.5(effect@4.0.5))(@electric-sql/pglite@0.3.15)(@libsql/client@0.17.3(bufferutil@4.1.0)(utf-8-validate@6.0.6))(bun-types@1.3.14)(effect@4.0.5)(expo-sqlite@58.0.13(expo@58.0.14)(react-native@0.88.0(@babel/core@7.29.7(supports-color@8.1.1))(@react-native/metro-config@0.88.0(@babel/core@7.29.7(supports-color@8.1.1))(bufferutil@4.1.0)(supports-color@8.1.1)(utf-8-validate@6.0.6))(@types/react@19.3.0)(bufferutil@4.1.0)(react@19.3.0)(supports-color@8.1.1)(utf-8-validate@6.0.6))(react@19.3.0))(pg@8.23.0)(zod@4.4.3) + drizzle-orm: 1.0.0-rc.5-ab785fc(@cloudflare/workers-types@4.20260604.1)(@effect/sql-d1@4.0.0(effect@4.0.5))(@effect/sql-pg@4.0.5(effect@4.0.5))(@effect/sql-sqlite-bun@4.0.0-rc.112(effect@4.0.5))(@effect/sql-sqlite-do@4.0.5(effect@4.0.5))(@electric-sql/pglite@0.3.15)(@libsql/client@0.17.3(bufferutil@4.1.0)(utf-8-validate@6.0.6))(bun-types@1.3.14)(effect@4.0.5)(expo-sqlite@58.0.13(expo@58.0.14)(react-native@0.88.0(@babel/core@7.29.7(supports-color@8.1.1))(@react-native/metro-config@0.88.0(@babel/core@7.29.7(supports-color@8.1.1))(bufferutil@4.1.0)(supports-color@8.1.1)(utf-8-validate@6.0.6))(@types/react@19.3.0)(bufferutil@4.1.0)(react@19.3.0)(supports-color@8.1.1)(utf-8-validate@6.0.6))(react@19.3.0))(pg@8.23.0)(zod@4.6.5) mongodb: 6.21.0(@aws-sdk/credential-providers@3.1062.0)(socks@2.8.9) pg: 8.23.0 vite: '@voidzero-dev/vite-plus-core@1.3.0(@tsc-rs/typescript@0.8.0)(@types/node@24.12.4)(@volar/typescript@2.4.28(@tsc-rs/typescript@0.8.0))(esbuild@0.28.2)(jiti@2.7.0)(terser@5.48.0)(unrun@0.2.39)(yaml@2.9.0)' @@ -17216,7 +17184,7 @@ snapshots: http-cache-semantics: 4.2.0 js-yaml: 4.3.2 jsonc-parser: 3.3.1 - magic-string: 1.4.1 + magic-string: 1.4.3 magicast: 0.5.5 mrmime: 2.0.1 neotraverse: 1.0.1 @@ -18027,7 +17995,7 @@ snapshots: get-tsconfig: 4.14.3 jiti: 2.7.0 - drizzle-orm@1.0.0-rc.5-ab785fc(@cloudflare/workers-types@4.20260604.1)(@effect/sql-d1@4.0.0(effect@4.0.5))(@effect/sql-pg@4.0.5(effect@4.0.5))(@effect/sql-sqlite-bun@4.0.0-rc.112(effect@4.0.5))(@effect/sql-sqlite-do@4.0.5(effect@4.0.5))(@electric-sql/pglite@0.3.15)(@libsql/client@0.17.3(bufferutil@4.1.0)(utf-8-validate@6.0.6))(bun-types@1.3.14)(effect@4.0.5)(expo-sqlite@58.0.13(expo@58.0.14)(react-native@0.88.0(@babel/core@7.29.7(supports-color@8.1.1))(@react-native/metro-config@0.88.0(@babel/core@7.29.7(supports-color@8.1.1))(bufferutil@4.1.0)(supports-color@8.1.1)(utf-8-validate@6.0.6))(@types/react@19.3.0)(bufferutil@4.1.0)(react@19.3.0)(supports-color@8.1.1)(utf-8-validate@6.0.6))(react@19.3.0))(pg@8.23.0)(zod@4.4.3): + drizzle-orm@1.0.0-rc.5-ab785fc(@cloudflare/workers-types@4.20260604.1)(@effect/sql-d1@4.0.0(effect@4.0.5))(@effect/sql-pg@4.0.5(effect@4.0.5))(@effect/sql-sqlite-bun@4.0.0-rc.112(effect@4.0.5))(@effect/sql-sqlite-do@4.0.5(effect@4.0.5))(@electric-sql/pglite@0.3.15)(@libsql/client@0.17.3(bufferutil@4.1.0)(utf-8-validate@6.0.6))(bun-types@1.3.14)(effect@4.0.5)(expo-sqlite@58.0.13(expo@58.0.14)(react-native@0.88.0(@babel/core@7.29.7(supports-color@8.1.1))(@react-native/metro-config@0.88.0(@babel/core@7.29.7(supports-color@8.1.1))(bufferutil@4.1.0)(supports-color@8.1.1)(utf-8-validate@6.0.6))(@types/react@19.3.0)(bufferutil@4.1.0)(react@19.3.0)(supports-color@8.1.1)(utf-8-validate@6.0.6))(react@19.3.0))(pg@8.23.0)(zod@4.6.5): optionalDependencies: '@cloudflare/workers-types': 4.20260604.1 '@effect/sql-d1': 4.0.0(effect@4.0.5) @@ -18040,7 +18008,7 @@ snapshots: effect: 4.0.5 expo-sqlite: 58.0.13(expo@58.0.14)(react-native@0.88.0(@babel/core@7.29.7(supports-color@8.1.1))(@react-native/metro-config@0.88.0(@babel/core@7.29.7(supports-color@8.1.1))(bufferutil@4.1.0)(supports-color@8.1.1)(utf-8-validate@6.0.6))(@types/react@19.3.0)(bufferutil@4.1.0)(react@19.3.0)(supports-color@8.1.1)(utf-8-validate@6.0.6))(react@19.3.0) pg: 8.23.0 - zod: 4.4.3 + zod: 4.6.5 dset@3.1.4: {} @@ -19020,7 +18988,7 @@ snapshots: es6-error: 4.1.1 matcher: 3.0.0 roarr: 2.15.4 - semver: 7.8.5 + semver: 7.7.4 serialize-error: 7.0.1 optional: true @@ -19387,8 +19355,6 @@ snapshots: jose@6.2.2: {} - jose@6.2.3: {} - js-base64@3.7.8: {} js-cookie@3.0.8: {} @@ -19504,7 +19470,7 @@ snapshots: tinyglobby: 0.2.17 unbash: 4.0.11 yaml: 2.9.0 - zod: 4.4.3 + zod: 4.6.5 lan-network@0.2.1: {} @@ -19648,10 +19614,6 @@ snapshots: dependencies: '@jridgewell/sourcemap-codec': 1.6.0 - magic-string@1.4.1: - dependencies: - '@jridgewell/sourcemap-codec': 1.6.0 - magic-string@1.4.3: dependencies: '@jridgewell/sourcemap-codec': 1.6.0 @@ -19660,7 +19622,7 @@ snapshots: dependencies: '@babel/parser': 7.29.8 '@babel/types': 7.29.8 - source-map-js: 1.2.1 + source-map-js: 1.2.2 makeerror@1.0.12: dependencies: @@ -20356,8 +20318,6 @@ snapshots: multitars@1.0.2: {} - nanoid@3.3.19: {} - nanoid@3.3.20: {} negotiator@0.6.3: {} @@ -20374,7 +20334,7 @@ snapshots: node-abi@4.33.0: dependencies: - semver: 7.8.5 + semver: 7.7.4 node-addon-api@7.1.1: {} @@ -20383,7 +20343,7 @@ snapshots: node-api-version@0.2.1: dependencies: - semver: 7.8.5 + semver: 7.7.4 node-fetch-h2@2.3.0: dependencies: @@ -20409,7 +20369,7 @@ snapshots: graceful-fs: 4.2.11 nopt: 9.0.0 proc-log: 6.1.0 - semver: 7.8.5 + semver: 7.7.4 tar: 7.5.22 tinyglobby: 0.2.17 undici: 6.29.0 @@ -20763,8 +20723,6 @@ snapshots: p-try@2.2.0: {} - package-manager-detector@1.6.0: {} - package-manager-detector@1.8.0: {} pako@1.0.11: {} @@ -21870,8 +21828,6 @@ snapshots: smart-buffer: 4.2.0 optional: true - source-map-js@1.2.1: {} - source-map-js@1.2.2: {} source-map-support@0.5.21: @@ -22104,8 +22060,6 @@ snapshots: tinyclip@1.0.3: {} - tinyexec@1.2.4: {} - tinyexec@1.3.1: {} tinyglobby@0.2.17: @@ -22851,8 +22805,6 @@ snapshots: zod@3.25.76: {} - zod@4.4.3: {} - zod@4.5.4: {} zod@4.6.5: {} diff --git a/pnpm-workspace.yaml b/pnpm-workspace.yaml index a8b2ec7ca419..6a251dbd220a 100644 --- a/pnpm-workspace.yaml +++ b/pnpm-workspace.yaml @@ -294,6 +294,7 @@ overrides: "@effect/platform-node": "catalog:" "@effect/platform-node-shared": "catalog:" "@effect/sql-pg": "catalog:" + "@effect/graphql-generator": "catalog:" "@effect/vitest": "catalog:" "@effect/vitest>vitest": "-" "@expo/dom-webview": 58.0.2 @@ -357,6 +358,7 @@ patchedDependencies: expo-audio@58.0.9: patches/expo-audio@58.0.9.patch expo-network@58.0.3: patches/expo-network@58.0.3.patch "@clerk/expo-native-components@0.4.0": patches/@clerk__expo-native-components@0.4.0.patch + "@effect/graphql-generator@4.0.5": patches/@effect__graphql-generator@4.0.5.patch "@effect/vitest@4.0.5": patches/@effect__vitest@4.0.5.patch "@expo/metro-config@58.0.14": patches/@expo__metro-config@58.0.14.patch expo-sharing@58.0.19: patches/expo-sharing@58.0.19.patch diff --git a/scripts/check-changed.ts b/scripts/check-changed.ts index d717c7bbbe63..717c895a5313 100644 --- a/scripts/check-changed.ts +++ b/scripts/check-changed.ts @@ -72,9 +72,11 @@ const runKnip = files.some( ); // CI's Lint job checks that generated GraphQL operations match their sources. -const graphql = ["apps/server", "packages/source-control-github"].filter((dir) => - files.some((file) => file.startsWith(`${dir}/`)), -); +const graphql = [ + "apps/server", + "packages/issue-tracker-linear", + "packages/source-control-github", +].filter((dir) => files.some((file) => file.startsWith(`${dir}/`))); const filters = (names: ReadonlyArray) => names.flatMap((name) => ["--filter", name]); const steps = [ diff --git a/scripts/release-smoke.ts b/scripts/release-smoke.ts index e8507af86228..6b302b433f3e 100644 --- a/scripts/release-smoke.ts +++ b/scripts/release-smoke.ts @@ -38,6 +38,7 @@ const workspaceFiles = [ "packages/provider-muse/package.json", "packages/provider-opencode/package.json", "packages/issue-tracker-core/package.json", + "packages/issue-tracker-linear/package.json", "packages/source-control-azure-devops/package.json", "packages/source-control-bitbucket/package.json", "packages/source-control-core/package.json",