Add tag filter to blogs, portfolios, and videos list APIs.

Storefronts can filter published content by metadata.tags the same way as products; website API docs are updated to match.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
Alireza Hassani
2026-08-22 21:14:42 +03:30
co-authored by Cursor
parent e0e122ed57
commit 1b16e79d3f
12 changed files with 128 additions and 2 deletions
+8
View File
@@ -39,6 +39,10 @@ export class ListVideosDto {
@IsOptional()
@IsString()
title?: string;
@IsOptional()
@IsString()
tag?: string;
}
export class ListPublicVideosDto {
@@ -65,6 +69,10 @@ export class ListPublicVideosDto {
@IsOptional()
@IsString()
title?: string;
@IsOptional()
@IsString()
tag?: string;
}
export class CreateVideoDto {
+8
View File
@@ -566,6 +566,14 @@ export class VideosService {
],
}
: {}),
...(query.tag?.trim()
? {
metadata: {
path: ['tags'],
array_contains: query.tag.trim(),
},
}
: {}),
};
}