latestOpenAPI 3.0.32026-08-182,281012.1 MB

e2a4b9a05251

Secret Validation Rules

Update Secret Validation Rule

patch/api/v1/projects/{projectId}/secret-validation-rules/{ruleId}

Path parameters

projectIdstring required

The ID of the project the secret validation rule belongs to.

ruleIdstring uuid required

The ID of the secret validation rule to update.

Request body

namestring

The name of the secret validation rule.

descriptionstring nullable

An optional description of the secret validation rule.

environmentSlugstring nullable

The slug of the environment this rule is scoped to. Omit to leave the current scope unchanged; pass null to make the rule apply to every environment in the project.

secretPathstring

The secret path this rule is scoped to.

isActiveboolean

Whether the secret validation rule is active.

Example request

{
  "rule": {
    "constraints": [
      {
        "type": "min-length",
        "appliesTo": "value",
        "value": "8"
      }
    ]
  }
}

Response

Default Response

Example response

{
  "rule": {
    "constraints": [
      {
        "type": "min-length",
        "appliesTo": "value",
        "value": "8"
      }
    ]
  }
}