plexus.dashboard.api.models.scorecard module
Scorecard Model - Python representation of the GraphQL Scorecard type.
Provides lookup methods to find scorecards by: - ID (direct lookup) - Key (using secondary index) - Name (using filter)
Each scorecard belongs to an account and contains sections with scores.
- class plexus.dashboard.api.models.scorecard.Scorecard(id: str, name: str, key: str, externalId: str, accountId: str, description: str | None = None, client: plexus.dashboard.api.client._BaseAPIClient | None = None)
Bases:
BaseModel
- __init__(id: str, name: str, key: str, externalId: str, accountId: str, description: str | None = None, client: _BaseAPIClient | None = None)
- accountId: str
- classmethod create(client: _BaseAPIClient, name: str, key: str, externalId: str, accountId: str, description: str | None = None) Scorecard
Create a new scorecard.
- Args:
client: The API client name: Name of the scorecard key: Unique key identifier externalId: External ID (usually from YAML) accountId: ID of the account this scorecard belongs to description: Optional description
- Returns:
The created Scorecard instance
- description: str | None = None
- externalId: str
- classmethod fields() str
Return the GraphQL fields to query for this model
- classmethod from_dict(data: Dict[str, Any], client: _BaseAPIClient) Scorecard
Create an instance from a dictionary of data
- key: str
- name: str