---
title: "Create a new package"
method: POST
path: "/scopes/{scope}/packages"
---

# Create a new package

`POST /scopes/{scope}/packages`

Creates a new package in a scope

## Path parameters

- `scope` string, required — The name of a scope. This must not be @ prefixed.

## Request body

- CreatePackageRequest
  - `package` string, required — The name of a package.

## Response `200`

OK

- Package
  - `scope` string, required — The name of a scope. This must not be @ prefixed.
  - `name` string, required — The name of a package.
  - `description` string, required — The description of the package.
  - `runtimeCompat` RuntimeCompat
    - `browser` boolean, nullable — Whether the package is compatible with web browsers.
    - `deno` boolean, nullable — Whether the package is compatible with Deno.
    - `node` boolean, nullable — Whether the package is compatible with Node.js.
    - `workerd` boolean, nullable — Whether the package is compatible with workerd.
    - `bun` boolean, nullable — Whether the package is compatible with Bun.
  - `createdAt` string, date-time, required — The date and time when the package was created.
  - `updatedAt` string, date-time, required — The date and time when the package was last updated.
  - `githubRepository` GitHubRepository
    - `owner` string — The GitHub user / organization of the repository.
    - `name` string — The GitHub repository name.
  - `score` number

## Other responses

- `400` — Invalid request
- `401` — Unauthorized
- `403` — User is not a scope member
- `404` — Scope not found

## Changes

- **2024-07-03** `bdf10fdaec39` — 1 info
  - added the optional property `score` to the response with the `200` status
- **2024-03-14** `cebb48e7803a` — 1 info
  - added the optional property `runtimeCompat` to the response with the `200` status
- **2024-03-14** `a15e5ad40921` — 1 info
  - added the optional property `githubRepository` to the response with the `200` status
- **2024-02-28** `f8d3b912d946` — 5 breaking, 7 warning, 2 info
  - removed the required property `dependencyCount` from the response with the `200` status
  - removed the required property `dependentCount` from the response with the `200` status
  - removed the required property `isArchived` from the response with the `200` status
  - removed the required property `readmeSource` from the response with the `200` status
  - …10 more

[Change history](https://skmtc.dev/jsr-io/apis/jsr-api/changes/scopes/:scope/packages/post.md)

---

[API](https://skmtc.dev/jsr-io/apis/jsr-api.md) · [All operations](https://skmtc.dev/jsr-io/apis/jsr-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/jsr-io/jsr-api/revisions/bdf10fdaec39/schema)
