memorium/lib/types.ts
2023-08-08 11:03:20 +02:00

42 lines
922 B
TypeScript

import { SearchResponse } from "https://raw.githubusercontent.com/bradenmacdonald/typesense-deno/main/src/Typesense/Documents.ts";
import { resources } from "@lib/resources.ts";
export interface TMDBMovie {
adult: boolean;
backdrop_path: string;
genre_ids: number[];
id: number;
original_language: string;
original_title: string;
overview: string;
popularity: number;
poster_path: string;
release_date: string;
title: string;
video: boolean;
vote_average: number;
vote_count: number;
}
export interface GiteaOauthUser {
sub: string;
name: string;
preferred_username: string;
email: string;
picture: string;
groups: any;
}
export type TypesenseDocument = {
id: string;
name: string;
type: keyof typeof resources;
date?: string;
rating: number;
tags: string[];
description?: string;
image?: string;
};
export type SearchResult = SearchResponse<TypesenseDocument>;