UNPKG

attio-js

Version:

Developer-friendly & type-safe JS/TS SDK based on the official OpenAPI spec of Attio.

2,042 lines (1,904 loc) 88.5 kB
/* * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. */ import * as z from "zod"; import { remap as remap$ } from "../../lib/primitives.js"; import { safeParse } from "../../lib/schemas.js"; import { ClosedEnum } from "../../types/enums.js"; import { Result as SafeParseResult } from "../../types/fp.js"; import { SDKValidationError } from "../errors/sdkvalidationerror.js"; import { SelectOption, SelectOption$inboundSchema, SelectOption$Outbound, SelectOption$outboundSchema, } from "./selectoption.js"; import { Status, Status$inboundSchema, Status$Outbound, Status$outboundSchema, } from "./status.js"; /** * The attribute type of the value. */ export const AttributeTypeTimestamp = { Timestamp: "timestamp", } as const; /** * The attribute type of the value. */ export type AttributeTypeTimestamp = ClosedEnum<typeof AttributeTypeTimestamp>; export type OutputValueTimestamp = { /** * The attribute type of the value. */ attributeType: AttributeTypeTimestamp; /** * A timestamp value represents a single, universal moment in time using an ISO 8601 formatted string. This means that a timestamp consists of a date, a time (with nanosecond precision), and a time zone. Attio will coerce timestamps which do not provide full nanosecond precision and UTC is assumed if no time zone is provided. For example, "2023", "2023-01", "2023-01-02", "2023-01-02T13:00", "2023-01-02T13:00:00", and "2023-01-02T13:00:00.000000000" will all be coerced to "2023-01-02T13:00:00.000000000Z". Timestamps are always returned in UTC. For example, writing a timestamp value using the string "2023-01-02T13:00:00.000000000+02:00" will result in the value "2023-01-02T11:00:00.000000000Z" being returned. The maximum date is "9999-12-31T23:59:59.999999999Z". */ value: Date; }; /** * The attribute type of the value. */ export const AttributeTypeText = { Text: "text", } as const; /** * The attribute type of the value. */ export type AttributeTypeText = ClosedEnum<typeof AttributeTypeText>; export type OutputValueText = { /** * A raw text field. Values are limited to 10MB. */ value: string; /** * The attribute type of the value. */ attributeType: AttributeTypeText; }; /** * The attribute type of the value. */ export const AttributeTypeSelect2 = { Select: "select", } as const; /** * The attribute type of the value. */ export type AttributeTypeSelect2 = ClosedEnum<typeof AttributeTypeSelect2>; export type OutputValueSelect2 = { option: SelectOption; /** * The attribute type of the value. */ attributeType: AttributeTypeSelect2; }; /** * The attribute type of the value. */ export const AttributeTypeSelect1 = { Select: "select", } as const; /** * The attribute type of the value. */ export type AttributeTypeSelect1 = ClosedEnum<typeof AttributeTypeSelect1>; export type OutputValueSelect1 = { /** * The UUID identifying the selected select option. */ option: string; /** * The attribute type of the value. */ attributeType: AttributeTypeSelect1; }; /** * The attribute type of the value. */ export const AttributeTypeRating = { Rating: "rating", } as const; /** * The attribute type of the value. */ export type AttributeTypeRating = ClosedEnum<typeof AttributeTypeRating>; export type OutputValueRating = { /** * A number between 0 and 5 (inclusive) to represent a star rating. */ value: number; /** * The attribute type of the value. */ attributeType: AttributeTypeRating; }; /** * The attribute type of the value. */ export const AttributeTypeStatus2 = { Status: "status", } as const; /** * The attribute type of the value. */ export type AttributeTypeStatus2 = ClosedEnum<typeof AttributeTypeStatus2>; export type OutputValueStatus2 = { status: Status; /** * The attribute type of the value. */ attributeType: AttributeTypeStatus2; }; /** * The attribute type of the value. */ export const AttributeTypeStatus1 = { Status: "status", } as const; /** * The attribute type of the value. */ export type AttributeTypeStatus1 = ClosedEnum<typeof AttributeTypeStatus1>; export type OutputValueStatus1 = { /** * The UUID identifying the selected status. */ status: string; /** * The attribute type of the value. */ attributeType: AttributeTypeStatus1; }; /** * The ISO 3166-1 alpha-2 country code representing the country that this phone number belongs to. */ export const OutputValueCountryCode2 = { Af: "AF", Ax: "AX", Al: "AL", Dz: "DZ", As: "AS", Ad: "AD", Ao: "AO", Ai: "AI", Aq: "AQ", Ag: "AG", Ar: "AR", Am: "AM", Aw: "AW", Au: "AU", At: "AT", Az: "AZ", Bs: "BS", Bh: "BH", Bd: "BD", Bb: "BB", By: "BY", Be: "BE", Bz: "BZ", Bj: "BJ", Bm: "BM", Bt: "BT", Bo: "BO", Ba: "BA", Bw: "BW", Bv: "BV", Br: "BR", Io: "IO", Bn: "BN", Bg: "BG", Bf: "BF", Bi: "BI", Kh: "KH", Cm: "CM", Ca: "CA", Cv: "CV", Ky: "KY", Cf: "CF", Td: "TD", Cl: "CL", Cn: "CN", Cx: "CX", Cc: "CC", Co: "CO", Km: "KM", Cg: "CG", Cd: "CD", Ck: "CK", Cr: "CR", Ci: "CI", Hr: "HR", Cu: "CU", Cw: "CW", Cy: "CY", Cz: "CZ", Dk: "DK", Dj: "DJ", Dm: "DM", Do: "DO", Ec: "EC", Eg: "EG", Sv: "SV", Gq: "GQ", Er: "ER", Ee: "EE", Et: "ET", Fk: "FK", Fo: "FO", Fj: "FJ", Fi: "FI", Fr: "FR", Gf: "GF", Pf: "PF", Tf: "TF", Ga: "GA", Gm: "GM", Ge: "GE", De: "DE", Gh: "GH", Gi: "GI", Gr: "GR", Gl: "GL", Gd: "GD", Gp: "GP", Gu: "GU", Gt: "GT", Gg: "GG", Gn: "GN", Gw: "GW", Gy: "GY", Ht: "HT", Hm: "HM", Va: "VA", Hn: "HN", Hk: "HK", Hu: "HU", Is: "IS", In: "IN", Id: "ID", Ir: "IR", Iq: "IQ", Ie: "IE", Im: "IM", Il: "IL", It: "IT", Jm: "JM", Jp: "JP", Je: "JE", Jo: "JO", Kz: "KZ", Ke: "KE", Ki: "KI", Kr: "KR", Kw: "KW", Kg: "KG", La: "LA", Lv: "LV", Lb: "LB", Ls: "LS", Lr: "LR", Ly: "LY", Li: "LI", Lt: "LT", Lu: "LU", Mo: "MO", Mk: "MK", Mg: "MG", Mw: "MW", My: "MY", Mv: "MV", Ml: "ML", Mt: "MT", Mh: "MH", Mq: "MQ", Mr: "MR", Mu: "MU", Yt: "YT", Mx: "MX", Fm: "FM", Md: "MD", Mc: "MC", Mn: "MN", Me: "ME", Ms: "MS", Ma: "MA", Mz: "MZ", Mm: "MM", Na: "NA", Nr: "NR", Np: "NP", Nl: "NL", An: "AN", Nc: "NC", Nz: "NZ", Ni: "NI", Ne: "NE", Ng: "NG", Nu: "NU", Nf: "NF", Mp: "MP", No: "NO", Om: "OM", Pk: "PK", Pw: "PW", Ps: "PS", Pa: "PA", Pg: "PG", Py: "PY", Pe: "PE", Ph: "PH", Pn: "PN", Pl: "PL", Pt: "PT", Pr: "PR", Qa: "QA", Re: "RE", Ro: "RO", Ru: "RU", Rw: "RW", Bl: "BL", Sh: "SH", Kn: "KN", Lc: "LC", Mf: "MF", Pm: "PM", Vc: "VC", Ws: "WS", Sm: "SM", St: "ST", Sa: "SA", Sn: "SN", Ss: "SS", Rs: "RS", Sc: "SC", Sl: "SL", Sg: "SG", Sk: "SK", Si: "SI", Sb: "SB", So: "SO", Za: "ZA", Gs: "GS", Es: "ES", Lk: "LK", Sd: "SD", Sr: "SR", Sj: "SJ", Sz: "SZ", Se: "SE", Ch: "CH", Sy: "SY", Tw: "TW", Tj: "TJ", Tz: "TZ", Th: "TH", Tl: "TL", Tg: "TG", Tk: "TK", To: "TO", Tt: "TT", Tn: "TN", Tr: "TR", Tm: "TM", Tc: "TC", Tv: "TV", Ug: "UG", Ua: "UA", Ae: "AE", Gb: "GB", Us: "US", Um: "UM", Uy: "UY", Uz: "UZ", Vu: "VU", Ve: "VE", Vn: "VN", Vg: "VG", Vi: "VI", Wf: "WF", Eh: "EH", Ye: "YE", Zm: "ZM", Zw: "ZW", } as const; /** * The ISO 3166-1 alpha-2 country code representing the country that this phone number belongs to. */ export type OutputValueCountryCode2 = ClosedEnum< typeof OutputValueCountryCode2 >; /** * The attribute type of the value. */ export const AttributeTypePhoneNumber = { PhoneNumber: "phone-number", } as const; /** * The attribute type of the value. */ export type AttributeTypePhoneNumber = ClosedEnum< typeof AttributeTypePhoneNumber >; export type OutputValuePhoneNumber = { /** * The raw, original phone number, as inputted. */ originalPhoneNumber: string; /** * The ISO 3166-1 alpha-2 country code representing the country that this phone number belongs to. */ countryCode: OutputValueCountryCode2; phoneNumber: string; /** * The attribute type of the value. */ attributeType: AttributeTypePhoneNumber; }; /** * The attribute type of the value. */ export const AttributeTypePersonalName = { PersonalName: "personal-name", } as const; /** * The attribute type of the value. */ export type AttributeTypePersonalName = ClosedEnum< typeof AttributeTypePersonalName >; export type OutputValuePersonalName = { /** * The first name. */ firstName: string; /** * The last name. */ lastName: string; /** * The full name. */ fullName: string; /** * The attribute type of the value. */ attributeType: AttributeTypePersonalName; }; /** * The attribute type of the value. */ export const AttributeTypeNumber = { Number: "number", } as const; /** * The attribute type of the value. */ export type AttributeTypeNumber = ClosedEnum<typeof AttributeTypeNumber>; export type OutputValueNumber = { /** * Numbers are persisted as 64 bit floats. */ value: number; /** * The attribute type of the value. */ attributeType: AttributeTypeNumber; }; /** * The ISO 3166-1 alpha-2 country code for the country this location is in. */ export const OutputValueCountryCode1 = { Af: "AF", Ax: "AX", Al: "AL", Dz: "DZ", As: "AS", Ad: "AD", Ao: "AO", Ai: "AI", Aq: "AQ", Ag: "AG", Ar: "AR", Am: "AM", Aw: "AW", Au: "AU", At: "AT", Az: "AZ", Bs: "BS", Bh: "BH", Bd: "BD", Bb: "BB", By: "BY", Be: "BE", Bz: "BZ", Bj: "BJ", Bm: "BM", Bt: "BT", Bo: "BO", Ba: "BA", Bw: "BW", Bv: "BV", Br: "BR", Io: "IO", Bn: "BN", Bg: "BG", Bf: "BF", Bi: "BI", Kh: "KH", Cm: "CM", Ca: "CA", Cv: "CV", Ky: "KY", Cf: "CF", Td: "TD", Cl: "CL", Cn: "CN", Cx: "CX", Cc: "CC", Co: "CO", Km: "KM", Cg: "CG", Cd: "CD", Ck: "CK", Cr: "CR", Ci: "CI", Hr: "HR", Cu: "CU", Cw: "CW", Cy: "CY", Cz: "CZ", Dk: "DK", Dj: "DJ", Dm: "DM", Do: "DO", Ec: "EC", Eg: "EG", Sv: "SV", Gq: "GQ", Er: "ER", Ee: "EE", Et: "ET", Fk: "FK", Fo: "FO", Fj: "FJ", Fi: "FI", Fr: "FR", Gf: "GF", Pf: "PF", Tf: "TF", Ga: "GA", Gm: "GM", Ge: "GE", De: "DE", Gh: "GH", Gi: "GI", Gr: "GR", Gl: "GL", Gd: "GD", Gp: "GP", Gu: "GU", Gt: "GT", Gg: "GG", Gn: "GN", Gw: "GW", Gy: "GY", Ht: "HT", Hm: "HM", Va: "VA", Hn: "HN", Hk: "HK", Hu: "HU", Is: "IS", In: "IN", Id: "ID", Ir: "IR", Iq: "IQ", Ie: "IE", Im: "IM", Il: "IL", It: "IT", Jm: "JM", Jp: "JP", Je: "JE", Jo: "JO", Kz: "KZ", Ke: "KE", Ki: "KI", Kr: "KR", Kw: "KW", Kg: "KG", La: "LA", Lv: "LV", Lb: "LB", Ls: "LS", Lr: "LR", Ly: "LY", Li: "LI", Lt: "LT", Lu: "LU", Mo: "MO", Mk: "MK", Mg: "MG", Mw: "MW", My: "MY", Mv: "MV", Ml: "ML", Mt: "MT", Mh: "MH", Mq: "MQ", Mr: "MR", Mu: "MU", Yt: "YT", Mx: "MX", Fm: "FM", Md: "MD", Mc: "MC", Mn: "MN", Me: "ME", Ms: "MS", Ma: "MA", Mz: "MZ", Mm: "MM", Na: "NA", Nr: "NR", Np: "NP", Nl: "NL", An: "AN", Nc: "NC", Nz: "NZ", Ni: "NI", Ne: "NE", Ng: "NG", Nu: "NU", Nf: "NF", Mp: "MP", No: "NO", Om: "OM", Pk: "PK", Pw: "PW", Ps: "PS", Pa: "PA", Pg: "PG", Py: "PY", Pe: "PE", Ph: "PH", Pn: "PN", Pl: "PL", Pt: "PT", Pr: "PR", Qa: "QA", Re: "RE", Ro: "RO", Ru: "RU", Rw: "RW", Bl: "BL", Sh: "SH", Kn: "KN", Lc: "LC", Mf: "MF", Pm: "PM", Vc: "VC", Ws: "WS", Sm: "SM", St: "ST", Sa: "SA", Sn: "SN", Ss: "SS", Rs: "RS", Sc: "SC", Sl: "SL", Sg: "SG", Sk: "SK", Si: "SI", Sb: "SB", So: "SO", Za: "ZA", Gs: "GS", Es: "ES", Lk: "LK", Sd: "SD", Sr: "SR", Sj: "SJ", Sz: "SZ", Se: "SE", Ch: "CH", Sy: "SY", Tw: "TW", Tj: "TJ", Tz: "TZ", Th: "TH", Tl: "TL", Tg: "TG", Tk: "TK", To: "TO", Tt: "TT", Tn: "TN", Tr: "TR", Tm: "TM", Tc: "TC", Tv: "TV", Ug: "UG", Ua: "UA", Ae: "AE", Gb: "GB", Us: "US", Um: "UM", Uy: "UY", Uz: "UZ", Vu: "VU", Ve: "VE", Vn: "VN", Vg: "VG", Vi: "VI", Wf: "WF", Eh: "EH", Ye: "YE", Zm: "ZM", Zw: "ZW", } as const; /** * The ISO 3166-1 alpha-2 country code for the country this location is in. */ export type OutputValueCountryCode1 = ClosedEnum< typeof OutputValueCountryCode1 >; /** * The attribute type of the value. */ export const AttributeTypeLocation = { Location: "location", } as const; /** * The attribute type of the value. */ export type AttributeTypeLocation = ClosedEnum<typeof AttributeTypeLocation>; export type OutputValueLocation = { /** * The first line of the address. Note that this value is not currently represented in the UI but will be persisted and readable through API calls. */ line1: string | null; /** * The second line of the address. Note that this value is not currently represented in the UI but will be persisted and readable through API calls. */ line2: string | null; /** * The third line of the address. Note that this value is not currently represented in the UI but will be persisted and readable through API calls. */ line3: string | null; /** * The fourth line of the address. Note that this value is not currently represented in the UI but will be persisted and readable through API calls. */ line4: string | null; /** * The town, neighborhood or area the location is in. */ locality: string | null; /** * The state, county, province or region that the location is in. */ region: string | null; /** * The postcode or zip code for the location. Note that this value is not currently represented in the UI but will be persisted and readable through API calls.} */ postcode: string | null; /** * The ISO 3166-1 alpha-2 country code for the country this location is in. */ countryCode: OutputValueCountryCode1 | null; /** * The latitude of the location. Validated by the regular expression `/^[-+]?([1-8]?\d(\.\d+)?|90(\.0+)?)$/`. Note that this value is not currently represented in the UI but will be persisted and readable through API calls.} */ latitude: string | null; /** * The longitude of the location. Validated by the regular expression `/^[-+]?(180(\.0+)?|((1[0-7]\d)|([1-9]?\d))(\.\d+)?)$/` */ longitude: string | null; /** * The attribute type of the value. */ attributeType: AttributeTypeLocation; }; /** * The type of interaction e.g. calendar or email. */ export const OutputValueInteractionType = { CalendarEvent: "calendar-event", Call: "call", ChatThread: "chat-thread", Email: "email", InPersonMeeting: "in-person-meeting", Meeting: "meeting", } as const; /** * The type of interaction e.g. calendar or email. */ export type OutputValueInteractionType = ClosedEnum< typeof OutputValueInteractionType >; /** * The type of actor. [Read more information on actor types here](/docs/actors). */ export const OutputValueType = { ApiToken: "api-token", WorkspaceMember: "workspace-member", System: "system", App: "app", } as const; /** * The type of actor. [Read more information on actor types here](/docs/actors). */ export type OutputValueType = ClosedEnum<typeof OutputValueType>; /** * The actor that created this value. */ export type OutputValueOwnerActor = { /** * An ID to identify the actor. */ id?: string | null | undefined; /** * The type of actor. [Read more information on actor types here](/docs/actors). */ type?: OutputValueType | null | undefined; }; /** * The attribute type of the value. */ export const AttributeTypeInteraction = { Interaction: "interaction", } as const; /** * The attribute type of the value. */ export type AttributeTypeInteraction = ClosedEnum< typeof AttributeTypeInteraction >; export type OutputValueInteraction = { /** * The type of interaction e.g. calendar or email. */ interactionType: OutputValueInteractionType; /** * When the interaction occurred. */ interactedAt: Date; /** * The actor that created this value. */ ownerActor: OutputValueOwnerActor; /** * The attribute type of the value. */ attributeType: AttributeTypeInteraction; }; /** * The attribute type of the value. */ export const AttributeTypeRecordReference = { RecordReference: "record-reference", } as const; /** * The attribute type of the value. */ export type AttributeTypeRecordReference = ClosedEnum< typeof AttributeTypeRecordReference >; export type OutputValueRecordReference = { /** * A slug identifying the object that the referenced record belongs to. */ targetObject: string; /** * A UUID to identify the referenced record. */ targetRecordId: string; /** * The attribute type of the value. */ attributeType: AttributeTypeRecordReference; }; /** * The attribute type of the value. */ export const AttributeTypeEmailAddress = { EmailAddress: "email-address", } as const; /** * The attribute type of the value. */ export type AttributeTypeEmailAddress = ClosedEnum< typeof AttributeTypeEmailAddress >; export type OutputValueEmailAddress = { originalEmailAddress: string; emailAddress: string; emailDomain: string; emailRootDomain: string; emailLocalSpecifier: string; /** * The attribute type of the value. */ attributeType: AttributeTypeEmailAddress; }; /** * The attribute type of the value. */ export const AttributeTypeDomain = { Domain: "domain", } as const; /** * The attribute type of the value. */ export type AttributeTypeDomain = ClosedEnum<typeof AttributeTypeDomain>; export type OutputValueDomain = { domain: string; rootDomain: string; /** * The attribute type of the value. */ attributeType: AttributeTypeDomain; }; /** * The attribute type of the value. */ export const AttributeTypeDate = { Date: "date", } as const; /** * The attribute type of the value. */ export type AttributeTypeDate = ClosedEnum<typeof AttributeTypeDate>; export type OutputValueDate = { /** * The attribute type of the value. */ attributeType: AttributeTypeDate; /** * A date represents a single calendar year, month and day, independent of timezone. If hours, months, seconds or timezones are provided, they will be trimmed. For example, "2023" and "2023-01" will be coerced into "2023-01-01", and "2023-01-02", "2023-01-02T13:00", "2023-01-02T14:00:00", "2023-01-02T15:00:00.000000000", and "2023-01-02T15:00:00.000000000+02:00" will all be coerced to "2023-01-02". If a timezone is provided that would result in a different calendar date in UTC, the date will be coerced to UTC and then the timezone component will be trimmed. For example, the value "2023-01-02T23:00:00-10:00" will be returned as "2023-01-03". The maximum date is "9999-12-31". */ value: string; }; /** * The ISO4217 currency code representing the currency that the value is stored in. */ export const CurrencyCode = { Aud: "AUD", Brl: "BRL", Bel: "BEL", Cad: "CAD", Cny: "CNY", Cop: "COP", Czk: "CZK", Dkk: "DKK", Eur: "EUR", Hkd: "HKD", Isk: "ISK", Inr: "INR", Ils: "ILS", Jpy: "JPY", Krw: "KRW", Myr: "MYR", Mxn: "MXN", Ntd: "NTD", Nzd: "NZD", Ngn: "NGN", Nok: "NOK", Xpf: "XPF", Pen: "PEN", Php: "PHP", Pln: "PLN", Gbp: "GBP", Sar: "SAR", Sgd: "SGD", Zar: "ZAR", Sek: "SEK", Chf: "CHF", Aed: "AED", Usd: "USD", } as const; /** * The ISO4217 currency code representing the currency that the value is stored in. */ export type CurrencyCode = ClosedEnum<typeof CurrencyCode>; /** * The attribute type of the value. */ export const AttributeTypeCurrency = { Currency: "currency", } as const; /** * The attribute type of the value. */ export type AttributeTypeCurrency = ClosedEnum<typeof AttributeTypeCurrency>; export type OutputValueCurrency = { /** * A numerical representation of the currency value. A decimal with a max of 4 decimal places. */ currencyValue: number; /** * The ISO4217 currency code representing the currency that the value is stored in. */ currencyCode?: CurrencyCode | null | undefined; /** * The attribute type of the value. */ attributeType: AttributeTypeCurrency; }; /** * The attribute type of the value. */ export const AttributeTypeCheckbox = { Checkbox: "checkbox", } as const; /** * The attribute type of the value. */ export type AttributeTypeCheckbox = ClosedEnum<typeof AttributeTypeCheckbox>; export type OutputValueCheckbox = { /** * A boolean representing whether the checkbox is checked or not. The string values 'true' and 'false' are also accepted. */ value: boolean; /** * The attribute type of the value. */ attributeType: AttributeTypeCheckbox; }; /** * The type of the referenced actor. [Read more information on actor types here](/docs/actors). */ export const OutputValueReferencedActorType = { ApiToken: "api-token", WorkspaceMember: "workspace-member", System: "system", App: "app", } as const; /** * The type of the referenced actor. [Read more information on actor types here](/docs/actors). */ export type OutputValueReferencedActorType = ClosedEnum< typeof OutputValueReferencedActorType >; /** * The attribute type of the value. */ export const AttributeTypeActorReference = { ActorReference: "actor-reference", } as const; /** * The attribute type of the value. */ export type AttributeTypeActorReference = ClosedEnum< typeof AttributeTypeActorReference >; export type OutputValueActorReference = { /** * The type of the referenced actor. [Read more information on actor types here](/docs/actors). */ referencedActorType: OutputValueReferencedActorType; /** * The ID of the referenced actor. */ referencedActorId: string | null; /** * The attribute type of the value. */ attributeType: AttributeTypeActorReference; }; /** * A union of possible value types, as returned in response bodies. */ export type OutputValue = | OutputValueCheckbox | OutputValueDate | OutputValueNumber | OutputValueStatus1 | OutputValueStatus2 | OutputValueRating | OutputValueSelect1 | OutputValueSelect2 | OutputValueText | OutputValueTimestamp | OutputValueActorReference | OutputValueCurrency | OutputValueDomain | OutputValueRecordReference | OutputValueInteraction | OutputValuePersonalName | OutputValuePhoneNumber | OutputValueEmailAddress | OutputValueLocation; /** @internal */ export const AttributeTypeTimestamp$inboundSchema: z.ZodNativeEnum< typeof AttributeTypeTimestamp > = z.nativeEnum(AttributeTypeTimestamp); /** @internal */ export const AttributeTypeTimestamp$outboundSchema: z.ZodNativeEnum< typeof AttributeTypeTimestamp > = AttributeTypeTimestamp$inboundSchema; /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ export namespace AttributeTypeTimestamp$ { /** @deprecated use `AttributeTypeTimestamp$inboundSchema` instead. */ export const inboundSchema = AttributeTypeTimestamp$inboundSchema; /** @deprecated use `AttributeTypeTimestamp$outboundSchema` instead. */ export const outboundSchema = AttributeTypeTimestamp$outboundSchema; } /** @internal */ export const OutputValueTimestamp$inboundSchema: z.ZodType< OutputValueTimestamp, z.ZodTypeDef, unknown > = z.object({ attribute_type: AttributeTypeTimestamp$inboundSchema, value: z.string().datetime({ offset: true }).transform(v => new Date(v)), }).transform((v) => { return remap$(v, { "attribute_type": "attributeType", }); }); /** @internal */ export type OutputValueTimestamp$Outbound = { attribute_type: string; value: string; }; /** @internal */ export const OutputValueTimestamp$outboundSchema: z.ZodType< OutputValueTimestamp$Outbound, z.ZodTypeDef, OutputValueTimestamp > = z.object({ attributeType: AttributeTypeTimestamp$outboundSchema, value: z.date().transform(v => v.toISOString()), }).transform((v) => { return remap$(v, { attributeType: "attribute_type", }); }); /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ export namespace OutputValueTimestamp$ { /** @deprecated use `OutputValueTimestamp$inboundSchema` instead. */ export const inboundSchema = OutputValueTimestamp$inboundSchema; /** @deprecated use `OutputValueTimestamp$outboundSchema` instead. */ export const outboundSchema = OutputValueTimestamp$outboundSchema; /** @deprecated use `OutputValueTimestamp$Outbound` instead. */ export type Outbound = OutputValueTimestamp$Outbound; } export function outputValueTimestampToJSON( outputValueTimestamp: OutputValueTimestamp, ): string { return JSON.stringify( OutputValueTimestamp$outboundSchema.parse(outputValueTimestamp), ); } export function outputValueTimestampFromJSON( jsonString: string, ): SafeParseResult<OutputValueTimestamp, SDKValidationError> { return safeParse( jsonString, (x) => OutputValueTimestamp$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'OutputValueTimestamp' from JSON`, ); } /** @internal */ export const AttributeTypeText$inboundSchema: z.ZodNativeEnum< typeof AttributeTypeText > = z.nativeEnum(AttributeTypeText); /** @internal */ export const AttributeTypeText$outboundSchema: z.ZodNativeEnum< typeof AttributeTypeText > = AttributeTypeText$inboundSchema; /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ export namespace AttributeTypeText$ { /** @deprecated use `AttributeTypeText$inboundSchema` instead. */ export const inboundSchema = AttributeTypeText$inboundSchema; /** @deprecated use `AttributeTypeText$outboundSchema` instead. */ export const outboundSchema = AttributeTypeText$outboundSchema; } /** @internal */ export const OutputValueText$inboundSchema: z.ZodType< OutputValueText, z.ZodTypeDef, unknown > = z.object({ value: z.string(), attribute_type: AttributeTypeText$inboundSchema, }).transform((v) => { return remap$(v, { "attribute_type": "attributeType", }); }); /** @internal */ export type OutputValueText$Outbound = { value: string; attribute_type: string; }; /** @internal */ export const OutputValueText$outboundSchema: z.ZodType< OutputValueText$Outbound, z.ZodTypeDef, OutputValueText > = z.object({ value: z.string(), attributeType: AttributeTypeText$outboundSchema, }).transform((v) => { return remap$(v, { attributeType: "attribute_type", }); }); /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ export namespace OutputValueText$ { /** @deprecated use `OutputValueText$inboundSchema` instead. */ export const inboundSchema = OutputValueText$inboundSchema; /** @deprecated use `OutputValueText$outboundSchema` instead. */ export const outboundSchema = OutputValueText$outboundSchema; /** @deprecated use `OutputValueText$Outbound` instead. */ export type Outbound = OutputValueText$Outbound; } export function outputValueTextToJSON( outputValueText: OutputValueText, ): string { return JSON.stringify(OutputValueText$outboundSchema.parse(outputValueText)); } export function outputValueTextFromJSON( jsonString: string, ): SafeParseResult<OutputValueText, SDKValidationError> { return safeParse( jsonString, (x) => OutputValueText$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'OutputValueText' from JSON`, ); } /** @internal */ export const AttributeTypeSelect2$inboundSchema: z.ZodNativeEnum< typeof AttributeTypeSelect2 > = z.nativeEnum(AttributeTypeSelect2); /** @internal */ export const AttributeTypeSelect2$outboundSchema: z.ZodNativeEnum< typeof AttributeTypeSelect2 > = AttributeTypeSelect2$inboundSchema; /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ export namespace AttributeTypeSelect2$ { /** @deprecated use `AttributeTypeSelect2$inboundSchema` instead. */ export const inboundSchema = AttributeTypeSelect2$inboundSchema; /** @deprecated use `AttributeTypeSelect2$outboundSchema` instead. */ export const outboundSchema = AttributeTypeSelect2$outboundSchema; } /** @internal */ export const OutputValueSelect2$inboundSchema: z.ZodType< OutputValueSelect2, z.ZodTypeDef, unknown > = z.object({ option: SelectOption$inboundSchema, attribute_type: AttributeTypeSelect2$inboundSchema, }).transform((v) => { return remap$(v, { "attribute_type": "attributeType", }); }); /** @internal */ export type OutputValueSelect2$Outbound = { option: SelectOption$Outbound; attribute_type: string; }; /** @internal */ export const OutputValueSelect2$outboundSchema: z.ZodType< OutputValueSelect2$Outbound, z.ZodTypeDef, OutputValueSelect2 > = z.object({ option: SelectOption$outboundSchema, attributeType: AttributeTypeSelect2$outboundSchema, }).transform((v) => { return remap$(v, { attributeType: "attribute_type", }); }); /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ export namespace OutputValueSelect2$ { /** @deprecated use `OutputValueSelect2$inboundSchema` instead. */ export const inboundSchema = OutputValueSelect2$inboundSchema; /** @deprecated use `OutputValueSelect2$outboundSchema` instead. */ export const outboundSchema = OutputValueSelect2$outboundSchema; /** @deprecated use `OutputValueSelect2$Outbound` instead. */ export type Outbound = OutputValueSelect2$Outbound; } export function outputValueSelect2ToJSON( outputValueSelect2: OutputValueSelect2, ): string { return JSON.stringify( OutputValueSelect2$outboundSchema.parse(outputValueSelect2), ); } export function outputValueSelect2FromJSON( jsonString: string, ): SafeParseResult<OutputValueSelect2, SDKValidationError> { return safeParse( jsonString, (x) => OutputValueSelect2$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'OutputValueSelect2' from JSON`, ); } /** @internal */ export const AttributeTypeSelect1$inboundSchema: z.ZodNativeEnum< typeof AttributeTypeSelect1 > = z.nativeEnum(AttributeTypeSelect1); /** @internal */ export const AttributeTypeSelect1$outboundSchema: z.ZodNativeEnum< typeof AttributeTypeSelect1 > = AttributeTypeSelect1$inboundSchema; /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ export namespace AttributeTypeSelect1$ { /** @deprecated use `AttributeTypeSelect1$inboundSchema` instead. */ export const inboundSchema = AttributeTypeSelect1$inboundSchema; /** @deprecated use `AttributeTypeSelect1$outboundSchema` instead. */ export const outboundSchema = AttributeTypeSelect1$outboundSchema; } /** @internal */ export const OutputValueSelect1$inboundSchema: z.ZodType< OutputValueSelect1, z.ZodTypeDef, unknown > = z.object({ option: z.string(), attribute_type: AttributeTypeSelect1$inboundSchema, }).transform((v) => { return remap$(v, { "attribute_type": "attributeType", }); }); /** @internal */ export type OutputValueSelect1$Outbound = { option: string; attribute_type: string; }; /** @internal */ export const OutputValueSelect1$outboundSchema: z.ZodType< OutputValueSelect1$Outbound, z.ZodTypeDef, OutputValueSelect1 > = z.object({ option: z.string(), attributeType: AttributeTypeSelect1$outboundSchema, }).transform((v) => { return remap$(v, { attributeType: "attribute_type", }); }); /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ export namespace OutputValueSelect1$ { /** @deprecated use `OutputValueSelect1$inboundSchema` instead. */ export const inboundSchema = OutputValueSelect1$inboundSchema; /** @deprecated use `OutputValueSelect1$outboundSchema` instead. */ export const outboundSchema = OutputValueSelect1$outboundSchema; /** @deprecated use `OutputValueSelect1$Outbound` instead. */ export type Outbound = OutputValueSelect1$Outbound; } export function outputValueSelect1ToJSON( outputValueSelect1: OutputValueSelect1, ): string { return JSON.stringify( OutputValueSelect1$outboundSchema.parse(outputValueSelect1), ); } export function outputValueSelect1FromJSON( jsonString: string, ): SafeParseResult<OutputValueSelect1, SDKValidationError> { return safeParse( jsonString, (x) => OutputValueSelect1$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'OutputValueSelect1' from JSON`, ); } /** @internal */ export const AttributeTypeRating$inboundSchema: z.ZodNativeEnum< typeof AttributeTypeRating > = z.nativeEnum(AttributeTypeRating); /** @internal */ export const AttributeTypeRating$outboundSchema: z.ZodNativeEnum< typeof AttributeTypeRating > = AttributeTypeRating$inboundSchema; /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ export namespace AttributeTypeRating$ { /** @deprecated use `AttributeTypeRating$inboundSchema` instead. */ export const inboundSchema = AttributeTypeRating$inboundSchema; /** @deprecated use `AttributeTypeRating$outboundSchema` instead. */ export const outboundSchema = AttributeTypeRating$outboundSchema; } /** @internal */ export const OutputValueRating$inboundSchema: z.ZodType< OutputValueRating, z.ZodTypeDef, unknown > = z.object({ value: z.number(), attribute_type: AttributeTypeRating$inboundSchema, }).transform((v) => { return remap$(v, { "attribute_type": "attributeType", }); }); /** @internal */ export type OutputValueRating$Outbound = { value: number; attribute_type: string; }; /** @internal */ export const OutputValueRating$outboundSchema: z.ZodType< OutputValueRating$Outbound, z.ZodTypeDef, OutputValueRating > = z.object({ value: z.number(), attributeType: AttributeTypeRating$outboundSchema, }).transform((v) => { return remap$(v, { attributeType: "attribute_type", }); }); /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ export namespace OutputValueRating$ { /** @deprecated use `OutputValueRating$inboundSchema` instead. */ export const inboundSchema = OutputValueRating$inboundSchema; /** @deprecated use `OutputValueRating$outboundSchema` instead. */ export const outboundSchema = OutputValueRating$outboundSchema; /** @deprecated use `OutputValueRating$Outbound` instead. */ export type Outbound = OutputValueRating$Outbound; } export function outputValueRatingToJSON( outputValueRating: OutputValueRating, ): string { return JSON.stringify( OutputValueRating$outboundSchema.parse(outputValueRating), ); } export function outputValueRatingFromJSON( jsonString: string, ): SafeParseResult<OutputValueRating, SDKValidationError> { return safeParse( jsonString, (x) => OutputValueRating$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'OutputValueRating' from JSON`, ); } /** @internal */ export const AttributeTypeStatus2$inboundSchema: z.ZodNativeEnum< typeof AttributeTypeStatus2 > = z.nativeEnum(AttributeTypeStatus2); /** @internal */ export const AttributeTypeStatus2$outboundSchema: z.ZodNativeEnum< typeof AttributeTypeStatus2 > = AttributeTypeStatus2$inboundSchema; /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ export namespace AttributeTypeStatus2$ { /** @deprecated use `AttributeTypeStatus2$inboundSchema` instead. */ export const inboundSchema = AttributeTypeStatus2$inboundSchema; /** @deprecated use `AttributeTypeStatus2$outboundSchema` instead. */ export const outboundSchema = AttributeTypeStatus2$outboundSchema; } /** @internal */ export const OutputValueStatus2$inboundSchema: z.ZodType< OutputValueStatus2, z.ZodTypeDef, unknown > = z.object({ status: Status$inboundSchema, attribute_type: AttributeTypeStatus2$inboundSchema, }).transform((v) => { return remap$(v, { "attribute_type": "attributeType", }); }); /** @internal */ export type OutputValueStatus2$Outbound = { status: Status$Outbound; attribute_type: string; }; /** @internal */ export const OutputValueStatus2$outboundSchema: z.ZodType< OutputValueStatus2$Outbound, z.ZodTypeDef, OutputValueStatus2 > = z.object({ status: Status$outboundSchema, attributeType: AttributeTypeStatus2$outboundSchema, }).transform((v) => { return remap$(v, { attributeType: "attribute_type", }); }); /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ export namespace OutputValueStatus2$ { /** @deprecated use `OutputValueStatus2$inboundSchema` instead. */ export const inboundSchema = OutputValueStatus2$inboundSchema; /** @deprecated use `OutputValueStatus2$outboundSchema` instead. */ export const outboundSchema = OutputValueStatus2$outboundSchema; /** @deprecated use `OutputValueStatus2$Outbound` instead. */ export type Outbound = OutputValueStatus2$Outbound; } export function outputValueStatus2ToJSON( outputValueStatus2: OutputValueStatus2, ): string { return JSON.stringify( OutputValueStatus2$outboundSchema.parse(outputValueStatus2), ); } export function outputValueStatus2FromJSON( jsonString: string, ): SafeParseResult<OutputValueStatus2, SDKValidationError> { return safeParse( jsonString, (x) => OutputValueStatus2$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'OutputValueStatus2' from JSON`, ); } /** @internal */ export const AttributeTypeStatus1$inboundSchema: z.ZodNativeEnum< typeof AttributeTypeStatus1 > = z.nativeEnum(AttributeTypeStatus1); /** @internal */ export const AttributeTypeStatus1$outboundSchema: z.ZodNativeEnum< typeof AttributeTypeStatus1 > = AttributeTypeStatus1$inboundSchema; /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ export namespace AttributeTypeStatus1$ { /** @deprecated use `AttributeTypeStatus1$inboundSchema` instead. */ export const inboundSchema = AttributeTypeStatus1$inboundSchema; /** @deprecated use `AttributeTypeStatus1$outboundSchema` instead. */ export const outboundSchema = AttributeTypeStatus1$outboundSchema; } /** @internal */ export const OutputValueStatus1$inboundSchema: z.ZodType< OutputValueStatus1, z.ZodTypeDef, unknown > = z.object({ status: z.string(), attribute_type: AttributeTypeStatus1$inboundSchema, }).transform((v) => { return remap$(v, { "attribute_type": "attributeType", }); }); /** @internal */ export type OutputValueStatus1$Outbound = { status: string; attribute_type: string; }; /** @internal */ export const OutputValueStatus1$outboundSchema: z.ZodType< OutputValueStatus1$Outbound, z.ZodTypeDef, OutputValueStatus1 > = z.object({ status: z.string(), attributeType: AttributeTypeStatus1$outboundSchema, }).transform((v) => { return remap$(v, { attributeType: "attribute_type", }); }); /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ export namespace OutputValueStatus1$ { /** @deprecated use `OutputValueStatus1$inboundSchema` instead. */ export const inboundSchema = OutputValueStatus1$inboundSchema; /** @deprecated use `OutputValueStatus1$outboundSchema` instead. */ export const outboundSchema = OutputValueStatus1$outboundSchema; /** @deprecated use `OutputValueStatus1$Outbound` instead. */ export type Outbound = OutputValueStatus1$Outbound; } export function outputValueStatus1ToJSON( outputValueStatus1: OutputValueStatus1, ): string { return JSON.stringify( OutputValueStatus1$outboundSchema.parse(outputValueStatus1), ); } export function outputValueStatus1FromJSON( jsonString: string, ): SafeParseResult<OutputValueStatus1, SDKValidationError> { return safeParse( jsonString, (x) => OutputValueStatus1$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'OutputValueStatus1' from JSON`, ); } /** @internal */ export const OutputValueCountryCode2$inboundSchema: z.ZodNativeEnum< typeof OutputValueCountryCode2 > = z.nativeEnum(OutputValueCountryCode2); /** @internal */ export const OutputValueCountryCode2$outboundSchema: z.ZodNativeEnum< typeof OutputValueCountryCode2 > = OutputValueCountryCode2$inboundSchema; /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ export namespace OutputValueCountryCode2$ { /** @deprecated use `OutputValueCountryCode2$inboundSchema` instead. */ export const inboundSchema = OutputValueCountryCode2$inboundSchema; /** @deprecated use `OutputValueCountryCode2$outboundSchema` instead. */ export const outboundSchema = OutputValueCountryCode2$outboundSchema; } /** @internal */ export const AttributeTypePhoneNumber$inboundSchema: z.ZodNativeEnum< typeof AttributeTypePhoneNumber > = z.nativeEnum(AttributeTypePhoneNumber); /** @internal */ export const AttributeTypePhoneNumber$outboundSchema: z.ZodNativeEnum< typeof AttributeTypePhoneNumber > = AttributeTypePhoneNumber$inboundSchema; /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ export namespace AttributeTypePhoneNumber$ { /** @deprecated use `AttributeTypePhoneNumber$inboundSchema` instead. */ export const inboundSchema = AttributeTypePhoneNumber$inboundSchema; /** @deprecated use `AttributeTypePhoneNumber$outboundSchema` instead. */ export const outboundSchema = AttributeTypePhoneNumber$outboundSchema; } /** @internal */ export const OutputValuePhoneNumber$inboundSchema: z.ZodType< OutputValuePhoneNumber, z.ZodTypeDef, unknown > = z.object({ original_phone_number: z.string(), country_code: OutputValueCountryCode2$inboundSchema, phone_number: z.string(), attribute_type: AttributeTypePhoneNumber$inboundSchema, }).transform((v) => { return remap$(v, { "original_phone_number": "originalPhoneNumber", "country_code": "countryCode", "phone_number": "phoneNumber", "attribute_type": "attributeType", }); }); /** @internal */ export type OutputValuePhoneNumber$Outbound = { original_phone_number: string; country_code: string; phone_number: string; attribute_type: string; }; /** @internal */ export const OutputValuePhoneNumber$outboundSchema: z.ZodType< OutputValuePhoneNumber$Outbound, z.ZodTypeDef, OutputValuePhoneNumber > = z.object({ originalPhoneNumber: z.string(), countryCode: OutputValueCountryCode2$outboundSchema, phoneNumber: z.string(), attributeType: AttributeTypePhoneNumber$outboundSchema, }).transform((v) => { return remap$(v, { originalPhoneNumber: "original_phone_number", countryCode: "country_code", phoneNumber: "phone_number", attributeType: "attribute_type", }); }); /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ export namespace OutputValuePhoneNumber$ { /** @deprecated use `OutputValuePhoneNumber$inboundSchema` instead. */ export const inboundSchema = OutputValuePhoneNumber$inboundSchema; /** @deprecated use `OutputValuePhoneNumber$outboundSchema` instead. */ export const outboundSchema = OutputValuePhoneNumber$outboundSchema; /** @deprecated use `OutputValuePhoneNumber$Outbound` instead. */ export type Outbound = OutputValuePhoneNumber$Outbound; } export function outputValuePhoneNumberToJSON( outputValuePhoneNumber: OutputValuePhoneNumber, ): string { return JSON.stringify( OutputValuePhoneNumber$outboundSchema.parse(outputValuePhoneNumber), ); } export function outputValuePhoneNumberFromJSON( jsonString: string, ): SafeParseResult<OutputValuePhoneNumber, SDKValidationError> { return safeParse( jsonString, (x) => OutputValuePhoneNumber$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'OutputValuePhoneNumber' from JSON`, ); } /** @internal */ export const AttributeTypePersonalName$inboundSchema: z.ZodNativeEnum< typeof AttributeTypePersonalName > = z.nativeEnum(AttributeTypePersonalName); /** @internal */ export const AttributeTypePersonalName$outboundSchema: z.ZodNativeEnum< typeof AttributeTypePersonalName > = AttributeTypePersonalName$inboundSchema; /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ export namespace AttributeTypePersonalName$ { /** @deprecated use `AttributeTypePersonalName$inboundSchema` instead. */ export const inboundSchema = AttributeTypePersonalName$inboundSchema; /** @deprecated use `AttributeTypePersonalName$outboundSchema` instead. */ export const outboundSchema = AttributeTypePersonalName$outboundSchema; } /** @internal */ export const OutputValuePersonalName$inboundSchema: z.ZodType< OutputValuePersonalName, z.ZodTypeDef, unknown > = z.object({ first_name: z.string(), last_name: z.string(), full_name: z.string(), attribute_type: AttributeTypePersonalName$inboundSchema, }).transform((v) => { return remap$(v, { "first_name": "firstName", "last_name": "lastName", "full_name": "fullName", "attribute_type": "attributeType", }); }); /** @internal */ export type OutputValuePersonalName$Outbound = { first_name: string; last_name: string; full_name: string; attribute_type: string; }; /** @internal */ export const OutputValuePersonalName$outboundSchema: z.ZodType< OutputValuePersonalName$Outbound, z.ZodTypeDef, OutputValuePersonalName > = z.object({ firstName: z.string(), lastName: z.string(), fullName: z.string(), attributeType: AttributeTypePersonalName$outboundSchema, }).transform((v) => { return remap$(v, { firstName: "first_name", lastName: "last_name", fullName: "full_name", attributeType: "attribute_type", }); }); /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ export namespace OutputValuePersonalName$ { /** @deprecated use `OutputValuePersonalName$inboundSchema` instead. */ export const inboundSchema = OutputValuePersonalName$inboundSchema; /** @deprecated use `OutputValuePersonalName$outboundSchema` instead. */ export const outboundSchema = OutputValuePersonalName$outboundSchema; /** @deprecated use `OutputValuePersonalName$Outbound` instead. */ export type Outbound = OutputValuePersonalName$Outbound; } export function outputValuePersonalNameToJSON( outputValuePersonalName: OutputValuePersonalName, ): string { return JSON.stringify( OutputValuePersonalName$outboundSchema.parse(outputValuePersonalName), ); } export function outputValuePersonalNameFromJSON( jsonString: string, ): SafeParseResult<OutputValuePersonalName, SDKValidationError> { return safeParse( jsonString, (x) => OutputValuePersonalName$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'OutputValuePersonalName' from JSON`, ); } /** @internal */ export const AttributeTypeNumber$inboundSchema: z.ZodNativeEnum< typeof AttributeTypeNumber > = z.nativeEnum(AttributeTypeNumber); /** @internal */ export const AttributeTypeNumber$outboundSchema: z.ZodNativeEnum< typeof AttributeTypeNumber > = AttributeTypeNumber$inboundSchema; /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ export namespace AttributeTypeNumber$ { /** @deprecated use `AttributeTypeNumber$inboundSchema` instead. */ export const inboundSchema = AttributeTypeNumber$inboundSchema; /** @deprecated use `AttributeTypeNumber$outboundSchema` instead. */ export const outboundSchema = AttributeTypeNumber$outboundSchema; } /** @internal */ export const OutputValueNumber$inboundSchema: z.ZodType< OutputValueNumber, z.ZodTypeDef, unknown > = z.object({ value: z.number(), attribute_type: AttributeTypeNumber$inboundSchema, }).transform((v) => { return remap$(v, { "attribute_type": "attributeType", }); }); /** @internal */ export type OutputValueNumber$Outbound = { value: number; attribute_type: string; }; /** @internal */ export const OutputValueNumber$outboundSchema: z.ZodType< OutputValueNumber$Outbound, z.ZodTypeDef, OutputValueNumber > = z.object({ value: z.number(), attributeType: AttributeTypeNumber$outboundSchema, }).transform((v) => { return remap$(v, { attributeType: "attribute_type", }); }); /** * @internal * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. */ export namespace OutputValueNumber$ { /** @deprecated use `OutputValueNumber$inboundSchema` instead. */ export const inboundSchema = OutputValueNumber$inboundSchema; /** @depreca