- HTTP request
- Path parameters
- Query parameters
- Request body
- Response body
- Authorization scopes
- Try it!
Creates a new KeyRing in an instance. The server assigns the KeyRing ID.
The KeyPolicy is provided in keyRing.key_policy and is created together with the KeyRing.
Returns the following error codes:
- INVALID_ARGUMENT:
keyRing.key_policyis missing or malformed. For example, athresholdis out of range, aPolicyNodeis nested below the second level, or apolicyNodeIdis repeated. - FAILED_PRECONDITION: A Team or User referenced by the KeyPolicy does not exist in the instance, or a User in a
UserNodedoes not have theSIGNERrole.
HTTP request
POST https://mpc.googleapis.com/v1beta/{parent=projects/*/locations/*/instances/*}/keyRings
The URL uses gRPC Transcoding syntax.
Path parameters
| Parameters | |
|---|---|
parent |
Required. The parent instance where the KeyRing will be created. Format: projects/{project}/locations/{location}/instances/{instance} It takes the form |
Query parameters
| Parameters | |
|---|---|
requestId |
Optional. An idempotency key. Because KeyRing IDs are server-generated, a client must set this to retry a create safely. If a request with the same requestId was already completed, the server returns the KeyRing it created. Must be a UUID4 and not the zero UUID. |
Request body
The request body contains an instance of KeyRing.
Response body
If successful, the response body contains a newly created instance of KeyRing.
Authorization scopes
Requires the following OAuth scope:
https://www.googleapis.com/auth/cloud-platform
For more information, see the Authentication Overview.