gallery.ts 321 B

1234567891011121314151617
  1. import { API } from '../api'
  2. class GalleryModule extends API {
  3. // TODO: types
  4. async getAlbums() {
  5. return await this.get<object>(
  6. `/photos/albums`,
  7. )
  8. }
  9. // TODO: types
  10. async getPhotos(album_id: string) {
  11. return await this.get<object>(`/photos/${album_id}`)
  12. }
  13. }
  14. export default GalleryModule