Add API Profiles feature design documentation for DMS #764
+3,078
−0
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Comprehensive architectural design for adapting Ed-Fi API Profiles from AdminAPI-2.x to DMS. Profiles enable fine-grained data access control via XML-defined inclusion/exclusion rules on resource properties, collections, and references.
Design Documentation
API-PROFILES-DESIGN.md (40KB) - Complete architecture specification
API-PROFILES-QUICKSTART.md (12KB) - Developer onboarding guide
memberSelectionstrategies (IncludeOnly, ExcludeOnly, IncludeAll, ExcludeAll)Accept: application/json;profile=name(reads),Content-Type: application/json;profile=name(writes)API-PROFILES-MIGRATION.md (18KB) - AdminAPI-2.x migration guide
Example Profiles
Five production-ready XML profiles with inline documentation:
Additional examples: write-limited student access, restricted assessment data, public school directory, full descriptor access.
profile-schema.xsd included for XML validation.
Database Schema
Implementation Tickets
Architecture
Profile resolution flow:
Storage: XML profiles imported to database, cached in-memory
Selection: HTTP media type parameters (
application/json;profile=name)Enforcement: Pipeline middleware intercepts requests/responses
Management: REST API + Admin UI for CRUD operations
Warning
Firewall rules blocked me from connecting to one or more addresses (expand for details)
I tried to connect to the following addresses, but was blocked by firewall rules:
4vyvsblobprodcus361.blob.core.windows.net/usr/bin/dotnet dotnet restore EdFi.DataManagementService.sln(dns block)kh4vsblobprodcus325.blob.core.windows.net/usr/bin/dotnet dotnet restore EdFi.DataManagementService.sln(dns block)If you need me to access, download, or install something from one of these locations, you can either:
Original prompt
This section details on the original issue you should resolve
<issue_title>Design: Adaptation of Ed-Fi API Profiles Feature (XML) into Data Management Service (DMS)</issue_title>
<issue_description># Architecture Design: API Profiles Feature Adaptation from AdminAPI-2.x to Data Management Service (DMS)
Problem Definition
The Ed-Fi API Profiles feature enables the enforcement of data policies on API resources in support of specific operational or regulatory scenarios. Profiles are rulesets defined in XML, specifying which Resource properties, references, and collections are exposed or excluded for each API consumer role.
Currently, this feature exists in the AdminAPI-2.x codebase and enforces rules at the API layer. Moving this capability into the Data Management Service (DMS) is needed for:
Conceptual Design
Main Principles
Acceptfor reads,Content-Typefor writes); DMS resolves the effective data policy and enforces.Integration Strategy
graph TD A[API Client] -->|Profile via HTTP Header| B(DMS API Gateway) B --> C[Profile Resolver] C --> D[Profile Rules Engine] D --> E[Resource Data Filter] E --> F[Database] C & D --> G[Profile Table (DB)]Existing XML Logic Utilization
Implementation Tickets
Ticket 1: DMS Profile Table and XML Import
Ticket 2: DMS Profiles Enforcement Pipeline
Ticket 3: Admin API - Profile Export and Management
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.