curl --request POST \
--url https://api.veryfront.com/projects/{project_reference}/dependencies/resolve \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"specifiers": [
"styled-components",
"@radix-ui/react-dialog",
"[email protected]",
"zod@^3"
],
"branch": "feature-a",
"expected_declarations": {
"styled-components": "^6",
"got": null
}
}
'import requests
url = "https://api.veryfront.com/projects/{project_reference}/dependencies/resolve"
payload = {
"specifiers": ["styled-components", "@radix-ui/react-dialog", "[email protected]", "zod@^3"],
"branch": "feature-a",
"expected_declarations": {
"styled-components": "^6",
"got": None
}
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
specifiers: ['styled-components', '@radix-ui/react-dialog', '[email protected]', 'zod@^3'],
branch: 'feature-a',
expected_declarations: {'styled-components': '^6', got: null}
})
};
fetch('https://api.veryfront.com/projects/{project_reference}/dependencies/resolve', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.veryfront.com/projects/{project_reference}/dependencies/resolve",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'specifiers' => [
'styled-components',
'@radix-ui/react-dialog',
'[email protected]',
'zod@^3'
],
'branch' => 'feature-a',
'expected_declarations' => [
'styled-components' => '^6',
'got' => null
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.veryfront.com/projects/{project_reference}/dependencies/resolve"
payload := strings.NewReader("{\n \"specifiers\": [\n \"styled-components\",\n \"@radix-ui/react-dialog\",\n \"[email protected]\",\n \"zod@^3\"\n ],\n \"branch\": \"feature-a\",\n \"expected_declarations\": {\n \"styled-components\": \"^6\",\n \"got\": null\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.veryfront.com/projects/{project_reference}/dependencies/resolve")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"specifiers\": [\n \"styled-components\",\n \"@radix-ui/react-dialog\",\n \"[email protected]\",\n \"zod@^3\"\n ],\n \"branch\": \"feature-a\",\n \"expected_declarations\": {\n \"styled-components\": \"^6\",\n \"got\": null\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.veryfront.com/projects/{project_reference}/dependencies/resolve")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"specifiers\": [\n \"styled-components\",\n \"@radix-ui/react-dialog\",\n \"[email protected]\",\n \"zod@^3\"\n ],\n \"branch\": \"feature-a\",\n \"expected_declarations\": {\n \"styled-components\": \"^6\",\n \"got\": null\n }\n}"
response = http.request(request)
puts response.read_body{
"pins": {
"styled-components": "6.3.5",
"got": "12.6.1",
"zod": "3.23.8"
},
"persisted": true,
"skipped": {
"zod": "declaration_changed"
}
}{
"type": "https://api.veryfront.com/errors/validation-failed",
"title": "Validation Failed",
"status": 400,
"cause": "schedule_concurrency_forbidden",
"idempotency": {
"state": "in_progress",
"operation": "<string>",
"retryable": true,
"retry_after_seconds": 1,
"expires_at": "<string>",
"recovery": {
"available": true,
"description": "<string>",
"resource_url": "<string>"
}
},
"code": "RUN_INVALID_INPUT",
"detail": "The 'email' field must be a valid email address",
"instance": "/projects/my-project/members",
"slug": "validation-failed",
"category": "VALIDATION",
"suggestion": "Check the request body and query parameters against the API documentation.",
"errors": [
{
"field": "email",
"message": "Invalid email format",
"code": "INVALID_FORMAT"
}
]
}{
"type": "https://api.veryfront.com/errors/validation-failed",
"title": "Validation Failed",
"status": 400,
"cause": "schedule_concurrency_forbidden",
"idempotency": {
"state": "in_progress",
"operation": "<string>",
"retryable": true,
"retry_after_seconds": 1,
"expires_at": "<string>",
"recovery": {
"available": true,
"description": "<string>",
"resource_url": "<string>"
}
},
"code": "RUN_INVALID_INPUT",
"detail": "The 'email' field must be a valid email address",
"instance": "/projects/my-project/members",
"slug": "validation-failed",
"category": "VALIDATION",
"suggestion": "Check the request body and query parameters against the API documentation.",
"errors": [
{
"field": "email",
"message": "Invalid email format",
"code": "INVALID_FORMAT"
}
]
}{
"type": "https://api.veryfront.com/errors/validation-failed",
"title": "Validation Failed",
"status": 400,
"cause": "schedule_concurrency_forbidden",
"idempotency": {
"state": "in_progress",
"operation": "<string>",
"retryable": true,
"retry_after_seconds": 1,
"expires_at": "<string>",
"recovery": {
"available": true,
"description": "<string>",
"resource_url": "<string>"
}
},
"code": "RUN_INVALID_INPUT",
"detail": "The 'email' field must be a valid email address",
"instance": "/projects/my-project/members",
"slug": "validation-failed",
"category": "VALIDATION",
"suggestion": "Check the request body and query parameters against the API documentation.",
"errors": [
{
"field": "email",
"message": "Invalid email format",
"code": "INVALID_FORMAT"
}
]
}{
"type": "https://api.veryfront.com/errors/validation-failed",
"title": "Validation Failed",
"status": 400,
"cause": "schedule_concurrency_forbidden",
"idempotency": {
"state": "in_progress",
"operation": "<string>",
"retryable": true,
"retry_after_seconds": 1,
"expires_at": "<string>",
"recovery": {
"available": true,
"description": "<string>",
"resource_url": "<string>"
}
},
"code": "RUN_INVALID_INPUT",
"detail": "The 'email' field must be a valid email address",
"instance": "/projects/my-project/members",
"slug": "validation-failed",
"category": "VALIDATION",
"suggestion": "Check the request body and query parameters against the API documentation.",
"errors": [
{
"field": "email",
"message": "Invalid email format",
"code": "INVALID_FORMAT"
}
]
}{
"type": "https://api.veryfront.com/errors/validation-failed",
"title": "Validation Failed",
"status": 400,
"cause": "schedule_concurrency_forbidden",
"idempotency": {
"state": "in_progress",
"operation": "<string>",
"retryable": true,
"retry_after_seconds": 1,
"expires_at": "<string>",
"recovery": {
"available": true,
"description": "<string>",
"resource_url": "<string>"
}
},
"code": "RUN_INVALID_INPUT",
"detail": "The 'email' field must be a valid email address",
"instance": "/projects/my-project/members",
"slug": "validation-failed",
"category": "VALIDATION",
"suggestion": "Check the request body and query parameters against the API documentation.",
"errors": [
{
"field": "email",
"message": "Invalid email format",
"code": "INVALID_FORMAT"
}
]
}Resolve and pin dependencies
Resolve dependency pins. Requires project.files.write.
curl --request POST \
--url https://api.veryfront.com/projects/{project_reference}/dependencies/resolve \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"specifiers": [
"styled-components",
"@radix-ui/react-dialog",
"[email protected]",
"zod@^3"
],
"branch": "feature-a",
"expected_declarations": {
"styled-components": "^6",
"got": null
}
}
'import requests
url = "https://api.veryfront.com/projects/{project_reference}/dependencies/resolve"
payload = {
"specifiers": ["styled-components", "@radix-ui/react-dialog", "[email protected]", "zod@^3"],
"branch": "feature-a",
"expected_declarations": {
"styled-components": "^6",
"got": None
}
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
specifiers: ['styled-components', '@radix-ui/react-dialog', '[email protected]', 'zod@^3'],
branch: 'feature-a',
expected_declarations: {'styled-components': '^6', got: null}
})
};
fetch('https://api.veryfront.com/projects/{project_reference}/dependencies/resolve', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.veryfront.com/projects/{project_reference}/dependencies/resolve",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'specifiers' => [
'styled-components',
'@radix-ui/react-dialog',
'[email protected]',
'zod@^3'
],
'branch' => 'feature-a',
'expected_declarations' => [
'styled-components' => '^6',
'got' => null
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.veryfront.com/projects/{project_reference}/dependencies/resolve"
payload := strings.NewReader("{\n \"specifiers\": [\n \"styled-components\",\n \"@radix-ui/react-dialog\",\n \"[email protected]\",\n \"zod@^3\"\n ],\n \"branch\": \"feature-a\",\n \"expected_declarations\": {\n \"styled-components\": \"^6\",\n \"got\": null\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.veryfront.com/projects/{project_reference}/dependencies/resolve")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"specifiers\": [\n \"styled-components\",\n \"@radix-ui/react-dialog\",\n \"[email protected]\",\n \"zod@^3\"\n ],\n \"branch\": \"feature-a\",\n \"expected_declarations\": {\n \"styled-components\": \"^6\",\n \"got\": null\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.veryfront.com/projects/{project_reference}/dependencies/resolve")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"specifiers\": [\n \"styled-components\",\n \"@radix-ui/react-dialog\",\n \"[email protected]\",\n \"zod@^3\"\n ],\n \"branch\": \"feature-a\",\n \"expected_declarations\": {\n \"styled-components\": \"^6\",\n \"got\": null\n }\n}"
response = http.request(request)
puts response.read_body{
"pins": {
"styled-components": "6.3.5",
"got": "12.6.1",
"zod": "3.23.8"
},
"persisted": true,
"skipped": {
"zod": "declaration_changed"
}
}{
"type": "https://api.veryfront.com/errors/validation-failed",
"title": "Validation Failed",
"status": 400,
"cause": "schedule_concurrency_forbidden",
"idempotency": {
"state": "in_progress",
"operation": "<string>",
"retryable": true,
"retry_after_seconds": 1,
"expires_at": "<string>",
"recovery": {
"available": true,
"description": "<string>",
"resource_url": "<string>"
}
},
"code": "RUN_INVALID_INPUT",
"detail": "The 'email' field must be a valid email address",
"instance": "/projects/my-project/members",
"slug": "validation-failed",
"category": "VALIDATION",
"suggestion": "Check the request body and query parameters against the API documentation.",
"errors": [
{
"field": "email",
"message": "Invalid email format",
"code": "INVALID_FORMAT"
}
]
}{
"type": "https://api.veryfront.com/errors/validation-failed",
"title": "Validation Failed",
"status": 400,
"cause": "schedule_concurrency_forbidden",
"idempotency": {
"state": "in_progress",
"operation": "<string>",
"retryable": true,
"retry_after_seconds": 1,
"expires_at": "<string>",
"recovery": {
"available": true,
"description": "<string>",
"resource_url": "<string>"
}
},
"code": "RUN_INVALID_INPUT",
"detail": "The 'email' field must be a valid email address",
"instance": "/projects/my-project/members",
"slug": "validation-failed",
"category": "VALIDATION",
"suggestion": "Check the request body and query parameters against the API documentation.",
"errors": [
{
"field": "email",
"message": "Invalid email format",
"code": "INVALID_FORMAT"
}
]
}{
"type": "https://api.veryfront.com/errors/validation-failed",
"title": "Validation Failed",
"status": 400,
"cause": "schedule_concurrency_forbidden",
"idempotency": {
"state": "in_progress",
"operation": "<string>",
"retryable": true,
"retry_after_seconds": 1,
"expires_at": "<string>",
"recovery": {
"available": true,
"description": "<string>",
"resource_url": "<string>"
}
},
"code": "RUN_INVALID_INPUT",
"detail": "The 'email' field must be a valid email address",
"instance": "/projects/my-project/members",
"slug": "validation-failed",
"category": "VALIDATION",
"suggestion": "Check the request body and query parameters against the API documentation.",
"errors": [
{
"field": "email",
"message": "Invalid email format",
"code": "INVALID_FORMAT"
}
]
}{
"type": "https://api.veryfront.com/errors/validation-failed",
"title": "Validation Failed",
"status": 400,
"cause": "schedule_concurrency_forbidden",
"idempotency": {
"state": "in_progress",
"operation": "<string>",
"retryable": true,
"retry_after_seconds": 1,
"expires_at": "<string>",
"recovery": {
"available": true,
"description": "<string>",
"resource_url": "<string>"
}
},
"code": "RUN_INVALID_INPUT",
"detail": "The 'email' field must be a valid email address",
"instance": "/projects/my-project/members",
"slug": "validation-failed",
"category": "VALIDATION",
"suggestion": "Check the request body and query parameters against the API documentation.",
"errors": [
{
"field": "email",
"message": "Invalid email format",
"code": "INVALID_FORMAT"
}
]
}{
"type": "https://api.veryfront.com/errors/validation-failed",
"title": "Validation Failed",
"status": 400,
"cause": "schedule_concurrency_forbidden",
"idempotency": {
"state": "in_progress",
"operation": "<string>",
"retryable": true,
"retry_after_seconds": 1,
"expires_at": "<string>",
"recovery": {
"available": true,
"description": "<string>",
"resource_url": "<string>"
}
},
"code": "RUN_INVALID_INPUT",
"detail": "The 'email' field must be a valid email address",
"instance": "/projects/my-project/members",
"slug": "validation-failed",
"category": "VALIDATION",
"suggestion": "Check the request body and query parameters against the API documentation.",
"errors": [
{
"field": "email",
"message": "Invalid email format",
"code": "INVALID_FORMAT"
}
]
}Authorizations
Use a JWT bearer token or a Veryfront API key in the Authorization header.
Path Parameters
Project UUID or slug, or the project domain.
Body
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").
1 - 100 elements1 - 200[
"styled-components",
"@radix-ui/react-dialog",
"[email protected]",
"zod@^3"
]
Branch name or UUID, 1-255 characters without surrounding whitespace. Omit for main; selected package.json receives the resolved pins.
1 - 255"feature-a"
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.
Show child attributes
Show child attributes
{ "styled-components": "^6", "got": null }
Response
Dependency resolution result.
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.
Show child attributes
Show child attributes
{
"styled-components": "6.3.5",
"got": "12.6.1",
"zod": "3.23.8"
}
True when eligible pins were persisted or no eligible write was needed. False means persistence failed; pins retain intended values for retry.
Packages skipped because their current declaration differs from the supplied snapshot. The skip reason is declaration_changed.
Show child attributes
Show child attributes
{ "zod": "declaration_changed" }