Skip to main content
POST
/
api
/
v4
/
ppm
/
snippet
Render PPM Installation Snippet
curl --request POST \
  --url https://api.example.com/api/v4/ppm/snippet \
  --header 'Content-Type: application/json' \
  --header 'X-Domino-Api-Key: <api-key>' \
  --data '
{
  "biocVersion": "<string>",
  "constraints": "<string>",
  "repo": "<string>",
  "targetSnapshot": "<string>",
  "workspaceRepos": [
    {
      "baseUrl": "<string>",
      "currentSnapshot": "<string>",
      "fullUrl": "<string>",
      "repoName": "<string>"
    }
  ]
}
'
{
  "text": "<string>"
}

Authorizations

X-Domino-Api-Key
string
header
required

Body

application/json

Request to render a snippet

biocVersion
string

Bioconductor version for Bioconductor repositories (e.g., "3.19", "3.20"). If omitted, auto-discovers latest version

constraints
string

Comma-separated package constraints (e.g., "ggplot2==3.5.0,dplyr>=1.0.0,sf"). If omitted, generates snippet without specific packages

mode
enum<string>

Output mode for the snippet. "r" generates pure R code for direct execution in R console. "bash" wraps the R code in a Rscript command for bash execution. Defaults to "r" if omitted

Available options:
r,
bash
repo
string

Specific repository name filter (e.g., "cran", "bioconductor", "pypi"). If omitted, uses all enabled repos

repoType
enum<string>

Repository type filter. If omitted, uses all repository types

Available options:
R,
Bioconductor,
Python
targetSnapshot
string

Target snapshot date for the snippet generation. If omitted, uses latest

workspaceRepos
object[]

Array of workspace repositories from renv.lock. If provided, snippet generation is based on matching server repositories

Response

Success

text
string
required

The rendered Rscript command