/* * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. */ import { trackingStatusCreate } from "../funcs/trackingStatusCreate.js"; import { trackingStatusGet } from "../funcs/trackingStatusGet.js"; import { ClientSDK, RequestOptions } from "../lib/sdks.js"; import * as components from "../models/components/index.js"; import { unwrapAsync } from "../types/fp.js"; export class TrackingStatus extends ClientSDK { /** * Register a tracking webhook * * @remarks * Registers a webhook that will send HTTP notifications to you when the status of your tracked package changes. For more details on creating a webhook, see our guides on Webhooks and Tracking. */ async create( request: components.TracksRequest, options?: RequestOptions, ): Promise { return unwrapAsync(trackingStatusCreate( this, request, options, )); } /** * Get a tracking status * * @remarks * Returns the tracking status of a shipment using a carrier name and a tracking number. */ async get( trackingNumber: string, carrier: string, options?: RequestOptions, ): Promise { return unwrapAsync(trackingStatusGet( this, trackingNumber, carrier, options, )); } }