Skip to main content
POST
Resolve and pin dependencies

Authorizations

Authorization
string
header
required

Use a JWT bearer token or a Veryfront API key in the Authorization header.

Path Parameters

project_reference
string
required

Project UUID or slug, or the project domain.

Body

application/json
specifiers
string[]
required

npm package specifiers to pin in package.json after adding imports or packages. Inline exact versions are used as-is; ranges and bare names resolve against the npm registry (cached in Redis). Existing exact pins are never overwritten. Each entry may be a bare name, a name with an inline exact version, or a name with a semver range (for example, "react", "[email protected]", "zod@^3", "@radix-ui/react-dialog").

Required array length: 1 - 100 elements
Required string length: 1 - 200
Example:
branch
string

Branch name or UUID, 1-255 characters without surrounding whitespace. Omit for main; selected package.json receives the resolved pins.

Required string length: 1 - 255
Example:

"feature-a"

expected_declarations
object

Package declarations observed by the caller, at most 100 entries with string values up to 200 characters. A null value means the package was absent. When supplied, every requested package must be present and stale declarations are not overwritten.

Example:

Response

Dependency resolution result.

pins
object
required

Successfully resolved exact pins, including existing pins. Existing exact pins remain unchanged. Unknown packages and registry failures are omitted without failing the batch. A requested package absent from both pins and skipped was not resolved or written.

Example:
persisted
boolean
required

True when eligible pins were persisted or no eligible write was needed. False means persistence failed; pins retain intended values for retry.

skipped
object
required

Packages skipped because their current declaration differs from the supplied snapshot. The skip reason is declaration_changed.

Example: