@burdenoff/microfe-govcitizenhub 2026.730.2 → 2026.730.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1 +1 @@
1
- {"version":3,"file":"intelligence.js","names":[],"sources":["../../../src/govcitizenhub/types/intelligence.ts"],"sourcesContent":["/**\n * GovCitizenHub — Community Intelligence type definitions (BOFF-5666)\n *\n * Every type below mirrors the FROZEN `wspace-govcitizenhub-svc` `intelligence`\n * module SDL byte-for-byte:\n * src/modules/intelligence/schema/{010-enums,020-jurisdiction,030-governance,\n * 040-finance,050-indicators,060-participation}.gql\n *\n * Conventions inherited from `./index.ts`:\n * - GraphQL enums become string-union types.\n * - `DateTime` is serialised as an ISO string.\n * - Nullable SDL fields are `| null`; fields that are only selected by a\n * *detail* query (relations, nested lists) are marked optional so a list\n * query's narrower selection still type-checks.\n * - `GovConnection<T>` is reused from `./index.ts` — never redefined.\n * - `User` / `File` are id-only federation stubs: file references are carried\n * as opaque `*FileId` strings and resolved through the `useFiles` hook.\n *\n * COUNTRY-AGNOSTIC: nothing here encodes one country's administrative tiers,\n * fiscal calendar or currency. Tiers are `GovAdminLevel` rows keyed by ISO\n * 3166-1 alpha-2; money carries an ISO 4217 `currencyCode` per record.\n *\n * @module govcitizenhub/types/intelligence\n */\n\nimport type { GovConnection, GovJson, GovServiceCategory, GovTrendDirection } from './index';\n\n// ============================================================================\n// Enums (010-enums.gql)\n// ============================================================================\n\n/** Publication lifecycle of a jurisdiction profile. DRAFT is never citizen-visible. */\nexport type GovJurisdictionStatus = 'DRAFT' | 'PUBLISHED' | 'ARCHIVED';\n\n/** Provenance grade of a published civic fact. */\nexport type GovVerificationStatus = 'UNVERIFIED' | 'OFFICIAL' | 'COMMUNITY_VERIFIED' | 'DISPUTED';\n\n/** Nature of an office holder's appointment. */\nexport type GovOfficeType = 'ELECTED' | 'ADMINISTRATIVE' | 'JUDICIAL' | 'ADVISORY';\n\n/** Delivery state of a public promise made by an office holder. */\nexport type GovCommitmentStatus =\n 'PROMISED' | 'IN_PROGRESS' | 'DELIVERED' | 'STALLED' | 'ABANDONED';\n\n/** Approval lifecycle of a published budget. */\nexport type GovBudgetStatus = 'DRAFT' | 'PROPOSED' | 'APPROVED' | 'REVISED' | 'CLOSED';\n\n/** Which side of the ledger a budget line sits on. */\nexport type GovBudgetLineKind = 'REVENUE' | 'EXPENSE';\n\n/**\n * Budget classification. `TAXES`..`OTHER_REVENUE` are revenue-side;\n * `EDUCATION`..`OTHER_EXPENSE` are expense-side. The backend rejects a category\n * that does not match its line's `kind` — see `GOV_REVENUE_CATEGORIES` /\n * `GOV_EXPENSE_CATEGORIES` for the same split.\n */\nexport type GovBudgetCategory =\n | 'TAXES'\n | 'FEES_AND_CHARGES'\n | 'GRANTS'\n | 'INTERGOVERNMENTAL_TRANSFERS'\n | 'LOANS'\n | 'INTERNATIONAL_AID'\n | 'PUBLIC_PRIVATE_PARTNERSHIP'\n | 'ASSET_SALES'\n | 'OTHER_REVENUE'\n | 'EDUCATION'\n | 'HEALTHCARE'\n | 'ROADS_AND_TRANSPORT'\n | 'WATER_AND_SANITATION'\n | 'ENERGY'\n | 'AGRICULTURE'\n | 'ENVIRONMENT'\n | 'PUBLIC_SAFETY'\n | 'SOCIAL_WELFARE'\n | 'HOUSING'\n | 'DIGITAL_INFRASTRUCTURE'\n | 'CULTURE_AND_RECREATION'\n | 'ADMINISTRATION'\n | 'DEBT_SERVICE'\n | 'CAPITAL_PROJECTS'\n | 'OTHER_EXPENSE';\n\n/** Where a development project's money comes from. */\nexport type GovFundingSource =\n | 'LOCAL_REVENUE'\n | 'STATE_GRANT'\n | 'NATIONAL_GRANT'\n | 'LOAN'\n | 'INTERNATIONAL_AID'\n | 'PUBLIC_PRIVATE_PARTNERSHIP'\n | 'CSR'\n | 'OTHER';\n\n/** Delivery lifecycle of a development project. */\nexport type GovProjectStatus =\n 'PLANNED' | 'TENDERED' | 'AWARDED' | 'IN_PROGRESS' | 'SUSPENDED' | 'COMPLETED' | 'CANCELLED';\n\n/** Delivery state of a project milestone. */\nexport type GovMilestoneStatus = 'PENDING' | 'IN_PROGRESS' | 'COMPLETED' | 'DELAYED' | 'CANCELLED';\n\n/** Sector taxonomy shared by indicators, projects and datasets. */\nexport type GovIndicatorDomain =\n | 'DEMOGRAPHICS'\n | 'ECONOMY'\n | 'EDUCATION'\n | 'HEALTHCARE'\n | 'INFRASTRUCTURE'\n | 'PUBLIC_SAFETY'\n | 'ENVIRONMENT'\n | 'SOCIAL_WELFARE'\n | 'UTILITIES'\n | 'TRANSPORT'\n | 'HOUSING'\n | 'GOVERNANCE'\n | 'DIGITAL'\n | 'TOURISM'\n | 'FINANCE';\n\n/** How an indicator's value should be read and formatted. */\nexport type GovIndicatorValueType =\n 'NUMBER' | 'PERCENTAGE' | 'RATIO' | 'CURRENCY' | 'INDEX' | 'COUNT' | 'DURATION_DAYS';\n\n/** Whether a rising value is good, bad or neutral. */\nexport type GovIndicatorDirection = 'HIGHER_IS_BETTER' | 'LOWER_IS_BETTER' | 'NEUTRAL';\n\n/** How often an indicator or dataset is expected to be refreshed. */\nexport type GovIndicatorPeriodicity =\n 'ANNUAL' | 'QUARTERLY' | 'MONTHLY' | 'WEEKLY' | 'DAILY' | 'ADHOC';\n\n/** Category of a mapped public asset, facility, organisation or landmark. */\nexport type GovAssetCategory =\n | 'SCHOOL'\n | 'UNIVERSITY'\n | 'LIBRARY'\n | 'HOSPITAL'\n | 'CLINIC'\n | 'PHARMACY'\n | 'POLICE_STATION'\n | 'FIRE_STATION'\n | 'EMERGENCY_SHELTER'\n | 'WATER_FACILITY'\n | 'POWER_FACILITY'\n | 'WASTE_FACILITY'\n | 'TRANSIT_STOP'\n | 'TRANSIT_STATION'\n | 'AIRPORT'\n | 'PORT'\n | 'BRIDGE'\n | 'PARK'\n | 'SPORTS_FACILITY'\n | 'COMMUNITY_CENTER'\n | 'GOVERNMENT_OFFICE'\n | 'PUBLIC_TOILET'\n | 'PARKING'\n | 'EV_CHARGING'\n | 'MARKET'\n | 'NGO'\n | 'BUSINESS'\n | 'LANDMARK'\n | 'MUSEUM'\n | 'OTHER';\n\n/** Who runs a public asset. */\nexport type GovAssetOperator = 'PUBLIC' | 'PRIVATE' | 'PUBLIC_PRIVATE' | 'NGO' | 'UNKNOWN';\n\n/** Operational state of a public asset. */\nexport type GovAssetStatus =\n 'OPERATIONAL' | 'UNDER_CONSTRUCTION' | 'UNDER_MAINTENANCE' | 'CLOSED' | 'PLANNED';\n\n/** Kind of electoral event. */\nexport type GovElectionType =\n 'GENERAL' | 'LOCAL' | 'BY_ELECTION' | 'REFERENDUM' | 'PRIMARY' | 'OTHER';\n\n/** Lifecycle of an electoral event. */\nexport type GovElectionStatus = 'SCHEDULED' | 'IN_PROGRESS' | 'COUNTING' | 'DECLARED' | 'CANCELLED';\n\n/** Kind of public participation exercise. */\nexport type GovConsultationType =\n 'SURVEY' | 'POLL' | 'PARTICIPATORY_BUDGET' | 'PUBLIC_HEARING' | 'FEEDBACK';\n\n/** Lifecycle of a consultation. Responses are only accepted while OPEN. */\nexport type GovConsultationStatus = 'DRAFT' | 'OPEN' | 'CLOSED' | 'PUBLISHED' | 'CANCELLED';\n\n/** Coarse sentiment recorded against a consultation response. */\nexport type GovSentiment = 'POSITIVE' | 'NEUTRAL' | 'NEGATIVE';\n\n/** Distribution format of an open-data dataset. */\nexport type GovDatasetFormat = 'CSV' | 'JSON' | 'GEOJSON' | 'XLSX' | 'PDF' | 'XML' | 'API';\n\n/** Open-data licence a dataset is released under. */\nexport type GovDataLicense =\n 'CC0' | 'CC_BY' | 'CC_BY_SA' | 'ODBL' | 'OGL' | 'PUBLIC_DOMAIN' | 'PROPRIETARY' | 'OTHER';\n\n/** Publication lifecycle of a dataset. */\nexport type GovDatasetStatus = 'DRAFT' | 'PUBLISHED' | 'DEPRECATED' | 'ARCHIVED';\n\n/** Category of a historical timeline entry. */\nexport type GovEventCategory =\n | 'POLICY'\n | 'PROJECT'\n | 'ELECTION'\n | 'DISASTER'\n | 'INFRASTRUCTURE'\n | 'DEMOGRAPHIC'\n | 'BUDGET'\n | 'AWARD'\n | 'OTHER';\n\n/** Whether a timeline entry was good, bad or neutral for the region. */\nexport type GovEventImpact = 'POSITIVE' | 'NEUTRAL' | 'NEGATIVE';\n\n/** Which Community Intelligence record a data-change proposal targets. */\nexport type GovIntelEntityType =\n | 'JURISDICTION'\n | 'OFFICIAL'\n | 'OFFICIAL_COMMITMENT'\n | 'BUDGET'\n | 'BUDGET_LINE'\n | 'PROJECT'\n | 'PROJECT_MILESTONE'\n | 'INDICATOR_VALUE'\n | 'PUBLIC_ASSET'\n | 'ELECTION'\n | 'ELECTION_RESULT'\n | 'DATASET'\n | 'EVENT';\n\n/** Review lifecycle of a proposed data correction. */\nexport type GovProposalStatus =\n 'SUBMITTED' | 'UNDER_REVIEW' | 'ACCEPTED' | 'REJECTED' | 'WITHDRAWN';\n\n/** Which peer set a jurisdiction is benchmarked against. */\nexport type GovBenchmarkScope =\n 'SIBLINGS' | 'CHILDREN' | 'PARENT_AVERAGE' | 'SAME_LEVEL_NATIONAL' | 'CUSTOM';\n\n/** Kind of deterministically derived insight surfaced on a jurisdiction profile. */\nexport type GovInsightKind =\n 'STRENGTH' | 'WEAKNESS' | 'EMERGING_ISSUE' | 'ANOMALY' | 'IMPROVEMENT' | 'RISK' | 'COVERAGE_GAP';\n\n/** How loudly an insight should be surfaced. */\nexport type GovInsightSeverity = 'INFO' | 'LOW' | 'MEDIUM' | 'HIGH';\n\n// ============================================================================\n// Administrative hierarchy & jurisdiction profile (020-jurisdiction.gql)\n// ============================================================================\n\n/** One configurable tier of a country's administrative hierarchy (rank 0 = national). */\nexport interface GovAdminLevel {\n id: string;\n workspaceId: string;\n /** ISO 3166-1 alpha-2 country code this tier belongs to. */\n countryCode: string;\n /** Depth of the tier: 0 is the national level, ascending downward. */\n rank: number;\n /** Stable machine code, unique per country (e.g. STATE, DISTRICT, WARD). */\n code: string;\n name: string;\n pluralName: string;\n description?: string | null;\n /** True when the tier elects representatives. */\n isElectoral: boolean;\n createdAt: string;\n updatedAt: string;\n /** Published + draft jurisdictions currently sitting at this tier. */\n jurisdictionCount: number;\n}\n\n/** The permanent digital profile of one administrative region. */\nexport interface GovJurisdiction {\n id: string;\n workspaceId: string;\n parentId?: string | null;\n adminLevelId: string;\n countryCode: string;\n\n name: string;\n localName?: string | null;\n officialCode?: string | null;\n slug: string;\n status: GovJurisdictionStatus;\n /** Materialized ancestor path, `/<id>/<id>/`. */\n path: string;\n depth: number;\n\n summary?: string | null;\n establishedOn?: string | null;\n headquarters?: string | null;\n officialWebsite?: string | null;\n contactEmail?: string | null;\n contactPhone?: string | null;\n /** Public emergency contacts: `[{ label, number }]`. */\n emergencyNumbers?: GovJson;\n timezone?: string | null;\n languages: string[];\n /** ISO 4217 currency code used by this region. */\n currencyCode?: string | null;\n climateSummary?: string | null;\n\n areaSqKm?: number | null;\n population?: number | null;\n populationYear?: number | null;\n households?: number | null;\n centroidLat?: number | null;\n centroidLng?: number | null;\n /** Population per square kilometre, derived when both inputs are published. */\n populationDensity?: number | null;\n\n /** wspace-files-svc File id holding the boundary GeoJSON. */\n boundaryFileId?: string | null;\n bannerFileId?: string | null;\n crestFileId?: string | null;\n\n tags: string[];\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification: GovVerificationStatus;\n publishedAt?: string | null;\n createdAt: string;\n updatedAt: string;\n\n adminLevel?: GovAdminLevel | null;\n parent?: GovJurisdiction | null;\n children?: GovJurisdiction[];\n /** Ancestors ordered from the root down to the immediate parent. */\n ancestors?: GovJurisdiction[];\n}\n\n/** A node in the administrative hierarchy tree, with its children inlined. */\nexport interface GovJurisdictionTreeNode {\n id: string;\n name: string;\n slug: string;\n status: GovJurisdictionStatus;\n depth: number;\n adminLevelCode: string;\n adminLevelName: string;\n population?: number | null;\n childCount: number;\n children: GovJurisdictionTreeNode[];\n}\n\n/** Single page-load aggregate for the jurisdiction profile screen. */\nexport interface GovJurisdictionOverview {\n jurisdiction: GovJurisdiction;\n adminLevel?: GovAdminLevel | null;\n parent?: GovJurisdiction | null;\n childCount: number;\n officialCount: number;\n currentBudget?: GovBudget | null;\n activeProjectCount: number;\n completedProjectCount: number;\n publishedDatasetCount: number;\n openConsultationCount: number;\n publicAssetCount: number;\n followerCount: number;\n /** Whether the calling actor follows this jurisdiction. */\n isFollowedByMe: boolean;\n scorecard?: GovJurisdictionScorecard | null;\n insights: GovJurisdictionInsight[];\n}\n\n// ============================================================================\n// Governance, commitments, elections, timeline (030-governance.gql)\n// ============================================================================\n\n/** An elected representative or administrative office holder for a jurisdiction. */\nexport interface GovOfficial {\n id: string;\n workspaceId: string;\n jurisdictionId: string;\n fullName: string;\n localName?: string | null;\n officeTitle: string;\n officeType: GovOfficeType;\n department?: string | null;\n party?: string | null;\n isIndependent: boolean;\n photoFileId?: string | null;\n biography?: string | null;\n contactEmail?: string | null;\n contactPhone?: string | null;\n officeAddress?: string | null;\n officeHours?: string | null;\n /** Public social profiles: `[{ platform, url }]`. */\n socialProfiles?: GovJson;\n termStart?: string | null;\n termEnd?: string | null;\n termDurationMonths?: number | null;\n electedOn?: string | null;\n nextElectionOn?: string | null;\n /** Published sitting/house attendance, 0-100. */\n attendancePercent?: number | null;\n votingRecordUrl?: string | null;\n committees: string[];\n responsibilities?: string | null;\n isCurrent: boolean;\n displayOrder: number;\n /** Opaque global-auth user id when the office holder also has a platform account. */\n linkedUserId?: string | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification: GovVerificationStatus;\n createdAt: string;\n updatedAt: string;\n\n /** Delivered commitments as a share of all non-abandoned commitments, 0-100. */\n commitmentDeliveryRate?: number | null;\n jurisdiction?: GovJurisdiction | null;\n commitments?: GovOfficialCommitment[];\n}\n\n/** A public promise or pledge, tracked from statement to delivery. */\nexport interface GovOfficialCommitment {\n id: string;\n workspaceId: string;\n officialId: string;\n jurisdictionId: string;\n title: string;\n description?: string | null;\n domain?: GovIndicatorDomain | null;\n promisedOn?: string | null;\n targetDate?: string | null;\n status: GovCommitmentStatus;\n progressPercent: number;\n /** Opaque GovProject id when a project delivers this commitment. */\n linkedProjectId?: string | null;\n evidenceUrl?: string | null;\n evidenceFileIds: string[];\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification: GovVerificationStatus;\n createdAt: string;\n updatedAt: string;\n /** True when the target date has passed and the commitment is not DELIVERED. */\n isOverdue: boolean;\n official?: GovOfficial | null;\n}\n\n/** A past or scheduled electoral event for a jurisdiction. */\nexport interface GovElection {\n id: string;\n workspaceId: string;\n jurisdictionId: string;\n name: string;\n electionType: GovElectionType;\n officeTitle?: string | null;\n electionDate: string;\n status: GovElectionStatus;\n registeredVoters?: number | null;\n votesCast?: number | null;\n validVotes?: number | null;\n invalidVotes?: number | null;\n turnoutPercent?: number | null;\n resultDeclaredOn?: string | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification: GovVerificationStatus;\n createdAt: string;\n updatedAt: string;\n\n /** Winning margin in votes between the top two declared results. */\n winningMarginVotes?: number | null;\n /** Winning margin as a percentage of valid votes. */\n winningMarginPercent?: number | null;\n jurisdiction?: GovJurisdiction | null;\n results?: GovElectionResult[];\n}\n\n/** One candidate's declared result within an election. */\nexport interface GovElectionResult {\n id: string;\n workspaceId: string;\n electionId: string;\n candidateName: string;\n party?: string | null;\n isIndependent: boolean;\n votes: number;\n votePercent?: number | null;\n position?: number | null;\n isWinner: boolean;\n photoFileId?: string | null;\n /** Opaque GovOfficial id once the winner is seated. */\n officialId?: string | null;\n createdAt: string;\n updatedAt: string;\n}\n\n/** A dated entry on the region's historical timeline. */\nexport interface GovJurisdictionEvent {\n id: string;\n workspaceId: string;\n jurisdictionId: string;\n title: string;\n description?: string | null;\n occurredOn: string;\n category: GovEventCategory;\n impact?: GovEventImpact | null;\n linkedProjectId?: string | null;\n linkedElectionId?: string | null;\n linkedBudgetId?: string | null;\n imageFileId?: string | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification: GovVerificationStatus;\n createdAt: string;\n updatedAt: string;\n}\n\n// ============================================================================\n// Public finance & development projects (040-finance.gql)\n// ============================================================================\n\n/** One fiscal period's published budget. */\nexport interface GovBudget {\n id: string;\n workspaceId: string;\n jurisdictionId: string;\n fiscalYear: string;\n periodStart: string;\n periodEnd: string;\n /** ISO 4217 currency this budget is denominated in. */\n currencyCode: string;\n status: GovBudgetStatus;\n totalRevenuePlanned: number;\n totalRevenueActual?: number | null;\n totalExpensePlanned: number;\n totalExpenseActual?: number | null;\n populationAtPublication?: number | null;\n summary?: string | null;\n /** wspace-files-svc File id for the published budget document. */\n documentFileId?: string | null;\n approvedOn?: string | null;\n publishedAt?: string | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification: GovVerificationStatus;\n createdAt: string;\n updatedAt: string;\n\n jurisdiction?: GovJurisdiction | null;\n lines?: GovBudgetLine[];\n}\n\n/** One revenue source or expenditure head within a budget. */\nexport interface GovBudgetLine {\n id: string;\n workspaceId: string;\n budgetId: string;\n kind: GovBudgetLineKind;\n category: GovBudgetCategory;\n label: string;\n department?: string | null;\n /** Government functional classification code, where one is published. */\n functionCode?: string | null;\n plannedAmount: number;\n actualAmount?: number | null;\n previousYearAmount?: number | null;\n notes?: string | null;\n displayOrder: number;\n createdAt: string;\n updatedAt: string;\n /** `actualAmount - plannedAmount`; null until an actual is recorded. */\n variance?: number | null;\n /** Variance as a percentage of the planned amount; null when planned is zero. */\n variancePercent?: number | null;\n}\n\n/** One category's rolled-up planned/actual position within a budget. */\nexport interface GovBudgetCategoryRow {\n kind: GovBudgetLineKind;\n category: GovBudgetCategory;\n planned: number;\n actual?: number | null;\n variance?: number | null;\n variancePercent?: number | null;\n /** This category's share of its side of the ledger, 0-100. */\n sharePercent: number;\n}\n\n/** Planned vs actual execution of a budget, rolled up by category. */\nexport interface GovBudgetExecution {\n budgetId: string;\n fiscalYear: string;\n currencyCode: string;\n plannedRevenue: number;\n actualRevenue?: number | null;\n plannedExpense: number;\n actualExpense?: number | null;\n /** Actual expenditure as a percentage of planned; null when nothing is planned. */\n executionPercent?: number | null;\n /** Planned expenditure per head; null when no population is snapshotted. */\n perCapitaExpense?: number | null;\n /** Actual expenditure per head; null when either input is missing. */\n perCapitaActualExpense?: number | null;\n byCategory: GovBudgetCategoryRow[];\n}\n\n/** A public works / development project, from tender through to completion. */\nexport interface GovProject {\n id: string;\n workspaceId: string;\n jurisdictionId: string;\n /** Owning GovAgency, when the project is agency-run. */\n agencyId?: string | null;\n name: string;\n code?: string | null;\n description?: string | null;\n domain: GovIndicatorDomain;\n department?: string | null;\n contractorName?: string | null;\n contractorRegistrationId?: string | null;\n fundingSource: GovFundingSource;\n budgetAmount?: number | null;\n actualCost?: number | null;\n currencyCode?: string | null;\n tenderReference?: string | null;\n tenderUrl?: string | null;\n awardedOn?: string | null;\n startDate?: string | null;\n plannedCompletionDate?: string | null;\n actualCompletionDate?: string | null;\n status: GovProjectStatus;\n progressPercent: number;\n delayReason?: string | null;\n locationLabel?: string | null;\n latitude?: number | null;\n longitude?: number | null;\n imageFileIds: string[];\n documentFileIds: string[];\n beneficiaryCount?: number | null;\n tags: string[];\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification: GovVerificationStatus;\n publishedAt?: string | null;\n createdAt: string;\n updatedAt: string;\n\n /** Days late, derived at read time. Never negative; null with no planned date. */\n delayDays?: number | null;\n /** `actualCost - budgetAmount`; null until an actual cost is recorded. */\n costVariance?: number | null;\n jurisdiction?: GovJurisdiction | null;\n milestones?: GovProjectMilestone[];\n}\n\n/** A dated checkpoint within a project's delivery timeline. */\nexport interface GovProjectMilestone {\n id: string;\n workspaceId: string;\n projectId: string;\n name: string;\n description?: string | null;\n dueDate?: string | null;\n completedOn?: string | null;\n status: GovMilestoneStatus;\n progressPercent: number;\n evidenceFileId?: string | null;\n displayOrder: number;\n createdAt: string;\n updatedAt: string;\n /** True when the due date has passed and the milestone is not COMPLETED. */\n isOverdue: boolean;\n}\n\n// ============================================================================\n// Indicators, scorecards, benchmarking, reused performance (050-indicators.gql)\n// ============================================================================\n\n/** The definition of a measurable civic KPI. */\nexport interface GovIndicator {\n id: string;\n workspaceId: string;\n /** Stable dotted code, unique per workspace (e.g. EDU.LITERACY.RATE). */\n code: string;\n name: string;\n description?: string | null;\n domain: GovIndicatorDomain;\n /** Display unit (%, per 1,000, days). */\n unit: string;\n valueType: GovIndicatorValueType;\n direction: GovIndicatorDirection;\n periodicity: GovIndicatorPeriodicity;\n methodology?: string | null;\n targetValue?: number | null;\n /** Normalization floor used when scoring this indicator 0-100. */\n minValue?: number | null;\n /** Normalization ceiling used when scoring this indicator 0-100. */\n maxValue?: number | null;\n /** Only core indicators contribute to the composite scorecard. */\n isCore: boolean;\n weight: number;\n isActive: boolean;\n /** UN Sustainable Development Goal number, 1-17. */\n sdgGoal?: number | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n createdAt: string;\n updatedAt: string;\n}\n\n/** One measured fact: an indicator, for a jurisdiction, over a period, with provenance. */\nexport interface GovIndicatorValue {\n id: string;\n workspaceId: string;\n indicatorId: string;\n jurisdictionId: string;\n /** Human period label matching the indicator's periodicity (2026, 2026-Q1). */\n periodLabel: string;\n periodStart: string;\n periodEnd: string;\n value: number;\n /** Optional raw components, so a rate can be audited back to its inputs. */\n numerator?: number | null;\n denominator?: number | null;\n targetValue?: number | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n sourceDate?: string | null;\n /** Opaque GovDataset id this value was derived from, when applicable. */\n datasetId?: string | null;\n verification: GovVerificationStatus;\n notes?: string | null;\n publishedAt?: string | null;\n createdAt: string;\n updatedAt: string;\n\n indicator?: GovIndicator | null;\n jurisdiction?: GovJurisdiction | null;\n}\n\n/** One point on an indicator's time series for a jurisdiction. */\nexport interface GovIndicatorPoint {\n periodLabel: string;\n periodStart: string;\n value: number;\n targetValue?: number | null;\n verification: GovVerificationStatus;\n}\n\n/** An indicator's full published history for one jurisdiction. */\nexport interface GovIndicatorSeries {\n indicator: GovIndicator;\n jurisdictionId: string;\n points: GovIndicatorPoint[];\n latestValue?: number | null;\n latestPeriodLabel?: string | null;\n /** Percentage change between the two most recent published points. */\n changePercent?: number | null;\n /** Direction of travel, already adjusted for whether higher is better. */\n trend: GovTrendDirection;\n}\n\n/** A single domain's contribution to a jurisdiction's composite score. */\nexport interface GovDomainScore {\n domain: GovIndicatorDomain;\n /** Weighted 0-100 score; null when no core indicator in this domain is measured. */\n score?: number | null;\n /** Core indicators defined in this domain. */\n indicatorCount: number;\n /** Core indicators in this domain that actually have a published value. */\n measuredCount: number;\n trend: GovTrendDirection;\n changePercent?: number | null;\n}\n\n/** A jurisdiction's composite performance scorecard. */\nexport interface GovJurisdictionScorecard {\n jurisdictionId: string;\n jurisdictionName: string;\n periodLabel?: string | null;\n /** Weighted composite 0-100; null when coverage is below the publishable threshold. */\n overallScore?: number | null;\n domains: GovDomainScore[];\n /** Measured core indicators as a percentage of defined core indicators. */\n coveragePercent: number;\n indicatorCount: number;\n measuredCount: number;\n generatedAt: string;\n}\n\n/** One jurisdiction's standing within a benchmark peer set. */\nexport interface GovBenchmarkEntry {\n jurisdictionId: string;\n jurisdictionName: string;\n value: number;\n rank: number;\n}\n\n/** A jurisdiction benchmarked against a peer set for one indicator. */\nexport interface GovBenchmarkResult {\n indicator: GovIndicator;\n jurisdictionId: string;\n periodLabel?: string | null;\n scope: GovBenchmarkScope;\n /** The subject's own entry; null when the subject has no value for the period. */\n subject?: GovBenchmarkEntry | null;\n peers: GovBenchmarkEntry[];\n peerCount: number;\n /** The subject's percentile within the peer set, 0-100. */\n percentile?: number | null;\n average?: number | null;\n median?: number | null;\n best?: GovBenchmarkEntry | null;\n worst?: GovBenchmarkEntry | null;\n /** False when the peer set was too small to publish a rank. */\n isRankPublished: boolean;\n}\n\n/** A deterministically derived, evidence-carrying observation about a jurisdiction. */\nexport interface GovJurisdictionInsight {\n kind: GovInsightKind;\n severity: GovInsightSeverity;\n title: string;\n detail: string;\n domain?: GovIndicatorDomain | null;\n indicatorCode?: string | null;\n evidence: string[];\n generatedAt: string;\n}\n\n/** Per-service row of a jurisdiction's service-delivery performance rollup. */\nexport interface GovServicePerformanceRow {\n serviceId: string;\n serviceName: string;\n applications: number;\n approved: number;\n rejected: number;\n pending: number;\n avgProcessingHours?: number | null;\n slaDays: number;\n slaCompliancePercent?: number | null;\n}\n\n/** Per-agency row of a jurisdiction's service-delivery performance rollup. */\nexport interface GovAgencyPerformanceRow {\n agencyId: string;\n agencyName: string;\n applications: number;\n approved: number;\n rejected: number;\n pending: number;\n avgProcessingHours?: number | null;\n slaCompliancePercent?: number | null;\n}\n\n/** Service-delivery performance for a jurisdiction, rolled up from live casework. */\nexport interface GovServicePerformance {\n jurisdictionId: string;\n totalApplications: number;\n approvedCount: number;\n rejectedCount: number;\n pendingCount: number;\n /** Approvals as a percentage of decided applications; null when nothing is decided. */\n approvalRate?: number | null;\n avgProcessingHours?: number | null;\n slaBreachedCount: number;\n slaCompliancePercent?: number | null;\n byService: GovServicePerformanceRow[];\n byAgency: GovAgencyPerformanceRow[];\n}\n\n/** Per-category row of a jurisdiction's grievance rollup. */\nexport interface GovGrievanceCategoryRow {\n category: GovServiceCategory;\n total: number;\n resolved: number;\n avgResolutionHours?: number | null;\n}\n\n/** A recurring-issue cluster; cells below the suppression threshold are omitted. */\nexport interface GovGrievanceHotspot {\n locationLabel: string;\n latitude?: number | null;\n longitude?: number | null;\n count: number;\n topCategory: GovServiceCategory;\n}\n\n/** Citizen-issue insight for a jurisdiction, rolled up from live grievances. */\nexport interface GovGrievanceInsights {\n jurisdictionId: string;\n total: number;\n open: number;\n inProgress: number;\n resolved: number;\n avgResolutionHours?: number | null;\n byCategory: GovGrievanceCategoryRow[];\n hotspots: GovGrievanceHotspot[];\n}\n\n// ============================================================================\n// Assets, participation, open data, following, corrections (060-participation.gql)\n// ============================================================================\n\n/** The mappable registry of everything physical or organisational in a jurisdiction. */\nexport interface GovPublicAsset {\n id: string;\n workspaceId: string;\n jurisdictionId: string;\n name: string;\n category: GovAssetCategory;\n subCategory?: string | null;\n description?: string | null;\n operator: GovAssetOperator;\n status: GovAssetStatus;\n address?: string | null;\n latitude?: number | null;\n longitude?: number | null;\n capacity?: number | null;\n /** Unit the capacity is counted in (beds, students, vehicles). */\n capacityUnit?: string | null;\n contactPhone?: string | null;\n contactEmail?: string | null;\n website?: string | null;\n openingHours?: string | null;\n /** Whether the facility is accessible to people with disabilities. */\n isAccessible?: boolean | null;\n establishedOn?: string | null;\n imageFileId?: string | null;\n /** Category-specific attributes, keyed per the documented convention. */\n metadata?: GovJson;\n tags: string[];\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification: GovVerificationStatus;\n createdAt: string;\n updatedAt: string;\n}\n\n/** A count of assets in one category, for map legends and registry summaries. */\nexport interface GovAssetCategoryCount {\n category: GovAssetCategory;\n count: number;\n}\n\n/** A survey, poll, public hearing or participatory-budgeting exercise. */\nexport interface GovConsultation {\n id: string;\n workspaceId: string;\n jurisdictionId: string;\n title: string;\n description?: string | null;\n consultationType: GovConsultationType;\n status: GovConsultationStatus;\n opensAt?: string | null;\n closesAt?: string | null;\n /** `[{ id, label, type, options?, required, min?, max? }]`. */\n questions: GovJson;\n allowAnonymous: boolean;\n /** Pot to distribute, for participatory-budgeting consultations. */\n budgetAmount?: number | null;\n currencyCode?: string | null;\n responseCount: number;\n /** Aggregated, publishable results. Raw responses are never exposed. */\n resultsSummary?: GovJson;\n resultsPublishedAt?: string | null;\n documentFileId?: string | null;\n tags: string[];\n createdAt: string;\n updatedAt: string;\n /** True when the consultation is OPEN and within its date window. */\n isAcceptingResponses: boolean;\n /** Whether the calling actor has already responded. */\n hasRespondedByMe: boolean;\n jurisdiction?: GovJurisdiction | null;\n}\n\n/** One participant's submission. Only ever readable by its own author. */\nexport interface GovConsultationResponse {\n id: string;\n workspaceId: string;\n consultationId: string;\n jurisdictionId: string;\n respondentActorId?: string | null;\n /** `[{ questionId, value }]`. */\n answers: GovJson;\n sentiment?: GovSentiment | null;\n submittedAt: string;\n}\n\n/** Aggregated answers for one consultation question. */\nexport interface GovConsultationQuestionResult {\n questionId: string;\n label: string;\n type: string;\n responseCount: number;\n /** Aggregate for the question. Free-text questions carry a count only. */\n aggregate: GovJson;\n}\n\n/** Publishable results for a consultation. */\nexport interface GovConsultationResults {\n consultationId: string;\n status: GovConsultationStatus;\n responseCount: number;\n resultsPublishedAt?: string | null;\n questions: GovConsultationQuestionResult[];\n /** True when the result set is below the suppression threshold and withheld. */\n isSuppressed: boolean;\n}\n\n/** An open-data catalogue entry. Metadata only — the bytes live elsewhere. */\nexport interface GovDataset {\n id: string;\n workspaceId: string;\n jurisdictionId?: string | null;\n name: string;\n slug: string;\n description?: string | null;\n domain?: GovIndicatorDomain | null;\n format: GovDatasetFormat;\n license: GovDataLicense;\n licenseUrl?: string | null;\n version: string;\n /** wspace-files-svc File id holding the dataset. */\n fileId?: string | null;\n /** Publisher-hosted location, when the data is not held on the platform. */\n externalUrl?: string | null;\n periodStart?: string | null;\n periodEnd?: string | null;\n updateFrequency?: GovIndicatorPeriodicity | null;\n rowCount?: number | null;\n sizeBytes?: number | null;\n publisher?: string | null;\n contactEmail?: string | null;\n status: GovDatasetStatus;\n publishedAt?: string | null;\n downloadCount: number;\n tags: string[];\n createdAt: string;\n updatedAt: string;\n jurisdiction?: GovJurisdiction | null;\n}\n\n/** A citizen's subscription to a jurisdiction's updates. */\nexport interface GovJurisdictionFollow {\n id: string;\n workspaceId: string;\n jurisdictionId: string;\n actorId: string;\n /** Delivery channels: IN_APP | EMAIL. */\n channels: string[];\n /** Topics: BUDGET | PROJECT | ELECTION | CONSULTATION | EMERGENCY | INDICATOR | DATASET. */\n topics: string[];\n createdAt: string;\n jurisdiction?: GovJurisdiction | null;\n}\n\n/** A proposed correction to published civic data, with evidence, reviewed by an official. */\nexport interface GovDataChangeProposal {\n id: string;\n workspaceId: string;\n jurisdictionId: string;\n entityType: GovIntelEntityType;\n entityId: string;\n fieldPath: string;\n currentValue?: string | null;\n proposedValue: string;\n rationale: string;\n evidenceUrl?: string | null;\n evidenceFileIds: string[];\n status: GovProposalStatus;\n submittedByActorId: string;\n submittedAt: string;\n reviewedByActorId?: string | null;\n reviewedAt?: string | null;\n reviewNote?: string | null;\n appliedAt?: string | null;\n createdAt: string;\n updatedAt: string;\n jurisdiction?: GovJurisdiction | null;\n}\n\n// ============================================================================\n// Connections — every one is the frozen `{ items, pageInfo }` shape.\n// There is NO `totalCount` anywhere in this contract.\n// ============================================================================\n\nexport type GovAdminLevelConnection = GovConnection<GovAdminLevel>;\nexport type GovJurisdictionConnection = GovConnection<GovJurisdiction>;\nexport type GovOfficialConnection = GovConnection<GovOfficial>;\nexport type GovOfficialCommitmentConnection = GovConnection<GovOfficialCommitment>;\nexport type GovElectionConnection = GovConnection<GovElection>;\nexport type GovJurisdictionEventConnection = GovConnection<GovJurisdictionEvent>;\nexport type GovBudgetConnection = GovConnection<GovBudget>;\nexport type GovProjectConnection = GovConnection<GovProject>;\nexport type GovIndicatorConnection = GovConnection<GovIndicator>;\nexport type GovIndicatorValueConnection = GovConnection<GovIndicatorValue>;\nexport type GovPublicAssetConnection = GovConnection<GovPublicAsset>;\nexport type GovConsultationConnection = GovConnection<GovConsultation>;\nexport type GovDatasetConnection = GovConnection<GovDataset>;\nexport type GovDataChangeProposalConnection = GovConnection<GovDataChangeProposal>;\n\n// ============================================================================\n// Filter inputs\n// ============================================================================\n\nexport interface GovJurisdictionFilterInput {\n parentId?: string | null;\n adminLevelId?: string | null;\n countryCode?: string | null;\n status?: GovJurisdictionStatus | null;\n /** Free-text match against name, local name and official code. */\n search?: string | null;\n /** Restrict to descendants of this jurisdiction (materialized-path subtree). */\n ancestorId?: string | null;\n tags?: string[] | null;\n}\n\nexport interface GovOfficialFilterInput {\n jurisdictionId?: string | null;\n officeType?: GovOfficeType | null;\n isCurrent?: boolean | null;\n party?: string | null;\n search?: string | null;\n}\n\nexport interface GovOfficialCommitmentFilterInput {\n officialId?: string | null;\n jurisdictionId?: string | null;\n status?: GovCommitmentStatus | null;\n domain?: GovIndicatorDomain | null;\n}\n\nexport interface GovElectionFilterInput {\n jurisdictionId?: string | null;\n electionType?: GovElectionType | null;\n status?: GovElectionStatus | null;\n fromDate?: string | null;\n toDate?: string | null;\n}\n\nexport interface GovBudgetFilterInput {\n jurisdictionId?: string | null;\n fiscalYear?: string | null;\n status?: GovBudgetStatus | null;\n}\n\nexport interface GovProjectFilterInput {\n jurisdictionId?: string | null;\n agencyId?: string | null;\n status?: GovProjectStatus | null;\n domain?: GovIndicatorDomain | null;\n fundingSource?: GovFundingSource | null;\n department?: string | null;\n search?: string | null;\n /** Only projects running late by at least one day. */\n delayedOnly?: boolean | null;\n}\n\nexport interface GovIndicatorFilterInput {\n domain?: GovIndicatorDomain | null;\n isCore?: boolean | null;\n isActive?: boolean | null;\n sdgGoal?: number | null;\n search?: string | null;\n}\n\nexport interface GovIndicatorValueFilterInput {\n jurisdictionId?: string | null;\n indicatorId?: string | null;\n indicatorCode?: string | null;\n domain?: GovIndicatorDomain | null;\n periodLabel?: string | null;\n fromPeriodStart?: string | null;\n toPeriodStart?: string | null;\n verification?: GovVerificationStatus | null;\n}\n\nexport interface GovPublicAssetFilterInput {\n jurisdictionId?: string | null;\n category?: GovAssetCategory | null;\n operator?: GovAssetOperator | null;\n status?: GovAssetStatus | null;\n isAccessible?: boolean | null;\n search?: string | null;\n /** Only assets that carry coordinates, for map layers. */\n mappableOnly?: boolean | null;\n}\n\nexport interface GovConsultationFilterInput {\n jurisdictionId?: string | null;\n consultationType?: GovConsultationType | null;\n status?: GovConsultationStatus | null;\n openOnly?: boolean | null;\n}\n\nexport interface GovDatasetFilterInput {\n jurisdictionId?: string | null;\n domain?: GovIndicatorDomain | null;\n format?: GovDatasetFormat | null;\n license?: GovDataLicense | null;\n status?: GovDatasetStatus | null;\n search?: string | null;\n}\n\nexport interface GovDataChangeProposalFilterInput {\n jurisdictionId?: string | null;\n entityType?: GovIntelEntityType | null;\n entityId?: string | null;\n status?: GovProposalStatus | null;\n}\n\n// ============================================================================\n// Create / update inputs\n// ============================================================================\n\nexport interface GovCreateAdminLevelInput {\n countryCode: string;\n rank: number;\n code: string;\n name: string;\n pluralName: string;\n description?: string | null;\n isElectoral?: boolean | null;\n}\n\nexport interface GovUpdateAdminLevelInput {\n rank?: number | null;\n code?: string | null;\n name?: string | null;\n pluralName?: string | null;\n description?: string | null;\n isElectoral?: boolean | null;\n}\n\nexport interface GovCreateJurisdictionInput {\n parentId?: string | null;\n adminLevelId: string;\n countryCode: string;\n name: string;\n localName?: string | null;\n officialCode?: string | null;\n slug?: string | null;\n summary?: string | null;\n establishedOn?: string | null;\n headquarters?: string | null;\n officialWebsite?: string | null;\n contactEmail?: string | null;\n contactPhone?: string | null;\n emergencyNumbers?: GovJson;\n timezone?: string | null;\n languages?: string[] | null;\n currencyCode?: string | null;\n climateSummary?: string | null;\n areaSqKm?: number | null;\n population?: number | null;\n populationYear?: number | null;\n households?: number | null;\n centroidLat?: number | null;\n centroidLng?: number | null;\n boundaryFileId?: string | null;\n bannerFileId?: string | null;\n crestFileId?: string | null;\n tags?: string[] | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification?: GovVerificationStatus | null;\n}\n\nexport interface GovUpdateJurisdictionInput {\n parentId?: string | null;\n adminLevelId?: string | null;\n name?: string | null;\n localName?: string | null;\n officialCode?: string | null;\n summary?: string | null;\n establishedOn?: string | null;\n headquarters?: string | null;\n officialWebsite?: string | null;\n contactEmail?: string | null;\n contactPhone?: string | null;\n emergencyNumbers?: GovJson;\n timezone?: string | null;\n languages?: string[] | null;\n currencyCode?: string | null;\n climateSummary?: string | null;\n areaSqKm?: number | null;\n population?: number | null;\n populationYear?: number | null;\n households?: number | null;\n centroidLat?: number | null;\n centroidLng?: number | null;\n boundaryFileId?: string | null;\n bannerFileId?: string | null;\n crestFileId?: string | null;\n tags?: string[] | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification?: GovVerificationStatus | null;\n}\n\nexport interface GovCreateOfficialInput {\n jurisdictionId: string;\n fullName: string;\n localName?: string | null;\n officeTitle: string;\n officeType?: GovOfficeType | null;\n department?: string | null;\n party?: string | null;\n isIndependent?: boolean | null;\n photoFileId?: string | null;\n biography?: string | null;\n contactEmail?: string | null;\n contactPhone?: string | null;\n officeAddress?: string | null;\n officeHours?: string | null;\n socialProfiles?: GovJson;\n termStart?: string | null;\n termEnd?: string | null;\n termDurationMonths?: number | null;\n electedOn?: string | null;\n nextElectionOn?: string | null;\n attendancePercent?: number | null;\n votingRecordUrl?: string | null;\n committees?: string[] | null;\n responsibilities?: string | null;\n isCurrent?: boolean | null;\n displayOrder?: number | null;\n linkedUserId?: string | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification?: GovVerificationStatus | null;\n}\n\nexport interface GovUpdateOfficialInput {\n fullName?: string | null;\n localName?: string | null;\n officeTitle?: string | null;\n officeType?: GovOfficeType | null;\n department?: string | null;\n party?: string | null;\n isIndependent?: boolean | null;\n photoFileId?: string | null;\n biography?: string | null;\n contactEmail?: string | null;\n contactPhone?: string | null;\n officeAddress?: string | null;\n officeHours?: string | null;\n socialProfiles?: GovJson;\n termStart?: string | null;\n termEnd?: string | null;\n termDurationMonths?: number | null;\n electedOn?: string | null;\n nextElectionOn?: string | null;\n attendancePercent?: number | null;\n votingRecordUrl?: string | null;\n committees?: string[] | null;\n responsibilities?: string | null;\n isCurrent?: boolean | null;\n displayOrder?: number | null;\n linkedUserId?: string | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification?: GovVerificationStatus | null;\n}\n\nexport interface GovCreateOfficialCommitmentInput {\n officialId: string;\n title: string;\n description?: string | null;\n domain?: GovIndicatorDomain | null;\n promisedOn?: string | null;\n targetDate?: string | null;\n status?: GovCommitmentStatus | null;\n progressPercent?: number | null;\n linkedProjectId?: string | null;\n evidenceUrl?: string | null;\n evidenceFileIds?: string[] | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification?: GovVerificationStatus | null;\n}\n\nexport interface GovUpdateOfficialCommitmentInput {\n title?: string | null;\n description?: string | null;\n domain?: GovIndicatorDomain | null;\n promisedOn?: string | null;\n targetDate?: string | null;\n status?: GovCommitmentStatus | null;\n progressPercent?: number | null;\n linkedProjectId?: string | null;\n evidenceUrl?: string | null;\n evidenceFileIds?: string[] | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification?: GovVerificationStatus | null;\n}\n\nexport interface GovCreateElectionInput {\n jurisdictionId: string;\n name: string;\n electionType?: GovElectionType | null;\n officeTitle?: string | null;\n electionDate: string;\n status?: GovElectionStatus | null;\n registeredVoters?: number | null;\n votesCast?: number | null;\n validVotes?: number | null;\n invalidVotes?: number | null;\n resultDeclaredOn?: string | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification?: GovVerificationStatus | null;\n}\n\nexport interface GovUpdateElectionInput {\n name?: string | null;\n electionType?: GovElectionType | null;\n officeTitle?: string | null;\n electionDate?: string | null;\n status?: GovElectionStatus | null;\n registeredVoters?: number | null;\n votesCast?: number | null;\n validVotes?: number | null;\n invalidVotes?: number | null;\n resultDeclaredOn?: string | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification?: GovVerificationStatus | null;\n}\n\nexport interface GovElectionResultInput {\n candidateName: string;\n party?: string | null;\n isIndependent?: boolean | null;\n votes: number;\n position?: number | null;\n isWinner?: boolean | null;\n photoFileId?: string | null;\n officialId?: string | null;\n}\n\nexport interface GovCreateJurisdictionEventInput {\n jurisdictionId: string;\n title: string;\n description?: string | null;\n occurredOn: string;\n category?: GovEventCategory | null;\n impact?: GovEventImpact | null;\n linkedProjectId?: string | null;\n linkedElectionId?: string | null;\n linkedBudgetId?: string | null;\n imageFileId?: string | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification?: GovVerificationStatus | null;\n}\n\nexport interface GovUpdateJurisdictionEventInput {\n title?: string | null;\n description?: string | null;\n occurredOn?: string | null;\n category?: GovEventCategory | null;\n impact?: GovEventImpact | null;\n linkedProjectId?: string | null;\n linkedElectionId?: string | null;\n linkedBudgetId?: string | null;\n imageFileId?: string | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification?: GovVerificationStatus | null;\n}\n\nexport interface GovCreateBudgetInput {\n jurisdictionId: string;\n fiscalYear: string;\n periodStart: string;\n periodEnd: string;\n currencyCode: string;\n status?: GovBudgetStatus | null;\n totalRevenuePlanned?: number | null;\n totalRevenueActual?: number | null;\n totalExpensePlanned?: number | null;\n totalExpenseActual?: number | null;\n populationAtPublication?: number | null;\n summary?: string | null;\n documentFileId?: string | null;\n approvedOn?: string | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification?: GovVerificationStatus | null;\n}\n\nexport interface GovUpdateBudgetInput {\n fiscalYear?: string | null;\n periodStart?: string | null;\n periodEnd?: string | null;\n currencyCode?: string | null;\n status?: GovBudgetStatus | null;\n totalRevenuePlanned?: number | null;\n totalRevenueActual?: number | null;\n totalExpensePlanned?: number | null;\n totalExpenseActual?: number | null;\n populationAtPublication?: number | null;\n summary?: string | null;\n documentFileId?: string | null;\n approvedOn?: string | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification?: GovVerificationStatus | null;\n}\n\nexport interface GovBudgetLineInput {\n /** Omit to create a new line; supply to update an existing one. */\n id?: string | null;\n kind: GovBudgetLineKind;\n category: GovBudgetCategory;\n label: string;\n department?: string | null;\n functionCode?: string | null;\n plannedAmount?: number | null;\n actualAmount?: number | null;\n previousYearAmount?: number | null;\n notes?: string | null;\n displayOrder?: number | null;\n}\n\nexport interface GovCreateProjectInput {\n jurisdictionId: string;\n agencyId?: string | null;\n name: string;\n code?: string | null;\n description?: string | null;\n domain?: GovIndicatorDomain | null;\n department?: string | null;\n contractorName?: string | null;\n contractorRegistrationId?: string | null;\n fundingSource?: GovFundingSource | null;\n budgetAmount?: number | null;\n actualCost?: number | null;\n currencyCode?: string | null;\n tenderReference?: string | null;\n tenderUrl?: string | null;\n awardedOn?: string | null;\n startDate?: string | null;\n plannedCompletionDate?: string | null;\n actualCompletionDate?: string | null;\n status?: GovProjectStatus | null;\n progressPercent?: number | null;\n delayReason?: string | null;\n locationLabel?: string | null;\n latitude?: number | null;\n longitude?: number | null;\n imageFileIds?: string[] | null;\n documentFileIds?: string[] | null;\n beneficiaryCount?: number | null;\n tags?: string[] | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification?: GovVerificationStatus | null;\n}\n\nexport interface GovUpdateProjectInput {\n agencyId?: string | null;\n name?: string | null;\n code?: string | null;\n description?: string | null;\n domain?: GovIndicatorDomain | null;\n department?: string | null;\n contractorName?: string | null;\n contractorRegistrationId?: string | null;\n fundingSource?: GovFundingSource | null;\n budgetAmount?: number | null;\n actualCost?: number | null;\n currencyCode?: string | null;\n tenderReference?: string | null;\n tenderUrl?: string | null;\n awardedOn?: string | null;\n startDate?: string | null;\n plannedCompletionDate?: string | null;\n actualCompletionDate?: string | null;\n status?: GovProjectStatus | null;\n progressPercent?: number | null;\n delayReason?: string | null;\n locationLabel?: string | null;\n latitude?: number | null;\n longitude?: number | null;\n imageFileIds?: string[] | null;\n documentFileIds?: string[] | null;\n beneficiaryCount?: number | null;\n tags?: string[] | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification?: GovVerificationStatus | null;\n}\n\nexport interface GovCreateProjectMilestoneInput {\n projectId: string;\n name: string;\n description?: string | null;\n dueDate?: string | null;\n completedOn?: string | null;\n status?: GovMilestoneStatus | null;\n progressPercent?: number | null;\n evidenceFileId?: string | null;\n displayOrder?: number | null;\n}\n\nexport interface GovUpdateProjectMilestoneInput {\n name?: string | null;\n description?: string | null;\n dueDate?: string | null;\n completedOn?: string | null;\n status?: GovMilestoneStatus | null;\n progressPercent?: number | null;\n evidenceFileId?: string | null;\n displayOrder?: number | null;\n}\n\nexport interface GovCreateIndicatorInput {\n code: string;\n name: string;\n description?: string | null;\n domain: GovIndicatorDomain;\n unit: string;\n valueType?: GovIndicatorValueType | null;\n direction?: GovIndicatorDirection | null;\n periodicity?: GovIndicatorPeriodicity | null;\n methodology?: string | null;\n targetValue?: number | null;\n minValue?: number | null;\n maxValue?: number | null;\n isCore?: boolean | null;\n weight?: number | null;\n isActive?: boolean | null;\n sdgGoal?: number | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n}\n\nexport interface GovUpdateIndicatorInput {\n name?: string | null;\n description?: string | null;\n domain?: GovIndicatorDomain | null;\n unit?: string | null;\n valueType?: GovIndicatorValueType | null;\n direction?: GovIndicatorDirection | null;\n periodicity?: GovIndicatorPeriodicity | null;\n methodology?: string | null;\n targetValue?: number | null;\n minValue?: number | null;\n maxValue?: number | null;\n isCore?: boolean | null;\n weight?: number | null;\n isActive?: boolean | null;\n sdgGoal?: number | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n}\n\nexport interface GovRecordIndicatorValueInput {\n /** Supply either the indicator id or its code. */\n indicatorId?: string | null;\n indicatorCode?: string | null;\n jurisdictionId: string;\n periodLabel: string;\n periodStart: string;\n periodEnd: string;\n value: number;\n numerator?: number | null;\n denominator?: number | null;\n targetValue?: number | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n sourceDate?: string | null;\n datasetId?: string | null;\n verification?: GovVerificationStatus | null;\n notes?: string | null;\n}\n\nexport interface GovUpdateIndicatorValueInput {\n value?: number | null;\n numerator?: number | null;\n denominator?: number | null;\n targetValue?: number | null;\n periodLabel?: string | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n sourceDate?: string | null;\n datasetId?: string | null;\n verification?: GovVerificationStatus | null;\n notes?: string | null;\n}\n\nexport interface GovCreatePublicAssetInput {\n jurisdictionId: string;\n name: string;\n category: GovAssetCategory;\n subCategory?: string | null;\n description?: string | null;\n operator?: GovAssetOperator | null;\n status?: GovAssetStatus | null;\n address?: string | null;\n latitude?: number | null;\n longitude?: number | null;\n capacity?: number | null;\n capacityUnit?: string | null;\n contactPhone?: string | null;\n contactEmail?: string | null;\n website?: string | null;\n openingHours?: string | null;\n isAccessible?: boolean | null;\n establishedOn?: string | null;\n imageFileId?: string | null;\n metadata?: GovJson;\n tags?: string[] | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification?: GovVerificationStatus | null;\n}\n\nexport interface GovUpdatePublicAssetInput {\n name?: string | null;\n category?: GovAssetCategory | null;\n subCategory?: string | null;\n description?: string | null;\n operator?: GovAssetOperator | null;\n status?: GovAssetStatus | null;\n address?: string | null;\n latitude?: number | null;\n longitude?: number | null;\n capacity?: number | null;\n capacityUnit?: string | null;\n contactPhone?: string | null;\n contactEmail?: string | null;\n website?: string | null;\n openingHours?: string | null;\n isAccessible?: boolean | null;\n establishedOn?: string | null;\n imageFileId?: string | null;\n metadata?: GovJson;\n tags?: string[] | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification?: GovVerificationStatus | null;\n}\n\nexport interface GovCreateConsultationInput {\n jurisdictionId: string;\n title: string;\n description?: string | null;\n consultationType?: GovConsultationType | null;\n opensAt?: string | null;\n closesAt?: string | null;\n questions: GovJson;\n allowAnonymous?: boolean | null;\n budgetAmount?: number | null;\n currencyCode?: string | null;\n documentFileId?: string | null;\n tags?: string[] | null;\n}\n\nexport interface GovUpdateConsultationInput {\n title?: string | null;\n description?: string | null;\n consultationType?: GovConsultationType | null;\n opensAt?: string | null;\n closesAt?: string | null;\n questions?: GovJson;\n allowAnonymous?: boolean | null;\n budgetAmount?: number | null;\n currencyCode?: string | null;\n documentFileId?: string | null;\n tags?: string[] | null;\n}\n\nexport interface GovSubmitConsultationResponseInput {\n consultationId: string;\n /** Answers: `[{ questionId, value }]`. */\n answers: GovJson;\n sentiment?: GovSentiment | null;\n /** Submit without recording the responding actor. Rejected when not allowed. */\n anonymous?: boolean | null;\n}\n\nexport interface GovCreateDatasetInput {\n jurisdictionId?: string | null;\n name: string;\n slug?: string | null;\n description?: string | null;\n domain?: GovIndicatorDomain | null;\n format?: GovDatasetFormat | null;\n license?: GovDataLicense | null;\n licenseUrl?: string | null;\n version?: string | null;\n fileId?: string | null;\n externalUrl?: string | null;\n periodStart?: string | null;\n periodEnd?: string | null;\n updateFrequency?: GovIndicatorPeriodicity | null;\n rowCount?: number | null;\n sizeBytes?: number | null;\n publisher?: string | null;\n contactEmail?: string | null;\n tags?: string[] | null;\n}\n\nexport interface GovUpdateDatasetInput {\n jurisdictionId?: string | null;\n name?: string | null;\n description?: string | null;\n domain?: GovIndicatorDomain | null;\n format?: GovDatasetFormat | null;\n license?: GovDataLicense | null;\n licenseUrl?: string | null;\n version?: string | null;\n fileId?: string | null;\n externalUrl?: string | null;\n periodStart?: string | null;\n periodEnd?: string | null;\n updateFrequency?: GovIndicatorPeriodicity | null;\n rowCount?: number | null;\n sizeBytes?: number | null;\n publisher?: string | null;\n contactEmail?: string | null;\n status?: GovDatasetStatus | null;\n tags?: string[] | null;\n}\n\nexport interface GovSubmitDataChangeProposalInput {\n jurisdictionId: string;\n entityType: GovIntelEntityType;\n entityId: string;\n fieldPath: string;\n proposedValue: string;\n rationale: string;\n evidenceUrl?: string | null;\n evidenceFileIds?: string[] | null;\n}\n\n// ============================================================================\n// UI helper maps — LABELS ONLY. No colours here: pages style with the semantic\n// Tailwind tokens the sibling GovCitizenHub pages already use.\n// ============================================================================\n\n/** Human label per indicator/project/dataset domain. */\nexport const GOV_INDICATOR_DOMAIN_LABELS: Record<GovIndicatorDomain, string> = {\n DEMOGRAPHICS: 'Demographics',\n ECONOMY: 'Economy',\n EDUCATION: 'Education',\n HEALTHCARE: 'Healthcare',\n INFRASTRUCTURE: 'Infrastructure',\n PUBLIC_SAFETY: 'Public safety',\n ENVIRONMENT: 'Environment',\n SOCIAL_WELFARE: 'Social welfare',\n UTILITIES: 'Utilities',\n TRANSPORT: 'Transport',\n HOUSING: 'Housing',\n GOVERNANCE: 'Governance',\n DIGITAL: 'Digital',\n TOURISM: 'Tourism',\n FINANCE: 'Finance',\n};\n\n/** Human label per public-asset category. */\nexport const GOV_ASSET_CATEGORY_LABELS: Record<GovAssetCategory, string> = {\n SCHOOL: 'School',\n UNIVERSITY: 'University',\n LIBRARY: 'Library',\n HOSPITAL: 'Hospital',\n CLINIC: 'Clinic',\n PHARMACY: 'Pharmacy',\n POLICE_STATION: 'Police station',\n FIRE_STATION: 'Fire station',\n EMERGENCY_SHELTER: 'Emergency shelter',\n WATER_FACILITY: 'Water facility',\n POWER_FACILITY: 'Power facility',\n WASTE_FACILITY: 'Waste facility',\n TRANSIT_STOP: 'Transit stop',\n TRANSIT_STATION: 'Transit station',\n AIRPORT: 'Airport',\n PORT: 'Port',\n BRIDGE: 'Bridge',\n PARK: 'Park',\n SPORTS_FACILITY: 'Sports facility',\n COMMUNITY_CENTER: 'Community centre',\n GOVERNMENT_OFFICE: 'Government office',\n PUBLIC_TOILET: 'Public toilet',\n PARKING: 'Parking',\n EV_CHARGING: 'EV charging',\n MARKET: 'Market',\n NGO: 'NGO',\n BUSINESS: 'Business',\n LANDMARK: 'Landmark',\n MUSEUM: 'Museum',\n OTHER: 'Other',\n};\n\n/** Human label per budget category (both sides of the ledger). */\nexport const GOV_BUDGET_CATEGORY_LABELS: Record<GovBudgetCategory, string> = {\n TAXES: 'Taxes',\n FEES_AND_CHARGES: 'Fees and charges',\n GRANTS: 'Grants',\n INTERGOVERNMENTAL_TRANSFERS: 'Intergovernmental transfers',\n LOANS: 'Loans',\n INTERNATIONAL_AID: 'International aid',\n PUBLIC_PRIVATE_PARTNERSHIP: 'Public-private partnership',\n ASSET_SALES: 'Asset sales',\n OTHER_REVENUE: 'Other revenue',\n EDUCATION: 'Education',\n HEALTHCARE: 'Healthcare',\n ROADS_AND_TRANSPORT: 'Roads and transport',\n WATER_AND_SANITATION: 'Water and sanitation',\n ENERGY: 'Energy',\n AGRICULTURE: 'Agriculture',\n ENVIRONMENT: 'Environment',\n PUBLIC_SAFETY: 'Public safety',\n SOCIAL_WELFARE: 'Social welfare',\n HOUSING: 'Housing',\n DIGITAL_INFRASTRUCTURE: 'Digital infrastructure',\n CULTURE_AND_RECREATION: 'Culture and recreation',\n ADMINISTRATION: 'Administration',\n DEBT_SERVICE: 'Debt service',\n CAPITAL_PROJECTS: 'Capital projects',\n OTHER_EXPENSE: 'Other expenditure',\n};\n\n/**\n * Revenue-side budget categories — the exact split the backend enforces\n * (`TAXES`..`OTHER_REVENUE` in 010-enums.gql). A line whose category is not in\n * this list is rejected with VALIDATION_FAILED when `kind` is REVENUE.\n */\nexport const GOV_REVENUE_CATEGORIES: readonly GovBudgetCategory[] = [\n 'TAXES',\n 'FEES_AND_CHARGES',\n 'GRANTS',\n 'INTERGOVERNMENTAL_TRANSFERS',\n 'LOANS',\n 'INTERNATIONAL_AID',\n 'PUBLIC_PRIVATE_PARTNERSHIP',\n 'ASSET_SALES',\n 'OTHER_REVENUE',\n];\n\n/**\n * Expense-side budget categories (`EDUCATION`..`OTHER_EXPENSE` in\n * 010-enums.gql). A line whose category is not in this list is rejected with\n * VALIDATION_FAILED when `kind` is EXPENSE.\n */\nexport const GOV_EXPENSE_CATEGORIES: readonly GovBudgetCategory[] = [\n 'EDUCATION',\n 'HEALTHCARE',\n 'ROADS_AND_TRANSPORT',\n 'WATER_AND_SANITATION',\n 'ENERGY',\n 'AGRICULTURE',\n 'ENVIRONMENT',\n 'PUBLIC_SAFETY',\n 'SOCIAL_WELFARE',\n 'HOUSING',\n 'DIGITAL_INFRASTRUCTURE',\n 'CULTURE_AND_RECREATION',\n 'ADMINISTRATION',\n 'DEBT_SERVICE',\n 'CAPITAL_PROJECTS',\n 'OTHER_EXPENSE',\n];\n\n/** Human label per project delivery status. */\nexport const GOV_PROJECT_STATUS_LABELS: Record<GovProjectStatus, string> = {\n PLANNED: 'Planned',\n TENDERED: 'Tendered',\n AWARDED: 'Awarded',\n IN_PROGRESS: 'In progress',\n SUSPENDED: 'Suspended',\n COMPLETED: 'Completed',\n CANCELLED: 'Cancelled',\n};\n\n/** Human label per commitment delivery status. */\nexport const GOV_COMMITMENT_STATUS_LABELS: Record<GovCommitmentStatus, string> = {\n PROMISED: 'Promised',\n IN_PROGRESS: 'In progress',\n DELIVERED: 'Delivered',\n STALLED: 'Stalled',\n ABANDONED: 'Abandoned',\n};\n\n/** Human label per provenance grade. */\nexport const GOV_VERIFICATION_LABELS: Record<GovVerificationStatus, string> = {\n UNVERIFIED: 'Unverified',\n OFFICIAL: 'Official',\n COMMUNITY_VERIFIED: 'Community verified',\n DISPUTED: 'Disputed',\n};\n"],"mappings":";AAgzDA,IAAa,IAAkE;CAC7E,cAAc;CACd,SAAS;CACT,WAAW;CACX,YAAY;CACZ,gBAAgB;CAChB,eAAe;CACf,aAAa;CACb,gBAAgB;CAChB,WAAW;CACX,WAAW;CACX,SAAS;CACT,YAAY;CACZ,SAAS;CACT,SAAS;CACT,SAAS;AACX,GAGa,IAA8D;CACzE,QAAQ;CACR,YAAY;CACZ,SAAS;CACT,UAAU;CACV,QAAQ;CACR,UAAU;CACV,gBAAgB;CAChB,cAAc;CACd,mBAAmB;CACnB,gBAAgB;CAChB,gBAAgB;CAChB,gBAAgB;CAChB,cAAc;CACd,iBAAiB;CACjB,SAAS;CACT,MAAM;CACN,QAAQ;CACR,MAAM;CACN,iBAAiB;CACjB,kBAAkB;CAClB,mBAAmB;CACnB,eAAe;CACf,SAAS;CACT,aAAa;CACb,QAAQ;CACR,KAAK;CACL,UAAU;CACV,UAAU;CACV,QAAQ;CACR,OAAO;AACT,GAGa,IAAgE;CAC3E,OAAO;CACP,kBAAkB;CAClB,QAAQ;CACR,6BAA6B;CAC7B,OAAO;CACP,mBAAmB;CACnB,4BAA4B;CAC5B,aAAa;CACb,eAAe;CACf,WAAW;CACX,YAAY;CACZ,qBAAqB;CACrB,sBAAsB;CACtB,QAAQ;CACR,aAAa;CACb,aAAa;CACb,eAAe;CACf,gBAAgB;CAChB,SAAS;CACT,wBAAwB;CACxB,wBAAwB;CACxB,gBAAgB;CAChB,cAAc;CACd,kBAAkB;CAClB,eAAe;AACjB,GAOa,IAAuD;CAClE;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;AACF,GAOa,IAAuD;CAClE;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;AACF,GAGa,IAA8D;CACzE,SAAS;CACT,UAAU;CACV,SAAS;CACT,aAAa;CACb,WAAW;CACX,WAAW;CACX,WAAW;AACb,GAGa,IAAoE;CAC/E,UAAU;CACV,aAAa;CACb,WAAW;CACX,SAAS;CACT,WAAW;AACb,GAGa,IAAiE;CAC5E,YAAY;CACZ,UAAU;CACV,oBAAoB;CACpB,UAAU;AACZ"}
1
+ {"version":3,"file":"intelligence.js","names":[],"sources":["../../../src/govcitizenhub/types/intelligence.ts"],"sourcesContent":["/**\n * GovCitizenHub — Community Intelligence type definitions (BOFF-5666)\n *\n * Every type below mirrors the FROZEN `wspace-govcitizenhub-svc` `intelligence`\n * module SDL byte-for-byte:\n * src/modules/intelligence/schema/{010-enums,020-jurisdiction,030-governance,\n * 040-finance,050-indicators,060-participation}.gql\n *\n * Conventions inherited from `./index.ts`:\n * - GraphQL enums become string-union types.\n * - `DateTime` is serialised as an ISO string.\n * - Nullable SDL fields are `| null`; fields that are only selected by a\n * *detail* query (relations, nested lists) are marked optional so a list\n * query's narrower selection still type-checks.\n * - `GovConnection<T>` is reused from `./index.ts` — never redefined.\n * - `User` / `File` are id-only federation stubs: file references are carried\n * as opaque `*FileId` strings and resolved through the `useFiles` hook.\n *\n * COUNTRY-AGNOSTIC: nothing here encodes one country's administrative tiers,\n * fiscal calendar or currency. Tiers are `GovAdminLevel` rows keyed by ISO\n * 3166-1 alpha-2; money carries an ISO 4217 `currencyCode` per record.\n *\n * @module govcitizenhub/types/intelligence\n */\n\nimport type { GovConnection, GovJson, GovServiceCategory, GovTrendDirection } from './index';\n\n// ============================================================================\n// Enums (010-enums.gql)\n// ============================================================================\n\n/** Publication lifecycle of a jurisdiction profile. DRAFT is never citizen-visible. */\nexport type GovJurisdictionStatus = 'DRAFT' | 'PUBLISHED' | 'ARCHIVED';\n\n/** Provenance grade of a published civic fact. */\nexport type GovVerificationStatus = 'UNVERIFIED' | 'OFFICIAL' | 'COMMUNITY_VERIFIED' | 'DISPUTED';\n\n/** Nature of an office holder's appointment. */\nexport type GovOfficeType = 'ELECTED' | 'ADMINISTRATIVE' | 'JUDICIAL' | 'ADVISORY';\n\n/** Delivery state of a public promise made by an office holder. */\nexport type GovCommitmentStatus =\n 'PROMISED' | 'IN_PROGRESS' | 'DELIVERED' | 'STALLED' | 'ABANDONED';\n\n/** Approval lifecycle of a published budget. */\nexport type GovBudgetStatus = 'DRAFT' | 'PROPOSED' | 'APPROVED' | 'REVISED' | 'CLOSED';\n\n/** Which side of the ledger a budget line sits on. */\nexport type GovBudgetLineKind = 'REVENUE' | 'EXPENSE';\n\n/**\n * Budget classification. `TAXES`..`OTHER_REVENUE` are revenue-side;\n * `EDUCATION`..`OTHER_EXPENSE` are expense-side. The backend rejects a category\n * that does not match its line's `kind` — see `GOV_REVENUE_CATEGORIES` /\n * `GOV_EXPENSE_CATEGORIES` for the same split.\n */\nexport type GovBudgetCategory =\n | 'TAXES'\n | 'FEES_AND_CHARGES'\n | 'GRANTS'\n | 'INTERGOVERNMENTAL_TRANSFERS'\n | 'LOANS'\n | 'INTERNATIONAL_AID'\n | 'PUBLIC_PRIVATE_PARTNERSHIP'\n | 'ASSET_SALES'\n | 'OTHER_REVENUE'\n | 'EDUCATION'\n | 'HEALTHCARE'\n | 'ROADS_AND_TRANSPORT'\n | 'WATER_AND_SANITATION'\n | 'ENERGY'\n | 'AGRICULTURE'\n | 'ENVIRONMENT'\n | 'PUBLIC_SAFETY'\n | 'SOCIAL_WELFARE'\n | 'HOUSING'\n | 'DIGITAL_INFRASTRUCTURE'\n | 'CULTURE_AND_RECREATION'\n | 'ADMINISTRATION'\n | 'DEBT_SERVICE'\n | 'CAPITAL_PROJECTS'\n | 'OTHER_EXPENSE';\n\n/** Where a development project's money comes from. */\nexport type GovFundingSource =\n | 'LOCAL_REVENUE'\n | 'STATE_GRANT'\n | 'NATIONAL_GRANT'\n | 'LOAN'\n | 'INTERNATIONAL_AID'\n | 'PUBLIC_PRIVATE_PARTNERSHIP'\n | 'CSR'\n | 'OTHER';\n\n/** Delivery lifecycle of a development project. */\nexport type GovProjectStatus =\n 'PLANNED' | 'TENDERED' | 'AWARDED' | 'IN_PROGRESS' | 'SUSPENDED' | 'COMPLETED' | 'CANCELLED';\n\n/** Delivery state of a project milestone. */\nexport type GovMilestoneStatus = 'PENDING' | 'IN_PROGRESS' | 'COMPLETED' | 'DELAYED' | 'CANCELLED';\n\n/** Sector taxonomy shared by indicators, projects and datasets. */\nexport type GovIndicatorDomain =\n | 'DEMOGRAPHICS'\n | 'ECONOMY'\n | 'EDUCATION'\n | 'HEALTHCARE'\n | 'INFRASTRUCTURE'\n | 'PUBLIC_SAFETY'\n | 'ENVIRONMENT'\n | 'SOCIAL_WELFARE'\n | 'UTILITIES'\n | 'TRANSPORT'\n | 'HOUSING'\n | 'GOVERNANCE'\n | 'DIGITAL'\n | 'TOURISM'\n | 'FINANCE';\n\n/** How an indicator's value should be read and formatted. */\nexport type GovIndicatorValueType =\n 'NUMBER' | 'PERCENTAGE' | 'RATIO' | 'CURRENCY' | 'INDEX' | 'COUNT' | 'DURATION_DAYS';\n\n/** Whether a rising value is good, bad or neutral. */\nexport type GovIndicatorDirection = 'HIGHER_IS_BETTER' | 'LOWER_IS_BETTER' | 'NEUTRAL';\n\n/** How often an indicator or dataset is expected to be refreshed. */\nexport type GovIndicatorPeriodicity =\n 'ANNUAL' | 'QUARTERLY' | 'MONTHLY' | 'WEEKLY' | 'DAILY' | 'ADHOC';\n\n/** Category of a mapped public asset, facility, organisation or landmark. */\nexport type GovAssetCategory =\n | 'SCHOOL'\n | 'UNIVERSITY'\n | 'LIBRARY'\n | 'HOSPITAL'\n | 'CLINIC'\n | 'PHARMACY'\n | 'POLICE_STATION'\n | 'FIRE_STATION'\n | 'EMERGENCY_SHELTER'\n | 'WATER_FACILITY'\n | 'POWER_FACILITY'\n | 'WASTE_FACILITY'\n | 'TRANSIT_STOP'\n | 'TRANSIT_STATION'\n | 'AIRPORT'\n | 'PORT'\n | 'BRIDGE'\n | 'PARK'\n | 'SPORTS_FACILITY'\n | 'COMMUNITY_CENTER'\n | 'GOVERNMENT_OFFICE'\n | 'PUBLIC_TOILET'\n | 'PARKING'\n | 'EV_CHARGING'\n | 'MARKET'\n | 'NGO'\n | 'BUSINESS'\n | 'LANDMARK'\n | 'MUSEUM'\n | 'OTHER';\n\n/** Who runs a public asset. */\nexport type GovAssetOperator = 'PUBLIC' | 'PRIVATE' | 'PUBLIC_PRIVATE' | 'NGO' | 'UNKNOWN';\n\n/** Operational state of a public asset. */\nexport type GovAssetStatus =\n 'OPERATIONAL' | 'UNDER_CONSTRUCTION' | 'UNDER_MAINTENANCE' | 'CLOSED' | 'PLANNED';\n\n/** Kind of electoral event. */\nexport type GovElectionType =\n 'GENERAL' | 'LOCAL' | 'BY_ELECTION' | 'REFERENDUM' | 'PRIMARY' | 'OTHER';\n\n/** Lifecycle of an electoral event. */\nexport type GovElectionStatus = 'SCHEDULED' | 'IN_PROGRESS' | 'COUNTING' | 'DECLARED' | 'CANCELLED';\n\n/** Kind of public participation exercise. */\nexport type GovConsultationType =\n 'SURVEY' | 'POLL' | 'PARTICIPATORY_BUDGET' | 'PUBLIC_HEARING' | 'FEEDBACK';\n\n/** Lifecycle of a consultation. Responses are only accepted while OPEN. */\nexport type GovConsultationStatus = 'DRAFT' | 'OPEN' | 'CLOSED' | 'PUBLISHED' | 'CANCELLED';\n\n/** Coarse sentiment recorded against a consultation response. */\nexport type GovSentiment = 'POSITIVE' | 'NEUTRAL' | 'NEGATIVE';\n\n/** Distribution format of an open-data dataset. */\nexport type GovDatasetFormat = 'CSV' | 'JSON' | 'GEOJSON' | 'XLSX' | 'PDF' | 'XML' | 'API';\n\n/** Open-data licence a dataset is released under. */\nexport type GovDataLicense =\n 'CC0' | 'CC_BY' | 'CC_BY_SA' | 'ODBL' | 'OGL' | 'PUBLIC_DOMAIN' | 'PROPRIETARY' | 'OTHER';\n\n/** Publication lifecycle of a dataset. */\nexport type GovDatasetStatus = 'DRAFT' | 'PUBLISHED' | 'DEPRECATED' | 'ARCHIVED';\n\n/** Category of a historical timeline entry. */\nexport type GovEventCategory =\n | 'POLICY'\n | 'PROJECT'\n | 'ELECTION'\n | 'DISASTER'\n | 'INFRASTRUCTURE'\n | 'DEMOGRAPHIC'\n | 'BUDGET'\n | 'AWARD'\n | 'OTHER';\n\n/** Whether a timeline entry was good, bad or neutral for the region. */\nexport type GovEventImpact = 'POSITIVE' | 'NEUTRAL' | 'NEGATIVE';\n\n/** Which Community Intelligence record a data-change proposal targets. */\nexport type GovIntelEntityType =\n | 'JURISDICTION'\n | 'OFFICIAL'\n | 'OFFICIAL_COMMITMENT'\n | 'BUDGET'\n | 'BUDGET_LINE'\n | 'PROJECT'\n | 'PROJECT_MILESTONE'\n | 'INDICATOR_VALUE'\n | 'PUBLIC_ASSET'\n | 'ELECTION'\n | 'ELECTION_RESULT'\n | 'DATASET'\n | 'EVENT';\n\n/** Review lifecycle of a proposed data correction. */\nexport type GovProposalStatus =\n 'SUBMITTED' | 'UNDER_REVIEW' | 'ACCEPTED' | 'REJECTED' | 'WITHDRAWN';\n\n/** Which peer set a jurisdiction is benchmarked against. */\nexport type GovBenchmarkScope =\n 'SIBLINGS' | 'CHILDREN' | 'PARENT_AVERAGE' | 'SAME_LEVEL_NATIONAL' | 'CUSTOM';\n\n/** Kind of deterministically derived insight surfaced on a jurisdiction profile. */\nexport type GovInsightKind =\n 'STRENGTH' | 'WEAKNESS' | 'EMERGING_ISSUE' | 'ANOMALY' | 'IMPROVEMENT' | 'RISK' | 'COVERAGE_GAP';\n\n/** How loudly an insight should be surfaced. */\nexport type GovInsightSeverity = 'INFO' | 'LOW' | 'MEDIUM' | 'HIGH';\n\n// ============================================================================\n// Administrative hierarchy & jurisdiction profile (020-jurisdiction.gql)\n// ============================================================================\n\n/** One configurable tier of a country's administrative hierarchy (rank 0 = national). */\n/** One tier of a seedable administrative-hierarchy preset. */\nexport interface GovAdminLevelPresetTier {\n rank: number;\n code: string;\n name: string;\n pluralName: string;\n isElectoral: boolean;\n}\n\n/**\n * A hierarchy a country can be seeded from. A country-specific preset uses the\n * terminology that country actually uses; the structural fallbacks are offered\n * for countries with no bundled chain.\n */\nexport interface GovAdminLevelPreset {\n key: string;\n label: string;\n description: string;\n isCountrySpecific: boolean;\n tiers: GovAdminLevelPresetTier[];\n}\n\nexport interface GovAdminLevel {\n id: string;\n workspaceId: string;\n /** ISO 3166-1 alpha-2 country code this tier belongs to. */\n countryCode: string;\n /** Depth of the tier: 0 is the national level, ascending downward. */\n rank: number;\n /** Stable machine code, unique per country (e.g. STATE, DISTRICT, WARD). */\n code: string;\n name: string;\n pluralName: string;\n description?: string | null;\n /** True when the tier elects representatives. */\n isElectoral: boolean;\n createdAt: string;\n updatedAt: string;\n /** Published + draft jurisdictions currently sitting at this tier. */\n jurisdictionCount: number;\n}\n\n/** The permanent digital profile of one administrative region. */\nexport interface GovJurisdiction {\n id: string;\n workspaceId: string;\n parentId?: string | null;\n adminLevelId: string;\n countryCode: string;\n\n name: string;\n localName?: string | null;\n officialCode?: string | null;\n slug: string;\n status: GovJurisdictionStatus;\n /** Materialized ancestor path, `/<id>/<id>/`. */\n path: string;\n depth: number;\n\n summary?: string | null;\n establishedOn?: string | null;\n headquarters?: string | null;\n officialWebsite?: string | null;\n contactEmail?: string | null;\n contactPhone?: string | null;\n /** Public emergency contacts: `[{ label, number }]`. */\n emergencyNumbers?: GovJson;\n timezone?: string | null;\n languages: string[];\n /** ISO 4217 currency code used by this region. */\n currencyCode?: string | null;\n climateSummary?: string | null;\n\n areaSqKm?: number | null;\n population?: number | null;\n populationYear?: number | null;\n households?: number | null;\n centroidLat?: number | null;\n centroidLng?: number | null;\n /** Population per square kilometre, derived when both inputs are published. */\n populationDensity?: number | null;\n\n /** wspace-files-svc File id holding the boundary GeoJSON. */\n boundaryFileId?: string | null;\n bannerFileId?: string | null;\n crestFileId?: string | null;\n\n tags: string[];\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification: GovVerificationStatus;\n publishedAt?: string | null;\n createdAt: string;\n updatedAt: string;\n\n adminLevel?: GovAdminLevel | null;\n parent?: GovJurisdiction | null;\n children?: GovJurisdiction[];\n /** Ancestors ordered from the root down to the immediate parent. */\n ancestors?: GovJurisdiction[];\n}\n\n/** A node in the administrative hierarchy tree, with its children inlined. */\nexport interface GovJurisdictionTreeNode {\n id: string;\n name: string;\n slug: string;\n status: GovJurisdictionStatus;\n depth: number;\n adminLevelCode: string;\n adminLevelName: string;\n population?: number | null;\n childCount: number;\n children: GovJurisdictionTreeNode[];\n}\n\n/** Single page-load aggregate for the jurisdiction profile screen. */\nexport interface GovJurisdictionOverview {\n jurisdiction: GovJurisdiction;\n adminLevel?: GovAdminLevel | null;\n parent?: GovJurisdiction | null;\n childCount: number;\n officialCount: number;\n currentBudget?: GovBudget | null;\n activeProjectCount: number;\n completedProjectCount: number;\n publishedDatasetCount: number;\n openConsultationCount: number;\n publicAssetCount: number;\n followerCount: number;\n /** Whether the calling actor follows this jurisdiction. */\n isFollowedByMe: boolean;\n scorecard?: GovJurisdictionScorecard | null;\n insights: GovJurisdictionInsight[];\n}\n\n// ============================================================================\n// Governance, commitments, elections, timeline (030-governance.gql)\n// ============================================================================\n\n/** An elected representative or administrative office holder for a jurisdiction. */\nexport interface GovOfficial {\n id: string;\n workspaceId: string;\n jurisdictionId: string;\n fullName: string;\n localName?: string | null;\n officeTitle: string;\n officeType: GovOfficeType;\n department?: string | null;\n party?: string | null;\n isIndependent: boolean;\n photoFileId?: string | null;\n biography?: string | null;\n contactEmail?: string | null;\n contactPhone?: string | null;\n officeAddress?: string | null;\n officeHours?: string | null;\n /** Public social profiles: `[{ platform, url }]`. */\n socialProfiles?: GovJson;\n termStart?: string | null;\n termEnd?: string | null;\n termDurationMonths?: number | null;\n electedOn?: string | null;\n nextElectionOn?: string | null;\n /** Published sitting/house attendance, 0-100. */\n attendancePercent?: number | null;\n votingRecordUrl?: string | null;\n committees: string[];\n responsibilities?: string | null;\n isCurrent: boolean;\n displayOrder: number;\n /** Opaque global-auth user id when the office holder also has a platform account. */\n linkedUserId?: string | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification: GovVerificationStatus;\n createdAt: string;\n updatedAt: string;\n\n /** Delivered commitments as a share of all non-abandoned commitments, 0-100. */\n commitmentDeliveryRate?: number | null;\n jurisdiction?: GovJurisdiction | null;\n commitments?: GovOfficialCommitment[];\n}\n\n/** A public promise or pledge, tracked from statement to delivery. */\nexport interface GovOfficialCommitment {\n id: string;\n workspaceId: string;\n officialId: string;\n jurisdictionId: string;\n title: string;\n description?: string | null;\n domain?: GovIndicatorDomain | null;\n promisedOn?: string | null;\n targetDate?: string | null;\n status: GovCommitmentStatus;\n progressPercent: number;\n /** Opaque GovProject id when a project delivers this commitment. */\n linkedProjectId?: string | null;\n evidenceUrl?: string | null;\n evidenceFileIds: string[];\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification: GovVerificationStatus;\n createdAt: string;\n updatedAt: string;\n /** True when the target date has passed and the commitment is not DELIVERED. */\n isOverdue: boolean;\n official?: GovOfficial | null;\n}\n\n/** A past or scheduled electoral event for a jurisdiction. */\nexport interface GovElection {\n id: string;\n workspaceId: string;\n jurisdictionId: string;\n name: string;\n electionType: GovElectionType;\n officeTitle?: string | null;\n electionDate: string;\n status: GovElectionStatus;\n registeredVoters?: number | null;\n votesCast?: number | null;\n validVotes?: number | null;\n invalidVotes?: number | null;\n turnoutPercent?: number | null;\n resultDeclaredOn?: string | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification: GovVerificationStatus;\n createdAt: string;\n updatedAt: string;\n\n /** Winning margin in votes between the top two declared results. */\n winningMarginVotes?: number | null;\n /** Winning margin as a percentage of valid votes. */\n winningMarginPercent?: number | null;\n jurisdiction?: GovJurisdiction | null;\n results?: GovElectionResult[];\n}\n\n/** One candidate's declared result within an election. */\nexport interface GovElectionResult {\n id: string;\n workspaceId: string;\n electionId: string;\n candidateName: string;\n party?: string | null;\n isIndependent: boolean;\n votes: number;\n votePercent?: number | null;\n position?: number | null;\n isWinner: boolean;\n photoFileId?: string | null;\n /** Opaque GovOfficial id once the winner is seated. */\n officialId?: string | null;\n createdAt: string;\n updatedAt: string;\n}\n\n/** A dated entry on the region's historical timeline. */\nexport interface GovJurisdictionEvent {\n id: string;\n workspaceId: string;\n jurisdictionId: string;\n title: string;\n description?: string | null;\n occurredOn: string;\n category: GovEventCategory;\n impact?: GovEventImpact | null;\n linkedProjectId?: string | null;\n linkedElectionId?: string | null;\n linkedBudgetId?: string | null;\n imageFileId?: string | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification: GovVerificationStatus;\n createdAt: string;\n updatedAt: string;\n}\n\n// ============================================================================\n// Public finance & development projects (040-finance.gql)\n// ============================================================================\n\n/** One fiscal period's published budget. */\nexport interface GovBudget {\n id: string;\n workspaceId: string;\n jurisdictionId: string;\n fiscalYear: string;\n periodStart: string;\n periodEnd: string;\n /** ISO 4217 currency this budget is denominated in. */\n currencyCode: string;\n status: GovBudgetStatus;\n totalRevenuePlanned: number;\n totalRevenueActual?: number | null;\n totalExpensePlanned: number;\n totalExpenseActual?: number | null;\n populationAtPublication?: number | null;\n summary?: string | null;\n /** wspace-files-svc File id for the published budget document. */\n documentFileId?: string | null;\n approvedOn?: string | null;\n publishedAt?: string | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification: GovVerificationStatus;\n createdAt: string;\n updatedAt: string;\n\n jurisdiction?: GovJurisdiction | null;\n lines?: GovBudgetLine[];\n}\n\n/** One revenue source or expenditure head within a budget. */\nexport interface GovBudgetLine {\n id: string;\n workspaceId: string;\n budgetId: string;\n kind: GovBudgetLineKind;\n category: GovBudgetCategory;\n label: string;\n department?: string | null;\n /** Government functional classification code, where one is published. */\n functionCode?: string | null;\n plannedAmount: number;\n actualAmount?: number | null;\n previousYearAmount?: number | null;\n notes?: string | null;\n displayOrder: number;\n createdAt: string;\n updatedAt: string;\n /** `actualAmount - plannedAmount`; null until an actual is recorded. */\n variance?: number | null;\n /** Variance as a percentage of the planned amount; null when planned is zero. */\n variancePercent?: number | null;\n}\n\n/** One category's rolled-up planned/actual position within a budget. */\nexport interface GovBudgetCategoryRow {\n kind: GovBudgetLineKind;\n category: GovBudgetCategory;\n planned: number;\n actual?: number | null;\n variance?: number | null;\n variancePercent?: number | null;\n /** This category's share of its side of the ledger, 0-100. */\n sharePercent: number;\n}\n\n/** Planned vs actual execution of a budget, rolled up by category. */\nexport interface GovBudgetExecution {\n budgetId: string;\n fiscalYear: string;\n currencyCode: string;\n plannedRevenue: number;\n actualRevenue?: number | null;\n plannedExpense: number;\n actualExpense?: number | null;\n /** Actual expenditure as a percentage of planned; null when nothing is planned. */\n executionPercent?: number | null;\n /** Planned expenditure per head; null when no population is snapshotted. */\n perCapitaExpense?: number | null;\n /** Actual expenditure per head; null when either input is missing. */\n perCapitaActualExpense?: number | null;\n byCategory: GovBudgetCategoryRow[];\n}\n\n/** A public works / development project, from tender through to completion. */\nexport interface GovProject {\n id: string;\n workspaceId: string;\n jurisdictionId: string;\n /** Owning GovAgency, when the project is agency-run. */\n agencyId?: string | null;\n name: string;\n code?: string | null;\n description?: string | null;\n domain: GovIndicatorDomain;\n department?: string | null;\n contractorName?: string | null;\n contractorRegistrationId?: string | null;\n fundingSource: GovFundingSource;\n budgetAmount?: number | null;\n actualCost?: number | null;\n currencyCode?: string | null;\n tenderReference?: string | null;\n tenderUrl?: string | null;\n awardedOn?: string | null;\n startDate?: string | null;\n plannedCompletionDate?: string | null;\n actualCompletionDate?: string | null;\n status: GovProjectStatus;\n progressPercent: number;\n delayReason?: string | null;\n locationLabel?: string | null;\n latitude?: number | null;\n longitude?: number | null;\n imageFileIds: string[];\n documentFileIds: string[];\n beneficiaryCount?: number | null;\n tags: string[];\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification: GovVerificationStatus;\n publishedAt?: string | null;\n createdAt: string;\n updatedAt: string;\n\n /** Days late, derived at read time. Never negative; null with no planned date. */\n delayDays?: number | null;\n /** `actualCost - budgetAmount`; null until an actual cost is recorded. */\n costVariance?: number | null;\n jurisdiction?: GovJurisdiction | null;\n milestones?: GovProjectMilestone[];\n}\n\n/** A dated checkpoint within a project's delivery timeline. */\nexport interface GovProjectMilestone {\n id: string;\n workspaceId: string;\n projectId: string;\n name: string;\n description?: string | null;\n dueDate?: string | null;\n completedOn?: string | null;\n status: GovMilestoneStatus;\n progressPercent: number;\n evidenceFileId?: string | null;\n displayOrder: number;\n createdAt: string;\n updatedAt: string;\n /** True when the due date has passed and the milestone is not COMPLETED. */\n isOverdue: boolean;\n}\n\n// ============================================================================\n// Indicators, scorecards, benchmarking, reused performance (050-indicators.gql)\n// ============================================================================\n\n/** The definition of a measurable civic KPI. */\nexport interface GovIndicator {\n id: string;\n workspaceId: string;\n /** Stable dotted code, unique per workspace (e.g. EDU.LITERACY.RATE). */\n code: string;\n name: string;\n description?: string | null;\n domain: GovIndicatorDomain;\n /** Display unit (%, per 1,000, days). */\n unit: string;\n valueType: GovIndicatorValueType;\n direction: GovIndicatorDirection;\n periodicity: GovIndicatorPeriodicity;\n methodology?: string | null;\n targetValue?: number | null;\n /** Normalization floor used when scoring this indicator 0-100. */\n minValue?: number | null;\n /** Normalization ceiling used when scoring this indicator 0-100. */\n maxValue?: number | null;\n /** Only core indicators contribute to the composite scorecard. */\n isCore: boolean;\n weight: number;\n isActive: boolean;\n /** UN Sustainable Development Goal number, 1-17. */\n sdgGoal?: number | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n createdAt: string;\n updatedAt: string;\n}\n\n/** One measured fact: an indicator, for a jurisdiction, over a period, with provenance. */\nexport interface GovIndicatorValue {\n id: string;\n workspaceId: string;\n indicatorId: string;\n jurisdictionId: string;\n /** Human period label matching the indicator's periodicity (2026, 2026-Q1). */\n periodLabel: string;\n periodStart: string;\n periodEnd: string;\n value: number;\n /** Optional raw components, so a rate can be audited back to its inputs. */\n numerator?: number | null;\n denominator?: number | null;\n targetValue?: number | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n sourceDate?: string | null;\n /** Opaque GovDataset id this value was derived from, when applicable. */\n datasetId?: string | null;\n verification: GovVerificationStatus;\n notes?: string | null;\n publishedAt?: string | null;\n createdAt: string;\n updatedAt: string;\n\n indicator?: GovIndicator | null;\n jurisdiction?: GovJurisdiction | null;\n}\n\n/** One point on an indicator's time series for a jurisdiction. */\nexport interface GovIndicatorPoint {\n periodLabel: string;\n periodStart: string;\n value: number;\n targetValue?: number | null;\n verification: GovVerificationStatus;\n}\n\n/** An indicator's full published history for one jurisdiction. */\nexport interface GovIndicatorSeries {\n indicator: GovIndicator;\n jurisdictionId: string;\n points: GovIndicatorPoint[];\n latestValue?: number | null;\n latestPeriodLabel?: string | null;\n /** Percentage change between the two most recent published points. */\n changePercent?: number | null;\n /** Direction of travel, already adjusted for whether higher is better. */\n trend: GovTrendDirection;\n}\n\n/** A single domain's contribution to a jurisdiction's composite score. */\nexport interface GovDomainScore {\n domain: GovIndicatorDomain;\n /** Weighted 0-100 score; null when no core indicator in this domain is measured. */\n score?: number | null;\n /** Core indicators defined in this domain. */\n indicatorCount: number;\n /** Core indicators in this domain that actually have a published value. */\n measuredCount: number;\n trend: GovTrendDirection;\n changePercent?: number | null;\n}\n\n/** A jurisdiction's composite performance scorecard. */\nexport interface GovJurisdictionScorecard {\n jurisdictionId: string;\n jurisdictionName: string;\n periodLabel?: string | null;\n /** Weighted composite 0-100; null when coverage is below the publishable threshold. */\n overallScore?: number | null;\n domains: GovDomainScore[];\n /** Measured core indicators as a percentage of defined core indicators. */\n coveragePercent: number;\n indicatorCount: number;\n measuredCount: number;\n generatedAt: string;\n}\n\n/** One jurisdiction's standing within a benchmark peer set. */\nexport interface GovBenchmarkEntry {\n jurisdictionId: string;\n jurisdictionName: string;\n value: number;\n rank: number;\n}\n\n/** A jurisdiction benchmarked against a peer set for one indicator. */\nexport interface GovBenchmarkResult {\n indicator: GovIndicator;\n jurisdictionId: string;\n periodLabel?: string | null;\n scope: GovBenchmarkScope;\n /** The subject's own entry; null when the subject has no value for the period. */\n subject?: GovBenchmarkEntry | null;\n peers: GovBenchmarkEntry[];\n peerCount: number;\n /** The subject's percentile within the peer set, 0-100. */\n percentile?: number | null;\n average?: number | null;\n median?: number | null;\n best?: GovBenchmarkEntry | null;\n worst?: GovBenchmarkEntry | null;\n /** False when the peer set was too small to publish a rank. */\n isRankPublished: boolean;\n}\n\n/** A deterministically derived, evidence-carrying observation about a jurisdiction. */\nexport interface GovJurisdictionInsight {\n kind: GovInsightKind;\n severity: GovInsightSeverity;\n title: string;\n detail: string;\n domain?: GovIndicatorDomain | null;\n indicatorCode?: string | null;\n evidence: string[];\n generatedAt: string;\n}\n\n/** Per-service row of a jurisdiction's service-delivery performance rollup. */\nexport interface GovServicePerformanceRow {\n serviceId: string;\n serviceName: string;\n applications: number;\n approved: number;\n rejected: number;\n pending: number;\n avgProcessingHours?: number | null;\n slaDays: number;\n slaCompliancePercent?: number | null;\n}\n\n/** Per-agency row of a jurisdiction's service-delivery performance rollup. */\nexport interface GovAgencyPerformanceRow {\n agencyId: string;\n agencyName: string;\n applications: number;\n approved: number;\n rejected: number;\n pending: number;\n avgProcessingHours?: number | null;\n slaCompliancePercent?: number | null;\n}\n\n/** Service-delivery performance for a jurisdiction, rolled up from live casework. */\nexport interface GovServicePerformance {\n jurisdictionId: string;\n totalApplications: number;\n approvedCount: number;\n rejectedCount: number;\n pendingCount: number;\n /** Approvals as a percentage of decided applications; null when nothing is decided. */\n approvalRate?: number | null;\n avgProcessingHours?: number | null;\n slaBreachedCount: number;\n slaCompliancePercent?: number | null;\n byService: GovServicePerformanceRow[];\n byAgency: GovAgencyPerformanceRow[];\n}\n\n/** Per-category row of a jurisdiction's grievance rollup. */\nexport interface GovGrievanceCategoryRow {\n category: GovServiceCategory;\n total: number;\n resolved: number;\n avgResolutionHours?: number | null;\n}\n\n/** A recurring-issue cluster; cells below the suppression threshold are omitted. */\nexport interface GovGrievanceHotspot {\n locationLabel: string;\n latitude?: number | null;\n longitude?: number | null;\n count: number;\n topCategory: GovServiceCategory;\n}\n\n/** Citizen-issue insight for a jurisdiction, rolled up from live grievances. */\nexport interface GovGrievanceInsights {\n jurisdictionId: string;\n total: number;\n open: number;\n inProgress: number;\n resolved: number;\n avgResolutionHours?: number | null;\n byCategory: GovGrievanceCategoryRow[];\n hotspots: GovGrievanceHotspot[];\n}\n\n// ============================================================================\n// Assets, participation, open data, following, corrections (060-participation.gql)\n// ============================================================================\n\n/** The mappable registry of everything physical or organisational in a jurisdiction. */\nexport interface GovPublicAsset {\n id: string;\n workspaceId: string;\n jurisdictionId: string;\n name: string;\n category: GovAssetCategory;\n subCategory?: string | null;\n description?: string | null;\n operator: GovAssetOperator;\n status: GovAssetStatus;\n address?: string | null;\n latitude?: number | null;\n longitude?: number | null;\n capacity?: number | null;\n /** Unit the capacity is counted in (beds, students, vehicles). */\n capacityUnit?: string | null;\n contactPhone?: string | null;\n contactEmail?: string | null;\n website?: string | null;\n openingHours?: string | null;\n /** Whether the facility is accessible to people with disabilities. */\n isAccessible?: boolean | null;\n establishedOn?: string | null;\n imageFileId?: string | null;\n /** Category-specific attributes, keyed per the documented convention. */\n metadata?: GovJson;\n tags: string[];\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification: GovVerificationStatus;\n createdAt: string;\n updatedAt: string;\n}\n\n/** A count of assets in one category, for map legends and registry summaries. */\nexport interface GovAssetCategoryCount {\n category: GovAssetCategory;\n count: number;\n}\n\n/** A survey, poll, public hearing or participatory-budgeting exercise. */\nexport interface GovConsultation {\n id: string;\n workspaceId: string;\n jurisdictionId: string;\n title: string;\n description?: string | null;\n consultationType: GovConsultationType;\n status: GovConsultationStatus;\n opensAt?: string | null;\n closesAt?: string | null;\n /** `[{ id, label, type, options?, required, min?, max? }]`. */\n questions: GovJson;\n allowAnonymous: boolean;\n /** Pot to distribute, for participatory-budgeting consultations. */\n budgetAmount?: number | null;\n currencyCode?: string | null;\n responseCount: number;\n /** Aggregated, publishable results. Raw responses are never exposed. */\n resultsSummary?: GovJson;\n resultsPublishedAt?: string | null;\n documentFileId?: string | null;\n tags: string[];\n createdAt: string;\n updatedAt: string;\n /** True when the consultation is OPEN and within its date window. */\n isAcceptingResponses: boolean;\n /** Whether the calling actor has already responded. */\n hasRespondedByMe: boolean;\n jurisdiction?: GovJurisdiction | null;\n}\n\n/** One participant's submission. Only ever readable by its own author. */\nexport interface GovConsultationResponse {\n id: string;\n workspaceId: string;\n consultationId: string;\n jurisdictionId: string;\n respondentActorId?: string | null;\n /** `[{ questionId, value }]`. */\n answers: GovJson;\n sentiment?: GovSentiment | null;\n submittedAt: string;\n}\n\n/** Aggregated answers for one consultation question. */\nexport interface GovConsultationQuestionResult {\n questionId: string;\n label: string;\n type: string;\n responseCount: number;\n /** Aggregate for the question. Free-text questions carry a count only. */\n aggregate: GovJson;\n}\n\n/** Publishable results for a consultation. */\nexport interface GovConsultationResults {\n consultationId: string;\n status: GovConsultationStatus;\n responseCount: number;\n resultsPublishedAt?: string | null;\n questions: GovConsultationQuestionResult[];\n /** True when the result set is below the suppression threshold and withheld. */\n isSuppressed: boolean;\n}\n\n/** An open-data catalogue entry. Metadata only — the bytes live elsewhere. */\nexport interface GovDataset {\n id: string;\n workspaceId: string;\n jurisdictionId?: string | null;\n name: string;\n slug: string;\n description?: string | null;\n domain?: GovIndicatorDomain | null;\n format: GovDatasetFormat;\n license: GovDataLicense;\n licenseUrl?: string | null;\n version: string;\n /** wspace-files-svc File id holding the dataset. */\n fileId?: string | null;\n /** Publisher-hosted location, when the data is not held on the platform. */\n externalUrl?: string | null;\n periodStart?: string | null;\n periodEnd?: string | null;\n updateFrequency?: GovIndicatorPeriodicity | null;\n rowCount?: number | null;\n sizeBytes?: number | null;\n publisher?: string | null;\n contactEmail?: string | null;\n status: GovDatasetStatus;\n publishedAt?: string | null;\n downloadCount: number;\n tags: string[];\n createdAt: string;\n updatedAt: string;\n jurisdiction?: GovJurisdiction | null;\n}\n\n/** A citizen's subscription to a jurisdiction's updates. */\nexport interface GovJurisdictionFollow {\n id: string;\n workspaceId: string;\n jurisdictionId: string;\n actorId: string;\n /** Delivery channels: IN_APP | EMAIL. */\n channels: string[];\n /** Topics: BUDGET | PROJECT | ELECTION | CONSULTATION | EMERGENCY | INDICATOR | DATASET. */\n topics: string[];\n createdAt: string;\n jurisdiction?: GovJurisdiction | null;\n}\n\n/** A proposed correction to published civic data, with evidence, reviewed by an official. */\nexport interface GovDataChangeProposal {\n id: string;\n workspaceId: string;\n jurisdictionId: string;\n entityType: GovIntelEntityType;\n entityId: string;\n fieldPath: string;\n currentValue?: string | null;\n proposedValue: string;\n rationale: string;\n evidenceUrl?: string | null;\n evidenceFileIds: string[];\n status: GovProposalStatus;\n submittedByActorId: string;\n submittedAt: string;\n reviewedByActorId?: string | null;\n reviewedAt?: string | null;\n reviewNote?: string | null;\n appliedAt?: string | null;\n createdAt: string;\n updatedAt: string;\n jurisdiction?: GovJurisdiction | null;\n}\n\n// ============================================================================\n// Connections — every one is the frozen `{ items, pageInfo }` shape.\n// There is NO `totalCount` anywhere in this contract.\n// ============================================================================\n\nexport type GovAdminLevelConnection = GovConnection<GovAdminLevel>;\nexport type GovJurisdictionConnection = GovConnection<GovJurisdiction>;\nexport type GovOfficialConnection = GovConnection<GovOfficial>;\nexport type GovOfficialCommitmentConnection = GovConnection<GovOfficialCommitment>;\nexport type GovElectionConnection = GovConnection<GovElection>;\nexport type GovJurisdictionEventConnection = GovConnection<GovJurisdictionEvent>;\nexport type GovBudgetConnection = GovConnection<GovBudget>;\nexport type GovProjectConnection = GovConnection<GovProject>;\nexport type GovIndicatorConnection = GovConnection<GovIndicator>;\nexport type GovIndicatorValueConnection = GovConnection<GovIndicatorValue>;\nexport type GovPublicAssetConnection = GovConnection<GovPublicAsset>;\nexport type GovConsultationConnection = GovConnection<GovConsultation>;\nexport type GovDatasetConnection = GovConnection<GovDataset>;\nexport type GovDataChangeProposalConnection = GovConnection<GovDataChangeProposal>;\n\n// ============================================================================\n// Filter inputs\n// ============================================================================\n\nexport interface GovJurisdictionFilterInput {\n parentId?: string | null;\n adminLevelId?: string | null;\n countryCode?: string | null;\n status?: GovJurisdictionStatus | null;\n /** Free-text match against name, local name and official code. */\n search?: string | null;\n /** Restrict to descendants of this jurisdiction (materialized-path subtree). */\n ancestorId?: string | null;\n tags?: string[] | null;\n}\n\nexport interface GovOfficialFilterInput {\n jurisdictionId?: string | null;\n officeType?: GovOfficeType | null;\n isCurrent?: boolean | null;\n party?: string | null;\n search?: string | null;\n}\n\nexport interface GovOfficialCommitmentFilterInput {\n officialId?: string | null;\n jurisdictionId?: string | null;\n status?: GovCommitmentStatus | null;\n domain?: GovIndicatorDomain | null;\n}\n\nexport interface GovElectionFilterInput {\n jurisdictionId?: string | null;\n electionType?: GovElectionType | null;\n status?: GovElectionStatus | null;\n fromDate?: string | null;\n toDate?: string | null;\n}\n\nexport interface GovBudgetFilterInput {\n jurisdictionId?: string | null;\n fiscalYear?: string | null;\n status?: GovBudgetStatus | null;\n}\n\nexport interface GovProjectFilterInput {\n jurisdictionId?: string | null;\n agencyId?: string | null;\n status?: GovProjectStatus | null;\n domain?: GovIndicatorDomain | null;\n fundingSource?: GovFundingSource | null;\n department?: string | null;\n search?: string | null;\n /** Only projects running late by at least one day. */\n delayedOnly?: boolean | null;\n}\n\nexport interface GovIndicatorFilterInput {\n domain?: GovIndicatorDomain | null;\n isCore?: boolean | null;\n isActive?: boolean | null;\n sdgGoal?: number | null;\n search?: string | null;\n}\n\nexport interface GovIndicatorValueFilterInput {\n jurisdictionId?: string | null;\n indicatorId?: string | null;\n indicatorCode?: string | null;\n domain?: GovIndicatorDomain | null;\n periodLabel?: string | null;\n fromPeriodStart?: string | null;\n toPeriodStart?: string | null;\n verification?: GovVerificationStatus | null;\n}\n\nexport interface GovPublicAssetFilterInput {\n jurisdictionId?: string | null;\n category?: GovAssetCategory | null;\n operator?: GovAssetOperator | null;\n status?: GovAssetStatus | null;\n isAccessible?: boolean | null;\n search?: string | null;\n /** Only assets that carry coordinates, for map layers. */\n mappableOnly?: boolean | null;\n}\n\nexport interface GovConsultationFilterInput {\n jurisdictionId?: string | null;\n consultationType?: GovConsultationType | null;\n status?: GovConsultationStatus | null;\n openOnly?: boolean | null;\n}\n\nexport interface GovDatasetFilterInput {\n jurisdictionId?: string | null;\n domain?: GovIndicatorDomain | null;\n format?: GovDatasetFormat | null;\n license?: GovDataLicense | null;\n status?: GovDatasetStatus | null;\n search?: string | null;\n}\n\nexport interface GovDataChangeProposalFilterInput {\n jurisdictionId?: string | null;\n entityType?: GovIntelEntityType | null;\n entityId?: string | null;\n status?: GovProposalStatus | null;\n}\n\n// ============================================================================\n// Create / update inputs\n// ============================================================================\n\nexport interface GovCreateAdminLevelInput {\n countryCode: string;\n rank: number;\n code: string;\n name: string;\n pluralName: string;\n description?: string | null;\n isElectoral?: boolean | null;\n}\n\nexport interface GovUpdateAdminLevelInput {\n rank?: number | null;\n code?: string | null;\n name?: string | null;\n pluralName?: string | null;\n description?: string | null;\n isElectoral?: boolean | null;\n}\n\nexport interface GovCreateJurisdictionInput {\n parentId?: string | null;\n adminLevelId: string;\n countryCode: string;\n name: string;\n localName?: string | null;\n officialCode?: string | null;\n slug?: string | null;\n summary?: string | null;\n establishedOn?: string | null;\n headquarters?: string | null;\n officialWebsite?: string | null;\n contactEmail?: string | null;\n contactPhone?: string | null;\n emergencyNumbers?: GovJson;\n timezone?: string | null;\n languages?: string[] | null;\n currencyCode?: string | null;\n climateSummary?: string | null;\n areaSqKm?: number | null;\n population?: number | null;\n populationYear?: number | null;\n households?: number | null;\n centroidLat?: number | null;\n centroidLng?: number | null;\n boundaryFileId?: string | null;\n bannerFileId?: string | null;\n crestFileId?: string | null;\n tags?: string[] | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification?: GovVerificationStatus | null;\n}\n\nexport interface GovUpdateJurisdictionInput {\n parentId?: string | null;\n adminLevelId?: string | null;\n name?: string | null;\n localName?: string | null;\n officialCode?: string | null;\n summary?: string | null;\n establishedOn?: string | null;\n headquarters?: string | null;\n officialWebsite?: string | null;\n contactEmail?: string | null;\n contactPhone?: string | null;\n emergencyNumbers?: GovJson;\n timezone?: string | null;\n languages?: string[] | null;\n currencyCode?: string | null;\n climateSummary?: string | null;\n areaSqKm?: number | null;\n population?: number | null;\n populationYear?: number | null;\n households?: number | null;\n centroidLat?: number | null;\n centroidLng?: number | null;\n boundaryFileId?: string | null;\n bannerFileId?: string | null;\n crestFileId?: string | null;\n tags?: string[] | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification?: GovVerificationStatus | null;\n}\n\nexport interface GovCreateOfficialInput {\n jurisdictionId: string;\n fullName: string;\n localName?: string | null;\n officeTitle: string;\n officeType?: GovOfficeType | null;\n department?: string | null;\n party?: string | null;\n isIndependent?: boolean | null;\n photoFileId?: string | null;\n biography?: string | null;\n contactEmail?: string | null;\n contactPhone?: string | null;\n officeAddress?: string | null;\n officeHours?: string | null;\n socialProfiles?: GovJson;\n termStart?: string | null;\n termEnd?: string | null;\n termDurationMonths?: number | null;\n electedOn?: string | null;\n nextElectionOn?: string | null;\n attendancePercent?: number | null;\n votingRecordUrl?: string | null;\n committees?: string[] | null;\n responsibilities?: string | null;\n isCurrent?: boolean | null;\n displayOrder?: number | null;\n linkedUserId?: string | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification?: GovVerificationStatus | null;\n}\n\nexport interface GovUpdateOfficialInput {\n fullName?: string | null;\n localName?: string | null;\n officeTitle?: string | null;\n officeType?: GovOfficeType | null;\n department?: string | null;\n party?: string | null;\n isIndependent?: boolean | null;\n photoFileId?: string | null;\n biography?: string | null;\n contactEmail?: string | null;\n contactPhone?: string | null;\n officeAddress?: string | null;\n officeHours?: string | null;\n socialProfiles?: GovJson;\n termStart?: string | null;\n termEnd?: string | null;\n termDurationMonths?: number | null;\n electedOn?: string | null;\n nextElectionOn?: string | null;\n attendancePercent?: number | null;\n votingRecordUrl?: string | null;\n committees?: string[] | null;\n responsibilities?: string | null;\n isCurrent?: boolean | null;\n displayOrder?: number | null;\n linkedUserId?: string | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification?: GovVerificationStatus | null;\n}\n\nexport interface GovCreateOfficialCommitmentInput {\n officialId: string;\n title: string;\n description?: string | null;\n domain?: GovIndicatorDomain | null;\n promisedOn?: string | null;\n targetDate?: string | null;\n status?: GovCommitmentStatus | null;\n progressPercent?: number | null;\n linkedProjectId?: string | null;\n evidenceUrl?: string | null;\n evidenceFileIds?: string[] | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification?: GovVerificationStatus | null;\n}\n\nexport interface GovUpdateOfficialCommitmentInput {\n title?: string | null;\n description?: string | null;\n domain?: GovIndicatorDomain | null;\n promisedOn?: string | null;\n targetDate?: string | null;\n status?: GovCommitmentStatus | null;\n progressPercent?: number | null;\n linkedProjectId?: string | null;\n evidenceUrl?: string | null;\n evidenceFileIds?: string[] | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification?: GovVerificationStatus | null;\n}\n\nexport interface GovCreateElectionInput {\n jurisdictionId: string;\n name: string;\n electionType?: GovElectionType | null;\n officeTitle?: string | null;\n electionDate: string;\n status?: GovElectionStatus | null;\n registeredVoters?: number | null;\n votesCast?: number | null;\n validVotes?: number | null;\n invalidVotes?: number | null;\n resultDeclaredOn?: string | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification?: GovVerificationStatus | null;\n}\n\nexport interface GovUpdateElectionInput {\n name?: string | null;\n electionType?: GovElectionType | null;\n officeTitle?: string | null;\n electionDate?: string | null;\n status?: GovElectionStatus | null;\n registeredVoters?: number | null;\n votesCast?: number | null;\n validVotes?: number | null;\n invalidVotes?: number | null;\n resultDeclaredOn?: string | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification?: GovVerificationStatus | null;\n}\n\nexport interface GovElectionResultInput {\n candidateName: string;\n party?: string | null;\n isIndependent?: boolean | null;\n votes: number;\n position?: number | null;\n isWinner?: boolean | null;\n photoFileId?: string | null;\n officialId?: string | null;\n}\n\nexport interface GovCreateJurisdictionEventInput {\n jurisdictionId: string;\n title: string;\n description?: string | null;\n occurredOn: string;\n category?: GovEventCategory | null;\n impact?: GovEventImpact | null;\n linkedProjectId?: string | null;\n linkedElectionId?: string | null;\n linkedBudgetId?: string | null;\n imageFileId?: string | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification?: GovVerificationStatus | null;\n}\n\nexport interface GovUpdateJurisdictionEventInput {\n title?: string | null;\n description?: string | null;\n occurredOn?: string | null;\n category?: GovEventCategory | null;\n impact?: GovEventImpact | null;\n linkedProjectId?: string | null;\n linkedElectionId?: string | null;\n linkedBudgetId?: string | null;\n imageFileId?: string | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification?: GovVerificationStatus | null;\n}\n\nexport interface GovCreateBudgetInput {\n jurisdictionId: string;\n fiscalYear: string;\n periodStart: string;\n periodEnd: string;\n currencyCode: string;\n status?: GovBudgetStatus | null;\n totalRevenuePlanned?: number | null;\n totalRevenueActual?: number | null;\n totalExpensePlanned?: number | null;\n totalExpenseActual?: number | null;\n populationAtPublication?: number | null;\n summary?: string | null;\n documentFileId?: string | null;\n approvedOn?: string | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification?: GovVerificationStatus | null;\n}\n\nexport interface GovUpdateBudgetInput {\n fiscalYear?: string | null;\n periodStart?: string | null;\n periodEnd?: string | null;\n currencyCode?: string | null;\n status?: GovBudgetStatus | null;\n totalRevenuePlanned?: number | null;\n totalRevenueActual?: number | null;\n totalExpensePlanned?: number | null;\n totalExpenseActual?: number | null;\n populationAtPublication?: number | null;\n summary?: string | null;\n documentFileId?: string | null;\n approvedOn?: string | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification?: GovVerificationStatus | null;\n}\n\nexport interface GovBudgetLineInput {\n /** Omit to create a new line; supply to update an existing one. */\n id?: string | null;\n kind: GovBudgetLineKind;\n category: GovBudgetCategory;\n label: string;\n department?: string | null;\n functionCode?: string | null;\n plannedAmount?: number | null;\n actualAmount?: number | null;\n previousYearAmount?: number | null;\n notes?: string | null;\n displayOrder?: number | null;\n}\n\nexport interface GovCreateProjectInput {\n jurisdictionId: string;\n agencyId?: string | null;\n name: string;\n code?: string | null;\n description?: string | null;\n domain?: GovIndicatorDomain | null;\n department?: string | null;\n contractorName?: string | null;\n contractorRegistrationId?: string | null;\n fundingSource?: GovFundingSource | null;\n budgetAmount?: number | null;\n actualCost?: number | null;\n currencyCode?: string | null;\n tenderReference?: string | null;\n tenderUrl?: string | null;\n awardedOn?: string | null;\n startDate?: string | null;\n plannedCompletionDate?: string | null;\n actualCompletionDate?: string | null;\n status?: GovProjectStatus | null;\n progressPercent?: number | null;\n delayReason?: string | null;\n locationLabel?: string | null;\n latitude?: number | null;\n longitude?: number | null;\n imageFileIds?: string[] | null;\n documentFileIds?: string[] | null;\n beneficiaryCount?: number | null;\n tags?: string[] | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification?: GovVerificationStatus | null;\n}\n\nexport interface GovUpdateProjectInput {\n agencyId?: string | null;\n name?: string | null;\n code?: string | null;\n description?: string | null;\n domain?: GovIndicatorDomain | null;\n department?: string | null;\n contractorName?: string | null;\n contractorRegistrationId?: string | null;\n fundingSource?: GovFundingSource | null;\n budgetAmount?: number | null;\n actualCost?: number | null;\n currencyCode?: string | null;\n tenderReference?: string | null;\n tenderUrl?: string | null;\n awardedOn?: string | null;\n startDate?: string | null;\n plannedCompletionDate?: string | null;\n actualCompletionDate?: string | null;\n status?: GovProjectStatus | null;\n progressPercent?: number | null;\n delayReason?: string | null;\n locationLabel?: string | null;\n latitude?: number | null;\n longitude?: number | null;\n imageFileIds?: string[] | null;\n documentFileIds?: string[] | null;\n beneficiaryCount?: number | null;\n tags?: string[] | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification?: GovVerificationStatus | null;\n}\n\nexport interface GovCreateProjectMilestoneInput {\n projectId: string;\n name: string;\n description?: string | null;\n dueDate?: string | null;\n completedOn?: string | null;\n status?: GovMilestoneStatus | null;\n progressPercent?: number | null;\n evidenceFileId?: string | null;\n displayOrder?: number | null;\n}\n\nexport interface GovUpdateProjectMilestoneInput {\n name?: string | null;\n description?: string | null;\n dueDate?: string | null;\n completedOn?: string | null;\n status?: GovMilestoneStatus | null;\n progressPercent?: number | null;\n evidenceFileId?: string | null;\n displayOrder?: number | null;\n}\n\nexport interface GovCreateIndicatorInput {\n code: string;\n name: string;\n description?: string | null;\n domain: GovIndicatorDomain;\n unit: string;\n valueType?: GovIndicatorValueType | null;\n direction?: GovIndicatorDirection | null;\n periodicity?: GovIndicatorPeriodicity | null;\n methodology?: string | null;\n targetValue?: number | null;\n minValue?: number | null;\n maxValue?: number | null;\n isCore?: boolean | null;\n weight?: number | null;\n isActive?: boolean | null;\n sdgGoal?: number | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n}\n\nexport interface GovUpdateIndicatorInput {\n name?: string | null;\n description?: string | null;\n domain?: GovIndicatorDomain | null;\n unit?: string | null;\n valueType?: GovIndicatorValueType | null;\n direction?: GovIndicatorDirection | null;\n periodicity?: GovIndicatorPeriodicity | null;\n methodology?: string | null;\n targetValue?: number | null;\n minValue?: number | null;\n maxValue?: number | null;\n isCore?: boolean | null;\n weight?: number | null;\n isActive?: boolean | null;\n sdgGoal?: number | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n}\n\nexport interface GovRecordIndicatorValueInput {\n /** Supply either the indicator id or its code. */\n indicatorId?: string | null;\n indicatorCode?: string | null;\n jurisdictionId: string;\n periodLabel: string;\n periodStart: string;\n periodEnd: string;\n value: number;\n numerator?: number | null;\n denominator?: number | null;\n targetValue?: number | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n sourceDate?: string | null;\n datasetId?: string | null;\n verification?: GovVerificationStatus | null;\n notes?: string | null;\n}\n\nexport interface GovUpdateIndicatorValueInput {\n value?: number | null;\n numerator?: number | null;\n denominator?: number | null;\n targetValue?: number | null;\n periodLabel?: string | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n sourceDate?: string | null;\n datasetId?: string | null;\n verification?: GovVerificationStatus | null;\n notes?: string | null;\n}\n\nexport interface GovCreatePublicAssetInput {\n jurisdictionId: string;\n name: string;\n category: GovAssetCategory;\n subCategory?: string | null;\n description?: string | null;\n operator?: GovAssetOperator | null;\n status?: GovAssetStatus | null;\n address?: string | null;\n latitude?: number | null;\n longitude?: number | null;\n capacity?: number | null;\n capacityUnit?: string | null;\n contactPhone?: string | null;\n contactEmail?: string | null;\n website?: string | null;\n openingHours?: string | null;\n isAccessible?: boolean | null;\n establishedOn?: string | null;\n imageFileId?: string | null;\n metadata?: GovJson;\n tags?: string[] | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification?: GovVerificationStatus | null;\n}\n\nexport interface GovUpdatePublicAssetInput {\n name?: string | null;\n category?: GovAssetCategory | null;\n subCategory?: string | null;\n description?: string | null;\n operator?: GovAssetOperator | null;\n status?: GovAssetStatus | null;\n address?: string | null;\n latitude?: number | null;\n longitude?: number | null;\n capacity?: number | null;\n capacityUnit?: string | null;\n contactPhone?: string | null;\n contactEmail?: string | null;\n website?: string | null;\n openingHours?: string | null;\n isAccessible?: boolean | null;\n establishedOn?: string | null;\n imageFileId?: string | null;\n metadata?: GovJson;\n tags?: string[] | null;\n sourceName?: string | null;\n sourceUrl?: string | null;\n verification?: GovVerificationStatus | null;\n}\n\nexport interface GovCreateConsultationInput {\n jurisdictionId: string;\n title: string;\n description?: string | null;\n consultationType?: GovConsultationType | null;\n opensAt?: string | null;\n closesAt?: string | null;\n questions: GovJson;\n allowAnonymous?: boolean | null;\n budgetAmount?: number | null;\n currencyCode?: string | null;\n documentFileId?: string | null;\n tags?: string[] | null;\n}\n\nexport interface GovUpdateConsultationInput {\n title?: string | null;\n description?: string | null;\n consultationType?: GovConsultationType | null;\n opensAt?: string | null;\n closesAt?: string | null;\n questions?: GovJson;\n allowAnonymous?: boolean | null;\n budgetAmount?: number | null;\n currencyCode?: string | null;\n documentFileId?: string | null;\n tags?: string[] | null;\n}\n\nexport interface GovSubmitConsultationResponseInput {\n consultationId: string;\n /** Answers: `[{ questionId, value }]`. */\n answers: GovJson;\n sentiment?: GovSentiment | null;\n /** Submit without recording the responding actor. Rejected when not allowed. */\n anonymous?: boolean | null;\n}\n\nexport interface GovCreateDatasetInput {\n jurisdictionId?: string | null;\n name: string;\n slug?: string | null;\n description?: string | null;\n domain?: GovIndicatorDomain | null;\n format?: GovDatasetFormat | null;\n license?: GovDataLicense | null;\n licenseUrl?: string | null;\n version?: string | null;\n fileId?: string | null;\n externalUrl?: string | null;\n periodStart?: string | null;\n periodEnd?: string | null;\n updateFrequency?: GovIndicatorPeriodicity | null;\n rowCount?: number | null;\n sizeBytes?: number | null;\n publisher?: string | null;\n contactEmail?: string | null;\n tags?: string[] | null;\n}\n\nexport interface GovUpdateDatasetInput {\n jurisdictionId?: string | null;\n name?: string | null;\n description?: string | null;\n domain?: GovIndicatorDomain | null;\n format?: GovDatasetFormat | null;\n license?: GovDataLicense | null;\n licenseUrl?: string | null;\n version?: string | null;\n fileId?: string | null;\n externalUrl?: string | null;\n periodStart?: string | null;\n periodEnd?: string | null;\n updateFrequency?: GovIndicatorPeriodicity | null;\n rowCount?: number | null;\n sizeBytes?: number | null;\n publisher?: string | null;\n contactEmail?: string | null;\n status?: GovDatasetStatus | null;\n tags?: string[] | null;\n}\n\nexport interface GovSubmitDataChangeProposalInput {\n jurisdictionId: string;\n entityType: GovIntelEntityType;\n entityId: string;\n fieldPath: string;\n proposedValue: string;\n rationale: string;\n evidenceUrl?: string | null;\n evidenceFileIds?: string[] | null;\n}\n\n// ============================================================================\n// UI helper maps — LABELS ONLY. No colours here: pages style with the semantic\n// Tailwind tokens the sibling GovCitizenHub pages already use.\n// ============================================================================\n\n/** Human label per indicator/project/dataset domain. */\nexport const GOV_INDICATOR_DOMAIN_LABELS: Record<GovIndicatorDomain, string> = {\n DEMOGRAPHICS: 'Demographics',\n ECONOMY: 'Economy',\n EDUCATION: 'Education',\n HEALTHCARE: 'Healthcare',\n INFRASTRUCTURE: 'Infrastructure',\n PUBLIC_SAFETY: 'Public safety',\n ENVIRONMENT: 'Environment',\n SOCIAL_WELFARE: 'Social welfare',\n UTILITIES: 'Utilities',\n TRANSPORT: 'Transport',\n HOUSING: 'Housing',\n GOVERNANCE: 'Governance',\n DIGITAL: 'Digital',\n TOURISM: 'Tourism',\n FINANCE: 'Finance',\n};\n\n/** Human label per public-asset category. */\nexport const GOV_ASSET_CATEGORY_LABELS: Record<GovAssetCategory, string> = {\n SCHOOL: 'School',\n UNIVERSITY: 'University',\n LIBRARY: 'Library',\n HOSPITAL: 'Hospital',\n CLINIC: 'Clinic',\n PHARMACY: 'Pharmacy',\n POLICE_STATION: 'Police station',\n FIRE_STATION: 'Fire station',\n EMERGENCY_SHELTER: 'Emergency shelter',\n WATER_FACILITY: 'Water facility',\n POWER_FACILITY: 'Power facility',\n WASTE_FACILITY: 'Waste facility',\n TRANSIT_STOP: 'Transit stop',\n TRANSIT_STATION: 'Transit station',\n AIRPORT: 'Airport',\n PORT: 'Port',\n BRIDGE: 'Bridge',\n PARK: 'Park',\n SPORTS_FACILITY: 'Sports facility',\n COMMUNITY_CENTER: 'Community centre',\n GOVERNMENT_OFFICE: 'Government office',\n PUBLIC_TOILET: 'Public toilet',\n PARKING: 'Parking',\n EV_CHARGING: 'EV charging',\n MARKET: 'Market',\n NGO: 'NGO',\n BUSINESS: 'Business',\n LANDMARK: 'Landmark',\n MUSEUM: 'Museum',\n OTHER: 'Other',\n};\n\n/** Human label per budget category (both sides of the ledger). */\nexport const GOV_BUDGET_CATEGORY_LABELS: Record<GovBudgetCategory, string> = {\n TAXES: 'Taxes',\n FEES_AND_CHARGES: 'Fees and charges',\n GRANTS: 'Grants',\n INTERGOVERNMENTAL_TRANSFERS: 'Intergovernmental transfers',\n LOANS: 'Loans',\n INTERNATIONAL_AID: 'International aid',\n PUBLIC_PRIVATE_PARTNERSHIP: 'Public-private partnership',\n ASSET_SALES: 'Asset sales',\n OTHER_REVENUE: 'Other revenue',\n EDUCATION: 'Education',\n HEALTHCARE: 'Healthcare',\n ROADS_AND_TRANSPORT: 'Roads and transport',\n WATER_AND_SANITATION: 'Water and sanitation',\n ENERGY: 'Energy',\n AGRICULTURE: 'Agriculture',\n ENVIRONMENT: 'Environment',\n PUBLIC_SAFETY: 'Public safety',\n SOCIAL_WELFARE: 'Social welfare',\n HOUSING: 'Housing',\n DIGITAL_INFRASTRUCTURE: 'Digital infrastructure',\n CULTURE_AND_RECREATION: 'Culture and recreation',\n ADMINISTRATION: 'Administration',\n DEBT_SERVICE: 'Debt service',\n CAPITAL_PROJECTS: 'Capital projects',\n OTHER_EXPENSE: 'Other expenditure',\n};\n\n/**\n * Revenue-side budget categories — the exact split the backend enforces\n * (`TAXES`..`OTHER_REVENUE` in 010-enums.gql). A line whose category is not in\n * this list is rejected with VALIDATION_FAILED when `kind` is REVENUE.\n */\nexport const GOV_REVENUE_CATEGORIES: readonly GovBudgetCategory[] = [\n 'TAXES',\n 'FEES_AND_CHARGES',\n 'GRANTS',\n 'INTERGOVERNMENTAL_TRANSFERS',\n 'LOANS',\n 'INTERNATIONAL_AID',\n 'PUBLIC_PRIVATE_PARTNERSHIP',\n 'ASSET_SALES',\n 'OTHER_REVENUE',\n];\n\n/**\n * Expense-side budget categories (`EDUCATION`..`OTHER_EXPENSE` in\n * 010-enums.gql). A line whose category is not in this list is rejected with\n * VALIDATION_FAILED when `kind` is EXPENSE.\n */\nexport const GOV_EXPENSE_CATEGORIES: readonly GovBudgetCategory[] = [\n 'EDUCATION',\n 'HEALTHCARE',\n 'ROADS_AND_TRANSPORT',\n 'WATER_AND_SANITATION',\n 'ENERGY',\n 'AGRICULTURE',\n 'ENVIRONMENT',\n 'PUBLIC_SAFETY',\n 'SOCIAL_WELFARE',\n 'HOUSING',\n 'DIGITAL_INFRASTRUCTURE',\n 'CULTURE_AND_RECREATION',\n 'ADMINISTRATION',\n 'DEBT_SERVICE',\n 'CAPITAL_PROJECTS',\n 'OTHER_EXPENSE',\n];\n\n/** Human label per project delivery status. */\nexport const GOV_PROJECT_STATUS_LABELS: Record<GovProjectStatus, string> = {\n PLANNED: 'Planned',\n TENDERED: 'Tendered',\n AWARDED: 'Awarded',\n IN_PROGRESS: 'In progress',\n SUSPENDED: 'Suspended',\n COMPLETED: 'Completed',\n CANCELLED: 'Cancelled',\n};\n\n/** Human label per commitment delivery status. */\nexport const GOV_COMMITMENT_STATUS_LABELS: Record<GovCommitmentStatus, string> = {\n PROMISED: 'Promised',\n IN_PROGRESS: 'In progress',\n DELIVERED: 'Delivered',\n STALLED: 'Stalled',\n ABANDONED: 'Abandoned',\n};\n\n/** Human label per provenance grade. */\nexport const GOV_VERIFICATION_LABELS: Record<GovVerificationStatus, string> = {\n UNVERIFIED: 'Unverified',\n OFFICIAL: 'Official',\n COMMUNITY_VERIFIED: 'Community verified',\n DISPUTED: 'Disputed',\n};\n"],"mappings":";AAs0DA,IAAa,IAAkE;CAC7E,cAAc;CACd,SAAS;CACT,WAAW;CACX,YAAY;CACZ,gBAAgB;CAChB,eAAe;CACf,aAAa;CACb,gBAAgB;CAChB,WAAW;CACX,WAAW;CACX,SAAS;CACT,YAAY;CACZ,SAAS;CACT,SAAS;CACT,SAAS;AACX,GAGa,IAA8D;CACzE,QAAQ;CACR,YAAY;CACZ,SAAS;CACT,UAAU;CACV,QAAQ;CACR,UAAU;CACV,gBAAgB;CAChB,cAAc;CACd,mBAAmB;CACnB,gBAAgB;CAChB,gBAAgB;CAChB,gBAAgB;CAChB,cAAc;CACd,iBAAiB;CACjB,SAAS;CACT,MAAM;CACN,QAAQ;CACR,MAAM;CACN,iBAAiB;CACjB,kBAAkB;CAClB,mBAAmB;CACnB,eAAe;CACf,SAAS;CACT,aAAa;CACb,QAAQ;CACR,KAAK;CACL,UAAU;CACV,UAAU;CACV,QAAQ;CACR,OAAO;AACT,GAGa,IAAgE;CAC3E,OAAO;CACP,kBAAkB;CAClB,QAAQ;CACR,6BAA6B;CAC7B,OAAO;CACP,mBAAmB;CACnB,4BAA4B;CAC5B,aAAa;CACb,eAAe;CACf,WAAW;CACX,YAAY;CACZ,qBAAqB;CACrB,sBAAsB;CACtB,QAAQ;CACR,aAAa;CACb,aAAa;CACb,eAAe;CACf,gBAAgB;CAChB,SAAS;CACT,wBAAwB;CACxB,wBAAwB;CACxB,gBAAgB;CAChB,cAAc;CACd,kBAAkB;CAClB,eAAe;AACjB,GAOa,IAAuD;CAClE;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;AACF,GAOa,IAAuD;CAClE;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;CACA;AACF,GAGa,IAA8D;CACzE,SAAS;CACT,UAAU;CACV,SAAS;CACT,aAAa;CACb,WAAW;CACX,WAAW;CACX,WAAW;AACb,GAGa,IAAoE;CAC/E,UAAU;CACV,aAAa;CACb,WAAW;CACX,SAAS;CACT,WAAW;AACb,GAGa,IAAiE;CAC5E,YAAY;CACZ,UAAU;CACV,oBAAoB;CACpB,UAAU;AACZ"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@burdenoff/microfe-govcitizenhub",
3
- "version": "2026.730.2",
3
+ "version": "2026.730.3",
4
4
  "description": "Burdenoff GovCitizenHub Microfrontend",
5
5
  "type": "module",
6
6
  "files": [