UNPKG

@renegade-fi/core

Version:
20 lines 741 B
import { CANCEL_ORDER_ROUTE } from "../constants.js"; import { postRelayerWithAuth } from "../utils/http.js"; import { getWalletId } from "./getWalletId.js"; export async function cancelOrderRequest(config, parameters) { const { request, id } = parameters; const { getBaseUrl } = config; const walletId = getWalletId(config); try { const res = await postRelayerWithAuth(config, getBaseUrl(CANCEL_ORDER_ROUTE(walletId, id)), request); console.log(`task update-wallet(${res.task_id}): ${walletId}`); return { taskId: res.task_id }; } catch (error) { console.error(`${walletId}`, { error, }); throw error; } } //# sourceMappingURL=cancelOrderRequest.js.map