Create an API key rule.
Changed onCreate an API key rule.
Request
- Base URLhttps://api.cloudsmith.io
- Auth
- API key in header X-Api-Key
- or HTTP basic
Request body
When enabled, API keys that violate the organization's rule will be replaced automatically.
Whether this rule is currently active and enforced.
The maximum permitted age of an API key for use in the organization. API keys older than this will no longer have access until they are refreshed. To disable the rule unset this value.
If set to True, API keys that violate this rule will be replaced immediately after the request is made. There is no way to undo this.
Specify which account types this rule applies to: all accounts (deprecated — prefer separate service/user rules), service accounts only, or user accounts only.
Response
Created
When enabled, API keys that violate the organization's rule will be replaced automatically.
Whether this rule is currently active and enforced.
The last time this rule was evaluated and applied by the expiry task.
The maximum permitted age of an API key for use in the organization. API keys older than this will no longer have access until they are refreshed. To disable the rule unset this value.
Specify which account types this rule applies to: all accounts (deprecated — prefer separate service/user rules), service accounts only, or user accounts only.
Human-readable identifier for the rule type. Automatically generated based on the rule type.
An auto-generated id that uniquely identifies the rule.
Changes
- info
endpoint added
- info