Skip to content

v1.1.0

Compare
Choose a tag to compare
@github-actions github-actions released this 05 Mar 06:11
· 467 commits to master since this release
5fd6423

Minor Changes

  • #36 ccc39dd Thanks @charlypoly! - expose getExecution(id) to poll for an execution status and result:

    import { type FetchExecutionResponse, getExecution } from "@defer/client";
    import type { NextApiRequest, NextApiResponse } from "next";
    
    type Response = {
      res: FetchExecutionResponse;
    };
    
    export default async function handler(
      req: NextApiRequest,
      res: NextApiResponse<Response>
    ) {
      const executionId = req.query.id;
      const ret = await getExecution(executionId as string);
      res.status(200).json({ res: ret });
    }