Rivier/ Reference/ hosting

Set a variable on a Next site

put/hosting/sites/{id}/env

Set a variable on a Next site. The value is sealed and delivered to the running site only.

Before you call

Credential
Authorization: Bearer $KEY
Scope
hosting:write
Graphql
Mutation.hostingEnvSet
Sdk
hosting.env.set
Cli
hosting env set

Parameters

  • idstring (uuid)required
    In the path

Request bodyapplication/json, required

  • namestringrequired
    At most 64 characters.
  • valuestringrequired
    At most 8192 characters.
  • scopestring
    One of: production, preview, all.

Responses

  • 200application/json
    Success
    • namestringrequired
    • scopestringrequired
      One of: production, preview, all.
  • 400application/json
    The request was malformed
    • errorstringrequired
    • messagestring
  • 401application/json
    No valid credential
    • errorstringrequired
    • messagestring
  • 403application/json
    The credential lacks the scope, origin or address
    • errorstringrequired
    • messagestring
  • 429application/json
    Over the key's rate limit; see Retry-After
    • errorstringrequired
    • messagestring

This page as Markdown