@archastro/sdk
    Preparing search index...
    Index

    Constructors

    Methods

    • List task blocker cycles for an organization Runs an on-demand diagnostic over unfinished org-owned tasks for the specified organization and returns a forward cursor-paginated page of complete cyclic blocker components. Detection is bounded to owners with at most 100 unfinished tasks. This endpoint is read-only: cycles do not prevent task updates, lease acquisition, or completion.

      Parameters

      • org: string

        Organization ID (org_...) whose org-owned tasks should be returned.

      • Optionalparams: { afterCursor?: string; limit?: number }

        Query parameters.

        • OptionalafterCursor?: string

          Opaque cursor returned by the preceding page.

        • Optionallimit?: number

          Maximum cycle components to return. Defaults to 50; maximum is 100.

      Returns Promise<
          {
              after_cursor?: string;
              before_cursor?: string;
              data: {
                  tasks: {
                      agent?: string
                      | null;
                      aggregate_version?: number | null;
                      blocked_by_count?: number;
                      blockers?: string[];
                      closed_at?: string | null;
                      comments_count?: number;
                      created_at?: string;
                      created_by_actor?:
                          | {
                              alias?: string
                              | null;
                              id?: string | null;
                              name?: string | null;
                              profile_picture?:
                                  | {
                                      content_url?: (...)
                                      | (...)
                                      | (...);
                                      file?: (...) | (...) | (...);
                                      height?: (...) | (...) | (...);
                                      media?: (...) | (...) | (...);
                                      mime_type?: (...) | (...) | (...);
                                      refresh_url?: (...) | (...) | (...);
                                      url?: (...) | (...) | (...);
                                      width?: (...) | (...) | (...);
                                  }
                                  | null;
                          }
                          | null;
                      created_by_agent?: string
                      | null;
                      created_by_user?: string | null;
                      current_lease?:
                          | { expires_at: string; harness: string; session_name: string }
                          | null;
                      description?: string | null;
                      due_date?: string | null;
                      epic?: string | null;
                      human_answer_receipts?: Record<string, unknown>;
                      id: string;
                      is_blocked?: boolean;
                      is_stalled?: boolean;
                      links?: Record<string, unknown>;
                      machine_rescope_receipts?: Record<string, unknown>;
                      metadata?: Record<string, unknown>;
                      name: string;
                      org?: string | null;
                      owner_actor?:
                          | {
                              alias?: string
                              | null;
                              id?: string | null;
                              name?: string | null;
                              profile_picture?:
                                  | {
                                      content_url?: (...)
                                      | (...)
                                      | (...);
                                      file?: (...) | (...) | (...);
                                      height?: (...) | (...) | (...);
                                      media?: (...) | (...) | (...);
                                      mime_type?: (...) | (...) | (...);
                                      refresh_url?: (...) | (...) | (...);
                                      url?: (...) | (...) | (...);
                                      width?: (...) | (...) | (...);
                                  }
                                  | null;
                          }
                          | null;
                      owner_agent?: string
                      | null;
                      owner_user?: string | null;
                      parent?: string | null;
                      priority?: number;
                      project_id?: string | null;
                      sandbox?: string | null;
                      source_id?: string | null;
                      source_scope?: string | null;
                      source_type?: string | null;
                      stalled_since?: string | null;
                      status: string;
                      subtasks_count?: number;
                      tags?: string[];
                      target_binary?: string | null;
                      target_version?: string | null;
                      task_epic?: string | null;
                      team?: string | null;
                      thread?: string | null;
                      updated_at?: string;
                      user?: string | null;
                  }[];
              }[];
              has_more: boolean;
          },
      >

      Successful response

    • Find an owner's tasks by external reference Returns all exact external-reference matches owned by the requested principal. Multiple matches remain explicit; callers must not choose an arbitrary task.

      Parameters

      • org: string

        Organization ID (org_...) whose org-owned tasks should be returned.

      • Optionalparams: {
            externalScope?: string;
            objectId?: string;
            objectType?: string;
            team?: string;
            user?: string;
        }

        Query parameters.

        • OptionalexternalScope?: string

          External host.

        • OptionalobjectId?: string

          External object identity.

        • OptionalobjectType?: string

          External object type.

        • Optionalteam?: string

          Team owner.

        • Optionaluser?: string

          User owner.

      Returns Promise<
          {
              data: {
                  agent?: string
                  | null;
                  aggregate_version?: number | null;
                  blocked_by_count?: number;
                  blockers?: string[];
                  closed_at?: string | null;
                  comments_count?: number;
                  created_at?: string;
                  created_by_actor?:
                      | {
                          alias?: string
                          | null;
                          id?: string | null;
                          name?: string | null;
                          profile_picture?:
                              | {
                                  content_url?: string
                                  | null;
                                  file?: string | null;
                                  height?: number | null;
                                  media?: string | null;
                                  mime_type?: string | null;
                                  refresh_url?: string | null;
                                  url?: string | null;
                                  width?: number | null;
                              }
                              | null;
                      }
                      | null;
                  created_by_agent?: string
                  | null;
                  created_by_user?: string | null;
                  current_lease?:
                      | { expires_at: string; harness: string; session_name: string }
                      | null;
                  description?: string | null;
                  due_date?: string | null;
                  epic?: string | null;
                  human_answer_receipts?: Record<string, unknown>;
                  id: string;
                  is_blocked?: boolean;
                  is_stalled?: boolean;
                  links?: Record<string, unknown>;
                  machine_rescope_receipts?: Record<string, unknown>;
                  metadata?: Record<string, unknown>;
                  name: string;
                  org?: string | null;
                  owner_actor?:
                      | {
                          alias?: string
                          | null;
                          id?: string | null;
                          name?: string | null;
                          profile_picture?:
                              | {
                                  content_url?: string
                                  | null;
                                  file?: string | null;
                                  height?: number | null;
                                  media?: string | null;
                                  mime_type?: string | null;
                                  refresh_url?: string | null;
                                  url?: string | null;
                                  width?: number | null;
                              }
                              | null;
                      }
                      | null;
                  owner_agent?: string
                  | null;
                  owner_user?: string | null;
                  parent?: string | null;
                  priority?: number;
                  project_id?: string | null;
                  sandbox?: string | null;
                  source_id?: string | null;
                  source_scope?: string | null;
                  source_type?: string | null;
                  stalled_since?: string | null;
                  status: string;
                  subtasks_count?: number;
                  tags?: string[];
                  target_binary?: string | null;
                  target_version?: string | null;
                  task_epic?: string | null;
                  team?: string | null;
                  thread?: string | null;
                  updated_at?: string;
                  user?: string | null;
              }[];
          },
      >

      Successful response

    • Find or create a task by source Atomically creates one task per owner, tenant and source. Retries return the current task without updating it. Historical tasks created through ordinary create are not adopted.

      Parameters

      • org: string

        Organization ID (org_...) whose org-owned tasks should be returned.

      • input: {
            agent?: string;
            description?: string;
            epic?: string;
            name: string;
            owner_user?: string;
            source_id: string;
            source_scope: string;
            source_type: string;
            status?: string;
            team?: string;
            user?: string;
        }

        Request body.

        • Optionalagent?: string

          Explicit acting agent for privileged callers.

        • Optionaldescription?: string

          Initial task description.

        • Optionalepic?: string

          Initial epic grouping.

        • name: string

          Initial task name.

        • Optionalowner_user?: string

          Initial assigned user; immutable on retries.

        • source_id: string

          Source identity, for example owner/repo#123.

        • source_scope: string

          Source scope, for example github.

        • source_type: string

          Source type, for example pull_request.

        • Optionalstatus?: string

          Initial task status.

        • Optionalteam?: string

          Team owner.

        • Optionaluser?: string

          User owner, or explicit acting user on a team route.

      Returns Promise<TaskEnsureResult>

      The task and whether this request created it.

    • Create a task for an organization Creates a new org-owned task (org tenant, no narrower user/team/agent scope) and returns the full task object. User-authenticated calls are attributed to the authenticated user or agent. App-scoped developer and server-to-server callers must provide an explicit user or agent actor for the organization. Every referenced principal is validated against the app and organization before creation.

      Parameters

      • org: string

        Organization ID (org_...) whose org-owned tasks should be returned.

      • input: {
            agent?: string;
            task: {
                blockers?: string[];
                description?: string;
                due_date?: string;
                epic?: string;
                epic_id?: string;
                id?: string;
                links?: Record<string, unknown>;
                metadata?: Record<string, unknown>;
                name: string;
                owner_agent?: string;
                owner_user?: string;
                parent?: string;
                priority?: number;
                project_id?: string;
                source_id?: string;
                source_scope?: string;
                source_type?: string;
                status?: string;
                tags?: string[];
                target_binary?: string;
                target_version?: string;
                thread?: string;
            };
            user?: string;
        }

        Request body.

        • Optionalagent?: string

          Explicit acting agent (agi_...) for a developer or server-to-server call. Mutually exclusive with an acting user; the agent must belong to the organization.

        • task: {
              blockers?: string[];
              description?: string;
              due_date?: string;
              epic?: string;
              epic_id?: string;
              id?: string;
              links?: Record<string, unknown>;
              metadata?: Record<string, unknown>;
              name: string;
              owner_agent?: string;
              owner_user?: string;
              parent?: string;
              priority?: number;
              project_id?: string;
              source_id?: string;
              source_scope?: string;
              source_type?: string;
              status?: string;
              tags?: string[];
              target_binary?: string;
              target_version?: string;
              thread?: string;
          }

          Attributes for the task to create. name is required; all other fields are optional.

        • Optionaluser?: string

          Explicit acting user (usr_...) for a developer or server-to-server call. Mutually exclusive with an acting agent.

      Returns Promise<Task>

      The newly created task.

    • List an organization's tasks Returns org-owned tasks for the specified organization: rows with the org tenant and no narrower user/team/agent scope. Explicitly personal, team, or agent tasks are excluded here; list those via the user/team collections or fetch them directly when authorized. Every organization member may list. App-scoped developer and server-to-server callers supply the org in the route.

      Parameters

      • org: string

        Organization ID (org_...) whose org-owned tasks should be returned.

      • Optionalparams: {
            afterCursor?: string;
            attention?: boolean;
            dueAfter?: string;
            dueBefore?: string;
            epic?: string;
            epicId?: string;
            include?: string;
            involving?: string;
            limit?: number;
            order?: string;
            overdue?: boolean;
            owner?: string;
            ownerAgent?: string;
            ownerUser?: string;
            parent?: string;
            priority?: number;
            ready?: boolean;
            search?: string;
            sort?: string;
            sourceId?: string;
            sourceScope?: string;
            sourceType?: string;
            status?: string;
            summary?: boolean;
            tag?: string;
        }

        Query parameters.

        • OptionalafterCursor?: string

          Opaque cursor returned by the previous page.

        • Optionalattention?: boolean

          When true, return paused, failed, or in-progress tasks with no lease or a past lease expiry.

        • OptionaldueAfter?: string

          Return only tasks with a due date strictly after this ISO 8601 datetime or date. Tasks without a due date are excluded.

        • OptionaldueBefore?: string

          Return only tasks with a due date strictly before this ISO 8601 datetime (2026-08-01T00:00:00Z) or date (2026-08-01, meaning midnight UTC). Tasks without a due date are excluded.

        • Optionalepic?: string

          Return only tasks with this exact epic label.

        • OptionalepicId?: string

          Return only members of this Epic ID.

        • Optionalinclude?: string

          Set to blockers to include visible blocker task IDs.

        • Optionalinvolving?: string

          Return only tasks owned or created by this user: me or a user public ID (usr_...). The "My work" predicate.

        • Optionallimit?: number

          Maximum number of tasks to return. Capped at 100.

        • Optionalorder?: string

          Sort direction, "asc" or "desc". Defaults to "desc" for created and "asc" for updated, due_date and priority.

        • Optionaloverdue?: boolean

          When true, return only overdue tasks: a due date before the current UTC day and a status other than "done". A task due today is not overdue.

        • Optionalowner?: string

          Return only tasks owned by this user: me or a user public ID (usr_...).

        • OptionalownerAgent?: string

          Filter tasks assigned to a specific agent. Provide the agent's public ID (agi_...).

        • OptionalownerUser?: string

          Filter tasks assigned to a specific user. Provide the user's public ID (usr_...).

        • Optionalparent?: string

          Return only subtasks of the given task (tsk_...), or pass none to return only top-level tasks.

        • Optionalpriority?: number

          Filter tasks by priority, from 0 (highest) to 4 (lowest).

        • Optionalready?: boolean

          When true, return only open tasks with no unfinished blockers and no active session lease. This is a projection snapshot; claim a lease before starting work.

        • Optionalsearch?: string

          Restrict results to tasks whose name or description contains this string.

        • Optionalsort?: string

          Sort key. One of "created" (default — most recently created first), "due_date" (soonest due first; tasks without a due date always sort last), "priority" (most urgent first), or "updated" (latest-state sync, ties by ID). Updated rows can coalesce or reappear: upsert by ID and aggregate version. Delayed/backdated or equal-time updates behind a cursor require periodic reconciliation. This is not a lossless mutation log.

        • OptionalsourceId?: string

          Return only tasks whose source matches this object identity. Must be supplied with the other source filters.

        • OptionalsourceScope?: string

          Return only tasks whose source matches this container. Must be supplied with source_type and source_id.

        • OptionalsourceType?: string

          Return only tasks whose source matches this object kind. Must be supplied with the other source filters.

        • Optionalstatus?: string

          Filter tasks by status. One of "open", "in_progress", "in_review", or "done". Omit to return tasks in all statuses.

        • Optionalsummary?: boolean

          When true, omit description from every task. Use for list views.

        • Optionaltag?: string

          Return only tasks carrying this tag (matched against the canonical lowercase form).

      Returns Promise<
          {
              after_cursor?: string
              | null;
              before_cursor?: string | null;
              data: {
                  agent?: string | null;
                  aggregate_version?: number | null;
                  blocked_by_count?: number;
                  blockers?: string[];
                  closed_at?: string | null;
                  comments_count?: number;
                  created_at?: string;
                  created_by_actor?:
                      | {
                          alias?: string
                          | null;
                          id?: string | null;
                          name?: string | null;
                          profile_picture?:
                              | {
                                  content_url?: string
                                  | null;
                                  file?: string | null;
                                  height?: number | null;
                                  media?: string | null;
                                  mime_type?: string | null;
                                  refresh_url?: string | null;
                                  url?: string | null;
                                  width?: number | null;
                              }
                              | null;
                      }
                      | null;
                  created_by_agent?: string
                  | null;
                  created_by_user?: string | null;
                  current_lease?:
                      | { expires_at: string; harness: string; session_name: string }
                      | null;
                  description?: string | null;
                  due_date?: string | null;
                  epic?: string | null;
                  human_answer_receipts?: Record<string, unknown>;
                  id: string;
                  is_blocked?: boolean;
                  is_stalled?: boolean;
                  links?: Record<string, unknown>;
                  machine_rescope_receipts?: Record<string, unknown>;
                  metadata?: Record<string, unknown>;
                  name: string;
                  org?: string | null;
                  owner_actor?:
                      | {
                          alias?: string
                          | null;
                          id?: string | null;
                          name?: string | null;
                          profile_picture?:
                              | {
                                  content_url?: string
                                  | null;
                                  file?: string | null;
                                  height?: number | null;
                                  media?: string | null;
                                  mime_type?: string | null;
                                  refresh_url?: string | null;
                                  url?: string | null;
                                  width?: number | null;
                              }
                              | null;
                      }
                      | null;
                  owner_agent?: string
                  | null;
                  owner_user?: string | null;
                  parent?: string | null;
                  priority?: number;
                  project_id?: string | null;
                  sandbox?: string | null;
                  source_id?: string | null;
                  source_scope?: string | null;
                  source_type?: string | null;
                  stalled_since?: string | null;
                  status: string;
                  subtasks_count?: number;
                  tags?: string[];
                  target_binary?: string | null;
                  target_version?: string | null;
                  task_epic?: string | null;
                  team?: string | null;
                  thread?: string | null;
                  updated_at?: string;
                  user?: string | null;
              }[];
              has_more: boolean;
          },
      >

      Successful response

    • Get task activity metrics for an organization Returns task activity metrics scoped to org-owned tasks (org tenant, no narrower user/team/agent scope). open counts currently open or in-progress org tasks, created counts tasks inserted in the UTC-day window, and completed counts tasks whose closed_at falls in that window while still in a closed status. Hard-deleted tasks are absent from the projection and therefore omitted. The daily series is zero-filled across the requested window and includes reconstructed end-of-day open stock. Any organization member may read this count-only summary. Requests from callers without org access return 404 so organization existence is not disclosed.

      Parameters

      • org: string

        Organization ID (org_...) whose org-owned tasks should be returned.

      • Optionalparams: { days?: number }

        Query parameters.

        • Optionaldays?: number

          UTC-day window. One of 7, 30, 90, or 365; defaults to 30.

      Returns Promise<
          {
              completed: number;
              created: number;
              days: number;
              end_at: string;
              open: number;
              series: Record<string, unknown>[];
              start_at: string;
          },
      >

      Successful response

    • List an organization's ready tasks Returns open org-owned tasks with no unfinished blockers and no active session lease. Readiness is calculated by the server from the current task projection. It is a snapshot, not a reservation; claim a task lease before starting work. Results are ordered by priority (0, the most urgent, first), then oldest first, so the first page is always the most urgent ready work. Pass explain=true to include every open task with a stable readiness reason.

      Parameters

      • org: string

        Organization ID (org_...) whose org-owned tasks should be returned.

      • Optionalparams: {
            afterCursor?: string;
            assignedToMe?: boolean;
            epic?: string;
            epicId?: string;
            explain?: boolean;
            limit?: number;
            owner?: string[];
            sourceId?: string;
            sourceScope?: string;
            sourceType?: string;
        }

        Query parameters.

        • OptionalafterCursor?: string

          Opaque cursor returned by the previous page.

        • OptionalassignedToMe?: boolean

          Only include tasks assigned to the authenticated user. Equivalent to owner[]=me; sending it together with owner returns 422.

        • Optionalepic?: string

          Only include tasks with this exact epic label.

        • OptionalepicId?: string

          Return only members of this Epic ID.

        • Optionalexplain?: boolean

          Include blocked and actively leased open tasks with exclusion reasons.

        • Optionallimit?: number

          Maximum number of readiness entries to return. Capped at 100.

        • Optionalowner?: string[]

          Owner kinds to include; the result is the union of the listed kinds. Accepted values: me (assigned to the authenticated user) and unassigned (no user or agent owner). Agent-assigned tasks match neither value. Omit to include every owner.

        • OptionalsourceId?: string

          Only include tasks whose source matches this object identity.

        • OptionalsourceScope?: string

          Only include tasks whose source matches this container. Must be supplied with source_type and source_id.

        • OptionalsourceType?: string

          Only include tasks whose source matches this object kind.

      Returns Promise<
          {
              after_cursor?: string;
              authoritative: boolean;
              before_cursor?: string;
              data: {
                  readiness: "leased"
                  | "ready"
                  | "blocked";
                  reason?: "open_blockers" | "active_lease" | null;
                  task: {
                      agent?: string | null;
                      aggregate_version?: number | null;
                      blocked_by_count?: number;
                      blockers?: string[];
                      closed_at?: string | null;
                      comments_count?: number;
                      created_at?: string;
                      created_by_actor?:
                          | {
                              alias?: string
                              | null;
                              id?: string | null;
                              name?: string | null;
                              profile_picture?:
                                  | {
                                      content_url?: string
                                      | null;
                                      file?: string | null;
                                      height?: number | null;
                                      media?: string | null;
                                      mime_type?: string | null;
                                      refresh_url?: string | null;
                                      url?: string | null;
                                      width?: number | null;
                                  }
                                  | null;
                          }
                          | null;
                      created_by_agent?: string
                      | null;
                      created_by_user?: string | null;
                      current_lease?:
                          | { expires_at: string; harness: string; session_name: string }
                          | null;
                      description?: string | null;
                      due_date?: string | null;
                      epic?: string | null;
                      human_answer_receipts?: Record<string, unknown>;
                      id: string;
                      is_blocked?: boolean;
                      is_stalled?: boolean;
                      links?: Record<string, unknown>;
                      machine_rescope_receipts?: Record<string, unknown>;
                      metadata?: Record<string, unknown>;
                      name: string;
                      org?: string | null;
                      owner_actor?:
                          | {
                              alias?: string
                              | null;
                              id?: string | null;
                              name?: string | null;
                              profile_picture?:
                                  | {
                                      content_url?: string
                                      | null;
                                      file?: string | null;
                                      height?: number | null;
                                      media?: string | null;
                                      mime_type?: string | null;
                                      refresh_url?: string | null;
                                      url?: string | null;
                                      width?: number | null;
                                  }
                                  | null;
                          }
                          | null;
                      owner_agent?: string
                      | null;
                      owner_user?: string | null;
                      parent?: string | null;
                      priority?: number;
                      project_id?: string | null;
                      sandbox?: string | null;
                      source_id?: string | null;
                      source_scope?: string | null;
                      source_type?: string | null;
                      stalled_since?: string | null;
                      status: string;
                      subtasks_count?: number;
                      tags?: string[];
                      target_binary?: string | null;
                      target_version?: string | null;
                      task_epic?: string | null;
                      team?: string | null;
                      thread?: string | null;
                      updated_at?: string;
                      user?: string | null;
                  };
              }[];
              has_more: boolean;
          },
      >

      Successful response

    • Search an organization's tasks Performs a full-text search over org-owned tasks for the specified organization and returns matching results. Combine q with the optional filters to narrow the result set further. When no query is provided, the endpoint behaves like a filtered list. The query field in the response echoes the effective search query. Explicitly personal, team, or agent tasks are excluded here.

      Parameters

      • org: string

        Organization ID (org_...) whose org-owned tasks should be returned.

      • Optionalparams: {
            afterCursor?: string;
            epic?: string;
            epicId?: string;
            limit?: number;
            ownerAgent?: string;
            ownerUser?: string;
            parent?: string;
            priority?: number;
            q?: string;
            query?: string;
            sourceId?: string;
            sourceScope?: string;
            sourceType?: string;
            status?: string;
            tag?: string;
        }

        Query parameters.

        • OptionalafterCursor?: string

          Opaque cursor returned by the previous page.

        • Optionalepic?: string

          Return only tasks with this exact epic label.

        • OptionalepicId?: string

          Return only members of this Epic ID.

        • Optionallimit?: number

          Maximum number of tasks to return. Capped at 100.

        • OptionalownerAgent?: string

          Filter tasks assigned to a specific agent. Provide the agent's public ID (agi_...).

        • OptionalownerUser?: string

          Filter tasks assigned to a specific user. Provide the user's public ID (usr_...).

        • Optionalparent?: string

          Return only subtasks of the given task (tsk_...), or pass none to return only top-level tasks.

        • Optionalpriority?: number

          Filter tasks by priority, from 0 (highest) to 4 (lowest).

        • Optionalq?: string

          Full-text search query matched against task names and descriptions. Takes precedence over query when both are provided.

        • Optionalquery?: string

          Alias for q. Use q when possible; this parameter exists for compatibility.

        • OptionalsourceId?: string

          Return only tasks whose source matches this object identity. Must be supplied with the other source filters.

        • OptionalsourceScope?: string

          Return only tasks whose source matches this container. Must be supplied with source_type and source_id.

        • OptionalsourceType?: string

          Return only tasks whose source matches this object kind. Must be supplied with the other source filters.

        • Optionalstatus?: string

          Filter results by status. One of "open", "in_progress", "in_review", or "done". Omit to include all statuses.

        • Optionaltag?: string

          Return only tasks carrying this tag (matched against the canonical lowercase form).

      Returns Promise<
          {
              after_cursor?: string;
              before_cursor?: string;
              data: {
                  agent?: string
                  | null;
                  aggregate_version?: number | null;
                  blocked_by_count?: number;
                  blockers?: string[];
                  closed_at?: string | null;
                  comments_count?: number;
                  created_at?: string;
                  created_by_actor?:
                      | {
                          alias?: string
                          | null;
                          id?: string | null;
                          name?: string | null;
                          profile_picture?:
                              | {
                                  content_url?: string
                                  | null;
                                  file?: string | null;
                                  height?: number | null;
                                  media?: string | null;
                                  mime_type?: string | null;
                                  refresh_url?: string | null;
                                  url?: string | null;
                                  width?: number | null;
                              }
                              | null;
                      }
                      | null;
                  created_by_agent?: string
                  | null;
                  created_by_user?: string | null;
                  current_lease?:
                      | { expires_at: string; harness: string; session_name: string }
                      | null;
                  description?: string | null;
                  due_date?: string | null;
                  epic?: string | null;
                  human_answer_receipts?: Record<string, unknown>;
                  id: string;
                  is_blocked?: boolean;
                  is_stalled?: boolean;
                  links?: Record<string, unknown>;
                  machine_rescope_receipts?: Record<string, unknown>;
                  metadata?: Record<string, unknown>;
                  name: string;
                  org?: string | null;
                  owner_actor?:
                      | {
                          alias?: string
                          | null;
                          id?: string | null;
                          name?: string | null;
                          profile_picture?:
                              | {
                                  content_url?: string
                                  | null;
                                  file?: string | null;
                                  height?: number | null;
                                  media?: string | null;
                                  mime_type?: string | null;
                                  refresh_url?: string | null;
                                  url?: string | null;
                                  width?: number | null;
                              }
                              | null;
                      }
                      | null;
                  owner_agent?: string
                  | null;
                  owner_user?: string | null;
                  parent?: string | null;
                  priority?: number;
                  project_id?: string | null;
                  sandbox?: string | null;
                  source_id?: string | null;
                  source_scope?: string | null;
                  source_type?: string | null;
                  stalled_since?: string | null;
                  status: string;
                  subtasks_count?: number;
                  tags?: string[];
                  target_binary?: string | null;
                  target_version?: string | null;
                  task_epic?: string | null;
                  team?: string | null;
                  thread?: string | null;
                  updated_at?: string;
                  user?: string | null;
              }[];
              has_more: boolean;
              query: string;
          },
      >

      Successful response

    • Stream organization task changes Organization task hints, not a lossless mutation log. Subscribe before reading ready cursors. Resume tasks with sort=updated&order=asc and deletions with their own cursor, retaining each page's after_cursor. Rows may coalesce or reappear; upsert by ID/version and periodically reconcile late/backdated/equal-time rows behind a cursor. Gaps beyond seven-day tombstone retention require full resync. Projector commit/ack failures can lose hints, so clients must reconcile too. Cross-batch deduplication retains at most 1024 task IDs in FIFO order; hints for evicted IDs can reappear, so clients must discard older/equal versions. Pending batches admit at most 512 distinct IDs, bounding visibility queries and emitted event lists. Overflow closes the stream; reconnect and reconcile. The independently released Rust Factory panel and assignment sweeps consume this contract in https://archdev.ai/tasks/tsk_6ttk2gUwttt6wwkiprwui7. That consumer must not roll out until this provider endpoint and the cursor / deletion contracts are deployed and verified on Platform. Its old-server 404 polling fallback is compatibility protection, not a substitute for this gate.

      Parameters

      • org: string

        Organization ID (org_...) whose org-owned tasks should be returned.

      Returns AsyncIterable<
          | {
              data: {
                  deletions_after_cursor: string
                  | null;
                  tasks_after_cursor: string | null;
              };
              event: "ready";
          }
          | {
              data: {
                  aggregate_version: number;
                  id: string;
                  status: string;
                  updated_at: string;
              };
              event: "task_changed";
          }
          | { data: TaskDeletion; event: "task_deleted" },
      >

      Server-Sent Events stream