Policy Resource Service Create
Create a Policy.
Request
URI
POST
https://{api_host}/https://your_org.tmc.cloud.vmware.com/v1alpha1/workspaces/{policy.fullName.workspaceName}/policies
COPY
Path Parameters
string
policy.fullName.workspaceName
Required
Name of the workspace.
Request Body
vmware.tanzu.manage.v1alpha1.workspace.policy.CreatePolicyRequest of type(s) application/json
Required
{
"policy": {
"type": {
"kind": "string",
"version": "string",
"package": "string"
},
"fullName": {
"orgId": "string",
"workspaceName": "string",
"name": "string"
},
"meta": {
"uid": "string",
"generation": "string",
"resourceVersion": "string",
"creationTime": "string",
"updateTime": "string",
"description": "string",
"parentReferences": [
{
"rid": "string",
"uid": "string"
}
]
},
"spec": {
"type": "string",
"recipe": "string",
"recipeVersion": "string",
"namespaceSelector": {
"matchExpressions": [
{
"key": "string",
"operator": "string",
"values": [
"string"
]
}
]
},
"resources": [
"string"
]
}
}
}
Responses
200
A successful response.
Returns vmware.tanzu.manage.v1alpha1.workspace.policy.CreatePolicyResponse of type(s) */*
{
"policy": {
"type": {
"kind": "string",
"version": "string",
"package": "string"
},
"fullName": {
"orgId": "string",
"workspaceName": "string",
"name": "string"
},
"meta": {
"uid": "string",
"generation": "string",
"resourceVersion": "string",
"creationTime": "string",
"updateTime": "string",
"description": "string",
"parentReferences": [
{
"rid": "string",
"uid": "string"
}
]
},
"spec": {
"type": "string",
"recipe": "string",
"recipeVersion": "string",
"namespaceSelector": {
"matchExpressions": [
{
"key": "string",
"operator": "string",
"values": [
"string"
]
}
]
},
"resources": [
"string"
]
}
}
}
default
An unexpected error response.
Returns grpc.gateway.runtime.Error of type(s) */*
{
"error": "string",
"code": 0,
"message": "string",
"details": [
{
"typeUrl": "string",
"value": "string"
}
]
}
Policy Resource Service Operations
POST
Policy Resource Service Create
POST
Policy Resource Service Create
POST
Policy Resource Service Create
POST
Policy Resource Service Create
DELETE
Policy Resource Service Delete
DELETE
Policy Resource Service Delete
DELETE
Policy Resource Service Delete
DELETE
Policy Resource Service Delete
GET
Policy Resource Service Get
GET
Policy Resource Service Get
GET
Policy Resource Service Get
GET
Policy Resource Service Get
GET
Policy Resource Service List
GET
Policy Resource Service List
GET
Policy Resource Service List
GET
Policy Resource Service List
PUT
Policy Resource Service Update
PUT
Policy Resource Service Update
PUT
Policy Resource Service Update
PUT
Policy Resource Service Update