Organizations
PolicyPacks

CreatePolicyPack

Creates a new Policy Pack for an organization. A Policy Pack is a versioned collection of related policies that validate infrastructure configuration during deployments. Policies can enforce rules such as requiring encryption on storage buckets or prohibiting public access to databases. The pack must contain at least one policy. Once created, the pack can be applied to Policy Groups to enforce rules on specific stacks with configurable enforcement levels (advisory, mandatory, or disabled).

post/api/orgs/{orgName}/policypacks

Request

  • Base URL: https://api.pulumi.com (the document declares no server; this is the origin it was published from)
  • URL: https://api.pulumi.com/api/orgs/{orgName}/policypacks
  • Auth: none declared

Path parameters

orgNamestring required

The organization name

Request body

descriptionstring

A brief description of the policy pack.

displayNamestring required

A pretty name for the Policy Pack that is supplied by the package.

metadataobject

Metadata contains optional data about the environment performing the publish operation, e.g. the current source code control commit information.

namestring required

Name is a unique URL-safe identifier (at the org level) for the package. If the name has already been used by the organization, then the request will create a new version of the Policy Pack (incremented by one). This is supplied by the CLI.

providerstring

The cloud provider/platform this policy pack is associated with, e.g. AWS, Azure, etc.

readmestring

README text about the policy pack.

repositorystring

A URL to the repository where the policy pack is defined.

runtimestring

Analyzer SDK runtime that produced the pack (e.g. "nodejs", "python", "opa"). When both the existing pack and the incoming request specify a runtime, publishing a new version with a different runtime is rejected to avoid overwriting behavior. If either side is omitted (older CLIs that do not report a runtime, or packs published before this field existed), the runtime check is skipped.

tagsstring[]

Tags for this policy pack.

versionTagstring

VersionTag is the semantic version of the Policy Pack. One a version is published, it cannot never be republished. Older clients will not have a version tag.

Response

Created

requiredHeadersobject

RequiredHeaders represents headers that the CLI must set in order for the upload to succeed.

uploadURIstring required

The upload URI

versioninteger required

The version number

Changes

No recorded changes to this operation across all 1 revision of this API.