/* * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. */ import { processesV2CreateProcessV2Deprecated } from "../funcs/processesV2CreateProcessV2Deprecated.js"; import { processesV2GetLatestProcessesV2Deprecated } from "../funcs/processesV2GetLatestProcessesV2Deprecated.js"; import { processesV2GetProcessesCountExperimentalV2Deprecated } from "../funcs/processesV2GetProcessesCountExperimentalV2Deprecated.js"; import { processesV2GetProcessInfoV2Deprecated } from "../funcs/processesV2GetProcessInfoV2Deprecated.js"; import { processesV2StopProcessV2Deprecated } from "../funcs/processesV2StopProcessV2Deprecated.js"; import { ClientSDK, RequestOptions } from "../lib/sdks.js"; import * as components from "../models/components/index.js"; import * as operations from "../models/operations/index.js"; import { unwrapAsync } from "../types/fp.js"; export class ProcessesV2 extends ClientSDK { /** * GetProcessInfoV2Deprecated * * @remarks * Get details for a [process](https://hathora.dev/docs/concepts/hathora-entities#process). * * @deprecated method: This will be removed in a future release, please migrate away from it as soon as possible. */ async getProcessInfoV2Deprecated( processId: string, appId?: string | undefined, options?: RequestOptions, ): Promise { return unwrapAsync(processesV2GetProcessInfoV2Deprecated( this, processId, appId, options, )); } /** * GetLatestProcessesV2Deprecated * * @remarks * Retrieve the 10 most recent [processes](https://hathora.dev/docs/concepts/hathora-entities#process) objects for an [application](https://hathora.dev/docs/concepts/hathora-entities#application). Filter the array by optionally passing in a `status` or `region`. * * @deprecated method: This will be removed in a future release, please migrate away from it as soon as possible. */ async getLatestProcessesV2Deprecated( appId?: string | undefined, status?: Array | undefined, region?: Array | undefined, options?: RequestOptions, ): Promise> { return unwrapAsync(processesV2GetLatestProcessesV2Deprecated( this, appId, status, region, options, )); } /** * GetProcessesCountExperimentalV2Deprecated * * @remarks * Count the number of [processes](https://hathora.dev/docs/concepts/hathora-entities#process) objects for an [application](https://hathora.dev/docs/concepts/hathora-entities#application). Filter by optionally passing in a `status` or `region`. * * @deprecated method: This will be removed in a future release, please migrate away from it as soon as possible. */ async getProcessesCountExperimentalV2Deprecated( appId?: string | undefined, status?: Array | undefined, region?: Array | undefined, options?: RequestOptions, ): Promise { return unwrapAsync(processesV2GetProcessesCountExperimentalV2Deprecated( this, appId, status, region, options, )); } /** * StopProcessV2Deprecated * * @remarks * Stops a [process](https://hathora.dev/docs/concepts/hathora-entities#process) immediately. * * @deprecated method: This will be removed in a future release, please migrate away from it as soon as possible. */ async stopProcessV2Deprecated( processId: string, appId?: string | undefined, options?: RequestOptions, ): Promise { return unwrapAsync(processesV2StopProcessV2Deprecated( this, processId, appId, options, )); } /** * CreateProcessV2Deprecated * * @remarks * Creates a [process](https://hathora.dev/docs/concepts/hathora-entities#process) without a room. Use this to pre-allocate processes ahead of time so that subsequent room assignment via [CreateRoom()](https://hathora.dev/api#tag/RoomV2/operation/CreateRoom) can be instant. * * @deprecated method: This will be removed in a future release, please migrate away from it as soon as possible. */ async createProcessV2Deprecated( region: components.Region, appId?: string | undefined, options?: RequestOptions, ): Promise { return unwrapAsync(processesV2CreateProcessV2Deprecated( this, region, appId, options, )); } }