import type { ApiClient } from "@promobase/sdk-runtime"; import { Cursor } from "@promobase/sdk-runtime"; import { metaPagination } from "../../pagination.ts"; import type { LeadgenFormFields } from "./leadgen-form.ts"; import type { PageFields } from "./page.ts"; export interface MessengerAdsPartialAutomatedStepListFields { fblead_form: LeadgenFormFields; first_step_id: string; id: string; page: PageFields; privacy_url: string; reminder_text: string; stop_question_message: string; } export function messengerAdsPartialAutomatedStepListNode(client: ApiClient, id: string) { return { __path: id, __brand: undefined as unknown as MessengerAdsPartialAutomatedStepListFields, get: (opts: { fields: F; params?: Record }) => client.get>(`${id}`, opts), steps: )[]>(opts: { fields: F; params?: Record }) => new Cursor, F[number]>>(client, `${id}/steps`, opts as { fields: readonly string[]; params?: Record }, metaPagination()), }; }