diff --git a/.speakeasy/gen.lock b/.speakeasy/gen.lock index ea8f7b44..bdc554c2 100755 --- a/.speakeasy/gen.lock +++ b/.speakeasy/gen.lock @@ -1,12 +1,12 @@ lockVersion: 2.0.0 id: f28179cc-ef59-426d-9e85-60cec22fc642 management: - docChecksum: 91f8a271509d1f385478a60c83339f25 + docChecksum: 8242eb9b26c7e6790d67cbbd98b96b1b docVersion: 0.0.1 - speakeasyVersion: 1.456.1 - generationVersion: 2.481.0 - releaseVersion: 0.46.7 - configChecksum: 95646f8cacdf7b5d2c5bf3c570c4762e + speakeasyVersion: 1.459.2 + generationVersion: 2.483.1 + releaseVersion: 0.46.8 + configChecksum: 45ea4f7d62e5e97dcf681c0c81a36179 repoURL: https://github.com/dubinc/dub-ts.git installationURL: https://github.com/dubinc/dub-ts published: true @@ -14,7 +14,7 @@ features: typescript: additionalDependencies: 0.1.0 constsAndDefaults: 0.1.11 - core: 3.18.11 + core: 3.18.12 defaultEnabledRetries: 0.1.0 deprecations: 2.81.1 enumUnions: 0.1.0 @@ -30,7 +30,7 @@ features: methodArguments: 0.1.2 nameOverrides: 2.81.2 nullables: 0.1.0 - pagination: 2.82.7 + pagination: 2.82.8 responseFormat: 0.2.3 retries: 2.83.0 sdkHooks: 0.2.0 @@ -77,11 +77,13 @@ generatedFiles: - docs/models/components/leadcreatedeventclick.md - docs/models/components/leadcreatedeventcustomer.md - docs/models/components/leadcreatedeventdata.md + - docs/models/components/leadcreatedeventdatalink.md - docs/models/components/leadcreatedeventevent.md - docs/models/components/leadcreatedeventgeo.md - docs/models/components/leadcreatedeventlink.md - docs/models/components/leadevent.md - docs/models/components/leadeventclick.md + - docs/models/components/leadeventcustomerlink.md - docs/models/components/leadeventevent.md - docs/models/components/leadeventgeo.md - docs/models/components/leadeventlink.md @@ -107,6 +109,7 @@ generatedFiles: - docs/models/components/salecreatedeventclick.md - docs/models/components/salecreatedeventcustomer.md - docs/models/components/salecreatedeventdata.md + - docs/models/components/salecreatedeventdatalink.md - docs/models/components/salecreatedeventevent.md - docs/models/components/salecreatedeventgeo.md - docs/models/components/salecreatedeventlink.md @@ -114,6 +117,7 @@ generatedFiles: - docs/models/components/saleevent.md - docs/models/components/saleeventclick.md - docs/models/components/saleeventcustomer.md + - docs/models/components/saleeventcustomerlink.md - docs/models/components/saleeventevent.md - docs/models/components/saleeventgeo.md - docs/models/components/saleeventlink.md @@ -161,6 +165,7 @@ generatedFiles: - docs/models/operations/bulkupdatelinkstagnames.md - docs/models/operations/click.md - docs/models/operations/color.md + - docs/models/operations/createcustomerlink.md - docs/models/operations/createcustomerrequestbody.md - docs/models/operations/createcustomerresponsebody.md - docs/models/operations/createdomainrequestbody.md @@ -179,6 +184,7 @@ generatedFiles: - docs/models/operations/deletetagrequest.md - docs/models/operations/deletetagresponsebody.md - docs/models/operations/event.md + - docs/models/operations/getcustomerlink.md - docs/models/operations/getcustomerrequest.md - docs/models/operations/getcustomerresponsebody.md - docs/models/operations/getlinkinforequest.md @@ -194,6 +200,7 @@ generatedFiles: - docs/models/operations/groupby.md - docs/models/operations/interval.md - docs/models/operations/level.md + - docs/models/operations/link.md - docs/models/operations/listdomainsrequest.md - docs/models/operations/listdomainsresponse.md - docs/models/operations/listeventsqueryparamtagids.md @@ -219,8 +226,6 @@ generatedFiles: - docs/models/operations/tagids.md - docs/models/operations/tagnames.md - docs/models/operations/three.md - - docs/models/operations/trackcustomerrequestbody.md - - docs/models/operations/trackcustomerresponsebody.md - docs/models/operations/trackleadrequestbody.md - docs/models/operations/trackleadresponsebody.md - docs/models/operations/tracksalecustomer.md @@ -228,6 +233,7 @@ generatedFiles: - docs/models/operations/tracksaleresponsebody.md - docs/models/operations/trigger.md - docs/models/operations/two.md + - docs/models/operations/updatecustomerlink.md - docs/models/operations/updatecustomerrequest.md - docs/models/operations/updatecustomerrequestbody.md - docs/models/operations/updatecustomerresponsebody.md @@ -288,7 +294,6 @@ generatedFiles: - src/funcs/tagsDelete.ts - src/funcs/tagsList.ts - src/funcs/tagsUpdate.ts - - src/funcs/trackCustomer.ts - src/funcs/trackLead.ts - src/funcs/trackSale.ts - src/funcs/workspacesGet.ts @@ -378,7 +383,6 @@ generatedFiles: - src/models/operations/listdomains.ts - src/models/operations/listevents.ts - src/models/operations/retrieveanalytics.ts - - src/models/operations/trackcustomer.ts - src/models/operations/tracklead.ts - src/models/operations/tracksale.ts - src/models/operations/updatecustomer.ts diff --git a/.speakeasy/gen.yaml b/.speakeasy/gen.yaml index 215a13cc..c80b8d73 100755 --- a/.speakeasy/gen.yaml +++ b/.speakeasy/gen.yaml @@ -13,7 +13,7 @@ generation: oAuth2ClientCredentialsEnabled: false oAuth2PasswordEnabled: false typescript: - version: 0.46.7 + version: 0.46.8 additionalDependencies: dependencies: {} devDependencies: diff --git a/.speakeasy/workflow.lock b/.speakeasy/workflow.lock index df6b6646..b87a7e28 100644 --- a/.speakeasy/workflow.lock +++ b/.speakeasy/workflow.lock @@ -1,21 +1,21 @@ -speakeasyVersion: 1.456.1 +speakeasyVersion: 1.459.2 sources: my-first-source: sourceNamespace: my-first-source - sourceRevisionDigest: sha256:55c3751ed985c605a654db813b1abc25a337fe45b0f354194421a0e2debfd363 - sourceBlobDigest: sha256:dd73501fb0082ccb7033caed86fb515bcb93da12c57f60ee5448c42448cd0d8f + sourceRevisionDigest: sha256:863222a06bab87028207c717ff5b5bb7f75a7c7ec71ba5490ad86e454bd240a2 + sourceBlobDigest: sha256:31c3bc85b042d5d18b7291d6a5247793acae15f938e3f4dc7c42709e91b8670b tags: - latest - - speakeasy-sdk-regen-1734568080 + - speakeasy-sdk-regen-1734654398 - 0.0.1 targets: my-first-target: source: my-first-source sourceNamespace: my-first-source - sourceRevisionDigest: sha256:55c3751ed985c605a654db813b1abc25a337fe45b0f354194421a0e2debfd363 - sourceBlobDigest: sha256:dd73501fb0082ccb7033caed86fb515bcb93da12c57f60ee5448c42448cd0d8f + sourceRevisionDigest: sha256:863222a06bab87028207c717ff5b5bb7f75a7c7ec71ba5490ad86e454bd240a2 + sourceBlobDigest: sha256:31c3bc85b042d5d18b7291d6a5247793acae15f938e3f4dc7c42709e91b8670b codeSamplesNamespace: code-samples-typescript-my-first-target - codeSamplesRevisionDigest: sha256:8c600623c18eb5cb21cc79917a737ff02492fe4b24a605f28fd78e2587ad71bc + codeSamplesRevisionDigest: sha256:62632ded4ae1c68bce3ecd52db3a9e1965f5ebb06e79b912294df000dc834c08 workflow: workflowVersion: 1.0.0 speakeasyVersion: latest diff --git a/README.md b/README.md index 5999f583..76b5b0b6 100644 --- a/README.md +++ b/README.md @@ -183,7 +183,6 @@ run(); * [lead](docs/sdks/track/README.md#lead) - Track a lead * [sale](docs/sdks/track/README.md#sale) - Track a sale -* [~~customer~~](docs/sdks/track/README.md#customer) - Track a customer :warning: **Deprecated** ### [workspaces](docs/sdks/workspaces/README.md) @@ -570,7 +569,6 @@ To read more about standalone functions, check [FUNCTIONS.md](./FUNCTIONS.md). - [`trackSale`](docs/sdks/track/README.md#sale) - Track a sale - [`workspacesGet`](docs/sdks/workspaces/README.md#get) - Retrieve a workspace - [`workspacesUpdate`](docs/sdks/workspaces/README.md#update) - Update a workspace -- ~~[`trackCustomer`](docs/sdks/track/README.md#customer)~~ - Track a customer :warning: **Deprecated** diff --git a/RELEASES.md b/RELEASES.md index bfef4ba4..7e60dc5f 100644 --- a/RELEASES.md +++ b/RELEASES.md @@ -1076,4 +1076,14 @@ Based on: ### Generated - [typescript v0.46.7] . ### Releases -- [NPM v0.46.7] https://www.npmjs.com/package/dub/v/0.46.7 - . \ No newline at end of file +- [NPM v0.46.7] https://www.npmjs.com/package/dub/v/0.46.7 - . + +## 2024-12-21 05:02:09 +### Changes +Based on: +- OpenAPI Doc +- Speakeasy CLI 1.459.2 (2.483.1) https://github.com/speakeasy-api/speakeasy +### Generated +- [typescript v0.46.8] . +### Releases +- [NPM v0.46.8] https://www.npmjs.com/package/dub/v/0.46.8 - . \ No newline at end of file diff --git a/RUNTIMES.md b/RUNTIMES.md index d08a0c07..80a757e9 100644 --- a/RUNTIMES.md +++ b/RUNTIMES.md @@ -1,6 +1,6 @@ # Supported JavaScript runtimes -This SDK is intended to be used in JavaScript runtimes that support the following features: +This SDK is intended to be used in JavaScript runtimes that support ECMAScript 2020 or newer. The SDK uses the following features: * [Web Fetch API][web-fetch] * [Web Streams API][web-streams] and in particular `ReadableStream` diff --git a/docs/models/components/customer.md b/docs/models/components/customer.md index a47e78a9..fe1bcac7 100644 --- a/docs/models/components/customer.md +++ b/docs/models/components/customer.md @@ -15,11 +15,13 @@ let value: Customer = { ## Fields -| Field | Type | Required | Description | -| ------------------------------------------------------- | ------------------------------------------------------- | ------------------------------------------------------- | ------------------------------------------------------- | -| `id` | *string* | :heavy_check_mark: | The unique identifier of the customer in Dub. | -| `externalId` | *string* | :heavy_check_mark: | Unique identifier for the customer in the client's app. | -| `name` | *string* | :heavy_check_mark: | Name of the customer. | -| `email` | *string* | :heavy_minus_sign: | Email of the customer. | -| `avatar` | *string* | :heavy_minus_sign: | Avatar URL of the customer. | -| `createdAt` | *string* | :heavy_check_mark: | The date the customer was created. | \ No newline at end of file +| Field | Type | Required | Description | +| ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | +| `id` | *string* | :heavy_check_mark: | The unique identifier of the customer in Dub. | +| `externalId` | *string* | :heavy_check_mark: | Unique identifier for the customer in the client's app. | +| `name` | *string* | :heavy_check_mark: | Name of the customer. | +| `email` | *string* | :heavy_minus_sign: | Email of the customer. | +| `avatar` | *string* | :heavy_minus_sign: | Avatar URL of the customer. | +| `country` | *string* | :heavy_minus_sign: | Country of the customer. | +| `createdAt` | *string* | :heavy_check_mark: | The date the customer was created. | +| `link` | [components.LeadEventCustomerLink](../../models/components/leadeventcustomerlink.md) | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/components/data.md b/docs/models/components/data.md index ce2febcf..38dbfc00 100644 --- a/docs/models/components/data.md +++ b/docs/models/components/data.md @@ -7,17 +7,18 @@ import { Data } from "dub/models/components"; let value: Data = { id: "", - domain: "watery-receptor.com", + domain: "front-planula.name", key: "", - url: "https://fond-vision.net", + url: "https://tall-dulcimer.biz/", externalId: "", expiresAt: "", - expiredUrl: "https://royal-humor.info", - password: "yGlwDNI8gr1jyxX", + expiredUrl: "https://livid-hydrolyse.com", + password: "P9FfzjGYgHCfpkZ", title: "", - description: "appliance made-up brr carelessly at", - image: "https://picsum.photos/seed/73U8Q/3606/2034", - video: "https://loremflickr.com/1404/3202?lock=2411083482827735", + description: + "atop sediment duh stingy than wiggly apropos besmirch consequently", + image: "https://picsum.photos/seed/aKFTY75Na/656/1517", + video: "https://picsum.videos/seed/QRBzzi/779/3528", ios: "", android: "", geo: {}, @@ -26,16 +27,15 @@ let value: Data = { { id: "", name: "", - color: "red", + color: "purple", }, ], webhookIds: [ "", ], - comments: - "except obtrude like thorough before verify well-groomed sadly beneath", - shortLink: "https://orderly-final.org", - qrCode: "https://faraway-meadow.info/", + comments: "coordinated guidance anti fast advocate weird qualified woot", + shortLink: "https://colossal-hospitalization.info", + qrCode: "https://misguided-fund.net", utmSource: "", utmMedium: "", utmCampaign: "", diff --git a/docs/models/components/leadcreatedevent.md b/docs/models/components/leadcreatedevent.md index 52fffcfe..1d19e6a7 100644 --- a/docs/models/components/leadcreatedevent.md +++ b/docs/models/components/leadcreatedevent.md @@ -21,32 +21,31 @@ let value: LeadCreatedEvent = { }, click: { id: "", - url: "https://ajar-louse.com", - country: "Suriname", - city: "Bergnaumfurt", + url: "https://tricky-sediment.org/", + country: "Curacao", + city: "Lake Tateshire", region: "", - continent: "South America", + continent: "Australia", device: "Mobile", browser: "Chrome", - os: "Blackberry", - referer: "pitiful-outrun.net", - refererUrl: "https://happy-go-lucky-courtroom.info/", - ip: "21.62.30.141", + os: "Android", + referer: "mysterious-swim.info", + refererUrl: "https://babyish-viability.info", + ip: "86.131.35.50", }, link: { id: "", - domain: "deserted-fencing.net", + domain: "upbeat-supplier.com", key: "", - url: "https://miserable-unblinking.info", + url: "https://primary-disposer.com/", externalId: "", expiresAt: "", - expiredUrl: "https://orderly-haircut.info", - password: "vV8R87bkGlTvqUX", + expiredUrl: "https://diligent-fen.biz", + password: "fzW0NOjS3nSDRTw", title: "", - description: - "bank shyly rapidly brr ew bah whether sediment litter oxidise", - image: "https://loremflickr.com/223/3858?lock=1443587685981279", - video: "https://loremflickr.com/1356/2053?lock=1771237131304753", + description: "as under queasily nucleotidase angrily damaged", + image: "https://loremflickr.com/1688/2574?lock=267713634672299", + video: "https://loremflickr.com/1268/2704?lock=4038872682700146", ios: "", android: "", geo: {}, @@ -55,16 +54,16 @@ let value: LeadCreatedEvent = { { id: "", name: "", - color: "brown", + color: "pink", }, ], webhookIds: [ "", ], comments: - "finally reschedule whenever indeed brightly for till hence phew since woot drat baa gift matter despite generously polyester", - shortLink: "https://frightened-account.com/", - qrCode: "https://disloyal-babushka.com/", + "dimly yippee inasmuch woot acidly gracefully ferociously screw defendant", + shortLink: "https://incomparable-vestment.name", + qrCode: "https://weird-bookend.biz/", utmSource: "", utmMedium: "", utmCampaign: "", diff --git a/docs/models/components/leadcreatedeventclick.md b/docs/models/components/leadcreatedeventclick.md index a95ed724..9263e3af 100644 --- a/docs/models/components/leadcreatedeventclick.md +++ b/docs/models/components/leadcreatedeventclick.md @@ -7,17 +7,17 @@ import { LeadCreatedEventClick } from "dub/models/components"; let value: LeadCreatedEventClick = { id: "", - url: "https://excellent-cook.info/", - country: "Botswana", - city: "South Richmond", + url: "https://qualified-sustenance.com/", + country: "Svalbard & Jan Mayen Islands", + city: "Harrystad", region: "", - continent: "South America", - device: "Desktop", - browser: "Chrome", - os: "Windows Phone", - referer: "considerate-following.com", - refererUrl: "https://classic-meander.name/", - ip: "44ed:dc4d:d5be:eec5:f96a:d764:1db5:10a4", + continent: "North America", + device: "Mobile", + browser: "Firefox", + os: "Chrome OS", + referer: "unripe-department.com", + refererUrl: "https://sad-metabolite.biz", + ip: "157.69.127.85", }; ``` diff --git a/docs/models/components/leadcreatedeventcustomer.md b/docs/models/components/leadcreatedeventcustomer.md index 9d3a751f..eb3277a6 100644 --- a/docs/models/components/leadcreatedeventcustomer.md +++ b/docs/models/components/leadcreatedeventcustomer.md @@ -15,11 +15,13 @@ let value: LeadCreatedEventCustomer = { ## Fields -| Field | Type | Required | Description | -| ------------------------------------------------------- | ------------------------------------------------------- | ------------------------------------------------------- | ------------------------------------------------------- | -| `id` | *string* | :heavy_check_mark: | The unique identifier of the customer in Dub. | -| `externalId` | *string* | :heavy_check_mark: | Unique identifier for the customer in the client's app. | -| `name` | *string* | :heavy_check_mark: | Name of the customer. | -| `email` | *string* | :heavy_minus_sign: | Email of the customer. | -| `avatar` | *string* | :heavy_minus_sign: | Avatar URL of the customer. | -| `createdAt` | *string* | :heavy_check_mark: | The date the customer was created. | \ No newline at end of file +| Field | Type | Required | Description | +| ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | +| `id` | *string* | :heavy_check_mark: | The unique identifier of the customer in Dub. | +| `externalId` | *string* | :heavy_check_mark: | Unique identifier for the customer in the client's app. | +| `name` | *string* | :heavy_check_mark: | Name of the customer. | +| `email` | *string* | :heavy_minus_sign: | Email of the customer. | +| `avatar` | *string* | :heavy_minus_sign: | Avatar URL of the customer. | +| `country` | *string* | :heavy_minus_sign: | Country of the customer. | +| `createdAt` | *string* | :heavy_check_mark: | The date the customer was created. | +| `link` | [components.LeadCreatedEventDataLink](../../models/components/leadcreatedeventdatalink.md) | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/components/leadcreatedeventdata.md b/docs/models/components/leadcreatedeventdata.md index 99162635..c14d5d43 100644 --- a/docs/models/components/leadcreatedeventdata.md +++ b/docs/models/components/leadcreatedeventdata.md @@ -15,31 +15,31 @@ let value: LeadCreatedEventData = { }, click: { id: "", - url: "https://pointed-kielbasa.biz/", - country: "Malawi", - city: "New Rubyeville", + url: "https://windy-rationale.name", + country: "Guatemala", + city: "South Harleyfield", region: "", - continent: "Asia", + continent: "Antarctica", device: "Mobile", - browser: "Firefox", - os: "iOS", - referer: "grimy-jacket.info", - refererUrl: "https://disloyal-bin.info/", - ip: "1e9d:7f8b:bf2b:20af:d116:80ca:fdbd:662b", + browser: "Chrome", + os: "BeOS", + referer: "raw-hexagon.biz", + refererUrl: "https://outlying-handle.net/", + ip: "6e90:d80a:2dbb:edfc:5027:4cb8:bafb:09a9", }, link: { id: "", - domain: "bossy-hydrolyze.biz", + domain: "accomplished-pecan.biz", key: "", - url: "https://husky-tennis.biz", + url: "https://mealy-toothbrush.com/", externalId: "", expiresAt: "", - expiredUrl: "https://paltry-case.name", - password: "hHuGgsPTjfWCJHo", + expiredUrl: "https://outstanding-majority.com/", + password: "pL0iKgOtrxQf5x_", title: "", - description: "boohoo excepting that faint", - image: "https://loremflickr.com/33/479?lock=1771966907057028", - video: "https://loremflickr.com/2280/2140?lock=7210664053745970", + description: "where oof planula forenenst eminent", + image: "https://picsum.photos/seed/dzkEwCCJN/2151/3576", + video: "https://loremflickr.com/248/3793?lock=1532097681395324", ios: "", android: "", geo: {}, @@ -48,16 +48,16 @@ let value: LeadCreatedEventData = { { id: "", name: "", - color: "pink", + color: "brown", }, ], webhookIds: [ "", ], comments: - "pecan overstay consequently anenst when inasmuch ectoderm where oof planula forenenst eminent inasmuch beloved powerfully squeaky", - shortLink: "https://joyous-legislature.com/", - qrCode: "https://these-rim.com/", + "intrepid finally huzzah captain equally apud upward inside during arrange faithfully individual gadzooks lonely hm vice slowly", + shortLink: "https://alienated-lift.org/", + qrCode: "https://unrealistic-linseed.info", utmSource: "", utmMedium: "", utmCampaign: "", diff --git a/docs/models/components/leadcreatedeventdatalink.md b/docs/models/components/leadcreatedeventdatalink.md new file mode 100644 index 00000000..c7da8f61 --- /dev/null +++ b/docs/models/components/leadcreatedeventdatalink.md @@ -0,0 +1,25 @@ +# LeadCreatedEventDataLink + +## Example Usage + +```typescript +import { LeadCreatedEventDataLink } from "dub/models/components"; + +let value: LeadCreatedEventDataLink = { + id: "", + domain: "those-thorn.info", + key: "", + shortLink: "https://defensive-scout.org", + programId: "", +}; +``` + +## Fields + +| Field | Type | Required | Description | +| ----------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------- | +| `id` | *string* | :heavy_check_mark: | The unique ID of the short link. | +| `domain` | *string* | :heavy_check_mark: | The domain of the short link. If not provided, the primary domain for the workspace will be used (or `dub.sh` if the workspace has no domains). | +| `key` | *string* | :heavy_check_mark: | The short link slug. If not provided, a random 7-character slug will be generated. | +| `shortLink` | *string* | :heavy_check_mark: | The full URL of the short link, including the https protocol (e.g. `https://dub.sh/try`). | +| `programId` | *string* | :heavy_check_mark: | The ID of the program the short link is associated with. | \ No newline at end of file diff --git a/docs/models/components/leadcreatedeventlink.md b/docs/models/components/leadcreatedeventlink.md index 65433d82..0596c2e2 100644 --- a/docs/models/components/leadcreatedeventlink.md +++ b/docs/models/components/leadcreatedeventlink.md @@ -7,17 +7,17 @@ import { LeadCreatedEventLink } from "dub/models/components"; let value: LeadCreatedEventLink = { id: "", - domain: "fearless-advancement.com", + domain: "menacing-deer.biz", key: "", - url: "https://excitable-validity.com", + url: "https://idolized-department.org", externalId: "", expiresAt: "", - expiredUrl: "https://trim-hoof.biz/", - password: "buplOVaNGvlypZc", + expiredUrl: "https://clean-procurement.biz/", + password: "V3yeKfHGR9FrjYd", title: "", - description: "fooey pulp except scout mortally stall claw if", - image: "https://picsum.photos/seed/DaMSjES/948/3410", - video: "https://picsum.videos/seed/wPIvuTe/62/3423", + description: "depot deadly fen well-worn suffice drat shell", + image: "https://picsum.photos/seed/z1uBD/608/3365", + video: "https://picsum.videos/seed/FOINDNU/3707/1188", ios: "", android: "", geo: {}, @@ -26,16 +26,16 @@ let value: LeadCreatedEventLink = { { id: "", name: "", - color: "red", + color: "brown", }, ], webhookIds: [ "", ], comments: - "once department gee reboot aha catch receptor ack king different but boo critical powerfully strident", - shortLink: "https://stale-ownership.net", - qrCode: "https://unsung-festival.org", + "as likewise inspection populist circumnavigate hastily in meanwhile oxidize except", + shortLink: "https://impure-reorganisation.com", + qrCode: "https://meager-understanding.name", utmSource: "", utmMedium: "", utmCampaign: "", diff --git a/docs/models/components/leadevent.md b/docs/models/components/leadevent.md index 1d28fce3..76c4d9b2 100644 --- a/docs/models/components/leadevent.md +++ b/docs/models/components/leadevent.md @@ -11,32 +11,31 @@ let value: LeadEvent = { eventName: "", click: { id: "", - url: "https://meaty-following.net/", - country: "Angola", - city: "Feeneyboro", + url: "https://sticky-valuable.biz/", + country: "Somalia", + city: "Lake Nettieville", region: "", - continent: "North America", + continent: "Asia", device: "Mobile", browser: "Chrome", - os: "BeOS", - referer: "careless-overcoat.net", - refererUrl: "https://intelligent-taro.com/", - ip: "151.111.204.236", + os: "Windows", + referer: "overdue-hubris.net", + refererUrl: "https://frilly-gown.info", + ip: "ff85:e2fe:e948:feed:be68:8ce6:086e:dce7", }, link: { id: "", - domain: "frilly-gown.info", + domain: "negligible-singing.com", key: "", - url: "https://worthless-postbox.info", + url: "https://arid-skean.net", externalId: "", expiresAt: "", - expiredUrl: "https://wealthy-chairperson.net/", - password: "xI3CdysnwDEVFzu", + expiredUrl: "https://powerless-knitting.biz/", + password: "jVz8Lh4V2BIG1mX", title: "", - description: - "ascertain yowza vivaciously alongside against so immense tomb total", - image: "https://picsum.photos/seed/2LvMKNi/1437/3550", - video: "https://loremflickr.com/3203/2195?lock=6080993627822653", + description: "whose barring hateful since till atrium smuggle", + image: "https://picsum.photos/seed/RiqNG/2642/610", + video: "https://loremflickr.com/3751/2484?lock=7965610004715368", ios: "", android: "", geo: {}, @@ -45,15 +44,16 @@ let value: LeadEvent = { { id: "", name: "", - color: "red", + color: "pink", }, ], webhookIds: [ "", ], - comments: "yum huzzah outside availability sorrowful towards", - shortLink: "https://big-apricot.org", - qrCode: "https://nocturnal-whack.info/", + comments: + "vibration tomorrow optimistically everlasting specific fray rebuke well-to-do antique reel foot oof interestingly swing across clamour", + shortLink: "https://frightened-disconnection.net/", + qrCode: "https://murky-unblinking.info", utmSource: "", utmMedium: "", utmCampaign: "", @@ -75,17 +75,17 @@ let value: LeadEvent = { }, clickId: "", linkId: "", - domain: "rapid-guidance.net", + domain: "cavernous-hammock.biz", key: "", - url: "https://everlasting-dredger.biz", - continent: "Australia", - country: "Philippines", - city: "Pittsfield", + url: "https://questionable-independence.org/", + continent: "South America", + country: "Peru", + city: "Brendenview", device: "Mobile", browser: "Chrome", - os: "iOS", - qr: 4137.80, - ip: "667b:c118:affa:6cba:f6be:cbe0:3a1b:46f0", + os: "MacOS", + qr: 9078.98, + ip: "dbca:de5d:bbe6:fdab:ae74:ec0e:9d7a:b3fc", }; ``` diff --git a/docs/models/components/leadeventcustomerlink.md b/docs/models/components/leadeventcustomerlink.md new file mode 100644 index 00000000..985cc205 --- /dev/null +++ b/docs/models/components/leadeventcustomerlink.md @@ -0,0 +1,25 @@ +# LeadEventCustomerLink + +## Example Usage + +```typescript +import { LeadEventCustomerLink } from "dub/models/components"; + +let value: LeadEventCustomerLink = { + id: "", + domain: "flawed-lace.info", + key: "", + shortLink: "https://alive-overcoat.biz", + programId: "", +}; +``` + +## Fields + +| Field | Type | Required | Description | +| ----------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------- | +| `id` | *string* | :heavy_check_mark: | The unique ID of the short link. | +| `domain` | *string* | :heavy_check_mark: | The domain of the short link. If not provided, the primary domain for the workspace will be used (or `dub.sh` if the workspace has no domains). | +| `key` | *string* | :heavy_check_mark: | The short link slug. If not provided, a random 7-character slug will be generated. | +| `shortLink` | *string* | :heavy_check_mark: | The full URL of the short link, including the https protocol (e.g. `https://dub.sh/try`). | +| `programId` | *string* | :heavy_check_mark: | The ID of the program the short link is associated with. | \ No newline at end of file diff --git a/docs/models/components/linkclickedevent.md b/docs/models/components/linkclickedevent.md index 2726513d..df8ac9ad 100644 --- a/docs/models/components/linkclickedevent.md +++ b/docs/models/components/linkclickedevent.md @@ -14,32 +14,31 @@ let value: LinkClickedEvent = { data: { click: { id: "", - url: "https://biodegradable-epic.com/", - country: "Zambia", - city: "Leannonfield", + url: "https://flowery-meatloaf.com", + country: "Bouvet Island", + city: "West Ernest", region: "", continent: "Europe", device: "Desktop", - browser: "Chrome", - os: "BeOS", - referer: "greedy-hyena.info", - refererUrl: "https://same-mainstream.net/", - ip: "104.49.107.167", + browser: "Safari", + os: "Windows", + referer: "glum-pile.name", + refererUrl: "https://joyful-expense.name/", + ip: "171.118.70.191", }, link: { id: "", - domain: "wealthy-pharmacopoeia.name", + domain: "deserted-circumference.com", key: "", - url: "https://cautious-intervention.com/", + url: "https://made-up-leading.com", externalId: "", expiresAt: "", - expiredUrl: "https://shallow-underpants.biz", - password: "F2tojU7k5PR5OtH", + expiredUrl: "https://grave-leading.net/", + password: "PoDIr7DIiHqOdTT", title: "", - description: - "sans fairly than knotty place consequently sans beside finally before", - image: "https://picsum.photos/seed/Pn1q5jZ/1335/2065", - video: "https://loremflickr.com/3429/946?lock=3883590246111898", + description: "following in lazily belabor", + image: "https://loremflickr.com/1505/248?lock=2177495066732726", + video: "https://loremflickr.com/751/1619?lock=3149271446944808", ios: "", android: "", geo: {}, @@ -48,15 +47,16 @@ let value: LinkClickedEvent = { { id: "", name: "", - color: "pink", + color: "blue", }, ], webhookIds: [ "", ], - comments: "jump whoever among broadcast intently", - shortLink: "https://blushing-anticodon.name", - qrCode: "https://bare-giant.com/", + comments: + "availability even which filthy ah advocate hence unless meh table gadzooks fooey pulp except scout mortally stall claw", + shortLink: "https://average-prohibition.org", + qrCode: "https://sentimental-euphonium.biz/", utmSource: "", utmMedium: "", utmCampaign: "", diff --git a/docs/models/components/linkclickedeventclick.md b/docs/models/components/linkclickedeventclick.md index c70ba079..f1a67585 100644 --- a/docs/models/components/linkclickedeventclick.md +++ b/docs/models/components/linkclickedeventclick.md @@ -7,17 +7,17 @@ import { LinkClickedEventClick } from "dub/models/components"; let value: LinkClickedEventClick = { id: "", - url: "https://beloved-godfather.info/", - country: "Turks and Caicos Islands", - city: "Meghanside", + url: "https://torn-nougat.org/", + country: "Egypt", + city: "Lake Aubreyfort", region: "", - continent: "Australia", - device: "Desktop", - browser: "Chrome", + continent: "Antarctica", + device: "Mobile", + browser: "Safari", os: "WebOS", - referer: "unselfish-footrest.biz", - refererUrl: "https://hairy-pecan.biz", - ip: "128.236.158.53", + referer: "major-waist.info", + refererUrl: "https://front-reorganisation.info/", + ip: "5.78.220.205", }; ``` diff --git a/docs/models/components/linkclickedeventdata.md b/docs/models/components/linkclickedeventdata.md index 69502342..9feef019 100644 --- a/docs/models/components/linkclickedeventdata.md +++ b/docs/models/components/linkclickedeventdata.md @@ -8,32 +8,32 @@ import { LinkClickedEventData } from "dub/models/components"; let value: LinkClickedEventData = { click: { id: "", - url: "https://grizzled-possession.biz/", - country: "Gambia", - city: "Veumfurt", + url: "https://swift-marksman.net/", + country: "San Marino", + city: "West Javonteshire", region: "", - continent: "Africa", - device: "Mobile", - browser: "Firefox", - os: "Android", - referer: "surprised-scarification.name", - refererUrl: "https://ruddy-teammate.biz/", - ip: "a6d6:2ced:38d3:145b:e00c:d2d5:782f:f95f", + continent: "South America", + device: "Desktop", + browser: "Chrome", + os: "iOS", + referer: "musty-term.biz", + refererUrl: "https://powerless-labourer.biz/", + ip: "125.199.199.249", }, link: { id: "", - domain: "suburban-quart.info", + domain: "icy-grandpa.com", key: "", - url: "https://sparkling-legging.name/", + url: "https://puny-runway.info", externalId: "", expiresAt: "", - expiredUrl: "https://scientific-bowler.info", - password: "074PRao3f_6cW5K", + expiredUrl: "https://ample-captain.info", + password: "V5yo8DLdImWmbZS", title: "", description: - "oof scruple carelessly memorise considering verbally furthermore yet minority", - image: "https://picsum.photos/seed/DFBDCxKmt/172/1340", - video: "https://loremflickr.com/1606/837?lock=495531766047415", + "helpfully chasuble defiantly rightfully behind tuxedo enchanting free humidity", + image: "https://loremflickr.com/833/2212?lock=4819343008042912", + video: "https://loremflickr.com/801/3599?lock=5497405378201913", ios: "", android: "", geo: {}, @@ -42,16 +42,16 @@ let value: LinkClickedEventData = { { id: "", name: "", - color: "green", + color: "red", }, ], webhookIds: [ "", ], comments: - "what knottily apostrophize correctly immense spirit customise for notwithstanding degrease nor", - shortLink: "https://light-baseboard.biz", - qrCode: "https://gray-coast.net", + "ack innovation and shark instead energetically alongside judgementally furthermore meh woot round whereas whenever essence", + shortLink: "https://jealous-steeple.name/", + qrCode: "https://determined-diver.com", utmSource: "", utmMedium: "", utmCampaign: "", diff --git a/docs/models/components/linkclickedeventlink.md b/docs/models/components/linkclickedeventlink.md index f2b60204..14f3e66e 100644 --- a/docs/models/components/linkclickedeventlink.md +++ b/docs/models/components/linkclickedeventlink.md @@ -7,17 +7,17 @@ import { LinkClickedEventLink } from "dub/models/components"; let value: LinkClickedEventLink = { id: "", - domain: "rewarding-rule.biz", + domain: "similar-airline.com", key: "", - url: "https://responsible-coast.org", + url: "https://liquid-thorn.info/", externalId: "", expiresAt: "", - expiredUrl: "https://wordy-cop-out.info/", - password: "07GIuJbPtvCVpCF", + expiredUrl: "https://old-toaster.net/", + password: "r2TcDARbVeEr2j2", title: "", - description: "neatly pro yet blue ugh", - image: "https://picsum.photos/seed/OIxF5tRBW/2869/1417", - video: "https://picsum.videos/seed/MfxOM/1049/386", + description: "astride verbally smug up adult", + image: "https://picsum.photos/seed/WLkencIPE/3902/530", + video: "https://picsum.videos/seed/cmxDtY2/745/150", ios: "", android: "", geo: {}, @@ -26,16 +26,16 @@ let value: LinkClickedEventLink = { { id: "", name: "", - color: "blue", + color: "purple", }, ], webhookIds: [ "", ], comments: - "airbrush happily short-term galoshes unimpressively cook solemnly etch scorpion hence woot saloon bah aw geez affectionate obvious nor anaesthetise option", - shortLink: "https://stained-characterization.com/", - qrCode: "https://hollow-extension.biz", + "vague promise fisherman unethically onto indeed yum exterior pfft throughout absent midst before serene scientific aboard tremendously geez ah", + shortLink: "https://jittery-boyfriend.info", + qrCode: "https://winged-statue.com", utmSource: "", utmMedium: "", utmCampaign: "", diff --git a/docs/models/components/linkwebhookevent.md b/docs/models/components/linkwebhookevent.md index b3c8ba63..a0b68cc5 100644 --- a/docs/models/components/linkwebhookevent.md +++ b/docs/models/components/linkwebhookevent.md @@ -9,21 +9,21 @@ import { LinkWebhookEvent } from "dub/models/components"; let value: LinkWebhookEvent = { id: "", - event: "link.updated", + event: "link.created", createdAt: "", data: { id: "", - domain: "crushing-label.biz", + domain: "another-hepatitis.org", key: "", - url: "https://shimmering-tuba.net/", + url: "https://decisive-trash.biz/", externalId: "", expiresAt: "", - expiredUrl: "https://paltry-reporter.info/", - password: "CfpkZkHhGUL9uEE", + expiredUrl: "https://shady-distinction.biz/", + password: "Fkw0YUnohNzyhHC", title: "", - description: "briefly quip after minus pish up", - image: "https://picsum.photos/seed/cks29anK/3031/246", - video: "https://picsum.videos/seed/TY75NacSW/3325/652", + description: "without yowza readily instead abnormally", + image: "https://picsum.photos/seed/iVlEh6v/1142/3256", + video: "https://loremflickr.com/3693/2474?lock=6146779144649977", ios: "", android: "", geo: {}, @@ -32,16 +32,15 @@ let value: LinkWebhookEvent = { { id: "", name: "", - color: "green", + color: "pink", }, ], webhookIds: [ "", ], - comments: - "athwart coordinated guidance anti fast advocate weird qualified woot concerning huzzah grouper ugh clavicle yawningly dally and whether", - shortLink: "https://sorrowful-jet.name", - qrCode: "https://short-suv.com", + comments: "apud while meh um fabricate actual ew mmm zowie reorient", + shortLink: "https://negative-signature.net/", + qrCode: "https://nautical-pine.com", utmSource: "", utmMedium: "", utmCampaign: "", diff --git a/docs/models/components/paymentprocessor.md b/docs/models/components/paymentprocessor.md index 769f4243..90249e46 100644 --- a/docs/models/components/paymentprocessor.md +++ b/docs/models/components/paymentprocessor.md @@ -7,7 +7,7 @@ The payment processor via which the sale was made. ```typescript import { PaymentProcessor } from "dub/models/components"; -let value: PaymentProcessor = "shopify"; +let value: PaymentProcessor = "paddle"; ``` ## Values diff --git a/docs/models/components/plan.md b/docs/models/components/plan.md index 7c17b827..aba005b5 100644 --- a/docs/models/components/plan.md +++ b/docs/models/components/plan.md @@ -7,7 +7,7 @@ The plan of the workspace. ```typescript import { Plan } from "dub/models/components"; -let value: Plan = "pro"; +let value: Plan = "business max"; ``` ## Values diff --git a/docs/models/components/role.md b/docs/models/components/role.md index 1d405535..18490cb7 100644 --- a/docs/models/components/role.md +++ b/docs/models/components/role.md @@ -7,7 +7,7 @@ The role of the authenticated user in the workspace. ```typescript import { Role } from "dub/models/components"; -let value: Role = "owner"; +let value: Role = "member"; ``` ## Values diff --git a/docs/models/components/sale.md b/docs/models/components/sale.md index c281c170..ceb7daf8 100644 --- a/docs/models/components/sale.md +++ b/docs/models/components/sale.md @@ -6,7 +6,7 @@ import { Sale } from "dub/models/components"; let value: Sale = { - amount: 982927, + amount: 852689, paymentProcessor: "stripe", }; ``` diff --git a/docs/models/components/salecreatedevent.md b/docs/models/components/salecreatedevent.md index 26ae0867..b0d068ae 100644 --- a/docs/models/components/salecreatedevent.md +++ b/docs/models/components/salecreatedevent.md @@ -21,31 +21,31 @@ let value: SaleCreatedEvent = { }, click: { id: "", - url: "https://urban-importance.info/", - country: "Northern Mariana Islands", - city: "New Sheaview", + url: "https://shadowy-scale.com", + country: "Virgin Islands, British", + city: "Stillwater", region: "", - continent: "Asia", + continent: "North America", device: "Desktop", browser: "Safari", - os: "Windows Phone", - referer: "simple-publicity.com", - refererUrl: "https://sarcastic-molasses.com", - ip: "ae9c:da39:8ac0:a53e:cb4a:bbf9:76ff:6ace", + os: "BeOS", + referer: "fearless-commercial.net", + refererUrl: "https://celebrated-guard.biz", + ip: "9ebf:dd5b:a44f:bd9f:36d3:f2b7:a8ad:d3eb", }, link: { id: "", - domain: "experienced-verve.name", + domain: "evil-hammock.net", key: "", - url: "https://specific-coliseum.org", + url: "https://untimely-character.org", externalId: "", expiresAt: "", - expiredUrl: "https://tricky-stall.biz", - password: "qu1hWF_Hldw8Qh6", + expiredUrl: "https://incomparable-injunction.net", + password: "q_mEKQ9HknxMZLB", title: "", - description: "yum shrilly aw stint", - image: "https://loremflickr.com/2361/1639?lock=7157226076564740", - video: "https://loremflickr.com/3379/2631?lock=7281993395579244", + description: "easily eek fine and stigmatize governance ice-cream", + image: "https://loremflickr.com/2508/2494?lock=5708150078719394", + video: "https://picsum.videos/seed/QagcSN/2663/2008", ios: "", android: "", geo: {}, @@ -54,16 +54,16 @@ let value: SaleCreatedEvent = { { id: "", name: "", - color: "red", + color: "blue", }, ], webhookIds: [ "", ], comments: - "through nor cheerfully neatly juvenile instead promptly yahoo emergent bah barring", - shortLink: "https://unfit-seagull.info/", - qrCode: "https://affectionate-premise.org/", + "knowingly unto unfortunately until ascertain yum deceivingly colligate uh-huh drat capsize", + shortLink: "https://ripe-tarragon.com/", + qrCode: "https://remorseful-dulcimer.net", utmSource: "", utmMedium: "", utmCampaign: "", @@ -78,8 +78,8 @@ let value: SaleCreatedEvent = { programId: "", }, sale: { - amount: 7785.19, - currency: "Danish Krone", + amount: 1033.28, + currency: "Dominican Peso", paymentProcessor: "", invoiceId: "", }, diff --git a/docs/models/components/salecreatedeventclick.md b/docs/models/components/salecreatedeventclick.md index 7e931133..738ea0b6 100644 --- a/docs/models/components/salecreatedeventclick.md +++ b/docs/models/components/salecreatedeventclick.md @@ -7,17 +7,17 @@ import { SaleCreatedEventClick } from "dub/models/components"; let value: SaleCreatedEventClick = { id: "", - url: "https://steel-babushka.org/", - country: "Norfolk Island", - city: "Palm Springs", + url: "https://gentle-battle.biz", + country: "Kuwait", + city: "South Augusta", region: "", - continent: "North America", - device: "Desktop", + continent: "Africa", + device: "Mobile", browser: "Chrome", - os: "Blackberry", - referer: "nutritious-labourer.biz", - refererUrl: "https://neighboring-handful.org/", - ip: "9e25:7ca6:d1ae:615a:6920:d16e:c7ea:180f", + os: "Android", + referer: "ragged-starboard.biz", + refererUrl: "https://linear-atrium.info", + ip: "246.195.86.60", }; ``` diff --git a/docs/models/components/salecreatedeventcustomer.md b/docs/models/components/salecreatedeventcustomer.md index 04179999..4e0b3372 100644 --- a/docs/models/components/salecreatedeventcustomer.md +++ b/docs/models/components/salecreatedeventcustomer.md @@ -15,11 +15,13 @@ let value: SaleCreatedEventCustomer = { ## Fields -| Field | Type | Required | Description | -| ------------------------------------------------------- | ------------------------------------------------------- | ------------------------------------------------------- | ------------------------------------------------------- | -| `id` | *string* | :heavy_check_mark: | The unique identifier of the customer in Dub. | -| `externalId` | *string* | :heavy_check_mark: | Unique identifier for the customer in the client's app. | -| `name` | *string* | :heavy_check_mark: | Name of the customer. | -| `email` | *string* | :heavy_minus_sign: | Email of the customer. | -| `avatar` | *string* | :heavy_minus_sign: | Avatar URL of the customer. | -| `createdAt` | *string* | :heavy_check_mark: | The date the customer was created. | \ No newline at end of file +| Field | Type | Required | Description | +| ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------ | +| `id` | *string* | :heavy_check_mark: | The unique identifier of the customer in Dub. | +| `externalId` | *string* | :heavy_check_mark: | Unique identifier for the customer in the client's app. | +| `name` | *string* | :heavy_check_mark: | Name of the customer. | +| `email` | *string* | :heavy_minus_sign: | Email of the customer. | +| `avatar` | *string* | :heavy_minus_sign: | Avatar URL of the customer. | +| `country` | *string* | :heavy_minus_sign: | Country of the customer. | +| `createdAt` | *string* | :heavy_check_mark: | The date the customer was created. | +| `link` | [components.SaleCreatedEventDataLink](../../models/components/salecreatedeventdatalink.md) | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/components/salecreatedeventdata.md b/docs/models/components/salecreatedeventdata.md index 09c41a7a..7872a46d 100644 --- a/docs/models/components/salecreatedeventdata.md +++ b/docs/models/components/salecreatedeventdata.md @@ -15,31 +15,31 @@ let value: SaleCreatedEventData = { }, click: { id: "", - url: "https://blaring-compromise.biz", - country: "Nepal", - city: "North Fordcester", + url: "https://extroverted-behest.name", + country: "Burundi", + city: "Kunzecester", region: "", - continent: "Europe", + continent: "Asia", device: "Mobile", browser: "Safari", os: "Windows Phone", - referer: "low-cross-contamination.name", - refererUrl: "https://cluttered-membership.com", - ip: "322e:d51b:3baf:8ffc:ccc6:eb8b:356b:f62c", + referer: "terrible-moment.name", + refererUrl: "https://victorious-league.info/", + ip: "356b:f62c:c9a6:b23f:fcbf:4b7a:ff20:acfa", }, link: { id: "", - domain: "tidy-hello.info", + domain: "magnificent-formamide.net", key: "", - url: "https://striking-case.biz/", + url: "https://portly-tarragon.com/", externalId: "", expiresAt: "", - expiredUrl: "https://rewarding-mantua.net", - password: "3lAfdhWbhOBjEu0", + expiredUrl: "https://fantastic-secret.name/", + password: "zUi_nKI6c5phyVK", title: "", - description: "sans beside spork", - image: "https://picsum.photos/seed/ysNCh/241/3004", - video: "https://picsum.videos/seed/7R25Xn4t21/6/1931", + description: "christen nor ceramics hm invite butter platter abacus which", + image: "https://loremflickr.com/3700/2997?lock=5664857904966971", + video: "https://loremflickr.com/929/1069?lock=5155823791799436", ios: "", android: "", geo: {}, @@ -54,9 +54,9 @@ let value: SaleCreatedEventData = { webhookIds: [ "", ], - comments: "fully brook mmm bah carp gah off er", - shortLink: "https://spanish-airmail.biz/", - qrCode: "https://muted-partridge.info", + comments: "provided jaywalk kissingly worriedly hunt retool space informal", + shortLink: "https://flustered-pomelo.org/", + qrCode: "https://lean-minor.org/", utmSource: "", utmMedium: "", utmCampaign: "", @@ -71,8 +71,8 @@ let value: SaleCreatedEventData = { programId: "", }, sale: { - amount: 4356.32, - currency: "Brazilian Real", + amount: 2471.45, + currency: "Yemeni Rial", paymentProcessor: "", invoiceId: "", }, diff --git a/docs/models/components/salecreatedeventdatalink.md b/docs/models/components/salecreatedeventdatalink.md new file mode 100644 index 00000000..0b1a4b4e --- /dev/null +++ b/docs/models/components/salecreatedeventdatalink.md @@ -0,0 +1,25 @@ +# SaleCreatedEventDataLink + +## Example Usage + +```typescript +import { SaleCreatedEventDataLink } from "dub/models/components"; + +let value: SaleCreatedEventDataLink = { + id: "", + domain: "gruesome-stir-fry.net", + key: "", + shortLink: "https://trustworthy-barge.info/", + programId: "", +}; +``` + +## Fields + +| Field | Type | Required | Description | +| ----------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------- | +| `id` | *string* | :heavy_check_mark: | The unique ID of the short link. | +| `domain` | *string* | :heavy_check_mark: | The domain of the short link. If not provided, the primary domain for the workspace will be used (or `dub.sh` if the workspace has no domains). | +| `key` | *string* | :heavy_check_mark: | The short link slug. If not provided, a random 7-character slug will be generated. | +| `shortLink` | *string* | :heavy_check_mark: | The full URL of the short link, including the https protocol (e.g. `https://dub.sh/try`). | +| `programId` | *string* | :heavy_check_mark: | The ID of the program the short link is associated with. | \ No newline at end of file diff --git a/docs/models/components/salecreatedeventlink.md b/docs/models/components/salecreatedeventlink.md index 6f363320..263777d5 100644 --- a/docs/models/components/salecreatedeventlink.md +++ b/docs/models/components/salecreatedeventlink.md @@ -7,17 +7,17 @@ import { SaleCreatedEventLink } from "dub/models/components"; let value: SaleCreatedEventLink = { id: "", - domain: "snappy-flat.biz", + domain: "impolite-eyeliner.info", key: "", - url: "https://giving-gallery.org/", + url: "https://impressionable-release.com", externalId: "", expiresAt: "", - expiredUrl: "https://shy-cleaner.name/", - password: "OYar6EyFY5S347f", + expiredUrl: "https://magnificent-mousse.net", + password: "r6EyFY5S347fPlV", title: "", - description: "creative yieldingly hidden probe emphasise signature", - image: "https://loremflickr.com/3531/2667?lock=7865492779134028", - video: "https://loremflickr.com/1685/927?lock=8661943020570040", + description: "slime our underneath bobble once store", + image: "https://loremflickr.com/1685/927?lock=8661943020570040", + video: "https://loremflickr.com/352/2119?lock=7820774530911577", ios: "", android: "", geo: {}, @@ -26,16 +26,16 @@ let value: SaleCreatedEventLink = { { id: "", name: "", - color: "red", + color: "yellow", }, ], webhookIds: [ "", ], comments: - "gadzooks necklace mmm indeed but exacerbate accessorise jealously enlightened clavicle depot hm spectacles", - shortLink: "https://ordinary-electronics.biz", - qrCode: "https://showy-going.name", + "idealistic maroon ameliorate lest save oh unearth where low daintily hm charm inasmuch musty fowl deduce", + shortLink: "https://prime-casket.name", + qrCode: "https://neglected-co-producer.com/", utmSource: "", utmMedium: "", utmCampaign: "", diff --git a/docs/models/components/salecreatedeventsale.md b/docs/models/components/salecreatedeventsale.md index 9bb38651..d2a09c49 100644 --- a/docs/models/components/salecreatedeventsale.md +++ b/docs/models/components/salecreatedeventsale.md @@ -6,8 +6,8 @@ import { SaleCreatedEventSale } from "dub/models/components"; let value: SaleCreatedEventSale = { - amount: 8880.33, - currency: "Balboa", + amount: 1131.00, + currency: "Venezuelan bolívar", paymentProcessor: "", invoiceId: "", }; diff --git a/docs/models/components/saleevent.md b/docs/models/components/saleevent.md index 7ce88a3a..06b3afa8 100644 --- a/docs/models/components/saleevent.md +++ b/docs/models/components/saleevent.md @@ -11,17 +11,18 @@ let value: SaleEvent = { eventName: "", link: { id: "", - domain: "unripe-caption.com", + domain: "exhausted-flat.biz", key: "", - url: "https://cheap-membership.info", + url: "https://sociable-leading.org", externalId: "", expiresAt: "", - expiredUrl: "https://unruly-runway.org", - password: "QH6zBq49u4lmy5g", + expiredUrl: "https://unripe-caption.com/", + password: "cVHfvjqQH6zBq49", title: "", - description: "woot birdbath celebrated founder", - image: "https://picsum.photos/seed/cMgTaF5YHQ/618/1251", - video: "https://picsum.videos/seed/tLbaqj4Q/2267/1907", + description: + "rival inasmuch uh-huh the unless scorpion ha scamper safe excitedly", + image: "https://picsum.photos/seed/3OCUKyPh/3156/577", + video: "https://picsum.videos/seed/0kv1yS/2188/1175", ios: "", android: "", geo: {}, @@ -30,16 +31,16 @@ let value: SaleEvent = { { id: "", name: "", - color: "pink", + color: "purple", }, ], webhookIds: [ "", ], comments: - "where term why pish lucky whenever happily likewise pace fall ick incidentally gullible", - shortLink: "https://indolent-license.com/", - qrCode: "https://peppery-decongestant.org/", + "eek oof if deserted meh failing up subsidy except fax hence optimistically militate rusty", + shortLink: "https://massive-effector.biz/", + qrCode: "https://gifted-mixture.net/", utmSource: "", utmMedium: "", utmCampaign: "", @@ -55,17 +56,17 @@ let value: SaleEvent = { }, click: { id: "", - url: "https://caring-blight.org/", - country: "Botswana", - city: "Port Deontechester", + url: "https://common-backburn.name/", + country: "Christmas Island", + city: "Fort Kaleland", region: "", continent: "North America", device: "Mobile", - browser: "Safari", - os: "Blackberry", - referer: "chubby-mathematics.net", - refererUrl: "https://altruistic-publicity.net", - ip: "bacf:eddf:1b66:76cf:521c:40eb:2cf9:028d", + browser: "Firefox", + os: "Windows", + referer: "clear-cut-goat.org", + refererUrl: "https://superb-advancement.info/", + ip: "1de3:ad40:0bee:fac2:daf6:42fb:3c93:3f6e", }, customer: { id: "", @@ -74,25 +75,25 @@ let value: SaleEvent = { createdAt: "", }, sale: { - amount: 148038, - paymentProcessor: "paddle", + amount: 75610, + paymentProcessor: "shopify", }, - saleAmount: 149.76, + saleAmount: 1296.19, invoiceId: "", paymentProcessor: "", clickId: "", linkId: "", - domain: "late-parade.com", + domain: "accomplished-marksman.com", key: "", - url: "https://wealthy-coast.net", - continent: "Europe", - country: "Christmas Island", - city: "North Juvenalshire", - device: "Mobile", - browser: "Safari", - os: "Chrome OS", - qr: 5818.89, - ip: "224.194.255.76", + url: "https://rundown-compromise.org", + continent: "North America", + country: "Fiji", + city: "Reynoldsborough", + device: "Desktop", + browser: "Firefox", + os: "Windows Phone", + qr: 9004.10, + ip: "224.7.169.106", }; ``` diff --git a/docs/models/components/saleeventclick.md b/docs/models/components/saleeventclick.md index df913422..738851db 100644 --- a/docs/models/components/saleeventclick.md +++ b/docs/models/components/saleeventclick.md @@ -7,17 +7,17 @@ import { SaleEventClick } from "dub/models/components"; let value: SaleEventClick = { id: "", - url: "https://red-sermon.biz/", - country: "India", - city: "Ivyfield", + url: "https://discrete-litter.net/", + country: "Kiribati", + city: "Delray Beach", region: "", - continent: "South America", + continent: "North America", device: "Mobile", - browser: "Chrome", - os: "WebOS", - referer: "biodegradable-depot.com", - refererUrl: "https://motionless-pillow.info/", - ip: "5adc:ad9c:98f2:3ca6:8ebd:409e:cc05:74ba", + browser: "Firefox", + os: "Chrome OS", + referer: "partial-horde.name", + refererUrl: "https://impolite-porter.com/", + ip: "217.197.72.96", }; ``` diff --git a/docs/models/components/saleeventcustomer.md b/docs/models/components/saleeventcustomer.md index 0c6ed23c..f25270b8 100644 --- a/docs/models/components/saleeventcustomer.md +++ b/docs/models/components/saleeventcustomer.md @@ -15,11 +15,13 @@ let value: SaleEventCustomer = { ## Fields -| Field | Type | Required | Description | -| ------------------------------------------------------- | ------------------------------------------------------- | ------------------------------------------------------- | ------------------------------------------------------- | -| `id` | *string* | :heavy_check_mark: | The unique identifier of the customer in Dub. | -| `externalId` | *string* | :heavy_check_mark: | Unique identifier for the customer in the client's app. | -| `name` | *string* | :heavy_check_mark: | Name of the customer. | -| `email` | *string* | :heavy_minus_sign: | Email of the customer. | -| `avatar` | *string* | :heavy_minus_sign: | Avatar URL of the customer. | -| `createdAt` | *string* | :heavy_check_mark: | The date the customer was created. | \ No newline at end of file +| Field | Type | Required | Description | +| ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------ | +| `id` | *string* | :heavy_check_mark: | The unique identifier of the customer in Dub. | +| `externalId` | *string* | :heavy_check_mark: | Unique identifier for the customer in the client's app. | +| `name` | *string* | :heavy_check_mark: | Name of the customer. | +| `email` | *string* | :heavy_minus_sign: | Email of the customer. | +| `avatar` | *string* | :heavy_minus_sign: | Avatar URL of the customer. | +| `country` | *string* | :heavy_minus_sign: | Country of the customer. | +| `createdAt` | *string* | :heavy_check_mark: | The date the customer was created. | +| `link` | [components.SaleEventCustomerLink](../../models/components/saleeventcustomerlink.md) | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/components/saleeventcustomerlink.md b/docs/models/components/saleeventcustomerlink.md new file mode 100644 index 00000000..6a7fe6af --- /dev/null +++ b/docs/models/components/saleeventcustomerlink.md @@ -0,0 +1,25 @@ +# SaleEventCustomerLink + +## Example Usage + +```typescript +import { SaleEventCustomerLink } from "dub/models/components"; + +let value: SaleEventCustomerLink = { + id: "", + domain: "variable-skyline.name", + key: "", + shortLink: "https://assured-hose.net/", + programId: "", +}; +``` + +## Fields + +| Field | Type | Required | Description | +| ----------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------- | +| `id` | *string* | :heavy_check_mark: | The unique ID of the short link. | +| `domain` | *string* | :heavy_check_mark: | The domain of the short link. If not provided, the primary domain for the workspace will be used (or `dub.sh` if the workspace has no domains). | +| `key` | *string* | :heavy_check_mark: | The short link slug. If not provided, a random 7-character slug will be generated. | +| `shortLink` | *string* | :heavy_check_mark: | The full URL of the short link, including the https protocol (e.g. `https://dub.sh/try`). | +| `programId` | *string* | :heavy_check_mark: | The ID of the program the short link is associated with. | \ No newline at end of file diff --git a/docs/models/components/saleeventlink.md b/docs/models/components/saleeventlink.md index 0f01997b..e238658f 100644 --- a/docs/models/components/saleeventlink.md +++ b/docs/models/components/saleeventlink.md @@ -7,18 +7,18 @@ import { SaleEventLink } from "dub/models/components"; let value: SaleEventLink = { id: "", - domain: "trusty-hydrocarbon.name", + domain: "bad-elver.com", key: "", - url: "https://punctual-flu.com", + url: "https://raw-viability.name", externalId: "", expiresAt: "", - expiredUrl: "https://deadly-massage.biz/", - password: "uiC4OwvT4943b9h", + expiredUrl: "https://hospitable-forager.info", + password: "_Cv36Kp6OylUX3G", title: "", description: - "once coolly gee punctually lavish wherever needily wetly govern cleverly", - image: "https://loremflickr.com/170/911?lock=7538938994453623", - video: "https://picsum.videos/seed/NyYA2cpBL/888/1976", + "pull optimistically monthly searchingly forgather wherever ascribe", + image: "https://loremflickr.com/2058/2187?lock=617865358872778", + video: "https://loremflickr.com/916/1432?lock=5322594761832499", ios: "", android: "", geo: {}, @@ -27,16 +27,16 @@ let value: SaleEventLink = { { id: "", name: "", - color: "green", + color: "pink", }, ], webhookIds: [ "", ], comments: - "shy bug testing list zealous vastly fledgling facilitate runway oval enormously vastly capsize supposing immediately terrible", - shortLink: "https://funny-suspension.com", - qrCode: "https://firsthand-individual.name/", + "runway oval enormously vastly capsize supposing immediately terrible joint nervously", + shortLink: "https://steep-version.net/", + qrCode: "https://straight-basket.biz/", utmSource: "", utmMedium: "", utmCampaign: "", diff --git a/docs/models/components/users.md b/docs/models/components/users.md index 869b3434..45a98fa3 100644 --- a/docs/models/components/users.md +++ b/docs/models/components/users.md @@ -6,7 +6,7 @@ import { Users } from "dub/models/components"; let value: Users = { - role: "member", + role: "owner", }; ``` diff --git a/docs/models/components/webhookevent.md b/docs/models/components/webhookevent.md index d77e8a4d..4799ea61 100644 --- a/docs/models/components/webhookevent.md +++ b/docs/models/components/webhookevent.md @@ -14,17 +14,18 @@ const value: components.LinkWebhookEvent = { createdAt: "", data: { id: "", - domain: "sentimental-precedent.biz", + domain: "appropriate-airman.biz", key: "", - url: "https://selfish-epic.net", + url: "https://severe-intent.org/", externalId: "", expiresAt: "", - expiredUrl: "https://grounded-ghost.info", - password: "v1t_HleNPnNR8ZW", + expiredUrl: "https://delicious-flame.name/", + password: "rBoEWkmjTFZGe7z", title: "", - description: "oh conservation throughout shoulder", - image: "https://picsum.photos/seed/B3pIeWG/3077/2148", - video: "https://loremflickr.com/1151/3076?lock=8779987451976765", + description: + "dispense aha coincide oh correctly sedately pfft notwithstanding", + image: "https://picsum.photos/seed/Xpm2bebKx/2182/3898", + video: "https://loremflickr.com/2670/3282?lock=2935661867862455", ios: "", android: "", geo: {}, @@ -33,16 +34,16 @@ const value: components.LinkWebhookEvent = { { id: "", name: "", - color: "red", + color: "purple", }, ], webhookIds: [ "", ], comments: - "amid jubilantly dark machine entice ah excepting inexperienced mothball oh helpful shakily nor per beside sweet majority wonderfully bah", - shortLink: "https://classic-mainstream.name", - qrCode: "https://outlying-vicinity.org", + "onto closely arcade offend poorly square boring engage whether override ambitious", + shortLink: "https://carefree-retention.info/", + qrCode: "https://personal-goodwill.name", utmSource: "", utmMedium: "", utmCampaign: "", @@ -69,32 +70,31 @@ const value: components.LinkClickedEvent = { data: { click: { id: "", - url: "https://measly-insolence.org", - country: "Anguilla", - city: "North Nikkiborough", + url: "https://wasteful-minister.name", + country: "Bahamas", + city: "Maple Grove", region: "", - continent: "Europe", - device: "Mobile", + continent: "North America", + device: "Desktop", browser: "Firefox", - os: "Chrome OS", - referer: "punctual-tusk.name", - refererUrl: "https://bitter-valentine.name", - ip: "1955:bd90:ff40:beec:67da:2562:aee1:067b", + os: "Linux", + referer: "fearless-scratch.name", + refererUrl: "https://adolescent-viability.org/", + ip: "10.135.243.233", }, link: { id: "", - domain: "wide-eyed-government.net", + domain: "outlandish-event.biz", key: "", - url: "https://silver-ownership.com", + url: "https://mad-ceramic.biz", externalId: "", expiresAt: "", - expiredUrl: "https://unwilling-courtroom.org/", - password: "cCSTdRjG9Wv1XLK", + expiredUrl: "https://cluttered-information.org/", + password: "CjEbgw4qcCSTdRj", title: "", - description: - "on incidentally nasalise while broken puppet psst word huzzah", - image: "https://picsum.photos/seed/8gq04etfSk/2502/2491", - video: "https://loremflickr.com/3698/3899?lock=2045794510305791", + description: "deficient long unselfish meh strange vaguely", + image: "https://picsum.photos/seed/5YfIvtfI/2014/2483", + video: "https://picsum.videos/seed/qhvShvek/452/3961", ios: "", android: "", geo: {}, @@ -103,16 +103,16 @@ const value: components.LinkClickedEvent = { { id: "", name: "", - color: "green", + color: "yellow", }, ], webhookIds: [ "", ], comments: - "founder yahoo coaxingly gah finally painfully politely boohoo delirious oh along solemnly suitcase smoothly affect louse abaft", - shortLink: "https://merry-seagull.info", - qrCode: "https://sick-technologist.info", + "huzzah knowledgeably inasmuch drive frankly unblinking furthermore sightseeing drat than sailor eventually phew violently quaff plus extent except instead aboard", + shortLink: "https://firm-bracelet.info", + qrCode: "https://agile-meadow.name", utmSource: "", utmMedium: "", utmCampaign: "", @@ -147,31 +147,31 @@ const value: components.LeadCreatedEvent = { }, click: { id: "", - url: "https://rowdy-approach.net", - country: "Guinea", - city: "Kozeycester", + url: "https://insignificant-marksman.net", + country: "Tokelau", + city: "New Maude", region: "", - continent: "North America", - device: "Desktop", + continent: "Africa", + device: "Mobile", browser: "Firefox", - os: "BeOS", - referer: "esteemed-reward.name", - refererUrl: "https://faraway-clamp.biz", - ip: "193.187.171.55", + os: "Blackberry", + referer: "limping-premium.net", + refererUrl: "https://quixotic-step-mother.biz/", + ip: "df53:65aa:e4cf:beb6:664d:ca8e:4c14:decd", }, link: { id: "", - domain: "total-vanadyl.name", + domain: "yellowish-role.info", key: "", - url: "https://massive-ectoderm.biz", + url: "https://cloudy-plugin.name", externalId: "", expiresAt: "", - expiredUrl: "https://different-tennis.org/", - password: "LCz6U3Z_XsiMpaR", + expiredUrl: "https://windy-flame.name/", + password: "tQnBtrBhSMcr8PI", title: "", - description: "throughout wrathful hastily investigate", - image: "https://loremflickr.com/3905/3777?lock=7949627724845943", - video: "https://loremflickr.com/321/2031?lock=3295663458974559", + description: "after plus lest generally save", + image: "https://picsum.photos/seed/vsXNykQs5s/370/2742", + video: "https://loremflickr.com/3488/1793?lock=5507770153865479", ios: "", android: "", geo: {}, @@ -180,16 +180,16 @@ const value: components.LeadCreatedEvent = { { id: "", name: "", - color: "pink", + color: "brown", }, ], webhookIds: [ "", ], comments: - "immediately phooey off metabolise impact worth shameful mount gradient oof even", - shortLink: "https://qualified-label.name", - qrCode: "https://pleasing-help.biz/", + "that condense playfully out viciously dally kaleidoscopic round doting when co-producer over dearly nor concentration nor truly worth", + shortLink: "https://coarse-independence.info/", + qrCode: "https://concerned-bookend.com", utmSource: "", utmMedium: "", utmCampaign: "", @@ -224,32 +224,31 @@ const value: components.SaleCreatedEvent = { }, click: { id: "", - url: "https://hopeful-schnitzel.info", - country: "Liberia", - city: "Kingworth", + url: "https://knotty-cinder.name", + country: "Malawi", + city: "New Eusebioburgh", region: "", - continent: "North America", - device: "Mobile", - browser: "Safari", - os: "iOS", - referer: "ornery-popularity.net", - refererUrl: "https://formal-elver.org", - ip: "4ca7:9caa:097d:b13e:acfa:2fdc:ce21:35dd", + continent: "Australia", + device: "Desktop", + browser: "Chrome", + os: "BeOS", + referer: "crushing-e-mail.info", + refererUrl: "https://dutiful-safe.biz/", + ip: "138.32.91.225", }, link: { id: "", - domain: "entire-jump.info", + domain: "hollow-outset.name", key: "", - url: "https://stormy-instructor.net/", + url: "https://pushy-stool.com/", externalId: "", expiresAt: "", - expiredUrl: "https://multicolored-smoke.biz/", - password: "MZ2hzMJ_p40v2LJ", + expiredUrl: "https://rotating-substitution.com", + password: "bfrLJ2sCvcFUnP7", title: "", - description: - "supposing however for suckle along although boohoo consequently aha where", - image: "https://loremflickr.com/1311/2806?lock=8683400969558279", - video: "https://loremflickr.com/3083/1426?lock=5922412711647966", + description: "hard-to-find before astride oof throughout postbox hence", + image: "https://picsum.photos/seed/4zoDg/1327/1372", + video: "https://loremflickr.com/3638/3044?lock=7060792830789141", ios: "", android: "", geo: {}, @@ -258,15 +257,16 @@ const value: components.SaleCreatedEvent = { { id: "", name: "", - color: "yellow", + color: "brown", }, ], webhookIds: [ "", ], - comments: "hmph reckon drat fuzzy culture any", - shortLink: "https://ordinary-grouper.name/", - qrCode: "https://unused-rim.com/", + comments: + "pike highlight meaningfully airman toothpick hydrocarbon soliloquy yowza whose brr above tenderly igloo past generously ha tremendously likewise vanadyl broadly", + shortLink: "https://unsung-jury.net", + qrCode: "https://elderly-chow.name/", utmSource: "", utmMedium: "", utmCampaign: "", @@ -281,8 +281,8 @@ const value: components.SaleCreatedEvent = { programId: "", }, sale: { - amount: 7839.05, - currency: "Rand", + amount: 1975.40, + currency: "Azerbaijanian Manat", paymentProcessor: "", invoiceId: "", }, diff --git a/docs/models/components/workspaceschema.md b/docs/models/components/workspaceschema.md index f8c3d659..0873a796 100644 --- a/docs/models/components/workspaceschema.md +++ b/docs/models/components/workspaceschema.md @@ -10,30 +10,30 @@ let value: WorkspaceSchema = { name: "", slug: "", inviteCode: "", - plan: "business max", + plan: "business extra", stripeId: "", - billingCycleStart: 1663.25, + billingCycleStart: 5017.73, paymentFailedAt: "", stripeConnectId: "", payoutMethodId: "", - usage: 5526.86, - usageLimit: 4137.68, - linksUsage: 1514.86, - linksLimit: 1620.73, - salesUsage: 9634.70, - salesLimit: 3049.64, - domainsLimit: 9414.39, - tagsLimit: 756.11, - usersLimit: 4608.03, - aiUsage: 1296.19, - aiLimit: 47.87, + usage: 8115.18, + usageLimit: 4760.84, + linksUsage: 5231.56, + linksLimit: 2505.21, + salesUsage: 6050.43, + salesLimit: 3029.05, + domainsLimit: 5772.84, + tagsLimit: 1696.78, + usersLimit: 1594.69, + aiUsage: 4170.30, + aiLimit: 4268.20, conversionEnabled: false, dotLinkClaimed: false, partnersEnabled: false, createdAt: "", users: [ { - role: "member", + role: "owner", }, ], domains: [ diff --git a/docs/models/operations/bulkdeletelinksresponsebody.md b/docs/models/operations/bulkdeletelinksresponsebody.md index 0404e1fe..7295c634 100644 --- a/docs/models/operations/bulkdeletelinksresponsebody.md +++ b/docs/models/operations/bulkdeletelinksresponsebody.md @@ -8,7 +8,7 @@ The deleted links count. import { BulkDeleteLinksResponseBody } from "dub/models/operations"; let value: BulkDeleteLinksResponseBody = { - deletedCount: 8371.54, + deletedCount: 7436.22, }; ``` diff --git a/docs/models/operations/createcustomerlink.md b/docs/models/operations/createcustomerlink.md new file mode 100644 index 00000000..bc68004b --- /dev/null +++ b/docs/models/operations/createcustomerlink.md @@ -0,0 +1,25 @@ +# CreateCustomerLink + +## Example Usage + +```typescript +import { CreateCustomerLink } from "dub/models/operations"; + +let value: CreateCustomerLink = { + id: "", + domain: "crazy-octave.info", + key: "", + shortLink: "https://blank-switchboard.info", + programId: "", +}; +``` + +## Fields + +| Field | Type | Required | Description | +| ----------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------- | +| `id` | *string* | :heavy_check_mark: | The unique ID of the short link. | +| `domain` | *string* | :heavy_check_mark: | The domain of the short link. If not provided, the primary domain for the workspace will be used (or `dub.sh` if the workspace has no domains). | +| `key` | *string* | :heavy_check_mark: | The short link slug. If not provided, a random 7-character slug will be generated. | +| `shortLink` | *string* | :heavy_check_mark: | The full URL of the short link, including the https protocol (e.g. `https://dub.sh/try`). | +| `programId` | *string* | :heavy_check_mark: | The ID of the program the short link is associated with. | \ No newline at end of file diff --git a/docs/models/operations/createcustomerresponsebody.md b/docs/models/operations/createcustomerresponsebody.md index 27c0b42b..bcaaf9ad 100644 --- a/docs/models/operations/createcustomerresponsebody.md +++ b/docs/models/operations/createcustomerresponsebody.md @@ -17,11 +17,13 @@ let value: CreateCustomerResponseBody = { ## Fields -| Field | Type | Required | Description | -| ------------------------------------------------------- | ------------------------------------------------------- | ------------------------------------------------------- | ------------------------------------------------------- | -| `id` | *string* | :heavy_check_mark: | The unique identifier of the customer in Dub. | -| `externalId` | *string* | :heavy_check_mark: | Unique identifier for the customer in the client's app. | -| `name` | *string* | :heavy_check_mark: | Name of the customer. | -| `email` | *string* | :heavy_minus_sign: | Email of the customer. | -| `avatar` | *string* | :heavy_minus_sign: | Avatar URL of the customer. | -| `createdAt` | *string* | :heavy_check_mark: | The date the customer was created. | \ No newline at end of file +| Field | Type | Required | Description | +| ------------------------------------------------------------------------------ | ------------------------------------------------------------------------------ | ------------------------------------------------------------------------------ | ------------------------------------------------------------------------------ | +| `id` | *string* | :heavy_check_mark: | The unique identifier of the customer in Dub. | +| `externalId` | *string* | :heavy_check_mark: | Unique identifier for the customer in the client's app. | +| `name` | *string* | :heavy_check_mark: | Name of the customer. | +| `email` | *string* | :heavy_minus_sign: | Email of the customer. | +| `avatar` | *string* | :heavy_minus_sign: | Avatar URL of the customer. | +| `country` | *string* | :heavy_minus_sign: | Country of the customer. | +| `createdAt` | *string* | :heavy_check_mark: | The date the customer was created. | +| `link` | [operations.CreateCustomerLink](../../models/operations/createcustomerlink.md) | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/operations/customer.md b/docs/models/operations/customer.md index b8833ad9..d02ea7d0 100644 --- a/docs/models/operations/customer.md +++ b/docs/models/operations/customer.md @@ -7,8 +7,8 @@ import { Customer } from "dub/models/operations"; let value: Customer = { name: "", - email: "Efrain31@hotmail.com", - avatar: "https://picsum.photos/seed/kuJj6/1612/280", + email: "Elsa40@gmail.com", + avatar: "https://loremflickr.com/2910/2530?lock=2587263839838918", externalId: "", }; ``` diff --git a/docs/models/operations/event.md b/docs/models/operations/event.md index efe6cdcb..21852fc9 100644 --- a/docs/models/operations/event.md +++ b/docs/models/operations/event.md @@ -7,7 +7,7 @@ The type of event to retrieve analytics for. Defaults to `clicks`. ```typescript import { Event } from "dub/models/operations"; -let value: Event = "sales"; +let value: Event = "composite"; ``` ## Values diff --git a/docs/models/operations/getcustomerlink.md b/docs/models/operations/getcustomerlink.md new file mode 100644 index 00000000..d36d4827 --- /dev/null +++ b/docs/models/operations/getcustomerlink.md @@ -0,0 +1,25 @@ +# GetCustomerLink + +## Example Usage + +```typescript +import { GetCustomerLink } from "dub/models/operations"; + +let value: GetCustomerLink = { + id: "", + domain: "dramatic-knickers.org", + key: "", + shortLink: "https://grizzled-event.name", + programId: "", +}; +``` + +## Fields + +| Field | Type | Required | Description | +| ----------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------- | +| `id` | *string* | :heavy_check_mark: | The unique ID of the short link. | +| `domain` | *string* | :heavy_check_mark: | The domain of the short link. If not provided, the primary domain for the workspace will be used (or `dub.sh` if the workspace has no domains). | +| `key` | *string* | :heavy_check_mark: | The short link slug. If not provided, a random 7-character slug will be generated. | +| `shortLink` | *string* | :heavy_check_mark: | The full URL of the short link, including the https protocol (e.g. `https://dub.sh/try`). | +| `programId` | *string* | :heavy_check_mark: | The ID of the program the short link is associated with. | \ No newline at end of file diff --git a/docs/models/operations/getcustomerresponsebody.md b/docs/models/operations/getcustomerresponsebody.md index 448d36d6..3800ab4d 100644 --- a/docs/models/operations/getcustomerresponsebody.md +++ b/docs/models/operations/getcustomerresponsebody.md @@ -17,11 +17,13 @@ let value: GetCustomerResponseBody = { ## Fields -| Field | Type | Required | Description | -| ------------------------------------------------------- | ------------------------------------------------------- | ------------------------------------------------------- | ------------------------------------------------------- | -| `id` | *string* | :heavy_check_mark: | The unique identifier of the customer in Dub. | -| `externalId` | *string* | :heavy_check_mark: | Unique identifier for the customer in the client's app. | -| `name` | *string* | :heavy_check_mark: | Name of the customer. | -| `email` | *string* | :heavy_minus_sign: | Email of the customer. | -| `avatar` | *string* | :heavy_minus_sign: | Avatar URL of the customer. | -| `createdAt` | *string* | :heavy_check_mark: | The date the customer was created. | \ No newline at end of file +| Field | Type | Required | Description | +| ------------------------------------------------------------------------ | ------------------------------------------------------------------------ | ------------------------------------------------------------------------ | ------------------------------------------------------------------------ | +| `id` | *string* | :heavy_check_mark: | The unique identifier of the customer in Dub. | +| `externalId` | *string* | :heavy_check_mark: | Unique identifier for the customer in the client's app. | +| `name` | *string* | :heavy_check_mark: | Name of the customer. | +| `email` | *string* | :heavy_minus_sign: | Email of the customer. | +| `avatar` | *string* | :heavy_minus_sign: | Avatar URL of the customer. | +| `country` | *string* | :heavy_minus_sign: | Country of the customer. | +| `createdAt` | *string* | :heavy_check_mark: | The date the customer was created. | +| `link` | [operations.GetCustomerLink](../../models/operations/getcustomerlink.md) | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/operations/getlinksresponse.md b/docs/models/operations/getlinksresponse.md index 4b79816d..d550ca51 100644 --- a/docs/models/operations/getlinksresponse.md +++ b/docs/models/operations/getlinksresponse.md @@ -9,17 +9,18 @@ let value: GetLinksResponse = { result: [ { id: "", - domain: "insidious-hamburger.biz", + domain: "meager-dividend.com", key: "", - url: "https://spiteful-printer.com", + url: "https://disloyal-merit.biz", externalId: "", expiresAt: "", - expiredUrl: "https://grim-alert.name", - password: "gFrBTxfjvoNo9sF", + expiredUrl: "https://quarterly-quinoa.biz", + password: "rukOSaWshlXx_1Z", title: "", - description: "twist er until known unlike over brook council absent", - image: "https://picsum.photos/seed/MuDBx/3429/3877", - video: "https://picsum.videos/seed/RKXNA/2700/2465", + description: + "victorious plus wilderness all the hence instead overburden", + image: "https://loremflickr.com/3201/3572?lock=5855549025985730", + video: "https://picsum.videos/seed/KaXRi7NY7E/2370/2404", ios: "", android: "", geo: {}, @@ -28,16 +29,15 @@ let value: GetLinksResponse = { { id: "", name: "", - color: "brown", + color: "red", }, ], webhookIds: [ "", ], - comments: - "until usually even by wholly unnecessarily amid far-off beloved decent whoa lively publicity briskly oof", - shortLink: "https://edible-bowler.com", - qrCode: "https://inferior-diagram.org/", + comments: "flawed reasonable while carefully ouch", + shortLink: "https://unfortunate-underneath.org/", + qrCode: "https://trained-foodstuffs.com/", utmSource: "", utmMedium: "", utmCampaign: "", diff --git a/docs/models/operations/getqrcoderequest.md b/docs/models/operations/getqrcoderequest.md index 7d23b741..c11962ab 100644 --- a/docs/models/operations/getqrcoderequest.md +++ b/docs/models/operations/getqrcoderequest.md @@ -6,7 +6,7 @@ import { GetQRCodeRequest } from "dub/models/operations"; let value: GetQRCodeRequest = { - url: "https://variable-inspection.biz/", + url: "https://quarrelsome-kinase.com/", }; ``` diff --git a/docs/models/operations/interval.md b/docs/models/operations/interval.md index 267bf011..50be0057 100644 --- a/docs/models/operations/interval.md +++ b/docs/models/operations/interval.md @@ -7,7 +7,7 @@ The interval to retrieve analytics for. If undefined, defaults to 24h. ```typescript import { Interval } from "dub/models/operations"; -let value: Interval = "all_unfiltered"; +let value: Interval = "90d"; ``` ## Values diff --git a/docs/models/operations/level.md b/docs/models/operations/level.md index edb0a0ce..91363c97 100644 --- a/docs/models/operations/level.md +++ b/docs/models/operations/level.md @@ -7,7 +7,7 @@ The level of error correction to use for the QR code. Defaults to `L` if not pro ```typescript import { Level } from "dub/models/operations"; -let value: Level = "Q"; +let value: Level = "L"; ``` ## Values diff --git a/docs/models/operations/link.md b/docs/models/operations/link.md new file mode 100644 index 00000000..6ca5aef7 --- /dev/null +++ b/docs/models/operations/link.md @@ -0,0 +1,25 @@ +# Link + +## Example Usage + +```typescript +import { Link } from "dub/models/operations"; + +let value: Link = { + id: "", + domain: "worthy-mountain.name", + key: "", + shortLink: "https://golden-costume.name/", + programId: "", +}; +``` + +## Fields + +| Field | Type | Required | Description | +| ----------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------- | +| `id` | *string* | :heavy_check_mark: | The unique ID of the short link. | +| `domain` | *string* | :heavy_check_mark: | The domain of the short link. If not provided, the primary domain for the workspace will be used (or `dub.sh` if the workspace has no domains). | +| `key` | *string* | :heavy_check_mark: | The short link slug. If not provided, a random 7-character slug will be generated. | +| `shortLink` | *string* | :heavy_check_mark: | The full URL of the short link, including the https protocol (e.g. `https://dub.sh/try`). | +| `programId` | *string* | :heavy_check_mark: | The ID of the program the short link is associated with. | \ No newline at end of file diff --git a/docs/models/operations/listeventsresponsebody.md b/docs/models/operations/listeventsresponsebody.md index d9874524..96dcc2a9 100644 --- a/docs/models/operations/listeventsresponsebody.md +++ b/docs/models/operations/listeventsresponsebody.md @@ -13,32 +13,31 @@ const value: components.ClickEvent[] = [ event: "click", click: { id: "", - url: "https://beloved-elevator.org", - country: "San Marino", - city: "Jacobston", + url: "https://amused-overcoat.info/", + country: "American Samoa", + city: "Columbia", region: "", continent: "Antarctica", - device: "Desktop", + device: "Mobile", browser: "Firefox", - os: "Chrome OS", - referer: "amused-overcoat.info", - refererUrl: "https://warped-couch.biz/", - ip: "7d09:044f:6c9c:e020:14ba:58c1:c2f9:e3f1", + os: "Windows Phone", + referer: "accurate-hose.com", + refererUrl: "https://dim-vision.biz/", + ip: "9ce0:2014:ba58:c1c2:f9e3:f11c:b55a:edcd", }, link: { id: "", - domain: "baggy-smog.net", + domain: "concerned-mixture.org", key: "", - url: "https://expensive-integer.org/", + url: "https://juicy-rosemary.org/", externalId: "", expiresAt: "", - expiredUrl: "https://talkative-suitcase.com", - password: "WKiGhYtTZnqNZbQ", + expiredUrl: "https://impressionable-resolve.name/", + password: "tTZnqNZbQ0ErQnQ", title: "", - description: - "rewarding brr even hmph joyfully and whether cafe filter abscond", - image: "https://loremflickr.com/1533/1627?lock=7227413113546858", - video: "https://loremflickr.com/383/460?lock=4627292823404907", + description: "brr even hmph joyfully and whether cafe filter", + image: "https://picsum.photos/seed/l90npmN5/2796/1474", + video: "https://picsum.videos/seed/Ug7viZ2bK/460/934", ios: "", android: "", geo: {}, @@ -47,16 +46,16 @@ const value: components.ClickEvent[] = [ { id: "", name: "", - color: "pink", + color: "green", }, ], webhookIds: [ "", ], comments: - "boohoo responsible up aside beard cruelly tectonics for off bah revere a aha ugh uselessly yowza whoever shallow fit", - shortLink: "https://peppery-hovel.com", - qrCode: "https://rubbery-jazz.info/", + "punctually anneal although amongst supposing elastic inasmuch ew detective divert despite drab eek", + shortLink: "https://wasteful-deployment.org", + qrCode: "https://amused-cafe.name/", utmSource: "", utmMedium: "", utmCampaign: "", @@ -72,17 +71,17 @@ const value: components.ClickEvent[] = [ }, clickId: "", linkId: "", - domain: "hospitable-horde.net", + domain: "muffled-coil.com", key: "", - url: "https://blank-climb.com", + url: "https://whimsical-consistency.biz", continent: "Africa", - country: "San Marino", - city: "Independence", - device: "Mobile", + country: "Montenegro", + city: "Deerfield Beach", + device: "Desktop", browser: "Safari", - os: "BeOS", - qr: 3671.84, - ip: "a7d0:cb1c:68ab:dc76:a579:cecb:f7ae:73ae", + os: "Blackberry", + qr: 5282.87, + ip: "aaa6:4e17:fd92:3fa7:89fd:1310:bc9f:cc8e", }, ]; ``` @@ -97,31 +96,31 @@ const value: components.LeadEvent[] = [ eventName: "", click: { id: "", - url: "https://clumsy-event.org/", - country: "Oman", - city: "New Magnolia", + url: "https://handy-tabletop.com", + country: "Mayotte", + city: "Arnaldohaven", region: "", - continent: "Australia", - device: "Mobile", - browser: "Chrome", - os: "Linux", - referer: "wide-king.com", - refererUrl: "https://able-mobility.org/", - ip: "d75b:d0c9:dc94:8318:d5ef:ff0b:e0de:4cd4", + continent: "Antarctica", + device: "Desktop", + browser: "Firefox", + os: "WebOS", + referer: "parallel-mechanic.info", + refererUrl: "https://livid-disconnection.info/", + ip: "215.238.212.134", }, link: { id: "", - domain: "wide-eyed-cutover.net", + domain: "scented-fisherman.info", key: "", - url: "https://separate-brace.org/", + url: "https://happy-community.info", externalId: "", expiresAt: "", - expiredUrl: "https://electric-markup.info/", - password: "K7jv7jF0rktpRNS", + expiredUrl: "https://colorless-cash.biz", + password: "wa6Z_Ri3PXYZ7Qv", title: "", - description: "vastly rebuke giggle yahoo about finally vainly as", - image: "https://picsum.photos/seed/dN3ArK1n/3965/3450", - video: "https://loremflickr.com/1908/610?lock=8200853935349854", + description: "considering duh powerfully", + image: "https://picsum.photos/seed/dXdGtI6X/2706/785", + video: "https://picsum.videos/seed/r2eLTeL/818/882", ios: "", android: "", geo: {}, @@ -130,15 +129,15 @@ const value: components.LeadEvent[] = [ { id: "", name: "", - color: "blue", + color: "red", }, ], webhookIds: [ "", ], - comments: "so finally lest save sightseeing lawful lest if avaricious", - shortLink: "https://intelligent-cornet.org", - qrCode: "https://vengeful-lid.net", + comments: "fishery blah cooperative bah ah", + shortLink: "https://humiliating-desk.com/", + qrCode: "https://hairy-reasoning.com/", utmSource: "", utmMedium: "", utmCampaign: "", @@ -160,17 +159,17 @@ const value: components.LeadEvent[] = [ }, clickId: "", linkId: "", - domain: "miserable-maestro.org", + domain: "hungry-flint.name", key: "", - url: "https://obvious-grandson.com", + url: "https://corny-skean.name", continent: "Africa", - country: "Fiji", - city: "Dickiville", - device: "Desktop", - browser: "Safari", + country: "Saint Pierre and Miquelon", + city: "Pollyview", + device: "Mobile", + browser: "Chrome", os: "Linux", - qr: 2008.50, - ip: "161.150.236.174", + qr: 3402.62, + ip: "fec9:e24f:53d1:fcdd:4b1c:9a08:a39e:a5b1", }, ]; ``` @@ -185,17 +184,17 @@ const value: components.SaleEvent[] = [ eventName: "", link: { id: "", - domain: "noxious-prohibition.name", + domain: "free-scenario.name", key: "", - url: "https://old-fashioned-shore.org", + url: "https://official-daddy.org/", externalId: "", expiresAt: "", - expiredUrl: "https://harmful-dwell.name", - password: "g6_Rqo5ggEiSrfM", + expiredUrl: "https://colossal-goodwill.info", + password: "2cpG1vmTjgW1nOi", title: "", - description: "oof sentimental furthermore aha adolescent fooey now", - image: "https://picsum.photos/seed/54YoAq97/3416/1817", - video: "https://picsum.videos/seed/2koKJd/851/2421", + description: "psst ew strange why well-documented poppy", + image: "https://loremflickr.com/767/526?lock=7622336785222754", + video: "https://loremflickr.com/965/804?lock=5669907635884783", ios: "", android: "", geo: {}, @@ -204,16 +203,16 @@ const value: components.SaleEvent[] = [ { id: "", name: "", - color: "yellow", + color: "purple", }, ], webhookIds: [ "", ], comments: - "whereas barring frizzy entire minor since tomatillo that ha easily birdbath inasmuch before despite defendant", - shortLink: "https://arid-anticodon.biz/", - qrCode: "https://rough-reward.info/", + "strident alienated gosh alongside chilly yahoo yippee carefully shadowy lobster including heroine political even between pulverize tighten frankly supposing", + shortLink: "https://rundown-hospitalization.name", + qrCode: "https://entire-dead.info", utmSource: "", utmMedium: "", utmCampaign: "", @@ -229,17 +228,17 @@ const value: components.SaleEvent[] = [ }, click: { id: "", - url: "https://shabby-outset.com", - country: "Ethiopia", - city: "Raquelview", + url: "https://alienated-mom.info/", + country: "Mexico", + city: "Fremont", region: "", - continent: "South America", - device: "Mobile", + continent: "Africa", + device: "Desktop", browser: "Chrome", - os: "Windows Phone", - referer: "hot-thunderbolt.com", - refererUrl: "https://bustling-shark.biz/", - ip: "ccf3:3d0b:88c7:64fa:d5f3:d9a4:dfce:674b", + os: "BeOS", + referer: "neighboring-yeast.biz", + refererUrl: "https://frizzy-wriggler.net/", + ip: "d6e5:86e9:ff2e:bf7e:bcb7:4b5b:09b1:f526", }, customer: { id: "", @@ -248,25 +247,25 @@ const value: components.SaleEvent[] = [ createdAt: "", }, sale: { - amount: 147974, + amount: 19336, paymentProcessor: "shopify", }, - saleAmount: 4653.10, + saleAmount: 3329.09, invoiceId: "", paymentProcessor: "", clickId: "", linkId: "", - domain: "possible-begonia.org", + domain: "yellowish-brace.org", key: "", - url: "https://dramatic-knickers.org/", + url: "https://clear-cut-stool.com/", continent: "Europe", - country: "Ghana", - city: "Lake Ashton", + country: "Djibouti", + city: "Kiarrashire", device: "Desktop", browser: "Firefox", - os: "WebOS", - qr: 3255.17, - ip: "b04e:a07d:f438:ce75:0425:7183:c8eb:18f0", + os: "Linux", + qr: 3436.22, + ip: "140.143.159.58", }, ]; ``` diff --git a/docs/models/operations/paymentprocessor.md b/docs/models/operations/paymentprocessor.md index e387ed2c..2a81ee97 100644 --- a/docs/models/operations/paymentprocessor.md +++ b/docs/models/operations/paymentprocessor.md @@ -7,7 +7,7 @@ The payment processor via which the sale was made. ```typescript import { PaymentProcessor } from "dub/models/operations"; -let value: PaymentProcessor = "shopify"; +let value: PaymentProcessor = "stripe"; ``` ## Values diff --git a/docs/models/operations/queryparamevent.md b/docs/models/operations/queryparamevent.md index d086d5ae..acb74537 100644 --- a/docs/models/operations/queryparamevent.md +++ b/docs/models/operations/queryparamevent.md @@ -7,7 +7,7 @@ The type of event to retrieve analytics for. Defaults to 'clicks'. ```typescript import { QueryParamEvent } from "dub/models/operations"; -let value: QueryParamEvent = "sales"; +let value: QueryParamEvent = "clicks"; ``` ## Values diff --git a/docs/models/operations/queryparamgroupby.md b/docs/models/operations/queryparamgroupby.md index 402f7a6e..b64a5811 100644 --- a/docs/models/operations/queryparamgroupby.md +++ b/docs/models/operations/queryparamgroupby.md @@ -7,7 +7,7 @@ The parameter to group the analytics data points by. Defaults to `count` if unde ```typescript import { QueryParamGroupBy } from "dub/models/operations"; -let value: QueryParamGroupBy = "browsers"; +let value: QueryParamGroupBy = "top_urls"; ``` ## Values diff --git a/docs/models/operations/queryparaminterval.md b/docs/models/operations/queryparaminterval.md index 2471f8e2..c5ee3d66 100644 --- a/docs/models/operations/queryparaminterval.md +++ b/docs/models/operations/queryparaminterval.md @@ -7,7 +7,7 @@ The interval to retrieve events for. Takes precedence over start and end. If und ```typescript import { QueryParamInterval } from "dub/models/operations"; -let value: QueryParamInterval = "ytd"; +let value: QueryParamInterval = "7d"; ``` ## Values diff --git a/docs/models/operations/queryparamtrigger.md b/docs/models/operations/queryparamtrigger.md index 746c89e8..ba634227 100644 --- a/docs/models/operations/queryparamtrigger.md +++ b/docs/models/operations/queryparamtrigger.md @@ -7,7 +7,7 @@ The trigger to retrieve analytics for. If undefined, return both QR and link cli ```typescript import { QueryParamTrigger } from "dub/models/operations"; -let value: QueryParamTrigger = "link"; +let value: QueryParamTrigger = "qr"; ``` ## Values diff --git a/docs/models/operations/responsebody.md b/docs/models/operations/responsebody.md index 3f66af13..a467ed8a 100644 --- a/docs/models/operations/responsebody.md +++ b/docs/models/operations/responsebody.md @@ -22,4 +22,6 @@ let value: ResponseBody = { | `name` | *string* | :heavy_check_mark: | Name of the customer. | | `email` | *string* | :heavy_minus_sign: | Email of the customer. | | `avatar` | *string* | :heavy_minus_sign: | Avatar URL of the customer. | -| `createdAt` | *string* | :heavy_check_mark: | The date the customer was created. | \ No newline at end of file +| `country` | *string* | :heavy_minus_sign: | Country of the customer. | +| `createdAt` | *string* | :heavy_check_mark: | The date the customer was created. | +| `link` | [operations.Link](../../models/operations/link.md) | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/operations/retrieveanalyticsresponsebody.md b/docs/models/operations/retrieveanalyticsresponsebody.md index 6c1dfe68..d5a3a2ec 100644 --- a/docs/models/operations/retrieveanalyticsresponsebody.md +++ b/docs/models/operations/retrieveanalyticsresponsebody.md @@ -26,7 +26,7 @@ const value: components.AnalyticsTimeseries[] = [ ```typescript const value: components.AnalyticsContinents[] = [ { - continent: "SA", + continent: "AF", }, ]; ``` @@ -36,7 +36,7 @@ const value: components.AnalyticsContinents[] = [ ```typescript const value: components.AnalyticsCountries[] = [ { - country: "ER", + country: "IL", }, ]; ``` @@ -46,8 +46,8 @@ const value: components.AnalyticsCountries[] = [ ```typescript const value: components.AnalyticsCities[] = [ { - city: "Glen Burnie", - country: "IO", + city: "Jerrodville", + country: "HM", }, ]; ``` @@ -67,7 +67,7 @@ const value: components.AnalyticsDevices[] = [ ```typescript const value: components.AnalyticsBrowsers[] = [ { - browser: "Safari", + browser: "Firefox", }, ]; ``` @@ -77,7 +77,7 @@ const value: components.AnalyticsBrowsers[] = [ ```typescript const value: components.AnalyticsOS[] = [ { - os: "Symbian", + os: "Chrome OS", }, ]; ``` @@ -97,7 +97,7 @@ const value: components.AnalyticsTriggers[] = [ ```typescript const value: components.AnalyticsReferers[] = [ { - referer: "failing-baseboard.info", + referer: "idealistic-bandwidth.biz", }, ]; ``` @@ -107,7 +107,7 @@ const value: components.AnalyticsReferers[] = [ ```typescript const value: components.AnalyticsRefererUrls[] = [ { - refererUrl: "https://male-coil.info", + refererUrl: "https://outlandish-interviewer.info/", }, ]; ``` @@ -119,10 +119,10 @@ const value: components.AnalyticsTopLinks[] = [ { link: "", id: "", - domain: "upset-in-joke.name", + domain: "stormy-populist.org", key: "", shortLink: "", - url: "https://idealistic-bandwidth.biz/", + url: "https://silky-bar.biz/", createdAt: "", }, ]; @@ -133,7 +133,7 @@ const value: components.AnalyticsTopLinks[] = [ ```typescript const value: components.AnalyticsTopUrls[] = [ { - url: "https://outlandish-interviewer.info/", + url: "https://soulful-petticoat.info", }, ]; ``` diff --git a/docs/models/operations/sale.md b/docs/models/operations/sale.md index 5e9a2579..41783461 100644 --- a/docs/models/operations/sale.md +++ b/docs/models/operations/sale.md @@ -6,8 +6,8 @@ import { Sale } from "dub/models/operations"; let value: Sale = { - amount: 5040.97, - currency: "Boliviano boliviano", + amount: 5720.46, + currency: "Hong Kong Dollar", paymentProcessor: "", invoiceId: "", metadata: { diff --git a/docs/models/operations/trackcustomerrequestbody.md b/docs/models/operations/trackcustomerrequestbody.md deleted file mode 100644 index 921d3c64..00000000 --- a/docs/models/operations/trackcustomerrequestbody.md +++ /dev/null @@ -1,20 +0,0 @@ -# TrackCustomerRequestBody - -## Example Usage - -```typescript -import { TrackCustomerRequestBody } from "dub/models/operations"; - -let value: TrackCustomerRequestBody = { - customerId: "", -}; -``` - -## Fields - -| Field | Type | Required | Description | -| ----------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------- | -| `customerId` | *string* | :heavy_check_mark: | This is the unique identifier for the customer in the client's app. This is used to track the customer's journey. | -| `customerName` | *string* | :heavy_minus_sign: | Name of the customer in the client's app. | -| `customerEmail` | *string* | :heavy_minus_sign: | Email of the customer in the client's app. | -| `customerAvatar` | *string* | :heavy_minus_sign: | Avatar of the customer in the client's app. | \ No newline at end of file diff --git a/docs/models/operations/trackcustomerresponsebody.md b/docs/models/operations/trackcustomerresponsebody.md deleted file mode 100644 index 497ee241..00000000 --- a/docs/models/operations/trackcustomerresponsebody.md +++ /dev/null @@ -1,25 +0,0 @@ -# TrackCustomerResponseBody - -A customer was tracked. - -## Example Usage - -```typescript -import { TrackCustomerResponseBody } from "dub/models/operations"; - -let value: TrackCustomerResponseBody = { - customerId: "", - customerName: "", - customerEmail: "", - customerAvatar: "", -}; -``` - -## Fields - -| Field | Type | Required | Description | -| ------------------ | ------------------ | ------------------ | ------------------ | -| `customerId` | *string* | :heavy_check_mark: | N/A | -| `customerName` | *string* | :heavy_check_mark: | N/A | -| `customerEmail` | *string* | :heavy_check_mark: | N/A | -| `customerAvatar` | *string* | :heavy_check_mark: | N/A | \ No newline at end of file diff --git a/docs/models/operations/trackleadresponsebody.md b/docs/models/operations/trackleadresponsebody.md index 7c1b00c4..3fc5fd77 100644 --- a/docs/models/operations/trackleadresponsebody.md +++ b/docs/models/operations/trackleadresponsebody.md @@ -13,8 +13,8 @@ let value: TrackLeadResponseBody = { }, customer: { name: "", - email: "Adelia.Breitenberg16@hotmail.com", - avatar: "https://loremflickr.com/3179/3244?lock=1013468629013638", + email: "Raquel_Wisoky@yahoo.com", + avatar: "https://loremflickr.com/1500/3648?lock=2061887836504205", externalId: "", }, }; diff --git a/docs/models/operations/tracksalecustomer.md b/docs/models/operations/tracksalecustomer.md index e43348f4..e9b5af56 100644 --- a/docs/models/operations/tracksalecustomer.md +++ b/docs/models/operations/tracksalecustomer.md @@ -8,8 +8,8 @@ import { TrackSaleCustomer } from "dub/models/operations"; let value: TrackSaleCustomer = { id: "", name: "", - email: "Nyah7@gmail.com", - avatar: "https://loremflickr.com/1911/2905?lock=4548025511027127", + email: "Kellie.Ziemann@hotmail.com", + avatar: "https://loremflickr.com/146/3269?lock=3593284539031351", externalId: "", }; ``` diff --git a/docs/models/operations/tracksalerequestbody.md b/docs/models/operations/tracksalerequestbody.md index fababe57..3d1fa81a 100644 --- a/docs/models/operations/tracksalerequestbody.md +++ b/docs/models/operations/tracksalerequestbody.md @@ -6,8 +6,8 @@ import { TrackSaleRequestBody } from "dub/models/operations"; let value: TrackSaleRequestBody = { - amount: 699707, - paymentProcessor: "shopify", + amount: 805620, + paymentProcessor: "stripe", }; ``` diff --git a/docs/models/operations/tracksaleresponsebody.md b/docs/models/operations/tracksaleresponsebody.md index 8f911547..cb648d0c 100644 --- a/docs/models/operations/tracksaleresponsebody.md +++ b/docs/models/operations/tracksaleresponsebody.md @@ -12,13 +12,13 @@ let value: TrackSaleResponseBody = { customer: { id: "", name: "", - email: "Silas31@yahoo.com", - avatar: "https://picsum.photos/seed/cqQJrXM/387/2310", + email: "Conor23@gmail.com", + avatar: "https://loremflickr.com/632/3513?lock=4286177311887332", externalId: "", }, sale: { - amount: 442.61, - currency: "Sudanese Pound", + amount: 2041.48, + currency: "Naira", paymentProcessor: "", invoiceId: "", metadata: { diff --git a/docs/models/operations/trigger.md b/docs/models/operations/trigger.md index aa26256c..89d33c51 100644 --- a/docs/models/operations/trigger.md +++ b/docs/models/operations/trigger.md @@ -7,7 +7,7 @@ The trigger to retrieve analytics for. If undefined, return both QR and link cli ```typescript import { Trigger } from "dub/models/operations"; -let value: Trigger = "link"; +let value: Trigger = "qr"; ``` ## Values diff --git a/docs/models/operations/updatecustomerlink.md b/docs/models/operations/updatecustomerlink.md new file mode 100644 index 00000000..cc3f88da --- /dev/null +++ b/docs/models/operations/updatecustomerlink.md @@ -0,0 +1,25 @@ +# UpdateCustomerLink + +## Example Usage + +```typescript +import { UpdateCustomerLink } from "dub/models/operations"; + +let value: UpdateCustomerLink = { + id: "", + domain: "brilliant-fuel.info", + key: "", + shortLink: "https://golden-seafood.net", + programId: "", +}; +``` + +## Fields + +| Field | Type | Required | Description | +| ----------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------- | +| `id` | *string* | :heavy_check_mark: | The unique ID of the short link. | +| `domain` | *string* | :heavy_check_mark: | The domain of the short link. If not provided, the primary domain for the workspace will be used (or `dub.sh` if the workspace has no domains). | +| `key` | *string* | :heavy_check_mark: | The short link slug. If not provided, a random 7-character slug will be generated. | +| `shortLink` | *string* | :heavy_check_mark: | The full URL of the short link, including the https protocol (e.g. `https://dub.sh/try`). | +| `programId` | *string* | :heavy_check_mark: | The ID of the program the short link is associated with. | \ No newline at end of file diff --git a/docs/models/operations/updatecustomerresponsebody.md b/docs/models/operations/updatecustomerresponsebody.md index 7a1ca46b..79b69866 100644 --- a/docs/models/operations/updatecustomerresponsebody.md +++ b/docs/models/operations/updatecustomerresponsebody.md @@ -17,11 +17,13 @@ let value: UpdateCustomerResponseBody = { ## Fields -| Field | Type | Required | Description | -| ------------------------------------------------------- | ------------------------------------------------------- | ------------------------------------------------------- | ------------------------------------------------------- | -| `id` | *string* | :heavy_check_mark: | The unique identifier of the customer in Dub. | -| `externalId` | *string* | :heavy_check_mark: | Unique identifier for the customer in the client's app. | -| `name` | *string* | :heavy_check_mark: | Name of the customer. | -| `email` | *string* | :heavy_minus_sign: | Email of the customer. | -| `avatar` | *string* | :heavy_minus_sign: | Avatar URL of the customer. | -| `createdAt` | *string* | :heavy_check_mark: | The date the customer was created. | \ No newline at end of file +| Field | Type | Required | Description | +| ------------------------------------------------------------------------------ | ------------------------------------------------------------------------------ | ------------------------------------------------------------------------------ | ------------------------------------------------------------------------------ | +| `id` | *string* | :heavy_check_mark: | The unique identifier of the customer in Dub. | +| `externalId` | *string* | :heavy_check_mark: | Unique identifier for the customer in the client's app. | +| `name` | *string* | :heavy_check_mark: | Name of the customer. | +| `email` | *string* | :heavy_minus_sign: | Email of the customer. | +| `avatar` | *string* | :heavy_minus_sign: | Avatar URL of the customer. | +| `country` | *string* | :heavy_minus_sign: | Country of the customer. | +| `createdAt` | *string* | :heavy_check_mark: | The date the customer was created. | +| `link` | [operations.UpdateCustomerLink](../../models/operations/updatecustomerlink.md) | :heavy_minus_sign: | N/A | \ No newline at end of file diff --git a/docs/models/operations/updatetagcolor.md b/docs/models/operations/updatetagcolor.md index 24f62eec..13d42835 100644 --- a/docs/models/operations/updatetagcolor.md +++ b/docs/models/operations/updatetagcolor.md @@ -7,7 +7,7 @@ The color of the tag. If not provided, a random color will be used from the list ```typescript import { UpdateTagColor } from "dub/models/operations"; -let value: UpdateTagColor = "blue"; +let value: UpdateTagColor = "red"; ``` ## Values diff --git a/docs/sdks/track/README.md b/docs/sdks/track/README.md index b181bf65..7ecc8c2b 100644 --- a/docs/sdks/track/README.md +++ b/docs/sdks/track/README.md @@ -7,7 +7,6 @@ * [lead](#lead) - Track a lead * [sale](#sale) - Track a sale -* [~~customer~~](#customer) - Track a customer :warning: **Deprecated** ## lead @@ -158,89 +157,6 @@ run(); ### Errors -| Error Type | Status Code | Content Type | -| -------------------------- | -------------------------- | -------------------------- | -| errors.BadRequest | 400 | application/json | -| errors.Unauthorized | 401 | application/json | -| errors.Forbidden | 403 | application/json | -| errors.NotFound | 404 | application/json | -| errors.Conflict | 409 | application/json | -| errors.InviteExpired | 410 | application/json | -| errors.UnprocessableEntity | 422 | application/json | -| errors.RateLimitExceeded | 429 | application/json | -| errors.InternalServerError | 500 | application/json | -| errors.SDKError | 4XX, 5XX | \*/\* | - -## ~~customer~~ - -Track a customer for an authenticated workspace. - -> :warning: **DEPRECATED**: This will be removed in a future release, please migrate away from it as soon as possible. - -### Example Usage - -```typescript -import { Dub } from "dub"; - -const dub = new Dub({ - token: "DUB_API_KEY", -}); - -async function run() { - const result = await dub.track.customer(); - - // Handle the result - console.log(result); -} - -run(); -``` - -### Standalone function - -The standalone function version of this method: - -```typescript -import { DubCore } from "dub/core.js"; -import { trackCustomer } from "dub/funcs/trackCustomer.js"; - -// Use `DubCore` for best tree-shaking performance. -// You can create one instance of it to use across an application. -const dub = new DubCore({ - token: "DUB_API_KEY", -}); - -async function run() { - const res = await trackCustomer(dub); - - if (!res.ok) { - throw res.error; - } - - const { value: result } = res; - - // Handle the result - console.log(result); -} - -run(); -``` - -### Parameters - -| Parameter | Type | Required | Description | -| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | -| `request` | [operations.TrackCustomerRequestBody](../../models/operations/trackcustomerrequestbody.md) | :heavy_check_mark: | The request object to use for the request. | -| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. | -| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. | -| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. | - -### Response - -**Promise\<[operations.TrackCustomerResponseBody](../../models/operations/trackcustomerresponsebody.md)\>** - -### Errors - | Error Type | Status Code | Content Type | | -------------------------- | -------------------------- | -------------------------- | | errors.BadRequest | 400 | application/json | diff --git a/jsr.json b/jsr.json index 14df5464..73892836 100644 --- a/jsr.json +++ b/jsr.json @@ -2,7 +2,7 @@ { "name": "dub", - "version": "0.46.7", + "version": "0.46.8", "exports": { ".": "./src/index.ts", "./models/errors": "./src/models/errors/index.ts", diff --git a/package-lock.json b/package-lock.json index 60ed5d4e..ba167d10 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "dub", - "version": "0.46.7", + "version": "0.46.8", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "dub", - "version": "0.46.7", + "version": "0.46.8", "devDependencies": { "@types/node": "^20.12.7", "@typescript-eslint/eslint-plugin": "^7.7.1", diff --git a/package.json b/package.json index 3201c690..4c434f93 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "dub", - "version": "0.46.7", + "version": "0.46.8", "author": "Dub", "tshy": { "exports": { diff --git a/src/funcs/domainsList.ts b/src/funcs/domainsList.ts index 677d28d3..c65e9b5a 100644 --- a/src/funcs/domainsList.ts +++ b/src/funcs/domainsList.ts @@ -209,7 +209,7 @@ export async function domainsList( >; "~next"?: { page: number }; } => { - const page = request?.page || 0; + const page = request?.page ?? 1; const nextPage = page + 1; if (!responseData) { @@ -221,7 +221,7 @@ export async function domainsList( if (!Array.isArray(results) || !results.length) { return { next: () => null }; } - const limit = request?.pageSize || 0; + const limit = request?.pageSize ?? 50; if (results.length < limit) { return { next: () => null }; } diff --git a/src/funcs/linksList.ts b/src/funcs/linksList.ts index 7035ce3b..c8beba7f 100644 --- a/src/funcs/linksList.ts +++ b/src/funcs/linksList.ts @@ -214,7 +214,7 @@ export async function linksList( >; "~next"?: { page: number }; } => { - const page = request?.page || 0; + const page = request?.page ?? 1; const nextPage = page + 1; if (!responseData) { @@ -226,7 +226,7 @@ export async function linksList( if (!Array.isArray(results) || !results.length) { return { next: () => null }; } - const limit = request?.pageSize || 0; + const limit = request?.pageSize ?? 100; if (results.length < limit) { return { next: () => null }; } diff --git a/src/funcs/trackCustomer.ts b/src/funcs/trackCustomer.ts deleted file mode 100644 index f8d0ca02..00000000 --- a/src/funcs/trackCustomer.ts +++ /dev/null @@ -1,175 +0,0 @@ -/* - * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. - */ - -import { DubCore } from "../core.js"; -import { encodeJSON } from "../lib/encodings.js"; -import * as M from "../lib/matchers.js"; -import { safeParse } from "../lib/schemas.js"; -import { RequestOptions } from "../lib/sdks.js"; -import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js"; -import { pathToFunc } from "../lib/url.js"; -import { - ConnectionError, - InvalidRequestError, - RequestAbortedError, - RequestTimeoutError, - UnexpectedClientError, -} from "../models/errors/httpclienterrors.js"; -import * as errors from "../models/errors/index.js"; -import { SDKError } from "../models/errors/sdkerror.js"; -import { SDKValidationError } from "../models/errors/sdkvalidationerror.js"; -import * as operations from "../models/operations/index.js"; -import { Result } from "../types/fp.js"; - -/** - * Track a customer - * - * @remarks - * Track a customer for an authenticated workspace. - * - * @deprecated method: This will be removed in a future release, please migrate away from it as soon as possible. - */ -export async function trackCustomer( - client: DubCore, - request?: operations.TrackCustomerRequestBody | undefined, - options?: RequestOptions, -): Promise< - Result< - operations.TrackCustomerResponseBody, - | errors.BadRequest - | errors.Unauthorized - | errors.Forbidden - | errors.NotFound - | errors.Conflict - | errors.InviteExpired - | errors.UnprocessableEntity - | errors.RateLimitExceeded - | errors.InternalServerError - | SDKError - | SDKValidationError - | UnexpectedClientError - | InvalidRequestError - | RequestAbortedError - | RequestTimeoutError - | ConnectionError - > -> { - const parsed = safeParse( - request, - (value) => - operations.TrackCustomerRequestBody$outboundSchema.optional().parse( - value, - ), - "Input validation failed", - ); - if (!parsed.ok) { - return parsed; - } - const payload = parsed.value; - const body = payload === undefined - ? null - : encodeJSON("body", payload, { explode: true }); - - const path = pathToFunc("/track/customer")(); - - const headers = new Headers({ - "Content-Type": "application/json", - Accept: "application/json", - }); - - const secConfig = await extractSecurity(client._options.token); - const securityInput = secConfig == null ? {} : { token: secConfig }; - const requestSecurity = resolveGlobalSecurity(securityInput); - - const context = { - operationID: "trackCustomer", - oAuth2Scopes: [], - - resolvedSecurity: requestSecurity, - - securitySource: client._options.token, - retryConfig: options?.retries - || client._options.retryConfig - || { strategy: "none" }, - retryCodes: options?.retryCodes || ["429", "500", "502", "503", "504"], - }; - - const requestRes = client._createRequest(context, { - security: requestSecurity, - method: "POST", - baseURL: options?.serverURL, - path: path, - headers: headers, - body: body, - timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1, - }, options); - if (!requestRes.ok) { - return requestRes; - } - const req = requestRes.value; - - const doResult = await client._do(req, { - context, - errorCodes: [ - "400", - "401", - "403", - "404", - "409", - "410", - "422", - "429", - "4XX", - "500", - "5XX", - ], - retryConfig: context.retryConfig, - retryCodes: context.retryCodes, - }); - if (!doResult.ok) { - return doResult; - } - const response = doResult.value; - - const responseFields = { - HttpMeta: { Response: response, Request: req }, - }; - - const [result] = await M.match< - operations.TrackCustomerResponseBody, - | errors.BadRequest - | errors.Unauthorized - | errors.Forbidden - | errors.NotFound - | errors.Conflict - | errors.InviteExpired - | errors.UnprocessableEntity - | errors.RateLimitExceeded - | errors.InternalServerError - | SDKError - | SDKValidationError - | UnexpectedClientError - | InvalidRequestError - | RequestAbortedError - | RequestTimeoutError - | ConnectionError - >( - M.json(200, operations.TrackCustomerResponseBody$inboundSchema), - M.jsonErr(400, errors.BadRequest$inboundSchema), - M.jsonErr(401, errors.Unauthorized$inboundSchema), - M.jsonErr(403, errors.Forbidden$inboundSchema), - M.jsonErr(404, errors.NotFound$inboundSchema), - M.jsonErr(409, errors.Conflict$inboundSchema), - M.jsonErr(410, errors.InviteExpired$inboundSchema), - M.jsonErr(422, errors.UnprocessableEntity$inboundSchema), - M.jsonErr(429, errors.RateLimitExceeded$inboundSchema), - M.jsonErr(500, errors.InternalServerError$inboundSchema), - M.fail(["4XX", "5XX"]), - )(response, { extraFields: responseFields }); - if (!result.ok) { - return result; - } - - return result; -} diff --git a/src/lib/config.ts b/src/lib/config.ts index cddd99c1..56fdccee 100644 --- a/src/lib/config.ts +++ b/src/lib/config.ts @@ -57,7 +57,7 @@ export function serverURLFromOptions(options: SDKOptions): URL | null { export const SDK_METADATA = { language: "typescript", openapiDocVersion: "0.0.1", - sdkVersion: "0.46.7", - genVersion: "2.481.0", - userAgent: "speakeasy-sdk/typescript 0.46.7 2.481.0 0.0.1 dub", + sdkVersion: "0.46.8", + genVersion: "2.483.1", + userAgent: "speakeasy-sdk/typescript 0.46.8 2.483.1 0.0.1 dub", } as const; diff --git a/src/models/components/leadcreatedevent.ts b/src/models/components/leadcreatedevent.ts index 2625e7de..a3928672 100644 --- a/src/models/components/leadcreatedevent.ts +++ b/src/models/components/leadcreatedevent.ts @@ -20,6 +20,29 @@ export const LeadCreatedEventEvent = { } as const; export type LeadCreatedEventEvent = ClosedEnum; +export type LeadCreatedEventDataLink = { + /** + * The unique ID of the short link. + */ + id: string; + /** + * The domain of the short link. If not provided, the primary domain for the workspace will be used (or `dub.sh` if the workspace has no domains). + */ + domain: string; + /** + * The short link slug. If not provided, a random 7-character slug will be generated. + */ + key: string; + /** + * The full URL of the short link, including the https protocol (e.g. `https://dub.sh/try`). + */ + shortLink: string; + /** + * The ID of the program the short link is associated with. + */ + programId: string | null; +}; + export type LeadCreatedEventCustomer = { /** * The unique identifier of the customer in Dub. @@ -41,10 +64,15 @@ export type LeadCreatedEventCustomer = { * Avatar URL of the customer. */ avatar?: string | null | undefined; + /** + * Country of the customer. + */ + country?: string | null | undefined; /** * The date the customer was created. */ createdAt: string; + link?: LeadCreatedEventDataLink | null | undefined; }; export type LeadCreatedEventClick = { @@ -497,6 +525,72 @@ export namespace LeadCreatedEventEvent$ { export const outboundSchema = LeadCreatedEventEvent$outboundSchema; } +/** @internal */ +export const LeadCreatedEventDataLink$inboundSchema: z.ZodType< + LeadCreatedEventDataLink, + z.ZodTypeDef, + unknown +> = z.object({ + id: z.string(), + domain: z.string(), + key: z.string(), + shortLink: z.string(), + programId: z.nullable(z.string()), +}); + +/** @internal */ +export type LeadCreatedEventDataLink$Outbound = { + id: string; + domain: string; + key: string; + shortLink: string; + programId: string | null; +}; + +/** @internal */ +export const LeadCreatedEventDataLink$outboundSchema: z.ZodType< + LeadCreatedEventDataLink$Outbound, + z.ZodTypeDef, + LeadCreatedEventDataLink +> = z.object({ + id: z.string(), + domain: z.string(), + key: z.string(), + shortLink: z.string(), + programId: z.nullable(z.string()), +}); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace LeadCreatedEventDataLink$ { + /** @deprecated use `LeadCreatedEventDataLink$inboundSchema` instead. */ + export const inboundSchema = LeadCreatedEventDataLink$inboundSchema; + /** @deprecated use `LeadCreatedEventDataLink$outboundSchema` instead. */ + export const outboundSchema = LeadCreatedEventDataLink$outboundSchema; + /** @deprecated use `LeadCreatedEventDataLink$Outbound` instead. */ + export type Outbound = LeadCreatedEventDataLink$Outbound; +} + +export function leadCreatedEventDataLinkToJSON( + leadCreatedEventDataLink: LeadCreatedEventDataLink, +): string { + return JSON.stringify( + LeadCreatedEventDataLink$outboundSchema.parse(leadCreatedEventDataLink), + ); +} + +export function leadCreatedEventDataLinkFromJSON( + jsonString: string, +): SafeParseResult { + return safeParse( + jsonString, + (x) => LeadCreatedEventDataLink$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'LeadCreatedEventDataLink' from JSON`, + ); +} + /** @internal */ export const LeadCreatedEventCustomer$inboundSchema: z.ZodType< LeadCreatedEventCustomer, @@ -508,7 +602,10 @@ export const LeadCreatedEventCustomer$inboundSchema: z.ZodType< name: z.string(), email: z.nullable(z.string()).optional(), avatar: z.nullable(z.string()).optional(), + country: z.nullable(z.string()).optional(), createdAt: z.string(), + link: z.nullable(z.lazy(() => LeadCreatedEventDataLink$inboundSchema)) + .optional(), }); /** @internal */ @@ -518,7 +615,9 @@ export type LeadCreatedEventCustomer$Outbound = { name: string; email?: string | null | undefined; avatar?: string | null | undefined; + country?: string | null | undefined; createdAt: string; + link?: LeadCreatedEventDataLink$Outbound | null | undefined; }; /** @internal */ @@ -532,7 +631,10 @@ export const LeadCreatedEventCustomer$outboundSchema: z.ZodType< name: z.string(), email: z.nullable(z.string()).optional(), avatar: z.nullable(z.string()).optional(), + country: z.nullable(z.string()).optional(), createdAt: z.string(), + link: z.nullable(z.lazy(() => LeadCreatedEventDataLink$outboundSchema)) + .optional(), }); /** diff --git a/src/models/components/leadevent.ts b/src/models/components/leadevent.ts index 7dd0a33b..b6b66be1 100644 --- a/src/models/components/leadevent.ts +++ b/src/models/components/leadevent.ts @@ -432,6 +432,29 @@ export type LeadEventLink = { programId: string | null; }; +export type LeadEventCustomerLink = { + /** + * The unique ID of the short link. + */ + id: string; + /** + * The domain of the short link. If not provided, the primary domain for the workspace will be used (or `dub.sh` if the workspace has no domains). + */ + domain: string; + /** + * The short link slug. If not provided, a random 7-character slug will be generated. + */ + key: string; + /** + * The full URL of the short link, including the https protocol (e.g. `https://dub.sh/try`). + */ + shortLink: string; + /** + * The ID of the program the short link is associated with. + */ + programId: string | null; +}; + export type Customer = { /** * The unique identifier of the customer in Dub. @@ -453,10 +476,15 @@ export type Customer = { * Avatar URL of the customer. */ avatar?: string | null | undefined; + /** + * Country of the customer. + */ + country?: string | null | undefined; /** * The date the customer was created. */ createdAt: string; + link?: LeadEventCustomerLink | null | undefined; }; export type LeadEvent = { @@ -2149,6 +2177,72 @@ export function leadEventLinkFromJSON( ); } +/** @internal */ +export const LeadEventCustomerLink$inboundSchema: z.ZodType< + LeadEventCustomerLink, + z.ZodTypeDef, + unknown +> = z.object({ + id: z.string(), + domain: z.string(), + key: z.string(), + shortLink: z.string(), + programId: z.nullable(z.string()), +}); + +/** @internal */ +export type LeadEventCustomerLink$Outbound = { + id: string; + domain: string; + key: string; + shortLink: string; + programId: string | null; +}; + +/** @internal */ +export const LeadEventCustomerLink$outboundSchema: z.ZodType< + LeadEventCustomerLink$Outbound, + z.ZodTypeDef, + LeadEventCustomerLink +> = z.object({ + id: z.string(), + domain: z.string(), + key: z.string(), + shortLink: z.string(), + programId: z.nullable(z.string()), +}); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace LeadEventCustomerLink$ { + /** @deprecated use `LeadEventCustomerLink$inboundSchema` instead. */ + export const inboundSchema = LeadEventCustomerLink$inboundSchema; + /** @deprecated use `LeadEventCustomerLink$outboundSchema` instead. */ + export const outboundSchema = LeadEventCustomerLink$outboundSchema; + /** @deprecated use `LeadEventCustomerLink$Outbound` instead. */ + export type Outbound = LeadEventCustomerLink$Outbound; +} + +export function leadEventCustomerLinkToJSON( + leadEventCustomerLink: LeadEventCustomerLink, +): string { + return JSON.stringify( + LeadEventCustomerLink$outboundSchema.parse(leadEventCustomerLink), + ); +} + +export function leadEventCustomerLinkFromJSON( + jsonString: string, +): SafeParseResult { + return safeParse( + jsonString, + (x) => LeadEventCustomerLink$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'LeadEventCustomerLink' from JSON`, + ); +} + /** @internal */ export const Customer$inboundSchema: z.ZodType< Customer, @@ -2160,7 +2254,10 @@ export const Customer$inboundSchema: z.ZodType< name: z.string(), email: z.nullable(z.string()).optional(), avatar: z.nullable(z.string()).optional(), + country: z.nullable(z.string()).optional(), createdAt: z.string(), + link: z.nullable(z.lazy(() => LeadEventCustomerLink$inboundSchema)) + .optional(), }); /** @internal */ @@ -2170,7 +2267,9 @@ export type Customer$Outbound = { name: string; email?: string | null | undefined; avatar?: string | null | undefined; + country?: string | null | undefined; createdAt: string; + link?: LeadEventCustomerLink$Outbound | null | undefined; }; /** @internal */ @@ -2184,7 +2283,10 @@ export const Customer$outboundSchema: z.ZodType< name: z.string(), email: z.nullable(z.string()).optional(), avatar: z.nullable(z.string()).optional(), + country: z.nullable(z.string()).optional(), createdAt: z.string(), + link: z.nullable(z.lazy(() => LeadEventCustomerLink$outboundSchema)) + .optional(), }); /** diff --git a/src/models/components/salecreatedevent.ts b/src/models/components/salecreatedevent.ts index 15e1e785..8aeb3c15 100644 --- a/src/models/components/salecreatedevent.ts +++ b/src/models/components/salecreatedevent.ts @@ -20,6 +20,29 @@ export const SaleCreatedEventEvent = { } as const; export type SaleCreatedEventEvent = ClosedEnum; +export type SaleCreatedEventDataLink = { + /** + * The unique ID of the short link. + */ + id: string; + /** + * The domain of the short link. If not provided, the primary domain for the workspace will be used (or `dub.sh` if the workspace has no domains). + */ + domain: string; + /** + * The short link slug. If not provided, a random 7-character slug will be generated. + */ + key: string; + /** + * The full URL of the short link, including the https protocol (e.g. `https://dub.sh/try`). + */ + shortLink: string; + /** + * The ID of the program the short link is associated with. + */ + programId: string | null; +}; + export type SaleCreatedEventCustomer = { /** * The unique identifier of the customer in Dub. @@ -41,10 +64,15 @@ export type SaleCreatedEventCustomer = { * Avatar URL of the customer. */ avatar?: string | null | undefined; + /** + * Country of the customer. + */ + country?: string | null | undefined; /** * The date the customer was created. */ createdAt: string; + link?: SaleCreatedEventDataLink | null | undefined; }; export type SaleCreatedEventClick = { @@ -505,6 +533,72 @@ export namespace SaleCreatedEventEvent$ { export const outboundSchema = SaleCreatedEventEvent$outboundSchema; } +/** @internal */ +export const SaleCreatedEventDataLink$inboundSchema: z.ZodType< + SaleCreatedEventDataLink, + z.ZodTypeDef, + unknown +> = z.object({ + id: z.string(), + domain: z.string(), + key: z.string(), + shortLink: z.string(), + programId: z.nullable(z.string()), +}); + +/** @internal */ +export type SaleCreatedEventDataLink$Outbound = { + id: string; + domain: string; + key: string; + shortLink: string; + programId: string | null; +}; + +/** @internal */ +export const SaleCreatedEventDataLink$outboundSchema: z.ZodType< + SaleCreatedEventDataLink$Outbound, + z.ZodTypeDef, + SaleCreatedEventDataLink +> = z.object({ + id: z.string(), + domain: z.string(), + key: z.string(), + shortLink: z.string(), + programId: z.nullable(z.string()), +}); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace SaleCreatedEventDataLink$ { + /** @deprecated use `SaleCreatedEventDataLink$inboundSchema` instead. */ + export const inboundSchema = SaleCreatedEventDataLink$inboundSchema; + /** @deprecated use `SaleCreatedEventDataLink$outboundSchema` instead. */ + export const outboundSchema = SaleCreatedEventDataLink$outboundSchema; + /** @deprecated use `SaleCreatedEventDataLink$Outbound` instead. */ + export type Outbound = SaleCreatedEventDataLink$Outbound; +} + +export function saleCreatedEventDataLinkToJSON( + saleCreatedEventDataLink: SaleCreatedEventDataLink, +): string { + return JSON.stringify( + SaleCreatedEventDataLink$outboundSchema.parse(saleCreatedEventDataLink), + ); +} + +export function saleCreatedEventDataLinkFromJSON( + jsonString: string, +): SafeParseResult { + return safeParse( + jsonString, + (x) => SaleCreatedEventDataLink$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'SaleCreatedEventDataLink' from JSON`, + ); +} + /** @internal */ export const SaleCreatedEventCustomer$inboundSchema: z.ZodType< SaleCreatedEventCustomer, @@ -516,7 +610,10 @@ export const SaleCreatedEventCustomer$inboundSchema: z.ZodType< name: z.string(), email: z.nullable(z.string()).optional(), avatar: z.nullable(z.string()).optional(), + country: z.nullable(z.string()).optional(), createdAt: z.string(), + link: z.nullable(z.lazy(() => SaleCreatedEventDataLink$inboundSchema)) + .optional(), }); /** @internal */ @@ -526,7 +623,9 @@ export type SaleCreatedEventCustomer$Outbound = { name: string; email?: string | null | undefined; avatar?: string | null | undefined; + country?: string | null | undefined; createdAt: string; + link?: SaleCreatedEventDataLink$Outbound | null | undefined; }; /** @internal */ @@ -540,7 +639,10 @@ export const SaleCreatedEventCustomer$outboundSchema: z.ZodType< name: z.string(), email: z.nullable(z.string()).optional(), avatar: z.nullable(z.string()).optional(), + country: z.nullable(z.string()).optional(), createdAt: z.string(), + link: z.nullable(z.lazy(() => SaleCreatedEventDataLink$outboundSchema)) + .optional(), }); /** diff --git a/src/models/components/saleevent.ts b/src/models/components/saleevent.ts index 9862db6a..21203cd6 100644 --- a/src/models/components/saleevent.ts +++ b/src/models/components/saleevent.ts @@ -432,6 +432,29 @@ export type SaleEventClick = { ip: string; }; +export type SaleEventCustomerLink = { + /** + * The unique ID of the short link. + */ + id: string; + /** + * The domain of the short link. If not provided, the primary domain for the workspace will be used (or `dub.sh` if the workspace has no domains). + */ + domain: string; + /** + * The short link slug. If not provided, a random 7-character slug will be generated. + */ + key: string; + /** + * The full URL of the short link, including the https protocol (e.g. `https://dub.sh/try`). + */ + shortLink: string; + /** + * The ID of the program the short link is associated with. + */ + programId: string | null; +}; + export type SaleEventCustomer = { /** * The unique identifier of the customer in Dub. @@ -453,10 +476,15 @@ export type SaleEventCustomer = { * Avatar URL of the customer. */ avatar?: string | null | undefined; + /** + * Country of the customer. + */ + country?: string | null | undefined; /** * The date the customer was created. */ createdAt: string; + link?: SaleEventCustomerLink | null | undefined; }; /** @@ -2194,6 +2222,72 @@ export function saleEventClickFromJSON( ); } +/** @internal */ +export const SaleEventCustomerLink$inboundSchema: z.ZodType< + SaleEventCustomerLink, + z.ZodTypeDef, + unknown +> = z.object({ + id: z.string(), + domain: z.string(), + key: z.string(), + shortLink: z.string(), + programId: z.nullable(z.string()), +}); + +/** @internal */ +export type SaleEventCustomerLink$Outbound = { + id: string; + domain: string; + key: string; + shortLink: string; + programId: string | null; +}; + +/** @internal */ +export const SaleEventCustomerLink$outboundSchema: z.ZodType< + SaleEventCustomerLink$Outbound, + z.ZodTypeDef, + SaleEventCustomerLink +> = z.object({ + id: z.string(), + domain: z.string(), + key: z.string(), + shortLink: z.string(), + programId: z.nullable(z.string()), +}); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace SaleEventCustomerLink$ { + /** @deprecated use `SaleEventCustomerLink$inboundSchema` instead. */ + export const inboundSchema = SaleEventCustomerLink$inboundSchema; + /** @deprecated use `SaleEventCustomerLink$outboundSchema` instead. */ + export const outboundSchema = SaleEventCustomerLink$outboundSchema; + /** @deprecated use `SaleEventCustomerLink$Outbound` instead. */ + export type Outbound = SaleEventCustomerLink$Outbound; +} + +export function saleEventCustomerLinkToJSON( + saleEventCustomerLink: SaleEventCustomerLink, +): string { + return JSON.stringify( + SaleEventCustomerLink$outboundSchema.parse(saleEventCustomerLink), + ); +} + +export function saleEventCustomerLinkFromJSON( + jsonString: string, +): SafeParseResult { + return safeParse( + jsonString, + (x) => SaleEventCustomerLink$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'SaleEventCustomerLink' from JSON`, + ); +} + /** @internal */ export const SaleEventCustomer$inboundSchema: z.ZodType< SaleEventCustomer, @@ -2205,7 +2299,10 @@ export const SaleEventCustomer$inboundSchema: z.ZodType< name: z.string(), email: z.nullable(z.string()).optional(), avatar: z.nullable(z.string()).optional(), + country: z.nullable(z.string()).optional(), createdAt: z.string(), + link: z.nullable(z.lazy(() => SaleEventCustomerLink$inboundSchema)) + .optional(), }); /** @internal */ @@ -2215,7 +2312,9 @@ export type SaleEventCustomer$Outbound = { name: string; email?: string | null | undefined; avatar?: string | null | undefined; + country?: string | null | undefined; createdAt: string; + link?: SaleEventCustomerLink$Outbound | null | undefined; }; /** @internal */ @@ -2229,7 +2328,10 @@ export const SaleEventCustomer$outboundSchema: z.ZodType< name: z.string(), email: z.nullable(z.string()).optional(), avatar: z.nullable(z.string()).optional(), + country: z.nullable(z.string()).optional(), createdAt: z.string(), + link: z.nullable(z.lazy(() => SaleEventCustomerLink$outboundSchema)) + .optional(), }); /** diff --git a/src/models/operations/createcustomer.ts b/src/models/operations/createcustomer.ts index 40ec4524..b72ebdbe 100644 --- a/src/models/operations/createcustomer.ts +++ b/src/models/operations/createcustomer.ts @@ -26,6 +26,29 @@ export type CreateCustomerRequestBody = { externalId: string; }; +export type CreateCustomerLink = { + /** + * The unique ID of the short link. + */ + id: string; + /** + * The domain of the short link. If not provided, the primary domain for the workspace will be used (or `dub.sh` if the workspace has no domains). + */ + domain: string; + /** + * The short link slug. If not provided, a random 7-character slug will be generated. + */ + key: string; + /** + * The full URL of the short link, including the https protocol (e.g. `https://dub.sh/try`). + */ + shortLink: string; + /** + * The ID of the program the short link is associated with. + */ + programId: string | null; +}; + /** * The customer was created. */ @@ -50,10 +73,15 @@ export type CreateCustomerResponseBody = { * Avatar URL of the customer. */ avatar?: string | null | undefined; + /** + * Country of the customer. + */ + country?: string | null | undefined; /** * The date the customer was created. */ createdAt: string; + link?: CreateCustomerLink | null | undefined; }; /** @internal */ @@ -119,6 +147,72 @@ export function createCustomerRequestBodyFromJSON( ); } +/** @internal */ +export const CreateCustomerLink$inboundSchema: z.ZodType< + CreateCustomerLink, + z.ZodTypeDef, + unknown +> = z.object({ + id: z.string(), + domain: z.string(), + key: z.string(), + shortLink: z.string(), + programId: z.nullable(z.string()), +}); + +/** @internal */ +export type CreateCustomerLink$Outbound = { + id: string; + domain: string; + key: string; + shortLink: string; + programId: string | null; +}; + +/** @internal */ +export const CreateCustomerLink$outboundSchema: z.ZodType< + CreateCustomerLink$Outbound, + z.ZodTypeDef, + CreateCustomerLink +> = z.object({ + id: z.string(), + domain: z.string(), + key: z.string(), + shortLink: z.string(), + programId: z.nullable(z.string()), +}); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace CreateCustomerLink$ { + /** @deprecated use `CreateCustomerLink$inboundSchema` instead. */ + export const inboundSchema = CreateCustomerLink$inboundSchema; + /** @deprecated use `CreateCustomerLink$outboundSchema` instead. */ + export const outboundSchema = CreateCustomerLink$outboundSchema; + /** @deprecated use `CreateCustomerLink$Outbound` instead. */ + export type Outbound = CreateCustomerLink$Outbound; +} + +export function createCustomerLinkToJSON( + createCustomerLink: CreateCustomerLink, +): string { + return JSON.stringify( + CreateCustomerLink$outboundSchema.parse(createCustomerLink), + ); +} + +export function createCustomerLinkFromJSON( + jsonString: string, +): SafeParseResult { + return safeParse( + jsonString, + (x) => CreateCustomerLink$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'CreateCustomerLink' from JSON`, + ); +} + /** @internal */ export const CreateCustomerResponseBody$inboundSchema: z.ZodType< CreateCustomerResponseBody, @@ -130,7 +224,9 @@ export const CreateCustomerResponseBody$inboundSchema: z.ZodType< name: z.string(), email: z.nullable(z.string()).optional(), avatar: z.nullable(z.string()).optional(), + country: z.nullable(z.string()).optional(), createdAt: z.string(), + link: z.nullable(z.lazy(() => CreateCustomerLink$inboundSchema)).optional(), }); /** @internal */ @@ -140,7 +236,9 @@ export type CreateCustomerResponseBody$Outbound = { name: string; email?: string | null | undefined; avatar?: string | null | undefined; + country?: string | null | undefined; createdAt: string; + link?: CreateCustomerLink$Outbound | null | undefined; }; /** @internal */ @@ -154,7 +252,9 @@ export const CreateCustomerResponseBody$outboundSchema: z.ZodType< name: z.string(), email: z.nullable(z.string()).optional(), avatar: z.nullable(z.string()).optional(), + country: z.nullable(z.string()).optional(), createdAt: z.string(), + link: z.nullable(z.lazy(() => CreateCustomerLink$outboundSchema)).optional(), }); /** diff --git a/src/models/operations/getcustomer.ts b/src/models/operations/getcustomer.ts index 756fa7cf..fa38b788 100644 --- a/src/models/operations/getcustomer.ts +++ b/src/models/operations/getcustomer.ts @@ -14,6 +14,29 @@ export type GetCustomerRequest = { id: string; }; +export type GetCustomerLink = { + /** + * The unique ID of the short link. + */ + id: string; + /** + * The domain of the short link. If not provided, the primary domain for the workspace will be used (or `dub.sh` if the workspace has no domains). + */ + domain: string; + /** + * The short link slug. If not provided, a random 7-character slug will be generated. + */ + key: string; + /** + * The full URL of the short link, including the https protocol (e.g. `https://dub.sh/try`). + */ + shortLink: string; + /** + * The ID of the program the short link is associated with. + */ + programId: string | null; +}; + /** * The customer object. */ @@ -38,10 +61,15 @@ export type GetCustomerResponseBody = { * Avatar URL of the customer. */ avatar?: string | null | undefined; + /** + * Country of the customer. + */ + country?: string | null | undefined; /** * The date the customer was created. */ createdAt: string; + link?: GetCustomerLink | null | undefined; }; /** @internal */ @@ -98,6 +126,70 @@ export function getCustomerRequestFromJSON( ); } +/** @internal */ +export const GetCustomerLink$inboundSchema: z.ZodType< + GetCustomerLink, + z.ZodTypeDef, + unknown +> = z.object({ + id: z.string(), + domain: z.string(), + key: z.string(), + shortLink: z.string(), + programId: z.nullable(z.string()), +}); + +/** @internal */ +export type GetCustomerLink$Outbound = { + id: string; + domain: string; + key: string; + shortLink: string; + programId: string | null; +}; + +/** @internal */ +export const GetCustomerLink$outboundSchema: z.ZodType< + GetCustomerLink$Outbound, + z.ZodTypeDef, + GetCustomerLink +> = z.object({ + id: z.string(), + domain: z.string(), + key: z.string(), + shortLink: z.string(), + programId: z.nullable(z.string()), +}); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace GetCustomerLink$ { + /** @deprecated use `GetCustomerLink$inboundSchema` instead. */ + export const inboundSchema = GetCustomerLink$inboundSchema; + /** @deprecated use `GetCustomerLink$outboundSchema` instead. */ + export const outboundSchema = GetCustomerLink$outboundSchema; + /** @deprecated use `GetCustomerLink$Outbound` instead. */ + export type Outbound = GetCustomerLink$Outbound; +} + +export function getCustomerLinkToJSON( + getCustomerLink: GetCustomerLink, +): string { + return JSON.stringify(GetCustomerLink$outboundSchema.parse(getCustomerLink)); +} + +export function getCustomerLinkFromJSON( + jsonString: string, +): SafeParseResult { + return safeParse( + jsonString, + (x) => GetCustomerLink$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'GetCustomerLink' from JSON`, + ); +} + /** @internal */ export const GetCustomerResponseBody$inboundSchema: z.ZodType< GetCustomerResponseBody, @@ -109,7 +201,9 @@ export const GetCustomerResponseBody$inboundSchema: z.ZodType< name: z.string(), email: z.nullable(z.string()).optional(), avatar: z.nullable(z.string()).optional(), + country: z.nullable(z.string()).optional(), createdAt: z.string(), + link: z.nullable(z.lazy(() => GetCustomerLink$inboundSchema)).optional(), }); /** @internal */ @@ -119,7 +213,9 @@ export type GetCustomerResponseBody$Outbound = { name: string; email?: string | null | undefined; avatar?: string | null | undefined; + country?: string | null | undefined; createdAt: string; + link?: GetCustomerLink$Outbound | null | undefined; }; /** @internal */ @@ -133,7 +229,9 @@ export const GetCustomerResponseBody$outboundSchema: z.ZodType< name: z.string(), email: z.nullable(z.string()).optional(), avatar: z.nullable(z.string()).optional(), + country: z.nullable(z.string()).optional(), createdAt: z.string(), + link: z.nullable(z.lazy(() => GetCustomerLink$outboundSchema)).optional(), }); /** diff --git a/src/models/operations/getcustomers.ts b/src/models/operations/getcustomers.ts index 72bb04d1..03c8a202 100644 --- a/src/models/operations/getcustomers.ts +++ b/src/models/operations/getcustomers.ts @@ -7,6 +7,29 @@ import { safeParse } from "../../lib/schemas.js"; import { Result as SafeParseResult } from "../../types/fp.js"; import { SDKValidationError } from "../errors/sdkvalidationerror.js"; +export type Link = { + /** + * The unique ID of the short link. + */ + id: string; + /** + * The domain of the short link. If not provided, the primary domain for the workspace will be used (or `dub.sh` if the workspace has no domains). + */ + domain: string; + /** + * The short link slug. If not provided, a random 7-character slug will be generated. + */ + key: string; + /** + * The full URL of the short link, including the https protocol (e.g. `https://dub.sh/try`). + */ + shortLink: string; + /** + * The ID of the program the short link is associated with. + */ + programId: string | null; +}; + export type ResponseBody = { /** * The unique identifier of the customer in Dub. @@ -28,12 +51,73 @@ export type ResponseBody = { * Avatar URL of the customer. */ avatar?: string | null | undefined; + /** + * Country of the customer. + */ + country?: string | null | undefined; /** * The date the customer was created. */ createdAt: string; + link?: Link | null | undefined; }; +/** @internal */ +export const Link$inboundSchema: z.ZodType = z + .object({ + id: z.string(), + domain: z.string(), + key: z.string(), + shortLink: z.string(), + programId: z.nullable(z.string()), + }); + +/** @internal */ +export type Link$Outbound = { + id: string; + domain: string; + key: string; + shortLink: string; + programId: string | null; +}; + +/** @internal */ +export const Link$outboundSchema: z.ZodType = + z.object({ + id: z.string(), + domain: z.string(), + key: z.string(), + shortLink: z.string(), + programId: z.nullable(z.string()), + }); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace Link$ { + /** @deprecated use `Link$inboundSchema` instead. */ + export const inboundSchema = Link$inboundSchema; + /** @deprecated use `Link$outboundSchema` instead. */ + export const outboundSchema = Link$outboundSchema; + /** @deprecated use `Link$Outbound` instead. */ + export type Outbound = Link$Outbound; +} + +export function linkToJSON(link: Link): string { + return JSON.stringify(Link$outboundSchema.parse(link)); +} + +export function linkFromJSON( + jsonString: string, +): SafeParseResult { + return safeParse( + jsonString, + (x) => Link$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'Link' from JSON`, + ); +} + /** @internal */ export const ResponseBody$inboundSchema: z.ZodType< ResponseBody, @@ -45,7 +129,9 @@ export const ResponseBody$inboundSchema: z.ZodType< name: z.string(), email: z.nullable(z.string()).optional(), avatar: z.nullable(z.string()).optional(), + country: z.nullable(z.string()).optional(), createdAt: z.string(), + link: z.nullable(z.lazy(() => Link$inboundSchema)).optional(), }); /** @internal */ @@ -55,7 +141,9 @@ export type ResponseBody$Outbound = { name: string; email?: string | null | undefined; avatar?: string | null | undefined; + country?: string | null | undefined; createdAt: string; + link?: Link$Outbound | null | undefined; }; /** @internal */ @@ -69,7 +157,9 @@ export const ResponseBody$outboundSchema: z.ZodType< name: z.string(), email: z.nullable(z.string()).optional(), avatar: z.nullable(z.string()).optional(), + country: z.nullable(z.string()).optional(), createdAt: z.string(), + link: z.nullable(z.lazy(() => Link$outboundSchema)).optional(), }); /** diff --git a/src/models/operations/index.ts b/src/models/operations/index.ts index d3c34654..581d6ab9 100644 --- a/src/models/operations/index.ts +++ b/src/models/operations/index.ts @@ -25,7 +25,6 @@ export * from "./getworkspace.js"; export * from "./listdomains.js"; export * from "./listevents.js"; export * from "./retrieveanalytics.js"; -export * from "./trackcustomer.js"; export * from "./tracklead.js"; export * from "./tracksale.js"; export * from "./updatecustomer.js"; diff --git a/src/models/operations/trackcustomer.ts b/src/models/operations/trackcustomer.ts deleted file mode 100644 index 0364eb10..00000000 --- a/src/models/operations/trackcustomer.ts +++ /dev/null @@ -1,163 +0,0 @@ -/* - * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. - */ - -import * as z from "zod"; -import { safeParse } from "../../lib/schemas.js"; -import { Result as SafeParseResult } from "../../types/fp.js"; -import { SDKValidationError } from "../errors/sdkvalidationerror.js"; - -export type TrackCustomerRequestBody = { - /** - * This is the unique identifier for the customer in the client's app. This is used to track the customer's journey. - */ - customerId: string; - /** - * Name of the customer in the client's app. - */ - customerName?: string | undefined; - /** - * Email of the customer in the client's app. - */ - customerEmail?: string | undefined; - /** - * Avatar of the customer in the client's app. - */ - customerAvatar?: string | undefined; -}; - -/** - * A customer was tracked. - */ -export type TrackCustomerResponseBody = { - customerId: string; - customerName: string | null; - customerEmail: string | null; - customerAvatar: string | null; -}; - -/** @internal */ -export const TrackCustomerRequestBody$inboundSchema: z.ZodType< - TrackCustomerRequestBody, - z.ZodTypeDef, - unknown -> = z.object({ - customerId: z.string(), - customerName: z.string().optional(), - customerEmail: z.string().optional(), - customerAvatar: z.string().optional(), -}); - -/** @internal */ -export type TrackCustomerRequestBody$Outbound = { - customerId: string; - customerName?: string | undefined; - customerEmail?: string | undefined; - customerAvatar?: string | undefined; -}; - -/** @internal */ -export const TrackCustomerRequestBody$outboundSchema: z.ZodType< - TrackCustomerRequestBody$Outbound, - z.ZodTypeDef, - TrackCustomerRequestBody -> = z.object({ - customerId: z.string(), - customerName: z.string().optional(), - customerEmail: z.string().optional(), - customerAvatar: z.string().optional(), -}); - -/** - * @internal - * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. - */ -export namespace TrackCustomerRequestBody$ { - /** @deprecated use `TrackCustomerRequestBody$inboundSchema` instead. */ - export const inboundSchema = TrackCustomerRequestBody$inboundSchema; - /** @deprecated use `TrackCustomerRequestBody$outboundSchema` instead. */ - export const outboundSchema = TrackCustomerRequestBody$outboundSchema; - /** @deprecated use `TrackCustomerRequestBody$Outbound` instead. */ - export type Outbound = TrackCustomerRequestBody$Outbound; -} - -export function trackCustomerRequestBodyToJSON( - trackCustomerRequestBody: TrackCustomerRequestBody, -): string { - return JSON.stringify( - TrackCustomerRequestBody$outboundSchema.parse(trackCustomerRequestBody), - ); -} - -export function trackCustomerRequestBodyFromJSON( - jsonString: string, -): SafeParseResult { - return safeParse( - jsonString, - (x) => TrackCustomerRequestBody$inboundSchema.parse(JSON.parse(x)), - `Failed to parse 'TrackCustomerRequestBody' from JSON`, - ); -} - -/** @internal */ -export const TrackCustomerResponseBody$inboundSchema: z.ZodType< - TrackCustomerResponseBody, - z.ZodTypeDef, - unknown -> = z.object({ - customerId: z.string(), - customerName: z.nullable(z.string()), - customerEmail: z.nullable(z.string()), - customerAvatar: z.nullable(z.string()), -}); - -/** @internal */ -export type TrackCustomerResponseBody$Outbound = { - customerId: string; - customerName: string | null; - customerEmail: string | null; - customerAvatar: string | null; -}; - -/** @internal */ -export const TrackCustomerResponseBody$outboundSchema: z.ZodType< - TrackCustomerResponseBody$Outbound, - z.ZodTypeDef, - TrackCustomerResponseBody -> = z.object({ - customerId: z.string(), - customerName: z.nullable(z.string()), - customerEmail: z.nullable(z.string()), - customerAvatar: z.nullable(z.string()), -}); - -/** - * @internal - * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. - */ -export namespace TrackCustomerResponseBody$ { - /** @deprecated use `TrackCustomerResponseBody$inboundSchema` instead. */ - export const inboundSchema = TrackCustomerResponseBody$inboundSchema; - /** @deprecated use `TrackCustomerResponseBody$outboundSchema` instead. */ - export const outboundSchema = TrackCustomerResponseBody$outboundSchema; - /** @deprecated use `TrackCustomerResponseBody$Outbound` instead. */ - export type Outbound = TrackCustomerResponseBody$Outbound; -} - -export function trackCustomerResponseBodyToJSON( - trackCustomerResponseBody: TrackCustomerResponseBody, -): string { - return JSON.stringify( - TrackCustomerResponseBody$outboundSchema.parse(trackCustomerResponseBody), - ); -} - -export function trackCustomerResponseBodyFromJSON( - jsonString: string, -): SafeParseResult { - return safeParse( - jsonString, - (x) => TrackCustomerResponseBody$inboundSchema.parse(JSON.parse(x)), - `Failed to parse 'TrackCustomerResponseBody' from JSON`, - ); -} diff --git a/src/models/operations/updatecustomer.ts b/src/models/operations/updatecustomer.ts index c4103ef3..3dbdb859 100644 --- a/src/models/operations/updatecustomer.ts +++ b/src/models/operations/updatecustomer.ts @@ -35,6 +35,29 @@ export type UpdateCustomerRequest = { requestBody?: UpdateCustomerRequestBody | undefined; }; +export type UpdateCustomerLink = { + /** + * The unique ID of the short link. + */ + id: string; + /** + * The domain of the short link. If not provided, the primary domain for the workspace will be used (or `dub.sh` if the workspace has no domains). + */ + domain: string; + /** + * The short link slug. If not provided, a random 7-character slug will be generated. + */ + key: string; + /** + * The full URL of the short link, including the https protocol (e.g. `https://dub.sh/try`). + */ + shortLink: string; + /** + * The ID of the program the short link is associated with. + */ + programId: string | null; +}; + /** * The customer was updated. */ @@ -59,10 +82,15 @@ export type UpdateCustomerResponseBody = { * Avatar URL of the customer. */ avatar?: string | null | undefined; + /** + * Country of the customer. + */ + country?: string | null | undefined; /** * The date the customer was created. */ createdAt: string; + link?: UpdateCustomerLink | null | undefined; }; /** @internal */ @@ -194,6 +222,72 @@ export function updateCustomerRequestFromJSON( ); } +/** @internal */ +export const UpdateCustomerLink$inboundSchema: z.ZodType< + UpdateCustomerLink, + z.ZodTypeDef, + unknown +> = z.object({ + id: z.string(), + domain: z.string(), + key: z.string(), + shortLink: z.string(), + programId: z.nullable(z.string()), +}); + +/** @internal */ +export type UpdateCustomerLink$Outbound = { + id: string; + domain: string; + key: string; + shortLink: string; + programId: string | null; +}; + +/** @internal */ +export const UpdateCustomerLink$outboundSchema: z.ZodType< + UpdateCustomerLink$Outbound, + z.ZodTypeDef, + UpdateCustomerLink +> = z.object({ + id: z.string(), + domain: z.string(), + key: z.string(), + shortLink: z.string(), + programId: z.nullable(z.string()), +}); + +/** + * @internal + * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module. + */ +export namespace UpdateCustomerLink$ { + /** @deprecated use `UpdateCustomerLink$inboundSchema` instead. */ + export const inboundSchema = UpdateCustomerLink$inboundSchema; + /** @deprecated use `UpdateCustomerLink$outboundSchema` instead. */ + export const outboundSchema = UpdateCustomerLink$outboundSchema; + /** @deprecated use `UpdateCustomerLink$Outbound` instead. */ + export type Outbound = UpdateCustomerLink$Outbound; +} + +export function updateCustomerLinkToJSON( + updateCustomerLink: UpdateCustomerLink, +): string { + return JSON.stringify( + UpdateCustomerLink$outboundSchema.parse(updateCustomerLink), + ); +} + +export function updateCustomerLinkFromJSON( + jsonString: string, +): SafeParseResult { + return safeParse( + jsonString, + (x) => UpdateCustomerLink$inboundSchema.parse(JSON.parse(x)), + `Failed to parse 'UpdateCustomerLink' from JSON`, + ); +} + /** @internal */ export const UpdateCustomerResponseBody$inboundSchema: z.ZodType< UpdateCustomerResponseBody, @@ -205,7 +299,9 @@ export const UpdateCustomerResponseBody$inboundSchema: z.ZodType< name: z.string(), email: z.nullable(z.string()).optional(), avatar: z.nullable(z.string()).optional(), + country: z.nullable(z.string()).optional(), createdAt: z.string(), + link: z.nullable(z.lazy(() => UpdateCustomerLink$inboundSchema)).optional(), }); /** @internal */ @@ -215,7 +311,9 @@ export type UpdateCustomerResponseBody$Outbound = { name: string; email?: string | null | undefined; avatar?: string | null | undefined; + country?: string | null | undefined; createdAt: string; + link?: UpdateCustomerLink$Outbound | null | undefined; }; /** @internal */ @@ -229,7 +327,9 @@ export const UpdateCustomerResponseBody$outboundSchema: z.ZodType< name: z.string(), email: z.nullable(z.string()).optional(), avatar: z.nullable(z.string()).optional(), + country: z.nullable(z.string()).optional(), createdAt: z.string(), + link: z.nullable(z.lazy(() => UpdateCustomerLink$outboundSchema)).optional(), }); /** diff --git a/src/sdk/track.ts b/src/sdk/track.ts index b1f21b19..cd1fbd9e 100644 --- a/src/sdk/track.ts +++ b/src/sdk/track.ts @@ -2,7 +2,6 @@ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT. */ -import { trackCustomer } from "../funcs/trackCustomer.js"; import { trackLead } from "../funcs/trackLead.js"; import { trackSale } from "../funcs/trackSale.js"; import { ClientSDK, RequestOptions } from "../lib/sdks.js"; @@ -43,23 +42,4 @@ export class Track extends ClientSDK { options, )); } - - /** - * Track a customer - * - * @remarks - * Track a customer for an authenticated workspace. - * - * @deprecated method: This will be removed in a future release, please migrate away from it as soon as possible. - */ - async customer( - request?: operations.TrackCustomerRequestBody | undefined, - options?: RequestOptions, - ): Promise { - return unwrapAsync(trackCustomer( - this, - request, - options, - )); - } } diff --git a/tsconfig.json b/tsconfig.json index f9d286a7..94d81a34 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -2,7 +2,7 @@ "compilerOptions": { "incremental": true, "tsBuildInfoFile": ".tsbuildinfo", - "target": "ES2018", + "target": "ES2020", "lib": ["ES2022", "DOM", "DOM.Iterable"], "jsx": "react-jsx",