Update Package Variables
Updates only the variables and secret_variables of the specified package.
Other package fields, including name, description, and data_flow_json,
are not touched even if sent in the request body.
Use this endpoint when you want to save variable changes without persisting
any unsaved canvas edits on the package. For full package updates, use
PUT /packages/{package_id} instead.
variables replaces the existing variables map. secret_variables is
merged into the existing secrets: a null value deletes that secret key,
and any other value adds or replaces it.
A secret value shorter than 6 characters, or a variable with an empty
name, returns 400. Sending null for the whole secret_variables
field, or a package that fails validation, returns 422.
Authorizations
Enter your API key as the username. Leave the password field blank.
Example: curl -u YOUR_API_KEY: https://api.xplenty.com/...
Headers
API version header — required on all requests
Path Parameters
The unique ID of the package
Body
Partial update payload for the variables-only endpoint. Only variables and
secret_variables are accepted; any other fields are ignored.
Package variables. Replaces the package's existing variables. Omit to leave them unchanged. Send {} to clear them.
Secret variables as key-value pairs, merged into the existing secrets. Values of DUMMY_KEY or masked values are ignored. A key with a null value deletes that secret. Any other value must be a string of at least 6 characters. Sending null for the whole field returns a 422 error.
Response
Package variables updated
Returned on create or update when the request referenced secret variables with placeholder values that the package has no value for. Set these secrets before running the package. Present only when at least one secret is missing.