---
title: "Get subscription and policy form data"
method: GET
path: "/api/v1/subscription-policy-form-data"
tags: ["general"]
---

# Get subscription and policy form data

`GET /api/v1/subscription-policy-form-data`

Returns the data needed to populate subscription and policy creation forms, including available groups, MaaSModelRef resources, existing policies, and existing subscriptions.
K8s calls: GET /k8s/v1/groups, GET /k8s/v1/maasmodelref, GET /k8s/v1/maasauthpolicy, GET /k8s/v1/maassubscription

## Response `200`

Form data for creating a new policy

- SubscriptionFormDataResponse — Data needed to populate subscription and policy creation/edit forms
  - `groups` string[], required — Available Kubernetes groups
  - `modelRefs` MaaSModelRefSummary[], required — Available MaaSModelRef resources that can be added to a subscription or policy
    - `name` string, required — Name of the MaaSModelRef resource
    - `namespace` string, required — Namespace of the MaaSModelRef resource
    - `displayName` string — Human-readable display name (from openshift.io/display-name annotation)
    - `description` string — Optional description of the model (from openshift.io/description annotation)
    - `modelRef` ModelReference, required — Reference to a model endpoint
      - `kind` 'LLMInferenceService' | 'ExternalModel', required — Kind of the model resource
      - `name` string, required — Name of the model resource
    - `phase` 'Pending' | 'Ready' | 'Unhealthy' | 'Failed' — Current phase of the model (from status)
    - `statusMessage` string — Human-readable status message from the Ready condition in status.conditions
    - `reason` string — Reason from the Ready condition in status.conditions
    - `status` string — Status from the Ready condition in status.conditions (e.g. True, False, Unknown)
    - `conditionType` string — Condition type from the Ready condition in status.conditions
    - `lastTransitionTime` string, date-time — lastTransitionTime from the Ready condition in status.conditions
    - `endpoint` string — Endpoint URL for the model (from status)
    - `modelCapabilities` string[] — Model capability tags from the opendatahub.io/model-capabilities annotation (e.g. text-generation, vision). Absent when the annotation was not set.
  - `policies` MaaSAuthPolicy[] — Available MaaSAuthPolicy resources
    - `name` string, required — Name of the MaaSAuthPolicy resource
    - `namespace` string, required — Namespace of the MaaSAuthPolicy resource
    - `displayName` string — Human-readable display name for the policy
    - `description` string — Description of the policy
    - `phase` 'Pending' | 'Active' | 'Failed' — Current phase of the auth policy (from status)
    - `statusMessage` string — Human-readable status message from the Ready condition in status.conditions
    - `reason` string — Reason from the Ready condition in status.conditions
    - `status` string — Status from the Ready condition in status.conditions (e.g. True, False, Unknown)
    - `conditionType` string — Condition type from the Ready condition in status.conditions
    - `lastTransitionTime` string, date-time — lastTransitionTime from the Ready condition in status.conditions
    - `creationTimestamp` string, date-time — Timestamp when the policy was created
    - `modelRefs` ModelRef[], required — Models this policy grants access to
      - `name` string, required — Name of the MaaSModelRef
      - `namespace` string, required — Namespace where the MaaSModelRef lives
    - `subjects` SubjectSpec, required — Defines subjects (groups) that have access
      - `groups` GroupReference[] — Kubernetes group names
        - `name` string, required — Name of the Kubernetes group
    - `meteringMetadata` TokenMetadata — Metadata for token usage attribution and metering
      - `organizationId` string — Organization identifier for metering and billing
      - `costCenter` string — Cost center for usage attribution
      - `labels` object — Additional labels for tracking and metrics
    - `deletionTimestamp` string, date-time — When set, the policy is marked for deletion (Kubernetes metadata.deletionTimestamp)
  - `subscriptions` MaaSSubscription[], required — Available MaaSSubscription resources
    - `name` string, required — Name of the MaaSSubscription resource (metadata.name)
    - `displayName` string — Display name for the subscription (from openshift.io/display-name annotation)
    - `description` string — Description of the subscription (from openshift.io/description annotation)
    - `namespace` string, required — Namespace of the MaaSSubscription resource
    - `phase` 'Pending' | 'Active' | 'Failed' — Current phase of the subscription (from status)
    - `statusMessage` string — Human-readable status message from the Ready condition in status.conditions
    - `reason` string — Reason from the Ready condition in status.conditions
    - `status` string — Status from the Ready condition in status.conditions (e.g. True, False, Unknown)
    - `conditionType` string — Condition type from the Ready condition in status.conditions
    - `lastTransitionTime` string, date-time — lastTransitionTime from the Ready condition in status.conditions
    - `priority` integer — Subscription priority (higher = higher priority)
    - `owner` OwnerSpec, required — Defines who owns a subscription
      - `groups` GroupReference[] — Kubernetes group names that own this subscription
        - `name` string, required — Name of the Kubernetes group
    - `modelRefs` ModelSubscriptionRef[], required — Models included in this subscription with per-model rate limits
      - `name` string, required — Name of the MaaSModelRef
      - `namespace` string, required — Namespace where the MaaSModelRef lives
      - `tokenRateLimits` TokenRateLimit[] — Token-based rate limits for this model
        - `limit` integer, required — Maximum number of tokens allowed
        - `window` string, required — Time window (e.g., "1m", "1h", "24h")
      - `billingRate` BillingRate — Billing information for a model
        - `perToken` string, required — Cost per token
    - `tokenMetadata` TokenMetadata — Metadata for token usage attribution and metering
      - `organizationId` string — Organization identifier for metering and billing
      - `costCenter` string — Cost center for usage attribution
      - `labels` object — Additional labels for tracking and metrics
    - `creationTimestamp` string, date-time — When the resource was created
    - `deletionTimestamp` string, date-time — When set, the subscription is marked for deletion (Kubernetes metadata.deletionTimestamp)

## Other responses

- `401` — Unauthorized
- `500` — Internal Server Error

---

[API](https://skmtc.net/opendatahub-io/apis/maas-bff-api.md) · [All operations](https://skmtc.net/opendatahub-io/apis/maas-bff-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/opendatahub-io/maas-bff-api/revisions/9112415ceeca/schema)
