Skip to content
Back to skills

Admin And Seed Data

ASecurity

Manage database seeding, reset operations, and the admin interface.

  • 57 stars
  • 0 votes
  • 0 copies
  • 0 views
  • Added October 17, 2026
developmentreactapidatabasefrontend

Works with

  • api

Security analysis

A100/100

Scanned October 17, 2026

npx -y skills add diegosouzapw/awesome-omni-skill --skill admin-and-seed-data --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Admin And Seed Data?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Admin And Seed Data
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/diegosouzapw-admin-and-seed-data/badge)](https://www.skillsdirectory.com/skills/diegosouzapw-admin-and-seed-data)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: Admin and Seed Data
description: Manage database seeding, reset operations, and the admin interface.
globs:
  - "RestReactAspire.Server/Endpoints/AdminEndpoints.cs"
  - "RestReactAspire.Server/Stores/SeedDataGenerator.cs"
  - "RestReactAspire.Server/Telemetry/AdminTelemetry.cs"
  - "RestReactAspire.Server/Models/AdminDto.cs"
  - "frontend/src/pages/AdminPage.tsx"
---

# Admin and Seed Data

## Admin API Endpoints
Located in `RestReactAspire.Server/Endpoints/AdminEndpoints.cs`, registered under `/api/admin`.

| Endpoint | Method | Description |
|----------|--------|-------------|
| `/seed` | POST | Populates database with sample data (additive) |
| `/reset` | POST | Deletes all data from all collections |
| `/stats` | GET | Returns current count of patients, doctors, exams |

### Response DTOs (`AdminDto.cs`)
- `SeedResponse(int PatientsCreated, int DoctorsCreated, int ExamsCreated, Links)`
- `ResetResponse(int PatientsDeleted, int DoctorsDeleted, int ExamsDeleted, Links)`
- `StatsResponse(int PatientCount, int DoctorCount, int ExamCount, Links)`

## Seed Data Generator
Located in `RestReactAspire.Server/Stores/SeedDataGenerator.cs`.

### Current Data Volumes
- **100 patients** — random Italian names, varied dates of birth, email, phone
- **30 doctors** — random Italian names, assigned from 15 medical specialties
- **200 exams** — distributed across patients and doctors with realistic types, durations, dates, statuses, results, and notes

### Data Characteristics
- Patient names drawn from pools of 50 first names and 50 last names.
- Doctor specialties: Cardiology, Neurology, Orthopedics, Dermatology, Gastroenterology, Ophthalmology, Pulmonology, Endocrinology, Urology, Oncology, Rheumatology, Nephrology, Hematology, Infectious Disease, General Surgery.
- Exam types: Blood Test, MRI Brain, X-Ray Chest, ECG, Skin Biopsy, Colonoscopy, Eye Exam, Spirometry, Thyroid Panel, Ultrasound, Urinalysis, Mammography, CT Scan, Bone Density Scan, Stress Test.
- Each exam type has min/max duration ranges for realistic `DurationMinutes`.
- Completed exams have type-specific result strings and notes.
- Scheduled dates span a 12-month range for meaningful time-series charts.

### Modifying Seed Data
- Adjust counts in `GeneratePatients()`, `GenerateDoctors()`, `GenerateExams()`.
- Add new name pools, specialties, or exam types to the static arrays.
- Ensure cross-references remain valid (exams reference valid patient and doctor IDs).

## Frontend Admin Page
- Displays current database stats (patient, doctor, exam counts).
- Provides "Seed Database" and "Reset Database" buttons.
- Shows operation results after seeding or resetting.

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.