diff --git a/src/lib/api/resources/characters.ts b/src/lib/api/resources/characters.ts index e69de29b..c67af371 100644 --- a/src/lib/api/resources/characters.ts +++ b/src/lib/api/resources/characters.ts @@ -0,0 +1,16 @@ +import type { FetchLike } from '../core' +import { get } from '../core' + +export interface CharacterEntity { + id: string + granblue_id: number | string + name: { en?: string; ja?: string } | string + element?: number + rarity?: number + uncap?: { flb?: boolean; ulb?: boolean } +} + +export const characters = { + show: (f: FetchLike, id: string, init?: RequestInit) => + get(f, `/characters/${encodeURIComponent(id)}`, undefined, init) +} diff --git a/src/lib/api/resources/summons.ts b/src/lib/api/resources/summons.ts index e69de29b..75e400ba 100644 --- a/src/lib/api/resources/summons.ts +++ b/src/lib/api/resources/summons.ts @@ -0,0 +1,16 @@ +import type { FetchLike } from '../core' +import { get } from '../core' + +export interface SummonEntity { + id: string + granblue_id: number + name: { en?: string; ja?: string } | string + element?: number + rarity?: number + uncap?: { flb?: boolean; ulb?: boolean; transcendence?: boolean } +} + +export const summons = { + show: (f: FetchLike, id: string, init?: RequestInit) => + get(f, `/summons/${encodeURIComponent(id)}`, undefined, init) +} diff --git a/src/lib/api/resources/weapons.ts b/src/lib/api/resources/weapons.ts index 040d44b2..9a38f2ba 100644 --- a/src/lib/api/resources/weapons.ts +++ b/src/lib/api/resources/weapons.ts @@ -1,2 +1,16 @@ -import type { FetchLike, Dict } from '../core' -import { get, post, put, del } from '../core' +import type { FetchLike } from '../core' +import { get } from '../core' + +export interface WeaponEntity { + id: string + granblue_id: number + name: { en?: string; ja?: string } | string + element?: number + rarity?: number + uncap?: { flb?: boolean; ulb?: boolean; transcendence?: boolean } +} + +export const weapons = { + show: (f: FetchLike, id: string, init?: RequestInit) => + get(f, `/weapons/${encodeURIComponent(id)}`, undefined, init) +}