export type CreateApiAdisyonDetayYazdirIdArgs = {Authorization?: string | undefined, id: number}; export type CreateApiAdisyonDetayYazdirIdOptions = {baseUrl?: string | undefined, fetch?: typeof fetch | undefined}; /** * POST /adisyon/detay-yazdir/{id} */ export const createApiAdisyonDetayYazdirId = async (args: CreateApiAdisyonDetayYazdirIdArgs, options?: CreateApiAdisyonDetayYazdirIdOptions) => { const {baseUrl = "https://demo.poskobi.com", fetch: fetchFn = fetch} = options ?? {} const query = new URLSearchParams() const headers = new Headers() headers.set('accept', "application/octet-stream") if (args.Authorization != null) headers.set("Authorization", String(args.Authorization)) const url = `${baseUrl.replace(/\/+$/, '')}/adisyon/detay-yazdir/${encodeURIComponent(String(args.id))}${query.size > 0 ? `?${query}` : ''}` const res = await fetchFn(url, {method: "POST", headers}) if (!res.ok) throw new Error(`Request failed with status ${res.status}`, {cause: {status: res.status, body: await res.text()}}) return res.blob() };