v29

latestOpenAPI 3.0.3Apache 2.0raw.githubusercontent.com2026-08-063044104.9 KB
policies

Update an existing policy

Updates an existing MaaSAuthPolicy resource. K8s calls: PUT /k8s/v1/maasauthpolicy/:name

put/api/v1/update-policy/{name}

Path parameters

namestring required

Name of the MaaSAuthPolicy to update

Request body

displayNamestring

Human-readable display name (stored as openshift.io/display-name annotation)

descriptionstring

Description of the policy (stored as openshift.io/description annotation)

Example request

{
  "modelRefs": [
    {
      "name": "llama-2-7b-chat",
      "namespace": "maas-models"
    }
  ],
  "subjects": {
    "groups": [
      {
        "name": "premium-users"
      }
    ]
  },
  "meteringMetadata": {
    "organizationId": "org-123",
    "costCenter": "engineering"
  }
}

Response

Policy updated successfully

namestring required

Name of the MaaSAuthPolicy resource

namespacestring required

Namespace of the MaaSAuthPolicy resource

displayNamestring

Human-readable display name for the policy

descriptionstring

Description of the policy

phase'Pending' | 'Active' | 'Failed'

Current phase of the auth policy (from status)

statusMessagestring

Human-readable status message from the Ready condition in status.conditions

reasonstring

Reason from the Ready condition in status.conditions

statusstring

Status from the Ready condition in status.conditions (e.g. True, False, Unknown)

conditionTypestring

Condition type from the Ready condition in status.conditions

lastTransitionTimestring date-time

lastTransitionTime from the Ready condition in status.conditions

creationTimestampstring date-time

Timestamp when the policy was created

deletionTimestampstring date-time

When set, the policy is marked for deletion (Kubernetes metadata.deletionTimestamp)

Example response

{
  "name": "premium-team-sub-policy",
  "namespace": "maas-system",
  "displayName": "Premium Team Policy",
  "description": "High-priority access policy for the premium team.",
  "phase": "Active",
  "statusMessage": "successfully reconciled",
  "reason": "Reconciled",
  "status": "True",
  "conditionType": "Ready",
  "lastTransitionTime": "2026-01-01T00:00:00Z",
  "creationTimestamp": "2025-03-01T10:00:00Z",
  "modelRefs": [
    {
      "name": "llama-2-7b-chat",
      "namespace": "maas-models"
    }
  ],
  "subjects": {
    "groups": [
      {
        "name": "premium-users"
      }
    ]
  },
  "meteringMetadata": {
    "organizationId": "org-123",
    "costCenter": "engineering"
  }
}