Skip to content

Feature media details endpoint - #22

Merged
hmjn023 merged 2 commits into
developfrom
feature-media-details-endpoint
Nov 7, 2025
Merged

hmjn023 merged 2 commits into
developfrom
feature-media-details-endpoint

Conversation

@hmjn023

@hmjn023 hmjn023 commented Nov 7, 2025

Copy link
Copy Markdown
Owner

No description provided.

google-labs-jules Bot and others added 2 commits November 6, 2025 23:00
Implements a new API endpoint to retrieve detailed information for a media item.

The endpoint `GET /api/sources/{mediaSourceId}/{mediaId}/details` returns a comprehensive object containing the media's basic information, its tags, and AI generation metadata.

If the generation metadata is not already in the database, the endpoint logic triggers an on-demand extraction from the media file and persists the result.

Includes a new integration test to ensure the endpoint functions correctly.
This commit introduces several improvements and fixes to the media handling functionality.

- **Refine Tag API Response:** The API endpoints for media tags and details now return a more concise tag object, excluding the 'description', 'createdAt', and 'updatedAt' fields to reduce verbosity.

- **Correct Media Timestamps:** The 'createdAt' and 'modifiedAt' timestamps for media records now accurately reflect the file's creation and modification times from the filesystem. This corrects the previous behavior where these timestamps were incorrectly set to the database indexing time.

- **Fix Metadata Extraction:** A bug in the metadata extraction logic for ComfyUI prompts has been fixed. This ensures that tags are correctly extracted from prompts that have a workflow structure.

- **Code Quality:** Includes various linting fixes and updates to improve code consistency and quality.
@hmjn023
hmjn023 merged commit 91b37a5 into develop Nov 7, 2025
@hmjn023
hmjn023 deleted the feature-media-details-endpoint branch November 7, 2025 17:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant