---
title: "List scripts"
method: GET
path: "/api/scripts/{handle}"
---

# List scripts

`GET /api/scripts/{handle}`

## Request

- Base URL: `https://reduck.ai`
- URL: `https://reduck.ai/api/scripts/{handle}`
- Auth: one of:
  - HTTP bearer
  - API key in header `X-API-Key`

List the scripts owned by one handle. The owner, and any member of the project when the handle names one, sees every script under it; everyone else sees only that owner's public scripts.

## Path parameters

- `handle` string, required: The owner a resource is addressed under: "@username" for a personal scope, or a bare slug for a project.

## Query parameters

- `page` integer
- `pageSize` integer
- `host` string
- `slug` string: The script's unique identifier within its host, unique per owner.
- `visibility` 'private' | 'public'
- `archived` 'true' | 'false': Filter on archived state. Omit it and both archived and active scripts come back; `true` for archived only, `false` for active only.
- `status` 'healthy' | 'degraded' | 'failing' | 'unknown'
- `q` string
- `sortBy` 'relevance' | 'featured' | 'name' | 'host' | 'runs' | 'successRate' | 'avgTime' | 'lastRunAt' | 'createdAt' | 'updatedAt': How to order the results. `relevance` needs a `q` search term and is the default with one; without `q` there is nothing to be relevant to and the default order is used instead.
- `order` 'asc' | 'desc'

## Response `200`

OK

- PaginatedResponseScriptSummary
  - `data` ScriptSummary[], required
    - `id` string, required
    - `name` string, required
    - `slug` string, required
    - `host` string, required
    - `description` string, required
    - `visibility` 'private' | 'public', required
    - `current_version_id` string, nullable, required
    - `archived_at` string, nullable, required
    - `created_at` string, required
    - `updated_at` string, required
    - `author` ScriptAuthor, required
      - `kind` 'user' | 'project', required
      - `handle` string, required
      - `name` string, required
      - `approval` 'official' | 'trusted' | 'unverified', required
    - `execution_count` number, required
    - `last_run_at` string, nullable, required
    - `success_rate` number, nullable, required
    - `avg_time_ms` number, nullable, required
    - `version_count` number, required
    - `human_required` boolean, required
    - `current_version` ScriptVersionSummary, required
      - `id` string, required
      - `script_id` string, required
      - `version_number` number, required
      - `parent_version_id` string, nullable, required
      - `language` string, required
      - `logged_in` boolean, required
      - `side_effects` 'none' | 'undetermined' | 'write', required
      - `draft` boolean, required
      - `note` string, nullable: Why this version exists. Omitted on an official script unless you belong to the project that owns it, and never carried by the version a script listing embeds.
      - `created_by` object, nullable, required: Who saved this version. Distinct from the script's `author`, which is the OWNER (a user or a project): a project's script is edited by its members one at a time, and this names the one. Null when that account has since been deleted.
        - `handle` string, required
        - `name` string, required
      - `created_at` string, required
      - `execution_count` number, required
      - `last_run_at` string, nullable, required
      - `success_rate` number, nullable, required
      - `avg_time_ms` number, nullable, required
  - `hasNextPage` boolean, required
  - `totalCount` number

## Other responses

- `401`: Not authenticated
- `403`: Forbidden
- `404`: Not found

---

[API](https://skmtc.dev/reduck/apis/reduck-api.md) · [All operations](https://skmtc.dev/reduck/apis/reduck-api/llms.txt) · [OpenAPI document](https://skmtc.dev/reduck/apis/reduck-api/revisions/a573b91206d6?raw)
